diff --git a/packages/nc-gui-v2/nuxt.config.ts b/packages/nc-gui-v2/nuxt.config.ts index 23843c0966..461777dcee 100644 --- a/packages/nc-gui-v2/nuxt.config.ts +++ b/packages/nc-gui-v2/nuxt.config.ts @@ -1,6 +1,7 @@ import path from 'path' import { defineNuxtConfig } from 'nuxt' import vueI18n from '@intlify/vite-plugin-vue-i18n' +import Icons from 'unplugin-icons/vite' // https://v3.nuxtjs.org/api/configuration/nuxt.config export default defineNuxtConfig({ @@ -28,6 +29,10 @@ export default defineNuxtConfig({ vueI18n({ include: path.resolve(__dirname, './lang'), }), + Icons({ + autoInstall: true, + compiler: 'vue3', + }), ], define: { 'process.env.DEBUG': 'false', diff --git a/packages/nc-gui-v2/package-lock.json b/packages/nc-gui-v2/package-lock.json index 6ba79e8399..f3f975c593 100644 --- a/packages/nc-gui-v2/package-lock.json +++ b/packages/nc-gui-v2/package-lock.json @@ -18,10 +18,13 @@ }, "devDependencies": { "@antfu/eslint-config": "^0.25.2", + "@iconify-json/material-symbols": "^1.1.8", "@intlify/vite-plugin-vue-i18n": "^4.0.0", + "@vue/compiler-sfc": "^3.2.37", "@vueuse/nuxt": "^8.6.0", "nuxt": "3.0.0-rc.4", - "sass": "^1.53.0" + "sass": "^1.53.0", + "unplugin-icons": "^0.14.7" } }, "../nocodb-sdk": { @@ -162,6 +165,98 @@ "eslint": ">=7.4.0" } }, + "node_modules/@antfu/install-pkg": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/@antfu/install-pkg/-/install-pkg-0.1.0.tgz", + "integrity": "sha512-VaIJd3d1o7irZfK1U0nvBsHMyjkuyMP3HKYVV53z8DKyulkHKmjhhtccXO51WSPeeSHIeoJEoNOKavYpS7jkZw==", + "dev": true, + "dependencies": { + "execa": "^5.1.1", + "find-up": "^5.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/antfu" + } + }, + "node_modules/@antfu/install-pkg/node_modules/find-up": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", + "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", + "dev": true, + "dependencies": { + "locate-path": "^6.0.0", + "path-exists": "^4.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@antfu/install-pkg/node_modules/locate-path": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", + "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", + "dev": true, + "dependencies": { + "p-locate": "^5.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@antfu/install-pkg/node_modules/p-limit": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", + "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", + "dev": true, + "dependencies": { + "yocto-queue": "^0.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@antfu/install-pkg/node_modules/p-locate": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", + "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", + "dev": true, + "dependencies": { + "p-limit": "^3.0.2" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@antfu/install-pkg/node_modules/path-exists": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", + "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/@antfu/utils": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/@antfu/utils/-/utils-0.5.2.tgz", + "integrity": "sha512-CQkeV+oJxUazwjlHD0/3ZD08QWKuGQkhnrKo3e6ly5pd48VUpXbb77q0xMU4+vc2CkJnDS02Eq/M9ugyX20XZA==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/antfu" + } + }, "node_modules/@babel/code-frame": { "version": "7.16.7", "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.16.7.tgz", @@ -749,6 +844,35 @@ "integrity": "sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA==", "peer": true }, + "node_modules/@iconify-json/material-symbols": { + "version": "1.1.8", + "resolved": "https://registry.npmjs.org/@iconify-json/material-symbols/-/material-symbols-1.1.8.tgz", + "integrity": "sha512-RJlqCJJjntQQzTe+nbv1/aTMkEtrkGO30CYOAdSIhxyIox32IGHQqvySTXYjAOMwpQrmwbCHwnJjxDTLc6kISw==", + "dev": true, + "dependencies": { + "@iconify/types": "*" + } + }, + "node_modules/@iconify/types": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@iconify/types/-/types-1.1.0.tgz", + "integrity": "sha512-Jh0llaK2LRXQoYsorIH8maClebsnzTcve+7U3rQUSnC11X4jtPnFuyatqFLvMxZ8MLG8dB4zfHsbPfuvxluONw==", + "dev": true + }, + "node_modules/@iconify/utils": { + "version": "1.0.33", + "resolved": "https://registry.npmjs.org/@iconify/utils/-/utils-1.0.33.tgz", + "integrity": "sha512-vGeAqo7aGPxOQmGdVoXFUOuyN+0V7Lcrx2EvaiRjxUD1x6Om0Tvq2bdm7E24l2Pz++4S0mWMCVFXe/17EtKImQ==", + "dev": true, + "dependencies": { + "@antfu/install-pkg": "^0.1.0", + "@antfu/utils": "^0.5.0", + "@iconify/types": "^1.1.0", + "debug": "^4.3.4", + "kolorist": "^1.5.1", + "local-pkg": "^0.4.1" + } + }, "node_modules/@intlify/bundle-utils": { "version": "2.2.2", "resolved": "https://registry.npmjs.org/@intlify/bundle-utils/-/bundle-utils-2.2.2.tgz", @@ -10414,6 +10538,76 @@ } } }, + "node_modules/unplugin-icons": { + "version": "0.14.7", + "resolved": "https://registry.npmjs.org/unplugin-icons/-/unplugin-icons-0.14.7.tgz", + "integrity": "sha512-TrNnEdpaXMdiG5BsCgvU6cv/gSLYvIk1f8wGCGZmOo4wmi3nqYBuqIEuiXhmmyXdDZuRRpCaOzCnCYYZ5H7U8g==", + "dev": true, + "dependencies": { + "@antfu/install-pkg": "^0.1.0", + "@antfu/utils": "^0.5.2", + "@iconify/utils": "^1.0.33", + "debug": "^4.3.4", + "kolorist": "^1.5.1", + "local-pkg": "^0.4.1", + "unplugin": "^0.7.0" + }, + "funding": { + "url": "https://github.com/sponsors/antfu" + }, + "peerDependencies": { + "@svgr/core": ">=5.5.0", + "@vue/compiler-sfc": "^3.0.2", + "vue-template-compiler": "^2.6.12", + "vue-template-es2015-compiler": "^1.9.0" + }, + "peerDependenciesMeta": { + "@svgr/core": { + "optional": true + }, + "@vue/compiler-sfc": { + "optional": true + }, + "vue-template-compiler": { + "optional": true + }, + "vue-template-es2015-compiler": { + "optional": true + } + } + }, + "node_modules/unplugin-icons/node_modules/unplugin": { + "version": "0.7.1", + "resolved": "https://registry.npmjs.org/unplugin/-/unplugin-0.7.1.tgz", + "integrity": "sha512-Z6hNDXDNh9aimMkPU1mEjtk+2ova8gh0y7rJeJdGH1vWZOHwF2lLQiQ/R97rv9ymmzEQXsR2fyMet72T8jy6ew==", + "dev": true, + "dependencies": { + "acorn": "^8.7.1", + "chokidar": "^3.5.3", + "webpack-sources": "^3.2.3", + "webpack-virtual-modules": "^0.4.4" + }, + "peerDependencies": { + "esbuild": ">=0.13", + "rollup": "^2.50.0", + "vite": "^2.3.0 || ^3.0.0-0", + "webpack": "4 || 5" + }, + "peerDependenciesMeta": { + "esbuild": { + "optional": true + }, + "rollup": { + "optional": true + }, + "vite": { + "optional": true + }, + "webpack": { + "optional": true + } + } + }, "node_modules/unstorage": { "version": "0.5.2", "resolved": "https://registry.npmjs.org/unstorage/-/unstorage-0.5.2.tgz", @@ -11070,6 +11264,18 @@ "node": ">=12" } }, + "node_modules/yocto-queue": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", + "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/zip-stream": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/zip-stream/-/zip-stream-4.1.0.tgz", @@ -11168,6 +11374,67 @@ "eslint-plugin-vue": "^9.0.1" } }, + "@antfu/install-pkg": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/@antfu/install-pkg/-/install-pkg-0.1.0.tgz", + "integrity": "sha512-VaIJd3d1o7irZfK1U0nvBsHMyjkuyMP3HKYVV53z8DKyulkHKmjhhtccXO51WSPeeSHIeoJEoNOKavYpS7jkZw==", + "dev": true, + "requires": { + "execa": "^5.1.1", + "find-up": "^5.0.0" + }, + "dependencies": { + "find-up": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", + "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", + "dev": true, + "requires": { + "locate-path": "^6.0.0", + "path-exists": "^4.0.0" + } + }, + "locate-path": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", + "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", + "dev": true, + "requires": { + "p-locate": "^5.0.0" + } + }, + "p-limit": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", + "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", + "dev": true, + "requires": { + "yocto-queue": "^0.1.0" + } + }, + "p-locate": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", + "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", + "dev": true, + "requires": { + "p-limit": "^3.0.2" + } + }, + "path-exists": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", + "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", + "dev": true + } + } + }, + "@antfu/utils": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/@antfu/utils/-/utils-0.5.2.tgz", + "integrity": "sha512-CQkeV+oJxUazwjlHD0/3ZD08QWKuGQkhnrKo3e6ly5pd48VUpXbb77q0xMU4+vc2CkJnDS02Eq/M9ugyX20XZA==", + "dev": true + }, "@babel/code-frame": { "version": "7.16.7", "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.16.7.tgz", @@ -11604,6 +11871,35 @@ "integrity": "sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA==", "peer": true }, + "@iconify-json/material-symbols": { + "version": "1.1.8", + "resolved": "https://registry.npmjs.org/@iconify-json/material-symbols/-/material-symbols-1.1.8.tgz", + "integrity": "sha512-RJlqCJJjntQQzTe+nbv1/aTMkEtrkGO30CYOAdSIhxyIox32IGHQqvySTXYjAOMwpQrmwbCHwnJjxDTLc6kISw==", + "dev": true, + "requires": { + "@iconify/types": "*" + } + }, + "@iconify/types": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@iconify/types/-/types-1.1.0.tgz", + "integrity": "sha512-Jh0llaK2LRXQoYsorIH8maClebsnzTcve+7U3rQUSnC11X4jtPnFuyatqFLvMxZ8MLG8dB4zfHsbPfuvxluONw==", + "dev": true + }, + "@iconify/utils": { + "version": "1.0.33", + "resolved": "https://registry.npmjs.org/@iconify/utils/-/utils-1.0.33.tgz", + "integrity": "sha512-vGeAqo7aGPxOQmGdVoXFUOuyN+0V7Lcrx2EvaiRjxUD1x6Om0Tvq2bdm7E24l2Pz++4S0mWMCVFXe/17EtKImQ==", + "dev": true, + "requires": { + "@antfu/install-pkg": "^0.1.0", + "@antfu/utils": "^0.5.0", + "@iconify/types": "^1.1.0", + "debug": "^4.3.4", + "kolorist": "^1.5.1", + "local-pkg": "^0.4.1" + } + }, "@intlify/bundle-utils": { "version": "2.2.2", "resolved": "https://registry.npmjs.org/@intlify/bundle-utils/-/bundle-utils-2.2.2.tgz", @@ -18592,6 +18888,35 @@ "webpack-virtual-modules": "^0.4.3" } }, + "unplugin-icons": { + "version": "0.14.7", + "resolved": "https://registry.npmjs.org/unplugin-icons/-/unplugin-icons-0.14.7.tgz", + "integrity": "sha512-TrNnEdpaXMdiG5BsCgvU6cv/gSLYvIk1f8wGCGZmOo4wmi3nqYBuqIEuiXhmmyXdDZuRRpCaOzCnCYYZ5H7U8g==", + "dev": true, + "requires": { + "@antfu/install-pkg": "^0.1.0", + "@antfu/utils": "^0.5.2", + "@iconify/utils": "^1.0.33", + "debug": "^4.3.4", + "kolorist": "^1.5.1", + "local-pkg": "^0.4.1", + "unplugin": "^0.7.0" + }, + "dependencies": { + "unplugin": { + "version": "0.7.1", + "resolved": "https://registry.npmjs.org/unplugin/-/unplugin-0.7.1.tgz", + "integrity": "sha512-Z6hNDXDNh9aimMkPU1mEjtk+2ova8gh0y7rJeJdGH1vWZOHwF2lLQiQ/R97rv9ymmzEQXsR2fyMet72T8jy6ew==", + "dev": true, + "requires": { + "acorn": "^8.7.1", + "chokidar": "^3.5.3", + "webpack-sources": "^3.2.3", + "webpack-virtual-modules": "^0.4.4" + } + } + } + }, "unstorage": { "version": "0.5.2", "resolved": "https://registry.npmjs.org/unstorage/-/unstorage-0.5.2.tgz", @@ -19060,6 +19385,12 @@ "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.0.1.tgz", "integrity": "sha512-9BK1jFpLzJROCI5TzwZL/TU4gqjK5xiHV/RfWLOahrjAko/e4DJkRDZQXfvqAsiZzzYhgAzbgz6lg48jcm4GLg==" }, + "yocto-queue": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", + "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==", + "dev": true + }, "zip-stream": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/zip-stream/-/zip-stream-4.1.0.tgz", diff --git a/packages/nc-gui-v2/package.json b/packages/nc-gui-v2/package.json index c610b50fb4..39c32bd3a3 100644 --- a/packages/nc-gui-v2/package.json +++ b/packages/nc-gui-v2/package.json @@ -9,10 +9,13 @@ }, "devDependencies": { "@antfu/eslint-config": "^0.25.2", + "@iconify-json/material-symbols": "^1.1.8", "@intlify/vite-plugin-vue-i18n": "^4.0.0", + "@vue/compiler-sfc": "^3.2.37", "@vueuse/nuxt": "^8.6.0", "nuxt": "3.0.0-rc.4", - "sass": "^1.53.0" + "sass": "^1.53.0", + "unplugin-icons": "^0.14.7" }, "dependencies": { "@vueuse/core": "^8.7.5", diff --git a/packages/nc-gui-v2/tsconfig.json b/packages/nc-gui-v2/tsconfig.json index 3dfea5b1ff..d5b92e6fe8 100644 --- a/packages/nc-gui-v2/tsconfig.json +++ b/packages/nc-gui-v2/tsconfig.json @@ -10,7 +10,7 @@ "noUnusedLocals": false, "strictNullChecks": true, "forceConsistentCasingInFileNames": true, - "types": ["@intlify/vite-plugin-vue-i18n/client", "vue-i18n"] + "types": ["@intlify/vite-plugin-vue-i18n/client", "vue-i18n", "unplugin-icons/types/vue"] }, "files": ["nuxt-shim.d.ts"], "exclude": [