dependency cleanup and loader removal (#17781)

* dependency cleanup and loader removal

* build bat

* tgfont update
This commit is contained in:
Kashargul
2025-06-02 05:45:34 -07:00
committed by GitHub
parent eeb21ddf0d
commit b4eb766984
27 changed files with 986 additions and 14124 deletions
-3
View File
@@ -12,9 +12,6 @@ logFilters:
- code: YN0002
level: discard
pattern: css-loader@*
- code: YN0002
level: discard
pattern: url-loader@*
preferInteractive: true
+1 -2
View File
@@ -39,8 +39,7 @@
"sass": "^1.80.6",
"sass-embedded": "^1.85.1",
"sass-loader": "^16.0.3",
"typescript": "5.8.3",
"url-loader": "^4.1.1"
"typescript": "5.8.3"
},
"devDependencies": {
"@types/node": "^22.14.0",
+1
View File
@@ -0,0 +1 @@
/dist
-18
View File
@@ -1,18 +0,0 @@
/**
* @file
* @copyright 2021 AnturK https://github.com/AnturK
* @license MIT
*/
module.exports = {
name: 'tgfont',
inputDir: './icons',
normalize: true,
outputDir: './dist',
fontTypes: ['woff2', 'eot'],
assetTypes: ['css'],
prefix: 'tg',
formatOptions: {
preserveAspectRatio: true,
},
};
@@ -1 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 437.4 434.4" style="enable-background:new 0 0 437.4 434.4" xml:space="preserve"><style>.st0{fill:none;stroke:#000;stroke-width:.57;stroke-miterlimit:10}</style><g id="Layer_1"><path class="st0" d="m41.18 306.18 84.43 84.43-19.53 20.8c-11.26 11.99-26.1 17.98-40.93 17.98-14.84 0-29.68-5.99-40.93-17.98-22.52-23.97-22.52-63.2 0-87.18l16.96-18.05zm310.48-156.3L139.65 375.65l-84.43-84.43L269.8 62.7c22.51-23.98 59.34-23.98 81.86 0 22.51 23.97 22.51 63.2 0 87.18z"/><path d="M426.11 88.46c-24.57-26.71-49.15-53.42-73.72-80.13a93.834 93.834 0 0 1-30.93-4.39c-6.96 7.41-6.96 19.53 0 26.94l79.36 84.52c6.96 7.41 18.34 7.41 25.29 0 6.96-7.41 6.96-19.53 0-26.94zM248.07 35.83c13.66 16.01 4.9 48.19-19.57 71.87-24.47 23.68-33.21 29.27-46.88 13.25-13.66-16.01-2.33-26.15 22.14-49.83 24.47-23.67 30.65-51.3 44.31-35.29z" style="stroke-width:.5;fill:none;stroke:#000;stroke-miterlimit:10"/><path class="st0" d="m139.93 375.93-.28-.28m-13.72 15.28-.32-.32"/><path transform="rotate(-45.001 211.427 209.932)" style="stroke:#000;stroke-width:18;stroke-miterlimit:10" d="M191.43-6.09h40v432.04h-40z"/></g></svg>
<svg xmlns="http://www.w3.org/2000/svg" xml:space="preserve" viewBox="0 0 437.4 434.4"><style>.st0{fill:none;stroke:#000;stroke-width:.57;stroke-miterlimit:10}</style><g id="Layer_1"><path d="m41.18 306.18 84.43 84.43-19.53 20.8c-11.26 11.99-26.1 17.98-40.93 17.98-14.84 0-29.68-5.99-40.93-17.98-22.52-23.97-22.52-63.2 0-87.18zm310.48-156.3L139.65 375.65l-84.43-84.43L269.8 62.7c22.51-23.98 59.34-23.98 81.86 0 22.51 23.97 22.51 63.2 0 87.18z" class="st0"/><path d="M426.11 88.46c-24.57-26.71-49.15-53.42-73.72-80.13a93.8 93.8 0 0 1-30.93-4.39c-6.96 7.41-6.96 19.53 0 26.94l79.36 84.52c6.96 7.41 18.34 7.41 25.29 0 6.96-7.41 6.96-19.53 0-26.94zM248.07 35.83c13.66 16.01 4.9 48.19-19.57 71.87s-33.21 29.27-46.88 13.25c-13.66-16.01-2.33-26.15 22.14-49.83 24.47-23.67 30.65-51.3 44.31-35.29z" style="stroke-width:.5;fill:none;stroke:#000;stroke-miterlimit:10"/><path d="m139.93 375.93-.28-.28m-13.72 15.28-.32-.32" class="st0"/><path d="M191.43-6.09h40v432.04h-40z" style="stroke:#000;stroke-width:18;stroke-miterlimit:10" transform="rotate(-45.001 211.427 209.932)"/></g></svg>

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.0 KiB

+1 -1
View File
@@ -1 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 437.4 434.4" style="enable-background:new 0 0 437.4 434.4" xml:space="preserve"><style>.st0{fill:none;stroke:#000;stroke-width:.57;stroke-miterlimit:10}</style><g id="Layer_1"><path class="st0" d="m41.18 306.18 84.43 84.43-19.53 20.8c-11.26 11.99-26.1 17.98-40.93 17.98-14.84 0-29.68-5.99-40.93-17.98-22.52-23.97-22.52-63.2 0-87.18l16.96-18.05zm310.48-156.3L139.65 375.65l-84.43-84.43L269.8 62.7c22.51-23.98 59.34-23.98 81.86 0 22.51 23.97 22.51 63.2 0 87.18z"/><path d="M426.11 88.46c-24.57-26.71-49.15-53.42-73.72-80.13a93.834 93.834 0 0 1-30.93-4.39c-6.96 7.41-6.96 19.53 0 26.94l79.36 84.52c6.96 7.41 18.34 7.41 25.29 0 6.96-7.41 6.96-19.53 0-26.94zM248.07 35.83c13.66 16.01 4.9 48.19-19.57 71.87-24.47 23.68-33.21 29.27-46.88 13.25-13.66-16.01-2.33-26.15 22.14-49.83 24.47-23.67 30.65-51.3 44.31-35.29z" style="stroke-width:.5;fill:none;stroke:#000;stroke-miterlimit:10"/><path class="st0" d="m139.93 375.93-.28-.28m-13.72 15.28-.32-.32"/></g></svg>
<svg xmlns="http://www.w3.org/2000/svg" xml:space="preserve" viewBox="0 0 437.4 434.4"><style>.st0{fill:none;stroke:#000;stroke-width:.57;stroke-miterlimit:10}</style><g id="Layer_1"><path d="m41.18 306.18 84.43 84.43-19.53 20.8c-11.26 11.99-26.1 17.98-40.93 17.98-14.84 0-29.68-5.99-40.93-17.98-22.52-23.97-22.52-63.2 0-87.18zm310.48-156.3L139.65 375.65l-84.43-84.43L269.8 62.7c22.51-23.98 59.34-23.98 81.86 0 22.51 23.97 22.51 63.2 0 87.18z" class="st0"/><path d="M426.11 88.46c-24.57-26.71-49.15-53.42-73.72-80.13a93.8 93.8 0 0 1-30.93-4.39c-6.96 7.41-6.96 19.53 0 26.94l79.36 84.52c6.96 7.41 18.34 7.41 25.29 0 6.96-7.41 6.96-19.53 0-26.94zM248.07 35.83c13.66 16.01 4.9 48.19-19.57 71.87s-33.21 29.27-46.88 13.25c-13.66-16.01-2.33-26.15 22.14-49.83 24.47-23.67 30.65-51.3 44.31-35.29z" style="stroke-width:.5;fill:none;stroke:#000;stroke-miterlimit:10"/><path d="m139.93 375.93-.28-.28m-13.72 15.28-.32-.32" class="st0"/></g></svg>

Before

Width:  |  Height:  |  Size: 1007 B

After

Width:  |  Height:  |  Size: 935 B

+1 -23
View File
@@ -1,23 +1 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 23.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 500 388" style="enable-background:new 0 0 500 388;" xml:space="preserve">
<g>
<g>
<ellipse transform="matrix(0.7071 -0.7071 0.7071 0.7071 471.6391 371.7563)" cx="684.6" cy="-383.4" rx="83.1" ry="83.1"/>
<polygon points="947,-49.1 885.8,46.5 870.2,71.6 813.7,159.4 769.8,131.2 718.1,96.7 793.3,-19.3 694.6,-89.9 669.5,55.9
671,55.9 724.3,200.2 774.5,333.4 697.7,452.6 628.7,560.8 531.5,499.7 647.5,319.3 598.9,187.6 359,560.8 263.4,499.7
556.6,43.4 556.6,43.4 575.4,-66.4 355.9,112.4 283.7,24.6 603.6,-235.7 608.3,-240.4 625.6,-237.3 666.3,-231 700.8,-224.7
714.9,-215.3 854.5,-115 "/>
</g>
</g>
<g transform="translate(-1.9001193,-43.556581)">
<path d="M131.6-382.3c0-54.7-44.3-99-99-99s-99,44.3-99,99l0,0c0,54.7,44.3,99,99,99S131.6-327.6,131.6-382.3z"/>
<path d="M321.8-85.3C231.4-90.8,142.5-111,58.5-145c-6.6-2.7-9.7-10.1-7.1-16.7c1.9-4.9,6.7-8,11.9-8h243.8
c22.3,0,40.5-18.1,40.5-40.5s-18.1-40.5-40.5-40.5H-41.1c-36.3,0-68.1,24.1-77.9,59l-69.8,248.5l-35.9,209.6l-178,32
c-27.5,4.9-45.8,31.2-40.8,58.7c4.9,27.5,31.2,45.8,58.7,40.8l200.4-36.1c33.5-6,59.7-32.4,65.5-66l16.7-97.4
c0.8-4.4,5.1-7.3,9.5-6.4c2.4,0.5,4.5,2,5.6,4.2l53.2,107.2l-84.2,229.3c-9.2,26.4,4.6,55.2,31,64.4c25.8,9,54.1-4.1,63.9-29.6
l91-247.9c7.7-20.9,6.4-44-3.4-63.9L-24,77.6L21.6-72.7c94,38.9,193.7,61.9,295.2,68.2c22.3,1.4,41.5-15.6,42.9-37.9
C361.1-64.7,344.1-83.9,321.8-85.3z"/>
</g>
</svg>
<svg xmlns="http://www.w3.org/2000/svg" xml:space="preserve" width="1393.223" height="1085.657"><g transform="translate(446.223 524.857)"><circle cx="684.6" cy="-383.4" r="83.1" transform="rotate(-45.001 684.577 -383.435)"/><path d="m870.2 71.6-56.5 87.8-43.9-28.2-51.7-34.5 75.2-116-98.7-70.6-25.1 145.8h1.5l53.3 144.3 50.2 133.2-76.8 119.2-69 108.2-97.2-61.1 116-180.4-48.6-131.7L359 560.8l-95.6-61.1L556.6 43.4l18.8-109.8-219.5 178.8-72.2-87.8 319.9-260.3 4.7-4.7 17.3 3.1 40.7 6.3 34.5 6.3 14.1 9.4L854.5-115 947-49.1l-61.2 95.6z"/></g><path d="M575.923 99c0-54.7-44.3-99-99-99s-99 44.3-99 99 44.3 99 99 99 99-44.3 99-99m190.2 297c-90.4-5.5-179.3-25.7-263.3-59.7-6.6-2.7-9.7-10.1-7.1-16.7 1.9-4.9 6.7-8 11.9-8h243.8c22.3 0 40.5-18.1 40.5-40.5s-18.1-40.5-40.5-40.5h-348.2c-36.3 0-68.1 24.1-77.9 59l-69.8 248.5-35.9 209.6-178 32c-27.5 4.9-45.8 31.2-40.8 58.7 4.9 27.5 31.2 45.8 58.7 40.8l200.4-36.1c33.5-6 59.7-32.4 65.5-66l16.7-97.4c.8-4.4 5.1-7.3 9.5-6.4 2.4.5 4.5 2 5.6 4.2l53.2 107.2-84.2 229.3c-9.2 26.4 4.6 55.2 31 64.4 25.8 9 54.1-4.1 63.9-29.6l91-247.9c7.7-20.9 6.4-44-3.4-63.9l-88.4-178.1 45.6-150.3c94 38.9 193.7 61.9 295.2 68.2 22.3 1.4 41.5-15.6 42.9-37.9s-15.6-41.5-37.9-42.9"/></svg>

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

+1 -1
View File
@@ -1 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="670" height="512"><path d="M655.714 228H484.286c-7.857 0-14.286 6.412-14.286 14.25v28.5c0 7.838 6.429 14.25 14.286 14.25h171.428c7.857 0 14.286-6.413 14.286-14.25v-28.5c0-7.838-6.429-14.25-14.286-14.25z" style="stroke-width:.89174"/><path d="M384 121.941V128H256V0h6.059a24 24 0 0 1 16.97 7.029l97.941 97.941a24.002 24.002 0 0 1 7.03 16.971zM248 160c-13.2 0-24-10.8-24-24V0H24C10.745 0 0 10.745 0 24v464c0 13.255 10.745 24 24 24h336c13.255 0 24-10.745 24-24V160zm-135.46 16c26.51 0 48 21.49 48 48s-21.49 48-48 48-48-21.49-48-48 21.491-48 48-48zm208 240h-256l.485-48.485L104.54 328c4.686-4.686 11.799-4.201 16.485.485L160.54 368l103.52-103.52c4.686-4.686 12.284-4.686 16.971 0l39.514 39.515z"/></svg>
<svg xmlns="http://www.w3.org/2000/svg" width="670" height="512"><path d="M655.714 228H484.286c-7.857 0-14.286 6.412-14.286 14.25v28.5c0 7.838 6.429 14.25 14.286 14.25h171.428c7.857 0 14.286-6.413 14.286-14.25v-28.5c0-7.838-6.429-14.25-14.286-14.25" style="stroke-width:.89174"/><path d="M384 121.941V128H256V0h6.059a24 24 0 0 1 16.97 7.029l97.941 97.941a24 24 0 0 1 7.03 16.971M248 160c-13.2 0-24-10.8-24-24V0H24C10.745 0 0 10.745 0 24v464c0 13.255 10.745 24 24 24h336c13.255 0 24-10.745 24-24V160zm-135.46 16c26.51 0 48 21.49 48 48s-21.49 48-48 48-48-21.49-48-48 21.491-48 48-48m208 240h-256l.485-48.485L104.54 328c4.686-4.686 11.799-4.201 16.485.485L160.54 368l103.52-103.52c4.686-4.686 12.284-4.686 16.971 0l39.514 39.515z"/></svg>

Before

Width:  |  Height:  |  Size: 746 B

After

Width:  |  Height:  |  Size: 735 B

+1 -1
View File
@@ -1 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="670" height="512"><path d="M655.714 228.429h-57.143v-57.143c0-7.857-6.428-14.286-14.285-14.286h-28.572c-7.857 0-14.285 6.429-14.285 14.286v57.143h-57.143c-7.857 0-14.286 6.428-14.286 14.285v28.572c0 7.857 6.429 14.285 14.286 14.285h57.143v57.143c0 7.857 6.428 14.286 14.285 14.286h28.572c7.857 0 14.285-6.429 14.285-14.286v-57.143h57.143c7.857 0 14.286-6.428 14.286-14.285v-28.572c0-7.857-6.429-14.285-14.286-14.285z" style="stroke-width:.892857"/><path d="M384 121.941V128H256V0h6.059a24 24 0 0 1 16.97 7.029l97.941 97.941a24.002 24.002 0 0 1 7.03 16.971zM248 160c-13.2 0-24-10.8-24-24V0H24C10.745 0 0 10.745 0 24v464c0 13.255 10.745 24 24 24h336c13.255 0 24-10.745 24-24V160zm-135.46 16c26.51 0 48 21.49 48 48s-21.49 48-48 48-48-21.49-48-48 21.491-48 48-48zm208 240h-256l.485-48.485L104.54 328c4.686-4.686 11.799-4.201 16.485.485L160.54 368l103.52-103.52c4.686-4.686 12.284-4.686 16.971 0l39.514 39.515z"/></svg>
<svg xmlns="http://www.w3.org/2000/svg" width="670" height="512"><path d="M655.714 228.429h-57.143v-57.143c0-7.857-6.428-14.286-14.285-14.286h-28.572c-7.857 0-14.285 6.429-14.285 14.286v57.143h-57.143c-7.857 0-14.286 6.428-14.286 14.285v28.572c0 7.857 6.429 14.285 14.286 14.285h57.143v57.143c0 7.857 6.428 14.286 14.285 14.286h28.572c7.857 0 14.285-6.429 14.285-14.286v-57.143h57.143c7.857 0 14.286-6.428 14.286-14.285v-28.572c0-7.857-6.429-14.285-14.286-14.285" style="stroke-width:.892857"/><path d="M384 121.941V128H256V0h6.059a24 24 0 0 1 16.97 7.029l97.941 97.941a24 24 0 0 1 7.03 16.971M248 160c-13.2 0-24-10.8-24-24V0H24C10.745 0 0 10.745 0 24v464c0 13.255 10.745 24 24 24h336c13.255 0 24-10.745 24-24V160zm-135.46 16c26.51 0 48 21.49 48 48s-21.49 48-48 48-48-21.49-48-48 21.491-48 48-48m208 240h-256l.485-48.485L104.54 328c4.686-4.686 11.799-4.201 16.485.485L160.54 368l103.52-103.52c4.686-4.686 12.284-4.686 16.971 0l39.514 39.515z"/></svg>

Before

Width:  |  Height:  |  Size: 961 B

After

Width:  |  Height:  |  Size: 950 B

@@ -1,3 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" version="1.0" viewBox="0 0 425 200" opacity=".33"><path d="M178.004.039H106.8a6.761 6.026 0 0 0-6.761 6.025v187.872a6.761 6.026 0 0 0 6.761 6.025h53.107a6.761 6.026 0 0 0 6.762-6.025V92.392l72.216 104.7a6.761 6.026 0 0 0 5.76 2.87H318.2a6.761 6.026 0 0 0 6.761-6.026V6.064A6.761 6.026 0 0 0 318.2.04h-54.717a6.761 6.026 0 0 0-6.76 6.025v102.62L183.763 2.909a6.761 6.026 0 0 0-5.76-2.87zM4.845 22.109A13.412 12.502 0 0 1 13.478.039h66.118A5.365 5 0 0 1 84.96 5.04v79.88zm415.31 155.782a13.412 12.502 0 0 1-8.633 22.07h-66.118a5.365 5 0 0 1-5.365-5.001v-79.88z"/></svg>
<!-- This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License. -->
<!-- http://creativecommons.org/licenses/by-sa/4.0/ -->
<svg xmlns="http://www.w3.org/2000/svg" opacity=".33" version="1.0" viewBox="0 0 425 200"><path d="M178.004.039H106.8a6.761 6.026 0 0 0-6.761 6.025v187.872a6.761 6.026 0 0 0 6.761 6.025h53.107a6.761 6.026 0 0 0 6.762-6.025V92.392l72.216 104.7a6.761 6.026 0 0 0 5.76 2.87H318.2a6.761 6.026 0 0 0 6.761-6.026V6.064A6.761 6.026 0 0 0 318.2.04h-54.717a6.761 6.026 0 0 0-6.76 6.025v102.62L183.763 2.909a6.761 6.026 0 0 0-5.76-2.87zM4.845 22.109A13.412 12.502 0 0 1 13.478.039h66.118A5.365 5 0 0 1 84.96 5.04v79.88zm415.31 155.782a13.412 12.502 0 0 1-8.633 22.07h-66.118a5.365 5 0 0 1-5.365-5.001v-79.88z"/></svg>

Before

Width:  |  Height:  |  Size: 770 B

After

Width:  |  Height:  |  Size: 607 B

+1 -17
View File
@@ -1,17 +1 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 23.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 707.8 944.4" style="enable-background:new 0 0 707.8 944.4;" xml:space="preserve">
<g id="woman" focusable="false">
</g>
<g id="man">
<g>
<path d="M532.7,767.2L532.7,767.2l-80-320.1c-4.5-17.8-20.5-30.3-38.8-30.3H395c-19.1,8.8-40,13.3-61.1,13.3v600.1h26.7
c22.1,0,40-17.9,40-40V816.9h93.3C519.9,816.9,539,792.5,532.7,767.2z"/>
<path d="M440.6,283.5c0-58.9-47.8-106.7-106.7-106.7v213.4C392.8,390.2,440.6,342.4,440.6,283.5z"/>
<path d="M253.9,416.9c-44.2,0-80,35.8-80,80v226.7c0,22.1,17.9,40,40,40h26.7v226.7c0,22.1,17.9,40,40,40h53.3V430.2
c-20.7,0-41.5-4.3-61.1-13.3H253.9z"/>
<path d="M227.2,283.5c0,58.9,47.8,106.7,106.7,106.7V176.8C275,176.8,227.2,224.6,227.2,283.5z"/>
</g>
</g>
</svg>
<svg xmlns="http://www.w3.org/2000/svg" xml:space="preserve" width="360.01" height="853.5"><path d="m358.8 590.4-80-320.1c-4.5-17.8-20.5-30.3-38.8-30.3h-18.9c-19.1 8.8-40 13.3-61.1 13.3v600.1h26.7c22.1 0 40-17.9 40-40V640.1H320c26 0 45.1-24.4 38.8-49.7m-92.1-483.7C266.7 47.8 218.9 0 160 0v213.4c58.9 0 106.7-47.8 106.7-106.7M80 240.1c-44.2 0-80 35.8-80 80v226.7c0 22.1 17.9 40 40 40h26.7v226.7c0 22.1 17.9 40 40 40H160V253.4c-20.7 0-41.5-4.3-61.1-13.3zM53.3 106.7c0 58.9 47.8 106.7 106.7 106.7V0C101.1 0 53.3 47.8 53.3 106.7"/></svg>

Before

Width:  |  Height:  |  Size: 966 B

After

Width:  |  Height:  |  Size: 534 B

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" xml:space="preserve" width="1077.457" height="1380.779"><g style="display:inline"><path d="M250-574.713A222.22 222.22 0 0 0 27.777-352.49 222.22 222.22 0 0 0 250-130.268 222.22 222.22 0 0 0 472.223-352.49 222.22 222.22 0 0 0 250-574.713ZM-219.498-45.977c-24.504 0-44.23 19.727-44.23 44.23v80.122c0 24.504 19.726 44.23 44.23 44.23H-1.504v589.231c0 24.504 19.727 44.23 44.23 44.23h118.436c24.504 0 44.23-19.726 44.23-44.23V591.494h87.712v120.342c0 24.504 19.726 44.23 44.23 44.23H455.77c24.503 0 44.23-19.726 44.23-44.23V122.605h219.498c24.504 0 44.23-19.726 44.23-44.23V-1.746c0-24.504-19.726-44.23-44.23-44.23z" style="fill:#000;fill-opacity:1;stroke:#000;stroke-width:50;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:20;stroke-dasharray:none;stroke-dashoffset:0;paint-order:normal" transform="translate(288.729 599.713)"/></g></svg>

After

Width:  |  Height:  |  Size: 887 B

+1 -22
View File
@@ -1,22 +1 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 23.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 500 500" style="enable-background:new 0 0 500 500;" xml:space="preserve">
<g>
<ellipse cx="97" cy="-305.1" rx="141.8" ry="141.8"/>
<path d="M654.7,11.6L455.2-212.6c-22.9-25.8-101.3,34.4-118.8,76.8c-42.1,11.9-85.6,16.4-126.2,16.4c-49.5,0-94.4-6.6-126.6-13.2
c-16.1-3.3-29-6.6-37.6-9c-4.3-1.1-7.6-2.2-9.7-2.8c-1.1-0.3-1.8-0.6-2.3-0.7c-0.4-0.2-0.4-0.2-0.4-0.2c-0.5-0.2-0.9-0.2-1.4-0.4
c-4.2-2-8.6-3.7-13.2-4.8c-53.8-13.4-131.9,15.8-163.7,108.1c-42.9,127.3-52.2,210.1-35.8,350.2c17.3,89.2,73.2,108.1,125.7,110.8
c4,0.7,8.1,1.1,12.3,1.1l0,0h302.7L359.9,687c11.9,31.7,41.9,51.3,73.9,51.3c9.2,0,18.5-1.6,27.6-5c40.8-15.2,61.5-60.6,46.3-101.4
L388.8,313.4c-11.5-30.8-41-51.3-73.9-51.3h-98.5l59.5-37.2c36.9-23.1-46.8-156.7-83.7-133.7L46.3,182.6
c5.6-48.8,14.9-96.4,23.5-138.7c-54.2-9.9-89.7-24-99.2-28c-15.9-7-27.7-19.3-33.9-35s-5.8-32.8,1-48.3
c10.1-23,32.7-37.8,57.8-37.8c8.8,0,17.3,1.8,25.3,5.3l1.2,0.5c1.8,0.7,4.5,1.7,8,3c7,2.5,18.3,6.1,33.1,9.8
c26.9,6.8,70,14.8,122.5,14.8c79.8,0,157.6-18.2,231.1-54c8.7-4.3,18-6.4,27.6-6.4c24.4,0,46.1,13.6,56.8,35.5
c15.2,31.2,2.1,69.1-29.1,84.3c-11.7,5.7-23.5,11-35.3,16l100.3,112.7c29,32.6,78.8,35.4,111.3,6.5c21-18.7,29.7-46.2,25.3-72.2
C671.2,36.6,665,23,654.7,11.6z"/>
<path d="M489.7-91.2c-12.2-25-42.4-35.5-67.5-23.3c-87.4,42.6-169.1,55.3-236.6,55.3c-52,0-95.5-7.6-125.7-15.2
c-15-3.8-26.7-7.4-34.3-10.1c-3.8-1.3-6.6-2.4-8.3-3.1c-0.8-0.3-1.5-0.6-1.7-0.7h-0.1c-25.5-11.1-55.3,0.5-66.4,26
C-62-36.8-50.4-7.1-24.8,4.1l0,0c4.3,1.8,86.6,37.5,210.6,37.7c0.1,0,0.2,0,0.2,0c80.2,0,177.9-15.5,280.6-65.4
C491.5-35.9,501.9-66,489.7-91.2z"/>
</g>
</svg>
<svg xmlns="http://www.w3.org/2000/svg" xml:space="preserve" width="862.822" height="1185.2"><g transform="translate(188.11 446.9)"><circle cx="97" cy="-305.1" r="141.8"/><path d="M654.7 11.6 455.2-212.6c-22.9-25.8-101.3 34.4-118.8 76.8-42.1 11.9-85.6 16.4-126.2 16.4-49.5 0-94.4-6.6-126.6-13.2-16.1-3.3-29-6.6-37.6-9-4.3-1.1-7.6-2.2-9.7-2.8-1.1-.3-1.8-.6-2.3-.7l-.4-.2c-.5-.2-.9-.2-1.4-.4-4.2-2-8.6-3.7-13.2-4.8-53.8-13.4-131.9 15.8-163.7 108.1-42.9 127.3-52.2 210.1-35.8 350.2 17.3 89.2 73.2 108.1 125.7 110.8 4 .7 8.1 1.1 12.3 1.1h302.7L359.9 687c11.9 31.7 41.9 51.3 73.9 51.3 9.2 0 18.5-1.6 27.6-5 40.8-15.2 61.5-60.6 46.3-101.4L388.8 313.4c-11.5-30.8-41-51.3-73.9-51.3h-98.5l59.5-37.2c36.9-23.1-46.8-156.7-83.7-133.7L46.3 182.6c5.6-48.8 14.9-96.4 23.5-138.7-54.2-9.9-89.7-24-99.2-28-15.9-7-27.7-19.3-33.9-35s-5.8-32.8 1-48.3c10.1-23 32.7-37.8 57.8-37.8 8.8 0 17.3 1.8 25.3 5.3l1.2.5c1.8.7 4.5 1.7 8 3 7 2.5 18.3 6.1 33.1 9.8 26.9 6.8 70 14.8 122.5 14.8 79.8 0 157.6-18.2 231.1-54 8.7-4.3 18-6.4 27.6-6.4 24.4 0 46.1 13.6 56.8 35.5 15.2 31.2 2.1 69.1-29.1 84.3-11.7 5.7-23.5 11-35.3 16L537 116.3c29 32.6 78.8 35.4 111.3 6.5 21-18.7 29.7-46.2 25.3-72.2-2.4-14-8.6-27.6-18.9-39"/><path d="M489.7-91.2c-12.2-25-42.4-35.5-67.5-23.3-87.4 42.6-169.1 55.3-236.6 55.3-52 0-95.5-7.6-125.7-15.2-15-3.8-26.7-7.4-34.3-10.1-3.8-1.3-6.6-2.4-8.3-3.1-.8-.3-1.5-.6-1.7-.7h-.1c-25.5-11.1-55.3.5-66.4 26s.5 55.2 26.1 66.4c4.3 1.8 86.6 37.5 210.6 37.7h.2c80.2 0 177.9-15.5 280.6-65.4 24.9-12.3 35.3-42.4 23.1-67.6"/></g></svg>

Before

Width:  |  Height:  |  Size: 1.8 KiB

After

Width:  |  Height:  |  Size: 1.5 KiB

+1 -1
View File
@@ -1 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="542" height="512"><path d="M215.03 71.05 126.06 160H24c-13.26 0-24 10.74-24 24v144c0 13.25 10.74 24 24 24h102.06l88.97 88.95c15.03 15.03 40.97 4.47 40.97-16.97V88.02c0-21.46-25.96-31.98-40.97-16.97z"/><path d="M527.714 228H356.286c-7.857 0-14.286 6.412-14.286 14.25v28.5c0 7.838 6.429 14.25 14.286 14.25h171.428c7.857 0 14.286-6.413 14.286-14.25v-28.5c0-7.838-6.429-14.25-14.286-14.25z" style="stroke-width:.89174"/></svg>
<svg xmlns="http://www.w3.org/2000/svg" width="542" height="512"><path d="M215.03 71.05 126.06 160H24c-13.26 0-24 10.74-24 24v144c0 13.25 10.74 24 24 24h102.06l88.97 88.95c15.03 15.03 40.97 4.47 40.97-16.97V88.02c0-21.46-25.96-31.98-40.97-16.97"/><path d="M527.714 228H356.286c-7.857 0-14.286 6.412-14.286 14.25v28.5c0 7.838 6.429 14.25 14.286 14.25h171.428c7.857 0 14.286-6.413 14.286-14.25v-28.5c0-7.838-6.429-14.25-14.286-14.25" style="stroke-width:.89174"/></svg>

Before

Width:  |  Height:  |  Size: 469 B

After

Width:  |  Height:  |  Size: 467 B

+1 -1
View File
@@ -1 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="542" height="512"><path d="M527.714 227.929h-57.143v-57.143c0-7.857-6.428-14.286-14.285-14.286h-28.572c-7.857 0-14.285 6.429-14.285 14.286v57.143h-57.143c-7.857 0-14.286 6.428-14.286 14.285v28.572c0 7.857 6.429 14.285 14.286 14.285h57.143v57.143c0 7.857 6.428 14.286 14.285 14.286h28.572c7.857 0 14.285-6.429 14.285-14.286v-57.143h57.143c7.857 0 14.286-6.428 14.286-14.285v-28.572c0-7.857-6.429-14.285-14.286-14.285z" style="stroke-width:.892857"/><path d="M215.03 71.05 126.06 160H24c-13.26 0-24 10.74-24 24v144c0 13.25 10.74 24 24 24h102.06l88.97 88.95c15.03 15.03 40.97 4.47 40.97-16.97V88.02c0-21.46-25.96-31.98-40.97-16.97z"/></svg>
<svg xmlns="http://www.w3.org/2000/svg" width="542" height="512"><path d="M527.714 227.929h-57.143v-57.143c0-7.857-6.428-14.286-14.285-14.286h-28.572c-7.857 0-14.285 6.429-14.285 14.286v57.143h-57.143c-7.857 0-14.286 6.428-14.286 14.285v28.572c0 7.857 6.429 14.285 14.286 14.285h57.143v57.143c0 7.857 6.428 14.286 14.285 14.286h28.572c7.857 0 14.285-6.429 14.285-14.286v-57.143h57.143c7.857 0 14.286-6.428 14.286-14.285v-28.572c0-7.857-6.429-14.285-14.286-14.285" style="stroke-width:.892857"/><path d="M215.03 71.05 126.06 160H24c-13.26 0-24 10.74-24 24v144c0 13.25 10.74 24 24 24h102.06l88.97 88.95c15.03 15.03 40.97 4.47 40.97-16.97V88.02c0-21.46-25.96-31.98-40.97-16.97"/></svg>

Before

Width:  |  Height:  |  Size: 684 B

After

Width:  |  Height:  |  Size: 682 B

@@ -1,3 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" version="1.0" viewBox="0 0 200 289.742" opacity=".33"><path d="M93.538 0c-18.113 0-34.22 3.112-48.324 9.334-13.965 6.222-24.612 15.072-31.94 26.547C6.084 47.22 2.972 60.631 2.972 76.116c0 10.647 2.725 20.465 8.175 29.453 5.616 8.987 14.039 17.352 25.27 25.094 11.23 7.606 26.507 15.419 45.83 23.438 19.984 8.296 34.849 15.555 44.593 21.776 9.744 6.223 16.761 12.859 21.055 19.91 4.295 7.052 6.442 15.764 6.442 26.134 0 16.178-5.202 28.483-15.606 36.917-10.24 8.435-25.022 12.653-44.345 12.653-14.039 0-25.516-1.66-34.434-4.978-8.918-3.457-16.186-8.711-21.8-15.763-5.616-7.052-10.076-16.661-13.379-28.829H0v56.827c33.857 7.328 63.749 10.994 89.678 10.994 16.02 0 30.72-1.383 44.098-4.148 13.542-2.904 25.104-7.467 34.683-13.69 9.744-6.359 17.34-14.519 22.79-24.474 5.45-10.093 8.175-22.4 8.175-36.917 0-12.997-3.302-24.335-9.908-34.014-6.44-9.818-15.525-18.527-27.251-26.132-11.561-7.604-27.911-15.831-49.051-24.68-17.506-7.19-30.72-13.69-39.638-19.497S54.969 93.756 49.479 87.316c-5.426-6.366-9.658-15.07-9.658-24.887 0-9.264 2.075-17.214 6.223-23.85C57.142 24.18 87.331 36.782 91.12 62.925c4.84 6.775 8.85 16.247 12.03 28.415h20.532v-56c-4.479-5.924-9.955-10.631-15.909-14.373 1.64.479 3.19 1.023 4.639 1.64 6.498 2.626 12.168 7.327 17.007 14.103 4.84 6.775 8.85 16.246 12.03 28.414 0 0 8.48-.129 8.49-.002.417 6.415-1.754 9.453-4.124 12.561-2.417 3.17-5.145 6.79-4.003 13.003 1.508 8.203 10.184 10.597 14.622 9.312-3.318-.5-5.318-1.75-5.318-1.75s1.876.999 5.65-1.36c-3.276.956-10.704-.797-11.8-6.763-.958-5.208.946-7.295 3.4-10.514 2.455-3.22 5.285-6.959 4.685-14.489l.003.002h8.927v-56c-15.072-3.871-27.653-6.36-37.747-7.465C114.279.552 104.046 0 93.537 0zm70.321 17.309.238 40.305c1.318 1.226 2.44 2.278 3.341 3.106 4.84 6.775 8.85 16.246 12.03 28.414H200v-56c-6.677-4.594-19.836-10.473-36.14-15.825zm-28.12 5.605 8.565 17.717c-11.97-6.467-13.847-9.717-8.565-17.717zm22.797 0c2.771 8 1.787 11.25-4.494 17.717l4.494-17.717zm15.222 24.009 8.565 17.716c-11.97-6.466-13.847-9.717-8.565-17.716zm22.797 0c2.771 8 1.787 11.25-4.494 17.716l4.494-17.716zM97.44 49.13l8.565 17.716c-11.97-6.467-13.847-9.717-8.565-17.716zm22.795 0c2.772 7.999 1.788 11.25-4.493 17.716l4.493-17.716z"/></svg>
<!-- This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License. -->
<!-- http://creativecommons.org/licenses/by-sa/4.0/ -->
<svg xmlns="http://www.w3.org/2000/svg" width="200mm" height="300mm" opacity=".33" version="1.0" viewBox="0 0 755.71 1133.9"><path d="M353.55 49.811c-68.112 0-128.68 11.108-181.72 33.318-52.514 22.209-92.55 53.8-120.11 94.76-27.037 40.475-38.739 88.345-38.739 143.62q0 57.009 30.741 105.13 31.676 48.12 95.025 89.573 63.344 40.726 172.34 83.662c75.147 29.613 131.05 55.524 167.69 77.73 36.641 22.213 63.028 45.9 79.175 71.069q24.225 37.76 24.224 93.286c0 57.748-19.561 101.67-58.684 131.78-38.506 30.109-94.092 45.165-166.75 45.165q-79.187-.002-129.48-17.769c-33.535-12.34-60.865-31.094-81.976-56.266-21.118-25.172-37.89-59.472-50.31-102.91H1.82v202.84c127.31 26.157 239.72 39.243 337.22 39.243 60.241 0 115.52-4.936 165.82-14.806 50.923-10.366 94.4-26.654 130.42-48.867 36.641-22.699 65.205-51.826 85.699-87.36 20.494-36.027 30.741-79.957 30.741-131.78q.002-69.59-37.258-121.41c-24.217-35.045-58.38-66.132-102.47-93.278q-65.213-40.715-184.45-88.096c-65.829-25.665-115.52-48.867-149.05-69.595-33.535-20.728-69.969-44.383-90.614-67.371-20.404-22.724-36.318-53.793-36.318-88.834q.002-49.602 23.401-85.133c41.733-51.397 155.25-6.414 169.5 86.903q27.3 36.275 45.237 101.43h77.208v-199.89c-16.843-21.146-37.434-37.947-59.824-51.305 6.167 1.71 11.996 3.652 17.444 5.854 24.435 9.374 45.756 26.154 63.953 50.341q27.3 36.275 45.237 101.42s31.888-.46 31.926-.007c1.568 22.898-6.596 33.743-15.508 44.837-9.089 11.315-19.347 24.237-15.053 46.414 5.67 29.281 38.296 37.826 54.984 33.239-12.477-1.785-19.998-6.247-19.998-6.247s7.054 3.566 21.246-4.854c-12.319 3.412-40.251-2.845-44.372-24.141-3.602-18.59 3.557-26.04 12.785-37.53 9.232-11.494 19.874-24.84 17.617-51.72l.011.008h33.57V82.374q-85.015-20.728-141.94-26.646c-37.435-3.952-75.915-5.922-115.43-5.922zm264.43 61.785.895 143.87c4.956 4.376 9.175 8.131 12.563 11.087q27.3 36.275 45.237 101.42h77.208v-199.89c-25.108-16.398-74.591-37.383-135.9-56.488zm-105.74 20.007 32.208 63.241c-45.012-23.084-52.07-34.685-32.208-63.241m85.725 0c10.42 28.556 6.72 40.157-16.899 63.241zm57.24 85.7 32.208 63.237c-45.012-23.08-52.07-34.685-32.208-63.237m85.725 0c10.42 28.556 6.72 40.157-16.899 63.237zm-372.71 7.878 32.208 63.237c-45.012-23.084-52.07-34.685-32.208-63.237m85.718 0c10.424 28.553 6.724 40.157-16.895 63.237z"/></svg>

Before

Width:  |  Height:  |  Size: 2.3 KiB

After

Width:  |  Height:  |  Size: 2.2 KiB

-13
View File
@@ -1,13 +0,0 @@
/**
* @file
* @copyright 2021 AnturK https://github.com/AnturK
* @license MIT
*/
// Change working directory to project root
process.chdir(__dirname);
// Silently make a dist folder
try {
require('fs').mkdirSync('dist');
} catch (err) {}
+11 -9
View File
@@ -1,11 +1,13 @@
{
"private": true,
"name": "tgfont",
"version": "1.0.0",
"scripts": {
"tgfont:build": "node mkdist.cjs && fantasticon --config config.cjs"
},
"dependencies": {
"fantasticon": "^1.2.3"
}
"private": true,
"name": "tgfont",
"type": "module",
"version": "2.0.0",
"scripts": {
"tgfont:build": "svgo icons && node svgtofont.mjs"
},
"dependencies": {
"svgo": "^3.3.2",
"svgtofont": "^6.3.2"
}
}
+64
View File
@@ -0,0 +1,64 @@
@font-face {
font-family: 'tgfont';
src: url('tgfont.woff2?t=1747971548188') format('woff2');
}
[class^='tg-'],
[class*=' tg-'] {
font-family: 'tgfont' !important;
font-size: undefined;
font-style: normal;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
:root {
--tg-air-tank-slash: '\ea01';
--tg-air-tank: '\ea02';
--tg-bad-touch: '\ea03';
--tg-image-minus: '\ea04';
--tg-image-plus: '\ea05';
--tg-nanotrasen-logo: '\ea06';
--tg-non-binary: '\ea07';
--tg-prosthetic-full: '\ea08';
--tg-prosthetic-leg: '\ea09';
--tg-sound-minus: '\ea0a';
--tg-sound-plus: '\ea0b';
--tg-syndicate-logo: '\ea0c';
}
.tg-air-tank-slash::before {
content: var(--tg-air-tank-slash);
}
.tg-air-tank::before {
content: var(--tg-air-tank);
}
.tg-bad-touch::before {
content: var(--tg-bad-touch);
}
.tg-image-minus::before {
content: var(--tg-image-minus);
}
.tg-image-plus::before {
content: var(--tg-image-plus);
}
.tg-nanotrasen-logo::before {
content: var(--tg-nanotrasen-logo);
}
.tg-non-binary::before {
content: var(--tg-non-binary);
}
.tg-prosthetic-full::before {
content: var(--tg-prosthetic-full);
}
.tg-prosthetic-leg::before {
content: var(--tg-prosthetic-leg);
}
.tg-sound-minus::before {
content: var(--tg-sound-minus);
}
.tg-sound-plus::before {
content: var(--tg-sound-plus);
}
.tg-syndicate-logo::before {
content: var(--tg-syndicate-logo);
}
Binary file not shown.
+20
View File
@@ -0,0 +1,20 @@
import svgtofont from 'svgtofont';
/** @type {import('svgtofont').SvgToFontOptions} */
const config = {
classNamePrefix: 'tg',
css: {
include: /\.css$/,
},
dist: './dist',
emptyDist: true,
excludeFormat: ['eot', 'svg', 'symbol.svg', 'ttf', 'woff'],
fontName: 'tgfont',
src: './icons',
svgicons2svgfont: {
normalize: true,
},
useCSSVars: true,
};
svgtofont(config).catch(console.error);
-2
View File
@@ -7,9 +7,7 @@
"common": "workspace:*",
"dateformat": "^5.0.3",
"dompurify": "^3.2.4",
"file-extension-icon-js": "^1.1.6",
"highlight.js": "^11.11.1",
"jest": "^29.7.0",
"js-yaml": "^4.1.0",
"marked": "^4.3.0",
"react": "^19.1.0",
+7 -17
View File
@@ -78,14 +78,13 @@ module.exports = (env = {}, argv) => {
},
{
test: /\.(png|jpg)$/,
use: [
oneOf: [
{
loader: require.resolve('url-loader'),
options: {
esModule: false,
outputPath: 'assets/',
publicPath: '/assets/',
},
issuer: /\.(s)?css$/,
type: 'asset/inline',
},
{
type: 'asset/resource',
},
],
},
@@ -97,16 +96,7 @@ module.exports = (env = {}, argv) => {
type: 'asset/inline',
},
{
use: [
{
loader: require.resolve('url-loader'),
options: {
esModule: false,
outputPath: 'assets/',
publicPath: '/assets/',
},
},
],
type: 'asset/resource',
},
],
},
+7 -17
View File
@@ -110,14 +110,13 @@ module.exports = (env = {}, argv) => {
},
{
test: /\.(png|jpg)$/,
use: [
oneOf: [
{
loader: require.resolve('url-loader'),
options: {
esModule: false,
outputPath: 'assets/',
publicPath: '/assets/',
},
issuer: /\.(s)?css$/,
type: 'asset/inline',
},
{
type: 'asset/resource',
},
],
},
@@ -129,16 +128,7 @@ module.exports = (env = {}, argv) => {
type: 'asset/inline',
},
{
use: [
{
loader: require.resolve('url-loader'),
options: {
esModule: false,
outputPath: 'assets/',
publicPath: '/assets/',
},
},
],
type: 'asset/resource',
},
],
},
+650 -13773
View File
File diff suppressed because it is too large Load Diff
+213 -196
View File
@@ -6,21 +6,21 @@
* https://github.com/stylemistake/juke-build
*/
import fs from 'fs';
import https from 'https';
import { env } from 'process';
import Juke from './juke/index.js';
import { DreamDaemon, DreamMaker, NamedVersionFile } from './lib/byond.js';
import { yarn } from './lib/yarn.js';
import fs from "fs";
import https from "https";
import { env } from "process";
import Juke from "./juke/index.js";
import { DreamDaemon, DreamMaker, NamedVersionFile } from "./lib/byond.js";
import { yarn } from "./lib/yarn.js";
const TGS_MODE = process.env.CBT_BUILD_MODE === 'TGS';
const TGS_MODE = process.env.CBT_BUILD_MODE === "TGS";
Juke.chdir('../..', import.meta.url);
Juke.chdir("../..", import.meta.url);
Juke.setup({ file: import.meta.url }).then((code) => {
// We're using the currently available quirk in Juke Build, which
// prevents it from exiting on Windows, to wait on errors.
if (code !== 0 && process.argv.includes('--wait-on-error')) {
Juke.logger.error('Please inspect the error and close the window.');
if (code !== 0 && process.argv.includes("--wait-on-error")) {
Juke.logger.error("Please inspect the error and close the window.");
return;
}
@@ -28,70 +28,70 @@ Juke.setup({ file: import.meta.url }).then((code) => {
// workaround for ESBuild process lingering
// Once https://github.com/privatenumber/esbuild-loader/pull/354 is merged and updated to, this can be removed
setTimeout(() => process.exit(code), 10000);
}
else {
} else {
process.exit(code);
}
});
const DME_NAME = 'vorestation';
const DME_NAME = "vorestation";
// Stores the contents of dependencies.sh as a key value pair
// Best way I could figure to get ahold of this stuff
const dependencies = fs.readFileSync('dependencies.sh', 'utf8')
const dependencies = fs
.readFileSync("dependencies.sh", "utf8")
.split("\n")
.map((statement) => statement.replace("export", "").trim())
.filter((value) => !(value == "" || value.startsWith("#")))
.map((statement) => statement.split("="))
.reduce((acc, kv_pair) => {
acc[kv_pair[0]] = kv_pair[1];
return acc
}, {})
return acc;
}, {});
// Canonical path for the cutter exe at this moment
const getCutterPath = () => {
const ver = dependencies.CUTTER_VERSION;
const suffix = process.platform === 'win32' ? '.exe' : '';
const file_ver = ver.split('.').join('-');
const suffix = process.platform === "win32" ? ".exe" : "";
const file_ver = ver.split(".").join("-");
return `tools/icon_cutter/cache/hypnagogic${file_ver}${suffix}`;
};
const cutter_path = getCutterPath();
export const DefineParameter = new Juke.Parameter({
type: 'string[]',
alias: 'D',
type: "string[]",
alias: "D",
});
export const PortParameter = new Juke.Parameter({
type: 'string',
alias: 'p',
type: "string",
alias: "p",
});
export const DmVersionParameter = new Juke.Parameter({
type: 'string',
type: "string",
});
export const CiParameter = new Juke.Parameter({ type: 'boolean' });
export const CiParameter = new Juke.Parameter({ type: "boolean" });
export const ForceRecutParameter = new Juke.Parameter({
type: 'boolean',
type: "boolean",
name: "force-recut",
});
export const SkipIconCutter = new Juke.Parameter({
type: 'boolean',
type: "boolean",
name: "skip-icon-cutter",
});
export const WarningParameter = new Juke.Parameter({
type: 'string[]',
alias: 'W',
type: "string[]",
alias: "W",
});
export const NoWarningParameter = new Juke.Parameter({
type: 'string[]',
alias: 'I',
type: "string[]",
alias: "I",
});
export const CutterTarget = new Juke.Target({
@@ -102,14 +102,11 @@ export const CutterTarget = new Juke.Target({
executes: async () => {
const repo = dependencies.CUTTER_REPO;
const ver = dependencies.CUTTER_VERSION;
const suffix = process.platform === 'win32' ? '.exe' : '';
const download_from = `https://github.com/${repo}/releases/download/${ver}/hypnagogic${suffix}`
const suffix = process.platform === "win32" ? ".exe" : "";
const download_from = `https://github.com/${repo}/releases/download/${ver}/hypnagogic${suffix}`;
await download_file(download_from, cutter_path);
if(process.platform !== 'win32') {
await Juke.exec("chmod", [
'+x',
cutter_path,
]);
if (process.platform !== "win32") {
await Juke.exec("chmod", ["+x", cutter_path]);
}
},
});
@@ -117,41 +114,43 @@ export const CutterTarget = new Juke.Target({
async function download_file(url, file) {
return new Promise((resolve, reject) => {
let file_stream = fs.createWriteStream(file);
https.get(url, function(response) {
if (response.statusCode === 302) {
file_stream.close();
download_file(response.headers.location, file)
.then((value) => resolve());
return;
}
if (response.statusCode !== 200) {
Juke.logger.error(`Failed to download ${url}: Status ${response.statusCode}`);
file_stream.close();
reject()
return
}
response.pipe(file_stream);
https
.get(url, function (response) {
if (response.statusCode === 302) {
file_stream.close();
download_file(response.headers.location, file).then((value) =>
resolve(),
);
return;
}
if (response.statusCode !== 200) {
Juke.logger.error(
`Failed to download ${url}: Status ${response.statusCode}`,
);
file_stream.close();
reject();
return;
}
response.pipe(file_stream);
// after download completed close filestream
file_stream.on("finish", () => {
// after download completed close filestream
file_stream.on("finish", () => {
file_stream.close();
resolve();
});
})
.on("error", (err) => {
file_stream.close();
resolve()
Juke.rm(download_into);
Juke.logger.error(`Failed to download ${url}: ${err.message}`);
reject();
});
}).on("error", (err) => {
file_stream.close();
Juke.rm(download_into);
Juke.logger.error(`Failed to download ${url}: ${err.message}`);
reject()
});
});
}
export const IconCutterTarget = new Juke.Target({
parameters: [ForceRecutParameter],
dependsOn: () => [
CutterTarget,
],
dependsOn: () => [CutterTarget],
inputs: ({ get }) => {
const standard_inputs = [
`icons/**/*.png.toml`,
@@ -159,7 +158,7 @@ export const IconCutterTarget = new Juke.Target({
`cutter_templates/**/*.toml`,
"tgui/public/tgui.html",
cutter_path,
]
];
// Alright we're gonna search out any existing toml files and convert
// them to their matching .dmi or .png file
const existing_configs = [
@@ -168,63 +167,68 @@ export const IconCutterTarget = new Juke.Target({
];
return [
...standard_inputs,
...existing_configs.map((file) => file.replace('.toml', '')),
]
...existing_configs.map((file) => file.replace(".toml", "")),
];
},
outputs: ({ get }) => {
if(get(ForceRecutParameter))
return [];
if (get(ForceRecutParameter)) return [];
const folders = [
...Juke.glob(`icons/**/*.png.toml`),
...Juke.glob(`icons/**/*.dmi.toml`),
];
return folders
.map((file) => file.replace(`.png.toml`, '.dmi'))
.map((file) => file.replace(`.dmi.toml`, '.png'));
.map((file) => file.replace(`.png.toml`, ".dmi"))
.map((file) => file.replace(`.dmi.toml`, ".png"));
},
executes: async () => {
// Don't run icon cutter, we don't use it and it's not compiled for ubuntu 20.04
// await Juke.exec(cutter_path, [
// '--dont-wait',
// '--templates',
// 'cutter_templates',
// 'icons',
// ]);
await Juke.exec(cutter_path, [
"--dont-wait",
"--templates",
"cutter_templates",
"icons",
]);
},
});
export const DmMapsIncludeTarget = new Juke.Target({
executes: async () => {
const folders = [
...Juke.glob('_maps/map_files/**/modular_pieces/*.dmm'),
...Juke.glob('_maps/RandomRuins/**/*.dmm'),
...Juke.glob('_maps/RandomZLevels/**/*.dmm'),
...Juke.glob('_maps/shuttles/**/*.dmm'),
...Juke.glob('_maps/templates/**/*.dmm'),
...Juke.glob("_maps/map_files/**/modular_pieces/*.dmm"),
...Juke.glob("_maps/RandomRuins/**/*.dmm"),
...Juke.glob("_maps/RandomZLevels/**/*.dmm"),
...Juke.glob("_maps/shuttles/**/*.dmm"),
...Juke.glob("_maps/templates/**/*.dmm"),
];
const content = folders
.map((file) => file.replace('_maps/', ''))
.map((file) => `#include "${file}"`)
.join('\n') + '\n';
fs.writeFileSync('_maps/templates.dm', content);
const content =
folders
.map((file) => file.replace("_maps/", ""))
.map((file) => `#include "${file}"`)
.join("\n") + "\n";
fs.writeFileSync("_maps/templates.dm", content);
},
});
export const DmTarget = new Juke.Target({
parameters: [DefineParameter, DmVersionParameter, WarningParameter, NoWarningParameter, SkipIconCutter],
parameters: [
DefineParameter,
DmVersionParameter,
WarningParameter,
NoWarningParameter,
SkipIconCutter,
],
dependsOn: ({ get }) => [
get(DefineParameter).includes('ALL_MAPS') && DmMapsIncludeTarget,
get(DefineParameter).includes("ALL_MAPS") && DmMapsIncludeTarget,
!get(SkipIconCutter) && IconCutterTarget,
],
inputs: [
'_maps/map_files/generic/**',
'maps/**/*.dm',
'code/**',
'html/**',
'icons/**',
'interface/**',
'sound/**',
'tgui/public/tgui.html',
"_maps/map_files/generic/**",
"maps/**/*.dm",
"code/**",
"html/**",
"icons/**",
"interface/**",
"sound/**",
"tgui/public/tgui.html",
`${DME_NAME}.dme`,
NamedVersionFile,
],
@@ -232,15 +236,12 @@ export const DmTarget = new Juke.Target({
if (get(DmVersionParameter)) {
return []; // Always rebuild when dm version is provided
}
return [
`${DME_NAME}.dmb`,
`${DME_NAME}.rsc`,
]
return [`${DME_NAME}.dmb`, `${DME_NAME}.rsc`];
},
executes: async ({ get }) => {
await DreamMaker(`${DME_NAME}.dme`, {
defines: ['CBT', ...get(DefineParameter)],
warningsAsErrors: get(WarningParameter).includes('error'),
defines: ["CBT", ...get(DefineParameter)],
warningsAsErrors: get(WarningParameter).includes("error"),
ignoreWarningCodes: get(NoWarningParameter),
namedDmVersion: get(DmVersionParameter),
});
@@ -248,156 +249,173 @@ export const DmTarget = new Juke.Target({
});
export const DmTestTarget = new Juke.Target({
parameters: [DefineParameter, DmVersionParameter, WarningParameter, NoWarningParameter],
parameters: [
DefineParameter,
DmVersionParameter,
WarningParameter,
NoWarningParameter,
],
dependsOn: ({ get }) => [
get(DefineParameter).includes('ALL_MAPS') && DmMapsIncludeTarget,
get(DefineParameter).includes("ALL_MAPS") && DmMapsIncludeTarget,
IconCutterTarget,
],
executes: async ({ get }) => {
fs.copyFileSync(`${DME_NAME}.dme`, `${DME_NAME}.test.dme`);
await DreamMaker(`${DME_NAME}.test.dme`, {
defines: ['CBT', 'CIBUILDING', ...get(DefineParameter)],
warningsAsErrors: get(WarningParameter).includes('error'),
defines: ["CBT", "CIBUILDING", ...get(DefineParameter)],
warningsAsErrors: get(WarningParameter).includes("error"),
ignoreWarningCodes: get(NoWarningParameter),
namedDmVersion: get(DmVersionParameter),
});
Juke.rm('data/logs/ci', { recursive: true });
Juke.rm("data/logs/ci", { recursive: true });
const options = {
dmbFile : `${DME_NAME}.test.dmb`,
dmbFile: `${DME_NAME}.test.dmb`,
namedDmVersion: get(DmVersionParameter),
}
};
await DreamDaemon(
options,
'-close', '-trusted', '-verbose',
'-params', 'log-directory=ci'
"-close",
"-trusted",
"-verbose",
"-params",
"log-directory=ci",
);
Juke.rm('*.test.*');
Juke.rm("*.test.*");
try {
const cleanRun = fs.readFileSync('data/logs/ci/clean_run.lk', 'utf-8');
const cleanRun = fs.readFileSync("data/logs/ci/clean_run.lk", "utf-8");
console.log(cleanRun);
}
catch (err) {
Juke.logger.error('Test run was not clean, exiting');
} catch (err) {
Juke.logger.error("Test run was not clean, exiting");
throw new Juke.ExitCode(1);
}
},
});
export const AutowikiTarget = new Juke.Target({
parameters: [DefineParameter, DmVersionParameter, WarningParameter, NoWarningParameter],
parameters: [
DefineParameter,
DmVersionParameter,
WarningParameter,
NoWarningParameter,
],
dependsOn: ({ get }) => [
get(DefineParameter).includes('ALL_MAPS') && DmMapsIncludeTarget,
get(DefineParameter).includes("ALL_MAPS") && DmMapsIncludeTarget,
IconCutterTarget,
],
outputs: [
'data/autowiki_edits.txt',
],
outputs: ["data/autowiki_edits.txt"],
executes: async ({ get }) => {
fs.copyFileSync(`${DME_NAME}.dme`, `${DME_NAME}.test.dme`);
await DreamMaker(`${DME_NAME}.test.dme`, {
defines: ['CBT', 'AUTOWIKI', ...get(DefineParameter)],
warningsAsErrors: get(WarningParameter).includes('error'),
defines: ["CBT", "AUTOWIKI", ...get(DefineParameter)],
warningsAsErrors: get(WarningParameter).includes("error"),
ignoreWarningCodes: get(NoWarningParameter),
namedDmVersion: get(DmVersionParameter),
});
Juke.rm('data/autowiki_edits.txt');
Juke.rm('data/autowiki_files', { recursive: true });
Juke.rm('data/logs/ci', { recursive: true });
Juke.rm("data/autowiki_edits.txt");
Juke.rm("data/autowiki_files", { recursive: true });
Juke.rm("data/logs/ci", { recursive: true });
const options = {
dmbFile: `${DME_NAME}.test.dmb`,
namedDmVersion: get(DmVersionParameter),
}
};
await DreamDaemon(
options,
'-close', '-trusted', '-verbose',
'-params', 'log-directory=ci',
"-close",
"-trusted",
"-verbose",
"-params",
"log-directory=ci",
);
Juke.rm('*.test.*');
if (!fs.existsSync('data/autowiki_edits.txt')) {
Juke.logger.error('Autowiki did not generate an output, exiting');
Juke.rm("*.test.*");
if (!fs.existsSync("data/autowiki_edits.txt")) {
Juke.logger.error("Autowiki did not generate an output, exiting");
throw new Juke.ExitCode(1);
}
},
})
});
export const YarnTarget = new Juke.Target({
parameters: [CiParameter],
inputs: [
'tgui/.yarn/+(cache|releases|plugins|sdks)/**/*',
'tgui/**/package.json',
'tgui/yarn.lock',
"tgui/.yarn/+(cache|releases|plugins|sdks)/**/*",
"tgui/**/package.json",
"tgui/yarn.lock",
],
outputs: [
'tgui/.yarn/install-target',
],
executes: ({ get }) => yarn('install', get(CiParameter) && '--immutable'),
outputs: ["tgui/.yarn/install-target"],
executes: ({ get }) => yarn("install", get(CiParameter) && "--immutable"),
});
export const TgFontTarget = new Juke.Target({
dependsOn: [YarnTarget],
inputs: [
'tgui/.yarn/install-target',
'tgui/packages/tgfont/**/*.+(js|cjs|svg)',
'tgui/packages/tgfont/package.json',
"tgui/.yarn/install-target",
"tgui/packages/tgfont/**/*.+(js|mjs|svg)",
"tgui/packages/tgfont/package.json",
],
outputs: [
'tgui/packages/tgfont/dist/tgfont.css',
'tgui/packages/tgfont/dist/tgfont.eot',
'tgui/packages/tgfont/dist/tgfont.woff2',
"tgui/packages/tgfont/dist/tgfont.css",
"tgui/packages/tgfont/dist/tgfont.woff2",
],
executes: async () => {
await yarn('tgfont:build');
fs.copyFileSync('tgui/packages/tgfont/dist/tgfont.css', 'tgui/packages/tgfont/static/tgfont.css');
fs.copyFileSync('tgui/packages/tgfont/dist/tgfont.eot', 'tgui/packages/tgfont/static/tgfont.eot');
fs.copyFileSync('tgui/packages/tgfont/dist/tgfont.woff2', 'tgui/packages/tgfont/static/tgfont.woff2');
}
await yarn("tgfont:build");
fs.mkdirSync("tgui/packages/tgfont/static", { recursive: true });
fs.copyFileSync(
"tgui/packages/tgfont/dist/tgfont.css",
"tgui/packages/tgfont/static/tgfont.css",
);
fs.copyFileSync(
"tgui/packages/tgfont/dist/tgfont.woff2",
"tgui/packages/tgfont/static/tgfont.woff2",
);
},
});
export const TguiTarget = new Juke.Target({
dependsOn: [YarnTarget],
inputs: [
'tgui/.yarn/install-target',
'tgui/rspack.config.cjs',
'tgui/**/package.json',
'tgui/packages/**/*.+(js|cjs|ts|tsx|jsx|scss)',
"tgui/.yarn/install-target",
"tgui/rspack.config.cjs",
"tgui/**/package.json",
"tgui/packages/**/*.+(js|cjs|ts|tsx|jsx|scss)",
],
outputs: [
'tgui/public/tgui.bundle.css',
'tgui/public/tgui.bundle.js',
'tgui/public/tgui-panel.bundle.css',
'tgui/public/tgui-panel.bundle.js',
'tgui/public/tgui-say.bundle.css',
'tgui/public/tgui-say.bundle.js',
"tgui/public/tgui.bundle.css",
"tgui/public/tgui.bundle.js",
"tgui/public/tgui-panel.bundle.css",
"tgui/public/tgui-panel.bundle.js",
"tgui/public/tgui-say.bundle.css",
"tgui/public/tgui-say.bundle.js",
],
executes: () => yarn('tgui:build'),
executes: () => yarn("tgui:build"),
});
export const TguiEslintTarget = new Juke.Target({
parameters: [CiParameter],
dependsOn: [YarnTarget],
executes: ({ get }) => yarn('tgui:lint', !get(CiParameter) && '--fix'),
executes: ({ get }) => yarn("tgui:lint", !get(CiParameter) && "--fix"),
});
export const TguiPrettierTarget = new Juke.Target({
dependsOn: [YarnTarget],
executes: () => yarn('tgui:prettier'),
executes: () => yarn("tgui:prettier"),
});
export const TguiSonarTarget = new Juke.Target({
dependsOn: [YarnTarget],
executes: () => yarn('tgui:sonar'),
executes: () => yarn("tgui:sonar"),
});
export const TguiTscTarget = new Juke.Target({
dependsOn: [YarnTarget],
executes: () => yarn('tgui:tsc'),
executes: () => yarn("tgui:tsc"),
});
export const TguiTestTarget = new Juke.Target({
parameters: [CiParameter],
dependsOn: [YarnTarget],
executes: ({ get }) => yarn(`tgui:test-${get(CiParameter) ? 'ci' : 'simple'}`),
executes: ({ get }) =>
yarn(`tgui:test-${get(CiParameter) ? "ci" : "simple"}`),
});
export const TguiLintTarget = new Juke.Target({
@@ -406,27 +424,27 @@ export const TguiLintTarget = new Juke.Target({
export const TguiDevTarget = new Juke.Target({
dependsOn: [YarnTarget],
executes: ({ args }) => yarn('tgui:dev', ...args),
executes: ({ args }) => yarn("tgui:dev", ...args),
});
export const TguiAnalyzeTarget = new Juke.Target({
dependsOn: [YarnTarget],
executes: () => yarn('tgui:analyze'),
executes: () => yarn("tgui:analyze"),
});
export const TguiBenchTarget = new Juke.Target({
dependsOn: [YarnTarget],
executes: () => yarn('tgui:bench'),
executes: () => yarn("tgui:bench"),
});
export const TguiPrettierFix = new Juke.Target({
dependsOn: [YarnTarget],
executes: () => yarn('tgui:prettier-fix'),
executes: () => yarn("tgui:prettier-fix"),
});
export const TguiEslintFix = new Juke.Target({
dependsOn: [YarnTarget],
executes: () => yarn('tgui:eslint-fix'),
executes: () => yarn("tgui:eslint-fix"),
});
export const TguiFix = new Juke.Target({
@@ -449,12 +467,12 @@ export const ServerTarget = new Juke.Target({
parameters: [DmVersionParameter, PortParameter],
dependsOn: [BuildTarget],
executes: async ({ get }) => {
const port = get(PortParameter) || '1337';
const port = get(PortParameter) || "1337";
const options = {
dmbFile: `${DME_NAME}.dmb`,
namedDmVersion: get(DmVersionParameter),
}
await DreamDaemon(options, port, '-trusted');
};
await DreamDaemon(options, port, "-trusted");
},
});
@@ -464,23 +482,23 @@ export const AllTarget = new Juke.Target({
export const TguiCleanTarget = new Juke.Target({
executes: async () => {
Juke.rm('tgui/public/.tmp', { recursive: true });
Juke.rm('tgui/public/*.map');
Juke.rm('tgui/public/*.{chunk,bundle,hot-update}.*');
Juke.rm('tgui/packages/tgfont/dist', { recursive: true });
Juke.rm('tgui/.yarn/{cache,unplugged,webpack}', { recursive: true });
Juke.rm('tgui/.yarn/build-state.yml');
Juke.rm('tgui/.yarn/install-state.gz');
Juke.rm('tgui/.yarn/install-target');
Juke.rm('tgui/.pnp.*');
Juke.rm("tgui/public/.tmp", { recursive: true });
Juke.rm("tgui/public/*.map");
Juke.rm("tgui/public/*.{chunk,bundle,hot-update}.*");
Juke.rm("tgui/packages/tgfont/dist", { recursive: true });
Juke.rm("tgui/.yarn/{cache,unplugged,rspack}", { recursive: true });
Juke.rm("tgui/.yarn/build-state.yml");
Juke.rm("tgui/.yarn/install-state.gz");
Juke.rm("tgui/.yarn/install-target");
Juke.rm("tgui/.pnp.*");
},
});
export const CleanTarget = new Juke.Target({
dependsOn: [TguiCleanTarget],
executes: async () => {
Juke.rm('*.{dmb,rsc}');
Juke.rm('_maps/templates.dm');
Juke.rm("*.{dmb,rsc}");
Juke.rm("_maps/templates.dm");
},
});
@@ -490,10 +508,10 @@ export const CleanTarget = new Juke.Target({
export const CleanAllTarget = new Juke.Target({
dependsOn: [CleanTarget],
executes: async () => {
Juke.logger.info('Cleaning up data/logs');
Juke.rm('data/logs', { recursive: true });
Juke.logger.info('Cleaning up global yarn cache');
await yarn('cache', 'clean', '--all');
Juke.logger.info("Cleaning up data/logs");
Juke.rm("data/logs", { recursive: true });
Juke.logger.info("Cleaning up global yarn cache");
await yarn("cache", "clean", "--all");
},
});
@@ -504,17 +522,16 @@ export const CleanAllTarget = new Juke.Target({
*/
const prependDefines = (...defines) => {
const dmeContents = fs.readFileSync(`${DME_NAME}.dme`);
const textToWrite = defines.map(define => `#define ${define}\n`);
const textToWrite = defines.map((define) => `#define ${define}\n`);
fs.writeFileSync(`${DME_NAME}.dme`, `${textToWrite}\n${dmeContents}`);
};
export const TgsTarget = new Juke.Target({
dependsOn: [TguiTarget],
executes: async () => {
Juke.logger.info('Prepending TGS define');
prependDefines('TGS');
Juke.logger.info("Prepending TGS define");
prependDefines("TGS");
},
});
export default TGS_MODE ? TgsTarget : BuildTarget;