diff --git a/.eslintrc b/.eslintrc index 7ab680f4a..c1042c736 100644 --- a/.eslintrc +++ b/.eslintrc @@ -1,11 +1,10 @@ { "root": true, - "extends": [ - "@nuxtjs/eslint-config-typescript" - ], + "extends": ["@nuxtjs/eslint-config-typescript"], "rules": { "vue/multi-word-component-names": "off", "vue/no-multiple-template-root": "off", - "no-redeclare": "off" + "no-redeclare": "off", + "import/named": "off" } } diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7e7401787..0063c5863 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -22,7 +22,7 @@ jobs: - run: yarn dev:prepare - run: yarn lint - run: yarn build - - run: yarn test:unit + - run: yarn test - name: Release Edge if: | github.event_name == 'push' && diff --git a/docs/content/3.guide/1.writing/7.document-driven.md b/docs/content/3.guide/1.writing/7.document-driven.md new file mode 100644 index 000000000..8267b3934 --- /dev/null +++ b/docs/content/3.guide/1.writing/7.document-driven.md @@ -0,0 +1,139 @@ +--- +title: Document-driven +description: '@nuxt/content allows a new way of writing your website pages called Document-driven.' +--- + +Document-driven development gives a lot more power to Markdown-based pages. + +This mode creates a direct binding between your `content/` directory and your pages. + +It also offers `page`, `navigation`, `surround` and `globals` global variables. + +Let's dive into what this new @nuxt/content feature has to offer. + +## Global `page`, `surround` and `navigation` + +With this mode enabled, queries will be made from [route middlewares](https://v3.nuxtjs.org/guide/directory-structure/middleware#middleware-directory) and will be resolve before your page renders. + +That gives access to the [`useContent()`](/api/composables/use-document-driven) composable anywhere in your app. + +```ts + +``` + +--- + +## Layout binding + +Most of the content context of your project becomes globally available with Document-driven mode. + +This unlocks the capability of configuring your page layout from the front-matter. + +To do so, you only have to specify an available layout from your page front-matter: + +```md [my-page.md] +--- +layout: reversed +--- + +This page will use the reversed layout! +``` + +By default, the app will search for `default` layout if none is specified. + +If you want to use another layout, you might want to use `layoutFallbacks` key from the configuration: + +```ts [nuxt.config.ts] +export default defineNuxtConfig({ + content: { + documentDriven: { + layoutFallbacks: ['theme'], + } + } +}) +``` + +This configuration will search for a `theme` key in `globals`, then search for a `layout` key inside that global object. + +If it is found, that layout key will be used as a fallback. + +--- + +## Globally available queries + +This mode gives you a convenient way to access some files data globally in your app. + +To do so, you have to specify a query in your `documentDriven.globals` key of your module configuration: + +```ts [nuxt.config.ts] +export default defineNuxtConfig({ + content: { + documentDriven: { + globals: { + theme: { + where: [ + { + _id: 'content:_theme.yml' + } + ], + without: ['_'] + } + } + } + } +}) +``` + +This configuration will search for a `_theme.yml` file in the `content/` directory. + +If it is found, it'll add it as `globals.theme` key, accessible via `useContent().globals`. + +Any change to these files will be automatically reflected in the app, as any other file from @nuxt/content. + +--- + +## Catch-all page injection + +The Document-driven mode also ships with a pre-configured catch-all page. + +That bundled page is useful to keep your project structure ultra minimal when using Document-driven mode. + +Here is what your project can look like with this enabled: + +``` +my-project/ + content/ + nuxt.config.ts + package.json + tsconfig.json +``` + +It comes with a direct binding between your pages `title` and `description` to your OpenGraph tags. + +Also, it allows you to use `cover` key from front-matter to set the OpenGraph `og:image` and `twitter:image` tags. + +```md [my-page.md] +--- +cover: + src: /path/to/image.jpg + alt: "My Cover Image" +--- +``` + +### Page slots + +That page comes with 2 slot components, that you can replace at your project level. + +To do so, you only have to create a component with the same name in your project `components/` directory. + +#### `` + +This component will be shown when there is no content for the current page, but the page exists. + +#### `` + +This component will be shown when no page has been found for the current URL. diff --git a/docs/content/4.api/2.composables/4.use-document-driven.md b/docs/content/4.api/2.composables/4.use-document-driven.md new file mode 100644 index 000000000..4e19619b5 --- /dev/null +++ b/docs/content/4.api/2.composables/4.use-document-driven.md @@ -0,0 +1,84 @@ +--- +title: useContent() +--- + +::alert{type="warning"} +This composable will only be enabled if you toggle the [Document-driven](/guide/writing/document-driven) feature! +:: + +## Usage + +`useContent()`{lang="ts"} is available everywhere in your app and gives access to a list of refs based on your content. + +```ts + +``` + +## Examples + +### Rendering the page + +Rendering the current page becomes a bliss with this composable: + +```vue [pages/[...slug].vue] + + + +``` + +### Creating a previous/next page component + +```vue [PagePrevNext.vue] + + + +``` + +### Creating a Table of Contents component + +```vue [PageToc.vue] + + + +``` diff --git a/docs/content/4.api/2.composables/5.use-content-helpers.md b/docs/content/4.api/2.composables/5.use-content-helpers.md new file mode 100644 index 000000000..7a59fb66b --- /dev/null +++ b/docs/content/4.api/2.composables/5.use-content-helpers.md @@ -0,0 +1,80 @@ +--- +title: useContentHelpers() +--- + +## Usage + +`useContentHelpers()`{lang="ts"} is available everywhere in your app and gives access to helpers to interact with the navigation object. + +```ts + +``` + +### `navBottomLink()` + +This function will take a navigation node and will resolve the first available path from that node. + +It can be useful to build nested navigations systems. + +**Example:** + +```ts +const { navigation } = useContent() + +const path = navBottomLink(navigation.value) +``` + +### `navDirFromPath()` + +This function will take a path and will resolve the first available navigation node from that path. + +It can be useful to find the current directory of a navigation node. + +**Example:** + +```ts +const route = useRoute() + +const { navigation } = useContent() + +const dir = navDirFromPath(route.path, navigation.value) +``` + +### `navPageFromPath()` + +This function will take a path and will resolve the first available navigation page from that path. + +It can be useful to find the current navigation node the page you're browsing. + +**Example:** + +```ts +const route = useRoute() + +const { navigation } = useContent() + +const page = navPageFromPath(route.path, navigation.value) +``` + +### `navKeyFromPath()` + +This function will take a path and will resolve a specific key from that path. + +It can be useful when you want to add a fallback on the `_dir.yml` value of a key in a page. + +**Example:** + +```ts +const route = useRoute() + +const { navigation } = useContent() + +const layout = navKeyFromPath(route.path, 'layout', navigation.value) +``` diff --git a/docs/content/4.api/3.configuration.md b/docs/content/4.api/3.configuration.md index 6eac43711..37c7a274c 100644 --- a/docs/content/4.api/3.configuration.md +++ b/docs/content/4.api/3.configuration.md @@ -63,10 +63,10 @@ The watcher is a development feature and will not be included in production. ### `ws` options -| Option | Default | Description | -| ----------------- | :--------: | :-------- | -| `port` | `4000` | Select the port used for the WebSocket server. | -| `showUrl` | `false` | Toggle URL display in dev server boot message. | +| Option | Default | Description | +| --------- | :-----: | :--------------------------------------------- | +| `port` | `4000` | Select the port used for the WebSocket server. | +| `showUrl` | `false` | Toggle URL display in dev server boot message. | ## `sources` @@ -200,10 +200,10 @@ Nuxt Content uses [Shiki](https://github.com/shikijs/shiki) to provide syntax hi ### `highlight` options -| Option | Type | Description | -| ----------------- | :--------: | :-------- | -| `theme` | `ShikiTheme` or `Record` | The [color theme](https://github.com/shikijs/shiki/blob/main/docs/themes.md) to use. | -| `preload` | `ShikiLang[]` | The [preloaded languages](https://github.com/shikijs/shiki/blob/main/docs/languages.md) available for highlighting. | +| Option | Type | Description | +| --------- | :------------------------------------------: | :------------------------------------------------------------------------------------------------------------------ | +| `theme` | `ShikiTheme` or `Record` | The [color theme](https://github.com/shikijs/shiki/blob/main/docs/themes.md) to use. | +| `preload` | `ShikiLang[]` | The [preloaded languages](https://github.com/shikijs/shiki/blob/main/docs/languages.md) available for highlighting. | #### `highlight.theme` @@ -251,9 +251,9 @@ Can be set to `false` to disable the feature completely. ### `navigation` options -| Option | Type | Description | -| ----------------- | :--------: | :-------- | -| `fields` | `string[]` | A list of fields to inherit from front-matter to navigation nodes. | +| Option | Type | Description | +| -------- | :--------: | :----------------------------------------------------------------- | +| `fields` | `string[]` | A list of fields to inherit from front-matter to navigation nodes. | ## `locales` @@ -268,3 +268,47 @@ List of locale codes. This codes will be used to detect contents locale. - Default: `undefined`{lang=ts} Default locale for top level contents. Module will use first locale code from `locales` array if this option is not defined. + +## `documentDriven` + +- Type: `Boolean | Object`{lang=ts} +- Default: `false`{lang=ts} + +Toggles the document-driven mode. + +`false`{lang="ts"} will disable the feature completely. + +`true`{lang="ts"} will enable the feature with these defaults: + +```ts [Document-driven defaults] +{ + // Will fetch navigation, page and surround. + navigation: true, + page: true, + surround: true, + // Will fetch `content/_theme.yml` and put it in `globals.theme` if present. + globals: { + theme: { + where: { + _id: 'content:_theme.yml' + }, + without: ['_'] + } + }, + // Will use `theme` global to search for a fallback `layout` key. + layoutFallbacks: ['theme'], + // Will inject `[...slug].vue` as the root page. + injectPage: true +} +``` + +### `documentDriven` options + +| Option | Type | Description | +| ----------------- | :--------: | :------------------------------------------------------------- | +| `page` | `Boolean` | Enables the page binding, making it globally accessible. | +| `navigation` | `Boolean` | Enables the navigation binding, making it globally accessible. | +| `surround` | `Boolean` | Enables the surround binding, making it globally accessible. | +| `globals` | `Object \| Boolean` | A list of globals to be made available globally. | +| `layoutFallbacks` | `string[]` | A list of `globals` key to use to find a layout fallback. | +| `injectPage` | `boolean` | Inject `[...slug].vue` pre-configured page | diff --git a/docs/content/5.examples/6.document-driven/1.hello-world.md b/docs/content/5.examples/6.document-driven/1.hello-world.md new file mode 100644 index 000000000..877d2b82b --- /dev/null +++ b/docs/content/5.examples/6.document-driven/1.hello-world.md @@ -0,0 +1,9 @@ +--- +title: Hello world +--- + +::ReadMore{link="/guide/writing/document-driven"} +:: + +::sandbox{repo="nuxt/content" branch="main" dir="examples/document-driven" file="index.md"} +:: diff --git a/docs/content/5.examples/6.document-driven/_dir.yml b/docs/content/5.examples/6.document-driven/_dir.yml new file mode 100644 index 000000000..da5980ef1 --- /dev/null +++ b/docs/content/5.examples/6.document-driven/_dir.yml @@ -0,0 +1,2 @@ +title: Document-driven +icon: heroicons-outline:cube diff --git a/docs/yarn.lock b/docs/yarn.lock index f30b51332..2d432ab5e 100644 --- a/docs/yarn.lock +++ b/docs/yarn.lock @@ -280,10 +280,10 @@ resolved "https://registry.yarnpkg.com/@csstools/selector-specificity/-/selector-specificity-2.0.1.tgz#b6b8d81780b9a9f6459f4bfe9226ac6aefaefe87" integrity sha512-aG20vknL4/YjQF9BSV7ts4EWm/yrjagAN7OWBNmlbEOUiu0llj4OGrFoOKK3g2vey4/p2omKCoHrWtPxSwV3HA== -"@docus/base@npm:@docus/base-edge@3.0.0-4720f14": - version "3.0.0-4720f14" - resolved "https://registry.yarnpkg.com/@docus/base-edge/-/base-edge-3.0.0-4720f14.tgz#885672113edd1a1206cd6a596e269fbbff66db80" - integrity sha512-yhldmqQb8jdBMFhPDX9N4s5arkZu0G3wKY0/Q+II23iEAS1534wzHHNXiDyxfxwR2v1X5q/Jpg7JDSS7tX3d2g== +"@docus/base@npm:@docus/base-edge@3.0.0-cc82b14": + version "3.0.0-cc82b14" + resolved "https://registry.yarnpkg.com/@docus/base-edge/-/base-edge-3.0.0-cc82b14.tgz#8a570fd5eca8425375fa96c69e7d6fd2195fc3ab" + integrity sha512-b0xqyqYDwXrcGiqQI8rtwgiHSXmRvC16pWk/8KfS/5YDcmQRRskWb+1tlffnr8X+G8GLInRrq/mywNKrLnwcBA== dependencies: "@nuxt/content" "npm:@nuxt/content-edge@latest" "@nuxthq/admin" "npm:@nuxthq/admin-edge@latest" @@ -294,11 +294,11 @@ pkg-types "^0.3.2" "@docus/docs-theme@npm:@docus/docs-theme-edge@latest": - version "3.0.0-4720f14" - resolved "https://registry.yarnpkg.com/@docus/docs-theme-edge/-/docs-theme-edge-3.0.0-4720f14.tgz#eec0f92160f83dac954cdc30e069e64283174e84" - integrity sha512-vb5mxVDQoeYsX4u9NrCuwvrP3F0jeKH0AMa+IBKlN6wza2HyRtthNk+GDFCxcUDXOg4RZAXEa37mDctsN21aOA== + version "3.0.0-cc82b14" + resolved "https://registry.yarnpkg.com/@docus/docs-theme-edge/-/docs-theme-edge-3.0.0-cc82b14.tgz#a29d37848023117e5ee65e224ab7dc406f0b73cb" + integrity sha512-IkG5/a82p3oFMIAHC5qmNDtMO8MaRHsM2PR5X6G84Pou9K8RFURxQN4nvj3pUyKz1rbYSDdnAG9pYxZw1QAeyw== dependencies: - "@docus/base" "npm:@docus/base-edge@3.0.0-4720f14" + "@docus/base" "npm:@docus/base-edge@3.0.0-cc82b14" "@iconify/vue" "^3.2.1" "@nuxtjs/color-mode" "^3.1.4" "@nuxtjs/tailwindcss" "^5.1.2" @@ -311,9 +311,9 @@ vue-plausible "^1.3.1" "@docus/github@npm:@docus/github-edge@latest": - version "1.2.6-4720f14" - resolved "https://registry.yarnpkg.com/@docus/github-edge/-/github-edge-1.2.6-4720f14.tgz#a48e75147eecf90e259c7e0ac10c2f27a406cc67" - integrity sha512-wsjsxAeRGisDzy0Gghw3wkeRb2dGHB/wduainYbJOSKCsQw3rJX3U3CkTFUEVY7qysvgaN2htBqqfrlxhDsNKA== + version "1.2.6-cc82b14" + resolved "https://registry.yarnpkg.com/@docus/github-edge/-/github-edge-1.2.6-cc82b14.tgz#eb92deec34a882f73666096264b0ad06b552c525" + integrity sha512-uooYOtaxx+PJ+J4wWTW2fUaRaku30m+/UB1fwF5G1uhykKmql0X1x/C/ALjiM1bUr0SQnijLBvxRYo40gO4gLA== dependencies: "@nuxt/kit" "^3.0.0-rc.4" "@octokit/graphql" "^4.8.0" @@ -452,9 +452,9 @@ fastq "^1.6.0" "@nuxt/content@npm:@nuxt/content-edge@latest": - version "2.0.1-27594175.6a05508" - resolved "https://registry.yarnpkg.com/@nuxt/content-edge/-/content-edge-2.0.1-27594175.6a05508.tgz#a46bbb0d530fa3c9e72765c36a50962b2f0576ce" - integrity sha512-nmSoH0AHqIbRZKGLLMcuLB1r+/00v8jStYaByRSsCtQAbjOuUKshY1K4LPLRL46Jf+TvZ0Oa3Q9BjnEL3c24Pg== + version "2.0.1-27597026.cfbad47" + resolved "https://registry.yarnpkg.com/@nuxt/content-edge/-/content-edge-2.0.1-27597026.cfbad47.tgz#a522963d14270ce60d1486a7d5992e2bd65b088f" + integrity sha512-fKDFLKHnBhhqzmjCtT3xFfgIGeIsVrI6nCBNhQyMFsiAnD5YXelr/afiqPu5zKQdhCYqoNrWI+0wOGiCgqTwmQ== dependencies: "@nuxt/kit" "^3.0.0-rc.4" csvtojson "^2.0.10" @@ -465,7 +465,7 @@ html-tags "^3.2.0" js-yaml "^4.1.0" json5 "^2.2.1" - listhen "^0.2.12" + listhen "^0.2.13" mdast-util-from-markdown "^1.2.0" mdast-util-to-hast "^12.1.1" mdast-util-to-markdown "^1.3.0" @@ -728,17 +728,17 @@ "@octokit/types" "^6.0.3" universal-user-agent "^6.0.0" -"@octokit/openapi-types@^12.1.0": - version "12.1.0" - resolved "https://registry.yarnpkg.com/@octokit/openapi-types/-/openapi-types-12.1.0.tgz#a68b60e969f26dee0eb7d127c65a84967f2d3a6e" - integrity sha512-kQzJh3ZUv3lDpi6M+uekMRHULvf9DlWoI1XgKN6nPeGDzkSgtkhVq1MMz3bFKQ6H6GbdC3ZqG/a6VzKhIx0VeA== +"@octokit/openapi-types@^12.4.0": + version "12.4.0" + resolved "https://registry.yarnpkg.com/@octokit/openapi-types/-/openapi-types-12.4.0.tgz#fd8bf5db72bd566c5ba2cb76754512a9ebe66e71" + integrity sha512-Npcb7Pv30b33U04jvcD7l75yLU0mxhuX2Xqrn51YyZ5WTkF04bpbxLaZ6GcaTqu03WZQHoO/Gbfp95NGRueDUA== "@octokit/plugin-paginate-rest@^2.16.8": - version "2.18.0" - resolved "https://registry.yarnpkg.com/@octokit/plugin-paginate-rest/-/plugin-paginate-rest-2.18.0.tgz#e412977782690a4134b0a4aa2f536cca7a2ca125" - integrity sha512-n5/AzIoy5Wzp85gqzSbR+dWQDHlyHZrGijnDfLh452547Ynu0hCvszH7EfRE0eqM5ZjfkplO0k+q+P8AAIIJEA== + version "2.19.0" + resolved "https://registry.yarnpkg.com/@octokit/plugin-paginate-rest/-/plugin-paginate-rest-2.19.0.tgz#b52eae6ecacfa1f5583dc2cc0985cfbed3ca78b0" + integrity sha512-hQ4Qysg2hNmEMuZeJkvyzM4eSZiTifOKqYAMsW8FnxFKowhuwWICSgBQ9Gn9GpUmgKB7qaf1hFvMjYaTAg5jQA== dependencies: - "@octokit/types" "^6.35.0" + "@octokit/types" "^6.36.0" "@octokit/plugin-request-log@^1.0.4": version "1.0.4" @@ -746,11 +746,11 @@ integrity sha512-mLUsMkgP7K/cnFEw07kWqXGF5LKrOkD+lhCrKvPHXWDywAwuDUeDwWBpc69XK3pNX0uKiVt8g5z96PJ6z9xCFA== "@octokit/plugin-rest-endpoint-methods@^5.12.0": - version "5.14.0" - resolved "https://registry.yarnpkg.com/@octokit/plugin-rest-endpoint-methods/-/plugin-rest-endpoint-methods-5.14.0.tgz#758e01ac40998e607feaea7f80220c69990814ae" - integrity sha512-MRnMs4Dcm1OSaz/g/RLr4YY9otgysS7vN5SUkHGd7t+R8323cHsHFoEWHYPSmgUC0BieHRhvnCRWb4i3Pl+Lgg== + version "5.15.0" + resolved "https://registry.yarnpkg.com/@octokit/plugin-rest-endpoint-methods/-/plugin-rest-endpoint-methods-5.15.0.tgz#6c8251b55c33315a6e53e5b55654f72023ed5049" + integrity sha512-Gsw9+Xm56jVhfbJoy4pt6eOOyf8/3K6CAnx1Sl7U2GhZWcg8MR6YgXWnpfdF69S2ViMXLA7nfvTDAsZpFlkLRw== dependencies: - "@octokit/types" "^6.35.0" + "@octokit/types" "^6.36.0" deprecation "^2.3.1" "@octokit/request-error@^2.0.5", "@octokit/request-error@^2.1.0": @@ -784,12 +784,12 @@ "@octokit/plugin-request-log" "^1.0.4" "@octokit/plugin-rest-endpoint-methods" "^5.12.0" -"@octokit/types@^6.0.3", "@octokit/types@^6.16.1", "@octokit/types@^6.35.0": - version "6.35.0" - resolved "https://registry.yarnpkg.com/@octokit/types/-/types-6.35.0.tgz#11cd9a679c32b4a6c36459ae2ec3ac4de0104f71" - integrity sha512-DhLfdUuv3H37u6jBDfkwamypx3HflHg29b26nbA6iVFYkAlZ5cMEtu/9pQoihGnQE5M7jJFnNo25Rr1UwQNF8Q== +"@octokit/types@^6.0.3", "@octokit/types@^6.16.1", "@octokit/types@^6.36.0": + version "6.37.0" + resolved "https://registry.yarnpkg.com/@octokit/types/-/types-6.37.0.tgz#32eb78edb34cf5cea4ba5753ab8db75b776d617a" + integrity sha512-BXWQhFKRkjX4dVW5L2oYa0hzWOAqsEsujXsQLSdepPoDZfYdubrD1KDGpyNldGXtR8QM/WezDcxcIN1UKJMGPA== dependencies: - "@octokit/openapi-types" "^12.1.0" + "@octokit/openapi-types" "^12.4.0" "@rollup/plugin-alias@^3.1.9": version "3.1.9" @@ -1484,15 +1484,14 @@ braces@^3.0.2, braces@~3.0.2: fill-range "^7.0.1" browserslist@^4.0.0, browserslist@^4.16.6, browserslist@^4.20.2, browserslist@^4.20.3: - version "4.20.4" - resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.20.4.tgz#98096c9042af689ee1e0271333dbc564b8ce4477" - integrity sha512-ok1d+1WpnU24XYN7oC3QWgTyMhY/avPJ/r9T00xxvUOIparA/gc+UPUMaod3i+G6s+nI2nUb9xZ5k794uIwShw== + version "4.21.0" + resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.21.0.tgz#7ab19572361a140ecd1e023e2c1ed95edda0cefe" + integrity sha512-UQxE0DIhRB5z/zDz9iA03BOfxaN2+GQdBYH/2WrSIWEUrnpzTPJbhqt+umq6r3acaPRTW1FNTkrcp0PXgtFkvA== dependencies: - caniuse-lite "^1.0.30001349" - electron-to-chromium "^1.4.147" - escalade "^3.1.1" + caniuse-lite "^1.0.30001358" + electron-to-chromium "^1.4.164" node-releases "^2.0.5" - picocolors "^1.0.0" + update-browserslist-db "^1.0.0" buffer-crc32@^0.2.1, buffer-crc32@^0.2.13: version "0.2.13" @@ -1578,10 +1577,10 @@ caniuse-api@^3.0.0: lodash.memoize "^4.1.2" lodash.uniq "^4.5.0" -caniuse-lite@^1.0.0, caniuse-lite@^1.0.30001335, caniuse-lite@^1.0.30001349: - version "1.0.30001357" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001357.tgz#dec7fc4158ef6ad24690d0eec7b91f32b8cb1b5d" - integrity sha512-b+KbWHdHePp+ZpNj+RDHFChZmuN+J5EvuQUlee9jOQIUAdhv9uvAZeEtUeLAknXbkiu1uxjQ9NLp1ie894CuWg== +caniuse-lite@^1.0.0, caniuse-lite@^1.0.30001335, caniuse-lite@^1.0.30001358: + version "1.0.30001358" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001358.tgz#473d35dabf5e448b463095cab7924e96ccfb8c00" + integrity sha512-hvp8PSRymk85R20bsDra7ZTCpSVGN/PAz9pSAjPSjKC+rNmnUk5vCRgJwiTT/O4feQ/yu/drvZYpKxxhbFuChw== ccount@^2.0.0: version "2.0.1" @@ -2240,10 +2239,10 @@ ee-first@1.1.1: resolved "https://registry.yarnpkg.com/ee-first/-/ee-first-1.1.1.tgz#590c61156b0ae2f4f0255732a158b266bc56b21d" integrity sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow== -electron-to-chromium@^1.4.147: - version "1.4.161" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.4.161.tgz#49cb5b35385bfee6cc439d0a04fbba7a7a7f08a1" - integrity sha512-sTjBRhqh6wFodzZtc5Iu8/R95OkwaPNn7tj/TaDU5nu/5EFiQDtADGAXdR4tJcTEHlYfJpHqigzJqHvPgehP8A== +electron-to-chromium@^1.4.164: + version "1.4.164" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.4.164.tgz#3d0f5c83557d8ec8a7faa531e498f198c3bd974a" + integrity sha512-K7iy5y6XyP9Pzh3uaDti0KC4JUNT6T1tLG5RTOmesqq2YgAJpYYYJ32m+anvZYjCV35llPTEh87kvEV/uSsiyQ== emmet-monaco-es@^5.1.0: version "5.1.0" @@ -2339,131 +2338,131 @@ error-ex@^1.3.1: dependencies: is-arrayish "^0.2.1" -esbuild-android-64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-android-64/-/esbuild-android-64-0.14.46.tgz#98d019853ca7b526d0d645bb4618fda425b74d35" - integrity sha512-ZyJqwAcjNbZprs0ZAxnUAOhEhdE5kTKwz+CZuLmZYNLAPyRgBtaC8pT2PCuPifNvV8Cl3yLlrQPaOCjovoyb5g== - -esbuild-android-arm64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-android-arm64/-/esbuild-android-arm64-0.14.46.tgz#19835d5265b57120c14fba56a19fc317ca4bbda0" - integrity sha512-BKcnUksvCijO9ONv6b4SikZE/OZftwJvX91XROODZGQmuwGVg97jmLDVu3lxuHdFlMNNzxh8taJ2mbCWZzH/Iw== - -esbuild-darwin-64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-darwin-64/-/esbuild-darwin-64-0.14.46.tgz#2819465ab92f6df407e6462d9e56f6563a043a44" - integrity sha512-/ss2kO92sUJ9/1nHnMb3+oab8w6dyqKrMtPMvSYJ9KZIYGAZxz/WYxfFprY7Xk+ZxWnnlASSyZlG+If1nVmFYg== - -esbuild-darwin-arm64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.14.46.tgz#2d523fa628930bba38a4f75cede75d6341bc3b5b" - integrity sha512-WX0JOaEFf6t+rIjXO6THsf/0fhQAt2Zb0/PSYlvXnuQQAmOmFAfPsuRNocp5ME0NGaUqZd4FxqqmLEVK3RzPAg== - -esbuild-freebsd-64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-freebsd-64/-/esbuild-freebsd-64-0.14.46.tgz#dbfbbb1cb943149aaa83b9e767ded6f14ad42ba5" - integrity sha512-o+ozPFuHRCAGCVWU2bLurOUgVkT0jcPEu082VBUY2Q/yLf+B+/3nXzh4Fjp5O21tOvJRTn7hUVydG9j5+vYE6A== - -esbuild-freebsd-arm64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-freebsd-arm64/-/esbuild-freebsd-arm64-0.14.46.tgz#fb066d6e7de2bd96138dd1c2fba5e8ce5233ed5a" - integrity sha512-9zicZ0X43WDKz3sjNfcqYO38xbfJpSWYXB+FxvYYkmBwGA52K0SAu4oKuTTLi8od8X2IIo1x5C5TUNvKDSVJww== - -esbuild-linux-32@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-linux-32/-/esbuild-linux-32-0.14.46.tgz#ea2464b10fe188ee7c9be81a2757e2d69ffdb8c1" - integrity sha512-ZnTpZMVb0VGvL99R5eh4OrJwbUyvpM6M88VAMuHP4LvFjuvZrhgefjKqEGuWZZW7JRnAjKqjXLjWdhdSjwMFnQ== - -esbuild-linux-64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-linux-64/-/esbuild-linux-64-0.14.46.tgz#f4f2d181af6ea78137311712fca423f8fa954314" - integrity sha512-ECCRRZtX6l4ubeVhHhiVoK/uYAkvzNqfmR4gP4N/9H9RPu+b8YCcN4bQGp7xCuYIV6Xd41WpOMyO+xpcQvjtQQ== - -esbuild-linux-arm64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-linux-arm64/-/esbuild-linux-arm64-0.14.46.tgz#113d17c523dfe80c9d4981d05c58f5ada3470e30" - integrity sha512-HX0TXCHyI0NEWG4jg8LlW1PbZQbnz+PUH56yjx996cgM5pC90u32drKs/tyJiyyQmNk9OXOogjKw7LEdp/Qc1w== - -esbuild-linux-arm@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-linux-arm/-/esbuild-linux-arm-0.14.46.tgz#1b6ba77b0301572b2fed35fe922b1613b10b5c7e" - integrity sha512-RvTJEi4vj13c5FP9YPp+8Y6x6HK1E7uSqfy3y9UoeaNAzNZWA7fN1U3hQjTL/dy5zTJH5KE64mrt5k5+he+CQA== - -esbuild-linux-mips64le@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-linux-mips64le/-/esbuild-linux-mips64le-0.14.46.tgz#8775e12510eaf988a9bc5e6787cf0c87c3eb40d6" - integrity sha512-jnb2NDwGqJUVmxn1v0f7seNdDm0nRNWHP9Z3MrWAGnBCdnnDlsjqRFDnbKoaQvWONEa+rOOr/giK+VL0hgQExA== - -esbuild-linux-ppc64le@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-linux-ppc64le/-/esbuild-linux-ppc64le-0.14.46.tgz#da003df59859b02e160827e26bc1e107bec23d07" - integrity sha512-uu3JTQUrwwauKY9z8yq5MnDyOlT3f2DNOzBcYz4dB78HqwEqilCsifoBGd0WcbED5n57dc59X+LZMTZ8Ose44w== - -esbuild-linux-riscv64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-linux-riscv64/-/esbuild-linux-riscv64-0.14.46.tgz#b6c4faf9f8482e2a898ec2becac4a6789ae3ff22" - integrity sha512-OB29r1EG44ZY34JnXCRERxo7k4pRKoQdaoRg2HIeCavatsXZwW4LCakpLnMQ72vXT1HtpBUABEjHkKkn5JyrUg== - -esbuild-linux-s390x@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-linux-s390x/-/esbuild-linux-s390x-0.14.46.tgz#d30d0f7ee8466c4ec99ac2c689b70514320406b2" - integrity sha512-XQ/U9TueMSGYyPTKyZsJVraiuvxhwCDIMn/QwFXCRCJ6H/Cy/Rq33u9qhpeSziinHKfzJROGx5A8mQY6aYamdQ== - -esbuild-netbsd-64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-netbsd-64/-/esbuild-netbsd-64-0.14.46.tgz#fcf2b739b63731b5b264dc584240c0b61dbbf035" - integrity sha512-i15BwqHaAIFp1vBJkitAbHtwXcLk9TdHs/Ia1xGIAutQYXSJNPLM3Z4B4hyfHNEFl2yBqBIYpglMohv2ClNdOQ== - -esbuild-openbsd-64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-openbsd-64/-/esbuild-openbsd-64-0.14.46.tgz#fc7880751b78b325216e66470b9a3df7b1c21cbf" - integrity sha512-XwOIFCE140Y/PvjrwjFfa/QLWBuvhR1mPCOa35mKx02jt++wPNgf0qhn6HfdVC3vQe7R46RwTp4q2cp99fepEg== - -esbuild-sunos-64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-sunos-64/-/esbuild-sunos-64-0.14.46.tgz#ab73b91e79ae53dddb035da9bb69ba7dd44d36ee" - integrity sha512-+kV3JnmfdxBVpHyFvuGXWtu6tXxXApOLPkSrVkMJf6+ns/3PLtPndpzwCzHjD+qYUEk8ln4MA+ufQ2qmjW5mZg== - -esbuild-windows-32@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-windows-32/-/esbuild-windows-32-0.14.46.tgz#88ad388c896325d273e92dbf28f146d1d34d4351" - integrity sha512-gzGC1Q11B/Bo5A2EX4N22oigWmhL7Z0eDyc8kbSoJjqSrGQuRE7B0uMpluO+q0O/gZ1S3zdw+M4PCWlqOIeXLA== - -esbuild-windows-64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-windows-64/-/esbuild-windows-64-0.14.46.tgz#bfb21b68d54d0db86190f8073cbf66a86bd0de14" - integrity sha512-Do2daaskfOjmCB7o3ygz6fD3K6SPjZLERiZLktzHz2oUCwsebKu/gmop0+j/XdrVIXC32wFzHzDS+9CTu9OShw== - -esbuild-windows-arm64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-windows-arm64/-/esbuild-windows-arm64-0.14.46.tgz#b8aa66a0c347342b9ae780b537d5574e9691c123" - integrity sha512-VEzMy6bM60/HT/URTDElyhfi2Pk0quCCrEhRlI4MRno/AIqYUGw0rZwkPl6PeoqVI6BgoBHGY576GWTiPmshCA== +esbuild-android-64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-android-64/-/esbuild-android-64-0.14.47.tgz#ef95b42c67bcf4268c869153fa3ad1466c4cea6b" + integrity sha512-R13Bd9+tqLVFndncMHssZrPWe6/0Kpv2/dt4aA69soX4PRxlzsVpCvoJeFE8sOEoeVEiBkI0myjlkDodXlHa0g== + +esbuild-android-arm64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-android-arm64/-/esbuild-android-arm64-0.14.47.tgz#4ebd7ce9fb250b4695faa3ee46fd3b0754ecd9e6" + integrity sha512-OkwOjj7ts4lBp/TL6hdd8HftIzOy/pdtbrNA4+0oVWgGG64HrdVzAF5gxtJufAPOsEjkyh1oIYvKAUinKKQRSQ== + +esbuild-darwin-64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-darwin-64/-/esbuild-darwin-64-0.14.47.tgz#e0da6c244f497192f951807f003f6a423ed23188" + integrity sha512-R6oaW0y5/u6Eccti/TS6c/2c1xYTb1izwK3gajJwi4vIfNs1s8B1dQzI1UiC9T61YovOQVuePDcfqHLT3mUZJA== + +esbuild-darwin-arm64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.14.47.tgz#cd40fd49a672fca581ed202834239dfe540a9028" + integrity sha512-seCmearlQyvdvM/noz1L9+qblC5vcBrhUaOoLEDDoLInF/VQ9IkobGiLlyTPYP5dW1YD4LXhtBgOyevoIHGGnw== + +esbuild-freebsd-64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-freebsd-64/-/esbuild-freebsd-64-0.14.47.tgz#8da6a14c095b29c01fc8087a16cb7906debc2d67" + integrity sha512-ZH8K2Q8/Ux5kXXvQMDsJcxvkIwut69KVrYQhza/ptkW50DC089bCVrJZZ3sKzIoOx+YPTrmsZvqeZERjyYrlvQ== + +esbuild-freebsd-arm64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-freebsd-arm64/-/esbuild-freebsd-arm64-0.14.47.tgz#ad31f9c92817ff8f33fd253af7ab5122dc1b83f6" + integrity sha512-ZJMQAJQsIOhn3XTm7MPQfCzEu5b9STNC+s90zMWe2afy9EwnHV7Ov7ohEMv2lyWlc2pjqLW8QJnz2r0KZmeAEQ== + +esbuild-linux-32@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-linux-32/-/esbuild-linux-32-0.14.47.tgz#de085e4db2e692ea30c71208ccc23fdcf5196c58" + integrity sha512-FxZOCKoEDPRYvq300lsWCTv1kcHgiiZfNrPtEhFAiqD7QZaXrad8LxyJ8fXGcWzIFzRiYZVtB3ttvITBvAFhKw== + +esbuild-linux-64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-linux-64/-/esbuild-linux-64-0.14.47.tgz#2a9321bbccb01f01b04cebfcfccbabeba3658ba1" + integrity sha512-nFNOk9vWVfvWYF9YNYksZptgQAdstnDCMtR6m42l5Wfugbzu11VpMCY9XrD4yFxvPo9zmzcoUL/88y0lfJZJJw== + +esbuild-linux-arm64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-linux-arm64/-/esbuild-linux-arm64-0.14.47.tgz#b9da7b6fc4b0ca7a13363a0c5b7bb927e4bc535a" + integrity sha512-ywfme6HVrhWcevzmsufjd4iT3PxTfCX9HOdxA7Hd+/ZM23Y9nXeb+vG6AyA6jgq/JovkcqRHcL9XwRNpWG6XRw== + +esbuild-linux-arm@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-linux-arm/-/esbuild-linux-arm-0.14.47.tgz#56fec2a09b9561c337059d4af53625142aded853" + integrity sha512-ZGE1Bqg/gPRXrBpgpvH81tQHpiaGxa8c9Rx/XOylkIl2ypLuOcawXEAo8ls+5DFCcRGt/o3sV+PzpAFZobOsmA== + +esbuild-linux-mips64le@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-linux-mips64le/-/esbuild-linux-mips64le-0.14.47.tgz#9db21561f8f22ed79ef2aedb7bbef082b46cf823" + integrity sha512-mg3D8YndZ1LvUiEdDYR3OsmeyAew4MA/dvaEJxvyygahWmpv1SlEEnhEZlhPokjsUMfRagzsEF/d/2XF+kTQGg== + +esbuild-linux-ppc64le@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-linux-ppc64le/-/esbuild-linux-ppc64le-0.14.47.tgz#dc3a3da321222b11e96e50efafec9d2de408198b" + integrity sha512-WER+f3+szmnZiWoK6AsrTKGoJoErG2LlauSmk73LEZFQ/iWC+KhhDsOkn1xBUpzXWsxN9THmQFltLoaFEH8F8w== + +esbuild-linux-riscv64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-linux-riscv64/-/esbuild-linux-riscv64-0.14.47.tgz#9bd6dcd3dca6c0357084ecd06e1d2d4bf105335f" + integrity sha512-1fI6bP3A3rvI9BsaaXbMoaOjLE3lVkJtLxsgLHqlBhLlBVY7UqffWBvkrX/9zfPhhVMd9ZRFiaqXnB1T7BsL2g== + +esbuild-linux-s390x@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-linux-s390x/-/esbuild-linux-s390x-0.14.47.tgz#a458af939b52f2cd32fc561410d441a51f69d41f" + integrity sha512-eZrWzy0xFAhki1CWRGnhsHVz7IlSKX6yT2tj2Eg8lhAwlRE5E96Hsb0M1mPSE1dHGpt1QVwwVivXIAacF/G6mw== + +esbuild-netbsd-64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-netbsd-64/-/esbuild-netbsd-64-0.14.47.tgz#6388e785d7e7e4420cb01348d7483ab511b16aa8" + integrity sha512-Qjdjr+KQQVH5Q2Q1r6HBYswFTToPpss3gqCiSw2Fpq/ua8+eXSQyAMG+UvULPqXceOwpnPo4smyZyHdlkcPppQ== + +esbuild-openbsd-64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-openbsd-64/-/esbuild-openbsd-64-0.14.47.tgz#309af806db561aa886c445344d1aacab850dbdc5" + integrity sha512-QpgN8ofL7B9z8g5zZqJE+eFvD1LehRlxr25PBkjyyasakm4599iroUpaj96rdqRlO2ShuyqwJdr+oNqWwTUmQw== + +esbuild-sunos-64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-sunos-64/-/esbuild-sunos-64-0.14.47.tgz#3f19612dcdb89ba6c65283a7ff6e16f8afbf8aaa" + integrity sha512-uOeSgLUwukLioAJOiGYm3kNl+1wJjgJA8R671GYgcPgCx7QR73zfvYqXFFcIO93/nBdIbt5hd8RItqbbf3HtAQ== + +esbuild-windows-32@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-windows-32/-/esbuild-windows-32-0.14.47.tgz#a92d279c8458d5dc319abcfeb30aa49e8f2e6f7f" + integrity sha512-H0fWsLTp2WBfKLBgwYT4OTfFly4Im/8B5f3ojDv1Kx//kiubVY0IQunP2Koc/fr/0wI7hj3IiBDbSrmKlrNgLQ== + +esbuild-windows-64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-windows-64/-/esbuild-windows-64-0.14.47.tgz#2564c3fcf0c23d701edb71af8c52d3be4cec5f8a" + integrity sha512-/Pk5jIEH34T68r8PweKRi77W49KwanZ8X6lr3vDAtOlH5EumPE4pBHqkCUdELanvsT14yMXLQ/C/8XPi1pAtkQ== + +esbuild-windows-arm64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-windows-arm64/-/esbuild-windows-arm64-0.14.47.tgz#86d9db1a22d83360f726ac5fba41c2f625db6878" + integrity sha512-HFSW2lnp62fl86/qPQlqw6asIwCnEsEoNIL1h2uVMgakddf+vUuMcCbtUY1i8sst7KkgHrVKCJQB33YhhOweCQ== esbuild@^0.14.27, esbuild@^0.14.43: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild/-/esbuild-0.14.46.tgz#d548cfc13fecfd4bc074ce38e0122d1dd9b067db" - integrity sha512-vdm5G1JdZBktva8dwQci/s44VbeBUg8g907xoZx77mqFZ4gU5GlMULNsdGeID+qXCXocsfYSGtE0LvqH3eiNQg== + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild/-/esbuild-0.14.47.tgz#0d6415f6bd8eb9e73a58f7f9ae04c5276cda0e4d" + integrity sha512-wI4ZiIfFxpkuxB8ju4MHrGwGLyp1+awEHAHVpx6w7a+1pmYIq8T9FGEVVwFo0iFierDoMj++Xq69GXWYn2EiwA== optionalDependencies: - esbuild-android-64 "0.14.46" - esbuild-android-arm64 "0.14.46" - esbuild-darwin-64 "0.14.46" - esbuild-darwin-arm64 "0.14.46" - esbuild-freebsd-64 "0.14.46" - esbuild-freebsd-arm64 "0.14.46" - esbuild-linux-32 "0.14.46" - esbuild-linux-64 "0.14.46" - esbuild-linux-arm "0.14.46" - esbuild-linux-arm64 "0.14.46" - esbuild-linux-mips64le "0.14.46" - esbuild-linux-ppc64le "0.14.46" - esbuild-linux-riscv64 "0.14.46" - esbuild-linux-s390x "0.14.46" - esbuild-netbsd-64 "0.14.46" - esbuild-openbsd-64 "0.14.46" - esbuild-sunos-64 "0.14.46" - esbuild-windows-32 "0.14.46" - esbuild-windows-64 "0.14.46" - esbuild-windows-arm64 "0.14.46" + esbuild-android-64 "0.14.47" + esbuild-android-arm64 "0.14.47" + esbuild-darwin-64 "0.14.47" + esbuild-darwin-arm64 "0.14.47" + esbuild-freebsd-64 "0.14.47" + esbuild-freebsd-arm64 "0.14.47" + esbuild-linux-32 "0.14.47" + esbuild-linux-64 "0.14.47" + esbuild-linux-arm "0.14.47" + esbuild-linux-arm64 "0.14.47" + esbuild-linux-mips64le "0.14.47" + esbuild-linux-ppc64le "0.14.47" + esbuild-linux-riscv64 "0.14.47" + esbuild-linux-s390x "0.14.47" + esbuild-netbsd-64 "0.14.47" + esbuild-openbsd-64 "0.14.47" + esbuild-sunos-64 "0.14.47" + esbuild-windows-32 "0.14.47" + esbuild-windows-64 "0.14.47" + esbuild-windows-arm64 "0.14.47" escalade@^3.1.1: version "3.1.1" @@ -3384,9 +3383,9 @@ jest-worker@^26.2.1: supports-color "^7.0.0" jiti@^1.12.14, jiti@^1.13.0: - version "1.13.0" - resolved "https://registry.yarnpkg.com/jiti/-/jiti-1.13.0.tgz#3cdfc4e651ca0cca4c62ed5e47747b5841d41a8e" - integrity sha512-/n9mNxZj/HDSrincJ6RP+L+yXbpnB8FybySBa+IjIaoH9FIxBbrbRT5XUbe8R7zuVM2AQqNMNDDqz0bzx3znOQ== + version "1.14.0" + resolved "https://registry.yarnpkg.com/jiti/-/jiti-1.14.0.tgz#5350fff532a4d891ca4bcd700c47c1f40e6ee326" + integrity sha512-4IwstlaKQc9vCTC+qUXLM1hajy2ImiL9KnLvVYiaHOtS/v3wRjhLlGl121AmgDgx/O43uKmxownJghS5XMya2A== js-tokens@^4.0.0: version "4.0.0" @@ -3542,7 +3541,7 @@ lines-and-columns@^1.1.6: resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-1.2.4.tgz#eca284f75d2965079309dc0ad9255abb2ebc1632" integrity sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg== -listhen@^0.2.11, listhen@^0.2.12: +listhen@^0.2.11, listhen@^0.2.12, listhen@^0.2.13: version "0.2.13" resolved "https://registry.yarnpkg.com/listhen/-/listhen-0.2.13.tgz#bd34338fe04ff9f3f08e4f83a46eefc9104b2482" integrity sha512-axfyPgsrypKohOglPjzMVj+6nSQuDfdDzq92tYEg4HO+YkvvMGz0bGeoGA+pdEC7a8gbIgLduf/62Pkk1a9jMQ== @@ -4259,12 +4258,7 @@ mkdirp@^1.0.3: resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-1.0.4.tgz#3eb5ed62622756d79a5f0e2a221dfebad75c2f7e" integrity sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw== -mlly@^0.3.6: - version "0.3.19" - resolved "https://registry.yarnpkg.com/mlly/-/mlly-0.3.19.tgz#a4aac171d2142eafc9c9d4c1937dac5a11f70565" - integrity sha512-zMq5n3cOf4fOzA4WoeulxagbAgMChdev3MgP6K51k7M0u2whTXxupfIY4VVzws4vxkiWhwH1rVQcsw7zDGfRhA== - -mlly@^0.5.1, mlly@^0.5.2: +mlly@^0.5.1, mlly@^0.5.2, mlly@^0.5.3: version "0.5.3" resolved "https://registry.yarnpkg.com/mlly/-/mlly-0.5.3.tgz#8a613b6273886490a5f462ce18fa486492cf053b" integrity sha512-im69tuLD9EJh9fc9TZRpJEFvsBcGMez7glUCWDcHWWCKzhvPmNvyaYjp/+h0qJJN/Xovrs//GzGjOOKmFw4Gog== @@ -4399,9 +4393,9 @@ node-emoji@^1.11.0: lodash "^4.17.21" node-fetch-native@^0.1.2, node-fetch-native@^0.1.3: - version "0.1.3" - resolved "https://registry.yarnpkg.com/node-fetch-native/-/node-fetch-native-0.1.3.tgz#61a4e4250d7aa6e272cacdbaa979ea916bff321a" - integrity sha512-Jf1IQZdovUIv9E+5avmN6Sf+bND+rnMlODnBQhdE2VRyuWP9WgqZb/KEgPekh19DAN1X2C4vbS1VCOaz2OH19g== + version "0.1.4" + resolved "https://registry.yarnpkg.com/node-fetch-native/-/node-fetch-native-0.1.4.tgz#09b06754f9e298bac23848050da2352125634f89" + integrity sha512-10EKpOCQPXwZVFh3U1ptOMWBgKTbsN7Vvo6WVKt5pw4hp8zbv6ZVBZPlXw+5M6Tyi1oc1iD4/sNPd71KYA16tQ== node-fetch@^2.6.7: version "2.6.7" @@ -4838,13 +4832,13 @@ pify@^2.3.0: integrity sha512-udgsAY+fTnvv7kI7aaxbqwWNb0AHiB0qBO89PZKPkoTmGOgdbrHDKD+0B2X4uTfJ/FT1R09r9gTsjUjNJotuog== pkg-types@^0.3.2: - version "0.3.2" - resolved "https://registry.yarnpkg.com/pkg-types/-/pkg-types-0.3.2.tgz#1b3244b561745591035517475bc8af9c5e089e47" - integrity sha512-eBYzX/7NYsQEOR2alWY4rnQB49G62oHzFpoi9Som56aUr8vB8UGcmcIia9v8fpBeuhH3Ltentuk2OGpp4IQV3Q== + version "0.3.3" + resolved "https://registry.yarnpkg.com/pkg-types/-/pkg-types-0.3.3.tgz#3c25e45274e1c586ec7811dcc3449afde846e463" + integrity sha512-6AJcCMnjUQPQv/Wk960w0TOmjhdjbeaQJoSKWRQv9N3rgkessCu6J0Ydsog/nw1MbpnxHuPzYbfOn2KmlZO1FA== dependencies: jsonc-parser "^3.0.0" - mlly "^0.3.6" - pathe "^0.2.0" + mlly "^0.5.3" + pathe "^0.3.0" plausible-tracker@^0.3.4: version "0.3.8" @@ -6026,9 +6020,9 @@ tailwind-config-viewer@^1.7.0: replace-in-file "^6.1.0" tailwindcss@^3.0.24, tailwindcss@^3.1.3: - version "3.1.3" - resolved "https://registry.yarnpkg.com/tailwindcss/-/tailwindcss-3.1.3.tgz#b9ef2c1ae537c339679e8e89635af8e143d1c7eb" - integrity sha512-PRJNYdSIthrb8hjmAyymEyEN8Yo61TMXpzyFUpxULeeyRn3Y3gpvuw6FlRTKrJvK7thSGKRnhT36VovVx4WeMA== + version "3.1.4" + resolved "https://registry.yarnpkg.com/tailwindcss/-/tailwindcss-3.1.4.tgz#64b09059805505902139fa805d97046080bd90b9" + integrity sha512-NrxbFV4tYsga/hpWbRyUfIaBrNMXDxx5BsHgBS4v5tlyjf+sDsgBg5m9OxjrXIqAS/uR9kicxLKP+bEHI7BSeQ== dependencies: arg "^5.0.2" chokidar "^3.5.3" @@ -6400,6 +6394,14 @@ untyped@^0.4.4: "@babel/types" "^7.17.0" scule "^0.2.1" +update-browserslist-db@^1.0.0: + version "1.0.3" + resolved "https://registry.yarnpkg.com/update-browserslist-db/-/update-browserslist-db-1.0.3.tgz#6c47cb996f34afb363e924748e2f6e4d983c6fc1" + integrity sha512-ufSazemeh9Gty0qiWtoRpJ9F5Q5W3xdIPm1UZQqYQv/q0Nyb9EMHUB2lu+O9x1re9WsorpMAUu4Y6Lxcs5n+XQ== + dependencies: + escalade "^3.1.1" + picocolors "^1.0.0" + uri-js@^4.2.2: version "4.4.1" resolved "https://registry.yarnpkg.com/uri-js/-/uri-js-4.4.1.tgz#9b1a52595225859e55f669d928f88c6c57f2a77e" @@ -6413,9 +6415,9 @@ util-deprecate@^1.0.1, util-deprecate@^1.0.2, util-deprecate@~1.0.1: integrity sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw== uvu@^0.5.0: - version "0.5.3" - resolved "https://registry.yarnpkg.com/uvu/-/uvu-0.5.3.tgz#3d83c5bc1230f153451877bfc7f4aea2392219ae" - integrity sha512-brFwqA3FXzilmtnIyJ+CxdkInkY/i4ErvP7uV0DnUVxQcQ55reuHphorpF+tZoVHK2MniZ/VJzI7zJQoc9T9Yw== + version "0.5.4" + resolved "https://registry.yarnpkg.com/uvu/-/uvu-0.5.4.tgz#5a37482ade580b7d817569e0b2c013712857293c" + integrity sha512-x1CyUjcP9VKaNPhjeB3FIc/jqgLsz2Q9LFhRzUTu/jnaaHILEGNuE0XckQonl8ISLcwyk9I2EZvWlYsQnwxqvQ== dependencies: dequal "^2.0.0" diff "^5.0.0" diff --git a/examples/document-driven/app.vue b/examples/document-driven/app.vue new file mode 100644 index 000000000..55298c17b --- /dev/null +++ b/examples/document-driven/app.vue @@ -0,0 +1,5 @@ + diff --git a/examples/document-driven/content/about.md b/examples/document-driven/content/about.md new file mode 100644 index 000000000..b31f9628c --- /dev/null +++ b/examples/document-driven/content/about.md @@ -0,0 +1,3 @@ +# About page + +You can go back to the [home page](/). diff --git a/examples/document-driven/content/index.md b/examples/document-driven/content/index.md new file mode 100644 index 000000000..f896feced --- /dev/null +++ b/examples/document-driven/content/index.md @@ -0,0 +1,6 @@ +# Hello Nuxt Content + +Welcome to Nuxt Content Hello World example. + +Checkout the [about page](/about). + diff --git a/examples/document-driven/nuxt.config.ts b/examples/document-driven/nuxt.config.ts new file mode 100644 index 000000000..d896bcd50 --- /dev/null +++ b/examples/document-driven/nuxt.config.ts @@ -0,0 +1,11 @@ +import { defineNuxtConfig } from 'nuxt' + +export default defineNuxtConfig({ + modules: [ + '@nuxt/content', + '@nuxt/ui' + ], + content: { + documentDriven: true + } +}) diff --git a/examples/document-driven/package.json b/examples/document-driven/package.json new file mode 100644 index 000000000..42722a700 --- /dev/null +++ b/examples/document-driven/package.json @@ -0,0 +1,15 @@ +{ + "name": "example-hello-world", + "private": true, + "scripts": { + "build": "nuxt build", + "dev": "nuxt dev", + "generate": "nuxt generate", + "preview": "nuxt preview" + }, + "devDependencies": { + "@nuxt/content": "npm:@nuxt/content-edge@latest", + "@nuxt/ui": "npm:@nuxt/ui-edge@latest", + "nuxt": "npm:nuxt3@latest" + } +} diff --git a/package.json b/package.json index 724646e63..9ad854913 100644 --- a/package.json +++ b/package.json @@ -24,18 +24,18 @@ ], "scripts": { "build": "nuxt-module-build", - "dev": "nuxi dev playground", - "dev:build": "nuxi build playground", - "dev:prepare": "nuxt-module-build --stub && nuxi prepare playground", - "dev:docs": "(cd docs && nuxi dev)", - "dev:fixtures": "nuxi dev test/fixtures/basic", + "dev": "./scripts/playground.sh", + "dev:build": "nuxi build playground/basic", + "dev:prepare": "nuxt-module-build --stub && nuxi prepare playground/basic", + "dev:fixtures": "./scripts/fixture.sh", "build:docs": "(cd docs && nuxi build)", "example": "./scripts/example.sh", "lint": "eslint --ext .js,.ts,.vue .", "prepack": "yarn build", "test:coverage": "vitest --coverage", "test:types": "tsc --build tsconfig.json", - "test:unit": "nuxi prepare test/fixtures/basic && vitest run" + "test": "./scripts/test.sh", + "test:unit": "nuxi prepare test/fixtures/basic && nuxi prepare test/fixtures/document-driven && vitest run" }, "dependencies": { "@nuxt/kit": "^3.0.0-rc.4", diff --git a/playground/content-fa/_dir.yml b/playground/basic/content-fa/_dir.yml similarity index 100% rename from playground/content-fa/_dir.yml rename to playground/basic/content-fa/_dir.yml diff --git a/playground/content-fa/hello.md b/playground/basic/content-fa/hello.md similarity index 100% rename from playground/content-fa/hello.md rename to playground/basic/content-fa/hello.md diff --git a/playground/basic/content/0.index.md b/playground/basic/content/0.index.md new file mode 100644 index 000000000..0d0526857 --- /dev/null +++ b/playground/basic/content/0.index.md @@ -0,0 +1,9 @@ +--- +title: Index +--- + +# 🎨 Playground + +- [Playground](/playground) +- [Query Builder](/query-playground) +- [Not found](/404) diff --git a/playground/content/real-content/content.md b/playground/basic/content/1.real-content/content.md similarity index 100% rename from playground/content/real-content/content.md rename to playground/basic/content/1.real-content/content.md diff --git a/playground/content/real-content/query.md b/playground/basic/content/1.real-content/query.md similarity index 100% rename from playground/content/real-content/query.md rename to playground/basic/content/1.real-content/query.md diff --git a/playground/content/features/1.unwrap.md b/playground/basic/content/2.features/1.unwrap.md similarity index 100% rename from playground/content/features/1.unwrap.md rename to playground/basic/content/2.features/1.unwrap.md diff --git a/playground/content/features/2.excerpt.md b/playground/basic/content/2.features/2.excerpt.md similarity index 100% rename from playground/content/features/2.excerpt.md rename to playground/basic/content/2.features/2.excerpt.md diff --git a/playground/content/features/3.mdc-highlighter.md b/playground/basic/content/2.features/3.mdc-highlighter.md similarity index 100% rename from playground/content/features/3.mdc-highlighter.md rename to playground/basic/content/2.features/3.mdc-highlighter.md diff --git a/playground/basic/content/2.features/4.path-overwrite.md b/playground/basic/content/2.features/4.path-overwrite.md new file mode 100644 index 000000000..356e73cba --- /dev/null +++ b/playground/basic/content/2.features/4.path-overwrite.md @@ -0,0 +1,6 @@ +--- +title: 'Path overwriting' +_path: '/features/overwrited-path' +--- + +# Path overwriting diff --git a/playground/content/empty.md b/playground/basic/content/2.features/5.empty-document.md similarity index 100% rename from playground/content/empty.md rename to playground/basic/content/2.features/5.empty-document.md diff --git a/playground/content/file-formats/csv.csv b/playground/basic/content/3.file-formats/csv.csv similarity index 100% rename from playground/content/file-formats/csv.csv rename to playground/basic/content/3.file-formats/csv.csv diff --git a/playground/content/file-formats/json.json b/playground/basic/content/3.file-formats/json.json similarity index 100% rename from playground/content/file-formats/json.json rename to playground/basic/content/3.file-formats/json.json diff --git a/playground/content/file-formats/json5.json5 b/playground/basic/content/3.file-formats/json5.json5 similarity index 100% rename from playground/content/file-formats/json5.json5 rename to playground/basic/content/3.file-formats/json5.json5 diff --git a/playground/content/file-formats/yaml.yml b/playground/basic/content/3.file-formats/yaml.yml similarity index 100% rename from playground/content/file-formats/yaml.yml rename to playground/basic/content/3.file-formats/yaml.yml diff --git a/playground/basic/content/98.playground.md b/playground/basic/content/98.playground.md new file mode 100644 index 000000000..a916681c8 --- /dev/null +++ b/playground/basic/content/98.playground.md @@ -0,0 +1,6 @@ +--- +title: Playground +--- + +::playground +:: diff --git a/playground/basic/content/99.query-playground.md b/playground/basic/content/99.query-playground.md new file mode 100644 index 000000000..7d1d54de9 --- /dev/null +++ b/playground/basic/content/99.query-playground.md @@ -0,0 +1,6 @@ +--- +title: Query Playground +--- + +::query-playground +:: diff --git a/playground/content/_partials/cards.yml b/playground/basic/content/_partials/cards.yml similarity index 100% rename from playground/content/_partials/cards.yml rename to playground/basic/content/_partials/cards.yml diff --git a/playground/content/_partials/hello-world.md b/playground/basic/content/_partials/hello-world.md similarity index 100% rename from playground/content/_partials/hello-world.md rename to playground/basic/content/_partials/hello-world.md diff --git a/playground/basic/nuxt.config.ts b/playground/basic/nuxt.config.ts new file mode 100644 index 000000000..664e5d46c --- /dev/null +++ b/playground/basic/nuxt.config.ts @@ -0,0 +1,15 @@ +import { defineNuxtConfig } from 'nuxt' +import { resolve } from 'pathe' + +export default defineNuxtConfig({ + extends: ['../shared'], + content: { + sources: { + 'translation-fa': { + prefix: '/fa', + driver: 'fs', + base: resolve(__dirname, 'content-fa') + } + } + } +}) diff --git a/playground/basic/pages/[...slug].vue b/playground/basic/pages/[...slug].vue new file mode 100644 index 000000000..7abf428fc --- /dev/null +++ b/playground/basic/pages/[...slug].vue @@ -0,0 +1,21 @@ + + + + + diff --git a/playground/basic/pages/playground.vue b/playground/basic/pages/playground.vue new file mode 100644 index 000000000..5eaf15fbb --- /dev/null +++ b/playground/basic/pages/playground.vue @@ -0,0 +1,21 @@ + + + + + diff --git a/playground/basic/pages/query-playground.vue b/playground/basic/pages/query-playground.vue new file mode 100644 index 000000000..5eaf15fbb --- /dev/null +++ b/playground/basic/pages/query-playground.vue @@ -0,0 +1,21 @@ + + + + + diff --git a/playground/public/favicon.ico b/playground/basic/public/favicon.ico similarity index 100% rename from playground/public/favicon.ico rename to playground/basic/public/favicon.ico diff --git a/playground/content/1.index.md b/playground/content/1.index.md deleted file mode 100644 index 93a521733..000000000 --- a/playground/content/1.index.md +++ /dev/null @@ -1,9 +0,0 @@ -# Hello World! - -Index page. - -- [Playground](/playground) -- [Query Builder](/query) -- [Sandbox](/sandbox) -- [Empty](/empty) -- [Not found](/not-found) diff --git a/playground/content/_test.md b/playground/content/_test.md deleted file mode 100644 index 66ef82ff4..000000000 --- a/playground/content/_test.md +++ /dev/null @@ -1,7 +0,0 @@ ---- -navigation: false ---- - -# Hello World! - -This is a test page! diff --git a/playground/content/features/4.navigation.md b/playground/content/features/4.navigation.md deleted file mode 100644 index cc0be1e56..000000000 --- a/playground/content/features/4.navigation.md +++ /dev/null @@ -1 +0,0 @@ -# Hello World! diff --git a/playground/content/toto.md b/playground/content/toto.md deleted file mode 100644 index 9693fa796..000000000 --- a/playground/content/toto.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -_path: '/titi' ---- - -# Toto 2 diff --git a/playground/document-driven/components/content/Debug.vue b/playground/document-driven/components/content/Debug.vue new file mode 100644 index 000000000..e3ff624d4 --- /dev/null +++ b/playground/document-driven/components/content/Debug.vue @@ -0,0 +1,36 @@ + + + diff --git a/playground/document-driven/composables/useTheme.ts b/playground/document-driven/composables/useTheme.ts new file mode 100644 index 000000000..9a707d114 --- /dev/null +++ b/playground/document-driven/composables/useTheme.ts @@ -0,0 +1,9 @@ +import { useContent } from '#imports' + +export const useTheme = () => { + const { globals } = useContent() + + const theme = computed(() => globals.value?.theme) + + return theme +} diff --git a/playground/document-driven/content/0.index.md b/playground/document-driven/content/0.index.md new file mode 100644 index 000000000..f3c858066 --- /dev/null +++ b/playground/document-driven/content/0.index.md @@ -0,0 +1,3 @@ +# Home + +Hello World! diff --git a/playground/document-driven/content/1.debug.md b/playground/document-driven/content/1.debug.md new file mode 100644 index 000000000..c594ec203 --- /dev/null +++ b/playground/document-driven/content/1.debug.md @@ -0,0 +1,6 @@ +# Debug + +::debug +:: + +`useTheme()` is built on top of `globals` key. diff --git a/playground/document-driven/content/2.layout.md b/playground/document-driven/content/2.layout.md new file mode 100644 index 000000000..cb2e7fc50 --- /dev/null +++ b/playground/document-driven/content/2.layout.md @@ -0,0 +1,9 @@ +--- +layout: reversed +--- + +# Layout + +This page uses `reversed` layout. + +Navigation should be on bottom. diff --git a/playground/document-driven/content/4.redirect.md b/playground/document-driven/content/4.redirect.md new file mode 100644 index 000000000..ab2cf733c --- /dev/null +++ b/playground/document-driven/content/4.redirect.md @@ -0,0 +1,5 @@ +--- +redirect: /redirect-target +--- + +This page should redirect to `/redirect-target`. diff --git a/playground/document-driven/content/5.redirect-target.md b/playground/document-driven/content/5.redirect-target.md new file mode 100644 index 000000000..d6cb603bc --- /dev/null +++ b/playground/document-driven/content/5.redirect-target.md @@ -0,0 +1,13 @@ +--- +navigation: false +--- + +You have been redirect to this page from `/redirect`. + +It uses: + +```md +--- +redirect: /redirect-target +--- +``` diff --git a/playground/document-driven/content/6.empty-file.md b/playground/document-driven/content/6.empty-file.md new file mode 100644 index 000000000..e69de29bb diff --git a/playground/document-driven/content/_theme.yml b/playground/document-driven/content/_theme.yml new file mode 100644 index 000000000..4cdafb27e --- /dev/null +++ b/playground/document-driven/content/_theme.yml @@ -0,0 +1 @@ +test: 'Hello World' diff --git a/playground/app.vue b/playground/document-driven/layouts/reversed.vue similarity index 78% rename from playground/app.vue rename to playground/document-driven/layouts/reversed.vue index 85c8d71e4..5a8dfd8c6 100644 --- a/playground/app.vue +++ b/playground/document-driven/layouts/reversed.vue @@ -1,8 +1,10 @@ @@ -10,5 +12,7 @@ body, html { margin: 0; padding: 0; + min-height: 100vh; + min-width: 100vw; } diff --git a/playground/document-driven/nuxt.config.ts b/playground/document-driven/nuxt.config.ts new file mode 100644 index 000000000..88146fabc --- /dev/null +++ b/playground/document-driven/nuxt.config.ts @@ -0,0 +1,17 @@ +import { defineNuxtConfig } from 'nuxt' + +export default defineNuxtConfig({ + extends: ['../shared'], + content: { + documentDriven: { + globals: { + theme: { + where: { + _id: 'content:_theme.yml' + }, + without: ['_'] + } + } + } + } +}) diff --git a/playground/pages/[...slug].vue b/playground/pages/[...slug].vue deleted file mode 100644 index 693f07c87..000000000 --- a/playground/pages/[...slug].vue +++ /dev/null @@ -1,5 +0,0 @@ - diff --git a/playground/pages/sandbox.vue b/playground/pages/sandbox.vue deleted file mode 100644 index 5f954037a..000000000 --- a/playground/pages/sandbox.vue +++ /dev/null @@ -1,26 +0,0 @@ - diff --git a/playground/components/NavItem.vue b/playground/shared/components/NavItem.vue similarity index 100% rename from playground/components/NavItem.vue rename to playground/shared/components/NavItem.vue diff --git a/playground/components/NuxtLoadingBar.vue b/playground/shared/components/NuxtLoadingBar.vue similarity index 100% rename from playground/components/NuxtLoadingBar.vue rename to playground/shared/components/NuxtLoadingBar.vue diff --git a/playground/components/PageNav.vue b/playground/shared/components/PageNav.vue similarity index 52% rename from playground/components/PageNav.vue rename to playground/shared/components/PageNav.vue index 503cb29ab..c412fde55 100644 --- a/playground/components/PageNav.vue +++ b/playground/shared/components/PageNav.vue @@ -15,18 +15,18 @@ watch( diff --git a/playground/components/PagePrevNext.vue b/playground/shared/components/PagePrevNext.vue similarity index 100% rename from playground/components/PagePrevNext.vue rename to playground/shared/components/PagePrevNext.vue diff --git a/playground/pages/playground.vue b/playground/shared/components/Playground.vue similarity index 94% rename from playground/pages/playground.vue rename to playground/shared/components/Playground.vue index 1e4f58e97..d34277f20 100644 --- a/playground/pages/playground.vue +++ b/playground/shared/components/Playground.vue @@ -72,6 +72,7 @@ const tabs = ref(['Preview', 'AST']) {{ name }} + - diff --git a/playground/components/content/Alert.vue b/playground/shared/components/content/Alert.vue similarity index 100% rename from playground/components/content/Alert.vue rename to playground/shared/components/content/Alert.vue diff --git a/playground/components/content/MarkdownBetween.vue b/playground/shared/components/content/MarkdownBetween.vue similarity index 100% rename from playground/components/content/MarkdownBetween.vue rename to playground/shared/components/content/MarkdownBetween.vue diff --git a/playground/components/content/PageList.vue b/playground/shared/components/content/PageList.vue similarity index 100% rename from playground/components/content/PageList.vue rename to playground/shared/components/content/PageList.vue diff --git a/playground/components/content/YamlList.vue b/playground/shared/components/content/YamlList.vue similarity index 100% rename from playground/components/content/YamlList.vue rename to playground/shared/components/content/YamlList.vue diff --git a/playground/shared/layouts/default.vue b/playground/shared/layouts/default.vue new file mode 100644 index 000000000..454a8f9b8 --- /dev/null +++ b/playground/shared/layouts/default.vue @@ -0,0 +1,18 @@ + + + diff --git a/playground/nuxt.config.ts b/playground/shared/nuxt.config.ts similarity index 60% rename from playground/nuxt.config.ts rename to playground/shared/nuxt.config.ts index 85cc6712d..0d02af73b 100644 --- a/playground/nuxt.config.ts +++ b/playground/shared/nuxt.config.ts @@ -1,6 +1,10 @@ +import { fileURLToPath } from 'url' import { defineNuxtConfig } from 'nuxt' import { resolve } from 'pathe' -import contentModule from '../src/module' // eslint-disable-line +import contentModule from '../../src/module' // eslint-disable-line + +const themeDir = fileURLToPath(new URL('./', import.meta.url)) +const resolveThemeDir = (path: string) => resolve(themeDir, path) export default defineNuxtConfig({ app: { @@ -13,19 +17,17 @@ export default defineNuxtConfig({ ] } }, - rootDir: __dirname, + components: [ + { + global: true, + path: resolveThemeDir('./components') + } + ], modules: [contentModule, '@nuxthq/admin'], content: { navigation: { fields: ['icon'] }, - sources: { - 'translation-fa': { - prefix: '/fa', - driver: 'fs', - base: resolve(__dirname, 'content-fa') - } - }, highlight: { theme: 'one-dark-pro', preload: ['json', 'js', 'ts', 'html', 'css', 'vue'] diff --git a/playground/shared/pages/404/index.vue b/playground/shared/pages/404/index.vue new file mode 100644 index 000000000..8b6497af4 --- /dev/null +++ b/playground/shared/pages/404/index.vue @@ -0,0 +1,6 @@ + diff --git a/playground/server/api/parse.ts b/playground/shared/server/api/parse.ts similarity index 100% rename from playground/server/api/parse.ts rename to playground/shared/server/api/parse.ts diff --git a/scripts/fixture.sh b/scripts/fixture.sh new file mode 100755 index 000000000..a46462b1b --- /dev/null +++ b/scripts/fixture.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +CWD=$(pwd) +ARG1=${1:-basic} +FIXTURE_PATH=$CWD/test/fixtures/$ARG1 + +(cd $FIXTURE_PATH && npx nuxi dev) diff --git a/scripts/playground.sh b/scripts/playground.sh new file mode 100755 index 000000000..084404345 --- /dev/null +++ b/scripts/playground.sh @@ -0,0 +1,13 @@ +#!/bin/bash + +CWD=$(pwd) +ARG1=${1:-basic} +PLAYGROUND_PATH=$CWD/playground/$ARG1 + +if [[ $ARG1 == docs ]] +then +PLAYGROUND_PATH=$CWD/docs +(cd $PLAYGROUND_PATH && npx nuxi dev) +else +(cd $PLAYGROUND_PATH && npx nuxi dev) +fi diff --git a/scripts/test.sh b/scripts/test.sh new file mode 100755 index 000000000..1c2a99ecb --- /dev/null +++ b/scripts/test.sh @@ -0,0 +1,21 @@ +#!/bin/bash + +CWD=$(pwd) +ARG1=${1} + +# Remove all .nuxt directories in the test/fixtures directory +for d in $(find $CWD/test/fixtures -maxdepth 1 -mindepth 1 -type d); do + cd $d + rm -rf .nuxt + npx nuxi prepare + cd $CWD +done + +if [[ $ARG1 ]] +then + echo "npx vitest run -t $ARG1" + (npx vitest run -t $ARG1.test) +else + echo "npx vitest run" + (npx vitest run) +fi diff --git a/src/module.ts b/src/module.ts index 09d05703a..8ffc553a8 100644 --- a/src/module.ts +++ b/src/module.ts @@ -27,7 +27,7 @@ import { PROSE_TAGS, useContentMounts } from './utils' -import type { MarkdownPlugin } from './runtime/types' +import type { MarkdownPlugin, QueryBuilderParams } from './runtime/types' export type MountOptions = { driver: 'fs' | 'http' | string @@ -163,7 +163,20 @@ export interface ModuleOptions { * * @default undefined */ - defaultLocale: string + defaultLocale?: string + /** + * Document-driven mode config + */ + documentDriven: boolean | { + page: boolean + navigation: boolean + surround: boolean + globals: { + [key: string]: QueryBuilderParams + } + layoutFallbacks: string[] + injectPage: boolean + } } interface ContentContext extends ModuleOptions { @@ -204,7 +217,8 @@ export default defineNuxtModule({ csv: {}, navigation: { fields: [] - } + }, + documentDriven: false }, async setup (options, nuxt) { const { resolve } = createResolver(import.meta.url) @@ -234,21 +248,27 @@ export default defineNuxtModule({ } // Add Content plugin - addPlugin(resolveRuntimeModule('./plugin')) + addPlugin(resolveRuntimeModule('./plugins/ws')) nuxt.hook('nitro:config', (nitroConfig) => { - // Add server handlers + // Init Nitro context + nitroConfig.prerender = nitroConfig.prerender || {} + nitroConfig.prerender.routes = nitroConfig.prerender.routes || [] nitroConfig.handlers = nitroConfig.handlers || [] + + // Add server handlers nitroConfig.handlers.push( { method: 'get', route: `/api/${options.base}/query/:qid`, handler: resolveRuntimeModule('./server/api/query') - }, { + }, + { method: 'get', route: `/api/${options.base}/query`, handler: resolveRuntimeModule('./server/api/query') - }, { + }, + { method: 'get', route: `/api/${options.base}/cache`, handler: resolveRuntimeModule('./server/api/cache') @@ -273,6 +293,7 @@ export default defineNuxtModule({ nitroConfig.bundledStorage = nitroConfig.bundledStorage || [] nitroConfig.bundledStorage.push('/cache/content') + // @ts-ignore nitroConfig.externals = defu(typeof nitroConfig.externals === 'object' ? nitroConfig.externals : {}, { inline: [ // Inline module runtime in Nitro bundle @@ -280,6 +301,7 @@ export default defineNuxtModule({ ] }) + nitroConfig.alias = nitroConfig.alias || {} nitroConfig.alias['#content/server'] = resolveRuntimeModule('./server') nitroConfig.virtual = nitroConfig.virtual || {} @@ -296,6 +318,7 @@ export default defineNuxtModule({ // Register composables addAutoImport([ { name: 'queryContent', as: 'queryContent', from: resolveRuntimeModule('./composables/query') }, + { name: 'useContentHelpers', as: 'useContentHelpers', from: resolveRuntimeModule('./composables/helpers') }, { name: 'withContentBase', as: 'withContentBase', from: resolveRuntimeModule('./composables/utils') }, { name: 'useUnwrap', as: 'useUnwrap', from: resolveRuntimeModule('./composables/utils') } ]) @@ -353,6 +376,7 @@ export default defineNuxtModule({ addAutoImport({ name: 'fetchContentNavigation', as: 'fetchContentNavigation', from: resolveRuntimeModule('./composables/navigation') }) nuxt.hook('nitro:config', (nitroConfig) => { + nitroConfig.handlers = nitroConfig.handlers || [] nitroConfig.handlers.push({ method: 'get', route: `/api/${options.base}/navigation/:qid`, @@ -371,6 +395,7 @@ export default defineNuxtModule({ contentContext.transformers.push(resolveRuntimeModule('./server/transformers/shiki')) nuxt.hook('nitro:config', (nitroConfig) => { + nitroConfig.handlers = nitroConfig.handlers || [] nitroConfig.handlers.push({ method: 'post', route: `/api/${options.base}/highlight`, @@ -379,6 +404,69 @@ export default defineNuxtModule({ }) } + // Register document-driven + if (options.documentDriven) { + // Enable every feature by default + const defaultDocumentDrivenConfig = { + page: true, + navigation: true, + surround: true, + globals: { + theme: { + where: [ + { + _id: 'content:_theme.yml' + } + ], + without: ['_'] + } + }, + layoutFallbacks: ['theme'], + injectPage: true + } + + // If set to true, use defaults else merge defaults with user config + if (options.documentDriven === true) { + options.documentDriven = defaultDocumentDrivenConfig + } else { + options.documentDriven = { + ...defaultDocumentDrivenConfig, + ...options.documentDriven + } + } + + // Support layout field by default + if (options.navigation) { + options.navigation.fields.push('layout') + } + + addAutoImport([ + { name: 'useContentState', as: 'useContentState', from: resolveRuntimeModule('./composables/content') }, + { name: 'useContent', as: 'useContent', from: resolveRuntimeModule('./composables/content') } + ]) + + addPlugin(resolveRuntimeModule('./plugins/documentDriven')) + + if (options.documentDriven.injectPage) { + nuxt.options.pages = true + + nuxt.hook('pages:extend', (pages) => { + pages.unshift({ + name: 'slug', + path: '/:slug(.*)*', + file: resolveRuntimeModule('./pages/document-driven.vue'), + children: [] + }) + }) + } + } else { + // Noop useContent + addAutoImport([ + { name: 'useContentDisabled', as: 'useContentState', from: resolveRuntimeModule('./composables/utils') }, + { name: 'useContentDisabled', as: 'useContent', from: resolveRuntimeModule('./composables/utils') } + ]) + } + // @ts-ignore await nuxt.callHook('content:context', contentContext) @@ -400,8 +488,11 @@ export default defineNuxtModule({ // Tags will use in markdown renderer for component replacement tags: contentContext.markdown.tags as any, highlight: options.highlight as any, - wsUrl: '' + wsUrl: '', + // Document-driven configuration + documentDriven: options.documentDriven as ModuleOptions['documentDriven'] }) + // Context will use in server nuxt.options.runtimeConfig.content = { cacheVersion: CACHE_VERSION, diff --git a/src/runtime/components/DocumentDrivenEmpty.ts b/src/runtime/components/DocumentDrivenEmpty.ts new file mode 100644 index 000000000..e5695b6cf --- /dev/null +++ b/src/runtime/components/DocumentDrivenEmpty.ts @@ -0,0 +1,21 @@ +import { defineComponent, h } from 'vue' +import type { PropType } from 'vue' +import { ParsedContent } from '../types' + +/** + * Used in `src/runtime/pages/document-driven.vue` + */ +export default defineComponent({ + props: { + value: { + type: Object as PropType, + required: true + } + }, + render ({ value }) { + return h('div', undefined, [ + h('p', 'Document is empty'), + h('p', `Add content to it by opening ${value._source}/${value._file} file.`) + ]) + } +}) diff --git a/src/runtime/components/DocumentDrivenNotFound.ts b/src/runtime/components/DocumentDrivenNotFound.ts new file mode 100644 index 000000000..9d1bdb50b --- /dev/null +++ b/src/runtime/components/DocumentDrivenNotFound.ts @@ -0,0 +1,10 @@ +import { defineComponent, h } from 'vue' + +/** + * Used in `src/runtime/pages/document-driven.vue` + */ +export default defineComponent({ + render () { + return h('div', 'Document not found') + } +}) diff --git a/src/runtime/composables/content.ts b/src/runtime/composables/content.ts new file mode 100644 index 000000000..c8ac97f30 --- /dev/null +++ b/src/runtime/composables/content.ts @@ -0,0 +1,83 @@ +import type { NavItem, ParsedContent } from '../types' +import { computed, useState } from '#imports' + +export const useContentState = () => { + /** + * Current page complete data. + */ + const page = useState('content-document-driven-page') + + /** + * Navigation tree from root of app. + */ + const navigation = useState('content-document-driven-navigation') + + /** + * Previous and next page data. + * Format: [prev, next] + */ + const surround = useState[]>('content-document-driven-page-surround') + + /** + * Globally loaded content files. + * Format: { [key: string]: ParsedContent } + */ + const globals = useState>('content-document-driven-globals', () => ({})) + + return { + page, + navigation, + surround, + globals + } +} + +export const useContent = () => { + const { navigation, page, surround, globals } = useContentState() + + /** + * Table of contents from `page`. + */ + const toc = computed(() => page?.value?.body?.toc) + + /** + * Content type from `page`. + */ + const type = computed(() => page.value?.meta?.type) + + /** + * Excerpt from `page`. + */ + const excerpt = computed(() => page.value?.excerpt) + + /** + * Layout type from `page`. + */ + const layout = computed(() => page.value?.meta?.layout) + + /** + * Next page from `surround`. + */ + const next = computed(() => surround.value?.[1]) + + /** + * Previous page from `surround`. + */ + const prev = computed(() => surround.value?.[0]) + + return { + // Refs + globals, + navigation, + surround, + page, + // From page + excerpt, + toc, + type, + layout, + // From surround + next, + prev + } +} diff --git a/src/runtime/composables/helpers.ts b/src/runtime/composables/helpers.ts new file mode 100644 index 000000000..fc3624f5e --- /dev/null +++ b/src/runtime/composables/helpers.ts @@ -0,0 +1,71 @@ +import type { NavItem } from '../types' + +/** + * Find first child link from a navigation node. + */ +const navBottomLink = (link: NavItem) => { + if (!link.children) { return link._path } + + for (const child of link?.children || []) { + const result = navBottomLink(child) + if (result) { return result } + } +} + +/** + * Find current navigation directory node from a path. + */ +const navDirFromPath = (path: string, tree: NavItem[]) => { + for (const file of tree) { + if (file._path === path && !file._id) { return file.children } + + if (file.children) { + const result = navDirFromPath(path, file.children) + if (result) { return result } + } + } +} + +/** + * Find a navigation page node from a path. + */ +const navPageFromPath = (path: string, tree: NavItem[]) => { + for (const file of tree) { + if (file._path === path) { return file } + + if (file.children) { + const result = navPageFromPath(path, file.children) + if (result) { return result } + } + } +} + +/** + * Find a nav field node from a path. + */ +const navKeyFromPath = (path: string, key: string, tree: NavItem[]) => { + let value: any + + const goDeep = (path: string, tree: NavItem[]) => { + for (const file of tree) { + if (path.startsWith(file._path) && file[key]) { value = file[key] } + + if (file._path === path) { return } + + if (file.children) { goDeep(path, file.children) } + } + } + + goDeep(path, tree) + + return value +} + +export const useContentHelpers = () => { + return { + navBottomLink, + navDirFromPath, + navPageFromPath, + navKeyFromPath + } +} diff --git a/src/runtime/composables/navigation.ts b/src/runtime/composables/navigation.ts index 1d236e886..75bdd0b92 100644 --- a/src/runtime/composables/navigation.ts +++ b/src/runtime/composables/navigation.ts @@ -12,6 +12,7 @@ export const fetchContentNavigation = (queryBuilder?: QueryBuilder | QueryBuilde const apiPath = withContentBase(params ? `/navigation/${hash(params)}` : '/navigation') + // Add `prefetch` to `` in production if (!process.dev && process.server) { useHead({ link: [ @@ -19,6 +20,7 @@ export const fetchContentNavigation = (queryBuilder?: QueryBuilder | QueryBuilde ] }) } + return $fetch>(apiPath, { method: 'GET', responseType: 'json', diff --git a/src/runtime/composables/utils.ts b/src/runtime/composables/utils.ts index 62aa7061d..4062ed63f 100644 --- a/src/runtime/composables/utils.ts +++ b/src/runtime/composables/utils.ts @@ -8,3 +8,14 @@ export const useUnwrap = () => ({ unwrap, flatUnwrap }) + +export const useContentDisabled = () => { + // Console warnings + // eslint-disable-next-line no-console + console.warn('useContent is only accessible when you are using `documentDriven` mode.') + // eslint-disable-next-line no-console + console.warn('Learn more by visiting: https://content.nuxtjs.org/guide/writing/document-driven') + + // Break app + throw new Error('useContent is only accessible when you are using `documentDriven` mode.') +} diff --git a/src/runtime/pages/document-driven.vue b/src/runtime/pages/document-driven.vue new file mode 100644 index 000000000..6d5da2d80 --- /dev/null +++ b/src/runtime/pages/document-driven.vue @@ -0,0 +1,76 @@ + + + + + diff --git a/src/runtime/plugins/documentDriven.ts b/src/runtime/plugins/documentDriven.ts new file mode 100644 index 000000000..297ff95c2 --- /dev/null +++ b/src/runtime/plugins/documentDriven.ts @@ -0,0 +1,229 @@ +import type { RouteLocationNormalized, RouteLocationNormalizedLoaded } from 'vue-router' +// @ts-ignore +import { useRuntimeConfig, addRouteMiddleware } from '#app' +import { NavItem, ParsedContent } from '../types' +// @ts-ignore +import { defineNuxtPlugin, queryContent, useContentHelpers, useContentState, fetchContentNavigation, useRoute } from '#imports' +// @ts-ignore +import layouts from '#build/layouts' + +export default defineNuxtPlugin((nuxt) => { + const { documentDriven: moduleOptions } = useRuntimeConfig()?.public?.content + + /** + * Finds a layout value from a cascade of objects. + */ + const findLayout = (page: ParsedContent, navigation: NavItem[], globals: Record) => { + // Page `layout` key has priority + if (page && page?.layout) { return page.layout } + + // Resolve key from navigation + if (navigation && page) { + const { navKeyFromPath } = useContentHelpers() + const layoutFromNav = navKeyFromPath(page._path, 'layout', navigation) + if (layoutFromNav) { return layoutFromNav } + } + + // Resolve key from globals fallback + if (moduleOptions.layoutFallbacks && globals) { + let layoutFallback + for (const fallback of moduleOptions.layoutFallbacks) { + if (globals[fallback] && globals[fallback].layout) { + layoutFallback = globals[fallback].layout + break + } + } + if (layoutFallback) { return layoutFallback } + } + + return 'default' + } + + const refresh = async (to: RouteLocationNormalized | RouteLocationNormalizedLoaded, force: boolean = false) => { + const { navigation, page, globals, surround } = useContentState() + + const promises: (() => Promise | undefined)[] = [] + + /** + * `navigation` + */ + if (moduleOptions.navigation) { + const navigationQuery = () => { + const { navigation } = useContentState() + + if (navigation.value && !force) { return navigation.value } + + return fetchContentNavigation() + .then((_navigation) => { + navigation.value = _navigation + return _navigation + }) + .catch((_) => { + // eslint-disable-next-line no-console + console.log('Could not fetch navigation!') + }) + } + + promises.push(navigationQuery) + } + + /** + * `globals` + */ + if (moduleOptions.globals) { + const globalsQuery = () => { + const { globals } = useContentState() + + if ( + typeof moduleOptions.globals === 'object' && Array.isArray(moduleOptions.globals) + ) { + // eslint-disable-next-line no-console + console.log('Globals must be a list of keys with QueryBuilderParams as a value.') + return + } + + return Promise.all( + Object.entries(moduleOptions.globals).map( + ([key, query]: [string, any]) => { + // Avoid fetching same file twice + if (!force && globals.value[key]) { return globals.value[key] } + + // Supports `find` if passed as `query: 'find'` in the query definition. + let type = 'findOne' + if (query?.type) { type = query.type } + + return queryContent(query)[type]().catch(() => { + // eslint-disable-next-line no-console + console.log(`Could not find globals key: ${key}`) + }) + } + ) + ).then( + (values) => { + return values.reduce( + (acc, value, index) => { + const key = Object.keys(moduleOptions.globals)[index] + + acc[key] = value + + return acc + }, {}) + } + ) + } + + promises.push(globalsQuery) + } + + /** + * `page` + */ + if (moduleOptions.page) { + const pageQuery = () => { + const { page } = useContentState() + + // Return same page as page is already loaded + if (!force && page.value && page.value._path === to.path) { + return page.value + } + + return queryContent() + .where({ _path: to.path }) + .findOne() + .catch(() => { + // eslint-disable-next-line no-console + console.log(`Could not find page: ${to.path}`) + }) + } + + promises.push(pageQuery) + } + + /** + * `surround` + */ + if (moduleOptions.surround) { + const surroundQuery = () => { + // Return same surround as page is already loaded + if (!force && page.value && page.value._path === to.path) { + return surround.value + } + + return queryContent() + .where({ + _partial: { $not: true }, + navigation: { $not: false } + }) + // Exclude `body` for `surround` + .without(['body']) + .findSurround(to.path) + .catch(() => { + // eslint-disable-next-line no-console + console.log(`Could not find surrounding pages for: ${to.path}`) + }) + } + + promises.push(surroundQuery) + } + + return await Promise.all(promises.map(promise => promise())).then(async ([ + _navigation, + _globals, + _page, + _surround + ]) => { + if (_navigation) { + navigation.value = _navigation + } else { + navigation.value = [] + } + + if (_globals) { + globals.value = _globals + } else { + globals.value = {} + } + + if (_surround) { + surround.value = _surround + } else { + surround.value = [] + } + + if (_page) { + // Use `redirect` key to redirect to another page + if (_page?.redirect) { return _page?.redirect } + + // Update values + page.value = _page + } else { + page.value = undefined + } + + // Find used layout + const layoutName = findLayout(_page, _navigation, _globals) + + // Prefetch layout component + const layout = layouts[layoutName] + if (layout && layout?.__asyncLoader && !layout.__asyncResolved) { + await layout.__asyncLoader() + } + + // Apply layout + to.meta.layout = layoutName + }) + } + + // Route middleware + addRouteMiddleware(async (to) => { + // TODO: Remove this (https://github.com/nuxt/framework/pull/5274) + if (to.path.includes('favicon.ico')) { return } + + const redirect = await refresh(to, false) + + if (redirect) { return redirect } + }) + + // @ts-ignore - Refresh on client-side + nuxt.hook('app:data:refresh', async () => process.client && await refresh(useRoute(), true)) +}) diff --git a/src/runtime/plugin.ts b/src/runtime/plugins/ws.ts similarity index 71% rename from src/runtime/plugin.ts rename to src/runtime/plugins/ws.ts index d6c690f71..de9762203 100644 --- a/src/runtime/plugin.ts +++ b/src/runtime/plugins/ws.ts @@ -5,6 +5,6 @@ export default defineNuxtPlugin(() => { if (process.client && publicConfig.content.wsUrl) { // Connect to websocket - import('./composables/web-socket').then(({ useContentWebSocket }) => useContentWebSocket()) + import('../composables/web-socket').then(({ useContentWebSocket }) => useContentWebSocket()) } }) diff --git a/test/__snapshots__/basic.test.ts.snap b/test/__snapshots__/basic.test.ts.snap index e22deed6e..c26a8da8e 100644 --- a/test/__snapshots__/basic.test.ts.snap +++ b/test/__snapshots__/basic.test.ts.snap @@ -1,5 +1,79 @@ // Vitest Snapshot v1 +exports[`Basic usage > Get contents index > basic-index-body 1`] = ` +{ + "children": [ + { + "children": [ + { + "type": "text", + "value": "Index", + }, + ], + "props": { + "id": "index", + }, + "tag": "h1", + "type": "element", + }, + ], + "toc": { + "depth": 2, + "links": [], + "searchDepth": 2, + "title": "", + }, + "type": "root", +} +`; + +exports[`Basic usage > Navigation > Get cats navigation > basic-navigation-cats 1`] = ` +[ + { + "_path": "/cats", + "children": [ + { + "_path": "/cats/bombay", + "title": "Bombay", + }, + { + "_path": "/cats", + "title": "Cats", + }, + { + "_path": "/cats/persian", + "title": "Persian", + }, + { + "_path": "/cats/ragdoll", + "title": "Ragdoll", + }, + ], + "title": "Cats list", + }, +] +`; + +exports[`Basic usage > Navigation > Get dogs navigation > basic-navigation-dogs 1`] = ` +[ + { + "_path": "/dogs", + "children": [ + { + "_path": "/dogs/bulldog", + "title": "Bulldog", + }, + { + "_path": "/dogs/german-shepherd", + "title": "German Shepherd", + }, + ], + "icon": "🐶", + "title": "Dogs List", + }, +] +`; + exports[`fixtures:basic > Get contents index > basic-index-body 1`] = ` { "children": [ diff --git a/test/basic.test.ts b/test/basic.test.ts index 6c1611fab..02a40cc8c 100644 --- a/test/basic.test.ts +++ b/test/basic.test.ts @@ -12,14 +12,14 @@ import { testCSVParser } from './features/parser-csv' import { testRegex } from './features/regex' import { testMarkdownParserExcerpt } from './features/parser-markdown-excerpt' import { testParserHooks } from './features/parser-hooks' -import { testModuleOption } from './features/module-options' +import { testModuleOptions } from './features/module-options' import { testContentQuery } from './features/content-query' import { testHighlighter } from './features/highlighter' import { testMarkdownRenderer } from './features/renderer-markdown' const spyConsoleWarn = vi.spyOn(global.console, 'warn') -describe('fixtures:basic', async () => { +describe('Basic usage', async () => { await setup({ rootDir: fileURLToPath(new URL('./fixtures/basic', import.meta.url)), server: true @@ -87,30 +87,30 @@ describe('fixtures:basic', async () => { }) }) - test('features:multi-part-path', async () => { + test('Multi part path', async () => { const html = await $fetch('/features/multi-part-path') expect(html).contains('Persian') }) - test('features: head management (if same path)', async () => { + test(' head management (if same path)', async () => { const html = await $fetch('/head') expect(html).contains('Head overwritten') expect(html).contains('') expect(html).contains('') }) - test('features: head management (not same path)', async () => { + test(' head management (not same path)', async () => { const html = await $fetch('/bypass-head') expect(html).not.contains('Head overwritten') expect(html).not.contains('') expect(html).not.contains('') }) - test('partial:specials-chars', async () => { + test('Partials specials chars', async () => { const html = await $fetch('/_partial/content-(v2)') expect(html).contains('Content (v2)') }) - test('warn invalid file name', () => { + test('Warning for invalid file name', () => { expect(spyConsoleWarn).toHaveBeenCalled() expect(spyConsoleWarn).toHaveBeenCalledWith('Ignoring [content:with-\'invalid\'-char.md]. File name should not contain any of the following characters: \', ", ?, #, /') }) @@ -138,7 +138,7 @@ describe('fixtures:basic', async () => { testParserHooks() - testModuleOption() + testModuleOptions() testHighlighter() }) diff --git a/test/document-driven.test.ts b/test/document-driven.test.ts new file mode 100644 index 000000000..bef0c3cba --- /dev/null +++ b/test/document-driven.test.ts @@ -0,0 +1,16 @@ +import { fileURLToPath } from 'url' +import { test, describe, expect } from 'vitest' +import { setup, $fetch } from '@nuxt/test-utils' + +describe('fixtures:document-driven', async () => { + await setup({ + rootDir: fileURLToPath(new URL('./fixtures/document-driven', import.meta.url)), + server: true + }) + + test(' from front-matter', async () => { + const html = await $fetch('/') + + expect(html).contains('Home | Document Driven Fixture') + }) +}) diff --git a/test/features/content-query.ts b/test/features/content-query.ts index 31f317290..ef0d0dc3c 100644 --- a/test/features/content-query.ts +++ b/test/features/content-query.ts @@ -2,7 +2,7 @@ import { describe, expect, test } from 'vitest' import { $fetch } from '@nuxt/test-utils' export const testContentQuery = () => { - describe('content-query', () => { + describe('Content Queries', () => { test('Find index', async () => { const content = await $fetch('/') diff --git a/test/features/highlighter.ts b/test/features/highlighter.ts index d986961cc..065c01794 100644 --- a/test/features/highlighter.ts +++ b/test/features/highlighter.ts @@ -8,7 +8,7 @@ const content = [ ].join('\n') export const testHighlighter = () => { - describe('highlighter', () => { + describe('Highlighter', () => { test('themed', async () => { const parsed = await $fetch('/api/parse', { method: 'POST', diff --git a/test/features/mdc-component.ts b/test/features/mdc-component.ts index cd47685c1..4b6fd195b 100644 --- a/test/features/mdc-component.ts +++ b/test/features/mdc-component.ts @@ -2,8 +2,8 @@ import { describe, expect, test } from 'vitest' import { $fetch } from '@nuxt/test-utils' export const testMDCComponent = () => { - describe('mdc-component', () => { - test('normal/binded props', async () => { + describe('MDC Components', () => { + test('Normal or binded props', async () => { const content = await $fetch('/_partial/mdc-props') // Normal Prop @@ -17,7 +17,7 @@ export const testMDCComponent = () => { ].join('\n')) }) - test('normal/binded props (inline component)', async () => { + test('Normal or binded props (inline component)', async () => { const content = await $fetch('/_partial/mdc-props-inline') // Normal Prop diff --git a/test/features/module-options.ts b/test/features/module-options.ts index 2720940ae..b1b9bfcf7 100644 --- a/test/features/module-options.ts +++ b/test/features/module-options.ts @@ -1,9 +1,9 @@ import { describe, test, expect } from 'vitest' import { $fetch } from '@nuxt/test-utils' -export const testModuleOption = () => { - describe('module options', () => { - test('overwrite `remark-emoji` options: enable emoticon', async () => { +export const testModuleOptions = () => { + describe('Module Options', () => { + test('Overwrite `remark-emoji` options: enable emoticon', async () => { const parsed = await $fetch('/api/parse', { method: 'POST', body: { @@ -16,7 +16,7 @@ export const testModuleOption = () => { expect(parsed.body.children[0].children[0].value).toContain('😃') }) - test('disable `remark-gfm`', async () => { + test('Disable `remark-gfm`', async () => { const parsed = await $fetch('/api/parse', { method: 'POST', body: { @@ -29,7 +29,7 @@ export const testModuleOption = () => { expect(parsed.body.children[0].children[0].value).toBe('~one~') }) - test('add `remark-oembed`', async () => { + test('Add `remark-oembed`', async () => { const parsed = await $fetch('/api/parse', { method: 'POST', body: { @@ -42,7 +42,7 @@ export const testModuleOption = () => { expect(parsed.body.children[0].props.className).toContain('remark-oembed-you-tube') }) - test('add `rehype-figure`', async () => { + test('Add `rehype-figure`', async () => { const parsed = await $fetch('/api/parse', { method: 'POST', body: { diff --git a/test/features/navigation.ts b/test/features/navigation.ts index 64be6c6c7..3df3f6749 100644 --- a/test/features/navigation.ts +++ b/test/features/navigation.ts @@ -4,7 +4,7 @@ import { hash } from 'ohash' import { jsonStringify } from '../../src/runtime/utils/json' export const testNavigation = () => { - describe('navigation', () => { + describe('Navigation', () => { test('Get navigation', async () => { const query = { where: [{ _locale: 'en' }] } const list = await $fetch(`/api/_content/navigation/${hash(query)}`, { diff --git a/test/features/parser-csv.ts b/test/features/parser-csv.ts index 0b4f44746..b94f226c5 100644 --- a/test/features/parser-csv.ts +++ b/test/features/parser-csv.ts @@ -6,8 +6,8 @@ const csv = `a,b,c 4,5,6` export const testCSVParser = () => { - describe('parser:csv', () => { - test('simple', async () => { + describe('Parser (.csv)', () => { + test('Basic usage', async () => { const parsed = await $fetch('/api/parse', { method: 'POST', body: { diff --git a/test/features/parser-hooks.ts b/test/features/parser-hooks.ts index ba7e63009..2e24e0a19 100644 --- a/test/features/parser-hooks.ts +++ b/test/features/parser-hooks.ts @@ -2,7 +2,7 @@ import { describe, test, expect, assert } from 'vitest' import { $fetch } from '@nuxt/test-utils' export const testParserHooks = () => { - describe('parser:hooks', () => { + describe('Parser (hooks)', () => { test('beforeParse', async () => { const parsed = await $fetch('/api/parse', { method: 'POST', diff --git a/test/features/parser-json.ts b/test/features/parser-json.ts index 613223851..d73462438 100644 --- a/test/features/parser-json.ts +++ b/test/features/parser-json.ts @@ -23,7 +23,7 @@ No \\n's!", }` export const testJSONParser = () => { - describe('parser:json', () => { + describe('Parser (json)', () => { test('key:value', async () => { const parsed = await $fetch('/api/parse', { method: 'POST', @@ -37,6 +37,7 @@ export const testJSONParser = () => { assert(parsed._id === 'content:index.json') assert(parsed.key === 'value') }) + test('array', async () => { const parsed = await $fetch('/api/parse', { method: 'POST', diff --git a/test/features/parser-markdown-excerpt.ts b/test/features/parser-markdown-excerpt.ts index 81a0552e3..d6ba176e3 100644 --- a/test/features/parser-markdown-excerpt.ts +++ b/test/features/parser-markdown-excerpt.ts @@ -2,7 +2,7 @@ import { describe, test, expect, assert } from 'vitest' import { $fetch } from '@nuxt/test-utils' export const testMarkdownParserExcerpt = () => { - describe('parser:markdown:excerpt', () => { + describe('Parser (.md excerpt)', () => { test('Index file', async () => { const parsed = await $fetch('/api/parse', { method: 'POST', diff --git a/test/features/parser-markdown.ts b/test/features/parser-markdown.ts index a6200e2d5..5cf300193 100644 --- a/test/features/parser-markdown.ts +++ b/test/features/parser-markdown.ts @@ -3,7 +3,7 @@ import { $fetch } from '@nuxt/test-utils' import { visit } from 'unist-util-visit' export const testMarkdownParser = () => { - describe('parser:markdown', () => { + describe('Parser (.md)', () => { test('Index file', async () => { const parsed = await $fetch('/api/parse', { method: 'POST', diff --git a/test/features/parser-yaml.ts b/test/features/parser-yaml.ts index 5b26cd710..32ba9ddf5 100644 --- a/test/features/parser-yaml.ts +++ b/test/features/parser-yaml.ts @@ -2,7 +2,7 @@ import { describe, test, expect, assert } from 'vitest' import { $fetch } from '@nuxt/test-utils' export const testYamlParser = () => { - describe('parser:yaml', () => { + describe('Parser (.yml)', () => { test('key:value', async () => { const parsed = await $fetch('/api/parse', { method: 'POST', diff --git a/test/features/query/match.test.ts b/test/features/query/match.test.ts index 30b5e5013..aabc69517 100644 --- a/test/features/query/match.test.ts +++ b/test/features/query/match.test.ts @@ -13,7 +13,7 @@ describe('Match', () => { nested: { users: ['Mahatma', 'Steve', 'Woodrow'] } } - describe('string contains', () => { + describe('String contains', () => { test('$contains string', () => { expect(match(item, { name: { $contains: 'a' } })).toBe(true) expect(match(item, { 'nested.users.0': { $contains: 'Maha' } })).toBe(true) diff --git a/test/features/query/utils.test.ts b/test/features/query/utils.test.ts index dd3694576..225f8ff26 100644 --- a/test/features/query/utils.test.ts +++ b/test/features/query/utils.test.ts @@ -1,7 +1,7 @@ import { describe, expect, test } from 'vitest' import { apply, get, omit, pick, sortList } from '../../../src/runtime/query/match/utils' -describe('query utils', () => { +describe('Query utils', () => { test('Omit', () => { const obj = { a: 1, diff --git a/test/features/regex.ts b/test/features/regex.ts index 120f94528..b34c2a096 100644 --- a/test/features/regex.ts +++ b/test/features/regex.ts @@ -4,7 +4,7 @@ import { hash } from 'ohash' import { jsonStringify } from '../../src/runtime/utils/json' export const testRegex = () => { - describe('regex', () => { + describe('Regex queries', () => { test('Get cats with regex', async () => { const params = { where: { _path: /^\/cats/ } } const list = await $fetch(`/api/_content/query/${hash(params)}`, { diff --git a/test/features/transformer-path-meta.ts b/test/features/transformer-path-meta.ts index 2c7353940..1d02e87a9 100644 --- a/test/features/transformer-path-meta.ts +++ b/test/features/transformer-path-meta.ts @@ -57,7 +57,7 @@ const testCases = { } export const testPathMetaTransformer = () => { - describe('transformer:path-meta', () => { + describe('Transformer (path-meta)', () => { Object.entries(testCases).forEach(([id, expected]) => { test(id, async () => { const transformed = await $fetch('/api/parse', { diff --git a/test/fixtures/basic/nuxt.config.ts b/test/fixtures/basic/nuxt.config.ts index 599054d09..e9ccd1924 100644 --- a/test/fixtures/basic/nuxt.config.ts +++ b/test/fixtures/basic/nuxt.config.ts @@ -16,7 +16,7 @@ export default defineNuxtConfig({ } ] }, - buildModules: [contentModule], + modules: [contentModule], content: { locales: ['en', 'fa'], sources: [ diff --git a/test/fixtures/document-driven/components/content/Debug.vue b/test/fixtures/document-driven/components/content/Debug.vue new file mode 100644 index 000000000..e3ff624d4 --- /dev/null +++ b/test/fixtures/document-driven/components/content/Debug.vue @@ -0,0 +1,36 @@ +<template> + <div> + <h3 style="margin: 0 !important;"> + useContent().navigation + </h3> + <pre style="padding: 1rem; border-radius: 16px;">{{ navigation }}</pre> + + <h3 style="margin: 0 !important;"> + useContent().page + </h3> + <pre style="padding: 1rem; border-radius: 16px;">{{ page }}</pre> + + <h3 style="margin: 0 !important;"> + useContent().surround + </h3> + <pre style="padding: 1rem; border-radius: 16px;">{{ surround }}</pre> + + <h3 style="margin: 0 !important;"> + useContent().globals + </h3> + <pre style="padding: 1rem; border-radius: 16px;">{{ globals }}</pre> + + <h3 style="margin: 0 !important;"> + useTheme() + </h3> + <pre style="padding: 1rem; border-radius: 16px;">{{ theme }}</pre> + </div> +</template> + +<script setup lang="ts"> +import { useContent, useTheme } from '#imports' + +const { globals, surround, page, navigation } = useContent() + +const theme = useTheme() +</script> diff --git a/test/fixtures/document-driven/composables/useTheme.ts b/test/fixtures/document-driven/composables/useTheme.ts new file mode 100644 index 000000000..653958dd7 --- /dev/null +++ b/test/fixtures/document-driven/composables/useTheme.ts @@ -0,0 +1,9 @@ +import { useContent, computed } from '#imports' + +export const useTheme = () => { + const { globals } = useContent() + + const theme = computed(() => globals.value?.theme) + + return theme +} diff --git a/test/fixtures/document-driven/content/0.index.md b/test/fixtures/document-driven/content/0.index.md new file mode 100644 index 000000000..f3c858066 --- /dev/null +++ b/test/fixtures/document-driven/content/0.index.md @@ -0,0 +1,3 @@ +# Home + +Hello World! diff --git a/test/fixtures/document-driven/content/1.debug.md b/test/fixtures/document-driven/content/1.debug.md new file mode 100644 index 000000000..c594ec203 --- /dev/null +++ b/test/fixtures/document-driven/content/1.debug.md @@ -0,0 +1,6 @@ +# Debug + +::debug +:: + +`useTheme()` is built on top of `globals` key. diff --git a/test/fixtures/document-driven/content/2.layout.md b/test/fixtures/document-driven/content/2.layout.md new file mode 100644 index 000000000..cb2e7fc50 --- /dev/null +++ b/test/fixtures/document-driven/content/2.layout.md @@ -0,0 +1,9 @@ +--- +layout: reversed +--- + +# Layout + +This page uses `reversed` layout. + +Navigation should be on bottom. diff --git a/test/fixtures/document-driven/content/_theme.yml b/test/fixtures/document-driven/content/_theme.yml new file mode 100644 index 000000000..4cdafb27e --- /dev/null +++ b/test/fixtures/document-driven/content/_theme.yml @@ -0,0 +1 @@ +test: 'Hello World' diff --git a/test/fixtures/document-driven/layouts/reversed.vue b/test/fixtures/document-driven/layouts/reversed.vue new file mode 100644 index 000000000..5a8dfd8c6 --- /dev/null +++ b/test/fixtures/document-driven/layouts/reversed.vue @@ -0,0 +1,18 @@ +<template> + <div> + <NuxtLoadingBar /> + + <NuxtPage /> + + <PageNav /> + </div> +</template> + +<style> +body, html { + margin: 0; + padding: 0; + min-height: 100vh; + min-width: 100vw; +} +</style> diff --git a/test/fixtures/document-driven/nuxt.config.ts b/test/fixtures/document-driven/nuxt.config.ts new file mode 100644 index 000000000..d3184cd66 --- /dev/null +++ b/test/fixtures/document-driven/nuxt.config.ts @@ -0,0 +1,19 @@ + +import { defineNuxtConfig } from 'nuxt' +import contentModule from '../../..' + +export default defineNuxtConfig({ + modules: [contentModule], + content: { + documentDriven: { + globals: { + theme: { + where: { + _id: 'content:_theme.yml' + }, + without: ['_'] + } + } + } + } +}) diff --git a/test/fixtures/document-driven/pages/[...slug].vue b/test/fixtures/document-driven/pages/[...slug].vue new file mode 100644 index 000000000..203b45cdb --- /dev/null +++ b/test/fixtures/document-driven/pages/[...slug].vue @@ -0,0 +1,82 @@ +<script setup lang="ts"> +import { computed, useContent, useHead, useTheme } from '#imports' + +const { page } = useContent() + +const theme = useTheme() + +const cover = computed(() => { + const cover = page.value?.cover || theme.value?.cover + + if (typeof cover === 'string') { + return { src: cover, alt: page.value?.title || theme.value.title } + } + + return cover || {} +}) + +useHead({ + bodyAttrs: { + class: [] + }, + title: page.value?.title, + titleTemplate: theme.value?.title ? '%s | Document Driven Fixture' : '%s', + meta: [ + { hid: 'description', name: 'description', content: page.value?.description || theme.value?.description }, + { hid: 'og:site_name', property: 'og:site_name', content: 'Nuxt' }, + { hid: 'og:type', property: 'og:type', content: 'website' }, + { + hid: 'twitter:site', + name: 'twitter:site', + content: theme.value?.url || theme.value?.socials?.twitter || '' + }, + { + hid: 'twitter:card', + name: 'twitter:card', + content: 'summary_large_image' + }, + { + hid: 'og:image', + property: 'og:image', + content: cover.value.src || '' + }, + { + hid: 'og:image:secure_url', + property: 'og:image:secure_url', + content: cover.value.src || '' + }, + { + hid: 'og:image:alt', + property: 'og:image:alt', + content: cover.value.alt || '' + }, + { + hid: 'twitter:image', + name: 'twitter:image', + content: cover.value.src || '' + } + ] +}) +</script> + +<template> + <div class="document-driven-content"> + <ContentRenderer v-if="page" :key="page._id" :value="page"> + <template #empty="{ value }"> + <p> + You have succesfully created the page: <span class="font-semibold">{{ value._path }}</span> + </p> + + <p> + You can now start writing into: <span class="font-semibold">{{ value._source }}/{{ value._file }}</span> + </p> + </template> + </ContentRenderer> + </div> +</template> + +<style> +.document-driven-content { + padding: 1rem; +} +</style> diff --git a/tsconfig.json b/tsconfig.json index 9dd826f99..54e1fe19a 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,3 +1,3 @@ { - "extends": "./playground/.nuxt/tsconfig.json" + "extends": "./playground/basic/.nuxt/tsconfig.json" } diff --git a/yarn.lock b/yarn.lock index 09d5aa20b..dc7eb0202 100644 --- a/yarn.lock +++ b/yarn.lock @@ -359,7 +359,7 @@ resolved "https://registry.yarnpkg.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.13.tgz#b6461fb0c2964356c469e115f504c95ad97ab88c" integrity sha512-GryiOJmNcWbovBxTfZSF71V/mXbgcV3MewDe3kIMCLyIh5e7SKAeUZs+rMnJ8jkMolZ/4/VsdBmMrw3l+VdZ3w== -"@jridgewell/trace-mapping@^0.3.7", "@jridgewell/trace-mapping@^0.3.9": +"@jridgewell/trace-mapping@^0.3.12", "@jridgewell/trace-mapping@^0.3.9": version "0.3.13" resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.13.tgz#dcfe3e95f224c8fe97a87a5235defec999aa92ea" integrity sha512-o1xbKhp9qnIAoHJSWd6KlCZfqslL4valSF81H8ImioOAxluWYWOpWkpyktY2vnt4tbrX9XYaxovq6cgowaJp2w== @@ -920,13 +920,13 @@ "@types/node" "*" "@typescript-eslint/eslint-plugin@^5.21.0": - version "5.28.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.28.0.tgz#6204ac33bdd05ab27c7f77960f1023951115d403" - integrity sha512-DXVU6Cg29H2M6EybqSg2A+x8DgO9TCUBRp4QEXQHJceLS7ogVDP0g3Lkg/SZCqcvkAP/RruuQqK0gdlkgmhSUA== + version "5.29.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.29.0.tgz#c67794d2b0fd0b4a47f50266088acdc52a08aab6" + integrity sha512-kgTsISt9pM53yRFQmLZ4npj99yGl3x3Pl7z4eA66OuTzAGC4bQB5H5fuLwPnqTKU3yyrrg4MIhjF17UYnL4c0w== dependencies: - "@typescript-eslint/scope-manager" "5.28.0" - "@typescript-eslint/type-utils" "5.28.0" - "@typescript-eslint/utils" "5.28.0" + "@typescript-eslint/scope-manager" "5.29.0" + "@typescript-eslint/type-utils" "5.29.0" + "@typescript-eslint/utils" "5.29.0" debug "^4.3.4" functional-red-black-tree "^1.0.1" ignore "^5.2.0" @@ -935,68 +935,68 @@ tsutils "^3.21.0" "@typescript-eslint/parser@^5.21.0": - version "5.28.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.28.0.tgz#639b101cad2bfb7ae16e69710ac95c42bd4eae33" - integrity sha512-ekqoNRNK1lAcKhZESN/PdpVsWbP9jtiNqzFWkp/yAUdZvJalw2heCYuqRmM5eUJSIYEkgq5sGOjq+ZqsLMjtRA== + version "5.29.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.29.0.tgz#41314b195b34d44ff38220caa55f3f93cfca43cf" + integrity sha512-ruKWTv+x0OOxbzIw9nW5oWlUopvP/IQDjB5ZqmTglLIoDTctLlAJpAQFpNPJP/ZI7hTT9sARBosEfaKbcFuECw== dependencies: - "@typescript-eslint/scope-manager" "5.28.0" - "@typescript-eslint/types" "5.28.0" - "@typescript-eslint/typescript-estree" "5.28.0" + "@typescript-eslint/scope-manager" "5.29.0" + "@typescript-eslint/types" "5.29.0" + "@typescript-eslint/typescript-estree" "5.29.0" debug "^4.3.4" -"@typescript-eslint/scope-manager@5.28.0": - version "5.28.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-5.28.0.tgz#ef9a5c68fecde72fd2ff8a84b9c120324826c1b9" - integrity sha512-LeBLTqF/he1Z+boRhSqnso6YrzcKMTQ8bO/YKEe+6+O/JGof9M0g3IJlIsqfrK/6K03MlFIlycbf1uQR1IjE+w== +"@typescript-eslint/scope-manager@5.29.0": + version "5.29.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-5.29.0.tgz#2a6a32e3416cb133e9af8dcf54bf077a916aeed3" + integrity sha512-etbXUT0FygFi2ihcxDZjz21LtC+Eps9V2xVx09zFoN44RRHPrkMflidGMI+2dUs821zR1tDS6Oc9IXxIjOUZwA== dependencies: - "@typescript-eslint/types" "5.28.0" - "@typescript-eslint/visitor-keys" "5.28.0" + "@typescript-eslint/types" "5.29.0" + "@typescript-eslint/visitor-keys" "5.29.0" -"@typescript-eslint/type-utils@5.28.0": - version "5.28.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-5.28.0.tgz#53ccc78fdcf0205ef544d843b84104c0e9c7ca8e" - integrity sha512-SyKjKh4CXPglueyC6ceAFytjYWMoPHMswPQae236zqe1YbhvCVQyIawesYywGiu98L9DwrxsBN69vGIVxJ4mQQ== +"@typescript-eslint/type-utils@5.29.0": + version "5.29.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-5.29.0.tgz#241918001d164044020b37d26d5b9f4e37cc3d5d" + integrity sha512-JK6bAaaiJozbox3K220VRfCzLa9n0ib/J+FHIwnaV3Enw/TO267qe0pM1b1QrrEuy6xun374XEAsRlA86JJnyg== dependencies: - "@typescript-eslint/utils" "5.28.0" + "@typescript-eslint/utils" "5.29.0" debug "^4.3.4" tsutils "^3.21.0" -"@typescript-eslint/types@5.28.0": - version "5.28.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.28.0.tgz#cffd9bcdce28db6daaa146e48a0be4387a6f4e9d" - integrity sha512-2OOm8ZTOQxqkPbf+DAo8oc16sDlVR5owgJfKheBkxBKg1vAfw2JsSofH9+16VPlN9PWtv8Wzhklkqw3k/zCVxA== +"@typescript-eslint/types@5.29.0": + version "5.29.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.29.0.tgz#7861d3d288c031703b2d97bc113696b4d8c19aab" + integrity sha512-X99VbqvAXOMdVyfFmksMy3u8p8yoRGITgU1joBJPzeYa0rhdf5ok9S56/itRoUSh99fiDoMtarSIJXo7H/SnOg== -"@typescript-eslint/typescript-estree@5.28.0": - version "5.28.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.28.0.tgz#3487d158d091ca2772b285e67412ff6d9797d863" - integrity sha512-9GX+GfpV+F4hdTtYc6OV9ZkyYilGXPmQpm6AThInpBmKJEyRSIjORJd1G9+bknb7OTFYL+Vd4FBJAO6T78OVqA== +"@typescript-eslint/typescript-estree@5.29.0": + version "5.29.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.29.0.tgz#e83d19aa7fd2e74616aab2f25dfbe4de4f0b5577" + integrity sha512-mQvSUJ/JjGBdvo+1LwC+GY2XmSYjK1nAaVw2emp/E61wEVYEyibRHCqm1I1vEKbXCpUKuW4G7u9ZCaZhJbLoNQ== dependencies: - "@typescript-eslint/types" "5.28.0" - "@typescript-eslint/visitor-keys" "5.28.0" + "@typescript-eslint/types" "5.29.0" + "@typescript-eslint/visitor-keys" "5.29.0" debug "^4.3.4" globby "^11.1.0" is-glob "^4.0.3" semver "^7.3.7" tsutils "^3.21.0" -"@typescript-eslint/utils@5.28.0": - version "5.28.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-5.28.0.tgz#b27a136eac300a48160b36d2aad0da44a1341b99" - integrity sha512-E60N5L0fjv7iPJV3UGc4EC+A3Lcj4jle9zzR0gW7vXhflO7/J29kwiTGITA2RlrmPokKiZbBy2DgaclCaEUs6g== +"@typescript-eslint/utils@5.29.0": + version "5.29.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-5.29.0.tgz#775046effd5019667bd086bcf326acbe32cd0082" + integrity sha512-3Eos6uP1nyLOBayc/VUdKZikV90HahXE5Dx9L5YlSd/7ylQPXhLk1BYb29SDgnBnTp+jmSZUU0QxUiyHgW4p7A== dependencies: "@types/json-schema" "^7.0.9" - "@typescript-eslint/scope-manager" "5.28.0" - "@typescript-eslint/types" "5.28.0" - "@typescript-eslint/typescript-estree" "5.28.0" + "@typescript-eslint/scope-manager" "5.29.0" + "@typescript-eslint/types" "5.29.0" + "@typescript-eslint/typescript-estree" "5.29.0" eslint-scope "^5.1.1" eslint-utils "^3.0.0" -"@typescript-eslint/visitor-keys@5.28.0": - version "5.28.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-5.28.0.tgz#982bb226b763c48fc1859a60de33fbf939d40a0f" - integrity sha512-BtfP1vCor8cWacovzzPFOoeW4kBQxzmhxGoOpt0v1SFvG+nJ0cWaVdJk7cky1ArTcFHHKNIxyo2LLr3oNkSuXA== +"@typescript-eslint/visitor-keys@5.29.0": + version "5.29.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-5.29.0.tgz#7a4749fa7ef5160c44a451bf060ac1dc6dfb77ee" + integrity sha512-Hpb/mCWsjILvikMQoZIE3voc9wtQcS0A9FUw3h8bhr9UxBdtI/tw1ZDZUOXHXLOVMedKCH5NxyzATwnU78bWCQ== dependencies: - "@typescript-eslint/types" "5.28.0" + "@typescript-eslint/types" "5.29.0" eslint-visitor-keys "^3.3.0" "@vercel/nft@^0.20.0": @@ -1567,9 +1567,9 @@ caniuse-api@^3.0.0: lodash.uniq "^4.5.0" caniuse-lite@^1.0.0, caniuse-lite@^1.0.30001335, caniuse-lite@^1.0.30001349: - version "1.0.30001357" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001357.tgz#dec7fc4158ef6ad24690d0eec7b91f32b8cb1b5d" - integrity sha512-b+KbWHdHePp+ZpNj+RDHFChZmuN+J5EvuQUlee9jOQIUAdhv9uvAZeEtUeLAknXbkiu1uxjQ9NLp1ie894CuWg== + version "1.0.30001358" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001358.tgz#473d35dabf5e448b463095cab7924e96ccfb8c00" + integrity sha512-hvp8PSRymk85R20bsDra7ZTCpSVGN/PAz9pSAjPSjKC+rNmnUk5vCRgJwiTT/O4feQ/yu/drvZYpKxxhbFuChw== ccount@^1.0.0: version "1.1.0" @@ -2280,9 +2280,9 @@ ee-first@1.1.1: integrity sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow== electron-to-chromium@^1.4.147: - version "1.4.161" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.4.161.tgz#49cb5b35385bfee6cc439d0a04fbba7a7a7f08a1" - integrity sha512-sTjBRhqh6wFodzZtc5Iu8/R95OkwaPNn7tj/TaDU5nu/5EFiQDtADGAXdR4tJcTEHlYfJpHqigzJqHvPgehP8A== + version "1.4.164" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.4.164.tgz#3d0f5c83557d8ec8a7faa531e498f198c3bd974a" + integrity sha512-K7iy5y6XyP9Pzh3uaDti0KC4JUNT6T1tLG5RTOmesqq2YgAJpYYYJ32m+anvZYjCV35llPTEh87kvEV/uSsiyQ== emoji-regex@^8.0.0: version "8.0.0" @@ -2413,190 +2413,190 @@ es-to-primitive@^1.2.1: is-date-object "^1.0.1" is-symbol "^1.0.2" -esbuild-android-64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-android-64/-/esbuild-android-64-0.14.46.tgz#98d019853ca7b526d0d645bb4618fda425b74d35" - integrity sha512-ZyJqwAcjNbZprs0ZAxnUAOhEhdE5kTKwz+CZuLmZYNLAPyRgBtaC8pT2PCuPifNvV8Cl3yLlrQPaOCjovoyb5g== +esbuild-android-64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-android-64/-/esbuild-android-64-0.14.47.tgz#ef95b42c67bcf4268c869153fa3ad1466c4cea6b" + integrity sha512-R13Bd9+tqLVFndncMHssZrPWe6/0Kpv2/dt4aA69soX4PRxlzsVpCvoJeFE8sOEoeVEiBkI0myjlkDodXlHa0g== esbuild-android-arm64@0.13.15: version "0.13.15" resolved "https://registry.yarnpkg.com/esbuild-android-arm64/-/esbuild-android-arm64-0.13.15.tgz#3fc3ff0bab76fe35dd237476b5d2b32bb20a3d44" integrity sha512-m602nft/XXeO8YQPUDVoHfjyRVPdPgjyyXOxZ44MK/agewFFkPa8tUo6lAzSWh5Ui5PB4KR9UIFTSBKh/RrCmg== -esbuild-android-arm64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-android-arm64/-/esbuild-android-arm64-0.14.46.tgz#19835d5265b57120c14fba56a19fc317ca4bbda0" - integrity sha512-BKcnUksvCijO9ONv6b4SikZE/OZftwJvX91XROODZGQmuwGVg97jmLDVu3lxuHdFlMNNzxh8taJ2mbCWZzH/Iw== +esbuild-android-arm64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-android-arm64/-/esbuild-android-arm64-0.14.47.tgz#4ebd7ce9fb250b4695faa3ee46fd3b0754ecd9e6" + integrity sha512-OkwOjj7ts4lBp/TL6hdd8HftIzOy/pdtbrNA4+0oVWgGG64HrdVzAF5gxtJufAPOsEjkyh1oIYvKAUinKKQRSQ== esbuild-darwin-64@0.13.15: version "0.13.15" resolved "https://registry.yarnpkg.com/esbuild-darwin-64/-/esbuild-darwin-64-0.13.15.tgz#8e9169c16baf444eacec60d09b24d11b255a8e72" integrity sha512-ihOQRGs2yyp7t5bArCwnvn2Atr6X4axqPpEdCFPVp7iUj4cVSdisgvEKdNR7yH3JDjW6aQDw40iQFoTqejqxvQ== -esbuild-darwin-64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-darwin-64/-/esbuild-darwin-64-0.14.46.tgz#2819465ab92f6df407e6462d9e56f6563a043a44" - integrity sha512-/ss2kO92sUJ9/1nHnMb3+oab8w6dyqKrMtPMvSYJ9KZIYGAZxz/WYxfFprY7Xk+ZxWnnlASSyZlG+If1nVmFYg== +esbuild-darwin-64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-darwin-64/-/esbuild-darwin-64-0.14.47.tgz#e0da6c244f497192f951807f003f6a423ed23188" + integrity sha512-R6oaW0y5/u6Eccti/TS6c/2c1xYTb1izwK3gajJwi4vIfNs1s8B1dQzI1UiC9T61YovOQVuePDcfqHLT3mUZJA== esbuild-darwin-arm64@0.13.15: version "0.13.15" resolved "https://registry.yarnpkg.com/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.13.15.tgz#1b07f893b632114f805e188ddfca41b2b778229a" integrity sha512-i1FZssTVxUqNlJ6cBTj5YQj4imWy3m49RZRnHhLpefFIh0To05ow9DTrXROTE1urGTQCloFUXTX8QfGJy1P8dQ== -esbuild-darwin-arm64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.14.46.tgz#2d523fa628930bba38a4f75cede75d6341bc3b5b" - integrity sha512-WX0JOaEFf6t+rIjXO6THsf/0fhQAt2Zb0/PSYlvXnuQQAmOmFAfPsuRNocp5ME0NGaUqZd4FxqqmLEVK3RzPAg== +esbuild-darwin-arm64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.14.47.tgz#cd40fd49a672fca581ed202834239dfe540a9028" + integrity sha512-seCmearlQyvdvM/noz1L9+qblC5vcBrhUaOoLEDDoLInF/VQ9IkobGiLlyTPYP5dW1YD4LXhtBgOyevoIHGGnw== esbuild-freebsd-64@0.13.15: version "0.13.15" resolved "https://registry.yarnpkg.com/esbuild-freebsd-64/-/esbuild-freebsd-64-0.13.15.tgz#0b8b7eca1690c8ec94c75680c38c07269c1f4a85" integrity sha512-G3dLBXUI6lC6Z09/x+WtXBXbOYQZ0E8TDBqvn7aMaOCzryJs8LyVXKY4CPnHFXZAbSwkCbqiPuSQ1+HhrNk7EA== -esbuild-freebsd-64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-freebsd-64/-/esbuild-freebsd-64-0.14.46.tgz#dbfbbb1cb943149aaa83b9e767ded6f14ad42ba5" - integrity sha512-o+ozPFuHRCAGCVWU2bLurOUgVkT0jcPEu082VBUY2Q/yLf+B+/3nXzh4Fjp5O21tOvJRTn7hUVydG9j5+vYE6A== +esbuild-freebsd-64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-freebsd-64/-/esbuild-freebsd-64-0.14.47.tgz#8da6a14c095b29c01fc8087a16cb7906debc2d67" + integrity sha512-ZH8K2Q8/Ux5kXXvQMDsJcxvkIwut69KVrYQhza/ptkW50DC089bCVrJZZ3sKzIoOx+YPTrmsZvqeZERjyYrlvQ== esbuild-freebsd-arm64@0.13.15: version "0.13.15" resolved "https://registry.yarnpkg.com/esbuild-freebsd-arm64/-/esbuild-freebsd-arm64-0.13.15.tgz#2e1a6c696bfdcd20a99578b76350b41db1934e52" integrity sha512-KJx0fzEDf1uhNOZQStV4ujg30WlnwqUASaGSFPhznLM/bbheu9HhqZ6mJJZM32lkyfGJikw0jg7v3S0oAvtvQQ== -esbuild-freebsd-arm64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-freebsd-arm64/-/esbuild-freebsd-arm64-0.14.46.tgz#fb066d6e7de2bd96138dd1c2fba5e8ce5233ed5a" - integrity sha512-9zicZ0X43WDKz3sjNfcqYO38xbfJpSWYXB+FxvYYkmBwGA52K0SAu4oKuTTLi8od8X2IIo1x5C5TUNvKDSVJww== +esbuild-freebsd-arm64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-freebsd-arm64/-/esbuild-freebsd-arm64-0.14.47.tgz#ad31f9c92817ff8f33fd253af7ab5122dc1b83f6" + integrity sha512-ZJMQAJQsIOhn3XTm7MPQfCzEu5b9STNC+s90zMWe2afy9EwnHV7Ov7ohEMv2lyWlc2pjqLW8QJnz2r0KZmeAEQ== esbuild-linux-32@0.13.15: version "0.13.15" resolved "https://registry.yarnpkg.com/esbuild-linux-32/-/esbuild-linux-32-0.13.15.tgz#6fd39f36fc66dd45b6b5f515728c7bbebc342a69" integrity sha512-ZvTBPk0YWCLMCXiFmD5EUtB30zIPvC5Itxz0mdTu/xZBbbHJftQgLWY49wEPSn2T/TxahYCRDWun5smRa0Tu+g== -esbuild-linux-32@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-linux-32/-/esbuild-linux-32-0.14.46.tgz#ea2464b10fe188ee7c9be81a2757e2d69ffdb8c1" - integrity sha512-ZnTpZMVb0VGvL99R5eh4OrJwbUyvpM6M88VAMuHP4LvFjuvZrhgefjKqEGuWZZW7JRnAjKqjXLjWdhdSjwMFnQ== +esbuild-linux-32@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-linux-32/-/esbuild-linux-32-0.14.47.tgz#de085e4db2e692ea30c71208ccc23fdcf5196c58" + integrity sha512-FxZOCKoEDPRYvq300lsWCTv1kcHgiiZfNrPtEhFAiqD7QZaXrad8LxyJ8fXGcWzIFzRiYZVtB3ttvITBvAFhKw== esbuild-linux-64@0.13.15: version "0.13.15" resolved "https://registry.yarnpkg.com/esbuild-linux-64/-/esbuild-linux-64-0.13.15.tgz#9cb8e4bcd7574e67946e4ee5f1f1e12386bb6dd3" integrity sha512-eCKzkNSLywNeQTRBxJRQ0jxRCl2YWdMB3+PkWFo2BBQYC5mISLIVIjThNtn6HUNqua1pnvgP5xX0nHbZbPj5oA== -esbuild-linux-64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-linux-64/-/esbuild-linux-64-0.14.46.tgz#f4f2d181af6ea78137311712fca423f8fa954314" - integrity sha512-ECCRRZtX6l4ubeVhHhiVoK/uYAkvzNqfmR4gP4N/9H9RPu+b8YCcN4bQGp7xCuYIV6Xd41WpOMyO+xpcQvjtQQ== +esbuild-linux-64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-linux-64/-/esbuild-linux-64-0.14.47.tgz#2a9321bbccb01f01b04cebfcfccbabeba3658ba1" + integrity sha512-nFNOk9vWVfvWYF9YNYksZptgQAdstnDCMtR6m42l5Wfugbzu11VpMCY9XrD4yFxvPo9zmzcoUL/88y0lfJZJJw== esbuild-linux-arm64@0.13.15: version "0.13.15" resolved "https://registry.yarnpkg.com/esbuild-linux-arm64/-/esbuild-linux-arm64-0.13.15.tgz#3891aa3704ec579a1b92d2a586122e5b6a2bfba1" integrity sha512-bYpuUlN6qYU9slzr/ltyLTR9YTBS7qUDymO8SV7kjeNext61OdmqFAzuVZom+OLW1HPHseBfJ/JfdSlx8oTUoA== -esbuild-linux-arm64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-linux-arm64/-/esbuild-linux-arm64-0.14.46.tgz#113d17c523dfe80c9d4981d05c58f5ada3470e30" - integrity sha512-HX0TXCHyI0NEWG4jg8LlW1PbZQbnz+PUH56yjx996cgM5pC90u32drKs/tyJiyyQmNk9OXOogjKw7LEdp/Qc1w== +esbuild-linux-arm64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-linux-arm64/-/esbuild-linux-arm64-0.14.47.tgz#b9da7b6fc4b0ca7a13363a0c5b7bb927e4bc535a" + integrity sha512-ywfme6HVrhWcevzmsufjd4iT3PxTfCX9HOdxA7Hd+/ZM23Y9nXeb+vG6AyA6jgq/JovkcqRHcL9XwRNpWG6XRw== esbuild-linux-arm@0.13.15: version "0.13.15" resolved "https://registry.yarnpkg.com/esbuild-linux-arm/-/esbuild-linux-arm-0.13.15.tgz#8a00e99e6a0c6c9a6b7f334841364d8a2b4aecfe" integrity sha512-wUHttDi/ol0tD8ZgUMDH8Ef7IbDX+/UsWJOXaAyTdkT7Yy9ZBqPg8bgB/Dn3CZ9SBpNieozrPRHm0BGww7W/jA== -esbuild-linux-arm@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-linux-arm/-/esbuild-linux-arm-0.14.46.tgz#1b6ba77b0301572b2fed35fe922b1613b10b5c7e" - integrity sha512-RvTJEi4vj13c5FP9YPp+8Y6x6HK1E7uSqfy3y9UoeaNAzNZWA7fN1U3hQjTL/dy5zTJH5KE64mrt5k5+he+CQA== +esbuild-linux-arm@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-linux-arm/-/esbuild-linux-arm-0.14.47.tgz#56fec2a09b9561c337059d4af53625142aded853" + integrity sha512-ZGE1Bqg/gPRXrBpgpvH81tQHpiaGxa8c9Rx/XOylkIl2ypLuOcawXEAo8ls+5DFCcRGt/o3sV+PzpAFZobOsmA== esbuild-linux-mips64le@0.13.15: version "0.13.15" resolved "https://registry.yarnpkg.com/esbuild-linux-mips64le/-/esbuild-linux-mips64le-0.13.15.tgz#36b07cc47c3d21e48db3bb1f4d9ef8f46aead4f7" integrity sha512-KlVjIG828uFPyJkO/8gKwy9RbXhCEUeFsCGOJBepUlpa7G8/SeZgncUEz/tOOUJTcWMTmFMtdd3GElGyAtbSWg== -esbuild-linux-mips64le@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-linux-mips64le/-/esbuild-linux-mips64le-0.14.46.tgz#8775e12510eaf988a9bc5e6787cf0c87c3eb40d6" - integrity sha512-jnb2NDwGqJUVmxn1v0f7seNdDm0nRNWHP9Z3MrWAGnBCdnnDlsjqRFDnbKoaQvWONEa+rOOr/giK+VL0hgQExA== +esbuild-linux-mips64le@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-linux-mips64le/-/esbuild-linux-mips64le-0.14.47.tgz#9db21561f8f22ed79ef2aedb7bbef082b46cf823" + integrity sha512-mg3D8YndZ1LvUiEdDYR3OsmeyAew4MA/dvaEJxvyygahWmpv1SlEEnhEZlhPokjsUMfRagzsEF/d/2XF+kTQGg== esbuild-linux-ppc64le@0.13.15: version "0.13.15" resolved "https://registry.yarnpkg.com/esbuild-linux-ppc64le/-/esbuild-linux-ppc64le-0.13.15.tgz#f7e6bba40b9a11eb9dcae5b01550ea04670edad2" integrity sha512-h6gYF+OsaqEuBjeesTBtUPw0bmiDu7eAeuc2OEH9S6mV9/jPhPdhOWzdeshb0BskRZxPhxPOjqZ+/OqLcxQwEQ== -esbuild-linux-ppc64le@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-linux-ppc64le/-/esbuild-linux-ppc64le-0.14.46.tgz#da003df59859b02e160827e26bc1e107bec23d07" - integrity sha512-uu3JTQUrwwauKY9z8yq5MnDyOlT3f2DNOzBcYz4dB78HqwEqilCsifoBGd0WcbED5n57dc59X+LZMTZ8Ose44w== +esbuild-linux-ppc64le@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-linux-ppc64le/-/esbuild-linux-ppc64le-0.14.47.tgz#dc3a3da321222b11e96e50efafec9d2de408198b" + integrity sha512-WER+f3+szmnZiWoK6AsrTKGoJoErG2LlauSmk73LEZFQ/iWC+KhhDsOkn1xBUpzXWsxN9THmQFltLoaFEH8F8w== -esbuild-linux-riscv64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-linux-riscv64/-/esbuild-linux-riscv64-0.14.46.tgz#b6c4faf9f8482e2a898ec2becac4a6789ae3ff22" - integrity sha512-OB29r1EG44ZY34JnXCRERxo7k4pRKoQdaoRg2HIeCavatsXZwW4LCakpLnMQ72vXT1HtpBUABEjHkKkn5JyrUg== +esbuild-linux-riscv64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-linux-riscv64/-/esbuild-linux-riscv64-0.14.47.tgz#9bd6dcd3dca6c0357084ecd06e1d2d4bf105335f" + integrity sha512-1fI6bP3A3rvI9BsaaXbMoaOjLE3lVkJtLxsgLHqlBhLlBVY7UqffWBvkrX/9zfPhhVMd9ZRFiaqXnB1T7BsL2g== -esbuild-linux-s390x@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-linux-s390x/-/esbuild-linux-s390x-0.14.46.tgz#d30d0f7ee8466c4ec99ac2c689b70514320406b2" - integrity sha512-XQ/U9TueMSGYyPTKyZsJVraiuvxhwCDIMn/QwFXCRCJ6H/Cy/Rq33u9qhpeSziinHKfzJROGx5A8mQY6aYamdQ== +esbuild-linux-s390x@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-linux-s390x/-/esbuild-linux-s390x-0.14.47.tgz#a458af939b52f2cd32fc561410d441a51f69d41f" + integrity sha512-eZrWzy0xFAhki1CWRGnhsHVz7IlSKX6yT2tj2Eg8lhAwlRE5E96Hsb0M1mPSE1dHGpt1QVwwVivXIAacF/G6mw== esbuild-netbsd-64@0.13.15: version "0.13.15" resolved "https://registry.yarnpkg.com/esbuild-netbsd-64/-/esbuild-netbsd-64-0.13.15.tgz#a2fedc549c2b629d580a732d840712b08d440038" integrity sha512-3+yE9emwoevLMyvu+iR3rsa+Xwhie7ZEHMGDQ6dkqP/ndFzRHkobHUKTe+NCApSqG5ce2z4rFu+NX/UHnxlh3w== -esbuild-netbsd-64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-netbsd-64/-/esbuild-netbsd-64-0.14.46.tgz#fcf2b739b63731b5b264dc584240c0b61dbbf035" - integrity sha512-i15BwqHaAIFp1vBJkitAbHtwXcLk9TdHs/Ia1xGIAutQYXSJNPLM3Z4B4hyfHNEFl2yBqBIYpglMohv2ClNdOQ== +esbuild-netbsd-64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-netbsd-64/-/esbuild-netbsd-64-0.14.47.tgz#6388e785d7e7e4420cb01348d7483ab511b16aa8" + integrity sha512-Qjdjr+KQQVH5Q2Q1r6HBYswFTToPpss3gqCiSw2Fpq/ua8+eXSQyAMG+UvULPqXceOwpnPo4smyZyHdlkcPppQ== esbuild-openbsd-64@0.13.15: version "0.13.15" resolved "https://registry.yarnpkg.com/esbuild-openbsd-64/-/esbuild-openbsd-64-0.13.15.tgz#b22c0e5806d3a1fbf0325872037f885306b05cd7" integrity sha512-wTfvtwYJYAFL1fSs8yHIdf5GEE4NkbtbXtjLWjM3Cw8mmQKqsg8kTiqJ9NJQe5NX/5Qlo7Xd9r1yKMMkHllp5g== -esbuild-openbsd-64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-openbsd-64/-/esbuild-openbsd-64-0.14.46.tgz#fc7880751b78b325216e66470b9a3df7b1c21cbf" - integrity sha512-XwOIFCE140Y/PvjrwjFfa/QLWBuvhR1mPCOa35mKx02jt++wPNgf0qhn6HfdVC3vQe7R46RwTp4q2cp99fepEg== +esbuild-openbsd-64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-openbsd-64/-/esbuild-openbsd-64-0.14.47.tgz#309af806db561aa886c445344d1aacab850dbdc5" + integrity sha512-QpgN8ofL7B9z8g5zZqJE+eFvD1LehRlxr25PBkjyyasakm4599iroUpaj96rdqRlO2ShuyqwJdr+oNqWwTUmQw== esbuild-sunos-64@0.13.15: version "0.13.15" resolved "https://registry.yarnpkg.com/esbuild-sunos-64/-/esbuild-sunos-64-0.13.15.tgz#d0b6454a88375ee8d3964daeff55c85c91c7cef4" integrity sha512-lbivT9Bx3t1iWWrSnGyBP9ODriEvWDRiweAs69vI+miJoeKwHWOComSRukttbuzjZ8r1q0mQJ8Z7yUsDJ3hKdw== -esbuild-sunos-64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-sunos-64/-/esbuild-sunos-64-0.14.46.tgz#ab73b91e79ae53dddb035da9bb69ba7dd44d36ee" - integrity sha512-+kV3JnmfdxBVpHyFvuGXWtu6tXxXApOLPkSrVkMJf6+ns/3PLtPndpzwCzHjD+qYUEk8ln4MA+ufQ2qmjW5mZg== +esbuild-sunos-64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-sunos-64/-/esbuild-sunos-64-0.14.47.tgz#3f19612dcdb89ba6c65283a7ff6e16f8afbf8aaa" + integrity sha512-uOeSgLUwukLioAJOiGYm3kNl+1wJjgJA8R671GYgcPgCx7QR73zfvYqXFFcIO93/nBdIbt5hd8RItqbbf3HtAQ== esbuild-windows-32@0.13.15: version "0.13.15" resolved "https://registry.yarnpkg.com/esbuild-windows-32/-/esbuild-windows-32-0.13.15.tgz#c96d0b9bbb52f3303322582ef8e4847c5ad375a7" integrity sha512-fDMEf2g3SsJ599MBr50cY5ve5lP1wyVwTe6aLJsM01KtxyKkB4UT+fc5MXQFn3RLrAIAZOG+tHC+yXObpSn7Nw== -esbuild-windows-32@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-windows-32/-/esbuild-windows-32-0.14.46.tgz#88ad388c896325d273e92dbf28f146d1d34d4351" - integrity sha512-gzGC1Q11B/Bo5A2EX4N22oigWmhL7Z0eDyc8kbSoJjqSrGQuRE7B0uMpluO+q0O/gZ1S3zdw+M4PCWlqOIeXLA== +esbuild-windows-32@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-windows-32/-/esbuild-windows-32-0.14.47.tgz#a92d279c8458d5dc319abcfeb30aa49e8f2e6f7f" + integrity sha512-H0fWsLTp2WBfKLBgwYT4OTfFly4Im/8B5f3ojDv1Kx//kiubVY0IQunP2Koc/fr/0wI7hj3IiBDbSrmKlrNgLQ== esbuild-windows-64@0.13.15: version "0.13.15" resolved "https://registry.yarnpkg.com/esbuild-windows-64/-/esbuild-windows-64-0.13.15.tgz#1f79cb9b1e1bb02fb25cd414cb90d4ea2892c294" integrity sha512-9aMsPRGDWCd3bGjUIKG/ZOJPKsiztlxl/Q3C1XDswO6eNX/Jtwu4M+jb6YDH9hRSUflQWX0XKAfWzgy5Wk54JQ== -esbuild-windows-64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-windows-64/-/esbuild-windows-64-0.14.46.tgz#bfb21b68d54d0db86190f8073cbf66a86bd0de14" - integrity sha512-Do2daaskfOjmCB7o3ygz6fD3K6SPjZLERiZLktzHz2oUCwsebKu/gmop0+j/XdrVIXC32wFzHzDS+9CTu9OShw== +esbuild-windows-64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-windows-64/-/esbuild-windows-64-0.14.47.tgz#2564c3fcf0c23d701edb71af8c52d3be4cec5f8a" + integrity sha512-/Pk5jIEH34T68r8PweKRi77W49KwanZ8X6lr3vDAtOlH5EumPE4pBHqkCUdELanvsT14yMXLQ/C/8XPi1pAtkQ== esbuild-windows-arm64@0.13.15: version "0.13.15" resolved "https://registry.yarnpkg.com/esbuild-windows-arm64/-/esbuild-windows-arm64-0.13.15.tgz#482173070810df22a752c686509c370c3be3b3c3" integrity sha512-zzvyCVVpbwQQATaf3IG8mu1IwGEiDxKkYUdA4FpoCHi1KtPa13jeScYDjlW0Qh+ebWzpKfR2ZwvqAQkSWNcKjA== -esbuild-windows-arm64@0.14.46: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild-windows-arm64/-/esbuild-windows-arm64-0.14.46.tgz#b8aa66a0c347342b9ae780b537d5574e9691c123" - integrity sha512-VEzMy6bM60/HT/URTDElyhfi2Pk0quCCrEhRlI4MRno/AIqYUGw0rZwkPl6PeoqVI6BgoBHGY576GWTiPmshCA== +esbuild-windows-arm64@0.14.47: + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild-windows-arm64/-/esbuild-windows-arm64-0.14.47.tgz#86d9db1a22d83360f726ac5fba41c2f625db6878" + integrity sha512-HFSW2lnp62fl86/qPQlqw6asIwCnEsEoNIL1h2uVMgakddf+vUuMcCbtUY1i8sst7KkgHrVKCJQB33YhhOweCQ== esbuild@^0.13.8: version "0.13.15" @@ -2622,30 +2622,30 @@ esbuild@^0.13.8: esbuild-windows-arm64 "0.13.15" esbuild@^0.14.14, esbuild@^0.14.27, esbuild@^0.14.43: - version "0.14.46" - resolved "https://registry.yarnpkg.com/esbuild/-/esbuild-0.14.46.tgz#d548cfc13fecfd4bc074ce38e0122d1dd9b067db" - integrity sha512-vdm5G1JdZBktva8dwQci/s44VbeBUg8g907xoZx77mqFZ4gU5GlMULNsdGeID+qXCXocsfYSGtE0LvqH3eiNQg== + version "0.14.47" + resolved "https://registry.yarnpkg.com/esbuild/-/esbuild-0.14.47.tgz#0d6415f6bd8eb9e73a58f7f9ae04c5276cda0e4d" + integrity sha512-wI4ZiIfFxpkuxB8ju4MHrGwGLyp1+awEHAHVpx6w7a+1pmYIq8T9FGEVVwFo0iFierDoMj++Xq69GXWYn2EiwA== optionalDependencies: - esbuild-android-64 "0.14.46" - esbuild-android-arm64 "0.14.46" - esbuild-darwin-64 "0.14.46" - esbuild-darwin-arm64 "0.14.46" - esbuild-freebsd-64 "0.14.46" - esbuild-freebsd-arm64 "0.14.46" - esbuild-linux-32 "0.14.46" - esbuild-linux-64 "0.14.46" - esbuild-linux-arm "0.14.46" - esbuild-linux-arm64 "0.14.46" - esbuild-linux-mips64le "0.14.46" - esbuild-linux-ppc64le "0.14.46" - esbuild-linux-riscv64 "0.14.46" - esbuild-linux-s390x "0.14.46" - esbuild-netbsd-64 "0.14.46" - esbuild-openbsd-64 "0.14.46" - esbuild-sunos-64 "0.14.46" - esbuild-windows-32 "0.14.46" - esbuild-windows-64 "0.14.46" - esbuild-windows-arm64 "0.14.46" + esbuild-android-64 "0.14.47" + esbuild-android-arm64 "0.14.47" + esbuild-darwin-64 "0.14.47" + esbuild-darwin-arm64 "0.14.47" + esbuild-freebsd-64 "0.14.47" + esbuild-freebsd-arm64 "0.14.47" + esbuild-linux-32 "0.14.47" + esbuild-linux-64 "0.14.47" + esbuild-linux-arm "0.14.47" + esbuild-linux-arm64 "0.14.47" + esbuild-linux-mips64le "0.14.47" + esbuild-linux-ppc64le "0.14.47" + esbuild-linux-riscv64 "0.14.47" + esbuild-linux-s390x "0.14.47" + esbuild-netbsd-64 "0.14.47" + esbuild-openbsd-64 "0.14.47" + esbuild-sunos-64 "0.14.47" + esbuild-windows-32 "0.14.47" + esbuild-windows-64 "0.14.47" + esbuild-windows-arm64 "0.14.47" escalade@^3.1.1: version "3.1.1" @@ -4144,10 +4144,10 @@ jest-worker@^26.2.1: merge-stream "^2.0.0" supports-color "^7.0.0" -jiti@^1.12.14, jiti@^1.12.9, jiti@^1.13.0: - version "1.13.0" - resolved "https://registry.yarnpkg.com/jiti/-/jiti-1.13.0.tgz#3cdfc4e651ca0cca4c62ed5e47747b5841d41a8e" - integrity sha512-/n9mNxZj/HDSrincJ6RP+L+yXbpnB8FybySBa+IjIaoH9FIxBbrbRT5XUbe8R7zuVM2AQqNMNDDqz0bzx3znOQ== +jiti@^1.12.14, jiti@^1.12.9, jiti@^1.13.0, jiti@^1.14.0: + version "1.14.0" + resolved "https://registry.yarnpkg.com/jiti/-/jiti-1.14.0.tgz#5350fff532a4d891ca4bcd700c47c1f40e6ee326" + integrity sha512-4IwstlaKQc9vCTC+qUXLM1hajy2ImiL9KnLvVYiaHOtS/v3wRjhLlGl121AmgDgx/O43uKmxownJghS5XMya2A== jiti@^1.14.0: version "1.14.0" @@ -4228,9 +4228,9 @@ jsonfile@^6.0.1: graceful-fs "^4.1.6" keyv@^4.0.0: - version "4.3.0" - resolved "https://registry.yarnpkg.com/keyv/-/keyv-4.3.0.tgz#b4352e0e4fe7c94111947d6738a6d3fe7903027c" - integrity sha512-C30Un9+63J0CsR7Wka5quXKqYZsT6dcRQ2aOwGcSc3RiQ4HGWpTAHlCA+puNfw2jA/s11EsxA1nCXgZRuRKMQQ== + version "4.3.1" + resolved "https://registry.yarnpkg.com/keyv/-/keyv-4.3.1.tgz#7970672f137d987945821b1a07b524ce5a4edd27" + integrity sha512-nwP7AQOxFzELXsNq3zCx/oh81zu4DHWwCE6W9RaeHb7OHO0JpmKS8n801ovVQC7PTsZDWtPA5j1QY+/WWtARYg== dependencies: compress-brotli "^1.3.8" json-buffer "3.0.1" @@ -5078,7 +5078,7 @@ mkdist@^0.3.9: mri "^1.2.0" pathe "^0.2.0" -mlly@^0.3.19, mlly@^0.3.6: +mlly@^0.3.19: version "0.3.19" resolved "https://registry.yarnpkg.com/mlly/-/mlly-0.3.19.tgz#a4aac171d2142eafc9c9d4c1937dac5a11f70565" integrity sha512-zMq5n3cOf4fOzA4WoeulxagbAgMChdev3MgP6K51k7M0u2whTXxupfIY4VVzws4vxkiWhwH1rVQcsw7zDGfRhA== @@ -5088,7 +5088,7 @@ mlly@^0.4.1: resolved "https://registry.yarnpkg.com/mlly/-/mlly-0.4.3.tgz#a5c51b073601cc4cc49bda971f24d903a25adc29" integrity sha512-xezyv7hnfFPuiDS3AiJuWs0OxlvooS++3L2lURvmh/1n7UG4O2Ehz9UkwWgg3wyLEPKGVfJLlr2DjjTCl9UJTg== -mlly@^0.5.1, mlly@^0.5.2: +mlly@^0.5.1, mlly@^0.5.2, mlly@^0.5.3: version "0.5.3" resolved "https://registry.yarnpkg.com/mlly/-/mlly-0.5.3.tgz#8a613b6273886490a5f462ce18fa486492cf053b" integrity sha512-im69tuLD9EJh9fc9TZRpJEFvsBcGMez7glUCWDcHWWCKzhvPmNvyaYjp/+h0qJJN/Xovrs//GzGjOOKmFw4Gog== @@ -5226,9 +5226,9 @@ node-emoji@^1.11.0: lodash "^4.17.21" node-fetch-native@^0.1.2, node-fetch-native@^0.1.3: - version "0.1.3" - resolved "https://registry.yarnpkg.com/node-fetch-native/-/node-fetch-native-0.1.3.tgz#61a4e4250d7aa6e272cacdbaa979ea916bff321a" - integrity sha512-Jf1IQZdovUIv9E+5avmN6Sf+bND+rnMlODnBQhdE2VRyuWP9WgqZb/KEgPekh19DAN1X2C4vbS1VCOaz2OH19g== + version "0.1.4" + resolved "https://registry.yarnpkg.com/node-fetch-native/-/node-fetch-native-0.1.4.tgz#09b06754f9e298bac23848050da2352125634f89" + integrity sha512-10EKpOCQPXwZVFh3U1ptOMWBgKTbsN7Vvo6WVKt5pw4hp8zbv6ZVBZPlXw+5M6Tyi1oc1iD4/sNPd71KYA16tQ== node-fetch@^2.6.7: version "2.6.7" @@ -5797,13 +5797,13 @@ pify@^2.3.0: integrity sha512-udgsAY+fTnvv7kI7aaxbqwWNb0AHiB0qBO89PZKPkoTmGOgdbrHDKD+0B2X4uTfJ/FT1R09r9gTsjUjNJotuog== pkg-types@^0.3.2: - version "0.3.2" - resolved "https://registry.yarnpkg.com/pkg-types/-/pkg-types-0.3.2.tgz#1b3244b561745591035517475bc8af9c5e089e47" - integrity sha512-eBYzX/7NYsQEOR2alWY4rnQB49G62oHzFpoi9Som56aUr8vB8UGcmcIia9v8fpBeuhH3Ltentuk2OGpp4IQV3Q== + version "0.3.3" + resolved "https://registry.yarnpkg.com/pkg-types/-/pkg-types-0.3.3.tgz#3c25e45274e1c586ec7811dcc3449afde846e463" + integrity sha512-6AJcCMnjUQPQv/Wk960w0TOmjhdjbeaQJoSKWRQv9N3rgkessCu6J0Ydsog/nw1MbpnxHuPzYbfOn2KmlZO1FA== dependencies: jsonc-parser "^3.0.0" - mlly "^0.3.6" - pathe "^0.2.0" + mlly "^0.5.3" + pathe "^0.3.0" pluralize@^8.0.0: version "8.0.0" @@ -7571,11 +7571,11 @@ v8-compile-cache@^2.0.3: integrity sha512-l8lCEmLcLYZh4nbunNZvQCJc5pv7+RCwa8q/LdUx8u7lsWvPDKmpodJAJNwkAhJC//dFY48KuIEmjtd4RViDrA== v8-to-istanbul@^9.0.0: - version "9.0.0" - resolved "https://registry.yarnpkg.com/v8-to-istanbul/-/v8-to-istanbul-9.0.0.tgz#be0dae58719fc53cb97e5c7ac1d7e6d4f5b19511" - integrity sha512-HcvgY/xaRm7isYmyx+lFKA4uQmfUbN0J4M0nNItvzTvH/iQ9kW5j/t4YSR+Ge323/lrgDAWJoF46tzGQHwBHFw== + version "9.0.1" + resolved "https://registry.yarnpkg.com/v8-to-istanbul/-/v8-to-istanbul-9.0.1.tgz#b6f994b0b5d4ef255e17a0d17dc444a9f5132fa4" + integrity sha512-74Y4LqY74kLE6IFyIjPtkSTWzUZmj8tdHT9Ii/26dvQ6K9Dl2NbEfj0XgU2sHCtKgt5VupqhlO/5aWuqS+IY1w== dependencies: - "@jridgewell/trace-mapping" "^0.3.7" + "@jridgewell/trace-mapping" "^0.3.12" "@types/istanbul-lib-coverage" "^2.0.1" convert-source-map "^1.6.0"