Skip to content

Commit

Permalink
perf(front): reduces svg size; adds --force-prefers-reduced-motion to…
Browse files Browse the repository at this point in the history
… lighthouse
  • Loading branch information
dgrebb committed Nov 11, 2023
1 parent 9f59220 commit f747187
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 27 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/test-lighthouse.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,8 @@ jobs:
undurl=$(echo "$u" | sed -E 's|https?://([^/]+)(/[^?#]*)?([?#]?.*)?|\2|;s|/+$||;s|/|_|g')
automation_url="${u}?roboto"
echo "Running Lighthouse on $u and writing report to ./$undurl"
npm run lhgh $automation_url -- --output-path ./mobile_"$undurl"report.html --disable-extensions
npm run lhgh-d $automation_url -- --output-path ./desktop_"$undurl"report.html --disable-extensions
npm run lhgh $automation_url -- --output-path ./mobile_"$undurl"report.html --disable-extensions --force-prefers-reduced-motion
npm run lhgh-d $automation_url -- --output-path ./desktop_"$undurl"report.html --disable-extensions --force-prefers-reduced-motion
done <<<"$urls"
- name: ⚓️ Drop Anchor
Expand Down
10 changes: 5 additions & 5 deletions front/src/lib/components/icons/Catchafire.svelte
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<svg viewBox="0 7 24 33" fill="none" xmlns="http://www.w3.org/2000/svg">
<path
d="M16.9597 31.6028C17.7493 31.5396 19.1969 31.7295 20.5129 31.1599C23.079 30.084 23.8028 27.4259 23.4738 25.3373C23.079 22.9957 20.9734 21.3502 20.6445 21.097C20.4471 20.9704 20.1181 21.1603 20.2497 21.4135C20.4471 21.7299 21.0392 22.7425 20.8418 24.388C20.5787 26.6664 18.7363 28.1221 17.8151 28.8182C16.8939 29.5144 16.1702 29.0081 15.8412 28.5018C15.6438 28.2486 15.4464 27.7423 15.7096 27.2993C15.907 26.9195 16.3676 26.7297 16.8282 26.2234C18.4073 24.5779 18.9337 23.1856 19.0653 21.7932C19.1969 20.4009 19.0653 18.6921 17.8809 16.92C16.9597 15.5277 15.3148 14.3252 14.92 14.0088C14.5252 13.629 14.3278 13.6291 14.3936 12.9962C14.4594 12.3633 14.591 10.7811 14.1962 9.45204C13.8014 8.0597 13.0118 7.1104 13.0118 7.1104C12.9461 6.92053 12.6829 6.98382 12.7487 7.23697C12.8803 7.55341 12.9461 7.99639 12.8803 8.62927C12.7487 10.0216 10.9063 11.6038 9.59034 12.743C8.27437 13.8822 6.82681 15.0214 6.03723 16.6669C5.44504 17.9326 5.18185 19.5149 5.64244 21.4135C6.16882 23.3121 7.1558 24.0083 7.94538 25.3373C8.73496 26.6031 7.74798 27.6157 6.82681 27.8689C5.97143 28.122 4.91866 26.5398 4.39227 25.4639C3.73429 24.1349 3.80008 21.9197 3.80008 21.6033C3.80008 21.54 3.80008 21.4767 3.80008 21.3502C3.80008 21.2236 3.60269 21.1603 3.53689 21.2236C3.47109 21.2869 3.40529 21.3502 3.33949 21.4767C2.74731 22.2362 1.29975 23.8817 0.77336 25.0209C0.246974 26.1601 -0.345211 27.8056 0.246974 29.8941C0.839158 31.9193 2.15512 33.0585 2.61571 33.4382C2.68151 33.5015 2.74731 33.5648 2.81311 33.6281C2.94471 33.7547 3.2737 33.6913 3.33949 33.4382C3.40529 33.2483 3.40529 32.9952 3.40529 32.8687C3.47109 32.1092 3.86588 31.6662 5.11605 31.0333C6.49781 30.3371 9.52454 29.3245 10.8405 29.2612C11.8275 29.2612 12.6171 30.0839 11.3669 31.856C10.7089 32.742 8.53756 33.5016 8.01118 34.1977C7.48479 34.9572 8.01118 36.4128 9.85353 37.6153C11.6959 38.881 14.3278 38.8177 15.1174 38.8177C15.9728 38.7544 15.907 38.2481 15.907 37.8051C15.907 37.3621 15.907 36.4127 18.4073 35.4001C20.7103 34.4508 21.3024 33.6913 21.5656 33.3116C21.8288 32.8686 21.5656 32.6155 21.3024 32.8053C21.0392 32.9952 20.3155 33.4382 18.9337 33.6281C17.5519 33.818 16.8282 33.4382 16.565 32.9319C16.1702 32.6155 16.1702 31.6661 16.9597 31.6028ZM13.4066 25.7804C13.4724 26.4133 13.0776 26.793 12.6171 26.9196C11.8933 27.1094 10.6431 27.1727 10.4457 25.3373C10.1825 23.1855 10.2483 20.7173 11.3011 18.7554C12.0907 17.2365 13.0776 16.1606 13.1434 16.034C13.275 15.9074 13.5382 15.7808 13.7356 16.0973C14.0646 16.7301 13.5382 18.4389 13.3408 20.3376C13.0776 22.7425 13.275 25.0209 13.4066 25.7804Z"
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 7 24 33"
><path
fill="currentColor"
/>
</svg>
d="M16.96 31.603c.79-.063 2.237.127 3.553-.443 2.566-1.076 3.29-3.734 2.96-5.823-.394-2.341-2.5-3.987-2.828-4.24-.198-.127-.527.063-.395.316.197.317.79 1.33.592 2.975-.263 2.278-2.106 3.734-3.027 4.43-.921.696-1.645.19-1.974-.316-.197-.253-.395-.76-.131-1.203.197-.38.658-.57 1.118-1.076 1.58-1.645 2.106-3.037 2.237-4.43.132-1.392 0-3.1-1.184-4.873-.921-1.392-2.566-2.595-2.961-2.911-.395-.38-.592-.38-.526-1.013.065-.633.197-2.215-.198-3.544-.395-1.392-1.184-2.342-1.184-2.342-.066-.19-.33-.126-.263.127.131.316.197.76.131 1.392-.131 1.393-1.974 2.975-3.29 4.114-1.316 1.14-2.763 2.278-3.553 3.924-.592 1.266-.855 2.848-.395 4.746.527 1.9 1.514 2.595 2.303 3.924.79 1.266-.197 2.279-1.118 2.532-.856.253-1.908-1.33-2.435-2.405-.658-1.33-.592-3.544-.592-3.86v-.254c0-.126-.197-.19-.263-.126a.88.88 0 0 0-.198.253c-.592.76-2.04 2.405-2.566 3.544-.526 1.14-1.118 2.785-.526 4.873.592 2.025 1.908 3.165 2.369 3.544l.197.19c.132.127.46.063.526-.19.066-.19.066-.443.066-.57.066-.759.46-1.202 1.711-1.835 1.382-.696 4.409-1.709 5.725-1.772.987 0 1.776.823.526 2.595-.658.886-2.83 1.646-3.356 2.342-.526.76 0 2.215 1.843 3.417 1.842 1.266 4.474 1.203 5.263 1.203.856-.064.79-.57.79-1.013 0-.443 0-1.392 2.5-2.405 2.303-.95 2.895-1.709 3.159-2.088.263-.443 0-.697-.264-.507-.263.19-.986.633-2.368.823-1.382.19-2.106-.19-2.369-.696-.395-.317-.395-1.266.395-1.33Zm-3.553-5.823c.065.633-.33 1.013-.79 1.14-.724.19-1.974.253-2.171-1.583-.264-2.151-.198-4.62.855-6.582.79-1.518 1.777-2.594 1.842-2.721.132-.127.395-.253.593.063.329.633-.198 2.342-.395 4.24-.263 2.405-.066 4.684.066 5.443Z"
/></svg
>
29 changes: 9 additions & 20 deletions front/src/lib/components/icons/CreativeCommons.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -6,28 +6,17 @@
title="This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License"
>
<svg
class="icon-cc"
xmlns="http://www.w3.org/2000/svg"
xml:space="preserve"
width="100%"
version="1.1"
style="shape-rendering:geometricPrecision; text-rendering:geometricPrecision; image-rendering:optimizeQuality; fill-rule:evenodd; clip-rule:evenodd"
class="icon-cc"
style="shape-rendering:geometricPrecision;text-rendering:geometricPrecision;image-rendering:optimizeQuality;fill-rule:evenodd;clip-rule:evenodd"
viewBox="0 0 46296.26 40689.13"
preserveAspectRatio="xMidYMid meet"
xmlns:xlink="http://www.w3.org/1999/xlink"
><path
d="M23204.91 7530.98c2944.63-3188.84 6384.04-4639.01 10366.38-4077.21 4110.34 579.88 7609.97 3518.41 8854.17 7479.01 957.39 3047.58 559.96 6460.83-722.09 9573.35-1993.98 4840.97-7886.31 11722.09-18555.24 16532.85C12479.21 32228.22 6586.88 25347.1 4592.89 20506.13c-1282.05-3112.52-1679.47-6525.77-722.09-9573.35 1244.19-3960.6 4743.83-6899.13 8854.17-7479.01 3982.46-561.82 7421.94 888.46 10366.64 4077.48 5.4 5.84 56.52 61.37 56.53 61.36.04.04 51.9-56.36 56.79-61.63zm-56.79-4522.44C16716.43-2039.47 6635.87-722.29 2000.47 6864.48 461.39 9383.51-116.67 12312.23 19.17 15219.93c235.64 5043.59 2412.75 9452.27 5610.61 13256.78 4306.02 5122.9 10531.26 9148.59 17382.21 12152.72 9.53 4.18 88.63 38.56 136.13 59.69 41.66-17.53 114.6-50.41 137.01-60.3 6815.65-3004.07 13075.56-7030.12 17381.33-12152.12 3198.08-3804.33 5374.97-8213.2 5610.61-13256.78 135.85-2907.7-442.2-5836.43-1981.3-8355.45-4635.4-7586.77-14715.95-8903.95-21147.65-3855.94z"
class="fil0"
/><path
d="m22983.64 21630.19-2928.01-1451.38c-1017.73 1483.99-1758.21 2488.33-3897.08 1902.25-1678.91-460.05-2175.85-2300.18-2239.67-3843.76-87.17-2108.39 649.94-4543.46 3168.15-4413.24 1609.13 83.19 2294.75 1032.23 2661.15 1885.36l3196.99-1638.9c-1574.75-3004.31-5265.13-4026.05-8393.32-3188.81-3328.66 890.9-5014.61 3952.95-4955.5 7255.23 60.43 3375.58 1680.8 6291.51 5161.55 7052.54 1697.16 371.06 3545.13 284.81 5116.74-503.18 1216.27-609.83 2567.56-1786.86 3109-3056.12zm13802.46 0-2928.01-1451.38c-1017.73 1483.99-1758.21 2488.33-3897.08 1902.25-1678.91-460.05-2175.86-2300.18-2239.67-3843.76-87.18-2108.39 649.94-4543.46 3168.15-4413.24 1609.13 83.19 2294.74 1032.23 2661.15 1885.36l3196.99-1638.9c-1574.75-3004.31-5265.14-4026.05-8393.32-3188.81-3328.66 890.9-5014.61 3952.95-4955.5 7255.23 60.42 3375.58 1680.8 6291.51 5161.55 7052.54 1697.16 371.06 3545.13 284.81 5116.74-503.18 1216.27-609.83 2567.56-1786.86 3109-3056.12z"
class="fil0"
/></svg
>
<g id="Layer_x0020_1">
<metadata id="CorelCorpID_0Corel-Layer" />
<g id="_1763071151248">
<path
class="fil0"
d="M23204.91 7530.98c2944.63,-3188.84 6384.04,-4639.01 10366.38,-4077.21 4110.34,579.88 7609.97,3518.41 8854.17,7479.01 957.39,3047.58 559.96,6460.83 -722.09,9573.35 -1993.98,4840.97 -7886.31,11722.09 -18555.24,16532.85 -10668.92,-4810.76 -16561.25,-11691.88 -18555.24,-16532.85 -1282.05,-3112.52 -1679.47,-6525.77 -722.09,-9573.35 1244.19,-3960.6 4743.83,-6899.13 8854.17,-7479.01 3982.46,-561.82 7421.94,888.46 10366.64,4077.48 5.4,5.84 56.52,61.37 56.53,61.36 0.04,0.04 51.9,-56.36 56.79,-61.63zm-56.79 -4522.44c-6431.69,-5048.01 -16512.25,-3730.83 -21147.65,3855.94 -1539.08,2519.03 -2117.14,5447.75 -1981.3,8355.45 235.64,5043.59 2412.75,9452.27 5610.61,13256.78 4306.02,5122.9 10531.26,9148.59 17382.21,12152.72 9.53,4.18 88.63,38.56 136.13,59.69 41.66,-17.53 114.6,-50.41 137.01,-60.3 6815.65,-3004.07 13075.56,-7030.12 17381.33,-12152.12 3198.08,-3804.33 5374.97,-8213.2 5610.61,-13256.78 135.85,-2907.7 -442.2,-5836.43 -1981.3,-8355.45 -4635.4,-7586.77 -14715.95,-8903.95 -21147.65,-3855.94z"
/>
<path
class="fil0"
d="M22983.64 21630.19l-2928.01 -1451.38c-1017.73,1483.99 -1758.21,2488.33 -3897.08,1902.25 -1678.91,-460.05 -2175.85,-2300.18 -2239.67,-3843.76 -87.17,-2108.39 649.94,-4543.46 3168.15,-4413.24 1609.13,83.19 2294.75,1032.23 2661.15,1885.36l3196.99 -1638.9c-1574.75,-3004.31 -5265.13,-4026.05 -8393.32,-3188.81 -3328.66,890.9 -5014.61,3952.95 -4955.5,7255.23 60.43,3375.58 1680.8,6291.51 5161.55,7052.54 1697.16,371.06 3545.13,284.81 5116.74,-503.18 1216.27,-609.83 2567.56,-1786.86 3109,-3056.12zm13802.46 0l-2928.01 -1451.38c-1017.73,1483.99 -1758.21,2488.33 -3897.08,1902.25 -1678.91,-460.05 -2175.86,-2300.18 -2239.67,-3843.76 -87.18,-2108.39 649.94,-4543.46 3168.15,-4413.24 1609.13,83.19 2294.74,1032.23 2661.15,1885.36l3196.99 -1638.9c-1574.75,-3004.31 -5265.14,-4026.05 -8393.32,-3188.81 -3328.66,890.9 -5014.61,3952.95 -4955.5,7255.23 60.42,3375.58 1680.8,6291.51 5161.55,7052.54 1697.16,371.06 3545.13,284.81 5116.74,-503.18 1216.27,-609.83 2567.56,-1786.86 3109,-3056.12z"
/>
</g>
</g>
</svg>
</a>

0 comments on commit f747187

Please sign in to comment.