From e7dce2dd6709ccd7bba1a0e6c8282dd0b03db2d7 Mon Sep 17 00:00:00 2001 From: Julian <79840527+ace-of-aces@users.noreply.github.com> Date: Wed, 25 Oct 2023 13:31:50 +0200 Subject: [PATCH] feat: add iconify API configuration option (#111) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Sébastien Chopin --- README.md | 17 ++ package.json | 2 +- pnpm-lock.yaml | 389 +++++----------------------------------- src/module.ts | 16 ++ src/runtime/Icon.vue | 32 +++- src/runtime/IconCSS.vue | 22 ++- 6 files changed, 127 insertions(+), 351 deletions(-) diff --git a/README.md b/README.md index bc35aa3..a998051 100644 --- a/README.md +++ b/README.md @@ -110,6 +110,23 @@ The icons will have the default size of `24px` and the `nuxt` icon will be avail ``` +By default, this module will fetch the Icons from [the official Iconify API](https://api.iconify.design). You can change this behavior by setting the `nuxtIcon.iconifyApiOptions.url` property to [your own Iconify API](https://iconify.design/docs/api/hosting.html). + +You can also set `nuxtIcon.iconifyApiOptions.publicApiFallback` to `true` to use the public API as a fallback (only for the `` component, not for the `` component`) + +```ts +// app.config.ts +export default defineAppConfig({ + nuxtIcon: { + // ... + iconifyApiOptions: { + url: 'https://', + publicApiFallback: true // default: false + } + } +}) +``` + ## Render Function You can use the `Icon` component in a render function (useful if you create a functional component), for this you can import it from `#components`: diff --git a/package.json b/package.json index 2ca52bd..ca44aa3 100644 --- a/package.json +++ b/package.json @@ -30,7 +30,7 @@ "@nuxt/kit": "^3.8.0" }, "devDependencies": { - "@nuxt/devtools": "^0.8.5", + "@nuxt/devtools": "^1.0.0", "@nuxt/eslint-config": "^0.2.0", "@nuxt/module-builder": "latest", "@types/node": "^20.8.8", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 8e1ad99..329a77e 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -14,14 +14,14 @@ dependencies: devDependencies: '@nuxt/devtools': - specifier: ^0.8.5 - version: 0.8.5(nuxt@3.8.0)(rollup@3.25.3)(vite@4.3.9) + specifier: ^1.0.0 + version: 1.0.0(nuxt@3.8.0)(rollup@3.25.3)(vite@4.5.0) '@nuxt/eslint-config': specifier: ^0.2.0 version: 0.2.0(eslint@8.46.0) '@nuxt/module-builder': specifier: latest - version: 0.4.0(@nuxt/kit@3.8.0)(nuxi@3.6.5) + version: 0.4.0(@nuxt/kit@3.8.0)(nuxi@3.9.1) '@types/node': specifier: ^20.8.8 version: 20.8.8 @@ -30,7 +30,7 @@ devDependencies: version: 8.46.0 nuxt: specifier: ^3.8.0 - version: 3.8.0(@types/node@20.8.8)(eslint@8.46.0)(rollup@3.25.3)(typescript@5.2.2)(vite@4.3.9)(vue-tsc@1.8.21) + version: 3.8.0(@types/node@20.8.8)(eslint@8.46.0)(rollup@3.25.3)(typescript@5.2.2)(vite@4.5.0)(vue-tsc@1.8.21) release-it: specifier: ^16.2.1 version: 16.2.1(typescript@5.2.2) @@ -288,11 +288,6 @@ packages: '@babel/types': 7.22.5 dev: true - /@babel/helper-plugin-utils@7.21.5: - resolution: {integrity: sha512-0WDaIlXKOX/3KfBK/dwP1oQGiPh6rjMkT7HIRv7i5RR2VUMwrx5ZL0dwBkKx7+SW1zwNdgjHd34IMk5ZjTeHVg==} - engines: {node: '>=6.9.0'} - dev: true - /@babel/helper-plugin-utils@7.22.5: resolution: {integrity: sha512-uLls06UVKgFG9QD4OeFYLEGteMIAa5kpTPcFL28yuCIIzsf6ZyKZMllKVOCZFhiZ5ptnwX4mtKdWCBE/uT4amg==} engines: {node: '>=6.9.0'} @@ -456,17 +451,7 @@ packages: '@babel/core': ^7.0.0-0 dependencies: '@babel/core': 7.23.2 - '@babel/helper-plugin-utils': 7.21.5 - dev: true - - /@babel/plugin-syntax-jsx@7.21.4(@babel/core@7.23.2): - resolution: {integrity: sha512-5hewiLct5OKyh6PLKEYaFclcqtIgCb6bmELouxjF6up5q3Sov7rOayW4RwhbaBL0dit8rA80GNfY+UuDp2mBbQ==} - engines: {node: '>=6.9.0'} - peerDependencies: - '@babel/core': ^7.0.0-0 - dependencies: - '@babel/core': 7.23.2 - '@babel/helper-plugin-utils': 7.21.5 + '@babel/helper-plugin-utils': 7.22.5 dev: true /@babel/plugin-syntax-jsx@7.22.5(@babel/core@7.23.2): @@ -1225,16 +1210,6 @@ packages: resolution: {integrity: sha512-k2Ty1JcVojjJFwrg/ThKi2ujJ7XNLYaFGNB/bWT9wGR+oSMJHMa5w+CUq6p/pVrKeNNgA7pCqEcjSnHVoqJQFw==} dev: true - /@hapi/hoek@9.3.0: - resolution: {integrity: sha512-/c6rf4UJlmHlC9b5BaNvzAcFv7HZ2QHaV0D4/HNlBdvFnvQq8RI4kYdhyPCl7Xj+oWvTWQ8ujhqS53LIgAe6KQ==} - dev: true - - /@hapi/topo@5.1.0: - resolution: {integrity: sha512-foQZKJig7Ob0BMAYBfcJk8d77QtOe7Wo4ox7ff1lQYoNNAb6jwcY1ncdoy2e9wQZzvNy7ODZCYJkK8kzmcAnAg==} - dependencies: - '@hapi/hoek': 9.3.0 - dev: true - /@humanwhocodes/config-array@0.11.10: resolution: {integrity: sha512-KVVjQmNUepDVGXNuoRRdmmEjruj0KfiGSbS8LVc12LMsWDQzRXJ0qdhN8L8uUigKpfEHRhlaQFY0ib1tnUbNeQ==} engines: {node: '>=10.10.0'} @@ -1282,7 +1257,7 @@ packages: dependencies: string-width: 5.1.2 string-width-cjs: /string-width@4.2.3 - strip-ansi: 7.0.1 + strip-ansi: 7.1.0 strip-ansi-cjs: /strip-ansi@6.0.1 wrap-ansi: 8.1.0 wrap-ansi-cjs: /wrap-ansi@7.0.0 @@ -1407,7 +1382,7 @@ packages: http-proxy-agent: 7.0.0 https-proxy-agent: 7.0.2 lru-cache: 10.0.1 - socks-proxy-agent: 8.0.1 + socks-proxy-agent: 8.0.2 transitivePeerDependencies: - supports-color dev: true @@ -1491,23 +1466,7 @@ packages: resolution: {integrity: sha512-GBzP8zOc7CGWyFQS6dv1lQz8VVpz5C2yRszbXufwG/9zhStTIH50EtD87NmWbTMwXDvZLNg8GIpb1UFdH93JCA==} dev: true - /@nuxt/devtools-kit@0.8.5(nuxt@3.8.0)(rollup@3.25.3)(vite@4.3.9): - resolution: {integrity: sha512-gkZuythYbx6ybwQc2zE1DC40B3cj3rrSxHG6GIihWseilTea7G4QMkDliEbGnqyM4cLQmMBD+SU4DxiDVSNlQQ==} - peerDependencies: - nuxt: ^3.7.3 - vite: '*' - dependencies: - '@nuxt/kit': 3.8.0(rollup@3.25.3) - '@nuxt/schema': 3.8.0(rollup@3.25.3) - execa: 7.2.0 - nuxt: 3.8.0(@types/node@20.8.8)(eslint@8.46.0)(rollup@3.25.3)(typescript@5.2.2)(vite@4.3.9)(vue-tsc@1.8.21) - vite: 4.3.9(@types/node@20.8.8) - transitivePeerDependencies: - - rollup - - supports-color - dev: true - - /@nuxt/devtools-kit@1.0.0(nuxt@3.8.0)(rollup@3.25.3)(vite@4.3.9): + /@nuxt/devtools-kit@1.0.0(nuxt@3.8.0)(rollup@3.25.3)(vite@4.5.0): resolution: {integrity: sha512-cNloBepQYCBW6x/ctfCvyYRZudxhfgh5w5JDswpCzn7KXmm8U6abG2jyT0FXIaceW1d5QYMpGCN1RUw24wSvOA==} peerDependencies: nuxt: ^3.7.4 @@ -1516,29 +1475,13 @@ packages: '@nuxt/kit': 3.8.0(rollup@3.25.3) '@nuxt/schema': 3.8.0(rollup@3.25.3) execa: 7.2.0 - nuxt: 3.8.0(@types/node@20.8.8)(eslint@8.46.0)(rollup@3.25.3)(typescript@5.2.2)(vite@4.3.9)(vue-tsc@1.8.21) - vite: 4.3.9(@types/node@20.8.8) + nuxt: 3.8.0(@types/node@20.8.8)(eslint@8.46.0)(rollup@3.25.3)(typescript@5.2.2)(vite@4.5.0)(vue-tsc@1.8.21) + vite: 4.5.0(@types/node@20.8.8) transitivePeerDependencies: - rollup - supports-color dev: true - /@nuxt/devtools-wizard@0.8.5: - resolution: {integrity: sha512-4QbI4SgzKJrJTWmObsgUAM5wZ0vlYAy0eNTpXsc2aMQZkpmb74ebY9yvgyz9e5tLOvPOjZNUkFYNmun5uy3QRA==} - hasBin: true - dependencies: - consola: 3.2.3 - diff: 5.1.0 - execa: 7.2.0 - global-dirs: 3.0.1 - magicast: 0.3.0 - pathe: 1.1.1 - pkg-types: 1.0.3 - prompts: 2.4.2 - rc9: 2.1.1 - semver: 7.5.4 - dev: true - /@nuxt/devtools-wizard@1.0.0: resolution: {integrity: sha512-9OeZM2/Y4VuI06gdlDjmYM8yUzdfnywy4t2u2VAEfA2Lk7vk3U1lYn51IAqr+Gits9tp/Q9OiktMWmPLLNGgFw==} hasBin: true @@ -1555,61 +1498,7 @@ packages: semver: 7.5.4 dev: true - /@nuxt/devtools@0.8.5(nuxt@3.8.0)(rollup@3.25.3)(vite@4.3.9): - resolution: {integrity: sha512-xNogUcv257gj/1NreQ0TiS7SqalHRoDYkPM5zaBbimBtUa7tlmtpbI/VpFrkpVbHOvBpPWk8JMMFkIDScYyMyw==} - hasBin: true - peerDependencies: - nuxt: ^3.7.3 - vite: '*' - dependencies: - '@antfu/utils': 0.7.6 - '@nuxt/devtools-kit': 0.8.5(nuxt@3.8.0)(rollup@3.25.3)(vite@4.3.9) - '@nuxt/devtools-wizard': 0.8.5 - '@nuxt/kit': 3.8.0(rollup@3.25.3) - birpc: 0.2.14 - consola: 3.2.3 - error-stack-parser-es: 0.1.1 - execa: 7.2.0 - fast-glob: 3.3.1 - flatted: 3.2.9 - get-port-please: 3.1.1 - global-dirs: 3.0.1 - h3: 1.8.2 - hookable: 5.5.3 - image-meta: 0.1.1 - is-installed-globally: 0.4.0 - launch-editor: 2.6.0 - local-pkg: 0.4.3 - magicast: 0.3.0 - nuxt: 3.8.0(@types/node@20.8.8)(eslint@8.46.0)(rollup@3.25.3)(typescript@5.2.2)(vite@4.3.9)(vue-tsc@1.8.21) - nypm: 0.3.3 - ofetch: 1.3.3 - ohash: 1.1.3 - pacote: 17.0.4 - pathe: 1.1.1 - perfect-debounce: 1.0.0 - pkg-types: 1.0.3 - rc9: 2.1.1 - semver: 7.5.4 - simple-git: 3.20.0 - sirv: 2.0.3 - unimport: 3.4.0(rollup@3.25.3) - vite: 4.3.9(@types/node@20.8.8) - vite-plugin-inspect: 0.7.40(@nuxt/kit@3.8.0)(rollup@3.25.3)(vite@4.3.9) - vite-plugin-vue-inspector: 3.7.2(vite@4.3.9) - wait-on: 7.0.1 - which: 3.0.1 - ws: 8.14.2 - transitivePeerDependencies: - - bluebird - - bufferutil - - debug - - rollup - - supports-color - - utf-8-validate - dev: true - - /@nuxt/devtools@1.0.0(nuxt@3.8.0)(rollup@3.25.3)(vite@4.3.9): + /@nuxt/devtools@1.0.0(nuxt@3.8.0)(rollup@3.25.3)(vite@4.5.0): resolution: {integrity: sha512-pM5AvystXlFPYOsGbH8PBxEYkttiEWHsZnGw660iMw8QedB6mAweT21XX9LDS69cqnRY5uTFqVOmO9Y4EYL3hg==} hasBin: true peerDependencies: @@ -1617,7 +1506,7 @@ packages: vite: '*' dependencies: '@antfu/utils': 0.7.6 - '@nuxt/devtools-kit': 1.0.0(nuxt@3.8.0)(rollup@3.25.3)(vite@4.3.9) + '@nuxt/devtools-kit': 1.0.0(nuxt@3.8.0)(rollup@3.25.3)(vite@4.5.0) '@nuxt/devtools-wizard': 1.0.0 '@nuxt/kit': 3.8.0(rollup@3.25.3) birpc: 0.2.14 @@ -1637,7 +1526,7 @@ packages: local-pkg: 0.5.0 magicast: 0.3.0 nitropack: 2.7.0 - nuxt: 3.8.0(@types/node@20.8.8)(eslint@8.46.0)(rollup@3.25.3)(typescript@5.2.2)(vite@4.3.9)(vue-tsc@1.8.21) + nuxt: 3.8.0(@types/node@20.8.8)(eslint@8.46.0)(rollup@3.25.3)(typescript@5.2.2)(vite@4.5.0)(vue-tsc@1.8.21) nypm: 0.3.3 ofetch: 1.3.3 ohash: 1.1.3 @@ -1651,9 +1540,9 @@ packages: simple-git: 3.20.0 sirv: 2.0.3 unimport: 3.4.0(rollup@3.25.3) - vite: 4.3.9(@types/node@20.8.8) - vite-plugin-inspect: 0.7.40(@nuxt/kit@3.8.0)(rollup@3.25.3)(vite@4.3.9) - vite-plugin-vue-inspector: 4.0.0(vite@4.3.9) + vite: 4.5.0(@types/node@20.8.8) + vite-plugin-inspect: 0.7.40(@nuxt/kit@3.8.0)(rollup@3.25.3)(vite@4.5.0) + vite-plugin-vue-inspector: 4.0.0(vite@4.5.0) which: 3.0.1 ws: 8.14.2 transitivePeerDependencies: @@ -1718,7 +1607,7 @@ packages: - rollup - supports-color - /@nuxt/module-builder@0.4.0(@nuxt/kit@3.8.0)(nuxi@3.6.5): + /@nuxt/module-builder@0.4.0(@nuxt/kit@3.8.0)(nuxi@3.9.1): resolution: {integrity: sha512-B+UAYgFV1Hkc2ZcD7GaiKZ3SNHhyxFlXzZoBWTc9ulE0Z/+rq6RTa9fNm13BZyGhVhDCl5FN/wF/yYa1O/D2iw==} hasBin: true peerDependencies: @@ -1729,7 +1618,7 @@ packages: consola: 3.2.2 mlly: 1.4.0 mri: 1.2.0 - nuxi: 3.6.5 + nuxi: 3.9.1 pathe: 1.1.1 unbuild: 1.2.1 transitivePeerDependencies: @@ -2055,6 +1944,7 @@ packages: dependencies: is-glob: 4.0.3 micromatch: 4.0.5 + napi-wasm: 1.1.0 dev: true bundledDependencies: - napi-wasm @@ -2406,20 +2296,6 @@ packages: resolution: {integrity: sha512-6i/8UoL0P5y4leBIGzvkZdS85RDMG9y1ihZzmTZQ5LdHUYmZ7pKFoj8X0236s3lusPs1Fa5HTQUpwI+UfTcmeA==} dev: true - /@sideway/address@4.1.4: - resolution: {integrity: sha512-7vwq+rOHVWjyXxVlR76Agnvhy8I9rpzjosTESvmhNeXOXdZZB15Fl+TI9x1SiHZH5Jv2wTGduSxFDIaq0m3DUw==} - dependencies: - '@hapi/hoek': 9.3.0 - dev: true - - /@sideway/formula@3.0.1: - resolution: {integrity: sha512-/poHZJJVjx3L+zVD6g9KgHfYnb443oi7wLu/XKojDviHy6HOEOA6z1Trk5aR1dGcmPenJEgb2sK2I80LeS3MIg==} - dev: true - - /@sideway/pinpoint@2.0.0: - resolution: {integrity: sha512-RNiOoTPkptFtSVzQevY/yWtZwf/RxyVnPy/OcA9HBM3MlGDnBEYL5B41H0MTn0Uec8Hi+2qUtTfG2WWZBmMejQ==} - dev: true - /@sigstore/bundle@2.1.0: resolution: {integrity: sha512-89uOo6yh/oxaU8AeOUnVrTdVMcGk9Q1hJa7Hkvalc6G3Z3CupWk4Xe9djSgJm9fMkH69s0P0cVHUoKSOemLdng==} engines: {node: ^16.14.0 || >=18.0.0} @@ -2779,31 +2655,10 @@ packages: - rollup dev: true - /@vue/babel-helper-vue-transform-on@1.0.2: - resolution: {integrity: sha512-hz4R8tS5jMn8lDq6iD+yWL6XNB699pGIVLk7WSJnn1dbpjaazsjZQkieJoRX6gW5zpYSCFqQ7jUquPNY65tQYA==} - dev: true - /@vue/babel-helper-vue-transform-on@1.1.5: resolution: {integrity: sha512-SgUymFpMoAyWeYWLAY+MkCK3QEROsiUnfaw5zxOVD/M64KQs8D/4oK6Q5omVA2hnvEOE0SCkH2TZxs/jnnUj7w==} dev: true - /@vue/babel-plugin-jsx@1.1.1(@babel/core@7.23.2): - resolution: {integrity: sha512-j2uVfZjnB5+zkcbc/zsOc0fSNGCMMjaEXP52wdwdIfn0qjFfEYpYZBFKFg+HHnQeJCVrjOeO0YxgaL7DMrym9w==} - dependencies: - '@babel/helper-module-imports': 7.21.4 - '@babel/plugin-syntax-jsx': 7.21.4(@babel/core@7.23.2) - '@babel/template': 7.20.7 - '@babel/traverse': 7.21.5 - '@babel/types': 7.22.5 - '@vue/babel-helper-vue-transform-on': 1.0.2 - camelcase: 6.3.0 - html-tags: 3.3.1 - svg-tags: 1.0.0 - transitivePeerDependencies: - - '@babel/core' - - supports-color - dev: true - /@vue/babel-plugin-jsx@1.1.5(@babel/core@7.23.2): resolution: {integrity: sha512-nKs1/Bg9U1n3qSWnsHhCVQtAzI6aQXqua8j/bZrau8ywT1ilXQbK4FwEJGmU8fV7tcpuFvWmmN7TMmV1OBma1g==} peerDependencies: @@ -3176,10 +3031,6 @@ packages: resolution: {integrity: sha512-iAB+JbDEGXhyIUavoDl9WP/Jj106Kz9DEn1DPgYw5ruDn0e3Wgi3sKFm55sASdGBNOQB8F59d9qQ7deqrHA8wQ==} dev: true - /asynckit@0.4.0: - resolution: {integrity: sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==} - dev: true - /autoprefixer@10.4.16(postcss@8.4.31): resolution: {integrity: sha512-7vd3UC6xKp0HLfua5IjZlcXvGAGy7cBAXTg2lyQ/8WpNhd6SiZ8Be+xm3FyBSYJx5GKcpRCzBh7RH4/0dnY+uQ==} engines: {node: ^10 || ^12 || >=14} @@ -3201,15 +3052,6 @@ packages: engines: {node: '>= 0.4'} dev: true - /axios@0.27.2: - resolution: {integrity: sha512-t+yRIyySRTp/wua5xEr+z1q60QmLq8ABsS5O9Me1AsE5dfKqgnCFzwiCZZ/cGNd1lq4/7akDWMxdhVlucjmnOQ==} - dependencies: - follow-redirects: 1.15.2 - form-data: 4.0.0 - transitivePeerDependencies: - - debug - dev: true - /b4a@1.6.4: resolution: {integrity: sha512-fpWrvyVHEKyeEvbKZTVOeZF3VSKKWtJxFIxX/jaVPf+cLbGUSitjb49pHLqPV2BUNNZ0LcoeEGfE/YCpyDYHIw==} dev: true @@ -3413,7 +3255,7 @@ packages: promise-inflight: 1.0.1 rimraf: 3.0.2 ssri: 9.0.1 - tar: 6.1.15 + tar: 6.2.0 unique-filename: 2.0.1 transitivePeerDependencies: - bluebird @@ -3433,7 +3275,7 @@ packages: minipass-pipeline: 1.2.4 p-map: 4.0.0 ssri: 10.0.4 - tar: 6.1.15 + tar: 6.2.0 unique-filename: 3.0.0 dev: true @@ -3538,7 +3380,7 @@ packages: normalize-path: 3.0.0 readdirp: 3.6.0 optionalDependencies: - fsevents: 2.3.2 + fsevents: 2.3.3 /chownr@2.0.0: resolution: {integrity: sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ==} @@ -3652,13 +3494,6 @@ packages: /colorette@2.0.20: resolution: {integrity: sha512-IfEDxwoWIjkeXL1eXcDiow4UbKjhLdq6/EuSVR9GMN7KVH3r9gQ83e73hsz1Nd1T3ijd5xv1wcWRYO+D6kCI2w==} - /combined-stream@1.0.8: - resolution: {integrity: sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==} - engines: {node: '>= 0.8'} - dependencies: - delayed-stream: 1.0.0 - dev: true - /commander@2.20.3: resolution: {integrity: sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==} dev: true @@ -4033,11 +3868,6 @@ packages: esprima: 4.0.1 dev: true - /delayed-stream@1.0.0: - resolution: {integrity: sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==} - engines: {node: '>=0.4.0'} - dev: true - /delegates@1.0.0: resolution: {integrity: sha512-bd2L678uiWATM6m5Z1VzNCErI3jiGzt6HGY8OVICs40JQq/HALfbyNJmp0UDakEY4pMMaN0Ly5om/B1VI/+xfQ==} dev: true @@ -4729,16 +4559,6 @@ packages: resolution: {integrity: sha512-36yxDn5H7OFZQla0/jFJmbIKTdZAQHngCedGxiMmpNfEZM0sdEeT+WczLQrjK6D7o2aiyLYDnkw0R3JK0Qv1RQ==} dev: true - /follow-redirects@1.15.2: - resolution: {integrity: sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA==} - engines: {node: '>=4.0'} - peerDependencies: - debug: '*' - peerDependenciesMeta: - debug: - optional: true - dev: true - /for-each@0.3.3: resolution: {integrity: sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==} dependencies: @@ -4750,7 +4570,7 @@ packages: engines: {node: '>=14'} dependencies: cross-spawn: 7.0.3 - signal-exit: 4.0.2 + signal-exit: 4.1.0 dev: true /form-data-encoder@2.1.4: @@ -4758,15 +4578,6 @@ packages: engines: {node: '>= 14.17'} dev: true - /form-data@4.0.0: - resolution: {integrity: sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==} - engines: {node: '>= 6'} - dependencies: - asynckit: 0.4.0 - combined-stream: 1.0.8 - mime-types: 2.1.35 - dev: true - /formdata-polyfill@4.0.10: resolution: {integrity: sha512-buewHzMvYL29jdeQTVILecSaZKnt/RJWjoZCF5OW60Z67/GmSLBkOFM7qh1PI3zFNtJbaZL5eQu1vLfazOwj4g==} engines: {node: '>=12.20.0'} @@ -4818,19 +4629,11 @@ packages: resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==} dev: true - /fsevents@2.3.2: - resolution: {integrity: sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==} - engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} - os: [darwin] - requiresBuild: true - optional: true - /fsevents@2.3.3: resolution: {integrity: sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==} engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} os: [darwin] requiresBuild: true - dev: true optional: true /function-bind@1.1.1: @@ -4997,7 +4800,7 @@ packages: dependencies: foreground-child: 3.1.1 jackspeak: 2.2.0 - minimatch: 9.0.0 + minimatch: 9.0.3 minipass: 5.0.0 path-scurry: 1.9.2 dev: true @@ -5341,7 +5144,7 @@ packages: resolution: {integrity: sha512-C7FfFoTA+bI10qfeydT8aZbvr91vAEU+2W5BZUlzPec47oNb07SsOfwYrtxuvOYdUApPP/Qlh4DtAO51Ekk2QA==} engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} dependencies: - minimatch: 9.0.0 + minimatch: 9.0.3 dev: true /ignore@5.2.4: @@ -5794,16 +5597,6 @@ packages: resolution: {integrity: sha512-3TV69ZbrvV6U5DfQimop50jE9Dl6J8O1ja1dvBbMba/sZ3YBEQqJ2VZRoQPVnhlzjNtU1vaXRZVrVjU4qtm8yA==} hasBin: true - /joi@17.9.2: - resolution: {integrity: sha512-Itk/r+V4Dx0V3c7RLFdRh12IOjySm2/WGPMubBT92cQvRfYZhPM2W0hZlctjj72iES8jsRCwp7S/cRmWBnJ4nw==} - dependencies: - '@hapi/hoek': 9.3.0 - '@hapi/topo': 5.1.0 - '@sideway/address': 4.1.4 - '@sideway/formula': 3.0.1 - '@sideway/pinpoint': 2.0.0 - dev: true - /js-tokens@4.0.0: resolution: {integrity: sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==} @@ -5897,13 +5690,6 @@ packages: package-json: 8.1.0 dev: true - /launch-editor@2.6.0: - resolution: {integrity: sha512-JpDCcQnyAAzZZaZ7vEiSqL690w7dAEyLao+KC96zBplnYbJS7TYNjvM3M7y3dGz+v7aIsJk3hllWuc0kWAjyRQ==} - dependencies: - picocolors: 1.0.0 - shell-quote: 1.8.1 - dev: true - /launch-editor@2.6.1: resolution: {integrity: sha512-eB/uXmFVpY4zezmGp5XtU21kwo7GBbKB+EQ+UZeWtGb9yAM5xt/Evk+lYH3eRNAtId+ej4u7TYPFZ07w4s7rRw==} dependencies: @@ -6271,13 +6057,6 @@ packages: brace-expansion: 2.0.1 dev: true - /minimatch@9.0.0: - resolution: {integrity: sha512-0jJj8AvgKqWN05mrwuqi8QYKx1WmYSUoKSxu5Qhs9prezTz10sxAHGNZe9J9cqIJzta8DWsleh2KaVaLl6Ru2w==} - engines: {node: '>=16 || 14 >=14.17'} - dependencies: - brace-expansion: 2.0.1 - dev: true - /minimatch@9.0.3: resolution: {integrity: sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg==} engines: {node: '>=16 || 14 >=14.17'} @@ -6452,6 +6231,10 @@ packages: hasBin: true dev: true + /napi-wasm@1.1.0: + resolution: {integrity: sha512-lHwIAJbmLSjF9VDRm9GoVOy9AGp3aIvkjv+Kvz9h16QR3uSVYH78PNQUnT2U4X53mhlnV2M7wrhibQ3GHicDmg==} + dev: true + /natural-compare@1.4.0: resolution: {integrity: sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==} dev: true @@ -6618,7 +6401,7 @@ packages: npmlog: 6.0.2 rimraf: 3.0.2 semver: 7.5.4 - tar: 6.1.15 + tar: 6.2.0 which: 2.0.2 transitivePeerDependencies: - bluebird @@ -6772,14 +6555,6 @@ packages: boolbase: 1.0.0 dev: true - /nuxi@3.6.5: - resolution: {integrity: sha512-4XEXYz71UiWWiKC1/cJCzqRSUEImYRmjcvKpSsBKMU58ALYVSx5KIoas5SwLO8tEKO5BS4DAe4u7MYix7hfuHQ==} - engines: {node: ^14.18.0 || >=16.10.0} - hasBin: true - optionalDependencies: - fsevents: 2.3.2 - dev: true - /nuxi@3.9.1: resolution: {integrity: sha512-4R4tcC2uQ5QCnHxyKoX5nZm/YUesCcQM3bZBKYU/8ZWrWjK6aPG6Q5zOQG1aLPkAotyahNsqtSiU/CrRoenEgA==} engines: {node: ^14.18.0 || >=16.10.0} @@ -6788,7 +6563,7 @@ packages: fsevents: 2.3.3 dev: true - /nuxt@3.8.0(@types/node@20.8.8)(eslint@8.46.0)(rollup@3.25.3)(typescript@5.2.2)(vite@4.3.9)(vue-tsc@1.8.21): + /nuxt@3.8.0(@types/node@20.8.8)(eslint@8.46.0)(rollup@3.25.3)(typescript@5.2.2)(vite@4.5.0)(vue-tsc@1.8.21): resolution: {integrity: sha512-ZnisJYx5AcUl7xlw18m6zfINBpNhld+ZF+jdTLRZxkLjKSFZeFMGqKxOR1jNVSmxfIXM/guK0uV9GPm6HK/z7g==} engines: {node: ^14.18.0 || >=16.10.0} hasBin: true @@ -6802,7 +6577,7 @@ packages: optional: true dependencies: '@nuxt/devalue': 2.0.2 - '@nuxt/devtools': 1.0.0(nuxt@3.8.0)(rollup@3.25.3)(vite@4.3.9) + '@nuxt/devtools': 1.0.0(nuxt@3.8.0)(rollup@3.25.3)(vite@4.5.0) '@nuxt/kit': 3.8.0(rollup@3.25.3) '@nuxt/schema': 3.8.0(rollup@3.25.3) '@nuxt/telemetry': 2.5.2(rollup@3.25.3) @@ -7135,7 +6910,7 @@ packages: read-package-json-fast: 3.0.2 sigstore: 2.1.0 ssri: 10.0.4 - tar: 6.1.15 + tar: 6.2.0 transitivePeerDependencies: - bluebird - supports-color @@ -7951,7 +7726,7 @@ packages: rollup: 3.25.3 typescript: 5.2.2 optionalDependencies: - '@babel/code-frame': 7.21.4 + '@babel/code-frame': 7.22.13 dev: true /rollup-plugin-visualizer@5.9.2(rollup@3.25.3): @@ -7993,14 +7768,14 @@ packages: engines: {node: '>=14.18.0', npm: '>=8.0.0'} hasBin: true optionalDependencies: - fsevents: 2.3.2 + fsevents: 2.3.3 /rollup@3.29.4: resolution: {integrity: sha512-oWzmBZwvYrU0iJHtDmhsm662rC15FRXmcjCk1xD771dFDx5jJ02ufAQQTn0etB2emNk4J9EZg/yWKpsn9BWGRw==} engines: {node: '>=14.18.0', npm: '>=8.0.0'} hasBin: true optionalDependencies: - fsevents: 2.3.2 + fsevents: 2.3.3 dev: true /run-applescript@5.0.0: @@ -8191,11 +7966,6 @@ packages: resolution: {integrity: sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==} dev: true - /signal-exit@4.0.2: - resolution: {integrity: sha512-MY2/qGx4enyjprQnFaZsHib3Yadh3IXyV2C321GY0pjGfVBu4un0uDJkwgdxqO+Rdx8JMT8IfJIRwbYVz3Ob3Q==} - engines: {node: '>=14'} - dev: true - /signal-exit@4.1.0: resolution: {integrity: sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==} engines: {node: '>=14'} @@ -8265,17 +8035,6 @@ packages: - supports-color dev: true - /socks-proxy-agent@8.0.1: - resolution: {integrity: sha512-59EjPbbgg8U3x62hhKOFVAmySQUcfRQ4C7Q/D5sEHnZTQRrQlNKINks44DMR1gwXp0p4LaVIeccX2KHTTcHVqQ==} - engines: {node: '>= 14'} - dependencies: - agent-base: 7.1.0 - debug: 4.3.4 - socks: 2.7.1 - transitivePeerDependencies: - - supports-color - dev: true - /socks-proxy-agent@8.0.2: resolution: {integrity: sha512-8zuqoLv1aP/66PHF5TqwJ7Czm3Yv32urJQHrVyhD7mmA6d61Zv8cIXQYPTWwmg6qlupnPvs/QKDmfa4P/qct2g==} engines: {node: '>= 14'} @@ -9209,7 +8968,7 @@ packages: vue-tsc: 1.8.21(typescript@5.2.2) dev: true - /vite-plugin-inspect@0.7.40(@nuxt/kit@3.8.0)(rollup@3.25.3)(vite@4.3.9): + /vite-plugin-inspect@0.7.40(@nuxt/kit@3.8.0)(rollup@3.25.3)(vite@4.5.0): resolution: {integrity: sha512-tsfva6MCg0ch6ckReWHvJ/9xf/zjTuJvakONf2qcMBB/iu9JqiRixfxMa/yLGrlNaBe6fUZHOVhtN2Me3Kthow==} engines: {node: '>=14'} peerDependencies: @@ -9228,32 +8987,13 @@ packages: open: 9.1.0 picocolors: 1.0.0 sirv: 2.0.3 - vite: 4.3.9(@types/node@20.8.8) + vite: 4.5.0(@types/node@20.8.8) transitivePeerDependencies: - rollup - supports-color dev: true - /vite-plugin-vue-inspector@3.7.2(vite@4.3.9): - resolution: {integrity: sha512-PSe/t2RoVzB64Ofuec7W/Z0FuKHzmU7esLrMOGwX+BNyXt8dAMtYbz4wL/TqoH1zVPDdjQecQpM5+K9VnBYpAg==} - peerDependencies: - vite: ^3.0.0-0 || ^4.0.0-0 - dependencies: - '@babel/core': 7.23.2 - '@babel/plugin-proposal-decorators': 7.23.2(@babel/core@7.23.2) - '@babel/plugin-syntax-import-attributes': 7.22.5(@babel/core@7.23.2) - '@babel/plugin-syntax-import-meta': 7.10.4(@babel/core@7.23.2) - '@babel/plugin-transform-typescript': 7.22.15(@babel/core@7.23.2) - '@vue/babel-plugin-jsx': 1.1.1(@babel/core@7.23.2) - '@vue/compiler-dom': 3.3.4 - kolorist: 1.8.0 - magic-string: 0.30.2 - vite: 4.3.9(@types/node@20.8.8) - transitivePeerDependencies: - - supports-color - dev: true - - /vite-plugin-vue-inspector@4.0.0(vite@4.3.9): + /vite-plugin-vue-inspector@4.0.0(vite@4.5.0): resolution: {integrity: sha512-xNjMbRj3YrebuuInTvlC8ghPtzT+3LjMIQPeeR/5CaFd+WcbA9wBnECZmlcP3GITCVED0SxGmTyoJ3iVKsK4vQ==} peerDependencies: vite: ^3.0.0-0 || ^4.0.0-0 @@ -9267,44 +9007,11 @@ packages: '@vue/compiler-dom': 3.3.4 kolorist: 1.8.0 magic-string: 0.30.5 - vite: 4.3.9(@types/node@20.8.8) + vite: 4.5.0(@types/node@20.8.8) transitivePeerDependencies: - supports-color dev: true - /vite@4.3.9(@types/node@20.8.8): - resolution: {integrity: sha512-qsTNZjO9NoJNW7KnOrgYwczm0WctJ8m/yqYAMAK9Lxt4SoySUfS5S8ia9K7JHpa3KEeMfyF8LoJ3c5NeBJy6pg==} - engines: {node: ^14.18.0 || >=16.0.0} - hasBin: true - peerDependencies: - '@types/node': '>= 14' - less: '*' - sass: '*' - stylus: '*' - sugarss: '*' - terser: ^5.4.0 - peerDependenciesMeta: - '@types/node': - optional: true - less: - optional: true - sass: - optional: true - stylus: - optional: true - sugarss: - optional: true - terser: - optional: true - dependencies: - '@types/node': 20.8.8 - esbuild: 0.17.19 - postcss: 8.4.24 - rollup: 3.25.3 - optionalDependencies: - fsevents: 2.3.2 - dev: true - /vite@4.5.0(@types/node@20.8.8): resolution: {integrity: sha512-ulr8rNLA6rkyFAlVWw2q5YJ91v098AFQ2R0PRFwPzREXOUJQPtFUG0t+/ZikhaOCDqFoDhN6/v8Sq0o4araFAw==} engines: {node: ^14.18.0 || >=16.0.0} @@ -9338,7 +9045,7 @@ packages: postcss: 8.4.31 rollup: 3.29.4 optionalDependencies: - fsevents: 2.3.2 + fsevents: 2.3.3 dev: true /vscode-jsonrpc@6.0.0: @@ -9446,20 +9153,6 @@ packages: '@vue/server-renderer': 3.3.4(vue@3.3.4) '@vue/shared': 3.3.4 - /wait-on@7.0.1: - resolution: {integrity: sha512-9AnJE9qTjRQOlTZIldAaf/da2eW0eSRSgcqq85mXQja/DW3MriHxkpODDSUEg+Gri/rKEcXUZHe+cevvYItaog==} - engines: {node: '>=12.0.0'} - hasBin: true - dependencies: - axios: 0.27.2 - joi: 17.9.2 - lodash: 4.17.21 - minimist: 1.2.8 - rxjs: 7.8.1 - transitivePeerDependencies: - - debug - dev: true - /wcwidth@1.0.1: resolution: {integrity: sha512-XHPEwS0q6TaxcvG85+8EYkbiCux2XtWG2mkc47Ng2A77BQu9+DqIOJldST4HgPkuea7dvKSj5VgX3P1d4rW8Tg==} dependencies: diff --git a/src/module.ts b/src/module.ts index a5d7889..7e52050 100644 --- a/src/module.ts +++ b/src/module.ts @@ -57,6 +57,22 @@ export default defineNuxtModule({ tsType: '{ [alias: string]: string }', }, }, + iconifyApiOptions: { + url: { + $default: 'https://api.iconify.design', + $schema: { + title: 'Iconify API URL', + description: 'Define a custom Iconify API URL. Useful if you want to use a self-hosted Iconify API. Learn more: https://iconify.design/docs/api/', + }, + }, + publicApiFallback: { + $default: false, + $schema: { + title: 'Public Iconify API fallback', + description: 'Define, if the public Iconify API should be used as fallback if the .', + }, + }, + }, }, }, }) diff --git a/src/runtime/Icon.vue b/src/runtime/Icon.vue index f6a78d9..d75e3ee 100644 --- a/src/runtime/Icon.vue +++ b/src/runtime/Icon.vue @@ -2,7 +2,7 @@