diff --git a/components.json b/components.json new file mode 100644 index 0000000..71ab3bf --- /dev/null +++ b/components.json @@ -0,0 +1,23 @@ +{ + "$schema": "https://shadcn-vue.com/schema.json", + "style": "new-york", + "font": "roboto", + "typescript": true, + "tailwind": { + "config": "", + "css": "src/style.css", + "baseColor": "stone", + "cssVariables": true, + "prefix": "" + }, + "iconLibrary": "lucide", + "rtl": false, + "aliases": { + "components": "@/components", + "utils": "@/lib/utils", + "ui": "@/components/ui", + "lib": "@/lib", + "composables": "@/composables" + }, + "registries": {} +} diff --git a/package-lock.json b/package-lock.json index 857936f..2ff7793 100644 --- a/package-lock.json +++ b/package-lock.json @@ -10,8 +10,13 @@ "dependencies": { "@headlessui/vue": "^1.7.23", "@vueuse/core": "^14.2.1", + "@zumer/snapdom": "^2.8.0", + "class-variance-authority": "^0.7.1", + "clsx": "^2.1.1", "lucide-vue-next": "^1.0.0", "pinia": "^3.0.4", + "reka-ui": "^2.9.6", + "tailwind-merge": "^3.5.0", "vue": "^3.5.31", "vue-i18n": "^11.3.2", "vue-router": "^5.0.4", @@ -38,6 +43,7 @@ "prettier": "3.8.1", "sharp": "^0.34.5", "tailwindcss": "^4.2.2", + "tw-animate-css": "^1.4.0", "typescript": "~6.0.0", "vite": "^7.3.2", "vite-plugin-vue-devtools": "^8.1.1", @@ -1193,6 +1199,68 @@ } } }, + "node_modules/@floating-ui/core": { + "version": "1.7.5", + "resolved": "https://registry.npmjs.org/@floating-ui/core/-/core-1.7.5.tgz", + "integrity": "sha512-1Ih4WTWyw0+lKyFMcBHGbb5U5FtuHJuujoyyr5zTaWS5EYMeT6Jb2AuDeftsCsEuchO+mM2ij5+q9crhydzLhQ==", + "license": "MIT", + "dependencies": { + "@floating-ui/utils": "^0.2.11" + } + }, + "node_modules/@floating-ui/dom": { + "version": "1.7.6", + "resolved": "https://registry.npmjs.org/@floating-ui/dom/-/dom-1.7.6.tgz", + "integrity": "sha512-9gZSAI5XM36880PPMm//9dfiEngYoC6Am2izES1FF406YFsjvyBMmeJ2g4SAju3xWwtuynNRFL2s9hgxpLI5SQ==", + "license": "MIT", + "dependencies": { + "@floating-ui/core": "^1.7.5", + "@floating-ui/utils": "^0.2.11" + } + }, + "node_modules/@floating-ui/utils": { + "version": "0.2.11", + "resolved": "https://registry.npmjs.org/@floating-ui/utils/-/utils-0.2.11.tgz", + "integrity": "sha512-RiB/yIh78pcIxl6lLMG0CgBXAZ2Y0eVHqMPYugu+9U0AeT6YBeiJpf7lbdJNIugFP5SIjwNRgo4DhR1Qxi26Gg==", + "license": "MIT" + }, + "node_modules/@floating-ui/vue": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/@floating-ui/vue/-/vue-1.1.11.tgz", + "integrity": "sha512-HzHKCNVxnGS35r9fCHBc3+uCnjw9IWIlCPL683cGgM9Kgj2BiAl8x1mS7vtvP6F9S/e/q4O6MApwSHj8hNLGfw==", + "license": "MIT", + "dependencies": { + "@floating-ui/dom": "^1.7.6", + "@floating-ui/utils": "^0.2.11", + "vue-demi": ">=0.13.0" + } + }, + "node_modules/@floating-ui/vue/node_modules/vue-demi": { + "version": "0.14.10", + "resolved": "https://registry.npmjs.org/vue-demi/-/vue-demi-0.14.10.tgz", + "integrity": "sha512-nMZBOwuzabUO0nLgIcc6rycZEebF6eeUfaiQx9+WSk8e29IbLvPU9feI6tqW4kTo3hvoYAJkMh8n8D0fuISphg==", + "hasInstallScript": true, + "license": "MIT", + "bin": { + "vue-demi-fix": "bin/vue-demi-fix.js", + "vue-demi-switch": "bin/vue-demi-switch.js" + }, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/antfu" + }, + "peerDependencies": { + "@vue/composition-api": "^1.0.0-rc.1", + "vue": "^3.0.0-0 || ^2.6.0" + }, + "peerDependenciesMeta": { + "@vue/composition-api": { + "optional": true + } + } + }, "node_modules/@headlessui/vue": { "version": "1.7.23", "license": "MIT", @@ -1740,6 +1808,24 @@ "url": "https://opencollective.com/libvips" } }, + "node_modules/@internationalized/date": { + "version": "3.12.1", + "resolved": "https://registry.npmjs.org/@internationalized/date/-/date-3.12.1.tgz", + "integrity": "sha512-6IedsVWXyq4P9Tj+TxuU8WGWM70hYLl12nbYU8jkikVpa6WXapFazPUcHUMDMoWftIDE2ILDkFFte6W2nFCkRQ==", + "license": "Apache-2.0", + "dependencies": { + "@swc/helpers": "^0.5.0" + } + }, + "node_modules/@internationalized/number": { + "version": "3.6.6", + "resolved": "https://registry.npmjs.org/@internationalized/number/-/number-3.6.6.tgz", + "integrity": "sha512-iFgmQaXHE0vytNfpLZWOC2mEJCBRzcUxt53Xf/yCXG93lRvqas237i3r7X4RKMwO3txiyZD4mQjKAByFv6UGSQ==", + "license": "Apache-2.0", + "dependencies": { + "@swc/helpers": "^0.5.0" + } + }, "node_modules/@intlify/core-base": { "version": "11.3.2", "resolved": "https://registry.npmjs.org/@intlify/core-base/-/core-base-11.3.2.tgz", @@ -2580,6 +2666,15 @@ "dev": true, "license": "MIT" }, + "node_modules/@swc/helpers": { + "version": "0.5.21", + "resolved": "https://registry.npmjs.org/@swc/helpers/-/helpers-0.5.21.tgz", + "integrity": "sha512-jI/VAmtdjB/RnI8GTnokyX7Ug8c+g+ffD6QRLa6XQewtnGyukKkKSk3wLTM3b5cjt1jNh9x0jfVlagdN2gDKQg==", + "license": "Apache-2.0", + "dependencies": { + "tslib": "^2.8.0" + } + }, "node_modules/@tailwindcss/node": { "version": "4.2.2", "dev": true, @@ -2913,6 +3008,8 @@ }, "node_modules/@types/node": { "version": "24.12.2", + "resolved": "https://registry.npmjs.org/@types/node/-/node-24.12.2.tgz", + "integrity": "sha512-A1sre26ke7HDIuY/M23nd9gfB+nrmhtYyMINbjI1zHJxYteKR6qSMX56FsmjMcDb3SMcjJg5BiRRgOCC/yBD0g==", "dev": true, "license": "MIT", "dependencies": { @@ -3627,6 +3724,8 @@ }, "node_modules/@vueuse/core": { "version": "14.2.1", + "resolved": "https://registry.npmjs.org/@vueuse/core/-/core-14.2.1.tgz", + "integrity": "sha512-3vwDzV+GDUNpdegRY6kzpLm4Igptq+GA0QkJ3W61Iv27YWwW/ufSlOfgQIpN6FZRMG0mkaz4gglJRtq5SeJyIQ==", "license": "MIT", "dependencies": { "@types/web-bluetooth": "^0.0.21", @@ -3657,6 +3756,15 @@ "vue": "^3.5.0" } }, + "node_modules/@zumer/snapdom": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/@zumer/snapdom/-/snapdom-2.8.0.tgz", + "integrity": "sha512-NhztgFDNfOkFt8Ox9PIJ1IwggyMui5UDazysOgZD7FSGL0G7H8U+J3ft0iecxAS8daj5aC62i3blaTk7s2GcpA==", + "license": "MIT", + "workspaces": [ + "packages/*" + ] + }, "node_modules/abbrev": { "version": "2.0.0", "dev": true, @@ -3733,6 +3841,18 @@ "node": ">=14" } }, + "node_modules/aria-hidden": { + "version": "1.2.6", + "resolved": "https://registry.npmjs.org/aria-hidden/-/aria-hidden-1.2.6.tgz", + "integrity": "sha512-ik3ZgC9dY/lYVVM++OISsaYDeg1tb0VtP5uL3ouh1koGOaUMDPpbFIei4JkFimWUFPn90sbMNMXQAIVOlnYKJA==", + "license": "MIT", + "dependencies": { + "tslib": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/assertion-error": { "version": "2.0.1", "dev": true, @@ -3916,6 +4036,27 @@ "url": "https://paulmillr.com/funding/" } }, + "node_modules/class-variance-authority": { + "version": "0.7.1", + "resolved": "https://registry.npmjs.org/class-variance-authority/-/class-variance-authority-0.7.1.tgz", + "integrity": "sha512-Ka+9Trutv7G8M6WT6SeiRWz792K5qEqIGEGzXKhAE6xOWAY6pPH8U+9IY3oCMv6kqTmLsv7Xh/2w2RigkePMsg==", + "license": "Apache-2.0", + "dependencies": { + "clsx": "^2.1.1" + }, + "funding": { + "url": "https://polar.sh/cva" + } + }, + "node_modules/clsx": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/clsx/-/clsx-2.1.1.tgz", + "integrity": "sha512-eYm0QWBtUrBWZWG0d386OGAw16Z995PiOVo2B7bjWSbHedGl5e0ZWaq65kOGgUSNesEIDkB9ISbTg/JK9dhCZA==", + "license": "MIT", + "engines": { + "node": ">=6" + } + }, "node_modules/color-convert": { "version": "2.0.1", "dev": true, @@ -4086,6 +4227,12 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/defu": { + "version": "6.1.7", + "resolved": "https://registry.npmjs.org/defu/-/defu-6.1.7.tgz", + "integrity": "sha512-7z22QmUWiQ/2d0KkdYmANbRUVABpZ9SNYyH5vx6PZ+nE5bcC0l7uFvEfHlyld/HcGBFTL536ClDt3DEcSlEJAQ==", + "license": "MIT" + }, "node_modules/detect-libc": { "version": "2.1.2", "dev": true, @@ -5298,6 +5445,8 @@ }, "node_modules/lucide-vue-next": { "version": "1.0.0", + "resolved": "https://registry.npmjs.org/lucide-vue-next/-/lucide-vue-next-1.0.0.tgz", + "integrity": "sha512-V6SPvx1IHTj/UY+FrIYWV5faISsPSb8BnWSFDxAtezWKvWc9ZZ40PDrdu1/Qb5vg4lHWr1hs1BAMGVGm6V1Xdg==", "license": "ISC", "peerDependencies": { "vue": ">=3.0.1" @@ -5549,7 +5698,6 @@ }, "node_modules/ohash": { "version": "2.0.11", - "dev": true, "license": "MIT" }, "node_modules/open": { @@ -5904,6 +6052,31 @@ "url": "https://paulmillr.com/funding/" } }, + "node_modules/reka-ui": { + "version": "2.9.6", + "resolved": "https://registry.npmjs.org/reka-ui/-/reka-ui-2.9.6.tgz", + "integrity": "sha512-K6bL457owpvWONc7hsjFxo3HDC9s6IzhRqShW0w9JSKelPGfRbkHD558UQTn/NH1cvrXVHygKyC7fExFmRketg==", + "license": "MIT", + "dependencies": { + "@floating-ui/dom": "^1.6.13", + "@floating-ui/vue": "^1.1.6", + "@internationalized/date": "^3.5.0", + "@internationalized/number": "^3.5.0", + "@tanstack/vue-virtual": "^3.12.0", + "@vueuse/core": "^14.1.0", + "@vueuse/shared": "^14.1.0", + "aria-hidden": "^1.2.4", + "defu": "^6.1.5", + "ohash": "^2.0.11" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/zernonia" + }, + "peerDependencies": { + "vue": ">= 3.4.0" + } + }, "node_modules/require-from-string": { "version": "2.0.2", "dev": true, @@ -6258,6 +6431,16 @@ "dev": true, "license": "MIT" }, + "node_modules/tailwind-merge": { + "version": "3.5.0", + "resolved": "https://registry.npmjs.org/tailwind-merge/-/tailwind-merge-3.5.0.tgz", + "integrity": "sha512-I8K9wewnVDkL1NTGoqWmVEIlUcB9gFriAEkXkfCjX5ib8ezGxtR3xD7iZIxrfArjEsH7F1CHD4RFUtxefdqV/A==", + "license": "MIT", + "funding": { + "type": "github", + "url": "https://github.com/sponsors/dcastil" + } + }, "node_modules/tailwindcss": { "version": "4.2.2", "dev": true, @@ -6407,9 +6590,17 @@ "version": "2.8.1", "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz", "integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==", + "license": "0BSD" + }, + "node_modules/tw-animate-css": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/tw-animate-css/-/tw-animate-css-1.4.0.tgz", + "integrity": "sha512-7bziOlRqH0hJx80h/3mbicLW7o8qLsH5+RaLR2t+OHM3D0JlWGODQKQ4cxbK7WlvmUxpcj6Kgu6EKqjrGFe3QQ==", "dev": true, - "license": "0BSD", - "optional": true + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/Wombosvideo" + } }, "node_modules/type-check": { "version": "0.4.0", diff --git a/package.json b/package.json index 6153d09..f3dc17f 100644 --- a/package.json +++ b/package.json @@ -12,8 +12,13 @@ "dependencies": { "@headlessui/vue": "^1.7.23", "@vueuse/core": "^14.2.1", + "@zumer/snapdom": "^2.8.0", + "class-variance-authority": "^0.7.1", + "clsx": "^2.1.1", "lucide-vue-next": "^1.0.0", "pinia": "^3.0.4", + "reka-ui": "^2.9.6", + "tailwind-merge": "^3.5.0", "vue": "^3.5.31", "vue-i18n": "^11.3.2", "vue-router": "^5.0.4", @@ -40,6 +45,7 @@ "prettier": "3.8.1", "sharp": "^0.34.5", "tailwindcss": "^4.2.2", + "tw-animate-css": "^1.4.0", "typescript": "~6.0.0", "vite": "^7.3.2", "vite-plugin-vue-devtools": "^8.1.1", diff --git a/scripts/check-i18n.mjs b/scripts/check-i18n.mjs index 78fb804..412f6f7 100644 --- a/scripts/check-i18n.mjs +++ b/scripts/check-i18n.mjs @@ -7,13 +7,13 @@ const jiti = createJiti(import.meta.url) const LOCALE_PAIRS = [ { name: 'text', - zhPath: resolve('src/locales/text/zh-CN.ts'), - enPath: resolve('src/locales/text/en-US.ts'), + zhPath: resolve('src/i18n/locales/text/zh-CN.ts'), + enPath: resolve('src/i18n/locales/text/en-US.ts'), }, { name: 'questions', - zhPath: resolve('src/locales/questions/zh-CN.ts'), - enPath: resolve('src/locales/questions/en-US.ts'), + zhPath: resolve('src/i18n/locales/questions/zh-CN.ts'), + enPath: resolve('src/i18n/locales/questions/en-US.ts'), }, ] diff --git a/src/App.vue b/src/App.vue index 1f962ec..533dc05 100644 --- a/src/App.vue +++ b/src/App.vue @@ -1,5 +1,5 @@