diff --git a/frontend/index.html b/frontend/index.html index a13c333..545285a 100644 --- a/frontend/index.html +++ b/frontend/index.html @@ -1,13 +1,10 @@ - + - - - - - GoHoarder Dashboard + + GoHoarder dashboard
diff --git a/frontend/package.json b/frontend/package.json index c6c388a..a7763e0 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -8,25 +8,20 @@ "preview": "vite preview", "test": "vitest run", "test:watch": "vitest", - "test:coverage": "vitest run --coverage" + "test:coverage": "vitest run --coverage", + "sources": "node scripts/library-sources.mjs --write" }, "dependencies": { - "@vueuse/core": "^15.0.0", + "@fontsource/ibm-plex-mono": "5.3.0", + "@fontsource/ibm-plex-sans": "5.3.0", + "@fortawesome/free-solid-svg-icons": "7.3.1", + "@perfect-design/ui": "0.3.10", "axios": "^1.20.0", - "class-variance-authority": "^0.7.1", - "clsx": "^2.1.1", - "lucide-vue-next": "^1.0.0", - "marked": "^18.0.0", "pinia": "^4.0.0", - "reka-ui": "^2.7.0", - "tailwind-merge": "^3.4.0", - "tailwindcss-animate": "^1.0.7", "vue": "^3.5.26", "vue-router": "^5.3.1" }, "devDependencies": { - "@fortawesome/fontawesome-free": "^7.1.0", - "@tailwindcss/typography": "^0.5.19", "@tailwindcss/vite": "^4.3.3", "@testing-library/jest-dom": "^7.0.0", "@testing-library/vue": "^8.1.0", diff --git a/frontend/pnpm-lock.yaml b/frontend/pnpm-lock.yaml index c21aab3..030e2cb 100644 --- a/frontend/pnpm-lock.yaml +++ b/frontend/pnpm-lock.yaml @@ -13,36 +13,24 @@ importers: .: dependencies: - '@vueuse/core': - specifier: ^15.0.0 - version: 15.0.0(vue@3.5.45(typescript@6.0.3)) + '@fontsource/ibm-plex-mono': + specifier: 5.3.0 + version: 5.3.0 + '@fontsource/ibm-plex-sans': + specifier: 5.3.0 + version: 5.3.0 + '@fortawesome/free-solid-svg-icons': + specifier: 7.3.1 + version: 7.3.1 + '@perfect-design/ui': + specifier: 0.3.10 + version: 0.3.10(pinia@4.1.0(@vue/devtools-api@8.2.1)(typescript@6.0.3)(vue@3.5.45(typescript@6.0.3)))(tailwindcss@4.3.5)(vue@3.5.45(typescript@6.0.3)) axios: specifier: ^1.20.0 - version: 1.21.1(debug@4.4.3(supports-color@7.2.0))(supports-color@7.2.0) - class-variance-authority: - specifier: ^0.7.1 - version: 0.7.1 - clsx: - specifier: ^2.1.1 - version: 2.1.1 - lucide-vue-next: - specifier: ^1.0.0 - version: 1.0.0(vue@3.5.45(typescript@6.0.3)) - marked: - specifier: ^18.0.0 - version: 18.2.1 + version: 1.21.1 pinia: specifier: ^4.0.0 version: 4.1.0(@vue/devtools-api@8.2.1)(typescript@6.0.3)(vue@3.5.45(typescript@6.0.3)) - reka-ui: - specifier: ^2.7.0 - version: 2.11.0(vue@3.5.45(typescript@6.0.3)) - tailwind-merge: - specifier: ^3.4.0 - version: 3.7.1 - tailwindcss-animate: - specifier: ^1.0.7 - version: 1.0.7(tailwindcss@4.3.5) vue: specifier: ^3.5.26 version: 3.5.45(typescript@6.0.3) @@ -50,12 +38,6 @@ importers: specifier: ^5.3.1 version: 5.5.1(@vue/compiler-sfc@3.5.45)(esbuild@0.28.2)(pinia@4.1.0(@vue/devtools-api@8.2.1)(typescript@6.0.3)(vue@3.5.45(typescript@6.0.3)))(rolldown@1.2.18)(vite@8.3.8(esbuild@0.28.2)(jiti@2.7.0))(vue@3.5.45(typescript@6.0.3)) devDependencies: - '@fortawesome/fontawesome-free': - specifier: ^7.1.0 - version: 7.3.1 - '@tailwindcss/typography': - specifier: ^0.5.19 - version: 0.5.20(tailwindcss@4.3.5) '@tailwindcss/vite': specifier: ^4.3.3 version: 4.3.5(vite@8.3.8(esbuild@0.28.2)(jiti@2.7.0)) @@ -329,8 +311,18 @@ packages: peerDependencies: vue: '>=3.3.0' - '@fortawesome/fontawesome-free@7.3.1': - resolution: {integrity: sha512-wmglKKPDIkgV3aWlZzWECCPoGIkYCulzBwxG9+w7rc5BGapZ6cPMpoPOT8k36J0Ni7PPX6c/rsoMWfS4d1MUMg==} + '@fontsource/ibm-plex-mono@5.3.0': + resolution: {integrity: sha512-eTgnZjZEGk1QtD3ZstF+Vclo2HLAni8YMy34/DxllwZvyz1lR/1RF/xTiAquOBO7MvqBx8D2Ig2WCPMVfdZu7Q==} + + '@fontsource/ibm-plex-sans@5.3.0': + resolution: {integrity: sha512-CbE4CbbEEZJX860XyUiRpsksXIQR8Rp2XDva2VO53NJox9tVNtusrysd2x5YkUEY3ErQ66W1IiiQL8/wihhw5w==} + + '@fortawesome/fontawesome-common-types@7.3.1': + resolution: {integrity: sha512-k0C0sdHmZtAo6dRDtd1Z/qcpyHbL0CKsjV8seMY/21xGhY5Wsv0XRmiI/xEEH4y2c9b1+jvgNs/3EqhV27yUEA==} + engines: {node: '>=6'} + + '@fortawesome/free-solid-svg-icons@7.3.1': + resolution: {integrity: sha512-v0BLa0eqg7ubvVWeNSHVBs8fWH/GJicERZoJaxJ3FE/lj67VSqzoMg9pzfZVOfLMX10y0pGwQAuxoRVVH2patg==} engines: {node: '>=6'} '@internationalized/date@3.10.1': @@ -361,6 +353,13 @@ packages: '@oxc-project/types@0.156.0': resolution: {integrity: sha512-1Duyg48TdJNdyhEB8Xn1L36bT9Pv6GUtlKjHxOys8xkaF/rQq3XJE+bAurSK/AgIz5mGFsb77cn9Pb20+WCScw==} + '@perfect-design/ui@0.3.10': + resolution: {integrity: sha512-nFpY8dK6braHsRPVdX3bUCrkPNfwiUj2KfvUfLdFRFlfBRaqrkNGx2QkmNu/L0rdNe6JQj6Mvdrb+LnC/sFg8Q==} + peerDependencies: + pinia: ^3.0.0 || ^4.0.0 + tailwindcss: ^4.1.0 + vue: ^3.5.0 + '@rolldown/binding-android-arm-eabi@1.2.18': resolution: {integrity: sha512-ubTG+4KlidvioxjOFdsdEa2F6JVGZb8m2ByJUqQ7fYzUeT1cEn194POcsQ10PKH4p//q0YQn4SB3YpSuzcA1Yg==} engines: {node: ^20.19.0 || >=22.12.0} @@ -402,42 +401,36 @@ packages: engines: {node: ^20.19.0 || >=22.12.0} cpu: [arm64] os: [linux] - libc: [glibc] '@rolldown/binding-linux-arm64-musl@1.2.18': resolution: {integrity: sha512-4oqWItLLYt7IceOnElCct8T2ek5p7PmD7LN04TRJRXGo5f3HtKTgGH6PhYRFK4C2ICkq/LMUU0BVPvvlAKhm8g==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [arm64] os: [linux] - libc: [musl] '@rolldown/binding-linux-ppc64-gnu@1.2.18': resolution: {integrity: sha512-+AkRly5SrCEgnPhGRfub7pucASYEC2fTsxZg7VCcnozpA2+Wn/gCYy1t7LuJS67/xyJu/7noYBJncDUkbwgw2A==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [ppc64] os: [linux] - libc: [glibc] '@rolldown/binding-linux-s390x-gnu@1.2.18': resolution: {integrity: sha512-Ttg1r9vVykMnQrE/GwYO9icKtXiuiMfRe/w74xJkeoVuvhRG+WtT6LEMOf58Yl63yd77lhHzO8Y55R8CC3XALA==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [s390x] os: [linux] - libc: [glibc] '@rolldown/binding-linux-x64-gnu@1.2.18': resolution: {integrity: sha512-xX1Tt4o5jUMma0vJsXp5eRZA9nOuyigb2dKJMMzZRmzMxLYGE9PaKKSqHPzPvSQgM8ZOEacSTQwDQcwWfh0xmQ==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [x64] os: [linux] - libc: [glibc] '@rolldown/binding-linux-x64-musl@1.2.18': resolution: {integrity: sha512-4VVlGI5K2kociZlW3lSN8VjG3TW5yQIlAcfCdBXMgGjJxZll15Fa4ocRHXHvIVVnwlibCw/NQajJrNDiqqpiiw==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [x64] os: [linux] - libc: [musl] '@rolldown/binding-openharmony-arm64@1.2.18': resolution: {integrity: sha512-PApTsgH1jLYuyy3tSCz9De82Gq5qXwi7vImVZhEzTgX1C4150Cp5M2ZfL3pLvbCvbEHL0oJeC6pd6podtv8Y5w==} @@ -501,28 +494,24 @@ packages: engines: {node: '>= 20'} cpu: [arm64] os: [linux] - libc: [glibc] '@tailwindcss/oxide-linux-arm64-musl@4.3.5': resolution: {integrity: sha512-H9lsvO4x9E4nE4Hi8h7NHHw0O/kcVSu+iOyFHNGdYzazGgDjFHZbE6S3hQ8kMcbNXSBlMdNi67LV5EVqtpaJtw==} engines: {node: '>= 20'} cpu: [arm64] os: [linux] - libc: [musl] '@tailwindcss/oxide-linux-x64-gnu@4.3.5': resolution: {integrity: sha512-4uxQvtBvPuIdl13WfUBj9xMZHH14PtHZ8OZdtLmdyDtG66sCa1t599NZT+jagkUzRtWhuul1qRZQ1nAJscXN5g==} engines: {node: '>= 20'} cpu: [x64] os: [linux] - libc: [glibc] '@tailwindcss/oxide-linux-x64-musl@4.3.5': resolution: {integrity: sha512-0JQAzs7jwbA7O6+z/adU+Jk3AXwsu3npAhtr5escXS7TqEqWcaDV7qHuI+0Vy/KQRuVGnLQREcSJWYauyV3oqg==} engines: {node: '>= 20'} cpu: [x64] os: [linux] - libc: [musl] '@tailwindcss/oxide-wasm32-wasi@4.3.5': resolution: {integrity: sha512-OJhFmlEfdzMr+avACdi40RPtnkW0B6hXyxL/8r+tnEHBWZji36CYRjEXrrvgBmaYsD3oEOBqwYFRKsYvzFe7Bw==} @@ -551,11 +540,6 @@ packages: resolution: {integrity: sha512-PynqGLZsZvwM9tqD/CUxkOIfyd6K5elZ2MooauzJryP/UqXYgi3yYbtt3N0Xe+MHV/eFKPFQCEfIKAqlAS1CBg==} engines: {node: '>= 20'} - '@tailwindcss/typography@0.5.20': - resolution: {integrity: sha512-hwbzQuNUfcPvbegQFatVPl/MY/tcM9KLl963hQ5laJKPh81TEZ1+dNG9PirGvcaDBkp+BCshExAyKVPW91dozw==} - peerDependencies: - tailwindcss: '>=3.0.0 || >=4.0.0 || insiders' - '@tailwindcss/vite@4.3.5': resolution: {integrity: sha512-BCNiY0a1ZjdOHVqw7kyb7U72BwfMF3dfUuN+tQsLWky/J5JOI/r7abibglXfygrZhVO/3u3V+E25kkKTeMkXaQ==} peerDependencies: @@ -727,30 +711,14 @@ packages: peerDependencies: vue: ^3.5.0 - '@vueuse/core@15.0.0': - resolution: {integrity: sha512-Zv67h5mrk7YHDJsRObx+DXaCBz6RKBUpxqLesJ+3xZNPG6yuQs7ja7kg3veFrrouYLWAqydQ7CwGEbLVxB43Ng==} - engines: {node: '>=22'} - peerDependencies: - vue: ^3.5.0 - '@vueuse/metadata@14.4.0': resolution: {integrity: sha512-swx/255R6JyHZFJhx845iz5CRWDZdCfvkZOpACWc5+c5WHcG24mv8gUT1WIdFQaHt6dq79rvILd9QnCWiyVm9g==} - '@vueuse/metadata@15.0.0': - resolution: {integrity: sha512-sfWE5LADAKJ0KnjtGliMdSN8Ij/L7uP6rXIZlgPloAI4zvvefbw6H5Lt7KJA6RqQOYgVqWF5Guj50HHMIzygBg==} - engines: {node: '>=22'} - '@vueuse/shared@14.4.0': resolution: {integrity: sha512-JRgY90Sz8DDtPMsaDflvPMp9xYk69JZAmbuDvAquUVXKr2gEjqtzGNTTthLfckH0BzBqvnu31gb4a8TGLRe79g==} peerDependencies: vue: ^3.5.0 - '@vueuse/shared@15.0.0': - resolution: {integrity: sha512-vbNXhGrbV53xPOMSyOzMHQRvhMgZf7oNDw2RChUetVxwTIEkInQ1joZ9JbT0G3z2n2AJNjvmCWeM9ySYrnvogA==} - engines: {node: '>=22'} - peerDependencies: - vue: ^3.5.0 - abbrev@5.0.0: resolution: {integrity: sha512-/XrFJgzQQQHpti1raDJC6m4ws6aNktmjBlhk8Fdlk7LwCEuDoieEJJY9OFHjfiFJFFRM2tK+Ky/IsfbbmlMu1w==} engines: {node: ^22.22.2 || ^24.15.0 || >=26.0.0} @@ -860,13 +828,6 @@ packages: resolution: {integrity: sha512-Ec2Z7wpcKBiMpR7DxteoqS/sq5G5d2A4fpxzPv6+fD7xNNdrTghn7L11YwV5EN1B3i72Erc3XVT5FkWIDx90+A==} engines: {node: '>= 22.22'} - class-variance-authority@0.7.1: - resolution: {integrity: sha512-Ka+9Trutv7G8M6WT6SeiRWz792K5qEqIGEGzXKhAE6xOWAY6pPH8U+9IY3oCMv6kqTmLsv7Xh/2w2RigkePMsg==} - - clsx@2.1.1: - resolution: {integrity: sha512-eYm0QWBtUrBWZWG0d386OGAw16Z995PiOVo2B7bjWSbHedGl5e0ZWaq65kOGgUSNesEIDkB9ISbTg/JK9dhCZA==} - engines: {node: '>=6'} - color-convert@2.0.1: resolution: {integrity: sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==} engines: {node: '>=7.0.0'} @@ -894,11 +855,6 @@ packages: css.escape@1.5.1: resolution: {integrity: sha512-YUifsXXuknHlUsmlgyY0PKzgPOr7/FjCePfHNt0jxm83wHZi44VDMQ7/fGNkjY3/jV1MC+1CmZbaHzugyeRtpg==} - cssesc@3.0.0: - resolution: {integrity: sha512-/Tb/JcjK111nNScGob5MNtsntNM1aCNUDipB/TkwZFhyDrrE47SOx/18wF2bbjgc3ZzCSKW1T5nt5EbFoAz/Vg==} - engines: {node: '>=4'} - hasBin: true - csstype@3.2.3: resolution: {integrity: sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ==} @@ -1247,28 +1203,24 @@ packages: engines: {node: '>= 12.0.0'} cpu: [arm64] os: [linux] - libc: [glibc] lightningcss-linux-arm64-musl@1.33.0: resolution: {integrity: sha512-yiO5ROMuYQgXbC60yjZU5CYSFZGKXL0HFATXt9mHJn1+zW55oCtMI9NfcVhYLMFDL7gV7oBPon/EmMMGg2OvtQ==} engines: {node: '>= 12.0.0'} cpu: [arm64] os: [linux] - libc: [musl] lightningcss-linux-x64-gnu@1.33.0: resolution: {integrity: sha512-ar+Ju7LmcN0Jo4FpL4hpFybwNG9/3A/Br5KW2n2jyODg3MEZXaDYADdemoNS+BDNfMgKvylJLj4S5tyRActuAg==} engines: {node: '>= 12.0.0'} cpu: [x64] os: [linux] - libc: [glibc] lightningcss-linux-x64-musl@1.33.0: resolution: {integrity: sha512-RYiYbkokw0trfKqqzfF55lginwEPrD3OJDfTuJzFs1MK6iFnDenaz1fqLLtX4ITG3OktJQXOeTaw1awrBAlZPw==} engines: {node: '>= 12.0.0'} cpu: [x64] os: [linux] - libc: [musl] lightningcss-win32-arm64-msvc@1.33.0: resolution: {integrity: sha512-1K+MPfLSFVpphzpdbfkhlWk6wBrTObBzS2T6db10PNOZgR9GoVsAWzwNyuhUYYbTp23j+4RrncfujZ4uAzXvwA==} @@ -1298,12 +1250,6 @@ packages: resolution: {integrity: sha512-U4N8FgzmWxc8k1VH8Kr6lQg18U7Fjvby6wXHVRX/ZZ7IwWbRMgrRbP0Wrb5q5NVinryp4SQampHKdvtecItxUg==} engines: {node: 20 || >=22} - lucide-vue-next@1.0.0: - resolution: {integrity: sha512-V6SPvx1IHTj/UY+FrIYWV5faISsPSb8BnWSFDxAtezWKvWc9ZZ40PDrdu1/Qb5vg4lHWr1hs1BAMGVGm6V1Xdg==} - deprecated: Package deprecated. Please use @lucide/vue instead. - peerDependencies: - vue: '>=3.0.1' - lz-string@1.5.0: resolution: {integrity: sha512-h5bgJWpxJNswbU7qCrV0tIKQCaS3blPDrqKWx+QxzuzL1zGUzij9XCWLrSLsJPu5t+eWA/ycetzYAO5IOMcWAQ==} hasBin: true @@ -1321,11 +1267,6 @@ packages: magic-string@1.4.5: resolution: {integrity: sha512-oLLC2+YvQUfAa+vxoufE/yc1icb87M9iXIRqAoR/2EhE/8cb3SF/+Gi0c2By1B+5Vz2e2vQtUvHiu1+63Znh+w==} - marked@18.2.1: - resolution: {integrity: sha512-ii4bxCTCqqwpT86XZWgJNs+ZnAIZksmLGYMViWA7PDIXYIeNo1x6cDdX3JOip9NM/cI6p8z57FxliACboTruMA==} - engines: {node: '>= 20'} - hasBin: true - math-intrinsics@1.1.0: resolution: {integrity: sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==} engines: {node: '>= 0.4'} @@ -1441,10 +1382,6 @@ packages: resolution: {integrity: sha512-/+5VFTchJDoVj3bhoqi6UeymcD00DAwb1nJwamzPvHEszJ4FpF6SNNbUbOS8yI56qHzdV8eK0qEfOSiodkTdxg==} engines: {node: '>= 0.4'} - postcss-selector-parser@7.1.6: - resolution: {integrity: sha512-7qASPzhKF2l2KLboRZux8CCTRMdGiV08vWmyKzPz22qZ7ZjQBOeY7rNzNoCLSUiftJ7HUq0GERHmxw/t0dCdMw==} - engines: {node: '>=4'} - postcss@8.5.32: resolution: {integrity: sha512-LJlKCCAUFKOuZxipUdYw1NzIITEsPcgyOG9LkvRJvuKj/bRzbuRY0ARXvL0pWGpsZvn8jku+LMep2eU0seHp8g==} engines: {node: ^10 || ^12 || >=14} @@ -1557,11 +1494,6 @@ packages: tailwind-merge@3.7.1: resolution: {integrity: sha512-v7y4BV4FUlO8exj/4M5UXKeoowDiuugVUg3tkMNIyOUCOHy5xp8+5aWQeXCtZ2491sUV1YPsVeM9EveZ6/xuZQ==} - tailwindcss-animate@1.0.7: - resolution: {integrity: sha512-bl6mpH3T7I3UFxuvDEXLxy/VuFxBk5bbzplh7tXI68mwMokNYd1t9qPBHlnyTwfa4JGC4zP516I1hYYtQ/vspA==} - peerDependencies: - tailwindcss: '>=3.0.0 || insiders' - tailwindcss@4.3.5: resolution: {integrity: sha512-FcQk9BuffmEHJP2G0XmB2SplU1aLTI7j07Kunk+U74Ny+XiWOtzXz9aujFZ/avntw1e2cOv/3PkgzflQ7gX2vQ==} @@ -1651,9 +1583,6 @@ packages: webpack: optional: true - util-deprecate@1.0.2: - resolution: {integrity: sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==} - vite@8.3.8: resolution: {integrity: sha512-LzOn3h9rG/0vhLdXrV4yJ4QFA9eEoqCl+Yx+kGJd7aB9w6nfNgVHKSYwLPZUHrz4ZGa+t+kXjV9itvcHDLQouA==} engines: {node: ^20.19.0 || >=22.12.0} @@ -1978,7 +1907,15 @@ snapshots: '@floating-ui/utils': 0.2.12 vue: 3.5.45(typescript@6.0.3) - '@fortawesome/fontawesome-free@7.3.1': {} + '@fontsource/ibm-plex-mono@5.3.0': {} + + '@fontsource/ibm-plex-sans@5.3.0': {} + + '@fortawesome/fontawesome-common-types@7.3.1': {} + + '@fortawesome/free-solid-svg-icons@7.3.1': + dependencies: + '@fortawesome/fontawesome-common-types': 7.3.1 '@internationalized/date@3.10.1': dependencies: @@ -2011,6 +1948,14 @@ snapshots: '@oxc-project/types@0.156.0': {} + '@perfect-design/ui@0.3.10(pinia@4.1.0(@vue/devtools-api@8.2.1)(typescript@6.0.3)(vue@3.5.45(typescript@6.0.3)))(tailwindcss@4.3.5)(vue@3.5.45(typescript@6.0.3))': + dependencies: + pinia: 4.1.0(@vue/devtools-api@8.2.1)(typescript@6.0.3)(vue@3.5.45(typescript@6.0.3)) + reka-ui: 2.11.0(vue@3.5.45(typescript@6.0.3)) + tailwind-merge: 3.7.1 + tailwindcss: 4.3.5 + vue: 3.5.45(typescript@6.0.3) + '@rolldown/binding-android-arm-eabi@1.2.18': optional: true @@ -2123,11 +2068,6 @@ snapshots: '@tailwindcss/oxide-win32-arm64-msvc': 4.3.5 '@tailwindcss/oxide-win32-x64-msvc': 4.3.5 - '@tailwindcss/typography@0.5.20(tailwindcss@4.3.5)': - dependencies: - postcss-selector-parser: 7.1.6 - tailwindcss: 4.3.5 - '@tailwindcss/vite@4.3.5(vite@8.3.8(esbuild@0.28.2)(jiti@2.7.0))': dependencies: '@tailwindcss/node': 4.3.5 @@ -2360,32 +2300,19 @@ snapshots: '@vueuse/shared': 14.4.0(vue@3.5.45(typescript@6.0.3)) vue: 3.5.45(typescript@6.0.3) - '@vueuse/core@15.0.0(vue@3.5.45(typescript@6.0.3))': - dependencies: - '@types/web-bluetooth': 0.0.21 - '@vueuse/metadata': 15.0.0 - '@vueuse/shared': 15.0.0(vue@3.5.45(typescript@6.0.3)) - vue: 3.5.45(typescript@6.0.3) - '@vueuse/metadata@14.4.0': {} - '@vueuse/metadata@15.0.0': {} - '@vueuse/shared@14.4.0(vue@3.5.45(typescript@6.0.3))': dependencies: vue: 3.5.45(typescript@6.0.3) - '@vueuse/shared@15.0.0(vue@3.5.45(typescript@6.0.3))': - dependencies: - vue: 3.5.45(typescript@6.0.3) - abbrev@5.0.0: {} acorn@8.18.0: {} - agent-base@6.0.2(supports-color@7.2.0): + agent-base@6.0.2: dependencies: - debug: 4.4.3(supports-color@7.2.0) + debug: 4.4.3 transitivePeerDependencies: - supports-color @@ -2441,11 +2368,11 @@ snapshots: dependencies: possible-typed-array-names: 1.1.0 - axios@1.21.1(debug@4.4.3(supports-color@7.2.0))(supports-color@7.2.0): + axios@1.21.1: dependencies: - follow-redirects: 1.16.3(debug@4.4.3(supports-color@7.2.0)) + follow-redirects: 1.16.3 form-data: 4.0.6 - https-proxy-agent: 5.0.1(supports-color@7.2.0) + https-proxy-agent: 5.0.1 proxy-from-env: 2.1.0 transitivePeerDependencies: - debug @@ -2495,12 +2422,6 @@ snapshots: dependencies: readdirp: 5.1.1 - class-variance-authority@0.7.1: - dependencies: - clsx: 2.1.1 - - clsx@2.1.1: {} - color-convert@2.0.1: dependencies: color-name: 1.1.4 @@ -2524,8 +2445,6 @@ snapshots: css.escape@1.5.1: {} - cssesc@3.0.0: {} - csstype@3.2.3: {} data-urls@8.0.0: @@ -2535,11 +2454,9 @@ snapshots: transitivePeerDependencies: - '@noble/hashes' - debug@4.4.3(supports-color@7.2.0): + debug@4.4.3: dependencies: ms: 2.1.3 - optionalDependencies: - supports-color: 7.2.0 decimal.js@10.6.0: {} @@ -2683,9 +2600,7 @@ snapshots: optionalDependencies: picomatch: 4.0.7 - follow-redirects@1.16.3(debug@4.4.3(supports-color@7.2.0)): - optionalDependencies: - debug: 4.4.3(supports-color@7.2.0) + follow-redirects@1.16.3: {} for-each@0.3.5: dependencies: @@ -2760,10 +2675,10 @@ snapshots: transitivePeerDependencies: - '@noble/hashes' - https-proxy-agent@5.0.1(supports-color@7.2.0): + https-proxy-agent@5.0.1: dependencies: - agent-base: 6.0.2(supports-color@7.2.0) - debug: 4.4.3(supports-color@7.2.0) + agent-base: 6.0.2 + debug: 4.4.3 transitivePeerDependencies: - supports-color @@ -2955,10 +2870,6 @@ snapshots: lru-cache@11.5.3: {} - lucide-vue-next@1.0.0(vue@3.5.45(typescript@6.0.3)): - dependencies: - vue: 3.5.45(typescript@6.0.3) - lz-string@1.5.0: {} magic-string-ast@1.0.3: @@ -2977,8 +2888,6 @@ snapshots: dependencies: '@jridgewell/sourcemap-codec': 1.6.0 - marked@18.2.1: {} - math-intrinsics@1.1.0: {} mime-db@1.52.0: {} @@ -3081,11 +2990,6 @@ snapshots: possible-typed-array-names@1.1.0: {} - postcss-selector-parser@7.1.6: - dependencies: - cssesc: 3.0.0 - util-deprecate: 1.0.2 - postcss@8.5.32: dependencies: nanoid: 3.3.20 @@ -3237,10 +3141,6 @@ snapshots: tailwind-merge@3.7.1: {} - tailwindcss-animate@1.0.7(tailwindcss@4.3.5): - dependencies: - tailwindcss: 4.3.5 - tailwindcss@4.3.5: {} tapable@2.3.3: {} @@ -3292,8 +3192,6 @@ snapshots: rolldown: 1.2.18 vite: 8.3.8(esbuild@0.28.2)(jiti@2.7.0) - util-deprecate@1.0.2: {} - vite@8.3.8(esbuild@0.28.2)(jiti@2.7.0): dependencies: lightningcss: 1.33.0 diff --git a/frontend/scripts/library-sources.d.mts b/frontend/scripts/library-sources.d.mts new file mode 100644 index 0000000..bf6e9fa --- /dev/null +++ b/frontend/scripts/library-sources.d.mts @@ -0,0 +1 @@ +export function librarySources(root: string): string[] diff --git a/frontend/scripts/library-sources.mjs b/frontend/scripts/library-sources.mjs new file mode 100644 index 0000000..ea7b924 --- /dev/null +++ b/frontend/scripts/library-sources.mjs @@ -0,0 +1,94 @@ +// Lists the @source lines for the @perfect-design/ui dist directories the app imports, transitively. +// `node scripts/library-sources.mjs` prints them; `--write` rewrites the block in src/styles/main.css. +import { readFileSync, writeFileSync, readdirSync, statSync, existsSync } from 'node:fs' +import { fileURLToPath } from 'node:url' +import { join, dirname, resolve, relative } from 'node:path' + +export function librarySources(root) { + const dist = join(root, 'node_modules/@perfect-design/ui/dist') + + function walk(dir, out = []) { + for (const e of readdirSync(dir)) { + const p = join(dir, e) + statSync(p).isDirectory() ? walk(p, out) : out.push(p) + } + return out + } + + // names imported from the package entry + const names = new Set() + for (const f of walk(join(root, 'src')).filter((f) => /\.(vue|ts)$/.test(f) && !/\.(spec|test)\./.test(f))) { + const src = readFileSync(f, 'utf8') + for (const m of src.matchAll(/import\s*\{([^}]*)\}\s*from\s*'@perfect-design\/ui'/g)) + for (const n of m[1].split(',')) { + const name = n.trim().replace(/^type\s+/, '').split(/\s+as\s+/)[0] + if (name && !n.trim().startsWith('type ')) names.add(name) + } + } + + // name -> file: follow the barrel index.js re-exports + const resolveJs = (from, spec) => { + const base = resolve(dirname(from), spec) + for (const c of [base, base + '.js', join(base, 'index.js')]) if (existsSync(c) && statSync(c).isFile()) return c + return null + } + const exportsOf = new Map() // exported name -> file + { + const idx = join(dist, 'index.js') + const src = readFileSync(idx, 'utf8') + const localFile = new Map() + for (const m of src.matchAll(/^import\s+(?:(\w+)\s*,?\s*)?(?:\{([^}]*)\})?\s*from\s*"(\.[^"]+)";?$/gm)) { + const target = resolveJs(idx, m[3]) + if (!target) continue + if (m[1]) localFile.set(m[1], target) + if (m[2]) for (const n of m[2].split(',')) { const p = n.trim().split(/\s+as\s+/); if (p[0]) localFile.set(p[1] ?? p[0], target) } + } + for (const m of src.matchAll(/^export\s*\{([^}]*)\};?$/gm)) + for (const n of m[1].split(',')) { + const p = n.trim().split(/\s+as\s+/) + const local = p[0], exported = p[1] ?? p[0] + if (localFile.has(local)) exportsOf.set(exported, localFile.get(local)) + } + } + const files = new Set() + const queue = [] + const missing = [] + for (const n of names) { + const f = exportsOf.get(n) + f ? queue.push(f) : missing.push(n) + } + while (queue.length) { + const f = queue.pop() + if (files.has(f)) continue + files.add(f) + const src = readFileSync(f, 'utf8') + for (const m of src.matchAll(/from\s*["'](\.[^"']+)["']/g)) { + const t = resolveJs(f, m[1]) + if (t && !files.has(t)) queue.push(t) + } + } + const dirs = new Set([...files].map((f) => dirname(f))) + if (missing.length) throw new Error(`not exported by @perfect-design/ui: ${missing.join(', ')}`) + const rel = (d) => relative(join(root, 'src/styles'), d).split('\\').join('/') + const lines = [...dirs] + .map(rel) + .sort() + .map((d) => `@source "${d}/*.js";`) + return lines +} + +if (import.meta.url === `file://${process.argv[1]}`) { + const root = resolve(dirname(fileURLToPath(import.meta.url)), '..') + const lines = librarySources(root) + if (process.argv.includes('--write')) { + const css = join(root, 'src/styles/main.css') + const kept = readFileSync(css, 'utf8') + .split('\n') + .filter((l) => !l.startsWith('@source ')) + const at = kept.findIndex((l) => l.startsWith('/* Only the library components')) + kept.splice(at + 1, 0, ...lines) + writeFileSync(css, kept.join('\n')) + } else { + console.log(lines.join('\n')) + } +} diff --git a/frontend/src/App.vue b/frontend/src/App.vue index 64981d8..9895115 100644 --- a/frontend/src/App.vue +++ b/frontend/src/App.vue @@ -1,61 +1,49 @@ -