Host license image with website instead of hotlinking and use svg instead of png

This fixes an issue where the CORS headers for the website would not allow the image to be loaded
from the Creative Commons servers.

The switch to svg also makes sure that the icon will always be perfectly rendered, regardless of
screen size or page zooming.
master
Jonas Tobias Hopusch 6 months ago
parent bbf061a364
commit 8536ef00a4
Failed to generate hash of commit
  1. 121
      static/images/copyright/cc-by-nc-nd-4.0-small.svg
  2. 2
      templates/base.html

@ -0,0 +1,121 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://web.resource.org/cc/"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="80"
height="15"
id="svg2279"
sodipodi:version="0.32"
inkscape:version="0.45+devel"
version="1.0"
sodipodi:docname="by-nc-nd.svg"
inkscape:output_extension="org.inkscape.output.svg.inkscape">
<defs
id="defs2281">
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath3442">
<rect
style="fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.92243534;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
id="rect3444"
width="20.614058"
height="12.483703"
x="171.99832"
y="239.1203" />
</clipPath>
</defs>
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#999999"
borderopacity="1"
gridtolerance="10000"
guidetolerance="10"
objecttolerance="10"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="10.5125"
inkscape:cx="40"
inkscape:cy="7.5"
inkscape:document-units="px"
inkscape:current-layer="layer1"
width="80px"
height="15px"
showborder="true"
inkscape:showpageshadow="false"
inkscape:window-width="935"
inkscape:window-height="624"
inkscape:window-x="50"
inkscape:window-y="160" />
<metadata
id="metadata2284">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1">
<g
id="BY-NC-ND"
transform="matrix(0.9875019,0,0,0.9333518,-323.90064,-411.87964)">
<g
id="g3783"
transform="translate(158,204)">
<rect
style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1.04161763;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
id="rect3785"
width="80"
height="15"
x="170.5"
y="237.86218" />
<rect
y="239.36218"
x="172"
height="12"
width="77"
id="rect3787"
style="fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.92243534;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" />
<path
style="fill:#abb1aa;fill-opacity:1;stroke:none;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.46913578"
d="M 171.99996,239.37505 L 171.99996,251.37505 L 192.33474,251.37505 C 193.64339,249.62474 194.52652,247.59057 194.52652,245.37505 C 194.52652,243.17431 193.65859,241.1179 192.36599,239.37505 L 171.99996,239.37505 z"
id="path3789"
sodipodi:nodetypes="cccscc" />
<g
id="g3791"
transform="matrix(0.9612533,0,0,0.9612533,6.8341566,9.5069994)"
clip-path="url(#clipPath3442)">
<path
id="path3793"
cx="296.35416"
ry="22.939548"
cy="264.3577"
type="arc"
rx="22.939548"
d="M 190.06417,245.36206 C 190.06667,249.25405 186.91326,252.41072 183.02153,252.41323 C 179.12979,252.41572 175.97262,249.26256 175.97036,245.3706 C 175.97036,245.36783 175.97036,245.36507 175.97036,245.36206 C 175.9681,241.47007 179.12126,238.3134 183.013,238.31113 C 186.90524,238.30864 190.06191,241.46181 190.06417,245.3538 C 190.06417,245.35628 190.06417,245.35929 190.06417,245.36206 z"
style="opacity:1;fill:#ffffff" />
<path
d="M 188.74576,239.62226 C 190.30843,241.18492 191.08988,243.09869 191.08988,245.36206 C 191.08988,247.62592 190.32197,249.51913 188.78615,251.04165 C 187.15627,252.64521 185.22995,253.44672 183.00722,253.44672 C 180.81132,253.44672 178.91837,252.65172 177.32887,251.06174 C 175.73912,249.47198 174.94436,247.57226 174.94436,245.36206 C 174.94436,243.15235 175.73912,241.23908 177.32887,239.62226 C 178.87799,238.0591 180.77094,237.27764 183.00722,237.27764 C 185.2706,237.27764 187.18312,238.05909 188.74576,239.62226 z M 178.38093,240.67355 C 177.05978,242.008 176.39945,243.57116 176.39945,245.36429 C 176.39945,247.15694 177.05326,248.70682 178.36062,250.01393 C 179.66822,251.32153 181.22487,251.97509 183.03105,251.97509 C 184.83724,251.97509 186.40716,251.31502 187.74161,249.99412 C 189.0086,248.76725 189.64234,247.22467 189.64234,245.36429 C 189.64234,243.51799 188.99831,241.95084 187.71101,240.66354 C 186.42396,239.37649 184.86406,238.7327 183.03105,238.7327 C 181.19804,238.73271 179.64767,239.37975 178.38093,240.67355 z M 181.85761,244.57559 C 181.65573,244.13545 181.35354,243.91525 180.95051,243.91525 C 180.23802,243.91525 179.8819,244.39501 179.8819,245.35404 C 179.8819,246.31328 180.23802,246.79255 180.95051,246.79255 C 181.421,246.79255 181.75705,246.55908 181.95869,246.09111 L 182.94629,246.61701 C 182.47555,247.45339 181.76934,247.87168 180.82763,247.87168 C 180.10136,247.87168 179.51953,247.64899 179.08265,247.20409 C 178.64502,246.7587 178.42684,246.14477 178.42684,245.36206 C 178.42684,244.59313 178.65204,243.98271 179.10271,243.53056 C 179.55338,243.07838 180.11463,242.8524 180.7875,242.8524 C 181.78288,242.8524 182.49561,243.24465 182.92647,244.02835 L 181.85761,244.57559 z M 186.50398,244.57559 C 186.30184,244.13545 186.00567,243.91525 185.61517,243.91525 C 184.88839,243.91525 184.52474,244.39501 184.52474,245.35404 C 184.52474,246.31328 184.88839,246.79255 185.61517,246.79255 C 186.08642,246.79255 186.41644,246.55908 186.6048,246.09111 L 187.61447,246.61701 C 187.14448,247.45339 186.43926,247.87168 185.49931,247.87168 C 184.77403,247.87168 184.19346,247.64899 183.75683,247.20409 C 183.32096,246.7587 183.10254,246.14477 183.10254,245.36206 C 183.10254,244.59313 183.32422,243.98271 183.76737,243.53056 C 184.21026,243.07838 184.77404,242.8524 185.4592,242.8524 C 186.45282,242.8524 187.16455,243.24465 187.5939,244.02835 L 186.50398,244.57559 z"
id="path3795"
style="opacity:1" />
</g>
</g>
<path
id="text3797"
d="M 357.4197,448.68503 C 357.66518,448.68504 357.85131,448.63146 357.9781,448.52428 C 358.10488,448.41712 358.16827,448.25905 358.16828,448.05008 C 358.16827,447.84378 358.10488,447.68705 357.9781,447.57988 C 357.85131,447.47004 357.66518,447.41512 357.4197,447.41511 L 356.55784,447.41511 L 356.55784,448.68503 L 357.4197,448.68503 M 357.4723,451.30929 C 357.78522,451.30929 358.0199,451.24364 358.17637,451.11236 C 358.33552,450.98109 358.4151,450.78283 358.4151,450.51759 C 358.4151,450.25771 358.33686,450.06347 358.18041,449.93488 C 358.02396,449.80359 357.78792,449.73796 357.4723,449.73795 L 356.55784,449.73795 L 356.55784,451.30929 L 357.4723,451.30929 M 358.92089,449.15122 C 359.25538,449.24767 359.51434,449.42583 359.69779,449.68571 C 359.88121,449.94559 359.97293,450.26441 359.97294,450.64217 C 359.97293,451.22087 359.776,451.65222 359.38217,451.93621 C 358.98833,452.2202 358.38947,452.36219 357.5856,452.36219 L 355.00001,452.36219 L 355.00001,446.3622 L 357.33878,446.3622 C 358.17771,446.36221 358.78466,446.48813 359.15962,446.73996 C 359.53727,446.99181 359.7261,447.39502 359.7261,447.9496 C 359.7261,448.24164 359.65732,448.4908 359.51975,448.69709 C 359.38217,448.90072 359.18255,449.05209 358.92089,449.15122 M 359.83746,446.3622 L 361.54096,446.3622 L 362.91671,448.50018 L 364.29245,446.3622 L 366,446.3622 L 363.69764,449.8344 L 363.69764,452.36219 L 362.13982,452.36219 L 362.13982,449.8344 L 359.83746,446.3622 M 365.15837,449.40842 L 367.69946,449.40842 L 367.69946,450.57787 L 365.15837,450.57787 L 365.15837,449.40842 M 368.9174,446.3622 L 370.65732,446.3622 L 372.85447,450.47741 L 372.85447,446.3622 L 374.33138,446.3622 L 374.33138,452.36219 L 372.59146,452.36219 L 370.3943,448.24699 L 370.3943,452.36219 L 368.9174,452.36219 L 368.9174,446.3622 M 380.65173,452.03266 C 380.36579,452.18002 380.0677,452.2912 379.75749,452.36622 C 379.44727,452.44123 379.12357,452.47875 378.78638,452.47875 C 377.78019,452.47875 376.98307,452.20011 376.395,451.64284 C 375.80693,451.08289 375.5129,450.32469 375.5129,449.36823 C 375.5129,448.40909 375.80693,447.65089 376.395,447.09361 C 376.98307,446.53367 377.78019,446.2537 378.78638,446.25369 C 379.12357,446.2537 379.44727,446.29121 379.75749,446.36621 C 380.0677,446.44124 380.36579,446.55243 380.65173,446.69977 L 380.65173,447.94157 C 380.36309,447.746 380.0785,447.60266 379.79796,447.51156 C 379.5174,447.42047 379.22203,447.37493 378.91181,447.37493 C 378.35611,447.37493 377.91911,447.55175 377.6008,447.9054 C 377.28249,448.25905 377.12333,448.74666 377.12333,449.36823 C 377.12333,449.98712 377.28249,450.47339 377.6008,450.82703 C 377.91911,451.18069 378.35611,451.35751 378.91181,451.35751 C 379.22203,451.35751 379.5174,451.31197 379.79796,451.22087 C 380.0785,451.12978 380.36309,450.98644 380.65173,450.79086 L 380.65173,452.03266 M 381.82921,449.40842 L 384.3703,449.40842 L 384.3703,450.57787 L 381.82921,450.57787 L 381.82921,449.40842 M 385.58824,446.3622 L 387.32815,446.3622 L 389.52531,450.47741 L 389.52531,446.3622 L 391.00222,446.3622 L 391.00222,452.36219 L 389.26229,452.36219 L 387.06515,448.24699 L 387.06515,452.36219 L 385.58824,452.36219 L 385.58824,446.3622 M 394.08956,447.53165 L 394.08956,451.19274 L 394.64795,451.19274 C 395.28456,451.19274 395.77013,451.03602 396.10462,450.72255 C 396.44181,450.40909 396.61041,449.95363 396.61042,449.35617 C 396.61041,448.7614 396.44317,448.30862 396.10867,447.99783 C 395.77417,447.68705 395.28726,447.53166 394.64795,447.53165 L 394.08956,447.53165 M 392.53172,446.3622 L 394.17453,446.3622 C 395.09169,446.36221 395.77417,446.42784 396.22197,446.55912 C 396.67245,446.68772 397.0582,446.90742 397.37922,447.2182 C 397.66246,447.48879 397.87286,447.80092 398.01044,448.15456 C 398.14801,448.50822 398.2168,448.90875 398.21681,449.35617 C 398.2168,449.80896 398.14801,450.21351 398.01044,450.56983 C 397.87286,450.92349 397.66246,451.23561 397.37922,451.50621 C 397.05551,451.81699 396.66706,452.03802 396.21387,452.1693 C 395.76069,452.29789 395.0809,452.36219 394.17453,452.36219 L 392.53172,452.36219 L 392.53172,446.3622"
style="font-size:8.25858784px;font-style:normal;font-weight:bold;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:'Bitstream Vera Sans'" />
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 11 KiB

@ -70,7 +70,7 @@
id="licenseimg"
alt="CC BY-NC-ND 4.0"
title="CC BY-NC-ND 4.0"
src="https://licensebuttons.net/l/by-nc-nd/4.0/80x15.png"
src="/images/copyright/cc-by-nc-nd-4.0-small.svg"
/></a>
(unless otherwise specified)
</p>

Loading…
Cancel
Save