Compare commits

..
Author SHA1 Message Date
Ken 82656da435 📝 Added comments 2026-04-27 09:57:48 +02:00
Ken ab9932ed8f 📝 Added comments 2026-04-27 09:55:47 +02:00
Ken 180ca25861 ⚡ Add cached parser for optimization 2026-04-24 13:38:51 +02:00
Ken cbac535fcb 📝 Add docs 2026-04-24 13:10:18 +02:00
Ken 296049b8c7 [DataTable] Optimize recursive parsing 2026-04-24 13:00:21 +02:00
Ken 073d811b3f [DataTable] Now supports branch selection 2026-04-24 12:45:15 +02:00
Ken da1374e833 [DataTable] Updated selection 2026-04-24 12:22:41 +02:00
Ken c0080e6729 [DataTable] Added play-test story 2026-04-24 12:20:59 +02:00
Ken dd1bc5241b [DataTable] Move prop-drilled value to context 2026-04-24 11:43:01 +02:00
Halvor Haugan 816f0fcaab DataTable: autoWidth prop 2026-04-24 10:14:20 +02:00
github-actions[bot] 9d9a5b9afe Version Packages (#4832)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-04-24 09:49:13 +02:00
Ken 90194d7d95 💄 Dialog now bottom-aligns on smaller breakpoint (#4831) 2026-04-24 09:44:13 +02:00
Ken 26b0bd2595 [LLM] Added llm route for codemod configs, optimized json strings in markdown 2026-04-23 22:46:41 +02:00
Ken 58f74b9a8f [DataTable] Expanded, loading and empty-state rows now have correct colSpan 2026-04-23 16:47:01 +02:00
Ken cf3b550e80 [LLM] Reduce thinking verbosity with instructions 2026-04-23 16:32:15 +02:00
Ken c8deba5677 [DataTable] Refactor expansionContext 2026-04-23 16:29:58 +02:00
Ken 16ffbc0209 [DataTable] Removed unused context-data 2026-04-23 16:15:05 +02:00
Ken 90caff2e7f [DataTable] Inline row-parsing in expandable row hook 2026-04-23 16:11:15 +02:00
Ken cd3afbfcaa [DataTable] Fix pagination demo 2026-04-23 16:07:44 +02:00
Ken 4d91935a3a [DataTable] Re-use parsed rowIds 2026-04-23 16:05:49 +02:00
Ken d92ffe5cc7 [LLM] Re add lines about thinking process and verbosity 2026-04-23 16:01:47 +02:00
Ken 2970c20d00 [LLM] Specify test instructions 2026-04-23 15:53:30 +02:00
Ken f48a6b9cc2 [LLM] Updated coped instructions 2026-04-23 15:37:24 +02:00
Ken 95dba94df4 [LLM] Added scoped instructions 2026-04-23 15:33:11 +02:00
Ken c5413d65c9 [LLM] Update root instruction 2026-04-23 15:09:10 +02:00
Ken 5884628710 [DataTable] Optimize item parsing with map 2026-04-23 14:30:42 +02:00
Ken c33cdad6e5 [DataTable] Refactor contract between rendring rows and sub-rows 2026-04-23 14:06:29 +02:00
Ken f7fdd35ff0 [DataTable] Still render rows without nesting 2026-04-23 12:51:09 +02:00
Ken 9a0f5dbf45 [DataTable] Remove old use of expansioncontext for nested rows 2026-04-23 12:20:30 +02:00
Ken fd0de677ad [DataTable] Refactor nested use of context 2026-04-23 12:15:02 +02:00
Ken bb709aeb35 [DataTable] Use new items context to render nested rows 2026-04-23 12:09:09 +02:00
Ken cac3c38cff [DataTable] ⚡ Optimize item parsing 2026-04-23 11:27:45 +02:00
Ken d4063849a8 [DataTable] ⚡ Memorize parsing 2026-04-23 10:15:44 +02:00
Ken fccf5bafdb [DataTable] Add global index counter when traversing rows 2026-04-23 10:04:49 +02:00
Ken df075c7ec8 🐛 Sync yarn.lock 2026-04-22 21:36:51 +02:00
Ken 0672fc6cee [LLM] Updated categories in LLM.md 2026-04-22 21:13:41 +02:00
Ken 088d65a63b [LLM] Added tailwind config route 2026-04-22 21:01:56 +02:00
Ken 11dc6bf0c6 [DataTable] WIP nested item hook 2026-04-22 20:45:46 +02:00
Ken 7f127ad5b0 [DataTable] 🎉 Added nested row handling --no-verify 2026-04-22 20:26:13 +02:00
Halvor Haugan 5885a70c41 DataTable: Remove code that was not supposed to be pushed 2026-04-22 15:12:47 +02:00
Halvor Haugan 7e23ed71e7 DataTable: Add support for col resize with Home and End 2026-04-22 15:01:21 +02:00
Ken 9205952283 [DataTable] Added check for exandable data in nested rows 2026-04-22 13:08:42 +02:00
Ken f70bb419e8 [DataTable] Added separate toggles for nested and master-detail pattern 2026-04-22 12:49:48 +02:00
Ken b22c98d215 [DataTable] Added more nested rows stories 2026-04-22 12:32:03 +02:00
Halvor Haugan 1efadf3df3 DataTable: Fix SR issue related to col resizing 2026-04-22 11:49:55 +02:00
Halvor Haugan bc69e8cfbd DataTable: Avoid setting onClick on <tr> if not needed 2026-04-22 11:47:55 +02:00
Halvor Haugan 8198d53ecc DataTable: Adjust when column header gets hover/active background 2026-04-22 09:59:27 +02:00
Ken cb03a70eb2 [DataTable] Added styling for ensted rows 2026-04-21 15:34:54 +02:00
Ken cdad58bdbb [DataTable] Added subrows 2026-04-21 15:34:54 +02:00
Ken e3830c70c2 [DataTable] Added getSubRows prop 2026-04-21 15:34:54 +02:00
Ken 607259ee75 🏷️ Typo 2026-04-21 15:34:53 +02:00
Halvor Haugan 55e41f44ad DataTable: Auto-size column to fit content on double click 2026-04-21 15:28:05 +02:00
Halvor Haugan 443754ebc3 DataTable: Fix type error 2026-04-21 13:05:11 +02:00
Halvor Haugan a49b9925a6 DataTable: role=slider on resize handle for improved (?) a11y 2026-04-21 12:43:20 +02:00
Halvor Haugan dbf498264a Storybook: improved types in main and preview config (#4828) 2026-04-21 11:55:06 +02:00
Halvor Haugan 081f6b14b4 Sync react versions 2026-04-21 09:40:48 +02:00
Halvor Haugan e28d875d46 createMainChangelog: Order changelogs deterministically (#4827) 2026-04-21 09:36:11 +02:00
dependabot[bot]andKen 99393696ee Bump next from 16.2.0 to 16.2.3 in /aksel.nav.no/website in the npm_and_yarn group across 1 directory (#4796)
* ⬆️ Bump next

Bumps the npm_and_yarn group with 1 update in the /aksel.nav.no/website directory: [next](https://github.com/vercel/next.js).


Updates `next` from 16.2.0 to 16.2.3
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/compare/v16.2.0...v16.2.3)

---
updated-dependencies:
- dependency-name: next
  dependency-version: 16.2.3
  dependency-type: direct:production
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>

* ⬆️ Update nextjs

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2026-04-21 09:34:19 +02:00
Halvor Haugan 255131b4bd Modal: Separate story for small size (#4826) 2026-04-21 09:33:52 +02:00
ec7beb2b37 Bump react-dom from 19.2.4 to 19.2.5 in the react group across 1 directory (#4819)
* Bump react-dom from 19.2.4 to 19.2.5 in the react group

Bumps the react group with 1 update: [react-dom](https://github.com/facebook/react/tree/HEAD/packages/react-dom).


Updates `react-dom` from 19.2.4 to 19.2.5
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/v19.2.5/packages/react-dom)

---
updated-dependencies:
- dependency-name: react-dom
  dependency-version: 19.2.5
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: react
...

Signed-off-by: dependabot[bot] <support@github.com>

* 📝 Update react and react-dom

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2026-04-21 09:29:02 +02:00
dependabot[bot]andKen 396f2641d7 Bump swr from 2.4.0 to 2.4.1 (#4822)
* Bump swr from 2.4.0 to 2.4.1

Bumps [swr](https://github.com/vercel/swr) from 2.4.0 to 2.4.1.
- [Release notes](https://github.com/vercel/swr/releases)
- [Commits](https://github.com/vercel/swr/compare/v2.4.0...v2.4.1)

---
updated-dependencies:
- dependency-name: swr
  dependency-version: 2.4.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* 🎉 Sync SWR versions

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2026-04-20 19:11:57 +02:00
c94f87e6dc [Markdown] Added Markdown routes for each page, ikon-page and design-tokens (#4814)
* 🎉 Added unpacked enums

* 🎉 Updated queries

* ⬆️ yarn update

* 🎉 Added markdown-docs for each page

* 🎉 Added regular link interception

* 🎉 Added design-token route

* 🎉 Added icon-documentation

* 🎉 Add static paths to root llm.md

* Update aksel.nav.no/website/scripts/update-props.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update aksel.nav.no/website/sanity/interface/queries.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 📝 Fix naming

* Update aksel.nav.no/website/sanity/interface/queries.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* ♻️ Small refactors to config and comments

* 🐛 Update types after enum addition

* 🏷️ Update query-types

* Update aksel.nav.no/website/app/api/markdown/routes/design-tokens.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Use -

* 🐛 Resolve em-dash

* 📝 Updated token formatting

* 📝 Updated docs

* 🏷️ Rename enum -> unpackedTypes

* 🏷️ Rename enum -> unpackedTypes

* 📝 Update schema

* Update aksel.nav.no/website/app/api/markdown/llm.config.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update aksel.nav.no/website/app/api/markdown/routes/grunnleggende.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update aksel.nav.no/website/app/api/markdown/routes/design-tokens.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update aksel.nav.no/website/app/api/markdown/routes/design-tokens.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 🐛 Fix typo

* 🔒 Security updates

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-04-20 19:11:37 +02:00
dependabot[bot]andKen 1c2a43dba8 Bump the vitest group across 1 directory with 4 updates (#4821)
* Bump the vitest group with 4 updates

Bumps the vitest group with 4 updates: [@vitest/browser](https://github.com/vitest-dev/vitest/tree/HEAD/packages/browser), [@vitest/browser-playwright](https://github.com/vitest-dev/vitest/tree/HEAD/packages/browser-playwright), [@vitest/coverage-v8](https://github.com/vitest-dev/vitest/tree/HEAD/packages/coverage-v8) and [vitest](https://github.com/vitest-dev/vitest/tree/HEAD/packages/vitest).


Updates `@vitest/browser` from 4.1.0 to 4.1.4
- [Release notes](https://github.com/vitest-dev/vitest/releases)
- [Commits](https://github.com/vitest-dev/vitest/commits/v4.1.4/packages/browser)

Updates `@vitest/browser-playwright` from 4.1.0 to 4.1.4
- [Release notes](https://github.com/vitest-dev/vitest/releases)
- [Commits](https://github.com/vitest-dev/vitest/commits/v4.1.4/packages/browser-playwright)

Updates `@vitest/coverage-v8` from 4.1.0 to 4.1.4
- [Release notes](https://github.com/vitest-dev/vitest/releases)
- [Commits](https://github.com/vitest-dev/vitest/commits/v4.1.4/packages/coverage-v8)

Updates `vitest` from 4.1.0 to 4.1.4
- [Release notes](https://github.com/vitest-dev/vitest/releases)
- [Commits](https://github.com/vitest-dev/vitest/commits/v4.1.4/packages/vitest)

---
updated-dependencies:
- dependency-name: "@vitest/browser"
  dependency-version: 4.1.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: vitest
- dependency-name: "@vitest/browser-playwright"
  dependency-version: 4.1.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: vitest
- dependency-name: "@vitest/coverage-v8"
  dependency-version: 4.1.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: vitest
- dependency-name: vitest
  dependency-version: 4.1.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: vitest
...

Signed-off-by: dependabot[bot] <support@github.com>

* ⬆️ Update vitest

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2026-04-20 14:16:59 +02:00
dependabot[bot] 697d1a2793 Bump the storybook group with 9 updates (#4820)
Bumps the storybook group with 9 updates:

| Package | From | To |
| --- | --- | --- |
| [@storybook/addon-a11y](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/a11y) | `10.2.10` | `10.3.5` |
| [@storybook/addon-docs](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/docs) | `10.2.10` | `10.3.5` |
| [@storybook/addon-themes](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/themes) | `10.2.10` | `10.3.5` |
| [@storybook/addon-vitest](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/vitest) | `10.2.10` | `10.3.5` |
| [@storybook/nextjs-vite](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/nextjs) | `10.2.10` | `10.3.5` |
| [@storybook/react-vite](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/react-vite) | `10.2.10` | `10.3.5` |
| [eslint-plugin-storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/eslint-plugin) | `10.2.10` | `10.3.5` |
| [storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/core) | `10.2.10` | `10.3.5` |
| [storybook-addon-pseudo-states](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/pseudo-states) | `10.3.0` | `10.3.5` |


Updates `@storybook/addon-a11y` from 10.2.10 to 10.3.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.3.5/code/addons/a11y)

Updates `@storybook/addon-docs` from 10.2.10 to 10.3.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.3.5/code/addons/docs)

Updates `@storybook/addon-themes` from 10.2.10 to 10.3.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.3.5/code/addons/themes)

Updates `@storybook/addon-vitest` from 10.2.10 to 10.3.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.3.5/code/addons/vitest)

Updates `@storybook/nextjs-vite` from 10.2.10 to 10.3.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.3.5/code/frameworks/nextjs)

Updates `@storybook/react-vite` from 10.2.10 to 10.3.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.3.5/code/frameworks/react-vite)

Updates `eslint-plugin-storybook` from 10.2.10 to 10.3.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.3.5/code/lib/eslint-plugin)

Updates `storybook` from 10.2.10 to 10.3.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.3.5/code/core)

Updates `storybook-addon-pseudo-states` from 10.3.0 to 10.3.5
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.3.5/code/addons/pseudo-states)

---
updated-dependencies:
- dependency-name: "@storybook/addon-a11y"
  dependency-version: 10.3.5
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/addon-docs"
  dependency-version: 10.3.5
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/addon-themes"
  dependency-version: 10.3.5
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/addon-vitest"
  dependency-version: 10.3.5
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/nextjs-vite"
  dependency-version: 10.3.5
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/react-vite"
  dependency-version: 10.3.5
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: eslint-plugin-storybook
  dependency-version: 10.3.5
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: storybook
  dependency-version: 10.3.5
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: storybook-addon-pseudo-states
  dependency-version: 10.3.5
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-20 14:14:43 +02:00
KenandCopilot d36ee0fcd7 [Sanity/Ai] Unpack enum-props so that markdown-docs can have better docs for AI (#4812)
* 🎉 Added unpacked enums

* 🎉 Updated queries

* ⬆️ yarn update

* Update aksel.nav.no/website/scripts/update-props.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update aksel.nav.no/website/sanity/interface/queries.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 📝 Fix naming

* Update aksel.nav.no/website/sanity/interface/queries.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 🐛 Update types after enum addition

* 📝 Updated docs

* 🏷️ Rename enum -> unpackedTypes

* 🏷️ Rename enum -> unpackedTypes

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-04-20 14:06:58 +02:00
github-actions[bot] 13cb816166 Version Packages (#4824)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-04-20 13:28:26 +02:00
KenandHalvor Haugan f66236c371 [Modal] 🐛 Changing Modal-size had no effect before (#4823)
* 🐛 Changing Modal-size had no effect before

* 📝 Add default jsdoc

* Update .changeset/chilly-llamas-show.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-04-20 13:18:54 +02:00
Halvor Haugan 11463cebc3 DataTable: Disable keyboard nav when trying to resize col with arrow keys 2026-04-20 12:50:53 +02:00
Halvor Haugan 5f3c6541fd DataTable: Remove default padding on sort-button and cells 2026-04-20 12:48:22 +02:00
github-actions[bot] 756c9578eb Version Packages (#4789)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-04-20 11:14:15 +02:00
Halvor Haugan 2eab5b9564 DatePicker: Highlight days between start and hovered day (#4801) 2026-04-20 09:53:52 +02:00
Ken c037bc4733 📝 Add todos 2026-04-19 12:48:29 +02:00
Halvor HauganandCopilot 794bf825a5 [Docs] Adjust CONTRIBUTING.md in aksel-icons (#4817)
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-04-17 16:42:56 +02:00
Ken 33b8b279a6 Revert -> Website: Test LLM llm uA 2026-04-17 16:36:56 +02:00
Ken 5c8c77503c Website: Test LLM llm uA 2026-04-17 16:16:03 +02:00
Ken 55b48252a9 [Timeline] When row has focus, focus first or last period based on arrow-keys (#4816)
* 🎉 Added fallbacks when row is active

* 🐛 Fix typo
2026-04-17 15:57:11 +02:00
Ken df8fb7e3e9 [DataTable] Avoid selecting rows that are disabled 2026-04-17 14:54:18 +02:00
Ken c096f46beb 🐛 Fix typo-sizing, header-padding for infocard and alerts (#4815)
* 🐛 Fix typo-sizing, header-padding for infocard and alerts

* 🔥 Removed comments

* 📝 Update changeset

* 💄 Optical align infocard header

* ♻️ Use size directly

* 📝 Updated comments
2026-04-17 13:43:59 +02:00
KenandHalvor Haugan f491aaec70 [Timeline] Enhance keyboard navigation, optimize pin interactions, period-scaling (#4809)
* 🐛 Add onClick handler for Pin

* ⚡ Added keyboard-nav between rows

* ⚡ Refactor keyboard-handler

* 🎉 Added pins to keyboard-nav

* ⚡ Added early returns

* ⚡ Optimize re-renders

* 💄 Hide icons on smallest periods

* 💄 Update icon sizing based on width

* 🧪 Timeline nav tests

* 📝 Changeset

* ⚰️ Clean up unused state, avoid navigating when inside popovers

* 🐛 Avoid preventDefault on event if no focus is done

* 🐛 Return focus to element that opened popover

* Update @navikt/core/react/src/timeline/hooks/TimelineKeyboardNavProvider.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ Refactor ref-handling

* Update @navikt/core/react/src/timeline/hooks/TimelineKeyboardNavProvider.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ⚡ Updated memorization

* ⚡ Move util outside of component

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-04-17 13:43:31 +02:00
Anniken GranbergandCopilot Autofix powered by AI 139805d5b4 ExpandableRow: Top border disappeared on selected rows when row above was collapsed (#4810)
* ExpandableRow: Fix selected row top border not showing when row above was collapsed

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

* more spesific css selector

* Wrote wrong classname 🤦‍♀️

---------

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-04-17 10:13:35 +02:00
Halvor HauganandKen eceeb3855a ⬆️ Upgrade Sanity to 5.20 (and related packages) (#4813)
Co-authored-by: Ken <ken.aleksander@gmail.com>
2026-04-17 08:58:50 +02:00
Halvor Haugan 67ee836fb6 Sync vite versions 2026-04-16 17:29:13 +02:00
391018ed29 Typescript 6.0.2 update: Fix type and build issues (#4786)
* Bump typescript from 5.9.3 to 6.0.2

Bumps [typescript](https://github.com/microsoft/TypeScript) from 5.9.3 to 6.0.2.
- [Release notes](https://github.com/microsoft/TypeScript/releases)
- [Commits](https://github.com/microsoft/TypeScript/compare/v5.9.3...v6.0.2)

---
updated-dependencies:
- dependency-name: typescript
  dependency-version: 6.0.2
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* ⬆️ Sync typescript version across repo

* 🐛 Fix build-errors

* 🐛 Fix type-errors in daypicker, ignore tsbuildinfo

* 🐛 Resolve CLI type-errors

* 🐛 Fix TS 6.0 issues

* 🐛 Fix codemod issues

* ⚡ Utility for extracting strings and literals

* 🔥 Removed comments

* Apply suggestions from code review

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ Review updates

* ⬆️ Update ts for playroom

* ⬆️ yarn update

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-04-16 16:17:28 +02:00
Ken 12a584f9ab [DataTable] Resolve context issue 2 2026-04-16 13:37:08 +02:00
Halvor Haugan f57ef4323d [website] Update examples of InternalHeader and Timeline (#4805) 2026-04-16 12:47:46 +02:00
Ken f73546039b [DataTable] Resolve context issue 2026-04-16 11:40:35 +02:00
Ken 563aa6530a [DataTable] Resolve context issue 2026-04-16 11:38:58 +02:00
Ken 9726f26c53 [DataTable] Add missing prop to context 2026-04-16 10:37:58 +02:00
Ken 25cc71c6e0 [DataTable] Allow rendring data with loading state enabled, instead making body inert 2026-04-16 10:18:07 +02:00
Ken 2f70ea3101 [DataTable] Avoid triggering onRowClick on cells with actions 2026-04-16 09:53:08 +02:00
Ken 476804b90c [DataTable] Move onRowClick to Row itself trough context 2026-04-16 09:38:03 +02:00
Ken c7d2a8a3aa [DataTable] Auto refactors 2 bogaloo 2026-04-16 09:23:01 +02:00
Ken e0b2bee5f0 [DataTable] Auto refactors 2026-04-16 09:18:31 +02:00
Ken 36fa158dc8 [DataTable] Added Expandable Rows and onRowClick 2026-04-15 16:09:42 +02:00
d23551b7da sporing-dev.js script + potentially useful tracking events (#4800)
* use the sporing-dev tracking script in dev, no longer use data-host-url

* ➕ add taxonomy package + use it

* fix: expose PRODUCTION env var to client via nextConfig.env

Agent-Logs-Url: https://github.com/navikt/aksel/sessions/08c505b1-b087-431b-bd30-41b9956c320d

Co-authored-by: JulianNymark <819074+JulianNymark@users.noreply.github.com>

* Update aksel.nav.no/website/app/_ui/code-block/CodeBlock.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* add missing \"use client\" to components using umamiTrack

* fix: keep WebsiteExpansionCard as server component, extract onToggle tracking to thin client wrapper

* do not track actual search strings

* fix: send placement as lenkegruppe and actual link text as lenketekst in UmamiLink

* 🐛 Resolve render-issues

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: JulianNymark <819074+JulianNymark@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2026-04-15 13:56:32 +02:00
Anniken Granberg 3f0efd7dc4 DataTable/dnd: add label 2026-04-15 13:16:38 +02:00
Ken 63f5aaf2f4 🐛 Make sure text-variant for Skeleton has properly rounded edges (#4808) 2026-04-15 12:49:34 +02:00
Anniken Granberg ee95122ec1 DataTable: fix types 2026-04-15 10:29:07 +02:00
Anniken Granberg e8f90be978 DataTable: Add label to columnDefinition and changed item type for dnd 2026-04-15 10:26:51 +02:00
Ken 2c0ee8d2ca [DataTable] Added onRowClick 2026-04-14 15:57:11 +02:00
Ken 8d708b1ef8 [DataTable] Auto version feature addons
[DataTable] Refactor loading state and body rendring.

[DataTable] Added emptyState prop

[DataTable] Removed render-prop for custom filterMenu

[DataTable] Updated stickyColumns jsdoc

[DataTable] Added loading states

[DataTable] Added loading label, better handling of colspan in loading/empty-state
2026-04-14 14:36:33 +02:00
Ken 3e4c2deced [DataTable] Added shift click sort support 2026-04-14 13:33:31 +02:00
Ken 0101acd2e0 [DataTable] Added sorting API to table auto 2026-04-14 12:55:28 +02:00
Halvor Haugan 14dc7b3775 Update vscode settings (#4804) 2026-04-14 11:16:06 +02:00
Ken 64d07ad527 🧪 Improve test-suite for storybook 2026-04-14 10:25:48 +02:00
Ken 99f04a8129 [DataTable] Refactor DataTableContextProvider 2026-04-14 10:25:48 +02:00
Ken 75c62c4e92 [DataTable] Refactor getRowIds use 2026-04-14 10:25:48 +02:00
Ken 0055a744c1 [DataTable] Move table ref-state to hook 2026-04-14 10:25:48 +02:00
Halvor Haugan e6c5b9b868 ⬆️ Upgrade Vite to 7.3.2 / 8.0.5 2026-04-14 09:35:20 +02:00
dependabot[bot] a245d0dbfb ⬆️ Bump vite from 7.3.1 to 7.3.2 (#4802)
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 7.3.1 to 7.3.2.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v7.3.2/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v7.3.2/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 7.3.2
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-14 09:27:22 +02:00
Anniken Granberg e09bbdc0fe DataTable / dnd: Added announcer, changed some props, better (?) labels 2026-04-14 09:19:26 +02:00
Ken 873724d1f4 [DataTable] Fix filler-cell taking space when not needed, added fixed layout stories 2026-04-13 16:13:33 +02:00
Halvor HauganandKen 004d0fc547 DatePicker: Reset range when selecting a new day, upgrade react-day-picker (#4799)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2026-04-13 16:07:40 +02:00
Ken cc37a94093 [DataTable] Fix resizable handle overflow and clipping 2026-04-13 15:00:59 +02:00
Ken 46bc3c92b3 [DataTable] Fix border overflow when sticky 2026-04-13 14:40:37 +02:00
Ken 7782b83105 Patch Axios to v1.15 (#4798)
* Path CVE 10 axios error. Axios 1.15 patch

* 🔥 Removed preApproved for axios
2026-04-13 11:32:26 +02:00
Ken 5f79eeade6 [DataTable] Added header sticking with column sticking 2026-04-13 09:51:17 +02:00
Ken 471635d518 [DataTable] Added column sticking 2026-04-11 17:21:09 +02:00
Anniken Granberg b4a1dd72db DataTable/dnd: Accessibility, renaming, cancel event, rewrite 2026-04-10 14:50:28 +02:00
Halvor Haugan a714e05c56 [website] Fix typo in LegacyTokenTable (#4795) 2026-04-10 14:41:28 +02:00
Ken 9daea7aa21 [DataTable] Forward row and col-span 2026-04-10 14:27:05 +02:00
Ken 0303d825fa [DataTable] Split column header and generic TH-cell 2026-04-10 14:06:29 +02:00
Ken c6ac943c88 [DataTable] added sticky column prop 2026-04-10 14:06:29 +02:00
Ken 0551a90951 [DataTable] Fix CSS for genetic cell 2026-04-10 14:06:29 +02:00
fbfd1656e2 ⬆️ Bump eslint-plugin-react-hooks from 5.2.0 to 7.0.1 (#4447)
* ⬆️ Bump eslint-plugin-react-hooks from 5.2.0 to 7.0.1

Bumps [eslint-plugin-react-hooks](https://github.com/facebook/react/tree/HEAD/packages/eslint-plugin-react-hooks) from 5.2.0 to 7.0.1.
- [Release notes](https://github.com/facebook/react/releases)
- [Changelog](https://github.com/facebook/react/blob/main/packages/eslint-plugin-react-hooks/CHANGELOG.md)
- [Commits](https://github.com/facebook/react/commits/HEAD/packages/eslint-plugin-react-hooks)

---
updated-dependencies:
- dependency-name: eslint-plugin-react-hooks
  dependency-version: 7.0.1
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* 🐛 update config

* 🏷️ Lint-updates

* eslint-disable combobox.stories, ErrorSummary, Dropzone

* Add disable comments in modal.stories.tsx

* Add eslint-disable comment in LinkAnchor

* eslint-disable in generic-error-page.tsx

* disable ref rule and ignore remaining lint errors

* inline

* fix yarn.lock

* CRLF -> LF

* New attempt at fixing lockfile

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-04-10 13:07:28 +02:00
Ken 4b674930c5 🐛 Resolve test-errors after data-table update 2026-04-10 13:02:50 +02:00
Ken 2128e94a1b 🎉 Added formatting to pre-push command 2026-04-10 13:00:55 +02:00
Ken f381a3b9c7 🎉 Added pre-push command to run tests before pushing to main 2026-04-10 12:59:00 +02:00
Ken dec64b021f [DataTable] TdCell uses genetic cell 2026-04-10 12:51:54 +02:00
Ken af95682d22 [DataTable] Generic cell boilerplate 2026-04-10 12:45:33 +02:00
Ken cf0f7c3b79 [DataTable] JSDoc update 2026-04-10 12:30:26 +02:00
Ken 1d19f27008 [DataTable] JSDoc update 2026-04-10 12:21:02 +02:00
Ken 52b4dcd7b6 [DataTable] Rename selection disabled props 2026-04-10 12:18:49 +02:00
Ken 3822bf50fa [DataTable] Removed unused labels for checkbox and radio 2026-04-10 12:01:06 +02:00
Ken 99ce4399fa [DataTable] optimize selection hook 2026-04-10 11:55:09 +02:00
Ken 3d693351fe [Actions] Matrix resolver for container cleanup 2026-04-10 11:40:22 +02:00
Ken 93872c5573 Revert: [Actions] allow chaning number of deleted images from ghp 2026-04-10 10:33:21 +02:00
Ken 2f0a99e744 [Actions] allow chaning number of deleted images from ghp 2026-04-10 10:29:32 +02:00
Ken af5e83d613 [DataTable] Improved selecting + pagination logic, added todos 2026-04-10 10:25:40 +02:00
Ken 6b64f271cf [Timeline] ♿ Improved JAWS support with click-handler for period-popups (#4793)
* ♿ Improved JAWS support with click-handler for period-popups

* 🐛 Allow mouse-events to toggle clickable-period popup
2026-04-10 09:31:09 +02:00
Halvor Haugan 1ea580482e [website] Show clear button on sidebar filter input 2026-04-09 14:38:13 +02:00
Halvor Haugan cf9c5ef2c4 InlineMessage: Improve screen reader experience (#4792) 2026-04-09 12:21:31 +02:00
Ken 9f15a817a0 🐛 Revert locale update from backup 2026-04-09 11:45:51 +02:00
dependabot[bot] e9067600fc Bump lodash-es from 4.17.23 to 4.18.1 (#4791)
Bumps [lodash-es](https://github.com/lodash/lodash) from 4.17.23 to 4.18.1.
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](https://github.com/lodash/lodash/compare/4.17.23...4.18.1)

---
updated-dependencies:
- dependency-name: lodash-es
  dependency-version: 4.18.1
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-09 11:34:37 +02:00
Halvor Haugan 363a6061bd CheckboxGroup: Set aria-invalid on error (#4790) 2026-04-09 09:39:42 +02:00
dependabot[bot] 37bad55c75 Bump mlly from 1.8.0 to 1.8.2 (#4787)
Bumps [mlly](https://github.com/unjs/mlly) from 1.8.0 to 1.8.2.
- [Release notes](https://github.com/unjs/mlly/releases)
- [Changelog](https://github.com/unjs/mlly/blob/main/CHANGELOG.md)
- [Commits](https://github.com/unjs/mlly/compare/v1.8.0...v1.8.2)

---
updated-dependencies:
- dependency-name: mlly
  dependency-version: 1.8.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-09 09:21:59 +02:00
Anniken Granberg acdcd29f70 DataTable/Dnd: Add buttons for rearranging items, deactivate active handler on outside click, disble dragging on active handle 2026-04-08 16:42:35 +02:00
Ken 45d87ce21d [DataTable] 🐛 Add data-type to column-definition 2026-04-08 15:31:19 +02:00
Ken bfe01c316a [DataTable] 🐛 Selection-state css 2026-04-08 15:05:01 +02:00
Ken 8f6286d081 [DataTable] 🐛 handle type-errors 2026-04-08 14:56:43 +02:00
Ken a5240353b8 [DataTable] Added datatable stories 2026-04-08 14:53:10 +02:00
Ken b9612e348e [DataTable] Extracted selected cell width as a constant 2026-04-08 14:53:09 +02:00
Ken 60624d4a8a [DataTable] Optimize checked and disabled lookup 2026-04-08 14:53:09 +02:00
Ken 072b24d46e [DataTable] Handle single-select and disabled keys better 2026-04-08 14:53:09 +02:00
Ken 28b5dea3d3 [DataTable] Update CSS to show disabled state in standalone mode 2026-04-08 14:53:08 +02:00
Halvor Haugan 741a270eed ⬆️ Upgrade Biome to 2.4.10 (#4788) 2026-04-08 14:05:28 +02:00
Halvor Haugan 3c128e12a5 RadioGroup: Set role=radiogroup, and set aria-invalid on error (#4773) 2026-04-08 13:38:47 +02:00
Ken 658b44fa46 [DataTable] Add accessible labels to selection inputs 2026-04-08 13:31:44 +02:00
Ken 4c4cd1ef02 [DataTable] Remove 'all' from selection type API 2026-04-08 13:31:44 +02:00
Ken 9ee70a881a [DataTable] Unique names for radio 2026-04-08 13:31:43 +02:00
Ken e20f669c79 [DataTable] Derive selected state from context 2026-04-08 13:31:43 +02:00
Halvor Haugan 4d5639a31b Box: Fix typo in JSDoc 2026-04-08 13:06:17 +02:00
Halvor Haugan 6e3421189f [website] Remove the word "statisk" from InfoCard examples 2026-04-08 12:56:04 +02:00
Ken 77fc4fdefc [DataTable] Fix type-error 2026-04-08 11:49:10 +02:00
Halvor Haugan 50688d5b07 ⬆️ Upgrade lodash 2026-04-08 11:42:37 +02:00
Ken 4e49f74470 [DataTable] Update Selectionstate to be rendered within tablerows 2026-04-08 11:38:41 +02:00
dependabot[bot] 8d9e46a528 Bump @vitest/eslint-plugin from 1.6.9 to 1.6.14 in the vitest group (#4785)
Bumps the vitest group with 1 update: [@vitest/eslint-plugin](https://github.com/vitest-dev/eslint-plugin-vitest).


Updates `@vitest/eslint-plugin` from 1.6.9 to 1.6.14
- [Release notes](https://github.com/vitest-dev/eslint-plugin-vitest/releases)
- [Commits](https://github.com/vitest-dev/eslint-plugin-vitest/compare/v1.6.9...v1.6.14)

---
updated-dependencies:
- dependency-name: "@vitest/eslint-plugin"
  dependency-version: 1.6.14
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: vitest
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-08 11:34:00 +02:00
Halvor Haugan db94a7eb4c Upgrade deps in examples/astro 2026-04-08 11:30:28 +02:00
Halvor Haugan c4dcc61dfb Merge branch 'main' of github.com:navikt/aksel 2026-04-08 11:18:41 +02:00
Halvor Haugan 12a4b6af33 Delete lock files in examples, and exclude package.jsons in Dependabot 2026-04-08 11:18:08 +02:00
Ken 167c474668 🐛 Update CSP header for umami (#4784) 2026-04-08 11:18:04 +02:00
Halvor Haugan 522285238b Empty lock files in examples to prevent Dependabot touching them 2026-04-08 10:02:25 +02:00
Ken ac8cba2cf4 [DataTable] Fixed checkbox alignment 2026-04-08 09:10:17 +02:00
Halvor HauganandKen d1c7d72a0d 🚨 Linting: Use Biome to find import cycles instead of eslint (#4768)
Co-authored-by: Ken <ken.aleksander@gmail.com>
2026-04-07 16:16:28 +02:00
Ken bb6726b1ee ⬅️ Revert release-packages workflow name update to avoid NPM packages release issues 2026-04-07 16:15:38 +02:00
github-actions[bot] c0a7be2008 Version Packages (#4782)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-04-07 15:59:40 +02:00
KenandHalvor Haugan a3743a6b37 [Workflows] 🧹 Better naming, grouping and texts (#4767)
* 📝 Update workflows with better naming, texts and permissions

* 📝 Name updates

* 🎉 Clean up images used for testing

* 🔥 Removed unused deploy tag

* Update .github/workflows/build-validation.yml

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update .github/workflows/build-validation.yml

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Clean up permissions

* Update .github/workflows/deploy-prod-gcp.yml

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Sync sanity texts

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-04-07 14:57:03 +02:00
Ken 47d74be1a0 🐛 Sync datepicker input button with input itself (#4781)
* 🐛 Sync datepicker input button with input itself

* 🔥 removed non needed width and height definition
2026-04-07 14:56:19 +02:00
Ken bff180ad42 [DataTable] 🐛 Remove row-selection from not-yet-implemented simple kitchen-sink demo 2026-04-07 13:39:58 +02:00
Ken 14bcb500d0 [DataTable] Add selection mode to kitchen-sink demo 2026-04-07 13:33:51 +02:00
Ken 9014bf0073 [DataTable] Added selection css for testign 2026-04-07 13:19:06 +02:00
93465781c1 [Checkbox, Radio] Inline inputs for use internally in DataTable (#4760)
* 🎉 Added checkbox-item component

* 🔥 Removed hardcoded sr-only classname

* 🎉 unpack props for better destructuring

* 🎉 Working standalone radio and checkbox inputs

* 🎉 Use standalone inputs in table

* 📝 Changeset

* Update @navikt/core/react/src/form/radio/radio-input/RadioInput.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update @navikt/core/react/src/form/checkbox/checkbox-input/CheckboxInput.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 🐛 Forward className

* 🐛 Story value fix

* Update @navikt/core/css/src/form/radio-checkbox.css

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 JSDOC update

* 🐛 Hide margin when empty SR-text

* 📝 added hidelegend story

* 🔥 removed css-var declarations on root css

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-04-07 12:48:47 +02:00
Halvor Haugan f7393f7515 Button: Use correct text color when inherited data-color is "neutral" (#4772) 2026-04-07 11:52:52 +02:00
dependabot[bot]andKen 890db16c2a Bump yaml from 1.10.2 to 1.10.3 (#4777)
Bumps [yaml](https://github.com/eemeli/yaml) from 1.10.2 to 1.10.3.
- [Release notes](https://github.com/eemeli/yaml/releases)
- [Commits](https://github.com/eemeli/yaml/compare/v1.10.2...v1.10.3)

---
updated-dependencies:
- dependency-name: yaml
  dependency-version: 1.10.3
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2026-04-07 10:09:16 +02:00
dependabot[bot] 08e3457314 Bump path-to-regexp from 0.1.12 to 0.1.13 (#4779)
Bumps [path-to-regexp](https://github.com/pillarjs/path-to-regexp) from 0.1.12 to 0.1.13.
- [Release notes](https://github.com/pillarjs/path-to-regexp/releases)
- [Changelog](https://github.com/pillarjs/path-to-regexp/blob/v.0.1.13/History.md)
- [Commits](https://github.com/pillarjs/path-to-regexp/compare/v0.1.12...v.0.1.13)

---
updated-dependencies:
- dependency-name: path-to-regexp
  dependency-version: 0.1.13
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-07 09:46:30 +02:00
dependabot[bot] 8cd871403c Bump picomatch from 2.3.1 to 2.3.2 (#4776)
Bumps [picomatch](https://github.com/micromatch/picomatch) from 2.3.1 to 2.3.2.
- [Release notes](https://github.com/micromatch/picomatch/releases)
- [Changelog](https://github.com/micromatch/picomatch/blob/master/CHANGELOG.md)
- [Commits](https://github.com/micromatch/picomatch/compare/2.3.1...2.3.2)

---
updated-dependencies:
- dependency-name: picomatch
  dependency-version: 2.3.2
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-07 09:30:56 +02:00
Anniken Granberg b6e3c7dc2e DataTable: fix errors 2026-03-27 17:18:22 +01:00
Anniken Granberg 956e1c10c7 DataTable: Allow onClick on drag handlerr 2026-03-27 17:14:49 +01:00
Anniken Granberg 08020c7aff DataTable: fix error 2026-03-27 16:08:19 +01:00
Anniken Granberg ba547bbad7 DataTable: Make item overlay same width as item 2026-03-27 15:24:52 +01:00
Halvor Haugan fd2bbd3de0 Update ActionMenu shortcuts example (#4774) 2026-03-27 14:20:47 +01:00
Ken f23f6855ad [DataTable] TokenFilter chips WIP 2026-03-27 14:00:09 +01:00
Ken a06dcabfc7 [DataTable] TokenFilter input layout 2026-03-27 14:00:09 +01:00
Ken e804a857af [DataTable] KitchenSink with tokenfilter 2026-03-27 14:00:09 +01:00
Ken 70c255aebc [DataTable] Story cleanup 2026-03-27 14:00:08 +01:00
Halvor Haugan fe21575a8d Update changeset format in PR template 2026-03-27 13:29:37 +01:00
github-actions[bot] f5d0a158d1 Version Packages (#4759)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-03-27 13:20:27 +01:00
Ken b359130706 [DataTable] layout-story updates 2026-03-27 11:34:02 +01:00
Ken d76d3cc30b [DataTable] Update pagination and toolbar view 2026-03-27 09:52:48 +01:00
Ken 112f5f97db 📝 Disable autocomplete in tokenfilter 2026-03-27 09:52:48 +01:00
Ken 4811920686 🔒 Disable scripts when running yarn install for sercurity (#4766) 2026-03-27 09:45:18 +01:00
Halvor Haugan c894748316 Run in-sync-versions.ts in CI instead of pre-commit (#4769) 2026-03-27 08:56:23 +01:00
Halvor Haugan 6d5ef574cd Sync vitest versions (#4770) 2026-03-27 08:56:09 +01:00
Ken 5a911b469e [DataTable] Removed actionbar, updated toolbar 2026-03-26 20:59:14 +01:00
Ken 192db60c20 [DataTable] TokenFilter + listbox updates 2026-03-26 20:32:58 +01:00
Ken c041bcd8ca ⬆️ nextjs (#4771) 2026-03-26 16:55:21 +01:00
Ken 86f86d3760 [InternalHeader] 🎉 Added 'isActive'-prop to InternalHeaderButton. (#4761)
* 🎉 Added 'isActive'-prop to InternalHeaderButton.

* 🐛 Use actual links in story view

* review updates: aria-current, forced-colors and taller line

* 🐛 Allow user to override aria-current
2026-03-26 15:36:21 +01:00
Ken c2e123d403 🔊 Clean up boot command output 2026-03-26 15:22:50 +01:00
Ken 58a413d98d 🐛 revert story test enabling for flaky tests 2026-03-26 14:49:57 +01:00
Ken 4bb0edddad 🧹 Misc test and comment cleanup 2026-03-26 13:39:54 +01:00
Anniken Granberg df8979ff50 DataTable: try to fix dependecy cicle linting fail 2026-03-26 13:18:09 +01:00
Ken 7771731b0f 🔊 Add deployment permissions to show deployments when publishing 2026-03-26 12:29:30 +01:00
Halvor Haugan 6fdf8f1782 Change clean script to use glob from node (#4763) 2026-03-26 12:21:29 +01:00
Anniken Granberg 5d61d5269a DataTable: comment 2026-03-23 18:26:17 +01:00
Anniken Granberg 33a5d8a85c DataTable: comments 2026-03-23 18:22:41 +01:00
Anniken Granberg 42a8c75184 DataTable: new native dnd component 2026-03-23 18:22:41 +01:00
Anniken Granberg 9cefd6e73d DataTable: rename files 2026-03-23 18:22:41 +01:00
Anniken Granberg 097a506a19 DataTable: Rename, removed data in front 2026-03-23 18:22:41 +01:00
dependabot[bot] 46dcee3636 Bump the vitest group with 4 updates (#4753)
Bumps the vitest group with 4 updates: [@vitest/browser](https://github.com/vitest-dev/vitest/tree/HEAD/packages/browser), [@vitest/browser-playwright](https://github.com/vitest-dev/vitest/tree/HEAD/packages/browser-playwright), [@vitest/coverage-v8](https://github.com/vitest-dev/vitest/tree/HEAD/packages/coverage-v8) and [vitest](https://github.com/vitest-dev/vitest/tree/HEAD/packages/vitest).


Updates `@vitest/browser` from 4.0.18 to 4.1.0
- [Release notes](https://github.com/vitest-dev/vitest/releases)
- [Commits](https://github.com/vitest-dev/vitest/commits/v4.1.0/packages/browser)

Updates `@vitest/browser-playwright` from 4.0.18 to 4.1.0
- [Release notes](https://github.com/vitest-dev/vitest/releases)
- [Commits](https://github.com/vitest-dev/vitest/commits/v4.1.0/packages/browser-playwright)

Updates `@vitest/coverage-v8` from 4.0.18 to 4.1.0
- [Release notes](https://github.com/vitest-dev/vitest/releases)
- [Commits](https://github.com/vitest-dev/vitest/commits/v4.1.0/packages/coverage-v8)

Updates `vitest` from 4.0.18 to 4.1.0
- [Release notes](https://github.com/vitest-dev/vitest/releases)
- [Commits](https://github.com/vitest-dev/vitest/commits/v4.1.0/packages/vitest)

---
updated-dependencies:
- dependency-name: "@vitest/browser"
  dependency-version: 4.1.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: vitest
- dependency-name: "@vitest/browser-playwright"
  dependency-version: 4.1.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: vitest
- dependency-name: "@vitest/coverage-v8"
  dependency-version: 4.1.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: vitest
- dependency-name: vitest
  dependency-version: 4.1.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: vitest
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-23 14:20:26 +01:00
Halvor Haugan 72a9131aee DatePicker, MonthPicker: Make open button more prominent (#4751) 2026-03-23 14:05:17 +01:00
dependabot[bot] 4a9d358d0a Bump vite-tsconfig-paths from 6.1.0 to 6.1.1 (#4758)
Bumps [vite-tsconfig-paths](https://github.com/aleclarson/vite-tsconfig-paths) from 6.1.0 to 6.1.1.
- [Release notes](https://github.com/aleclarson/vite-tsconfig-paths/releases)
- [Commits](https://github.com/aleclarson/vite-tsconfig-paths/compare/v6.1.0...v6.1.1)

---
updated-dependencies:
- dependency-name: vite-tsconfig-paths
  dependency-version: 6.1.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-23 13:59:54 +01:00
Halvor Haugan 14f1491cce Dependabot: Try excluding lockfiles in examples dir (#4756) 2026-03-23 13:27:53 +01:00
Halvor Haugan ad9978fb93 lint-staged: make biome ignore attempts to lint ignored files 2026-03-23 10:44:49 +01:00
dependabot[bot] 04c4414de5 Bump lint-staged from 16.2.7 to 16.4.0 (#4754)
Bumps [lint-staged](https://github.com/lint-staged/lint-staged) from 16.2.7 to 16.4.0.
- [Release notes](https://github.com/lint-staged/lint-staged/releases)
- [Changelog](https://github.com/lint-staged/lint-staged/blob/main/CHANGELOG.md)
- [Commits](https://github.com/lint-staged/lint-staged/compare/v16.2.7...v16.4.0)

---
updated-dependencies:
- dependency-name: lint-staged
  dependency-version: 16.4.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-23 10:24:40 +01:00
dependabot[bot] fa7ae4ec6f Bump esbuild from 0.27.3 to 0.27.4 (#4755)
Bumps [esbuild](https://github.com/evanw/esbuild) from 0.27.3 to 0.27.4.
- [Release notes](https://github.com/evanw/esbuild/releases)
- [Changelog](https://github.com/evanw/esbuild/blob/main/CHANGELOG.md)
- [Commits](https://github.com/evanw/esbuild/compare/v0.27.3...v0.27.4)

---
updated-dependencies:
- dependency-name: esbuild
  dependency-version: 0.27.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-23 09:48:33 +01:00
Anniken Granberg 94c6e5cf79 [Website] Add aria-current attribute to navigation links for improved… (#4750)
* [Website] Add aria-current attribute to navigation links for improved accessibility

* Use const value and use true instead of page
2026-03-23 09:48:24 +01:00
Halvor Haugan 0e8e4fc4a2 ⬆️ Bump flatted to 3.4.2 2026-03-23 09:47:21 +01:00
dependabot[bot]andHalvor Haugan ecef57a167 Bump next from 16.1.6 to 16.1.7 in /aksel.nav.no/website in the npm_and_yarn group across 1 directory (#4752)
* Bump next

Bumps the npm_and_yarn group with 1 update in the /aksel.nav.no/website directory: [next](https://github.com/vercel/next.js).


Updates `next` from 16.1.6 to 16.1.7
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/compare/v16.1.6...v16.1.7)

---
updated-dependencies:
- dependency-name: next
  dependency-version: 16.1.7
  dependency-type: direct:production
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>

* lockfile

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2026-03-23 09:44:51 +01:00
Ken 666616232d [LLM] Added grunnleggende and templates LLM-docs 2026-03-21 20:54:04 +01:00
Ken b607e20964 [LLM] Set up templates and grunnleggende 2026-03-21 20:32:00 +01:00
Ken a093c9385a [DataTable] Selection API refactor 2026-03-21 19:41:04 +01:00
Ken 9889b16500 [DataTable] Added more flexibility to row id creation 2026-03-21 19:41:03 +01:00
Halvor Haugan 1273dcd586 ⬆️ Upgrade deps in /examples 2026-03-20 19:33:18 +01:00
Halvor Haugan 2342b687ce Biome/eslint adjustments (#4749) 2026-03-20 15:35:29 +01:00
github-actions[bot] cf5d3e98c5 Version Packages (#4718)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-03-20 15:01:04 +01:00
Halvor Haugan b990be4ee8 Chromatic: update externals value (#4748) 2026-03-20 13:12:11 +01:00
KenandHalvor Haugan c3b06bdc80 [Dialog] Links are now a valid focusable target when tabbing (#4747)
* 🧪 set up failing story test

* Dialog: Fixed issue where tabbing would not work when focusable element was a link

* Update .changeset/rare-seas-trade.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-03-20 12:48:46 +01:00
dependabot[bot] 82c00e2591 Bump flatted from 3.3.3 to 3.4.1 (#4746)
Bumps [flatted](https://github.com/WebReflection/flatted) from 3.3.3 to 3.4.1.
- [Commits](https://github.com/WebReflection/flatted/compare/v3.3.3...v3.4.1)

---
updated-dependencies:
- dependency-name: flatted
  dependency-version: 3.4.1
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-20 12:09:46 +01:00
Ken 5756986070 GlobalAlert, LocalAlert: Content outline changed from 4px to 2px. (#4745) 2026-03-20 11:34:32 +01:00
Ken 738813046f [InfoCard] InfoCardMessage sub-component (#4717)
* 🎉 Added new sub-component for InfoCard: InfoCard.Message

* 📝 Jsdocs

* Apply suggestion from @KenAJoh

* 📝 Update jsdoc

* 💄 Refactor composition

* ♻️ Review updates

* 📝 Jsdocs

* ♻️ Remove data-size attrb from message-component

* 📝 examples
2026-03-20 11:29:42 +01:00
dependabot[bot] e942e77281 Bump undici from 6.23.0 to 6.24.0 (#4743)
Bumps [undici](https://github.com/nodejs/undici) from 6.23.0 to 6.24.0.
- [Release notes](https://github.com/nodejs/undici/releases)
- [Commits](https://github.com/nodejs/undici/compare/v6.23.0...v6.24.0)

---
updated-dependencies:
- dependency-name: undici
  dependency-version: 6.24.0
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-20 09:58:42 +01:00
Ken e422ab4292 [LLM] Formatting cleanup 2026-03-20 09:30:56 +01:00
Ken b7f826a2a7 [LLM] Formatting cleanup for better token usage 2026-03-19 13:54:11 +01:00
Ken 71dc4693a1 [LLM] Now prints all react-component documentation 2026-03-19 13:32:21 +01:00
Ken 4bb3ef19fc [LLM] Added llm.md route on root for testing (currently disabled) 2026-03-19 13:05:37 +01:00
Halvor Haugan c44f921b4c Fieldset: Adjust examples (#4742) 2026-03-19 12:23:58 +01:00
Ken d585c16164 [DataTable] Selection select all reset 2026-03-19 12:19:11 +01:00
Ken 91a5243c2c [DataTable] Selection hook initial setup 2026-03-19 09:50:19 +01:00
Ken 3322acde59 [DataTable] Working table with items 2026-03-18 16:11:59 +01:00
Ken 71dba0d15c [DataTable] Table with item-prop WIP 2026-03-18 15:37:50 +01:00
KenandHalvor Haugan 232ed45694 💄 Disabled token adjusted to 0.45 (#4734)
* 💄 Disabled token adjusted to 0.45

* Update .changeset/tidy-coats-hope.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-03-18 14:52:48 +01:00
Ken 84261202ce 🐛 Fixed mailto validation in sanity link schema 2026-03-18 14:24:59 +01:00
Ken 44c39ee6b8 [DataTable]: Selected demo cleanup 2026-03-18 14:03:59 +01:00
Ken 856afc3f78 [DataTable]: Selected state registry 2026-03-18 13:13:23 +01:00
Ken b7a6b3131e [DataTable]: Working selection states 2026-03-18 10:28:39 +01:00
Ken 8b5980b794 [DataTable]: Initial selected row config 2026-03-18 10:28:39 +01:00
Anniken Granberg 7b4a47d31b DataTable: dnd native skeleton 2026-03-18 08:52:29 +01:00
Anniken Granberg dc88ccbece DataTable: Move old dnd kit 2026-03-18 08:36:41 +01:00
Halvor Haugan aa4d610a50 Fieldset: variant:static on address examples 2026-03-17 15:54:14 +01:00
Halvor Haugan 3e6678fc8c Fieldset: Add example on hideLegend (#4739) 2026-03-17 15:36:21 +01:00
Ken edff0148ad [DataTable]: Resize event cleanup 2026-03-17 15:22:39 +01:00
Ken 5bc7adeff4 [DataTable]: Resize refactor 2026-03-17 15:22:39 +01:00
Ken 4d9e66d276 [DataTable]: Resize touch-events 2026-03-17 15:22:38 +01:00
Halvor Haugan 252aed6e07 Fieldset: Update JSDoc and add examples (#4738) 2026-03-17 15:08:35 +01:00
Halvor Haugan 2d70b8df7e ⬆️ Bump tar to 7.5.11 2026-03-17 15:06:01 +01:00
Ken 8f3e5072ae [DataTable]: DND anchor demo 2026-03-17 14:58:29 +01:00
Ken ab7f08850f [DataTable]: Added selectionMode prop (not implemented) 2026-03-16 16:31:01 +01:00
Ken f3f7fb797e [DataTable]: Added loading-component 2026-03-16 16:11:31 +01:00
Ken c20d5d7211 [DataTable]: Added emptystate-component 2026-03-16 15:51:56 +01:00
dependabot[bot] 182fbf9819 ⬆️ Bump the npm_and_yarn group across 2 directories with 1 update (#4736)
Bumps the npm_and_yarn group with 1 update in the /examples/astro directory: [tar](https://github.com/isaacs/node-tar).
Bumps the npm_and_yarn group with 1 update in the /examples/shadow-dom directory: [tar](https://github.com/isaacs/node-tar).


Updates `tar` from 7.5.10 to 7.5.11
- [Release notes](https://github.com/isaacs/node-tar/releases)
- [Changelog](https://github.com/isaacs/node-tar/blob/main/CHANGELOG.md)
- [Commits](https://github.com/isaacs/node-tar/compare/v7.5.10...v7.5.11)

Updates `tar` from 7.5.10 to 7.5.11
- [Release notes](https://github.com/isaacs/node-tar/releases)
- [Changelog](https://github.com/isaacs/node-tar/blob/main/CHANGELOG.md)
- [Commits](https://github.com/isaacs/node-tar/compare/v7.5.10...v7.5.11)

---
updated-dependencies:
- dependency-name: tar
  dependency-version: 7.5.11
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: tar
  dependency-version: 7.5.11
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-16 15:15:40 +01:00
dependabot[bot]andKen 95c58bacc6 ⬆️ Bump @floating-ui/react-dom from 2.1.7 to 2.1.8 (#4733)
Bumps [@floating-ui/react-dom](https://github.com/floating-ui/floating-ui/tree/HEAD/packages/react-dom) from 2.1.7 to 2.1.8.
- [Release notes](https://github.com/floating-ui/floating-ui/releases)
- [Changelog](https://github.com/floating-ui/floating-ui/blob/master/packages/react-dom/CHANGELOG.md)
- [Commits](https://github.com/floating-ui/floating-ui/commits/@floating-ui/react-dom@2.1.8/packages/react-dom)

---
updated-dependencies:
- dependency-name: "@floating-ui/react-dom"
  dependency-version: 2.1.8
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2026-03-16 15:14:49 +01:00
dependabot[bot] 942d98945d ⬆️ Bump eslint-plugin-testing-library from 7.15.4 to 7.16.0 (#4732)
Bumps [eslint-plugin-testing-library](https://github.com/testing-library/eslint-plugin-testing-library) from 7.15.4 to 7.16.0.
- [Release notes](https://github.com/testing-library/eslint-plugin-testing-library/releases)
- [Changelog](https://github.com/testing-library/eslint-plugin-testing-library/blob/main/release.config.js)
- [Commits](https://github.com/testing-library/eslint-plugin-testing-library/compare/v7.15.4...v7.16.0)

---
updated-dependencies:
- dependency-name: eslint-plugin-testing-library
  dependency-version: 7.16.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-16 15:09:50 +01:00
KenandHalvor Haugan befae1e0a2 [Readmore] Added variants ghost and moderate (#4723)
* 🎉 WIP readmore

* ♻️ Readmore CSS refactor

* 🎉 Finishing up Readmore refactor and variant addition

* 🎉 Finishing up Readmore refactor and variant addition

* 📝 Update Readmore examples

* Update .changeset/fine-seals-rule.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Story and example updated

* Update @navikt/core/react/src/read-more/ReadMore.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 Miscalculated border-radius fixed

* 📝 Desc-texts

* 📝 Short and long readmore demo

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-03-16 15:08:10 +01:00
Ken 763ed480ca [DataTabke] Only add tabIndex when keyboardsupport is enabled 2026-03-16 15:00:17 +01:00
Halvor Haugan 03a0ec0d69 Playroom: allow-forms 2026-03-16 14:51:06 +01:00
Anniken Granberg 66cb8e7c14 DataTable: ops wrong type 2026-03-16 14:20:01 +01:00
Anniken Granberg e527923580 DataTabel: bad example of our own drag and drop 2026-03-16 14:15:21 +01:00
Ken 7009d899f1 [DataTable] Support starting with auto size when maxWidth is smaller than auto 2026-03-16 12:47:01 +01:00
Ken 8976136b3e [DataTable] style-forwarding 2026-03-16 10:45:02 +01:00
Ken 59dff16be0 [DataTable] Handle focus in header-row and col-span better 2026-03-16 10:37:27 +01:00
KenandHalvor Haugan 7074d96fba README update (#4726)
* 📝 README update

* 📝 Update contributing.md

* Update CONTRIBUTING.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-03-16 09:40:30 +01:00
Halvor Haugan b4df1bd349 DataTable: Sort button css adjustments 2026-03-13 23:01:22 +01:00
Ken 93f31e23c9 [DataTable] Fixed dom-validation warning 2026-03-13 21:51:05 +01:00
Ken 521c5a1ac0 [DataTable] Added todo 2026-03-13 15:01:01 +01:00
Ken 5a356677b2 [DataTable] Added auto-sizing on double-click 2026-03-13 14:47:33 +01:00
Ken 28077c6edd [DataTable] Build-in resizing in TH cells 2026-03-13 14:28:50 +01:00
Anniken Granberg b43de6188e DataTable: Add alternative for rendering arrow icons that doesn't move 2026-03-13 13:02:11 +01:00
dependabot[bot] ae762f5c3e ⬆️ Bump the npm_and_yarn group across 2 directories with 2 updates (#4724)
Bumps the npm_and_yarn group with 2 updates in the /examples/astro directory: [svgo](https://github.com/svg/svgo) and [tar](https://github.com/isaacs/node-tar).
Bumps the npm_and_yarn group with 1 update in the /examples/shadow-dom directory: [tar](https://github.com/isaacs/node-tar).


Updates `svgo` from 4.0.0 to 4.0.1
- [Release notes](https://github.com/svg/svgo/releases)
- [Commits](https://github.com/svg/svgo/compare/v4.0.0...v4.0.1)

Updates `tar` from 7.5.9 to 7.5.10
- [Release notes](https://github.com/isaacs/node-tar/releases)
- [Changelog](https://github.com/isaacs/node-tar/blob/main/CHANGELOG.md)
- [Commits](https://github.com/isaacs/node-tar/compare/v7.5.9...v7.5.10)

Updates `tar` from 7.5.9 to 7.5.10
- [Release notes](https://github.com/isaacs/node-tar/releases)
- [Changelog](https://github.com/isaacs/node-tar/blob/main/CHANGELOG.md)
- [Commits](https://github.com/isaacs/node-tar/compare/v7.5.9...v7.5.10)

---
updated-dependencies:
- dependency-name: svgo
  dependency-version: 4.0.1
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: tar
  dependency-version: 7.5.10
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: tar
  dependency-version: 7.5.10
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-12 14:40:24 +01:00
Ken 293e9b3159 [DataTable] Updated sort-icon display 2026-03-12 13:16:35 +01:00
Ken 81ed901143 [DataTable] Added textAlign to table-cells 2026-03-12 12:54:10 +01:00
Halvor Haugan fd2d80c3e2 DataTable: No-framework story: Add support for resizing with touch 2026-03-12 12:35:32 +01:00
Halvor Haugan 31d9d44d93 ⬆️ Bump dompurify to 3.3.2 2026-03-12 11:48:05 +01:00
Halvor Haugan 553b2e48f3 Merge branch 'main' of github.com:navikt/aksel 2026-03-12 11:42:09 +01:00
Halvor Haugan 0acb173966 ⬆️ Bump tar to 7.5.10 2026-03-12 11:41:39 +01:00
Ken e20ef739bb 🐛 Sanity presentation-mode now resolves correct document. Fixed syntax error 2026-03-12 10:56:10 +01:00
Halvor Haugan eef03050b6 Add comment in LinkAnchor about auxClick 2026-03-12 10:51:15 +01:00
Ken f51ca8e1bd [DataTable] Misc CSS-adjustments to header, cells and resize-handle 2026-03-11 11:17:49 +01:00
Halvor Haugan 96a730c798 useDatepicker, useMonthpicker: Add descriptions to validation type (#4722) 2026-03-11 10:38:14 +01:00
Halvor Haugan 6716217e8e Adjust validation examples on Date/MonthPicker (#4721) 2026-03-11 10:26:50 +01:00
Halvor Haugan d7034a7c93 ⬆️ Bump svgo to 3.3.3 2026-03-11 09:40:28 +01:00
dependabot[bot] 7b2692a3fe ⬆️ Bump simple-git from 3.30.0 to 3.32.3 (#4720)
Bumps [simple-git](https://github.com/steveukx/git-js/tree/HEAD/simple-git) from 3.30.0 to 3.32.3.
- [Release notes](https://github.com/steveukx/git-js/releases)
- [Changelog](https://github.com/steveukx/git-js/blob/main/simple-git/CHANGELOG.md)
- [Commits](https://github.com/steveukx/git-js/commits/simple-git@3.32.3/simple-git)

---
updated-dependencies:
- dependency-name: simple-git
  dependency-version: 3.32.3
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-11 09:34:56 +01:00
Anniken Granberg fad46c010b DataTable: Styling fix and keyboard bug fix 2026-03-10 15:58:03 +01:00
Ken 938324cb8f 🐛 Resolve import type issue 2026-03-10 15:47:42 +01:00
Ken 789d7f8312 🐛 GodPraksis tema-page now works in preview-mode 2026-03-10 15:44:43 +01:00
Ken 15cd549d44 🐛 Test having direct-imports for better bundle-analyzer 2026-03-10 15:37:52 +01:00
Ken 0ec9e25603 🐛 useScrollLock now handles scrollbar-gutter better (#4703)
* 🐛 useScrollLock now handles scrollbar-gutter better

* 🔥 Removed aditional story

* 📝 COmment

* 📝 OS -> MacOs
2026-03-10 15:25:13 +01:00
Ken b96ecff836 🎉 Removed tabindex-change based on open-state in date-input (#4714) 2026-03-10 13:06:04 +01:00
Anniken Granberg 37c952adad DataTable: create DataDragAndDropDragHandler and update styles 2026-03-10 12:55:17 +01:00
Halvor Haugan a4854226c6 Upgrade Playroom (#4716) 2026-03-10 12:47:20 +01:00
dependabot[bot]andKen 3a9318406e ⬆️ Bump @eslint/js from 9.39.2 to 10.0.1 in the eslint group across 1 directory (#4706)
* ⬆️ Bump @eslint/js in the eslint group across 1 directory

Bumps the eslint group with 1 update in the / directory: [@eslint/js](https://github.com/eslint/eslint/tree/HEAD/packages/js).


Updates `@eslint/js` from 9.39.2 to 10.0.1
- [Release notes](https://github.com/eslint/eslint/releases)
- [Commits](https://github.com/eslint/eslint/commits/v10.0.1/packages/js)

---
updated-dependencies:
- dependency-name: "@eslint/js"
  dependency-version: 10.0.1
  dependency-type: direct:development
  update-type: version-update:semver-major
  dependency-group: eslint
...

Signed-off-by: dependabot[bot] <support@github.com>

* 🏷️ Fix new lint rules

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2026-03-10 11:36:25 +01:00
Halvor Haugan 55a5ad4671 [website] Fix bug when clicking on active example chip (#4713) 2026-03-10 09:09:59 +01:00
Halvor Haugan 7fbf9c3c4f [website] Fix "Oppdater godkjenningsdato" button (#4705) 2026-03-10 09:09:42 +01:00
dependabot[bot] 9c322bfd7e ⬆️ Bump the actions group with 2 updates (#4709)
Bumps the actions group with 2 updates: [docker/login-action](https://github.com/docker/login-action) and [docker/build-push-action](https://github.com/docker/build-push-action).


Updates `docker/login-action` from 3 to 4
- [Release notes](https://github.com/docker/login-action/releases)
- [Commits](https://github.com/docker/login-action/compare/v3...v4)

Updates `docker/build-push-action` from 6 to 7
- [Release notes](https://github.com/docker/build-push-action/releases)
- [Commits](https://github.com/docker/build-push-action/compare/v6...v7)

---
updated-dependencies:
- dependency-name: docker/login-action
  dependency-version: '4'
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: actions
- dependency-name: docker/build-push-action
  dependency-version: '7'
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: actions
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-10 08:57:52 +01:00
Halvor Haugan 5be17b9bea Merge branch 'main' of github.com:navikt/aksel 2026-03-09 21:21:14 +01:00
Halvor Haugan 180ab068c2 ⬆️ Bump figlet 2026-03-09 21:20:49 +01:00
dependabot[bot] 250824bff5 ⬆️ Bump globals from 17.3.0 to 17.4.0 (#4708)
Bumps [globals](https://github.com/sindresorhus/globals) from 17.3.0 to 17.4.0.
- [Release notes](https://github.com/sindresorhus/globals/releases)
- [Commits](https://github.com/sindresorhus/globals/compare/v17.3.0...v17.4.0)

---
updated-dependencies:
- dependency-name: globals
  dependency-version: 17.4.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-09 21:14:26 +01:00
dependabot[bot] 50fc325fbd ⬆️ Bump react-router from 7.13.0 to 7.13.1 (#4707)
Bumps [react-router](https://github.com/remix-run/react-router/tree/HEAD/packages/react-router) from 7.13.0 to 7.13.1.
- [Release notes](https://github.com/remix-run/react-router/releases)
- [Changelog](https://github.com/remix-run/react-router/blob/main/packages/react-router/CHANGELOG.md)
- [Commits](https://github.com/remix-run/react-router/commits/react-router@7.13.1/packages/react-router)

---
updated-dependencies:
- dependency-name: react-router
  dependency-version: 7.13.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-09 21:13:24 +01:00
Halvor Haugan 4316ca4782 Listbox: Rename sub-components 2026-03-09 15:11:55 +01:00
github-actions[bot] c5ff537870 Version Packages (#4692)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-03-09 12:03:01 +01:00
Halvor Haugan ede1f6024e Fix typo in changeset text 2026-03-09 10:33:08 +01:00
Halvor Haugan b5c5e69bcf DataTable: Refactor Listbox 2026-03-06 19:36:28 +01:00
Ken f1a21b314f [Datepicker] 🐛 Fixed issue where using fixedWeeks still caused layout shifts i… (#4701)
* 🐛 Fixed issue where using fixedWeeks still caused layout shifts in cases of last/first month

* 📝 storybook demo

* 💄 Now supoorts breakpoints better

* ♻️ Use css-variables

* 🐛 Even more placeholder space for chromatic demo

* 🐛 Accound for missing padding

* 📝 Moved story order
2026-03-06 15:05:29 +01:00
Halvor Haugan 955b8930e6 [website] Adjust Switch examples + OG-description field desc + metadata query (#4704) 2026-03-06 14:26:30 +01:00
Halvor Haugan 5086556f27 ⬆️ Upgrade deps in examples/shadow-dom 2026-03-06 12:09:49 +01:00
Halvor Haugan 8cdd2d5b15 ⬆️ Upgrade deps in examples/astro 2026-03-06 12:01:17 +01:00
Halvor Haugan bbd68a9ff8 DataTable: Small adjustments in AutoSuggest 2026-03-05 18:54:54 +01:00
Halvor Haugan 3a4780fd79 Remove unused file Cube.tsx 2026-03-05 16:35:49 +01:00
Halvor Haugan a70256ce16 [website] Hover styling on God praksis hero button (#4697) 2026-03-05 13:03:35 +01:00
Ken 1b4924b6e3 God praksis sanity: remove legacy-view for tema-contacts 2026-03-05 11:59:25 +01:00
Ken 61319a2a34 🏷️ RootElement prop now accepts null as value. (#4700) 2026-03-05 11:30:50 +01:00
538c59a2ef [Sanity] Publishing wizard (#4691)
* ⬆️ Sanity update

* 🎉 Working custom update view

* 🎉 Better publishing workflow

* 🎉 Update logic and texts

* 📝 Update blueprint config

* 🐛 Handle unpublished documents

* 📝 Remove unused description

* add function that unsets lastVerified on unpublish

* small InfoCard

* ⚡ Optimize

* Update aksel.nav.no/website/sanity/schema/custom-components/updateInfo.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/sanity/schema/custom-components/updateInfo.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Added readme

* Update aksel.nav.no/website/sanity/plugins/publication-flow/actions/lastVerified.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/sanity/functions/README.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-03-05 11:18:35 +01:00
Ken d3f87c5c80 🐛 Calculate margin on open in God-praksis hero 2026-03-05 11:16:59 +01:00
Halvor Haugan 665729641f Refactor some less-than-ideal usage of the ref prop (#4699) 2026-03-05 10:10:06 +01:00
Ken 41f14751fd 🐛 Resolve failing tests in data-table autocomplete generation 2026-03-05 10:05:48 +01:00
Ken c8dca96c14 [DataTable] Implemented datatable + tokenfilter demo 2026-03-04 16:40:01 +01:00
Ken e7f3761fab [DataTable] Implemented working tokenfilter demo 2026-03-04 16:34:14 +01:00
Ken 18dbb9a200 [DataTable] 🎉 Updated sort-button handler 2026-03-04 15:21:06 +01:00
Ken 6a45d097c8 [DataTable] Build in columns and items support demo 2026-03-04 13:50:21 +01:00
Anniken Granberg 0cbf7f5341 DataTable: integrate drag-and-drop functionality for column ordering example 2026-03-04 13:39:58 +01:00
Anniken Granberg 8abc0c0285 DataTable: create drag-and-drop component 2026-03-04 12:04:25 +01:00
KenandHalvor Haugan 8285d80751 Datepicker popover autofocus on open (#4676)
* 🧪 Test focus on datepicker popover

* 🎉 Handle state-updates better

* 🎉 Further delay datepicker button re-focus

* 📝 Changelog

* 🐛 Handle label ids dynamically

* 🐛 Use correct id

* 🐛 Avoid using contexts where not needed

* 🐛 Remove requirement for label

* 🐛 Resolve use of non assigned context

* 📝 Rename removal

* Update .changeset/forty-ads-tell.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ⚡ Optimize autofocus

* ⚡ Remove need for useCallback

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-03-04 10:42:49 +01:00
Halvor Haugan e03e73d7e8 Storybook: Set lang attribute according to selected language (#4693) 2026-03-04 09:26:20 +01:00
Ken b343c2f7a0 [DataTable] 🐛 Resolve missing update after sorting update 2026-03-03 16:21:11 +01:00
Ken 6d1d57d114 [DataTable] TableHeader is now a button when sorting 2026-03-03 15:36:11 +01:00
Halvor Haugan 9911a68ca7 DataTable: TokenFilter: Use Listbox subcomponents 2026-03-03 13:17:03 +01:00
Halvor Haugan 1653b7e2d4 Listbox: role=combobox 2026-03-03 12:43:02 +01:00
Halvor Haugan cb2d2b25c3 DataTable: Use Listbox in TokenFilter 2026-03-03 11:40:36 +01:00
Ken ab2e6062fb [DataTable] Css cleanup 2026-03-03 10:32:17 +01:00
Ken 9d8b9ffca8 [DataTable] Implement auto-grow cell in fixed tables 2026-03-03 10:31:13 +01:00
Ken 0b4bccdeb2 [DataTable] 🧪 Testing placeholder cells 2026-03-02 18:06:46 +01:00
Halvor Haugan 723eb0c82a ⬆️ Bump minimatch and glob 2026-03-02 16:50:50 +01:00
Anniken Granberg edc4781c82 DataTable: block keyboard navigation for specific elements 2026-03-02 16:37:13 +01:00
Halvor Haugan 4a55f901b0 DataTable: Listbox utility component 2026-03-02 16:07:22 +01:00
Halvor Haugan 28d4a07576 Add internal hook useDeferredValue (#4690) 2026-03-02 15:06:27 +01:00
Ken 112cea77bb [InlineMessage] 🎉 Updated InlineMessage to use BodyLong based on review (#4683)
* 🎉 Updated InlineMessage to use BodyLong based on review

* 🐛 Avoid duplicating typo-import
2026-03-02 14:59:43 +01:00
dependabot[bot] bfa1aef07e Bump commander from 14.0.2 to 14.0.3 (#4687)
Bumps [commander](https://github.com/tj/commander.js) from 14.0.2 to 14.0.3.
- [Release notes](https://github.com/tj/commander.js/releases)
- [Changelog](https://github.com/tj/commander.js/blob/master/CHANGELOG.md)
- [Commits](https://github.com/tj/commander.js/compare/v14.0.2...v14.0.3)

---
updated-dependencies:
- dependency-name: commander
  dependency-version: 14.0.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-02 14:58:11 +01:00
dependabot[bot] 8be4c55b2b Bump the actions group with 2 updates (#4688)
Bumps the actions group with 2 updates: [actions/upload-artifact](https://github.com/actions/upload-artifact) and [actions/download-artifact](https://github.com/actions/download-artifact).


Updates `actions/upload-artifact` from 6 to 7
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v6...v7)

Updates `actions/download-artifact` from 7 to 8
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](https://github.com/actions/download-artifact/compare/v7...v8)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: '7'
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: actions
- dependency-name: actions/download-artifact
  dependency-version: '8'
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: actions
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-02 14:57:17 +01:00
Anniken Granberg 63ee00ad08 DataTable: keyboard resizing support 2026-03-02 14:34:24 +01:00
dependabot[bot] a19df981d0 Bump the npm_and_yarn group across 2 directories with 1 update (#4689)
Bumps the npm_and_yarn group with 1 update in the /examples/astro directory: [rollup](https://github.com/rollup/rollup).
Bumps the npm_and_yarn group with 1 update in the /examples/shadow-dom directory: [rollup](https://github.com/rollup/rollup).


Updates `rollup` from 4.57.1 to 4.59.0
- [Release notes](https://github.com/rollup/rollup/releases)
- [Changelog](https://github.com/rollup/rollup/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rollup/rollup/compare/v4.57.1...v4.59.0)

Updates `rollup` from 4.57.1 to 4.59.0
- [Release notes](https://github.com/rollup/rollup/releases)
- [Changelog](https://github.com/rollup/rollup/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rollup/rollup/compare/v4.57.1...v4.59.0)

---
updated-dependencies:
- dependency-name: rollup
  dependency-version: 4.59.0
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: rollup
  dependency-version: 4.59.0
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-02 09:10:07 +01:00
dependabot[bot] 98ccb5c3ed Bump rimraf from 6.1.2 to 6.1.3 (#4685)
Bumps [rimraf](https://github.com/isaacs/rimraf) from 6.1.2 to 6.1.3.
- [Changelog](https://github.com/isaacs/rimraf/blob/main/CHANGELOG.md)
- [Commits](https://github.com/isaacs/rimraf/compare/v6.1.2...v6.1.3)

---
updated-dependencies:
- dependency-name: rimraf
  dependency-version: 6.1.3
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-02 09:03:56 +01:00
Halvor Haugan 27633dbd03 ⬆️ Upgrade React (#4684) 2026-02-27 14:59:56 +01:00
Ken 88c5e8d589 🧪 Added slider to test disabled-opacity token 2026-02-27 12:53:44 +01:00
Ken f1beb98e2c 🧪 Added disabled button to form story 2026-02-27 12:31:45 +01:00
Ken a7253d2287 🧪 Added disabled form story 2026-02-27 12:29:11 +01:00
Halvor Haugan 5e3b0ffa5b ➖ Remove postcss from figma-plugin (#4682) 2026-02-27 11:51:52 +01:00
Halvor Haugan f71c96f552 ⬆️ Upgrade Storybook (#4681) 2026-02-27 10:52:58 +01:00
Halvor Haugan 739e349ff3 ⬆️ Bump rollup (#4680) 2026-02-27 10:42:23 +01:00
dependabot[bot] 34e4dadf5e Bump the npm_and_yarn group across 2 directories with 1 update (#4678)
Bumps the npm_and_yarn group with 1 update in the /examples/astro directory: [minimatch](https://github.com/isaacs/minimatch).
Bumps the npm_and_yarn group with 1 update in the /examples/shadow-dom directory: [minimatch](https://github.com/isaacs/minimatch).


Updates `minimatch` from 10.2.1 to 10.2.2
- [Changelog](https://github.com/isaacs/minimatch/blob/main/changelog.md)
- [Commits](https://github.com/isaacs/minimatch/compare/v10.2.1...v10.2.2)

Updates `minimatch` from 10.2.1 to 10.2.2
- [Changelog](https://github.com/isaacs/minimatch/blob/main/changelog.md)
- [Commits](https://github.com/isaacs/minimatch/compare/v10.2.1...v10.2.2)

---
updated-dependencies:
- dependency-name: minimatch
  dependency-version: 10.2.2
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: minimatch
  dependency-version: 10.2.2
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-27 10:22:30 +01:00
Halvor Haugan 418dd5b254 ⬆️ Bump minimatch 2026-02-27 09:59:21 +01:00
Halvor Haugan 294c2e6241 ⬆️ Bump basic-ftp 2026-02-27 09:50:39 +01:00
Ken df5416eb8d [DataTable] 🐛 Flip naming convention in token-filter 2026-02-24 14:40:55 +01:00
Halvor Haugan 0217af895e Delete referansesider-spa-deploy.yml (#4671) 2026-02-24 11:18:21 +01:00
KenandCopilot Autofix powered by AI 0e3eed8854 [Website] Markdown routes and portable blocks (#4672)
* 🎉 Initial markdown setup

* 🚚 Move helpers

* 🎉 Markdown-types

* 🎉 Added marks

* 📝 Updated token fallback comment

* 🎉 Added metadata-header

* 🎉 Updated kode-title header

* 🔥 Remove working test, only show when testing

* 📝 Comments

* ⬅️ Use supported version

* Potential fix for code scanning alert no. 58: Incomplete string escaping or encoding

Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>

---------

Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
2026-02-24 09:27:48 +01:00
Ken 47d60322cf [DataTable] 🐛 Resolve incorrect type-conversion 2026-02-23 16:39:07 +01:00
Ken ef13e6c7bd [DataTable] Filter types refactor 2026-02-23 16:34:30 +01:00
Ken 2d5afa57c3 [DataTable] Set up change handler for token-filter 2026-02-23 15:22:46 +01:00
github-actions[bot] 8ad0dd4288 Version Packages (#4666)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-23 14:24:36 +01:00
dependabot[bot] 66f11b6678 Bump @vitest/eslint-plugin from 1.6.7 to 1.6.9 in the vitest group (#4673)
Bumps the vitest group with 1 update: [@vitest/eslint-plugin](https://github.com/vitest-dev/eslint-plugin-vitest).


Updates `@vitest/eslint-plugin` from 1.6.7 to 1.6.9
- [Release notes](https://github.com/vitest-dev/eslint-plugin-vitest/releases)
- [Commits](https://github.com/vitest-dev/eslint-plugin-vitest/compare/v1.6.7...v1.6.9)

---
updated-dependencies:
- dependency-name: "@vitest/eslint-plugin"
  dependency-version: 1.6.9
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: vitest
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-23 09:40:55 +01:00
dependabot[bot] 3dcd3a4874 Bump globals from 16.5.0 to 17.3.0 (#4675)
Bumps [globals](https://github.com/sindresorhus/globals) from 16.5.0 to 17.3.0.
- [Release notes](https://github.com/sindresorhus/globals/releases)
- [Commits](https://github.com/sindresorhus/globals/compare/v16.5.0...v17.3.0)

---
updated-dependencies:
- dependency-name: globals
  dependency-version: 17.3.0
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-23 09:38:26 +01:00
Halvor Haugan 547a565afa yarnrc: Add navikt to npmPreapprovedPackages (#4670) 2026-02-19 13:31:25 +01:00
Halvor Haugan ea83c18937 Remove referansesider from eslint ignore 2026-02-19 13:19:11 +01:00
Halvor Haugan 2af57f66c1 ⬆️ Remove examples "next-appdir" and "referansesider", upgrade deps in the rest (#4669) 2026-02-19 13:08:48 +01:00
Ken 47411e209f Merge branch 'main' of https://github.com/navikt/aksel 2026-02-19 12:39:28 +01:00
Ken 69bea7f51d 🐛 Revert focus-state handle update in ToggleGroup (#4668) 2026-02-19 12:38:19 +01:00
Ken 2472765f78 [DataTable] Added story for multiple tokens 2026-02-19 12:35:10 +01:00
Halvor Haugan 9012ea4760 Stylelint plugin: Remove redundant code (#4667) 2026-02-19 12:26:51 +01:00
Ken ecb05c4184 [DataTable] comment cleanup 2026-02-19 11:23:17 +01:00
Ken 925d3a3be7 [DataTable] Removed unused filteringTag 2026-02-19 11:16:32 +01:00
Ken d7cda7e623 [DataTable] Show properties when starting to type instead of just values 2026-02-19 10:32:09 +01:00
Ken 914d38db12 Merge branch 'main' of https://github.com/navikt/aksel 2026-02-19 10:18:50 +01:00
Ken dcf4c54e6e [DataTable] Unify datastructure for autocomplete options 2026-02-19 09:51:31 +01:00
Halvor HauganandKen f4e980eeed ⬆️ Upgrade stylelint (#4662)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2026-02-19 09:27:34 +01:00
Ken fe00807e6b 🐛 Update yarn lock 2026-02-19 09:25:24 +01:00
dependabot[bot] 23589bd40d ⬆️ Bump lint-staged from 16.1.5 to 16.2.7 (#4649)
Bumps [lint-staged](https://github.com/lint-staged/lint-staged) from 16.1.5 to 16.2.7.
- [Release notes](https://github.com/lint-staged/lint-staged/releases)
- [Changelog](https://github.com/lint-staged/lint-staged/blob/main/CHANGELOG.md)
- [Commits](https://github.com/lint-staged/lint-staged/compare/v16.1.5...v16.2.7)

---
updated-dependencies:
- dependency-name: lint-staged
  dependency-version: 16.2.7
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-19 09:22:40 +01:00
github-actions[bot] fd6b9a43bd Version Packages (#4665)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-18 16:53:34 +01:00
Halvor Haugan 2caeacc21b Timeline: Adjust pin position (#4664) 2026-02-18 16:45:37 +01:00
Halvor Haugan 26264a7677 DataTable: New prop called "layout", and more 2026-02-18 16:42:12 +01:00
Ken 9eecccdc2d Merge branch 'main' of https://github.com/navikt/aksel 2026-02-18 16:36:25 +01:00
Ken 7c4a079019 [DataTable] Added tests for new operator customization 2026-02-18 16:35:50 +01:00
Ken baaea9770a [DataTable] Added option to customize operators for each filter 2026-02-18 16:27:08 +01:00
Halvor Haugan 028f456388 ⬆️ Upgrade Chromatic and @trivago/prettier-plugin-sort-imports (#4661) 2026-02-18 16:06:38 +01:00
Ken 0f16b01e63 [DataTable] Autosuggest options generation refactor (#4663)
* WIP

* [DataTable] Add tests and fix free-text logic

* ♻️ Cleanup

* ♻️ Refactor text-matcher

* 🚚 Extracted query-build API

* 🚚 Extracted grouping api

* 🚚 Update value option creation

* 📝 Jsdoc

* 🏷️ Update types

* 🚚 Extract operator utils

* 🧪 Extracted operator-tests

* ⚡ Make sure performance is consistent

* 🎉 Implemented autosuggest demo
2026-02-18 16:06:13 +01:00
Halvor Haugan 3b13616c95 ⬆️ Upgrade dependencies (#4660) 2026-02-18 14:24:06 +01:00
dependabot[bot] 79aa63746e ⬆️ Bump markdown-it from 14.1.0 to 14.1.1 (#4658)
Bumps [markdown-it](https://github.com/markdown-it/markdown-it) from 14.1.0 to 14.1.1.
- [Changelog](https://github.com/markdown-it/markdown-it/blob/master/CHANGELOG.md)
- [Commits](https://github.com/markdown-it/markdown-it/compare/14.1.0...14.1.1)

---
updated-dependencies:
- dependency-name: markdown-it
  dependency-version: 14.1.1
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-18 13:03:23 +01:00
github-actions[bot] 855925cf38 Version Packages (#4657)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-18 09:55:03 +01:00
Christian Skrøvseth e28bd67ed9 Add missing key prop to nested Tooltip shortcuts (#4656) 2026-02-18 09:40:27 +01:00
Ken 9c86ff3b5f ⬅️ Revert last changes to allow PR to go trough 2026-02-18 09:39:53 +01:00
Ken e5702e719b [Tooltip] Added missing key-prop when mapping shortcut in fragment 2026-02-18 09:37:45 +01:00
Ken 449cf3e661 🐛 Avoid crashing page when navigating trough god-praksis in preview-mode 2026-02-17 16:29:33 +01:00
Ken 866b93b6e2 [DataTable] Document expected behaviour for autosuggest option generation 2026-02-17 15:57:28 +01:00
Ken 4806fd4f9a [DataTable] Resolve failing tests 2026-02-17 15:26:54 +01:00
Ken a8534aa229 Merge branch 'main' of https://github.com/navikt/aksel 2026-02-17 15:22:14 +01:00
Ken 3f27574a1c [DataTable] Autocomplete: Generate list of options 2026-02-17 15:21:55 +01:00
Ken 8461510d9a [DataTable] Autocomplete option generation update 2026-02-17 14:34:30 +01:00
Ken d8fa95b8e2 [DataTable] Autocomplete option refactor 2026-02-17 14:28:59 +01:00
Ken 1deb97dad2 [DataTable] Mock autocomplete component 2026-02-17 14:23:55 +01:00
Ken a2fdbf7e40 [DataTable] AutoComplete suggestion option generation 2026-02-17 13:53:46 +01:00
Halvor Haugan f89271cdd7 [website] Endringslogg: Don't clear input when toggling semver (#4654) 2026-02-17 13:37:54 +01:00
Halvor Haugan 9f501c5b08 DataTable: Improved (?) border styling that works with colspan/rowspan 2026-02-17 12:46:29 +01:00
Halvor Haugan 518135a741 DataTable: Fix issue with resize handle on last column 2026-02-17 12:41:50 +01:00
Halvor HauganandKen 84747373f0 [website] Fix issues with global search (#4653)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2026-02-17 11:58:40 +01:00
Ken 4db531bad8 [DataTable] Resolve file-name switchup 2026-02-17 10:51:27 +01:00
Ken d678db2542 [DataTable] Query parsing in text-filter 2026-02-17 10:29:57 +01:00
Ken 5e848cfde2 [DataTable] Filtering parsing --no-verify 2026-02-17 09:48:18 +01:00
Karl-Magnus Thorsnes fe3611025c - Vis hurtigtast ut fra enhetens OS i globalSearch.dialog (#4652) 2026-02-17 09:31:00 +01:00
Anniken Granberg f95ff765d2 DataTable: Forgot padding 2026-02-16 19:44:49 +01:00
Anniken Granberg beebf35833 [DataTable]: Replace ActionMenu with Dialog for settings adjustments 2026-02-16 19:34:12 +01:00
Anniken Granberg 739aa80525 [DataTable] Change zebra stripes and truncate content styles to use data prop 2026-02-16 19:30:04 +01:00
Halvor Haugan fb3238d30c DataTable: Improved (?) border styling that works with colspan/rowspan 2026-02-16 15:40:44 +01:00
Halvor Haugan 418a2f7a23 DataTable: Fix issue with resize handle on last column 2026-02-16 15:36:47 +01:00
Ken 37f1581b95 Merge remote-tracking branch 'refs/remotes/origin/main' 2026-02-16 13:03:43 +01:00
github-actions[bot] 765032d4e2 Version Packages (#4644)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-16 12:37:55 +01:00
Ken 51ae3163cc [DataTable] Resolve rowspan/colspan focus check bug 2026-02-16 12:01:15 +01:00
Ken 758969848f [DataTable] Grid-navigation tests 2026-02-16 11:55:24 +01:00
Ken 6beef2453b [DataTable] More tests, separate focus-cell concerns 2026-02-16 10:52:40 +01:00
Ken 5500280a3f [DataTable] table-grid tests 2026-02-16 10:25:54 +01:00
Ken 1a3dd1c80e [DataTable] Doc updates 2026-02-16 10:20:40 +01:00
Ken b83114dc80 Merge remote-tracking branch 'refs/remotes/origin/main' 2026-02-13 17:26:57 +01:00
Ken 363dd78e49 [DataTable] Added more key-supports, better tabIndex handling 2026-02-13 15:31:51 +01:00
Halvor Haugan 2987059974 [website] Adjust examples for Tooltip and List (#4645) 2026-02-13 15:22:58 +01:00
Ken 8af2ddb3b9 [DataTable] Update focus-utilities 2026-02-13 14:39:24 +01:00
Ken 318d736438 🎉 extract grid utility 2026-02-13 14:29:29 +01:00
Ken bb9da09260 [DataTable] 🏷️ Rename functions for keyboard-nav 2026-02-13 13:58:30 +01:00
Ken 34b227f966 [DataTable] Make some utilities more pure, avoid side-effects 2026-02-13 13:30:00 +01:00
Ken aa977f0c11 [DataTable] Extract maxCols from table grid on the fly 2026-02-13 12:49:35 +01:00
Ken 214e971963 [DataTable] Remove focus-handler for table element 2026-02-13 12:39:42 +01:00
Halvor Haugan 4337b00e33 Process: Allow mix of single items and array as children (#4643) 2026-02-13 11:09:28 +01:00
KenandHalvor Haugan 49e01f13dc 🎉 Support as-prop in Accordion and LinkCard (#4641)
* 🎉 Support as-prop in Accordion and LinkCard

* Update @navikt/core/react/src/link-card/LinkCard.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-02-13 10:44:47 +01:00
github-actions[bot] 1504c21978 Version Packages (#4640)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-13 09:42:32 +01:00
Halvor Haugan 2f6f97fc5a [website] Fix issue where example iframe doesn't load on initial render (SSR) (#4642) 2026-02-13 09:18:27 +01:00
Halvor Haugan 1ab26af8ba DataTable: Resize handle adjustments 2026-02-12 15:02:39 +01:00
fcdb044098 use dev url for umami tracking on dev (#4637)
* Initial plan

* Update dev tracking URL to new dev environment

Co-authored-by: JulianNymark <819074+JulianNymark@users.noreply.github.com>

* Fix: Use PRODUCTION env var instead of NODE_ENV for environment check

Co-authored-by: JulianNymark <819074+JulianNymark@users.noreply.github.com>

* chore: smart data > smart code

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: JulianNymark <819074+JulianNymark@users.noreply.github.com>
Co-authored-by: Julian Nymark <julian.nymark@nav.no>
2026-02-12 14:08:01 +01:00
Anniken Granberg f160e29d37 [DataTable] Add select functionality 2026-02-12 11:30:14 +01:00
Ken b7a865aa4f 🐛 Single-select text in combobox did not respect size-prop (#4638) 2026-02-12 11:29:21 +01:00
github-actions[bot] 2326f12a33 Version Packages (#4622)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-11 15:42:42 +01:00
Ken 4ea67c17b3 [Storybook] ⚡ optimize path resolving, decorator rendering 2026-02-11 15:30:30 +01:00
Ken 300eb00208 [DataTable] Resolve issue where focusing resize-handle auto-focused first cell in table 2026-02-11 14:59:45 +01:00
Ken 9324e3fe77 Merge branch 'main' of https://github.com/navikt/aksel 2026-02-11 13:49:09 +01:00
Ken bfd4c2ed54 [DataTable] Keyboard-nav optimization, re-structure and documentation
📝 Added doucmentation
⚡ Cache table grid generation
♻️ Refactors op setup
♻️ Extract utils
📝 Added some comments
♻️ Extract utils
♻️ Extracted helpers
⚡ Re-building optimizations
2026-02-11 13:49:03 +01:00
Halvor Haugan 9eff5c101c DataTable: Rename Data.wofw.stories.tsx -> Data.no-framework.stories.tsx 2026-02-11 13:04:20 +01:00
Halvor Haugan 4a8d66aa9e ⬆️ Upgrade dependencies (#4636) 2026-02-11 12:57:47 +01:00
dependabot[bot] 5ba2c5ba42 ⬆️ Bump tar (#4634)
Bumps the npm_and_yarn group with 1 update in the /examples/referansesider directory: [tar](https://github.com/isaacs/node-tar).


Updates `tar` from 7.5.6 to 7.5.7
- [Release notes](https://github.com/isaacs/node-tar/releases)
- [Changelog](https://github.com/isaacs/node-tar/blob/main/CHANGELOG.md)
- [Commits](https://github.com/isaacs/node-tar/compare/v7.5.6...v7.5.7)

---
updated-dependencies:
- dependency-name: tar
  dependency-version: 7.5.7
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-11 12:41:44 +01:00
Halvor Haugan 72fcfb05a0 ⬆️ Upgrade @portabletext/block-tools (#4633) 2026-02-11 12:10:05 +01:00
Halvor Haugan 0b81ae2dbd [website] Add cursor:pointer to iconButton 2026-02-11 12:00:44 +01:00
Ken 66d84915b5 [Timeline] Row-label now supports React.ReactNode (#4626)
* 🎉 Added timeline label flexibility

* 📝 Rename timeline stories

* 📝 changeset

* 📝 Update label jsdoc
2026-02-11 11:59:50 +01:00
Ken eb60ac97cf 🐛 Combobox now supports only using filteredOptions with no options (#4627)
* 🐛 Combobox now supports only using filteredOptions with no options

* 📝 rename var
2026-02-11 11:55:28 +01:00
Ken 103786e8fc Merge branch 'main' of https://github.com/navikt/aksel 2026-02-11 11:54:07 +01:00
Ken c6d663b38c [DataTable] Update Keyboard-nav tests/stories. Prepare for cache refactor.
♻️ make test-utils more readable
🎉 Add story for testing cache
🎉 Input tests
2026-02-11 11:54:02 +01:00
Halvor Haugan 54189c9c91 useEventListener: Add return type to interface (#4632) 2026-02-11 10:09:08 +01:00
Halvor Haugan ffa2539eaa Prettier (#4623) 2026-02-11 10:04:54 +01:00
Halvor Haugan 4de7bfff92 [website] Fix bug where copy button contents was not updated when changing icon (#4631) 2026-02-11 09:59:57 +01:00
Ken 313628298f ♿ Changed avatar type + name from span to div for SR-separation 2026-02-10 16:03:38 +01:00
Ken 491a273b04 Merge branch 'main' of https://github.com/navikt/aksel 2026-02-10 15:57:49 +01:00
Ken 2499145f48 [DataTable] More robust keyboard-navigation
🎉 Add row/col span checks
🎉 Set up test
🚚 Extract utils to helpers
🎉 Observe active cell changes
🎉 Check for disabled elements when focusing
🐛 Handle selects
🎉 Handle inputs in table with keyboard nav
🎉 Inputs in table demo
⚡ Optimize lookup
2026-02-10 15:57:43 +01:00
Anniken Granberg 262e8d2306 DatePicker: Adjust gap in VStack for improved layout (#4630) 2026-02-10 15:45:27 +01:00
Anniken Granberg a6bf684750 [DatePicker] Added example for input range with one common error message (#4628)
* added example

* added story

* pr fixes
2026-02-10 14:29:32 +01:00
Ken 7a1c02238b Merge branch 'main' of https://github.com/navikt/aksel 2026-02-10 13:58:37 +01:00
Ken a093bedbbe 🎉 Set up col/row-span demo
🎉 Handle header focus better
2026-02-10 13:58:18 +01:00
Halvor Haugan d7e0a7dac7 DataTable: Fix bottom border in header 2026-02-10 13:56:08 +01:00
Ken ba8ff07bd2 Merge branch 'main' of https://github.com/navikt/aksel 2026-02-10 13:38:27 +01:00
Ken 8c99573e98 [DataTable] Add keyboard nav with focus and scroll-handler
🎉 Handle focus inside cell
2026-02-10 13:38:09 +01:00
Anniken Granberg 271f27dc63 [DataTable] add zebra stripes and content truncation features 2026-02-10 13:31:26 +01:00
Halvor Haugan f401246f71 ToggleGroup: Remove unnecessary useEffect (#4625) 2026-02-10 10:01:12 +01:00
Halvor Haugan 97852d8a9b DataTable: Sticky header, more borders, no-page-scroll example 2026-02-10 10:00:35 +01:00
Ken 2d52f6ab32 Revert "⚡ Avoid prefetching all routes with NextLink". Some links stopped working
This reverts commit d49151a91e.
2026-02-09 20:07:18 +01:00
Ken d49151a91e ⚡ Avoid prefetching all routes with NextLink 2026-02-09 19:12:04 +01:00
Ken fe9f84e783 [DataTable] 🎉 Added boilerplate for keyboard-navigation 2026-02-09 16:25:42 +01:00
Ken 49c220b2bc 📝 Link to correct admin URL when logging deleted prop-data sync 2026-02-09 15:45:17 +01:00
Ken f8d6054a85 🐛 Docgen no longer found FileUploadItem 2026-02-09 14:48:29 +01:00
Ken 483bb8f4f1 [🧹 ] Moved actionmenu to root, primitives moved from /layout -> /primitives (#4613)
* 🚚 Moved primitives

* 🚚 Moved overlays and actionmenu

* 🐛 Fix import update
2026-02-09 14:40:59 +01:00
Ken b62435d579 [Parts rewrite] ♻️ Re-structure fileupload project (#4615)
* ♻️ Re-structure fileupload project

* 📝 Rename itemroot -> item
2026-02-09 14:29:22 +01:00
KenandHalvor Haugan b286ac28f1 [Parts rewirte] ♻️ Collapsible structure update (#4614)
* ♻️ Collapsible parts update

* 🐛 use correct names exports

* Update @navikt/core/react/src/collapsible/root/CollapsibleRoot.context.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-02-09 14:29:07 +01:00
Ken 64a671b334 [ActionMenu] 🎉 Updated animation and fixed subtrigger icon bug (#4612)
* 🎉 Updated animation and fixed subtrigger icon bug in ActionMenu

* 🐛 Fix actionmenu transform origin bug

* ♻️ Remove duplicate css
2026-02-09 14:28:26 +01:00
dependabot[bot] 2730853d68 ⬆️ Bump esbuild from 0.25.12 to 0.27.2 (#4596)
Bumps [esbuild](https://github.com/evanw/esbuild) from 0.25.12 to 0.27.2.
- [Release notes](https://github.com/evanw/esbuild/releases)
- [Changelog](https://github.com/evanw/esbuild/blob/main/CHANGELOG.md)
- [Commits](https://github.com/evanw/esbuild/compare/v0.25.12...v0.27.2)

---
updated-dependencies:
- dependency-name: esbuild
  dependency-version: 0.27.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-09 14:05:55 +01:00
87cbc0253f ⬆️ Bump next from 16.1.2 to 16.1.5 in /aksel.nav.no/website in the npm_and_yarn group across 1 directory (#4579)
* ⬆️ Bump next

Bumps the npm_and_yarn group with 1 update in the /aksel.nav.no/website directory: [next](https://github.com/vercel/next.js).


Updates `next` from 16.1.2 to 16.1.5
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/compare/v16.1.2...v16.1.5)

---
updated-dependencies:
- dependency-name: next
  dependency-version: 16.1.5
  dependency-type: direct:production
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>

* yarn.lock update

* ⬆️ Update next

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2026-02-09 14:03:15 +01:00
Ken 045342ca70 ⚡ Add concurrency cancel for e2e action 2026-02-09 14:01:05 +01:00
Ken bd1eb8532e ⚡ Add concurrency cancel for bundle-actions 2026-02-09 13:59:41 +01:00
Anniken Granberg a2f08f7768 [DataTable] Add row density options to DataTable component and stories 2026-02-09 10:27:39 +01:00
dependabot[bot] 28e6352e26 ⬆️ Bump react-router from 7.12.0 to 7.13.0 (#4595)
Bumps [react-router](https://github.com/remix-run/react-router/tree/HEAD/packages/react-router) from 7.12.0 to 7.13.0.
- [Release notes](https://github.com/remix-run/react-router/releases)
- [Changelog](https://github.com/remix-run/react-router/blob/main/packages/react-router/CHANGELOG.md)
- [Commits](https://github.com/remix-run/react-router/commits/react-router@7.13.0/packages/react-router)

---
updated-dependencies:
- dependency-name: react-router
  dependency-version: 7.13.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-09 09:54:31 +01:00
Halvor Haugan e9f935a25c DataTableProfiler: Move helper function getOpacity out of component 2026-02-09 09:50:16 +01:00
dependabot[bot] 7ce98d3ac0 ⬆️ Bump the vitest group with 3 updates (#4593)
Bumps the vitest group with 3 updates: [@vitest/browser](https://github.com/vitest-dev/vitest/tree/HEAD/packages/browser), [@vitest/browser-playwright](https://github.com/vitest-dev/vitest/tree/HEAD/packages/browser-playwright) and [@vitest/coverage-v8](https://github.com/vitest-dev/vitest/tree/HEAD/packages/coverage-v8).


Updates `@vitest/browser` from 4.0.17 to 4.0.18
- [Release notes](https://github.com/vitest-dev/vitest/releases)
- [Commits](https://github.com/vitest-dev/vitest/commits/v4.0.18/packages/browser)

Updates `@vitest/browser-playwright` from 4.0.17 to 4.0.18
- [Release notes](https://github.com/vitest-dev/vitest/releases)
- [Commits](https://github.com/vitest-dev/vitest/commits/v4.0.18/packages/browser-playwright)

Updates `@vitest/coverage-v8` from 4.0.17 to 4.0.18
- [Release notes](https://github.com/vitest-dev/vitest/releases)
- [Commits](https://github.com/vitest-dev/vitest/commits/v4.0.18/packages/coverage-v8)

---
updated-dependencies:
- dependency-name: "@vitest/browser"
  dependency-version: 4.0.18
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: vitest
- dependency-name: "@vitest/browser-playwright"
  dependency-version: 4.0.18
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: vitest
- dependency-name: "@vitest/coverage-v8"
  dependency-version: 4.0.18
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: vitest
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-09 09:43:40 +01:00
Halvor Haugan 1ec50ba5d9 Switch: Remove unnecessary useEffect (#4620) 2026-02-09 09:42:27 +01:00
Halvor Haugan ed9b920386 Box.stories.tsx: Refactor ThemingDemo story (#4621) 2026-02-09 09:12:37 +01:00
dependabot[bot] 3e1ec4d5e1 ⬆️ Bump tar from 7.5.6 to 7.5.7 (#4617)
Bumps [tar](https://github.com/isaacs/node-tar) from 7.5.6 to 7.5.7.
- [Release notes](https://github.com/isaacs/node-tar/releases)
- [Changelog](https://github.com/isaacs/node-tar/blob/main/CHANGELOG.md)
- [Commits](https://github.com/isaacs/node-tar/compare/v7.5.6...v7.5.7)

---
updated-dependencies:
- dependency-name: tar
  dependency-version: 7.5.7
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-09 09:08:00 +01:00
KenandHalvor Haugan 1a5aab396a [Website] 🎉 Detect user agent from header() for search-button icon (#4616)
* 🎉 Detect user agent from header for search-button icon

* Update aksel.nav.no/website/app/_ui/global-search/GlobalSearch.button.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ Remove no longer needed css

* 💄 KBD css updates

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-02-09 09:05:58 +01:00
Halvor Haugan 00fa8964ad [DataTable] Style adjustments, story adjustments, comments 2026-02-06 17:33:18 +01:00
github-actions[bot] 36d710cba8 Version Packages (#4610)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-06 13:38:52 +01:00
KenandHalvor Haugan b4664dc96e [Templates] 🐛 Add forced theme option (#4609)
* 🐛 Add forced theme option to template demos

* Update aksel.nav.no/website/components/website-modules/examples/withDsExample.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ Inline theme-class

* Update aksel.nav.no/website/components/website-modules/examples/withDsExample.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-02-06 13:01:10 +01:00
KenandHalvor Haugan da17a01b29 [Tooltip] 🎉 keys now accept multiple shortcuts (#4604)
* 🎉 Tooltip keys now accept multiple shortcuts

* ♻️ Add translations for tooltip divider

* Update @navikt/core/react/src/tooltip/Tooltip.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 💄 2->4px gap

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-02-06 12:45:04 +01:00
Karl-Magnus Thorsnes da8565b5f4 Button: ✨: Vis hurtigtast ut fra enhets OS (#4606)
* feat: Enhance GlobalSearchButton with platform-specific keyboard shortcuts

* feat: Update GlobalSearchButton to display platform-specific keyboard shortcuts

* Legg til "⌘" som default, legg til en liten animasjon som easer inn hurtigtasten ved førstegangs render
2026-02-06 11:52:37 +01:00
Ken 659e2748f4 [DataTable] Tanstack filtering testing 2026-02-06 11:47:32 +01:00
Ken 8d52cbde0c [Website] 🎉 Set up initial config for markdown pages 2026-02-05 15:02:26 +01:00
Halvor Haugan a0588a3dae [website] Fix FormProgress example "links" (#4611) 2026-02-05 12:59:03 +01:00
Halvor Haugan 6e71002e32 Chat: Fix avatar size when using icon from aksel-icons (#4608) 2026-02-05 11:58:19 +01:00
Ken 285d45c575 [DataTable] Experiment with Filter-view in column-header 2026-02-04 19:25:15 +01:00
Ken 36e45a8a39 [DataTable] Added todo 2026-02-04 12:22:25 +01:00
Ken 24ec3513c2 [DataTable] Dynamic view of th actions 2026-02-04 12:21:10 +01:00
Ken 547b99f6e5 [DataTable] Added Table footer component 2026-02-04 11:43:06 +01:00
Ken 463c70a20c [DataTable] Default to paginated demo for faster render 2026-02-04 10:20:12 +01:00
Ken 08ca5296af Merge branch 'main' of https://github.com/navikt/aksel 2026-02-04 10:13:05 +01:00
Ken 93a51d4f0b [DataTable] Profiler display
🎉 Added optional toggle
2026-02-04 10:11:05 +01:00
Halvor Haugan 207fada45e Fix eslint error 2026-02-04 09:26:50 +01:00
Ken 1b08ff37d9 Merge branch 'main' of https://github.com/navikt/aksel 2026-02-03 17:29:20 +01:00
Ken a30c150112 [DataTable] Updated actions, resize-handle and borders 2026-02-03 17:29:15 +01:00
Halvor Haugan dfa3afc595 eslint: exclude story-files from React-import restrictions 2026-02-03 17:08:23 +01:00
Halvor Haugan 5329255c08 DataTable: Story without framework 2026-02-03 16:58:19 +01:00
Halvor Haugan 6b4b924746 DataTable: Somewhat better perf when resizing in story 2026-02-03 16:43:09 +01:00
Ken da560f1124 [DataTable] Added sorting, optimized state 2026-02-03 16:17:40 +01:00
Ken 1d1ca54cd1 🐛 Move bundle-analyzer percentage to correct table-heading 2026-02-03 14:35:14 +01:00
Ken 5ef15bf1b1 🔥 Removed redundant if-checks in bundle-analyzer actions 2026-02-03 14:32:56 +01:00
Ken 10a258e7dd 🐛 Make sure bundle-analyzer uses correct script 2026-02-03 14:27:21 +01:00
Ken a4fc69bca5 Merge branch 'main' of https://github.com/navikt/aksel 2026-02-03 14:18:53 +01:00
Ken f592c2d757 🧪 Optimized bundle-analyzer to run in paralell 2026-02-03 14:18:38 +01:00
Ken 3ead8cf0ea 🎉 Better bundle-analyzer formatting, show percentage change 2026-02-03 14:04:51 +01:00
github-actions[bot] e5148d670c Version Packages (#4603)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-03 13:58:11 +01:00
Halvor Haugan c26d7a1a43 ExpansionCard/AccordionItem: Remove redundant class --no-animation (#4602) 2026-02-03 13:49:33 +01:00
Ken b38a38a117 [Website] ⚡ Test disabling sanity document-updating for redirects and cookies 2026-02-03 11:56:19 +01:00
Ken 3176806d29 📝 Avoid 'skipped checks' for bundle-action 2026-02-03 10:29:02 +01:00
Ken 5672990ce8 📝 Update bundle-analyzer markdown 2026-02-03 10:17:34 +01:00
Ken 51ac2602e3 🐛 Set analyzer workspace to private 2026-02-03 09:45:02 +01:00
github-actions[bot] 62a9cfb12d Version Packages (#4601)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-03 09:05:17 +01:00
Halvor Haugan e46a0fd394 Sync package versions (#4600) 2026-02-02 20:04:44 +01:00
Ken 74a268d40f [Sanity] 🐛 Fix backup-script (#4597)
* 🐛 Fix backup-script

* ➡️ Synk yarn
2026-02-02 15:20:44 +01:00
Ken 4b5f409d72 Merge branch 'main' of https://github.com/navikt/aksel 2026-02-02 15:17:36 +01:00
Ken 16e98acdef 🎉 Better bundle-analyzer formatting 2026-02-02 15:17:31 +01:00
Halvor Haugan 629884662c CLI: Remove redundant v8 codemods and fix issue running v8-tokens with other codemods (#4599) 2026-02-02 14:53:38 +01:00
Ken 5355b427be 🐛 Pull from correct package-dir in bundle analyzer 2026-02-02 14:22:21 +01:00
Ken 7f130fa460 📝 Update markdown format in Bundle-analyzer 2026-02-02 14:16:20 +01:00
Ken e75141e82a 🎉 Use artifact storage for bundle-analyzer 2026-02-02 13:53:59 +01:00
Ken 6cecd0a693 🐛 Handle non-existing temp-dir in Bundle analyzer 2026-02-02 12:38:09 +01:00
Ken 29bf6ef2bc 🐛 Correctly set up initial project structure for Bundle analyzer 2026-02-02 12:32:29 +01:00
4434ac5c08 [Bundle check] Bundle-size and config analyzer (#4580)
* 🎉 Set up bundle-analyzer workspace

* 📝 Cleaned up reporting code

* 🔥 Removed print of compare

* 🔥 Removed unused code

* rimnode=rimraf ./**/node_modules

* duplicate bundle for testing

* 🏷️ Sync tsconfig

* Classes

* 🎉 Add css compare function

* ⚡ Simplify css class

* 🔥 Remove regacy-files

* 🎉 Successfully extract exports

* 🎉 Extract types and components

* ♻️ Refactor looping

* 🐛 analyze correct file

* 🎉 Bundle size analyzer

* ♻️ Refactor use of classes

* ⚡ Streamline local analyzation

* 🎉 Add args

* 🎉 Interact with git actions

* 🎉 Compare function --no-verify

* 🎉 Add tests

* 🧪 More tests

* 🎉 Set up correct scripts

* 🎉 Added markdown-messaging

* 🎉 Set up action

* 🔥 removed temp analyzer code

* 🐛 Use correct ignore-script

* 🐛 Skip bundle-check for version-packages

* 🎉 Added version packages action

* Potential fix for code scanning alert no. 50: Workflow does not contain permissions

Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>

* Potential fix for code scanning alert no. 55: Workflow does not contain permissions

Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>

* ➡️ Synk permissions

* Update .github/workflows/bundle-check-npm.yml

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update .github/workflows/bundle-check-trunk.yml

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update scripts/analyzer/src/helpers/git-actions.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* ♻️ Function updates

* Update scripts/analyzer/src/analyze-css.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Cleanup

* 📝 Added comment on flatten

---------

Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-02-02 12:17:14 +01:00
Anniken GranbergandKen 60981fc091 Testing DataTable with column pinning and resizing features (#4589)
Co-authored-by: Ken <ken.aleksander@gmail.com>
2026-02-02 10:27:14 +01:00
Halvor Haugan 97b6342a91 Better types in find-unequal-documents.ts, update-props.tsx and docgen.ts (#4590) 2026-02-02 09:02:40 +01:00
Ken c9d6b3155b 🎉 Basic DataTable styling. Moved CSS-import to storybook 2026-01-30 22:44:59 +01:00
Halvor Haugan bad7ef7da7 [website] Disable sandbox on examples using useTheme (#4592) 2026-01-30 19:46:23 +01:00
Ken b6cb159efd [Website] 🐛 Avoid updating EVERY props/example document when deploying (#4581)
* 🐛 Avoid updating EVERY props/example document when deploying

* 🎉 Fix deep comparison and serialization

* Apply suggestion from @KenAJoh
2026-01-30 15:59:15 +01:00
Ken d9a06b244f 🎉 Added references tab (#4588) 2026-01-30 14:39:56 +01:00
Halvor Haugan 51dd32cd85 [website] Add support for anchor in internalLink (#4586) 2026-01-30 13:50:02 +01:00
Ken 80e12039b6 Merge branch 'main' of https://github.com/navikt/aksel 2026-01-30 13:11:48 +01:00
Ken df555e18fb 🐛 Explicitly limit replicas to max 2 2026-01-30 13:11:40 +01:00
Ken 9900b218ce [Website] Use static encryption key for server-actions (#4583)
* ⚡ use static encryption for static server-actions

* 🐛 Avoid adding encryption key to included .env
2026-01-30 13:06:34 +01:00
Petter Walbø Johnsgård 6c95bc7c5e Update JSDoc examples to use spacing tokens (#4585)
Replace deprecated numeric spacing values with space token format in documentation comments.
2026-01-30 12:30:15 +01:00
Ken 54f7a2063e [website]: Experiment with static 2 replicas, disabled autoscaling 2026-01-29 20:31:04 +01:00
Halvor Haugan 739b806810 Fix type error in Data.stories.tsx 2026-01-29 15:41:51 +01:00
Halvor Haugan 833f90377b DataToolbar: Add sub-comp. Button, and other adjustments 2026-01-29 15:18:59 +01:00
Halvor Haugan 8565961882 Search: Extract types for native props into separate type 2026-01-29 15:16:41 +01:00
Halvor Haugan 7b902b253c ActionMenu: Fix indentation in JSDoc examples 2026-01-29 13:58:49 +01:00
KenandHalvor Haugan 6c5f32a0df ⚡ Resolve website revalidating every query (#4578)
* ⚡ Resolve whole website revalidating every fetch

* Update aksel.nav.no/website/app/_sanity/live.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/app/_sanity/live.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-01-29 13:55:46 +01:00
Halvor Haugan 90871fef4b Refactor exports and JSDoc prop type links in components with sub-components (#4575) 2026-01-29 13:02:37 +01:00
github-actions[bot] 324e6f2b4b Version Packages (#4568)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-01-29 12:46:03 +01:00
Halvor Haugan f7a65471fd DataToolbar: Rename DataToggleButton.tsx -> DataToolbarToggleButton.tsx 2026-01-29 12:17:46 +01:00
Ken 9880d3a2cf 🧪 Added webook to log revalidating tags causing performance issue on website 2026-01-28 22:00:07 +01:00
Ken 002fdab355 [DataTable] Added column visibility story 2026-01-28 15:12:28 +01:00
Anniken Granberg b758987ad6 Dummy data and filtering 2026-01-28 14:56:30 +01:00
Halvor Haugan d8aa9ab581 DataActionBar 2026-01-28 13:11:37 +01:00
Ken 8bb5eb78d4 [DataTable] Update project-structure, added toggle-button, css 2026-01-28 10:39:30 +01:00
Ken e97b427dd3 ♻️ Refactor DataTable and related components to under 'data'-dir 2026-01-28 09:49:23 +01:00
Halvor Haugan 3a6832e009 [website] Example error page (#4571) 2026-01-28 09:36:26 +01:00
Ken 1d5401ad2a [Website] Test custom cache-handler (#4567)
* 🧪 Use 24-alpine

* 🧪 Test auto-instrumentation

* 🎉 Fix produktbloggen cache

* 🎉 Test cache-handler in memory

* 🎉 Test custom cache handler with ttl

* 📝 Add cache handler and observability
2026-01-28 09:23:56 +01:00
Ken 3070d28af6 [Website] 🎉 Auto-link to relevant changelogs (#4572)
* 🎉 Auto-link to relevant changelogs

* Apply suggestions from code review
2026-01-28 09:21:57 +01:00
Halvor Haugan 96a5d81248 [website] Non-sticky header on small screens (#4560) 2026-01-27 16:43:11 +01:00
Ken b3251bdbdf 🧪 Test less agressive live refresh of content (#4570) 2026-01-27 16:37:14 +01:00
Ken 8bd6b7e77d Merge branch 'main' of https://github.com/navikt/aksel 2026-01-27 16:35:06 +01:00
Ken f0d1b1f25a 🐛 Clean directories bottom up to avoid trying to delete already deleted directory 2026-01-27 16:34:50 +01:00
dependabot[bot]andKen 9676fbdcd8 ⬆️ Bump jscodeshift from 0.15.2 to 17.3.0 (#4552)
* ⬆️ Bump jscodeshift from 0.15.2 to 17.3.0

Bumps [jscodeshift](https://github.com/facebook/jscodeshift) from 0.15.2 to 17.3.0.
- [Release notes](https://github.com/facebook/jscodeshift/releases)
- [Changelog](https://github.com/facebook/jscodeshift/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jscodeshift/compare/v0.15.2...v17.3.0)

---
updated-dependencies:
- dependency-name: jscodeshift
  dependency-version: 17.3.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* ⬆️ Update jscodeshift

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2026-01-27 16:29:48 +01:00
dependabot[bot]andKen c207c954e1 ⬆️ Bump rimraf from 6.0.1 to 6.1.2 (#4564)
* ⬆️ Bump rimraf from 6.0.1 to 6.1.2

Bumps [rimraf](https://github.com/isaacs/rimraf) from 6.0.1 to 6.1.2.
- [Changelog](https://github.com/isaacs/rimraf/blob/main/CHANGELOG.md)
- [Commits](https://github.com/isaacs/rimraf/compare/v6.0.1...v6.1.2)

---
updated-dependencies:
- dependency-name: rimraf
  dependency-version: 6.1.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* ⬆️ Sync rimraf update

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2026-01-27 16:26:06 +01:00
dependabot[bot] 5239686aec ⬆️ Bump prettier from 3.6.2 to 3.8.1 (#4565)
Bumps [prettier](https://github.com/prettier/prettier) from 3.6.2 to 3.8.1.
- [Release notes](https://github.com/prettier/prettier/releases)
- [Changelog](https://github.com/prettier/prettier/blob/main/CHANGELOG.md)
- [Commits](https://github.com/prettier/prettier/compare/3.6.2...3.8.1)

---
updated-dependencies:
- dependency-name: prettier
  dependency-version: 3.8.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-27 16:24:30 +01:00
dependabot[bot] 1d05b69c98 ⬆️ Bump stylelint-test-rule-node from 0.4.0 to 1.0.0 (#4566)
Bumps [stylelint-test-rule-node](https://github.com/stylelint/stylelint-test-rule-node) from 0.4.0 to 1.0.0.
- [Release notes](https://github.com/stylelint/stylelint-test-rule-node/releases)
- [Changelog](https://github.com/stylelint/stylelint-test-rule-node/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint-test-rule-node/compare/0.4.0...1.0.0)

---
updated-dependencies:
- dependency-name: stylelint-test-rule-node
  dependency-version: 1.0.0
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-27 16:17:25 +01:00
Halvor Haugan 967c9092d2 [website] Adjust how example iframe height is calculated (#4569) 2026-01-27 15:37:53 +01:00
Anniken Granberg 6b9b2b4ebf [InternalHeader] Change examples to use ActionMenu (#4550)
* examples

* get global theme for website examples on actionmenu
2026-01-27 15:32:38 +01:00
Halvor Haugan 08e532b153 [website] Migrate BoxNew to Box (#4555) 2026-01-27 15:02:08 +01:00
Halvor Haugan b800248715 [website] Adjust theme-switch template and ProgressBar example (#4561) 2026-01-27 14:54:21 +01:00
Anniken Granberg 4da0f54173 [ActionMenu] Add support for right aligned icons on ActionMenu items (#4545)
* Add functionality for right placed icon

* add aksel website example

* remomve left padding for right icon

* add support for right icon on sub menu item

* changeset

* remove @property

* remove examples

* remove example

* remove example

* remove class and use data attr

* only add data attr if icon

* add story for icon position

* seperate the examples
2026-01-27 14:51:15 +01:00
Ken ff7a792049 📌 Dependabot adjustments (#4557) 2026-01-27 14:09:24 +01:00
Halvor Haugan 3976b2c710 Delete Darkside-migration.md 2026-01-26 16:44:48 +01:00
Ken 341aab24a2 [DataTable] Boilerplate setup (#4558)
* 🎉 Initial boilerplate

* 🎉 Boilerplate for all sub-components

* 🎉 Set up tooltip boilerplate

* 🎉 TableToolbar stories

* 🎉 TableFilter boilerplate

* 📝 Readme
2026-01-26 15:42:14 +01:00
Halvor Haugan 82c5bec4d7 Add npmMinimalAgeGate and defaultSemverRangePrefix to .yarnrc.yml (#4556) 2026-01-26 11:48:34 +01:00
dependabot[bot]andKen 0157be15ee ⬆️ Bump vitest from 3.2.4 to 4.0.16 in the vitest group (#4551)
* ⬆️ Bump vitest from 3.2.4 to 4.0.16 in the vitest group

Bumps the vitest group with 1 update: [vitest](https://github.com/vitest-dev/vitest/tree/HEAD/packages/vitest).


Updates `vitest` from 3.2.4 to 4.0.16
- [Release notes](https://github.com/vitest-dev/vitest/releases)
- [Commits](https://github.com/vitest-dev/vitest/commits/v4.0.16/packages/vitest)

---
updated-dependencies:
- dependency-name: vitest
  dependency-version: 4.0.16
  dependency-type: direct:development
  update-type: version-update:semver-major
  dependency-group: vitest
...

Signed-off-by: dependabot[bot] <support@github.com>

* ⬆️ Update vitest

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2026-01-26 10:42:01 +01:00
dependabot[bot]andKen b1dba62690 ⬆️ Bump fast-glob from 3.2.11 to 3.3.3 (#4553)
* ⬆️ Bump fast-glob from 3.2.11 to 3.3.3

Bumps [fast-glob](https://github.com/mrmlnc/fast-glob) from 3.2.11 to 3.3.3.
- [Release notes](https://github.com/mrmlnc/fast-glob/releases)
- [Commits](https://github.com/mrmlnc/fast-glob/compare/3.2.11...3.3.3)

---
updated-dependencies:
- dependency-name: fast-glob
  dependency-version: 3.3.3
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* ⬆️ Sync fast-glob

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2026-01-26 09:07:57 +01:00
dependabot[bot] 09b58c8245 ⬆️ Bump chromatic from 13.3.3 to 13.3.5 (#4554)
Bumps [chromatic](https://github.com/chromaui/chromatic-cli) from 13.3.3 to 13.3.5.
- [Release notes](https://github.com/chromaui/chromatic-cli/releases)
- [Changelog](https://github.com/chromaui/chromatic-cli/blob/main/CHANGELOG.md)
- [Commits](https://github.com/chromaui/chromatic-cli/compare/v13.3.3...v13.3.5)

---
updated-dependencies:
- dependency-name: chromatic
  dependency-version: 13.3.5
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-26 09:03:28 +01:00
Ken 6062678926 [Sanity] 🎉 Added sanity dashboard support (#4541)
* 🎉 Added sanity dashboard support

* Update deploy command
2026-01-23 17:24:00 +01:00
Ken 9de76e73d5 ⚡ Sort articles by published date, fix Formstate error 2026-01-23 17:13:45 +01:00
Ken e9c78c642d 🐛 Correct link-styling for show-all god-praksis links 2026-01-23 17:07:34 +01:00
Ken 982c4aa719 💄 Updates to frontpage beta-tag and highlights 2026-01-22 22:56:01 +01:00
Ken 3f7bdf20bc [Website] 🔥 Removed tailwind (#4548)
* 🔥 removed tailwind dependency

* yarn.lock update

* 🐛 Add pointer to buttons
2026-01-22 21:20:48 +01:00
github-actions[bot] 1c3194b1ba Version Packages (#4519)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-01-22 15:46:23 +01:00
dependabot[bot]andKen f787e4e9c5 ⬆️ Bump the npm_and_yarn group across 4 directories with 1 update (#4543)
* ⬆️ Bump the npm_and_yarn group across 4 directories with 1 update

Bumps the npm_and_yarn group with 1 update in the /@navikt/aksel directory: [lodash](https://github.com/lodash/lodash).
Bumps the npm_and_yarn group with 1 update in the /@navikt/aksel-icons directory: [lodash](https://github.com/lodash/lodash).
Bumps the npm_and_yarn group with 1 update in the /@navikt/core/tokens directory: [lodash](https://github.com/lodash/lodash).
Bumps the npm_and_yarn group with 1 update in the /aksel.nav.no/website directory: [lodash](https://github.com/lodash/lodash).


Updates `lodash` from 4.17.21 to 4.17.23
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](https://github.com/lodash/lodash/compare/4.17.21...4.17.23)

Updates `lodash` from 4.17.21 to 4.17.23
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](https://github.com/lodash/lodash/compare/4.17.21...4.17.23)

Updates `lodash` from 4.17.21 to 4.17.23
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](https://github.com/lodash/lodash/compare/4.17.21...4.17.23)

Updates `lodash` from 4.17.21 to 4.17.23
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](https://github.com/lodash/lodash/compare/4.17.21...4.17.23)

---
updated-dependencies:
- dependency-name: lodash
  dependency-version: 4.17.23
  dependency-type: direct:production
  dependency-group: npm_and_yarn
- dependency-name: lodash
  dependency-version: 4.17.23
  dependency-type: direct:development
  dependency-group: npm_and_yarn
- dependency-name: lodash
  dependency-version: 4.17.23
  dependency-type: direct:development
  dependency-group: npm_and_yarn
- dependency-name: lodash
  dependency-version: 4.17.23
  dependency-type: direct:production
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>

* yarn.lock update

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2026-01-22 13:24:35 +01:00
Ken 1a76b7e88f 📝 Require node 22 for CLI caused by use of ESM in CJS file (#4546) 2026-01-22 13:24:13 +01:00
KenandHalvor Haugan 745863f53d [Next/Sanity] Next 16 and Sanity v5 upgrade (#4437)
* ⬆️ Upgrade nextjs

* 📝 rename proxy

* 🐛 Fix eslint config

* 📝 Fix next-config

* 🐛 Fix next link import

* 🏷️ Resolve type-errors

* ⚡ Use Activity

* ⬅️ Revert mobilemenu optimization

* ⬆️ Update image util

* ⬆️ Upgrade sanityjs

* 🏷️ Type updates

* 🏷️ Update type packages

* ⬆️ Update sanity

* ⬆️ Update next

* ⬆️ Use React 19 for repo

* ⬆️ Use React 19

* undo react version changes in icon-package

* 🐛 Fix link rendering

* 🐛 Fix cssProperties types

* Update aksel.nav.no/website/app/(routes)/(designsystemet)/grunnleggende/endringslogg/_ui/ShowMoreButton.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ⬆️ Update yarn

* ⬆️ Update yarn

* yarn.lock update

* yarn.lock update

* 🐛 Sync react types version

* 🐛 Removed unused React import after setting jsx to react-jsx

* 🏷️ Resolve type-issue

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-01-22 13:13:56 +01:00
Ken cb7ac11a6a 🐛 Ingore location based search (#4542) 2026-01-22 12:44:33 +01:00
Halvor Haugan f5c739065c [Sanity] Allow anchor links and URLs without domain (#4547) 2026-01-22 12:34:52 +01:00
dependabot[bot] 0475a81b67 ⬆️ Bump lodash-es from 4.17.21 to 4.17.23 (#4544)
Bumps [lodash-es](https://github.com/lodash/lodash) from 4.17.21 to 4.17.23.
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](https://github.com/lodash/lodash/compare/4.17.21...4.17.23)

---
updated-dependencies:
- dependency-name: lodash-es
  dependency-version: 4.17.23
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-22 10:27:15 +01:00
Anniken Granberg ae8961b23e [GlobalAlert] Add centered as examples (#4536) 2026-01-21 15:06:02 +01:00
Halvor Haugan b4d56bc38a Upgrade stylelint-config-standard (#4540) 2026-01-21 12:50:28 +01:00
dependabot[bot] a1e14b4592 ⬆️ Bump vite-plugin-singlefile from 2.2.0 to 2.3.0 (#4538)
Bumps [vite-plugin-singlefile](https://github.com/richardtallent/vite-plugin-singlefile) from 2.2.0 to 2.3.0.
- [Release notes](https://github.com/richardtallent/vite-plugin-singlefile/releases)
- [Changelog](https://github.com/richardtallent/vite-plugin-singlefile/blob/main/CHANGELOG.md)
- [Commits](https://github.com/richardtallent/vite-plugin-singlefile/commits/v2.3.0)

---
updated-dependencies:
- dependency-name: vite-plugin-singlefile
  dependency-version: 2.3.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-21 12:47:51 +01:00
Halvor Haugan 163b4fd418 Accordion: Warn when only one item, or multiple instances after each other (#4525) 2026-01-21 12:32:44 +01:00
Anniken Granberg 15bc539a13 [ActionMenu] Allow focus for non-actionable content (#4522)
* testing action menu header

* revert to old example

* let focus on container

* added example for actionMenu

* remove testing stuff

* changeset

* remove comments

* changeset
2026-01-21 12:18:26 +01:00
Halvor Haugan 790d0efea5 Upgrade Yarn (#4534) 2026-01-21 12:18:03 +01:00
Halvor Haugan 32a2bcb8cb Dependabot: Add group for vitest (#4535) 2026-01-21 12:17:50 +01:00
dependabot[bot] 1684373897 ⬆️ Bump axios from 1.9.0 to 1.13.2 (#4529)
Bumps [axios](https://github.com/axios/axios) from 1.9.0 to 1.13.2.
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](https://github.com/axios/axios/compare/v1.9.0...v1.13.2)

---
updated-dependencies:
- dependency-name: axios
  dependency-version: 1.13.2
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-21 12:05:18 +01:00
dependabot[bot] ac1078989b ⬆️ Bump valibot from 1.1.0 to 1.2.0 (#4531)
Bumps [valibot](https://github.com/open-circle/valibot) from 1.1.0 to 1.2.0.
- [Release notes](https://github.com/open-circle/valibot/releases)
- [Commits](https://github.com/open-circle/valibot/compare/v1.1.0...v1.2.0)

---
updated-dependencies:
- dependency-name: valibot
  dependency-version: 1.2.0
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-21 12:00:57 +01:00
dependabot[bot] e1bcc77617 ⬆️ Bump mdast-util-to-hast from 13.2.0 to 13.2.1 (#4532)
Bumps [mdast-util-to-hast](https://github.com/syntax-tree/mdast-util-to-hast) from 13.2.0 to 13.2.1.
- [Release notes](https://github.com/syntax-tree/mdast-util-to-hast/releases)
- [Commits](https://github.com/syntax-tree/mdast-util-to-hast/compare/13.2.0...13.2.1)

---
updated-dependencies:
- dependency-name: mdast-util-to-hast
  dependency-version: 13.2.1
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-21 11:59:20 +01:00
dependabot[bot] 0a5029b610 ⬆️ Bump node-forge from 1.3.1 to 1.3.3 (#4530)
Bumps [node-forge](https://github.com/digitalbazaar/forge) from 1.3.1 to 1.3.3.
- [Changelog](https://github.com/digitalbazaar/forge/blob/main/CHANGELOG.md)
- [Commits](https://github.com/digitalbazaar/forge/compare/v1.3.1...v1.3.3)

---
updated-dependencies:
- dependency-name: node-forge
  dependency-version: 1.3.3
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-21 11:58:00 +01:00
dependabot[bot] 523868f414 ⬆️ Bump min-document from 2.19.0 to 2.19.2 (#4528)
Bumps [min-document](https://github.com/Raynos/min-document) from 2.19.0 to 2.19.2.
- [Commits](https://github.com/Raynos/min-document/compare/v2.19.0...v2.19.2)

---
updated-dependencies:
- dependency-name: min-document
  dependency-version: 2.19.2
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-21 11:57:23 +01:00
dependabot[bot] be2d7119b1 ⬆️ Bump the npm_and_yarn group across 3 directories with 1 update (#4527)
Bumps the npm_and_yarn group with 1 update in the /examples/astro directory: [tar](https://github.com/isaacs/node-tar).
Bumps the npm_and_yarn group with 1 update in the /examples/referansesider directory: [tar](https://github.com/isaacs/node-tar).
Bumps the npm_and_yarn group with 1 update in the /examples/shadow-dom directory: [tar](https://github.com/isaacs/node-tar).


Updates `tar` from 7.5.2 to 7.5.6
- [Release notes](https://github.com/isaacs/node-tar/releases)
- [Changelog](https://github.com/isaacs/node-tar/blob/main/CHANGELOG.md)
- [Commits](https://github.com/isaacs/node-tar/compare/v7.5.2...v7.5.6)

Updates `tar` from 7.5.3 to 7.5.6
- [Release notes](https://github.com/isaacs/node-tar/releases)
- [Changelog](https://github.com/isaacs/node-tar/blob/main/CHANGELOG.md)
- [Commits](https://github.com/isaacs/node-tar/compare/v7.5.2...v7.5.6)

Updates `tar` from 7.5.3 to 7.5.6
- [Release notes](https://github.com/isaacs/node-tar/releases)
- [Changelog](https://github.com/isaacs/node-tar/blob/main/CHANGELOG.md)
- [Commits](https://github.com/isaacs/node-tar/compare/v7.5.2...v7.5.6)

---
updated-dependencies:
- dependency-name: tar
  dependency-version: 7.5.6
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: tar
  dependency-version: 7.5.6
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: tar
  dependency-version: 7.5.6
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-21 11:56:40 +01:00
465bfb16b1 Upgrade to React 19 (#4123)
* Upgrade to React 19

* fix refs

* Lock versions

* 🐛 Port over showmorebutton typing-fix

* fix Avatar

* Fix type issue in EditorPanel.tsx

* Update browserslist

* Fix type error in CustomPortableText.components.tsx

* temp debugging

* debugging 2

* debug 3

* debug 4 next link

* Debug 5 refactor

* debug 6 vanlig lenke

* debug 7 hard coded text

* debug 8 wo LinkCardAnchor

* slot error

* just console error

* log children

* revert debugging

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2026-01-21 11:35:33 +01:00
Halvor Haugan 4bc5450809 Adjust changesets 2026-01-21 09:55:28 +01:00
Ken 776bd81f19 🐛 Discrete events did not handle react-19 well with event-batching (#4524) 2026-01-21 09:49:56 +01:00
dependabot[bot] ded4e4712e ⬆️ Bump the npm_and_yarn group across 2 directories with 1 update (#4509)
Bumps the npm_and_yarn group with 1 update in the /examples/referansesider directory: [tar](https://github.com/isaacs/node-tar).
Bumps the npm_and_yarn group with 1 update in the /examples/shadow-dom directory: [tar](https://github.com/isaacs/node-tar).


Updates `tar` from 7.4.3 to 7.5.3
- [Release notes](https://github.com/isaacs/node-tar/releases)
- [Changelog](https://github.com/isaacs/node-tar/blob/main/CHANGELOG.md)
- [Commits](https://github.com/isaacs/node-tar/compare/v7.4.3...v7.5.3)

Updates `tar` from 7.4.3 to 7.5.3
- [Release notes](https://github.com/isaacs/node-tar/releases)
- [Changelog](https://github.com/isaacs/node-tar/blob/main/CHANGELOG.md)
- [Commits](https://github.com/isaacs/node-tar/compare/v7.4.3...v7.5.3)

---
updated-dependencies:
- dependency-name: tar
  dependency-version: 7.5.3
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: tar
  dependency-version: 7.5.3
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-20 19:42:25 +01:00
Halvor Haugan d4f27e144c Slot: Fix RSC related issue (#4523) 2026-01-20 16:23:50 +01:00
Ken b12f2c8ffa [Vitest] ⬆️ Update package versions (#4520)
* ⬆️ Update vitest

* 🐛 Fix ui-tests runner with playwright-browser
2026-01-20 15:43:49 +01:00
Halvor Haugan b504aed88e Adjust desc in FormSummary grouped example 2026-01-20 11:39:55 +01:00
Ken 8ac99ca0a8 🐛 Fix import-errors after merge 2026-01-20 10:02:06 +01:00
Ken 9546d61ecf 📝 Update remaining stories to work with React 19 (#4518)
* 📝 Update remaining stories to work with React 19

* 🐛 Re-add chromatic to combobox

* 🐛 Fix formprogress story
2026-01-20 09:53:54 +01:00
KenandHalvor Haugan 7a524986d3 🚚 Updated utility structure (#4505)
* 🔥 Remove RenameCSS

* more cleanup

* 📝 Test path aliasing

* 🔥 Removed duplicate import

* 🚚 Moved external utils

* 📝 Update tests

* 🚚 Update utility structure

* Apply suggestion from @KenAJoh

* 🐛 Undo import removal

* 🚚 Inlined tests

* [Utility structure] Updated imports (#4516)

* 🏷️ Checkpint import update

* 🏷️ Checkpoint import update 2

* 🏷️ Checkpoint import update 3

* 🏷️ Resolve outside direct imports

* 🐛 Resolve no-cycle lint error

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2026-01-20 09:41:45 +01:00
Ken 98e971fb61 ⚡ Add lint-error when importing from cjs/esm dirs 2026-01-19 16:18:58 +01:00
github-actions[bot] 7383d66aeb Version Packages (#4497)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-01-19 15:03:59 +01:00
Halvor Haugan 03e8c2e847 Fix React 19 type errors in useMergeRefs and Modal.context (#4515) 2026-01-19 13:14:26 +01:00
Ken 9421b3da4e 🐛 AccordionContent-text had blue tint inherited from app color. (#4514) 2026-01-19 12:55:55 +01:00
Ken 30933e2233 🐛 Update endringslogg link 2026-01-19 11:30:12 +01:00
Halvor Haugan 269f79df23 DatePicker: Add prop fixedWeeks to DatePickerProps (#4507) 2026-01-16 12:38:04 +01:00
Halvor Haugan c1d634e95e [website] Remove clsx dependency (#4506) 2026-01-16 12:37:13 +01:00
Ken 88ab5b2ba0 [Stylelint] 🐛 Let stylelint resolve tokens from any CWD (#4504)
* 🐛 Let stylelint resolve tokens from any cwd

* 🔥 Removed added rule

* 🐛 Resolve lint errors
2026-01-16 12:23:40 +01:00
Ken 4ce76f654d 🐛 Fix sanity-data that returns null-values (#4508) 2026-01-16 12:22:16 +01:00
Halvor Haugan 39d56148d1 🔥 Remove RenameCSS (#4500) 2026-01-16 10:48:32 +01:00
Halvor Haugan fd73b70922 Upgrade packages in examples/astro 2026-01-16 09:32:01 +01:00
Halvor Haugan 48edb1e8aa Fix some React 19 type errors in stories (#4502) 2026-01-16 09:18:05 +01:00
dependabot[bot] c5763ea105 ⬆️ Bump devalue (#4501)
Bumps the npm_and_yarn group with 1 update in the /examples/astro directory: [devalue](https://github.com/sveltejs/devalue).


Updates `devalue` from 5.5.0 to 5.6.2
- [Release notes](https://github.com/sveltejs/devalue/releases)
- [Changelog](https://github.com/sveltejs/devalue/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sveltejs/devalue/compare/v5.5.0...v5.6.2)

---
updated-dependencies:
- dependency-name: devalue
  dependency-version: 5.6.2
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-15 19:56:47 +01:00
dependabot[bot] f072a32b12 ⬆️ Bump diff (#4492)
Bumps the npm_and_yarn group with 1 update in the /examples/referansesider directory: [diff](https://github.com/kpdecker/jsdiff).


Updates `diff` from 8.0.2 to 8.0.3
- [Changelog](https://github.com/kpdecker/jsdiff/blob/master/release-notes.md)
- [Commits](https://github.com/kpdecker/jsdiff/compare/v8.0.2...v8.0.3)

---
updated-dependencies:
- dependency-name: diff
  dependency-version: 8.0.3
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-15 19:29:54 +01:00
Ken 737f9e47f9 🐛 Fix link-color in FileUpload after css-layer update 2026-01-15 16:20:38 +01:00
Ken e11dc404db 🐛 Fix css var use on website 2026-01-15 14:46:23 +01:00
github-actions[bot] 18093afc94 Version Packages (#4494)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-01-15 14:31:11 +01:00
b88b8ba781 Fix upload pr (#4496)
* New component for buttons and loader within Item

* New component from file name with icon

* Removed loader and error icon for file icon

* Use new components for new design

* Css styling for new design to Item

* Delete unused filed, replaced by ItemHeader

* changeset

* try to fix cycle dependency

* Fill width

* Remove min width and height

* 🔥 Removed changeset

---------

Co-authored-by: Anniken Granberg <anniken.granberg@na.no>
Co-authored-by: Anniken Granberg <43889032+nixenixe@users.noreply.github.com>
2026-01-15 14:22:45 +01:00
5572548bb5 Version 8 major release (#4283)
* Always use aksel-prefix for classNames

* 🔥 Removed body override from Modal

* 🔥 Removed legacy classNames in GuidePanel

* 🔥 Removed legacy classNames in Stepper

* 🔥 Removed Arrow from popover

* 🔥 Removed deprecated prop from Accordion

* 🚚 Migrate Tag variant

* 🚚 Update all use of Tag

* 🚚 Migrate Chips variant

* ⬅️ Undo Accordion variant removal, fall back to data-color

* 🚚 Migrate Chips variant

* 🚚 Migrate CopyButton variant

* 🚚 Removed deprecated List props

* 🚚 More isDarkside cleanup

* 🚚 Togglegroup variant update

* ⚡ Remove darkside decorator in storybook

* 📝 Migration doc

* 🚚 Migrate Link

* 🔥 Removed variant subtle link from website

* 🚚 Migrate Pimitives check for darkside

* 🚚 Use new implementation as default for Radio and Checkbox

* 🚚 Finished removing isDarkside check

* 🚚 Migrated BoxNew -> Box

* 📝 TODOs

* 🚚 Migrated use of Box in stories

* 🔥 removed temp file

* 🚚 Migrate away from legacy-tokens

* 🚚 Migrate to new token-import

* ⚰️ Clean up depreactions-file in stylelint. We start anew again

* 🚚 Move data-color for variant from wrapper -> header Accordion

* 📝 Changes based on PR-review

* 🎉 Add link codemod

* 📝 Docs

* Update @navikt/core/react/src/chips/chips.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Docs

* Update @navikt/core/react/src/accordion/Accordion.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/layout/box/Box.darkside.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/tokens/tsconfig.json

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* [Darkside] Button changes for darkside update (#4322)

* 🎉 Update button variant and colors

* 📝 Update examples

* 📝 Button codemod

* 📝 Add back size story

* Update aksel.nav.no/website/pages/eksempler/button/neutral.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🔥 Darkside tailwindcss config -> main config (#4328)

* [Darkside] CSS-package update (#4330)

* ⚰️ Delete legacy CSS

* 🎉 Migrate away from legacy-css

* 🧪 rename test script

* 🚚 rename darkside css files

* 🔥 removed some legacy use of old css/tokens

* 🐛 Fix css imports

* 🎉 Optimize layer-handling

* 🎉 CSS is not import order agnostic

* ⬆️ yarn lock sync

* 🎉 Legacy-tokens reference new tokens (#4345)

* [Darkside] Fix type errors (#4354)

* [Darkside] Migrate examples (#4364)

* [Darkside] Migrate templates (#4358)

* 🔥 Removed cssnano from next-build

* 🐛 Only warn if using title in List to avoid type-errors

* ⬅️ Revert listtype change

* 📝 Update stylelint TODOs

* [Darkside] Migrate stylelint rules (#4388)

* [Darkside] Change remaining `--__ac-` prefixed CSS-variables to `--__axc-` (#4389)

* ⚰️ Deprecated variant prop in Chat

* Remove test script in ds-css

* [Darkside] Remove references to old tokens in components/stories (#4390)

* [Darkside] Added "data-color" prop to components (#4387)

* 🏷️ Add data-color type

* 🏷️ Add more data-color type

* Update @navikt/core/react/src/pagination/Pagination.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/alert/local-alert/root/LocalAlertRoot.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Better docs

* 📝 Doc-updates

* typo

* 🏷️ Resolve type-error

* Update @navikt/core/react/src/copybutton/CopyButton.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/loader/Loader.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/timeline/period/index.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>

* Rename Button-example "demo" to "accent" and add desc

* [Darkside] Remove legacy option from theme switch (#4405)

* 🎉 Allow more data-color options on Button

* 🎉 Added contrast to typo textColor-prop

* [Darkside] Examples update. Progress: Start -> Bodylong (#4421)

* 📝 Button variant update

* 📝 InternalHeader theme + actionMenu

* ⚰️ Delete Alert with buttons example

* Update aksel.nav.no/website/pages/eksempler/actionmenu/header.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🚚 Moved token-view replacing old tokens

* 🔥 Cleanup of legacy-tokens

* [Darkside] Theme provider adjustments (#4422)

* 🐛 Handle Loader-css layering bug, add background to website trough Theme-component.

* 📝 Show release as live docs

* 🎉 Updated playroom (#4436)

* 🎉 Updated playroom

* 📝 Update imports

* 📝 Ignore auto-generated file

* 🐛 Fix gitignore

* 🐛 Fix gitignore

* 🐛 Use typescript

* 🐛 Use min height to allow background to flow correctly

* ⬅️ Revert temp changes with no effect

* [Darkside] Update references to darkside in storybook and code (#4451)

* 📝 Remove more references to darkside.

* Update @navikt/core/tailwind/src/build.test.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* [Darkside] Update references to darkside in docs and code (#4449)

* 📝 Rename all references to darkside -> v8

* 📝 Update darkside references

* 🚚 Moved v8-tokens dir into codemod dir

* 🐛 resolve import issue

* ✨ Added ability to run CLI-tool without npx

* Update ColorRole-stories on typo-components

* [Darkside] Remove some unused classNames (#4454)

* [Darkside] Update links to token-docs (#4462)

* [Darkside] Fix chat and timeline examples (#4467)

* [Darkside] Removed legacy spacing and border-radius tokens (#4458)

* 🔥 Removed legacy spacing and border-radius tokens

* 📝 Migrate some space and radius token use

* 🎉 Update tokens

* 📝 Updated stories

* use propValue directly instead of reassigning it first

* 📝 Updated primitives spacing in stories

* 📝 Update remaining use of legacy spacing and borderRadius on stories

* 🔥 Removed 0 spacing

* 📝 Update use of hgrid

* 🐛 Undo change of bin-command

* 🔥 Removed px and 0 from bleed spacing

* 🐛 Revert tokenException removal

* Update @navikt/core/react/src/layout/utilities/css.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 Removed string | object notation from AkselColor type.

* [Darkside] Examples update darkside Start -> Modal (#4469)

* 📝 Body coloring

* 📝 More example updates for darkside colors

* 📝 Update primitive examples

* 🐛 Undo bin revert

* Change background on h-stack wrap example

* Update aksel.nav.no/website/pages/eksempler/heading/colors.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 💄 Better contrast for examples

* Update aksel.nav.no/website/pages/eksempler/chat/colors.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Adjust stories for icons, Bleed, Box and Stack (#4472)

* 🐛 Use correct colors

* [Darkside] 📝 Remaining example-updates (#4477)

* 📝 More updated examples

* 📝 Example id

* [Darkside] JSDoc adjustments for data-color on some components (#4485)

* [Darkside] TODO cleanup (#4481)

* 🏷️ Add dynamic theming to Box

* 🔥 Removed old comment

* 💄 Sync Modal backdrop-colors

* 🔥 Removed old comments for tokens

* Update @navikt/core/react/src/layout/box/Box.darkside.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/layout/box/Box.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* [Darkside] Handle theming better in FormSummary, Guidepanel. Fix forced-colors in Button (#4479)

* 💄 Primary-button forced colors

* 💄 Handle theming better in formsummary

* 📝 Handle nested colors better in GuidePanel

* 📝 Better forced-color handling for buttons

* [Darkside] Removed legacy-tokens, added migration to codemod (#4486)

* 🎉 Added 16px border-radius

* 🐛 Handle redefinition of radius-tokens

* 🐛 Handle space-update in token-migration codemod

* 📝 Print use of ax-tokens

* 🐛 Remove use of legacy border-radius

* 🔥 Removed comment

* Adjust description of v8-list migration

* 📝 Replacements update

* Token migration comments update

* Remove redundant Chromatic story for GlobalAlert

* Token migration comments update 2

* 📝 Updated ignore and tests

* legacy.tokens.ts: had comment in replacement by mistake

* 🐛 Update tests

* 🧪 Add failing test

* 🔥 removed unused code

* 🐛 Handle tailwind-tokens with matching css-var names

* 🔥 Removed perspective stack from sanity

* 📝 Update meta.json change-date for 400 and 500 templates

* 📝 Better v8-tokens migration status-texts

* 🔥 Removed darkside from sidebar config

* 🐛 Handle string inside object-literal

* changeset

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2026-01-15 13:55:41 +01:00
Anniken GranbergandAnniken Granberg 62e9650f38 Change website DatePicker and MonthPicker description examples to use date format in Norwegian (#4493)
* change format description to norwegian

* Update date format descriptions to Norwegian standard

---------

Co-authored-by: Anniken Granberg <anniken.granberg@na.no>
2026-01-15 13:30:45 +01:00
github-actions[bot] 10fedc5aac Version Packages (#4491)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-01-15 13:00:47 +01:00
Halvor Haugan 23a8e717f3 Date/MonthPicker: Remove role=dialog (#4463) 2026-01-15 10:47:32 +01:00
dependabot[bot]andKen 34cc031960 ⬆️ Bump colorjs.io from 0.5.2 to 0.6.0 (#4475)
* ⬆️ Bump colorjs.io from 0.5.2 to 0.6.0

Bumps [colorjs.io](https://github.com/color-js/color.js) from 0.5.2 to 0.6.0.
- [Release notes](https://github.com/color-js/color.js/releases)
- [Commits](https://github.com/color-js/color.js/compare/v0.5.2...v0.6.0)

---
updated-dependencies:
- dependency-name: colorjs.io
  dependency-version: 0.6.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* 🐛 Handle updated coords resolve after update

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2026-01-14 15:50:45 +01:00
Anniken GranbergandAnniken Granberg 2a43bcc6d1 [Icons] Add icons MagnifyGlassCheckmark (#4489)
* add icons

* changeset

---------

Co-authored-by: Anniken Granberg <anniken.granberg@na.no>
2026-01-14 15:32:08 +01:00
github-actions[bot] 19954045ba Version Packages (#4484)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-01-14 15:16:28 +01:00
Ken 7efacb88d1 [Dialog] [Modal] Handle overflow for extreme zoom-ranges (#4488)
* 🐛 Handle extreme zoom in Modal and Dialog better

* 📝 Changeset update
2026-01-14 11:22:00 +01:00
Ken f58df4e1bc 🐛 Test defining Ui test root 2026-01-13 15:45:21 +01:00
Ken 6e84d90e79 🐛 Try running CI-tests on firefox instead of chromium to avoid hangups 2026-01-13 12:22:24 +01:00
Ken 2883032861 [Dialog] Removed 'aria-expanded' from Dialog.Trigger (#4478)
* 📝 Changeset

* 🔥 Removed aria-expanded from dialog-examples
2026-01-13 09:38:00 +01:00
Anniken GranbergandAnniken Granberg b4622094ff added format description for MonthPicker (#4483)
Co-authored-by: Anniken Granberg <anniken.granberg@na.no>
2026-01-12 16:47:49 +01:00
Ken 6c3bff09cf 🐛 Avoid coloring paragraph-content in highlighted changelogs. Toned down highlighted heading. 2026-01-12 16:42:18 +01:00
Anniken GranbergandAnniken Granberg 796dd929c1 add chromatic (#4482)
Co-authored-by: Anniken Granberg <anniken.granberg@na.no>
2026-01-12 16:32:51 +01:00
Anniken GranbergandAnniken Granberg 1710577b70 Added format description to aksel website examples (#4480)
Co-authored-by: Anniken Granberg <anniken.granberg@na.no>
2026-01-12 16:30:57 +01:00
github-actions[bot] 20c6395fa9 Version Packages (#4473)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-01-12 16:14:45 +01:00
Ken 91f3f8acb8 📝 Changeset update 2026-01-12 16:00:03 +01:00
0e1685dd7d Update alert (#4476)
* Added alignContent prop to GlobalAlertRoot

* test

* test

* test

* changeset

* Change to use data-attributes. Change prop name to "centered" and made it boolean.

* Added styling to darkside

* Changed with prop change to boolean

* Change css to use data-attributes

* correct changeset

* Update .changeset/warm-meteors-go.md

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

---------

Co-authored-by: Anniken Granberg <anniken.granberg@na.no>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2026-01-12 13:21:37 +01:00
Ken e938cc0c7a [Dialog] Handle SR-only elements better, add scroll shadows (#4457)
* 🐛 Handle sr-only better for Dialog

* Apply suggestion from @KenAJoh

* 📝 Added scroll-story
2026-01-12 13:10:17 +01:00
Ken 7b487edb03 [Playroom] Resolve issues with preview (#4470)
* 🎉 Script to fix playroom issue

* 🐛 Resolve playroom preview issue

* 🐛 Resolve playroom e2e sandbox test
2026-01-12 12:52:49 +01:00
dependabot[bot] cc1c35d59a ⬆️ Bump the storybook group with 9 updates (#4474)
Bumps the storybook group with 9 updates:

| Package | From | To |
| --- | --- | --- |
| [@storybook/addon-a11y](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/a11y) | `10.1.10` | `10.1.11` |
| [@storybook/addon-docs](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/docs) | `10.1.10` | `10.1.11` |
| [@storybook/addon-themes](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/themes) | `10.1.10` | `10.1.11` |
| [@storybook/addon-vitest](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/vitest) | `10.1.10` | `10.1.11` |
| [@storybook/nextjs-vite](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/nextjs) | `10.1.10` | `10.1.11` |
| [@storybook/react-vite](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/react-vite) | `10.1.10` | `10.1.11` |
| [eslint-plugin-storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/eslint-plugin) | `10.1.10` | `10.1.11` |
| [storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/core) | `10.1.10` | `10.1.11` |
| [storybook-addon-pseudo-states](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/pseudo-states) | `10.1.10` | `10.1.11` |


Updates `@storybook/addon-a11y` from 10.1.10 to 10.1.11
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.1.11/code/addons/a11y)

Updates `@storybook/addon-docs` from 10.1.10 to 10.1.11
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.1.11/code/addons/docs)

Updates `@storybook/addon-themes` from 10.1.10 to 10.1.11
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.1.11/code/addons/themes)

Updates `@storybook/addon-vitest` from 10.1.10 to 10.1.11
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.1.11/code/addons/vitest)

Updates `@storybook/nextjs-vite` from 10.1.10 to 10.1.11
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.1.11/code/frameworks/nextjs)

Updates `@storybook/react-vite` from 10.1.10 to 10.1.11
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.1.11/code/frameworks/react-vite)

Updates `eslint-plugin-storybook` from 10.1.10 to 10.1.11
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.1.11/code/lib/eslint-plugin)

Updates `storybook` from 10.1.10 to 10.1.11
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.1.11/code/core)

Updates `storybook-addon-pseudo-states` from 10.1.10 to 10.1.11
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.1.11/code/addons/pseudo-states)

---
updated-dependencies:
- dependency-name: "@storybook/addon-a11y"
  dependency-version: 10.1.11
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-docs"
  dependency-version: 10.1.11
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-themes"
  dependency-version: 10.1.11
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-vitest"
  dependency-version: 10.1.11
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/nextjs-vite"
  dependency-version: 10.1.11
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react-vite"
  dependency-version: 10.1.11
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: eslint-plugin-storybook
  dependency-version: 10.1.11
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: storybook
  dependency-version: 10.1.11
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: storybook-addon-pseudo-states
  dependency-version: 10.1.11
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-12 09:54:09 +01:00
KenandHalvor Haugan fb384fa3e2 [Darkside] ExpansionCard.Content typography is no longer affected by 'app-color' (#4460)
* 🐛 Stop setting colors on typo-element from affecting nested typo

* 🐛 Inline fix expansioncard content

* Update .changeset/smart-canyons-cut.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 Handle ExpansionCard data-color prop

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-01-12 09:32:06 +01:00
Ken ae95c5c9db ♿ Removed tabIndex 0 from content (#4464)
* ♿ Removed tabIndex 0 from content

* 💄 Removed focus styling from readmore content
2026-01-09 17:06:01 +01:00
Halvor Haugan 2c25ceee09 Adjust some stories (#4471) 2026-01-09 16:48:07 +01:00
dependabot[bot] e0a1add87e ⬆️ Bump react-router from 7.10.0 to 7.12.0 (#4461)
Bumps [react-router](https://github.com/remix-run/react-router/tree/HEAD/packages/react-router) from 7.10.0 to 7.12.0.
- [Release notes](https://github.com/remix-run/react-router/releases)
- [Changelog](https://github.com/remix-run/react-router/blob/main/packages/react-router/CHANGELOG.md)
- [Commits](https://github.com/remix-run/react-router/commits/react-router@7.12.0/packages/react-router)

---
updated-dependencies:
- dependency-name: react-router
  dependency-version: 7.12.0
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-09 16:42:37 +01:00
Halvor Haugan 1b04724211 [website] Adjust some DatePicker examples, and fix some Loader examples not working in SB (#4468) 2026-01-09 15:37:54 +01:00
Halvor Haugan fee738602d Primitives: Fix type issue with className (#4466) 2026-01-09 15:16:13 +01:00
Halvor Haugan 873c1b3f9a Sync package versions (#4459) 2026-01-08 19:19:17 +01:00
github-actions[bot] abed964174 Version Packages (#4443)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-01-08 14:36:20 +01:00
Ken d631eefe59 🐛 Update v8-primitive-spacing codemod 2026-01-08 14:32:55 +01:00
Halvor Haugan 9255fd61b6 [website] Adjust examples of FileUpload (#4456) 2026-01-08 13:51:23 +01:00
Halvor Haugan b2e6f534c6 [docgen] Fix issues with JSDoc example parsing and rendering (#4423) 2026-01-08 13:24:44 +01:00
KenandHalvor Haugan d7285c94ec [Actionmenu] Safezone handling while inside custom-components (#4428)
* 🎉 Handle web-components and outsideclick better

* ✨ Use callback instead of static ref

* 🔥 Removed unreachable code

* Update .changeset/empty-balloons-roll.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 better docs and tests

* 🎉 Now auto-handles anchor and pointer-events

* Update @navikt/core/react/src/overlays/dismissablelayer/DismissableLayer.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Doc updates

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-01-08 13:16:55 +01:00
KenandHalvor Haugan 155b395187 [Dialog] Bugfix: Use inside/outside Modal, Escape-bubbling and z-index (#4455)
* 🐛 Handle Dialog inside Modal, and the opposite better

* 🐛 Handle use inside or outside Modal better, fix escape-bubbling in Modal and z-index for dialog backdrop

* 📝 Changeset

* Update .changeset/early-rockets-attend.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🔥 Removed styles from stories

* Update @navikt/core/react/src/date/Date.Dialog.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/dialog/popup/DialogPopup.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🏷️ Correct prop-naming

* 📝 story-cleanup

* 📝 Comments

* 📝 Two separate changesets

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-01-08 13:16:31 +01:00
Ken 5810913fa7 🐛 Use legacy-token for legacy dialog-css 2026-01-08 13:11:30 +01:00
Ken 6219718eba [Dialog] Now has border in light-mode (#4452)
* 💄 Dialog now has border in light-mode based on figma-adjustments

* 💄 Update legacy-css
2026-01-08 12:40:47 +01:00
Halvor Haugan a3b919fc31 Dialog: Fix typo in JSDoc 2026-01-07 11:59:26 +01:00
b30d92fed3 ⬆️ Bump commander from 10.0.1 to 14.0.2 (#4445)
* ⬆️ Bump commander from 10.0.1 to 14.0.2

Bumps [commander](https://github.com/tj/commander.js) from 10.0.1 to 14.0.2.
- [Release notes](https://github.com/tj/commander.js/releases)
- [Changelog](https://github.com/tj/commander.js/blob/master/CHANGELOG.md)
- [Commits](https://github.com/tj/commander.js/compare/v10.0.1...v14.0.2)

---
updated-dependencies:
- dependency-name: commander
  dependency-version: 14.0.2
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* 🐛 Handle unknown arguments

* 🐛 Allow unknown args

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2026-01-06 12:21:07 +01:00
Ken 5bd333af80 [Util] ⚡ Update mergedRef utility hook (#4434)
* ⚡ Update mergedRef utility

* 🐛 Rever locale update

* 📝 Tests
2026-01-06 12:16:34 +01:00
Ken cc8dc08010 🔥 Remove unused eslint directive 2026-01-05 16:42:23 +01:00
dependabot[bot] e4d29610f7 ⬆️ Bump @figma/rest-api-spec from 0.34.0 to 0.35.0 (#4446)
Bumps [@figma/rest-api-spec](https://github.com/figma/rest-api-spec) from 0.34.0 to 0.35.0.
- [Commits](https://github.com/figma/rest-api-spec/compare/v0.34.0...v0.35.0)

---
updated-dependencies:
- dependency-name: "@figma/rest-api-spec"
  dependency-version: 0.35.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-05 16:41:30 +01:00
Ken 2a9c5775a8 📌 Revert grouping of dependabot updates 2026-01-05 16:22:51 +01:00
Ken 51f61b63b0 ✨ Backport playroom update from darkside PR 2026-01-05 16:16:05 +01:00
KenandHalvor Haugan 43108e80d0 [CLI] Interactive major-version codemod selection (#4427)
* ✨ Version migrations

* 🎉 Interactive version migration

* 📝 Text updates

* 🎉 Dynamic interactive migrations

* 📝 Changeset

* 📝 Comments

* Update @navikt/aksel/src/codemod/index.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/aksel/src/codemod/migrations.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ⚡ More forgiving version migration check.

* 📝 remove linebreaks

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2026-01-05 16:01:52 +01:00
Ken 44e4c7d63e 🐛 defaultExclude when running vitest for website (avoids running tests found in node_modules). 2026-01-05 12:33:36 +01:00
dependabot[bot] 786189a901 ⬆️ Bump the eslint group with 2 updates (#4429)
Bumps the eslint group with 2 updates: [@eslint/js](https://github.com/eslint/eslint/tree/HEAD/packages/js) and [eslint](https://github.com/eslint/eslint).


Updates `@eslint/js` from 9.39.1 to 9.39.2
- [Release notes](https://github.com/eslint/eslint/releases)
- [Commits](https://github.com/eslint/eslint/commits/v9.39.2/packages/js)

Updates `eslint` from 9.39.1 to 9.39.2
- [Release notes](https://github.com/eslint/eslint/releases)
- [Commits](https://github.com/eslint/eslint/compare/v9.39.1...v9.39.2)

---
updated-dependencies:
- dependency-name: "@eslint/js"
  dependency-version: 9.39.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: eslint
- dependency-name: eslint
  dependency-version: 9.39.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: eslint
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-05 12:24:03 +01:00
dependabot[bot] de69d7a4c4 ⬆️ Bump mdast-util-to-hast (#4439)
Bumps the npm_and_yarn group with 1 update in the /examples/astro directory: [mdast-util-to-hast](https://github.com/syntax-tree/mdast-util-to-hast).


Updates `mdast-util-to-hast` from 13.2.0 to 13.2.1
- [Release notes](https://github.com/syntax-tree/mdast-util-to-hast/releases)
- [Commits](https://github.com/syntax-tree/mdast-util-to-hast/compare/13.2.0...13.2.1)

---
updated-dependencies:
- dependency-name: mdast-util-to-hast
  dependency-version: 13.2.1
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-05 12:21:50 +01:00
dependabot[bot] 53aeb88ba1 ⬆️ Bump qs from 6.14.0 to 6.14.1 (#4440)
Bumps [qs](https://github.com/ljharb/qs) from 6.14.0 to 6.14.1.
- [Changelog](https://github.com/ljharb/qs/blob/main/CHANGELOG.md)
- [Commits](https://github.com/ljharb/qs/compare/v6.14.0...v6.14.1)

---
updated-dependencies:
- dependency-name: qs
  dependency-version: 6.14.1
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-05 12:21:29 +01:00
Ken 3d8365a4d3 🐛 Corretly display code block title when avaliable, not just language 2026-01-05 11:44:29 +01:00
Ken 8d1039b813 Website: Static height for all Dialog examples 2026-01-05 10:06:28 +01:00
Ken 53ca1965d6 🐛 Resolve 'docgen' not resolving DialogRoot props. 2026-01-05 09:38:19 +01:00
github-actions[bot] 52a35d0903 Version Packages (#4426)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-01-05 09:25:40 +01:00
Ken 48132544e2 🐛 Avoid flash of christmas-tree 2026-01-04 17:34:47 +01:00
Ken 0c31af0ff4 [Util] Rename createContext -> createStrictContext (#4433)
* 📝 Update createContext -> createStrictContext

* 📝 Changeset

* ♻️ Update create-strict-context call signature
2025-12-23 14:35:39 +01:00
Ken d57b1a86b2 [Util] Utility hook updates (#4432)
* 🔥 remove useCallbackRef

* 📝 Rename useLatestRef

* 📝 Utility function updates

* 🐛 Resolve build-errors

* 📝 Changeset

* ⬅️ Revert mergeRef update

* 🐛 Rever useTab mergeRef
2025-12-23 14:13:51 +01:00
Ken 78870c02ad [Linter] Biome v2 update (#4431)
* 🎉 Upgrade biome to v2

* 🚨 Biome v2 lint update

* 📝 Make sure to filter out biome ignore comments from examples
2025-12-23 14:12:00 +01:00
Ken daa823dd2f 📝 Fix typo 2025-12-22 16:48:35 +01:00
Ken d1e8db180c 🐛 Bump dialog z-index 2025-12-22 14:38:44 +01:00
Ken 942255cb5b 🎉 Better location-resolver for sanity-articles 2025-12-19 16:12:09 +01:00
Ken 020fd7803a 📝 Rename migreringsguider category 2025-12-19 15:31:14 +01:00
452d12826f [Dialog] New component Dialog 🎉 (#4262)
* ✨ Added scrolllock utility

* 🎉 UseScrollLock story

* ♻️ Use scrolllock utility in Modal

* 📝 Changeset

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Update changeset

* 📝 Added className to list of styellint className deprecations

* 🔥 removed double negative negation

* 📝 Story-docs

* Update @navikt/core/react/src/util/hooks/useScrollLock.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Document body style overrides

* 📝 Docs

* ♻️ Cleanup redundant fn

* ♻️ better naming

* 📝 Docs

* 🔥 removed test-case in story that cant work

* 📝 Update docs

* 📝 Update docs

* 🔥 removed comment

* 🎉 Re-added bodylockscroll support for backwards compat

* 🎉 Re-added class to css, removed updated aksel prefix css

* ✨ Move Overlay from separate branch to dialog branch

* 🚚 Rename to dialog

* 🚚 Rename all overlay functions

* 🏷️ Move props

* 📝 Handle corrent pointerdown outside

* 🔥 Remove old code

* 💄 Dialog popoup and backdrop css

* 💄 Add default text-color

* 🐛 Resolve failed tests after updating autofocus interaction

* 🎉 Added header, footer, title and description components

* 🐛 Fix imports

* 💄 Dialog sizing

* 🧪 Added complex demo

* 🧪 Nested demo

* 🧪 Nested demo

* 🧪 Args demo

* 🐛 Fix center animation

* 🎉 Fix centering for position center

* 🎉 Now handles nested modal

* 💄 Centered dialog transition

* 💄 Adjust fullscreen size

* 💄 Fixed centered transition

* 💄 Dialog after element transition

* 🐛 Render multiple defaultOpen elements in correct order

* 🐛 Avoid auto-closing

* 📝 TODOs

* 🎉 Improved portal element

* 🧪 Set ut tests for dismissablelayer

* 📝 todos

* 📝 Copy file

* ✨ Registering and un-registering of elements

* ✨ Added escapeEventHandler

* 🐛 Added enabled support

* ✨ Added pointerDownOutside handler

* 📝 Added enabled check

* 🐛 Removed dismissablelayer enabled toggle

* 🐛 Removed dismissablelayer enabled toggle

* 🧪 Fix edgecase for checking safezone tests

* 🐛 Fix outside events

* 🎉 Render dismissable-layer handlers only when enabled

* 📝 story update

* 🎉 Layer ordering

* 🚚 Rename file

* 🧪 Tests for sorting

* 🐛 removed legacy safezone attrb

* 📝 Test name update

* 🚚 Update docs for DismissableLayer

* 🐛 re-add test-stories

* 📝 story-prettier

* 📝 Docs

* 🔥 Removed re-export

* 🔥 Revert portal changes

* 🎉 Fix escape event prevention

* 🎉 Added rightclick support

* 🎉 Handle pointer up events

* 🎉 Handle nested backdrops better

* ♻️ Simplify portal

* 🎉 Now 'hides' all other elements on screen when dialog is open

* 📝 removed todos

* 🔥 removed redundant re-assignment

* 📝 Added size support

* 💄 css size support

* ♿ Title and desc no updated labels on popup

* 📝 animationframe for focus-call

* ⚡ Properly queue focus

* 📝 todo-bug

* 📝 Docs

* 🎉 Add id-connections between popup and control

* 🐛 Move focus-update to microtask

* 🧪 Aria-attrb tests

* ♻️ Co-locate hide-attrb

* ♻️ Integrate Portal and backdrop

* 💄 Add rootElement prop, update nested styling

* 📝 Doc changes

* 💄 Update dialog backdrop and overlay color

* 💄 Avoid rendering backdrop in fullscreen mode

* ♻️ re-implement pointerup in dismissablelayer

* 🐛 Resolve returnfocus handling

* 🐛 waitfor mount

* 🐛 Resolve outside click handling

* ♻️ Forward outsideprop

* 📝 Docs

* 💄 Add will-change for animations

* 📝 Comments

* 🚚 Inlined Portal-element

* 🏷️ Rename backdrop -> backdropinternal

* ♻️ Extract transitionAttrb utility

* ♻️ Inline extracted consts

* 🎉 Slotted components

* 💄 Dialog now grid-based

* 🐛 Fix dialog-stories

* 🐛 Fix Dismissablelayer stories

* 📝 TODOs

* 🔥 Removed unmount check in backdrop

* 🚚 Moved user-select style to CSS

* ⚰️ Removed aria-describedby on popup

* 🔥 Removed safari trigger check since we allready ignore trigger

* 🔥 Removed todo

* 🚚 Rename backdrop and closebutton names

* 🏷️ Rename intiial and return-focus props

* 🎉 Call onOpenChangeComplete on open

* 💄 Adjust min/max height and widths

* ♻️ Update animationFinished

* 📝 CSS comments

* 🔥 removed will-change property

* 🔥 Removed outline on center-position popup

* 🐛 Fix story-tests issues

* adjust comment in usePointerUpOutside

* Some changes after review

* ⚡ Removed ref-connection for backdrop

* ♻️ Move internal classNames first in stack

* ⚡ Remove redundant optimization

* 📝 Doc update

* 🔥 Remove redundant test

* 🏷️ use same pointer-event for up and down

* Remove redundant expect()s in Dialog.test.stories.tsx

* 📝 todo

* 🏷️ Fixed autocomplete for width/height in dialog

* 🔥 Remove redundant ref

* 🚚 Move onAnimationComplete to popup itself

* 🔥 Removed unused ref

* ♻️ Ref-reset cleanup

* ✨ Only allow closing dialog on pointer up events

* ♻️ Avoid renaming props unnecessarily

* 🚚 Move size change in CSS to data-attrb

* 📝 Jsdoc

* 📝 Jsdoc

* 🏷️ Open state handler name

* ⚡ removed unnecessary optimization

* ⚡ UseCallback instead of eventCallback

* 📝 Jsdoc

* 🔥 Remove redundant test

* 💄 Remove top padding in body if header exists

* 💄 Render outline when no backdrop exists or in dark-mode

* 🔥 Removed height definition for left/right drawer

* 📝 Implementation-demo

* 🏷️ Rename exit-animation disable

* 🏷️ Rename DialogClose -> DialogCloseTrigger

* [FocusBoundary] Track previous active elements (#4282)

* 🎉 Track list of prev active elements

* 🧪 track previous focused elements

* Update @navikt/core/react/src/util/focus-boundary/FocusBoundary.tests.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/util/focus-boundary/FocusBoundary.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/util/focus-boundary/FocusBoundary.tests.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🏷️ Rename button

* ⚡ fall back to focusing trigger

* 🎉 Now properly cleans up prev-focused items no longer possible to focus

* 🐛 Update canvas-getby to use Role instead if id after component change

* 🐛 Allow trap-focus without backdrop to close onPointerDown

* 🔥 removed types

* 🐛 Fall back to trigger focus on outside click in trap-focus mode

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ PR-review cleanup

* ⚡ Optimize nested statehandler calls

* 💄 Dialog legacy CSS

* 📝 Update exports and jsdoc

* 📝 Update storybook and chromatic stories for dialog

* 🐛 Make trigger Slottable only

* 🔥 removed temp test story

* ♻️ Allow overriding roleb

* 🐛 Update dialog tests

* Update @navikt/core/react/src/dialog/popup/DialogPopupInternal.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/dialog/backdrop/DialogBackdropInternal.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/dialog/root/DialogRoot.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Changeset

* 💄 Use float and display block instead of grid in Dialog

* 🐛 Sync darkside css with legacy

* [Dialog] Remove asChild-API from child-components (#4356)

* 🔥 Removed asChild from Dialog-API

* 🔥 Remove unused fragment

* 💄 Sync leagcy-css with darkside

* [Dialog] Implement use of Dialog on Website (#4355)

* 🎉 Use dialog for website mobile-menu

* 🎉 use Dialog for global search

* 🎉 Optimize rendering

* 🎉 Use dialog for icon-page

* 🔥 Use closetrigger, removed old css

* 🎉 Better overflow handling

* ⚡ Avoid scrolling after closing icon-panel

* 🐛 Sync css

* ♻️ removed redundant max check in CSS

* 💄 MobileMenu changed to 400px

* 💄 Adjust max-width

* ♻️ Better handling of Dialog in on website

* 📝 Update JSDoc

* 🐛 Better browser-support for 'checkVisibility'

* ♿ Explicitly set aria-modal on Dialog

* 🎉 Backdrop defaults to off when modal !== true

* 💄 Force outline in force-colors mode

* 📝 Inline dialogPosition

* 🏷️ Update initial and return focus callbacks

* 🏷️ Update initial and return focus callbacks

* [Dialog] Website examples  (#4395)

* 📝 Examples dialog

* 📝 Lazy/conditional render examples

* 📝 Return-focus example

* 🎉 Reorder demos

* 📝 Actionmenu example

* ♿ Better a11y for menu

* 🐛 Typos

* 🐛 Typos and missing ids

* 🐛 Fix desc formatting error

* 📝 Position example updated, removed redundant stories

* Update aksel.nav.no/website/pages/eksempler/dialog/controlled.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Use dialogPopupProps

* 💄 More subtle destructive action

* 📝 Alertdialog description

* 📝 Sync prop-names

* 📝 Implementation-demo

* 📝 Update example

* 📝 Interactive implementation-demo

* 💄 Update height media-query for bottom-placement, removed ResponsiveProp from width/height.

* 🐛 Fix form overflow

* 📝 Form example

* 💄 Re-order buttons

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/pages/eksempler/dialog/position.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Trap-focus doc update, changeset

* Update .changeset/cuddly-camels-melt.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 Wrap global-search in Suspense

* 🐛 Optional trigger for fallback in global search suspense

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2025-12-19 12:15:00 +01:00
Ken 0d8cf4bcc5 🎉 Auto enable/disable holiday decorations based on month 2025-12-19 11:26:04 +01:00
Ken 579c5f162a 📝 Adjust datepicker-example for chromatic 2025-12-19 10:36:48 +01:00
github-actions[bot] a90c01ad50 Version Packages (#4418)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-12-19 10:26:55 +01:00
Ken d2870f7cb6 [CLI] Added option to run scripts locally (#4419)
* 🎉 Static export of version

* 🔥 Removed script-file

* 🔥 Removed axios dependency

* 📝 Changeset
2025-12-19 10:20:33 +01:00
KenandHalvor Haugan 06dab3b8a1 ✨ Popover now flips in Datepicker/MonthPicker (#4420)
* ✨ Popover now flips above input if more space is avaliable in Datepicker

* Update .changeset/short-weeks-sip.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ✨ Popover now respects placement alignment when flipping

* 📝 changeset

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-12-19 10:18:32 +01:00
Ken 2ed1c565e2 [Datepicker] Ranged same date click bug (#4417)
* 🧪 Set up failing tests

* 🐛 Fix ranged datepicker same date bug
2025-12-18 16:15:17 +01:00
KenandHalvor Haugan d11985bf03 [CLI] Show status and print legacy/component tokens (#4398)
* 🏷️ Better legacy-override naming

* 🎉 Now prints and lists legacy and component-tokens

* 🎉 Avoid re-writing old tokens

* 📝 Changeset

* Update @navikt/aksel/src/darkside/config/TokenStatus.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Updated changeset

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-12-18 09:32:38 +01:00
Ken 3e85294b44 🔒 Resolve storybook CVE-2025-68429 2025-12-17 19:12:39 +01:00
Halvor Haugan da6e970b29 Convert some Chromatic stories to renderStoriesForChromatic (#4397) 2025-12-17 16:31:57 +01:00
Ken 092853dd18 [Icons] Removed updated_at field (#4399)
* 🔥 Removed updated_at field from icon template

* 🔥 Removed updated_at field from icon yml

* 📝 Changeset
2025-12-17 16:30:55 +01:00
Ken 32056657dc ✨ InternalHeaderUser now supports ReactNode in props. (#4415) 2025-12-17 15:51:42 +01:00
github-actions[bot] a2ded80e69 Version Packages (#4413)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-12-17 12:36:10 +01:00
Halvor Haugan dacf10a809 [website] Fix minHeight option in withDsExample (#4411) 2025-12-17 11:53:57 +01:00
Halvor Haugan 28cbc81602 Migrate to nextjs-vite framework on storybook:aksel (#4412) 2025-12-17 11:53:24 +01:00
Ken 25233783a7 🎉 Support print in Checkbox and Radio CSS (#4404)
* 🎉 Support print in Checkbox and Radio CSS

* 🔥 removed unused css

* 🧪 Chromatic print stories

* 🧪 Use outline for radio outline

* 🐛 Add print-color exact

* 🔥 Revert print-exact change

* 🐛 Show selected radio in readonly-mode + print
2025-12-17 11:52:12 +01:00
dependabot[bot] 547a804eba ⬆️ Bump the actions group with 2 updates (#4407)
Bumps the actions group with 2 updates: [actions/upload-artifact](https://github.com/actions/upload-artifact) and [actions/download-artifact](https://github.com/actions/download-artifact).


Updates `actions/upload-artifact` from 5 to 6
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v5...v6)

Updates `actions/download-artifact` from 6 to 7
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](https://github.com/actions/download-artifact/compare/v6...v7)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: actions
- dependency-name: actions/download-artifact
  dependency-version: '7'
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: actions
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-16 19:40:50 +01:00
Halvor Haugan 1f5f205e2b [website] More adjustments of desc in Button examples 2025-12-15 15:46:42 +01:00
Halvor Haugan 066eaa5175 [website] Adjust descriptions on Button examples 2025-12-15 15:29:14 +01:00
Ken 5e44d1d10b 💄 Glow-effect on Ascii-tree, animated eyes
💄 Make Ascii-tree glow
💄 Animate eyes
2025-12-12 14:54:07 +01:00
Ken 10a304e84b [Website] Holiday decorations (#4400)
* 🎉 Snow and ascii christmas tree

* 🎉 Asci-tree used

* 🚚 Moved Ascii tree
2025-12-12 12:59:09 +01:00
Ken 1d0f9c6ca4 🔒 Resolve Nextjs CVE-2025-55184 and CVE-2025-55183 2025-12-12 09:43:35 +01:00
d9e0327b2c [Website] Added diff and highlighting support (#4394)
* 🎉 Added diff language

* 🎉 Added diff highlighting

* 🐛 Better validation

* 🎉 Added highlighting border

* Update aksel.nav.no/website/app/_ui/code-block/CodeBlock.module.css

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update aksel.nav.no/website/app/_ui/code-block/CodeBlock.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 Center marks

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-12-11 20:03:13 +01:00
github-actions[bot] c1e2116eec Version Packages (#4383)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-12-11 17:17:19 +01:00
Ken 25c8024a3e 🐛 Removed unused aria-labelledby from InfoCard.Title (#4393) 2025-12-11 13:15:04 +01:00
Ken 7b3dc3d282 📝 Update sanity (#4391)
* 📝 Update sanity

* 🐛 resolve import issue
2025-12-10 10:11:01 +01:00
Halvor Haugan b59c9c1d08 Update Modal.test.tsx to avoid "not wrapped in act" warning 2025-12-09 13:09:46 +01:00
KenandCopilot 0fda5a596c [CLI] 📝 Lock dependencies (#4386)
* 📝 Lock dependencies

* Update .changeset/smooth-books-bake.md

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 🔥 removed react-scanner

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-09 12:59:42 +01:00
Halvor Haugan 8a51477467 [Deps] Update browserslist 2025-12-09 12:54:59 +01:00
Halvor Haugan 33a7132c54 [website] Add type=button on sidebar subnav expand button 2025-12-09 12:36:06 +01:00
Ken 683107ea9a 📝 Re-order CLI codemods for v8 2025-12-09 10:29:08 +01:00
Ken 69514dcf22 📝 Add migrations as a category level for grunnleggende 2025-12-08 13:52:45 +01:00
Halvor HauganandKen b9a3de281d Accordion: Remove aria-hidden to prevent SiteImprove reporting an issue (#4382)
* Accordion: Remove aria-hidden to prevent SiteImprove reporting an issue

* Update sparkly-monkeys-glow.md

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2025-12-07 21:26:45 +01:00
Ken eb66a7395c 💄 [CLI] Add chalk colorization to status printout 2025-12-05 19:34:52 +01:00
Ken 926737350d [Tests] Rewrite old testing-library tests for Tooltip and Popover with Storybook (#4373)
* ♻️ Extract leagcy-tests for popover

* 📝 rename main popover story

* ♻️ Extract leagcy-tests for tooltip

* 📝 Rename tooltip story

* ♻️ Remove extra async-assertions from waitfor
2025-12-04 14:36:05 +01:00
github-actions[bot] 92091f979e Version Packages (#4348)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-12-04 13:58:31 +01:00
Ken b539ff183f 🎉 Trusted publishing of NPM-packages (#4379)
* 🎉 Trusted publishing of NPM-packages

* 🔥 Removed npm-automation token from git-release
2025-12-04 12:39:58 +01:00
Halvor Haugan 1e39b18962 [Tests] Fix some eslint errors in tests (#4380) 2025-12-04 12:25:04 +01:00
Halvor Haugan 7e9240c404 [Tests] Upgrade playwright image (#4381) 2025-12-04 12:23:40 +01:00
Ken f4592b517b [Templates] Update intro template (#4327)
* 🎉 Use tag for intro id

* ♻️ Use InfoCard instead of Alert

* 🐛 Re-add react import
2025-12-04 12:02:24 +01:00
Ken 5be02cdedc Resolve CVE-2025-66478 (#4376)
* ⬆️ Update react, react-dom

* 🐛 Reset yarn.lock

* 🐛 Temp resolve lint-errors
2025-12-04 09:57:28 +01:00
dependabot[bot] 505462b9ec ⬆️ Bump chalk from 4.1.0 to 5.6.2 (#4371)
Bumps [chalk](https://github.com/chalk/chalk) from 4.1.0 to 5.6.2.
- [Release notes](https://github.com/chalk/chalk/releases)
- [Commits](https://github.com/chalk/chalk/compare/v4.1.0...v5.6.2)

---
updated-dependencies:
- dependency-name: chalk
  dependency-version: 5.6.2
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-03 12:04:03 +01:00
dependabot[bot]andKen b9d5fe8ba2 ⬆️ Bump clipboardy from 2.3.0 to 5.0.0 (#4372)
* ⬆️ Bump clipboardy from 2.3.0 to 5.0.0

Bumps [clipboardy](https://github.com/sindresorhus/clipboardy) from 2.3.0 to 5.0.0.
- [Release notes](https://github.com/sindresorhus/clipboardy/releases)
- [Commits](https://github.com/sindresorhus/clipboardy/compare/v2.3.0...v5.0.0)

---
updated-dependencies:
- dependency-name: clipboardy
  dependency-version: 5.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* 📝 Min-engine set to node 20 for CLI

* 📝 Changeset

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-12-03 12:01:21 +01:00
Ken 0cd3dde88e [v8] 🎉 Action to deploy v7-app (#4367)
* 🎉 Action to deploy v7-app

* 📝 Update deploy v7 action
2025-12-03 11:49:49 +01:00
KenandHalvor Haugan 7cf0714490 [Dependabot] Update dependabot with cooldown and more grouping (#4365)
* 📝 Update dependabot with cooldown

* 🔥 Removed some setting dependabot

* Update .github/dependabot.yml

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-12-03 10:48:02 +01:00
Ken acbd3bda18 [V8 codemods] Box migration nesting/idempotent bug and prefixing update (#4363)
* 🎉 Fix prefixing of bg and border-tokens

* 🐛 Check that tokens is not already migrated to a valid value

* 📝 Changeset

* 🐛 Now correctly only checks opening/root element instead of all nested elements

* 📝 rename existingRepalcements
2025-12-02 16:50:17 +01:00
KenandHalvor Haugan 94764fea85 [CLI] v8-tokens codemod update (#4341)
* 🎉 Support ext

* ⚡ Optimize file indexing

* ⚡ Optimize file-indexing

* ⚡ Optimize regex creation

* 🐛 Optimize indexing, add js and some tailwind-support

* ⚡ Optimize tailwind codemod

* 🧪 More tests

* ⚡ Optimize css codemod

* 📝 Better status reports

* 📝 Better printouts

* 📝 Improve printouts

* ⚡ Avoid re-running status-update

* 📝 Update summary

* 🔥 Removed waitfor keypress

* 📝 Changeset

* ♻️ Avoid inline assignment

* 📝 Added comments

* ♻️ Small refactor, extracting complexity into functions

* 🔥 Removed commented code

* Update @navikt/aksel/src/codemod/run-codeshift.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/aksel/src/codemod/run-codeshift.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ No array for glob-list

* ♻️ getWordPositionInFile -> getCharacterPositionInFile

* ♻️ Only comment once for grouped tokens

* ⚡ Always update status on print

* Revert "⚡ Always update status on print"

This reverts commit 65b1d9cd36.

* ⚡ Always update status on print

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-12-02 14:21:24 +01:00
Halvor Haugan 97e4e69643 [website] Add URL to GitHub issue link on 404 page (#4344) 2025-12-02 14:00:01 +01:00
dependabot[bot] b0e25c2ef4 ⬆️ Bump mdast-util-to-hast from 13.2.0 to 13.2.1 (#4361)
Bumps [mdast-util-to-hast](https://github.com/syntax-tree/mdast-util-to-hast) from 13.2.0 to 13.2.1.
- [Release notes](https://github.com/syntax-tree/mdast-util-to-hast/releases)
- [Commits](https://github.com/syntax-tree/mdast-util-to-hast/compare/13.2.0...13.2.1)

---
updated-dependencies:
- dependency-name: mdast-util-to-hast
  dependency-version: 13.2.1
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-02 12:00:32 +01:00
Ken 5a09f88ea2 🐛 Properly parse v8-tokens arg with options 2025-12-02 11:46:55 +01:00
Halvor Haugan 488d0f5ef2 [website] Adjust examples of Search 2025-12-01 16:03:01 +01:00
dependabot[bot] 89fe0e1183 ⬆️ Bump the storybook group with 9 updates (#4350)
Bumps the storybook group with 9 updates:

| Package | From | To |
| --- | --- | --- |
| [@storybook/addon-a11y](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/a11y) | `10.0.8` | `10.1.2` |
| [@storybook/addon-docs](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/docs) | `10.0.8` | `10.1.2` |
| [@storybook/addon-themes](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/themes) | `10.0.8` | `10.1.2` |
| [@storybook/addon-vitest](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/vitest) | `10.0.8` | `10.1.2` |
| [@storybook/nextjs](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/nextjs) | `10.0.8` | `10.1.2` |
| [@storybook/react-vite](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/react-vite) | `10.0.8` | `10.1.2` |
| [eslint-plugin-storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/eslint-plugin) | `10.0.8` | `10.1.2` |
| [storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/core) | `10.0.8` | `10.1.2` |
| [storybook-addon-pseudo-states](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/pseudo-states) | `10.0.8` | `10.1.2` |


Updates `@storybook/addon-a11y` from 10.0.8 to 10.1.2
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.1.2/code/addons/a11y)

Updates `@storybook/addon-docs` from 10.0.8 to 10.1.2
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.1.2/code/addons/docs)

Updates `@storybook/addon-themes` from 10.0.8 to 10.1.2
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.1.2/code/addons/themes)

Updates `@storybook/addon-vitest` from 10.0.8 to 10.1.2
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.1.2/code/addons/vitest)

Updates `@storybook/nextjs` from 10.0.8 to 10.1.2
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.1.2/code/frameworks/nextjs)

Updates `@storybook/react-vite` from 10.0.8 to 10.1.2
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.1.2/code/frameworks/react-vite)

Updates `eslint-plugin-storybook` from 10.0.8 to 10.1.2
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.1.2/code/lib/eslint-plugin)

Updates `storybook` from 10.0.8 to 10.1.2
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.1.2/code/core)

Updates `storybook-addon-pseudo-states` from 10.0.8 to 10.1.2
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.1.2/code/addons/pseudo-states)

---
updated-dependencies:
- dependency-name: "@storybook/addon-a11y"
  dependency-version: 10.1.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/addon-docs"
  dependency-version: 10.1.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/addon-themes"
  dependency-version: 10.1.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/addon-vitest"
  dependency-version: 10.1.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/nextjs"
  dependency-version: 10.1.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: "@storybook/react-vite"
  dependency-version: 10.1.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: eslint-plugin-storybook
  dependency-version: 10.1.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: storybook
  dependency-version: 10.1.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: storybook-addon-pseudo-states
  dependency-version: 10.1.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-01 09:32:19 +01:00
Halvor Haugan 2f42b240e8 Select: Remove the htmlSize prop (#4347) 2025-11-28 14:13:40 +01:00
Halvor Haugan e413ffe06b [website] Adjust examples of Select (and Checkbox and Switch) (#4346) 2025-11-28 14:01:07 +01:00
Halvor Haugan f744df8966 [website] Fix examples navigation in preview mode 2025-11-28 13:30:29 +01:00
Halvor Haugan 3c888e8721 Adjusted example of links in ActionMenu (#4343) 2025-11-28 11:24:41 +01:00
Halvor Haugan 2acc2e2971 Refactor Chromatic story on alert, switch, progressbar and guidepanel stories (#4342) 2025-11-28 10:00:34 +01:00
Halvor Haugan fd9ba8927d Rewrite some Chromatic stories to using helper function (#4340) 2025-11-27 19:25:18 +01:00
github-actions[bot] 9e0d9046bc Version Packages (#4333)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-11-27 16:09:18 +01:00
Ken 7a5852d6b6 🎨 Disable biome Import sorting 2025-11-27 16:06:50 +01:00
Ken 7ee5092c58 [Darkside] Merge darkside token migration into codemod-script (#4334)
* ♻️ Merge darkside token migration into codemod

* 📝 Better docs and testing
2025-11-27 11:42:47 +01:00
dependabot[bot] dd3be45a36 ⬆️ Bump the npm_and_yarn group across 4 directories with 2 updates (#4336)
Bumps the npm_and_yarn group with 2 updates in the /examples/astro directory: [astro](https://github.com/withastro/astro/tree/HEAD/packages/astro) and [glob](https://github.com/isaacs/node-glob).
Bumps the npm_and_yarn group with 1 update in the /examples/next-appdir directory: [glob](https://github.com/isaacs/node-glob).
Bumps the npm_and_yarn group with 1 update in the /examples/referansesider directory: [glob](https://github.com/isaacs/node-glob).
Bumps the npm_and_yarn group with 1 update in the /examples/shadow-dom directory: [glob](https://github.com/isaacs/node-glob).


Updates `astro` from 5.15.6 to 5.15.9
- [Release notes](https://github.com/withastro/astro/releases)
- [Changelog](https://github.com/withastro/astro/blob/main/packages/astro/CHANGELOG.md)
- [Commits](https://github.com/withastro/astro/commits/astro@5.15.9/packages/astro)

Updates `glob` from 10.4.5 to 10.5.0
- [Changelog](https://github.com/isaacs/node-glob/blob/main/changelog.md)
- [Commits](https://github.com/isaacs/node-glob/compare/v10.4.5...v10.5.0)

Updates `glob` from 11.0.3 to 11.1.0
- [Changelog](https://github.com/isaacs/node-glob/blob/main/changelog.md)
- [Commits](https://github.com/isaacs/node-glob/compare/v10.4.5...v10.5.0)

Updates `glob` from 10.4.5 to 10.5.0
- [Changelog](https://github.com/isaacs/node-glob/blob/main/changelog.md)
- [Commits](https://github.com/isaacs/node-glob/compare/v10.4.5...v10.5.0)

Updates `glob` from 10.4.5 to 10.5.0
- [Changelog](https://github.com/isaacs/node-glob/blob/main/changelog.md)
- [Commits](https://github.com/isaacs/node-glob/compare/v10.4.5...v10.5.0)

---
updated-dependencies:
- dependency-name: astro
  dependency-version: 5.15.9
  dependency-type: direct:production
  dependency-group: npm_and_yarn
- dependency-name: glob
  dependency-version: 10.5.0
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: glob
  dependency-version: 11.1.0
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: glob
  dependency-version: 10.5.0
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: glob
  dependency-version: 10.5.0
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-27 11:27:57 +01:00
KenandHalvor Haugan 40e186c906 [CLI] Removed css-import command (#4331)
* 🔥 Removed css-import CLI

* 📝 Changeset

* ⬆️ yarn lock sync

* Update @navikt/aksel/README.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-11-27 11:26:58 +01:00
dependabot[bot] 7da5a1243e ⬆️ Bump node-forge from 1.3.1 to 1.3.2 (#4338)
Bumps [node-forge](https://github.com/digitalbazaar/forge) from 1.3.1 to 1.3.2.
- [Changelog](https://github.com/digitalbazaar/forge/blob/main/CHANGELOG.md)
- [Commits](https://github.com/digitalbazaar/forge/compare/v1.3.1...v1.3.2)

---
updated-dependencies:
- dependency-name: node-forge
  dependency-version: 1.3.2
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-27 10:09:34 +01:00
dependabot[bot] 656ada6764 ⬆️ Bump valibot from 1.1.0 to 1.2.0 (#4337)
Bumps [valibot](https://github.com/open-circle/valibot) from 1.1.0 to 1.2.0.
- [Release notes](https://github.com/open-circle/valibot/releases)
- [Commits](https://github.com/open-circle/valibot/compare/v1.1.0...v1.2.0)

---
updated-dependencies:
- dependency-name: valibot
  dependency-version: 1.2.0
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-27 10:08:18 +01:00
Ken 4ef660acb4 [Website] Remove @navikt/ds-tailwind dependency from website (#4326)
* ♻️ Remove dependency on ds-tailwind package on website

* 📝 Docs

* 🔥 Removed tw from depdendency array
2025-11-26 15:59:39 +01:00
Ken 42b860fedc 📝 Changeset cleanup 2025-11-26 15:45:33 +01:00
Ken 7a68589058 🐛 Add color to search icon (#4323)
* 🐛 Add color to search icon

* Apply suggestion from @KenAJoh
2025-11-26 15:39:20 +01:00
Ken 7fe90910e6 [Combobox] Locale update (#4324)
* 🎉 Add locale-support for no hits text combobox

* 📝 Changeset

* 📝 Rename translation-key
2025-11-26 15:38:45 +01:00
Ken e4172990f8 🐛 Added releases to Santiy 2025-11-26 14:14:11 +01:00
Ken 094cbf8bbe 🎉 Enable scheduled releases sanity 2025-11-26 13:32:50 +01:00
Ken bc37eb8ab0 🚚 Move Spacing codemod to v8-dir 2025-11-26 13:31:51 +01:00
Halvor Haugan ebf96f2172 [website] Fix overflow issue on Endringslogg page on mobile 2025-11-26 10:38:15 +01:00
Halvor Haugan 0dc95b5c01 [website] Fix search input size on darkside tokens page on mobile 2025-11-26 10:29:17 +01:00
Halvor Haugan e8036b9fe6 [website] Add min-height on Combobox examples (#4329) 2025-11-26 09:21:37 +01:00
Ken 29c616f93c 💄 Update code-block for website 2025-11-25 15:56:09 +01:00
Ken 78c6d53bdf 🐛 Darkside-css for LinkCard referenced legacy token 2025-11-25 14:15:50 +01:00
Halvor Haugan ee8fb859f0 [website] Fix warnings about NextImage (#4320) 2025-11-25 11:59:51 +01:00
Ken f3b0eda0fa 🐛 Try disabling: Datepicker/Monthpicker tests for CI-action 2025-11-25 10:20:06 +01:00
Ken 46eedbafe4 🐛 Try disabling: Combobox tests for CI-action 2025-11-25 10:03:40 +01:00
Ken ba3548bcf9 🐛 Prevent hydration mismatch with client-side only render of Examples 2025-11-25 09:21:06 +01:00
dependabot[bot] 584d5ff250 ⬆️ Bump astro (#4285)
Bumps the npm_and_yarn group with 1 update in the /examples/astro directory: [astro](https://github.com/withastro/astro/tree/HEAD/packages/astro).


Updates `astro` from 5.14.4 to 5.15.6
- [Release notes](https://github.com/withastro/astro/releases)
- [Changelog](https://github.com/withastro/astro/blob/main/packages/astro/CHANGELOG.md)
- [Commits](https://github.com/withastro/astro/commits/astro@5.15.6/packages/astro)

---
updated-dependencies:
- dependency-name: astro
  dependency-version: 5.15.6
  dependency-type: direct:production
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-24 15:50:12 +01:00
KenandHalvor Haugan 7618d0f91a [Codemods] Updated darkside/v8 codemods (#4305)
* 🚚 Moved and cleaned up box codemod

* Create file

* Set up box migraiton

* 🚚 Move box-new migration to standalone mod

* 🧪 Initial test files

* 🧪 Initial test files

* 🐛 Fix test names

* 🎉 Fix box codemod

* ✨ Added more test-cases

* ⚡ Create composite codemod for box

* 🎉 Add List component to prop deprecation codemod

* 📝 Set up color-update codemod

* 🎉 Add config for migration

* 🎉 Set up template cases

* 🎉 Added variant -> color migration for Tag

* 🎉 tag-variant migration setup

* 🎉 ToggleGroup variant migration

* 🚚 Extracted variant change to utility

* 🎉 Added Accordion migration

* 📝 Extract utility

* 🎉 Now supports sub-components

* 🎉 support nested imports

* 🎉 Added Chips variant migration

* Update @navikt/aksel/src/codemod/utils/check.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/aksel/src/codemod/migrations.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/aksel/src/codemod/migrations.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/aksel/src/codemod/migrations.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/aksel/src/codemod/migrations.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/aksel/src/codemod/migrations.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🏷️ Update any-type

* 📝 Update commen

* 📝 Added alias for old box

* 🔥 Removed List from prop-deprecation codemod

* Update @navikt/aksel/src/codemod/transforms/v8.0.0/box-new/tests/index.test.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Comment update

* 📝 Update test

* 🐛 Handle custom local import-name

* [Codemods] List codemod (#4319)

* 📝 list codemod

* 📝 List config maps

* 📝 Set up tests

* 📝 Add list test

* 🎉 List codemod

* 📝 Add import alias demo

* 📝 Handle allready existing imports

* 🐛 Handle attrbute spread

* 🏷️ Avoid any

* 📝 add List migration

* 📝 Update tests

* 🐛 Handle as/level prop

* 🐛 Handle more import-cases

* 🐛 Handle 'idempotent'

* 🐛 Allow standalone Lists to be migrated without Title and Description

* 📝 Readme

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-11-24 15:39:45 +01:00
eb4bc99861 [Linting] eslint-plugin-react-hooks v7 update for aksel website (#4258)
* ⬆️ Update react-hooks lint rule to v7

* ⬆️ Update react-hooks lint rule to v7

* 🚨 Fix ref in popover examples

* ♻️ Avoid unline-rendering of component

* ♻️ Update useMedia hook for website

* ♻️ Avoid use of state in umami-loading

* 📝 TOC-comment

* 🐛 Manually supress hydration-error

* ⚡ Derive active example from state

* ⚡ Move state-update to effect

* ⚡ Avoid syncronous state-update

* ⚡ Remove dom-node updates with ref in compareImages

* ⚡ Improve CompareImages state handling

* 🔥 Removed hovercard code

* 🐛 Avoid re-creating components

* 📝 Hide false positive

* ⚡ Make scroll-state reset use transition

* ⚡ Move state-update to transition

* ⚡ startTransition for role-reset in token-view

* ⚡ Ignore auto-generated sanity types with linter

* 🐛 Ignore auto-geneerated nextjs-types

* ⚡ StartTransition for iconpage

* ⬅️ Undo startTransition change

* Avoid scrolling to last example when page includes multiple examples

* Update aksel.nav.no/website/app/_ui/compare-images/CompareImages.handle.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Temp disable new eslint-rules that does not exist in v5

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-11-24 15:29:52 +01:00
Ken c3e8154c21 ⚡ Speed up CI-tests 2025-11-24 13:52:42 +01:00
Ken a6fc511785 🐛 Debug CI-workflow timing out 2025-11-24 13:33:50 +01:00
dependabot[bot] eabbe2394a ⬆️ Bump the storybook group with 9 updates (#4313)
Bumps the storybook group with 9 updates:

| Package | From | To |
| --- | --- | --- |
| [@storybook/addon-a11y](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/a11y) | `10.0.7` | `10.0.8` |
| [@storybook/addon-docs](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/docs) | `10.0.7` | `10.0.8` |
| [@storybook/addon-themes](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/themes) | `10.0.7` | `10.0.8` |
| [@storybook/addon-vitest](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/vitest) | `10.0.7` | `10.0.8` |
| [@storybook/nextjs](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/nextjs) | `10.0.7` | `10.0.8` |
| [@storybook/react-vite](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/react-vite) | `10.0.7` | `10.0.8` |
| [eslint-plugin-storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/eslint-plugin) | `10.0.7` | `10.0.8` |
| [storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/core) | `10.0.7` | `10.0.8` |
| [storybook-addon-pseudo-states](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/pseudo-states) | `10.0.7` | `10.0.8` |


Updates `@storybook/addon-a11y` from 10.0.7 to 10.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.0.8/code/addons/a11y)

Updates `@storybook/addon-docs` from 10.0.7 to 10.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.0.8/code/addons/docs)

Updates `@storybook/addon-themes` from 10.0.7 to 10.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.0.8/code/addons/themes)

Updates `@storybook/addon-vitest` from 10.0.7 to 10.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.0.8/code/addons/vitest)

Updates `@storybook/nextjs` from 10.0.7 to 10.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.0.8/code/frameworks/nextjs)

Updates `@storybook/react-vite` from 10.0.7 to 10.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.0.8/code/frameworks/react-vite)

Updates `eslint-plugin-storybook` from 10.0.7 to 10.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.0.8/code/lib/eslint-plugin)

Updates `storybook` from 10.0.7 to 10.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.0.8/code/core)

Updates `storybook-addon-pseudo-states` from 10.0.7 to 10.0.8
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.0.8/code/addons/pseudo-states)

---
updated-dependencies:
- dependency-name: "@storybook/addon-a11y"
  dependency-version: 10.0.8
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-docs"
  dependency-version: 10.0.8
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-themes"
  dependency-version: 10.0.8
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-vitest"
  dependency-version: 10.0.8
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/nextjs"
  dependency-version: 10.0.8
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react-vite"
  dependency-version: 10.0.8
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: eslint-plugin-storybook
  dependency-version: 10.0.8
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: storybook
  dependency-version: 10.0.8
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: storybook-addon-pseudo-states
  dependency-version: 10.0.8
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-24 11:49:05 +01:00
dependabot[bot] 7798dab309 ⬆️ Bump vite from 7.2.2 to 7.2.4 (#4315)
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 7.2.2 to 7.2.4.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v7.2.4/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 7.2.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-24 11:45:28 +01:00
dependabot[bot] de6b3d94ab ⬆️ Bump actions/checkout from 5 to 6 (#4317)
Bumps [actions/checkout](https://github.com/actions/checkout) from 5 to 6.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v5...v6)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-24 11:44:52 +01:00
Ken 0857815691 🐛 Fix 'as'-type in prop-section for InfoCard 2025-11-24 11:40:10 +01:00
Ken 0e969499d9 [website]: Update prop-table to unpack AkselColor-type 2025-11-24 11:35:37 +01:00
github-actions[bot] c5f8d13121 Version Packages (#4307)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-11-24 10:34:19 +01:00
Halvor Haugan 32de1be6d0 Fix typo in BaseAlertRoot/InfoCardRoot JSDoc 2025-11-21 15:25:50 +01:00
dependabot[bot] f265c2c648 ⬆️ Bump js-yaml from 4.1.0 to 4.1.1 (#4291)
Bumps [js-yaml](https://github.com/nodeca/js-yaml) from 4.1.0 to 4.1.1.
- [Changelog](https://github.com/nodeca/js-yaml/blob/master/CHANGELOG.md)
- [Commits](https://github.com/nodeca/js-yaml/compare/4.1.0...4.1.1)

---
updated-dependencies:
- dependency-name: js-yaml
  dependency-version: 4.1.1
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-21 15:22:38 +01:00
dependabot[bot] 95b962a065 ⬆️ Bump playwright from 1.56.0 to 1.56.1 (#4293)
Bumps [playwright](https://github.com/microsoft/playwright) from 1.56.0 to 1.56.1.
- [Release notes](https://github.com/microsoft/playwright/releases)
- [Commits](https://github.com/microsoft/playwright/compare/v1.56.0...v1.56.1)

---
updated-dependencies:
- dependency-name: playwright
  dependency-version: 1.56.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-21 15:21:55 +01:00
Ken a4058247d0 🎉 New icons PhoneSlash and BelleSlash (#4310) 2025-11-21 14:59:55 +01:00
Ken efebc5fbbb 🐛 Tooltip now has z-index max int (#4309)
* 🐛 Tooltip now has z-index max int

* 🐛 Update token-docs
2025-11-21 14:45:56 +01:00
Ken 5df9ebe102 🐛 Re-export Alert-components for better react-docgen props 2025-11-21 14:43:43 +01:00
Ken fae2ef763e [Alert] Close -> CloseButton (#4308)
* 📝 Close -> Closebutton

* 📝 Jsdoc update

* 🐛 Fix storybook import

* 📝 Update doc desc
2025-11-21 14:22:33 +01:00
Ken 8c230c799e [V8] Stylelint rule for removed navds-prefix (#4304)
* 🏷️ Liniting rule for legacy navds-classnames

* 📝 Readmore

* 📝 Doc changes

* 🔥 Avoid adding new rule-plugin to recommended
2025-11-21 13:31:21 +01:00
39cf344eeb [Alert] LocalAlert, GlobalAlert, InfoCard and InlineMessage components (#4186)
* ✨ InfoCard boilerplate

* ✨ Add context provider and size handling in InfoCard component

* 🎉 Added expand-button

* 🎉 Added animation utils

* 📝 More todos

* 🎉 Can now transition between height auto

* ♻️ Clean up css

* 🎉 New hooks and utilities

* ♻️ Added controlled state handler

* ⚡ Move root-function into callback

* 🎉 Handle initial mount transition

* 🧪 Added hiddenUntilFound experiment

* 🔥 Removed discarded API

* 📝 Added mdn docs

* 📝 Aria tests

* ♻️ Use variables in info-card css

* 📝 Updated stories

* ♻️ Extracted icon into a separate component, refactored stories

* 🐛 Reset color inside content

* ♻️ Re-add icon-prop instead of component

* ✨ InfoCard build output setup

* 📝 jsdoc cleanup

* 📝 Dynamic stories for all colors

* 💄 Added legacy-support

* 📝 Added CSS mappings

* 🔥 Removed todo

* Apply suggestion from @KenAJoh

* Apply suggestion from @KenAJoh

* ♻️ Implement base-alert

* ✨ Added Closebutton component to BaseAlert

* ✨ Implement LocalAlert react-code

* ✨ Added closebutton to LocalAlert

* 💄 Adjusted paddings

* ♿ Added aria-role to LocalAlert

* ✨ GlobalAlert boilerplate

* 💄 Centered global alert

* 💄 Fix centering and padding

* 🎉 Added success back

* 🐛 Properly omit icon from alert header

* 💄 Handle z-index fighting in InfoCard

* 💄 Revert to subtle infocard text

* ✨ InlineAlert component

* 📝 remove padding layout from inlineAlert stories

* 💄 Sync design-adjustments with figma discussions

* 🏷️ Update build config

* 📝 Update translations for Alert

* 📝 Move Alert-stories into a nested structure

* 💄 Add legacy-css support for new Alert-components

* 💄 Sync legacy colors inlineAlert

* 🔥 Removed old info-card css

* ♻️ Refactor BaseAlert structure to reflect modern project structure

* ♻️ Move utils to root

* 🐛 Fix imports

* 🚚 Migrated InlineAlert -> InlineMessage

* ♻️ Add overridablecomponent support

* 💄 Sync design with figma

* 🐛 Fix imports

* 🐛 Remove box-sizing override

* 🚚 Extracted BaseAlert component from #4085

* 🔥 Removed inlinemessage leftovers

* 🔥 Removed inlinemessage

* ⬅️ revert effect change

* Update @navikt/core/react/src/alert/base-alert/BaseAlert.stories.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update @navikt/core/react/src/alert/base-alert/root/BaseAlertRoot.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🔥 Removed position relative

* 🔥 Removed z-index

* Update @navikt/core/react/src/alert/base-alert/close/BaseAlertClose.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/alert/base-alert/root/BaseAlertRoot.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ Allow overriding button type

* ♻️ Temp remove aria-hidden from header icon

* 🐛 Fix nullish icon

* Update @navikt/core/react/src/alert/base-alert/root/BaseAlertRoot.context.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/alert/base-alert/root/BaseAlertRoot.utils.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/alert/base-alert/BaseAlert.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🧪 Predefined story-selections for type and statusType

* 🧪 Replace default story for chromatic

* [New component] LocalAlert (#4187)

* 🚚 Extracted LocalAlert from #4085

* 🏷️ Rename root

* 📝 Doc changes

* 🐛 Add button do depdendency mapping

* Update @navikt/core/react/src/alert/local-alert/close/LocalAlertClose.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/alert/local-alert/root/LocalAlertRoot.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/alert/local-alert/root/LocalAlertRoot.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/alert/local-alert/root/LocalAlertRoot.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🔊 LocalAlert now always an alert

* 🐛 revert closebutton change

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* [New component] InfoCard (#4189)

* 🚚 Extracted InfoCard from #4085

* Update .changeset/quiet-lions-serve.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/css/config/_mappings.js

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* [New component] GlobalAlert (#4188)

* 🚚 Extracted GlobalAlert from #4085

* 📝 Changeset

* 🏷️ Rename root

* 🔊 GlobalAlert now always an alert

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Add button css to global alert mappings

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Docs

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Apply suggestion from @Copilot

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ Remove prop-destructuring

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* [New component] InlineMessage (#4185)

* 🚚 Move InlineMessage PR out of #4085

* 📝 Changeset

* Update @navikt/core/react/src/inline-message/root/InlineMessage.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 📝 Jsdoc update

* Update @navikt/core/react/src/inline-message/root/InlineMessage.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 🔥 Removed flex-start alignment

* Update @navikt/core/react/src/inline-message/root/InlineMessage.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/inline-message/root/InlineMessage.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/inline-message/root/InlineMessage.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/inline-message/root/InlineMessage.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ Inline color-definitions

* ♻️ Clean up css use

* Update @navikt/core/react/src/inline-message/icon/InlineMessageIcon.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🔥 Remove redundant display-flex

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🏷️ Rename variant -> status

* 🏷️ Rename data-type -> data-variant

* 🐛 Fix jsdoc example

* 🔥 removed basealert chroamtic stories

* Apply suggestions from code review

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Doc-changes

* 📝 Doc-changes localalert

* ♻️ Inlinemessage variant -> status

* 🔥 removed wrappingtitle story

* 📝 Add aslink story to chromatic

* Apply suggestions from code review

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 JsDoc updates

* 🔥 Removed commented aria-hidden

* ♿ Add id-connection between icon and title

* 🌐 Move alert locale to global scope

* ♿ Moved section-element to root

* ♿ Aria-label set on alert-div

* 🐛 Avoid close-button being read twice

* 🧪 add title attrb to alert

* 🔥 Removed title on root alert

* Update @navikt/core/react/src/alert/global-alert/close/GlobalAlertClose.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/alert/global-alert/root/GlobalAlertRoot.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/alert/local-alert/close/LocalAlertClose.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/alert/local-alert/root/LocalAlertRoot.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🔥 Remove not-needed status attrb

* 📝 Aria-hidden on icon jsdoc

* 🔥 Removed z-index from header

* ✨ Allow alert-title to be div

* Update @navikt/core/react/src/alert/base-alert/close/BaseAlertClose.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Added a11y test

* 🏷️ Re-added aria-labelledby connection

* 🔥 Removed built-in icon title

* 📝 Reduce title

* [BaseAlert] Update InlineMessage, BaseAlert with more a11y updates (#4299)

* ♿ Better aria connections for InlineMessage

* ♿ Alerts now use section

* 🎉 Update Alert-usage

* 🎉 Website alert update

* 🔥 Removed unused CSS

* 🔥 Hide new alerts from Axe

* 🔥 removed role alert from inlineMessage

* ♿ Use aria-label instead of aria-labelledby

* ♻️ Always use InfoCard in WebsiteAlert

* 🔥 removed statusType from type omits

* 📝 use bold text for jsdoc

* 📝 JSdoc

* [Example] New Alert-component examples (#4290)

* 📝 Initial variant-setup

* 📝 More examples

* 📝 GlobalAlert examples

* 📝 InfoCard examples

* 📝 Inline examples

* Update aksel.nav.no/website/pages/eksempler/info-card/colors.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update aksel.nav.no/website/pages/eksempler/info-card/sizes.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 🔥 Removed desc

* Update aksel.nav.no/website/pages/eksempler/info-card/title-only.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 🔥 Removed desc

* 📝 Updated InfoCard Example

* 📝 Update examples

* 📝 text adjustments

* 📝 Update announcement and error examples

* 📝 Edit warning localalert example

* 📝 Remove unused vstack from examples

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-11-21 13:09:53 +01:00
Ken 66b377c314 🐛 Disable new dialog-view for sanity 2025-11-21 13:06:43 +01:00
Ken ef60170000 Storybook v10 update (#4288)
* 🎉 Upgrade to sb-10

* 🔥 Exclude sb util

* 🐛 Revert bg config change

* 🐛 Remove yarn from storybook command

* 🐛 Update moduleResolution

* 🎉 Removed now unused eslint disable rule comment

* 🐛 Fix imports
2025-11-21 09:55:38 +01:00
Halvor Haugan c25f30ea21 [website] Add desc to description example of Checkbox 2025-11-20 13:01:08 +01:00
Ken 1a8acf1f02 [Darkside] Use darkside configurations where possible without affecting current release
♻️ Use darkside-config where possible

🚚 Update website with darkside -> legacy migration

🚚 Update examples use of leagcy components

🔥 Remove legacy css support from website storybook
2025-11-20 11:29:15 +01:00
Ken fd85b8f85a 📝 Darkside migration changelist 2025-11-20 09:47:06 +01:00
github-actions[bot] ca1b0a715a Version Packages (#4302)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-11-20 09:10:34 +01:00
Halvor Haugan 5cfff15c1c Darkside: Remove [hidden] style (#4301) 2025-11-19 15:15:50 +01:00
Ken 7570678818 ⚡ Avoid rendering datepicker-dialog when not open (#4300) 2025-11-19 14:40:59 +01:00
github-actions[bot] 021f2a888f Version Packages (#4296)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-11-18 13:37:59 +01:00
Ken 43c5dd7285 🐛 Fix list-colors on website 2025-11-18 12:57:00 +01:00
Halvor Haugan 717545def7 Textarea: Set height on first render to auto instead of 0px to reduce layout shift when SSR (#4295) 2025-11-17 14:18:37 +01:00
Halvor Haugan 4f161c993a [website] Adjust examples of Radio 2025-11-14 12:41:01 +01:00
github-actions[bot] 5b00481cca Version Packages (#4286)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-11-14 09:12:57 +01:00
KenandHalvor Haugan ef8a6ceb49 [DismissableLayer] Avoid re-mounting react sub-tree when toggling enabled-state (#4281)
* 🐛 Set upt bug test env

* 🐛 Fix dismissablelayer-remounmt bug

* 📝 changeset

* ⚡ Disable event-handlers from mounting when not enabled

* Update .changeset/rotten-windows-fetch.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ⚡ Optimize cleanup

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-11-14 09:09:31 +01:00
Ken 9a9ce1f746 📝 Simple actionmenu jsdoc 2025-11-13 13:29:24 +01:00
Ken 485a456897 🎉 Moved admin-route above sanitylive to avoid page-reloads (#4279) 2025-11-13 10:32:06 +01:00
Halvor Haugan 4eb4760b2c Tokens: Translate shadow token comment to Norwegian (#4280) 2025-11-12 19:54:16 +01:00
Halvor Haugan 24146b6bb8 [Sanity] Minor field title typo fixes 2025-11-12 16:55:17 +01:00
Halvor Haugan ed06030152 stylelint ignore cleanup (#4278) 2025-11-11 15:07:23 +01:00
dependabot[bot]andKen ceac33cd92 ⬆️ Bump jsdom from 27.0.1 to 27.1.0 (#4274)
* ⬆️ Bump jsdom from 27.0.1 to 27.1.0

Bumps [jsdom](https://github.com/jsdom/jsdom) from 27.0.1 to 27.1.0.
- [Release notes](https://github.com/jsdom/jsdom/releases)
- [Changelog](https://github.com/jsdom/jsdom/blob/main/Changelog.md)
- [Commits](https://github.com/jsdom/jsdom/compare/27.0.1...27.1.0)

---
updated-dependencies:
- dependency-name: jsdom
  dependency-version: 27.1.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* ⬆️ Sync jsdom

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-11-11 13:58:51 +01:00
Ken 68dc355486 🧪 Try to run CI with pool threads to avoid hangups (#4277) 2025-11-11 10:18:35 +01:00
Halvor Haugan 8bd0071241 [website] Refactor artikkel-preview.tsx (#4276) 2025-11-11 09:36:10 +01:00
dependabot[bot] 5f211d60c7 ⬆️ Bump the eslint group with 2 updates (#4270)
Bumps the eslint group with 2 updates: [@eslint/js](https://github.com/eslint/eslint/tree/HEAD/packages/js) and [eslint](https://github.com/eslint/eslint).


Updates `@eslint/js` from 9.39.0 to 9.39.1
- [Release notes](https://github.com/eslint/eslint/releases)
- [Commits](https://github.com/eslint/eslint/commits/v9.39.1/packages/js)

Updates `eslint` from 9.39.0 to 9.39.1
- [Release notes](https://github.com/eslint/eslint/releases)
- [Commits](https://github.com/eslint/eslint/compare/v9.39.0...v9.39.1)

---
updated-dependencies:
- dependency-name: "@eslint/js"
  dependency-version: 9.39.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: eslint
- dependency-name: eslint
  dependency-version: 9.39.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: eslint
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-11 09:13:44 +01:00
Halvor Haugan 51bf912948 Upgrade some dependencies (#4268) 2025-11-10 13:49:48 +01:00
github-actions[bot] 988bc4c891 Version Packages (#4275)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-11-10 12:35:38 +01:00
Ken 4d39b71b32 🐛 Resolve Modal-bug where both HTML and Body were 'locked' with overflow hidden (#4269) 2025-11-10 11:35:54 +01:00
KenandCopilot 6df811455d [Timeline] Hides out of bound pins (#4266)
* 🐛 No longer render pins that are out of bounds

* 📝 Changeset

* Update .changeset/brown-steaks-try.md

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* ♻️ migration cleanup

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-11-10 11:34:34 +01:00
Halvor Haugan 32dd365baa useRangeDatepicker: defaultSelected no longer overrides defaultMonth when defaultSelected.from is undefined (#4267) 2025-11-10 09:30:36 +01:00
dependabot[bot] 6c8cbddd6a ⬆️ Bump min-document from 2.19.0 to 2.19.1 (#4263)
Bumps [min-document](https://github.com/Raynos/min-document) from 2.19.0 to 2.19.1.
- [Commits](https://github.com/Raynos/min-document/compare/v2.19.0...v2.19.1)

---
updated-dependencies:
- dependency-name: min-document
  dependency-version: 2.19.1
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-07 18:07:53 +01:00
dependabot[bot] bfc704507c ⬆️ Bump axios from 1.12.2 to 1.13.0 (#4265)
Bumps [axios](https://github.com/axios/axios) from 1.12.2 to 1.13.0.
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](https://github.com/axios/axios/compare/v1.12.2...v1.13.0)

---
updated-dependencies:
- dependency-name: axios
  dependency-version: 1.13.0
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-07 18:05:25 +01:00
dependabot[bot] db5dfb202f ⬆️ Bump vite from 7.1.11 to 7.1.12 (#4264)
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 7.1.11 to 7.1.12.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v7.1.12/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v7.1.12/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 7.1.12
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-07 18:03:29 +01:00
Ken 2795b7620b 📝 Adjust Datepicker validation example (#4261)
* 📝 Adjust example

* 📝 val -> validation name
2025-11-07 14:56:16 +01:00
github-actions[bot] 70e662dd3b Version Packages (#4260)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-11-07 14:05:14 +01:00
c7d6458b36 [Portal] Now respects render and mount order. (#4239)
* 🎉 Set ut new Portal-update

* 📝 Update Portal

* 🎉 Add prop-support to Portal

* 🧪 Portal stories

* 🔥 Removed asChild support from portal

* 📝 Changeset

* 🐛 Removed unused type-redeclaration

* Test this (needs cleanup)

* Update @navikt/core/react/src/portal/Portal.tests.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 Resolve rootElement order corretly

* 🔥 Removed ID

* 🧪 Test naming

* Apply suggestion from @KenAJoh

* ♻️ Remove no longer needed portalNode return

* 🐛 Add React import

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-11-06 13:44:25 +01:00
Ken aaf266637d 🐛 Stegaclean feedback-link 2025-11-06 12:46:41 +01:00
KenandHalvor Haugan 1ec451ee2c [FocusBoundary] Refactor initial/return-focus handling, added modal-prop (#4256)
* ♻️ Re-write of focus-handling in focusboundary

* ♻️ Added hideNonTargetElements to focusboundary

* 🐛 Make focus use animationFrame

* ⚡ Microtask focus-setting

* 🐛 add missing dep-array

* 🐛 return false instead of undefined

* 🐛 Update FocusBoundary story

* 🐛 Update Menu-stories

* 🐛 Default to true for initial focus and return-focus

* 🐛 Fix tests to avoid flaky results in CLI

* Apply suggestions from code review

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ Code cleanup

* ♻️ extracted fallback elements

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-11-06 11:48:22 +01:00
KenandHalvor Haugan 11af3e9a72 [DismissableLayer] Refactor layer handling (#4232)
* 🧪 Set ut tests for dismissablelayer

* 📝 todos

* 📝 Copy file

* ✨ Registering and un-registering of elements

* ✨ Added escapeEventHandler

* 🐛 Added enabled support

* ✨ Added pointerDownOutside handler

* 📝 Added enabled check

* 🐛 Removed dismissablelayer enabled toggle

* 🐛 Removed dismissablelayer enabled toggle

* 🧪 Fix edgecase for checking safezone tests

* 🐛 Fix outside events

* 🎉 Render dismissable-layer handlers only when enabled

* 📝 story update

* 🎉 Layer ordering

* 🚚 Rename file

* 🧪 Tests for sorting

* 🐛 removed legacy safezone attrb

* 📝 Test name update

* 🚚 Update docs for DismissableLayer

* 🐛 re-add test-stories

* 📝 story-prettier

* 📝 Docs

* 🔥 Removed re-export

* Update @navikt/core/react/src/overlays/dismissablelayer/DismissableLayer.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🏷️ Rename fored rerender call

* 🏷️ Rename pointer event check

* 🏷️ Enforce consistent naming

* 📝 re add comments

* 📝 re add comments

* 📝 Improved comment accuracy

* ♻️ Update function naming

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🧪 Update test-util to create unique divs

* 📝 Comment update

* 📝 Comment update

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-11-04 14:53:33 +01:00
dependabot[bot]andKen 8c05c4efdd ⬆️ Bump @vitejs/plugin-react from 4.4.1 to 5.1.0 (#4253)
* ⬆️ Bump @vitejs/plugin-react from 4.4.1 to 5.1.0

Bumps [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/tree/HEAD/packages/plugin-react) from 4.4.1 to 5.1.0.
- [Release notes](https://github.com/vitejs/vite-plugin-react/releases)
- [Changelog](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite-plugin-react/commits/plugin-react@5.1.0/packages/plugin-react)

---
updated-dependencies:
- dependency-name: "@vitejs/plugin-react"
  dependency-version: 5.1.0
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* 📝 Sync vitejs-react plugin

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-11-04 09:17:01 +01:00
github-actions[bot] dbb63dc0e9 Version Packages (#4238)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-11-03 12:28:20 +01:00
Halvor Haugan 7eb327d0d5 [website] Hide chips when only one example (#4255) 2025-11-03 11:55:24 +01:00
Halvor Haugan bd48881ece Adjust examples of Textarea (#4254) 2025-11-03 10:14:18 +01:00
Ken 26f9358bed ⬆️ React-dom now a peerDependency of @navikt/ds-react package (#4237)
* ⬆️ React-dom now a peerDependency of ds-react package

* 📝 Yarn lock sync

* 📝 Removed React 19 RC support

* 📝 Scoped homepages in package.json
2025-11-03 10:12:37 +01:00
dependabot[bot] 8ba6ae6f71 ⬆️ Bump the eslint group with 2 updates (#4249)
Bumps the eslint group with 2 updates: [@eslint/js](https://github.com/eslint/eslint/tree/HEAD/packages/js) and [eslint](https://github.com/eslint/eslint).


Updates `@eslint/js` from 9.38.0 to 9.39.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Commits](https://github.com/eslint/eslint/commits/v9.39.0/packages/js)

Updates `eslint` from 9.38.0 to 9.39.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Commits](https://github.com/eslint/eslint/compare/v9.38.0...v9.39.0)

---
updated-dependencies:
- dependency-name: "@eslint/js"
  dependency-version: 9.39.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: eslint
- dependency-name: eslint
  dependency-version: 9.39.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: eslint
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-03 09:41:35 +01:00
Halvor Haugan a8c44ad199 Disable actions-tab on Aksel Storybook (#4247) 2025-10-31 17:06:08 +01:00
Halvor Haugan 19fc768431 Add some missing types in "main" Storybook preview-file (#4246) 2025-10-31 17:04:33 +01:00
Halvor Haugan 420e3ab927 [website] Adjust examples of TextField (#4244) 2025-10-31 15:07:49 +01:00
KenandHalvor Haugan e51ae59d84 🐛 Timeline period dialogs now has accessible names (#4242)
* 🐛 Timeline period dialogs now has accessible names

* Update .changeset/full-terms-lie.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-10-31 14:11:26 +01:00
Ken 18baff33ad 📝 Actionmenu wity modal example (#4243) 2025-10-31 14:11:09 +01:00
KenandHalvor Haugan 61a52aa5dd [Process] New prop isTruncated (#4196)
* 🧪 set up views for Process line

* 🐛 Handle connectorplacement for dot-version

* 📝 Docs for use of connectorPlacement

* ♻️ Implement new connector prop for legacy

* 📝 Changeset

* 📝 Changeset edit

* 🐛 Use border-image unset instead of none to help with lightningcss minification

* Update .changeset/mean-insects-lick.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/pages/eksempler/process/connector.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Add connector-stories to chromatic

* 🎉 Update Process-prop from connectorPlacement -> isTruncated

* 📝 Update website docs for new isTruncated prop in Process

* Update aksel.nav.no/website/pages/eksempler/process/truncated.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-10-30 12:03:48 +01:00
github-actions[bot] 9625722ca7 Version Packages (#4236)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-10-30 09:57:40 +01:00
Julian Nymark c676565ab8 remove the ability for a fnr to become real. (#4230)
These FNR might not be valid in the first place (correct checksum), but they look like
they could be valid, rather than check each one, it's faster to
simply overwrite each one with an invalid day or month.

Why could a currently unused FNR suddenly become real? eg a valid FNR
(working checksum) set in the future _could_ end up being assigned to
a real future unborn person, and even a senior citizen could become
a norwegian citizen and even use a valid FNR from the past. Best to
avoid them entirely.

It's not a big probability, but better safe than sorry.
setting the month to 99 makes them so they would never be issued (similar to what Dolly
does).
2025-10-30 09:57:19 +01:00
Halvor Haugan 6e2e744f8e [website] Use Node 24 docker image (#4235) 2025-10-29 16:58:25 +01:00
dependabot[bot] f89b296903 ⬆️ Bump the storybook group with 9 updates (#4220)
Bumps the storybook group with 9 updates:

| Package | From | To |
| --- | --- | --- |
| [@storybook/addon-a11y](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/a11y) | `9.1.8` | `9.1.15` |
| [@storybook/addon-docs](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/docs) | `9.1.8` | `9.1.15` |
| [@storybook/addon-themes](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/themes) | `9.1.8` | `9.1.15` |
| [@storybook/addon-vitest](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/vitest) | `9.1.10` | `9.1.15` |
| [@storybook/nextjs](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/nextjs) | `9.1.8` | `9.1.15` |
| [@storybook/react-vite](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/react-vite) | `9.1.8` | `9.1.15` |
| [eslint-plugin-storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/eslint-plugin) | `9.1.8` | `9.1.15` |
| [storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/core) | `9.1.8` | `9.1.15` |
| [storybook-addon-pseudo-states](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/pseudo-states) | `9.1.8` | `9.1.15` |


Updates `@storybook/addon-a11y` from 9.1.8 to 9.1.15
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v9.1.15/code/addons/a11y)

Updates `@storybook/addon-docs` from 9.1.8 to 9.1.15
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v9.1.15/code/addons/docs)

Updates `@storybook/addon-themes` from 9.1.8 to 9.1.15
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v9.1.15/code/addons/themes)

Updates `@storybook/addon-vitest` from 9.1.10 to 9.1.15
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v9.1.15/code/addons/vitest)

Updates `@storybook/nextjs` from 9.1.8 to 9.1.15
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v9.1.15/code/frameworks/nextjs)

Updates `@storybook/react-vite` from 9.1.8 to 9.1.15
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v9.1.15/code/frameworks/react-vite)

Updates `eslint-plugin-storybook` from 9.1.8 to 9.1.15
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v9.1.15/code/lib/eslint-plugin)

Updates `storybook` from 9.1.8 to 9.1.15
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v9.1.15/code/core)

Updates `storybook-addon-pseudo-states` from 9.1.8 to 9.1.15
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v9.1.15/code/addons/pseudo-states)

---
updated-dependencies:
- dependency-name: "@storybook/addon-a11y"
  dependency-version: 9.1.15
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-docs"
  dependency-version: 9.1.15
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-themes"
  dependency-version: 9.1.15
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-vitest"
  dependency-version: 9.1.15
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/nextjs"
  dependency-version: 9.1.15
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react-vite"
  dependency-version: 9.1.15
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: eslint-plugin-storybook
  dependency-version: 9.1.15
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: storybook
  dependency-version: 9.1.15
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: storybook-addon-pseudo-states
  dependency-version: 9.1.15
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-29 16:35:31 +01:00
dependabot[bot]andKen f0b37d6cef ⬆️ Bump jsdom from 26.1.0 to 27.0.1 (#4221)
* ⬆️ Bump jsdom from 26.1.0 to 27.0.1

Bumps [jsdom](https://github.com/jsdom/jsdom) from 26.1.0 to 27.0.1.
- [Release notes](https://github.com/jsdom/jsdom/releases)
- [Changelog](https://github.com/jsdom/jsdom/blob/main/Changelog.md)
- [Commits](https://github.com/jsdom/jsdom/compare/26.1.0...27.0.1)

---
updated-dependencies:
- dependency-name: jsdom
  dependency-version: 27.0.1
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* ⬆️ Sync jsdom-versions across repo

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-10-29 16:30:30 +01:00
8ea60dc24f Scroll lock utility (#4234)
* ✨ Added scrolllock utility

* 🎉 UseScrollLock story

* ♻️ Use scrolllock utility in Modal

* 📝 Changeset

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Update changeset

* 📝 Added className to list of styellint className deprecations

* 🔥 removed double negative negation

* 📝 Story-docs

* Update @navikt/core/react/src/util/hooks/useScrollLock.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Document body style overrides

* 📝 Docs

* ♻️ Cleanup redundant fn

* ♻️ better naming

* 📝 Docs

* 🔥 removed test-case in story that cant work

* 📝 Update docs

* 📝 Update docs

* 🔥 removed comment

* 🎉 Re-added bodylockscroll support for backwards compat

* 🎉 Re-added class to css, removed updated aksel prefix css

* Update @navikt/core/react/src/util/hooks/useScrollLock.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/util/hooks/useScrollLock.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🧪 Demo story

* 🧪 Demo story

* iOS comment adjustments

* Apply suggestion from @KenAJoh

* Apply suggestion from @KenAJoh

* 📝 Changeset

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2025-10-29 16:28:11 +01:00
Halvor Haugan 107cf1cb2a Import fs and path explicitly from node (#4233) 2025-10-29 15:36:11 +01:00
github-actions[bot] 21a8de2326 Version Packages (#4214)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-10-29 11:54:38 +01:00
Halvor Haugan 4365a6c764 Combobox: Fix issue with toggle list button (#4228) 2025-10-28 11:41:46 +01:00
Halvor Haugan 87b085df2d Storybook: Fix story naming in Chromatic for templates (#4226) 2025-10-27 13:17:23 +01:00
Halvor Haugan c962a16b19 Adjust Slack feedback text (#4217) 2025-10-27 09:53:22 +01:00
dependabot[bot] 92793afd7f ⬆️ Bump esbuild from 0.25.10 to 0.25.11 (#4222)
Bumps [esbuild](https://github.com/evanw/esbuild) from 0.25.10 to 0.25.11.
- [Release notes](https://github.com/evanw/esbuild/releases)
- [Changelog](https://github.com/evanw/esbuild/blob/main/CHANGELOG.md)
- [Commits](https://github.com/evanw/esbuild/compare/v0.25.10...v0.25.11)

---
updated-dependencies:
- dependency-name: esbuild
  dependency-version: 0.25.11
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-27 09:46:43 +01:00
dependabot[bot] ca75754607 ⬆️ Bump actions/upload-artifact from 4 to 5 (#4224)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4 to 5.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-27 09:46:15 +01:00
dependabot[bot] ef8e32b499 ⬆️ Bump actions/download-artifact from 5 to 6 (#4225)
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 5 to 6.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](https://github.com/actions/download-artifact/compare/v5...v6)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-27 09:46:00 +01:00
Halvor Haugan 6e522b9d3a Tests: Fix warnings about act (#4218) 2025-10-27 09:30:18 +01:00
Halvor Haugan 26595dba73 Fix Chromatic bug in FormNavigationSimple.tsx 2025-10-24 15:56:05 +02:00
Ken aab22428e8 🎉 Update Accordion-header size (#4209)
* 🎉 Update Accordion-header size

* Apply suggestion from @KenAJoh
2025-10-24 15:05:40 +02:00
Ken 19ab7b7471 🐛 Add templates to chromatic build 2025-10-24 11:48:47 +02:00
KenandHalvor Haugan f6cefbe422 🎉 Update templates for form navigation (#4194)
* 🎉 Update templates for form navigation

* 🐛 Revert to correct icon

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/components/website-modules/examples/__parts-inline/FormNavigationSimple.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-10-24 11:17:53 +02:00
Ken d2964d3d3f ✨ Sync BodyShort size large line-height with figma (#4213)
* ✨ Sync BodyShort size large line-height with figma

* 🐛 Add line-height change to legacy css
2025-10-23 12:16:06 +02:00
Ken ee44d33d52 [Draft mode] Disable draft-mode in all tabs when stopping draft-mode (#4193)
* 🎉 Use Broadcast-channels to update draft-mode

* 🔥 removed console.log
2025-10-21 19:41:42 +02:00
dependabot[bot] 8552229bbf ⬆️ Bump vite in the npm_and_yarn group across 1 directory (#4211)
Bumps the npm_and_yarn group with 1 update in the / directory: [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).


Updates `vite` from 7.1.7 to 7.1.11
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v7.1.11/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 7.1.11
  dependency-type: direct:development
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-21 14:07:06 +02:00
dependabot[bot] 3243a0d35e ⬆️ Bump the npm_and_yarn group across 3 directories with 1 update (#4212)
Bumps the npm_and_yarn group with 1 update in the /examples/astro directory: [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).
Bumps the npm_and_yarn group with 1 update in the /examples/referansesider directory: [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).
Bumps the npm_and_yarn group with 1 update in the /examples/shadow-dom directory: [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).


Updates `vite` from 6.3.6 to 6.4.1
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/create-vite@6.4.1/packages/vite)

Updates `vite` from 6.3.6 to 6.4.1
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/create-vite@6.4.1/packages/vite)

Updates `vite` from 6.3.6 to 6.4.1
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/create-vite@6.4.1/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 6.4.1
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: vite
  dependency-version: 6.4.1
  dependency-type: direct:development
  dependency-group: npm_and_yarn
- dependency-name: vite
  dependency-version: 6.4.1
  dependency-type: direct:development
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-21 14:04:35 +02:00
KenandCopilot 86f353bbd9 [Overlay] Mark other elements as aria-hidden while overlay is open (#4181)
* ✨ Added aria-hidden utility

* 🧪 Generated tests

* 🧪 Generated test for shadow-root

* Update @navikt/core/react/src/util/markOtherElements.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 🏷️ Rename undoFn

* 🧪 Check target attributes

* ⚡ Simplified node children looping

* 🏷️ Rename variables

* ♻️ Removed non-modal implementation

* ♻️ Simplify flexibilty for attributes to hardcoded values

* ♻️ inert -> hidden

* 🧪 Added nested test

* 🏷️ Inline use of ariaHiddenCounter

* 🏷️ Rename markermap -> markerCounter

* ⚡ Rename function, optimize cleanup loop and add comments

* 📝 Comment update

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-10-21 13:31:13 +02:00
Ken ba44c5b9d2 🧪 Fix running of named tests with silent flag 2025-10-20 11:02:49 +02:00
Ken 460fc2fb54 📝 Update card example for skeleton (#4199)
* 📝 update card example for skeleton

* ♻️ Remove color override since opacity handles it
2025-10-20 09:42:39 +02:00
dependabot[bot]andKen 24846a7013 ⬆️ Bump postcss-import from 14.1.0 to 16.1.1 (#4204)
* ⬆️ Bump postcss-import from 14.1.0 to 16.1.1

Bumps [postcss-import](https://github.com/postcss/postcss-import) from 14.1.0 to 16.1.1.
- [Release notes](https://github.com/postcss/postcss-import/releases)
- [Changelog](https://github.com/postcss/postcss-import/blob/master/CHANGELOG.md)
- [Commits](https://github.com/postcss/postcss-import/compare/14.1.0...16.1.1)

---
updated-dependencies:
- dependency-name: postcss-import
  dependency-version: 16.1.1
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* ⬆️ Update postcss-import across workspace

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-10-20 09:42:22 +02:00
dependabot[bot] 3668f01a06 ⬆️ Bump @eslint/plugin-kit (#4208)
Bumps the npm_and_yarn group with 1 update in the /examples/referansesider directory: [@eslint/plugin-kit](https://github.com/eslint/rewrite/tree/HEAD/packages/plugin-kit).


Updates `@eslint/plugin-kit` from 0.3.2 to 0.4.0
- [Release notes](https://github.com/eslint/rewrite/releases)
- [Changelog](https://github.com/eslint/rewrite/blob/main/packages/plugin-kit/CHANGELOG.md)
- [Commits](https://github.com/eslint/rewrite/commits/core-v0.4.0/packages/plugin-kit)

---
updated-dependencies:
- dependency-name: "@eslint/plugin-kit"
  dependency-version: 0.4.0
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-20 09:41:36 +02:00
dependabot[bot]andKen fcb818cf3b ⬆️ Bump actions/setup-node from 5 to 6 (#4207)
* ⬆️ Bump actions/setup-node from 5 to 6

Bumps [actions/setup-node](https://github.com/actions/setup-node) from 5 to 6.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v5...v6)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* 📝 sync setup-node to v6

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-10-20 09:40:53 +02:00
dependabot[bot] ece13689ae ⬆️ Bump actions/download-artifact from 4 to 5 (#4206)
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 4 to 5.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](https://github.com/actions/download-artifact/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-20 09:26:26 +02:00
dependabot[bot] 4f13f4af03 ⬆️ Bump docker/build-push-action from 5 to 6 (#4205)
Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 5 to 6.
- [Release notes](https://github.com/docker/build-push-action/releases)
- [Commits](https://github.com/docker/build-push-action/compare/v5...v6)

---
updated-dependencies:
- dependency-name: docker/build-push-action
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-20 09:25:13 +02:00
dependabot[bot] d3cf7b1562 ⬆️ Bump @figma/rest-api-spec from 0.30.0 to 0.34.0 (#4203)
Bumps [@figma/rest-api-spec](https://github.com/figma/rest-api-spec) from 0.30.0 to 0.34.0.
- [Commits](https://github.com/figma/rest-api-spec/commits/v0.34.0)

---
updated-dependencies:
- dependency-name: "@figma/rest-api-spec"
  dependency-version: 0.34.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-20 09:12:57 +02:00
dependabot[bot]andKen 012280a71b ⬆️ Bump the eslint group with 2 updates (#4201)
* ⬆️ Bump the eslint group with 2 updates

Bumps the eslint group with 2 updates: [@eslint/js](https://github.com/eslint/eslint/tree/HEAD/packages/js) and [eslint](https://github.com/eslint/eslint).


Updates `@eslint/js` from 9.37.0 to 9.38.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Commits](https://github.com/eslint/eslint/commits/v9.38.0/packages/js)

Updates `eslint` from 9.37.0 to 9.38.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Commits](https://github.com/eslint/eslint/compare/v9.37.0...v9.38.0)

---
updated-dependencies:
- dependency-name: "@eslint/js"
  dependency-version: 9.38.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: eslint
- dependency-name: eslint
  dependency-version: 9.38.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: eslint
...

Signed-off-by: dependabot[bot] <support@github.com>

* ⬆️ Update eslint across workspace

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-10-20 09:09:36 +02:00
github-actions[bot] d25848494e Version Packages (#4198)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-10-20 09:06:48 +02:00
Ken 71580f3d11 ⬆️ Update sanity version (#4192) 2025-10-17 18:17:11 +02:00
Ken db055ae693 🎉 Update Robot icon (#4200) 2025-10-17 18:16:27 +02:00
Ken fd7a75be06 🐛 Replace div inside label with span (#4184) 2025-10-17 18:03:01 +02:00
Ken c81858437d [Linting] Treat useClientLayoutEffect as a regular React-effect (#4191)
* 🎉 Check for deps in 'useClientLayoutEffect'

* ♻️ Update dependency arrays

* 📝 changeset

* 🏷️ Remove on mount effect from depending on react Dispatch functioN
2025-10-17 14:55:27 +02:00
Halvor Haugan 81d162c4d0 [website] Adjust examples of Skeleton (#4197) 2025-10-17 14:31:09 +02:00
Halvor Haugan 5ec5d4e32e Combobox: Fix bug in highlighting when using custom filtering logic (#4195) 2025-10-17 13:29:07 +02:00
Ken 8520ffdfa1 [e2e] Sharded playwright workflow (#4168)
* 🔥 No need to log that users without loging creds are missing token

* ⚡ Sharded playwright workflow

* 🐛 Add permissions

* 🐛 Run yarn install before playwright shards

* 🐛 Install yarn before running playwright

* 🐛 Sync playwright versions

* 🐛 Add webserver config to playwright run

* 🐛 Test changing service-container name

* 🐛 Try running service-container with env-variables

* 🧪 Try removing upgrade request

* 🧪 Try using image-name in url

* 🔥 Removed temp tests

* 🐛 Try hardcoding testapp path

* 🐛 Page goto relative path

* 🔥 Removed node-setup in merge

* 🎉 Fixed blog-upload, added mobile e2e

* 🐛 Test different base-path

* 🐛 Use service-container name

* 🐛 remove name prefix

* 🐛 Try removing http

* 🐛 Try using https

* 🐛 try re-adding tokens

* 🐛 Try hardcoding path

* 🐛 Rename to testapp

* 🎉 Remove e2e test shortening

* ⚡ Test increasing workers to 2 in CI

* ♻️ Clean up old e2e scripts

* 🐛 Use dev-server when testing locally

* ♿ Correct headlig-levels for component intros

* 🔥 Removed legacy exclusion

* 🔥 No need to checkout repo on run

* 🧪 Test for mobile webkit instead of mobile chrome
2025-10-17 09:29:08 +02:00
github-actions[bot] 230b0944e8 Version Packages (#4164)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-10-15 16:35:20 +02:00
KenandHalvor Haugan 4e87e3caca [Sanity] Preview mode updates (#4165)
* 🐛 Allow for disabling visualediting component in preview

* 🚚 Remove perspective query from edit-links in VisualEditing-mode

* 🐛 Fix CSP issues, avatar resolve

* 🔥 removed redundant externalStorage hook

* Update aksel.nav.no/website/app/_ui/draft-overlay/DraftOverlay.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/app/_ui/draft-overlay/DraftOverlay.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-10-15 16:26:56 +02:00
44f5d07929 [Overlay] FocusBoundary utility extracted from Drawer PR (#4160)
* 🚚 Moved FocusScope and connected hooks

* 🎉 setup tests for focusscope

* ♻️ Story tests utilities

* ♻️ More test-code

* ♻️ Early returns

* ♻️ Refactor trapped handler

* ♻️ Update key event handler

* 📝 Better docs for FocusScope

* ♻️ Replace old FocusScope with new implementation

* 🚚 Rename FocusScope to FocusBoundary

* Update @navikt/core/react/src/util/focus-boundary/FocusBoundary.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update @navikt/core/react/src/util/focus-boundary/FocusBoundary.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 🐛 Update import

* 📝 TODOs

* Update @navikt/core/react/src/util/focus-boundary/FocusBoundary.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/util/focus-boundary/FocusBoundary.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 Avoid early return

* 🐛 Test correct close button

* 📝 comments

* 📝 comments

* ♻️ Add autoComplete off to demo

* 📝 comments

* 📝 comments

* 🧪 Added playground demo

* 🐛 Check for valid intialRef before focusing it

* 📝 Comments

* 📝 Comments

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-10-15 16:26:49 +02:00
Halvor Haugan dcb2641add Textarea: Break spaces (#4182) 2025-10-14 16:47:37 +02:00
dependabot[bot] 86fc3cfb29 ⬆️ Bump prettier from 3.1.1 to 3.6.2 (#4178)
Bumps [prettier](https://github.com/prettier/prettier) from 3.1.1 to 3.6.2.
- [Release notes](https://github.com/prettier/prettier/releases)
- [Changelog](https://github.com/prettier/prettier/blob/main/CHANGELOG.md)
- [Commits](https://github.com/prettier/prettier/compare/3.1.1...3.6.2)

---
updated-dependencies:
- dependency-name: prettier
  dependency-version: 3.6.2
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-14 12:25:09 +02:00
dependabot[bot] 059f591fc2 ⬆️ Bump @testing-library/dom from 10.4.0 to 10.4.1 (#4177)
Bumps [@testing-library/dom](https://github.com/testing-library/dom-testing-library) from 10.4.0 to 10.4.1.
- [Release notes](https://github.com/testing-library/dom-testing-library/releases)
- [Changelog](https://github.com/testing-library/dom-testing-library/blob/main/CHANGELOG.md)
- [Commits](https://github.com/testing-library/dom-testing-library/compare/v10.4.0...v10.4.1)

---
updated-dependencies:
- dependency-name: "@testing-library/dom"
  dependency-version: 10.4.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-14 12:24:39 +02:00
KenandHalvor Haugan e7775c8b0c 🎉 Added FocusGuard utility (#4170)
* 🎉 Added FocusGuard utility

* 📝 Added story explaining the use of useFocusGuard

* ♻️ Remove redundant isSafari-handling of focusguard

* Update @navikt/core/react/src/util/hooks/Hooks.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ Re-write focusGuard to use React

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-10-14 09:07:29 +02:00
Halvor Haugan adc4f07a26 Remove link styles from examples.module.css (#4180) 2025-10-13 12:09:26 +02:00
dependabot[bot] 58200023dc ⬆️ Bump astro (#4174)
Bumps the npm_and_yarn group with 1 update in the /examples/astro directory: [astro](https://github.com/withastro/astro/tree/HEAD/packages/astro).


Updates `astro` from 5.13.2 to 5.14.3
- [Release notes](https://github.com/withastro/astro/releases)
- [Changelog](https://github.com/withastro/astro/blob/main/packages/astro/CHANGELOG.md)
- [Commits](https://github.com/withastro/astro/commits/astro@5.14.3/packages/astro)

---
updated-dependencies:
- dependency-name: astro
  dependency-version: 5.14.3
  dependency-type: direct:production
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-13 09:51:18 +02:00
dependabot[bot] 7d52d78a38 ⬆️ Bump prettier-plugin-tailwindcss from 0.6.11 to 0.6.14 (#4179)
Bumps [prettier-plugin-tailwindcss](https://github.com/tailwindlabs/prettier-plugin-tailwindcss) from 0.6.11 to 0.6.14.
- [Release notes](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/releases)
- [Changelog](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/blob/main/CHANGELOG.md)
- [Commits](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/compare/v0.6.11...v0.6.14)

---
updated-dependencies:
- dependency-name: prettier-plugin-tailwindcss
  dependency-version: 0.6.14
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-13 09:50:06 +02:00
Ken 51b3c714a3 [Utils] Extracted utils from Overlay PR (#4143)
* 🎉 Added browser API utils

* ♻️ Updated owner

* ♻️ Use ownerdocument util

* ♻️ Added timeout hook

* 🐛 Update imports

* ♻️ Update use of window

* ♻️ Progressbar timeout

* 🎉 Animate height timeout

* ♻️ Use new timeout-func in debounce

* ♻️ Use new timeout-func in useToggleItem

* ⬅️ Revert animationFrame use

* ♻️ Clean up use in debounce

* 🔥 removed unused utility

* 🏷️ Removed extra ts type

* 🔥 removed reduntant clear in debounce

* ♻️ Inline clear

* 📝 Document use of owner.ts

* 📝 Timeout clear cleanup
2025-10-09 12:31:33 +02:00
Ken b615d21a27 🐛 Avoid screen-readers announcing helptext title twice (#4169) 2025-10-09 12:06:48 +02:00
Halvor Haugan 5adde847be Adjust exampels of MonthPicker (#4167) 2025-10-08 15:44:07 +02:00
dependabot[bot]andKen a29320821a ⬆️ Bump typescript from 5.8.3 to 5.9.3 (#4153)
* ⬆️ Bump typescript from 5.8.3 to 5.9.3

Bumps [typescript](https://github.com/microsoft/TypeScript) from 5.8.3 to 5.9.3.
- [Release notes](https://github.com/microsoft/TypeScript/releases)
- [Changelog](https://github.com/microsoft/TypeScript/blob/main/azure-pipelines.release-publish.yml)
- [Commits](https://github.com/microsoft/TypeScript/compare/v5.8.3...v5.9.3)

---
updated-dependencies:
- dependency-name: typescript
  dependency-version: 5.9.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* 📝 Sync ts versions across monorepo

* 🏷️ Fix type-errors after update to ts 5.9.3

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-10-08 15:17:41 +02:00
Ken 2d42a5025d [Website] Speed up build (#4166)
* ⬆️ Update playroom

* 🔥 Removed old searchIndex code, run next build concurrently

* ⚡ Add sanity to optimized packages

* 🔥 Removed searchindex entry
2025-10-08 15:11:20 +02:00
Ken 910ddea67f 🐛 Update doc-formating for PageBlock 2025-10-08 15:08:10 +02:00
dependabot[bot]andKen c95b9d3c89 ⬆️ Bump @floating-ui/react-dom from 2.1.2 to 2.1.6 (#4154)
* ⬆️ Bump @floating-ui/react-dom from 2.1.2 to 2.1.6

Bumps [@floating-ui/react-dom](https://github.com/floating-ui/floating-ui/tree/HEAD/packages/react-dom) from 2.1.2 to 2.1.6.
- [Release notes](https://github.com/floating-ui/floating-ui/releases)
- [Changelog](https://github.com/floating-ui/floating-ui/blob/master/packages/react-dom/CHANGELOG.md)
- [Commits](https://github.com/floating-ui/floating-ui/commits/@floating-ui/react-dom@2.1.6/packages/react-dom)

---
updated-dependencies:
- dependency-name: "@floating-ui/react-dom"
  dependency-version: 2.1.6
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* 📝 Changeset

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-10-08 14:45:35 +02:00
dependabot[bot] 006934dd9b ⬆️ Bump peter-evans/find-comment from 3 to 4 (#4155)
Bumps [peter-evans/find-comment](https://github.com/peter-evans/find-comment) from 3 to 4.
- [Release notes](https://github.com/peter-evans/find-comment/releases)
- [Commits](https://github.com/peter-evans/find-comment/compare/v3...v4)

---
updated-dependencies:
- dependency-name: peter-evans/find-comment
  dependency-version: '4'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-08 14:39:45 +02:00
dependabot[bot] 3e5ebce789 ⬆️ Bump peter-evans/create-or-update-comment from 4 to 5 (#4156)
Bumps [peter-evans/create-or-update-comment](https://github.com/peter-evans/create-or-update-comment) from 4 to 5.
- [Release notes](https://github.com/peter-evans/create-or-update-comment/releases)
- [Commits](https://github.com/peter-evans/create-or-update-comment/compare/v4...v5)

---
updated-dependencies:
- dependency-name: peter-evans/create-or-update-comment
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-08 14:38:40 +02:00
Ken 7ad588a573 [Aksel.nav.no] Uses searchparams for global search (#4146)
* 🎉 Sync global search based on query

* ♻️ Handle open/close state better

* 🎉 Properly update input state

* ♻️ Extract param logic to utility-hook

* ⚡ simplify form select

* 🔥 removed redundant comment

* ⚡ Removed redundant memo

* ⚡ Moved search to suspense

* 🎉 Suspense is now limited to within search, allowing button to render on mount

* ♻️ clean up global search views

* 🐛 Reset search on closebutton click

* ⚡ Make sure to clean up debounce call on unMount

* 🔥 Removed unnecesarry ternary
2025-10-08 14:37:47 +02:00
KenandHalvor Haugan 182753c8d2 [Vitest] Run storybook tests in CI (#4163)
* 🎉 Run only local stories, not node_modules

* 🚚 Move test-config to separate dir

* 🎉 Added UI-tests to CI action

* 🐛 Fix test-command used in action

* 📝 rename action

* 🐛 Add storybook command with CI-flag

* 🧪 Add forced file paralellism

* ⚡ only test play-fn tests

* 🔥 Remove a11y annotation

* 🔥 Cleanup after fixing performance

* 🐛 Allow test-runner widget to run without crash

* Update .storybook/main.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Name update

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-10-08 14:33:31 +02:00
Halvor Haugan da5229a011 [website] Fix warning about multiple elements in <title> 2025-10-08 09:10:44 +02:00
Ken 21b30d20ef [Combobox] Now remains open when navigating with voiceover in "quick-nav"-mode (#4158)
* 🎉 Use Dismissiblelayer for closing combobox

* 🐛 Avoid closing on escape

* ⬅️ Revert test story

* 📝 Changeset
2025-10-07 16:55:10 +02:00
dependabot[bot] aff72dc86e ⬆️ Bump the eslint group with 2 updates (#4150)
Bumps the eslint group with 2 updates: [@eslint/js](https://github.com/eslint/eslint/tree/HEAD/packages/js) and [eslint](https://github.com/eslint/eslint).


Updates `@eslint/js` from 9.36.0 to 9.37.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Commits](https://github.com/eslint/eslint/commits/v9.37.0/packages/js)

Updates `eslint` from 9.36.0 to 9.37.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Commits](https://github.com/eslint/eslint/compare/v9.36.0...v9.37.0)

---
updated-dependencies:
- dependency-name: "@eslint/js"
  dependency-version: 9.37.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: eslint
- dependency-name: eslint
  dependency-version: 9.37.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: eslint
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-07 16:20:08 +02:00
Ken 40958cd6e5 Revert "🔥 Removed NPM-token needed for publish to npm (#4159)" (#4162)
This reverts commit ba4707a277.
2025-10-07 14:51:54 +02:00
github-actions[bot] 8335327ab4 Version Packages (#4161)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-10-07 14:39:17 +02:00
Halvor Haugan 61bb22580b Darkside: Adjustments for DatePicker on very small devices (#4142) 2025-10-07 14:35:07 +02:00
Ken ba4707a277 🔥 Removed NPM-token needed for publish to npm (#4159) 2025-10-07 13:45:53 +02:00
Ken a57f05810e 🐛 Format example-texts for PageBlock component JsDoc 2025-10-06 15:46:18 +02:00
github-actions[bot] 8affd0804b Version Packages (#4119)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-10-06 15:43:36 +02:00
Halvor Haugan 73d4d6520e [website] Remove null values from writers array (#4144) 2025-10-06 09:39:55 +02:00
Halvor Haugan 3325ca0ea6 Make mergeRefs ready for React 19 (#4149) 2025-10-06 09:39:05 +02:00
Ken 822c5a30ed 🐛 Avoid client error on disconnect (#4141) 2025-10-02 11:41:15 +02:00
Ken ac36bba170 🔍 Added logging (#4140) 2025-10-02 11:37:41 +02:00
Ken ca4880ee16 [Icons] New icons (#4115)
* 🎉 Added new icons

* 📝 Synced icon-descriptions with Figma

* 📝 changeset updates

* 📝 Sync icon descriptions

* 🐛 Date updates
2025-10-02 09:22:18 +02:00
KenandHalvor Haugan f32e5c36c3 🎉 Updated storybook to v9 (#4134)
* 🎉 Updated storybook to v9

* 🐛 Resolve story-types

* Update aksel.nav.no/website/.storybook/preview.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🔥 Removed old controls

* ♻️ Use built in theme classname switch

* 🐛 Fix theme-switch toolbar

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-10-02 09:22:11 +02:00
dependabot[bot] 014c951346 ⬆️ Bump axios in the npm_and_yarn group across 1 directory (#4137)
Bumps the npm_and_yarn group with 1 update in the / directory: [axios](https://github.com/axios/axios).


Updates `axios` from 1.12.1 to 1.12.2
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](https://github.com/axios/axios/compare/v1.12.1...v1.12.2)

---
updated-dependencies:
- dependency-name: axios
  dependency-version: 1.12.2
  dependency-type: direct:production
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-30 14:35:41 +02:00
dependabot[bot] dd6d225f80 ⬆️ Bump axios in the npm_and_yarn group across 1 directory (#4133)
Bumps the npm_and_yarn group with 1 update in the / directory: [axios](https://github.com/axios/axios).


Updates `axios` from 1.12.0 to 1.12.1
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](https://github.com/axios/axios/compare/v1.12.0...v1.12.1)

---
updated-dependencies:
- dependency-name: axios
  dependency-version: 1.12.1
  dependency-type: direct:production
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-30 14:28:09 +02:00
Halvor Haugan d311ba90ea [website] Adjust Slack feedback text 2025-09-30 13:22:59 +02:00
Halvor Haugan f6f778b971 Prepare timeline.stories.tsx for React 19 (#4135) 2025-09-30 09:46:26 +02:00
Halvor Haugan a683001372 [website] Update link about tokens (#4136) 2025-09-30 09:43:15 +02:00
Ken d8a2c8f41f 🐛 Added React import to theme templates 2025-09-30 09:30:12 +02:00
Halvor HauganandKen 2e07bc2d97 [Sanity] Validate heading levels (#4131)
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-09-29 14:07:30 +02:00
d9a1363f5e [Templates] Added examples for theme-button (#4046)
* ✨ Set up first-draft for theme-switch pattern

* ✨ Added templates without system-setting

* ♻️ Remove redundant code

* Update aksel.nav.no/website/pages/templates/theme-switch/uten-system-bare-ikon.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/pages/templates/theme-switch/uten-system-bare-ikon.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ Theme middleware to handle theme-templates and communication to root app theme

* remove provider

* Update aksel.nav.no/website/pages/templates/theme-switch/tekst.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/pages/templates/theme-switch/tekst.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/pages/templates/theme-switch/bare-ikon.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/pages/templates/theme-switch/bare-ikon.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/pages/templates/theme-switch/tekst.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/pages/templates/theme-switch/bare-ikon.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/components/website-modules/examples/withDsExample.theme.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/pages/templates/theme-switch/bare-ikon.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 yarn lock sync

* 🐛 Avoid server/client CSS out of sync

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2025-09-29 12:53:05 +02:00
Halvor Haugan eade1aa7b6 yarn.lock sync 2025-09-29 12:41:41 +02:00
dependabot[bot] 16cd3e5c82 ⬆️ Bump stylelint from 16.19.1 to 16.24.0 (#4130)
Bumps [stylelint](https://github.com/stylelint/stylelint) from 16.19.1 to 16.24.0.
- [Release notes](https://github.com/stylelint/stylelint/releases)
- [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint/compare/16.19.1...16.24.0)

---
updated-dependencies:
- dependency-name: stylelint
  dependency-version: 16.24.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-29 11:55:26 +02:00
dependabot[bot] 45d666ce78 ⬆️ Bump the npm_and_yarn group across 1 directory with 4 updates (#4125)
Bumps the npm_and_yarn group with 4 updates in the / directory: [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite), [esbuild](https://github.com/evanw/esbuild), [axios](https://github.com/axios/axios) and [tar-fs](https://github.com/mafintosh/tar-fs).


Updates `vite` from 6.3.6 to 7.0.7
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v7.0.7/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v7.0.7/packages/vite)

Updates `esbuild` from 0.25.9 to 0.25.10
- [Release notes](https://github.com/evanw/esbuild/releases)
- [Changelog](https://github.com/evanw/esbuild/blob/main/CHANGELOG.md)
- [Commits](https://github.com/evanw/esbuild/compare/v0.25.9...v0.25.10)

Updates `axios` from 1.9.0 to 1.12.0
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](https://github.com/axios/axios/compare/v1.9.0...v1.12.0)

Updates `tar-fs` from 2.1.3 to 2.1.4
- [Commits](https://github.com/mafintosh/tar-fs/compare/v2.1.3...v2.1.4)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 7.0.7
  dependency-type: direct:development
  dependency-group: npm_and_yarn
- dependency-name: esbuild
  dependency-version: 0.25.10
  dependency-type: direct:development
  dependency-group: npm_and_yarn
- dependency-name: axios
  dependency-version: 1.12.0
  dependency-type: direct:production
  dependency-group: npm_and_yarn
- dependency-name: tar-fs
  dependency-version: 2.1.4
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-29 11:54:13 +02:00
dependabot[bot]andKen 89af04974e ⬆️ Bump the npm_and_yarn group across 2 directories with 3 updates (#4124)
* ⬆️ Bump the npm_and_yarn group across 2 directories with 3 updates

Bumps the npm_and_yarn group with 1 update in the /@navikt/aksel directory: [axios](https://github.com/axios/axios).
Bumps the npm_and_yarn group with 2 updates in the /examples/astro directory: [devalue](https://github.com/sveltejs/devalue) and [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).


Updates `axios` from 1.9.0 to 1.12.0
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](https://github.com/axios/axios/compare/v1.9.0...v1.12.0)

Updates `devalue` from 5.1.1 to 5.3.2
- [Release notes](https://github.com/sveltejs/devalue/releases)
- [Changelog](https://github.com/sveltejs/devalue/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sveltejs/devalue/compare/v5.1.1...v5.3.2)

Updates `vite` from 6.3.5 to 6.3.6
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v6.3.6/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v6.3.6/packages/vite)

---
updated-dependencies:
- dependency-name: axios
  dependency-version: 1.12.0
  dependency-type: direct:production
  dependency-group: npm_and_yarn
- dependency-name: devalue
  dependency-version: 5.3.2
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: vite
  dependency-version: 6.3.6
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>

* 📝 yarn lock sync

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-09-29 11:51:19 +02:00
Halvor Haugan e9f703eb9a [website] Adjust DatePicker examples (#4121) 2025-09-29 11:50:41 +02:00
Halvor Haugan c994ee793f Darkside: Adjust GuidePanel arrow position (#4120) 2025-09-29 11:48:50 +02:00
dependabot[bot]andKen 331eca903d ⬆️ Bump tsx from 4.19.4 to 4.20.6 (#4128)
* ⬆️ Bump tsx from 4.19.4 to 4.20.6

Bumps [tsx](https://github.com/privatenumber/tsx) from 4.19.4 to 4.20.6.
- [Release notes](https://github.com/privatenumber/tsx/releases)
- [Changelog](https://github.com/privatenumber/tsx/blob/master/release.config.cjs)
- [Commits](https://github.com/privatenumber/tsx/compare/v4.19.4...v4.20.6)

---
updated-dependencies:
- dependency-name: tsx
  dependency-version: 4.20.6
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* ⬆️ Sync 'tsx' dep update

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-09-29 11:46:35 +02:00
Halvor Haugan 541b3a190d Fix some React 19 type errors (#4122) 2025-09-29 11:31:46 +02:00
dependabot[bot] d9fb9c66c2 ⬆️ Bump the eslint group with 2 updates (#4126)
Bumps the eslint group with 2 updates: [@eslint/js](https://github.com/eslint/eslint/tree/HEAD/packages/js) and [eslint](https://github.com/eslint/eslint).


Updates `@eslint/js` from 9.35.0 to 9.36.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/commits/v9.36.0/packages/js)

Updates `eslint` from 9.35.0 to 9.36.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.35.0...v9.36.0)

---
updated-dependencies:
- dependency-name: "@eslint/js"
  dependency-version: 9.36.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: eslint
- dependency-name: eslint
  dependency-version: 9.36.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: eslint
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-29 09:43:47 +02:00
Halvor Haugan b094c23705 ReadMore: Added tabIndex on content + some other adjustments (#4116) 2025-09-29 09:20:08 +02:00
Karl OandKen fb16483a24 Legg til "kebab" som synonym for ellipsis-ikoner (#4117)
* Add 'kebab' synonym to ellipsis icons

* Delete .changeset/long-cameras-sing.md

No need for changeset for internal doc changes

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2025-09-26 11:44:36 +02:00
Halvor Haugan 08caddf18a Process: Adjusted active-marking (#4118) 2025-09-26 11:42:46 +02:00
KenandHalvor Haugan 74fd46fef7 [Hooks] Overlay hooks for new Overlay/Drawer implementation (#4108)
* ✨ Setup Overlay-component

* ✨ New dir setup

* 🐛 Update storybook imports

* 🎉 Working open close state handling

* ✨ Copy over utilities

* 📝 Document and explain new hooks

* 📝 Update link to hook source

* 📝 Updated docs

* ✨ Added eventCallback hook

* 📝 UseAnimationFinished hook

* ✨ Added openChangeComplete hook

* 🔥 Removed redundant code for PR

* 📝 Update comments

* 🎉 Allow for undefined references

* 🎉 Sync changes with #4106

* 📝 Rename hook

* Update @navikt/core/react/src/overlays/overlay/hooks/useTransitionStatus.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🏷️ starting -> entering, ending -> exiting

* 📝 More comments

* 🐛 Update import of hooks in Floating.tsx

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-09-23 13:26:30 +02:00
github-actions[bot] 960ff7b0c8 Version Packages (#4102)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-09-22 11:22:13 +02:00
Halvor Haugan 489fcbb53a Darkside: Avoid empty aria-describedby in Radio and Checkbox (#4111) 2025-09-22 11:10:06 +02:00
d22edd2773 [Combobox] Uses Floating utility for popover placement (#4106)
* ✨ Setup Overlay-component

* ✨ New dir setup

* 🐛 Update storybook imports

* 🎉 Working open close state handling

* ✨ Copy over utilities

* 📝 Document and explain new hooks

* 📝 Update link to hook source

* 🎉 Replace custom floating element in Combobox with Floating utility

* ✨ Update positioning logic

* 📝 Changeset

* 📝 Updated docs

* ✨ Added eventCallback hook

* 📝 UseAnimationFinished hook

* ✨ Added openChangeComplete hook

* 🔥 Removed redundant code for PR

* 📝 Update comments

* stories

* 🎉 Better positioning update by listening trough animation hooks

* ✨ Moved overscroll-behaviour to only smaller devices

* Update @navikt/core/react/src/overlays/overlay/hooks/useAnimationFinished.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Removed misleading comment

* Update @navikt/core/react/src/overlays/overlay/hooks/useAnimationFinished.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/overlays/overlay/hooks/useAnimationFrame.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/overlays/overlay/hooks/useEventCallback.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Updated comment

* 📝 Rename file

* Update @navikt/core/react/src/overlays/overlay/hooks/useEventCallback.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/overlays/overlay/hooks/useEventCallback.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🔥 Removed unused hook

* ⚰️ Delted animations scheduler API

* 📝 changeset text

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-09-22 11:08:23 +02:00
KenandCopilot 64a82baa94 ✨ Add 'onRowClick' callback-prop to allow for selecting rows on row-click (#4107)
* :spakles: Add 'onRowSelect' callback-prop to allow for selecting rows by clicking the row itself.

* 📝 Docs

* ⚡ Improve interactive check performance

* Update @navikt/core/react/src/table/Row.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 📝 onRowSelect -> onRowClick

* 📝 Update changeset

* 🔥 Removed interactive story from chromatic

* 🎉 Added cursor pointer to table

* 📝 updated docs

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-09-22 11:07:00 +02:00
Ken b6c108115d 🔥 Removed noto and roboto flex from storybook options 2025-09-22 11:06:38 +02:00
Ken 67a148ce27 🔥 Removed unused postcss-cli devDependency in ds-css 2025-09-22 10:29:02 +02:00
5c25c43e67 Redaksjon: cleanup (#4074)
* WIP cleanup

* update schema

* 🔥 Update feedback-solution to remove editor-links

* 🏷️ Sync sanity types

* ♻️ Clean up author-references

* Version Packages (#4078)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* ⬆️ Bump vite in the npm_and_yarn group across 1 directory (#4080)

Bumps the npm_and_yarn group with 1 update in the / directory: [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).


Updates `vite` from 6.3.5 to 6.3.6
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v6.3.6/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v6.3.6/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 6.3.6
  dependency-type: direct:development
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* ⬆️ Bump actions/setup-node from 4 to 5 (#4071)

* ⬆️ Bump actions/setup-node from 4 to 5

Bumps [actions/setup-node](https://github.com/actions/setup-node) from 4 to 5.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* 📝 Sync node-version in actions

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>

* ⬆️ Bump google-github-actions/auth from 2 to 3 (#4070)

Bumps [google-github-actions/auth](https://github.com/google-github-actions/auth) from 2 to 3.
- [Release notes](https://github.com/google-github-actions/auth/releases)
- [Changelog](https://github.com/google-github-actions/auth/blob/main/CHANGELOG.md)
- [Commits](https://github.com/google-github-actions/auth/compare/v2...v3)

---
updated-dependencies:
- dependency-name: google-github-actions/auth
  dependency-version: '3'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* [Templates] Synced our templates with new nav.no changes in header (#4045)

* 💄 Sync templates with updated nav.no template-design

* 📝 Added changelog-entry for templates

* 🔥 Removed unused justify-content prop

* Apply suggestion from @Copilot

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Apply suggestion from @Copilot

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Radio/Checkbox: Improve screen reader experience by moving description out of label (#4066)

* [CI] Change deprecated command and upgrade Chromatic (#4082)

* working filtering in structure, folder for "via redaksjoner"

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-09-19 09:47:02 +02:00
Halvor Haugan 2a78e6e7f5 [website] Avoid importing darkside reset css in examples since it overrides some of the legacy css (#4105) 2025-09-18 09:19:44 +02:00
Halvor Haugan 38d1376331 Darkside: Adjust visually-hidden typography css (#4103) 2025-09-16 15:17:46 +02:00
Halvor Haugan 3b68c61651 Darkside: Adjusted arrow on GuidePanel poster variant (#4101) 2025-09-16 10:34:01 +02:00
Halvor Haugan 0454d5bc68 Add deno.enablePaths to vscode settings (#4098) 2025-09-15 14:29:20 +02:00
Halvor Haugan b30e461e9f Dependabot: Ignore examples directory (#4091) 2025-09-12 14:23:04 +02:00
Halvor Haugan 5eef0563a4 [CI] Set cache-dependency-path to "yarn.lock" (#4093) 2025-09-12 14:05:55 +02:00
github-actions[bot] a6ff199035 Version Packages (#4084)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-09-12 13:53:06 +02:00
Halvor Haugan 6ca479e133 Checkbox/Radio: Correctly check if in darkside (#4094) 2025-09-12 13:23:51 +02:00
Ken 67aace079a Vite, Sanity and Nextjs depdendency-update (#4083)
* ⬆️ Vite and nextjs upgrade

* 📝 Update imports from next-sanity

* ⬆️ Use next-sanity v11
2025-09-12 09:04:28 +02:00
Halvor Haugan a2b8d9bd32 [website] Fix blog heading on mobile (#4088) 2025-09-11 15:08:08 +02:00
KenandHalvor Haugan a04ac98342 [ExpansionCard] Content defaults to app-color from Theme. (#4075)
* ♻️ Use isDarkside-flag for detecting darkside-use of Aksel

* 📝 changeset

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Checked checkbox for better color preview

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-09-11 15:06:53 +02:00
Halvor Haugan 88c6b9dee6 Adjust examples of CopyButton (#4087) 2025-09-11 14:50:43 +02:00
Halvor Haugan 493b604fe5 [CI] Change deprecated command and upgrade Chromatic (#4082) 2025-09-10 19:46:50 +02:00
Halvor Haugan a70ebb5b00 Radio/Checkbox: Improve screen reader experience by moving description out of label (#4066) 2025-09-10 19:40:46 +02:00
KenandCopilot 4935ad99e2 [Templates] Synced our templates with new nav.no changes in header (#4045)
* 💄 Sync templates with updated nav.no template-design

* 📝 Added changelog-entry for templates

* 🔥 Removed unused justify-content prop

* Apply suggestion from @Copilot

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Apply suggestion from @Copilot

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-09-10 19:39:02 +02:00
dependabot[bot] 5f4e5d95e8 ⬆️ Bump google-github-actions/auth from 2 to 3 (#4070)
Bumps [google-github-actions/auth](https://github.com/google-github-actions/auth) from 2 to 3.
- [Release notes](https://github.com/google-github-actions/auth/releases)
- [Changelog](https://github.com/google-github-actions/auth/blob/main/CHANGELOG.md)
- [Commits](https://github.com/google-github-actions/auth/compare/v2...v3)

---
updated-dependencies:
- dependency-name: google-github-actions/auth
  dependency-version: '3'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-10 19:15:54 +02:00
dependabot[bot]andKen 49209259c3 ⬆️ Bump actions/setup-node from 4 to 5 (#4071)
* ⬆️ Bump actions/setup-node from 4 to 5

Bumps [actions/setup-node](https://github.com/actions/setup-node) from 4 to 5.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* 📝 Sync node-version in actions

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-09-10 19:15:03 +02:00
dependabot[bot] 83c2f6fe0a ⬆️ Bump vite in the npm_and_yarn group across 1 directory (#4080)
Bumps the npm_and_yarn group with 1 update in the / directory: [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).


Updates `vite` from 6.3.5 to 6.3.6
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v6.3.6/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v6.3.6/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 6.3.6
  dependency-type: direct:development
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-10 18:54:31 +02:00
github-actions[bot] 137819ad6b Version Packages (#4078)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-09-10 15:08:40 +02:00
Ken cdc7a0dbc1 🐛 Fixed regressions where Weeknumber were missing styling in darkside (#4081) 2025-09-10 14:27:45 +02:00
Halvor Haugan 9647d7e078 Timeline: Refactor parseRows() to make it React 19 ready (#4076) 2025-09-10 11:14:16 +02:00
b9d88373f6 Feature/form summary footer (#4032)
* ✨ Adds FormSummary footer component

Adds a `FormSummaryFooter` component to the `FormSummary`.

Moves the `EditLink` from the header to the new footer for improved structure and consistency.

* 🚨 Adds usage warning for incorrect component placement

Adds a warning to prevent incorrect placement of a component within another.

This improves DX by guiding developers to use the intended structure for form summary components.

* ✨ Adds edit link to FormSummaryHeader

Adds an edit link to the FormSummaryHeader component during testing.

This allows users to easily navigate to the corresponding form section for editing.

Removes requirement for FormSummaryHeader to include EditLink - now optional

* ✨ Moves EditLink to FormSummary.Footer

Moves `EditLink` from `FormSummary.Header` to `FormSummary.Footer` for better component structure and to resolve design issues.

Adds `FormSummaryFooter` component and styles to support the `EditLink`.

Implements `useWarnIfContainsAny` hook to provide development-only warnings for incorrect usage of `FormSummary` subcomponents.

* 🏗️  Refactors FormSummary structure and adds slot warnings

Refactors the FormSummary component to improve structure and provide better guidance for developers.

- Introduces `FormSummary.Header` and `FormSummary.Footer` components as dedicated slots, enhancing the component's API.
- Implements `useForbidSlot` and `useRequireSlot` hooks to provide development-only warnings when components are misused within the wrong FormSummary slots, improving component usability and preventing common integration issues.
- Removes the previous complex logic for warnings within `FormSummaryHeader` in favor of the new slot-based approach.

✅ Renames usageWarnings to slotWarningProvider

🚚 Moves and renames `usageWarnings.tsx` to `slotWarningProvider.tsx` for clarity.

This change improves the naming and location of the slot warning utilities,
making their purpose more explicit and easier to discover.
It also enhances the documentation and debug tooling.

* ♻️ Updated API for slotwarning

* 📝 Added sb-story for testing

* 💄 Remove extra border-radius in footer

* 📝 Updated examples

* 📝 Added changeset

* ♻️ PR adjustments

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🎉 Added pencil-icon

* 📝 Updated jsdoc

* 📝 New changeset

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🔥 Removed forced-debug option

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Apply suggestion from @HalvorHaugan

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 show hidden warning-messages

* 📝 Scope edit-link css

* 🧪 Fixed tests

* 📝 Sync EditLink updates in templates

* 🐛 Update last missing doc-change

* ♿ Responsive padding

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-09-09 16:16:35 +02:00
Halvor Haugan 880c1c8ac3 [aksel.nav.no] Add main- and title-tag to examples (#4077) 2025-09-09 15:57:28 +02:00
Ken b92fb584a8 [Repo] Updated root repo script, added biome to lint-script (#4047)
* ♻️ Update root package.json with updated scripts for utility

* ♻️ Add biome to lint-script

* ♻️ Fix biome lint-errors
2025-09-09 14:57:54 +02:00
dependabot[bot] 55bb44cc6d ⬆️ Bump google-github-actions/upload-cloud-storage from 2 to 3 (#4072)
Bumps [google-github-actions/upload-cloud-storage](https://github.com/google-github-actions/upload-cloud-storage) from 2 to 3.
- [Release notes](https://github.com/google-github-actions/upload-cloud-storage/releases)
- [Changelog](https://github.com/google-github-actions/upload-cloud-storage/blob/main/CHANGELOG.md)
- [Commits](https://github.com/google-github-actions/upload-cloud-storage/compare/v2...v3)

---
updated-dependencies:
- dependency-name: google-github-actions/upload-cloud-storage
  dependency-version: '3'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-09 14:55:46 +02:00
dependabot[bot] e35ce2ad29 ⬆️ Bump actions/stale from 9 to 10 (#4073)
Bumps [actions/stale](https://github.com/actions/stale) from 9 to 10.
- [Release notes](https://github.com/actions/stale/releases)
- [Changelog](https://github.com/actions/stale/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/stale/compare/v9...v10)

---
updated-dependencies:
- dependency-name: actions/stale
  dependency-version: '10'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-09 14:55:09 +02:00
Halvor Haugan 6c6b445b26 Update packageManager field in package.json 2025-09-09 14:17:30 +02:00
dependabot[bot] 6fbc0420da ⬆️ Bump cssnano from 7.0.6 to 7.1.1 (#4069)
Bumps [cssnano](https://github.com/cssnano/cssnano) from 7.0.6 to 7.1.1.
- [Release notes](https://github.com/cssnano/cssnano/releases)
- [Commits](https://github.com/cssnano/cssnano/compare/cssnano@7.0.6...cssnano@7.1.1)

---
updated-dependencies:
- dependency-name: cssnano
  dependency-version: 7.1.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-09 14:04:53 +02:00
Halvor Haugan 495f8e48b4 [website] Add "Endringer" to ToC on template-articles (#4065)
* [website] Add "Endringer" to ToC on template-articles

* Endringer -> Endringslogg
2025-09-08 09:51:55 +02:00
Ken 85a54572ee 📝 IsoString -> DateString for datepicker examples 2025-09-08 09:46:34 +02:00
Halvor Haugan 97594424c6 [website] Activate sandbox on more examples (#4064) 2025-09-08 09:43:26 +02:00
dependabot[bot] 7b7cb89665 ⬆️ Bump the eslint group with 2 updates (#4067)
Bumps the eslint group with 2 updates: [@eslint/js](https://github.com/eslint/eslint/tree/HEAD/packages/js) and [eslint](https://github.com/eslint/eslint).


Updates `@eslint/js` from 9.34.0 to 9.35.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/commits/v9.35.0/packages/js)

Updates `eslint` from 9.34.0 to 9.35.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.34.0...v9.35.0)

---
updated-dependencies:
- dependency-name: "@eslint/js"
  dependency-version: 9.35.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: eslint
- dependency-name: eslint
  dependency-version: 9.35.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: eslint
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-08 09:33:14 +02:00
Julian Nymark 3ff3e0b816 remove bidragsytere, unhide redaksjoner from non-devs (#4063)
* remove bidragsytere, unhide redaksjoner from non-devs

* require redaksjon
2025-09-05 15:00:43 +02:00
Ken 51b2eb5182 ⚡ Update requested k8 CPU to recommended values in Nais-console 2025-09-05 10:15:41 +02:00
Julian Nymark b4ed0a85be one small gap tweak 2025-09-04 16:01:46 +02:00
Julian NymarkandKen f017741d8d [3/3] Redaksjon som forfatter: Feature (#3909)
* AvatarStack component

* storybook: preview with light/dark toggle

* avoid import cycle

* cards story++

* Avatar support empty data

* blogg: use AvatarStack and editorialStaff

* utils fn for blogg avatar

* 🚚 queryToAvatars

* 🔥 queryToAvatars

* snappier loading of Image

* refactor Component API (composeable)

* typing++

* update to new Avatar components

* 🚚 Avatar

* HoverCard (as styled Popover + button)

* SR redundant output

* remove stale comment

* Update Avatar.tsx

* HoverCard: use floating-ui instead of Popover

* HoverCard: use floating-ui instead of Popover

* update path for Avatar

* HoverCard css

* HoverCard: border-color

* missing old token for popover z index on website

* typing for utils

* HoverCardGroup

* use HoverCardGroup

* focus-visible

* p inside button is invalid html

* sync clientConfigs

* re-add the local datasett override

* [sanity-schema] team/miljø for Redaksjon

* redaksjon-som-redaktor] 🎨 render for new schema

* 🐛 broken storybook for aksel (tailwinds related)

* new required type param to stories

* remove HoverCard for now (enable when teams have descriptions)

* change schema for aksel_artikkel to use editorial_staff

* use new schema changes

* [website] use Avatar with editorial_staff for cards on frontpage

* ♻️ HighlightedArticle

* 💄 move date to top for blog entries

* typing++

* match design++

* typing++

* Update aksel.nav.no/website/app/(routes)/(produktbloggen)/produktbloggen/_ui/BloggList.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update aksel.nav.no/website/app/(routes)/(produktbloggen)/produktbloggen/_ui/BloggList.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update aksel.nav.no/website/app/(routes)/(produktbloggen)/produktbloggen/_ui/HighlightedBlogg.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* ♻️ move mapping utility fn to the resultant map location

* 🚚 from /dev/ -> not dev

* ♻️ avoid using fallback || ""

* stop using humanizeText + remove it, warn instead

* remove CSS that will be handled later, technically not used

* better a11y for reading out Avatar faster

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2025-09-04 14:57:16 +02:00
Halvor Haugan 3fb02497b9 Reorganize stories for Radio and Checkbox (#4060) 2025-09-04 08:58:39 +02:00
Halvor Haugan 0b754f13cd Run Chromatic on changes in .storybook directory (#4058) 2025-09-03 16:45:58 +02:00
Julian Nymark 27bed26fff add writers to gp-artikkel (#4059) 2025-09-03 14:54:42 +02:00
KenandCopilot bb230771c9 [Aksel.nav.no] Design-token toc moved between filter and content (#4037)
* ♻️ Design-token toc moved between filter and content resolving team-aksel#843

* Update aksel.nav.no/website/app/(routes)/(designsystemet)/grunnleggende/darkside/design-tokens/page.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-09-03 13:40:02 +02:00
Halvor Haugan c6b6bee287 Remove unused class in button.stories.tsx 2025-09-03 11:35:53 +02:00
Halvor Haugan a572008496 [website] GP: Fix link to related articles (#4057) 2025-09-03 10:14:25 +02:00
Halvor Haugan 317dbab4d0 [Storybook] Add Noto Sans and Open Sans for testing (#4056) 2025-09-03 09:58:52 +02:00
github-actions[bot] f7e9e5768d Version Packages (#4054)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-09-02 13:03:11 +02:00
Halvor Haugan c1560e6ff2 [aksel.nav.no] Adjust EditorPanel width, fix example scrolling, adjust examples (#4055) 2025-09-02 11:51:31 +02:00
Ken 3f58f7efa9 🐛 Removed rem-values on SVG causing errors in Safari (#4048)
* 🐛 Removed rem-values on SVG causing errors in Safari

* 📝 Added docs for future reference
2025-09-01 16:57:49 +02:00
Halvor Haugan 871ea24d16 Styling fixes on Radio and Checkbox (#4051) 2025-09-01 16:32:35 +02:00
Halvor Haugan 4a8eb905d1 [aksel.nav.no] Set sandbox URL length limit to 8000 (#4000) 2025-09-01 13:56:29 +02:00
dependabot[bot] f99fa01b6d ⬆️ Bump the eslint group with 2 updates (#4034)
Bumps the eslint group with 2 updates: [@eslint/js](https://github.com/eslint/eslint/tree/HEAD/packages/js) and [eslint](https://github.com/eslint/eslint).


Updates `@eslint/js` from 9.33.0 to 9.34.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/commits/v9.34.0/packages/js)

Updates `eslint` from 9.33.0 to 9.34.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.33.0...v9.34.0)

---
updated-dependencies:
- dependency-name: "@eslint/js"
  dependency-version: 9.34.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: eslint
- dependency-name: eslint
  dependency-version: 9.34.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: eslint
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-01 12:34:31 +02:00
Ken c15f982a77 [Eslint] Added check for use of React 18 and 19 features in packages (#4040)
* 🏷️ Better linting config to avoid using modern React syntax

* 🐛 Update React imports fixing eslint-config changes

* 🔥 Removed comments in nb-locale
2025-08-29 17:38:07 +02:00
Ken 7915307d06 📝 Updated hide-content example for process (#4043)
* 📝 Updated hide-content example for process

* 📝 Sync process-examples based on feedback
2025-08-29 13:58:35 +02:00
dependabot[bot] 7150c3a5b3 ⬆️ Bump astro (#4026)
Bumps the npm_and_yarn group with 1 update in the /examples/astro directory: [astro](https://github.com/withastro/astro/tree/HEAD/packages/astro).


Updates `astro` from 5.12.8 to 5.13.1
- [Release notes](https://github.com/withastro/astro/releases)
- [Changelog](https://github.com/withastro/astro/blob/main/packages/astro/CHANGELOG.md)
- [Commits](https://github.com/withastro/astro/commits/astro@5.13.1/packages/astro)

---
updated-dependencies:
- dependency-name: astro
  dependency-version: 5.13.1
  dependency-type: direct:production
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-29 13:39:25 +02:00
Ken 43e2d37e6a 🐛 Process-stories now based on static date to avoid chromatic snapshot false positives 2025-08-29 13:38:55 +02:00
b6b61c8f2b Add comprehensive GitHub Copilot instructions for Aksel design system (#4041)
* Initial plan

* Add comprehensive .github/copilot-instructions.md file

Co-authored-by: KenAJoh <26967723+KenAJoh@users.noreply.github.com>

* 📝 Added general instructions

* 📝 Auto-generated instructions

* 📝 Incremental improvements to config

* 📝 Incremental improvements to chat in config

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: KenAJoh <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-08-28 19:30:17 +02:00
dependabot[bot] 4f810da6dd ⬆️ Bump sha.js from 2.4.11 to 2.4.12 in the npm_and_yarn group (#4025)
Bumps the npm_and_yarn group with 1 update: [sha.js](https://github.com/crypto-browserify/sha.js).


Updates `sha.js` from 2.4.11 to 2.4.12
- [Changelog](https://github.com/browserify/sha.js/blob/master/CHANGELOG.md)
- [Commits](https://github.com/crypto-browserify/sha.js/compare/v2.4.11...v2.4.12)

---
updated-dependencies:
- dependency-name: sha.js
  dependency-version: 2.4.12
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-28 11:30:40 +02:00
Halvor Haugan 1438506211 Validate CSS in bundle.js instead of using CLI (#4042) 2025-08-27 12:34:00 +02:00
github-actions[bot] d278e5e50c Version Packages (#4015)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-08-26 15:32:39 +02:00
Halvor Haugan b13541bff4 Process: Remove Checkmark subcomponent, inactive -> uncompleted, adjust gradient (#4039) 2025-08-26 15:22:04 +02:00
Ken 887b47431b Icons: 🎉 New icons 'CheckmarkHeavy' and 'PageBreak'. (#4038) 2025-08-26 10:37:54 +02:00
5391dc9bcc 📝 Marked interactive prop on stepper-wrapper as deprecated (#4007)
* 📝 Marked interactive prop on stepper-wrapper as deprecated

* Update .changeset/eight-friends-yell.md

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 📝 Update changeset

* Update @navikt/core/react/src/stepper/Stepper.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🔥 Removed display only stepper example

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-08-26 10:31:25 +02:00
d189278fae [Components] Process (new component) (#3950)
* [Process] Init Process with clone of Stepper

* [Process] Add variants, state handling and custom overrides

* Clean up css and improve storybook

* [Process] Add component-level icon-overrides

* [Process] Make title optional and remove hideLine

* [Process] Align styles with design

* [Process] Fix high-contrast/forced-colors:active styling

* [Process] Clean up todos

* [Process] Clean up todos

* [Process] Fix lint errors

* [Process] Remove unused prop in Process-example

* [Process] Remove completedIcon and uncompletedIcon

* [Process] Simplify API by removing number and variant props on Step

* [Process] Fix storybook color role

* [Process] Fix styling of date and description

* [Process] Fix legacy css build by removing nesting

* [Process] Clean up jsdoc

* [Process] Update example

* [Process] Make dates in storybook dynamic

* [Process] Remove storybook example with Process-level icon-overrides

* [Process] Re-order storybook icon mix examples

* [Process] Adjust circle size to match design and switch from rem to px

* [Process] Fix according to comments

* [Process] Update Process example to not use 'description'-prop

* [Process] Support hiding of completed steps, with stepwise overrides

* [Process] Fix number size and content alignment

* [Process] Make default icon font-size responsive

* [Process] Remove support for deprecated tokens

* [Process] Adjust title alignment, make activeStep optional, update story

* [Process] Adjust title alignment

* [Process] Make circle numbers semibold and icon size dep on circle size

* [Process] Suggest examples

* ♻️ Collect process component into single file

* 📝 Revert story-name to avoid git naming conflict

* ♻️ Extract Checkbox icon

* ♻️ Make 'activeStep' optional

* ♻️ Update active API

* ♻️ Add line variant prop

* ♻️ Add 'endless' prop to Process

* ♻️ Make active item have colored line

* 💄 Remove 'current' step styling

* ♻️ Remove gap between process steps

* 💄 Connected lines to bullet

* ♻️ Icon -> bullet

* 🎉 Story for interactive content

* ♻️ remove completed prop, remove hideContent prop

* ♻️ Update naming and css syntax

* 🏷️ Make item -> step and step -> item

* 📝 Added demo with lineVariants

* 💄 Small transition on bullet-color

* 💄 Gradient border for current active step

* 💄 Update gradient stops

* 🔥 Removed lineVariant and reverActiveDirection props

* 🎉 Added a two-way aria-controls connection

* 🎉 Added checkmark sub-component

* 🏷️ Export Checkmark sub-component

* 🎉 Added nesting-support to legacy bundle build

* 🎉 Added back legacy css support + forced-colors support

* 🧪 Added CSS-validation for built CSS

* 📝 Changeset

* 📝 Eksempler

* 📝 Example adjustments

* 📝 Added checkmark and number-story

* ♿ Added role=list to ol-element

* Update @navikt/core/react/src/process/Process.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/process/Process.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/process/Process.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/process/Process.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ⚡ Default to undefined childId

* 🔥 remove unused prop

* 🔥 Removed redundant CSS and props

* 🔥 removed forwardRef from utility components

* 🚚 Rename step -> event

* 💄 Testing active-state for process

* ♻️ Update gradient

* 💄 Sync process API with Figma

* ♻️ Removed context and mapping, moved control to event

* 💄 Added active-label styling

* 💄 Make sure active-label has correct spacing

* 📝 Added translations to Process label

* 🚚 Moved hideStatusLabel to Process, renamed translation

* 📝 Updated storybook with translations demo

* 📝 WIP examples update

* 📝 Synced examples with updated API

* 🎉 Added aria-controls sync across Process and Process.Event

* 🏷️ Add number type to function for ts

* 📝 Edit texts in example

* ⚡ Removed redundant memoization

* 📝 Removed date from future 'state' in process

* 📝 Update stories to match new format

* 📝 Renamed active translation, hideStatusLabel -> hideStatusText

* 📝 Removed heading labeling in examples

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-08-26 10:09:51 +02:00
Julian NymarkandHalvor Haugan 467885bb75 [endringslogg] 🎨 hoist state up to searchForm, useEffect on handleSearch (#4030)
* 🎨 hoist state up to searchForm, useEffect on handleSearch

* 🎨 clear textInput on semver checkbox

* perhaps feature complete endringslogg form

* Refactor

* use useOptimistic and use less useEffect

* dynamic default year

* clear other filters when toggling semver search

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-08-26 09:57:58 +02:00
Ken ce619b8444 📝 Removed background on LinkCard 'icon'-demo resolving team-aksel#857 2025-08-26 09:48:20 +02:00
Halvor Haugan f738db1919 ToggleGroup: Improved SR experience by using aria-labelledby instead of aria-describedby for label (#4028) 2025-08-25 20:00:33 +02:00
Halvor Haugan 48c21aae2a Fieldset: Improved SR experience by using aria-labelledby for both legend and description (#4029) 2025-08-25 19:55:38 +02:00
Ken 752989ddd7 [CLI] Makes sure that transforms only run on relevant files (#4016)
* ⚡ Added testcase for css fileextension

* 🐛 Avoids running unsafe transforms on unsupported files

* 🔥 Removed demo tests

* 📝 Changeset

* 🏷️ Rename mislabeled function-name

* 📝 Improved input-args, added comments
2025-08-25 12:21:36 +02:00
KenandHalvor Haugan e049a9ffdd 🐛 Add correct className for border-radius when using Box (#4009)
* 🐛 Add correct className for border-radius when using Box

* Update .changeset/shaggy-wings-study.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-08-25 12:11:57 +02:00
Ken 22b1006e1d 🎉 Added roboto-flex support in storybook for testing (#4011) 2025-08-25 12:11:43 +02:00
KenandHalvor Haugan 08f70efa66 [Linkcard] Added iconPosition-prop for centering arrow (#4021)
* 💄 Move arrow out to component root, add alignment props

* 🎉 Added arrowPlacement prop for centering arrow in LinkCard

* 💄 Added centered arrow-support to legacy-css

* 📝 Resolve typo

* Update .changeset/proud-islands-poke.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 Fix CSS based on data-attrb

* 🔥 Removed unused context value

* 📝 Added centered arrow-stories to chromatic

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-08-25 12:00:54 +02:00
Julian Nymark 0fe52eaa76 Add backlinks to redaksjon (similar to the one for editor) (#4024)
* update schema type for redaksjon

* schema changes++

* sync schema types

* add backlinks to redaksjon
2025-08-22 12:06:29 +02:00
Julian Nymark 9eba4ff284 use subtle color for navSidebarLabels as they are non-clickable (#4027) 2025-08-22 12:03:46 +02:00
Julian Nymark d786e87606 update schema type for redaksjon (#4022)
* update schema type for redaksjon

* schema changes++
2025-08-21 16:25:48 +02:00
Ken 3cf5e1bea6 🎉 Observe editor-document locations in sanity 2025-08-21 15:56:03 +02:00
dependabot[bot] b4c6b5a818 ⬆️ Bump @astrojs/node (#4001)
Bumps the npm_and_yarn group with 1 update in the /examples/astro directory: [@astrojs/node](https://github.com/withastro/astro/tree/HEAD/packages/integrations/node).


Updates `@astrojs/node` from 9.2.2 to 9.4.1
- [Release notes](https://github.com/withastro/astro/releases)
- [Changelog](https://github.com/withastro/astro/blob/main/packages/integrations/node/CHANGELOG.md)
- [Commits](https://github.com/withastro/astro/commits/@astrojs/node@9.4.1/packages/integrations/node)

---
updated-dependencies:
- dependency-name: "@astrojs/node"
  dependency-version: 9.4.1
  dependency-type: direct:production
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-21 12:35:05 +02:00
dependabot[bot] 833ab44a35 ⬆️ Bump esbuild from 0.25.8 to 0.25.9 in the npm_and_yarn group (#4002)
Bumps the npm_and_yarn group with 1 update: [esbuild](https://github.com/evanw/esbuild).


Updates `esbuild` from 0.25.8 to 0.25.9
- [Release notes](https://github.com/evanw/esbuild/releases)
- [Changelog](https://github.com/evanw/esbuild/blob/main/CHANGELOG.md)
- [Commits](https://github.com/evanw/esbuild/compare/v0.25.8...v0.25.9)

---
updated-dependencies:
- dependency-name: esbuild
  dependency-version: 0.25.9
  dependency-type: direct:development
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-21 12:34:31 +02:00
dependabot[bot]andKen 4e644fec9f ⬆️ Bump swr from 2.3.3 to 2.3.6 (#4004)
* ⬆️ Bump swr from 2.3.3 to 2.3.6

Bumps [swr](https://github.com/vercel/swr) from 2.3.3 to 2.3.6.
- [Release notes](https://github.com/vercel/swr/releases)
- [Commits](https://github.com/vercel/swr/compare/v2.3.3...v2.3.6)

---
updated-dependencies:
- dependency-name: swr
  dependency-version: 2.3.6
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* ⬆️ Sync swr-package versions

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-08-21 12:33:55 +02:00
dependabot[bot] 7dd0ad778a ⬆️ Bump lint-staged from 13.0.3 to 16.1.5 (#4006)
Bumps [lint-staged](https://github.com/lint-staged/lint-staged) from 13.0.3 to 16.1.5.
- [Release notes](https://github.com/lint-staged/lint-staged/releases)
- [Changelog](https://github.com/lint-staged/lint-staged/blob/main/CHANGELOG.md)
- [Commits](https://github.com/lint-staged/lint-staged/compare/v13.0.3...v16.1.5)

---
updated-dependencies:
- dependency-name: lint-staged
  dependency-version: 16.1.5
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-21 12:32:07 +02:00
dependabot[bot] 7b145878c9 ⬆️ Bump actions/checkout from 4 to 5 (#4008)
Bumps [actions/checkout](https://github.com/actions/checkout) from 4 to 5.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-21 12:14:34 +02:00
Halvor Haugan e8c299301e [website] Small adjustments in Endringslogg (#4020) 2025-08-21 12:13:40 +02:00
KenandHalvor Haugan ee09c60f24 [Examples] Removed tailwind classes, migrated to new primtive spacing (#4014)
* 🐛 Support legacy and darkside switch in Aksel storybook setup

* ♻️ Adjust min-height examples

* ♻️ Removed all use of custom className in examples

* 🚚 Migrated to new primitive spacing scale

* Update aksel.nav.no/website/pages/eksempler/h-stack/align.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/pages/eksempler/v-stack/align.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 Update theme-css for aksel-storybook to handle layers

* 📝 Tag -> tab

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-08-20 18:09:21 +02:00
Halvor Haugan 4eb83bad69 [darkside] Fix issue with focus outline on checkbox in expandable table row content (#3998) 2025-08-20 15:00:08 +02:00
Halvor Haugan aa4aed512f Darkside: Fix arrow in Tooltip (#4018) 2025-08-20 09:46:16 +02:00
Halvor Haugan 316b78eefd Adjust examples of ToggleGroup + remove text about small on other examples (#4017) 2025-08-19 16:13:24 +02:00
Halvor Haugan ae7e517e67 Adjust examples of ToggleGroup (#4013) 2025-08-19 13:36:27 +02:00
Ken 639b837d74 🔥 Deprecate headingSize-prop in Accordion (#3993) 2025-08-19 13:28:07 +02:00
KenandJulian Nymark 3de2906e9e semver search in changelog entries (#3989)
* 📝 WIP setup for semver search in changelog entries

* settings display & opt-out

* maxWidth to not break mobile

* make feature opt-in

* now support semver range searches

* join filter back to valid semver range syntax

* tweaks to search syntaks Popover and button

* use Helptext instead of custom Helptext

* checkbox for search preference

* default checked for snappy prefilled value from search params

* group all form into SearchForm for use client shennanigans and state management

* typing++

* ♻️ refactor state management for FilterChips

Why? Since the form is a bit more "complex" in hiding fields based on
other fields, it felt apropriate to "somewhat centralize" the state,
not going full context here, but sending down the useState() is fine
for now in terms of complexity imo.

Unfortunately the smarter / optimized behaviour has been disabled for
now, so no prefetching of the resulting query when hovering over a
FilterChip. It also requires you to hit enter or click the search icon
in order to trigger a search. It's more manual, but simpler to
understand (and to develop). Consider re-adding smarts. The smarts was
also not "fully smart" in its previous incarnation, since we couldn't
have the search be "instant and automatic" (not requiring any
enter/clicks beyond typing).

* typing

---------

Co-authored-by: Julian Nymark <julian.nymark@nav.no>
2025-08-19 11:20:40 +02:00
Halvor Haugan 39240c5e48 [website] Hide sandbox button when base64 is falsy, and stegaClean it (#3999) 2025-08-15 14:52:12 +02:00
github-actions[bot] 8934728f89 Version Packages (#3987)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-08-15 14:06:26 +02:00
Julian Nymark 0b89a2f09c sync clientConfigs (#3986)
* sync clientConfigs

* re-add the local dataset override
2025-08-14 12:03:51 +02:00
Halvor Haugan 95f9b6ae46 Form components: Improved a11y when using JSX in description (#3990) 2025-08-13 12:06:59 +02:00
Halvor Haugan c2360cf595 Helper function for creating Chromatic stories (#3923) 2025-08-13 12:05:36 +02:00
Julian Nymark cf12f9e4d7 increase padding under certain width to avoid overlapping theme selection (#3992) 2025-08-13 09:48:51 +02:00
Halvor Haugan 2001a0c9de Fieldset: Connect description to fieldset with aria-describedby (#3974) 2025-08-12 12:31:08 +02:00
github-actions[bot] 9c793b4b90 Version Packages (#3985)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-08-12 11:53:23 +02:00
Ken cb03eb15f9 🎉 Use kbd in global-search button 2025-08-12 11:49:39 +02:00
Ken dc769d5c61 Updated Sanity API-version (#3984)
* ⬆️ Bumped Sanity API-version to current time

* 🔧 Use `SANITY_API_VERSION` in `editorialStaff.tsx` for API versioning
2025-08-12 10:40:44 +02:00
Ken b24ebb3499 🎉 New icons ArrowCirclepathReverse and ArrowsAllDirections. (#3979)
* 🎉 New icons ArrowCirclepathReset and ArrowsAllDirections.

* 🏷️ Rename ArrowCirclepathReset -> Reverse
2025-08-12 09:42:14 +02:00
Ken 2c24f85e98 🏷️ Export Datepicker hook argument types (#3983)
* 🏷️ Export Datepicker hook argument types

* Apply suggestion from @KenAJoh
2025-08-12 09:29:14 +02:00
f726c2c977 ⬆️ Bump cross-env from 7.0.3 to 10.0.0 (#3981)
* ⬆️ Bump cross-env from 7.0.3 to 10.0.0

Bumps [cross-env](https://github.com/kentcdodds/cross-env) from 7.0.3 to 10.0.0.
- [Release notes](https://github.com/kentcdodds/cross-env/releases)
- [Changelog](https://github.com/kentcdodds/cross-env/blob/main/CHANGELOG.md)
- [Commits](https://github.com/kentcdodds/cross-env/compare/v7.0.3...v10.0.0)

---
updated-dependencies:
- dependency-name: cross-env
  dependency-version: 10.0.0
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* upgrade cross-env in website workspace too

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-08-11 16:09:40 +02:00
Halvor Haugan d6b4ef6ec5 [website] Show dataset in footer when it's not production (#3947) 2025-08-11 15:30:00 +02:00
Julian Nymark ff5c013455 schema changes for working with redaksjon som forfatter 2025-08-11 14:47:12 +02:00
Halvor Haugan ea3dcb7d6c [website] stegaClean in ToC (#3982) 2025-08-11 14:00:43 +02:00
dependabot[bot] d9e88e3a04 ⬆️ Bump astro (#3969)
Bumps the npm_and_yarn group with 1 update in the /examples/astro directory: [astro](https://github.com/withastro/astro/tree/HEAD/packages/astro).


Updates `astro` from 5.9.3 to 5.12.8
- [Release notes](https://github.com/withastro/astro/releases)
- [Changelog](https://github.com/withastro/astro/blob/main/packages/astro/CHANGELOG.md)
- [Commits](https://github.com/withastro/astro/commits/astro@5.12.8/packages/astro)

---
updated-dependencies:
- dependency-name: astro
  dependency-version: 5.12.8
  dependency-type: direct:production
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-11 11:57:59 +02:00
github-actions[bot] 404d5bd024 Version Packages (#3980)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-08-11 11:44:32 +02:00
dependabot[bot] 2b37dd08f9 ⬆️ Bump postcss-selector-parser from 6.1.2 to 7.1.0 (#3978)
Bumps [postcss-selector-parser](https://github.com/postcss/postcss-selector-parser) from 6.1.2 to 7.1.0.
- [Release notes](https://github.com/postcss/postcss-selector-parser/releases)
- [Changelog](https://github.com/postcss/postcss-selector-parser/blob/master/CHANGELOG.md)
- [Commits](https://github.com/postcss/postcss-selector-parser/compare/v6.1.2...v7.1.0)

---
updated-dependencies:
- dependency-name: postcss-selector-parser
  dependency-version: 7.1.0
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-11 11:37:55 +02:00
dependabot[bot] 5e3a411cc5 ⬆️ Bump the eslint group with 2 updates (#3976)
Bumps the eslint group with 2 updates: [@eslint/js](https://github.com/eslint/eslint/tree/HEAD/packages/js) and [eslint](https://github.com/eslint/eslint).


Updates `@eslint/js` from 9.32.0 to 9.33.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/commits/v9.33.0/packages/js)

Updates `eslint` from 9.32.0 to 9.33.0
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v9.32.0...v9.33.0)

---
updated-dependencies:
- dependency-name: "@eslint/js"
  dependency-version: 9.33.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: eslint
- dependency-name: eslint
  dependency-version: 9.33.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: eslint
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-11 10:44:46 +02:00
Halvor Haugan 8908235bf5 Radio/Checkbox: 🐛 Fix issue where label was not announced by screen readers in Firefox (#3973) 2025-08-11 10:41:06 +02:00
Steinar e694aba9dd [Stepper] Increase circle size to match Process component (#3968)
* [Stepper] Increase circle size to match Process component

* [Stepper] Fix circle size issue in legacy css

* [Stepper] Make completed checkmark font-size responsive

* [Stepper] Adjust completed-icon to 24x24 while still dynamic

* [Stepper] Add changeset

* [Stepper] Adjust title alignment
2025-08-11 10:38:26 +02:00
Ken 962e2d4ee4 🎉 Left-align images for left-aligned page-layouts (#3970)
* 🎉 Left-align images for left-aligned page-layouts

* 🔥 Removed max-width limit
2025-08-08 12:50:36 +02:00
Halvor Haugan b9b8dbefcf [website] Fix image overflow issue in DoDont (#3971) 2025-08-08 12:03:25 +02:00
github-actions[bot] 21676b50a7 Version Packages (#3966)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-08-08 10:11:26 +02:00
KenandHalvor Haugan 703a0713fd 🐛 Use correct supports syntax in CSS when checking for has selector (#3965)
* 🐛 Use correct supports syntax in CSS when checking for has selector

* Update .changeset/tender-tools-tie.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-08-07 14:28:07 +02:00
41e1a5c98a 🎉 Auto-generate github-releases based on changeset release (#3964)
* 🎉 Auto-generate github-releases based on changeset release

* Update scripts/git-release.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update scripts/git-release.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update scripts/git-release.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🔥 Removed redundant prefixing of tag

* ♻️ Replace execSync with spawnSync

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-08-07 12:57:21 +02:00
Ken 1db53bb312 🐛 Remove immutable installs to allow changeset to perform automatic PRs 2025-08-07 09:29:18 +02:00
Ken 92985b8814 🐛 Using Theme component to set color to dark did not work when root node did not set light/dark (#3961) 2025-08-07 08:28:16 +02:00
Ken 3d9c55ed7d [Icons]: Did not tests for incorrect fill-color, causing ChatAdd to be released with issues (#3963)
* 🧪 we only checked for correct stroke-value, not fill in icons. Now tests for both

* 🐛 ChatAdd icon had wrong fill-color for + sign

* 📝 Changeset
2025-08-07 08:23:27 +02:00
Halvor Haugan d24ca8f3f0 Migrate to eslint 9 (flat config) (#3949) 2025-08-06 15:20:38 +02:00
Halvor Haugan 39191e5415 CI: Immutable yarn install (#3926) 2025-08-06 15:16:05 +02:00
Halvor Haugan ceacae6022 Improved clean script (#3962) 2025-08-06 14:50:38 +02:00
7f7f6bb6e1 Fix theme switcher accessible name (#3944)
* Theme switcher exposed both icon's accessible name, even if only one icon was shown. This change properly removes the icon.

* fix hydration error and use resolvedTheme instead of theme

* ♻️ Use tooltip for theme-switcher button

* 🎉 Replace sun/moon icon with theme-icon

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-08-06 11:26:52 +02:00
github-actions[bot] 0597d79537 Version Packages (#3959)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-08-06 08:35:11 +02:00
Steinar a2d4bb4e23 [website] Fix changelog link in component links to ref new changelog (#3957) 2025-08-05 14:58:33 +02:00
Ken ab84fea358 🎉 New icons ChatAdd and Theme (#3958) 2025-08-05 14:57:57 +02:00
dependabot[bot] ae1ecf5693 ⬆️ Bump next (#3934)
Bumps the npm_and_yarn group with 1 update in the /aksel.nav.no/website directory: [next](https://github.com/vercel/next.js).


Updates `next` from 15.3.1 to 15.3.3
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/compare/v15.3.1...v15.3.3)

---
updated-dependencies:
- dependency-name: next
  dependency-version: 15.3.3
  dependency-type: direct:production
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-05 10:43:52 +02:00
github-actions[bot] ef3cc858c0 Version Packages (#3956)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-08-05 10:40:51 +02:00
Ken 9df7d51e06 🐛 JsCodeshift ignored given filepaths when extensions were given (#3955) 2025-08-05 10:38:41 +02:00
dependabot[bot] 051262c367 ⬆️ Bump form-data from 4.0.2 to 4.0.4 in the npm_and_yarn group (#3952)
Bumps the npm_and_yarn group with 1 update: [form-data](https://github.com/form-data/form-data).


Updates `form-data` from 4.0.2 to 4.0.4
- [Release notes](https://github.com/form-data/form-data/releases)
- [Changelog](https://github.com/form-data/form-data/blob/master/CHANGELOG.md)
- [Commits](https://github.com/form-data/form-data/compare/v4.0.2...v4.0.4)

---
updated-dependencies:
- dependency-name: form-data
  dependency-version: 4.0.4
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-05 10:27:28 +02:00
Ken 4c8c647f67 🐛 Redirect from legacy ingress desgin.nav.no -> aksel.nav.no@ 2025-08-05 09:39:20 +02:00
dependabot[bot] 05b8fbc523 ⬆️ Bump esbuild from 0.25.5 to 0.25.8 (#3940)
---
updated-dependencies:
- dependency-name: esbuild
  dependency-version: 0.25.8
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 14:49:29 +02:00
Halvor Haugan 9e8bde1fa4 [website] Simplify update:sanity-schema script (#3948) 2025-08-04 10:10:28 +02:00
Halvor Haugan fdcc61b1ef [website] Adjust type for image url utils to avoid type assertion (#3946) 2025-08-04 10:09:45 +02:00
Ken 4976907fb6 [Website] Utility-function cleanup (#3937)
* 🔥 Remove old preview-api

* 🚚 Migrate format-text util

* 🔥 Removed unused util-code

* ♻️ Updated removeEmojies to handle compound-emojies

* 🐛 Update imports

* 🚚 Update and rename 'getImage' to 'fallbackImageUrl'

* 🧪 Added tests for fallback image util

* ♻️ Inline author deconstruction since it will be removed soon

* ⚰️ Delete old unused utility code
2025-07-04 16:07:14 +02:00
github-actions[bot] d737046e9a Version Packages (#3936)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-07-04 15:44:41 +02:00
Ken 6ed48b9a9b [Website] Darkside cleanup utils (#3935)
* ⚰️ Deleted legacy-files

* 🚚 Migrated date-str formatter
2025-07-04 13:36:07 +02:00
github-actions[bot] e73e26f9e2 Version Packages (#3924)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-07-04 13:18:47 +02:00
Ken e5b7d26587 [Website] Force-static render /admin (#3933)
* 🐛 Force static render Admin routes, refactor consent-banner

* 🐛 Update consent clientside

* ⚡ AAvoid extract render-step by inlining enablr check

* ⚡ Avoid suspense-boundary by using force-dynamic
2025-07-04 13:18:11 +02:00
Ken 8bc9247241 🐛 Render codeblocks without language set 2025-07-03 14:05:30 +02:00
Ken 882d4af9b8 ⚰️ Deleted legacy-files (#3929) 2025-07-03 13:47:35 +02:00
Ken de9ec5ebb6 ⚰️ Delete legacy search tests 2025-07-03 13:09:55 +02:00
Ken f5c481e487 🐛 Filter out empty headings from CMS in TOC-render 2025-07-03 12:27:23 +02:00
Ken c032d0cfe9 🐛 Make sure LinkCards are wrapped in li while inside ul 2025-07-03 11:45:00 +02:00
Ken 8e2e8a0e22 🐛 Ignore codeblock sections in e2e Axe tests 2025-07-03 11:38:00 +02:00
Ken 3dc3b4bcf7 🐛 Avoid duplicate aria-labels in code-blocks 2025-07-03 11:16:00 +02:00
Ken daaf3d145b 🐛 Make sure search is inside landmark 2025-07-03 10:34:53 +02:00
Ken e509285153 🔍 Added SEO-fields to changelog-articles 2025-07-03 10:31:51 +02:00
Ken f89cee0125 🐛 Clear interval before overriding it 2025-07-03 09:59:35 +02:00
Ken 9f1848bb78 📝 Yarn lock sync 2025-07-03 09:58:25 +02:00
Ken 435f528d65 💄 Updated Meta-lime scale for 300 and 400 (#3928) 2025-07-03 09:52:22 +02:00
Ken f4a4987200 🐛 Fallback to correct heading-color when animation is stopped 2025-07-02 15:46:14 +02:00
Ken b1ae7b36d5 🐛 Make sure to only update already published changelog documents 2025-07-02 14:54:14 +02:00
Ken e93e6d9a23 ⚰️ Delete legacy-changelog script 2025-07-02 14:40:52 +02:00
Halvor Haugan a7380c8582 Fix some minor issues in stepper.stories.tsx (#3925)
* Fix some minor issues in stepper.stories.tsx

* this should be a separate PR
2025-07-02 14:39:39 +02:00
Ken b8d36f2df6 💄 Start at brand-blue when animating colors 2025-07-02 14:35:51 +02:00
Ken 310f67996a 💄 Update changelog-cards, darkside highlight 2025-07-02 13:58:28 +02:00
Ken 19f6f82bce Aksel darkside release (#3922)
* 📝 Update redirects

* 🚚 Moved dev UI -> root UI

* 🚚 dev -> (routes)

* 🚚 Updated imports to reflect dev -> (routes) change

* 🔥 Deleted legacyroutes

* ♻️ Clean up _app

* 🔥 Clean up legacy global css

* 🔥 Removed stylesheet loading for examples

* 🔥 Removed legacy API

* 🚚 Move config-files

* 🚚 Use root routes, replacing /dev

* 🐛 Avoid importing darkside-css in global.css

* 🐛 Updated header-link directing to designsystemet

* 🐛 Add bg to examples

* 🚚 Development -> Production dataset

* 🐛 make sure darkside css overrides legacy

* ✨ Enable draftPreview

* ✨ Updated exit draftMode banner, resolve frontpage document

* 🚚 Migrate API-routes

* 💄 Height-align cards in li-grid

* 📝 Avoid redirecting monster-maler overview-page

* 🐛 Fix OG-image used in Endringslogg

* 🚚 Inline sidebargroup

* 💄 Update sidebar

* 💄 Fix indentation

* 🐛 Root overview-page now handles active-state correctly

* 🔊 Fixed next-logger config

* 🐛 Avoid reduntant revalidation

* 📝 ⚡ Rename route-labels, prefetch sidebar links

* 📝 Preview -> presentation redirect

* ♻️ Avoid using legacyBehaviour for Next links

* 💄 Better code-theme for html

* 💄 Reduce sidebar-width to 18rem

* 🐛 Remove theme-togglegroup

* 🐛 Avoid prefetching presentation-mode link

* 🐛 Resolve komponenter link to correct path

* 🎉 Link directly to God-praksis from frontpage

* 🐛 Update sidebar-tests to reflect renaming

* 🐛 Avoid force dynamic on icon-page

* 🐛 Avoid refreshing on focus

* ♿ Aria-expanded on mobile-menu dropdown

* 🐛 Add github user content to nais externals

* 💄 Better gp-frontpage lin kwidth

* 💄 Dedicated ds-section

* 🎉 New hero-cards

* 🎉 Updated hero-cards

* 🎉 Updated mobile-menu for ds-navigation

* 🐛 Fix Modal-bug where darkside className were not set on body after open

* 🎉 Update focus after changing view

* 📝 Global search texts

* 💄 auto-resize thumbnails

* 🚚 Move PromoTag to a standalone server-component

* 🎉 Added promo-tag to frontpage

* 💄 Updated animation for promotag

* 💄 Synced Aksel-logo in Card

* 🐛 Search did not forward data-color to button

* 📝 Update search and sidebar texts

* 💄 Animated icon-card

* 💄 More noticable promo-tag border when animating

* 📝 Update 'siste fra Aksel'-texts

* 🐛 Avoid always hiding table-rows on SM-breakpoint
2025-07-02 13:23:46 +02:00
Julian Nymark bf69efc005 correcter subdomain (#3900) 2025-06-30 15:43:23 +02:00
Julian Nymark cab4085906 [1/3] Redaksjon som forfatter: AvatarStack (#3905)
* AvatarStack component

* storybook: preview with light/dark toggle

* avoid import cycle

* cards story++

* Avatar support empty data

* 🔥 queryToAvatars

* snappier loading of Image

* refactor Component API (composeable)

* typing++

* 🚚 Avatar

* HoverCard (as styled Popover + button)

* SR redundant output

* remove stale comment

* Update Avatar.tsx

* HoverCard: use floating-ui instead of Popover

* HoverCard: use floating-ui instead of Popover

* HoverCard css

* HoverCard: border-color

* HoverCardGroup

* focus-visible

* p inside button is invalid html
2025-06-30 15:35:44 +02:00
Ken 91fced9951 [Website] Smart/compact examples (#3907)
* 🎉 Extract JSX for examples

* ✨ Added new jsx-data to examples-code

* 🏷️ Synced sanity-types

* 🐛 Make sure to remove trailing semicolon

* 🎉 Show compact code for examples and templates

* 📝 Adjust texts for expanding collapsed code-views

* 🎉 Add support for implicit return examples

* 🐛 Make sure to ignore nested return-statements

* 📝 Updates to expand/collapse texts in code-examples

* 🔥 Removed redundant boolean flag
2025-06-30 15:13:52 +02:00
KenandCopilot 6f11f31fe4 🎉 Scroll examples into view after being closed from expand-state (#3915)
* 🎉 Scroll examples into view after being closed from expand-state

* Update aksel.nav.no/website/app/_ui/code-block/CodeBlock.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update aksel.nav.no/website/app/_ui/code-block/CodeBlock.tsx

* ⚡ Instant-scroll to collapsed code-examples

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-06-30 15:13:36 +02:00
Ken 94726fc606 ♿ Replace ol-tag with div in <Chat /> (#3904)
* ♿ Chat ol-tag now has role presentation

* 🔥 Removed now redundant ol>li syntax for chat list

* 🔥 Removed now redundant list-reset css in chat

* 🔥 Removed now redundant list-reset css in chat in darkside

* 📝 Changeset

* 📝 Update changeset

* Delete .changeset/new-gifts-add.md
2025-06-30 15:06:56 +02:00
Ken f3de77539f [Table] Selected row highlight (#3898)
* 💄 Added outlined highlight styling to selected table-rows

* 📝 Changeset

* 📝 Add selection-demo for expanded table
2025-06-30 15:06:47 +02:00
Ken 8b62b2b1e4 ✨ Allow for custom buttons in fileupload item. (#3906)
* ✨ Allow for custom buttons in fileupload item.

* 📝 Add primtitives to FileUpload mappings
2025-06-30 14:43:59 +02:00
Ken 7237daa0e0 💄 Update code-example theme (#3919)
* 💄 Update code-example theme

* 💄 Adjust import styling for react-components
2025-06-30 12:21:55 +02:00
5d2b52ba51 [website] Endringslogg (#3885)
---------

Co-authored-by: stainawarjar <210375207+stainawarjar@users.noreply.github.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2025-06-30 11:33:47 +02:00
bf4b3fd459 Feature/designsystem front page (#3911)
* Add designsystem front page skeleton

* Add heading and ingress

* Add getting started with design/development link cards

* Implement first working version of "layers" component

* Add an initial attempt at hover styling for ds layers component

* Refactor DS Landing page into separate components

* Add a change log section to ds landing page

* Add AkselByNumbers module

* Get real change log entries from Sanity

* Multiple changes made by pair-design-gramming with Sjur

* Updated sanity schemes

* Add missing contrast colors/variants for link and the typography components

* Use data-color for AkselByNumbers

* Use data-color and slightly tweak padding for PromoTag

* Re-add arrow to ChangeLogNews LinkCard

* Tweaks to LinkCard, using more square icon backgrounds (compared to round backgrounds before) with large border radius, and changing the icon color to subtle

* Per discussion with Ken, removing new contrast variant/textColor option, so as not to break old version of components. Replacing it with CSS for now, but may re-add it later by giving sensible fallbacks in old ds-versions

* Move layers overview styling to a separate CSS-file

* Adjustments for mobile view

* Make all content on the designsystem front page editable in Sanity

* Further adaption to smaller screen sizes

* Handle promoTag being null

* Remove old patches to link and typography to support contrast variants. Will do this manually through CSS variables for now.

* Remove overrides from link-card css, and using local overrides instead

* Remove commented-out code

* Actually use Sanity data

* Update url

* Move getting started files to a sub-folder

* Move change log files to a sub-folder

* Move aksel-by-numbers files to a sub-folder

* Move ds layers overview files to a sub-folder

* Move support section files to a sub-folder

* Migrate to use new LinkCard component instead of the local one. Had to use Box to add background to the icon, as that has been removed from the component.

* Reverse changes made to this out-dated component, as this code no longer uses it.

* 🚚 Moved data-fetch for changelog to sub-component

* 💄 More spacing between promo and title

* 💄 Removed max-width for layers-panel

* ♻️ Inline gettingstarted-components

* ♻️ Use PageBlock for maxWidth handling

* ♻️ Use LinkCards for mobile layers view

* ♻️ Respect content-type for changelog

* ✨ Use new animated arrow for promo-link

* ♻️ Return notfound if data-loading fails

* 💄 Soft support card bg

* 🐛 Sync teal colors

* 💄 Use last changelog-card as a static link to changelog

* Update aksel.nav.no/website/app/dev/(designsystemet)/designsystemet/page.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Make layers links larger (20px)

* Change support cards to LinkCards

* Aksel by numbers: Change css to css modules

* ChangeLogNews: Change css to css modules

* DS Layers Overview: Change css to css modules

* PromoTag: Change css to css modules

* DSLandingPageHeading: Change css to css modules

* Attempt to add OG image and description

* Suggested typing change from Julian

* Update aksel.nav.no/website/sanity/schema/documents/designsystem-forside.tsx

* Handle null value as well

* Update aksel.nav.no/website/app/dev/(designsystemet)/designsystemet/_ui/change-log/ChangeLogNews.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/app/dev/(designsystemet)/designsystemet/_ui/change-log/ChangeLogNews.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/app/dev/(designsystemet)/designsystemet/_ui/promo-tag/PromoTag.module.css

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update aksel.nav.no/website/app/dev/(designsystemet)/designsystemet/_ui/page-heading/DSLandingPageHeading.module.css

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Can remove css by adding the color token, now that we use BoxNew to add the icon background

* Remove code that was copied from Figma, but does nothing

* Add correct focus styling to PromoTag

* Overriding LinkCard is no longer necessary.

* Filtrer vekk aksel_ds_forside dokumenttypen fra toppnivå i Sanity

* Use semantic colors in PromoTag. Needed to disable eslint-rule because the linter does not find aksel-tokens

* Update aksel.nav.no/website/app/dev/(designsystemet)/designsystemet/_ui/ds-layers-overview/DSLayersOverview.tsx

* Add position: relative to layers link to fix positioning bug in Safari for the rhombus. Also removed redundant/duplicate :last-of-type selector.

* Only show focus-outline for layers links, not the rhombus and the dotted line

* Use same :hover and :focus-visible highlighting for the dotted line and rhombus for all layers links

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-06-30 10:32:18 +02:00
Halvor Haugan d21403c3f9 [website] Fix ToC not scrolling correctly (#3920) 2025-06-30 09:50:22 +02:00
Halvor Haugan 15201b32a6 [website] Fix fill color on list bullet (#3918) 2025-06-27 13:56:46 +02:00
Halvor Haugan 777727a68e [website] Remove href from noninteractive example (#3916) 2025-06-26 13:47:06 +02:00
Ken f8e1c8fd16 🔥 Removed no-arrow demo for LinkCard 2025-06-26 09:34:19 +02:00
Ken 8d739d45f4 📝 Update examples theme-select texts 2025-06-26 09:28:10 +02:00
Julian Nymark 0a902a695e [2/3] Redaksjon som forfatter: Sanity (#3908)
* schema for editorialStaff

* 🚚 editorial_staff_teams -> writers

also make it soft-enabled during transition period (hidden + allow incomplete)

* missing rename
2025-06-25 16:54:23 +02:00
Halvor Haugan 95a6c06939 [website] Activate changelog script (#3913) 2025-06-25 15:11:28 +02:00
github-actions[bot] d319e3377c Version Packages (#3895)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-06-25 14:13:14 +02:00
KenandHalvor Haugan b4f7ffd78b [Komponenter] Scroll margin forms (#3897)
* 💄 Added scroll-margin to select, textfield and textarea

* 📝 Changeset

* Update .changeset/bumpy-singers-ask.md

* Update .changeset/bumpy-singers-ask.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-06-25 13:27:03 +02:00
Ken 5db38058c3 [LinkCard] Flex-start align arrow. (#3912)
* 💄 Flex-start align arrow in LinkCard

* 🐛 Center-align title when no description and footer is set

* 🔥 Removed redundant changesets since component is not yet released

* 📝 Modify story to show flex-start alignment of arrow
2025-06-25 13:26:35 +02:00
KenandHalvor Haugan 915317cb06 🎉 Added sticky-header for Table (#3893)
* 🎉 Added sticky-header for Table

* 🐛 Sync z-index

* Update .changeset/plain-ghosts-create.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/table/Table.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-06-25 13:26:23 +02:00
KenandHalvor Haugan b7d0120251 [Komponenter] Switch size small synced with radio and checkbox. (#3892)
* 🎉 Small switch now 20px high for darkside

* 💄 Dynamic loader-size based on checked and switch-size

* 💄 Small size switch for legacy css

* 📝 Changeset

* ⚰️ Add depcation-warning in stylelint-config

* 📝 Changeset

* 🐛 Loader-icon was not centered

* Update @navikt/aksel-stylelint/src/deprecations.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update .changeset/hip-walls-itch.md

* Update .changeset/flat-numbers-kiss.md

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-06-25 12:49:21 +02:00
Ken 621c189a24 [Darkside website] Use new LinkCard-component in website (#3903)
* 🐛 LinkCard did not spread remaining props and classNames

* ✨ Use new LinkCard on frontpage

* ✨ LinkCard overview update

* ✨ Hero LinkCard

* ✨ Hero LinkCard

* ✨ GP page LinkCard

* ✨ Frontpage link-card

* 🔥 Deleted legacy card, use new LinkCard from ds-react

* ♻️ Re-added line-clamp feature
2025-06-25 12:27:12 +02:00
Ken d77cc40144 ✨ Allow disabling new themeswitch and Theme in examples (#3891)
* ✨ Allow disabling new theme switch and darkside for spesific stories

* 🐛 Change default-value to false

* 🐛 Make sure to force light-mode when showing legacy-stories
2025-06-25 10:19:09 +02:00
Halvor Haugan 6a74f79605 LinkCard.stories.tsx: Static image in Chromatic story (#3910) 2025-06-24 16:09:52 +02:00
Halvor Haugan fb93a1c342 [website] Rename "innhold" to "content" in ds_endringslogg_artikkel schema 2025-06-24 15:05:18 +02:00
Ken fe05898d5b 🔥 Removed global gitignore for d.ts-files (#3890) 2025-06-24 11:49:17 +02:00
dependabot[bot] 9d1771368a ⬆️ Bump pbkdf2 from 3.1.2 to 3.1.3 in the npm_and_yarn group (#3901)
Bumps the npm_and_yarn group with 1 update: [pbkdf2](https://github.com/crypto-browserify/pbkdf2).


Updates `pbkdf2` from 3.1.2 to 3.1.3
- [Changelog](https://github.com/browserify/pbkdf2/blob/master/CHANGELOG.md)
- [Commits](https://github.com/crypto-browserify/pbkdf2/compare/v3.1.2...v3.1.3)

---
updated-dependencies:
- dependency-name: pbkdf2
  dependency-version: 3.1.3
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-24 11:47:19 +02:00
Ken a7a70ea5fd 🐛 LinkCard did not spread remaining props and classNames (#3902) 2025-06-24 11:42:37 +02:00
Ken 05fc8c1b2b [Website darkside] A11y review fixes (#3899)
* 💄 Update skiplink border-radius

* 📝 Shorten theme-switch text

* 📝 Labeled code-blocks

* 🐛 h2 -> span for overview card titles
2025-06-23 15:22:52 +02:00
Halvor Haugan b94db15f64 [website] 🔥 Remove unused prop showChangelogLink in TableOfContents.tsx 2025-06-23 12:40:05 +02:00
Ken 29716eba25 📝 Added descriptions to LinkCard examples 2025-06-23 12:14:54 +02:00
Halvor Haugan ca274bebb5 [website] Adjust examples of Table (#3896) 2025-06-23 10:38:37 +02:00
Ken 9ff6970432 💄 Add spacing around replications example 2025-06-23 10:23:14 +02:00
KenandHalvor Haugan 4916604973 [Components] LinkCard (#3883)
* ✨ LinkCard boilerplate

* ✨ Initial setup copying code over from website

* :WIP: Story update

* ⚡ Working mouseevent solution

* 🎉 Standalone card utilities

* 🚚 Moved LinkAnchor utility to separate file

* 💄 Add card css

* 💄 Grid-layout

* 🐛 visited text had wrong color

* 💄 Adjust animations

* 📝 Image sub-component docs

* 📝 LinkCard Stories

* 💄 Add support for data.colors

* 📝 Support chromatic-view

* 📝 Ajust story-example

* 🏷️ Export LinkCard component trough package.json

* 🏷️ Setup sub-component exports

* 🚚 Extract utils into util-dir

* 🚚 Extract LinkAnchor CSS

* ✨ Added LinkCard and LinkAnchor support for legacy

* 📝 Added LinkCard to CSS mappings

* ✨ Add size-prop to title and description

* 📝 Added stories for sizing-prop added to title and description

* ✨ Added size-support in Description

* 📝 Changeset

* ♻️ Update general sizing for type based on LinkCard size

* 📝 Adde uu-demo for testing

* 🐛 Resolve Modal-story bug

* ♻️ Re-write nested CSS in legacy to support postcss

* 📝 JSDoc

* 🐛 Add use-client

* 🎉 Implemented LinkCard Primitive

* ⚰️ Remove LinkCardPrimitive experiment

* 🎉 Compose onClick-events in Anchor util

* 🐛 Remove old stories

* 🏷️ Require href when not using asChild

* Update @navikt/core/react/src/link-card/LinkCard.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ Code review cleanup

* 🚚 Move isTextSelected util

* [Examples] Linkcard examples (#3886)

* 📝 LinkCard example code

* ♻️ Avoid rendering arrow when hasArrow is false

* ♻️ Make user add their own img-tag in LinkCard

* 🐛 Allow image to define its own with do avoid CLS when loading

* 🐛 Legacy CSS for linkcard was not synced with darkside

* 📝 More examples

* 📝 Update examples

* 📝 Add example for umami-logging

* ♻️ hasArrow -> arrow

* ♻️ Clean up unused word wrapping css

* 🐛 Center icon when only title is used

* 📝 Added jsdoc directly on sub-components

* 🚚 Moved LinkPanel to deprecated status

* 📝 Added new stories to chromatic

* Update @navikt/core/css/link-card.css

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/css/link-card.css

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/css/darkside/link-card.darkside.css

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 En -> nb

* 🐛 Use static images to avoid false hits from chromatic

* ⏪ Undo current Link-card css changes

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-06-23 09:53:07 +02:00
github-actions[bot] 13b03b1b30 Version Packages (#3884)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-06-23 09:40:17 +02:00
Ken 15655f0664 [Darkside] Padding update round ? (#3864)
* 💄 Padding adjustments

* 💄 Padding adjustments v2

* 📝 Changeset

* 💄 Update formsummary-header padding
2025-06-20 10:57:40 +02:00
Ken 35cf26b934 🐛 Outline-tag had light on light text-color in forced-color mode (#3889) 2025-06-19 10:22:18 +02:00
Julian NymarkandKen 941f67f5da add ghep (#3887)
* add ghep

* silence dependabot

* Update .nais/teams.yaml

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2025-06-19 09:30:06 +02:00
Halvor Haugan 7ebc9e6240 LICENSE: NAV -> Nav 2025-06-18 12:14:58 +02:00
Halvor Haugan 1ab496960d [website] NAV -> Nav (#3888) 2025-06-18 12:02:12 +02:00
Julian Nymark 43f34b2b33 🎨 deno cleanup (#3875) 2025-06-18 09:09:31 +02:00
Halvor Haugan ad9328a577 Form components: Fix edge case where description container would take up space when empty (#3866) 2025-06-17 15:54:33 +02:00
github-actions[bot] 8a415ef153 Version Packages (#3874)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-06-17 15:37:50 +02:00
Julian Nymark f29eac85b4 add script to use turbo (#3876) 2025-06-16 15:41:37 +02:00
Halvor Haugan 872fe00444 [website] Fix layout issues in Timeline examples (#3880) 2025-06-16 15:07:15 +02:00
Halvor Haugan cd9078da6c Upgrade packages in /examples (#3877) 2025-06-16 15:04:28 +02:00
Halvor Haugan 32c1423715 Bump react-router til v7 (#3878) 2025-06-16 15:04:04 +02:00
Ken 5662b35ea2 🐛 Close Search and mobile-sidebar when navigating to new link. (#3863) 2025-06-16 12:28:06 +02:00
KenandHalvor Haugan 9345f4d88f [Aksel.nav.no] Sidebar design sync (#3855)
* 💄 Update sidebar design to match figma

* 💄 Add sparkles-icon to highlighted sidebar sections

* 💄 Add gap between sidebar-items

* 💄 Animated highlighted border

* 🐛 Data-color-role -> data-color

* 🐛 Avoid double shadow for highligted items

* 💄 Add hover-color effect

* Update aksel.nav.no/website/app/dev/(designsystemet)/_ui/sidebar/Sidebar.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 Mobile-nav item was transparent, showing element behind when sticky

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-06-16 12:26:45 +02:00
Ken f0b05992b9 🐛 Use updated data-color concept for clearButton 2025-06-16 12:17:59 +02:00
KenandHalvor Haugan 64d980ef1c [Aksel.nav.no] Sidebar searchfield (#3854)
* 🎉 Added input filtering to sidebar

* 🐛 Clearbutton set to false now correctly avoids rendering button in Search for darkside

* 🎉 Respect section name in search

* 🐛 Remove autocomplete from sidebar-search

* Update .changeset/cyan-hoops-hope.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/app/dev/(designsystemet)/_ui/sidebar/Sidebar.nav.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Optimize sidebar-update on slow devices

* ♻️ Extract ClearButton component

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-06-16 11:52:23 +02:00
github-actions[bot] 79af062908 Version Packages (#3810)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-06-16 11:39:33 +02:00
Ken 8b80437c85 📝 Removed non-working links for changeset 2025-06-16 11:06:06 +02:00
Ken a0fdfcad85 💄 Use static bg-color for outline-variant in Tag (#3865) 2025-06-16 10:24:00 +02:00
Halvor Haugan 5de464f6c5 [website] Adjust examples of Link and InternalHeader (#3868) 2025-06-16 10:18:32 +02:00
Ken eb251b8d92 [Aksel.nav.no] Overview sidebar icon (#3853)
* ✨ Added new icons SquareGrid

* 💄 Add overview-icon to menu-items
2025-06-16 09:35:36 +02:00
89717dbb96 [Aksel.nav.no] Root overview-page in sidebar (#3848)
* 🎉 Added root overivew-page for monster-maler

* 🎉 Added root-overview page to sidebar

* Update aksel.nav.no/website/app/dev/(designsystemet)/monster-maler/page.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update aksel.nav.no/website/app/dev/(designsystemet)/monster-maler/page.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 🏷️ Updated types

* Update aksel.nav.no/website/app/dev/(designsystemet)/monster-maler/page.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-06-11 14:16:16 +02:00
Ken 5549cf6f7c 💄 More noticable link-styling for frontpage-hero 2025-06-10 20:47:57 +02:00
Ken 3f506754a2 ♻️ Removed reduntant wrapper 2025-06-10 20:35:48 +02:00
Ken 8730d7a7db 🐛 Avoid scrolling to last example when page includes multiple examples (#3852) 2025-06-10 12:17:32 +02:00
KenandHalvor Haugan 14c2490224 [Examples] Sliding window example for Timeline (#3847)
* :ai: Vibe-code periode status generation

* 📝 Document timeline example

* 📝 Add aria-controls to example

* 🎉 Example periods are more static now

* Update aksel.nav.no/website/pages/eksempler/timeline-intern/dynamic.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-06-10 12:17:05 +02:00
Halvor Haugan c8a96e7816 Fix issues caused by CSS transpilation, and use LightningCSS to build Storybook (#3850) 2025-06-10 11:19:13 +02:00
Ken 0932335a9e ✨ Added new icons SquareGrid (#3851) 2025-06-10 10:05:51 +02:00
Ken 3c01e1cada ✨ Change page-font when searching for spesific font (#3856) 2025-06-10 10:03:20 +02:00
Ken 3215cac4ad 🐛 Remove extra spacing caused by empty div for Card 2025-06-06 13:55:26 +02:00
Ken 6f98e50669 💄 Update frontpage-banner to sync with figma 2025-06-06 13:46:01 +02:00
Ken bb6b22f2f2 💄 Truncate linkcard-descriptions 2025-06-06 13:41:14 +02:00
fcf11110bb [Aksel darkside] forsiden (#3761)
* 🚧 initial conversion++

* Hero + color animation

* 🚧 infinitely loading?

* 🚧 loading 2/?

* ✨ GpFrontpageCard

* typing++

* regen query types

* disable turbopack

* animations work in dark & light, but if you toggle they get out of sync

* sync animations

* tone down the lines

* page + gpfrontpagecard

* move + use godPraksisPictogram

* 🚧 frontpageLatest

* convert the masonry stuff (wip)

* wip cards (masonry)

* wip cards (masonry)

* wip cards (masonry)

* mostly complete masonry

* cleanup

* tweak widths, better hierarchy with pageblock

* fix broken cube animation

* do not add stylelint rules in this PR

* bit of css insanity to block out the cube animation further down

* use LinkCard for latest news

* hero heading spacing and line height

* colors (gradient and cube) + heroText responsive size

* cube strokes respect pauseAnimation & mobile & responsive icons in gp

* working context state for pausing animations

* LinkCard usage++

* card transition animation fix

* use SEO image (opengraph)

* link fixes (use our Link with as={NextLink})

* design review fixes (#3816)

* minor gradient CSS tweak

* missing border-radius clip on gp og image

* Update Hero.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update Highlight.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update GpFrontpageCard.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update GpFrontpageCard.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update landingpage.module.css

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* PR comment fixes

* sync jsdom dep across workspaces

* ♻️ move and rename components to make more sense

* ♻️

* use non legacy Image + alt texts

* semantic html++ (li inside ul)

* LinkCard can be non-heading

* redundant screenreader info

* simplify shouldStopAnimation a fair bit

* useMemo

* copy cube to /dev/_ui/

* cleanup css

* remove unused CSS use globals.css data- attrib

* use hgrid

* add metadata/OG + minor css cleanup

* use existing LinkCardAnchor + tweak margin for it

* use Layout Component + rename variable

* update:sanity-schema

* improved typing

* type GpFrontpageCard

* redundant className

* LinkCard tweaks

* ♻️ broken file import + 🔥 comment

* better comment to explain hardcoded color values

* add missing type from query

* comments + og title

* fix highlighted cards alignment

* typing++

* 🚧 typing...

* good typing

* update query

* sort might fail if publishedAt is missing, but it should be

* typing++

* typing++

* 🐛 Div -> section for highlighted articles

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-06-06 13:33:09 +02:00
Ken 5917ab1a7e 🔍 Added RSS-link to root metadata (#3844) 2025-06-06 13:31:20 +02:00
77129e8b6f [Darkside] Dynamic color theming (#3849)
* 🎉 Allow data-color-role to override Button variant prop (#3805)

* :WIP: base-role theming for button

* 💄 Reorganize button styles in 'button.darkside.css' for clarity

* 📝 Changeset

* 📝 Pilot changeset

* 🔥 Removed duplicate CSS class

* Update .changeset/tricky-cobras-hide.md

* Update .changeset/tricky-cobras-hide.md

* 💄 Accent is now set as default base color theme (#3809)

* 💄 Accent is now set as default base color theme

* Update .changeset/plenty-areas-lick.md

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 📝 Better documentation

* Update .changeset/plenty-areas-lick.md

* Update @navikt/core/tokens/darkside/index.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* [Darkside] Base theming components part 1 (#3812)

* 💄 Accent is now set as default base color theme

* 💄 Accordion base-theming

* Update .changeset/plenty-areas-lick.md

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 📝 Better documentation

* 🎉 Base theming for ActionMenu

* ♻️ Base-theming Alert

* ♻️ Base-theming Chat

* ♻️ Base-theming Chips

* ♻️ Base-theming Datepicker

* ♻️ Base-theming Dropdown

* ♻️ Base-theming ExpansionCard

* ♻️ Base-theming GuidePanel

* ♻️ Add color role stories to chromatic

* ♻️ Base-theming HelpText

* ♻️ Base-theming Link

* ♻️ Base-theming Loader

* ♻️ Base-theming Pagination

* ♻️ Base-theming ProgressBar

* ♻️ Base-theming ReadMore

* ♻️ Base-theming Stepper

* ♻️ Base-theming Table

* ♻️ Base-theming Table

* ♻️ Base-theming Tabs

* ♻️ Base-theming Timeline

* ♻️ Base-theming ToggleGroup

* ♻️ Base-theming Typo

* ♻️ Base-theming Checkbox

* ♻️ Base-theming Radio

* ♻️ Base-theming Chips and Combobox

* ♻️ Base-theming Button and FileUpload

* ♻️ Base-theming FormProgress and ProgressBar

* ♻️ Base-theming FormSummary

* ♻️ Base-theming Search and TextField

* ♻️ Base-theming Select

* ♻️ Base-theming Switch and Loader

* ♻️ Base-theming TextArea

* 📝 Text change to trigger visual regression tests

* 🐛 Hide internal fileuoload story

* ♻️ re-use internal chromatic story in fileupload

* 🐛 ToggleChips did not respect global color roles

* 🧪 Better stories for color-role in accordion

* 🧪 Better stories for color-role in Link

* ♻️ Remove color-role prop extraction in button to simplify logic

* ♻️ Re-use same logic for ignoring default variant if not needed across components

* ♻️ Improve logic so that local undefined data-color-role avoids resetting internal data-color-role

* [Darkside] Base theming components Part 2 (#3832)

* 🚚 Changed 'data-color-role' to 'data-color'

* 🐛 Manually declare color-attrb in loader to avoid missing type

* 🐛 Update all stories to use new data-color name

* [Darkside] Base theming components Part 3 (#3835)

* 🏷️ Use locally declared color-type for components

* 🏷️ Exposed theme type trough package exports

* :WIP: theme setup

* 🏷️ Simplified type overrides

* 📝 Use local color-theme overrides

* 🐛 Use bg-raised for neutral expansioncard

* 💄 More noticable hover-effect for switch

* 🐛 Avoid adding undefined CSS class to link

* Update @navikt/core/react/src/accordion/accordion.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Added color-roles story to togglegroup chromatic

* 📝 Rename colorRole to color in Theme context

* 📝 Adjust stories

* [Darkside] Base theming components part 4 (#3836)

* 🏷️ Rename darkside token type exports

* 🚚 rename from public types to just types

* 🚚 Move space px list to internal types

* ♻️ Rename and clean up external type-definitions

* 🏷️ Use new type-definitions and names in components

* ♻️ Resolve circular dependency when importing internal types

* 🏷️ Better naming for token-types

* Update @navikt/core/tokens/types.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Story cleanup after review

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Update changeset

* 📝 Update changeset

* 📝 Storybook changelog

* Update .storybook/docs/PilotsChangelog.mdx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Doc-updates

* Update .changeset/darkside-3.md

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-06-06 13:16:47 +02:00
KenandCopilot fad1e962e8 [Aksel.nav.no] Added "Rediger side" button to footer (#3845)
* 📝 Rename draftmode hook destructure

* 🎉 Added edit-page button in footer for easier edit-access

* Update aksel.nav.no/website/app/_ui/footer/Footer.edit.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-06-04 16:14:48 +02:00
Halvor Haugan fcb5858388 [website darkside] Fix example chips in preview mode by adding stegaClean 2025-06-04 11:55:44 +02:00
KenandHalvor Haugan d70d4c9840 ✨ Now auto-scrolls to examples when navigated to. (#3837)
* ✨ Now auto-scrolls to examples when navigated to

* ♻️ Always scroll, even when example was already selected

* Update aksel.nav.no/website/app/_ui/kode-eksempler/KodeEksempler.provider.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 Avoid re-focusing example from side-effects

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-06-04 09:52:36 +02:00
Ken 4c00ffcf04 💄 Default to system-scheme for initial page-load (#3843) 2025-06-04 09:52:12 +02:00
Julian Nymark 81c246d33e 🐛 focus on many texts fail on contrast (#3846)
* 🐛 focus on many texts fail on contrast

* use focus-visible
2025-06-04 09:51:06 +02:00
Ken ee5598bdb4 🐛 Avoid resize-handle going out of bounds in code-examples 2025-06-03 13:54:23 +02:00
dependabot[bot] 7e822303ac ⬆️ Bump the npm_and_yarn group with 2 updates (#3842)
Bumps the npm_and_yarn group with 2 updates: [esbuild](https://github.com/evanw/esbuild) and [tar-fs](https://github.com/mafintosh/tar-fs).


Updates `esbuild` from 0.25.4 to 0.25.5
- [Release notes](https://github.com/evanw/esbuild/releases)
- [Changelog](https://github.com/evanw/esbuild/blob/main/CHANGELOG.md)
- [Commits](https://github.com/evanw/esbuild/compare/v0.25.4...v0.25.5)

Updates `tar-fs` from 2.1.2 to 2.1.3
- [Commits](https://github.com/mafintosh/tar-fs/commits)

---
updated-dependencies:
- dependency-name: esbuild
  dependency-version: 0.25.5
  dependency-type: direct:development
  dependency-group: npm_and_yarn
- dependency-name: tar-fs
  dependency-version: 2.1.3
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-03 11:49:16 +02:00
dependabot[bot] efe467dced ⬆️ Bump browserslist from 4.24.5 to 4.25.0 (#3839)
Bumps [browserslist](https://github.com/browserslist/browserslist) from 4.24.5 to 4.25.0.
- [Release notes](https://github.com/browserslist/browserslist/releases)
- [Changelog](https://github.com/browserslist/browserslist/blob/main/CHANGELOG.md)
- [Commits](https://github.com/browserslist/browserslist/compare/4.24.5...4.25.0)

---
updated-dependencies:
- dependency-name: browserslist
  dependency-version: 4.25.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-03 11:41:49 +02:00
dependabot[bot]andKen 8d7e8d0182 ⬆️ Bump react-day-picker from 9.6.1 to 9.7.0 (#3820)
* ⬆️ Bump react-day-picker from 9.6.1 to 9.7.0

Bumps [react-day-picker](https://github.com/gpbl/react-day-picker) from 9.6.1 to 9.7.0.
- [Release notes](https://github.com/gpbl/react-day-picker/releases)
- [Changelog](https://github.com/gpbl/react-day-picker/blob/main/CHANGELOG.md)
- [Commits](https://github.com/gpbl/react-day-picker/compare/v9.6.1...v9.7.0)

---
updated-dependencies:
- dependency-name: react-day-picker
  dependency-version: 9.7.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* 📝 Changeset

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-06-03 11:31:57 +02:00
Halvor Haugan b242700ec1 [Aksel darkside] Designsystemet: Adjust inline padding on mobile (#3841) 2025-06-03 10:12:20 +02:00
Ken 0e99e7bb5f 💄 More spacing between Heading and Ingress for god-praksis articles 2025-05-28 14:22:12 +02:00
Halvor Haugan 9bec9a45c1 [website] Adjustments in various examples (#3833) 2025-05-28 11:50:58 +02:00
Ken cd7f03ef40 [Tokens] Hide temp radius tokens from docs, add strong to markdown-parser (#3815)
* ♻️ Added feature to hide induvidual tokens from token-documentations by config

* 🎉 Added strong/bold-text support in custom markdown parser
2025-05-28 11:48:21 +02:00
Ken de9afbd6c6 ♿ Removed aria-haspopup from Timeline for improved SR experience (#3834) 2025-05-27 15:20:31 +02:00
Ken 6666e8cd25 🐛 Use default focus-shadow in hero-banner 2025-05-27 12:33:48 +02:00
Ken 13353f032c 💄 Update hero-banner with transparent bg 2025-05-27 12:32:34 +02:00
Halvor Haugan ddef199700 Skip Endringslogg when running Axe (#3830) 2025-05-27 11:34:35 +02:00
dependabot[bot]andKen bba2a486c4 ⬆️ Bump @figma/rest-api-spec from 0.19.0 to 0.30.0 (#3822)
* ⬆️ Bump @figma/rest-api-spec from 0.19.0 to 0.30.0

Bumps [@figma/rest-api-spec](https://github.com/figma/rest-api-spec) from 0.19.0 to 0.30.0.
- [Commits](https://github.com/figma/rest-api-spec/commits)

---
updated-dependencies:
- dependency-name: "@figma/rest-api-spec"
  dependency-version: 0.30.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* 🐛 Use non-deprecated types

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-05-27 10:32:11 +02:00
Halvor Haugan 5c8af30209 Adjust form validation pattern examples (#3829) 2025-05-27 10:22:15 +02:00
Ken 03395ae8a1 🐛 Reverted regression that lead to 'aria-controls' being ignored (#3828)
* 🐛 Reverted regression that lead to 'aria-controls' being ignored when passed to Pin or Period.

* 🐛 Add role='dialog' to timeline popover
2025-05-27 10:01:07 +02:00
Ken 6b4813fb74 🏷️ Fix type-errors in PropSeksjon 2025-05-27 10:00:11 +02:00
Ken 14978c1bf9 🐛 Avoid double quotes in prop-table default value 2025-05-26 16:24:13 +02:00
Ken 859d4c309d 📝 Prepare redirects for designsystemet routing update 2025-05-26 16:20:52 +02:00
Halvor Haugan 885f1eb75b Sync jsdom versions (#3825) 2025-05-26 14:27:51 +02:00
Sjur ec814f3387 Update global.tokens.ts (#3826)
-  Justerte kontrast på fargen 600 (4.51:1 i Leonardo), noen farger er endret.
-  La inne MetaPurple i DS Leonardo-fil. Det førte til små justeringer av fargene.
2025-05-26 13:10:52 +02:00
Halvor Haugan fd6176c3bf [website] Script for creating a doc per version in changelog (#3811) 2025-05-26 11:56:50 +02:00
KenandCopilot 10aa9710d9 💄 ErrorSummary heading is now size 'xsmall' on smaller sizes (#3806)
* 💄 ErrorSummary heading is now size 'xsmall' on smaller sizes

* Update .changeset/grumpy-melons-grab.md

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-05-21 14:43:31 +02:00
Halvor Haugan fc332df41e [website] Add field for alt text on ds_endringslogg_artikkel (#3814) 2025-05-21 11:59:18 +02:00
Halvor Haugan bc00c89801 Upgrade transitive dependencies (#3813) 2025-05-20 14:32:27 +02:00
Ken 9f5beaa042 🐛 Avoid sharp-corner borders overlapping outside border 2025-05-19 15:25:21 +02:00
Ken 07314ee30f [Appdir] 🎉 Allow for unique hardcoded pages to appear in global search (#3791)
* 🎉 Allow for unique hardcoded pages to appear in global search

* 🐛 Code cleanup

* 📝 Use page metadata for search metadata in routing config

* 🐛 Resolve null-check type error
2025-05-19 15:14:17 +02:00
Ken 14d606f5b6 💄 Removed uppdercase from GP-article eyebrow 2025-05-19 14:51:16 +02:00
Ken d6a1ae66f3 🐛 Limit headings to data-text-prose from CMS.
🐛 Limit headings to data-text-prose from DS-pages

🐛 Use BodyLong for GP intro text

🐛 Code-typo now scales with font-size
2025-05-19 14:46:16 +02:00
Ken 988e4472cd 🎉 Allow data-color-role to override Tag variant prop. (#3795)
* 🎉 Allow data-color-role to override Tag variant prop.

* 🚚 Move color-definition to Tag props internals, requiring explisit use of data-color-role for re-coloring

* ♻️ Simplified Tag.darkside.css to reflect future coloring syntax

* 🐛 Fix forced-color 'color'-hierarcy

* 📝 Update changeset
2025-05-19 14:29:14 +02:00
github-actions[bot] bbc44541d7 Version Packages (#3794)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-05-19 14:20:54 +02:00
Halvor Haugan a252f879e1 Fix Storybook warning about addon order (#3808) 2025-05-19 14:16:05 +02:00
dependabot[bot]andKen ccf0c20d33 ⬆️ Bump vite from 5.4.19 to 6.1.6 in the npm_and_yarn group (#3807)
* ⬆️ Bump vite from 5.4.19 to 6.1.6 in the npm_and_yarn group

Bumps the npm_and_yarn group with 1 update: [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).


Updates `vite` from 5.4.19 to 6.1.6
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v6.1.6/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v6.1.6/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 6.1.6
  dependency-type: direct:development
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>

* ♻️ Sync vite v6 across repository

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-05-19 12:53:26 +02:00
dependabot[bot]andKen e1370102bb ⬆️ Bump the npm_and_yarn group with 5 updates (#3793)
Bumps the npm_and_yarn group with 5 updates:

| Package | From | To |
| --- | --- | --- |
| [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) | `5.4.18` | `5.4.19` |
| [axios](https://github.com/axios/axios) | `1.8.4` | `1.9.0` |
| [http-proxy-middleware](https://github.com/chimurai/http-proxy-middleware) | `2.0.7` | `2.0.9` |
| [tar-fs](https://github.com/mafintosh/tar-fs) | `2.1.1` | `2.1.2` |
| [undici](https://github.com/nodejs/undici) | `5.28.5` | `5.29.0` |


Updates `vite` from 5.4.18 to 5.4.19
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v5.4.19/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.4.19/packages/vite)

Updates `axios` from 1.8.4 to 1.9.0
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](https://github.com/axios/axios/compare/v1.8.4...v1.9.0)

Updates `http-proxy-middleware` from 2.0.7 to 2.0.9
- [Release notes](https://github.com/chimurai/http-proxy-middleware/releases)
- [Changelog](https://github.com/chimurai/http-proxy-middleware/blob/v2.0.9/CHANGELOG.md)
- [Commits](https://github.com/chimurai/http-proxy-middleware/compare/v2.0.7...v2.0.9)

Updates `tar-fs` from 2.1.1 to 2.1.2
- [Commits](https://github.com/mafintosh/tar-fs/compare/v2.1.1...v2.1.2)

Updates `undici` from 5.28.5 to 5.29.0
- [Release notes](https://github.com/nodejs/undici/releases)
- [Commits](https://github.com/nodejs/undici/compare/v5.28.5...v5.29.0)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 5.4.19
  dependency-type: direct:development
  dependency-group: npm_and_yarn
- dependency-name: axios
  dependency-version: 1.9.0
  dependency-type: direct:production
  dependency-group: npm_and_yarn
- dependency-name: http-proxy-middleware
  dependency-version: 2.0.9
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: tar-fs
  dependency-version: 2.1.2
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: undici
  dependency-version: 5.29.0
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2025-05-19 12:44:48 +02:00
dependabot[bot]andKen 50bd475f25 ⬆️ Bump the npm_and_yarn group across 4 directories with 2 updates (#3792)
* ⬆️ Bump the npm_and_yarn group across 4 directories with 2 updates

Bumps the npm_and_yarn group with 1 update in the /examples/astro directory: [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).
Bumps the npm_and_yarn group with 1 update in the /examples/next-appdir directory: [next](https://github.com/vercel/next.js).
Bumps the npm_and_yarn group with 1 update in the /examples/referansesider directory: [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).
Bumps the npm_and_yarn group with 1 update in the /examples/shadow-dom directory: [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).


Updates `vite` from 5.4.15 to 5.4.19
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v5.4.19/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.4.19/packages/vite)

Updates `next` from 15.2.3 to 15.2.4
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/compare/v15.2.3...v15.2.4)

Updates `vite` from 5.4.15 to 5.4.19
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v5.4.19/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.4.19/packages/vite)

Updates `vite` from 5.4.15 to 5.4.19
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v5.4.19/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.4.19/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 5.4.19
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: next
  dependency-version: 15.2.4
  dependency-type: direct:production
  dependency-group: npm_and_yarn
- dependency-name: vite
  dependency-version: 5.4.19
  dependency-type: direct:development
  dependency-group: npm_and_yarn
- dependency-name: vite
  dependency-version: 5.4.19
  dependency-type: direct:development
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>

* ♻️ Sync yarn lock and package versions across workspace

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-05-19 12:43:01 +02:00
Halvor Haugan 6578f5d2dd [website] Add schema for changelog entries (#3796) 2025-05-19 12:35:34 +02:00
dependabot[bot] 349f184368 ⬆️ Bump the storybook group with 16 updates (#3802)
Bumps the storybook group with 16 updates:

| Package | From | To |
| --- | --- | --- |
| [@storybook/addon-a11y](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/a11y) | `8.6.12` | `8.6.14` |
| [@storybook/addon-essentials](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/essentials) | `8.6.12` | `8.6.14` |
| [@storybook/addon-interactions](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/interactions) | `8.6.12` | `8.6.14` |
| [@storybook/addon-storysource](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/storysource) | `8.6.12` | `8.6.14` |
| [@storybook/addon-themes](https://github.com/storybookjs/storybook/tree/HEAD/code/addons/themes) | `8.6.12` | `8.6.14` |
| [@storybook/blocks](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/blocks) | `8.6.12` | `8.6.14` |
| [@storybook/csf-tools](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/csf-tools) | `8.6.12` | `8.6.14` |
| [@storybook/manager-api](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/manager-api) | `8.6.12` | `8.6.14` |
| [@storybook/nextjs](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/nextjs) | `8.6.12` | `8.6.14` |
| [@storybook/react](https://github.com/storybookjs/storybook/tree/HEAD/code/renderers/react) | `8.6.12` | `8.6.14` |
| [@storybook/react-vite](https://github.com/storybookjs/storybook/tree/HEAD/code/frameworks/react-vite) | `8.6.12` | `8.6.14` |
| [@storybook/test](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/test) | `8.6.12` | `8.6.14` |
| [@storybook/theming](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/theming) | `8.6.12` | `8.6.14` |
| [eslint-plugin-storybook](https://github.com/storybookjs/eslint-plugin-storybook) | `0.9.0` | `0.12.0` |
| [storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/lib/cli) | `8.6.12` | `8.6.14` |
| [storybook-addon-pseudo-states](https://github.com/chromaui/storybook-addon-pseudo-states) | `4.0.3` | `4.0.4` |


Updates `@storybook/addon-a11y` from 8.6.12 to 8.6.14
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.6.14/code/addons/a11y)

Updates `@storybook/addon-essentials` from 8.6.12 to 8.6.14
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/v8.6.14/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.6.14/code/addons/essentials)

Updates `@storybook/addon-interactions` from 8.6.12 to 8.6.14
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/v8.6.14/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.6.14/code/addons/interactions)

Updates `@storybook/addon-storysource` from 8.6.12 to 8.6.14
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/v8.6.14/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.6.14/code/addons/storysource)

Updates `@storybook/addon-themes` from 8.6.12 to 8.6.14
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.6.14/code/addons/themes)

Updates `@storybook/blocks` from 8.6.12 to 8.6.14
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/v8.6.14/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.6.14/code/lib/blocks)

Updates `@storybook/csf-tools` from 8.6.12 to 8.6.14
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.6.14/code/lib/csf-tools)

Updates `@storybook/manager-api` from 8.6.12 to 8.6.14
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.6.14/code/lib/manager-api)

Updates `@storybook/nextjs` from 8.6.12 to 8.6.14
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.6.14/code/frameworks/nextjs)

Updates `@storybook/react` from 8.6.12 to 8.6.14
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.6.14/code/renderers/react)

Updates `@storybook/react-vite` from 8.6.12 to 8.6.14
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.6.14/code/frameworks/react-vite)

Updates `@storybook/test` from 8.6.12 to 8.6.14
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/v8.6.14/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.6.14/code/lib/test)

Updates `@storybook/theming` from 8.6.12 to 8.6.14
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.6.14/code/lib/theming)

Updates `eslint-plugin-storybook` from 0.9.0 to 0.12.0
- [Release notes](https://github.com/storybookjs/eslint-plugin-storybook/releases)
- [Changelog](https://github.com/storybookjs/eslint-plugin-storybook/blob/main/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/eslint-plugin-storybook/compare/v0.9.0...v0.12.0)

Updates `storybook` from 8.6.12 to 8.6.14
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/v8.6.14/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v8.6.14/code/lib/cli)

Updates `storybook-addon-pseudo-states` from 4.0.3 to 4.0.4
- [Release notes](https://github.com/chromaui/storybook-addon-pseudo-states/releases)
- [Changelog](https://github.com/storybookjs/storybook-addon-pseudo-states/blob/v4.0.4/CHANGELOG.md)
- [Commits](https://github.com/chromaui/storybook-addon-pseudo-states/compare/v4.0.3...v4.0.4)

---
updated-dependencies:
- dependency-name: "@storybook/addon-a11y"
  dependency-version: 8.6.14
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-essentials"
  dependency-version: 8.6.14
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-interactions"
  dependency-version: 8.6.14
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-storysource"
  dependency-version: 8.6.14
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/addon-themes"
  dependency-version: 8.6.14
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/blocks"
  dependency-version: 8.6.14
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/csf-tools"
  dependency-version: 8.6.14
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/manager-api"
  dependency-version: 8.6.14
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/nextjs"
  dependency-version: 8.6.14
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react"
  dependency-version: 8.6.14
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/react-vite"
  dependency-version: 8.6.14
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/test"
  dependency-version: 8.6.14
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: "@storybook/theming"
  dependency-version: 8.6.14
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: eslint-plugin-storybook
  dependency-version: 0.12.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: storybook
- dependency-name: storybook
  dependency-version: 8.6.14
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
- dependency-name: storybook-addon-pseudo-states
  dependency-version: 4.0.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: storybook
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-05-19 11:53:03 +02:00
dependabot[bot] 846df9e93e ⬆️ Bump browserslist from 4.24.4 to 4.24.5 (#3797)
Bumps [browserslist](https://github.com/browserslist/browserslist) from 4.24.4 to 4.24.5.
- [Release notes](https://github.com/browserslist/browserslist/releases)
- [Changelog](https://github.com/browserslist/browserslist/blob/main/CHANGELOG.md)
- [Commits](https://github.com/browserslist/browserslist/compare/4.24.4...4.24.5)

---
updated-dependencies:
- dependency-name: browserslist
  dependency-version: 4.24.5
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-05-19 11:51:00 +02:00
dependabot[bot] b794101d4f ⬆️ Bump vite-plugin-singlefile from 1.0.0 to 2.2.0 (#3803)
Bumps [vite-plugin-singlefile](https://github.com/richardtallent/vite-plugin-singlefile) from 1.0.0 to 2.2.0.
- [Release notes](https://github.com/richardtallent/vite-plugin-singlefile/releases)
- [Changelog](https://github.com/richardtallent/vite-plugin-singlefile/blob/main/CHANGELOG.md)
- [Commits](https://github.com/richardtallent/vite-plugin-singlefile/commits)

---
updated-dependencies:
- dependency-name: vite-plugin-singlefile
  dependency-version: 2.2.0
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-05-19 11:50:12 +02:00
dependabot[bot]andKen 3f71ade9ad ⬆️ Bump color from 4.2.3 to 5.0.0 (#3798)
* ⬆️ Bump color from 4.2.3 to 5.0.0

Bumps [color](https://github.com/Qix-/color) from 4.2.3 to 5.0.0.
- [Release notes](https://github.com/Qix-/color/releases)
- [Commits](https://github.com/Qix-/color/compare/4.2.3...5.0.0)

---
updated-dependencies:
- dependency-name: color
  dependency-version: 5.0.0
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* 🔥 Removed unused color depdendency

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-05-19 11:48:01 +02:00
Ken 67c6d88372 🐛 Updated and published Icon-plugin for Figma 2025-05-19 11:44:28 +02:00
Halvor Haugan 17437d4007 Add some groups to dependabot config (#3801) 2025-05-19 09:35:29 +02:00
Ken 84b8d1612a 🐛 Avoid overriding button-styles on website 2025-05-19 09:20:21 +02:00
Ken fe2feb9888 🐛 Avoid overriding link-styles for pages-router 2025-05-16 14:10:30 +02:00
Halvor Haugan 635277b657 Typos in changesets 2025-05-16 09:27:02 +02:00
Ken 1619b52008 [Darkside] Radius and text-icon token update (#3784)
* 🎉 Rename border-radius tokens to radius with number-naming

* 🔥 Remove border-radius token from darkside tailwind config

* 🚚 Rename border-radius tokens

* 🏷️ Text-icon renamed to text-decoration

* ♻️ Update auto-migration to new decoration token

* ♻️ Migrate text-icon -> text-decoration in components

* ♻️ Allow migrating to default tailwind rounded-tag from legacy aksel-token

* 🔥 Removed throw error for using legacy border-radius token i box

* 📝 Update types to allow for legacy and updated border-radius

* ♻️ Allow for use of both legacy and updated radius token in box

* ♻️ Updated Box-migration to support space-delimited prop-values

* 📝 Changeset

* 📝 Darkside changelog

* 🐛 Add missing manual token-docs

* 🐛 Resolve not updated import after radius filename change

* Delete .changeset/big-goats-report-5.md

* ✨ Support space-separated radius tokens in primitives migration

* ♻️ Temp support legacy radius toke for darkside system
2025-05-15 19:47:20 +02:00
Ken 9018f85dbc 🚚 Update icons to handle updated fill-color from Figma. (#3790)
* ♻️ Rename new icon-color to currentColor

* 🚚 Update icons to handle updated fill-color from Figma.
2025-05-15 19:45:26 +02:00
KenandCopilot 3de59ff1d4 📝 Deprecate ConfirmationPanel (#3789)
* 📝 Deprecate ConfirmationPanel

* Update .changeset/chatty-things-yawn.md

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-05-15 19:40:44 +02:00
Ken baebfcea56 [Appdir] Adds theme-switcher with Select in code-examples (#3787)
* ✨ Add theming-switch for legacy and darkside themes

* 🎉 Adds theme-switch to code-examples

* Update aksel.nav.no/website/components/website-modules/examples/withDsExample.theme.tsx

* Update aksel.nav.no/website/components/website-modules/examples/withDsExample.theme.tsx

* 📝 Adde new cookie to docs

* 📝 Oppdatert select-tekster for theme-switch

* 🔥 Removed testcode

* 📝 Update personvernnserklæring with theming info
2025-05-15 19:22:21 +02:00
Ken 4bed5a8a59 [Appdir] Sitemap for new setup (#3779)
* :WIP: Sitemap

* Move manual page mapping

* 🎉 use global routing config for sidebar generation

* 🔥 Remove darkside styling from `Sidebar.group.tsx` and `Sidebar.module.css`

* ✨ Add unique/hardcoded pages to sitmap

* 🔥 Removed commented code

* 🐛 Stricter typing with 'as const' broke typechecking
2025-05-15 15:05:36 +02:00
Ken 76e325aa6c [Appdir] Thumbnail recoloring (#3776)
* ✨ Introduce ImageAsThemedSvg for SVG handling in ImageAsSvg.tsx

* 💄 Update background color for dark mode in DesignsystemetOverview.module.css

* 🎉 Use 'themed' thumbnails for ds-pages

* 💄 Change background color to var(--ax-bg-neutral-soft) in DesignsystemetOverview.module.css

* 💄 Move tag to top of overview-card

* 📝 yarn lock sync

* 💄 Tone down overview thumbnail preview

* 🔥 Remove arrow from overview cards

* ♻️ Show arrow on LinkCard
2025-05-15 14:47:40 +02:00
Ken ff3ee5e087 [Sanity] Sanity presentation mode (dev only) (#3772)
* ✨ Introduce `Studio` component in `Studio.tsx` and `page.tsx` for admin interface

* ♻️ Move Admin and tooling to app-router.

* 🔥 Remove `[[...index]].js` from `legacy-admin` directory

* ♻️ Update sanity to v3.86.1

* 🐛 Setup non-working presentation-mode for sanity

* ✨ Update resolver

* 🎉 Added iframe support for preview in tandem with presentation-mode

* ✨ Integrate `stegaClean` in multiple components for consistent data handling

* 🎉 Render exit draft button

* ✨ Allow for better admin controls and preview

* 🔒 Upgrade insecure requests in production-builds

* 🐛 Update next-sanity to resolve SanityClient type mismatch

* 🐛 Update sanity to 3.87 to fix mismatching sanityclient types

* 🐛 Clean iframe URL to avoid using encoded data, causing errors since url is to long

* ♻️ Use server actions to disable preview mode to stay on page after reload

* 🔥 Remove unused lint-command
2025-05-15 14:40:37 +02:00
Halvor Haugan 8235e8424d Add repository.directory in package.json for ds-react and ds-css (#3786) 2025-05-13 13:30:05 +02:00
Ken 201e96cf06 Biome cleanup (#3770)
* ♻️ Refactor `syncPosition` to use `useCallback` in `CompareImagesProvider`

* ♻️ Refactor dependencies in `GlobalSearchProvider` effect and debounce function

* ♻️ Refactor exports to use type syntax in multiple components

* ♻️ Refactor `articlesMap` access in `page.tsx` to use dot notation

* 🐛 Ignore autogenerated sanity types

* ♻️ Refactor selectedRange rendering in `input-range.tsx`, `input-single.tsx`, and `two-digit-year.tsx`

* ♻️ Refactor `updateConsent` to use `useCallback` in `CookieProvider.tsx`

* 🩹 Ignore lint warning for assignment in expressions

* ♻️ Avoid variable re-assignent in while-loops
2025-05-12 13:25:33 +02:00
dependabot[bot] 4a6ccbed90 ⬆️ Bump stylelint from 16.15.0 to 16.19.1 (#3781)
Bumps [stylelint](https://github.com/stylelint/stylelint) from 16.15.0 to 16.19.1.
- [Release notes](https://github.com/stylelint/stylelint/releases)
- [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint/compare/16.15.0...16.19.1)

---
updated-dependencies:
- dependency-name: stylelint
  dependency-version: 16.19.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-05-12 13:25:12 +02:00
dependabot[bot] f041ec859c ⬆️ Bump tsc-alias from 1.8.8 to 1.8.16 (#3783)
Bumps [tsc-alias](https://github.com/justkey007/tsc-alias) from 1.8.8 to 1.8.16.
- [Release notes](https://github.com/justkey007/tsc-alias/releases)
- [Commits](https://github.com/justkey007/tsc-alias/compare/v1.8.8...v1.8.16)

---
updated-dependencies:
- dependency-name: tsc-alias
  dependency-version: 1.8.16
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-05-12 13:22:58 +02:00
dependabot[bot] 152c99c1c2 ⬆️ Bump esbuild from 0.25.2 to 0.25.4 (#3782)
Bumps [esbuild](https://github.com/evanw/esbuild) from 0.25.2 to 0.25.4.
- [Release notes](https://github.com/evanw/esbuild/releases)
- [Changelog](https://github.com/evanw/esbuild/blob/main/CHANGELOG.md)
- [Commits](https://github.com/evanw/esbuild/compare/v0.25.2...v0.25.4)

---
updated-dependencies:
- dependency-name: esbuild
  dependency-version: 0.25.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-05-12 13:21:29 +02:00
Ken 193aaf54f5 Typescript 5.8.3 update (#3771)
* ⬆️ Upgrade typescript minor

* ⬆️ Upgrade typescript minor

* ⬆️ Update Tyepscript to 5.8.3

* 🐛 Resolve ts-update lint issues
2025-05-08 13:13:56 +02:00
Ken d7d7665416 🔒 Remove admin dev from robots.txt 2025-05-07 15:18:45 +02:00
a6db68aa86 Tokens page (#3747)
* Init new tokens page

* Add token display for (most of) color tokens. Still need a real display example for opaque++.

* Add TableOfContents

* Improve category handling of tokens and add space, radius and shadow

Less reduce and format category on backend

* Fix shadow token example

* Re-introduce role filtering

* Custom sorting for different token types

* Added placeholder comments with text "TODO: Sjur fyller ut" for all (hopefully?) tokens

* Sort token categories

* Add breakpoint tokens

* Make comments a bit smaller in line with the design

* Add font tokens

* Simplify token example code (DRY-principle)

* Remove fallback-comment and add a small gap between token name + rawValue and the comment

* Do not show rawValue for color tokens, as we do not want to encourage using them directly

* Fix issue where we could potentially return undefined from sorting function

* Add breakpoint groups for easily selecting mobile or desktop first media queries

* Simplify how we generate the display value for breakpoint tokens

* Ignore global-color and opacity tokens when generating token config. These will not be displayed on the webpage.

* Fix ToC import after change from main

* Move Tokens toolbar/filter/search to /components

* Add naive token search

* Extract Color token example

* Extract Shadow token example

* Extract Breakpoint token example

* Extract Radius token example

* Extract Space token example

* Extract Font token example

* Refactor TokenExample wrappers

* Extract TokenPreview

* Extract token categories config

* Extract TokenEntry - the presentation of an individual token

* Extract TokenCategory - a collection of of tokens, like background color, radius og font tokens

* Move function for sorting tokens to a util-file

* Don't add Chips wrapper if the category has no roles

* Extract chips for selecting roles

* [Token-docs] Static semantic colors with comments (#3661)

* ✨ Config to create files

* ✨ Config to create files

* ✨ Add semantic role token configurations for info, accent, and danger colors

* 🔧 Refactor semantic role token configuration for consistency

* Add config for token roles and categories. This eliminates the need for some sorting and prettifying of text for titles

* Beskrivelse av tokens på config.ts (#3692)

* Show role descriptions and accept markdown in descriptions for categories, roles and tokens

* This link shouldn't have been pushed

* Tokenbeskrivelse til tokens i mappa /semantic-roles (#3700)

* Update meta-lime.tokens.ts

* Tokenbeskrivelse for accent, brand-beige, brand-blue, brand-magenta og danger.

* Tokenbeskrivelse til info, meta-purple, neutral, success og warning.

* Update @navikt/core/tokens/darkside/tokens/colors/semantic-roles/brand-beige.tokens.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update @navikt/core/tokens/darkside/tokens/colors/semantic-roles/brand-blue.tokens.ts

* Update @navikt/core/tokens/darkside/tokens/colors/semantic-roles/warning.tokens.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update @navikt/core/tokens/darkside/tokens/colors/semantic-roles/accent.tokens.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update @navikt/core/tokens/darkside/tokens/colors/semantic-roles/brand-beige.tokens.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update @navikt/core/tokens/darkside/tokens/colors/semantic-roles/brand-beige.tokens.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update @navikt/core/tokens/darkside/tokens/colors/semantic-roles/neutral.tokens.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update @navikt/core/tokens/darkside/tokens/colors/semantic-roles/brand-blue.tokens.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update @navikt/core/tokens/darkside/tokens/colors/semantic-roles/brand-magenta.tokens.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update @navikt/core/tokens/darkside/tokens/colors/semantic-roles/brand-magenta.tokens.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update @navikt/core/tokens/darkside/tokens/colors/semantic-roles/brand-blue.tokens.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update @navikt/core/tokens/darkside/tokens/colors/semantic-roles/danger.tokens.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update @navikt/core/tokens/darkside/tokens/colors/semantic-roles/success.tokens.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update @navikt/core/tokens/darkside/tokens/colors/semantic-roles/meta-purple.tokens.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update @navikt/core/tokens/darkside/tokens/colors/semantic-roles/meta-lime.tokens.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update @navikt/core/tokens/darkside/tokens/colors/semantic-roles/accent.tokens.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update @navikt/core/tokens/darkside/tokens/colors/semantic-roles/info.tokens.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Migrate new tokens page to app router. Changed border and background colors without checking much, so may need to go through those later. Layout is also a bit messed up.

* Add ToC on tokens page

* Layout fixes

* Show "Send feedback" button

* Rename tokens-page.tsx -> TokensPage.tsx

* Use proper type for tokens on TokenPage

* Move search query to url params to allow for use on server side rendered page

* Improve token search by using Fuse

* Filter TableOfContents based on search results

* Add background for opaque tokens. Kinda weak determination that the token is opaque, so that may have to be improved.

* Update tokens to use new darkside tokens as appdir uses this CSS

* Remove default color presentation. Rather log the unknown category for debugging purposes.

* Add functionality for switching between JS and CSS tokens

* Align CopyButton better with text

* Fix search onSubmit, so it does not clear the input

* Use simple Search variant

* Hard-code page header for non-Sanity token-page

* Move darkside tokens page to correct slug (grunnleggende/styling/tokens-darkside) and include it in the left-hand menu

* Filter token roles chips based on search results, so we don't show chips for the roles that has no results

* Token search should ignore where in the results the hits are located, as there are no long texts. A hit is a hit!

* Change multiple instances of Record to just add an "id" property to the objects and place them in an array for easier interaction in the code

* Filter out placeholder token comments and remove placeholder category descriptions

* Move filtering out of the render function

* Add subheadings for roles, and move descriptions to under the subheadings. Also remove chips if there are only one.

* Adjust spacing for tokens list (distance between heading + description vs those and the following list)

* Update aksel.nav.no/website/components/token-docs/token/example/TokenEntry.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update aksel.nav.no/website/components/token-docs/token/example/TokenEntry.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Added comments to semantic-root.tokens.ts

* We omit comments for radius, breakpoint, font and space tokens, so comment needs to be optional

* Clarify shadow token use in comment

* Add EmptyStateCard when no tokens are shown

* Vertically center TokenPreview

* Fine-tune search thresholds to provide better results for typos

* Properly define a "root" role for unique tokens and show heading and description. The actual name may be changed later.

* Add support for LESS and SASS tokens as well

* Formatting (line-length)

* Stop setting selected role automatically if filtering causes only one role to be shown. We now remove the chips in this case and always show a heading and description instead.

* Remove "mobile first"/"desktop first" from displayed breakpoint token value, because it hinders copying the text. The same need is covered by the new role heading instead.

* Fix copy-pasted label for TokenFormatSelector

* Refine spacing in line with new Figma sketches to better group content

* Remove "Stabil" tag and "Last updated" text because they do not make sense here. They always apply to the latest version, and then we might have to document outdated tokens somewhere.

* Clean up tokens-darkside page.tsx: remove unnecessary generateStaticParams() and remove awaiting unused params

* Move type into token-docs folder as it is only used there

* Proper typography for token comment

* Reset selected role when searching

* Use static metadata for tokens page, as we don't have any sanity data/parent to receive data from

* Move new tokens page to the "darkside" category

* Remove TODO in description of Meta Purple

* Make Token role Chips neutral to not steal too much attention

* Fix issue where selecting a chip was reverted after half a second, so changed the useEffect to only react to the actual changed search query instead

* Fixed missing gap in mobile view

* Fix bug where changing to another format and back to CSS caused the token name to disappear

* Proper "eyebrow" above page heading (Changed styling -> grunnleggende and color)

* Co-locate tokens page components in app dir

* Use correct heading color for H1

* Update to new darkside tokens

* No longer used

* Add the vk-error class to fallback examples for tokens (where category, group, etc. is unknown) and log a warning in the console

* Add a name to the tokens role chips list, so we inform the user about what they filter

* Disable autocomplete, like for other search fields on the website (main- and icon search)

* Add the correct gap between categories

* Do not use heading tags for token examples to avoid messing with accessibility

* Translate category titles

* Fine-tune search weighting. Still needs more adjustments - likely sorting results, as a "similar result" can now appear before a direct result.

E.g. "avstand" -> Background colors with "standard" in a comment appears before the "Avstand" category tokens.

* Adjust scroll margin so search field is not shown for top category

* Hide token preview from assistive technology

* Add links to Slack and GitHub to "no tokens" block

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Sjur <82579704+sjur-gr@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-05-07 14:37:11 +02:00
Ken d5ca617a3b [Appdir] Support "top-level"-pages (#3757)
* 🎉 Support top level articles for designsystem-pages

* ♻️ Update slug handling, staticParams and metadata for overview-pages
2025-05-06 19:48:37 +02:00
Ken a623486b1f 🐛 Umami event racking added onClick handlers to server-components. Now has use client added where needed 2025-05-06 14:03:43 +02:00
KenandCopilot a1fb6f51e0 [Umami] Migrate from data-attrb based tracking to onClick (#3764)
* 🎉 Added umamiTrack function

* 🚚 Use new umamiTrack function to do manual tracking

* 🚚 Use manual umami tracking onClick for links and logging

* 🏷️ Stronger typing

* 🚚 Manually track URL for navigation events

* 🐛 Use empty object in non-descriptive umamiTrack events

* ⚡ Re-enable Umami

* Update aksel.nav.no/website/app/_ui/umami/Umami.log.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 📈 Track navigation events in `GpChip` and simplify URL handling in `page`

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-05-06 12:53:18 +02:00
github-actions[bot] 411ecd37c6 Version Packages (#3769)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-05-06 10:29:44 +02:00
Ken 2da8707a21 🐛 Omit onToggle from ExpansionCard types to avoid overlapping with new Popover API. (#3773) 2025-05-06 10:20:53 +02:00
dependabot[bot]andKen 39caf0bd12 ⬆️ Bump @floating-ui/react from 0.25.4 to 0.27.8 (#3768)
* ⬆️ Bump @floating-ui/react from 0.25.4 to 0.27.8

Bumps [@floating-ui/react](https://github.com/floating-ui/floating-ui/tree/HEAD/packages/react) from 0.25.4 to 0.27.8.
- [Release notes](https://github.com/floating-ui/floating-ui/releases)
- [Changelog](https://github.com/floating-ui/floating-ui/blob/master/packages/react/CHANGELOG.md)
- [Commits](https://github.com/floating-ui/floating-ui/commits/@floating-ui/react@0.27.8/packages/react)

---
updated-dependencies:
- dependency-name: "@floating-ui/react"
  dependency-version: 0.27.8
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* 🐛 Add focus markings to popover dialogs

* 🐛 Remove placeholder tabindex

* 📝 Changeset

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-05-05 10:07:17 +02:00
dependabot[bot] 0710dda8a6 ⬆️ Bump @biomejs/biome from 1.9.3 to 1.9.4 (#3765)
Bumps [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome) from 1.9.3 to 1.9.4.
- [Release notes](https://github.com/biomejs/biome/releases)
- [Changelog](https://github.com/biomejs/biome/blob/main/CHANGELOG_v1.md)
- [Commits](https://github.com/biomejs/biome/commits/cli/v1.9.4/packages/@biomejs/biome)

---
updated-dependencies:
- dependency-name: "@biomejs/biome"
  dependency-version: 1.9.4
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-05-05 09:34:04 +02:00
dependabot[bot] b99286c71b ⬆️ Bump eslint-plugin-react from 7.37.1 to 7.37.5 (#3766)
Bumps [eslint-plugin-react](https://github.com/jsx-eslint/eslint-plugin-react) from 7.37.1 to 7.37.5.
- [Release notes](https://github.com/jsx-eslint/eslint-plugin-react/releases)
- [Changelog](https://github.com/jsx-eslint/eslint-plugin-react/blob/master/CHANGELOG.md)
- [Commits](https://github.com/jsx-eslint/eslint-plugin-react/compare/v7.37.1...v7.37.5)

---
updated-dependencies:
- dependency-name: eslint-plugin-react
  dependency-version: 7.37.5
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-05-05 09:32:50 +02:00
Ken f619c16362 💄 Adjust Do-dont panel 2025-05-05 09:23:46 +02:00
Ken 578a5729db 🔥 Disable Umami tracking in Umami.tsx 2025-04-30 12:15:21 +02:00
Ken b4775ba2d7 [App router] Admin route (sanity) migrated (#3754)
* ✨ Introduce `Studio` component in `Studio.tsx` and `page.tsx` for admin interface

* ♻️ Move Admin and tooling to app-router.

* 🔥 Remove `[[...index]].js` from `legacy-admin` directory

* Update aksel.nav.no/website/app/(admin)/admin/[[...index]]/Studio.tsx

* Update aksel.nav.no/website/app/(admin)/admin/[[...index]]/page.tsx
2025-04-30 11:51:17 +02:00
Ken 5c1c4188b3 ✨ Update Standalone, prinsipper and error/404 pages (#3753) 2025-04-30 11:43:41 +02:00
Ken 6e48d8cc60 ⬆️ Upgrade next from 15.2.3 to 15.3.1 in (#3759)
* ⬆️ Upgrade `next` from 15.2.3 to 15.3.1 in `package.json` and `yarn.lock`

* 📝 yarn lock sync
2025-04-30 11:42:11 +02:00
Ken 387c6a5004 Migrate to '@storybook/nextjs' and storybook 8.6 (#3758)
* Migrate to '@storybook/nextjs' and storybook 8.6

* 🔧 Add lodash types
2025-04-30 11:40:50 +02:00
github-actions[bot] 4ac8d81f63 Version Packages (#3741)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-04-30 09:20:50 +02:00
0404c4f156 [Aksel nettsiden] Produktbloggen landingsside (#3745)
* 🚧 scaffold for produktbloggen

* 🚧 query quirks

* 🚧 now renders sanity content

* 🚧 wip++

* css tw -> modules

* convert tw classes to modules

* better naming + use more tokens

* gitignore++

* purer css selectors (for modules)

* 🐛 Use correct body-component

* fixes for sanityContentBlock

* 🐛 Add spacing to list-block

* remove final unnecessary css override for produktbloggen

* Update aksel.nav.no/website/app/dev/produktbloggen/[...slug]/page.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update aksel.nav.no/website/app/dev/(designsystemet)/slug.ts

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update aksel.nav.no/website/app/dev/produktbloggen/[...slug]/page.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update aksel.nav.no/website/app/dev/produktbloggen/_ui/Produktbloggen.module.css

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update aksel.nav.no/website/app/dev/produktbloggen/layout.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* pr fixes + merge main in

* add import for Page + remove box-shadow

* remove unneeded margin (due to margin collapse) + 🔥 relatives

* uppercase prop redundancy

* diamond CSS tweaks

* 🔥 superflous CSS

* header variant > className

* adjust z-index

* initial conversion

* generateMetadata()

* Update aksel.nav.no/website/app/dev/(designsystemet)/slug.ts

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* use less custom CSS, update NextImage props

* 🔥 remove unused CSS

* generateStaticParams()

* move <main> to layout

* use <PageBlock> over custom CSS

* 🎨 small design tweaks

* box-shadow on top of image

* 🚧 from tw2cssmodules

* convert HighlightedBlogg

* use show & hide

* 🐛 add missing article render on md

* image radius & box-shadow

* simplify CSS

* generateMetadata()

* simplify CSS

* urlForImage > urlFor

* inline LatestBloggPosts

* Update aksel.nav.no/website/app/dev/produktbloggen/_ui/Produktbloggen.module.css

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Link fixes

* desanity simple things

* split/optimize queries

* update schema

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2025-04-30 09:18:01 +02:00
Julian Nymark 3a6da2564d make "hopp til innhold" disappear when not focused (#3760) 2025-04-29 14:37:24 +02:00
dependabot[bot]andKen 91955f5049 ⬆️ Bump the npm_and_yarn group with 3 updates (#3705)
* ⬆️ Bump the npm_and_yarn group with 3 updates

Bumps the npm_and_yarn group with 3 updates: [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite), [esbuild](https://github.com/evanw/esbuild) and [axios](https://github.com/axios/axios).


Updates `vite` from 5.4.15 to 6.0.12
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v6.0.12/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v6.0.12/packages/vite)

Updates `esbuild` from 0.25.0 to 0.25.1
- [Release notes](https://github.com/evanw/esbuild/releases)
- [Changelog](https://github.com/evanw/esbuild/blob/main/CHANGELOG.md)
- [Commits](https://github.com/evanw/esbuild/compare/v0.25.0...v0.25.1)

Updates `axios` from 1.8.3 to 1.8.4
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](https://github.com/axios/axios/compare/v1.8.3...v1.8.4)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
  dependency-group: npm_and_yarn
- dependency-name: esbuild
  dependency-type: direct:development
  dependency-group: npm_and_yarn
- dependency-name: axios
  dependency-type: direct:production
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>

* ⬆️ Upgrade `vite` to version `5.4.18` in `package.json`

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-04-29 11:48:45 +02:00
dependabot[bot] 34ce9cb72b ⬆️ Bump lightningcss from 1.29.2 to 1.29.3 (#3751)
Bumps [lightningcss](https://github.com/parcel-bundler/lightningcss) from 1.29.2 to 1.29.3.
- [Release notes](https://github.com/parcel-bundler/lightningcss/releases)
- [Commits](https://github.com/parcel-bundler/lightningcss/compare/v1.29.2...v1.29.3)

---
updated-dependencies:
- dependency-name: lightningcss
  dependency-version: 1.29.3
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-29 10:06:56 +02:00
dependabot[bot] 6b8d81e380 ⬆️ Bump @vitest/eslint-plugin from 1.1.7 to 1.1.43 (#3752)
Bumps [@vitest/eslint-plugin](https://github.com/vitest-dev/eslint-plugin-vitest) from 1.1.7 to 1.1.43.
- [Release notes](https://github.com/vitest-dev/eslint-plugin-vitest/releases)
- [Commits](https://github.com/vitest-dev/eslint-plugin-vitest/compare/v1.1.7...v1.1.43)

---
updated-dependencies:
- dependency-name: "@vitest/eslint-plugin"
  dependency-version: 1.1.43
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-29 10:05:48 +02:00
Ken e8f59ee29f 🔥 Remove actions.ts and unused .pageAuthor styling in CSS 2025-04-26 17:08:17 +02:00
Ken 5f3e0d619d Revert "🔥 Refactor queries and remove unused actions; update styling and layout for produktbloggen pages"
This reverts commit 9141a6f863.
2025-04-26 17:06:36 +02:00
Ken ab41aef076 🎨 Update max-width for data-text-prose and adjust list component styling 2025-04-26 13:51:52 +02:00
Ken 2decc636c8 🎨 Update theme button styling and enhance editor panel content structure 2025-04-26 13:51:52 +02:00
Ken 171410e7d4 🎨 Refactor Designsystemet components; introduce DesignsystemetEyebrow for consistent styling and layout 2025-04-26 13:51:52 +02:00
Ken 9141a6f863 🔥 Refactor queries and remove unused actions; update styling and layout for produktbloggen pages 2025-04-26 13:51:52 +02:00
Ken cc8742c179 🔊 Added umami-script
🔥 Refactor Attachment component, remove unused styles, and enhance EditorPanel integration
2025-04-26 13:51:51 +02:00
Ken e1b73178e1 [Website] Fix moduleresolution (#3750)
* ♻️ Use bundler as moduleresolution for website

* 📝 removed old ts-ignore
2025-04-25 15:02:41 +02:00
8eca3ceeac [Aksel nettsiden] Produktbloggen (#3716)
* 🚧 scaffold for produktbloggen

* 🚧 query quirks

* 🚧 now renders sanity content

* 🚧 wip++

* css tw -> modules

* convert tw classes to modules

* better naming + use more tokens

* gitignore++

* purer css selectors (for modules)

* 🐛 Use correct body-component

* fixes for sanityContentBlock

* 🐛 Add spacing to list-block

* remove final unnecessary css override for produktbloggen

* Update aksel.nav.no/website/app/dev/produktbloggen/[...slug]/page.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update aksel.nav.no/website/app/dev/(designsystemet)/slug.ts

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update aksel.nav.no/website/app/dev/produktbloggen/[...slug]/page.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update aksel.nav.no/website/app/dev/produktbloggen/_ui/Produktbloggen.module.css

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update aksel.nav.no/website/app/dev/produktbloggen/layout.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* pr fixes + merge main in

* add import for Page + remove box-shadow

* remove unneeded margin (due to margin collapse) + 🔥 relatives

* uppercase prop redundancy

* diamond CSS tweaks

* 🔥 superflous CSS

* header variant > className

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2025-04-25 11:18:50 +02:00
Ken 3313720bc3 🐛 makes sure to filter out 'root'-pages for designsystem-docs in generateStaticParams 2025-04-24 16:31:48 +02:00
Ken 64705d06bc 🔥 Remove ConsentForm and associated styles, refactor page structure
🐛 Avoid redundant gap between non-existent grid-areas in linkcard

🐛 Tema-page slug missing forward-slash

🔥 removed underline thickness animation

📝 Ensure consistent query-naming
2025-04-24 16:15:33 +02:00
Ken 88fb8977ea 🐛 Dont use zod 'undefined', breaking server-components 2025-04-24 14:33:44 +02:00
KenandCopilot 8d805eae2f [Appdir] God praksis tema-page (#3742)
* ✨ feat: Add GOD_PRAKSIS_ALL_TEMA_QUERY and related types for improved data fetching
🎨 style: Update globals.css to enhance accessibility for skip links
📝 docs: Enhance theme.d.ts with new data-text-prose attribute for prose text styling
🎉 feat: Implement HeroCube component for visual representation in the hero section
🎨 style: Create Hero.module.css for styling the hero components
🎉 feat: Develop GodPraksisIntroHero component for the hero section
🎉 feat: Create TemaHero component for displaying theme navigation
🎉 feat: Implement HeroCardList for rendering theme cards
🎉 feat: Add HeroIntro component for displaying theme title and description
🎉 feat: Create HeroSelectButton for toggling theme selection
🎉 feat: Build page.tsx to fetch and display themes with the new components

* 🚚 Port over linkcard

* 💄 Replicate gp figma card

* 🎉 Synced hero

* ✨ Implemented GP frontpage

* 🔍 Add god-praksis metadata

* 🎉 Fetch and parse svg from sanity

* 🎉 Update use of linkcard on gp-pages

* 🎉 Use LinkCard on overview-pages

* Update aksel.nav.no/website/app/dev/(god-praksis)/god-praksis/page.tsx

* Update aksel.nav.no/website/app/dev/(god-praksis)/god-praksis/page.tsx

* 🐛 Clean up linkcard types

* ✨ Added data-fetching for tema-pages

* ✨ Gp-hero is now a self-fetching component

* ✨ Migrated state-handling for hero-banner

* ✨ Migrated CSS and interactions for HeroModule

* 🎉 Implemented chip-navigation logic

* 🐛 margin-animation did not work

* 🐛 Used undefined 'open' value

* ⚡ Optimize article mapping

* 📝 Add better metadata to categories

* ✨ Render articles as LinkCard

* ⚡ Fix URL parameter handling in GodPrakisChipsNavigationButton and add prefetch on hover

* 🐛 Chips nav had duplicate data

* 💄 Synced layout with Figma

* 🔍 Added metadata

* 🎨 Refactor padding in search form and improve header logo visibility based on screen size
💄 Add icon styling for GodPraksisHeroButton and create GodPraksisTaxonomyTag component

* 🐛 Add spacing below hero description

* 🐛 Remove spacing from description when no element below

* 🐛 Use data-attrb since last-child selector cant work

* 💄 Use new linear gradient for darkmode hero banner

* 🐛 Add missing focus-markings, word break for title

* 🐛 Use updated colors for fallback image

* [Appdir] God praksis article page Part 1 (#3743)

* 🎉 Scaffolding for gp article pages

* 🐛 Add spacing top to non-first child headings

* ✨ Implemented SystemPanel component

* ✨ Added sanity login check to outdated panel

* [Appdir] God praksis article page Part 2 (#3746)

* ✨ Added authors

* 📝 Formatting

* ✨ Added related articles content

* ♻️ Refactor UnderTemaLink to inline implementation with NextLink

* ✨ Integrate EditorPanel into multiple components and remove unused styles

* 🔍 Add metadata to page

* 🔥 Remove TOC from GP pages

* 🐛 Remove duplicate outdated panel render

* ✨ Add GodPraksisFeedback component with context and states for user feedback

* ✨ Added form-state and validation clientside

* ✨ Added RCS auth

* ♻️ Optimize slack-user lookup, inline inside action

* ✨ Refactor GodPraksisFeedback components and enhance page layout with relevant articles

* 💄 Remove bg from bilde-caption

* 💄 Fix list layout

* 🐛 Editorpanel dir had extra space

* Update aksel.nav.no/website/app/_ui/toc/TableOfContents.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 🐛 Avoid getting updated types for legacy-implementation

* 💄 Move related links

* Update aksel.nav.no/website/app/_ui/toc/TableOfContents.tsx

* Update aksel.nav.no/website/app/dev/(god-praksis)/god-praksis/artikler/[slug]/page.tsx

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-04-24 14:29:55 +02:00
Julian Nymark 9dc60ba560 prevent focus trap (#3748) 2025-04-24 13:08:32 +02:00
Ken 088d5e6b59 🎨 Refactor feedback link in TableOfContents, adjust padding and margins in Designsystemet styles, and enhance slug parsing logic 2025-04-24 11:35:00 +02:00
Ken b0f1151fd6 [Aksel.nav.no] Appdir God praksis landing-page (#3732)
* ✨ feat: Add GOD_PRAKSIS_ALL_TEMA_QUERY and related types for improved data fetching
🎨 style: Update globals.css to enhance accessibility for skip links
📝 docs: Enhance theme.d.ts with new data-text-prose attribute for prose text styling
🎉 feat: Implement HeroCube component for visual representation in the hero section
🎨 style: Create Hero.module.css for styling the hero components
🎉 feat: Develop GodPraksisIntroHero component for the hero section
🎉 feat: Create TemaHero component for displaying theme navigation
🎉 feat: Implement HeroCardList for rendering theme cards
🎉 feat: Add HeroIntro component for displaying theme title and description
🎉 feat: Create HeroSelectButton for toggling theme selection
🎉 feat: Build page.tsx to fetch and display themes with the new components

* 🚚 Port over linkcard

* 💄 Replicate gp figma card

* 🎉 Synced hero

* ✨ Implemented GP frontpage

* 🔍 Add god-praksis metadata

* 🎉 Fetch and parse svg from sanity

* 🎉 Update use of linkcard on gp-pages

* 🎉 Use LinkCard on overview-pages

* Update aksel.nav.no/website/app/dev/(god-praksis)/god-praksis/page.tsx

* Update aksel.nav.no/website/app/dev/(god-praksis)/god-praksis/page.tsx
2025-04-24 10:07:43 +02:00
Ken c9ede88246 💄 Update hover-effect for Chips based on figma-review (#3738) 2025-04-24 10:05:09 +02:00
dependabot[bot] 7cfae6cd1d ⬆️ Bump vite-tsconfig-paths from 4.3.2 to 5.1.4 (#3712)
Bumps [vite-tsconfig-paths](https://github.com/aleclarson/vite-tsconfig-paths) from 4.3.2 to 5.1.4.
- [Release notes](https://github.com/aleclarson/vite-tsconfig-paths/releases)
- [Commits](https://github.com/aleclarson/vite-tsconfig-paths/compare/v4.3.2...v5.1.4)

---
updated-dependencies:
- dependency-name: vite-tsconfig-paths
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-22 12:41:06 +02:00
Ken 0a98a75514 ⚡ Use recommended memory values for application requests 2025-04-22 12:20:18 +02:00
Ken dbff5f79f8 🐛 Allow fetching from github on server-side 2025-04-22 11:21:12 +02:00
KenandCopilot 84f1cfec49 [Aksel.nav.no] Appdir iconpage (#3730)
* ✨ Added theming-support to appdir

* 📝 Added changelog docs for theme class change

* ♻️ Use inline head to set local styles instead of css-modules

* ✨ Setup overview-page

* 🐛 Use inline styles instead of Head element from nextjs

* WIP: V1 list view

* 💄 Align overview heading with regular page heading

* 🐛 Moved margin-bottom to top for overview grid

* 🎉 Add overview toggle for component pages

* 🎉 Added overview-pages to sidebar

* 🎉 Added routing support for overview pages

* 🎉 Setup staticparams and metadata for overview-pages

* 🚚 Moved overview components out to now dir

* ✨ Added overview support for komponenter, templates and grunnleggende

* 🔥 Removed unused sanity-field

* 🐛 Hide fallback-svg

* 🐛 Fix misspelling

* 🎉 Added Iconpage filtering and navigation

* 🎉 Added modal view

* 🐛 Fixed searchParams type

* 🎉 Added empty-state

* 🔥 Removed forced use-client for emptystate

* 🎉 Support svg fetch

* 🔥 Refactor IconPage components and remove unused sidepanel

* 🎉 Added links

* 📝 Added metadata

* 🐛 Resolve impure css module class

* 🐛 Fix iconName validation logic in IconPage component

* 🎨 Improve layout and styling in IconPage components

* 🎨 Update HStack component to use 'as="ul"' for semantic HTML

* ✨ Added icon-page to sidebar

* Update aksel.nav.no/website/app/dev/(designsystemet)/_ui/sidebar/Sidebar.util.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update aksel.nav.no/website/app/dev/(designsystemet)/_ui/icon-page/IconPage.button.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* ⚡ Added zod-validation and debounce to search

* 🏷️ Resolved updated types

* ⚡ Use clientside updates for icon-page

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-04-22 10:43:56 +02:00
dependabot[bot] 39817f924c ⬆️ Bump @testing-library/react from 16.1.0 to 16.3.0 (#3724)
Bumps [@testing-library/react](https://github.com/testing-library/react-testing-library) from 16.1.0 to 16.3.0.
- [Release notes](https://github.com/testing-library/react-testing-library/releases)
- [Changelog](https://github.com/testing-library/react-testing-library/blob/main/CHANGELOG.md)
- [Commits](https://github.com/testing-library/react-testing-library/compare/v16.1.0...v16.3.0)

---
updated-dependencies:
- dependency-name: "@testing-library/react"
  dependency-version: 16.3.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-22 10:26:15 +02:00
Ken 8ea18b07a3 ✨ New icon 'Cpu'. (#3740) 2025-04-22 10:11:24 +02:00
820a68f0a8 Chat: Add prop to control toptext heading level (#3739)
* Chat: Add prop to control toptext heading level

* Update @navikt/core/react/src/chat/Bubble.tsx

* Update @navikt/core/react/src/chat/Bubble.tsx

* Update @navikt/core/react/src/chat/chat.stories.tsx

* 📝 Typo

* 📝 Chat: Add 'toptextHeadingLevel'-prop to allow changing h-level based on semantics.

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-04-22 10:05:31 +02:00
github-actions[bot] f787e91a2f Version Packages (#3737)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-04-11 14:47:22 +02:00
KenandCopilot e7ec9c191a Timeline: Add placement-prop for periods for more fine-grained control (#3736)
* Timeline: Add placement-prop for periods for more fine-grained controll over Popover-placement

* Update .changeset/lazy-coats-beam.md

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-04-11 12:35:22 +02:00
Ken c57fe7c396 🐛 Use option-value as id instead of label in Combobox (#3735)
* 🐛 Use option-value as id instead of label

* 🐛 Use unique option-value as react-key
2025-04-11 12:32:16 +02:00
github-actions[bot] 4178ec2647 Version Packages (#3733)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-04-10 17:23:19 +02:00
Ken 8c9cf92c8b 🐛 Single-select combobox assumed that input needed min-width (#3734) 2025-04-10 14:55:37 +02:00
Ken 208adb8b3f 🐛 Using Page-component would always give errors when using new Theme-component 2025-04-10 14:15:13 +02:00
Ken 1966c3aed5 🐛 Pages without TOC broke page-layouts with assumed grid-placements 2025-04-10 12:00:45 +02:00
Ken 3a523392c7 [Aksel.nav.no] Support cookies in Appdir (#3726)
* ✨ Added theming-support to appdir

* 📝 Added changelog docs for theme class change

* ♻️ Use inline head to set local styles instead of css-modules

* ✨ Setup overview-page

* 🐛 Use inline styles instead of Head element from nextjs

* WIP: V1 list view

* 💄 Align overview heading with regular page heading

* 🐛 Moved margin-bottom to top for overview grid

* 🎉 Add overview toggle for component pages

* 🎉 Added overview-pages to sidebar

* 🎉 Added routing support for overview pages

* 🎉 Setup staticparams and metadata for overview-pages

* 🚚 Moved overview components out to now dir

* ✨ Added overview support for komponenter, templates and grunnleggende

* 🔥 Removed unused sanity-field

* 🐛 Hide fallback-svg

* 🐛 Fix misspelling

* ✨ Setup appdir cookie-banner view

* 🎉 Moved cookie-handling to server-actions

* 🐛 Remove impure css module use

* 🐛 Use forced dynamic to allow consent-banner

* 📝 Add docs

* 🎉 Moved consent doc-page

* ♻️ Rename cookie-actions to use 'action'-suffix
2025-04-10 11:51:33 +02:00
Ken 65c791c1eb [Aksel.nav.no] Add support for "overview" pages (#3722)
* ✨ Added theming-support to appdir

* 📝 Added changelog docs for theme class change

* ♻️ Use inline head to set local styles instead of css-modules

* ✨ Setup overview-page

* 🐛 Use inline styles instead of Head element from nextjs

* WIP: V1 list view

* 💄 Align overview heading with regular page heading

* 🐛 Moved margin-bottom to top for overview grid

* 🎉 Add overview toggle for component pages

* 🎉 Added overview-pages to sidebar

* 🎉 Added routing support for overview pages

* 🎉 Setup staticparams and metadata for overview-pages

* 🚚 Moved overview components out to now dir

* ✨ Added overview support for komponenter, templates and grunnleggende

* 🔥 Removed unused sanity-field

* 🐛 Hide fallback-svg

* 🐛 Fix misspelling

* Update aksel.nav.no/website/app/dev/(designsystemet)/_ui/sidebar/Sidebar.tsx

* 🐛 Could not create overview-pages for grunnleggende or templates
2025-04-10 11:18:32 +02:00
github-actions[bot] f1e058b67b Version Packages (#3706)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-04-08 14:11:10 +02:00
Vegard Haugstvedt 977ecec1df Forgot darkside-fix in #3727, so I am just pushing it individually 2025-04-08 14:06:38 +02:00
Vegard Haugstvedt 8b31c3bc58 Bugfix/combobox chips not wrapping when togglelist button is hidden (#3727)
* Remove unused CSS that causes issues when Combobox' ToggleListButton is skipped

This code removed wrapping of chips if ToggleListButton is hidden, and will only ever apply to the button otherwise. That does not need a flex layout.

* Add changeset
2025-04-08 13:58:49 +02:00
Ken 0d71a48458 [aksel.nav.no] 🎉 Themable empty-state for app-dir search 2025-04-07 13:44:52 +02:00
Julian Nymark c413f427a5 increase deprecation visibility (#3719) 2025-04-07 11:53:20 +02:00
Ken 023c06d66f [Aksel.nav.no] Theme-support (#3720)
* ✨ Added theming-support to appdir

* 📝 Added changelog docs for theme class change

* ♻️ Use inline head to set local styles instead of css-modules

* 🐛 Use inline styles instead of Head element from nextjs
2025-04-03 11:01:52 +02:00
Julian Nymark 68a3cfc340 remove outdated design examples (also somewhat erroneous hide example) (#3718) 2025-04-03 10:58:19 +02:00
Ken 277c74a657 🎨 Update background color for togglegroup in darkside theme (#3715) 2025-04-02 09:54:46 +02:00
Ken f0d569ab5f 🏷️ Refine type definitions for PortableContentTypes and update customPortableTextComponents type constraints 2025-04-02 09:54:16 +02:00
Julian NymarkandKen 58bb2e69c8 [Migration]: box -> boxNew (#3669)
* 🚧 box migration scaffolding

* 🚚 boxnew -> darkside/boxnew

* 🚧 wip

* 🚧 working single substitution (pending lookup in replacements)

* ✅ working test

* import rename in output test

* ✅ import rename + tests

* use config comments, better import example

* commentblock function (append to string output) + update tests (failing)

* 🚧 almost good... needs to respect renamed imports

* ✅ passing tests

* ♻️ organize some utils

* 🧪 Added more tests

* cast JSXIdentifier type

* pass idempotency tests

* also refactor the usage when renaming a function

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-04-02 09:20:13 +02:00
Ken 01a395bdf7 💄 Update text-sizing for app-router heading 2025-04-01 14:56:40 +02:00
Ken b4b316c639 [Aksel.nav.no] More updates to app-router DS-pages, added SEO (#3717)
* ♻️ Update TOC feedback, add layout padding bottom

* 🐛 Added missing type

* 🐛 Fix missing spacing in intro-section

* 🎉 Added metadata for changelog view support in mønster pages

* 🎨 Refactor layout styles and enhance sidebar button animations

* 🎉 Added SEO support

* 🐛 Add page SEO image to start of image list

* 🔥 Remove reduntant early exit code

* 🐛 Open feedback in new tab

* 🐛 Update footer to use responsive layout

* 🐛 Moved theme-colors to viewmport config

* 🐛 Show mobile-menu earlier

* 🐛 Use local schema in sanity-typegen

* 📝 Typo
2025-04-01 14:46:19 +02:00
Ken d859497f07 📝 Removed title from list example 2025-04-01 11:29:18 +02:00
KenandCopilot eb257db444 [Aksel.nav.no] Resolved remaining sanityblocks to the darkside and appdir (#3708)
* 🔥 Removed legacy block for riktekst_blokk

* 🚚 Migrated AkselTable component

* 🚚 Migrated TokenTable component

* 💄 More visible warning

* 💄 Use 1920 as max-width for ds layout

* 🚚 Moved sidebar to ds scope

* 🚚 Moved AkselTable to WebsiteTable

* ✨ Added grunnleggende route

* 🚚 Moved List to WebsiteList

* 🐛 Fix spacing between ds header and content

* 🚚 Migrated token-view

* 🚚 Migrated ExampleText block

* 🚚 Migrated Attachment block

* 🚚 Moved compare-images module

* 🎉 Migrated compareimages module

* 🎉 Added language migration

* 🎉 Stronger typing to make sure we resolve every sanity type

* 🏷️ stricter types

* Update aksel.nav.no/website/app/_ui/legacy-token-module/token-view/parts/categories/Breakpoints.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update aksel.nav.no/website/app/_ui/compare-images/CompareImages.handle.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 🐛 Use static initial aria value labels

* 🐛 Sync updated sanity schema

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-03-31 13:24:52 +02:00
Karl-Magnus Thorsnes 619547cd0e SearchButton💄 Vis forskjellig hurtigtast ut fra brukers OS (#3710)
* Feat differensier hurtigtast-beskrivelse ut fra OS

* Bruk simplere metode for å detectere OS
2025-03-31 12:29:06 +02:00
Julian Nymark dfd88e19dc update playroom (#3709) 2025-03-31 10:35:15 +02:00
dependabot[bot] fa17760f64 ⬆️ Bump figlet from 1.6.0 to 1.8.0 (#3711)
Bumps [figlet](https://github.com/patorjk/figlet.js) from 1.6.0 to 1.8.0.
- [Release notes](https://github.com/patorjk/figlet.js/releases)
- [Commits](https://github.com/patorjk/figlet.js/compare/1.6.0...1.8.0)

---
updated-dependencies:
- dependency-name: figlet
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-31 10:33:47 +02:00
Ken d77e7e203e 💄 Updated global meta-purple color for darkside (#3703) 2025-03-28 12:10:47 +01:00
github-actions[bot] d5893bf3b7 Version Packages (#3704)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-03-28 11:59:45 +01:00
Ken 38189a0440 🐛 Disabled expansion-rows now has same hover-effect as other rows (#3702) 2025-03-27 13:49:53 +01:00
Ken 726dc124e8 🎨 Update styles for CodeBlock and TableOfContents components 2025-03-27 11:31:51 +01:00
Ken 9d9ff637d9 📝 Sync icon metadata 2025-03-27 11:22:06 +01:00
Ken efd0739abb ✨ Throw error of legacy-props are used with new Theme in Box. (#3697)
* ✨ Throw error of legacy-props are used with new Theme in Box.

* Update @navikt/core/react/src/layout/box/Box.stories.tsx
2025-03-27 11:19:14 +01:00
dependabot[bot] aa7b7132bb ⬆️ Bump the npm_and_yarn group across 3 directories with 1 update (#3701)
Bumps the npm_and_yarn group with 1 update in the /examples/astro directory: [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).
Bumps the npm_and_yarn group with 1 update in the /examples/referansesider directory: [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).
Bumps the npm_and_yarn group with 1 update in the /examples/shadow-dom directory: [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).


Updates `vite` from 5.4.14 to 5.4.15
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v5.4.15/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.4.15/packages/vite)

Updates `vite` from 5.4.14 to 5.4.15
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v5.4.15/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.4.15/packages/vite)

Updates `vite` from 5.4.14 to 5.4.15
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v5.4.15/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.4.15/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: vite
  dependency-type: direct:development
  dependency-group: npm_and_yarn
- dependency-name: vite
  dependency-type: direct:development
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-27 11:09:16 +01:00
Ken 76318343a0 🐛 Search now works on mobile for IOS-devices, resolves #3693 2025-03-27 11:03:33 +01:00
dependabot[bot]andKen 6c58063a0d ⬆️ Bump the npm_and_yarn group with 5 updates (#3679)
* ⬆️ Bump the npm_and_yarn group with 5 updates

Bumps the npm_and_yarn group with 5 updates:

| Package | From | To |
| --- | --- | --- |
| [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) | `5.4.14` | `6.0.9` |
| [esbuild](https://github.com/evanw/esbuild) | `0.24.0` | `0.25.0` |
| [vitest](https://github.com/vitest-dev/vitest/tree/HEAD/packages/vitest) | `2.1.8` | `2.1.9` |
| [axios](https://github.com/axios/axios) | `1.8.2` | `1.8.3` |
| [@babel/helpers](https://github.com/babel/babel/tree/HEAD/packages/babel-helpers) | `7.25.7` | `7.26.10` |


Updates `vite` from 5.4.14 to 6.0.9
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v6.0.9/packages/vite)

Updates `esbuild` from 0.24.0 to 0.25.0
- [Release notes](https://github.com/evanw/esbuild/releases)
- [Changelog](https://github.com/evanw/esbuild/blob/main/CHANGELOG-2024.md)
- [Commits](https://github.com/evanw/esbuild/compare/v0.24.0...v0.25.0)

Updates `vitest` from 2.1.8 to 2.1.9
- [Release notes](https://github.com/vitest-dev/vitest/releases)
- [Commits](https://github.com/vitest-dev/vitest/commits/v2.1.9/packages/vitest)

Updates `axios` from 1.8.2 to 1.8.3
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](https://github.com/axios/axios/compare/v1.8.2...v1.8.3)

Updates `@babel/helpers` from 7.25.7 to 7.26.10
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.26.10/packages/babel-helpers)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
  dependency-group: npm_and_yarn
- dependency-name: esbuild
  dependency-type: direct:development
  dependency-group: npm_and_yarn
- dependency-name: vitest
  dependency-type: direct:development
  dependency-group: npm_and_yarn
- dependency-name: axios
  dependency-type: direct:production
  dependency-group: npm_and_yarn
- dependency-name: "@babel/helpers"
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>

* 🐛 Sync depdendencies repo-wide

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-03-27 10:08:02 +01:00
dependabot[bot] 195749dec6 ⬆️ Bump the npm_and_yarn group across 3 directories with 3 updates (#3685)
Bumps the npm_and_yarn group with 2 updates in the /examples/astro directory: [@babel/helpers](https://github.com/babel/babel/tree/HEAD/packages/babel-helpers) and [prismjs](https://github.com/PrismJS/prism).
Bumps the npm_and_yarn group with 1 update in the /examples/next-appdir directory: [next](https://github.com/vercel/next.js).
Bumps the npm_and_yarn group with 1 update in the /examples/shadow-dom directory: [@babel/helpers](https://github.com/babel/babel/tree/HEAD/packages/babel-helpers).


Updates `@babel/helpers` from 7.25.6 to 7.26.10
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.26.10/packages/babel-helpers)

Updates `prismjs` from 1.29.0 to 1.30.0
- [Release notes](https://github.com/PrismJS/prism/releases)
- [Changelog](https://github.com/PrismJS/prism/blob/master/CHANGELOG.md)
- [Commits](https://github.com/PrismJS/prism/compare/v1.29.0...v1.30.0)

Updates `next` from 15.1.2 to 15.2.3
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/compare/v15.1.2...v15.2.3)

Updates `@babel/helpers` from 7.23.9 to 7.26.10
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.26.10/packages/babel-helpers)

---
updated-dependencies:
- dependency-name: "@babel/helpers"
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: prismjs
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: next
  dependency-type: direct:production
  dependency-group: npm_and_yarn
- dependency-name: "@babel/helpers"
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-27 10:00:34 +01:00
Ken a185ab4d48 ⬆️ Upgrade rehype suite used for validating icon-SVG 2025-03-27 09:58:59 +01:00
Ken 88159c2cac [Aksel.nav.no] KodeEksempel blokk Appdir (#3699)
* ✨ Implemented codeblock header and codeblock

* ✨ Can now toggle betweem different code-views

* 🐛 Use Theme component to get color-scheme in CSS

* 💄 Updated padding, use custom theme

* ✨ Implemented custom prism-theme

* ✨ Use new prism-theme for propsseksjon

* 🎉 Use new codeblock for single code view

* 🐛 Add hover-effect for expander button

* ✨ Added provider and navigation support

* WIP: Add codeview block

* ✨ Enhance KodeEksempler with Suspense, toolbar, and improved props handling

* 🎨 Refactor CodeBlock component by removing unnecessary Theme wrapper and improving className handling

* ✨ Use local styles for kodeexample module

* 🐛 Add useclient

* 🐛 Use local css variable since css counter breaks at random
2025-03-27 09:12:18 +01:00
Ken c453dac6f0 🐛 scalingStrategy were put under wrong keyword in nais-config 2025-03-25 17:11:21 +01:00
Ken 676973621b ⚡ Optimize Nais config for less replication 2025-03-24 19:38:34 +01:00
Ken be5578ab28 [Aksel.nav.no] Migrated more components over to new PortableText component (#3689)
* 🚚 Migrated related links and added types for portable type-blocks

* ⚰️ Removed unused sanity-types for prinsipper

* 🔥 Removed old tastatur module

* 🎉 Migrated to new DoDont-component

* 🚚 Migrated Bilde module

* 🚚 Migrated Alert module

* 🚚 Migrated ExpansionCard module

* 🚚 Migrated ExpansionCard module

* 🚚 Migrated Tablev2 module

* 🚚 Migrated Accordion module

* 🐛 Avoid using client-component for Accordion module

* ♻️ Extracted components from PropsSeksjon

* ♻️ Re-use codeblock for proptable

* ♻️ Rename

* ♻️ Added Video support for new portable text

* 🚚 Migrate Tips module

* 💄 Use new CSS for darkside

* 🐛 Use new status-tag handling for sidebar

* 🐛 Alias portableText to avoid circular dependency-warnings

* 📝 Document getStatusTag
2025-03-24 19:32:55 +01:00
Ken f495c2c392 🐛 Nais-config deleted all routes from aksel.nav.no build. Removed 'emptyDir' config. 2025-03-24 13:28:59 +01:00
Ken 73d0a2c9c9 [Aksel.nav.no] Fix cve-2025-29927 (#3691)
* 🔒 Fix CVE-2025-29927

* 📝 Yarn lock sync
2025-03-24 12:54:48 +01:00
Ken 8be06ae014 ⚡ Update nais-config (#3690)
* ⚡ Update nais config limits for memory and cache

* ⚡ Avoid prefetching komponent landing page links

* 🔥 Removed cpu treshhold

* 🐛 Avoid prefetching external route
2025-03-24 12:33:14 +01:00
Ken 7c35584d90 [Aksel.nav.no] Grid-layouts and Porting of more components (#3683)
* ✨ Setup new layout grid

* ♻️ PortableText config setup

* ✨ Migrated over Blocks support to appdir

* 🚚 Moved typo components to appdir

* ✨ Add Komponent spesific modules to page template

* ✨ Added thumbnail (hardcoded)

* ✨ Introduced DesignsystemetKomponentIntro and DesignsystemetThumbnail components for enhanced component documentation

* 🐛 TOC is now sticky

* ✨ Added marks-support (#3684)
2025-03-21 17:49:17 +01:00
Ken 5d917e188f 🐛 Admin broke since schema.json were used as reference 2025-03-21 14:26:19 +01:00
Ken 7249aa1f43 🐛 Allow form-actions for codesandbox-examples 2025-03-20 14:56:35 +01:00
Ken 322167da20 [Aksel.nav.no] Ported over TOC to app-router, added sanity types (#3681)
* ✨ Set up page-slug query logic

* ♻️ Inline TableOfContents in smaller modules

* 🎨 Refactor TableOfContents styles and update component structure

* 🎨 Enhance TableOfContents styles and structure for improved responsiveness and clarity

* ✨ Enhance TableOfContents component with feedback and changelog links; refactor queries for improved data handling

* 🚚 Co-localized layout in grouped ui dir

* ✨ Extract schema types from sanity

* 🐛 Update sidebar types to use new sanity schema-types
2025-03-20 14:53:24 +01:00
Ken 46c0f434cf 🐛 Handle cases where sanity assets are undefined (#3682) 2025-03-20 11:45:12 +01:00
Ken f994d3868b 🔥 Critical frontpage crash fix 2025-03-20 09:28:47 +01:00
dependabot[bot] 53dab8e1a0 ⬆️ Bump @babel/helpers (#3678)
Bumps the npm_and_yarn group with 1 update in the /examples/referansesider directory: [@babel/helpers](https://github.com/babel/babel/tree/HEAD/packages/babel-helpers).


Updates `@babel/helpers` from 7.25.6 to 7.26.10
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.26.10/packages/babel-helpers)

---
updated-dependencies:
- dependency-name: "@babel/helpers"
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-20 09:18:52 +01:00
Ken 23400df9f0 ✨ Page layouts for new Ds-pages (#3675) 2025-03-19 13:52:58 +01:00
github-actions[bot] 6e9b0e9b1c Version Packages (#3677)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-03-19 13:43:46 +01:00
Ken ad0375e918 📝 Icon metadata sync (#3676) 2025-03-19 13:39:38 +01:00
Ken 0cb04db261 ✨ Update modal animations for reduced movement (#3671) 2025-03-19 13:36:58 +01:00
Roy Halvor Frimanslund 50113b4501 Update ExternalLinkFill.yml (#3673)
Bug: icon was marked as "new tab" but the icon for new tab is an box with the arrow stopping at the border. Having the new tab synonym here will cause missunderstandings.
2025-03-19 13:31:48 +01:00
Roy Halvor Frimanslund b745daa35c Update ExternalLink.yml (#3674)
Bug: icon was marked as "new tab" but the icon for new tab is an box with the arrow stopping at the border. Having the new tab synonym here will cause missunderstandings.
2025-03-19 13:31:37 +01:00
Ken 1d41f0d8f5 🐛 Editors without name broke preview and admin-tool 2025-03-19 11:41:50 +01:00
KenandCopilot 85eeb68f20 [Aksel.nav.no] Initial App-router setup (#3662)
* root layout

* ✨ Added draftmode

* ✨ Setup boilerplate

* ✨ Setup grouping-dir

* ✨ Implemented header

* 💄 Made header sticky

* 🔒 Content security policy updated

* 🚚 Moved favicon to appdir

* 🔥 restore old frontpage

* 🚚 Moved sidebar to appdir

* ✨ Implemented sidebar loading

* ✨ Doc lyout

* 🐛 Add id for skiplink

* ✨ Added new footer

* 💄 Move skiplink further away

* 💄 Add more padding bottom sidebar

* ✨ Refactor header and sidebar components for improved layout and structure

* 📝 Uncomment some code

* 🔥 Removed user server directive from component and layouts

* 🐛 Center footer

* 🐛 Re-added support for chromatic connect

* 🔥 removed browser-token

* Update aksel.nav.no/website/app/_ui/footer/Footer.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* [Aksel.nav.no] Ported over global search to app-router (#3663)

* 🚚 Moved search-code closer to app router

* ✨ Added button and modal

* ⚡ Initial loading for recent articles

* ⚡ Query data from the server

* ✨ Generates parsed search-results

* ⚡ Added debounce

* ✨ Render hits

* ♻️ Limit articles for each field to 20

* 🐛 Revert form-layout to initial view

* 🐛 Build searchindex before website

* ✨ Pre-select text when re-opening search

* ✨ Enhance global search UI with improved layout and styling

* ✨ Refactor global search components to improve search functionality and UI

* ✨ Improve global search functionality and UI responsiveness

* ✨ Update global search UI and functionality with improved input handling and styling

* ✨ Refactor global search dialog and add Kbd component for keyboard shortcuts

* ⚡ removed reduntant suspense

* ✨ Refactor global search components for improved styling and functionality

* ✨ Refactor global search results rendering for improved performance and readability

* ✨ Update global search dialog and form for improved styling and accessibility

* ✨ Refactor global search components for improved layout and styling

* ✨ Refactor GlobalSearchHitCollection for improved styling and accessibility

* 🎨 Update global search configuration and styles for improved clarity and aesthetics

* 🎨 Update layout and styles for global search components for improved aesthetics and readability

* ✨ Refactor global search utilities and update styles for improved clarity and maintainability

* 🔧 Refactor global search queries and implement caching for improved performance and data retrieval

* ⚡ Preload cache for search

* 🔧 Refactor fetchArticles function to improve caching logic and remove unnecessary logging

* 🔥 Removed user server directive from component

* 🔥 Removed comments

* ⚡ Explicitly declare server-only component

* Update aksel.nav.no/website/app/_ui/global-search/GlobalSearch.fetch.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update aksel.nav.no/website/app/_ui/global-search/GlobalSearch.fetch.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 📝 Rename sanitiezedata

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* [Aksel.nav.no] Move Aksel-brand theme into app-router for use (#3668)

* 💄 Added global aksel-theme tokens

* ✨ Implement new Aksel-brand for theming

* [Aksel.nav.no] Updated MobileMenu for new ds-pages (#3670)

* 💄 Added global aksel-theme tokens

* ✨ Implement new Aksel-brand for theming

* ✨ Initial setup mobile-menu

* ✨ V1 mobile-menu component

* 💄 Update mobile navigation and global search responsiveness; adjust overlay color opacity

* 💄 Refine modal backdrop animation timing and opacity for smoother transitions

* 💄 Adjust pressed-sidebar state

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-03-18 21:15:54 +01:00
Julian Nymark 9f958c1242 [Migration] deprecate darkside props (#3656)
* working impl

* new migrations key for darkside

* new import path

* 🚚 spacing -> utils/ast
2025-03-18 13:36:59 +01:00
dependabot[bot] 489ac3a426 ⬆️ Bump prettier-plugin-tailwindcss from 0.6.8 to 0.6.11 (#3664)
Bumps [prettier-plugin-tailwindcss](https://github.com/tailwindlabs/prettier-plugin-tailwindcss) from 0.6.8 to 0.6.11.
- [Release notes](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/releases)
- [Changelog](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/blob/main/CHANGELOG.md)
- [Commits](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/compare/v0.6.8...v0.6.11)

---
updated-dependencies:
- dependency-name: prettier-plugin-tailwindcss
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-18 09:33:23 +01:00
dependabot[bot] 68b61de895 ⬆️ Bump @changesets/cli from 2.27.11 to 2.28.1 (#3666)
Bumps [@changesets/cli](https://github.com/changesets/changesets) from 2.27.11 to 2.28.1.
- [Release notes](https://github.com/changesets/changesets/releases)
- [Changelog](https://github.com/changesets/changesets/blob/main/docs/modifying-changelog-format.md)
- [Commits](https://github.com/changesets/changesets/compare/@changesets/cli@2.27.11...@changesets/cli@2.28.1)

---
updated-dependencies:
- dependency-name: "@changesets/cli"
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-18 09:33:06 +01:00
Ken 528d4afa98 [Aksel.nav.no] Add support for "standalone" articles (#3657)
* 📝 Reposition sanity fields

* ✨ Added new standalone-category to sanity docs

* ✨ Added validation to make sure standalone articles dont overlap with sections

* 🐛 Always error out if using standalone articles until implemented

* 🔥 Removed temp removal of feature

* 🐛 Check for undefined slug

* [Aksel.nav.no] Implemented support for new lvl 1 articles  (#3658)

* ✨ Added support for new lvl 1 articles

* 🧪 Added tests for new sidebar

* 🔥 Removed breadcrumb from WithSidebar layout

* 🐛 Revert to prod dataset
2025-03-14 15:53:16 +01:00
dependabot[bot]andJulian Nymark 3d3e26a555 ⬆️ Bump denoland/setup-deno from 1 to 2 (#3541)
* ⬆️ Bump denoland/setup-deno from 1 to 2

Bumps [denoland/setup-deno](https://github.com/denoland/setup-deno) from 1 to 2.
- [Release notes](https://github.com/denoland/setup-deno/releases)
- [Commits](https://github.com/denoland/setup-deno/compare/v1...v2)

---
updated-dependencies:
- dependency-name: denoland/setup-deno
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* update article-views to deno 2

* scripts: chagelog (add deno.json)

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Julian Nymark <julian.nymark@nav.no>
2025-03-14 12:56:51 +01:00
KenandCopilot adaee5e002 [Darkside] Interaktiv migrering (#3642)
* ✨ Setup darkside migration

* ✨ Can now convert primitives spacing

* 🧪 Added more tests

* 📝 Docs for utils

* 📝 Changeset

* 📝 Typos

* [Darkside] ✨ Added migration for css, less and scss (#3598)

* ✨ Added migration for css, less and scsss

* Update @navikt/aksel/src/codemod/migrations.ts

* ✨ Make old px spacing space-1

* ✨ Use esbuild to inline local references

* ✨ Added js migration to space-tokens (#3600)

* ✨ Setup first iteration of token translation object

* ✨ Started mapping old to new tokens

* ♻️ Simplified repalcement logic

* ✨ Added tests for token-migration

* ✨ Replaces old token with new reference

* ✨ Handle overrides of tokens

* 🧪 Global messages storage

* 📝 Added migration

* 🐛 Initialize message list

* ✨ Customizable results messaging

* ✨ Customizable results messaging

* 🐛 Use replacement, not ref

* 📝 Only document found legacy-tokens, dont rename them

* 📝 Better comments

* ✨ Added context to remaining token updates

* ✨ Added comments to unsupported token

* ✨ Format comments better, remove duplicates

* 📝 Success message if no legacy-tokens found

* 🐛 Return updated source files

* 🐛 Reference valid replacement

* 🔥 Removed comments

* ✨ Added better messaging

* ✨ Better messaging structure

* 🧪 Added more tests

* 🧪 Tests for less, scss, css and js tokens

* 🐛 CSS hits were shown as scss and less hits

* 📝 Format messages better

* 📝 Format messages better

* ✨ Added js-migrations template

* Update test runner

* 🐛 Revert mistakes

* 🐛 Resolve testing rig

* ✨ Js token migration

* 📝 Better docs for JS migration

* 📝 Added missing lineshift

* ✨ Tooling setup

* ✨ Tooling setup with enquirer

* ✨ Tooling setup with enquirer

* ✨ Set up inquirier and enquirer to promt user for tasks

* ✨ Get legacy-data

* ✨ Now formats and prints progress

* ✨ Now formats and prints progress

* ⚡ Smarter scanning of updated tokens

* ⚡ Refactored status-code

* ✨ Now prints remaining files

* ✨ Smarter tailwind-regex

* 📝 Tell user we are scanning the files

* ✨ Moved transforms to new darkside location

* 🚚 Moved tests for js transforms

* 📝 Updated prettier config to ignore new test-files

* 📝 Moved css, less, scss tests

* 🐛 Resolved tests not running properly on less,scss setup

* WIP: tailwind config migration

* 📝 Added tailwind config for border-radius

* ✨ Strictly match tailwind-classes

* ♻️ Convert status obj to class

* ♻️ Compact regex parsing

* ♻️ Simplified regex-handling for new token lookup

* ✨ Added support for component tokens

* ⚡ Optimize lineNumber task

* 🐛 Inline regex-probe

* 🐛 Remove old merged code

* 🐛 Fix regex escape-characters

* Update @navikt/aksel/src/darkside/index.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 🐛 Fix token-tests

* ✨ Now prints with token-name

* ♻️ Move files

* ♻️ Move printing to TokenStatus class

* ✨ Add comments to printout

* 🐛 Handle word boundaries

* ⚡ Pre-generate the regexes

* 🧪 More regex-tests

* 🧪 More regex-tests

* ⚡ Use built-in regexes

* ⚡ Only run codeshift on relevant files

* 🐛 No print for codemod status update

* ⚡ Only run codeshift on relevant files

* 📝 Added extra space

* 📝 Exit after codemod

* 📝 Removed temp logging

* 🐛 Await codeshift execution

* 🧪 Added tests for not imported JS-tokens

* ✨ Implemented tailwind migration code

* 🧪 @apply tests for tailwind transform

* 🐛 Handle spaces better for tailwind config

* 🐛 Handle prefixing of tailwind config correctly

* 🐛 Handles cases where empty collection was passed

* 🐛 makes sure to clean up match before parsing

* 🧪 More tailwind-codemod tests

* ⚰️ Removed moved code, renamed darkside -> spacing for migrations

* ♻️ Config cleanup part 1

* ♻️ Config cleanup part 2

* ♻️ Refactored runner

* ✨ Added run all migraitons task

* 🐛 Use destrucutred taskname

* 📝 Better naming

* 📝 More spesific import docs

* 🐛 Print filename correctly when token contains special characters

* 🐛 Update spacing migrations paths

* 🐛 Added new spacing-tokens to legacy config

* ✨ Initialize status directly in constructor

* ⬆️ yarn lock sync

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-03-14 12:52:20 +01:00
Ken e826eb7bc6 ✨ Use ctrl + k for search-shortcut (#3660) 2025-03-14 12:41:35 +01:00
github-actions[bot] edd64c4bcd Version Packages (#3653)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-03-13 15:22:54 +01:00
Ken 4eba5a929c [Datepicker] Allow selecting dates when from is undefined (#3655)
* 🐛 Handle cases where to is defined and from is undefined

* 🐛 Fix missing state-option when selecting ranged datepicker values

* Update @navikt/core/react/src/date/datepicker/DatePicker.stories.tsx

* Update @navikt/core/react/src/date/datepicker/DatePicker.stories.tsx

* 🧪 Added tests for new ranged-datepicker logic

* 🐛 Typo
2025-03-13 14:48:23 +01:00
Ken a560bce1d2 [Aksel.nav.no] New Sidebar implementation (#3654)
* 🚚 Inline menu in TOC

* ♻️ Update import/exports

* ✨ Setup new sidebar

* WIP: Sidebar

* 💄 Styled dropdown button

* 💄 styled child-element

* WIP: sidebar designchanges

* 💄 Move notch to left of nested element

* ✨ Modulelerize sidebar

* 💄 Add hover-effects

* ✨ Added tag-support

* ♻️ Converted to css modules from tailwind

* 💄 Updated darkside styling

* 🐛 Re-add focus to item

* 🔊 Added logging to new sidebar

* ♻️ Inline isActive check

* ✨ Added mobile layout support

* 🐛 Layout prop now optional

* ♻️ Revert to legacy sidebar for prod

* 🔥 Removed new tailwind config import

* 🔥 Removed temp focus global css

* 🎉 Use new sidebar in prod

* 📝 Better CSS-naming

* 📝 Adde auto-open feature for future updates
2025-03-13 12:14:43 +01:00
Ken 1d3abd7a68 🚚 Inline menu in TOC (#3646)
* 🚚 Inline menu in TOC

* ♻️ Update import/exports

* 🐛 resolve toc import
2025-03-13 11:21:10 +01:00
Ken 8f3913c437 [Darkside] Fixed minifier for darkside CSS (#3648)
* ✨ Fix minifier

* ⚰️ Deleted clean-css package

* ⬆️ yarn lock sync

* ⬆️ yarn lock sync
2025-03-12 10:32:51 +01:00
Ken 56971a105d [Darkside] Padding sync (#3651)
* 🎨 Adjust padding in alert styles for consistency

* 🎨 Update chat bubble padding for improved consistency

* 🎨 Standardize padding in date and modal styles for consistency

* 🎨 Refactor padding in error summary styles for improved consistency

* 🎨 Adjust padding in file upload styles for improved consistency

* 🎨 Update padding in file upload styles for improved consistency

* 🎨 Adjust transition duration and padding for form progress and summary styles

* 🎨 Update padding in guide panel styles for improved consistency

* 📝 Changeset
2025-03-12 10:29:22 +01:00
github-actions[bot] 31ec44dd62 Version Packages (#3650)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-03-11 15:24:04 +01:00
Ken e769eed269 🐛 Darkside: Removed stacking backgrounds with transparency in Combobox. 2025-03-11 15:00:56 +01:00
dependabot[bot] b374aaa03e ⬆️ Bump browserslist from 4.24.2 to 4.24.4 (#3639)
Bumps [browserslist](https://github.com/browserslist/browserslist) from 4.24.2 to 4.24.4.
- [Release notes](https://github.com/browserslist/browserslist/releases)
- [Changelog](https://github.com/browserslist/browserslist/blob/main/CHANGELOG.md)
- [Commits](https://github.com/browserslist/browserslist/compare/4.24.2...4.24.4)

---
updated-dependencies:
- dependency-name: browserslist
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-11 11:23:51 +01:00
dependabot[bot] a6ab5335e0 ⬆️ Bump axios (#3643)
Bumps the npm_and_yarn group with 1 update in the /@navikt/aksel directory: [axios](https://github.com/axios/axios).


Updates `axios` from 1.7.4 to 1.8.2
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](https://github.com/axios/axios/compare/v1.7.4...v1.8.2)

---
updated-dependencies:
- dependency-name: axios
  dependency-type: direct:production
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-11 11:21:58 +01:00
Ken 9f37b3805e ✨ Added TOC-logging 2025-03-10 14:08:23 +01:00
dependabot[bot] c6ccfe53bc ⬆️ Bump lightningcss from 1.29.1 to 1.29.2 (#3641)
Bumps [lightningcss](https://github.com/parcel-bundler/lightningcss) from 1.29.1 to 1.29.2.
- [Release notes](https://github.com/parcel-bundler/lightningcss/releases)
- [Commits](https://github.com/parcel-bundler/lightningcss/commits/v1.29.2)

---
updated-dependencies:
- dependency-name: lightningcss
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-10 09:30:22 +01:00
Ken 0279b19579 [Aksel.nav.no] Track cookie clicks (#3638)
* ✨ Added sanity-config for tracking cookie-banner clicks

* ✨ Added logging for new cookie banner button

* 🐛 Don't return value from api
2025-03-07 16:30:38 +01:00
Ken 80f12069e1 ✨ Added URL-tracking to gp-chip navigation 2025-03-07 13:07:56 +01:00
Ken 7915b7e47b 🐛 Brakk god-praksis sider 2025-03-07 13:05:00 +01:00
Ken 3c646465b4 🔊 Added logging to gp-chips 2025-03-07 12:28:45 +01:00
github-actions[bot]andgithub-actions[bot] d37d03f05c Version Packages (#3636)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-03-07 10:54:27 +01:00
Ken c1b2944321 🐛 Fixed bug where '@media print' would hide header content. (#3634) 2025-03-07 10:37:19 +01:00
Ken c0078f1199 ✨ Add shortcut to header button (#3631) 2025-03-07 10:36:49 +01:00
Ken e7f42ab02e [Website] Replace amplitude with umami logging (#3625)
* ✨ Use umami instead of amplitude track

* 🐛 Check for umami before manually logging event

* 🐛 Re-added missing navigational logging

* 🐛 Removed kbd styling causing styles
2025-03-07 09:56:34 +01:00
Sjur abd5de2304 Update global.tokens.ts (#3633)
Endret i darkmode
Brand Blue og Success, 100 - 400, endret saturation til 100.
Accent, 100 - 400, endret saturation til 60.
Alle farger 600, endret til kontraststop til 4.52:1. Bug, noen farger havnet under 4.5:1.
Alle farger 1000, endret saturation til 100.
2025-03-06 16:33:21 +01:00
Ken 7f895df4a9 [Website] Nextjs v15 and sanity update (#3623)
* ✨ Added next 15 support

* ✨ Updated Sanity and nextjs

* ⬆️ yarn lock sync

* 🐛 Use newest ubuntu action runner

* 🐛 Removed redundant kbd-styling

* ⬆️ Updated to sanity 3.78

* ⬆️ yarn lock sync

* ⬆️ yarn lock sync
2025-03-06 10:34:47 +01:00
Ken ffd7e818e3 📝 Updated px-values shown for Heading examples 2025-03-06 10:22:27 +01:00
github-actions[bot]andgithub-actions[bot] 7894bbb510 Version Packages (#3630)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-03-06 10:01:50 +01:00
Ken 9f4535e6bb ✨ Aria-tags forwarded to list-element in list (#3626) 2025-03-06 09:59:47 +01:00
github-actions[bot]andgithub-actions[bot] 93dacbd854 Version Packages (#3628)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-03-05 10:43:20 +01:00
Ken 231c0b89a4 🐛 Resolved issue with react 19 types where children.props were unknown in Slot (#3627) 2025-03-05 10:40:42 +01:00
Julian Nymark f7f9436110 🔥 remove examples using deprecated title and description props (#3622) 2025-03-05 09:11:11 +01:00
0840a9211e ⬆️ Bump swr from 1.3.0 to 2.3.2 (#3574)
* ⬆️ Bump swr from 1.3.0 to 2.3.2

Bumps [swr](https://github.com/vercel/swr) from 1.3.0 to 2.3.2.
- [Release notes](https://github.com/vercel/swr/releases)
- [Commits](https://github.com/vercel/swr/compare/1.3.0...v2.3.2)

---
updated-dependencies:
- dependency-name: swr
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* 🐛 Sync swr instances

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-03-04 18:19:58 +01:00
Ken 9f0aed817f 🐛 Use ubuntu-latest for workflow actions, resolving brownout 2025-03-04 16:14:36 +01:00
fa1862da0d ⬆️ Bump stylelint-config-standard from 36.0.1 to 37.0.0 (#3570)
* ⬆️ Bump stylelint-config-standard from 36.0.1 to 37.0.0

Bumps [stylelint-config-standard](https://github.com/stylelint/stylelint-config-standard) from 36.0.1 to 37.0.0.
- [Release notes](https://github.com/stylelint/stylelint-config-standard/releases)
- [Changelog](https://github.com/stylelint/stylelint-config-standard/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint-config-standard/compare/36.0.1...37.0.0)

---
updated-dependencies:
- dependency-name: stylelint-config-standard
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* 🎉 Resolved stylelint versions mismatch

* 🎉 Resolved stylelint versions mismatch

* 🐛 Resolve dependency-mismatch for postcss node type

* 🐛 Revert inline-changes, use stylelint param type instead

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2025-03-04 15:06:15 +01:00
Ken 470518442f 🔥 Removed unused watch-script for ds-css, removed nodemon dependency 2025-03-04 13:14:08 +01:00
dependabot[bot] 46a5d20ce0 ⬆️ Bump lightningcss from 1.28.2 to 1.29.1 (#3571)
Bumps [lightningcss](https://github.com/parcel-bundler/lightningcss) from 1.28.2 to 1.29.1.
- [Release notes](https://github.com/parcel-bundler/lightningcss/releases)
- [Commits](https://github.com/parcel-bundler/lightningcss/commits)

---
updated-dependencies:
- dependency-name: lightningcss
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-04 13:12:10 +01:00
Ken 97130db7a5 💄 Use secondary-buttons for consent-banner 2025-03-04 13:11:59 +01:00
Ken a5e64c9f74 [Darkside] P3: Migrating all tokens to new prefix and colors (#3612)
* ✨ Setup darkside migration

* ✨ Can now convert primitives spacing

* 🧪 Added more tests

* 📝 Docs for utils

* 📝 Changeset

* 📝 Typos

* [Darkside] ✨ Added migration for css, less and scss (#3598)

* ✨ Added migration for css, less and scsss

* Update @navikt/aksel/src/codemod/migrations.ts

* ✨ Make old px spacing space-1

* ✨ Use esbuild to inline local references

* ✨ Added js migration to space-tokens (#3600)

* ✨ Setup first iteration of token translation object

* ✨ Started mapping old to new tokens

* ♻️ Simplified repalcement logic

* ✨ Added tests for token-migration

* ✨ Replaces old token with new reference

* ✨ Handle overrides of tokens

* 🧪 Global messages storage

* 📝 Added migration

* 🐛 Initialize message list

* ✨ Customizable results messaging

* ✨ Customizable results messaging

* 🐛 Use replacement, not ref

* 📝 Only document found legacy-tokens, dont rename them

* 📝 Better comments

* ✨ Added context to remaining token updates

* ✨ Added comments to unsupported token

* ✨ Format comments better, remove duplicates

* 📝 Success message if no legacy-tokens found

* 🐛 Return updated source files

* 🐛 Reference valid replacement

* 🔥 Removed comments

* ✨ Added better messaging

* ✨ Better messaging structure

* 🧪 Added more tests

* 🧪 Tests for less, scss, css and js tokens

* 🐛 CSS hits were shown as scss and less hits

* 📝 Format messages better

* 📝 Format messages better

* ✨ Added js-migrations template

* Update test runner

* 🐛 Revert mistakes

* 🐛 Resolve testing rig

* ✨ Js token migration

* 📝 Better docs for JS migration

* 📝 Added missing lineshift

* 🐛 Revert migration conflicts

* 📝 Better status docs
2025-03-04 13:06:33 +01:00
Ken 6e2e7a6d46 🐛 Resolve cookie-popup for /admin pages 2025-03-04 12:45:13 +01:00
Ken b9c1984078 ♻️ Cookie-tracking bug (#3620)
* ♻️ Cookie-tracking refactor

* 🐛 Memorize consent

* 🐛 Test always rendering script-tag

* 🐛 Test adding domains

* 📝 Test logging when tracking is enabled

* 🐛 Log umami-state

* 🔥 Revert test-config

* 🔥 remove manual umami track
2025-03-04 12:12:58 +01:00
github-actions[bot]andgithub-actions[bot] 2473bf4a96 Version Packages (#3619)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-03-04 11:21:50 +01:00
Ken 9add24abae 🐛 Added umami.nav.no to accespolicy 2025-03-03 16:29:56 +01:00
d4cfd094f4 Cookiebanner + Umami tracking (#3596)
* 🚧 umami test script

* 🚧 CSP for umami

* 🚧 test data-tag, set no auto tracking

* ♻️ make consentBanner more self contained

* 🚧 working implementation for consent modal

* ♻️ move ConsentBanner to website-modules + small changes

* use typescript-cookies over localStorage API

* Copy Nav.no consent text

* better name for cookie

* 🚧 crude complex consent object

* Update aksel.nav.no/website/components/website-modules/ConsentBanner.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* classify traffic better (umami)

* Update aksel.nav.no/website/components/website-modules/ConsentBanner.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* link to our own personvernerklering + disable modal on that specific page

* use same conditions for all showModal() triggers

* update comment

* limit cookie to specific subdomain (prevent it getting sent by clients to other *.nav.no pages

* remove the MutationObserver, but keep query param to disable banner (for tests)

* bypass banner in e2e tests

* store "no action" consent data in sessionStorage

* 🚧 change to in document flow style banner (no more modal)

* 📱 responsive consent banner++

* website: set cookie domain dynamically (from serving site)

* hardcode /side/personvernerklaering

* 🚧 placeholder cookie preferences box

* cookie preferences box++

* dokmøte plenumsendringer

* move page personvernserklaering

* make the cookie preference form functional

* ♿ add missing aria-labelledby target

* re-enable banner on e2e search tests

* Add explanation to organic and polluted traffic

* extract consent state into custom hook

* PR review changes

* ✨ Serverside-check for cookie consent

* banner set tracking id from env var

* remove unused url param check

* env var toggle for PRODUCTION

use this to inject code scripts clientside, do stuff during build or anything else really! (better to use this than NODE_ENV)

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-03-03 12:50:07 +01:00
Ken 5dbf34492a 📝 Better jsdoc for Theme-component 2025-03-03 12:21:45 +01:00
KenandJulian Nymark 96b9b8e5bc [Darkside] Implement className-switch (#3586)
* 📝 Update Accordion root

* 📝 Added comment to cn-function

* 📝 Updated Accordion, Alert and Button

* ♻️ Chat and Chips

* ♻️ CopyButton

* ♻️ Datepicker

* ♻️ Dropdown

* ♻️ ExpansionCard

* ♻️ Combobox

* ♻️ ConfirmationPanel

* ♻️ Tag

* ♻️ Timeline

* ♻️ Timeline++

* 📝 Theme

* ♻️ Panel

* ♻️ Stepper

* ♻️ Tabs

* ♻️ Skeleton

* ♻️ Popover

* ♻️ Loader

* ♻️ Link

* ♻️ Tooltip

* ♻️ Table

* ♻️ ErrorSummary -> FormSummary update

* ♻️ Radio, Search

* ♻️ Switch, Textarea

* ♻️ Textfield, guidepanel, Helptext

* ♻️ InternalHeader

* ♻️ Primitives -> List

* ♻️ Modal

* ♻️ ActionMenu

* ♻️ Pagination -> Typo

* ♻️ Update missing renames

* ♻️ Update migrated datepicker-components to use new className prefix

* [Darkside] ClassName prefix update CSS (#3591)

* 🚚 Rename all .navds prefixes to .aksel

* 📝 Changeset

* 📝 MD-docs

* ♻️ Update aksel prefixing for theme

* Update .storybook/docs/PilotsChangelog.mdx

---------

Co-authored-by: Julian Nymark <julian.nymark@nav.no>
2025-03-03 11:30:48 +01:00
github-actions[bot]andgithub-actions[bot] a98bfb7a90 Version Packages (#3618)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-03-03 10:43:25 +01:00
Ken 6728754503 P1: [Darkside] Primitives spacing -> space migrations (#3597)
* ✨ Setup darkside migration

* ✨ Can now convert primitives spacing

* 🧪 Added more tests

* 📝 Docs for utils

* 📝 Changeset

* 📝 Typos

* [Darkside] ✨ Added migration for css, less and scss (#3598)

* ✨ Added migration for css, less and scsss

* Update @navikt/aksel/src/codemod/migrations.ts

* ✨ Make old px spacing space-1

* ✨ Use esbuild to inline local references

* ✨ Added js migration to space-tokens (#3600)

* ♻️ Use eslint-bundle as main build for CLI

* ♻️ Add mappings exports in ds-css, avoid using esbuild
2025-03-03 10:37:32 +01:00
github-actions[bot]andgithub-actions[bot] bf76336dc7 Version Packages (#3613)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-02-27 15:00:34 +01:00
Ken 06fecf2af1 🐛 Changed outline-offset to -3px in tabpanel 2025-02-27 14:58:51 +01:00
Ken 6ffebc72c7 🐛 Now hides global tokens from publishing in Figma 2025-02-25 11:36:08 +01:00
github-actions[bot]andgithub-actions[bot] c633deb3e7 Version Packages (#3604)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-02-24 11:01:35 +01:00
Ken 441d8b732c 💄 Bumped bg-raised token to neutral-200 in darkmode. 2025-02-24 09:54:15 +01:00
github-actions[bot]andgithub-actions[bot] 2a4465a051 Version Packages (#3603)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-02-20 16:24:29 +01:00
Ken b77dbe0cad 🐛 Datepicker now checks that from/to dates are actually another day (#3602)
* 🐛 Datepicker now checks that from/to dates are actually another day

* 🐛 Wraps fromY/to dates in startOfDay to handle timezone differences
2025-02-20 16:17:08 +01:00
github-actions[bot]andgithub-actions[bot] 78fc16c1a9 Version Packages (#3593)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-02-19 12:01:40 +01:00
Ken 5937d085c0 ✨ Spacer-tokens (#3587) 2025-02-19 09:51:09 +01:00
Ken 2f248a65f7 ✨ Added docs-config for tokens 2025-02-17 11:20:03 +01:00
KenandVegard Haugstvedt 08e134ef3c [Darkside] ✨ Re-added arrow to Tooltip (#3589)
* ✨ Re-added arrow to Tooltip

* Update .storybook/docs/PilotMigration.mdx

Co-authored-by: Vegard Haugstvedt <it.vegard@gmail.com>

---------

Co-authored-by: Vegard Haugstvedt <it.vegard@gmail.com>
2025-02-17 10:32:02 +01:00
Ken 821343b67d [Datepicker] Bumped react-day-picker to v9. (#3525)
* 📝 Bumped date-fns to v4

* TEMP UPDATES

* TEMP CSS UPDATES

* ✨ New Caption component for datepicker

* ♻️ Extract util

* ♻️ Refactor standalone datepicker

* ♻️ Refactor dialog datepicker

* ♻️ Migrated weekday-click

* ♻️ Migrated mobile-view week-click

* ⚰️ Removed old code

* 🚚 Re-strucutre project

* 🐛 Fix imports

* ♻️ New MonthPicker context

* ♻️ Replace use to MonthPickerContext

* ♻️ Migrated standalone monthpicker

* ♻️ Remove react-day-picker connection for utils

* 🚚 Re-structure MonthPicker

* 📝 rename context

* 🚚 Re-structure DatePicker

* 🐛 Fix imports and nb

* ♻️ Parts restructure

* 🚚 Move inputcontext

* 🚚 Co-locate date-spesific context

* 🚚 Co-locate date-hooks

* 🐛 Update missing import-updates

* 🐛 Use new input-context in modal, popover

* 🚚 Moved new utils into date-utils

* ♻️ simplified calendar-range logic

* 🐛 Fix test-runs

* 🧪 Storybook tests for monthpicker

* 🧪 Storybook tests for monthpicker

* 💄 Lock datepicker dialog to top of screen

* 🐛 Don't re-open modal

* 🐛 Avoid double open-toggle

* 🧪 Storybook tests for DatePicker

* ♻️ Use local dateRange-handler

* 🐛 month-update caused custom-components to re-render

* 🐛 casings

* 🐛 casings 2

* 🐛 casings 3

* 🐛 casings 4

* 🧪 Added tests for legacy dom-structure

* 🐛 Resolved re-render causing tests to fail

* 🧪 More datepicker tests, daypicker now requires us to handle focus

* 📝 Changeset

* Update @navikt/core/react/src/date/datepicker/parts/DatePicker.RDP.tsx

* 🐛 Added weekend-className for backwards compat support

* 📝 yarn lock sync

* 🐛 Allow defaultMonth-prop in Datepicker
2025-02-17 09:46:40 +01:00
Ken 19b42daa69 🐛 New 'god-praksis' artikles were hidden from frontpage unless referenced to 2025-02-14 14:59:22 +01:00
github-actions[bot]andgithub-actions[bot] 09c44edccb Version Packages (#3584)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-02-14 14:38:59 +01:00
Ken 2fab45f757 ✨ Added contrast-token to themable-roles 2025-02-14 14:16:51 +01:00
Ken 1ba5d9b5a2 [Darkside] Added support for ConfirmationPanel, Linkpanel, Panel and Dropdown. (#3581)
* ✨ Added ConfirmationPanel to darkside

* ✨ Added Panel support

* ✨ Added linkpanel support

* ✨ Added dropdown support

* 📝 changeset

* 🐛 Removed exception for now re-added CSS
2025-02-13 19:29:13 +01:00
Ken 5a749690c6 [Darkside] Updated darkside token-build (#3578)
* ✨ Added themed roles config to darkside

* ♻️ Rename breakpint config

* 🚚 Move files

* 🐛 Update renamed import

* 🐛 Build theme-files before readig them

* ♻️ Refactored color-tokens setup

* ♻️ Updated setup and imports

* ♻️ Hide unwanted tokenfiles

* 🐛 Update imports for refactored colors

* ♻️ Simplified token-build

* ♻️ Removed custom root build

* ♻️ Add cleanup-step

* 📢 Hide verbose warnings

* 🐛 Added --ax- prefix to global tokens

* 📝 Removed dark-theme tag
2025-02-13 19:28:34 +01:00
KenandJulian Nymark 2f7873d3e7 [Aksel.nav.no] ✨ Highlights 'darkside' sections in sidebar (#3582)
* ✨ Highlights 'darkside' sections in sidebar

* 🔥 removed test-code

* Update aksel.nav.no/website/components/website-modules/menu/Menu.tsx

---------

Co-authored-by: Julian Nymark <julian.nymark@nav.no>
2025-02-13 15:35:46 +01:00
Ken e5dc975c44 ⬅️ Revert use of class update 2025-02-13 14:03:01 +01:00
Ken 1cc24c2998 [Darkside] Added hook for renaming className-prefix from navds-> aksel- (#3585)
* ✨ MVP replacement function

* ✨ Updated className replace function
2025-02-13 13:48:19 +01:00
Ken 636eb05bf5 ✨ Icon-update (#3583) 2025-02-13 13:24:27 +01:00
Ken c6424eda70 [Darkside] Tailwind support (#3580)
* 📝 Test config

* ✨ Added prefix-support, export for npm

* 📝 Added changeset, removed test-config

* 🐛 Removed conveluted tests

* 📝 Added temp-docs

* 📝 Added tailwind version suffix to export
2025-02-13 09:22:20 +01:00
Ken 90f76498d6 🐛 Handle icons where variant is 'filled' instead of 'fill'. 2025-02-13 09:14:42 +01:00
Julian Nymark 6201d87a1a Add more info on how to update an article (#3579) 2025-02-12 14:53:51 +01:00
Ken 4dcb4efeea 🐛 Fix flaky e2e-tests that timed out because of network-updates 2025-02-12 14:52:55 +01:00
Ken 5586d42096 Darkside role theming refactor (#3575)
* ✨ Added themed roles config to darkside

* ♻️ Rename breakpint config

* 🚚 Move files

* 🐛 Update renamed import

* 🐛 Build theme-files before readig them

* ♻️ Refactored color-tokens setup

* ♻️ Updated setup and imports

* ♻️ Hide unwanted tokenfiles

* 🐛 Update imports for refactored colors

* 📝 Clarify tests

* 📝 config -> configs
2025-02-12 09:24:43 +01:00
Ken 94e3bd7191 [Darkside] Added role-theming (#3569)
* ✨ Added themed roles config to darkside

* ♻️ Rename breakpint config

* 🐛 Update renamed import

* 🐛 Build theme-files before readig them

* 🐛 Updated breakpoint-import in test-files
2025-02-11 13:57:31 +01:00
Ken 0d886b12bf 📝 Added demo-page to pilot doc 2025-02-10 10:04:40 +01:00
Vegard Haugstvedt dfbec997fc Add language selector in decorator for templates (#3568) 2025-02-07 14:27:02 +01:00
Julian Nymark 1ec34524e7 Pilot docs edits (#3567)
* pilot text edits

* pilots edits

* pilot doc edits

* pilot doc edits

* update pilot docs
2025-02-07 12:53:16 +01:00
Ken 36f84458a5 🐛 Add type-annotations to exported ThemeProps 2025-02-07 12:08:52 +01:00
Julian Nymark 2271072d1c Website: remove snow (#3566) 2025-02-07 10:54:51 +01:00
Ken 0c22de8c61 [Aksel.nav.no] Added Hello bar under header (#3561)
* ✨ Added hello-bar

* 📝 Updated texts

* 🔥 Removed demo-versions

* 💄 Added x-axis padding
2025-02-06 13:50:00 +01:00
github-actions[bot]andgithub-actions[bot] 1b20ad54de Version Packages (#3563)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-02-06 13:17:51 +01:00
Ken 8576400263 🐛 Added BoxNew to index-export 2025-02-06 12:59:01 +01:00
github-actions[bot]andgithub-actions[bot] c1e6bcc6bd Version Packages (#3562)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-02-06 12:56:51 +01:00
Ken f269311dbb 🐛 Updated Theme component exports 2025-02-06 12:55:02 +01:00
Ken 11b1e98019 📝 Added link to design-docs for pilot-teams 2025-02-06 12:46:44 +01:00
github-actions[bot]andgithub-actions[bot] af39cbd79f Version Packages (#3557)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-02-06 12:41:35 +01:00
Ken a10e2a5c2d Merge branch 'main' of https://github.com/navikt/aksel 2025-02-06 12:16:51 +01:00
Ken bb02aa9c94 🐛 Updated List spacing in referansesider 2025-02-06 12:16:38 +01:00
Ken 2a26dc5130 ✨ Updated theme-switch toggle for demo pages 2025-02-06 12:14:37 +01:00
Julian Nymark cea27a85d9 pilot text edits (#3560)
* pilot text edits

* pilots edits
2025-02-06 12:11:18 +01:00
Ken 29798d83ac 🐛 Migrate referansesider to updated soft-hover tokens 2025-02-06 11:55:02 +01:00
Ken aefbf3e0de 🔥 Removed soft-hover and soft-pressed tokens 2025-02-06 11:53:39 +01:00
Ken ae02a87a9e [Darkside] Named brand-color tokens (#3559)
* 💄 Update background Header

* 💄 Update popover padding for smaller screens

* 💄 Adjusted borders

* 💄 Uses Alpha-tokens for zebra-stripes in Table

* 💄 Stronger border for hovered timeline items, transparent track bg

* 💄 Transparent lines for Tabs to contrast colored bg

* 💄 New icons for Table-sorting

* 💄 Selected exoanded item now has accent colors

* 💄 Keeps border-color for active state in search-button

* 💄 Removed hover-color change on checked radio

* 💄 Only non-responsive or left-static guidepanels shrink on tablet or below

* 📝 Changeset

* 🚚 -hover tokens are now soft-hover

* ✨ Added soft-pressed token

* 💄 Use new soft-pressed token where applicable

* 💄 Default colored text is now 1000, strong replaced by subtle

* 🏷️ Updated primitive types for new text-tokens

* 🚚 Migrated old text-role-strong color to text-role-default

* 🚚 Migrated referansesider to new text-colors

* 🚚 Referansesider uses new soft-hover token

* 🐛 Fallback to updated accent-color

* [Darkside] Removed 'base' as neutral role replacement (#3556)

* ♻️ Remove default-scale as replacement for neutral in config

* 🧪 Setup chromatic-run for complete build

* 🚚 Text migrated

* 🚚 Text icon migrated

* 🚚 Text contrast migrated

* 🚚 bg soft migrated to neutral

* 🚚 bg moderate migrated to neutral

* 🚚 bg strong migrated to neutral

* 🚚 border default migrated to neutral

* 🚚 border subtle migrated to neutral

* 🚚 border strong migrated to neutral

* ⬅️ Revert chromatic preview

* 🚚 Migrated referansesider to new neutral scale

* 🚚 Use named brand and meta-colors

* 🚚 Referansesider uses new brand-names token
2025-02-06 11:36:07 +01:00
Ken 2558874480 [Darkside] Default role-text is now 1000, strong replaced by subtle (#3555)
* 💄 Update background Header

* 💄 Update popover padding for smaller screens

* 💄 Adjusted borders

* 💄 Uses Alpha-tokens for zebra-stripes in Table

* 💄 Stronger border for hovered timeline items, transparent track bg

* 💄 Transparent lines for Tabs to contrast colored bg

* 💄 New icons for Table-sorting

* 💄 Selected exoanded item now has accent colors

* 💄 Keeps border-color for active state in search-button

* 💄 Removed hover-color change on checked radio

* 💄 Only non-responsive or left-static guidepanels shrink on tablet or below

* 📝 Changeset

* 🚚 -hover tokens are now soft-hover

* ✨ Added soft-pressed token

* 💄 Use new soft-pressed token where applicable

* 💄 Default colored text is now 1000, strong replaced by subtle

* 🏷️ Updated primitive types for new text-tokens

* 🚚 Migrated old text-role-strong color to text-role-default

* 🚚 Migrated referansesider to new text-colors

* 🚚 Referansesider uses new soft-hover token

* 🐛 Fallback to updated accent-color

* [Darkside] Removed 'base' as neutral role replacement (#3556)

* ♻️ Remove default-scale as replacement for neutral in config

* 🧪 Setup chromatic-run for complete build

* 🚚 Text migrated

* 🚚 Text icon migrated

* 🚚 Text contrast migrated

* 🚚 bg soft migrated to neutral

* 🚚 bg moderate migrated to neutral

* 🚚 bg strong migrated to neutral

* 🚚 border default migrated to neutral

* 🚚 border subtle migrated to neutral

* 🚚 border strong migrated to neutral

* ⬅️ Revert chromatic preview

* 🚚 Migrated referansesider to new neutral scale
2025-02-06 11:30:32 +01:00
Ken 83490d4711 [Darkside] Soft-pressed token (#3554)
* 💄 Update background Header

* 💄 Update popover padding for smaller screens

* 💄 Adjusted borders

* 💄 Uses Alpha-tokens for zebra-stripes in Table

* 💄 Stronger border for hovered timeline items, transparent track bg

* 💄 Transparent lines for Tabs to contrast colored bg

* 💄 New icons for Table-sorting

* 💄 Selected exoanded item now has accent colors

* 💄 Keeps border-color for active state in search-button

* 💄 Removed hover-color change on checked radio

* 💄 Only non-responsive or left-static guidepanels shrink on tablet or below

* 📝 Changeset

* 🚚 -hover tokens are now soft-hover

* ✨ Added soft-pressed token

* 💄 Use new soft-pressed token where applicable

* 🚚 Referansesider uses new soft-hover token
2025-02-06 11:19:04 +01:00
Ken 281ac2d940 [Darkside] 🚚 -hover tokens are now soft-hover (#3553)
* 💄 Update background Header

* 💄 Update popover padding for smaller screens

* 💄 Adjusted borders

* 💄 Uses Alpha-tokens for zebra-stripes in Table

* 💄 Stronger border for hovered timeline items, transparent track bg

* 💄 Transparent lines for Tabs to contrast colored bg

* 💄 New icons for Table-sorting

* 💄 Selected exoanded item now has accent colors

* 💄 Keeps border-color for active state in search-button

* 💄 Removed hover-color change on checked radio

* 💄 Only non-responsive or left-static guidepanels shrink on tablet or below

* 📝 Changeset

* 🚚 -hover tokens are now soft-hover

* 🚚 Referansesider uses new soft-hover token
2025-02-06 10:41:44 +01:00
Ken 70dd5b5926 ✨ Added descriptive naming for storybook controls 2025-02-06 10:41:27 +01:00
Ken fb5af09427 ✨ Added temp redirect to docs from /darkside 2025-02-06 10:38:29 +01:00
KenandVegard Haugstvedt e06f0c6f9e [Darkside] MVP documentation for testing (#3551)
* 📝 Setup docpage

* 📝 Setup page for docs

* 📝 Setup page for docs

* 📝 React-docs

* 📝 Clarify docs

* 📝 Token-docs

* 📝 Added changelog page

* 🔥 Removed references to static tokens

* 📝 Updated docs

* 📝 Updated migration

* 📝 Removed placeholder docs

* 📝 Use built-in color docs

* 📝 Second draft temp-docs

* 📝 Add feedback links, remove old css

* 📝 Updated docs

* Update .storybook/docs/PilotMigration.mdx

Co-authored-by: Vegard Haugstvedt <it.vegard@gmail.com>

---------

Co-authored-by: Vegard Haugstvedt <it.vegard@gmail.com>
2025-02-06 10:21:11 +01:00
Julian Nymark 5492741688 ⏪ remove our custom spa-deploy action
the feature for cache_invalidation has been merged upstream, so we can use that now.
2025-02-05 16:26:53 +01:00
Ken 2bba7af7c2 [List] Deprecate listprops title, headingTag and description (#3537)
* 🔥 Deprecated title, headingTag and description for List

* 📝 changeset
2025-02-05 11:24:50 +01:00
Ken 8f9f313a85 [Darkside] Quality assurance P8 (#3536)
* 💄 Update background Header

* 💄 Update popover padding for smaller screens

* 💄 Adjusted borders

* 💄 Uses Alpha-tokens for zebra-stripes in Table

* 💄 Stronger border for hovered timeline items, transparent track bg

* 💄 Transparent lines for Tabs to contrast colored bg

* 💄 New icons for Table-sorting

* 💄 Selected exoanded item now has accent colors

* 💄 Keeps border-color for active state in search-button

* 💄 Removed hover-color change on checked radio

* 💄 Only non-responsive or left-static guidepanels shrink on tablet or below

* 📝 Changeset
2025-02-05 11:24:27 +01:00
Ken 1c31997be9 🔥 Avoid exporting 'static' tokens until needed. 2025-02-05 09:10:30 +01:00
Ken 75d2f7a595 [Darkside] Quality assurance P7 (#3530)
* 💄 Stepper text-colors

* 💄 Adjusted paddings form-summary

* 💄 Alpha-border formsummary

* 🐛 Re-added animation to formprogress

* 💄 moderate active state for button

* ♻️ Copybutton re-uses button-component

* 💄 Updated shadow for lightmode

* 🔥 Removed comments CopyButton

* 📝 Added bw-compatibility for CopyButton

* 🐛 Added default-size for legacy CopyButton

* 🐛 Boolean flipped so that legacy wrapper were used on wrong state

* 🐛 Boolean flipped so that legacy wrapper were used on wrong state

* 🐛 Now accounts for custom icons in legacy CopyButton
2025-02-04 19:01:46 +01:00
62aa43bab2 demoside aktivitetsplan (#3552)
* Getting started converting ActivityPlan to Aksel components

* Refactor ActivityColumn

* attempt to add Theme (from local path)

* 🚧

* 🐛 minify strips navds-r-p?

* use correct react package (local) and use padding prop

* correctly use the Theme wrapper in ThemeProvider

* Refactored MainCard

* Make ActivityCard more similar to "the real deal".

* Reduce column padding

* use Link component

* add missing href to links in sykepenger

* remove generic seletors on root

* dark mode for sykepengericon (also use tokens)

* Fixes console warnings

* Added activity view for activity plan reference page

* Design review changes

* Add HelpText to columns

* Add focus indicator for activity cards

* Minor css tuning

* 🐛 Blogg did not sort latest articles by publishDate

* [Actions] ⚡ Optimize workflows (#3480)

* 🚚 Moved auth-token, fetch less history

* ♻️ Use composite actions for workflow

* 🐛 Checkout before running composite workflow

* 🚚 Move composite actions to separate dir

* ♻️ Pass token to composite action

* 📝 Better test names

* ⚡ Optimize chromatic workflow

* ⚰️ Removed old and broken redeploy action

* ⚡ Optimized website-build

* ♻️ Use composite actions for prod and dev build

* ⚡ Reduced e2e tests by 40%

* ⚡ Improved sandbox testing

* ⚡ Update search-tests

* 🐛 Disable invalid example-demos

* 🐛 Wait for search completion

* 📝 removed old env input

* 🐛 Moved vars out to input

* 🐛 Don't ignore inputs for if-tests

* 🐛 Check input for truuthynes

* test: Run sharded playwright

* 🐛 Removed sharded workflow

* ⚡ Update re-use of actions

* 🐛 Keep full git-history for chroamtic

* Update .github/workflows/chromatic.yml

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>

* Update .github/workflows/referansesider-spa-deploy.yml

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>

* Update .github/workflows/ci.yml

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>

* Update .github/workflows/ci.yml

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>

* Update .github/workflows/ci.yml

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>

* Update .github/workflows/ci.yml

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>

* Update .github/workflows/ci.yml

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>

* Update .github/workflows/ci.yml

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>

* 📝 Typo

* 📝 Typoo

* ⚡ Use built-in report for playwright

* 🐛 Use html-reporter, not list

---------

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>

* [Darkside] P 1/3 ♻️  Updated `default` scale to replace `neutral`-scale (#3487)

* ✨ Added new space tokens

* 🚚 Updated spacing-definitions

* ✨ Added new space-tokens to old system

* ✨ Added support for new space tokens i primitives

* 🔥 Removed space-tokens from tailwindcss

* 📝 Removed old comments

* [Darkside] Spacing -> Space update for CSS (#3478)

* 🚚 Migrated to new space-token

* 📝 Add docs for temp spacing

* 🐛 Add missing token-prefix to docs

* 🐛 Remove old tests

* 🐛 Added legacy-spacing support for primitives when using new theme-stystem

* ♻️ Move neutral-scale -> default scale

* ♻️ New box now supports updated default tokens

* ♻️ Default -> Soft token

* 📝 Update js-doc

* [Darkside] P 2/3 ♻️ Global/Meta-token naming, bumped role-scale (#3499)

* 💄 Text and border-tokens for roles bumped up

* 📝 Update global and meta-colors to numbers, removed hover color on accordion/button

* [Darkside] P 3/3 ♻️ Old neutral-scale now uses default-scale (#3488)

* ♻️ Use default-tokens for old neutral-scale

* 🐛 Fixed missing token migrations

* ♻️ role default  -> role-soft

* ♻️ Re-structure order and texts for GP section (#3492)

* ♻️ Re-structure order and texts for GP section

* 📝 Avoids extra capitalization for names

* Added script to check version-sync between workspace (#3486)

* ✨ Added script for verifying dep-versions across workspace

* ✨ Added script for verifying dep-versions across workspace

* ✨ Added script for verifying dep-versions across workspace

* ✨ Added script for verifying dep-versions across workspace

* ✨ Added script for verifying dep-versions across workspace

* 📝 Better texts

* 📝 Better texts

* 📝 Added comments

* 📝 Updated minoer package-differences

* 📝 Upgraded stylelint

* 📝 Upgraded babel-loader

* 📝 Add ^ to ds-css versionsing across repo

* ♻️ Small refactor to reduce use of forEach

* Table: Removed border-bottom for HeaderCell used in ExpandableRow (#3503)

* Use HeaderCell for name in expandable table example

* 🐛 Removed border-bottom for HeaderCell used inside ExpandableRow

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>

* Version Packages (#3505)

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>

* ♻️ Removed raised-tokens from darkside roles

* 💄 Incremental layout and list-view update on Produktbloggen

* 🐛 Added missing 'li'-tag for list-item in blogglist

* [Table] ExpandableRow `contentGutter`-prop (#3507)

* ✨ New prop contentGutter for ExpandableRow component

* ✨ Added new prop-support in darkside CSS

* 📝 changeset

* Update @navikt/core/react/src/table/ExpandableRow.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 Third bloggpost was sliced from view on frontpage

* ⬆️ Bump vite from 5.4.8 to 5.4.12 in /examples/referansesider (#3516)

* ⬆️ Bump vite from 5.4.8 to 5.4.12 in /examples/referansesider

Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 5.4.8 to 5.4.12.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v5.4.12/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.4.12/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>

* Repo-bump vite

* 🔀 Yarn lock

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>

* 📝 Added new sidebar category for /komponenter

* always render the maxSelected message when isMultiSelect (#3506)

* always render the maxSelected message when isMultiSelect

* also check if maxSelected is set

* Changeset

* Update .changeset/swift-readers-check.md

---------

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* 💄 Error borders uses danger-strong consistently (#3512)

* ♻️ Fix #3451 scaling for 400% zoom (#3514)

* 🐛 Using 'loader' inside 'icon'-prop broke layout caused by position absolute (#3515)

* [Darkside] Quality assurance P1 (#3510)

* 💄 Adjustments 1

* 💄 Bumped default strong scale

* 💄 Bumped secondary neutral border

* 💄 Reduced text-color change on hover

* 🐛 Resolved border and focus logic for combobox

* 🐛 Fix icon sizing for buttons

* 💄 Use tertiary-buttons for datepicker caption

* Update @navikt/core/react/src/chips/Toggle.tsx

* 💄 QA updates combobox darkside (#3511)

* Update swift-readers-check.md

* Version Packages (#3509)

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>

* Update LICENSE

* [Darkside] Updated Focus design for Checkbox, Radio and Switch  (#3513)

* 💄 Focus-outline now around item checkbox,radio

* 🐛 Resolved small and indeterminate-state

* 💄 updated focus-markings for switch

* Update @navikt/core/css/darkside/form/radio-checkbox.darkside.css

* 🐛 Hide new indeterminate node from old checkbox

* [Darkside] Quality assurance P4  (#3518)

* 💄 Adjust bg transparency

* 💄 Default border now same scale as roles

* [Darkside] Quality assurance P5 (border-radius and font-weight)  (#3519)

* 💄 Update border-radius based on Figma

* 💄 More border-radius adjustments

* 💄 Bolder medium+ headings

* [Darkside] Updated focus-outline (#3520)

* 💄 Updated focus-outline

* 🧪 Added legacy-support for deprecated files

* 🐛 Account for legacy files in count

* [Darkside] Quality assurance P6 (Fileupload) (#3524)

* 📝 Update FileUpload CSS-artifacts

* 🐛 Synced release-text with updated role-colors

* ✨ New icons for sorting (#3528)

* Theming for sykepenge icon

* 🐛 Use correct global token for darkside JS

* Updated SykepengerIcon to be one shape

* Changed text color to subtle

* Layout fixes

* Refactor activity modal and improve rendering of activity details

* Remove the decorator from the activity plan reference page to reduce complexity

It is not necessary to show off dark mode, and it introduces some problems we need to solve.
Will keep the code, so we can re-introduce it later if we want.

* remove route listing, redirect index.tsx to aktivitetsplan

* re-add the switcher

* resulotions for ds-react, and tweak spacing for header

* Fill out more activity details

* remove unused files + fix up some old tokens

* Darker modal backdrop

* Make JobInterestBox stand out more in dark mode

* Adjust heading size to better preserve hierarchy, although the modal header should have been larger instead (not supported)

* Add gap for better responsiveness on mobile

* Revert to secondary button to not conflict with other primaries. May revisit this later

* Increased Page.Block gutter tokens

* Background softA is now working, so we don't need to check for which is the active theme

* Better responsiveness

* Add "Add new activity" modal

* Reduce texts for responsiveness

* Make "save" button narrower

* 🚧 test deploy cache-invalidation

* 👷 test again

* 💄 remove border under ThemeSwitch

* Delete .changeset/late-hotels-try.md

* Delete @navikt/core/css/darkside/primitives/page.darkside.css

* Revert "Delete @navikt/core/css/darkside/primitives/page.darkside.css"

This reverts commit e1d683898a.

* undo the change that will be done on main

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Vegard Haugstvedt <it.vegard@gmail.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-04 16:57:53 +01:00
Ken 2434037250 🐛 Use new spacing-tokens in darkside theme 2025-02-04 16:44:11 +01:00
Julian Nymark a667f53dba 👷 testing++ 2025-02-04 14:50:57 +01:00
Julian Nymark 7bf6a81bd5 👷 testing 2025-02-04 14:40:49 +01:00
Julian Nymark 9bda05c3ce 👷 test using local action in workflow 2025-02-04 14:36:40 +01:00
Julian Nymark 6a7fbf7cc2 🚧 test adding a copy (with desired flag) of spa-deploy
action
2025-02-04 14:36:01 +01:00
Julian Nymark 51cc4de4df 👷 trying cache_invalidation for SPA deploy 2025-02-04 13:59:06 +01:00
Ken 132e2080a7 🐛 Revert vite v6 update, storybook fails on startup 2025-02-04 12:16:53 +01:00
Ken a516955681 ✨ Re-added neutral-roles scale 2025-02-03 15:02:25 +01:00
Andreas Nordahl 81449a3e67 Selecting an indeterminate checkbox checks all child items (#3549)
Ref. https://m3.material.io/components/checkbox/guidelines#26cbff1c-7a56-4237-b563-5593573e6cf4

| If some, but not all, child checkboxes are checked, the parent checkbox becomes an indeterminate checkbox. Selecting an indeterminate checkbox checks all child items.
2025-02-03 14:07:55 +01:00
github-actions[bot]andgithub-actions[bot] bb00b750e6 Version Packages (#3529)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-02-03 12:19:10 +01:00
dependabot[bot] 803eb21ab1 ⬆️ Bump cssnano from 6.0.0 to 7.0.6 (#3545)
Bumps [cssnano](https://github.com/cssnano/cssnano) from 6.0.0 to 7.0.6.
- [Release notes](https://github.com/cssnano/cssnano/releases)
- [Commits](https://github.com/cssnano/cssnano/compare/cssnano@6.0.0...cssnano@7.0.6)

---
updated-dependencies:
- dependency-name: cssnano
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-03 12:18:12 +01:00
dependabot[bot] dc548667ff ⬆️ Bump peter-evans/create-or-update-comment from 3 to 4 (#3539)
Bumps [peter-evans/create-or-update-comment](https://github.com/peter-evans/create-or-update-comment) from 3 to 4.
- [Release notes](https://github.com/peter-evans/create-or-update-comment/releases)
- [Commits](https://github.com/peter-evans/create-or-update-comment/compare/v3...v4)

---
updated-dependencies:
- dependency-name: peter-evans/create-or-update-comment
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-03 12:14:16 +01:00
dependabot[bot] aa537e4d4a ⬆️ Bump peter-evans/find-comment from 2 to 3 (#3540)
Bumps [peter-evans/find-comment](https://github.com/peter-evans/find-comment) from 2 to 3.
- [Release notes](https://github.com/peter-evans/find-comment/releases)
- [Commits](https://github.com/peter-evans/find-comment/compare/v2...v3)

---
updated-dependencies:
- dependency-name: peter-evans/find-comment
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-03 12:13:40 +01:00
Ken 71408487e0 🐛 Refreshed yarn.lock to stop chromatic from breaking on build 2025-02-03 10:03:23 +01:00
Ken ddd04367af [Darkside]: SoftA-token added for use in Table zebra-stripes 2025-02-01 14:03:32 +01:00
dependabot[bot] 2303d6ce8c ⬆️ Bump the npm_and_yarn group across 4 directories with 11 updates (#3535)
Bumps the npm_and_yarn group with 8 updates in the /examples/astro directory:

| Package | From | To |
| --- | --- | --- |
| [astro](https://github.com/withastro/astro/tree/HEAD/packages/astro) | `4.15.8` | `4.16.18` |
| [braces](https://github.com/micromatch/braces) | `3.0.2` | `3.0.3` |
| [cross-spawn](https://github.com/moxystudio/node-cross-spawn) | `7.0.3` | `7.0.6` |
| [dset](https://github.com/lukeed/dset) | `3.1.3` | `3.1.4` |
| [micromatch](https://github.com/micromatch/micromatch) | `4.0.5` | `4.0.8` |
| [nanoid](https://github.com/ai/nanoid) | `3.3.7` | `3.3.8` |
| [rollup](https://github.com/rollup/rollup) | `4.22.2` | `4.32.1` |
| [tar](https://github.com/isaacs/node-tar) | `6.2.0` | `6.2.1` |

Bumps the npm_and_yarn group with 3 updates in the /examples/next-appdir directory: [cross-spawn](https://github.com/moxystudio/node-cross-spawn), [nanoid](https://github.com/ai/nanoid) and [next](https://github.com/vercel/next.js).
Bumps the npm_and_yarn group with 3 updates in the /examples/referansesider directory: [nanoid](https://github.com/ai/nanoid), [rollup](https://github.com/rollup/rollup) and [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite).
Bumps the npm_and_yarn group with 4 updates in the /examples/shadow-dom directory: [cross-spawn](https://github.com/moxystudio/node-cross-spawn), [nanoid](https://github.com/ai/nanoid), [rollup](https://github.com/rollup/rollup) and [tar](https://github.com/isaacs/node-tar).


Updates `astro` from 4.15.8 to 4.16.18
- [Release notes](https://github.com/withastro/astro/releases)
- [Changelog](https://github.com/withastro/astro/blob/astro@4.16.18/packages/astro/CHANGELOG.md)
- [Commits](https://github.com/withastro/astro/commits/astro@4.16.18/packages/astro)

Updates `braces` from 3.0.2 to 3.0.3
- [Changelog](https://github.com/micromatch/braces/blob/master/CHANGELOG.md)
- [Commits](https://github.com/micromatch/braces/compare/3.0.2...3.0.3)

Updates `cookie` from 0.6.0 to 0.7.2
- [Release notes](https://github.com/jshttp/cookie/releases)
- [Commits](https://github.com/jshttp/cookie/compare/v0.6.0...v0.7.2)

Updates `cross-spawn` from 7.0.3 to 7.0.6
- [Changelog](https://github.com/moxystudio/node-cross-spawn/blob/master/CHANGELOG.md)
- [Commits](https://github.com/moxystudio/node-cross-spawn/compare/v7.0.3...v7.0.6)

Updates `dset` from 3.1.3 to 3.1.4
- [Release notes](https://github.com/lukeed/dset/releases)
- [Commits](https://github.com/lukeed/dset/compare/v3.1.3...v3.1.4)

Updates `micromatch` from 4.0.5 to 4.0.8
- [Release notes](https://github.com/micromatch/micromatch/releases)
- [Changelog](https://github.com/micromatch/micromatch/blob/master/CHANGELOG.md)
- [Commits](https://github.com/micromatch/micromatch/compare/4.0.5...4.0.8)

Updates `nanoid` from 3.3.7 to 3.3.8
- [Release notes](https://github.com/ai/nanoid/releases)
- [Changelog](https://github.com/ai/nanoid/blob/main/CHANGELOG.md)
- [Commits](https://github.com/ai/nanoid/compare/3.3.7...3.3.8)

Updates `rollup` from 4.22.2 to 4.32.1
- [Release notes](https://github.com/rollup/rollup/releases)
- [Changelog](https://github.com/rollup/rollup/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rollup/rollup/compare/v4.22.2...v4.32.1)

Updates `tar` from 6.2.0 to 6.2.1
- [Release notes](https://github.com/isaacs/node-tar/releases)
- [Changelog](https://github.com/isaacs/node-tar/blob/main/CHANGELOG.md)
- [Commits](https://github.com/isaacs/node-tar/compare/v6.2.0...v6.2.1)

Updates `vite` from 5.4.6 to 5.4.14
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v6.0.11/packages/vite)

Updates `cross-spawn` from 7.0.3 to 7.0.6
- [Changelog](https://github.com/moxystudio/node-cross-spawn/blob/master/CHANGELOG.md)
- [Commits](https://github.com/moxystudio/node-cross-spawn/compare/v7.0.3...v7.0.6)

Updates `nanoid` from 3.3.7 to 3.3.8
- [Release notes](https://github.com/ai/nanoid/releases)
- [Changelog](https://github.com/ai/nanoid/blob/main/CHANGELOG.md)
- [Commits](https://github.com/ai/nanoid/compare/3.3.7...3.3.8)

Updates `next` from 15.0.0 to 15.1.2
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/compare/v15.0.0...v15.1.2)

Updates `nanoid` from 3.3.7 to 3.3.8
- [Release notes](https://github.com/ai/nanoid/releases)
- [Changelog](https://github.com/ai/nanoid/blob/main/CHANGELOG.md)
- [Commits](https://github.com/ai/nanoid/compare/3.3.7...3.3.8)

Updates `rollup` from 4.22.4 to 4.32.1
- [Release notes](https://github.com/rollup/rollup/releases)
- [Changelog](https://github.com/rollup/rollup/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rollup/rollup/compare/v4.22.2...v4.32.1)

Updates `vite` from 5.4.14 to 6.0.11
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v6.0.11/packages/vite)

Updates `cross-spawn` from 7.0.3 to 7.0.6
- [Changelog](https://github.com/moxystudio/node-cross-spawn/blob/master/CHANGELOG.md)
- [Commits](https://github.com/moxystudio/node-cross-spawn/compare/v7.0.3...v7.0.6)

Updates `nanoid` from 3.3.7 to 3.3.8
- [Release notes](https://github.com/ai/nanoid/releases)
- [Changelog](https://github.com/ai/nanoid/blob/main/CHANGELOG.md)
- [Commits](https://github.com/ai/nanoid/compare/3.3.7...3.3.8)

Updates `rollup` from 4.22.0 to 4.32.1
- [Release notes](https://github.com/rollup/rollup/releases)
- [Changelog](https://github.com/rollup/rollup/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rollup/rollup/compare/v4.22.2...v4.32.1)

Updates `tar` from 6.2.0 to 6.2.1
- [Release notes](https://github.com/isaacs/node-tar/releases)
- [Changelog](https://github.com/isaacs/node-tar/blob/main/CHANGELOG.md)
- [Commits](https://github.com/isaacs/node-tar/compare/v6.2.0...v6.2.1)

Updates `vite` from 5.4.6 to 5.4.14
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v6.0.11/packages/vite)

---
updated-dependencies:
- dependency-name: astro
  dependency-type: direct:production
  dependency-group: npm_and_yarn
- dependency-name: braces
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: cookie
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: cross-spawn
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: dset
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: micromatch
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: nanoid
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: rollup
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: tar
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: vite
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: cross-spawn
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: nanoid
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: next
  dependency-type: direct:production
  dependency-group: npm_and_yarn
- dependency-name: nanoid
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: rollup
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: vite
  dependency-type: direct:development
  dependency-group: npm_and_yarn
- dependency-name: cross-spawn
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: nanoid
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: rollup
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: tar
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: vite
  dependency-type: direct:development
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-01-31 14:54:23 +01:00
dependabot[bot] 216eae6f1d ⬆️ Bump the npm_and_yarn group with 4 updates (#3534)
Bumps the npm_and_yarn group with 4 updates: [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite), [cross-spawn](https://github.com/moxystudio/node-cross-spawn), [nanoid](https://github.com/ai/nanoid) and [next](https://github.com/vercel/next.js).


Updates `vite` from 5.4.14 to 6.0.9
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/main/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v6.0.9/packages/vite)

Updates `cross-spawn` from 6.0.5 to 6.0.6
- [Changelog](https://github.com/moxystudio/node-cross-spawn/blob/v6.0.6/CHANGELOG.md)
- [Commits](https://github.com/moxystudio/node-cross-spawn/compare/v6.0.5...v6.0.6)

Updates `nanoid` from 3.3.7 to 3.3.8
- [Release notes](https://github.com/ai/nanoid/releases)
- [Changelog](https://github.com/ai/nanoid/blob/main/CHANGELOG.md)
- [Commits](https://github.com/ai/nanoid/compare/3.3.7...3.3.8)

Updates `next` from 14.2.15 to 14.2.23
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/compare/v14.2.15...v14.2.23)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
  dependency-group: npm_and_yarn
- dependency-name: cross-spawn
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: nanoid
  dependency-type: indirect
  dependency-group: npm_and_yarn
- dependency-name: next
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-01-31 14:53:42 +01:00
Ken 0e5c58b28f 🩺 Add dependabot support (#3533) 2025-01-31 14:35:52 +01:00
Julian NymarkandKen 163c1bce04 Accordion: change: do animation similar to ExpansionCard (#3491)
* Accordion: change: do animation similar to ExpansionCard

* changeset

* change: comment expansioncard -> accordion

* don't need changeset for unreleased code

* 🚧 attempt to smooth out expansion of accordion

* working animation

* Update @navikt/core/css/darkside/accordion.darkside.css

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* accordion: remove border-bottom on content, add on item

* Update @navikt/core/css/darkside/accordion.darkside.css

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Accordion: only set box-shadow line for indented items

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2025-01-31 14:03:11 +01:00
Ken 8ee604e6a7 🐛 Remove update to inline-reset 2025-01-31 13:16:25 +01:00
Ken c73db43c96 Fixed Tailwind 4 migration bugs, broken build (#3532)
* 🧪 Added tw-reset to compare chromatic

* 🐛 ExpansionCard button had dynamic padding

* 📝 Added changeset, removed old stories from Tag
2025-01-31 12:58:45 +01:00
Ken 83960d7390 🐛 Use correct global token for darkside JS 2025-01-29 16:23:30 +01:00
Ken 6c81fc0b23 ✨ New icons for sorting (#3528) 2025-01-29 12:45:59 +01:00
Ken a8cbd92e1c [Darkside] Quality assurance P6 (Fileupload) (#3524)
* 📝 Update FileUpload CSS-artifacts

* 🐛 Synced release-text with updated role-colors
2025-01-28 20:38:29 +01:00
Ken 2700f7ac41 [Darkside] Updated focus-outline (#3520)
* 💄 Updated focus-outline

* 🧪 Added legacy-support for deprecated files

* 🐛 Account for legacy files in count
2025-01-28 20:37:23 +01:00
Ken c3ce2c50f8 [Darkside] Quality assurance P5 (border-radius and font-weight) (#3519)
* 💄 Update border-radius based on Figma

* 💄 More border-radius adjustments

* 💄 Bolder medium+ headings
2025-01-28 18:55:16 +01:00
Ken a7db426e04 [Darkside] Quality assurance P4 (#3518)
* 💄 Adjust bg transparency

* 💄 Default border now same scale as roles
2025-01-28 18:54:24 +01:00
Ken 68a2f0249b [Darkside] Updated Focus design for Checkbox, Radio and Switch (#3513)
* 💄 Focus-outline now around item checkbox,radio

* 🐛 Resolved small and indeterminate-state

* 💄 updated focus-markings for switch

* Update @navikt/core/css/darkside/form/radio-checkbox.darkside.css

* 🐛 Hide new indeterminate node from old checkbox
2025-01-28 18:53:48 +01:00
Ken 5f9fdb617b Update LICENSE 2025-01-24 14:37:44 +01:00
github-actions[bot]andgithub-actions[bot] b4f37e80d0 Version Packages (#3509)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-01-23 09:07:21 +01:00
Ken f70bebc03e Update swift-readers-check.md 2025-01-22 14:03:11 +01:00
Ken 7aa85beb01 [Darkside] Quality assurance P1 (#3510)
* 💄 Adjustments 1

* 💄 Bumped default strong scale

* 💄 Bumped secondary neutral border

* 💄 Reduced text-color change on hover

* 🐛 Resolved border and focus logic for combobox

* 🐛 Fix icon sizing for buttons

* 💄 Use tertiary-buttons for datepicker caption

* Update @navikt/core/react/src/chips/Toggle.tsx

* 💄 QA updates combobox darkside (#3511)
2025-01-22 13:58:27 +01:00
Ken d29509dc0a 🐛 Using 'loader' inside 'icon'-prop broke layout caused by position absolute (#3515) 2025-01-22 11:19:29 +01:00
Ken 90f6178c3a ♻️ Fix #3451 scaling for 400% zoom (#3514) 2025-01-22 11:19:21 +01:00
Ken 6678742543 💄 Error borders uses danger-strong consistently (#3512) 2025-01-22 11:19:13 +01:00
715a34ac7d always render the maxSelected message when isMultiSelect (#3506)
* always render the maxSelected message when isMultiSelect

* also check if maxSelected is set

* Changeset

* Update .changeset/swift-readers-check.md

---------

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2025-01-22 09:02:58 +01:00
Ken 85feb0ed8a 📝 Added new sidebar category for /komponenter 2025-01-22 08:53:44 +01:00
dependabot[bot]andKen d2a7c868d5 ⬆️ Bump vite from 5.4.8 to 5.4.12 in /examples/referansesider (#3516)
* ⬆️ Bump vite from 5.4.8 to 5.4.12 in /examples/referansesider

Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 5.4.8 to 5.4.12.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v5.4.12/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.4.12/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>

* Repo-bump vite

* 🔀 Yarn lock

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-01-22 08:48:18 +01:00
Ken edab37a5da 🐛 Third bloggpost was sliced from view on frontpage 2025-01-21 13:13:20 +01:00
KenandHalvor Haugan fad913ce6b [Table] ExpandableRow contentGutter-prop (#3507)
* ✨ New prop contentGutter for ExpandableRow component

* ✨ Added new prop-support in darkside CSS

* 📝 changeset

* Update @navikt/core/react/src/table/ExpandableRow.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2025-01-21 06:00:20 +01:00
Ken 54e03db491 🐛 Added missing 'li'-tag for list-item in blogglist 2025-01-20 10:00:48 +01:00
Ken b52806535d 💄 Incremental layout and list-view update on Produktbloggen 2025-01-20 08:26:19 +01:00
Ken bbca69af9c ♻️ Removed raised-tokens from darkside roles 2025-01-20 07:48:09 +01:00
github-actions[bot]andgithub-actions[bot] 7e6d91efd4 Version Packages (#3505)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-01-17 13:17:19 +01:00
Halvor HauganandKen 54495a4460 Table: Removed border-bottom for HeaderCell used in ExpandableRow (#3503)
* Use HeaderCell for name in expandable table example

* 🐛 Removed border-bottom for HeaderCell used inside ExpandableRow

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
2025-01-17 12:58:10 +01:00
Ken 8b5bfb4b09 Added script to check version-sync between workspace (#3486)
* ✨ Added script for verifying dep-versions across workspace

* ✨ Added script for verifying dep-versions across workspace

* ✨ Added script for verifying dep-versions across workspace

* ✨ Added script for verifying dep-versions across workspace

* ✨ Added script for verifying dep-versions across workspace

* 📝 Better texts

* 📝 Better texts

* 📝 Added comments

* 📝 Updated minoer package-differences

* 📝 Upgraded stylelint

* 📝 Upgraded babel-loader

* 📝 Add ^ to ds-css versionsing across repo

* ♻️ Small refactor to reduce use of forEach
2025-01-17 12:11:54 +01:00
Ken 627d6d9a61 ♻️ Re-structure order and texts for GP section (#3492)
* ♻️ Re-structure order and texts for GP section

* 📝 Avoids extra capitalization for names
2025-01-16 10:14:42 +01:00
Ken f9c2c77559 [Darkside] P 1/3 ♻️ Updated default scale to replace neutral-scale (#3487)
* ✨ Added new space tokens

* 🚚 Updated spacing-definitions

* ✨ Added new space-tokens to old system

* ✨ Added support for new space tokens i primitives

* 🔥 Removed space-tokens from tailwindcss

* 📝 Removed old comments

* [Darkside] Spacing -> Space update for CSS (#3478)

* 🚚 Migrated to new space-token

* 📝 Add docs for temp spacing

* 🐛 Add missing token-prefix to docs

* 🐛 Remove old tests

* 🐛 Added legacy-spacing support for primitives when using new theme-stystem

* ♻️ Move neutral-scale -> default scale

* ♻️ New box now supports updated default tokens

* ♻️ Default -> Soft token

* 📝 Update js-doc

* [Darkside] P 2/3 ♻️ Global/Meta-token naming, bumped role-scale (#3499)

* 💄 Text and border-tokens for roles bumped up

* 📝 Update global and meta-colors to numbers, removed hover color on accordion/button

* [Darkside] P 3/3 ♻️ Old neutral-scale now uses default-scale (#3488)

* ♻️ Use default-tokens for old neutral-scale

* 🐛 Fixed missing token migrations

* ♻️ role default  -> role-soft
2025-01-16 10:14:23 +01:00
KenandLars Eirik Korsgaard Hansen a0ca882ee2 [Actions] ⚡ Optimize workflows (#3480)
* 🚚 Moved auth-token, fetch less history

* ♻️ Use composite actions for workflow

* 🐛 Checkout before running composite workflow

* 🚚 Move composite actions to separate dir

* ♻️ Pass token to composite action

* 📝 Better test names

* ⚡ Optimize chromatic workflow

* ⚰️ Removed old and broken redeploy action

* ⚡ Optimized website-build

* ♻️ Use composite actions for prod and dev build

* ⚡ Reduced e2e tests by 40%

* ⚡ Improved sandbox testing

* ⚡ Update search-tests

* 🐛 Disable invalid example-demos

* 🐛 Wait for search completion

* 📝 removed old env input

* 🐛 Moved vars out to input

* 🐛 Don't ignore inputs for if-tests

* 🐛 Check input for truuthynes

* test: Run sharded playwright

* 🐛 Removed sharded workflow

* ⚡ Update re-use of actions

* 🐛 Keep full git-history for chroamtic

* Update .github/workflows/chromatic.yml

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>

* Update .github/workflows/referansesider-spa-deploy.yml

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>

* Update .github/workflows/ci.yml

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>

* Update .github/workflows/ci.yml

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>

* Update .github/workflows/ci.yml

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>

* Update .github/workflows/ci.yml

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>

* Update .github/workflows/ci.yml

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>

* Update .github/workflows/ci.yml

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>

* 📝 Typo

* 📝 Typoo

* ⚡ Use built-in report for playwright

* 🐛 Use html-reporter, not list

---------

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>
2025-01-15 15:57:02 +01:00
Ken fd6e2b41cb 🐛 Blogg did not sort latest articles by publishDate 2025-01-14 14:08:03 +01:00
Halvor Haugan dd642d77e1 [aksel.nav.no] Make inert-prop in ShowMore work in React 19 (#3497) 2025-01-10 14:55:21 +01:00
Ken ad73a523a9 [Sanity] Updated actions and badges (#3484)
* 📝 Better naming for heading in richtext editor

* ♻️ Better syntax for publish-action

* ♻️ Refactored publication-flow plugin

* 🚚 Moved quality-assurance texts

* ♻️ Better handling of verification flow

* 🐛 Fixed verification without publish action

* 🐛 Check for permissions before assuming publish will work
2025-01-09 15:12:47 +01:00
Lars Eirik Korsgaard Hansen e92eb90d33 🎨 Small refactor of translateTokenStringToCSS function for readability (#3495)
* Small refactor of translateTokenStringToCSS function for readability

* Add missing curly braces
2025-01-09 14:33:10 +01:00
KenandLars Eirik Korsgaard Hansen eec41d6cb8 [Sanity] ✨ Can now add border to image-module in sanity (#3493)
* ✨ Can now add border to image-module in sanity

* Update aksel.nav.no/website/sanity/schema/objects/shared/bilde.tsx

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>

---------

Co-authored-by: Lars Eirik Korsgaard Hansen <71271458+larseirikhansen@users.noreply.github.com>
2025-01-09 14:30:01 +01:00
Ken 8da0af090f [Darkside] Spacing token is now "Space" (#3477)
* ✨ Added new space tokens

* 🚚 Updated spacing-definitions

* ✨ Added new space-tokens to old system

* ✨ Added support for new space tokens i primitives

* 🔥 Removed space-tokens from tailwindcss

* 📝 Removed old comments

* [Darkside] Spacing -> Space update for CSS (#3478)

* 🚚 Migrated to new space-token

* 📝 Add docs for temp spacing

* 🐛 Add missing token-prefix to docs

* 🐛 Remove old tests

* 🐛 Added legacy-spacing support for primitives when using new theme-stystem

* 📝 Updated JSDOC
2025-01-08 09:22:45 +01:00
github-actions[bot]andgithub-actions[bot] 99465ddbeb Version Packages (#3490)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-01-07 12:02:45 +01:00
Ken 25305ebba0 🐛 Use inside Alert got wrong text-color while focused or active (#3489) 2025-01-07 11:50:28 +01:00
Halvor HauganandKen ef3464c96c Support contributions from outside Nav + update some README files (#3483)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2025-01-06 11:36:42 +01:00
Ken 0480d785c4 🔇 Removed amplitude logging (#3485) 2025-01-01 12:56:36 +01:00
Halvor Haugan ef5e671cfe i18n: rename some files, add tests for useDateLocale (#3481) 2024-12-28 17:05:15 +01:00
Halvor HauganandKen fa156773e0 Upgrade vitest and some related packages (#3482)
* vitest

* Upgrade @testing-library

* Fix error building ds-react

* Upgrade "jsdom" in react-workspace (fixes "The `punycode` module is deprecated")

* ♻️ Matched JSDOM-versions across workspace (v25)

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
2024-12-28 17:03:37 +01:00
Halvor HauganandKen 137b4c49c1 Automatically add JSDoc with default values to nb.ts (#3479)
* Automatically add JSDoc with default values to nb.ts

* Added jscodeshift to devDeps

* 🐛 Use same jscodeshift versions

* 🐛 Use same types for jscodeshift

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
2024-12-23 12:03:07 +01:00
Ken 1fb72241fe [Aksel.nav.no] Image comparison module (#3473)
* WIP

* WIP CompareImages

* ✨ Handle more keys

* ♻️ Re-use positioning code

* 💄 Adjust for width

* ✨ Added sanity schema

* 💄 Moved focus to box, allow handle to overflow leftside by 1 px

* ✨ Added bg and alt-text support

* 🐛 Change env back to production
2024-12-23 11:55:52 +01:00
Julian Nymark 42470baaaf ❄️ ⛄ 🎶 🎄 Website: add snowfall (again!) (#3475)
* Website: add snowfall

* website: add egregious christmas ambience

* Revert "website: add egregious christmas ambience"

This reverts commit 3fb858b6ad.

* move dep

* yarn.lock
2024-12-20 15:23:19 +01:00
github-actions[bot]andgithub-actions[bot] 8cd6512181 Version Packages (#3474)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-12-20 14:48:03 +01:00
Halvor Haugan 7e976f9e20 [aksel.nav.no] Add example of ErrorMessage with icon (#3476) 2024-12-20 12:13:30 +01:00
Ken db828bddd3 [Switch] Updated default design to better reflect unchecked state (#3468)
* WIP Switch update

* 💄 Updated Switch to reflect unchecked state better

* 📝 Synced token for switch
2024-12-20 11:27:33 +01:00
443b129fe1 Bugfix/button loading issue in modal (#3252)
* Check loading prop for showing spinner, not widthOverride.

Making this change because widthOverride sometimes gets set to 0 (should also be fixed), meaning this check fails as "falsy".

* Prevent setting width to 0 while showing spinner, to avoid issue in Modals

Checking that width is truthy (not zero) will avoid issue where widthOverride gets set to 0 because the button is not yet rendered.

* Add changeset

* Replace width calculation with just visually hiding label + icon and absolutely positioning the loading icon.

* Update @navikt/core/react/src/button/Button.tsx

* add story for bug case

* We no longer use buttonRef/mergedRef internally, so removed them and set ref directly

* Update @navikt/core/css/button.css

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Hiding everything except loading spinner is more robust than hiding every specific item.

* In loading-state, the button icon will no longer be able to be the only child (hidden), because of the loader icon. Instead checks for no label.

Could consider :not(:has(:is(.navds-button__icon, .navds-loader))) as well, to be more robust, but it might be overkill.

* Much simpler/easier to read

* Don't need to destructure style, only to add it along with rest.

* Should destructure onKeyUp from props, instead of having it added through filteredProps and then overridden afterwards.

* Quick and easy conversion for darkside

* Unnecessary :is after refactoring

---------

Co-authored-by: Julian Nymark <julian.nymark@nav.no>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-12-20 10:44:04 +01:00
Ken 561fecbcac [Darkside] Updated <Theme /> component (#3467)
* 🚚 Rename and move theme-component

* 🐛 Portal now preserves theme when out of cascade

* 🐛 useThemeInternal missing strict-mode false

* 🐛 Removed unused storybook story

* Update @navikt/core/react/src/theme/Theme.tsx

* 📝 remove commented out code
2024-12-20 09:29:22 +01:00
Ken 00177898f5 [Select] 🐛 Focus-border no longer cancels out error-border. (#3465)
* 🐛 Focus-border no longer cancels out error-border.

* ♻️ Optimize CSS selectors, fix textarea

* 📝 Changeset
2024-12-19 17:20:10 +01:00
Ken 38f5e63008 🐛 Removed default tokens added to tailwind, added opacity-token (#3472) 2024-12-19 16:33:42 +01:00
Halvor Haugan c3d65a681e Make Chromatic workflow fail on errors but not on changes (#3471) 2024-12-19 16:05:07 +01:00
Ken 3025e4eb5c [Darkside] ✨ Now adds version-tokens to tokens css (#3466)
* ✨ Now adds version-tokens to tokens css

* ♻️ Remove redundant exist-check
2024-12-19 15:30:49 +01:00
Ken 043277f79b [Darkside] 💄 New ToggleGroup design (#3460)
* 💄 New ToggleGroup design

* 🐛 Removed hover-state from selected togglegroup in forced-colors mode

* 💄 Add px-gap to elements

* 🐛 Hide divider on both sides when selected
2024-12-19 15:16:03 +01:00
Julian NymarkandHalvor Haugan a2b3936878 Textarea: resize immediately upon receiving resize event (#3463)
* change: add story to demonstrate buggy textarea behaviour inside modal

* use lodash debounce with our own default value for wait

* Revert "use lodash debounce with our own default value for wait"

This reverts commit 7638297765.

* change: add leading to debounce + use it in TextareaAutoSize

* changeset

* changeset + co-author

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2024-12-19 14:23:39 +01:00
Julian Nymark c90abe7c23 [Darkside] Warning triangle icon in error messages (#3445)
* change: support icon in ErrorMessage + warning icon for textarea error

* change: ignore icon on old CSS + tweaks

* change: do not nest in old css

* wip commit (works nicely)

* clean up css for errormessage, remove it from form.css

* 🐛 tweaks + use icon in Search

* use icon for the rest of our form components

* backport new css to old form.css

* 🔥 remove unnecessary specification bump

* cleaner example story

* changeset

* ♻️ icon -> showIcon

* make flex & gap opt-in with 'icon'

* change: inline ErrorMessageIcon

* change: nest css more

* revert test changes (utility in multiple variants on one for DOM diffing, but probably no longer useful)

* debloat changeset

* mention form components in changeset

* change: typo in changeset

* change: typo in changeset
2024-12-19 14:17:50 +01:00
github-actions[bot]andgithub-actions[bot] ea19081b71 Version Packages (#3454)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-12-19 11:03:46 +01:00
Ken b9da4fd716 📝 Rename NAV -> Nav (#3470) 2024-12-19 10:08:52 +01:00
Kyrre Havik 858849d743 upkeep: NAVs -> Navs 2024-12-18 15:56:26 +01:00
Ken ae9e6235db [Combobox] Only open dropdown onClick, not onFocus. (#3440)
* ✨ Solves issue where programatic focus to fix error would show dropdown list and hide error

* 🚚 Moved onclick listener for open-state to input, not wrapper

* Update .changeset/forty-rules-ring.md
2024-12-18 15:29:08 +01:00
Julian NymarkandKen f895555ab2 [Darkside] timeline update CSS (#3438)
* change: timeline periods

* update stories for timeline

* change: Timeline pin update

* change: crude variable renaming (--a- -> --ax-)

also likely done with zoom buttons,
a bit of popover styling fix

* change: popover z-index bump

* change: remove unnecessary CSS state :active

* change: z-index fix, correct token usage

* change: remove @supports not selector(:focus-visible)

* change: use proper tokens

* change: can't get focus on popover

* change: remove arrow from popover consumers

* change: only render arrow div when !themeContext

* 💄 Use smaller offset without arrow, use subtleA border for popover

* 💄 Adjusted popover tokens for timeline

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
2024-12-17 15:37:31 +01:00
Ken 372a14b225 [Referansesider]: Updated CSS import breaking workflow 2024-12-17 14:49:29 +01:00
Ken a82126b893 🐛 Fixed Expandable row cursor (#3462) 2024-12-17 14:35:41 +01:00
KenandHalvor Haugan 06193ae300 Inline Alert: <Link>-components used within avoids re-colororing (#3461)
* 💄 Avoid coloring links whe used in Inline Alert

* 📝 Alert changeset

* Update .changeset/eleven-gorillas-scream.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Added link-demo to inline-story

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-12-17 14:35:31 +01:00
Ken b6db2c4ce5 [Darkside] Tag CSS update (#3459)
* ✨ Added darkmode-support to Tag

* 🐛 Update spacing-tokens to new format

* ✨ Added darkmode-support to Tag

* 💄 use canvas-color for text on filled forced color text

* ♻️ Use classNames for tag colors, not data-attrb

* 🐛 Old Tag-css supports new names
2024-12-17 13:18:43 +01:00
Ken d4ee3afb12 [Aksel.nav.no] ✨ Added alpha-category to component-pages 2024-12-17 10:21:31 +01:00
KenandHalvor Haugan 6d6900c08b [Timeline]: Earliest date defaulted to current date when found date was later than current day (#3458)
* 🐛 Timeline startDate defaulted to current Date when later than current day

* 🧪 Added tests

* Update @navikt/core/react/src/timeline/hooks/useTimelineRows.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🔥 Removed old exceptions

* 📝 Changeset

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-12-16 20:40:26 +01:00
Ken 3b43ad51f9 💄 Added outline to OG-image in blog-articles 2024-12-16 16:41:49 +01:00
Ken fe4ad00462 🐛 Incorrect import broke chromatic-build 2024-12-13 18:21:13 +01:00
Ken 2ea0876e50 🐛 CSS-export for /dist did not support /**/-glob 2024-12-13 14:55:34 +01:00
Ken 460c9c3dbd 🐛 Updated ds-css exports to include tokens.json 2024-12-13 14:50:06 +01:00
Ken 88dc43bd50 ♿ CopyButton now tells SR what you are copying (#3455)
* ♿ CopyButton now tells SR what you are copying

* ♻️ Re-use sanitized name for semantic copybutton
2024-12-13 14:37:53 +01:00
KenandHalvor Haugan 2e476ef559 [Darkside] Updated CSS-bundle (#3430)
* V1 of CSS bundler

* V1 of CSS bundler

* ♻️ Added target checking for browser

* ♻️ Remove built in variables added by lightningcss

* Setup bundling of darkside

* 🐛 Fix path resolving in bundle script

* Setup bundling for index

* 🚚 Re-order layering

* ✨ Filter for only components in bundle

* 🚚 Moved token-definition

* 🔥 Removed index.css copy

* ✨ Global build

* ✨ form and primitives build

* ✨ Component build

* ✨ Build versions dir for new setup

* :test_tupe: Added tests for bundle

* 🚚 Move bundle file to config

* 📝 Comments

* ✨ Allow import of darkside directly under ds-css

* 🐛 Use relative import for CSS in storybook

* [Darkside] Updated input-bg in darkmode, added token for opacity (#3441)

* [Darkside]: Update bg-input to be darker in darkmode

* Added opacity-token

* Use token for disabled opacity

* Update @navikt/core/css/darkside/button.darkside.css

* ♻️ De-dupe reading of index.css

* ♻️ Use regex to remove - and space instead of lodash

* 🥅 Throw when bundler fails

* Update @navikt/core/css/config/bundle.darkside.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/css/config/bundle.darkside.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🏷️ Updated opacity-tokens types, resolved import conflict

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-12-13 13:53:37 +01:00
KenandHalvor Haugan f3542d50d4 [Darkside] Tokens package finishing touches (#3435)
* ✨ Updated exports to allow better darkside support

* ✨ Setup less and scss support for darkside

* ✨ Added static build for tokens

* ✨ Token-config exports

* 🐛 Resolved import conflicts between tailwind and css

* 🐛 Resolved import conflicts between tailwind and css

* ♻️ Refactor Token-setup for better typing

* ♻️ WIP resolve import conflicts2

* ♻️ Avoid importing JSON in react from tokens

* 🐛 Resolve updated imports in referansesider after refactor

* Update @navikt/core/tokens/.gitignore

* Update @navikt/core/tokens/types.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 Removed prefix 'ax' when generating static tokens for js

* 🐛 Resolved export syntax to support less, scss and JS

* 📝 Updated JSDoc to link directly to types

* Update @navikt/core/tokens/darkside/figma/figma-config.types.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ Use colorRole-array as bases for Role array

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-12-13 13:37:42 +01:00
Halvor Haugan 1f9a343afc Combobox: Fix issue where you could select more options than defined in maxSelected (#3434) 2024-12-12 12:59:39 +01:00
Ken f026817dd3 [Darkside] Tailwind darkside file export (#3431)
* ✨ Added darkside export to tailwind package

* 🚚 Move darkside build-script to separate script

* 🐛 Avoid using darkside for website yet
2024-12-12 12:24:04 +01:00
Ken 36190f7657 📝 Update Textfield example for readonly after feedback (#3448) 2024-12-11 16:30:22 +01:00
Ken f12070842a [Darkside]: 🐛 Remove 'state'-tokens from new Box-component 2024-12-11 11:42:48 +01:00
Ken 601e1569f8 [Darkside]: Updated gap between text and icon in Link 2024-12-11 09:25:56 +01:00
Ken f7452d5d0d [Darkside]: Added darkmode-support to Tooltip (#3442) 2024-12-11 09:21:54 +01:00
github-actions[bot]andgithub-actions[bot] 04e65c701c Version Packages (#3439)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-12-09 15:42:28 +01:00
Halvor Haugan 878ee68e5c ✨ Release i18n support (#3429)
- Merged LanguageProvider into Provider, while also changing the API a bit to make it easier to use (with the help of TS).
- Updated tests for `useI18n()` according to changes in API.
- Chips.Removable: Removed prop `removeLabel`.
- DatePicker/MonthPicker: Added new `translations` prop and deprecated `locale` prop.
- Search: Deprecated prop `clearButtonLabel`.
- Textarea: Deprecated prop `i18n`.
- Timeline: Deprecated prop `axisLabelTemplates`.
- nb/nn/en.ts:
  - Arranged the top level keys alphabetically.
  - Merged `close` in Modal and DatePicker and put it under the `global` key.
  - Changed Search.clear from "Clear" to "Clear field" to make it more... clear 😅
  - Removed Combobox.clear since the clear button has been removed.
  - Made them importable from `@navikt/ds-react`
2024-12-09 15:38:49 +01:00
Ken ade48469dd [Darkside]: Secondary-button defaults to bg-input 2024-12-09 13:43:12 +01:00
Julian NymarkandKen cbea73abda [Darkside] GuidePanel CSS update (#3403)
* GuidePanel initial CSS rewrite

* ✨ new illustration

* change: layout

* change: add speechbubble arrow

* change: dark mode raised for speechbubble arrow

* change: correct stroke path color (actually fill) of path in svg

* change: fine tuned SVG with padding and overlapping paths

* change: exception CSS for FF rendering of speech bubble tail

* change: hardcode calculation as whole pixel value remove FF custom CSS

* change: convert BEM modifiers to simpler CSS data-attributes

* change: display:none for speech bubble tail on old token system

* change: refactor old css to use the attribute selectors

* change: noSVG example (see default story for side-by-side)

* change: rewrite to using only SVG for speechbubble

* change: only looks good in lightmode, no token support / hardcoded

* :refactor: Updated Guidepanel CSS to use SVG

* 🔥 Remove old commented CSS

* 🐛 Fixed cases where mediaqueries would target nesten element instead of itself

* 🗑️ Cleanup of unused code

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
2024-12-09 12:23:54 +01:00
Ken fd2e65e790 ✨ Stop page-scroll when previewing compoment-examples to reduce noise 2024-12-06 20:44:56 +01:00
Halvor HauganandKen f720562908 Combobox: Removed clear button, deprecated props clearButton/clearButtonLabel, changed maxSelected to number. (#3433)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-12-06 16:33:45 +01:00
KenandHalvor Haugan 5dedfa104a 🐛 Complete CSS-build was included in components.css bundle (#3427)
* 🐛 Complete CSS-build was included in components bundle

* Update .changeset/thick-tools-behave.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-12-06 16:18:04 +01:00
Ken 0189bd7b4a [Darkside] Table CSS update (#3396)
* ✨ Added darkmode support to table

* 📝 Added comments

* 📝 Added todo

* :refactor: Avoid use of custom animate height function

* :refactor: Use Alpha-token on hover-selected

* :refactor: Remove redundant token-use

* Update @navikt/core/css/table.css

* ♻️ Reverted to animate-component for table animation
2024-12-06 15:49:50 +01:00
Halvor Haugan 119d699ff2 Fix Combobox example 'react-hook-form' (#3436) 2024-12-06 15:01:43 +01:00
github-actions[bot]andgithub-actions[bot] fbc580e6bc Version Packages (#3420)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-12-06 14:30:55 +01:00
Halvor Haugan 13a9a2159f Refactor accordion stories (#3432) 2024-12-05 22:01:54 +01:00
Vegard HaugstvedtandHalvor Haugan 89e069d1d6 CopyButton: i18n & remove prop activeTitle (#3426)
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2024-12-05 13:36:33 +01:00
Halvor Haugan 4896bb1569 FormSummary: add translation (#3428) 2024-12-05 13:17:13 +01:00
Ken 713ccafed1 🐛 Accordion now deconstructs sanity-references (#3422) 2024-12-05 10:23:13 +01:00
Ken 4632a3ae2b [Darkside] Updated components based on Figma-comments (#3417)
* 💄 Alert now synced with standardized panel padding

* 💄 Expansioncard synced with standardized panel padding

* 💄 Chat synced with standardized panel padding

* 💄 ErrorSummary synced with standardized panel padding

* 💄 FileUpload synced with standardized panel padding

* 💄 FormSummary synced with standardized panel padding

* 💄 FormSummary synced with standardized panel padding

* 💄 Modal synced with standardized panel padding

* 💄 Popover/Helptext synced with standardized panel padding

* 💄 Text-neutral did not work in darkmode for Button. Now uses text-default
2024-12-04 16:26:21 +01:00
KenandHalvor Haugan f6666302f5 [Darkside] Updated Primitives CSS to use new token-prefix (#3405)
* 📝 Overlap comments

* WIP: update primitives prefixing

* ♻️ Use updated prefix in primitives ts-code

* ♻️ Use updated token-prefix in css

* ♻️ Use updated tokens in primitives css utilities

* 🔥 Removed backwards-compat with old stack CSS

* [Darkside] Primtives prop-support (#3423)

* :refactor: Support primitives with new theme

* :refactor: Use sub-component for new Box update

* ♻️ Update support for new and old theme in Page and Box

* ♻️ Resolve instances where tokens were not correctly named for theme-support

* ♻️ Avoid exposing component before necesarry

* ♻️ Avoid having to import figma-types in ds-react

* ♻️ Using camelCase on tokens breaks primtives. Now uses kebab-case

* 🔥 Removed comment used as notes

* Update @navikt/core/react/src/layout/page/Page.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/layout/box/Box.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ Remove redundant prefix const

* ♻️ remove redundant T-suffix on types

* ♻️ Better previews on hover when checking token-props

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ More fine-grained exception-testing for use of old props in Box

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-12-04 10:35:32 +01:00
Halvor HauganandKen bae136f847 Translate GuidePanel and HelpText, remove text from InternalHeader. (#3424)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-12-04 10:29:26 +01:00
Ken 53d1fe517e [Darkside] Tailwind: Added tests for new config setup 2024-12-03 12:48:59 +01:00
Ken ea0d7c1386 [Darkside] Tailwind: Added shadow-token support 2024-12-03 12:41:35 +01:00
8ea6c220dc [Darkside] datemonthpicker (#3357)
* 🚧 wip

* [Darkside] ErrorSummary updated CSS (#3331)

* First run for errorsummary css update

* Added nesting

* [Darkside] Fileupload CSS update (#3343)

* ✨ Updated Dropzone with darkmode

* ♻️ Added nesting for root

* ♻️ ac -> acx prefix for interla tokens

* ♻️ Removed reduntant token

* ♻️ More nesting

* 💄 Align overlay on drag better

* ⚰️ Removed test-code

* 💄 Update hover-border for dropzone

* 🐛 Removed border-color update on hover in disabled state

* ♻️ Use bg input on area, use border default

* [Darkside] Link CSS update (#3353)

* ✨ Darkmode-support for existing link-component

* :refactor: Adjusted line offsets and thickness

* [Darkside] ExpansionCard CSS update (#3338)

* 💄 Initial css-update expansioncard

* 📝 Added sub-headers

* 💫 Button animation

* ✨ Added data attrb for open-state

* 💫 Updated content animation

* ♻️ Added nesting

* ♻️ Better nesting of rules

* ♻️ Use outline for hover border

* ♻️ Use border as default outline

* 🔥 Remove redundant border css

* 🔥 Removed divider transition, unused state attributes in react

* [aksel.nav.no] Update examples of Page (#3349)

* Changesets: Run yarn as part of create-version

* Combobox: Fix issue where using arrow keys in list would make the entire page scroll (#3364)

* [Darkside] FormSummary updated CSS (#3345)

* :refactor: Use updated CSS for darkside

* 💄 Replace accent bg with info bg

* [Docs] Use NAV-dekorator for Page examples (#3362)

* [aksel.nav.no] Update examples of Page

* comment

* comment + rename + style->class

* fix

* 📝 Use NAV-dekorator for Page-examples

* 🚚 Moved content to separate __parts location

* :refactor: Updated examples

* Update aksel.nav.no/website/components/website-modules/examples/__parts/PageDemoContent.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 Use correct import syntax for parts

* 📝 Add description to page-block default story

* 💄 Removed spacing from all typo-headings in demo

* 🐛 Removed react import from content part

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Git hooks that notify when yarn.lock have changed (#3361)

* 💄 first pass css updates

* 🎨 nest CSS

* Datepicker: 💄 css layer changes & remove extra border

* 🔥 remove resolved todo

* 💄 border radius for caption buttons

* 🎨 drastically simplify focus outline

* change: make button selector less wildcardy

* change: outline smaller for rdp-cell buttons

* change: width large enough to show 4 characters in year caption

* change: match design for range middle selected

* change: remove redundant error CSS

* change: remove unused CSS

* change: un-shuffle css import ordering for date.css

* change: remove unused CSS

* change: week buttons & day button active

* change: use secondary-neutral button for weeknumber buttons

* change: same selector for month and day buttons, active state

* 🐛 Fixed weeknumber as the button broke old datepicker

* change: remove double border on captions, active state on disabled

* ♻️ Updated weeknumber to be barkw-compat with old system

* 🚚 Moved date-import further up

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2024-12-03 12:09:53 +01:00
Ken 9a190d371b [Darkside]: Removed hover-effect from disabled button in forced-color mode 2024-12-03 11:38:45 +01:00
KenandHalvor Haugan 685066e791 [Darkside] Search CSS update (#3385)
* ♻️ Use variables for Button-adjustment

* :refactor: Removed redundant selector nesting for disabled buttons

* :refactor: Use aksel-button for clearbutton

* ✨ Added darkmode support to Search

* :refactor: Updated paddings

* :refactor: Added disabled-support

* :refactor: Updated border of button when input is hovered

* Update @navikt/core/react/src/form/search/Search.tsx

* 🐛 Add correct button CSS from main

* 💄 Placeholder set to text-neutral

* ♻️ Undo nesting

* ♻️ Better error-css structure

* 📝 Added disabled-stories

* 💄 Set opacity on searchicon when disabled

* Update @navikt/core/react/src/form/search/Search.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-12-03 11:24:56 +01:00
Lars Eirik Korsgaard Hansen 41a21d280a fix forced colors toggle group (#3421) 2024-12-02 13:26:34 +01:00
Halvor Haugan 1895f4f763 Combobox: add translations and adjust buttons (#3409)
Hid buttons from screen readers since you can't tab to them anyways. Moved sr-only text on clear button to title attr. Removed sr-only text on toggle list button. Removed prop toggleListButtonLabel.
2024-12-02 12:55:02 +01:00
Halvor Haugan 8bc9a80bd4 Adjust examples of Combobox (#3419) 2024-12-02 10:42:59 +01:00
Lars Eirik Korsgaard Hansen d5a6285110 [Darkside] Togglegroup CSS update (#3400) 2024-12-02 10:38:28 +01:00
Vegard Haugstvedt 856e54aa2d Bugfix/CopyButton: Reduce over announcing active state (#3374)
* Prevent active text being announced waaay too many times.

* Add changeset

* New attempt at consistently reduced status messages on "copy" click

* Remove aria-relevant and aria-atomic to make announcement consistent between Safari and other browsers
2024-11-29 15:43:49 +01:00
github-actions[bot]andgithub-actions[bot] 8951c5c09c Version Packages (#3404)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-11-29 15:11:37 +01:00
fa2904d54b Remove space from combobox single select (#3384)
* When single select on combobox, remove the gap between the input and the selected value.

* ♻️ Updated spacing between options and input in Combobox

* 📝 Changeset

* Revert darkside update

* ♻️ Update darkside combobox

* :refactor: Make gap something we add, not remove for chips based on type

* Update .changeset/yellow-days-rhyme.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* :refactor: Only add margin-left when only-child

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-11-29 15:03:31 +01:00
Halvor Haugan 8c9b2e268a Adjust examples of Loader (#3418) 2024-11-29 13:10:54 +01:00
Ken dce149fca4 🐛 Select get focus-outline when clicked in firefox, as focus-visible were ignored previously (#3415) 2024-11-29 12:49:24 +01:00
Ken 39db249546 [Darkside] Tabs CSS update (#3398)
* 💫 Animate tab-border

* :refactor: Shorthand box-shadow

* 💄 Use 4px border-width for hover and selected state in tabs
2024-11-29 12:47:57 +01:00
KenandHalvor Haugan 9c5b32f9ba [Icons]: Added some new icons (synced from Figma) (#3416)
* ✨ New icons

* Update .changeset/swift-bags-design.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-11-29 11:58:15 +01:00
Ken efc1446fb9 📝 Changeset (#3414) 2024-11-29 11:56:34 +01:00
KenandHalvor Haugan 6d74cb72ad Fileupload: Remove list-styling when used in ul (#3413)
* 📝 Changeset

* Update .changeset/warm-adults-allow.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-11-29 11:36:35 +01:00
Ken d6f08ffaaf [Darkside]: Misc updates to darkside CSS, added shadow-token
- [Darkside]: Use shadow-dialog token in components, use subtle-border in combobox list
- [Darkside]: FileSummary nesten items border
- [Darkside]: Adjusted ExpansionCard padding
- [Darkside]: ActionMenu uses new Radio-design
- [Darkside]: Added shadow-token to system
2024-11-27 20:00:53 +01:00
Halvor Haugan 1f4ac7bfde DatePicker/MonthPicker: add support for translations provider (#3390) 2024-11-27 12:29:56 +01:00
Halvor Haugan 34538a1cbe Modal: Don't add scroll shadow when polyfilled (#3408) 2024-11-26 16:51:32 +01:00
KenandHalvor Haugan 9f088a9373 🐛 Modal now handles cases where it was opened with show() (#3407)
* 🐛 Modal now handles cases where it was opened with `show()`

* Update .changeset/sweet-birds-care.md

* 🐛 Add bottom unset to polyfilled modal

* Update @navikt/core/css/modal.css

* Update .changeset/sweet-birds-care.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-11-26 16:19:58 +01:00
Ken 547219923f [Darkside] Fileitem icon centering 2024-11-26 13:03:52 +01:00
Ken 05709ca43e [Darkside] Switch CSS update (#3389)
* :refactor: Initial darkmode-update to switch

* :refactor: Darkmode-support switch

* 📝 Added comments

* :refactor: Added nesting to readonly

* :refactor: Updated design to match figma
2024-11-26 11:47:25 +01:00
Ken 8fdb888270 [Darkside] Select CSS update (#3378)
* ✨ Added darkmode support to Select

* 🐛 Removed highlighted border-color on hover/focus state
2024-11-26 11:25:00 +01:00
Ken 87b2e54465 [Darkside] Textarea CSS update (#3399)
* :refactor: Added darkmode-support to textarea

* 💄 add some spacing between textarea and counter
2024-11-25 20:42:08 +01:00
Ken 1270c88d19 [Darkside] Stepper: Adjusted border and text-colors to sync with figma 2024-11-25 13:33:00 +01:00
Ken a368cd35b6 [Darkside] Stepper CSS update (#3388)
* :refactor: Added darkmode-support to Stepper

* :refactor: Restructure Stepper to support darkmode and nesting

* 🐛 text-decoration now changes on hover

* :refactor: Line before non-interactive step now has border-neutral
2024-11-25 13:27:20 +01:00
Ken b752d848e1 [Darkside] Skeleton CSS update (#3381)
* ✨ Added darkmode support to skeleton

* 🐛 use correct border-radius
2024-11-25 12:54:41 +01:00
Ken ac4b6f1713 [Darkside]: Update Textfield to show error-border on hover 2024-11-25 12:50:01 +01:00
Ken e15c62ddfd [Darkside] Use variables for Button (#3377)
* ♻️ Use variables for Button-adjustment

* :refactor: Removed redundant selector nesting for disabled buttons
2024-11-25 12:45:41 +01:00
KenandHalvor Haugan 641276bb44 [Darkside] ReadMore CSS update (#3372)
* ✨ Added brandvolume support in theme-component

* 📝 Added brandvolume story to readmore

* ✨ Added large size to readmore

* ✨ Added darkmode support for Readmore

* :refactor: Updated CSS syntax

* 🐛 Fixed brandvolume stories

* ✨ Implemented brandvolume in ReadMore

* ✨ Added large-variant of readmore to OG readmore

* :refactor: Use tokens and calc to handle volume

* 🐛 Added text-accent-strong on hover to high brandvolume

* 🐛 Avoid adjusting readmore body when size is large

* 📝 CHangeset

* Update @navikt/core/react/src/provider/theme/AkselTheme.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/provider/theme/AkselTheme.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-11-25 12:27:22 +01:00
Ken 0f983440ee ✨ Added logo-token (#3373) 2024-11-25 11:06:31 +01:00
Halvor Haugan fc62ae6870 Remove Storybook HTML addon (#3401) 2024-11-22 14:23:19 +01:00
Halvor Haugan 293fadeaeb Add test for placeholders in translations (#3387) 2024-11-22 12:34:24 +01:00
Ken eb3f830995 [Darkside] Refactor layering concept (#3395)
* :refactor: Update layer handling

* 📝 Improved comments
2024-11-22 12:32:41 +01:00
Halvor Haugan e257bf4945 [Darkside] Combobox: add scroll-margin (#3397) 2024-11-22 09:36:39 +01:00
Ken c8fd958e7a [Darkside] Internalheader CSS update (#3352)
* ✨ Added darkmode support in react for internalheader

* :refactor: Support darkmode theming for internalheader

* 💄 Added bottom border to header, divider now subtleA

* 🐛 Remove hover,active effect in static title

* :refactor: Remove redundant :is for button

* :refactor: use padding shorthand

* 💄 Improved hover-effect on forced-color buttons, added story

* 🐛 Revert back to is button syntax
2024-11-21 17:34:31 +01:00
Julian Nymark 0da07be3b7 Darkside combobox fixes (#3393)
* 💄 remove unused CSS

* 💄 remove sticky (and more) causing weird behaviour
2024-11-21 15:58:11 +01:00
github-actions[bot]andgithub-actions[bot] c054a607b8 Version Packages (#3392)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-11-21 13:34:46 +01:00
Halvor HauganandKen 15b000e162 Adjust examples of Popover (#3394)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-11-21 13:23:27 +01:00
Halvor Haugan 11133d1a8d Allow RC versions of React 19 through peerDependencies (#3391) 2024-11-21 11:29:59 +01:00
Julian Nymark 39d83bfc50 Combobox: update CSS to use new tokens (#3328)
* 🚧 wip

* 🚧 wip

* Combobox: darkside (keep old border radius for now)

* Combobox: 💄 replace error border with outline (on wrapper is probably fine), use tokens

* Combobox: 💄 replace transparents (almost never wanted), use tokens

* Combobox: 💄 only outline on --focus

* Combobox: 💄 outline adjustment, remove scroll guttering

* Combobox: 💄 prettify (nesting group) CSS

* Combobox: 💄 tweak "legg til" margin/padding

* Combobox: 💄 several small review changes

* Combobox: 💄 move border to wrapper-inner, use correct token for focus color

* Combobox: fix error & some outline on virtually-unfocused

* Combobox: 💄 smaller box-shadow on error

* Combobox: 💄 forced-colors

* Combobox: 💄 forced-colors++

* Combobox: 💄 several PR review fixes (border)

* Combobox: 💄 group review fixes

* Combobox: 💄 remove !important

* 💄 PR review changes

* 💄 PR review changes

* 💄 PR review changes

* 💄 color > stroke

* 💄 PR review changes

* 💄 new design for error outline

* 💄 PR group review batch fixes
2024-11-21 10:32:17 +01:00
dependabot[bot] 8ed0872b05 Bump cross-spawn from 7.0.3 to 7.0.6 in /examples/referansesider (#3386)
Bumps [cross-spawn](https://github.com/moxystudio/node-cross-spawn) from 7.0.3 to 7.0.6.
- [Changelog](https://github.com/moxystudio/node-cross-spawn/blob/master/CHANGELOG.md)
- [Commits](https://github.com/moxystudio/node-cross-spawn/compare/v7.0.3...v7.0.6)

---
updated-dependencies:
- dependency-name: cross-spawn
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-11-20 16:07:54 +01:00
github-actions[bot]andgithub-actions[bot] 7cc33d880a Version Packages (#3366)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-11-20 09:51:46 +01:00
KenandJulian Nymark 2c8dd2bc8a [Darkside] List CSS update (#3354)
* :refactor: Updated List css to support darkmode

* ♻️ nest some CSS

* 🐛 Updated stories

* 🐛 Removed removed story from chromatic view

* :refactor: Removed color-override on list-markers

* :refactor: Set icon-color to currentColor

* :refactor: Removed currentColor from icon

---------

Co-authored-by: Julian Nymark <julian.nymark@nav.no>
2024-11-19 16:30:28 +01:00
Ken 3ac02e3d87 [Darkside] Popover CSS update (#3369)
* ⚰️ Remove popover arrow in new design

* 🎉 Added darkmode support to popover

* 🎉 Progressbar darkmode support

* Revert "🎉 Progressbar darkmode support"

This reverts commit 77330a6fbd.

* 🔥 Remove focus-outline on Popover
2024-11-19 15:26:03 +01:00
Ken e15edd61ea [Darkside] Loader CSS update (#3355)
* :refactor: Initial loader update

* :refactor: Re-added support for inverted

* :refactor: Added nesting to loader

* 🐛 Foreground now scales the same as background track
2024-11-19 15:14:44 +01:00
Ken f38ab0bb45 [Darkside] TextField CSS update (#3376)
* ✨ Added darkmode support for Textfield

* 💄 Focus visible causes border-color to update

* :refactor: Added nesting
2024-11-19 15:08:06 +01:00
Ken c7409c073b 🎉 Progressbar darkmode support (#3370) 2024-11-19 15:07:58 +01:00
Ken 33b4e373b6 🎉 Updated modal css (#3368) 2024-11-19 15:07:41 +01:00
Ken 7d53efeeb7 🐛 Removed psuedo-state plugin (#3379) 2024-11-19 11:11:55 +01:00
Ken 452e8d8f27 [Darkside]: Errorsummary now has default bg and list-markers are text default 2024-11-18 18:14:07 +01:00
Ken 57356ea067 [Darkside] Pagination CSS update (#3367)
* :refactor: Added darkmode support for modal

* 💫 Reduced animation travel-distance

* 💄 Add border subtleA to modal

* 💄 Adjusted button to figma design

* 🎉 Added darkmode support to pagination

* 💥 reverted modal css changes

* 🐛 Flex-inline broke baseline when using icon inside button
2024-11-15 15:40:55 +01:00
Ken 41ae4a4b9f ✨ Added darkmode support for Helptext (#3375) 2024-11-15 13:13:04 +01:00
Ken 576b2e93a3 💫 Updated expansioncard animation (#3363) 2024-11-15 12:22:02 +01:00
Ken f7db3b7740 [Darkside] FormProgress CSS update (#3344)
* :refactor: Re-implemented animation

* :refactor: Re-add transition for old FormProgress

* 💄 Focused button now overlays panel

* 🔥 Removed redundant hover-state for icon rotation
2024-11-15 11:36:50 +01:00
Halvor Haugan 5f6996a64c Update codeowners file (#3365)
merging now, cuz I get a lot of spam and it's overwhelming 😅
2024-11-14 16:15:28 +01:00
Sjur 7e7e97c430 Update global-dark.ts (#3371)
Tester litt bedre kontrast på tekst i darkmode
2024-11-14 16:05:18 +01:00
Halvor Haugan 1ca5328d0e Git hooks that notify when yarn.lock have changed (#3361) 2024-11-14 11:42:08 +01:00
20fde22390 [Docs] Use NAV-dekorator for Page examples (#3362)
* [aksel.nav.no] Update examples of Page

* comment

* comment + rename + style->class

* fix

* 📝 Use NAV-dekorator for Page-examples

* 🚚 Moved content to separate __parts location

* :refactor: Updated examples

* Update aksel.nav.no/website/components/website-modules/examples/__parts/PageDemoContent.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 Use correct import syntax for parts

* 📝 Add description to page-block default story

* 💄 Removed spacing from all typo-headings in demo

* 🐛 Removed react import from content part

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-11-14 11:32:05 +01:00
Ken f400485fdd [Darkside] FormSummary updated CSS (#3345)
* :refactor: Use updated CSS for darkside

* 💄 Replace accent bg with info bg
2024-11-14 11:30:20 +01:00
Halvor Haugan 9c93342892 Combobox: Fix issue where using arrow keys in list would make the entire page scroll (#3364) 2024-11-14 11:28:29 +01:00
Halvor Haugan 6707674d88 Changesets: Run yarn as part of create-version 2024-11-13 13:18:15 +01:00
Halvor Haugan 0be3a081df [aksel.nav.no] Update examples of Page (#3349) 2024-11-13 12:50:26 +01:00
Ken 6483d6ba68 [Darkside] ExpansionCard CSS update (#3338)
* 💄 Initial css-update expansioncard

* 📝 Added sub-headers

* 💫 Button animation

* ✨ Added data attrb for open-state

* 💫 Updated content animation

* ♻️ Added nesting

* ♻️ Better nesting of rules

* ♻️ Use outline for hover border

* ♻️ Use border as default outline

* 🔥 Remove redundant border css

* 🔥 Removed divider transition, unused state attributes in react
2024-11-13 12:40:16 +01:00
Ken c5f46e60ad [Darkside] Link CSS update (#3353)
* ✨ Darkmode-support for existing link-component

* :refactor: Adjusted line offsets and thickness
2024-11-13 08:50:37 +01:00
Ken 204017eb96 [Darkside] Fileupload CSS update (#3343)
* ✨ Updated Dropzone with darkmode

* ♻️ Added nesting for root

* ♻️ ac -> acx prefix for interla tokens

* ♻️ Removed reduntant token

* ♻️ More nesting

* 💄 Align overlay on drag better

* ⚰️ Removed test-code

* 💄 Update hover-border for dropzone

* 🐛 Removed border-color update on hover in disabled state

* ♻️ Use bg input on area, use border default
2024-11-12 14:37:05 +01:00
Ken 37289b110c [Darkside] ErrorSummary updated CSS (#3331)
* First run for errorsummary css update

* Added nesting
2024-11-12 14:27:40 +01:00
Ken 539108a1f7 [Darkside] Checkbox and Radio updated CSS (#3329)
* Updated checkbox css

* bug: Added correct icon-color for readonly checkbox

* Form-css: Updated form.css and fieldset.css with new tokens

* Added radio dot support

* use 4px border-radius, use border-strong for error

* Error-state updated for checked checkbox

* Updated 'dot'-color for readonly radio

* Updated radio-design

* Added disabled-stories for checkbox and radio

* Radio story with checked and error

* Updated foced-colors support for radio

* Use border-syntax instead of box-shadow

* Removed old code

* Updated checked color to accent-strong-pressed for radio

* Adjusted Error-colors for radio/checkbox

* 💄 Radio can now be checked and have Error

* ♻️ Use hoverA bg for hover

* ♻️ Readio readonly now matches figma
2024-11-12 13:58:37 +01:00
Halvor Haugan 5da987f26a [aksel.nav.no] Fix example iframe resize in Firefox (#3351) 2024-11-12 12:24:42 +01:00
Halvor Haugan a85517e9e0 Timeline: add translations (#3341) 2024-11-12 12:13:01 +01:00
Ken bfc3061a70 [Darkside] Use moderate-hoverA bg for copybutton on hover 2024-11-11 15:51:01 +01:00
Halvor Haugan 85131a54c2 Storybook: Add language to toolbar (#3342) 2024-11-11 10:00:32 +01:00
Ken 339ba372ac [Chromatic] More fine-graines externals-filter to filter out darkside-updates 2024-11-08 14:19:39 +01:00
github-actions[bot]andgithub-actions[bot] 20d5ad597a Version Packages (#3340)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-11-08 12:14:52 +01:00
Ken aa7c2d9598 Chore: Fix npm/github version mismatch 2024-11-08 12:12:35 +01:00
github-actions[bot]andgithub-actions[bot] 4921dcfe7b Version Packages (#3336)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-11-08 11:54:36 +01:00
Niklas Backman 23f4d4b4a6 Update SuggestionBlock.tsx (#3339)
Typo. Fjernet et ekstra "ta"
2024-11-08 11:28:25 +01:00
Ken 47a4dd6c4c [Icons] Added FileJpeg and FilePng. (#3332)
* Updated icons

* ⚰️ Removed medicalthermometer icon

* Revert "⚰️ Removed medicalthermometer icon"

This reverts commit fcf7f1e124.
2024-11-08 10:52:51 +01:00
Ken 702aecf34b [Datepicker] DateWrapper now uses state instead of ref (#3333)
* bug: DateWrapper now uses state instead of ref to update after first render

* changeset update

* Added comments based on change
2024-11-08 09:38:26 +01:00
Ken c449c380fa Update README.md (#3337) 2024-11-07 12:43:36 +01:00
Ken 5f81e617c8 Use NB translation for e-mail (#3335) 2024-11-07 10:56:34 +01:00
Ken 7cefa52b81 Bumped allowed react-versions (#3334) 2024-11-07 10:12:59 +01:00
Halvor Haugan 97fbd9de64 Remove creation of empty .env files in workflows (#3294) 2024-11-07 09:40:22 +01:00
Ken 1fdb7c84c3 [Darkside] Accordion CSS-rewrite (#3296)
* [Darkside] Migrated typo to new CSS

* memo: Added comments

* change: Implemented accordion header and content

* change: Added lines

* feat: added todo

* change: Fixed layering issues with lines

* change: Avoid animation on initial render

* change: Removed comments

* change: moved icon state into nesting

* change: Added alpha-background for icon, updated fontweight

* change: Added forced-colors support

* Removed use op --open class

* Removed old grid centering

* Top, bottom line is now alpha

* Fixed animation

* bug: Revert to transparent bg

* deprecation: Added tags to accordion props that are to be removed

* removed deprecation for accordion headingSize prop

* Updated implementation of line in accordion

* Remove position relative in accordion content

* Implemented size-update for accordion

* bug: removed old comment

* Clarify comments

* Removed redundant header class

* Re-added className in accordionHeader
2024-11-06 18:52:49 +01:00
Ken ca0d5b4246 [Darkside] Copybutton CSS update (#3330)
* Use new tokens in copybutton

* Updated animation

* updated to nested syntax

* Updated text-color on hover

* Added subheading for sectioning

* removed background none
2024-11-06 18:52:01 +01:00
Halvor Haugan 9622b61a3d 🔧 Set cssVariables extension to only include tokens (#3327) 2024-11-06 16:18:01 +01:00
Ken 0fe767652d [CI] Testing chromatic ignore for darkside changes 2024-11-06 13:41:39 +01:00
Ken 256ab2a166 [Sanity] Updated custom publish actions (#3315)
* sanity config cleanup

* removed extra const for type

* re-organized admin tools and fixed types

* Removed no longer needed custom actions for translations

* Simplified publication plugin

* Removed extra logic in publish action

* synced SEO-updates

* lock sync

* bug: Removed old index export
2024-11-06 13:13:13 +01:00
Ken 4118a27c18 [Sanity] Collapsed multiple Util-locations, updated API-version, added types (#3313)
* sanity config cleanup

* removed extra const for type

* re-organized admin tools and fixed types

* synced SEO-updates

* lock sync
2024-11-06 13:10:53 +01:00
KenandHalvor Haugan 2d669a7513 [Sanity] Config cleanup (#3312)
* sanity config cleanup

* removed extra const for type

* Update aksel.nav.no/website/sanity/schema/documents/presets/seo.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-11-06 10:42:13 +01:00
Julian Nymark 923fce1961 🐛 fix wrong syntax for codeowners 2024-11-05 14:56:42 +01:00
Julian Nymark 16739a2cf6 ✨ CODEOWNERS (#3323)
* :sparkels: CODEOWNERS

* 📝 update codeowners
2024-11-05 14:39:05 +01:00
Ken 3227e0db91 [Darkside] Chat CSS update (#3305)
* Chat css-rewrite

* changed initials for chat story

* Update nested syntax
2024-11-05 14:35:49 +01:00
Ken ccb090448d [Bug]: Storybook preview used wrong prop for Theme context 2024-11-05 11:10:54 +01:00
KenandHalvor Haugan 36b0d8a8fd [Darkside] Actionmenu CSS update (#3304)
* change: Actionmenu css rewrite

* change: Synced with figma-design

* Added focus-state to subtrigger

* Updated animations

* acx -> axc

* Let items keep their original color when disabled

* Update @navikt/core/react/src/overlays/action-menu/ActionMenu.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-11-05 10:30:39 +01:00
Ken 056e29af52 [Chromatic] Ignores darkside css updates (#3325)
* Ignores darkside css updates

* better glob
2024-11-05 10:26:36 +01:00
Ken 4a2e47fe6a Chips CSS-reset (#3316) 2024-11-05 10:08:18 +01:00
KenandHalvor Haugan 1eace15576 [Darkside] Theme component as feature-flagging (#3318)
* Setup theme-component

* Added styling for global theming

* Update @navikt/core/react/src/provider/theme/AkselTheme.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* appearance -> theme

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-11-05 10:04:38 +01:00
Halvor HauganandKen ef44f2a25b [aksel.nav.no] Adjust exaples of Box and Bleed (#3321)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-11-05 09:08:13 +01:00
Sjur 916b383e7b Update global-dark.ts (#3320)
Endret fargene 100 - 400 for Info og BrandThree
2024-11-04 15:29:52 +01:00
github-actions[bot]andgithub-actions[bot] bc8761295b Version Packages (#3314)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-11-04 10:22:20 +01:00
Halvor Haugan 6d9f9001fe Table.ColumnHeader: Inherit text alignment in button (#3319) 2024-11-01 16:07:39 +01:00
KenandJulian Nymark 039332b4f8 [Darkside] Updated Alert CSS (#3301)
* change: Alert variants

* feat: Updated alert css

* change: use correct spacing

* Update @navikt/core/css/darkside/alert.darkside.css

Co-authored-by: Julian Nymark <julian.nymark@nav.no>

---------

Co-authored-by: Julian Nymark <julian.nymark@nav.no>
2024-11-01 16:05:32 +01:00
Halvor Haugan 8cadfd0979 Pagination: More precise type for renderItem (#3275) 2024-11-01 08:49:08 +01:00
Halvor Haugan c200f580c1 Translations for ReadOnlyIcon (#3311) 2024-10-31 16:28:48 +01:00
Halvor Haugan 5ce8ec620c Include number of failed stories in Chromatic comment (#3308) 2024-10-31 15:21:23 +01:00
github-actions[bot]andgithub-actions[bot] f7789522c6 Version Packages (#3307)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-10-31 12:27:02 +01:00
Julian Nymark a9a1182eff Website: 🐛 code example chip to same on first page (#3310)
* 🐛 fix bug still appearing on first page load

* Website: ♻️
2024-10-31 11:50:32 +01:00
Ken 35f7355233 bug: Checks if autocomplete should actually be used when pressing enter (#3306) 2024-10-31 09:56:16 +01:00
Julian NymarkandHalvor Haugan bbc06a3eab ErrorSummary: add translation support (#3245)
* ErrorSummary: add translation support

* Update @navikt/core/react/src/form/error-summary/ErrorSummary.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/util/i18n/locales/nn.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ErrorSummary: fix broken object notation (thanks github conflict webGUI! 😂)

* ErrorSummary: use proper casing for translations object

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-10-30 16:07:47 +01:00
Halvor Haugan 6e49de805f Textarea: translations (#3302) 2024-10-30 15:31:37 +01:00
github-actions[bot]andgithub-actions[bot] 9757d7d829 Version Packages (#3283)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-10-30 15:28:46 +01:00
Halvor Haugan d7fb6b5718 [aksel.nav.no] Fix bug when clicking on active code example chip (#3303) 2024-10-30 15:26:28 +01:00
Ken 3c53127e5e bug: Combobox now handles autocomplete correctly with new values (#3287) 2024-10-30 14:50:58 +01:00
Julian Nymark 561dd2e3c0 Introside: 📝 update confirmation text (#3300)
* Introside: 📝 update confirmation text

* Introside: 📝 update confirmation text (+ meta.json)
2024-10-30 13:47:41 +01:00
Julian Nymark 1e9983c65b Button: ✨ new tokens (darkside.css) (#3237)
* Button: ✨ new tokens (darkside.css)

* Button: 🚚 copy over the primitives CSS

* Button: temporary missing placeholder tokens (shadow)

* Button: use new tokens

* Button: remove temporary duplicate code, remove box-shadow focus

* Button: 🎨 use new token prefix

* Button: 🐛 erroneous token conversion from old

* Button: 🐛 erroneous precedence of some CSS rules

* Button: 🎨 do not use CSS nesting (...yet!)

* Button: 🎨 use alpha tokens for hover on secondary and tertiary

* Button: 🎨

* Button: 🚨 ignore outdated stylelint rule

* Button: 🎨 use bg token for storybook preview darkmode

* Button: 🔥 🎨 remove unused CSS, better scope for var def

* Button: 💄 use correct tokens, prettier css rules

* Button: 💄 remove unused CSS
2024-10-30 12:56:04 +01:00
Halvor Haugan 76937a0a2b Combobox: 🐛 Fix scroll issue when using arrow keys in list (#3299) 2024-10-30 12:20:56 +01:00
Halvor Haugan 1ac9ec2f56 Remove some excludes in axe.e2e.ts (#3291) 2024-10-30 10:06:31 +01:00
Halvor Haugan e88d328e8b Add darkside tokens to stylelint rule value-no-unknown-custom-properties (#3297) 2024-10-30 10:05:16 +01:00
Ken 1e2b1d885f [Darkside] Updated Typo CSS (#3295)
* [Darkside] Migrated typo to new CSS

* memo: Added comments
2024-10-30 10:03:09 +01:00
Halvor Haugan 4cdeeacaef Add "Decision Records" to PR template (#3289) 2024-10-29 15:39:07 +01:00
Halvor Haugan c2365712ca [Translations] Table: i18n support (#3281) 2024-10-29 13:28:36 +01:00
Ken 0afbef50a9 [Darkside] Allow old spacing tokens in darkside to avoid editing react-code in production 2024-10-29 13:17:39 +01:00
Halvor Haugan 7799416096 Search: i18n + remove role (#3280) 2024-10-29 12:48:28 +01:00
Halvor HauganandKen 92b39de213 [Translations] ProgressBar: i18n support (#3277)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-10-29 12:35:10 +01:00
Halvor Haugan 9dade96849 [Translations] Modal: i18n support (#3273) 2024-10-29 12:25:08 +01:00
Halvor Haugan 5c23ca62b6 [Translations] Pagination: i18n support (#3276) 2024-10-29 12:16:53 +01:00
Halvor Haugan d562ef0d87 [aksel.nav.no] Adjust examples of HGrid, Show and Hide (#3288) 2024-10-29 12:06:56 +01:00
Ken 13c9fef93a [Darkside] Moved old CSS over to new Darkside dir (#3284)
* change: Copy over old CSS into darkside dir

* change: Update imports for darkside css

* bug: Updated togglegroup css naming
2024-10-29 11:36:14 +01:00
Magnus TønnessenandKen b5c7defffb Add month input format MMyyyy (#3285)
* change: Add allowed month input format MMyyyy

* Update .changeset/strong-apes-hope.md

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-10-29 10:33:59 +01:00
Halvor Haugan e4eccd7616 [aksel.nav.no] Add language block (#3267) 2024-10-28 19:34:48 +01:00
Halvor Haugan 5295abb1bf [Translations] Loader: i18n support (#3272) 2024-10-28 11:42:13 +01:00
Halvor Haugan 3bfd5d2299 Tabs.List: Remove redundant icon titles (#3282) 2024-10-28 10:24:58 +01:00
Halvor Haugan a63ba59636 [Translations] ExpansionCard: i18n support (#3271) 2024-10-25 15:18:47 +02:00
Julian Nymark 81c79d8355 Combo filteredoptions offset fix (#3269)
* Combobox: 🐛 only apply the offset when it's needed

* Combobox: changeset
2024-10-25 14:52:16 +02:00
github-actions[bot]andgithub-actions[bot] f27698a2bf Version Packages (#3270)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-10-24 09:15:01 +02:00
Halvor Haugan fdc3244cde Better support for React 19 (#3268)
* Date/MonthPicker: Upgrade react-day-picker to fix issue with Nextjs 15
* Slot: Use ref from props to avoid warning in React 19
2024-10-24 09:07:26 +02:00
Vegard Haugstvedt 59dc3e999b Feature/combobox show add new value while autocompleting (#3225)
* Show AddNewValue button in Combobox based on searchTerm instead of value, so it is displayed when autocompleting words

* Highlight matching text in FilteredOptions

* Add changeset

* Move styling to combobox.css instead of inline JS

* Ensure label options are read as one text, even when highlighting search matches.

This only seemed to be a problem in testing library, so we should be able to remove this if they fix this in their calculation of accessible name.

* Update changeset to a minor version

* Re-introduce controlled value in storybook examples to not change Chromatic snapshots
2024-10-23 15:42:26 +02:00
Halvor Haugan 9711de90da Checkbox: Remove redundant attribute aria-checked (#3274) 2024-10-23 13:48:46 +02:00
Halvor Haugan ddf9f9bc5a Combobox: Don't scroll when moving virtual focus with mouse (#3265) 2024-10-23 09:44:11 +02:00
Ken d83a6feb36 [Darkside] Tailwind CSS config for new tokens (#3251)
* change: Updated actionmenu examples

* change: Removed flipAlignment prop for better alignment

* change: Removed defaultOpen-prop from ActionMenu

* change: Moved rootElement prop to component root

* change: Added support for use inside Modal

* change: Use MenuPortalProps instead of Pick

* feat: Added build for darkside

* feat: Implemented darkside-tokens in tailwind-build

* change: Code cleanup and syntax simplification

* change: Moved color-token extraction to start of file

* memo: Moved comment
2024-10-21 17:04:06 +02:00
Ken f505386104 [Aksel.nav.no] Add support for markdown-links in intro-texts (#3262)
* change: added markdown-support for intro-texts

* change: Added description for sanity-fields
2024-10-21 16:56:03 +02:00
github-actions[bot]andgithub-actions[bot] 9f56b84a96 Version Packages (#3259)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-10-21 15:28:43 +02:00
Halvor Haugan b91ce5794d Combobox: 🐛 Remove virtual focus on input blur instead of moving it (#3261) 2024-10-21 15:10:31 +02:00
Ken 99eaf41e47 change: Hide private props better (#3260) 2024-10-21 14:37:55 +02:00
Halvor HauganandKen 536b0fcc5e Combobox: Clearify in JSDoc what clearButton does (#3258)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-10-21 09:58:10 +02:00
KenandHalvor Haugan 64aab7361a Stylelint v16 update (#3250)
* update: Stylelint v15

* update: Stylelint v16

* updated: Use complex list syntax for not-selector

* lint updates

* More lint fixes

* memo: Changeset

* bug: Missing shorthand for spacer

* Update .changeset/slimy-yaks-smash.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* change: re-added directional placement for modal polyfill

* change: Inset -> direction

* update: lock sync

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-10-21 09:54:09 +02:00
Ken 8c15433b95 change: Update token-prefix to 'ax' (#3257) 2024-10-21 09:53:49 +02:00
Halvor Haugan 8137a1e500 Fix useState in Storybook (#3256) 2024-10-21 09:06:29 +02:00
Ken 7138b52c2d [Linting] Eslint v9 dependency upgrades (#3248)
* update: eslint-plugin-react-hooks v5 update

* update: Valid React-component names used for useDescendants

* update: Bumped eslint packages to support v9

* change: Rename hooknames

* update: lock sync
2024-10-18 15:54:12 +02:00
Ken 1730b2ebc1 [Scripts] Updated clean-script (#3249)
* change: Updated clean-script

* change: Removed logging and extra filtration
2024-10-18 15:53:01 +02:00
github-actions[bot]andgithub-actions[bot] 6324d63745 Version Packages (#3226)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-10-18 14:20:08 +02:00
Halvor Haugan debfb3fd15 [Translations] Chips.Removable: Remove translations-prop (partly reverts #3232) (#3255) 2024-10-18 14:15:23 +02:00
Ken a3e8457baf change: Reduced height for actionemu examples (#3246) 2024-10-18 12:45:36 +02:00
Halvor Haugan 0560f84acd ➖ Remove faker (#3254) 2024-10-18 12:20:35 +02:00
Halvor Haugan 663dfbe8a4 🆙 Upgrade some dependencies (#3247) 2024-10-18 12:02:05 +02:00
Halvor Haugan 536f088b97 List.Item: Center icon horizontally inside it's container (#3253) 2024-10-18 11:55:46 +02:00
Ken f659599787 [ActionMenu] Removed defaultOpen-prop, moved rootElement, added Modal-support (#3240)
* change: Updated actionmenu examples

* change: Removed flipAlignment prop for better alignment

* change: Removed defaultOpen-prop from ActionMenu

* change: Moved rootElement prop to component root

* change: Added support for use inside Modal

* change: Use MenuPortalProps instead of Pick

* change: Revert to using Pick for prop inheritance

* change: Menucontext uses required definition of rootElement
2024-10-17 16:19:27 +02:00
Ken ed34bc034a [Darkside]: Move text-contrast tokens into semantic groups 2024-10-17 14:26:20 +02:00
Ken 2a2028fd95 [BasePrimitive] Hide className from basePrimitive type (#3241)
* change: Hide className from basePrimitive type

* change: Re-order baseprimitive types (#3242)
2024-10-17 13:04:50 +02:00
Ken 386145d63a [Darkside] Made breakpoints and font-tokens avaliable in css output
[Darkside] Added breakpoints to token-config
[Darkside] Added font to token-config
2024-10-17 11:51:54 +02:00
Ken 1ed809c872 [Actionmenu] Updated examples for docs, removed flipAlignment-prop (#3236)
* change: Updated actionmenu examples

* change: Removed flipAlignment prop for better alignment
2024-10-17 09:49:56 +02:00
Ken e2359ddf33 [Darkside] Bumped role-raised tokens on darkmode one tick on the scale, updated darkmode input token 2024-10-16 19:45:15 +02:00
Ken 069e3346ec [darkside] Added spacing and border-radius token support for JS/TS file-format 2024-10-16 14:34:06 +02:00
Halvor Haugan c941af9de5 Refactor examples of Vstack and HStack (#3244) 2024-10-16 14:15:08 +02:00
Halvor Haugan a273a22172 Adjust examples of VStack and HStack (#3243) 2024-10-16 13:31:09 +02:00
Ken 0e94031f1e [Darkside] Added alpha-variant to border-subtle 2024-10-16 13:01:10 +02:00
Ken 64a9762286 change: Updated exports to make docgen work (#3235) 2024-10-16 09:29:39 +02:00
Ken a05dbadfa4 [darkside]: Added support for darkside views in chromatic (#3239) 2024-10-15 16:55:05 +02:00
Halvor Haugan 7c468b18d1 Adjust dates in Date/MonthPicker examples (#3238) 2024-10-15 16:35:45 +02:00
Ken cfcd78a450 [sanity] Grunnleggende now has access to props block 2024-10-15 15:40:45 +02:00
Halvor Haugan 9e677697a7 [aksel.nav.no] Fix copy-pasting snippets in Firefox 2024-10-15 12:15:24 +02:00
Halvor Haugan 8a8bf0a274 [aksel.nav.no] Adjust list of outdated articles (#3234) 2024-10-15 10:28:03 +02:00
Halvor Haugan 1e40d96510 Chips.Removable: Added new i18n API (#3232) 2024-10-15 09:55:30 +02:00
Ken db56141b2e [Darkside] Updated CSS-readme with syntax hints 2024-10-15 09:43:14 +02:00
Ken ec351ba27f [Darkside] Added CSS-resets, utilities, fonts ++ to darkside css
[Darkside] Removed unused 'baseline' css
[Referansesider] Updated css-import to layer 'framework'
2024-10-14 22:32:39 +02:00
Ken 2e98a09540 [Linting] Update @typescript-eslint/eslint-plugin to v8 (#3222)
* linting: update ts eslint package to v8

* linting: Update ts eslint package to v8

* change: removed redundant off-toggle of native eslint rules

* change: update interface declaration
2024-10-14 16:43:46 +02:00
Halvor Haugan 2d438e1d37 [Translations] Alert: i18n support (#3231) 2024-10-14 16:42:41 +02:00
Ken 8b373e8b80 bug: Use relative units instead of tokens for storybook markdown 2024-10-14 16:21:32 +02:00
KenandHalvor Haugan 179eb51221 [Darkside] Added development environment for new CSS (#3233)
* change: Added stoybook decorators for darkside toggle

* feat: Added dynamic CSS-loading based on mode

* memo: Added readme for new CSS

* change: Added basic body styles for darkside, including fonts

* change: Added loading of new CSS to referansesider

* bug: Removed old preview file in storybook

* change: Added utf-8 to darkside css

* change: Updated darkside css readme with new instructions

* change: Removed old bg style on wrapper

* Update .storybook/preview.jsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* change: Refactored theme decorator

* Update .storybook/preview.jsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* bug: Re-added return

* change: themedecorator -> modedecorator

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-10-14 16:12:03 +02:00
Halvor Haugan d98624618c [Translations] Accordion: Remove redundant icon title (#3230) 2024-10-14 15:36:20 +02:00
Julian Nymark ecc501a0a8 Referansesider: dagoversikten tweaks to table, remove Timeline 2024-10-14 11:49:51 +02:00
Ken fec3b12d5f [Darkside] Added alpha-scale for global and moderate
[darkside] Updated naming transform to support alpha-tokens
[darkside] Updated input-token to use opacity
[darkside] Added alpha-tokens to global config
[darkside] Now auto-generates the alpha-values
[darkside] Added semantic role tokens using alpha-values
bug: removed tempfile added by vitest
2024-10-14 11:36:23 +02:00
KenandHalvor Haugan 8f99d3a102 [Icons] Some icons that should be ignored were fetched and caused exceptions (#3228)
* bug: Some icons that should be ignored were fetched and caused exceptions

* change: Added some comments

* change: Better math for icon-check

* change: Better messaging

* Update @navikt/aksel-icons/config/figma/index.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-10-14 10:19:21 +02:00
Julian Nymark 7fa7719c24 Referansesider: dagoversikten tweaks to MiniTag 2024-10-11 16:41:22 +02:00
Julian Nymark bc1b9fdad9 Referansesider: dagoversikten table placeholder 2024-10-11 16:34:15 +02:00
Julian Nymark 755d75903a Referansesider: dagoversikten correct tokens for borders 2024-10-11 16:13:57 +02:00
Julian Nymark 5ebc71470a Referansesider: dagoversikten completed rightside 2024-10-11 16:03:17 +02:00
Halvor Haugan 17daddab86 Add description to GuidePanel examples (#3224) 2024-10-11 14:14:34 +02:00
20ced9b084 ActionMenu component (#3081)
* 🎨 Setup content

* 🎨 Fungerende popover med story

* 🎨 useDescendant-API kan bruke uten context-error på nesting

* 🐛 Fikset tilfeller der oppdatering av descendant-options ikke ble reflektert i descendants-map

* 🐛 Satte enabled til optional

* bug: import av Portal brakk stories for Popover og Floating

* bug: DescenadantContext er nå riktig typet som undefined

* label: scopet navn for bruk av descendant-provider i dismissablelayer

* memo: Bedre kommentarer

* feat: Sender ikke callbacks hvis layer er disabled

* memo: Formatering og kommentarer

* memo: Kommentarer

* copy: Kopiert over basekomponent

* refactor: Oppdatert imports

* refactor: Oppdatert Primitive bruk

* feat: Støtter forwardRef

* fire: Fjernet Radix import

* feat: Bruker Floating og ikke PopperPrimitive

* type: Bedre typet composeEventHandler

* refactor: Fjernet scopedProps

* feat: Custom RowingFocus

* wip feat: Replaced rowingfocus

* wip feat: Implemented initial focus for rowingfocus

* wip feat: Removed old collection api

* refactor: Use internal Slot component

* refactor: Fixed all scoped context-use

* feat: Fullført migrering til internt API

* test: Setup stories

* bug: Content is added to descendants

* bug: Found issue for nesten descendants

* copy: Kopiert over refactor for useDescendant

* bug: Fikset descendants nesting

* feat: Fikset keyboard nav med nested descendants

* bug: Removed early return

* memo: Kommentarer

* label: Typer

* refactor: Fjernet Root export

* refactor: Fjernet typeahead

* test: Setup story for entryfocus

* refactor: Forenklet FocusScope

* refactor: bedre dokumentert utils

* refactor: Moved utils to separate file

* refactor: Moved slotted-div to separate file

* refactor: Moved MenuContext out to context-file

* 🚚 Moved focus-files

* refactor: Update syntax

* refactor: Moved MenuAnchor to file

* refactor: Moved MenuGroup to file

* refactor: Moved Separator to file

* refactor: Moved Label to file

* refactor: Moved utility-components

* refactor: Flyttet item til mappe

* refactor: Flyttet checkbox

* refactor: Content in separate file

* refactor: Radio i separate filer

* refactor: SubComponents in files

* refactor: Bedre typer

* refactor: Re-written back to single file

* refactor: Fjernet gamle commits

* bug: Fikset import feil og feil extension av type

* refactor: data-attrb fra radix -> aksel

* refactor: Fjernet console.logs

* bug: Fixed import and test-type error

* refactor: Remove unwanted exports

* feat: Re-added ItemIndicator wrapper

* refactor: Updated exports

* refactor: removed focusguards

* refactor: FocusScope now assumes Slot

* refactor: Removed extra tabIndex

* feat: Implemented ItemIndicator and styling for testing

* refactor: Rowing -> Roving

* refactor: Moved Menu-component into overlays-dir

* bug: Fixed import of Slot

* bug: Re-add tabIndex to MenuItem for correct focus-handling

* memo: Rename Tab -> menu

* refactor: removed unwanted exports in story

* Update @navikt/core/react/src/overlays/floating-menu/Menu.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* bug: Added missing meta import

* bug: Aligned dash with checkmark

* bug: Circle icon now shows for radio-demo

* bug: keyframes has extra ':', breaking animations

* bug: Re-added ItemIndicator for all TickIcon

* bug: WithLabel story now shows complete dropdown

* feat: Added disabled-styling to submenu

* refactor: Now uses ownerdocument where needed instead of document

* adjustments after review 1

* adjustments after review 2

* refactor: Updated to correct function type syntax

* refactor: renamed floating content propname

* refactor: Consistent destructuring of props

* refactor: rename FocusScope props

* memo: Added explanation for why we use flushEvent

* refactor: added consistent use of composeEventHandlers

* refactor: Force userSelect none style

* demo: Allow canceling opening if pointerdown is released outside of menu

* memo: Better line-dividers

* refactor: removed data-highlighted logic

* Update @navikt/core/react/src/overlays/floating-menu/Menu.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/overlays/floating-menu/Menu.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* feat: DropdowmMenu boilerplate

* feat: MenuTrigger & MenuPortal

* feat: MenuContent

* feat: MenuGroup

* feat: lvl-1 components added

* feat: Implement each component

* feat: Implement export

* refactor: Fixeed proptypes for sub

* feat: Implemented trigger

* testing: Updated stories

* feat: Added experimental API 'requireReactelement'

* feat: Implemented content

* feat: Implemented label

* feat: Implemented Item

* feat: Implemented Item

* feat: Implemented group

* feat: Implemented radoigroup

* feat: Implemented radio

* feat: Implemented checkbox

* feat: Implemented sub-trigger

* feat: Implemented sub-content

* feat: Implemented separator classname

* feat: Added cancelable event for pointerdown

* feat: Added dropdown-menu css

* WIP: CSS

* WIP: Added label styling

* feat: Remove checkmarks whe unchecked

* feat: Allow use of 'il' in floating-element

* feat: Implemented semantic tags for items and content

* feat: Added test-markup

* Revert "feat: Implemented semantic tags for items and content"

This reverts commit 6bf473328d.

* Revert "feat: Allow use of 'il' in floating-element"

This reverts commit 5307facbca.

* css: Item active styling

* testing: Setup storybook test framework

* testing: setup basic feature stories

* testing: Un-nested variants

* testing: advanced demos

* feat: Disabled and submenu css

* feat: Added bg on open submenu-trigger

* feat: Added destructive item

* feat: Stop selecting checkbox from closing dropdown

* feat: Use actual radio and checkbox svg for components

* feat: Animate checkbox/radio checked

* feat: Added indeterminate checkbox

* feat: Added indeterminate demo

* feat: added story for shortcuts

* TODOS

* feat: added possibility to close submenus with arrowright when opened to the left of content

* refactor: Better implementation of Shortcuts and aria-keyboardshortcut

* feat: added thin scrollbar

* feat: Added animationsupport for all directions when opening dropdown

* refactor: Cleaned up CSS

* testing: Added chromatic stories for dropdown

* refactor: Dropdowm CSS -> Actionmenu CSS

* refactor: Rename files

* refactor: Move file to utils

* refactor: Inline Slot button

* refactor: rename react dropdown -> action

* refactor: Solved alignment issue with checkbox/radio and text

* feat: use div instead of removed Menu.Label

* refactor: Better useRef reference

* memo: Updated comments

* memo: removed old comments

* memo: Prop-comments

* memo: JSDOC

* bug: remove shortcut from exports

* refactor: Avoid exposing extra props for content

* refactor: Avoid exposing extra props for subcontent

* refactor: Updated CSS animation name

* feat: Updated exports making ActionMenu avaliable from the library

* memo: Added actionmenu to CSS-mappings

* feat: Added option to use links in actionmenu

* feat: Icon-prop for Item and Subtrigger

* refactor: Separator -> Divider

* feat: Updated danger variant item text color

* feat: Stronger label typings for group

* bug: Fixed edgecase where focus on trigger would close menu

* bug: removed storybook addon omit

* refactor: Used relative units and tokens for spacing/width

* feat: Added max-width, removed nowrap

* bug: removed demo story

* refactor: Removed old scale(1) property from animation

* Update @navikt/core/css/action-menu.css

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* feat: Added direct import of actionmenu

* Update @navikt/core/react/src/overlays/action-menu/ActionMenu.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/overlays/action-menu/ActionMenu.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Minor adjustments

* Remove unused CSS

* feat: De-select all checkboxes when every box is allready checked in indeterminate

* memo: Removed extra stories

* memo: Removed demo used for testing

* feat: More dynamic max-width with 'min'

* memo: Removed cryptic comments

* feat: Avoid spread in reduce

* refactor: Removed middle-step function to handle radio state update

* refactor: Better css-naming for marker css

* refactor: removed extra unused variables, added double underscore prefix

* refactor: Removed extra onSelect on disabled story

* feat: Actionmenu now proplery handles overflow

* feat: Avoid auto-closing modal

* feat: Menu is now Modal

* feat: Now always focuses trigger when closed

* Update @navikt/core/css/action-menu.css

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* feat: Fix space auto closing modal

* feat: Fallback to bottom of anchor when no avaliable space

* memo: Added todo

* ,memo: added todos

* memo: changeset

* refactor: Simplified SVG with groups

* [ActionMenu] Remove extra CSS-classes, fixed centering bug in safari (#3194)

* refactor: Remove extra CSS-classes, fixed center bug in safari

* refactor: Removed unused CSS

* [ActionMenu] Sub-menu now uses onClick for opening and closing instead of pointermove (#3193)

* feat: ActionMenu now only opens submeny onClick

* memo: removed TODO

* feat: Closes all adjacent submenues when opening a new one

* refactor: Undo unwrapping of onDismiss

* refactor: Remove unused code in Menu.tsx

* feat: Handle submenu keys correctly

* feat: use native onClick for Trigger

* refactor: Remove un-needed disabled check on trigger

* bug: Reuse already used context

* Update @navikt/core/react/src/overlays/floating-menu/Menu.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* bug: Rename open prop

* Memo: update comment

* feat: Use looser types for RovingFocus

* bug: Aboid auto-closing menu when opening with pointer

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/modal/ModalHeader.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/css/action-menu.css

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update .changeset/dry-flowers-dance.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 💄 Manually set zIndex value

* ActionMenu documentation (#3085)

* memo: ActionMenu documentation

* refactor: Update to use Icons

* bug: Fixed use of Item with nextjs link-component

* memo: Updated examples

* memo: Updated examples, removed div-wrapper

* TODOS

* memo: Oppdatert submenu med table-vising

* feat: Oppdatert eksempler

* memo: Default open first submenu in demo

* memo: Use norwegian in link docs

* Update aksel.nav.no/website/pages/eksempler/actionmenu/shortcuts.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* memo: Shortcut easter egg

* ⚡ Simplify indeterminate toggle for actionmenu

* refactor: remove redundant aria-label

* Update aksel.nav.no/website/pages/eksempler/actionmenu/sub-menu.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/pages/eksempler/actionmenu/links.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* memo: removed reference to nextjs app-router

* bug: Removed empty aria-label

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* [ActionMenu] Fixes overlapping elements for SubMenus (#3212)

* bug: Fixed scroll + wrapping issue

* bug: undo scrollbar gutter change

* change: Updated chromatic to not overlap

* change: Updated yarn.lock

* change: submenu changes floating position more flexibly than main content now

* change: Chromatic clips unused margins, so moved submenu higher in view

* change: Updated chromatic-story to better show submenu

* memo: changeset for modal head update

* Update .changeset/proud-rings-float.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2024-10-11 14:13:55 +02:00
Julian Nymark 6d2115cdc9 Referansesider: dagoversikten structure + completed leftside 2024-10-11 13:57:20 +02:00
Halvor Haugan 17ae19c5fe Add translations for NN and EN (#3209) 2024-10-11 12:01:11 +02:00
KenandHalvor Haugan a60298f232 [Icons] Refactored Figma fetch to TS (#3218)
* ♻️ Refactored Icon fetching from figma

* bug: Fixed types for YML-handling

* update: Lock update

* Update @navikt/aksel-icons/config/figma/index.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/aksel-icons/config/figma/index.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/aksel-icons/config/figma/make-configs.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* refactor: pages -> parts

* refactor: Better naming

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-10-11 09:10:31 +02:00
github-actions[bot]andgithub-actions[bot] 5866992e7d Version Packages (#3208)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-10-10 15:56:34 +02:00
KenandHalvor Haugan 8ab241a980 [Linting] Comment-cleanup in eslint (#3220)
* memo: Cleanup comments

* memo: Updated eslintRc

* bug: Removed ts from global eslint

* Update .eslintrc.js

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* memo: Updated temp comment

* Update .eslintrc.js

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-10-10 15:48:47 +02:00
KenandHalvor Haugan 363d76b9b2 [Linting] Fixed noUselessTernary and useOptionalChain-rules (#3215)
* memo: Added figma-plugin as ignore

* memo: Removed unused noSelfAssigned

* refactor: Fixed useJsxKeyInIterable

* memo: Removed unused noInnerDeclarations

* memo: Removed unused noUselessTernary

* refactor: Fixed useOptionalChan rule biome

* Update @navikt/aksel-icons/__tests__/validate-svg.test.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* feat: Better null-check

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-10-10 15:06:49 +02:00
Ken 5da970fd62 [Linting] Fixed useLiteralKeys rule from biome (#3219)
* memo: Added figma-plugin as ignore

* memo: Removed unused noSelfAssigned

* refactor: Fixed useJsxKeyInIterable

* memo: Removed unused noInnerDeclarations

* refactor: Fixed useLiteralKeys rule

* bug: Fixed typings for sanity publication action

* bug: Fixed typings for sanity publication action

* bug: Fixed typings for sanity publication action

* bug: added null-check
2024-10-10 14:47:11 +02:00
Ken 296e43cab2 [Linting] Fixed useJsxKeyInIterable ,noSelfAssign and noInnerDeclarations rules from biome (#3214)
* memo: Added figma-plugin as ignore

* memo: Removed unused noSelfAssigned

* refactor: Fixed useJsxKeyInIterable

* memo: Removed unused noInnerDeclarations
2024-10-10 14:33:26 +02:00
Ken 85fec974dc Added autoprefixer to @navikt/ds-css devDependencies (#3213)
* bug: added autoprefixer to ds-css devDeps

* ⬆️ Yarn lock
2024-10-10 13:29:56 +02:00
Vegard HaugstvedtandKen 6ddea4eaf2 Feature/combobox pageup and pagedown (#3158)
* Add support for PageUp and PageDown in Combobox.FilteredOptions

* Remove console.log statements

* Add test for PageDown/PageUp

* Open FilteredOptions when pressing PageDown

* Prevent scrolling from moving the whole page

* Consistently scroll to the active element in useVirtualFocus by using useLayoutEffect

It seems like doing it with the state update sometimes encounters a race condition preventing the scrolling.
This removes the need for a private function handling index update and scrolling, simplifying the code.

* Updated test to fit new options order

* Prevent "Home" and "End" in Combobox from scrolling as well

* Add changeset

* Update @navikt/core/react/src/form/combobox/FilteredOptions/useVirtualFocus.ts

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* useEffect seems to work the same way, and works better for SSR

* Removed code that did nothing

* Added the same check we have for PageDown, etc. Unsure if it is neccessary.

* Change behaviour for "Home" to move focus to the first element instead of Input

* Once we changed virtualFocus.moveFocusToTop to move focus to first element instead of the Input, we now need another function to move it to the Input where applicable.

* Update .changeset/tasty-cats-hear.md

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-10-10 12:05:13 +02:00
Halvor Haugan acea9ebb78 Change "personnummer" to "fødselsnummer" (#3211) 2024-10-10 11:59:28 +02:00
Julian Nymark fdbd634012 Referansesider: dagoversikten BreadCrumbs 2024-10-09 12:37:13 +02:00
Julian Nymark dcf5452d28 Referansesider: dagoversikten content 2024-10-08 16:34:15 +02:00
Sjur 0a8c33bbbe Justerte Danger-farger i LightMode (#3210)
Noen av HEX-verdiene i Danger LightMode er endret.
2024-10-08 15:26:07 +02:00
Vegard Haugstvedt 18b0cf5fa5 Bugfix/combobox disable autocomplete in firefox on android (#3201)
* Disable autocomplete in Combobox to "fix" issue where autocomplete is broken in Firefox on Android

The bug is that after three "correct" characters are entered in a row, the autocomplete inserts the third character incorrectly, messing up the text in the input.
This also happens in other implementations of autocomple, like W3C's ARIA Authoring Practices Guide combobox with inline autocomple.

* Add changeset

* Use type checking instead of useEffect to prevent client code from running server side
2024-10-08 12:37:07 +02:00
Julian Nymark 374a679bc3 Referansesider: ✨ dagoversikten.tsx 2024-10-08 11:53:09 +02:00
github-actions[bot]andgithub-actions[bot] a2e020d4f3 Version Packages (#3206)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-10-08 11:50:48 +02:00
Halvor Haugan 074c8da536 List: ✨ New size 'large' (#3207) 2024-10-08 11:30:47 +02:00
KenandHalvor Haugan bdbd6c24cc [Dependencies] Replaced ts-node with tsx, removed dotenv (#3198)
* refactor: ds-react uses tsx instead of ts-node

* refactor: ds-tailwind uses tsx

* refactor: Website backup and search uses tsx

* refactor: Test urls and rss-feed uses tsx

* refactor: Prop-updates uses tsx

* refactor: All website scripts uses tsx

* refactor: removed dotenv dependency from website

* feat: removed all dependencies to dotenv

* bug: Remove need for env in validate build script

* test: Create empty env file

* test: Scope env-file to build-dir

* bug: Fallback to empty env when no env exsists

* feat: Better error-messaging when fetching new icons

* Update @navikt/aksel-icons/package.json

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-10-08 10:18:51 +02:00
Ken f0e6c944d8 [Referansesider] Updated contrast tokens to new naming 2024-10-08 10:16:17 +02:00
Ken 22be148832 [Darkside] Moved contrast-tokens to text group
feat: Moved contrast tokens to 'text' collection
feat: Added support for adding custom scopes for each token
2024-10-08 10:06:43 +02:00
KenandHalvor Haugan aac12fe44f [Linting] Fixed useExhaustiveDependencies in biome (#3197)
* feat: Update biome

* feat: migrate biome config

* misc: Ignore semantic-tag rule biome

* refactor: resolved breaking changes after biome update

* feat: remove old excluded biome rule

* feat: Removed a11y/useFocusableInteractive ignore

* refactor: Fix useExhaustiveDependencies  biome

* memo: changeset

* memo: changeset gitmoji

* bug: Re-add selectedOptions to dependency array

* Update @navikt/core/react/src/overlays/dismissablelayer/DismissableLayer.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* bug: Fix initial focus for sidebar icon

* ⚡ remove reduntant memoization of isLimitReached

* bug: re-add sanity-plugin-iframe-pane

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-10-08 09:05:59 +02:00
Halvor Haugan 324358d086 FileUpload: 💥 Remove UNSAFE-prefix (#3205) 2024-10-07 15:16:25 +02:00
Ken 946cbeb016 [Liniting] Updated to biome v1.9 (#3196)
* feat: Update biome

* feat: migrate biome config

* misc: Ignore semantic-tag rule biome

* refactor: resolved breaking changes after biome update

* feat: remove old excluded biome rule

* feat: Removed a11y/useFocusableInteractive ignore

* refactor: Remove ariaRole rule

* bug: Remove extra fragments in dartepicker stories

* bug: Remove custom image rendering exception for safari on website
2024-10-05 15:41:23 +02:00
Sjur f4d22dae68 Endret Neutral-farger Darth Mode (#3204)
Neutral-fargene ble hentet fra fargene med lavere saturation, som gjorde at de mistet hintet av blått. Endret til den originale skalaen.
2024-10-04 22:09:27 +02:00
Ken ce2f5a9b90 [Darkside] Fixed missing test updates 2024-10-04 16:01:58 +02:00
github-actions[bot]andgithub-actions[bot] cf167064eb Version Packages (#3203)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-10-04 15:25:08 +02:00
Ken 73a6ae1bf1 [Darkside] Fixed no_cache_paths for figma config CDN 2024-10-04 15:24:06 +02:00
Halvor Haugan 95c84e1d01 List: Explicitly set list-style on ol to override reset-CSS (#3202) 2024-10-04 15:14:16 +02:00
Ken 4675857e8f [Darkside] Updated global colors config
feat: Avoid caching config for color-tokens
feat: Remove use of leonardo, hardcode global config
feat: Update 100-400 scale for darkmode
feat: Update 500-1000 scale for global colors
2024-10-04 15:06:32 +02:00
Julian Nymark 2a6e416b5c Referansesider: 🐛 use master branch for GA 2024-10-04 12:50:43 +02:00
Julian Nymark d3c3cafc97 Referansesider: 👷 point to maintained spa-deploy yml (#3199)
* Referansesider: 👷 point to maintained spa-deploy yml

new location: https://github.com/nais/deploy/tree/master/actions/spa-deploy

* Referansesider: 🐛 probably correct yml url (GH action)
2024-10-04 11:47:33 +02:00
KenandHalvor Haugan 678fa6692b [Darkside] Figma plugin for updating variables (#3191)
* feat: Implemented figma plugin

* feat: Can now detect production/development build

* feat: Now supports remote fetch for config

* misc: Stop reset from running by default

* feat:Semantic value handling

* feat: Pre-semantic implementation

* feat: Finished plugin API for semantic variables

* feat: Use this for Figma plugin extension

* bug: Fixed semantic collection naming

* bug: Handle reset correctly

* misc: avoid resetting when updating

* memo: Added comments

* bug: Ignore plugin buildfile from lint

* bug: Fix support for dynamic-page load in figma

* 📝 Better naming, simplified code-def syntax

* feat: Scoped ignorePattern for plugin.js

* memo: better logs for completing update

* Update @navikt/core/tokens/darkside/figma/plugin/AkselVariablesInterface.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/tokens/darkside/figma/plugin/AkselVariablesInterface.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* memo: Removed extra space for info logging

* refactor: Simplify for-loop for semantic color modes

* refactor: Inline creation of mode, collection and variable

* refactor: readable mapping variables

* feat: Better error-handling if variable is null

* refactor: Remove redundant getModes function

* refactor: Remove redundant getModes function

* refactor: Remove plugin watch function

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-10-04 11:19:43 +02:00
Ken 87aeb94c64 [Dependencies] Sanity 3.59 update (#3195)
* feat: Updated to sanity 3.59

* bug: Sanity updated icon and media types, so everything broke

* bug: Fallback to default media in article previews if everything is normal
2024-10-03 16:35:00 +02:00
github-actions[bot]andgithub-actions[bot] 4714a5ff32 Version Packages (#3181)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-10-03 16:01:01 +02:00
Halvor HauganandKen ca1d9be88f List: Add indentation and remove aria attributes (#3184)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-10-03 15:06:06 +02:00
Halvor Haugan 2654da8b64 update-article-views: Use latest docker image + remove reduntant stuff in workflow (#3189) 2024-10-03 08:52:48 +02:00
Julian Nymark 8d6418a594 Referansesider: 💄 use correct tokens 2024-10-02 14:24:10 +02:00
Julian Nymark 8269091fb8 Referansesider: 💄 outline offset for focus 2024-10-02 14:15:06 +02:00
Julian Nymark fd82184057 Referansesider: 🎨 aktivitetsplan buttons & select 2024-10-02 14:11:31 +02:00
Julian Nymark 39f2cb8614 Referansesider: 🎨 aktivitetsplan main card 2024-10-02 13:57:07 +02:00
Julian Nymark 4bf298f363 Referansesider: 🎨 Tag to own component, flesh out cards for aktivitetsplan 2024-10-02 12:55:54 +02:00
Halvor HauganandKen 3a239e4e17 [aksel.nav.no] Show breakpoints in GuidePanel examples (#3192)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-10-02 12:23:10 +02:00
Halvor Haugan 4fcfaf3deb [aksel.nav.no] Storybook: Change to Vite framework (#3185) 2024-10-02 10:14:17 +02:00
Julian Nymark 5dbc66daaa Referansesider: 🚧 Aktivitetsplan 2024-10-02 09:53:17 +02:00
Halvor Haugan 555a46b5da Adjust examples of Switch (#3188) 2024-10-01 13:55:03 +02:00
Julian Nymark 73b2bca156 Combobox: 💄 tweak the visibility of chevron (#3187)
* Combobox: 💄 tweak the visibility of chevron

* Combobox: 💄 dim visibility of icons for readonly datepicker, select, and combobox

* Combobox: 💄 dim visibility of icons for readonly datepicker, select, and combobox

* changeset
2024-10-01 13:47:53 +02:00
Julian Nymark 01411dc11f referansesider: 💄 sykepenger++ 2024-10-01 12:02:38 +02:00
Julian Nymark b1b0d23863 Referansesider: 💄 use more tokens 2024-09-30 14:56:17 +02:00
Julian Nymark cf59ce81bf Combobox disabled fixes (#3183)
* Combobox: 💄 remove hover border color when disabled

* Combobox: 💄 remove hover effect on chips when disabled
2024-09-30 13:53:48 +02:00
Julian Nymark 00c0ff31e1 Combobox: 💄 remove hover border color when disabled (#3182) 2024-09-30 13:38:22 +02:00
Julian Nymark d278060e59 Combobox: 🐛 implement Readonly + disabled (#3180)
* 🐛 [Combobox] implement disabled

* 💄 [Combobox] disabled

* ✨ [Combobox] implement readOnly

* 📝 [Combobox] add examples

* 📝 [Combobox] changeset

* 📝 [Combobox] changeset++

* 📝 [Combobox] stories (review fixes)

* 📝 [Combobox] stories (review fixes++)

* Combobox: 🎨 remove ToggleListButton when readonly or disabled

* Combobox: ♿ combobox input does not support native readonly, use nativeReadOnly={false}

* Revert "Combobox: 🎨 remove ToggleListButton when readonly or disabled"

This reverts commit e54a2eca32.

* Combobox: remove unused code
2024-09-30 11:24:47 +02:00
Ken e5d5b67262 [Referansesider] Migrated to new tokens 2024-09-27 14:13:54 +02:00
Ken 246f25cbaa misc: Update darkmode config for tokens 2024-09-27 14:01:51 +02:00
Ken b2a22438ad bug: Fixed CDN-location for figma config 2024-09-27 12:58:30 +02:00
KenandHalvor Haugan 8b8b724e40 [Darkside] Generate Token config to be consumed by Figma plugin (#3172)
* feat: Build figma config

* bug: Fix ignored gitignore config

* refactor: Rename collection -> name key

* feat: pre-update value to figma config

* feat: Re-resolve name with grouping

* feat: Better handling of relative units

* feat: Added better typings, workflow file

* feat: Updated name-parsing for pregen of config

* feat: Removed Unused eslint-disable directive

* feat: Extract figma scope when creating variables

* refactor: Simplified code by extracting logic

* feat: Updated workflow naming

* bug: re-add missing group for semantic color

* feat: Add metadata to figma config

* bug: Added missing 'contrast declaration

* bug: Calculate correct radius values

* refactor: Simplified config structure by unwrapping scopes

* refactor: Extracted logic for group check

* refactor: Only allow string or number as figma value in config

* feat: Added tests for value conversions

* refactor: Renamed figma config file

* update: Lock update

* refactor: Avoid using format as a workaround to extract token list

* Update @navikt/core/tokens/darkside/figma/index.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/tokens/darkside/figma/create-tokens.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/tokens/darkside/util.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* refactor: inline filter calls

* refactor: Better typing for as group declaration

* refactor: Avoid using objects as type definintions

* refactor: Inline semantic token check for roles

* refactor: date -> timestamp and NO locale

* refactor: token -> tokens

* refactor: removed redundant redaclaration of token name in test

* refactor: Avoid extra tests for same check

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-09-27 12:35:42 +02:00
Ken 9f9bdcc645 bug: Fixed old test for global tokens 2024-09-26 19:13:38 +02:00
Ken 82bdf8075a [Tokens]: Update darkmode tokens and separate config support
feat: Updated darkmode tokens
feat: Split global color config into separate files
2024-09-26 19:09:01 +02:00
Julian Nymark 410e543825 🎨 [referansesider] minside eslint 2024-09-26 15:47:29 +02:00
Julian Nymark 40308e0e77 🎨 [referansesider] minside dokumentarkiv 2024-09-26 15:39:02 +02:00
Julian Nymark fff309b573 💄 [referansesider] minside NotificationsPanel lightmode match figma 2024-09-26 14:44:44 +02:00
Julian Nymark fe7c2de8fa 💄 [referansesider] minside PassiveCards++ 2024-09-26 14:37:42 +02:00
Julian Nymark 6fedea0ba4 💄 [referansesider] minside PassiveCards 2024-09-25 15:02:05 +02:00
Halvor HauganandKen 9811327509 [aksel.nav.no] Adjust examples of Switch (#3175)
---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-09-25 14:21:19 +02:00
Ken cf2034f914 [Aksel.nav.no] Open all Accordions when searched (#3179)
* feat: Open all Accordions when searched

* refactor: Type node as possibly undefined
2024-09-25 14:19:15 +02:00
dependabot[bot] 9e5e7f8fdc build(deps): Bump rollup from 3.29.4 to 3.29.5 (#3178)
Bumps [rollup](https://github.com/rollup/rollup) from 3.29.4 to 3.29.5.
- [Release notes](https://github.com/rollup/rollup/releases)
- [Changelog](https://github.com/rollup/rollup/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rollup/rollup/compare/v3.29.4...v3.29.5)

---
updated-dependencies:
- dependency-name: rollup
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-25 13:49:55 +02:00
Ken e9dc171d74 Referansesider: Dynamic route-list generation for header and homepage 2024-09-25 13:25:43 +02:00
Julian Nymark 544b80eeae 💄 [referansesider] Minside Cards 2024-09-25 13:17:10 +02:00
Julian Nymark 4358b53095 🎨 [referansesider] move Styled components to top layer++ 2024-09-25 12:07:57 +02:00
Julian Nymark de57099b09 🎨 [referansesider] move Styled components to top layer 2024-09-25 11:59:57 +02:00
Ken 5a97cb422d feat: Add cache-control to index.html metadata referansesider 2024-09-25 11:16:03 +02:00
Ken 67fb3bb3a1 feat: Added theme switcher for referansesider 2024-09-25 10:52:03 +02:00
Ken 7bdd5cb748 bug: Fixes darkmode cascading for darkside tokens 2024-09-25 10:10:24 +02:00
github-actions[bot]andgithub-actions[bot] 62bcab1ab0 Version Packages (#3170)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-09-25 09:36:07 +02:00
Halvor Haugan 61e60d9556 Modify changeset text for Accordion change 2024-09-24 17:17:18 +02:00
Halvor Haugan 9c1eba4450 Accordion: Remove position:relative to fix popover clipping 2024-09-24 16:53:46 +02:00
Julian Nymark 63986d9872 💄 [referansesider] remove overflow 2024-09-24 16:43:04 +02:00
Ken 761c8ef64f refactor: Update tokens use in Piktogram for sykepenger page 2024-09-24 16:31:30 +02:00
Ken 4b86b555d8 feat: Referansesider now properly handles nested routing 2024-09-24 16:10:58 +02:00
Julian Nymark 8e1e294fda 💄 [referansesider] minside add icons 2024-09-24 15:51:55 +02:00
Halvor Haugan f71594e477 ErrorSummary: Remove aria-attributes. (#3171) 2024-09-24 15:41:49 +02:00
Julian Nymark d2a89851cd 💄 [referansesider] responsive design fix 2024-09-24 15:31:25 +02:00
Ken d27da71304 feat: Refactored to use more tokens in referansesider 2024-09-24 15:26:19 +02:00
Julian Nymark fcf17fc750 💄 [referansesider] minside card CSS 2024-09-24 15:24:41 +02:00
Julian Nymark e1b091358b 🎨 [referansesider] add content to minside 2024-09-24 15:15:15 +02:00
dependabot[bot] 988ad39ad1 build(deps): Bump rollup in /examples/referansesider (#3173)
Bumps [rollup](https://github.com/rollup/rollup) from 4.21.3 to 4.22.4.
- [Release notes](https://github.com/rollup/rollup/releases)
- [Changelog](https://github.com/rollup/rollup/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rollup/rollup/compare/v4.21.3...v4.22.4)

---
updated-dependencies:
- dependency-name: rollup
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-24 14:00:52 +02:00
Ken 524c87e3bd feat: Update referansesider header fontsize 2024-09-24 13:54:48 +02:00
Ken 8cf6123656 feat: Created /komponenter route for component-testing, refactored button-component
feat: Use func for sykepenger function
2024-09-24 13:32:24 +02:00
Julian Nymark 866e6a168c 💄 [referansesider] make sykepenger more responsive 2024-09-24 13:16:47 +02:00
Ken bc2be15c55 Update referansesider
- feat: Refactor to use aksel-icons package
- refactor: use google import for font instead of inline files
2024-09-24 13:06:55 +02:00
Julian Nymark 4e6fc073fe 🐛 [referansesider] only have tanstack router devtools in dev mode 2024-09-24 12:59:56 +02:00
Ken e895c691ce [Referansesider] SPA deploy to aksel-referansesider.ansatt.dev.nav.no (#3174)
* bug: Fix build-script

* feat: Workflow for SPA deploy of referansesider

* feat: Add workflow dispatch to SPA deploy
2024-09-24 12:40:08 +02:00
Halvor Haugan 186c0fec07 🆙 Upgrade some packages (#3165) 2024-09-23 17:24:04 +02:00
Ken 746a58b663 feat: Updated darkside tokens with figma 2024-09-23 16:30:13 +02:00
Julian Nymark d767aadde3 🎨 [referansesider] add crude dekoratør 2024-09-23 14:02:30 +02:00
KenandHalvor Haugan 4359428b40 [Pagination] Deprecated page-prop, synced design with Figma (#3164)
* feat: Mark page-prop as deprecated in pagination

* feat: Mark page-prop as deprecated in pagination with better comment

* feat: Synced pagination with Figma

* memo: Changeset

* memo: Add classes to deprecationlist in stylelint config

* memo: changeset for stylelint

* memo: changeset for stylelint

* Update @navikt/aksel-stylelint/src/deprecations.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update .changeset/thirty-snakes-doubt.md

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-09-23 12:28:52 +02:00
Halvor Haugan d583276428 Combobox: 🏷️ Better typing for maxSelected prop (#3169) 2024-09-23 10:07:06 +02:00
github-actions[bot]andgithub-actions[bot] 0d29a0708a Version Packages (#3151)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-09-20 10:33:33 +02:00
Vegard Haugstvedt d6b685c4c5 Bugfix/combobox list items with multiple spaces get invalid (#3162)
* Fix issue with whitespace in the id attribute for options with multiple spaces

* Add changeset
2024-09-20 09:32:34 +02:00
Julian Nymark 17eaf6139b 🎨 [referansesider] sykepenger++ 2024-09-20 00:38:18 +02:00
Julian Nymark f0820f4f89 🎨 [referansesider] sykepenger++ 2024-09-20 00:38:18 +02:00
Halvor Haugan cd9dc047ed Upgrade dockerimage (#3160) 2024-09-19 15:06:56 +02:00
Julian Nymark bc711c9653 💄 [referansesider] css tweaks for Accordion 2024-09-19 13:00:01 +02:00
Julian Nymark 5fd1d385cf 🎨 [referansesider] add PillLink 2024-09-19 12:22:13 +02:00
dependabot[bot]andHalvor Haugan f44acf4216 build(deps-dev): Bump vite in /examples/referansesider (#3154)
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 5.4.5 to 5.4.6.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v5.4.6/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.4.6/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2024-09-19 10:47:21 +02:00
Julian Nymark 302eed3908 💄 [referansesider] use new tokens 👏 2024-09-18 17:08:39 +02:00
Julian Nymark 24bec11799 💄 [referansesider] Accordion 2024-09-18 16:56:39 +02:00
KenandHalvor Haugan 72b2b3875b [Tokens] Updated to new config (#3157)
* feat: Update style-dictionary to v4

* feat: Rewritten tokens to typescript

* feat: Update to new token config

* refactor: removed unused types

* feat: Remove 'A'-prefix in js token

* update: Lock update

* testing: Updated tests to correctly mirror wanted behaviour

* refactor: Removed output fallbacks

* Update @navikt/core/tokens/darkside/tokens/contrast.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* refactor: Update white definition in contrast

* refactor: Remove duplicate global color definition

* refactor: Avoid accumulator spread in reduce

* refactor: rename 'mode' -> 'theme'

* Update @navikt/core/tokens/darkside/sd-format.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* feat: Added comment support to JS-tokens

* Update @navikt/core/tokens/darkside/tests/validate-config.test.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* refactor: Use correct config in tests

* Update @navikt/core/tokens/darkside/util.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* feat: Added returnType for semanticTokensForAllRolesConfig

* feat: Types token configurations

* feat: Updated color-scale to latest figma-update

* feat: Types mergeConfig function

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-09-18 16:43:42 +02:00
Halvor Haugan e023ace28d Adjust examples of Accordion (#3159) 2024-09-18 16:06:33 +02:00
Julian Nymark 0129159812 🚚 [referansesider] consistent file naming 2024-09-18 15:48:42 +02:00
Julian Nymark 72fd005990 🎨 [referansesider] clsx dep + more content 2024-09-18 15:41:32 +02:00
Julian Nymark 104427d7ef 🎨 [referansesider] more work on Sykepenger 2024-09-18 13:57:10 +02:00
Julian Nymark 996118532b ➕ [referansesider] tw-merge 2024-09-18 13:56:31 +02:00
Julian Nymark 1cdf2c93a8 ✨ [referansesider] add icon 2024-09-18 13:55:51 +02:00
Julian Nymark 82e66e2a4b ✨ [referansesider] add icon 2024-09-18 13:55:41 +02:00
Julian Nymark 03495f8343 💄 [referansesider] adjust sykepenger header 2024-09-18 10:40:51 +02:00
KenandHalvor Haugan 17031eafbe [Tokens] Updated config to Style-dictionary v4, rewritten to typescript (#3156)
* feat: Update style-dictionary to v4

* feat: Rewritten tokens to typescript

* Update @navikt/core/tokens/config/build.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/tokens/package.json

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* update: Lock update

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-09-18 10:17:41 +02:00
Julian Nymark fe3c42282a 🎨 [referansesider] add sykepenger header 2024-09-18 09:58:31 +02:00
Julian Nymark 7defbd9163 💄 [referansesider] remove broken negative margin calc css 2024-09-17 16:13:45 +02:00
Julian Nymark 4a402557f6 🎨 [referansesider] more scaffolding, remove unused CSS 2024-09-17 16:12:24 +02:00
Halvor Haugan f7ff964162 LanguageProvider: Remove spreading of empty object (#3153) 2024-09-17 15:28:41 +02:00
Julian Nymark 6bad72e891 🔥 [referansesider] remove generated file from git 2024-09-17 14:18:49 +02:00
Julian Nymark b0b493bc08 ➕ [referansesider] add tailwindcss 2024-09-17 14:13:36 +02:00
Julian Nymark 0720f22467 ➕ [referansesider] add tailwindcss 2024-09-17 14:11:00 +02:00
Halvor Haugan f4137e4df8 Adjust default story on ExpansionCard 2024-09-17 14:01:32 +02:00
Julian Nymark 730538cfb4 🎨 [referansesider] add router 2024-09-17 13:35:19 +02:00
Halvor Haugan a63c3792cc Simplify PR template and add guideline about changeset message (#3138) 2024-09-16 15:55:04 +02:00
Julian Nymark dd03bd8705 🚧 [referansesider] add example for variant in styled-components 2024-09-16 15:34:16 +02:00
Julian Nymark 97eec24ae0 🚧 [referansesider] do not use existing components & CSS 2024-09-16 15:26:06 +02:00
Julian Nymark 09e4f70365 🚧 [referansesider] use local dependencies for react as well 2024-09-16 13:56:02 +02:00
Julian Nymark ce694fa37c 🚧 [referansesider] use local dependencies for css & tokens 2024-09-16 13:50:53 +02:00
Julian Nymark 7f27e19032 🚧 [referansesider] correctly import design token 2024-09-16 13:21:35 +02:00
Julian Nymark 12f6ae9134 🚧 [referansesider] use styled-components, try to import our tokens 2024-09-16 13:13:42 +02:00
Julian Nymark 3c6459305e 🚧 [referansesider] add aksel dependencies 2024-09-16 12:47:26 +02:00
Julian Nymark 60cf2b863b ✨ (referansesider) init vite project 2024-09-16 12:19:26 +02:00
Halvor Haugan 78779fbb56 🆙 Upgrade to Storybook 8.3 (#3150) 2024-09-16 09:53:28 +02:00
SebastianJarsve 59156e603c Fix link in CONTRIBUTING.md (#3152) 2024-09-16 09:42:36 +02:00
Julian Nymark 057bfe85be 💄 tweak CSS for list icons (#3148) 2024-09-13 16:17:51 +02:00
github-actions[bot]andgithub-actions[bot] d2424ec22a Version Packages (#3149)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-09-13 14:03:22 +02:00
1c11a6a3b9 Aksel v7 (#3139)
* Tooltip labeling (#3094)

* feat: Better labeling of Tooltip

* feat: Better keyshortcuts for screenreaders in Tooltip

* memo: Updated story

* bug: Better error logging for example-parsing

* refactor: describeChild -> describesChild

* fire: Removed extra story

* bug: removed extra tabIndex

* memo: Update Tooltip demo description

* Update aksel.nav.no/website/pages/eksempler/tooltip/labeling.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* refactor: Updated defaultValue for describesChild

* bug: removed Tooltip prop from ToggleGroup

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Tailwind: Fixed 'screen' -> 'screens' bug to properly adopt breakpoints. (#3119)

* 💥 Screen -> Screens in tailwind-config

* refactor: Adopt updated screens-config in Aksel.nav.no project

* Icons: Removed old and renamed icons (#3120)

* 💥 Removed renamed icons

* ErrorSummary: Add fallback for heading + better focus handling (#3140)

Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* feat: Added composeEventHandlers to onFocus in ErrorSummary

* memo: Removed inaccurate description for tooltip demo

* feat: Omitted tabIndex from ErrorSummary

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2024-09-13 13:48:56 +02:00
Julian NymarkandKen 46a14b19dd translations in Provider (#3136)
* 🚧 translations in Provider

* ♻️ consume providerContext translations in useI18n + example usage (FormProgress)

* changeset

* 🎨 keep component level translations

* ♻️ extract language provider into own provider

* 📝 update changeset doc

* 🎨 undo all changes to original Provider

* 📝 changeset text

* ✅ update test for i18n changes

* refactor: Moved location of LanguageProvider, removed changeset

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
2024-09-12 15:36:04 +02:00
45a50a531e Version Packages (#3137)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-09-12 14:48:31 +02:00
Halvor Haugan c506c1787f [aksel.nav.no] SuggestionBlock for beta patterns (#3144) 2024-09-12 11:41:02 +02:00
dependabot[bot] 36ada01453 build(deps): Bump express from 4.19.2 to 4.20.0 (#3146)
Bumps [express](https://github.com/expressjs/express) from 4.19.2 to 4.20.0.
- [Release notes](https://github.com/expressjs/express/releases)
- [Changelog](https://github.com/expressjs/express/blob/master/History.md)
- [Commits](https://github.com/expressjs/express/compare/4.19.2...4.20.0)

---
updated-dependencies:
- dependency-name: express
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-11 15:01:20 +02:00
Ken 88201e34d8 🔒 Moved chromatic env token to .env and github secrets (#3145) 2024-09-11 11:56:52 +02:00
Halvor Haugan 14fed5aa95 Adjust examples of Stepper (#3143) 2024-09-10 12:52:40 +02:00
Ken 672fdb9d0c [Aksel.nav.no, Button docs] Renamed 'frameworks' example to 'button as link'. (#3135)
* memo: Updated storyname for button framework

* memo: Updated example with link i description and link -> nextlink

* testing: Added test to check link/markdown-parsing in description-field

* test for playwright

* bug: Playroom does not support Nextjs link

* bug: Turn off sandbox for bytton-demo missing import in playroom
2024-09-10 12:42:12 +02:00
Halvor Haugan 1d585e6667 Form validation demo improvements (#3132) 2024-09-09 12:51:45 +02:00
Ken 1b2dc88968 [Icons] Added new icons for face category (#3134)
* feat: Added new icons for face category

* Update .changeset/lazy-dryers-do.md
2024-09-09 09:48:08 +02:00
Halvor Haugan c8b79090d2 Combobox: Add support for onBlur, and omit props that have no effect (#3125) 2024-09-09 09:31:18 +02:00
github-actions[bot]andgithub-actions[bot] 914b0dbcb0 Version Packages (#3117)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-09-04 14:27:45 +02:00
Lars Eirik Korsgaard Hansen e271bc0aaa 🐛 Combobox: trailing spaces are no longer accepted autocomplete-letters (#3105)
* 🐛 spaces no longer act as an accepted autocomplete-letter

* changeset

* simplified previous code, added edge case to story
2024-09-04 11:01:29 +02:00
Halvor Haugan 052750b4b9 Form validation examples (#3100) 2024-09-03 22:03:58 +02:00
KenandHalvor Haugan 531e720a35 Update sanity (#3096)
* feat: Update sanity

* feat: Update sanity minor

* feat: Bumped sanity to 3.55

* Update aksel.nav.no/website/sanity/schema/objects/templates/ExampletextBlock.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-09-02 12:50:13 +02:00
Julian NymarkandHalvor Haugan c98ab95750 Combobox: 🚸 hide caret on select (until options list opened) (#3071)
* 🚸 hide caret on select (until list opened)

* 🔥 remove console.log()

* 🎨 invert varname for simpler CSS

* 🚸 also enable caret on "re-click" (while still focused)

* 🚸 DX improvement, placeholders++

* 🚸 (combobox) always show caret for multiple select

* 🚸 hide caret on multiselect + isLimitReached

* 🔥 remove console.log

* 🐛 hide caret when single has a selection (combobox)

* 🐛 hide caret if isLimitReached

* 🎨 remove unnecessary useState()

* 🐛 correct deps for useEffect

* 🐛 add maxSelected as dep

* Update @navikt/core/react/src/form/combobox/FilteredOptions/filteredOptionsContext.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* changeset

* 🐛 avoid setting placeholder twice

* Update .changeset/fresh-boxes-enjoy.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🔥 remove redundant placeholder

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-09-02 12:14:25 +02:00
Ken 1cea314de0 bug: Avoid RelatertInnhold from erroring when empty 2024-09-02 10:33:47 +02:00
Ken 7c5538fe5e Security token update (#3128)
* feat: Token re-roll

* demo: Placeholder frontpage

* Revert "demo: Placeholder frontpage"

This reverts commit b7dbc3a65b.

* feat: Token re-roll for slackbot

* bug: Added env to playwright url-generation
2024-09-01 23:18:35 +02:00
Halvor Haugan 2c346a81dd Adjust example heading text for ErrorSummary (#3126) 2024-08-30 16:35:07 +02:00
Julian Nymark 32c13c0363 combobox 🚸 tweaks for single select (#3124)
* combobox 🚸 tweaks for single select

- hide the selected value when inputing text
- delete input value on blur (you must actually select something with
  intent to select it, this prevents the field from "looking like it's
  filled in when it's actually not")

* changeset

* 🐛 use clearInput() instead of setValue("")

* 💄 match x-position of input to the selected option
2024-08-30 09:35:48 +02:00
Vegard Haugstvedt aca5143454 Bugfix/combobox selecting autocompleted word is broken (#3110)
* Add test case for selecting autocompleted word after first character typed, which is currently broken (selects first in list, not the autocompleted word)

* Select the correct option when pressing enter after autocompleting a word in Combobox

Fixes #3106

* Added changeset
2024-08-28 13:45:13 +02:00
Halvor Haugan 6220b9ce69 Icons: Adjust keywords for ClipboardXMark (#3121) 2024-08-28 12:07:35 +02:00
Julian Nymark 8540bd756b 🚨 no-console (#3078)
* 🚨 no-console

* 🚨 also fail on warnings

* 🔥 undo whitespace change

* 🔥 remove whitespace again?

* 🐛 don't lint js with ts rules

* 🚨 convert some log -> info

* 🐛 avoid the max-warnings bug failing on ignored files

* Revert "🐛 avoid the max-warnings bug failing on ignored files"

This reverts commit 0f7c169daf.

* 🐛 exclude some generated files

* 🔥 remove debug log

* 🔥 remove debug log

* 🔥 remove debug log
2024-08-26 12:01:19 +02:00
dependabot[bot] 3d2a9da528 build(deps): Bump micromatch from 4.0.7 to 4.0.8 (#3116)
Bumps [micromatch](https://github.com/micromatch/micromatch) from 4.0.7 to 4.0.8.
- [Release notes](https://github.com/micromatch/micromatch/releases)
- [Changelog](https://github.com/micromatch/micromatch/blob/4.0.8/CHANGELOG.md)
- [Commits](https://github.com/micromatch/micromatch/compare/4.0.7...4.0.8)

---
updated-dependencies:
- dependency-name: micromatch
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-08-26 10:09:42 +02:00
Ken 9907ef08a6 feat: Updated Clipboard-icons (#3113) 2024-08-26 09:55:02 +02:00
github-actions[bot]andgithub-actions[bot] 33b3ac795a Version Packages (#3115)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-08-26 09:48:48 +02:00
Ken 122477cf98 Font naming and location preload fix (#3114)
* feat: Update font-reference to old naming to preserve preloads

* memo: Changeset

* memo: Changeset update
2024-08-26 09:16:53 +02:00
Ken 64240eb84a feat: Added template category for 'brev' 2024-08-21 13:03:35 +02:00
KenandHalvor Haugan b5d76f7360 Updated contribution texts for templates (#3104)
* memo: Updated contribution texts on templates

* Update aksel.nav.no/website/components/website-modules/suggestionblock/SuggestionBlock.GhPages.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-08-21 13:00:51 +02:00
Ken 7244e7b148 feat: Update ExpansionCard heading options for sanity (#3111) 2024-08-21 12:38:02 +02:00
Ken deb4ef16fd 📝 Correct heading-size (xlarge) for templates 2024-08-21 08:21:02 +02:00
github-actions[bot]andgithub-actions[bot] 8c5c6dde96 Version Packages (#3107)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-08-21 07:55:59 +02:00
Julian Nymark f5ff01c830 🎨 add category to aksel website (monster og maler) 2024-08-19 13:57:06 +02:00
Ken 8ce364ec39 Table: Fixed background clipping when using ExpandableRow (#3095)
* bug: Fixed backgroud clipping when using ExpandableRow in Table

* Update .changeset/modern-items-leave.md

* refactor: Use onClick on expandable tablecell

* fire: Removed duplicate eventhandler

* fire: removed testing-story
2024-08-16 14:12:15 +02:00
Ken 293b15f6bb Markdown support in Code example descriptions (#3098)
* feat: Added markdown link support to code example descriptions

* memo: Markdown implementation tested in story

* refactor: Use child pattern
2024-08-16 13:40:58 +02:00
dependabot[bot] 289ce637f6 build(deps): Bump elliptic from 6.5.6 to 6.5.7 (#3109)
Bumps [elliptic](https://github.com/indutny/elliptic) from 6.5.6 to 6.5.7.
- [Commits](https://github.com/indutny/elliptic/compare/v6.5.6...v6.5.7)

---
updated-dependencies:
- dependency-name: elliptic
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-08-16 12:50:49 +02:00
Vebjørn RekkeboandKen 09ea18a54e Bump jscodeshift-add-imports (#3099)
* bump jscodeshift-add-imports to 1.0.11

* version-entry

* improve patch description

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-08-16 09:29:59 +02:00
Ken 936d4176f8 Feature: Block for download-links in Sanity (#3108)
* feat: Downloads block

* feat: Block for adding file-downloads to articles

* Update aksel.nav.no/website/components/sanity-modules/download-block/DownloadBlock.stories.tsx

* Update aksel.nav.no/website/components/sanity-modules/download-block/DownloadBlock.tsx

* feat: Added max width

* bug: Used nb locale for file size format

* refactor: DownloadLink -> attachment

* bug: attachment rename in query

* feat: Body-text not required

* memo: Updated story for no body variant of attachment

* bug: Fixed reference to old naming
2024-08-15 15:35:04 +02:00
Halvor Haugan 19e8fcaff1 Table: Corrected the type of onSortChange (#3103) 2024-08-15 14:45:29 +02:00
Lars Eirik Korsgaard HansenandHalvor Haugan 4e76298a9a 🩹 Combobox: placeholder fix (#3101)
* remove placeholder when value added; add placeholder to story

* add max selected to default story

* patch changeset

* Update .changeset/friendly-pens-sin.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update friendly-pens-sin.md

* move fix to Input from InputController

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-08-15 14:42:00 +02:00
Halvor Haugan 2f23278d53 Adjust examples of Tabs 2024-08-15 14:13:18 +02:00
Halvor Haugan 75da983588 Adjusted examples of Select (#3102) 2024-08-15 13:39:36 +02:00
dependabot[bot] 27c43ef5e5 build(deps): Bump axios from 1.6.0 to 1.7.4 (#3097)
Bumps [axios](https://github.com/axios/axios) from 1.6.0 to 1.7.4.
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](https://github.com/axios/axios/compare/v1.6.0...v1.7.4)

---
updated-dependencies:
- dependency-name: axios
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-08-14 14:34:56 +02:00
github-actions[bot]andgithub-actions[bot] b9ad316745 Version Packages (#3089)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-08-13 13:45:41 +02:00
Halvor Haugan 0de87ce911 FormSummary: Add background color (#3093) 2024-08-13 13:07:32 +02:00
KenandHalvor Haugan d4ce6aeb7d Updated Table sorting demo (#3090)
* memo: Updated Table sorting demo

* refactor: use nullish check for sortable

* Update aksel.nav.no/website/pages/eksempler/table/sortable.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-08-13 13:03:38 +02:00
Ken d319dae22f feat: History i now kept when navigating filters on god-praksis pages (#3092) 2024-08-13 13:03:30 +02:00
Halvor HauganandKen 9e6808d31f Adjusted color token Green 400 (#3091)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-08-13 10:29:03 +02:00
Halvor Haugan 1cba662ad3 Fix release job (#3087) 2024-08-12 14:08:26 +02:00
Ken 813d5020cc Primitives: Added gridColumn-prop for more grid alignment control (#3082)
* feat: Added gridColumn prop to Baseprimitives

* memo: Changeset
2024-08-12 12:56:35 +02:00
Halvor Haugan c53543ccd8 Modal: Added scroll shadows (#3083) 2024-08-12 12:38:08 +02:00
Halvor Haugan 0a9d3b3c59 🆙 Upgrade rimraf and yarn, remove glob (#3084) 2024-08-12 12:36:49 +02:00
Ken 5b1aeea15f feat: Changed design category to brand (#3086) 2024-08-12 12:28:33 +02:00
Ken 8e15d43e50 feat: Order GP-articles based on last verified, not publish date (#3068)
* feat: Order GP-articles based on last verified, not publish date

* refactor: Updated naming and removed publishedAt value from query
2024-08-09 14:23:37 +02:00
github-actions[bot]andgithub-actions[bot] 3c95772b1a Version Packages (#3077)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-08-09 09:53:16 +02:00
Ken a312faac6b Updated chromatic-project (#3079)
* feat: Updated chromatic-project

* bug: remove extra forwardslash
2024-08-08 14:34:48 +02:00
02fa92468b FloatingMenu component (#2906)
* ✨ Initial Popper wrapper

* ✨ Floating popper element

* 🏷️ Rename popper -> floating

* 🐛 Fikset imports

* ♻️ FLoating-fil splittet opp i moduler

* 🎨 Satt opp exports og story

* 🎨 Arrow er nå del av content

* 🐛 display block på arrow

* 🎉 Egen Portal-komponent

* 🎨 Portal og Overlay exportert i root

* ♻️ Tooltip bruker egen Portal

* 📝 Changeset

* 🔀 Merge Portal

* 📝 Story with portal

* 📝 Props story

* 🚚 Temp rename

* 🚚 Temp rename

* 🎨 La til Slot på Floating.Anchor

* ✨ Fungerende nesting av dismissable items

* ✨ Fungerende outsidepointerclick handler

* 🚚 Ryddet opp i struktur

* ✨ bedre event-handling

* 🎉 Popover bruker dismissableLayer

* 🔥 Fjernet console.logs

* ♻️ Extender nå ikke htmldivelement

* 📝 Commented on dimsissablelayer

* 📝 Kommentarer

* 🎨 Disable pointer-events on body

* 🎨 Setup content

* 🎨 Fungerende popover med story

* 🎨 useDescendant-API kan bruke uten context-error på nesting

* 🐛 Fikset tilfeller der oppdatering av descendant-options ikke ble reflektert i descendants-map

* 🐛 Satte enabled til optional

* bug: import av Portal brakk stories for Popover og Floating

* bug: DescenadantContext er nå riktig typet som undefined

* label: scopet navn for bruk av descendant-provider i dismissablelayer

* memo: Bedre kommentarer

* feat: Sender ikke callbacks hvis layer er disabled

* memo: Formatering og kommentarer

* memo: Kommentarer

* copy: Kopiert over basekomponent

* refactor: Oppdatert imports

* refactor: Oppdatert Primitive bruk

* feat: Støtter forwardRef

* fire: Fjernet Radix import

* feat: Bruker Floating og ikke PopperPrimitive

* type: Bedre typet composeEventHandler

* refactor: Fjernet scopedProps

* feat: Custom RowingFocus

* wip feat: Replaced rowingfocus

* wip feat: Implemented initial focus for rowingfocus

* wip feat: Removed old collection api

* refactor: Use internal Slot component

* refactor: Fixed all scoped context-use

* feat: Fullført migrering til internt API

* test: Setup stories

* bug: Content is added to descendants

* bug: Found issue for nesten descendants

* copy: Kopiert over refactor for useDescendant

* bug: Fikset descendants nesting

* feat: Fikset keyboard nav med nested descendants

* bug: Removed early return

* memo: Kommentarer

* label: Typer

* refactor: Fjernet Root export

* refactor: Fjernet typeahead

* test: Setup story for entryfocus

* refactor: Forenklet FocusScope

* refactor: bedre dokumentert utils

* refactor: Moved utils to separate file

* refactor: Moved slotted-div to separate file

* refactor: Moved MenuContext out to context-file

* 🚚 Moved focus-files

* refactor: Update syntax

* refactor: Moved MenuAnchor to file

* refactor: Moved MenuGroup to file

* refactor: Moved Separator to file

* refactor: Moved Label to file

* refactor: Moved utility-components

* refactor: Flyttet item til mappe

* refactor: Flyttet checkbox

* refactor: Content in separate file

* refactor: Radio i separate filer

* refactor: SubComponents in files

* refactor: Bedre typer

* refactor: Re-written back to single file

* refactor: Fjernet gamle commits

* bug: Fikset import feil og feil extension av type

* refactor: data-attrb fra radix -> aksel

* refactor: Fjernet console.logs

* bug: Fixed import and test-type error

* refactor: Remove unwanted exports

* feat: Re-added ItemIndicator wrapper

* refactor: Updated exports

* refactor: removed focusguards

* refactor: FocusScope now assumes Slot

* refactor: Removed extra tabIndex

* feat: Implemented ItemIndicator and styling for testing

* refactor: Rowing -> Roving

* refactor: Moved Menu-component into overlays-dir

* bug: Fixed import of Slot

* bug: Re-add tabIndex to MenuItem for correct focus-handling

* memo: Rename Tab -> menu

* refactor: removed unwanted exports in story

* Update @navikt/core/react/src/overlays/floating-menu/Menu.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* bug: Added missing meta import

* bug: Aligned dash with checkmark

* bug: Circle icon now shows for radio-demo

* bug: keyframes has extra ':', breaking animations

* bug: Re-added ItemIndicator for all TickIcon

* bug: WithLabel story now shows complete dropdown

* feat: Added disabled-styling to submenu

* refactor: Now uses ownerdocument where needed instead of document

* adjustments after review 1

* adjustments after review 2

* refactor: Updated to correct function type syntax

* refactor: renamed floating content propname

* refactor: Consistent destructuring of props

* refactor: rename FocusScope props

* memo: Added explanation for why we use flushEvent

* refactor: added consistent use of composeEventHandlers

* refactor: Force userSelect none style

* demo: Allow canceling opening if pointerdown is released outside of menu

* memo: Better line-dividers

* refactor: removed data-highlighted logic

* Update @navikt/core/react/src/overlays/floating-menu/Menu.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/overlays/floating-menu/Menu.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* feat: Allow use of 'il' in floating-element

* feat: Implemented semantic tags for items and content

* Revert "feat: Implemented semantic tags for items and content"

This reverts commit 6bf473328d.

* Revert "feat: Allow use of 'il' in floating-element"

This reverts commit 5307facbca.

* minor adjustments

* feat: Added optional close keybind for submenus

* refactor: Removed unneeded label component

* memo: Comments

* memo: Comments

* refactor: Update hookname

* refactor: removed duplicate callback

* refactor: Less nesting in FocusScope

* refactor: Remove extra edgecase check not needed for dropdown

* refactor: Impl -> internal

* Update @navikt/core/react/src/overlays/floating-menu/parts/FocusScope.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/overlays/floating-menu/parts/FocusScope.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* memo: FocusScope jsdoc

* Update @navikt/core/react/src/overlays/floating-menu/parts/FocusScope.tsx

* Update @navikt/core/react/src/overlays/floating-menu/parts/FocusScope.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* testing: Added onCloseAutoFocus demo

* refator: renamed onTriggerLeave

* refator: better handleing of edgecase where we close sidemenu with arrowright

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2024-08-08 12:07:03 +02:00
Ken ea3e881467 feat: New icons Split (#3072) 2024-08-08 11:03:22 +02:00
Halvor Haugan 779e30d1df Combobox: Can no longer remove options with backspace when shouldShowSelectedOptions is false (#3076) 2024-08-07 12:48:22 +02:00
Halvor Haugan 0bd7812cdd [aksel.nav.no] Correct icon on hard coded list item (#3075) 2024-08-07 12:39:06 +02:00
Vegard Haugstvedt 58283c0e95 Refactor/split up filtered options (#3073)
* refactor: Move AddNewOption to a separate file to make FilteredOptions cleaner and prepare for future features.

* refactor: Move FilteredOptionsItem to a separate file to make FilteredOptions cleaner and prepare for future features.

* refactor: Move MaxSelectedMessage to a separate file

* refactor: Move LoadingMessage to a separate file

* refactor: Move NoHitsMessage to a separate file

* Added changeset and a type to FilteredOptionsItem props
2024-08-07 12:38:54 +02:00
Ken 7cfb69c239 Update README.md (#3074) 2024-08-07 12:28:34 +02:00
github-actions[bot]andgithub-actions[bot] 09828a4223 Version Packages (#3043)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-08-07 11:52:24 +02:00
Halvor Haugan e776c7c560 Endre changeset 2024-08-07 11:45:17 +02:00
Halvor Haugan 2dd266f0c4 ⬆️ Upgrade dependencies (minor) (#3070) 2024-08-07 09:13:14 +02:00
Ken daee394a71 feat: Hide sandbox-pages from robots (#3069) 2024-08-06 07:31:39 +02:00
KenandHalvor Haugan 8fd183cc90 feat: Updated font support and definition (#3044)
* feat: Updated font definitions

* memo: Changeset

* stories adjustments

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2024-08-05 09:34:07 +02:00
Halvor Haugan 0b1ac4f82c [aksel.nav.no] Support relative markdown links (#3059) 2024-08-05 09:32:46 +02:00
KenandHalvor Haugan ec79e25060 feat: Added stale-issue handling (#3029)
* feat: Added stale-issue handling

* Update .github/workflows/stale.yml

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-08-05 08:57:44 +02:00
Vegard HaugstvedtandHalvor Haugan 18d20aaa8e Combobox: Pressing Escape in while focusing a Combobox inside a Modal will close the Modal (#3053)
* If pressing Escape while FilteredOptions is open, Combobox should swallow the keydown event, so it does not close a Modal

* Added changeset

* Update @navikt/core/react/src/form/combobox/Input/Input.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Prevent default Escape from bubbling out of Combobox also when we have a value (which will be cleared).
Also co-located all the Escape-handling in keyDown. This also better mimics Select's native behaviour.

* Add clearInput to dependency array

* Legg til et Storybook-eksempel på Combobox i Modal, for manuell testing. La inn en tekst for å forklare caset.

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-08-02 13:30:22 +02:00
Halvor Haugan 72c8f3112a Combobox: Fixed aria-describedby and some types (#3065) 2024-08-02 12:51:25 +02:00
Vegard HaugstvedtandHalvor Haugan 6e63069d6b Combobox: Fix NullPointer error in single-select with allowNewValues (#3054)
* Prevent NullPointer when selecting a new/custom value in Combobox single-select with Enter (without selecting it in FilteredOptions)

* Update .changeset/cyan-carrots-return.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Expect AddNewButton to be visible

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-08-02 12:47:37 +02:00
Halvor Haugan 825d87af43 Combobox: Entering an already selected option and pressing enter no longer removes it (#3061) 2024-08-02 12:43:34 +02:00
9181d2ce75 Combobox: Implement free text search (#2974)
* Implement fuzzy search in combobox

* bug: ArrowUp now works as intended, stopped onChange from running each arrow-press

* memo: Added comment

* refactor: Removed extra state-update for searchterm

* Update @navikt/core/react/src/form/combobox/FilteredOptions/filtered-options-util.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* bug: Missed function export after refactor

* Add test for filtering in search

* Fix comments to better reflect the new code

* Change type for onChange to take in only value, not the entire event. This simplifies calling onChange programatically.

* Added changesets to reflect the changes in this branch

* KeyboardEvent.currentTarget does not have selectionStart property

* Update example

* Update storybook examples

* bug: Fixed undefined value sent to toggleOption callback

* revert: Removed test for what was corret interaction

* Add generic to enhance the event type for handleKeyDown

* Updated JSDoc

* Changed method signatures for onChange earlier, but forgot these two tests

* Add test for triggering onChange on every typed character in Combobox with autocomplete.

Currently fails on the last character, as it does not actually change the word in the input field.

* Move onChangeHandler from triggering onChange to onInput, as the former does not trigger when typing the last character of an autocompleted word.
onInput seems to work more consistently, but will test multiple use cases.

* Update aksel.nav.no/website/pages/eksempler/combobox/multi-select-controlled.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/form/combobox/Input/Input.tsx

* Update .changeset/wild-owls-tan.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/form/combobox/Input/Input.tsx

* updateInputValue is no longer neccessary

* Update @navikt/core/react/src/form/combobox/Input/Input.tsx

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-08-02 11:04:50 +02:00
Ken 22016ec90f prettier-plugin-tailwindcss update (#3046)
* feat: Updated tailwind prettier plugin

* refactor: Used prettier-plugin to remove extra whitespace in className
2024-07-10 10:44:58 +02:00
Ken f7d4c43f98 Added support for markdown links in intro lists (#3045)
* feat: Added support for markdown-links in intro-list

* memo: Added comments
2024-07-10 10:40:22 +02:00
Ken c67fd8bcda feat: Increased amount of articles shown in masonary 2024-07-09 14:27:42 +02:00
Julian Nymark 5efa09d00e 🐛 bump playroom version + set white bg (#3042) 2024-07-08 15:35:46 +02:00
Ken 3afc568a04 refactor: Better naming for modifiers check in Tabs and Togglegroup 2024-07-08 08:44:36 +02:00
Ken 2fe2586ac6 Respect meta-keys when navigating in Tabs, ToggleGroup (#3041)
* bug: RovingFocus now respects alt-keys

* memo: changeset
2024-07-08 08:41:11 +02:00
Ken 420c5c30d8 Primitives CSS update (#3028)
* refactor: Updated stack to only add CSS when used as prop

* refactor: Updated hgrid to only add CSS when used as prop
2024-07-04 14:55:25 +02:00
Ken 6cf141a8c6 Font sync (#3032)
* refactor: Created namespaced location for SourceSans3 fonts

* testing: Added story/chromatic for fonts

* refactor: Rename to use - instead of underline

* refactor: Remove SourceSans3 prefix
2024-07-01 11:04:54 +02:00
dcba0fffad Chromatic stories consolidation (#2996)
* Guidepanel

* Bleed

* Move 'options' object out of 'control' object

* Hide & Show

* Page

* h2 instead of Heading in Chromatic FN

* 🎨 update stories

* 🐛 disable the forcedColors parameter, seems buggy?

- it seems to be a chromatic error, or at least I'm not sure what's
  happening when this parameter is enabled. Some stories seem to
  sporadically get the forcedColors applied.

* Stack

* Combobox: put 'Test' before every test-story for clarity

* Combobox & move combobox tests to tests-file

* made combobox stories testable with Chromatic snapshots

* Update @navikt/core/react/src/button/button.stories.tsx

* Alert rewrite

* Bleed add chromatic disable false

* FileUpload

* FormSummary

* HelpText

* Tooltip

* yarn update chromatic to 11.5.4

* Show: move parameters into Chromatic object

* memo: Removed duplicate heading

* bug: Removed extra argTypes

---------

Co-authored-by: Julian Nymark <julian.nymark@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2024-07-01 10:58:33 +02:00
Halvor Haugan da0a66fb62 Fix type for default export in stories (#3038) 2024-07-01 09:47:02 +02:00
Halvor Haugan 3a52359169 Improved example of top aligned Modal (#3039) 2024-07-01 09:40:01 +02:00
1b8d553c05 <VirtualFocus /> component (#2894)
* 🚧 WIP on some dropdown prop API

* ♻️ rename dropdown -> autocomplete

* 🚧 WIP towards Autocomplete (inspiration from Menu)

* 🚧 WIP Autocomplete

* 🚧 wip Autocomplete

* 🚧 wip Autocomplete

* 🚧 working idea for context (get & set autocomplete)

const thinger = () => {

* 🚧 pick property on Item

* 🚧 enrich story/example of Autocomplete

show how easy it is to add icons / do something more complicated inside
the autocomplete suggestions list alongside a <Search>

* 🚧 wip

- fairly nicely working list of virtually focusable items
- API interface kept simple (moved pick to Anchor though, single "exit
  point")
- item has focus function now, which triggers when it gets virtual
  focus, the API should not distinguish between virtual and real focus
  was the thinking here, it's more an implementation detail.

* 🚧 WIP new story for Autocomplete

- showcase dropdown search autocomplete

* Update @navikt/core/react/src/form/autocomplete/Autocomplete.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update @navikt/core/react/src/form/autocomplete/Autocomplete.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* 🔥 refactor class -> attr, remove css, use user provided <style> in story

* 🔥 remove originial ideas for a prop on <Search>

* ♻️ refactor + use mouseMove over mouseOver

* 🐛 reset virtualfocus on input change (within Anchor)

* ✨ add prop 'loop' for Autocomplete

* 🚚 Autocomplete -> VirtualFocus

* 🚧 WIP on some dropdown prop API

* ♻️ rename dropdown -> autocomplete

* 🚧 WIP towards Autocomplete (inspiration from Menu)

* 🚧 WIP Autocomplete

* 🚧 wip Autocomplete

* 🚧 wip Autocomplete

* 🚧 working idea for context (get & set autocomplete)

const thinger = () => {

* 🚧 pick property on Item

* 🚧 enrich story/example of Autocomplete

show how easy it is to add icons / do something more complicated inside
the autocomplete suggestions list alongside a <Search>

* 🚧 wip

- fairly nicely working list of virtually focusable items
- API interface kept simple (moved pick to Anchor though, single "exit
  point")
- item has focus function now, which triggers when it gets virtual
  focus, the API should not distinguish between virtual and real focus
  was the thinking here, it's more an implementation detail.

* 🚧 WIP new story for Autocomplete

- showcase dropdown search autocomplete

* 🔥 refactor class -> attr, remove css, use user provided <style> in story

* Update @navikt/core/react/src/form/autocomplete/Autocomplete.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update @navikt/core/react/src/form/autocomplete/Autocomplete.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* 🔥 remove originial ideas for a prop on <Search>

* ♻️ refactor + use mouseMove over mouseOver

* 🐛 reset virtualfocus on input change (within Anchor)

* ✨ add prop 'loop' for Autocomplete

* 🚚 Autocomplete -> VirtualFocus

* 🚚 Autocomplete -> VirtualFocus

* 🔥 remove unused CSS

* 🚧 add onActive, delete unused code

* 🚧 rename CSS classes

* ♻️ simplify <VirtualFocus> impl

- use the descendants API > grabbing the DOM nodes...

* 🔥 remove the aria-activedescendant responsibility from VirtualFocus

* Update aksel.nav.no/website/sanity/config.ts

* 🔥 remove comments that no longer apply

* 🔥 remove biome.json changes from PR

* ♻️ various PR changes

- homogenize the API (so both anchor and item have the sameish props,
  onActive, pick...)
- use useId() so multiple <VirtualFocus> on the same page get unique ids

* 🚧 + ♻️ testing changes in VO

- it's not great, weird behaviour on readouts of Items... (FF completely
  broken, sometimes reads "rgla" from "hourglass", other times nothing,
  Chrome is a little better)
- is this a decent API at all? is it overcomplicated?

* 🏷️ type itemRole

* 🔥 remove empty file

* ♻️ pr comments

- renaming to better match the rest of DS
- remove itemRole (just use role)
- eslint ignore

* ⚡ do not go via descendant API if self

* 🎨 add forwardRef & ...rest to Content

* 🐛 fix lying prop doc comment, remove unused CSS class

* ♻️ use <Slot /> (hoistmerge child)

* 💄 fix broken CSS (class was removed)

* 📝 update jsdoc

* 🚚 move role to Anchor (from VirtualFocus wrapper)

* 🎨 remove filtering from broken example

* 🐛 Anchor should trigger virtualfocused.onSelect()

* 🐛 use react v17 shimmed useId()

* Update @navikt/core/react/src/form/virtualfocus/VirtualFocus.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* 🚧 import

* 🎨 improve story

* 🐛 do not let consumer overwrite certain VirtualBox implementation

* 🎨 update story

* 🚚 move virtualfocus to utils

* 🎨 update to latest RovingFocus.tsx, tweaks to stories

* Update @navikt/core/react/src/util/virtualfocus/VirtualFocus.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🎨 improve docs (jsdoc), add Simple story

* 🚚 split up monster component into /parts

* 🐛 pull out dependency to remove cyclic dependency

* 🔥 RovingFocus.tsx

* 🐛 do not ignore external prop

* 🎨 simplify function calls + reorder for consistency

* 🔥 remove unused code

* 🎨 disable chromatic for internal tool stories

* 🏷️ Omit<> props that will get ignored/overridden

* 🏷️ Omit<> props that will get ignored/overridden

* 🏷️ use satisfies

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-06-28 15:56:54 +02:00
github-actions[bot]andgithub-actions[bot] 1aea10573c Version Packages (#3037)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-06-28 12:42:02 +02:00
Halvor Haugan 7c644cd9b1 Modal: New prop for aligning modal to top (#3033) 2024-06-27 13:58:45 +02:00
Halvor Haugan fe93f6450b Adjust examples and JSDOC for Alert (#3035) 2024-06-27 13:54:46 +02:00
github-actions[bot]andgithub-actions[bot] 86e52df680 Version Packages (#3013)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-06-25 15:39:57 +02:00
Halvor Haugan ff8072e352 Icons: FigureCombination icon adjusted (#3031) 2024-06-25 12:32:37 +02:00
Julian Nymark 5b033ab218 ✨ start formatting with biome too (#2991) 2024-06-25 12:27:35 +02:00
Halvor Haugan 6276b676d6 [aksel.nav.no] Validate unique title in exampletext_block (#3024) 2024-06-25 09:52:07 +02:00
Halvor Haugan c2ffd466af Update link in form templates (#3022) 2024-06-24 15:03:36 +02:00
Andreas Nordahl d6d6fb06b1 start align link items (#3026) 2024-06-24 13:05:47 +02:00
Halvor Haugan e829753847 Example of Alert with buttons (#3019) 2024-06-24 13:01:27 +02:00
Ken f1d8e9c4d3 feat: New icon ChildHairEyes (#3020) 2024-06-24 11:56:18 +02:00
Halvor Haugan 4d0f8067b7 Adjust examples of Chips 2024-06-24 10:00:34 +02:00
Halvor Haugan 4afe90122b Add Chromatic modes on some templates (#3023) 2024-06-24 09:23:49 +02:00
Halvor HauganandKen 350dfd3477 Adjust buttons in form summary page template (#2999)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-06-20 14:00:18 +02:00
Ken 9a74fecbfb fire: Removed old testing-templates (#3011) 2024-06-20 13:57:33 +02:00
Ken 7ec73f2008 [ToggleGroup] Selecting already selected value avoids sending extra onChange (#3012)
* feat: Selecting already selected value avoids sending extra onChange-event

* Update @navikt/core/react/src/toggle-group/ToggleGroup.stories.tsx
2024-06-20 13:55:34 +02:00
Halvor Haugan 952655ed63 Refactor templates (#3017) 2024-06-20 13:51:15 +02:00
Halvor Haugan 6af8cc526f Adjust examples of Chips (#3016) 2024-06-20 13:49:18 +02:00
Halvor Haugan 23ea3232fa Alert: Misc. adjustments (#3007) 2024-06-20 13:43:09 +02:00
b38789b98d Implement BasePrimitive for Box, Stack and HGrid (#3003)
* feat: Implemented baseprimitive in box

* refactor: segmented box-features into classes

* feat: Implemented baseprimitive margin css

* refactor: Correctly allow box with no children when no asChild is used

* refactor: Implement BasePrimitive on Stack/HGrid, addef as-prop for hgrid

* typo: Rename constant to a more 'content' nameing convention

* bug: Fix slot-import

* 🚧 --__ac-r-m.*

* bug: Fixed nesting of className

* feat: BasePrimitive now supports auto

* memo: Changeset

* bug: Added margin auto support for marginBlock

* refactor: Redo naming of base props

* bug: Typo

* bug: Wrong css-token reference for pi and pb

* Update @navikt/core/react/src/layout/base/BasePrimitive.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/layout/base/BasePrimitive.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* bug: Removed static padding representation

* Update @navikt/core/react/src/layout/base/BasePrimitive.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* refactor: Renamed AsChildProps used in Primitives

* bug: Re-added fallback to padding/margin when using a subset of breakpoints for inline/block

* Update @navikt/core/react/src/layout/base/BasePrimitive.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* memo: JSDoc

* refactor: Removed undefined as-props from docgen

---------

Co-authored-by: Julian Nymark <julian.nymark@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-06-19 11:17:08 +02:00
Halvor Haugan cb304d0bb6 Add example of horizontal radios (#3009) 2024-06-19 09:33:14 +02:00
github-actions[bot]andgithub-actions[bot] 1dc3e43c6f Version Packages (#2981)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-06-19 09:16:54 +02:00
Halvor Haugan 50afa6f535 Adjust exampels of Tag (#3006) 2024-06-14 14:08:55 +02:00
Ken 5753acd5c1 refactor: Fixed no-double-equals biome (#3002) 2024-06-14 11:02:52 +02:00
KenandHalvor Haugan ff1e8b1140 refactor: Fixed no misleading character class biome (#3001)
* refactor: Fixed no misleading character class biome

* bug: Add lint ignore rule to support nextjs

* Update aksel.nav.no/website/sanity/schema/util.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-06-14 10:49:05 +02:00
Ken 60ad18804a feat: Added version-tag to tokens (#2998)
* feat: Added version-tag to built tokens-lib

* feat: Avoid duplicate version-tags

* refactor: Changed --aksel -> -a when adding version-tag
2024-06-13 11:27:57 +02:00
Ken dda89c8a0d bug: BasePrimitive imported 'Slot' from wrong dir 2024-06-13 10:04:43 +02:00
Ken 623fbba362 🚚 Moved Slot into separate directory (#2959)
* refactor: Moved slot to single folder

* refactor: Updated use of Slot in system

* refactor: Rename SlotElement -> SlottedElement

* refactor: Removed slottedElement

Because of typing issues when using anything other than 'div', this added more complexity than needed at this stage
2024-06-13 09:54:33 +02:00
KenandHalvor Haugan 221f7c5d61 [Primitives] BasePrimitive (#2842)
* 🎉 Boilerplate for BasePrimitive

* feat: Lagt til height og width attrb

* test: Chromatic snapshot av height & width api

* feat: Position API

* feat: Overflow

* feat: Flex

* memo: Prop-comments

* refactor: children now React.ReactElement in BasePrimtive

* bug: removed comment strangler

* Update @navikt/core/react/src/layout/base/BasePrimitive.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* memo: Updated stories

* refactor: remove use of backtick

* Update @navikt/core/react/src/layout/base/BasePrimitive.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/layout/base/BasePrimitive.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/layout/base/BasePrimitive.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/layout/base/BasePrimitive.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-06-12 13:57:03 +02:00
Ken 82f9c30936 [Aksel.nav.no] Fixed clipping of focus-border in toc (#3000)
* bug: Fixed clipping of focus-border

* refactor: removed addition of padding-block in sidebar
2024-06-12 13:51:11 +02:00
Halvor HauganandKen e35ddd5282 [aksel.nav.no] Add possibility to import code in examples (#2970)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-06-11 12:47:00 +02:00
KenandHalvor Haugan 5b70a84674 feature: ToggleGroup icon and label-props replacing children. (#2929)
* refactor: ToggleGroup now supports label and icon-prop

* memo: changeset

* bug: Fixed render of default story

* Update @navikt/core/react/src/toggle-group/parts/ToggleItem.tsx

* Update @navikt/core/react/src/toggle-group/parts/ToggleItem.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update .changeset/tiny-lions-stare.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* doc: Added separate stories for group and item-labels in togglegroup

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-06-11 11:42:13 +02:00
KenandHalvor Haugan ce9da16147 update: Migrated to v9 of next-sanity (#2923)
* feat: API-routes for entering draftmode in nextjs

* feat: Grunlleggende now uses the new livequery-API

* feat: New preview for frontpage

* feat: New preview for standalone-pages

* feat: New preview for blogg

* feat: New preview for prinsipper

* feat: New preview for monster-maler

* feat: New preview for komponenter

* feat: New preview for god-praksis

* fire: Removed code from different PR

* refactor: default export syntax cleanup

* bug: Fixed colorScheme handling for studio

* bug: Added back global styling changes

* types: Better typed query-params for PagePreview

* refactor: typo with KomponentFrontpage in god-praksis

* refactor: Moved client definition out from livequeryprovider -> sanity client config

* Update aksel.nav.no/website/pages/komponenter/[...slug].tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* refactor: Removed select + valid from groq in prinsipp

* refactor: __props -> previewProps for more declarative naming

* refactor: Remove use of memo

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-06-11 11:41:12 +02:00
Halvor Haugan bed7db15c4 Fix error message when starting Storybook (#2994) 2024-06-11 09:36:29 +02:00
Halvor Haugan feff5ff5e4 [aksel.nav.no] Convert client.server.js to ts (#2993) 2024-06-11 09:15:48 +02:00
Halvor Haugan 8a338851b4 [aksel.nav.no] Fix React warning in Snippet (#2992) 2024-06-10 09:32:33 +02:00
Halvor Haugan a7bd3894ca Split BackgroundToken into BackgroundColorToken and SurfaceColorToken (#2990) 2024-06-07 15:11:14 +02:00
Ken 1b927d6396 feat: Synced button icon size with CopyButton (#2984)
* feat: Synced button icon size with copybutton

* bug: Added min-width to button small
2024-06-07 12:23:13 +02:00
Ken 96ed611e15 List spacing (#2979)
* WIP: List spacing

* test: Added spacing-story test for list

* feat: Updated List with new spacing and Typo-elemenet

* refactor: Changed to spacing-2

* refactor: Updated nest list spacing

* bug: Reverted change in gap between icon and text

* bug: Fixed marker height

* Update .changeset/strong-bulldogs-jam.md
2024-06-07 12:00:19 +02:00
KenandHalvor Haugan a23621d0b0 refactor: Fixed noShadowRestrictedNames lint-errors (#2982)
* refactor: Fixed noShadowRestrictedNames lint-errors

* bug: Fieldset error-story broke

* Update @navikt/core/react/src/form/confirmation-panel/confirmation-panel.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/form/fieldset/fieldset.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/form/fieldset/fieldset.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/form/textfield/text-field.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/form/select/select.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* refactor: synced new story-names

* refactor: Fixed noAssignInExpressions lint-errors (#2983)

* refactor: Fixed noAssignInExpressions lint-errors

* Update @navikt/core/react/src/util/i18n/get.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* refactor: added dialog-polyfill to biome ignorelist

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-06-07 11:58:52 +02:00
Halvor HauganandKen 395eea108f Improved JSDOC for background and borderColor in Box and Page (#2988)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-06-07 11:32:18 +02:00
Ken 2e4351cced refactor: Removed surface-subtle from background-prop (#2987) 2024-06-07 11:27:53 +02:00
Ken f1707fe057 feat: Added prop for hidden heading to allow screen-readers to navigate to pagination (#2976)
* bug: Omit page-prop from PaginationItem and add data-attrb

* feat: Added prop for hidden heading to allow screen-readers to navigate to pagination

* refactor: Revert change of page-attrb removal since it could be breaking

* refactor: Fixed GH PR-comments

* refactor: Changed heading -> srHeading

* refactor: Modernized pagination-story

* refactor: Change to aria-labelledby, update stories
2024-06-07 11:26:21 +02:00
Ken ba76356178 Workflow update to node 20 (#2980)
* refactor: use github checkout v4

* refactor: use setup-node v4, default node 20

* workflow: Updated workflows to use node 20

* bug: removal of node-version in setup-node broke tests

* refactor: Revert removal of node-version in setup node for all workflows

* memo: Fixed typo in workflow-name
2024-06-06 09:37:21 +02:00
Ken 4c7de30732 memo: Edit broken docs-link in changelog 2024-06-05 14:39:18 +02:00
Ken 99ea2fa022 memo: Edit broken docs-link 2024-06-05 14:38:10 +02:00
Ken d5818a5e60 design: Copybutton-icon is now 20px for small og xsmall sizes (#2977)
* design: Copybutton-icon is now 20px for small og xsmall sizes

* bug: Replace aspect-ratio for min height/width with regular min-width and min-height attrb
2024-06-05 13:50:41 +02:00
KenandHalvor Haugan d0debc10ab feat: Added description-prop for fileupload item (#2975)
* feat: Added description-prop for fileupload item

* Update @navikt/core/react/src/form/file-upload/parts/item/Item.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-06-05 12:09:26 +02:00
KenandHalvor Haugan 5b011192f7 feat: Added option to use quotes in sanity editor (#2962)
* feat: Added option to use quotes i sanity editor

* Update aksel.nav.no/website/sanity/schema/objects/shared/riktekst.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-06-05 12:07:21 +02:00
github-actions[bot]andgithub-actions[bot] 754d151a7f Version Packages (#2972)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-06-05 11:32:10 +02:00
Ken 677170a767 update: Updated svgr cli to v8 (#2930) 2024-06-05 11:19:22 +02:00
Ken 2cd6b1a391 bug: Icon-package missed src-dir referenced in sourcemap (#2978) 2024-06-05 10:09:53 +02:00
Ken 5bcb870b16 bug: Etterlevelse-link in footer had wrong ingress 2024-06-04 11:29:49 +02:00
Halvor Haugan 704e4f6c77 Adjust examples of Pagination (#2973) 2024-06-04 09:57:27 +02:00
Halvor Haugan 334627061a 💄 Remove bottom margin on last item in Stepper and adjust FormProgress accordingly (#2971) 2024-06-03 14:32:05 +02:00
github-actions[bot]andgithub-actions[bot] c171a73d2f Version Packages (#2969)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-05-31 14:14:07 +02:00
Lars Eirik Korsgaard Hansen 1cab3698b1 Modal small (#2909) 2024-05-31 14:06:27 +02:00
Halvor Haugan b9fb86cc27 Real examples of form summary pages (#2967) 2024-05-31 12:20:46 +02:00
github-actions[bot]andgithub-actions[bot] ceaedc4505 Version Packages (#2933)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-05-31 08:43:12 +02:00
Vegard HaugstvedtandHalvor Haugan 394cc94db7 Fixed Combobox small sizing (#2801)
* Remove extra vertical padding and fixed height for combobox input, to make the small variant the same size as TextField and so on.

* no message

* More robust combobox styling - using tokens and proper padding instead of min-height for sizing

* More robust combobox styling using tokens

* Remove gap between options in FilteredOptions

* Update @navikt/core/css/form/combobox.css

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Combine selectors for svg sizes in combobox

Removed pointer-events: none, because I couldn't find a use-case for it. The reason vanished when we squashed commits.

* Fix visual regression, where the first option was partially overlapped by the "max selected" message

* Revert yarn lock to match main

* A general selector for combobox SVGs had an effect on chips as well, so we need a selector for each SVG we want to set size for.

* Properly align items in FilteredOptions. Fixes issue with out-of-alignment checkmarks.

* Fix incorrect class selector

* This doesn't seem to do anything

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-05-29 11:32:24 +02:00
Halvor Haugan af171a3ffc New template: form summary page (#2958) 2024-05-29 09:23:13 +02:00
Halvor Haugan 868170ef38 List: Adjusted examples and JSDOC (#2961) 2024-05-28 14:32:24 +02:00
Ken 01d2ee85d0 move: Moved dismissablelayer into overlays dir from overlay dir (#2960) 2024-05-28 14:14:53 +02:00
KenandHalvor Haugan 50d594787c Disallow use of implicit any type on variable declarations. (#2943)
* feat: Added biome again

* bug: Fixes Disallow use of implicit any type on variable declarations.

* refactor: Import as type

* refactor: Reverted change to typed for-loops in dialog-polyfill

* refactor: Reverted change to typed for-loops in dialog-polyfill

* Update @navikt/core/react/src/modal/dialog-polyfill.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* refactor: biome-ignored inline-typing for-loop

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-05-27 14:05:07 +02:00
Ken 8d0f7ae4b5 Use Array.isArray() instead of instanceof Array. (#2942)
* feat: Added biome again

* bug: Fixes Use Array.isArray() instead of instanceof Array.
2024-05-27 13:58:52 +02:00
Ken f23fd9aa83 Removed useless if/else (#2939)
* feat: Added biome again

* feat: Fixed noUselessElse

* feat: Added original eslint-rule
2024-05-27 13:54:39 +02:00
Ken 1a18bbedbb [Sanity] Fixed view for "Mine utkast" and creation of new undertema (#2957)
* bug: Mine utkast did not correctly handle letter casing for email

* bug: Declaring schemaType after initialTemplates removes initialTemplates
2024-05-27 13:29:28 +02:00
Halvor Haugan b7ddb9e557 [aksel.nav.no] Add ShowMore to ExampletextBlock (#2950) 2024-05-27 11:32:54 +02:00
Ken 1f3df8ad93 feat: New icons for geometric shapes (#2927) 2024-05-27 11:16:49 +02:00
Halvor Haugan 7c339c6dc6 🐛 Modal: Fix issue where polyfill-classname was not applied when using SSR (Next.js) (#2954) 2024-05-27 11:15:11 +02:00
Ken 61de6853e3 ⚡ Performance improvements when using spread in reduce (#2937)
* refactor: Fixed type-errors

* refactor: Optimized omit

* refactor: Optimize search-grouping on website

* refactor: Optimize option grouping in combobox

* refactor: Optimize reduce-functions in systems
2024-05-27 11:14:29 +02:00
Ken f05615d373 Use Number.isNaN instead of global isNaN. (#2941)
* feat: Added biome again

* bug: Fixes isNaN is unsafe. It attempts a type coercion. Use Number.isNaN instead.
2024-05-27 09:52:02 +02:00
Ken 34cdf015ff [Website] List-component in place of custom ul>li (#2928)
* feat: Uses List-component internally in website

* fire: Removed old CSS for list-styling

* fire: Undid change to example made under testing
2024-05-27 08:56:20 +02:00
Halvor Haugan f48178de22 Adjust docs for Chat and some primitives (#2948) 2024-05-24 11:12:51 +02:00
Halvor Haugan fcfbad9b90 Use <Link> instead of <a> in Accordion examples (#2952) 2024-05-24 11:07:45 +02:00
Ken dfef7f5c76 Use Number.isFinite instead of global isFinite. (#2940)
* feat: Added biome again

* bug: Fixed isFinite is unsafe. It attempts a type coercion. Use Number.isFinite instead
2024-05-23 09:43:19 +02:00
Vegard Haugstvedt 5a60ac9ae1 Form intropage adjustments (#2949)
* Remove sandbox from intropage templates. It doesn't work, because of the URI length.

* Remove form id from the concrete examples

* Rename default template from "Introside" to "Standard"

* VStack is no longer necessary when we remove the form id

* Merged the real examples into one folder, so they can be added as one block (using chips) instead of after each other
2024-05-22 16:09:43 +02:00
Halvor Haugan 2e233e6a3f ♻️ Refactor form intro template (#2946) 2024-05-22 15:48:43 +02:00
Halvor Haugan c2d010e81d Include templates in ds storybook (#2947) 2024-05-22 15:34:13 +02:00
Ken 70dc5f18d1 refactor: Optimized omit (#2936) 2024-05-22 14:57:32 +02:00
Ken 0b79be7db1 refactor: Updated 30% of examples to primitives (#2932) 2024-05-22 14:35:23 +02:00
62dd6a321c Feature/template intropage (#2876)
* Init intropage. Just with header and guidepanel in first commit. The rest will follow.

Needs to move icon in header outside main column.

* Add "what can i apply to here" content, as well as prepare the page for more of these sections.

* Add "this is how you apply"-section

* Add confirmation checkbox and "start application" button

* Add "extra information" accordion

* Add language selector and switch to simple decorator

* Correct icon and placement for "start application" button

* Proper pictogram in FormHeader and bleed outside of the main column.

* Make Intropage header responsive, moving pictogram to the right on mobile/on the left on desktop

* Add IntroPage story to regular Storybook, so it is exposed through Chromatic

* Temporarily add ApplicationPictogram in same folder as template to make it available for demo tomorrow. Needs to find another place.

* Simplify/extract code for decorator

* updated texts according to Figma

* Center align title and form id with pictogram, to better support not showing the ID

* Update intro page standard template

* Update Stack direction type to support reverse order

* Add examples for alert and alternative applications. Need to clean up some TS-error later.

* Update Aksel examples for intropage

* Rename folder for intropage examples

* Use BodyLong instead of BodyShort

* Add specific examples for intropage

* Style fixes: add gutters to content (like header) and make sure a longer title does not take space from pictogram

* Update aksel.nav.no/website/pages/templates/soknad-introside/intro-med-alternativ-soknad.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Hide pictogram on the smallest screens, and keep it on the right side up until "lg"  screens (compared to "md" before)

* Correct heading level

* All the content should be inside main

* Replace <Box> without any props with regular div's

* Replace "flex: 1" from heading-stack in every layout with flexShrink: 0 on only the pictogram

* Hide SVG's from screen readers

* Missing <Show>-element

* Keep pictogram on the right until the screen is at least of size "lg"

* Change the data-aksel-template attribute to allow proper tracking of intropage template use

* Changed texts after feedback from Sjur

* Legg til meta.json for changelog i form-introside-mappen

* Use standard padding between content and footer, but increase it to spacing-16 (4 rem) to reflect Figma and the documentation

* Remove template from Chromatic. May add templates to Chromatic-build later, but that should be done by watching templates on Aksel-webpage.

* Remove unused util for decorator

* Inline decorator-kode in all form intropage templates. Otherwise, they won't be included in the example code.

* Inline application pictogram in form intropage templates, so it can be copied. Maybe we should extract the form header as a component in Aksel?

* Remove spacing from BodyLong inside of Accordion

* Update aksel.nav.no/website/pages/templates/soknad-introside/intro-med-alternativ-soknad.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Removed duplicate word

* Added changeset for ds-react and ds-css changes

* Update aksel.nav.no/website/pages/templates/soknad-introside-alderspensjon/soknad-introside-alderspensjon.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Fix alignment and placement in form header

* Move template tracking id further into the code, so it is not excluded by accident

* Title and other props are unnecessary on ApplicationPictogram, since it has aria-hidden set

* Remove title from single examples (only in folder), since it is not used, and use 0-index on all form intropage examples

* Align pictogram to the top of the title

* Reduce gap between sections from 3rem to 2rem

* Align pictogram to the top of the title for the rest of the templates

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-05-21 16:02:13 +02:00
Ken 88c26d2c70 bug: Fixed All exports are only types and should thus use export type 2024-05-16 18:29:50 +02:00
Ken 201fd75c0c bug: Fixed void is not valid as a constituent in a union type 2024-05-16 18:28:09 +02:00
Ken cbc512832c bug: ExampletextBlock used wrong bg-color 2024-05-16 12:54:13 +02:00
Ken 9d815adab2 bug: ExampletextBlock had no background on God-praksis pages 2024-05-16 12:40:41 +02:00
Ken 1800b2b34d feat: GodPraksis can now use ExampletextBlock on all articles 2024-05-16 09:37:47 +02:00
Ken 93623ce355 bug: DismissableLayer broke when disabling disableOutsidePointerEvents (#2925)
* bug: DismissableLayer broke when disabling outsidePointerEvents

* refactor: removed old code

* bug: New useEffect implementation ignored enabled-flag

* feat: Removed unsafe_index prop used in stepper and replaced it with context

* memo: Added changeset

* Revert "memo: Added changeset"

This reverts commit 03d7dc6bb8.

* Revert "feat: Removed unsafe_index prop used in stepper and replaced it with context"

This reverts commit 14c316f4a3.

* bug: Pointer-state were not corretly updated

* test: Demo setup in storybook

* bug: Fixed body-styles handling and pointerEvents on element

* refactor: Simplified expression for pointerEvents

* refactor: Removed extra state for pointer-state
2024-05-15 17:35:44 +02:00
Ken aed321728f feat: Removed unsafe_index prop used in stepper.step (#2926)
* feat: Removed unsafe_index prop used in stepper and replaced it with context

* memo: Better errormessaging

* refactor: Resolves PR-comments
2024-05-15 16:31:13 +02:00
Ken 8003fd2222 bug: templatesKategorier used wrong value for soknadsdialog 2024-05-15 15:40:31 +02:00
Ken 32c8bab6f9 update: Updated categories for new template-structure (#2931) 2024-05-15 15:30:18 +02:00
KenandHalvor Haugan 7527cbe07f sanity: removed scheduling (#2924)
* feat: Removed scheduled publishing from sanity, fixed type-errors

* bug: Wrong type for devOnly callback

* bug: removed sideeffect added when developing

* Update aksel.nav.no/website/sanity/schema/custom-components/InputWithCounter.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-05-15 11:33:32 +02:00
Ken 57a6a18dbe feat: API-routes for entering draftmode in nextjs (#2922) 2024-05-15 09:37:13 +02:00
github-actions[bot]andgithub-actions[bot] 7b691b6cd0 Version Packages (#2916)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-05-14 15:29:55 +02:00
Ken 1b048ba5c3 refactor: removed unsplash plugin from sanity media input (#2921) 2024-05-14 11:31:45 +02:00
Ken e92c897c01 update: New sanity versions (#2918)
* update: New sanity versions

* update: Bump canary-release of devDeps for nextjs

* sync: yarn lock
2024-05-14 10:15:52 +02:00
Halvor Haugan a1041d13cd Stepper.Step: Set aria-current to "step" instead of true (#2920) 2024-05-14 10:14:35 +02:00
Ken 241dd79ecb Block to show template/standard-texts on template-pages (#2913)
* feat: Standard highlighting komponent

* feat: Immplementert StandardHighlight i CMS

* refactor: Rename StandardHighlight -> ExampletextBlock

* memo: Riktigere initialValue
2024-05-14 09:40:59 +02:00
Halvor Haugan 6aaf56bc10 Adjust examples FormProgress 2024-05-13 15:54:23 +02:00
Ken 7becf3e4cf Simplified HGrid CSS-nesting (#2917)
* test: Setup testing env for HGrid bug

* refactor: Forenklet HGrid-css

* memo: Changeset
2024-05-13 14:39:41 +02:00
Ken a358d222b5 refactor: Removed extra w-fit left after refactor 2024-05-13 13:53:13 +02:00
Ken 24d4d48c87 Link to GH-discussions from template-pages (#2914)
* feat: New gh-discussions field for template-articles

* feat: Link to gh-discussions on template-pages

* refactor: removed extra display grid in wrapper

* feat: Added story for GHPages suggeestionBlock
2024-05-13 12:27:49 +02:00
Ken 2d0c2c6567 deps: Updated Nextjs and logging depdendencies (#2915) 2024-05-13 11:36:32 +02:00
Halvor Haugan bd482c5d3e Ny komponent FormProgress (#2855) 2024-05-13 10:30:28 +02:00
github-actions[bot]andgithub-actions[bot] c8c3fc4ec5 Version Packages (#2896)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-05-10 14:37:43 +02:00
Andreas Nordahl 834ba0cbae Decouple read-more icon hover offset and rotation style (#2912) 2024-05-10 13:53:03 +02:00
KenandHalvor Haugan be653cc67a [Aksel.nav.no] Mindre justeringer på Søk (#2899)
* refactor: Fjernet tags fra søk

* design: Oppdatert padding for søk og la tilbake border på focus

* refactor: Fjernet lenketags fra komponent-artikler

* design: Oppdatert fokusmarkering og hover for search-hit

* bug: Mobiltilpasset søk-headings

* bug: e2e-tester fant ikke søkefelt

* bug: Seksjoner i søk har nå riktig heading-level h2

* Update aksel.nav.no/website/components/website-modules/search/parts/Hit.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* refactor: Quotes i søk får samme farge

* Update aksel.nav.no/website/components/website-modules/search/parts/Results.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* refactor: Unødvendig filtrering basert på dokumenttype er fjernet

* bug: Bruker section-element for gruppering av søkeresultater

* refactor: Unødvendig filtrering basert på dokumenttype er fjernet

* bug: Border forsvant ved pointerdown

* refactor: Hides image-frame from serch-hit

* Revert "refactor: Hides image-frame from serch-hit"

This reverts commit 764c82ebdb.

* refactor: Truncate title

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-05-08 10:08:57 +02:00
Halvor Haugan 054835d1dd 🆙 Oppgradert deps (#2908) 2024-05-08 09:53:14 +02:00
Ken 7f99d407c0 Combobox refactor: Flyttet Input controls ut i egen komponent (#2900)
* refactor: Flyttet Input controls ut i egen komponent

* refactor: Inlinet clearbutton implementasjon, fikset typer

* 🚚 Flyttet ToggleListButton til input-mappe

* Combobox refactor: Bruker intern `createContext` for context-creation i Combobox (#2902)

* refactor: Bruker egen creactContext for selectedOptionsContext

* refactor: Bruker egen creactContext for filteredOptionsContext

* refactor: Bruker egen creactContext for InputContext

* refactor: Bruker egen creactContext for selectedOptionsContext

* refactor: Rename InputContext hook

* 🚚 Flyttet testfiler inn i egen mappe (#2905)
2024-05-08 09:05:02 +02:00
Ken 1202e0a6f7 bug: InitialValues for god-praksis struktur i admin ga ikke riktige tilganger 2024-05-07 18:22:56 +02:00
0c06fa12d0 Progressbar tweaks (etter docs-møtet) (#2892)
Co-authored-by: Julian Nymark <julian.nymark@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-05-07 14:36:11 +02:00
Lars Eirik Korsgaard Hansen 4797ccae9d Combobox: Remove 'Ingen søketreff' when custom options allowed (#2895) 2024-05-07 11:41:01 +02:00
Ken ac06d882a7 refactor: Forenklet mergeRefs i floating-util 2024-05-07 09:57:20 +02:00
Ken 8f5c956bad Floating utility (#2872)
* ✨ Initial Popper wrapper

* ✨ Floating popper element

* 🏷️ Rename popper -> floating

* 🐛 Fikset imports

* ♻️ FLoating-fil splittet opp i moduler

* 🎨 Satt opp exports og story

* 🎨 Arrow er nå del av content

* 🐛 display block på arrow

* 🎉 Egen Portal-komponent

* 🎨 Portal og Overlay exportert i root

* ♻️ Tooltip bruker egen Portal

* 📝 Changeset

* 🔀 Merge Portal

* 📝 Story with portal

* 📝 Props story

* 🚚 Temp rename

* 🚚 Temp rename

* 🎨 La til Slot på Floating.Anchor

* ✨ Fungerende nesting av dismissable items

* ✨ Fungerende outsidepointerclick handler

* 🚚 Ryddet opp i struktur

* ✨ bedre event-handling

* 🎉 Popover bruker dismissableLayer

* 🔥 Fjernet console.logs

* ♻️ Extender nå ikke htmldivelement

* 📝 Commented on dimsissablelayer

* 📝 Kommentarer

* 🎨 Disable pointer-events on body

* 🎨 Setup content

* 🎨 Fungerende popover med story

* 🎨 useDescendant-API kan bruke uten context-error på nesting

* 🐛 Fikset tilfeller der oppdatering av descendant-options ikke ble reflektert i descendants-map

* 🐛 Satte enabled til optional

* bug: import av Portal brakk stories for Popover og Floating

* bug: DescenadantContext er nå riktig typet som undefined

* label: scopet navn for bruk av descendant-provider i dismissablelayer

* memo: Bedre kommentarer

* feat: Sender ikke callbacks hvis layer er disabled

* memo: Formatering og kommentarer

* memo: Kommentarer

* feat: Støtter forwardRef

* merge: Merge branch with main

* 🔥 Fjernet ny popover implementasjon

* 🔥 Fjernet mergeconflict fra main i tabs

* 🔥 Fjernet mergeconflict fra main i tabs

* refactor: Cleaniup codestructure

* refactor: Fjernet unødvendige props

* refactor: Synket dependencies og changeset
2024-05-07 09:56:06 +02:00
Ken 6b40a0ddd8 refactor: Oppdatert stories til chromatic format
refactor: Oppdatert HGrid stories til chromatic format

refactor: Oppdatert InternalHeader stories til chromatic format

refactor: Oppdatert skeleton stories til chromatic format

refactor: Oppdatert box stories til chromatic format

refactor: Oppdatert loader stories til chromatic format

refactor: Oppdatert list stories til chromatic format

refactor: Oppdatert tag stories til chromatic format
2024-05-06 16:28:12 +02:00
Halvor Haugan 60a6cba329 Justering av stories på Chat (#2903) 2024-05-06 14:24:23 +02:00
Ken 7fd62f3b79 logging: Fjernet logging av query i søk (#2897) 2024-05-06 11:50:02 +02:00
Ken 0944bbc256 DismissableLayer-API (#2814)
* ✨ Fungerende nesting av dismissable items

* ✨ Fungerende outsidepointerclick handler

* 🚚 Ryddet opp i struktur

* ✨ bedre event-handling

* 🎉 Popover bruker dismissableLayer

* 🔥 Fjernet console.logs

* ♻️ Extender nå ikke htmldivelement

* 📝 Commented on dimsissablelayer

* 📝 Kommentarer

* 🎨 Disable pointer-events on body

* 🎨 useDescendant-API kan bruke uten context-error på nesting

* 🐛 Fikset tilfeller der oppdatering av descendant-options ikke ble reflektert i descendants-map

* 🐛 Satte enabled til optional

* bug: DescenadantContext er nå riktig typet som undefined

* label: scopet navn for bruk av descendant-provider i dismissablelayer

* memo: Bedre kommentarer

* feat: Sender ikke callbacks hvis layer er disabled

* memo: Formatering og kommentarer

* memo: Kommentarer

* feat: Støtter forwardRef

* ♻️ Ryddet i DismissableLayer filer

* ♻️ Fikset edgecase der 'disabled'-noder kunne stoppe pointer-events

* refactor: Cleanup PR før release

* bug: useDismissableDescendantsContext ikke required
2024-05-04 15:15:15 +02:00
Ken 16087a458a refactor: DescendantContext er nå scopet (#2890)
* refactor: DescendantContext er nå scopet

* ♻️ Fjernet unødvendig wrapping
2024-05-04 13:34:34 +02:00
KenandHalvor Haugan c47c372d0f [Datepicker|MonthPicker] Flippet visning av år. (#2882)
* feat: DropdownCaption viser år i motsatt rekkefølge for select

* feat: Year-select for MonthPicker er viser nyeste år først

* memo: Changeset

* Update .changeset/thick-poems-design.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-05-04 13:33:59 +02:00
Ken 0c479831df bug: Nettsidebygg feilet ved bruk av fjernet prop 2024-05-02 13:27:50 +02:00
github-actions[bot]andgithub-actions[bot] 41e9fbd2a5 Version Packages (#2878)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-05-02 12:35:49 +02:00
Ken 7b25f30e60 🏷️ Fjernet referanse til duration i Progressbar for pre-release 2024-05-02 12:32:31 +02:00
Ken db9c858153 refactor: Radio og Checkbox bruker :focus for bedre synlighet når de blir lenket til fra ErrorSummary (#2893) 2024-05-02 12:18:49 +02:00
Julian Nymark b21015bf54 💄 fix for broken pin style (#2889)
* 💄 fix for broken pin style

As content (Rows) grows, the pin would get pushed down (and under) the content.

* changeset

* 💄 make css for timeline pin even more compact
2024-04-29 19:13:57 +02:00
Lars Eirik Korsgaard Hansen bac48d9057 Progressbar aria hidden (#2888) 2024-04-29 14:47:29 +02:00
Lars Eirik Korsgaard Hansen e1a85dfbeb Progressbar demo-fixes (#2887) 2024-04-29 12:40:09 +02:00
Lars Eirik Korsgaard Hansen 3f65eee9e9 Progressbar demos (#2885) 2024-04-29 10:53:02 +02:00
Halvor Haugan cd77198f1c [aksel.nav.no] Fiks anker i søketreff-lenker (#2884) 2024-04-29 09:02:58 +02:00
Halvor Haugan 82827ec712 Justering av eksempler på Label, Detail og ErrorMessage (#2883) 2024-04-29 09:02:34 +02:00
Ken 710ed83661 [Aksel.nav.no] Ny Meny for sidebar og TOC (#2873)
* 🎉 WIP for ny sidebar og TOC meny

* 💫 Animert farger

* 🎨 Støtte for nested menuitems

* 🎨 Støtter nå sidebar og toc-variant for farger

* ♻️ Migrert TOC til å bruke ny meny

* ♻️ Migrert Sidebar til å bruke ny meny

* 🐛 Fikset story

* ♿ Klikkhøyde nå minst 32px

* 💄 Justert bakgrunnsanimasjon fra 200ms -> 100ms

* Types: variant bruker semantiske navn

* bug: MenuLink ble brukt utenfor MenuLi
2024-04-26 07:58:47 +02:00
Ken 3b44a97725 design: Fallback/Alle tema piktogram er nå Aksel-logo (#2877) 2024-04-25 11:55:46 +02:00
Ken edcbd6e198 bug: Error-handling for oppretting av nye brukerprofiler i sanity (#2881) 2024-04-25 11:54:08 +02:00
Halvor Haugan bd3f9355eb storybook:aksel viser og sorterer nå på index på kodeeksempler (#2880) 2024-04-25 10:49:04 +02:00
Halvor Haugan f11bce1f8c Oppdater JSDOC og eksempler på Heading, BodyLong og BodyShort (#2879) 2024-04-25 10:16:00 +02:00
Lars Eirik Korsgaard HansenandHalvor Haugan 277525f39f ✨ Ny komponent: ProgressBar (#2845)
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-04-24 14:18:55 +02:00
Ken 210496c2cc bug: Validering av SEO-felt i sanity brakk ved undefined asset 2024-04-24 08:03:27 +02:00
github-actions[bot]andgithub-actions[bot] 8f317878fc Version Packages (#2875)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-04-22 15:48:59 +02:00
KenandHalvor Haugan c3064a01f7 🎨 Spacer er nå span (tidligere div) (#2874)
* 🎨 Spacer er nå span (tidligere div)

* 📝 Changeset

* Update .changeset/thick-humans-smile.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-04-22 15:32:57 +02:00
Ken 02f0a911b0 🔥 Fjernet gammel kode for god praksis og sanity (#2866)
* 🔥 Fjernet filtrering av aksel_tema

* 🔥 Fjernet gamle migreringer

* ⚰️ Fjernet aksel_tema og gammelt feedback-dokument

* ⚰️ Fjernet gammelt god praksis card

* ♻️ Gjenbruker nytt gp-card for relaterte artikler

* ♻️ Fjernet gamle typer

* 🔥 Fjernet referanser til gammelt feedback-dokument
2024-04-22 15:12:56 +02:00
Ken ee8524229f 🎨 Temakontakter får slack-melding gjennom tilbakemeldinger (#2869) 2024-04-19 13:36:16 +02:00
Ken d9932e203a [Sanity] Temakontakter visning (#2868)
* 🎨 Lagt til Temakontakter-felt i for gp.tema

* 🔥 Fjernet requirement for temakontakter

* 🎨 Visning for temakontakter
2024-04-19 12:58:14 +02:00
KenandHalvor Haugan b14fc23ecb [react] Collapsible component utility (#2859)
* ✨ Boilerplate for collapsible-component

* 🎨 Collapsible wrapper interface

* 🎨 Collapsible trigger interface

* 🎨 Collapsible content interface

* 🧪 Stories

* ♻️ Satt opp storybook for chromatic

* 📝 Satt opp exports

* 🧪 Open/defaultOpen tester for chromatic

* 📝 Kommentert props

* ♻️ Definerer data-state verdi på root

* 📝 JSDOC

* 📝 Disabled-demo

* ♻️ aria-controls blir bare satt når open

* ♿ Content controls button

* Update @navikt/core/react/src/collapsible/Collapsible.types.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ props -> rest

* ♻️ props -> rest

* ♻️ Omit unreachable props

* 📝 _id rename

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-04-19 12:27:55 +02:00
Ken c16f75d6f8 [Sanity] Temakontakter (#2867)
* 🎨 Lagt til Temakontakter-felt i for gp.tema

* 🔥 Fjernet requirement for temakontakter
2024-04-19 08:42:22 +02:00
Halvor Haugan a01be91608 Rekkefølge på eksempler på FormSummary 2024-04-18 13:05:21 +02:00
github-actions[bot]andgithub-actions[bot] 8826a79021 Version Packages (#2850)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-04-18 11:59:36 +02:00
Vegard HaugstvedtandKen c2f3da84cc Bugfix/prevent submit on enter in combobox (#2861)
* Prevent "Enter" key in Combobox to...

* Added test for Enter not submitting form

* Added changeset

* Add test for un-selecting a selected option using "enter" on a Chip not submitting the form

* Do not prevent enter from submitting form if it should not perform another action (like selecting an option)

* Do not submit when the input field has a value

* Replace lots of sleep-calls with awaiting userEvents

* Create util function for looking up an option

* Fix bug where we couldn't un-select a custom option using "enter"

* Update test to account for the dropdown list closing when focus moves to the chips in the previous step

* Add possibility to slow down tests for debugging

* Fix issue with onFocus -> onToggleSelected(false), where clicking the open/close button didn't work

* Fix test

* Closing the FilteredOptionsList when focusing a Chip caused too many side effects, but we need to remove virtual focus at least. That way we won't double-click on enter.

* When no longer closing FilteredOptions on focusing a chip, we don't need to click the toggleIsOpen button to check that the option is un-selected

* Update .changeset/rotten-windows-cover.md

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-04-18 10:00:16 +02:00
Ken 2c1476022d 🐛 Descendant-provider feilet ved bruk av cloneElement (#2832)
* 🐛 Når Descendant-provider ble brukt med react cloneElement feilet child-re-render

* ⚡ Synker options for allerede registrert node

* ⚡ Unngår flere map-lookups for samme funksjon
2024-04-18 09:55:34 +02:00
Halvor Haugan dacf648c47 FormSummary: Link til dokumentasjonen i JSDOC (#2865) 2024-04-18 09:06:29 +02:00
Ken 5ec986771b [God praksis] Nye sider erstatter gamle (#2858)
* 🚚 Byttet ut gamle god-praksis sider med nye

* ♻️ Sitemap bruker ny gp-struktur

* ♻️ Lister med tema tittler bruker nå nye tema

* ♻️ Flyttet gammel godpraksiscardsimple

* ⚰️ Markert gamle tema-felt i sanity som deprecated

* ♻️ Bedre håndtering av editor/profil visning

* ♻️ Velger nå ikke en default tab for sanity visning

* 🔒 ErrorBoundary på alle gp-cards

* 🧪 Storybook for frontpage-cards

* 🐛 Dialog var ikke riktig lablet

* 🐛 Chips-liste wrappet ikke button i li, cube-illustrasjon var ikke gjemt for skjermleser

* 🎉 Viser publiserings og oppdateringsdatoer i toppen av artikkel

* 📝 Bidragsytere -> Medvirkende

* 🐛 Playwright testet gamle god praksis sider

* 🐛 Preview brakk på forside og god-praksis

* 💄 HeroCards har større illustrasjon

* ♻️ Forenklet size på herocard

* ♻️ Innhold i herocard er alltid sentrert

* 🔍 Artikler har nå riktig fallback OG-image

* Update aksel.nav.no/website/e2e/test-urls.json

* 🏷️ bruker SanityImageSource for piktogram

* 🏷️ Tagget title i staticprops som deprecated

* 🔥 Fjernet testkode

* Update aksel.nav.no/website/sanity/plugins/structure/god-praksis.ts

* 📝 Skrivefeil i structure

* 💄 Oppdatert gap mellom tagger i cards
2024-04-18 07:28:08 +02:00
ca6af8a5f7 index & process templates -> stories (#2856)
* index & process templates -> stories

* ✨ add duplication of templates to component storybook

* 🎨 fix story

* ♻️ refactor indexers for storybook

* ♻️ layout fullscreen for templates

* 🔥 Fjernet meta.json filer

* ♻️ Trukket dekorator-kode ut av alle templates

* 🐛 Fjerner storybook stories fra npm output

* 🔥 Fjernet templates fra core/react

* 🔥 Fjernet console.log

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-04-17 13:46:58 +02:00
Ken 9410840f74 🐛 Fikset lenke i sanity (#2863) 2024-04-17 13:22:42 +02:00
Ken d88884f785 🔥 Fjernet content-container.css og grid.css fra _mappings (#2860)
* 🔥 Fjernet content-container og grid css fra _mappings

* Update .changeset/wet-books-end.md
2024-04-17 09:46:27 +02:00
Ken 0c8239ee00 🐛 EditorPreview knapp Sanity admin 2024-04-16 12:48:06 +02:00
Halvor Haugan 987118fd47 FormSummary.Heading: Fjern overridable, level oblig. og css-justeringer på <sm (#2857) 2024-04-16 10:34:27 +02:00
8d13f11689 Summary component (docs tweaks) (#2853)
* 🚧 wip on Summary

* ✨ new HR component

* 👔 fancy utility function to inject components into children

This is to be used in 2 places where we iterate over children and add <hr /> components between them all.

It also wraps the children in a <Box>, which is used here and not really reflected in the name of the function 🤔

* 🎨 improved version of Summary component

* Remove (some) magic

* Fix children type in injectHRBetween

* css

* header gap and bg

* responsive story + example with long texts

* 🚚 Summary -> FormSummary

* 🎨 update stories

* 🎨 update story + tweak CSS for EditButton

* 📝 add JSDoc

* export FormSummary in core/react/src/index.ts

* FormSummaryValue bruker BodyLong

* 📝 update JSDoc

* 📝 add demo

* 📝 update README.md for eksempler

* forwardRef på Answers

* forwardRef på Header

* forwardRef på Label og Value

* forwardRef på Heading og Edit

* Answer export

* spread props

* 🔥 remove HR component

* 📝 update JSDoc

* 🎨 export more FormSummary

* 🔥 duplicate dependency of _mapping (same as main)

* 📝 update JSDoc for FormSummary

* changeset

* 🔖 changeset

* 🔥 duplicate changeset

* Rename EditButton -> Edit

* oops

* Link er vel valgfritt

* 🐛 add correct CSS dependency for FormSummary

* 💄 FormSummary

* 💄 FormSummary

* className navds-form-summary

* className navds-form-summary__answers

* className navds-form-summary__header

* Update @navikt/core/css/form/form-summary.css

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update @navikt/core/react/src/form-summary/FormSummaryLabel.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update @navikt/core/react/src/form-summary/FormSummaryValue.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Header wrapper på små skjermer

* Rekkefølgen på selectors samme som DOM

* 🎨 structure consistency (ref, then ...rest, then className, then other things)

- also convert a props -> {not_the_rest, ...rest}

* update mappings

* Flytt border slik at du kan ha flere dd etter hverandre

* 🎨 update stories

* 🎨 update stories (more empty values)

* 🚚 story ComplexData -> RealisticUsage

* Mindre padding på små skjermer

* 🎨 update stories

* Answer forwardRef

* 🎨 update stories

* Eksempel på linjeskift i value i story

* 🎨 update story

* 🎨 update story

* 🚚 FormSummary -> Form/FormSummary

* 🎨 update Demo and story

* 🏷️ make href required for FormSummaryEdit

* 🏷️ + 🚧 typing woes

* 💄 tweak CSS to make it look just right

* 🏷️ correct typing using Exclude > Omit

* 🎨 use div over section without label

* 💄 FormSummary, last-child padding removal

* Fjernet kommentar

* typo i readme

* 🚚 FormSummary.Edit -> FormSummary.EditLink

* 🏷️ make href for EditLink optional

* 🚚 rename FormSummaryEdit -> FormSummaryEditLink

* FormSummaryEdit -> FormSummaryEditLink

* ✨ add example to FormSummary

* 🎨 update examples

* 🎨 update examples

* 💄 FormSummary

* 🎨 types + jsdoc tweaks (FormSummary)

* 🔥 remove aria-label example

* 🎨 separate example for grouped data

* 🎨 update desc for example

* 🔥 unused example code

* 🚚 rename examples

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-04-15 13:54:08 +02:00
Ken 158e18454e 🚚 gp-sider lenker nå til god-praksis (#2852) 2024-04-15 13:53:40 +02:00
Ken be26bf22c9 🔥 Fjernet redirect (#2851) 2024-04-15 13:35:36 +02:00
Ken c2968a0e6d 🎨 Artikler med contributors får automatisk editor (#2849)
* 🎨 Artikler med contributors får automatisk editor lagt til ved creation

* 🔒 Lager bare profil automatisk for SSO-inlogging
2024-04-15 11:16:27 +02:00
KenandHalvor Haugan 3f92773273 [Sanity] Oppdatert deskStructure (#2844)
* 🚚 Flyttet bloggvisning til egen fil

* 🚚 Flyttet grunnleggende visning

* 🎨 Sorterer 'trenger oppdatering' etter eldst først

* 🎨 Sorterer 'trenger oppdatering' etter eldst først i god-praksis

* 🚚 Flyttet komponenter visning

* 🚚 Flyttet admin visning

* 💄 Endret ikon for utdaterte artikler. Dynamisk treshold for utdatert

* 📝 Skrivefeil

* 🐛 Skrivehjelp-tittel hadde for lav kontrast på darkmode i sanity

* 🔥 Fjernet unødvendig currenUser check

* ♻️ Fikset PR-kommentarer

* Update aksel.nav.no/website/sanity/plugins/structure/structure.util.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 Sjekker mail for lowercase

* 🐛 email kan være undefined

* Update aksel.nav.no/website/sanity/plugins/structure/structure.util.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ Bruker innebygd showIcon-funksjon

* 📝 Bedre gruppenavn for seksjoner i sanity

* 💄 Ikoner på landigssider

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-04-15 11:15:17 +02:00
Ken 0c3ab1d0e7 [Sanity] Oppdatert utdatertvarsel (#2846)
* 🎨 innholdstype og undertema er nå required

* ♻️ Bruker eget panel for utdatert-warning i sanity

* ⚡ Bruker sanity useCurrentUser for å vise tilganger til bruker på profilside

* Update aksel.nav.no/website/sanity/schema/custom-components/EditorPage.tsx

* 🔥 Fjernet rest-spread
2024-04-15 11:12:32 +02:00
3a73a029f6 ✨ new FormSummary component (#2802)
* 🚧 wip on Summary

* ✨ new HR component

* 👔 fancy utility function to inject components into children

This is to be used in 2 places where we iterate over children and add <hr /> components between them all.

It also wraps the children in a <Box>, which is used here and not really reflected in the name of the function 🤔

* 🎨 improved version of Summary component

* Remove (some) magic

* Fix children type in injectHRBetween

* css

* header gap and bg

* responsive story + example with long texts

* 🚚 Summary -> FormSummary

* 🎨 update stories

* 🎨 update story + tweak CSS for EditButton

* 📝 add JSDoc

* export FormSummary in core/react/src/index.ts

* FormSummaryValue bruker BodyLong

* 📝 update JSDoc

* 📝 add demo

* 📝 update README.md for eksempler

* forwardRef på Answers

* forwardRef på Header

* forwardRef på Label og Value

* forwardRef på Heading og Edit

* Answer export

* spread props

* 🔥 remove HR component

* 📝 update JSDoc

* 🎨 export more FormSummary

* 🔥 duplicate dependency of _mapping (same as main)

* 📝 update JSDoc for FormSummary

* changeset

* 🔖 changeset

* 🔥 duplicate changeset

* Rename EditButton -> Edit

* oops

* Link er vel valgfritt

* 🐛 add correct CSS dependency for FormSummary

* 💄 FormSummary

* 💄 FormSummary

* className navds-form-summary

* className navds-form-summary__answers

* className navds-form-summary__header

* Update @navikt/core/css/form/form-summary.css

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update @navikt/core/react/src/form-summary/FormSummaryLabel.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update @navikt/core/react/src/form-summary/FormSummaryValue.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Header wrapper på små skjermer

* Rekkefølgen på selectors samme som DOM

* 🎨 structure consistency (ref, then ...rest, then className, then other things)

- also convert a props -> {not_the_rest, ...rest}

* update mappings

* Flytt border slik at du kan ha flere dd etter hverandre

* 🎨 update stories

* 🎨 update stories (more empty values)

* 🚚 story ComplexData -> RealisticUsage

* Mindre padding på små skjermer

* 🎨 update stories

* Answer forwardRef

* 🎨 update stories

* Eksempel på linjeskift i value i story

* 🎨 update story

* 🎨 update story

* 🚚 FormSummary -> Form/FormSummary

* 🎨 update Demo and story

* 🏷️ make href required for FormSummaryEdit

* 🏷️ + 🚧 typing woes

* 💄 tweak CSS to make it look just right

* 🏷️ correct typing using Exclude > Omit

* 🎨 use div over section without label

* 💄 FormSummary, last-child padding removal

* Fjernet kommentar

* typo i readme

* 🚚 FormSummary.Edit -> FormSummary.EditLink

* 🏷️ make href for EditLink optional

* 🚚 rename FormSummaryEdit -> FormSummaryEditLink

* FormSummaryEdit -> FormSummaryEditLink

* ✨ add example to FormSummary

* 🎨 update examples

* 🎨 update examples

* 💄 FormSummary

* 🎨 types + jsdoc tweaks (FormSummary)

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-04-15 09:53:42 +02:00
Halvor Haugan 6fd0f501f5 Story med forced-colors på Button (#2847) 2024-04-15 09:24:07 +02:00
Ken a11b8ddf4e 🐛 Dokumentert bruk av full og overflow-x av bleed 2024-04-12 14:51:45 +02:00
Ken 171db6a813 [Sanity] Flyttet dev-område for ny god-praksis inn i "prod" (#2843)
* 🚚 Flyttet gp-taxonomy over til prod

* 🎉 Satt opp ny sanity-struktur for god-praksis

* 🔥 Fjernet gammel editor-visning

* 🎉 Oppdatert templates for ny sanity-visning av gp

* 🔥 Fjernet god-praksis-taxonomy struktur

Struktur er nå flyttet inn i main
2024-04-12 08:25:00 +02:00
github-actions[bot]andgithub-actions[bot] 085cc532ee Version Packages (#2839)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-04-11 12:21:05 +02:00
KenandHalvor Haugan deae4ecba5 Datepicker/MonthPicker required bugs (#2838)
* 🐛 Required-prop på monthpicker stoppet ikke de-select av valg

* 🧪 Tester required for datepicker

* 🔥 Fjernet console.logs

* 📝 Changeset

* Update .changeset/fifty-hairs-fix.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/date/datepicker/datepicker.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🔥 Disabled-attrb er ikke nødvendig i required demo

* 🐛 Satt defaultSelected-dato til statisk dato

* ♻️ Fjernet unødvendig required-sjekk

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-04-11 11:55:27 +02:00
KenandHalvor Haugan cd2adcb655 Erstattet Radix togglegroup med intern implementasjon (#2620)
* 🎉 Ny hook og API 'descendants'

* 📝 Bedre storiers

* 🎨 implementert togglegroup med descendants

* 🎨 Implemented togglegroup.item

* 🎨 Fjernet gammel togglegroup

* 🐛 Fikset keydown

* 🔥 Fjernet comment

* 🎉 RowingFocus resetter nå ved focus-exit

* 🔥 Fjernet radix toggleroup fra dependencies

* 📝 Changeset

* [V6] Deprecated Grid og ContentContainer (#2622)

* 🔥 Fjernet grid css

* 🔥 Fjernet grid tsx

* 🔥 Fjernet content-container fra systemet

* 🐛 la til deprecatePrefix-tag for stylelint

* 📝 Changeset

* Textarea: Fjern wrapper (#2635)

* [V6] Chat-props deprecation (#2631)

* 🎨 Satt opp codemod boilerplate for chat deprecation

* 🐛 v5 -> v6 i codemod

* 🧪 Tester for alias-import av chat

* 🧪 idempotent codemod-test

* 🔥 Fjernet deprecated props fra Chat

* 📝 Changeset

* 📝 Bedre advarsel i chat-codemod

* 📝 v6-migration update

* 🧪 Tester vanlig import av Chat

* 📝 Oppdatert tekster i codemod

* 🔥 Fjernet return fra removeProps

* Update @navikt/aksel/src/codemod/migrations.ts

* [V6] 1440px breakpoint (#2632)

* ✨ La til nytt brekkpunkt 1440px

* 🎉 Bleed støtter 2xl breakpoint

* 🎉 Bleed box 2xl breakpoint

* 🎉 hgrid 2xl breakpoint

* 🎉 resterende primitives støtter 1440px

* 📝 tailwind migreringsdocs

* 🔥 Fjernet navno-mal fra chromatic snapshot

* 📝 Changeset

* 🐛 2xl hgrid css brakk

* 📝 Oppdatert changset med tailwind-ref

* Update @navikt/core/react/src/layout/bleed/Bleed.tsx

* Update @navikt/core/react/src/layout/bleed/Bleed.tsx

* 📝 Mer konsekvent story for breakpoints i box

* 🐛 JSDOC for Bleed matcher nå syntax

* [V6] Fjernet z-index-modal token  (#2637)

* 🔥 Fjernet zindex-modal token

* 📝 Oppdatert docs

* 📝 Changeset

* [V6] ErrorSummary magic (#2642)

* ♻️ Flyttet li-tag fra ErrorSummary-parent til child

* 🏷️ Bedre typer

* 🔒 Heading er nå required i ErrorSummary

* 🎨 Egen prop for ErrorSummary fokus

* 📝 Changeset

* 🎨 Bedre fokushåndtering i ErrorSummary

* ♻️ focusTarget -> focusTargetRef

* 📝 Fikset jsdoc

* 📝 Migreringstekst

* 📝 changeset

* 📝 Migration-text

* 📝 JSDoc-staving

* 📝 Oppdatert migreringsguide for z-index + tailwind

* 🐛 Fikset bruk av z-modal i tailwind

* 🔥 Fjernet descendants-filer

* 📝 Rename context og types til namespace

* 🔥 Fjernet openOnFocus-prop fra date

* [V6] Modal: strengere prop-typer (#2718)

* 🎨 SortState i Table har nå none tilgjengelig (#2726)

* [V6] Oppdatert bruk av action-farger (#2717)

* 💄 Button secondary hover

* 💄 Radio/Checkbox action-farger

* :WIP: combobox action-farger

* 🐛 Tilpasset hover-farge på checkbox i confirmationpanel

* 💄 copybutton hover-text action

* 💄 dropdown, helptext hover-text

* 💄 link og linkpanel actionsfarger

* 💄 Search action-farger

* 💄 select action-farger

* 💄 Stepper action

* 💄 Textarea action

* 💄 Textarea og textfield colors

* 🐛 Riktig hover-bakgrunn på combobox selected option

* 📝 Changeset

* 📝 changeset tokens

* 📝 Dokumentert nye tokens

* [V6] Native ESM-støtte 🎉  (#2677)

* 🎨 Fungerende cjs/esm bundle med use-client

* 🎨 Oppdatert dir-output i for esm

* ⬆️ Bump date-fns og react-day-picker

* 🎨 oppdatert date-fns imports

* 🐛 Endret bruk av reat-day-picker i monthpicker

* 🐛 Fikset rendring av button i Datepicker-row

* ♻️ Bruker date-fns imports ssom støtter v2 og v3

* ⬆️ Synced date-fns versions

* ✨ Astro testmiljø

* 📝 Changeset

* 🎨 Skriver packagejson med type for esm

* 🔥 Fjernet .yarn/* fra astro

* 🎨 La til .yarn i gitignore for astro

* ⏪ Bruker riktig ds-react versjon

* ⬆️ Lik tsconfig som ds-react i aksel-icons

* 🐛 La tilbake provernance

* 🐛 Undo Day/Row fix fra main

* 🔥 Fjernet mulighet til å laste date-fns v2

* 🔥 Fjernet fs-extra dependency

* 🐛 Fikset feil versjon på core/react

* [V6] React-pakker støtter nå native SSR ved å bruke `use-client` 🎉  (#2707)

* 🎉 use-client blir lagt til på export av ds-react og aksel-icons

* 🎉 La til nextjs med appdir for testing

* ⚡ Tom yarn.lock med i git

* 📝 changeset

* 📝 Oppdatert migration-guide

* Update @navikt/aksel-icons/config/index-template.js

* 🎉 ToggleGroup-prop fill

* 🐛 Async-lasting av date-fns er nå v3 esm compliant

v3 av date-fns støtter ikke default export/import, noe som brakk async-lasting da vi brukte .default

* 🧪 Forbedret ToggleGroup-tester

* ⬆️ yarn sync

* 🐛 Fikset import av parts

* 🔥 Fjernet duplikate changesets

* ⬇️ Reversert duplikate endringer som kom fra v6

* 📝 rowing -> roving

* 📝 Bedre test-navn

* 📝 Bedre navngivning for tester

* ⚡ Fjernet useEffect for state update

* 📝 Oppdatert changeset og jsdoc

* ♻️ Inlinet aria-desribedby

* 📝 Demo for fill-prop på aksel.nav.no

* 🐛 Togglegroup krever onChange-prop

* 📝 ToggleGroup story for chromatic

* ⬆️ yarn lock

* 🎉 Bedre visning av eksempel på aksel.nav.no

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-04-11 11:29:33 +02:00
Ken 0d4385a545 🐛 Fill-eksempel på Tabs viste ikke funksjon riktig 2024-04-11 11:25:54 +02:00
Ken 6f1b9751f3 🛂 La til feedback på nye gp-sider (#2840) 2024-04-11 07:21:44 +02:00
Ken 7fb97808f0 🚚 Flyttet data-aksel-template attr dypere i dom-treet (#2841) 2024-04-11 07:21:29 +02:00
KenandHalvor Haugan d8ac958de2 Erstattet Radix tabs med intern implementasjon (#2621)
* 🎉 Ny hook og API 'descendants'

* 📝 Bedre storiers

* 🎉 Setup for ny tabs

* 🎨 Setup context

* 🎨 useTabs-hook

* 🎨 Tablist hook

* 🚚 Flyttet tablist i egen mappe

* 🎨 TabList

* 🐛 Fikset import av tabList

* 🎨 Tabs.Tab implementert

* 🎨 Tabs.TabPanel implementert

* 🐛 Fikset import av tabpanel

* 🐛 onOnClick -> onClick

* 🐛 Fikset keydown-håndtering i tablist

* 🐛 Fikset plassering av scrollbuttons i overflow

* ♿ Scrollbutton er nå

* ✨ Fitted variant

* 🐛 Fikset imports

* 🔥 Fjernet radix-tabs import

* 🎨 Panel-children rendres bare hvis selected

* 🎨 lazy-prop for å bare rendre children i panel hvis selected

* 🎨 Tabs.Tab håndterer nå tab-key og tabindex riktig

* 📝 Changeset

* 📝 Changeset

* [V6] Deprecated Grid og ContentContainer (#2622)

* 🔥 Fjernet grid css

* 🔥 Fjernet grid tsx

* 🔥 Fjernet content-container fra systemet

* 🐛 la til deprecatePrefix-tag for stylelint

* 📝 Changeset

* Textarea: Fjern wrapper (#2635)

* [V6] Chat-props deprecation (#2631)

* 🎨 Satt opp codemod boilerplate for chat deprecation

* 🐛 v5 -> v6 i codemod

* 🧪 Tester for alias-import av chat

* 🧪 idempotent codemod-test

* 🔥 Fjernet deprecated props fra Chat

* 📝 Changeset

* 📝 Bedre advarsel i chat-codemod

* 📝 v6-migration update

* 🧪 Tester vanlig import av Chat

* 📝 Oppdatert tekster i codemod

* 🔥 Fjernet return fra removeProps

* Update @navikt/aksel/src/codemod/migrations.ts

* [V6] 1440px breakpoint (#2632)

* ✨ La til nytt brekkpunkt 1440px

* 🎉 Bleed støtter 2xl breakpoint

* 🎉 Bleed box 2xl breakpoint

* 🎉 hgrid 2xl breakpoint

* 🎉 resterende primitives støtter 1440px

* 📝 tailwind migreringsdocs

* 🔥 Fjernet navno-mal fra chromatic snapshot

* 📝 Changeset

* 🐛 2xl hgrid css brakk

* 📝 Oppdatert changset med tailwind-ref

* Update @navikt/core/react/src/layout/bleed/Bleed.tsx

* Update @navikt/core/react/src/layout/bleed/Bleed.tsx

* 📝 Mer konsekvent story for breakpoints i box

* 🐛 JSDOC for Bleed matcher nå syntax

* [V6] Fjernet z-index-modal token  (#2637)

* 🔥 Fjernet zindex-modal token

* 📝 Oppdatert docs

* 📝 Changeset

* [V6] ErrorSummary magic (#2642)

* ♻️ Flyttet li-tag fra ErrorSummary-parent til child

* 🏷️ Bedre typer

* 🔒 Heading er nå required i ErrorSummary

* 🎨 Egen prop for ErrorSummary fokus

* 📝 Changeset

* 🎨 Bedre fokushåndtering i ErrorSummary

* ♻️ focusTarget -> focusTargetRef

* 📝 Fikset jsdoc

* 📝 Migreringstekst

* 📝 changeset

* 📝 Migration-text

* 📝 JSDoc-staving

* 📝 Oppdatert migreringsguide for z-index + tailwind

* 🐛 Fikset bruk av z-modal i tailwind

* 🔥 Fjernet descendants-filer

* 📝 Rename context og types til namespace

* 🔥 Fjernet openOnFocus-prop fra date

* [V6] Modal: strengere prop-typer (#2718)

* 🎨 SortState i Table har nå none tilgjengelig (#2726)

* [V6] Oppdatert bruk av action-farger (#2717)

* 💄 Button secondary hover

* 💄 Radio/Checkbox action-farger

* :WIP: combobox action-farger

* 🐛 Tilpasset hover-farge på checkbox i confirmationpanel

* 💄 copybutton hover-text action

* 💄 dropdown, helptext hover-text

* 💄 link og linkpanel actionsfarger

* 💄 Search action-farger

* 💄 select action-farger

* 💄 Stepper action

* 💄 Textarea action

* 💄 Textarea og textfield colors

* 🐛 Riktig hover-bakgrunn på combobox selected option

* 📝 Changeset

* 📝 changeset tokens

* 📝 Dokumentert nye tokens

* [V6] Native ESM-støtte 🎉  (#2677)

* 🎨 Fungerende cjs/esm bundle med use-client

* 🎨 Oppdatert dir-output i for esm

* ⬆️ Bump date-fns og react-day-picker

* 🎨 oppdatert date-fns imports

* 🐛 Endret bruk av reat-day-picker i monthpicker

* 🐛 Fikset rendring av button i Datepicker-row

* ♻️ Bruker date-fns imports ssom støtter v2 og v3

* ⬆️ Synced date-fns versions

* ✨ Astro testmiljø

* 📝 Changeset

* 🎨 Skriver packagejson med type for esm

* 🔥 Fjernet .yarn/* fra astro

* 🎨 La til .yarn i gitignore for astro

* ⏪ Bruker riktig ds-react versjon

* ⬆️ Lik tsconfig som ds-react i aksel-icons

* 🐛 La tilbake provernance

* 🐛 Undo Day/Row fix fra main

* 🔥 Fjernet mulighet til å laste date-fns v2

* 🔥 Fjernet fs-extra dependency

* 🐛 Fikset feil versjon på core/react

* [V6] React-pakker støtter nå native SSR ved å bruke `use-client` 🎉  (#2707)

* 🎉 use-client blir lagt til på export av ds-react og aksel-icons

* 🎉 La til nextjs med appdir for testing

* ⚡ Tom yarn.lock med i git

* 📝 changeset

* 📝 Oppdatert migration-guide

* Update @navikt/aksel-icons/config/index-template.js

* 🚚 rename fitted -> fill in tabs

* 🐛 Async-lasting av date-fns er nå v3 esm compliant

v3 av date-fns støtter ikke default export/import, noe som brakk async-lasting da vi brukte .default

* 🧪 Forbedret Tabs-tester

Lagt til flere test-caser, men implementert testing av keyboard-nav og tabbing

* ⬆️ yarn sync

* ⬆️ Yarn lock

* ⬇️ Reversert duplikate endringer som kom fra v6

* 🎨 Aria-hidden blir nå satt på ikon hvis label allerede er satt på tab

* Update @navikt/core/react/src/tabs/Tabs.types.ts

* 📝 Testnavn for tabs

* ⚡ Skipper unødvendig memo for tab-context, punktum etter all jsdoc

* 🔥 Fjernet TabsContextProps

* 📝 Fjernet comma på changeset

* 📝 Fill-demo for aksel.nav.no

* 📝 Changeset for lazy-prop

* Update @navikt/core/react/src/tabs/parts/tabpanel/TabPanel.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 Beholder  attr fra radix med i ny implementasjon

* ⚡ Flyttet fokus-state update ut av useeffect, fjernet unødvendig klasse for hidden

* ⚡ Unngår unødvendig sjekk for disabled i onFocus for useTab2

* ♻️ tab og tabpanel støtter nå egne id-er

* Update @navikt/core/react/src/tabs/useTabs.ts

* 🐛 I none tilfeller førte setFocusedValue utenfor useEffect til infinite re-renders

* Update @navikt/core/react/src/tabs/parts/tab/Tab.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 bruker-id var satt på feil attrb

* 📝 Dokumentert custom-ids for tabs

* ⚡ Chroamtic-format for tabs-stories

* ♻️ Omskrevet tabs-stories for ny syntax

* 📝 Bruker bold markdown istedenfor note syntax

* 📝 Flyttet warning til newline

* 📝 Bruker bare ett linjeskift for jsdoc

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-04-10 13:36:11 +02:00
dependabot[bot]andKen b417c74374 ⬆️ Bump vite from 5.1.6 to 5.1.7 (#2836)
* ⬆️ Bump vite from 5.1.6 to 5.1.7

Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 5.1.6 to 5.1.7.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v5.1.7/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.1.7/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>

* ⬆️ bumpet vite til 5.1.7 i shadow-dom demo

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2024-04-10 12:24:54 +02:00
Halvor Haugan ff1d3534a6 🆙 Oppgrader Chromatic (#2837) 2024-04-10 12:13:48 +02:00
KenandHalvor Haugan 57d015209d [aksel.nav.no] Oppdatert ny GP-struktur og frontend (#2778)
* 🎉 Animert hero-select for nye gp-sider

* 🎨 Implementert keyboard-handler for tema-hero

* ♿ Gjemmer elementer ikke synlige ved hero-select

* 🎉 Ny hero for gp-side

* 🎨 Oppdatet gp-forside

* 🧪 Stories for nye komponenter

* 🐛 tabindex -> tabIndex

* ♻️ Oppdatert queriy definition

* 💄 Justert for mobilvisning

* 🎨 Bruker prictogram-data fra sanity i cards

* 🎉 Bruker faktiske innholdstyper og undertema nå

* 🔥 Fjernet TODO

* 🎨 Oppdatert go-forside til å støtte riktekst description

* 🐛 stories var ikke oppdatert

* 🎉 Bruker hero-cards i tema-hero

* 🐛 stories var ikke oppdatert

* 🐛 Manglet image i response-type

* ♻️ Omstrukturert modalvariant av dialog

* 🎉 Dynamisk hero for gp-sider

* 💫 Dynamisk skalering er nå animert

* 💫 Justert exit-animasjon

* 🔥 Fjernet gammel inline style

* ♻️ Forenklet Static hero callbacks

* 🔥 Fjernet hasRefs sjekk etter query for gp-artikler

* 🎉 Oppdatert serverside interface for gp-tema

* 🎉 Visninger for filtervalg på gp-tema

* 🐛 Valgt element ble ikke fokusert ved hero-åpning

* 🎉 Oppdatert artikkelkort for nye gp-sider

* 💄 Justert spacing for heading/desc seksjoner

* 🎉 Fikset lasting av data og chips

* 🎉 Fungerende chip-navigering

* ⚰️ Fjernet gammel kode

* 🚚 rename tema-hero filer

* 📝 Dokumentert count articles funksjoner

* 🧪 tester for count-articles

* 🚚 Flyttet cardgrid ut til egen fil

* 🔍 lagt til seo for tema

* ⬇️ reversert til prod-dataset

* 🎉 Artikler på gp-forside er sortert etter mest populære

* 🎨 satt description på undertema til required

* 🎉 Panel for forhåndsvisning av undertema/innholdstype på artikkelside

* 🎉 Lagt til forklarings-felt i ny god-praksis struktur

* 🐛 Fjernet chiplist for lister uten noe data

* 🎉 Tilpasset temaheader for kontrast

* 💄 normal -> semibold for statichero title

* ♿ Wrappet lister i ul > li

* 🎉 Oppdatert til ul > li på artikkel-lister

* 🐛 Cards strakk seg ikke til høyde etter wrapping i li

* 🐛 Manglet main-element og skip-link støtte

* 🔍 Bedre meta-description

* 🔥 Fjernet kommentar

* 🎨 Gjort klar sitemap for ny god-praksis

* ♿ Bedre semantikk for temasider

* 🎨 Justert tema header

* 🎨 Oppdatert akselchevron

* 💫 Justert page-animasjon

* 🎨 La til artikkel-chips

* ♻️ Link chip -> temalink

* 🎨 Tema-tagging på gp-artikler

* 💄 Gradient og illustrasjon på tema-hero

* 💄 La til bildestøtte i hero-tittel

* 🐛 stories brakk

* 💄 Satt god praksis heading til text- default for bedre kontrast

* 💄 z-index problem på intro hero

* 💄 Småjusteringer design

* 🐛 z-index stacking av cube-illustrasjon nå bak tekst

* 📝 Lagt til kommentar

* 🚚 Flyttet over støtte for wc definering i react

* 🐛 Brukte feil temahenter i sitemap som brakk playwright

* ♿ uu-oppdateringer etter review

* ♻️ Explanation -> description for undertema og tema

* 💄 Oppdatert Hero for teamsider

* 💄 Blur-bg på tekst i hero, no underline på hover for komponentsforside

* ♻️ Fokus beholdet på select-knapp ved åpning av tema-dialog

* 📝 Commentarer på escapeKeyDown hook

* 💄 Gjennbruker gradient for alle hero-headers

* 📝 Skrivefeil

* 📝 Kommentert useGpViews

* 📝 Kommentert endringer

* ⬆️ Bumpet sanity til v3.36

* ♻️ Fjernet Modal variant av tema hero.

Bruker samme dialog på mobil og desktop

* 🎨 aria headings -> h3 for gp-forside lenke

* 📝 Lowercase i html for artikkelcards

* Update aksel.nav.no/website/pages/gp/index.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/components/website-modules/AnimatedChevron.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/components/layout/god-praksis-page/cards/GpArticleCard.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/components/layout/god-praksis-page/hero/tema-hero/parts/HeroCardList.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🚚 ArticleView -> ArticleSections

* 🚚 bosheight -> dialogheight

* 🐛 Import feilet av GpCardGrid etter navneendring

* 🐛 hero navigasjon var ikke sortert etter temanavn

* 🔥 Fjernet explanation-felt for innholdstyper

* ♻️ Ryddet opp i kommentarer fra github

* ♻️ Bruker SanityImageSource for Image-type

* 💄 Selected-variant av herocard. Inverted-pictogram i sanity

* 📝 view -> queryView

* ♻️ Skrevet om ArticleSections for å unngå repetert kode

* ⬆️ yarn lock

* ♻️ Fjernet unødvendig react-fragment

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-04-10 10:15:56 +02:00
Ken 5969859024 🐛 Unngå at global Escape-event lukker ikon-sidebar
Dette gjelder ved escape i Søk(modal) og søkefelt på ikonside
2024-04-10 09:05:51 +02:00
github-actions[bot]andgithub-actions[bot] 9bbc3e6813 Version Packages (#2835)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-04-09 15:25:38 +02:00
Ken 5250b47ca4 💄 Border-radius på FileUpload.Item er nå rund (#2834) 2024-04-09 15:20:40 +02:00
Ken fc7709ae2a 🐛 Søk filtrerte ut beste treff fra 'nyeste artikler' 2024-04-09 09:40:20 +02:00
github-actions[bot]andgithub-actions[bot] 2364e689ed Version Packages (#2831)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-04-09 09:12:06 +02:00
Halvor Haugan d57c0b2c2c Justering av eksempler på Checkbox (#2833) 2024-04-09 09:06:58 +02:00
Ken 868bb543a5 🐛 Preview brakk for god-praksis
Siden 'userState' ikke hentes fra Sanity, blir den undefined ved lasting av previewdata
2024-04-09 07:33:16 +02:00
Torkjel SkjetneandHalvor Haugan 8f9ed7a404 FileUpload.Item: 💥 Endret API og støtte for å sette ID på knappen (#2824)
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2024-04-08 09:16:53 +02:00
Halvor HauganandKen 5ea6255f6d Justeringer av eksempler på Radio og Checkbox med mer (#2830)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-04-04 20:54:12 +02:00
github-actions[bot]andgithub-actions[bot] 491fccbe80 Version Packages (#2828)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-04-03 11:56:35 +02:00
Ken cca2a8263f 💄 Fjernet Illustrasjon fra bloggsider (#2827) 2024-04-03 11:50:12 +02:00
Ken 3140ec2765 🔥 Fjernet role=gridcell fra datoknapper (#2826)
Siden knappene allerede er i en table og da også td er det unødvendig med gricell
2024-04-03 11:37:05 +02:00
Halvor Haugan d8fce83ae3 Oppgrader til Storybook 8 (#2825) 2024-04-03 10:03:44 +02:00
github-actions[bot]andgithub-actions[bot] f88b00daf6 Version Packages (#2821)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-04-03 09:45:19 +02:00
Ken 6d0baea5c1 👽 Oppdatert om Aksel lenke i footer
Side er flyttet fra god-praksis til standalone-side url
Er opprettet automatisk redirect slik at eldre lenker ikke brekker
2024-04-03 09:25:54 +02:00
Ken 880e77b9c2 ♻️ Fjernet max-krav for antall tegn i Relaterte lenker-module
Siden lenketeksten ofte refererer til en sidetittel skaper det utfordringer da de ofte er litt lengre
2024-04-03 09:03:57 +02:00
Ken 6d16373f85 👽 Oppdatert skriv for aksel lenke i footer
Side er flyttet fra god-praksis til standalone-side url
Er opprettet automatisk redirect slik at eldre lenker ikke brekker
2024-04-03 08:42:08 +02:00
Halvor Haugan ae078254dc Modal: Fjern tomt element (#2819) 2024-04-02 10:20:00 +02:00
github-actions[bot]andgithub-actions[bot] 638e8260b4 Version Packages (#2811)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-04-02 08:45:10 +02:00
Halvor Haugan d991011690 FileUpload.Dropzone: id prop settes på button (#2817) 2024-03-22 11:03:05 +01:00
KenandHalvor Haugan b6086f7b1f 📝 Oppdatert radio-error dokumentasjon (#2800)
* 📝 Oppdatert radio-error dokumentasjon

* Update aksel.nav.no/website/pages/eksempler/radio/error.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/pages/eksempler/radio/error.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/pages/eksempler/radio/error.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-03-22 10:42:38 +01:00
Ken 05462081aa useControllableState i Expansioncard og Switch state-bug (#2810)
* ♻️ Bruker controllableState i ExpansionCard

* 🐛 Fikset tilfelle der checked switch var visuelt unchecked

* 📝 Changeset

* 🔥 Fjernet utkommentert kode
2024-03-22 10:24:35 +01:00
Ken 63e42de3ee 🆙 Oppdatert Playroom (#2815) 2024-03-22 09:31:00 +01:00
Halvor Haugan 2e85178166 yarn.lock sync 2024-03-21 16:36:11 +01:00
Ken 456d4e2e07 🐛 Slack var ikke i outbound accessPolicy for feedback 2024-03-21 11:52:48 +01:00
Ken b5a0cb8cdf Oppdatert logging for Aksel.nav.no + bumpet feedback pagination page-size (#2812)
* 🆙 Oppgradert logging

* 🎨 Bedre loggeoutput

* 🎨 Bruker childlogger

* 🧪 Custome error-logg

* ⚡ Større paginering-page for slackusers

* 📝 error -> info
2024-03-21 11:36:43 +01:00
Ken a2af9bcc37 Lagt til mer padding-right på ReadMore (#2806)
* 💄 Oppdatert padding-right på readmore

* 📝 Changeset

* 🐛 Manglet chromatic-disable på readmore story
2024-03-21 10:16:14 +01:00
bd45754adb [aksel.nav.no] Slackbot for feedback (#2785)
* 🎉 Satt opp boilerplate for auth på Aksel

* 🎉 Auth boilerplate

* 🎨 Demo-setup for å teste auth i dev

* 🚚 Flyttet auth til getserversideprops

* 🔥 Fjernet authprovider fra _app

* 🐛 revalidate er ikke valid key for getserversideprops i nextjs

* 🚚 rename auth-dir

* 🔥 Fjernet auth types

* 🎉 Auth for api

* 🎨 Oppdatert workflows med token

* 🔥 Fjernet testing av auth på god-praksis sider

* 🎨 La til sidecar på prod-deploy

* 🐛 only return boolean in Promise<boolean>

* ✨ feedback form

* 🎨 showcase all states of new FeedBackForm

* 🔥 remove prop name (will use auth api)

* 🎨 use getAuthUser()

* 🎨 use useAuth() for login/logout

* 🎉 Slack feedback-api

* 🐛 handle case where token is null

* 🎨 scroll to anchor on login redirect

* ⚡ Utility-funksjoner for slack-api

* 🧪 Tests for slack-utilities

* 🎨 Ryddet opp i henting av slack memebers

* 🚚 Flyttet caching inn i funkson

* 📱 make FeedbackForm responsive

* 🎉 Strengere typet slack-utilities

* 🎨 Fikset typefeil i feedback-api

* ⬆️ Migrert til @navikt/oasis

* 🏷️ Satt typer til strict for å kjøre tester

* 🎨 Slackbot-API with protected auth and actual user

* 🏷️ strengere typer

* ⚡ Implementert paginering av slacbot

* 🎨 Lagt til slackbot-token i workflows

* 🏷️ strict tsconfig

* 🏷️ Typer for slackbot input

* 🔥 Fjernet demo-body

* 🎨 oppdatert medvirkende tekst

* ⬆️ Yarn lock

* 🎨 move state handling down to Feedback

* 🏷️ typing fixes

* 🚧 API usage

* 🏷️ fix type error

* 👷 update AccessPolicy

* 🦺 add validation to feedback form

* 💄 justify-items-stretch on TextArea needed 🤔

* ♻️ avoid prop drilling, use sanity data hook for document id

* 🔧 add auth to webpack config for storybook

* ♻️ Feedback form  (also add error state handling)

* 👷 add stories for Feedback form

* 🔊 log feedback results metadata

* ♻️ remove refs, use formData and event.currentTarget

* 🧪 retry flaky test

* ⚗️ test promises for dynamic import in test

* 🧪 flaky test config

* ⬆️ yarn lock sync

* ⬆️ yarn lock sync

* ♻️ Bruker nå egen userState-type for fortelle komponenter om bruker er logget inn eller ikke

* 🔥 remove unused CSS

* 📝 lagt til todods

* 🔥 remove anonymous feedback submission

* 🔥 remove CSS

* :goals_net: catch fetch clientside, feedback

* ✨ send feedback to private slack channel as well

notify everyone if there are 0 editors

* 💄 + ♿ aria-hiddens and better styling, Feedback

* ♻️ refactor + add more feedback (loading state + alert)

* ⚗️ test encoding uri for anchor (redirect)

* ⚗️ more testing URL redirect

* ⚗️ more testing

* ⚗️ testing

* ✅ stories for Feedback

* 🔒 sanitize user objects (then cache)

* 🏷️ type SanitizeUser in find-user

* 🐛 optionally render the message about zero editors

* ⚗️ more testing for URL redirect / fragment issue

* ⚗️ log the redirect URL

* ⚗️ more testing

* ♻️ Gjennbruker error-return for feedback-api

* 🧪 Tester alternativ løsning for scroll etter login

* 🐛 Query update slapte loop i useEffect

* 🧪 Tester alternativ løsning for scroll etter login

* 🚚 Flyttet autofocus inn i headingseksjon

* 🐛 Wonderwall fjerner & fra query

* 🐛 encodeUrl as defined in wonderwall docs

* 🧪 Reversert til anchor-løsning

* 🧪 Reversert til anchor-løsning med encoding

* 🐛 Fikset edgecase der asPath med allerede eksisterende hash brakk login-redirect

* 🔥 Cleanup etter anchor-testing

* ⬆️ yarn lock sync

* 🎨 Oppdatert til navikt channelid

* 📝 Endret på error-tekst i feedback

* Fjernet ts-expect-error

* ⬆️ yarn lock sync

* 🔥 Fjernet filterering på godkjent mail

* 📝 Oppdatert slackbot-block

---------

Co-authored-by: Julian Nymark <julian.nymark@nav.no>
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2024-03-20 15:48:49 +01:00
github-actions[bot]andgithub-actions[bot] a882a8a389 Version Packages (#2807)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-03-20 13:26:51 +01:00
Ken d1606d358a 🐛 useDatepicker håndterer isInvalid validation riktig (#2809)
* 🐛 useDatepicker håndterer isInvalid validation riktig nå

* Update @navikt/core/react/src/date/hooks/useDatepicker.tsx

* Update @navikt/core/react/src/date/hooks/useDatepicker.tsx
2024-03-20 13:21:05 +01:00
Ken bb87837632 🧪 Bump timeout and retry of dateStr testing 2024-03-20 12:33:56 +01:00
Halvor Haugan 9c8b2301ed FileUpload.Dropzone: Fiks feil med duplisert id (#2805) 2024-03-20 12:31:08 +01:00
Ken 54ba483d2d ✅ Oppdatert Chromatic-tester
✅ Oppdatert dropdown-tester

🐛 satt dropdown-story til open

✅ Oppdatert errorsummary-tester

✅ Oppdatert fieldset-tester
2024-03-20 11:51:46 +01:00
github-actions[bot]andgithub-actions[bot] 85f5458c06 Version Packages (#2804)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-03-20 09:51:54 +01:00
Halvor Haugan 19abec80f7 FileUpload: Fiks feil ved import av json (#2803) 2024-03-20 09:46:45 +01:00
Julian NymarkandHalvor Haugan b2ddce5279 📝 Search docs review (#2797)
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2024-03-19 15:39:12 +01:00
github-actions[bot]andgithub-actions[bot] bd7c945158 Version Packages (#2799)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-03-19 15:07:37 +01:00
Ken ca24684a25 🐛 Dropzone med disabled stoppet ikke filopplasting (#2798)
inputfelt settes nå til disabled ved bruk av prop for å unngå dette
2024-03-19 15:02:06 +01:00
Julian Nymark 1564363985 💄 break-normal on body text, but break-all on types, as they… (#2790)
* 💄 break-normal on body text, but break-all on types, as they get long and complicated without spaces

* 🔥 remove break-normal, as it's the default
2024-03-19 14:58:58 +01:00
Ken ca8d36e885 🔥 Fjernet UX-tweaks card på forside
Kode er kommentert ut fra forside, men vil være lett tilgjengelig hvis vi ønsker å legge til fremtidige undersøkelser
2024-03-19 14:43:00 +01:00
github-actions[bot]andgithub-actions[bot] 8efc6c58be Version Packages (#2794)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-03-19 14:00:30 +01:00
2ea2a91a37 Combobox complex options (#2716)
* Remove unused function

* Support for complex options, using objects with label and value instead of strings

* Better typing for isTextInSelectedOptions value (boolean instead of truthy/falsy)

* Stricter value type: Only accept string values. This will work better with the allowNewValues prop, and simplify returning a value from onToggleSelected.

* More JSDoc

* Add test for complex options with label and value

* Add example for complex options on the aksel-website

* yarn.lock

* Remove other properties than label and value from Combobox options in Storybook-examples, as we have limited the format for now

* Array.includes does not work with objects, so should use isInList utility function. Fixes missing checkmark for selected items in FilteredOptions.

* Add changeset

* Remove navds-dependencies in playroom that break playwright tests. These are outdated/unsynced, and will be inherited from parent package.json instead.

* Do not try to remove an undefined option

* "it" is from jest. Use "test" instead.

* Update @navikt/core/react/src/form/combobox/FilteredOptions/filteredOptionsContext.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/form/combobox/FilteredOptions/filteredOptionsContext.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/form/combobox/Input/Input.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/form/combobox/types.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Raise change level to minor, to signal the new feature

* Spread props instead of adding them separately

* JSDoc @returns doesn't do anything without a value specified, and neither of these return a value

* Options are used for multiple features, so will just skip specifying them

* Doesn't need a guaranteed unique ID for storybook examples. Use hard-coded instead.

* selectedOptions is a list of strings anyhow, so should just use the value

* More realistic example for complex options, where the option label is larger, and the SelectedOptions label uses a short code (the value)

Also made the isInList function better, by checking both label and value when checking ComboboxOptions. Pass just the value or just the label if you only want to check either of them.

* Add tests for mapToComboboxOptionArray (renamed from mapFromStringArrayToComboboxOptionArray)

* Add test for toComboboxOption and use this function in mapToComboboxOptionArray

* Update combobox unit test for complex options to use a more realistic example

* Don't say anything about what might be added in the future. That doesn't belong in the documentation

* Oppdater beskrivelsen for complex options-eksempelet (var kopiert fra annet eksempel)

* Fix Storybook example bug where de-selecting a value selected it an extra time

* Fix example

* Remove listing options because it breaks with allowNewValues

* Revert earlier change that always showed selected values in FilteredOptions, even if it didn't match the search text. This broke autocomplete.

* Remove unneccessary optional check

* yarn.lock

* Don't need to use toLocaleLowerCase

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-03-19 13:47:13 +01:00
Halvor HauganandKen aebba20fd4 🆙 Minor-oppgradering av deps (#2795)
Co-authored-by: Ken <ken.aleksander@gmail.com>
2024-03-18 18:51:11 +01:00
Ken 5ce4b4ea79 📱 Tilpasset aksel-header for 320px (#2793) 2024-03-17 15:27:43 +01:00
Ken 548d9bb169 💄 Bedre eksempel for logg-ut i dropdown (#2792) 2024-03-17 15:27:33 +01:00
25e0d15d67 Ny komponent FileUpload (#2504)
---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2024-03-15 12:54:35 +01:00
Halvor Haugan 98f6d7dde4 Forbedret beskrivelse for ref i prop-tabell (#2791) 2024-03-15 10:04:09 +01:00
6ac605dd48 Version Packages (#2775)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-03-14 16:15:40 +01:00
Ken d293d44b30 Fikset CDN deploy av Aksel og designsystem assets (#2789)
* 🐛 Oppdatert assetprefix

* 🐛 Fikset cdn asset upload
2024-03-14 16:05:09 +01:00
Julian Nymark 5754a08f6c 👷 update workflow for prod (new NAV CDN) 2024-03-14 14:20:08 +01:00
Julian Nymark 924c63324c 👷 swap team aksel for team designsystem (used elsewhere within NAIS) 2024-03-14 14:11:20 +01:00
Julian Nymark b78b818fea 👷 update workflow (new NAV CDN) 2024-03-14 14:00:44 +01:00
Ken dc5ea3b842 [Ikoner] Nytt ikon OpenSource (#2787)
* 🎉 Oppdatert ikonpakke

* 📝 changeset
2024-03-13 18:59:41 +01:00
Halvor Haugan bd315a239b [aksel.nav.no] Fiks link til token-guide (#2786) 2024-03-13 15:53:59 +01:00
Julian NymarkandKen <ken.aleksander@gmail.com>, Halvor 4469c641ed 💄 pretty up the props box on aksel.nav.no + typos (#2729)
* 💄 pretty up the props box on aksel.nav.no + typos

- also update some props docs here & there

* ♻️ pull out component, lazy() it

* 🔥 remove testing css

* 🎨 add fallback with <Suspense>

* 💬 correct @default strings

* 💄 spacing in Props table

* 🔥 @note is not a real JSDoc tag

* ✨ docgen extracts example, render fancy example box

* ✨ pretty @return and @params

* 💄 improve table layout / CSS

* 💄 + update CopyButton & Combobox jsdoc.

* 📝 update jsdoc

* 🎨 Oppdatert layout og visning av prop-table

* 🎨 use more semantic html, better nested <dl>

* ♿ add h4 to prop items

* 👷 use production sanity data

* ♿ revert nested <dl> so Axe tests pass

* 🏷️ correct some types for tsc to pass

* ♿ change from div -> ul

* 👷 commit lockfile

* 💄 make ul bottom rounded and align type with it\'s code block

* ♿ set language tag for props written in english

* 🏷️ type improvements for props section

* 🙈 update .gitignore

* 📝 jsdoc update

* 💄 props section

* ♻️ rename and less indentation (continues > ifs)

* 💄 style changes for Prop section

- breakpoint fail fix
- breakpoint col / row flex for prop fields
- padding tweaks

* 📝 update example jsdoc

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>, Halvor <halvor.haugan@nav.no>
2024-03-12 13:59:35 +01:00
Halvor Haugan b15218e1cb Oppdatering av eksempler på Textarea (#2784) 2024-03-12 09:11:18 +01:00
Ken 73a69f7048 🎉 Fikset search-bug der for god score fjernet resultat (#2783) 2024-03-11 12:48:02 +01:00
Halvor Haugan 7dcd58ff76 Select: Justert eksempler, JSDOC og stories (#2782) 2024-03-11 11:04:49 +01:00
Halvor Haugan 2f3c99f5f6 Justering av eksempel på Table med TextField (#2780) 2024-03-08 09:35:00 +01:00
KenandJulian Nymark 8835291a78 [Aksel.nav.no] Auth på Aksel (#2757)
* 🎉 Satt opp boilerplate for auth på Aksel

* 🎉 Auth boilerplate

* 🎨 Demo-setup for å teste auth i dev

* 🚚 Flyttet auth til getserversideprops

* 🔥 Fjernet authprovider fra _app

* 🐛 revalidate er ikke valid key for getserversideprops i nextjs

* 🚚 rename auth-dir

* 🔥 Fjernet auth types

* 🎉 Auth for api

* 🎨 Oppdatert workflows med token

* 🔥 Fjernet testing av auth på god-praksis sider

* 🎨 La til sidecar på prod-deploy

* 🐛 only return boolean in Promise<boolean>

* ⬆️ Migrert til @navikt/oasis

* 🏷️ Satt typer til strict for å kjøre tester

* ⬆️ Yarn lock

---------

Co-authored-by: Julian Nymark <julian.nymark@nav.no>
2024-03-06 11:53:30 +01:00
Halvor Haugan 2971129d1f Oppgrader eslint-plugin-storybook (#2777) 2024-03-05 16:34:36 +01:00
Ken 9915cf8232 🔥 Fjernet muligheten til å sette seg som anonym i sanity
Nye forfattere blir anbefalt å bruke et alias eller bare fornavn hvis man ønsker.

Ingen er satt som anonym i dag, slik at dette ikke vil påvirke noen forfattere
2024-03-05 14:34:20 +01:00
Halvor Haugan fa00774b0d Forberedelse for Storybook 8 (#2776) 2024-03-05 14:33:58 +01:00
Ken 966de79621 [aksel.nav.no] Migrert editor-felt til variant med email (#2760)
* 🎨 Satt opp migrering for editorsider

* 🎨 Oppdatert initialvalues for mail og oppretting av nye artikler

* 📝 Description på email-field

* Update aksel.nav.no/website/sanity/schema/documents/editors.tsx

* Update aksel.nav.no/website/sanity/schema/documents/editors.tsx

* Update aksel.nav.no/website/sanity/schema/documents/editors.tsx

* 🎨 Bedre validering av nav-mail i sanity

* 🐛 Feilet etter ts oppdatering
2024-03-05 13:35:48 +01:00
KenandHalvor Haugan 0ce2300f92 [aksel.nav.no] Satt strict -> true i tsconfig (#2766)
* 🏷️ sanity-video typer

* 🏷️ Typer storybook

* 🏷️ Typer usecheckauth

* 🏷️ Typer formateddate

* 🏷️ Typer useSanityDate

* 🏷️ Typer footerlink

* 🏷️ Typer ny gp

* 🏷️ Typer layout

* 🏷️ Typer logging

* 🏷️ Typer logging av href

* 🏷️ Typer codeexamples

* 🏷️ Typer sanity-modules

* 🏷️ Typer for alle sanity-modules

* 🏷️ Typer resolvers

* 🏷️ Typer serach

* 🏷️ Typer search

* 🏷️ Typer useToc

* 🏷️ Typer _app

* 🏷️ Typer pages

* 🔥 Fjernet buildlogs fra tsc

* ⬇️ Reversert til gammel logging av lenker

* Update aksel.nav.no/website/pages/eksempler/timeline-intern/aria-controls.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🏷️ Bruker satisifies for array-type sjekk

* 🏷️ Forenklet typer

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-03-05 11:46:10 +01:00
Halvor Haugan 08e9876176 Sandbox: Alltid bruk siste versjon av DS-pakkene (#2774) 2024-03-04 14:10:36 +01:00
Ken 331b4c4c00 🎉 Nytt ikon archive@ (#2772) 2024-03-04 14:10:04 +01:00
Halvor Haugan 2b6e9c8798 Oppdater stories for Link (#2770) 2024-03-01 20:00:18 +01:00
Ken 4065ee3987 💄 UXTweaks-hero på forside bruker Amber-farger
Designer ønsket å gjøre hero mer tydelig da dagens 'violet' forsvant mellom elementene
2024-02-29 19:33:30 +01:00
github-actions[bot]andgithub-actions[bot] 59756f32f7 Version Packages (#2764)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-02-29 12:21:22 +01:00
Halvor Haugan 9510327abe Link: Fjern hover-farge (#2767) 2024-02-28 15:18:25 +01:00
Christian Skrøvseth 356119e074 Modal: Fiks lukking ved slipp av museknapp på backdrop (#2752) 2024-02-27 15:02:02 +01:00
Halvor Haugan 3d2eab4fda Modal: fiks fokus bug i Safari + endre title på lukkeknappen (#2688) 2024-02-27 09:48:26 +01:00
Halvor Haugan 299c5f1db4 [aksel.nav.no] 🔨 Bytt ut cp med copyfiles (#2753) 2024-02-26 13:28:46 +01:00
Halvor Haugan 6267d0c7fb [aksel.nav.no] 🆙 Oppgradert start-server-and-test (#2759) 2024-02-26 13:26:59 +01:00
Halvor Haugan 44ba2ef7e8 [aksel.nav.no] 🚨 Ikke tillat @ts-ignore (#2758) 2024-02-26 13:07:30 +01:00
Ken 002f6a1b9e [Sanity] Oppdatert sanity minor (#2733)
* 🎉 Oppdatert sanity

* 🐛 Oppdatert import av deprecated desktool i sanity

* ⬆️ yarn sync

* 🐛 IntentButton var oppdatert i ny sanity-versjon
2024-02-26 10:43:00 +01:00
Halvor Haugan 124c28eb0e Oppdatering av eksempler på TextField (#2754) 2024-02-26 10:05:46 +01:00
Halvor Haugan ae7d4d5f07 Oppgradering av deps (#2756) 2024-02-26 09:07:11 +01:00
github-actions[bot]andgithub-actions[bot] bb5dd32357 Version Packages (#2746)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-02-21 15:27:30 +01:00
Ken 9581fb33f2 📝 Oppdatert changeset for ny v6.1 release 2024-02-21 15:24:26 +01:00
KenandHalvor Haugan 884bf0c997 [V6 minor] Oppdatert exports av komponenter for å støtte nextjs app router (#2745)
* 🚚 Oppdatert names-exports for expansioncard

* 🚚 Accordion

* 🚚 Alert

* 🚚 Button

* 🚚 Chat

* 🚚 Chips

* 🚚 CopyButton

* 🚚 Date components

* 🚚 Dropdown

* 🚚 Guidepanel

* 🚚 Helptext

* 🚚 InternalHeader

* 🚚 Primitives

* 🚚 Link

* 🚚 LinkPanel

* 🚚 List

* 🚚 Loader

* 🚚 Modal

* 🚚 Portal

* 🚚 Pagination

* 🚚 Popover

* 🚚 Provider

* 🚚 ReadMore

* 🚚 Skeleton

* 🚚 Stepper

* 🚚 Table

* 🚚 Tag

* 🚚 Timeline

* 🚚 ToggleGroup

* 🚚 Tooltip

* 🚚 Typography

* 🚚 Utils

* 🚚 Flyttet forms-komponenter inn i egne mapper

* 🚚 Oppdatert exports for alle skjemakomponenter

* 📝 Oppdatert exports av forms i package.json

* 🐛 Fikset regresjoner etter flytting av filer og exports

* 🐛 Manglet export av errorsummaryitem

* 🐛 Manglet export av search.button

* 🐛 Stories manglet riktig import

* 📝 changeset

* 🐛 Tester var ikke oppdatert med imports

* Update .storybook/main.ts

* 📝 Oppdatert package.json description

* 🎨 Oppdatert export til default-export

* 🐛 Exports av komponenter brakk for utils, combobox

* 🎨 Oppdatert eksempler for next appdir

* 🎨 Oppdatert astro-eksempel

* 📝 Client component test i use client scope

* 📝 Changelogs skrev use client feil

* 🐛 rename fieldset

* 🐛 rename Fieldset -> fieldset

* 🐛 Merge fra main brakk combobox tester og stories med feil import

* Update .changeset/silent-meals-watch-copy.md

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-02-21 15:20:26 +01:00
c0c812b77b 🏷️ fix types for modal issue (#2744)
* 🏷️ fix types for modal issue

* liten style justering

* Tester!

* changeset

* tester test

* tester test 2

* tester test 3

* Revert experiments, add proper tests

* fix Portal.stories.tsx

* 🏷️ Endret rekkefølge på modal conditional-typer for bedre feilmelding

* revert rekkefølge

* testkode

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2024-02-21 13:37:28 +01:00
Julian Nymark fd4358df31 ♻️ update several stories (#2740)
* ♻️ update several stories

* ♻️ textarea

* ♻️ remove unused props + radio, search, select, monthpicker

* ♻️ text-field
2024-02-20 16:35:29 +01:00
Halvor Haugan bf77c03cd8 Modal: Ikke opphev scroll lock ved lukking av nesta modal (#2743) 2024-02-20 15:55:19 +01:00
Ken 91e34e8ad8 [aksel.nav.no] Oppdatert til nextjs v14 (#2737)
* 🚚 Nextjs v14 støtter ikke route-names med default. renamet til demo

* 🎉 Nextjs canary-release for fungrende v14 + middleware

* 🐛 canary-version hadde feil syntax

* 🔥 Fjernet github-pattern fra image-config i next.config.js

* ⬆️ yarn sync
2024-02-19 19:58:11 +01:00
Ken 15f88a104f 🐛 Tester på nettside ble prøvd kjørt i feil workspace 2024-02-19 16:12:50 +01:00
Ken 5100662ea7 ⚡ Skrevet om Jest til Vitest (#2723)
* ⚡ Bruker vitest for Aksel cli

* ⚡ Tokens bruker vitest

* 🔥 Fjernet ubrukte dependencies fra aksel cli

* ♻️ Aksel icons vitest

* ♻️ React bruker vitest

* 🔥 Fjernet ubrukte dependencies

* ⚡ Ser nå hvilken workspace som kjører tester

* ⚡ Vitest på aksel.nav.no

* 🎉 Vitest for aksel

* 🐛 Fikset eslint-feil for vitetest

* 🔥 Fjernet happy-dom

* 🎉 Stylelint bruker native node test-runner og ikke jest lengre

* 🎨 Migrert nye Tabs/ToggleGroup-tester til vitest
2024-02-19 16:03:48 +01:00
github-actions[bot]andgithub-actions[bot] bea55aa8bc Version Packages (#2742)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-02-19 15:05:24 +01:00
Ken 7585351483 🐛 Manglende export av _docs.json brakk oppdaterting av sanity-data 2024-02-19 14:51:27 +01:00
KenandHalvor Haugan 636c1ad49b [V6] Major-release (#2623)
* [V6] Deprecated Grid og ContentContainer (#2622)

* 🔥 Fjernet grid css

* 🔥 Fjernet grid tsx

* 🔥 Fjernet content-container fra systemet

* 🐛 la til deprecatePrefix-tag for stylelint

* 📝 Changeset

* Textarea: Fjern wrapper (#2635)

* [V6] Chat-props deprecation (#2631)

* 🎨 Satt opp codemod boilerplate for chat deprecation

* 🐛 v5 -> v6 i codemod

* 🧪 Tester for alias-import av chat

* 🧪 idempotent codemod-test

* 🔥 Fjernet deprecated props fra Chat

* 📝 Changeset

* 📝 Bedre advarsel i chat-codemod

* 📝 v6-migration update

* 🧪 Tester vanlig import av Chat

* 📝 Oppdatert tekster i codemod

* 🔥 Fjernet return fra removeProps

* Update @navikt/aksel/src/codemod/migrations.ts

* [V6] 1440px breakpoint (#2632)

* ✨ La til nytt brekkpunkt 1440px

* 🎉 Bleed støtter 2xl breakpoint

* 🎉 Bleed box 2xl breakpoint

* 🎉 hgrid 2xl breakpoint

* 🎉 resterende primitives støtter 1440px

* 📝 tailwind migreringsdocs

* 🔥 Fjernet navno-mal fra chromatic snapshot

* 📝 Changeset

* 🐛 2xl hgrid css brakk

* 📝 Oppdatert changset med tailwind-ref

* Update @navikt/core/react/src/layout/bleed/Bleed.tsx

* Update @navikt/core/react/src/layout/bleed/Bleed.tsx

* 📝 Mer konsekvent story for breakpoints i box

* 🐛 JSDOC for Bleed matcher nå syntax

* [V6] Fjernet z-index-modal token  (#2637)

* 🔥 Fjernet zindex-modal token

* 📝 Oppdatert docs

* 📝 Changeset

* [V6] ErrorSummary magic (#2642)

* ♻️ Flyttet li-tag fra ErrorSummary-parent til child

* 🏷️ Bedre typer

* 🔒 Heading er nå required i ErrorSummary

* 🎨 Egen prop for ErrorSummary fokus

* 📝 Changeset

* 🎨 Bedre fokushåndtering i ErrorSummary

* ♻️ focusTarget -> focusTargetRef

* 📝 Fikset jsdoc

* 📝 Migreringstekst

* 📝 changeset

* 📝 Migration-text

* 📝 JSDoc-staving

* 📝 Oppdatert migreringsguide for z-index + tailwind

* 🐛 Fikset bruk av z-modal i tailwind

* 🔥 Fjernet openOnFocus-prop fra date

* [V6] Modal: strengere prop-typer (#2718)

* 🎨 SortState i Table har nå none tilgjengelig (#2726)

* [V6] Oppdatert bruk av action-farger (#2717)

* 💄 Button secondary hover

* 💄 Radio/Checkbox action-farger

* :WIP: combobox action-farger

* 🐛 Tilpasset hover-farge på checkbox i confirmationpanel

* 💄 copybutton hover-text action

* 💄 dropdown, helptext hover-text

* 💄 link og linkpanel actionsfarger

* 💄 Search action-farger

* 💄 select action-farger

* 💄 Stepper action

* 💄 Textarea action

* 💄 Textarea og textfield colors

* 🐛 Riktig hover-bakgrunn på combobox selected option

* 📝 Changeset

* 📝 changeset tokens

* 📝 Dokumentert nye tokens

* [V6] Native ESM-støtte 🎉  (#2677)

* 🎨 Fungerende cjs/esm bundle med use-client

* 🎨 Oppdatert dir-output i for esm

* ⬆️ Bump date-fns og react-day-picker

* 🎨 oppdatert date-fns imports

* 🐛 Endret bruk av reat-day-picker i monthpicker

* 🐛 Fikset rendring av button i Datepicker-row

* ♻️ Bruker date-fns imports ssom støtter v2 og v3

* ⬆️ Synced date-fns versions

* ✨ Astro testmiljø

* 📝 Changeset

* 🎨 Skriver packagejson med type for esm

* 🔥 Fjernet .yarn/* fra astro

* 🎨 La til .yarn i gitignore for astro

* ⏪ Bruker riktig ds-react versjon

* ⬆️ Lik tsconfig som ds-react i aksel-icons

* 🐛 La tilbake provernance

* 🐛 Undo Day/Row fix fra main

* 🔥 Fjernet mulighet til å laste date-fns v2

* 🔥 Fjernet fs-extra dependency

* 🐛 Fikset feil versjon på core/react

* [V6] React-pakker støtter nå native SSR ved å bruke `use-client` 🎉  (#2707)

* 🎉 use-client blir lagt til på export av ds-react og aksel-icons

* 🎉 La til nextjs med appdir for testing

* ⚡ Tom yarn.lock med i git

* 📝 changeset

* 📝 Oppdatert migration-guide

* Update @navikt/aksel-icons/config/index-template.js

* 🐛 Async-lasting av date-fns er nå v3 esm compliant

v3 av date-fns støtter ikke default export/import, noe som brakk async-lasting da vi brukte .default

* Search: Ekskluder 'type' fra SearchProps (#2736)

* 🎉 Ny token icon-action-hover

* 🔥 Fjernet v6-endringer for ErrorSummary. Endringer vil bli gjort i en senere major-versjon

* OverridableComponent: Fikset feil som tillot vilkårlige props (#2739)

* 🔥 Fjernet migration.md

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-02-19 14:03:17 +01:00
github-actions[bot]andgithub-actions[bot] aa438a998f Version Packages (#2741)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-02-19 11:34:15 +01:00
Ken 74216b6bc9 🎉 Fikset regresjon ved bruk av portal i tooltip (#2738) 2024-02-19 11:31:26 +01:00
github-actions[bot]andgithub-actions[bot] e5ecd66a57 Version Packages (#2732)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-02-19 10:11:11 +01:00
Ken 78817fef45 [Aksel.nav.no] Uxtweaks-card på forside (#2735)
* 🎉 Uxtweaks-panel på forsiden til Aksel

* 🎨 Flyttet uxtweaks-box til under god-praksis panel

* 🎨 Panel har nå aside med role presentation

Dette gjør at skjermlesere hopper over 'complementary' og kommer rett til heading

* 💄 Oppdatert heading-tekst
2024-02-16 16:38:46 +01:00
Halvor Haugan 38357b1a2e Oppdatering av eksemplene på Skeleton (#2734) 2024-02-16 13:14:43 +01:00
KenandHalvor Haugan 65c17db2e5 Oppdatert Modal Context til nytt createContext-api (#2714)
* ♻️ Oppdatert hvordan ModalContext leveres

* 🏷️ onBeforeClose krever nå boolean

* ♻️ Undo rename av Modal.types for å unngå conflict

* 📝 Changeset

* 🔥 Fjernet unødvendig story-oppdatering

* 🐛 Fikset forwardRef i createContext

I tilfellene der ref blir sendt inn som en context-value, ble den tidligere slettet av React (native oppførsel)
ForwardRef lar oss beholde ref og sende den inn som context-value

* Endring av strict

* null -> undefined

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2024-02-15 19:40:46 +01:00
Halvor Haugan 59e88773d1 🎨 prettier 2024-02-15 09:37:23 +01:00
Ken f175d0f781 🧪 ToggleGroup test (#2728) 2024-02-14 16:50:09 +01:00
Ken 18419f7d98 Stories refactor (delvis) for chromatic (#2721)
* ♻️ Oppdatert Accordion-story

* ♻️ Oppdatert Chat-story

* 🐛 Chromatic story var slått av

* 🎉 ♻️ Typo-stories oppdatert for chromatic

* ♻️ Tokens-stories

* ♻️ Oppdatert Table-stories
2024-02-14 09:43:10 +01:00
Ken f63a7ec36d 📄 Oppdatert License timestamp fra 2023 -> 2024 2024-02-09 09:44:55 +01:00
Halvor Haugan 107489bd3f [aksel.nav.no] 🔥 Fjern noAmps fra InlineCode (#2719) 2024-02-08 15:11:43 +01:00
github-actions[bot]andgithub-actions[bot] 792962592f Version Packages (#2720)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-02-08 13:08:21 +01:00
Ken 4a02a1987c Deprecate Panel (#2712)
* ⚰️ Markert Panel som deprecated

* 📝 Changeset

* 📝 JSDOC var feil for border på Box

* 🐛 📝 JSDoc manglet border-radius
2024-02-08 11:46:20 +01:00
Ken 700943b4a5 [ci skip] ♻️ Refaktorert Button-story 2024-02-07 20:31:25 +01:00
Ken 521c982457 🚚 Oppdatert imports til direkteimports og ikke fra root-index (#2715) 2024-02-07 16:17:17 +01:00
Ken 8c17099087 🔥 Fjernet hyphen på blogg-headings (#2711)
* 🔥 Fjernet hyphen på blogg-headings

* 🎨 Bare hyphens på mobil
2024-02-07 13:42:58 +01:00
Ken 29241a7153 ⚡ Refaktorert alert-stories for mindre chromatic-tester (#2709)
* ⚡ refaktorert alert-stories for mindre chromatic-tester

* 🐛 Fikset imports
2024-02-07 13:42:26 +01:00
github-actions[bot]andgithub-actions[bot] 7e4ee40a7f Version Packages (#2708)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-02-07 12:26:07 +01:00
Halvor Haugan 2be97970d6 Date/MonthPicker: Justeringer JSDOC og eksempel-desc (#2704) 2024-02-07 09:42:37 +01:00
Halvor Haugan 5b3c1f33c4 Eksterne typer kommer nå med i docgen (#2705) 2024-02-07 09:30:27 +01:00
KenandHalvor Haugan f44ff44410 Bytter ut FloatingPortal med egen implementasjon (#2697)
* 🎉 Egen Portal-komponent

* 🎨 Portal og Overlay exportert i root

* ♻️ Tooltip bruker egen Portal

* 📝 Changeset

* 🔥 Fjernet ID på Portal-element

* 🎉 Ny type WithAsChild

* ♻️ Mer robust sjekk for conditional elements i WithAsChild

* 📝 WithAsChild JSDOC

* 📝 WithAsChild JSDOC 2

* Update .changeset/lovely-points-heal.md

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* ♻️ Fikset kommentarer fra git-pr

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-02-06 18:02:00 +01:00
Ken 855669538e ⚡ Kjører bare release-workflow når nødvendige filer er endret (#2701) 2024-02-06 18:01:43 +01:00
github-actions[bot]andgithub-actions[bot] 3d830dc123 Version Packages (#2703)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-02-06 13:56:46 +01:00
Ken dcca2a9560 Expansioncard padding top (#2699)
* 🎉 Justert padding for expansioncard small

* 🎉 Justert padding for expansioncard small
2024-02-06 13:10:08 +01:00
Ken 26fb028f07 ⚡ Filterer ut chromatic-snapshots for build-files (#2700) 2024-02-06 11:59:51 +01:00
Halvor Haugan d928769d6f [aksel.nav.no] Fiks for teksting i video 2024-02-05 14:55:22 +01:00
Julian Nymark e96d33d13e 👷 update permissions (removed too much) 2024-02-05 14:35:38 +01:00
Julian Nymark 00ebe1c18b 👷 update workflow (post merge) 2024-02-05 14:31:51 +01:00
Julian NymarkandKen 53be894ad0 Gp popular articles (#2647)
* ❇️ new schema for view tracking

* 🚧 wip for article views schema

* 🚧 wip on schema

* 🚧 schema changes for ArticleViews

* 🚧 run prettier with new config

* 🚧 deno script to update article views

* 🚧 working sanity document updates with bogus view data

* 🚧 helper to delete all article_views

* 🚧 add views_day

* ✨ working update for views on all gp articles

* 💄 eye icon for page views in sanity studio

* ♻️ cleanup from PR review / huddle

* 🚧 improvements to updateViews script

* 🚧 seemingly healthy queries (sometimes proxy gives stale data?)

* 👷 add .github/workflow for update views

* 👷 update .github/workflow for update views

* 👷 add env var in workflow

* ♻️ refactor from PR comments

* ♻️ refactor from PR comments

* ♻️ refactor from PR comments

* ♻️ refactor from PR comments

* ♻️ refactor from PR comments

* ♻️ refactor from PR comments

* ♻️ refactor from PR comments

* 👷 update workflow

* 🐛 correct paths to changelog script

* 🐛 remove unused ?? -1

* 👷 dockerfile and naisjob.yml

* 👷 yml variable formatting

* 👷 yml update

* 👷 yml variable formatting

* 🔨 .prettierignore for all yml/yaml starting with nais

* 👷 unique name for naisjob

* 👷 new nais yaml

* 👷 yml variable formatting

* 👷 remove workflow, the workflow is developed in main

* 👷 update yml

* 🚧 update naisjob yml

* 🚧 update naisjob yml

* 🚧 update Dockerfile

* 🚧 update Dockerfile (permissions)

* 🚧 update Dockerfile

* 🚧 update Dockerfile

* 🚧 update Dockerfile

* 👷 decouple config code from rest of repo (more duplication, more robustness), build with correct docker context

* 👷 cache deps in dockerfile on build-time (no need to fetch at runtime and add to pod AccessPolicy)

* 👷 relative path might work, test Dockerfile live as it works fine locally... buildx?!

* 👷 test github action docker context tweak

* 👷 test script command entrypoint (workdir is not project root)

* 👷 add AccessPolicy for reops-proxy

* 👷 better github workflow naming

* 👷 refactor _and_ optimize the dockerfile

* 👷 new docker command path for nais yml

* Update scripts/article-views/queries.ts

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* 👷 do not add rows if no data

* 🐛 fix sanity query) + now delete + update in single transaction

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-02-05 14:29:14 +01:00
Julian Nymark 614946097e [aksel.nav.no] ♿ forbedret Video-modul (#2693) 2024-02-05 14:09:43 +01:00
github-actions[bot]andgithub-actions[bot] 74ac20ea7c Version Packages (#2696)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-02-02 17:54:34 +01:00
Ken d299137774 🐛 Bleed håndtere reflectivePadding og marginInline Full riktig (#2695) 2024-02-02 17:52:45 +01:00
Julian Nymark 304f6d6a12 👷 test workflow changes (update-article-views) 2024-02-02 15:44:15 +01:00
Halvor Haugan bf6952c2b2 Oppdatering av eksempler på ReadMore (#2691) 2024-02-02 09:59:04 +01:00
github-actions[bot]andgithub-actions[bot] 7705dd4ae5 Version Packages (#2692)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-02-01 14:37:43 +01:00
Halvor Haugan d9ce1299d9 🐛 Textarea: maxLength virker nå med onChange uten value (#2690) 2024-02-01 14:29:56 +01:00
Julian Nymark 0890eed59e 👷 better github workflow naming 2024-02-01 14:24:10 +01:00
Ken dbd7150762 🐛 Sletting av innholdstyper i CMS brakk deploy av Aksel, nye /gp-sider gir nå 404 uten riktig data 2024-02-01 10:14:24 +01:00
Ken 58933e2584 🎨 Bedre kopi visning av designtokens + refererer ikke til nav-red lengre (#2689) 2024-02-01 09:17:21 +01:00
Julian Nymark 86279919c8 👷 test github action docker context tweak 2024-01-31 17:46:37 +01:00
github-actions[bot]andgithub-actions[bot] 8866572e69 Version Packages (#2686)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-01-31 11:33:47 +01:00
a1accdbd95 ✨ suggest some .vscode workspace settings.json / extensions.json (#2664)
* ✨ suggest some workspace settigs / extensions.json

* 🚚 css-custom-properties -> css-variable-autocomplete

* Update .vscode/settings.json

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🔥 remove some extensions

* ✨ add some settings

* 🔥 remove wrongly added files to branch

* Update .vscode/settings.json

* Update .vscode/settings.json

* Update .vscode/settings.json

* 🎨 Fjernet noen uødvendige extensions

* 🎨 La til lokal TS-bruk

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2024-01-31 10:47:11 +01:00
Ken fdfdebfa99 🐛 Sentrering av checkmark i Checkbox (#2682)
* 🐛 Checkmark er nå alltid sentrert i checkbox

* 📝 Changeset

* Update @navikt/core/css/form/radio-checkbox.css
2024-01-31 10:47:02 +01:00
Halvor Haugan 56abe568e2 Textarea: debounce ResizeObserver for å unngå feilmelding (#2685) 2024-01-31 10:46:29 +01:00
Halvor Haugan 34acbb87a5 🐛 Textarea: Sett riktig høyde når brukt i Modal + StrictMode (#2679) 2024-01-31 10:35:43 +01:00
Ken fd479e3160 🐞 Datepicker Day Button (#2678)
* 🐛 Fikset Datepicker Day-button

* 📝 Changeset

* 🔥 Fjernet ubrukt referanse til DayButton i Datepicker
2024-01-31 10:30:37 +01:00
github-actions[bot]andgithub-actions[bot] 03ca21b4f6 Version Packages (#2683)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-01-30 22:09:38 +01:00
Vilde Roksand Fauchald e7804297bf Eksponer variabelen "role" i Search-komponenten (#2667)
* expose role variable so its possible to change it

* changeset
2024-01-30 22:07:49 +01:00
github-actions[bot]andgithub-actions[bot] a246c9d707 Version Packages (#2681)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-01-30 16:49:36 +01:00
d3fb3d4d96 🔴 Støtte for høykontrast i komponenter (#2680)
* 💄 Accordion tilpasset høykontrast

* 💄 Alert tilpasset høykontrast

* Legg til tokens for high contrast border og -border width. Tanken er å kunne gjenbruke på tvers av komponenter.

* 💄 Tooltip tilpasset høykontrast

* 💄 ToggleGroup tilpasset høykontrast

* 💄 bedre fargebruk på Accordion

* 🐛 Fjernet deprecated systemfarger

* 💄 alert-farger

* 💄 chat tilpasset høykontrast

* ♿ button css for high contrast

* ♿ Radio og checkbox høykontrast

* ♿ Chips høykontrast

* ♿ ConfirmationPanel høykontrast

* ♿ Tab høykontrast

* ♿ Tabs høykontrast

* ♿ Textfield høykontrast

* ♿ Textarea høykontrast

* ♿ Skeleton høykontrast

* ♿ Link høykontrast

* ♿ LinkPanel høykontrast

* ♿ ExpansionCard høykontrast

* ♿ high contrast CSS for select & datepicker / monthpicker

* ♿ Loader høykontrast

* ♿ dropdown høykontrast

* ♿ HelpText høykontrast

* ♿ Popover høykontrast

* ♿ Switch høykontrast

* ♿ high contrast CSS for ReadMore

* ♿ high contrast CSS for CopyButton

* ♿ high contrast CSS for InternalHeader

* ♿ Modal highcontrast

* ♿ Search høykontrast

* 💄 Timeline tilpasset høykontrast

* ♿ high contrast CSS for Stepper

* ♿ Combobox høykontrast

* Fix "diamond"-shape that should be an "arrow" in Timeline popover

* ♿ high contrast CSS for Switch (small tweaks)

* ♿ high contrast CSS for Switch (remove unused css)

* 🐛 Riktige fokusmarkeringer på radio/checkbox

* chips

* 🐛 Fikset ToggleGroup høykontrast

* 📝 Changeset2

* 🔥 Fjernet high-contrast token fra ds-tokens

* ♿ high contrast CSS for checkbox (tweaks)

* 🔥 Fjernet disabled-prop på radio-story

* Timeline focus in high contrast mode

* 🐛 Fikset fokusmarkering på radio/checkbox

* 🐛 Highlighting av outline var feil satt på ToggleGroup

* 📝 Highlight -> highlight

---------

Co-authored-by: Vegard Haugstvedt <it.vegard@gmail.com>
Co-authored-by: Julian Nymark <julian.nymark@nav.no>
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2024-01-30 16:47:26 +01:00
Julian Nymark d734d3071b 👷 update workflow for chromatic (stop old running action when new is created) 2024-01-30 16:22:04 +01:00
github-actions[bot]andgithub-actions[bot] 8d97bba1fe Version Packages (#2673)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-01-30 15:07:56 +01:00
Ken eff9b5ecce LocationPin-ikon (#2672)
* ✨ LocationPin ikoner

* 📝 Changeset

* Update .changeset/afraid-oranges-grow.md
2024-01-30 14:39:37 +01:00
Halvor Haugan 71fc90b301 Endring av kodeeksempler for CopyButton (#2674) 2024-01-29 19:30:35 +01:00
Ken e1d5e1b505 [tailwind] MaxWidth-token brukt for text i tailwind (#2652)
* ✨ Ny tailwind-token

* ♻️ maxWidth er nå lettere å forstå
2024-01-29 15:51:22 +01:00
Julian Nymark 45d4f6c478 Merge branch 'main' of github.com:navikt/aksel 2024-01-29 13:05:46 +01:00
Julian Nymark 2564e84b9c 👷 update workflow 2024-01-29 13:05:16 +01:00
Halvor Haugan e5637c64a8 Rename main.mts -> .ts (#2670) 2024-01-29 09:00:34 +01:00
Julian Nymark 82a1f32542 👷 update workflow 2024-01-26 15:21:38 +01:00
Julian Nymark a8d4b1e23e 👷 update workflow 2024-01-26 15:19:08 +01:00
Julian Nymark d50ebebad6 Merge branch 'main' of github.com:navikt/aksel 2024-01-26 14:51:17 +01:00
Julian Nymark e292e83128 👷 update workflow 2024-01-26 14:51:07 +01:00
23c472e60b ✨ Combobox: Mulighet for å begrense hvor mange valg bruker kan ta (#2260)
* yarn lock

* setting up maxSelectedOptions

* added correct margin

* Update tsconfig.build.json

* Make border of "max selected"-item in FilteredOptions overlap the list border

* Hide "add new value"-button if "max selected"-limit is reached

* Make MaxSelected example a bit more interactive

* wip styling max-selected option

* Disable filteredOptions that are not selected when maxSelectedOptions is reached

* Fix scrolling/clipping content in FilteredOptions

* Remove hover-effects from non-selectable options

* add prop so user can customize message shown when max num of choices reached

* Operate directly on the DOM nodes when moving virtual focus, instead of relying on index state.

The index state became stale/non-synced when replacing elements in the list.

* make maxSelectedMessage static

* Remove max-selected:hover

Co-authored-by: Vegard Haugstvedt <it.vegard@gmail.com>

* yarn lock update

* 'cursor: not allowed' only hits disabled options

* remove li-margins, add ul-gap with negative margin on max-selected-option

* remove 'a' from initialstate maxSelectedOptions Story

* Update @navikt/core/css/form/combobox.css

* Update @navikt/core/css/form/combobox.css

* Update @navikt/core/react/src/form/combobox/FilteredOptions/FilteredOptions.tsx

* Update @navikt/core/react/src/form/combobox/FilteredOptions/useVirtualFocus.ts

* Update @navikt/core/react/src/form/combobox/FilteredOptions/useVirtualFocus.ts

* Update @navikt/core/react/src/form/combobox/combobox.stories.tsx

* type assertion

* remove tab-index on wrapper div

* prototype for sticky non-selectable options

* "yarn lock"

* Fix feil med at focus-indikator for input-feltet ikke ble vist

* Forenkle og fikse "scroll til element" i FilteredOptions

* Sørg for at disabled FilteredOptions ikke vises under "max antall"-meldingen

* Focused option should not be covered by "max selected" message

* yarn lock

* Fix "scrollIntoView is not a function" error. Possibly needs to be checked for when it occurs, but I haven't figured it out yet

* Loading indicator is no longer exposed as an option, so we have to just search for it by the accessible name.

Should have been able to use findByRole("graphics-document", { name: "Søker..." }), but that is currently broken:
https://github.com/testing-library/dom-testing-library/issues/1131

* Aria-selected should not be placed on elements that are no longer role="option"

* Combine all "max selected options"-related props in one object

* Proper BEM syntax should use -- instead of __ for state-like classes, like --loading, --max-selected and --new-option

* Always show selected options in FilteredOptions, even if they don't match the search text

* Only to the getElementsAbleToReceiveFocus() call once per function, to reduce DOM lookups. Also changed isFocusOnThe[Top | Bottom] to functions, because it was needed for isFocusOnTheBottom to follow the same rule (and not store the value on the top level in the hook.

* Pressing "End" should not only move focus to the end of the list, but also open the list if it is closed. To mirror this, we close the list if moving focus back to the Input with "Home".

* Legg til Aksel-eksempel

* yarn changeset

* Update @navikt/core/css/form/combobox.css

* change 'maxSelectedOptions' prop to 'maxSelected'

* Mark disabled options with aria-disabled

* Add max selected text to aria-describedby, so it is announced when the user enters the input field

* Add role="status" to the wrapper for "no hits", "loading" and "max selected" info messages, so they are announced when they appear

* Remove aria-selected (again)

* fix: form error not showing correctly

* fix: rm left hover-border on add-new-option item

* Bare åpne listen som default, men la intern logikk styre etter første render

* Sticky trenger ikke ligger på hver enkelt av disse, da parent wrapperen også er sticky

* Combobox eksempler var ikke tilgjengelig i `yarn storybook:aksel` på grunn av manglende Demo-eksport

* Fjern ubrukt klasse som er i konflikt med navds-combobox__wrapper

* Trengs ikke etter at max selected ble flyttet ut av listen

* Denne koden gjør ingenting

* Trenger ikke bruke :not, fordi vi tok vekk data-no-focus i en commit tidligere i dag

* Bruk dynamiske selectedOptions for å kunne endre de

* Update @navikt/core/css/form/combobox.css

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update @navikt/core/react/src/form/combobox/FilteredOptions/FilteredOptions.tsx

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>

* Update aksel.nav.no/website/pages/eksempler/combobox/with-max-selected-limit.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/css/form/combobox.css

* Do not render an empty ul for FilteredOptions, as it add a gap at the bottom of the container

* Do not render an empty non-selectables container, as it adds a gap at the top of the container

* Non-selectables should not have navds-combobox__list-item class, as it introduces a few issues with hovering, etc.

* Copy-pasted in an extra class that broke styling for max selected

---------

Co-authored-by: Vegard Haugstvedt <it.vegard@gmail.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-01-26 14:24:35 +01:00
Halvor Haugan 058e012c26 [aksel.nav.no] Endret ord i OutdatedAlert 2024-01-26 14:11:39 +01:00
Julian Nymark ffce1f75ae 👷 update workflow test 2024-01-26 11:23:35 +01:00
Julian Nymark 46e5ffb6e4 👷 test new workflow 2024-01-26 11:11:46 +01:00
Ken d9696b3617 ⬆️ Sync yarn lock (#2669) 2024-01-25 20:52:12 +01:00
Halvor Haugan df1efb2748 Oppgradering av pakker i figma-plugin (#2661) 2024-01-25 11:32:13 +01:00
Julian Nymark 2b23f6ab91 👷 force push github workflow 2024-01-24 15:18:55 +01:00
Ken 01d422b01f 🐛 Fikset default-visning av bloggposter (#2657) 2024-01-24 09:49:20 +01:00
Halvor Haugan 8936db096f [aksel.nav.no] prettier-plugin-sort-imports (#2662) 2024-01-24 09:47:12 +01:00
Andreas NordahlandKen b66ad3673b Ny styling av inline code (#2660)
* forslag til ny styling av code

* Update aksel.nav.no/website/components/website-modules/InlineCode.tsx

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-01-23 21:21:53 +01:00
Andreas Nordahl 16eff2ce93 use noAmps for InlineCode in SanityBlockContent (#2659)
I en brukertest av Golden Path for frontend skapte fnuttene forvirring i inline code. Jeg tror det beste er å bare fjerne de.
2024-01-23 21:21:00 +01:00
Ken bdc0815dd7 Nytt eksperimentelt API descendants (#2586)
* 🎉 Ny hook og API 'descendants'

* 📝 Bedre storiers

* 🐛 Fikset type-mismatch mellom create-context og useDescendant

* 🐛 Fikset value setting i provider

* 🏷️ Fikset kommentert ut ts-feil

* 🎨 tester bruk av disabled

* 🔥 Fjernet unødvendig id-kobling i descendants typer
2024-01-23 15:28:12 +01:00
Halvor Haugan 4c5cdb22e9 [aksel.nav.no] Vis advarsel på gamle gp-artikler (#2650) 2024-01-23 13:24:59 +01:00
Halvor Haugan a1e74fa9bd Oppdater dependencies shadow-dom eksempel (#2656) 2024-01-23 11:16:19 +01:00
Halvor Haugan d5e5a6c64f Justering av eksempler på ExpansionCard (#2653) 2024-01-19 14:19:57 +01:00
Halvor Haugan 11e3a18526 Fiks clean (#2651) 2024-01-19 09:22:09 +01:00
Halvor Haugan 930c772bd6 [aksel.nav.no] Separat artikkelside for nye God praksis (#2648) 2024-01-18 13:50:40 +01:00
Halvor Haugan ade5d59392 [aksel.nav.no] Fjern forwardRef i ShowMore (#2649) 2024-01-18 13:49:04 +01:00
Julian Nymark d90fe26e26 popular articles (#2628)
* ❇️ new schema for view tracking

* 🚧 wip for article views schema

* 🚧 wip on schema

* 🚧 schema changes for ArticleViews

* 🚧 run prettier with new config
2024-01-17 15:26:48 +01:00
Andreas Nordahl 13b148aab6 Add dockerfile and yaml to syntax highlighting (#2638)
* Add dockerfile and yaml to syntax highlighting

* Remove dockerfile as it is not supported ootb
2024-01-17 12:31:13 +01:00
github-actions[bot]andgithub-actions[bot] 6abc1c0f3b Version Packages (#2644)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-01-17 11:14:41 +01:00
Ken 1177b36f48 🐛 HelpText-state ble ikke riktig oppdatert ved klikk (#2643) 2024-01-17 11:13:00 +01:00
Ken 1580290da0 🐛 Artikler uten riktig tema ble vist på forside 2024-01-16 16:19:21 +01:00
Ken b0b3b5e477 ⚡ Er nå mulig å opt-out fra chromatic (#2630) 2024-01-16 14:16:07 +01:00
Ken ef07a8ec0f 🐛 Fikset deploy av Aksel.nav.no (#2636) 2024-01-16 14:14:53 +01:00
Ken 52147b377c ✨ createContext-utility (#2619)
* ✨ createContext-utility

* ♻️ Oppdatert createcontext med bedre API

* 📝 Oppdatert kommentarer
2024-01-16 14:05:46 +01:00
github-actions[bot]andgithub-actions[bot] 515eabb2a5 Version Packages (#2633)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-01-16 13:08:35 +01:00
Ken 074f94184a 🔥 Fjernet hotjar fra nettside-bundle (#2626) 2024-01-16 13:05:44 +01:00
Ken 9c5288c405 [Ikoner] Synket ikoner med Figma (#2629)
* ✨ Synket ikoner

* :coffing: Fjernet ikoner med [ignore-docs] i descrption

* ✨ Nytt ikon FigureChild

* 📝 changeset

* 🐛 La tilbake ikoner som ble slettet
2024-01-16 13:05:21 +01:00
Halvor Haugan 4cad349f63 AnimateHeight: Refaktorerte sjekk av prefers-reduced-motion (#2624) 2024-01-16 12:17:41 +01:00
Halvor Haugan fa8b63706b ESLint: Legg til regel array-type (#2615) 2024-01-16 10:03:59 +01:00
github-actions[bot]andgithub-actions[bot] 2e36d59533 Version Packages (#2616)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-01-16 08:25:51 +01:00
Ken 4c6cecb94f 🚚 Ryddet util-mappe (#2618)
* 🚚 Flyttet useClientLayoutEffect

* 🚚 Flyttet useEventListener

* 🚚 Flyttet resterende hooks

* 🎨 Oppdatert imports av hooks

* 🚚 Flyttet Randomicon util til link-ikon

* 🚚 Flyttet overridablecomponent inn i egen types mappe

* 📝 Changeset
2024-01-15 13:36:27 +01:00
Ken 99adb77c31 🐛 Togglegroup på ikonside overlapper ikke lengre (#2614) 2024-01-15 12:34:01 +01:00
Ken 2d6cab7878 [Table] DataCell og HeaderCell støtter nå size-prop for font-size (#2613)
* ✨ Size-prop på HeaderCell og DataCell

* 🎨 Stories for size-test i table-cells

* 📝 Changeset

* ♻️ size -> textSize for datecell og headercell

* 🐛 Fikset changeset?

* Update @navikt/core/react/src/table/DataCell.tsx

* Update @navikt/core/react/src/table/HeaderCell.tsx
2024-01-15 09:09:39 +01:00
Halvor Haugan cf94da5ab6 Migrere til @storybook/test (#2617) 2024-01-15 09:07:46 +01:00
KenandHalvor Haugan f707b2211b ♻️ Ny utility composeEventHandlers (#2610)
* 💄 Synket prettier

* ✨ ComposeEventHandlers

* ♻️ Button composeEvent

* ♻️ chips composeEvent

* ♻️ copybutton composeEvent

* ♻️ composeEventhandlers dropdown

* ♻️ composeEventhandlers react-more, stepper

* ♻️ composeEventhandlers expandablerow

* ⚰️ Fjernet deprecated prop fra tooltip

* ♻️ composeEventhandlers searchbutton

* 📝 Changeset

* Update @navikt/core/react/src/util/composeEventHandlers.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🔥 Fjernet as unknown as event i composeEventhandler

* ♻️ Forenklet if-tester, la tilbake kommentarer 📝

* 📝 Oppdatert jsdoc

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-01-12 20:32:51 +01:00
Ken 2fedeab605 🐛 Checkbox nested i CheckboxGroup mister nå ikke padding (#2612)
* 🐛 Checkbox nested i CheckboxGroup mister nå ikke padding

* 🐛 Økt spesifisitet for checkbox i table
2024-01-12 20:30:54 +01:00
KenandHalvor Haugan b251e3f52d Ny hook useMergeRefs som erstatter mergeRefs (#2609)
* 🎨 Fjernet mergeRefs fra exponert API

* ♻️ Oppdatert bruk av mergeRefs -> useMergeRefs-hook

* Update @navikt/core/react/src/util/hooks/useMergeRefs.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-01-12 15:39:02 +01:00
Ken 793998faa2 📝 Eksempler for controlled switch (#2595)
* 📝 Eksempler for controlled switch

* 🔥 Fjernet console.logs

* ♻️ Mer beskrivende eksempel for controlled-value eksempel

* ♻️ Bedre praksis for switch-eksempler
2024-01-12 14:59:16 +01:00
Ken 642f188fa7 [Tag][Feature] Tags med ikon (#2611)
* 🎉 Tag har nå egen icon-prop

* 🎨 Tag.css tilpasset ikoner

* 📝 Storybook-demo for tags + ikoner

* 📝 Aksel-demo for tag

* 📝 Changeset

* 🔥 Fjernet iconPosition-prop fra tag.tsx

* 🧪 Oppdatert stories med nye props

* 🔥 Fjernet iconPosition-demo i Tag fra nettside

* 🔥 Fjernet gammel css for iconPosition right tag.tsx
2024-01-12 13:19:19 +01:00
Halvor Haugan 9297d90e91 Fikset story for HelpText (#2608) 2024-01-12 09:10:51 +01:00
KenandHalvor Haugan ef9b1201b3 🐛 Storybook html-addon brakk på grunn av prettier v3 (#2606)
* 🐛 Storybook html-addon brakk på brunn av prettier v3

* yarn lock

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2024-01-11 15:33:10 +01:00
Halvor Haugan 7bc697b515 HelpText: Justert eksempel og refaktorert type (#2607) 2024-01-11 15:16:39 +01:00
github-actions[bot]andgithub-actions[bot] a6baa67360 Version Packages (#2604)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-01-11 12:20:57 +01:00
Ken 145ce2e5f7 Page maxWidth-token (#2572)
* 🎨 La til ny token

* 🐛 maksbredde var kalkulert feil

* 💄 CSS for max-width text

* 📝 Changeset og bedre dokumentasjon

* 🐛 Docs for max-width token

* 🎨 tailwind-støtte for ny maxWidth-token

* 🎨 rem -> px

* 📝 Dynamic padding-inline -> gutters

* ♻️ Fjernet duplikat padding-inline

* ♻️ Oppdatert token-navn fra max-width-text -> text-width-max

* 🐛 Fikset key i token-docs

* 📝 Changeset for ny token
2024-01-11 12:10:37 +01:00
Ken 557786bd51 Prettify repo (#2599)
* 🧪 Oppdatert prettierignore

* 🧪 Oppdatert prettierignore og prettier plugins

* 🎨 Workaround for prettier error i svgr https://github.com/gregberge/svgr/issues/893\#issuecomment-1806701981

* 📝 Fjernet exclude av aksel-icons/src folder for prettier

* 🐛 Tester ble ikke ekskludert av prettier

* 💄 Prettify repo
2024-01-11 12:10:28 +01:00
Ken 76eefdf8b1 UseControllableState-API (#2585)
* 🎨 Added useControllableState

* 🎨 Forbedret Accordion-api for controlled

* 🎨 Forbedret readmore-api for controlled

* 🎨 Forbedret internt expandablerow-api for controlled open

* 🎨 Forbedret tooltip-api for controlled open

* 🎨 Forbedret dropdown-api for controlled open

* 📝 La til dokumentasjon

* 📝 changeset

* 📝 Bedre kommentarer

* 🎨 Forenklet hooks

* 🎨 DefaultValue er required i useControllabeState
2024-01-11 10:05:21 +01:00
github-actions[bot]andgithub-actions[bot] 3ee714e903 Version Packages (#2602)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-01-10 13:38:28 +01:00
Ken ffbe5b9d31 🚑 Monthpicker Caption-hotfix (#2601)
* 🐛 MonthCaption disabled prev/next-knapper når de skulle være enabled

* 📝 changeset
2024-01-10 13:36:10 +01:00
Ken 2a999286ca ⚡ Erstattet pretty-quick med lint-staged (#2597)
* ⚡ Erstattet pretty-quick med lint-staged

* ⬇️ Bruker eldre versjon av prettier (cjs) for codemod-tester

* 🐛 Bruker nå root prettie-versjon for codemods, bruker-experimental-vm-modules for codemod-jest
2024-01-09 17:48:29 +01:00
Halvor Haugan d29672d450 Fiks lint-kommandoer i Windows (#2596) 2024-01-09 11:20:58 +01:00
KenandJulian Nymark c7817b7cde [aksel.nav.no] Merge prototype for ny god praksis inn i main (#2570)
* 🎉 Boilerplate setup god-praksis

* 🚚 Moved to parts-folder

* 🎨 Hero-layout

* ✨ Hero story

* ✨ ChipNav stories

* 🐛 Fikset overalapping svg

* 🎉 Flere hero-stories

* 🐛 Fikset cutoff i hero-svg

* 🚧 bento article cards

* 🚧 bento & grid placeholders

* 🚧 correctly make all the card grids use HGrid

* 🚧 remove css

* 🚚 Restructure gp-parts

* 🏷️ rename chipsnav

* 💄 CSS for chips-scrollbar

* 🎨 Fade-scroll chips

* 💄 v1 chips

* 🐛 chips overflow-button width

* 🐛 Fikset gp-template

* 🎉 query navigation in chips

* 🚧 groq and cards

* 🐛 Padding for chips to avoid clipping on focus

* 🎉 Oppdatert visning i sanity for undertema/innholdstype

* ⚡ Serversideprops

* 🔥 Fjernet labels fra template

* 🔥 Fjernet slug-bug

* 🚧 add slugs to cards so their links work

* ⚡ forsidequery for tema

* 🐛 Fixed missing }

* 🎨 Tema-selector

* 🏷️ rename tema-data

* 🏷️ Query and ts cleanup

* 🚧 new sticker

* 🎨 Temavisning i hero

* 🎨 dynamiske chips

* 🎨 Dynamiske innholdstyper

* 🎨 Lagt til egen gp-page context

* 🎨 Hero bruker context

* 🔥 fjernet ubrukte props

* 🎨 Context in chips

* 🐛 fixed slug-resolve

* ⚡ Cleanup in article-view

* 🎨 Dynamic view of articles

* 🐛 Fikset data-entry

* 🐛 Resolvers for preview (still buggy)

* 🐛 Fixed resolvers

* 🐛 Fixed uncaught promise error

* 🎨 Fixed resolvers

* 🎨 Story update

* 🎨 Better hasRefs

* ⚡ StaticProps for index

* ⚡ Slug bruker staticprops

* ⚡ Slug bruker staticprops, oppdatert views

* 🎉 Modal i hero-nav

* 💄 cards use breakpoints

* ⚡ Limit initial article view-count

* 🚧 wip getting chipData into chips

* 🎨 WIP pagination

* ⚡ pagination

* 🔥 Fjernet comment

* 🐛 Fikset build

* 🎨 clean queries + minor styling update to cards

* ✨ now fetches & pre-renders correct chip data for innholdstype

* 🏷️ improve types

* ✨ undertema chip data & render

* 💄 more disabled looking 0 count chips (innholdstype)

* 📝 Comments

* WIP initial load data

* 🎉 Group-articles function with tests

* 🎉 Utility to get articles based on filter

* 🎨 Initial data now sent to page

* 🎨 Now uses preloaded data when navigating

* 🎨 Hook for å lytte til queries

* 🎨 Better initial load

* 🎨 Api-fetch based on filter

* 🐛 Still getting flash of wrong cards on initial load

* 🔥 unused styles

* ⚡ Simplified lazy-loading

* 🎨 animated cards

* 🎨 Better state-updates

* 🏷️ simplified article type

* 🏷️ Simpltified tema-types

* 🏷️ simplified innholdstype

* 🏷️ Cleanup for type-use in query

* 🔥 Removed unused sanity-data

* 🔥 Removed initial articles-fetch

* 🎨 Extracted setting of initial data

* 🎨 Tags on cards

* 🎨 Dynamic grid

* 🎨 Chips now shows for page-load

* 💄 dynamic grid for articles

* 🎨 dynamisk hero

* 📝 TODO for chips

* 📝 TODOS

* ✨ add (re-add?) parentheses to chipNav

* 🎨 Updated default-grid

* 🎨 Updated cards

* 🎨 Only current undertema is shown

* 🎨 Violet tags

* 🎨 Better hover on cards

* 🎨 Hide title on no data

* 🐛 load correct data into chipNav on [slug].tsx pages

* 🐛 "alle tema" page now also has working chip data

* ♻️ restructure before "alle tema" code

* ✨ working chipNav toggle counts

* 🎨 color label & chipNav

* 🎨 ChipsGroup

* 🚚 Moved chips to chipsgroup

* 🐛 Fikset hydration mismatch mellom server/client

* 🐛 List of articles were set in wrong chipnav

* 🎨 hero styling

* 🎨 Chip-label now breaks to column at md, not sm

* 🏷️ Fixed types

* 🎨 Hide paths in production

* 🎨 Mindre refactor av hero

* 📝 added todo

* 💄 Chips-styling

* 🎨 Chips-disabled

* 🎨 Chips-styling

* 🐛 Found edgecase bug when fetching initial articles

* 🎉 Bruker line-clamp for truncate

* ♻️ Bedre CSS-navn

* ♻️ article lengths som konstanter

* ♻️ Bedre scroll ved overflow av tabs

* 🐛 hero-cube ligger nå bak tekst

* 📝 Comments

* 📝 Skrivefeil

* 🐛 imports brakk tester

* 🚚 Flyttet queries og typer

* ♻️ god-praksis api er nå versjonert

* 📝 Organsiert typer

* :tuck: Flyttet API-queries ut til felles interface

* 🎨 Preview for gp/slug

* 🎨 Preview for gp/index

* 🎨 Synket hero med figma

* 🚚 Flyttet gp-schema inn i object

* 📝 Kommentert ut temp taxonomy widget

* 🎨 Gjemmer nye sanity-felt for prod-visning

* 🔥 Fjernet gammel hero-kode

---------

Co-authored-by: Julian Nymark <julian.nymark@nav.no>
2024-01-09 10:36:23 +01:00
Ken 5152ffa955 Update README.md 2024-01-05 14:11:17 +01:00
github-actions[bot]andgithub-actions[bot] 6c89a942d2 Version Packages (#2592)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-01-05 12:34:59 +01:00
Vegard HaugstvedtandKen 7a743b582f Radio component a11y fixes (#2562)
* Remove aria-invalid from individual Radio components because it is placed on the FieldSet

* Radio label and description should only be announced once with a screen reader

* Legg til mer realistiske tekster i eksempelet

* Checkbox label and description should only be announced once with a screen reader

When using multiple elements (span, etc) inside of a label, each one will be added as a screen reader "stop" and announced both as part of the label and as a separate text element.
Using this technique overrides this, to create the same experience as if the was only text inside of the label (native-like).

* Legg til mer realistiske tekster i eksempelet

* Remove aria-invalid from Checkbox and Radio, as it is redundant when we include an error message.

* Remove error message from example when we select an option

* Add error message to single description example to make it easier to test both

* Remove aria-describedby from Fieldset, because the error is connected to the input field

* 🐛 Fikset duplikat label-text funnet i tester

* Use local useId hook because of supporting React 17 and less

* Add changeset

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
2024-01-05 12:31:54 +01:00
Ken 42b31a0fe9 Stylelint v16 bug (#2591)
* 🐛 esm default export -> cjs module.export

* 📝 Changeset
2024-01-05 11:56:55 +01:00
Ken a4401b8535 🏷️ Bedre typet lokal useId (#2589) 2024-01-05 11:56:38 +01:00
github-actions[bot]andgithub-actions[bot] c67d3e3d1e Version Packages (#2590)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-01-04 20:17:12 +01:00
Ken 1b71fe01cb ExpansionCard divider (#2566)
* ♻️ Bruker tokens internt for padding, lagt til divider

* 🎨 transition on opacity

* 📝 Changeset
2024-01-04 20:10:35 +01:00
Ken 80c48cff0b Darkreader-støtte (#2588)
* 🐛 Darkreader støtte

* 🔥 Fjernet hardkodet bg
2024-01-04 15:15:23 +01:00
Ken 9c642c4e4d 🔥 Fjernet unødvendig workflow (#2578)
* 🔥 Fjernet unødvendig workflow

* 🔥 Fjernet ubrukt e2e-script
2024-01-04 10:11:55 +01:00
Halvor Haugan 6f53780c76 Justering av fokus-eksempel på ErrorSummary (#2577) 2023-12-21 12:48:27 +01:00
github-actions[bot]andgithub-actions[bot] a4eca33cfb Version Packages (#2571)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-12-20 13:45:33 +01:00
Halvor Haugan 65f6074fa8 📝 Modal: Oppdatert JSDoc (#2567) 2023-12-20 09:11:36 +01:00
Halvor Haugan 9b9ddd3d70 Sandbox: allow-modals (#2569) 2023-12-18 15:35:02 +01:00
github-actions[bot]andgithub-actions[bot] 35d49df393 Version Packages (#2565)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-12-18 14:09:41 +01:00
Ken ef947090f3 🐛 Fikset form-submition ved lukk av datepicker-modal (#2568) 2023-12-18 13:39:03 +01:00
Ken 58682f074e :ruler: Checkbox-scaling (#2563)
* :ruler: Checkbox-scaling

* ⚡ Forenklet checkbox checkmark-scaling
2023-12-17 17:47:30 +01:00
Halvor Haugan f278588f72 Justering av eksempler på Button (#2559) 2023-12-14 14:05:39 +01:00
github-actions[bot]andgithub-actions[bot] f9276ba3ca Version Packages (#2561)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-12-13 12:18:48 +01:00
Halvor Haugan 32c90444e6 Justering av eksempler på ToggleGroup (#2552) 2023-12-13 11:50:14 +01:00
Ken 7ff93e389f 🎉 Updated icons (#2538)
* ✨ Updated icons

* 📝 changeset

* 📝 yml update

* 🐛 Fixed paperplaneIcon

* 🎨 Tag-icon
2023-12-13 10:28:42 +01:00
Ken 3de1aac4c4 🐛 Fjernet location fra fuse-config (#2547) 2023-12-13 10:20:44 +01:00
Ken 7f066a27ee 🎨 Blogg-kategori under innhold-tab i sanity (#2557) 2023-12-13 10:20:21 +01:00
github-actions[bot]andgithub-actions[bot] 180b6f7af8 Version Packages (#2560)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-12-13 09:42:44 +01:00
Ken e77206da1a 🎨 Token for checkmark-circle (#2558) 2023-12-13 09:28:58 +01:00
Julian Nymark d66d90b326 🔥 fjerne illustration fra 404 (#2528)
* 🐛 optimize SVG for illustration on 404 page (nginx 414)

* 🔥 remove illustration from 404 templates

* 🚀 new version of 404 template

* 🎨 remove unnecessary HGrid on 404 template post illustration removal

* 🔥 also remove the HGrid for the examples
2023-12-08 11:26:06 +01:00
Halvor Haugan 39f9bc34a9 5XX-mal: Lenker for reload og tilbake, fjern global styles (#2544) 2023-12-08 09:57:48 +01:00
Ken ba54a28f50 Text-wrap: balance på blog og god-praksis heading (#2548)
* 🎉 Text-wrap: balance on headings

* 💄 Formating
2023-12-08 09:53:43 +01:00
Ken 7b56ae3013 ⬆️ Bump vite (#2549)
* ⬆️ Bump vite

* yarn lock-sync
2023-12-07 15:19:16 +01:00
github-actions[bot]andgithub-actions[bot] 874961ff7e Version Packages (#2543)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-12-05 11:57:14 +01:00
Vegard Haugstvedt df48236fc8 Fix issue where clicking Combobox.FilteredOptions after scrolling caused the wrong element to be selected (#2536)
* This onBlur triggered when clicking items in FilteredOptions, causing virtual focus to be moved and the list to scroll to the top.
Then, onPointerUp, we select the new element that has scrolled into position under the cursor.

* Added changeset
2023-12-05 09:58:17 +01:00
Halvor Haugan 65cc6f425d 🐛 Modal: Hindre at elementer med sr-only posisjoneres feil (#2541) 2023-12-05 09:06:58 +01:00
Ken 2d34691450 [Chromatic] Oppdatert chromatic + bruker turbosnap (#2533)
* 🎨 Update chromatic

* Testing turbosnap

* La til config for chroamtic i workflow

* Update .storybook/main.ts

* 📝 Update readme for chromatic test
2023-12-05 08:38:38 +01:00
Halvor Haugan 094f2b1c2b [aksel.nav.no] Justeringer i CodeExamples (#2530)
Blant annet ny parameter "compact" som gjør at koden skjules som standard og forhåndsvisningen får mindre vertikal padding.
2023-12-04 12:44:02 +01:00
Halvor Haugan fb1606d771 Fiks kodeeksempel "søk" på InternalHeader 2023-12-04 10:49:29 +01:00
Halvor Haugan ab62211743 Desc på header-eksempel "brukermeny" 2023-12-04 10:32:59 +01:00
Ken c3d9735ea7 [aksel.nav.no] ✨ MVP-Struktur for ny god-praksis (#2526)
* ✨ Nytt gp oppsett

* 🎨 Better structure

* 🔥 Fjernet referenceinput

* 🎨 bedre filterering av tags

* 🚚 Flyttet gp documents

* 🏷️ rename tags -> undertema

* 🔥 fjernet comments

* 🎨 låst til dev

* 🎨 Bedre filtrering ved valg av undertema i tema

* 🎨 Oppdatert artikkelmal

* 🚚 Rename tags -> undetema

* 🎨 Staging only for admins and devs

* 🎨 opt-in visning av god-praksis felter

* 🔥 Fjernet artikkelmal

* 🚚 tsx -> ts

* Rename label -> alias, fjernet undertema fra tema

* 🚚 Endret fra dev->prod datasett for staging

* ✅ Fikset sanitizeSlug normalize

* 🎨 riktige sanity-field for artikkel

* 🐛 Fikset publicationflow for staging

* 🐛 Fikset console-warnings for API-versjon
2023-12-04 10:13:30 +01:00
Halvor Haugan 1f16bfc866 [aksel.nav.no] Justering av eksempler på InternalHeader (#2531) 2023-12-01 09:50:27 +01:00
dependabot[bot] b218be2908 ⬆️ Bump @adobe/css-tools from 4.3.1 to 4.3.2 (#2532)
Bumps [@adobe/css-tools](https://github.com/adobe/css-tools) from 4.3.1 to 4.3.2.
- [Changelog](https://github.com/adobe/css-tools/blob/main/History.md)
- [Commits](https://github.com/adobe/css-tools/commits)

---
updated-dependencies:
- dependency-name: "@adobe/css-tools"
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-12-01 09:12:41 +01:00
Halvor Haugan 190b9b7dba Fiks Storybook (#2529) 2023-11-30 11:36:57 +01:00
Halvor Haugan cfd0b37906 📝 Korrigering av jsdoc på ReadMore (#2527) 2023-11-29 15:23:22 +01:00
Halvor Haugan 9ed49b8a20 månede -> måned 2023-11-29 14:46:03 +01:00
Julian Nymark 39ff2c1809 🔨 new plugin for prettier (#2523)
* 🔨 new plugin for prettier

* 🔨 remove default configs
2023-11-29 14:21:05 +01:00
Halvor Haugan 4fcc83381d Oppdater eksempler på InternalHeader (#2525) 2023-11-29 14:19:27 +01:00
github-actions[bot]andgithub-actions[bot] 8c855ee0da Version Packages (#2519)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-11-29 11:43:20 +01:00
Ken ade35e9fba 🐛 Fikset accumulator-bug i preview (#2520) 2023-11-28 16:43:20 +01:00
Ken b9d2a65c3f [aksel.nav.no] Lokal eslint-plugin for eksempler/templates (#2522)
* 🎉 Custom eslint-regel for eksempler

* 🔥 Fjernet eslint-plugin fra changeset

* 📝 comment

* ⚡ Bruker some for boolean-check
2023-11-28 16:43:11 +01:00
Halvor Haugan 5cd1a6d86a 🐛 Popover: Ikke lukk ved klikk inni når parent er fokuserbar (#2521) 2023-11-28 16:18:40 +01:00
Halvor Haugan 1bdebfd134 Justering av kodeeksempler for Table (#2517) 2023-11-28 16:05:12 +01:00
138c4523ee Templates for 500 error pages (#2500)
* ✨ add "enkel" template for 500

* ✨ add more templates for 500 error pages

* 🎨 shuffle some templates related to 500 errors

* 📝 Oppdatert lenke

* Update aksel.nav.no/website/pages/templates/500/med-lang-en.tsx

* Update aksel.nav.no/website/pages/templates/500/uten-dekorator.tsx

* PR review comments

* Update aksel.nav.no/website/pages/templates/500/med-feil-id.tsx

* Update aksel.nav.no/website/pages/templates/500/med-cta.tsx

* Update aksel.nav.no/website/pages/templates/500/komplett.tsx

* Update aksel.nav.no/website/pages/templates/500/enkel.tsx

* 📝 Oppdatert formulering på engelsk contact-us

* 📝 la til punktum

* 🔥 Fjernet HGRID fra template

* 📝 Oppdatert lenketekster

* 📝 Oppdatert tekster for enkel-variant

* 📝 Oppdatert desc-tekster

* 🎨 Oppdatert layout for 500-sider

* 🎨 La til data-attr

* 🎨 Oppdatert lokal bruk av 500-mal

* 🐛 Fikset 500-maler

* 🧪 Tester ikke templates med playwright

* 🐛 synket engelsk-tekst på 500-maler

* Update aksel.nav.no/website/pages/500.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/pages/_error.js

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🔥 Fjernet duplikat comment

* 🎨 oppdatert indeksering

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2023-11-28 15:53:05 +01:00
Ken 363d51e2c4 Page width md (#2510)
* 📝 Page width-md

* 🐛 La til med i liste over widths

* 🐛 Fikset lasting av CSS i aksel-stories
2023-11-28 15:52:42 +01:00
1079e8465a 🐛 fix templates examples (#2507)
* 🐛 fix templates examples, filter-code now throws on dubious input & output + add tests

* 🎨 convert filter-code to use string instead of code match

* 🎨 Kan nå se 404 sider i sandbox

* 🔥 Fjernet testing av templates

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2023-11-28 12:40:59 +01:00
Halvor Haugan 8dda59082d 🐛 Textarea: Skru av autosize ved manuell resize (#2518)
* 🐛 Textarea: Skru av autosize ved manuell resize

* typer stories

* ikke debounce resize
2023-11-28 12:30:33 +01:00
github-actions[bot]andgithub-actions[bot] 21d5ddd433 Version Packages (#2515)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-11-24 19:40:44 +01:00
Ken 1b7bc53294 🐛 Synket date-fns versioner i Repo 2023-11-24 18:56:08 +01:00
Lars Eirik Korsgaard Hansen 4dc5a90c72 ⬆️ upgrade date-fns version & make it minor-version agnostic (#2514)
* yarn lock

* ⬆️ upgrade date-fns version & make it minor-version agnostic
2023-11-24 11:04:24 +01:00
github-actions[bot]andgithub-actions[bot] c7694f8ddd Version Packages (#2513)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-11-23 14:16:48 +01:00
Ken 10bbdb730b Switch color (#2511)
* 💄 Switch er nå action

* 📝 changeset

* 🐛 Byttet fra action til action-selected
2023-11-23 13:57:06 +01:00
github-actions[bot]andgithub-actions[bot] f4458f3bb8 Version Packages (#2505)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-11-23 12:58:08 +01:00
Halvor Haugan 9dafbeb4eb ♿ Textarea: Forsinkelse ved live-opplesning av gjenstående tegn (#2502) 2023-11-23 12:51:57 +01:00
Halvor Haugan 4b4e190c20 Endre navn på ikon DrawingPin -> PushPin 2023-11-23 11:25:54 +01:00
Halvor Haugan b7d03bfc89 Textarea: Mulighet for å sette resize-retning (#2494) 2023-11-22 15:26:34 +01:00
Halvor Haugan bc259f5b30 Nytt ikon DrawingPin (#2503) 2023-11-22 15:21:18 +01:00
Halvor Haugan 16cad26378 ✨ Textarea: Støtte for automatisk scrollbar (#2457) 2023-11-22 15:15:32 +01:00
Ken 6ee4aa3e82 [Sanity/Aksel.nav.no] Sanity cleanup (#2499)
* ♻️ Sanity-id ut i const

* ⚡ Flyttet sanity apiVersion ut i const

* ⚡ Flyttet sanity dataset ut i const

* 🏷️ Bedre typer structure

* ⚡ La til blur på highlight-bilder

* 💄 Cube ligger nå bak innhold på bloggen

* 🔥 Fjernet gammel SEO fra sanity

* ♻️ SEO og groups import sanity

* ♻️ Ryddet opp i metadata

* 🎉 Annotering av lenker i sanity

* 🎨 Preview av kodemodul

* 🎨 Preview for dodont

* 🎨 Tips-preview

* 🎨 Relatert innhold preview

* 🔥 Fjernet console.log

* 🐛 Fikset småfeil

* 💄 Fikset darkmode-visning for preview
2023-11-22 11:47:31 +01:00
Ken bb5466178a 📝 Oppdatert typo-eksempler (#2493) 2023-11-22 10:14:05 +01:00
Ken efb92be344 🐛 Headings med space førte til wrapping av tekst (#2490) 2023-11-22 09:46:32 +01:00
KenandHalvor Haugan e3f75f542f 📝 Alert eksempler (#2492)
* 📝 Inline description i eksempler

* Update aksel.nav.no/website/pages/eksempler/alert/error.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/pages/eksempler/alert/info.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2023-11-22 09:39:53 +01:00
Halvor Haugan 96610bb543 Fiks storybook:aksel 2023-11-21 13:51:43 +01:00
Ken eee7143cf6 [Aksel.nav.no] Fjernet Scrollbar gutters på eksempler (#2491)
* 🐛 Fjerner scroll-gutters fra eksempler

* 🎨 Bedre visning av breakpoints i eksempler

* ⬆️ Yarn.lock
2023-11-20 11:58:24 +01:00
Ken a1b8cc0364 📝 Oppdatert page gutters eksempel (#2496) 2023-11-20 09:15:07 +01:00
github-actions[bot]andgithub-actions[bot] e5d2f7eb8c Version Packages (#2498)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-11-20 09:11:39 +01:00
Håvard Stigen Andersen 67b8b6626e Gjør lukknapp i alert til type button (#2497) 2023-11-20 09:08:04 +01:00
Ken 8783f1821d [Sanity] Oppdatert til v3.20, slått på kommentarer (#2487)
* 🎨 Updated sanity and enabled comments

* ♻️ Oppdatert structure

* 🎨 Bruker native input for bedre perspective og comment støtte

* 🎨 Added presentation-mode

* ⚡ Raskere load av sider

* 🔥 Fjernet experimental features
2023-11-17 21:44:46 +01:00
Julian Nymark d52085f256 ✨ add 1440px width to playroom default widths (#2476)
* ✨ add 1440px width to playroom default widths

* 🐛 fix for routing wrt /sandbox + future fix for default widths

* 🚚 shuffle redirect check to earlier in middleware
2023-11-17 17:18:18 +01:00
Halvor Haugan 67e8565da3 Link: Oppdatert eksempler (#2479) 2023-11-17 14:51:21 +01:00
Halvor Haugan bb4ff1afc3 Justering av eksempler på ConfirmationPanel (#2489) 2023-11-17 13:37:53 +01:00
dependabot[bot] 16c0c15c67 ⬆️ Bump sharp from 0.32.5 to 0.32.6 in /aksel.nav.no/website (#2488)
Bumps [sharp](https://github.com/lovell/sharp) from 0.32.5 to 0.32.6.
- [Release notes](https://github.com/lovell/sharp/releases)
- [Changelog](https://github.com/lovell/sharp/blob/main/docs/changelog.md)
- [Commits](https://github.com/lovell/sharp/compare/v0.32.5...v0.32.6)

---
updated-dependencies:
- dependency-name: sharp
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-11-17 12:54:27 +01:00
github-actions[bot]andgithub-actions[bot] f506dca7e1 Version Packages (#2485)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-11-17 12:53:01 +01:00
Torkjel Skjetne a44b2e2e7c Ikke rendre child som ikke er valid element i ErrorSummary (#2484)
Dette gjør det mulig å conditionally rendre barn i ErrorSummary. For eksempel kan man nå gjøre:

```
const shouldShow = false

return (
  <ErrorSummary>
    {shouldShow && <ErrorSummary.Item href="#id1">Jeg er en feilmelding, men vises ikke</ErrorSummary.Item>}
    <ErrorSummary.Item href="#id2">Jeg er en feilmelding som vises!</ErrorSummary.Item>
  </ErrorSummary>
)
```
2023-11-17 12:47:08 +01:00
Karl O d96d368e7b ♻ types for @navikt/ds-tailwind (#2486) 2023-11-17 12:46:32 +01:00
Halvor Haugan d3c0052c33 Textarea: Teller flyttet ut (#2483) 2023-11-17 11:46:07 +01:00
Ken f848bea71a [aksel.nav.no] Forside, Header og Footer bruker primitives (#2478)
* ♻️ Forside logikk cleanup

* 🎨 Page-wrapper

* ♻️ Bruker primitives på forside

* 🎨 Mer bruk av bleed

* 🎨 Footer bruker primitives

* 🎨 restrukturert header

* 🎨 Restrukturert Footer

* ♻️ Imports i footer

* ♻️ Header struktur

* ♻️ footer-struktur
2023-11-17 09:49:43 +01:00
Ken 1585106c55 [Aksel.nav.no] Fikser preview for Aksel-sider (#2481)
* WIP preview resolving

* 🐛 Fikset preview på maler med sidebar

* 🎨 Restrukturert preview-provider

* 🚚 Flyttet inn i parts

* 🎨 Bedre resolving av nested types

* 🎨 Better documentation

* 🎨 Bruker nye resolvers for preview

* 🐛 Henter nå nested data

* ✅ La til tester
2023-11-17 09:49:15 +01:00
Ken 5ed06e19fe 📝 Eksempler for Page-komponent (#2471)
* 📝 Eksempler for Page-komponent

* 🐛 Fikset import aliasing

* 📝 Refactor tekster

* 🐛 OverridableComponent fungerer nå med typeof

* 📝 changeset

* 🔥 Undo commit

* Rename belowfold.tsx to below-fold.tsx
2023-11-17 09:48:32 +01:00
github-actions[bot]andgithub-actions[bot] c0f334061b Version Packages (#2482)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-11-16 14:01:11 +01:00
Ken 79bddd9caa Primitives er nå mer spesifikk (#2469)
* 🐛 Mer spesifikke primitives

* 🔥 Fjernet story

* 📝 changeset

* 🎨 Oppdatert mappings
2023-11-16 11:41:31 +01:00
Ken 4a68409898 🎨 Oppdatert overridablecomponent (#2474)
* 🎨 Oppdatert overridablecomponent

* 📝 Kommentarer
2023-11-16 11:30:15 +01:00
Ken 786bff67ab 🔥 Fjernet assignees fra issue-templates 2023-11-15 13:14:59 +01:00
Ken 8a17caea6c 🐛 Fjernet TableOfContents fra bloggsider 2023-11-14 21:06:33 +01:00
Ken 3f43d0bf3b 🐛 Kjører nå ikke playroom build ved boot 2023-11-14 20:29:29 +01:00
Ken 26541984ac [aksel.nav.no] Sidebar & TableOfContents refactor (#2470)
* 🎨 toc setup

* 🎉 Implementert TOC-generering

* 💄 Nytt design på Toc

* 🎨 forenklet toc-styling

* 🎨 Scroll ved overflow

* 🎨 Bruker ny TOC på aksel

* 🐛 Bedre word-wrap

* 💄 Shadow on toc

* 🐛 Fikset fokusmarkering

* :trukket ut generateSidebar funksjon

* 🧪 tester for sidebar-generering

* 💄 Bedre design på toc

* 🎨 Mindre refactor av TOC

* 🎉 Ny sidebar

* 🎨 Oppdatert bruk av sidebar

* 🐛 Oppdatert sidebar-story

* 💄 Justert sidebar

* 💄 Indent på toc

* 💄 Hide scrollbar on toc

* 🎨 scrollfade toc

* ♻️ Flyttet scrollfade ut i egen komponent

* 💄 Smoother scroll-fade

* ⚡ Færre state-updates i toc

* 🎨 data atrrb for css

* 🎨 data-attrb i sidebar

* ⚡ Mindre css dom updates

* 🎨 Fjerner emojies fra toc

* 🎨 automatisk scroll-top

* 🎨 Next-link for sidebar

* 🎨 Toggle toc-button onClick

* 🐛 Fikset scroll-padding

* 🐛 Fikset fokushåndering av toc

* 🎨 Mindre tydelig fade for firefox

* 🔥 Fjernet console.log

* 🐛 Fikset recalculation ved page-change

* 🐛 Reversert til next 13.2.1
2023-11-14 20:10:42 +01:00
Julian NymarkandKen 10303602aa playroom (#2413)
* 🚧 playroom

testing it out, needs yarn run playroom:build before yarn dev (in aksel.nav.no)

* 🚧 width and height for iframe

* 🚚 move playroom into its own module

* 🚧

* 🐛 Fikset lasting av ts-filer

* build playroom & copy dist to public/

* 🚧 yarn maintenance

* 🚧 build the playroom before copy

* ✨ now examples might work in the sandbox? maybe 90% of them?!

* ✨ + 🔥 + ♻️

- remove route for /sandbox, in public/ means it gets served regardless?
- for each code example:
   - use jscodeshift to remove imports
   - also transpile to ESNext
- bump jscodeshift to 0.15.1 (for all uses)
- the sandbox button now sends you to /sandbox/index.html

* :refactor: j -> parse

* add non-ideal string replacer to make Examples work in Playroom

* ♻️ bring back CodeSandox link as fallback

* 🚚 Sandbox -> parts/Sandbox

* 🚚🚚 Sandbox -> parts/Sandbox

* seemingly working smoke tests for all sandbox examples

* ♻️ shuffle example code to work well with playroom

* ♻️ shuffle example code to work in sandbox (again)

* update sanity eksempler, do base64 url code work there

* PR comment fixes

* 📝 Sanity-schema for sandbox-snippets

* 🚚 generic cubeIcon -> codesandboxLogo

* 🔥 unused prop

* ♻️ do not run all tests in smoketest

* 🐛 pr comment fixes

* PR comment fixes, remove unneeded domcontentloaded await in tests

* ♻️ restructure so <Example> comes first

* 🐛 sandbox tests now for templates and examples

* 🐛 Fikset imports

* 🐛 disable some sandbox tests (for templates)

* 🐛 forgot to disable one template test

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
2023-11-13 15:12:52 +01:00
Ken 42254543d8 [aksel.nav.no] ♻️ Ryddet opp i imports, kodestruktur og ubrukte configs/moduler (#2465)
* 🚚 Oppdatert layout exports

* ⚡ Nextjs-config kan nå bruke webpack-builder

* 🐛 reverserte til gammel image-config i next.config

* 🚚 Oppdaterte assets exports

* 🚚 Fjernet barrel-exports av komponenter

* 🚚 Flyttet types

* 🚚 Flyttet sanityblock og withpreview

* 🚚 Flyttet styles inn i components

* ♻️ Forenklet jest-config

* 🚚 Flyttet logger

* ⚡ Kjører nå ikke middleware på alle side

* ♻️ next config analyze setup

* 🔥 fjernet getdocumentstmp

* 🔥 Fjernet getAkselDocuments

* 🎨 Forenklet imagebuilder

* ♻️ Fjernet ubrukte tailwind configs

* 🎨 Grupperer changelog med minor

* 🔥 Fjernet duplicate changelog

* 🎨 Ny ts alias

* ♻️ Refactor av utils dir

* ♻️ Header er nå default export

* ♻️ Byttet ut deprecated ingress med bodylong

* ♻️ Oppdatert assets export/imports

* ♻️ Oppdatert website/sanity imports

* 🐛 henter ut logger i dockerfile

* ⚡ Enda mer filtrering i middleware

* 🐛 Riktig generering av sider for e2e-sider

* 🐛 Fikset import i codeexamples update

* 🐛 la til mønster og maler i hamburgermeny
2023-11-10 18:44:42 +01:00
Ken 81c84e4817 📝 Liten M i Maler 2023-11-10 14:51:10 +01:00
Ken b441175028 📝 Oppdatert readme 2023-11-10 14:00:21 +01:00
dependabot[bot] 75362a0dc1 ⬆️ Bump axios from 1.3.6 to 1.6.0 in /@navikt/aksel (#2467)
Bumps [axios](https://github.com/axios/axios) from 1.3.6 to 1.6.0.
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](https://github.com/axios/axios/compare/v1.3.6...v1.6.0)

---
updated-dependencies:
- dependency-name: axios
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-11-10 11:12:38 +01:00
Ken d8732ffa0e 🎉 Lagt til Mønster og Maler i header 2023-11-10 10:58:16 +01:00
github-actions[bot]andgithub-actions[bot] 0ea9155085 Version Packages (#2466)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-11-10 10:40:12 +01:00
Ken 92b9687ed1 Håndterer target-detection bedre i ExpandableRow (#2461)
* 🎨 Håndterer nå target-detection bedre

* 🎨 Forenklet if-tester, tester 2x nested elementer
2023-11-10 10:36:34 +01:00
Ken 1c022b14c9 🎨 Lagt til closeOnBackdropClick for mobilmeny på Aksel 2023-11-08 21:16:17 +01:00
Ken abdeb616d2 🎨 Fikste søk + codeexamples for templates (#2462) 2023-11-08 20:41:47 +01:00
github-actions[bot]andgithub-actions[bot] 37165e9f38 Version Packages (#2459)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-11-08 16:24:10 +01:00
KenandHalvor Haugan d19920ca78 [aksel.nav.no] 404 template (#2455)
* ✨ Initial template

* 💄 Automatisk skalert svg

* 🎉 Maler v1

* 📝 Bedre endringslogg

* Update aksel.nav.no/website/pages/templates/404/complete.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update aksel.nav.no/website/pages/templates/404/complete.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 📝 Bedre kommentarer

* 📝 rename stories

* ♻️ Bruker nå page

* 🎨 Oppdatert mal med endringer

* 🎨 Bruker 404-mal på Aksel

* :trucK: Flyttet data-atributt

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2023-11-08 15:23:15 +01:00
Ken 60d3481300 [Primitives] Page-primitive (#2456)
* ✨ Frame-component

* 🏷️ rename to page

* 🎨 Belowfold

* 🎨 Gutters

* 🎨 Fjernet content width

* 🎨 Page-stories

* 📝 Config

* 📝 changeset

* 📝 Bedre props

* ♻️ Ryddet opp i CSS og prop-navn

* ♻️ Tokens for padding-verdier

* ♻️ Bedre background example

* ♻️ Bedre contentblockpadding example

* ♻️ Bedre gutters example

* 🔥 Fjernet dekoratør-story fra chromatic

* 🐛 Riktig page-padding

* 💄 Justert maksbredder

* 📝 kommentarer

* 📝 JSDoc

* 📝 jsdoc update

* 📝 Kommentarer
2023-11-08 12:14:35 +01:00
Halvor Haugan f486937439 ⬆️ Storybook 7.5.3 (#2458) 2023-11-08 09:12:00 +01:00
Halvor Haugan c62058abc1 🚨 eslint: sjekk avhengighetssykluser når i CI (#2430) 2023-11-07 14:29:51 +01:00
Halvor Haugan 84d9b8260f Fiks typo i timeline eksempel desc 2023-11-07 13:56:58 +01:00
Halvor Haugan c108063dcb Justering av eksempler på Timeline (#2454) 2023-11-06 08:55:31 +01:00
Ken 2a8533ad56 [aksel.nav.no] Templates vises nå riktig på mønster/mal-sider (#2450)
* 🐛 Fikset visning av templates

* 🐛 autoGenerateArrayKeys fungerte ikke for nested arrays

* 🐛 Fikset tester
2023-11-03 12:18:38 +01:00
KenandAnders Olsen Sandvik 9b990a2178 [aksel.nav.no] Legg til RSS feed på produktbloggen (#2439) (#2453)
* [aksel.nav.no] Legg til RSS feed på produktbloggen

* Adjust generateRssFeed to accept a path parameter

* 🎉 Oppdatert generering av rss

---------

Co-authored-by: Anders Olsen Sandvik <github@mlsv.no>
2023-11-03 10:26:35 +01:00
github-actions[bot]andgithub-actions[bot] 5fec1f24f4 Version Packages (#2452)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-11-02 22:03:10 +01:00
Halvor Haugan c27c1cfe26 🐛 Datepicker lukker ikke lenger modalen den er i (#2451) 2023-11-02 21:59:06 +01:00
Ken 5a649d2282 🐛 Kunne ikke se preview av mønster forside (#2449) 2023-11-02 15:11:34 +01:00
Ken baac9cc251 [aksel.nav.no] Sidemaler for Mønster og maler (#2438)
* 🎉 Sanity-schema for mønster og maler

* 🎨 La til mønster og maler i sanity structure

* 🎨 Støtte for templates i søk

* 🎨 Sidemaler for Mønster og Maler

* 🎨 Riktig håndtering av breadcrumbs

* 🐛 Fikset story

* 🐛 Fikset search-indeksering

* 🐛 Fikset search-test

* 🐛 Fikset typo

* [aksel.nav.no] Refaktorert synking av eksempler/templates mellom kode og sanity (#2442)

* 🎨 Template pages

* 🔥 Fjernet templates fra logging

* ♻️ Refaktorert example-generering

* ✅ extractArgs tests

* ✅ filter-code tester

* ✅ Ny code-parsing tester

* 🚚 Flyttet filer

* 🎨 Oppdaterer sanity remote

* 🎨 sanity schema for templates

* 🎨 Schema for metadata in templates

* 🎨 henter nå ut metadata fra templates

* 🎨 Flyttet createId funksjon

* 🚚 rename folder

* 🎨 schema for templates i sanity

* 🐛 Fjernet dryrun fra oppdatering

* 🎨 Make sure to delete old documents after updating

* 🐛 Riktige typer for version-schema

* [aksel.nav.no] Integrert mønster og maler templates inn på aksel (#2447)

* 🎨 Template pages

* 🔥 Fjernet templates fra logging

* ♻️ Refaktorert example-generering

* ✅ extractArgs tests

* ✅ filter-code tester

* ✅ Ny code-parsing tester

* 🚚 Flyttet filer

* 🎨 Oppdaterer sanity remote

* 🎨 sanity schema for templates

* 🎨 Schema for metadata in templates

* 🎨 henter nå ut metadata fra templates

* 🎨 Flyttet createId funksjon

* 🚚 rename folder

* 🎨 schema for templates i sanity

* 🐛 Fjernet dryrun fra oppdatering

* 🎨 Make sure to delete old documents after updating

* 🐛 Riktige typer for version-schema

* 🎨 Kan nå vise eksempler på side

* 🎨 Automatisk visning av changelog

* 📝 typo

* 📝 Rename fra changelog til Endringer

* 🐛 Fikset story-typer

* 🎨 Forsideblokk for templates

* 🐛 feil riktekst ble brukt
2023-11-02 11:47:57 +01:00
Sjur d924d523e4 Update in-the-wild.yml (#2448)
Tok bort "assignees"
2023-11-02 10:38:51 +01:00
Sjur fc5a77081d Create in-the-wild.yml (#2445)
Issue template for å ta imot eksempler fra folk
2023-11-02 10:01:49 +01:00
github-actions[bot]andgithub-actions[bot] 1f3477a3e9 Version Packages (#2446)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-11-02 09:55:38 +01:00
Halvor Haugan 925450cb73 💄 Modal: Bedre håndtering av mobiler i landskapsmodus (#2444) 2023-11-02 09:30:19 +01:00
github-actions[bot]andgithub-actions[bot] 534a6a3b40 Version Packages (#2443)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-11-01 15:46:41 +01:00
51eee7f011 [Datepicker/Modal] Datepicker bruker nå Modal på mobil og for nested Modal (#2419)
* 🎨 Initial Modal-update

* 🐛 close(open handling for Modal

* 🔥 Fjernet openOnFocus

* 🔥 Fjernet outsideclick og useEscape

* 🐛 monthpicker onClose forwarding

* 🎨 Flyttet DateInput til egen parts-mappe

* 🏷️ DateInput imports

* 🚚 Flyttet DateWrapper ut til egen komponent

* 🎨 Monthpicker bruker dateWrapper

* 💄 Oppdatert styling for datepicker

* 📝 Oppdatert eksempler

* 📝 changeset

* 🐛 Fikset imports i date-hooks

* ♻️ Bedre context-bruk i Modal.tsx

* 📝 Bedre tekster for deprecation

* 🐛 Støtter nå jsdom

* 🐛 Fikset polyfill av datepicker

* 🎨 closeOnBackdropClick i datepicker

* 🏷️ 🐛 Fikset outsideClick boundary + fjernet bubbleEscape-prop

* 🔥 Fjernet console.log

* 🔥 Fjernet bubbleEscape-prop

* Update @navikt/core/react/src/date/hooks/useMonthPicker.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/date/datepicker/datepicker.stories.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🎨 Bedre className for nested modal

* 🐛 Bedre check om popover er i datepicker

* 🔥 Fjernet unødvendig if rundt window-check

* 🎨 Bedre fallback for useMedia-hook

* 🎨 bedre navn i useMedia

* 📝 Datepicker-stories for size har preset-values

* Update @navikt/core/react/src/date/hooks/useDatepicker.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🎨 DateContext er nå default null hvis ikke satt

* Update @navikt/core/react/src/date/parts/DateWrapper.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/date/parts/DateWrapper.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/date/parts/DateWrapper.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* Update @navikt/core/react/src/date/utils/labels.ts

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

* 🐛 Fikset small-size padding

* 🔥 Fjernet error-demo

* fokusgreier

* 🎨 bedre onClose-handling av modal

* 🐛 Håndterer focus ved cancel og select nå

* 🐛 Feil i typer for dateinput

* 🐛 setAnchorRef var optional

* 🐛 null-test

* 🎨 Fjernet jsdom sjekk tester for useMedia

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2023-11-01 15:38:57 +01:00
Vegard Haugstvedt 909ae6aed1 Add new useVirtualFocus hook, for use in Combobox (#2394)
* Add new useVirtualFocus hook, for use in Combobox. Might be useful for other components later, but will scope it for Combobox at first.

* Create filteredOptionsUtils, which has utiltity functions for creating IDs and for text lookups in lists.

* Get rid of data-value, and use filteredOptionsMap to look up the value of the currently (virtually) focused element instead

This allows use of e.g. numbers as options, which data-value didn't.

* Using useState instead of useRef to handle filteredOptionsRef

* Added changeset

* Force option id to be lower case, to avoid different casing from being interpreted as being different from the existing options

* Fix bug where it was not possible to select multiple custom (new) options in a multiselect

selectedOptionsContext is not available inside customOptionsContext, so need to take isMultiSelect from props instead

* Switch to use toLocalLowerCase and remove uneccessary use of string literal

* type mismatch

* Clean up types - reuse from ComboboxProps type definition, and fix resulting type mismatches

* Rename filteredOptionsRef variable returned from filteredOptionsContext to reflect that it is now actually a setState-function

* Expose virtualFocus as an object through filteredOptionsContext, instead of each separate method.

Done to remove need to wrap moveFocusUp and moveFocusDown in order to toggle isListOpen
2023-11-01 12:02:57 +01:00
Lars Eirik Korsgaard Hansen cd3859a91e 📝 add aria roles example to Alert (#2440) 2023-11-01 09:16:42 +01:00
Ken 338f14e7ac [aksel.nav.no] Refaktorert ErrorBoundary-bruk for fast-refresh (#2433)
* ♻️ errorboundary refactor

* ♻️ Converted to non-anonymous function errorboundary

* ♻️ Fikset ErrorBoundary Full-refresh

* [aksel.nav.no] ♻️ Component-structure (#2435)

* 🔥 Fjernet UUFeedback-modul

* 🚚 Flyttet filer i egne mapper

* 🚚 Oppdatert struktur for sanity-moduler

* 🚚 Oppdatert akselcube exports

* 🔥 Fjernet Feedback-modul

* 🚚 Rename SuggestionBlock

* 🚚 Flyttet relatert innhold

* 🐛 Fikset suggestionblock imports

* 🎨 Oppdatert bruk av ShowMore
2023-10-30 15:42:35 +01:00
Halvor Haugan aed1d082c3 🐛 Legg på onClose på Popover-eksempler (#2436) 2023-10-30 12:36:47 +01:00
Ken 31e9226b55 [Aksel.nav.no] Bruker alpha ShowMore lokalt på nettsiden (#2409)
* 📝 Story for TokenTable

* ✨ Tester lokal alpha-showmore på Aksel

* 🎨 Showmore brukes nå bare når det er over 10 tokens i listen

* 📝 yarn lock
2023-10-30 12:10:16 +01:00
github-actions[bot]andgithub-actions[bot] fe15b4d275 Version Packages (#2414)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-10-30 10:57:37 +01:00
Halvor Haugan 28e095d5a2 Oppdater eksemplene på Popover (#2425) 2023-10-30 10:21:17 +01:00
dependabot[bot] 43377841ba ⬆️ Bump browserify-sign from 4.2.1 to 4.2.2 (#2434)
Bumps [browserify-sign](https://github.com/crypto-browserify/browserify-sign) from 4.2.1 to 4.2.2.
- [Changelog](https://github.com/browserify/browserify-sign/blob/main/CHANGELOG.md)
- [Commits](https://github.com/crypto-browserify/browserify-sign/compare/v4.2.1...v4.2.2)

---
updated-dependencies:
- dependency-name: browserify-sign
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-10-30 09:16:59 +01:00
Ken 2976ee9626 🐛 Bugfix routing i sidebar/eksempler (#2432) 2023-10-27 18:49:32 +02:00
Ken 23c135b437 🐛 Fikset lasting av toc (#2421) 2023-10-27 15:59:13 +02:00
Halvor Haugan 7f0498f250 🐛 Oppdater eksemplene på Loader (#2431) 2023-10-27 12:52:17 +02:00
Halvor Haugan 5075c8d0a6 ✨ Modal: Støtte for å lukke ved klikk utenfor (#2386) 2023-10-27 12:47:47 +02:00
Ken 792eeaba42 🐛 Fikset dom-validering av Accordion (#2426) 2023-10-27 12:36:45 +02:00
Halvor Haugan 0c7fc04935 🐛 Modal: Bedre støtte for Tooltip i Modal (#2429) 2023-10-27 10:47:24 +02:00
Halvor Haugan 0bb339e54a [aksel.nav.no] Legg til tittel på RelatertInnhold-modulen (#2423) 2023-10-25 16:51:40 +02:00
Halvor Haugan f5eb3adaea [aksel.nav.no] Få CodeSandbox til å fungere med TS (#2424) 2023-10-25 16:33:07 +02:00
Ken 77cf71f814 🐛 Tester fix for internlenker til anchors (#2420) 2023-10-25 15:07:07 +02:00
Vegard Haugstvedt f8c12b0757 Autocomplete should keep upper-/lowercase from the word being autocompleted (#2207)
* AutoComplete should keep upper-/lowercase from the word being autocompleted

* Fix issue where autocomplete doesn't format the casing of the last character in the word

* Added changeset

* Append the autocompleted text in the same casing used in the list, but preserve casing for the typed characters

* Preserve casing used while typing, then use the casing from the options when selecting a value

* Added custom options to test of casing when typing

* Correct changeset

* When allowNewValues is enabled, we should use the new value as is when pressing Enter, instead of using the first FilteredOption

* Change test case to use a partial match for a word in options. This tests both that we will use "add new" option if available and that we preserve casing for new options
2023-10-24 07:50:50 +02:00
Ken be8265e13e 🐛 Fikset versjon av nextjs (#2410) 2023-10-23 13:12:40 +02:00
Halvor Haugan 0c7d6fb461 Fiks shadowdom-eksempel (#2392) 2023-10-23 11:42:00 +02:00
Julian Nymark b97ac03c5a 🚧 test if this branch builds (#2368)
* 🚧 test if this branch builds

* ♻️ css -> types

* ♻️ remove double module imports
2023-10-23 10:07:54 +02:00
github-actions[bot]andgithub-actions[bot] 0ddb589138 Version Packages (#2408)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-10-20 17:18:00 +02:00
Ken 1440c99b96 [aksel.nav.no] 📝 Story for Table i aksel (#2406)
* 📝 Story for Table i aksel

* ♻️ Trukket args ut
2023-10-20 17:02:34 +02:00
Ken f8cf39c906 [aksel.nav.no] Lagt til muligheten til å ikke ha "Send innspill" modul på komponent-artikler (#2407)
* 🎨 Oversikt blir nå sortert basert på index

* 🎨 Kan nå skjule send innspill modul
2023-10-20 16:30:50 +02:00
Ken 158c032436 [aksel.nav.no] Refactor av amplitude-logging (#2396)
* ♻️ Refaktorert logging

* ♻️ Refaktorert logging

* 🔥 No need to lazyload hotjar

* 🐛 Sjekker nå produrl riktig

* ♻️ Bedre import/export av logging

* ✨ Batching evets logged pre-init

* ♻️ Cleanup av amplitude bruk
2023-10-20 16:05:38 +02:00
Halvor Haugan 6d6e6443dd 💄 Chips.Toggle: Ikon i uvalgt tilstand (#2395) 2023-10-20 15:54:05 +02:00
Ken e12ea8694e ✨ Monthpicker eksempel og bug (#2404) 2023-10-20 12:44:28 +02:00
github-actions[bot]andgithub-actions[bot] 2d4cb67643 Version Packages (#2403)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-10-20 10:52:13 +02:00
Ken f5533766c8 📝 Oppdatert link og linkpanel med nextjs eksempler 2023-10-20 10:28:24 +02:00
Ken 3d1b0ac204 🎨 Forms-border har nå outside shadow for background-bleed (#2388) 2023-10-20 09:21:42 +02:00
Ken a1678d3b19 🐛 Loader hadde legacyRef som ref-prop (#2391)
* 🐛 Loader hadde legacyRef som ref-prop

* Update .changeset/heavy-shoes-pay.md
2023-10-20 09:17:39 +02:00
github-actions[bot]andgithub-actions[bot] 7007d3c58e Version Packages (#2401)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-10-19 19:56:13 +02:00
Ken 8524346044 🐛 Modal + Popover fix (#2400)
* 🧪 SB-demo

* 🐛 Datepicker-popover vises ikke ritkig i Modal

* 📝 Modal + datepicker demo
2023-10-19 19:52:06 +02:00
Ken d5d8898659 🐛 Riktig CSP for hotjar 2023-10-19 18:28:24 +02:00
Ken 1d635e1dbd ⬇️ reverted til gammel nextjs-versjon (#2393) 2023-10-18 15:57:07 +02:00
Ken 6b3932b172 [aksel.nav.no] 📝 Oppdatert eksempler for Bleed og show/hide (#2385)
* 📝 Oppdatert eksempler for Bleed og show/hide

* ♻️ Refactor wrapper rundt bleed-eksempler
2023-10-18 12:50:12 +02:00
Ken 4d6ae1ae42 [aksel.nav.no] 🐛 Fikset next error ved redeploy av app (#2387)
* 🐛 Fikset next error ved redeploy av app

* 🎨 synket next-versjoner
2023-10-18 11:11:52 +02:00
github-actions[bot]andgithub-actions[bot] 6c29fa83dd Version Packages (#2381)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-10-17 16:30:38 +02:00
Ken a6b6733861 🎨 Mindre Helptext variant (#2376)
* 🎨 Mindre Helptext variant

* 🎨 small-variant er nå default helptext

* 💄 Larger helptext circle stroke-width

* Update .changeset/wild-rice-arrive.md
2023-10-17 16:23:14 +02:00
Halvor Haugan 3e54bd4f43 Ny eslint-regel no-shadow (#2377) 2023-10-17 16:05:22 +02:00
Mathias S. MüllerandKen ec205fbc5f 🐛 Fiks skrivefeil på size-klasse på form-komponenter (#2372)
* Fiks skrivefeil på size-klasse på select-komponent

* Fiks skrivefeil på size-klasse på form-komponenter

* 📝 changeset

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
2023-10-17 15:11:41 +02:00
Ken d8a4097c82 💄 Endring av tekstfarge endrer også chevron nå (#2383) 2023-10-17 14:55:53 +02:00
KenandHalvor Haugan 3a3a53f823 [Aksel.nav.no] Nextjs logging av getStaticProps (#2384)
* 🎨 Caching in dev

* 🎨 Logging getstaticprops

* 🐛 Endret tilbake til gammel caching

* Update aksel.nav.no/website/pages/komponenter/index.tsx

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2023-10-17 13:09:02 +02:00
Halvor Haugan 3d3e907608 Ny spacing token på 0.375rem (#2370) 2023-10-17 09:13:39 +02:00
Ken 986d0e9740 [aksel.nav.no] ⬆️ Oppdatert sanity (#2379)
* ⬆️ Oppdatert sanity

* ⬆️ yarnlock
2023-10-16 18:58:28 +02:00
dependabot[bot] 50bb7d4ff8 ⬆️ Bump @babel/traverse from 7.23.0 to 7.23.2 (#2380)
Bumps [@babel/traverse](https://github.com/babel/babel/tree/HEAD/packages/babel-traverse) from 7.23.0 to 7.23.2.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.23.2/packages/babel-traverse)

---
updated-dependencies:
- dependency-name: "@babel/traverse"
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-10-16 18:51:53 +02:00
github-actions[bot]andgithub-actions[bot] c2151e0514 Version Packages (#2378)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2023-10-16 16:19:27 +02:00
Ken 4bc4dea85f 🐛 Fikset tastaturnavigasjon i monthpicker (#2374) 2023-10-16 14:33:23 +02:00
4707 changed files with 226320 additions and 88076 deletions

No files matched your search

+14 -10
View File
@@ -1,31 +1,35 @@
# Changesets
For versjonering bruker vi løsningen [Changesets](https://github.com/changesets/changesets) for [versjonering](https://semver.org/) og publisering av pakker.
Vi bruker [Changesets](https://github.com/changesets/changesets) for [versjonering](https://semver.org/) og publisering av pakker.
## Howto
## Lage ny versjon
- For å lage en ny versjons-entry: `yarn changeset`
- Velg pakkene som skal versjoneres med `arrowkeys` + `Space`
1. `yarn changeset`
2. Svar på spørsmålene som kommer opp:
`🦋 Which packages would you like to include?`
Trykk `Space` for å velge pakkene som skal versjoneres, for så trykke `Enter` for å gå videre.
Trykk `Space` for å velge pakkene som skal versjoneres, trykk så `Enter` for å gå videre.
`🦋 Which packages should have a major bump?`
Trykk `Enter` for å gå videre _*eller*_ velg pakkene som skal marjor-bumpes med `arrowkeys` + `Space`
Trykk `Enter` for å gå videre _eller_ velg pakkene som skal marjor-bumpes med `arrowkeys` + `Space`.
`🦋 Which packages should have a minor bump?`
Trykk `Enter` for å gå videre _*eller*_ velg pakkene som skal marjor-bumpes med `arrowkeys` + `Space`
Trykk `Enter` for å gå videre _eller_ velg pakkene som skal minor-bumpes med `arrowkeys` + `Space`.
Hvis du ikke velger major eller minor, så blir pakkene få en patch-bump
Hvis du ikke velger major eller minor, så vil pakkene få en patch-bump.
- Commit og push.
`Please enter a summary for this change`
Skriv inn en kort beskrivelse av endringen på formatet `<Komponent>: <gitmoji?> <Beskrivelse>`, f.eks. "Button: ✨ Add feature xyz".
3. Commit og push.
## Fixed versjonering
Alle base-pakkene våre har `fixed versjonering`. Dette tilsier at en bump på en av disse vil bumpe alle til samme versjon
Alle base-pakkene våre har `fixed versjonering`. Dette betyr at en bump på en av disse vil bumpe alle til samme versjon
```sh
"@navikt/ds-react",
+7 -1
View File
@@ -20,7 +20,13 @@
"access": "public",
"baseBranch": "main",
"updateInternalDependencies": "patch",
"ignore": ["aksel.nav.no", "aksel-icons-figma-plugin"],
"ignore": [
"aksel.nav.no",
"aksel-icons-figma-plugin",
"eslint-plugin-aksel-local",
"scripts",
"aksel-analyzer"
],
"___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH": {
"updateInternalDependents": "always"
-96
View File
@@ -1,96 +0,0 @@
// TODO: Convert to new format: https://eslint.org/docs/latest/use/configure/migration-guide
module.exports = {
env: {
browser: true,
es6: true,
node: true,
},
extends: [
"eslint:recommended",
"plugin:react/recommended",
//"plugin:react/jsx-runtime", // Not sure if this will cause problems for projects not using the new JSX transform
"plugin:react-hooks/recommended",
"plugin:jsx-a11y/recommended",
"plugin:import/recommended",
"plugin:import/typescript",
"plugin:storybook/recommended",
// TODO: Look into opinionated stylistic plugin
// TODO: Replace @typescript-eslint/recommended with @typescript-eslint/recommended-type-checked
],
settings: { react: { version: "detect" } },
rules: {
"import/no-unresolved": "off",
"react/jsx-curly-brace-presence": [
"error",
{ propElementValues: "always" },
],
"array-callback-return": "error",
"object-shorthand": "error",
// TODO: Consider adding the rule "id-length"
// Temporary:
"react/prop-types": "off",
"react/display-name": "off",
"import/no-named-as-default": "off",
// "import/no-cycle": [1],
},
reportUnusedDisableDirectives: true,
overrides: [
{
files: ["**/*.ts?(x)"],
extends: ["plugin:@typescript-eslint/recommended"],
rules: {
"@typescript-eslint/no-explicit-any": "off", // Temporary
},
},
{
files: ["**/*.test.*", "**/__tests__/*"],
extends: ["plugin:jest/recommended", "plugin:testing-library/react"],
},
{
files: ["aksel.nav.no/website/**"],
env: {
browser: true,
es2021: true,
},
extends: ["plugin:@next/next/recommended"],
parser: "@typescript-eslint/parser",
parserOptions: {
ecmaFeatures: {
jsx: true,
},
ecmaVersion: 12,
sourceType: "module",
},
rules: {
"react/no-unknown-property": [2, { ignore: ["jsx", "global"] }],
"react/react-in-jsx-scope": "off",
"@next/next/no-html-link-for-pages": [
"error",
"aksel.nav.no/website/pages/",
],
"@typescript-eslint/ban-ts-comment": "off", // Temporary
},
},
{
files: ["aksel.nav.no/website/pages/eksempler/**"],
rules: {
"jsx-a11y/anchor-is-valid": "off",
},
},
],
globals: {
Locale: "readonly",
JSX: "readonly",
},
ignorePatterns: [
"node_modules",
"lib",
"public",
"examples",
"esm",
"cjs",
"dist",
"**/codemod/**/*.js",
"!.storybook",
],
};
+22
View File
@@ -0,0 +1,22 @@
name: Eksempel på bruk
description: Send et eksempel på ting fra Aksel som er brukt i det fri (tokens, komponenter, maler, etc)
title: "[Eksempel på bruk]: "
labels: ["dokumentasjon 📖"]
body:
- type: markdown
attributes:
value: |
Takk for at du bidrar til Aksel!
- type: input
id: title
attributes:
label: Lenke til side
description: Lenke til siden hvor eksemplet er
placeholder:
validations:
required: true
- type: textarea
id: examples
attributes:
label: Forklaring
description: Forklar om det er noe man må gjøre for å se eksemplet, eller hvor på siden det ligger
-2
View File
@@ -2,8 +2,6 @@ name: Ny komponent
description: Send et ønske om en eller flere nye komponenter
title: "[Ny komponent]: "
labels: ["nytt ✨", "forespørsel 🥰", "komponenter 🧩"]
assignees:
- KenAJoh
body:
- type: markdown
attributes:
-2
View File
@@ -2,8 +2,6 @@ name: Nytt ikon
description: Send et ønske om et eller flere nye ikoner
title: "[Nytt ikon]: "
labels: ["nytt ✨", "ikoner 🖼", "forespørsel 🥰"]
assignees:
- KenAJoh
body:
- type: markdown
attributes:
+9
View File
@@ -0,0 +1,9 @@
---
name: Bug Report
about: Meld inn bugs eller feil
title: "[BUG]"
labels: "bug \U0001F41B"
assignees: ""
---
## Hva forventet du å finne for dette søket?
@@ -2,8 +2,6 @@ name: Innspill til komponent
description: Send inn innspill til komponent
title: "[Innspill til komponent]: "
labels: ["forespørsel 🥰", "komponenter 🧩", "nytt ✨", "beta 🧪"]
assignees:
- KenAJoh
body:
- type: markdown
attributes:
-2
View File
@@ -2,8 +2,6 @@ name: Innspill til ikon
description: Send inn innspill til ikon
title: "[Tilbakemelding på ikon]: "
labels: ["forespørsel 🥰", "ikoner 🖼️"]
assignees:
- KenAJoh
body:
- type: markdown
attributes:
+12 -40
View File
@@ -1,44 +1,16 @@
### Description
<!-- PR description/motivation
add links to project-tasks, slack discussions etc here
-->
<!-- PR description/motivation, summary of changes, links to issue/slack discussion etc. -->
### Change summary
### Component Checklist 📝
<!-- Short summary of changes in PR
- added variant x
- fixed bug in y
-->
### PR Checklist 📝 (Remove fields after check!)
#### New component? ✨
- Check that component-styling is correctly configured in `@navikt/core/css/config/_mappings.js`. This is needed for correct build and CDN upload.
- Check that styling is correctly exported from `@navikt/core/css/index.css`
- Check that correct tokens for component is documented in `@navikt/core/css/tokens.json`
- Check that only needed components and types are exported from `@navikt/core/react/src/index.ts`
- Add JSDoc to component (see other components for reference)
- Create storybook-stories for relevant component variations and compositions. Stories are used for [visual regression testing](https://www.chromatic.com/docs/), so make sure they are complete.
- Is the component sufficiently complex to warrant tests? Add some unit-tests for jest.
#### Component-updates 🎉
- Revalidate if everything under `New component` is still accounted for
- Deprecating/removing a CSS class? Add it to `@navikt/aksel-stylelint/src/deprecations.ts` with a suitable description. This helps stylelint-users keep their code clean and bug-free.
#### Documentation 📝
- Add/update component-demos for component `aksel.nav.no/website/pages/eksempler`
- Create/Update documentation in sanity if needed
Note: Props, tokens and examples only updates to sanity on merge to main
#### Versioning 🏷️
- Run `yarn changeset` to generate a version-entry for change.
- - Bug/hotfix: Patch
- - New feature: Minor
- - Breaking change: Major
- Adding breaking changes? Consider adding a codemod for easier migration.
- Breaking changes also needs documentation under "Migration"-page on website
- [ ] JSDoc
- [ ] Examples
- [ ] Documentation / Decision Records
- [ ] Storybook
- [ ] Style mappings (`@navikt/core/css/config/_mappings.js`)
- [ ] CSS class deprecations (`@navikt/aksel-stylelint/src/deprecations.ts`)
- [ ] Exports (`@navikt/core/react/src/index.ts` and `@navikt/core/react/package.json`)
- [ ] New component? CSS import (`@navikt/core/css/index.css`)
- [ ] Breaking change? Update migration guide. Consider codemod.
- [ ] Changeset (Format: `<Component>: <gitmoji?> <Text>` E.g. "Button: :sparkles: Add feature xyz")
+80
View File
@@ -0,0 +1,80 @@
name: "Build website"
description: "Builds Nextjs-website and published CDN-asssets to GCP if needed"
inputs:
use_cdn_assets:
description: "Use CDN assets, and upload build to GCP"
required: true
npm_auth_token:
description: "NPM Auth Token"
required: true
nais_id_provider:
description: "NAIS_WORKLOAD_IDENTITY_PROVIDER token"
required: true
nais_project_id:
description: "NAIS_MANAGEMENT_PROJECT_ID token"
required: true
sanity_read_token:
description: "Sanity read-only token allowing published and un-published documents"
required: true
sanity_read_no_drafts_token:
description: "Sanity read-only token allowing only published documents"
required: true
sanity_deploy_studio:
description: "Sanity studio deployment token"
required: false
next_encryption_key:
description: "Overrides default NEXT_SERVER_ACTIONS_ENCRYPTION_KEY for production builds"
required: false
production:
description: "Toggle to differentiate production build (inject stuff based on this)"
default: false
required: false
runs:
using: "composite"
steps:
- name: Setup project
uses: ./.github/actions/setup
with:
npm_auth_token: ${{ inputs.npm_auth_token }}
- name: Run website tests
run: yarn workspace website test
shell: bash
- name: Make Next.js app use CDN assets
if: ${{ inputs.use_cdn_assets == 'true' }}
run: |
echo "USE_CDN_ASSETS=true" >> aksel.nav.no/website/.env
shell: bash
- name: Set production env var
if: ${{ inputs.production == 'true' }}
run: |
echo "PRODUCTION=true" >> aksel.nav.no/website/.env
shell: bash
- name: Update sanity manifest
if: ${{ inputs.production == 'true' && inputs.sanity_deploy_studio != '' }}
run: yarn update:sanity-manifest
env:
SANITY_AUTH_TOKEN: ${{ inputs.sanity_deploy_studio }}
shell: bash
- name: Build Next.js website
run: yarn build:next
env:
SANITY_READ: ${{ inputs.sanity_read_token }}
SANITY_READ_NO_DRAFTS: ${{ inputs.sanity_read_no_drafts_token }}
NEXT_SERVER_ACTIONS_ENCRYPTION_KEY: ${{ inputs.next_encryption_key }}
shell: bash
- name: Upload static files to Nav CDN
if: ${{ inputs.use_cdn_assets == 'true' }}
uses: nais/deploy/actions/cdn-upload/v2@master
with:
team: designsystem
source: ./aksel.nav.no/website/.next/static
destination: "/website/_next"
project_id: ${{ inputs.nais_project_id }}
identity_provider: ${{ inputs.nais_id_provider }}
+26
View File
@@ -0,0 +1,26 @@
name: "Setup Project"
description: "Checks out repo, sets up Node, installs dependencies and runs boot command."
inputs:
npm_auth_token:
description: "NPM Auth Token"
required: true
runs:
using: "composite"
steps:
- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: lts/*
cache: yarn
cache-dependency-path: "yarn.lock"
- name: Install dependencies
run: yarn --immutable
shell: bash
env:
NPM_AUTH_TOKEN: ${{ inputs.npm_auth_token }}
- name: Boot (build packages)
run: yarn boot
shell: bash
+145
View File
@@ -0,0 +1,145 @@
# Aksel - Copilot Instructions
## Use this file first
- Trust these instructions to narrow the search space, but still read the target code and nearest related files before editing.
- Optimize for local work. Prefer known paths, nearby patterns, and existing scripts over broad repo searches.
- Ignore release, deploy, changelog, CMS sync, and other remote/ops scripts unless the user asks.
## How to use this file
- Use this file to narrow the search space, not to replace reading code.
- Before editing, read the target file and the nearest related files in the same folder such as `index.ts`, story, test, and package/root export files.
- Search wider only when nearby files do not answer the question.
## Agent mode
- No apologies, no “I think”, no change summaries.
- Don’t ask to confirm info that’s already in context.
- Favor performance and security; add robust error handling and safe logging.
- Default tone: short and answer-first. Aim for max 0–2 concise sentences where needed.
- Thinking and explanation process: Keep it short, omit whats not strictly necessary, and focus on the next edit.
- Avoid long explanations or multiple steps at once.
- Don't explain thinking process for each step, just do the next edit. Only add explanations when the user explicitly asks for it or when it's necessary to clarify a non-obvious change.
## Inline chat and editor completions
- Verify before you claim. Don’t speculate.
- Keep functions small and focused; remove duplication (rule of three).
- Show only what changes. Provide minimal diffs/snippets; don’t paste whole files or unrelated lines.
- Keep edits scoped to a single file unless explicitly asked to touch more.
- Extract requirements into a tiny checklist and proceed. Ask a question only when truly blocked.
- Avoid heavy formatting: bullets are OK; skip tables; use code fences only for code.
- For performance/security: avoid unnecessary re-renders, side effects at module top-level, unsafe HTML, and leaking env vars.
## Repo summary
- Large Yarn 4 workspaces monorepo for NAV's design system: public React/CSS/tokens/icons/stylelint/CLI packages plus docs site and playroom.
- Stack: TypeScript 6, React 19, Next.js 16, Storybook 10, Vitest 4, ESLint 9, Stylelint 17, Biome 2, Prettier 3.
- Runtime: Node 22+ recommended, Yarn 4.12.0.
- Important constraint: code under `@navikt/*` must stay React 17 API compatible. Do not use React 18/19-only APIs there.
## Start and validate
1. `corepack enable`
2. `yarn install`
3. `yarn boot`
- Run `yarn boot` after first install and after `yarn clean`.
- Full install may need `NPM_AUTH_TOKEN` for GitHub Packages.
Public-package-only install:
```bash
yarn workspaces focus @navikt/aksel-icons @navikt/ds-tokens @navikt/ds-css @navikt/ds-react @navikt/ds-tailwind @navikt/aksel @navikt/aksel-stylelint
```
## Definition of done
- Behavior or visual change: update the implementation, closest story, and closest test.
- New public export: update the component `index.ts`, package `src/index.ts`, and `package.json` exports.
- User-facing package change: add a changeset unless the task says otherwise.
- Validate with the narrowest workspace command first; use root commands only for cross-workspace changes.
### Common local commands
Always prefer using these commands that already exists in workspaces before running custom commands or doing manual steps. These are optimized for local development and validation. For example:
- `yarn boot` - build all workspaces
- `yarn test` - run all workspace tests
- `yarn lint` - eslint + stylelint + biome + cycle + version checks
- `yarn lint:eslint` / `yarn lint:css` / `yarn lint:biome`
- `yarn storybook` - root Storybook on `localhost:6006`
- `yarn storybook:aksel` - website/example Storybook on `localhost:6007`
- `yarn storybook:test` - Storybook browser tests, slow, uses Playwright/Firefox
- `yarn dev` - website dev server on `localhost:3000`
- `yarn clean` - remove build artifacts
- `yarn workspace @navikt/ds-react build`
- `yarn workspace @navikt/ds-react test`
- `yarn workspace website test`
- `yarn workspace playroom sync-imports`
### Validated locally
- Works: `yarn boot`, `yarn test`, `yarn storybook --ci --smoke-test`, `yarn storybook:aksel --ci --smoke-test`
- Caveat: `yarn lint` and `yarn lint:eslint` can fail if playroom imports are stale. Fix with `yarn workspace playroom sync-imports`.
## Where to edit
- `@navikt/core/react/` - `@navikt/ds-react`
- `src/<component>/<Component>.tsx`
- `src/<component>/index.ts`
- `src/<component>/*.stories.tsx`
- `src/index.ts`
- `package.json` exports map for new public components
- `@navikt/core/css/src/` - component CSS
- `@navikt/core/tokens/src/` - design token source
- `@navikt/core/tailwind/` - Tailwind preset
- `@navikt/aksel-icons/icons/` - source SVGs; `src/` is generated
- `@navikt/aksel-stylelint/src/` - Stylelint rules/config
- `@navikt/aksel/src/` - CLI and codemods
- `aksel.nav.no/website/` - Next.js docs site
- `aksel.nav.no/playroom/` - playroom and generated imports
- `examples/` - example apps
- `scripts/` - shared repo scripts
- Root references: `README.md`, `CONTRIBUTING.md`, `aksel.nav.no/README.md`, `package.json`, `eslint.config.js`, `stylelint.config.mjs`, `biome.json`, `tsconfig.json`, `tsconfig.build.json`, `.storybook/`, `.github/workflows/build-validation.yml`
## Coding defaults
- Keep diffs small. No drive-by refactors, formatting churn, or new dependencies unless asked.
- Read the full file and copy the nearest existing pattern before changing code.
- Keep public APIs stable. Prefer additive props and exports.
- In `@navikt/*`, import React in TSX files; root JSX runtime is classic.
- Use named exports with explicit type exports.
- Keep `forwardRef`, `className`, `...rest`, and `as`/`OverridableComponent` patterns when the surrounding component uses them.
- Reuse internal helpers instead of re-implementing them: `cl`, `composeEventHandlers`, `useId`, `omit`, `useClientLayoutEffect`, `useEventListener`.
- Use `node:` imports for Node builtins.
- Never import from `esm/` or `cjs/` build output.
- Keep import order consistent: `@navikt/*`, `@/*`, then relative. Let Prettier handle sorting.
- Preserve or add JSDoc for public props/components when changing public APIs.
## React and ds-react specifics
- Component `index.ts` files in `@navikt/core/react/src/**` start with `"use client"`.
- When adding or exposing a public component, keep these in sync:
- component `index.ts`
- `@navikt/core/react/src/index.ts`
- `@navikt/core/react/package.json` exports
- Do not use React 18/19-only APIs under `@navikt/*`. Use internal helpers like `useId`.
## CSS and tokens
- Never hardcode colors, spacing, radius, or shadows. Use tokens only.
- Public tokens use `--ax-*`. Internal component variables use `--__axc-*`.
- Follow existing CSS nesting, `data-*` selectors, `focus-visible`, `forced-colors`, and reduced-motion patterns.
- Prettier formats; Biome is lint-only.
## Stories, tests, website
- Update the closest story and test whenever behavior or visuals change.
- Use Testing Library queries by role and name.
- Stories live next to components and use `@storybook/react-vite`.
- For component work, prefer Storybook over `yarn dev`.
- `aksel.nav.no/website/pages/eksempler/**` and `pages/templates/**` feed the website and Storybook. In these files, only import from `@navikt/*` and `react`.
- The website uses both `app/` and `pages/`; stay inside the router already used nearby.
- `yarn storybook:aksel` works for website examples/templates without Sanity secrets. `yarn dev` may need website env values such as `SANITY_READ_NO_DRAFTS`.
+61
View File
@@ -0,0 +1,61 @@
version: 2
registries:
npm-github:
type: npm-registry
url: https://npm.pkg.github.com
token: ${{ secrets.READER_TOKEN }}
updates:
- package-ecosystem: npm
directory: /
exclude-paths:
- "examples/astro/package.json"
- "examples/shadow-dom/package.json"
schedule:
interval: weekly
day: monday
time: "04:00"
registries:
- npm-github
groups:
sanity:
patterns:
- "sanity"
- "sanity-*"
- "@sanity/*"
- "next-sanity"
- "@portabletext/*"
eslint:
patterns:
- "eslint"
- "@eslint/*"
react:
patterns:
- "react"
- "react-dom"
storybook:
patterns:
- "*storybook*"
vitest:
patterns:
- "vitest"
- "@vitest/*"
- package-ecosystem: github-actions
directory: "/"
schedule:
interval: weekly
day: monday
time: "04:00"
registries:
- npm-github
groups:
actions:
patterns:
- "*"
- package-ecosystem: docker
directory: "/"
schedule:
interval: weekly
day: monday
time: "04:00"
@@ -0,0 +1,11 @@
description: "Use for JS/TS code in this repo."
applyTo: "**/\*.tsx", "**/_.jsx", "\*\*/_.ts", "\*_/_.js"
---
# JS/TS instructions
- Prefer `for...of` over `Array.forEach`.
- Prefer named exports; keep type exports separate from value exports.
- Group exports at the bottom: values first, then types.
- In `*.stories.*`, keep the default export at the top.
@@ -0,0 +1,13 @@
description: "Use for ds-react components and component CSS."
applyTo: "@navikt/core/react/src/**", "@navikt/core/css/src/**"
---
# ds-react and component instructions
- Read the full component folder before editing.
- Preserve the surrounding `forwardRef`, `className`, `...rest`, and `as`/`OverridableComponent` patterns.
- Keep `@navikt/*` code React 17 API compatible.
- Use tokens, not hardcoded component values.
- If behavior or visuals change, update the nearest story and test.
- If a public component changes, keep component exports, package exports, and root exports in sync.
@@ -0,0 +1,11 @@
description: "Use for tests and stories."
applyTo: "**/_.test._", "**/\*.stories.tsx"
---
# Testing and Storybook instructions
- Prefer story `play` functions and `yarn storybook:test` for real user flows; use Vitest for logic and non-browser cases.
- Prefer focused assertions over snapshots unless nearby tests already use snapshots.
- Cover the main path and one or two meaningful edge cases.
- If UI behavior changes, update the nearest story and test in the same change.
@@ -0,0 +1,14 @@
description: "Use for website and playroom work."
applyTo:
- "aksel.nav.no/website/\*\*"
- "aksel.nav.no/playroom/\*\*"
---
# Website and playroom instructions
- Stay inside the router already used nearby; do not mix `app/` and `pages/` patterns in the same area.
- In `aksel.nav.no/website/pages/eksempler/**` and `aksel.nav.no/website/pages/templates/**`, only import from `@navikt/*` and `react`.
- Reuse nearby website utilities and patterns before adding abstractions.
- Prefer `yarn storybook:aksel` for examples/templates; use `yarn dev` only for app-only behavior.
-73
View File
@@ -1,73 +0,0 @@
name: Deploy aksel.dev.nav.no
on:
workflow_dispatch:
push:
branches:
- next
jobs:
build_and_deploy:
name: Build and deploy to dev-gcp
runs-on: ubuntu-20.04
permissions:
packages: "write"
contents: "read"
id-token: "write"
steps:
- uses: actions/setup-node@v3
with:
node-version: "20"
- uses: actions/checkout@v3
- name: add tokens to .env
run: |
echo "SANITY_WRITE_KEY=${{ secrets.SANITY_FEEDBACK_WRITE_KEY }}" >> aksel.nav.no/website/.env
echo "SANITY_PREVIEW_TOKEN=${{ secrets.SANITY_PREVIEW_TOKEN }}" >> aksel.nav.no/website/.env
echo "SANITY_PRIVATE_NO_DRAFTS=${{ secrets.SANITY_PRIVATE_NO_DRAFTS }}" >> aksel.nav.no/website/.env
echo "USE_CDN_ASSETS=true" >> aksel.nav.no/website/.env
- name: Hide page from search engines
run: |
echo "User-agent: *\nDisallow: /" > aksel.nav.no/website/public/robots.txt
- name: Restore cache
uses: actions/cache@v3
with:
path: "**/node_modules"
key: ${{ runner.os }}-dev-${{ github.sha }}
restore-keys: |
${{ runner.os }}-dev-
- name: Install dependencies
run: yarn
- name: Build application
run: |
yarn boot
yarn workspace aksel.nav.no build:next
- name: Upload static files to NAV CDN
uses: navikt/frontend/actions/cdn-upload/v1@main
with:
cdn-team-name: aksel
source: ./aksel.nav.no/website/.next/static
destination: "/website/_next"
- name: Get complete tag
run: echo "TAG=DEV-$( date +%s )" >> $GITHUB_ENV
- uses: nais/docker-build-push@v0
id: docker-push
with:
team: designsystem
push_image: true
dockerfile: aksel.nav.no/Dockerfile
project_id: ${{ vars.NAIS_MANAGEMENT_PROJECT_ID }}
identity_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
- name: Deploy to dev-gcp
uses: nais/deploy/actions/deploy@master
env:
APIKEY: ${{ secrets.NAIS_DEPLOY_APIKEY }}
RESOURCE: aksel.nav.no/nais-dev.yaml
CLUSTER: dev-gcp
IMAGE: ${{ steps.docker-push.outputs.image }}
-116
View File
@@ -1,116 +0,0 @@
name: Deploy aksel.nav.no
on:
push:
branches:
- main
paths:
- "aksel.nav.no/**"
env:
IMAGE: ghcr.io/navikt/aksel
jobs:
sync_data_with_sanity:
name: Update component data
runs-on: ubuntu-latest
steps:
- uses: actions/setup-node@v3
with:
node-version: "20"
- uses: actions/checkout@v3
- name: add tokens to .env
run: |
echo "SANITY_WRITE_KEY=${{ secrets.SANITY_FEEDBACK_WRITE_KEY }}" >> aksel.nav.no/website/.env
- name: Restore cache
uses: actions/cache@v3
with:
path: "**/node_modules"
key: ${{ runner.os }}-prod-${{ github.sha }}
restore-keys: |
${{ runner.os }}-prod-
- name: Install dependencies
run: yarn
- name: Run docgen
run: |
yarn boot
yarn docgen
- name: Update sanity sync
run: yarn workspace aksel.nav.no sanity:update
build_and_deploy:
name: Build and deploy to prod-gcp
runs-on: ubuntu-latest
permissions:
packages: "write"
contents: "read"
id-token: "write"
steps:
- uses: actions/setup-node@v3
with:
node-version: "20"
- uses: actions/checkout@v3
- name: add tokens to .env
run: |
echo "SANITY_WRITE_KEY=${{ secrets.SANITY_FEEDBACK_WRITE_KEY }}" >> aksel.nav.no/website/.env
echo "SANITY_PREVIEW_TOKEN=${{ secrets.SANITY_PREVIEW_TOKEN }}" >> aksel.nav.no/website/.env
echo "SANITY_PRIVATE_NO_DRAFTS=${{ secrets.SANITY_PRIVATE_NO_DRAFTS }}" >> aksel.nav.no/website/.env
echo "USE_CDN_ASSETS=true" >> aksel.nav.no/website/.env
- name: Restore cache
uses: actions/cache@v3
with:
path: "**/node_modules"
key: ${{ runner.os }}-prod-${{ github.sha }}
restore-keys: |
${{ runner.os }}-prod-
- name: Install dependencies
run: yarn
- name: Build packages
run: yarn boot
- name: Tests
run: yarn workspace aksel.nav.no test
- name: Build application
run: yarn workspace aksel.nav.no build:next
- name: Upload static files to NAV CDN
uses: navikt/frontend/actions/cdn-upload/v1@main
with:
cdn-team-name: aksel
source: ./aksel.nav.no/website/.next/static
destination: "/website/_next"
- name: Get complete tag
run: echo "TAG=PROD-$( date +%s )" >> $GITHUB_ENV
- uses: nais/docker-build-push@v0
id: docker-push
with:
team: designsystem
push_image: true
dockerfile: aksel.nav.no/Dockerfile
project_id: ${{ vars.NAIS_MANAGEMENT_PROJECT_ID }}
identity_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
- name: Wait for e2e-tests to succeed
uses: lewagon/wait-on-check-action@v1.2.0
with:
ref: ${{ github.ref }}
check-name: "Smoketest Aksel"
repo-token: ${{ secrets.GITHUB_TOKEN }}
wait-interval: 10
- name: Deploy to prod-gcp
uses: nais/deploy/actions/deploy@master
env:
APIKEY: ${{ secrets.NAIS_DEPLOY_APIKEY }}
RESOURCE: aksel.nav.no/nais-prod.yaml
CLUSTER: prod-gcp
IMAGE: ${{ steps.docker-push.outputs.image }}
-41
View File
@@ -1,41 +0,0 @@
name: Redeploy image to for aksel.nav.no
on:
workflow_dispatch:
inputs:
tag:
description: "Docker image tag"
required: true
default: ""
dry:
description: "Dry-run"
required: true
default: "false"
env:
IMAGE: ghcr.io/navikt/aksel
jobs:
redeploy:
name: Redeploy image
runs-on: ubuntu-20.04
steps:
- uses: actions/setup-node@v3
with:
node-version: "20"
- uses: actions/checkout@v3
- name: Login to GitHub Container Registry
uses: docker/login-action@f4ef78c080cd8ba55a85445d5b36e214a81df20a # Use commit-sha1 instead of tag for security concerns
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Create docker image tag
run: echo "DOCKER_TAG=${{ env.IMAGE }}:${{ github.event.inputs.tag }}" >> $GITHUB_ENV
- name: Deploy to prod-gcp
uses: nais/deploy/actions/deploy@master
env:
APIKEY: ${{ secrets.NAIS_DEPLOY_APIKEY }}
RESOURCE: aksel.nav.no/nais-prod.yaml
CLUSTER: prod-gcp
IMAGE: ${{ env.DOCKER_TAG }}
DRY_RUN: ${{ github.event.inputs.dry }}
+48
View File
@@ -0,0 +1,48 @@
name: Backup Sanity dataset
on:
workflow_dispatch:
schedule:
- cron: "0 0 */3 * *"
permissions:
contents: read
jobs:
execute:
name: Export and upload Sanity backup
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v6
with:
fetch-depth: 1
- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: lts/*
cache: yarn
cache-dependency-path: "yarn.lock"
- name: Install dependencies
run: cd aksel.nav.no/website && yarn
env:
NPM_AUTH_TOKEN: ${{ secrets.READER_TOKEN }}
- name: Export dataset
run: cd aksel.nav.no/website && yarn backup
env:
SANITY_READ: ${{ secrets.SANITY_READ }}
- name: Authenticate with GCP
uses: "google-github-actions/auth@v3"
with:
credentials_json: "${{ secrets.gcp_credentials_prod }}"
- name: Upload backup to GCS bucket
uses: "google-github-actions/upload-cloud-storage@v3"
with:
path: ./aksel.nav.no/website
destination: "aksel-website-prod/backups"
glob: "backup-*.tar.gz"
-38
View File
@@ -1,38 +0,0 @@
name: Backup sanity dateset to gcp
on:
workflow_dispatch:
schedule:
# 12.00 every 3 days
- cron: "0 0 */3 * *"
jobs:
execute:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0 # Required to retrieve git history
- uses: actions/setup-node@v3
with:
node-version: "20"
- name: Restore cache
uses: actions/cache@v3
with:
path: "**/node_modules"
key: ${{ runner.os }}-build-${{ github.sha }}
restore-keys: |
${{ runner.os }}-build-
- name: Install dependencies
run: cd aksel.nav.no/website && yarn
- name: Export dataset
run: cd aksel.nav.no/website && SANITY_PREVIEW_TOKEN=${{secrets.SANITY_DATASET_EDITOR_TOKEN}} yarn backup
- name: Upload GCP bucket
uses: "google-github-actions/auth@v0"
with:
credentials_json: "${{ secrets.gcp_credentials_prod }}"
- uses: "google-github-actions/upload-cloud-storage@v0"
with:
path: ./aksel.nav.no/website
destination: "aksel-website-prod/backups"
glob: "backup-*.tar.gz"
+134
View File
@@ -0,0 +1,134 @@
name: E2E tests (Playwright)
on:
push:
branches: [main, next]
paths:
- "aksel.nav.no/**"
pull_request:
branches: [main, next]
paths:
- "aksel.nav.no/**"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
actions: read
contents: read
packages: write
id-token: write
jobs:
prebuild-app-for-playwright:
name: Build app for Playwright
runs-on: ubuntu-latest
env:
IMAGE_NAME: ${{ github.repository }}-e2e
REGISTRY: ghcr.io
steps:
- name: Checkout code
uses: actions/checkout@v6
with:
fetch-depth: 1
- name: Setup and build Next.js application
uses: ./.github/actions/build-website
with:
use_cdn_assets: false
npm_auth_token: ${{ secrets.READER_TOKEN }}
nais_id_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
nais_project_id: ${{ vars.NAIS_MANAGEMENT_PROJECT_ID }}
sanity_read_token: ${{ secrets.SANITY_READ }}
sanity_read_no_drafts_token: ${{ secrets.SANITY_READ_NO_DRAFTS }}
- name: Log in to the Container registry
uses: docker/login-action@v4
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push Docker image
uses: docker/build-push-action@v7
with:
context: .
file: aksel.nav.no/Dockerfile
push: true
tags: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ github.sha }}
outputs:
image: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ github.sha }}
run-playwright:
needs: [prebuild-app-for-playwright]
name: Playwright shard ${{ matrix.shardIndex }}/${{ matrix.shardTotal }}
runs-on: ubuntu-latest
container:
image: mcr.microsoft.com/playwright:v1.58.1-noble
services:
testapp:
image: ${{ needs.prebuild-app-for-playwright.outputs.image }}
ports: ["3000:3000"]
env:
SANITY_READ: ${{ secrets.SANITY_READ }}
SANITY_READ_NO_DRAFTS: ${{ secrets.SANITY_READ_NO_DRAFTS }}
strategy:
fail-fast: false
matrix:
shardIndex: [1, 2, 3, 4, 5]
shardTotal: [5]
steps:
- name: Checkout code
uses: actions/checkout@v6
with:
fetch-depth: 1
- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: lts/*
cache: yarn
cache-dependency-path: "yarn.lock"
- name: Install dependencies
run: yarn --immutable
shell: bash
env:
NPM_AUTH_TOKEN: ${{ secrets.READER_TOKEN }}
- name: Run Playwright
shell: bash
run: yarn e2e:docker --shard=${{ matrix.shardIndex }}/${{ matrix.shardTotal }}
env:
SANITY_READ: ${{ secrets.SANITY_READ }}
SANITY_READ_NO_DRAFTS: ${{ secrets.SANITY_READ_NO_DRAFTS }}
- name: Upload blob report to GitHub Actions Artifacts
if: ${{ !cancelled() }}
uses: actions/upload-artifact@v7
with:
name: blob-report-${{ matrix.shardIndex }}
path: aksel.nav.no/website/blob-report
retention-days: 1
merge-reports:
name: Merge Playwright reports
if: ${{ !cancelled() }}
needs: [run-playwright]
runs-on: ubuntu-latest
steps:
- name: Download blob reports from GitHub Actions Artifacts
uses: actions/download-artifact@v8
with:
path: all-blob-reports
pattern: blob-report-*
merge-multiple: true
- name: Merge into HTML Report
run: npx playwright merge-reports --reporter html ./all-blob-reports
- name: Upload HTML report
uses: actions/upload-artifact@v7
with:
name: html-report--attempt-${{ github.run_attempt }}
path: playwright-report
retention-days: 14
+90
View File
@@ -0,0 +1,90 @@
name: Validation (Lint, Tests)
on:
push:
branches:
- main
- next
pull_request:
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: read
jobs:
lint:
name: Lint (ESLint, Stylelint etc.)
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v6
with:
fetch-depth: 1
- name: Setup project
uses: ./.github/actions/setup
with:
npm_auth_token: ${{ secrets.READER_TOKEN }}
- name: Lint
run: yarn lint
validate-examples:
name: Validate component examples
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v6
with:
fetch-depth: 1
- name: Setup project
uses: ./.github/actions/setup
with:
npm_auth_token: ${{ secrets.READER_TOKEN }}
- name: Validate example code
run: yarn validate:eksempler
test:
name: Unit and integration tests
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v6
with:
fetch-depth: 1
- name: Setup project
uses: ./.github/actions/setup
with:
npm_auth_token: ${{ secrets.READER_TOKEN }}
- name: Test
run: yarn test
ui:
name: UI tests (Storybook)
runs-on: ubuntu-latest
timeout-minutes: 10
container:
image: mcr.microsoft.com/playwright:v1.58.1-noble
steps:
- name: Checkout code
uses: actions/checkout@v6
with:
fetch-depth: 1
- name: Setup project
uses: ./.github/actions/setup
with:
npm_auth_token: ${{ secrets.READER_TOKEN }}
- name: Test UI
run: yarn storybook:test --max-workers=2
env:
HOME: /root
@@ -0,0 +1,86 @@
name: Visual regression (Chromatic)
on:
push:
branches:
- "main"
paths:
- "@navikt/**"
pull_request:
branches: [main, next]
paths:
- "@navikt/**"
- "aksel.nav.no/website/pages/templates/**"
- ".storybook/**"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
chromatic:
name: Run Chromatic
runs-on: ubuntu-latest
permissions:
issues: write
pull-requests: write
contents: write
steps:
- name: Checkout code
uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Setup project
uses: ./.github/actions/setup
with:
npm_auth_token: ${{ secrets.READER_TOKEN }}
- name: Chromatic
uses: chromaui/action@latest
id: chromatic_tests
continue-on-error: false
with:
autoAcceptChanges: "main"
token: ${{ secrets.GITHUB_TOKEN }}
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
exitZeroOnChanges: true
buildScriptName: "build:storybook-chromatic"
onlyChanged: true
untraced: "**/package.json|yarn.lock|**/*.md"
externals: "**/core/css/src/**/*.css"
traceChanged: true
env:
STORYBOOK_GITHUB_SHA: ${{ github.sha }}
- name: Get commit sha
if: github.event_name != 'push' && !contains(github.event.head_commit.message, '[ci skip]')
id: vars
shell: bash
run: |
echo "sha_short=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
- name: Find Comment
if: github.event_name != 'push' && !contains(github.event.head_commit.message, '[ci skip]')
uses: peter-evans/find-comment@v4
id: fc
with:
issue-number: ${{ github.event.pull_request.number }}
comment-author: "github-actions[bot]"
body-includes: Storybook demo
- name: Create or update comment
if: github.event_name != 'push' && !contains(github.event.head_commit.message, '[ci skip]')
uses: peter-evans/create-or-update-comment@v5
with:
comment-id: ${{ steps.fc.outputs.comment-id }}
issue-number: ${{ github.event.pull_request.number }}
body: |
## [Storybook demo](${{steps.chromatic_tests.outputs.storybookUrl}}) / [Chromatic](${{steps.chromatic_tests.outputs.url}})
${{ steps.chromatic_tests.outputs.changeCount > 0 && format('### 📝 Changes to review: {0}', steps.chromatic_tests.outputs.changeCount) || '' }}
${{ steps.chromatic_tests.outputs.errorCount > 0 && format('### ❌ Stories with errors: {0}', steps.chromatic_tests.outputs.errorCount) || '' }}
${{ steps.chromatic_tests.outputs.interactionTestFailuresCount > 0 && format('### ❌ Failed interaction tests: {0}', steps.chromatic_tests.outputs.interactionTestFailuresCount) || '' }}
[${{ steps.vars.outputs.sha_short }}](https://github.com/navikt/aksel/commit/${{ steps.vars.outputs.sha_short }}) | ${{steps.chromatic_tests.outputs.componentCount}} components | ${{steps.chromatic_tests.outputs.specCount}} stories
edit-mode: replace
+147
View File
@@ -0,0 +1,147 @@
name: Bundle check (main branch)
on:
pull_request:
branches: [main]
paths:
- "@navikt/**"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: read
jobs:
check-title:
name: Check PR title
runs-on: ubuntu-latest
outputs:
should-run: ${{ steps.check.outputs.should-run }}
steps:
- id: check
run: echo "should-run=${{ !contains(github.event.pull_request.title, 'Version Packages') }}" >> $GITHUB_OUTPUT
analyze-trunk:
name: Analyze main branch
runs-on: ubuntu-latest
needs: check-title
if: ${{ needs.check-title.outputs.should-run == 'true' }}
steps:
- name: Checkout main branch
uses: actions/checkout@v6
with:
fetch-depth: 1
ref: main
- name: Setup project
uses: ./.github/actions/setup
with:
npm_auth_token: ${{ secrets.READER_TOKEN }}
- name: Analyze main branch
run: yarn run:analyze-local-action
- name: Upload json report to GitHub Actions Artifacts
if: ${{ !cancelled() }}
uses: actions/upload-artifact@v7
with:
name: trunk-results.json
path: scripts/analyzer
retention-days: 1
analyze-local:
name: Analyze PR branch
runs-on: ubuntu-latest
needs: check-title
if: ${{ needs.check-title.outputs.should-run == 'true' }}
steps:
- name: Checkout PR branch
uses: actions/checkout@v6
with:
fetch-depth: 1
- name: Setup project
uses: ./.github/actions/setup
with:
npm_auth_token: ${{ secrets.READER_TOKEN }}
- name: Analyze PR branch
run: yarn run:analyze-branch-action
- name: Upload json report to GitHub Actions Artifacts
if: ${{ !cancelled() }}
uses: actions/upload-artifact@v7
with:
name: branch-results.json
path: scripts/analyzer
retention-days: 1
compare-against-trunk:
name: Compare bundles (PR vs main)
runs-on: ubuntu-latest
needs: [analyze-trunk, analyze-local]
steps:
- name: Checkout code
uses: actions/checkout@v6
with:
fetch-depth: 1
- name: Setup project
uses: ./.github/actions/setup
with:
npm_auth_token: ${{ secrets.READER_TOKEN }}
- name: Download trunk json from GitHub Actions Artifacts
uses: actions/download-artifact@v8
with:
path: scripts/analyzer
name: trunk-results.json
- name: Download branch json from GitHub Actions Artifacts
uses: actions/download-artifact@v8
with:
path: scripts/analyzer
name: branch-results.json
- name: Analyze compare branches
run: yarn run:compare-bundles
- name: Upload comparison markdown to GitHub Actions Artifacts
if: ${{ !cancelled() }}
uses: actions/upload-artifact@v7
with:
name: compare-markdown.md
path: scripts/analyzer
retention-days: 1
update-comment:
name: Post PR comment with results
runs-on: ubuntu-latest
needs: [compare-against-trunk]
permissions:
contents: read
pull-requests: write
steps:
- name: Download comparison markdown to GitHub Actions Artifacts
uses: actions/download-artifact@v8
with:
path: scripts/analyzer
name: compare-markdown.md
- name: Find Comment
uses: peter-evans/find-comment@v4
id: fc
with:
issue-number: ${{ github.event.pull_request.number }}
comment-author: "github-actions[bot]"
body-includes: Bundle Analysis Result
- name: Create or update comment
uses: peter-evans/create-or-update-comment@v5
with:
comment-id: ${{ steps.fc.outputs.comment-id }}
issue-number: ${{ github.event.pull_request.number }}
body-path: scripts/analyzer/compare-markdown.md
edit-mode: replace
+84
View File
@@ -0,0 +1,84 @@
name: Bundle check (npm)
on:
pull_request:
branches: [main]
paths:
- "@navikt/**"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: read
jobs:
check-title:
name: Check PR title
runs-on: ubuntu-latest
outputs:
should-run: ${{ steps.check.outputs.should-run }}
steps:
- id: check
run: echo "should-run=${{ contains(github.event.pull_request.title, 'Version Packages') }}" >> $GITHUB_OUTPUT
analyze:
name: Analyze npm packages
runs-on: ubuntu-latest
needs: check-title
if: ${{ needs.check-title.outputs.should-run == 'true' }}
steps:
- name: Checkout code
uses: actions/checkout@v6
with:
fetch-depth: 1
- name: Setup project
uses: ./.github/actions/setup
with:
npm_auth_token: ${{ secrets.READER_TOKEN }}
- name: Analyze Npm and local packages
run: yarn run:analyze-npm-action
- name: Run comparison analysis
run: yarn run:compare-bundles
- name: Upload comparison markdown to GitHub Actions Artifacts
if: ${{ !cancelled() }}
uses: actions/upload-artifact@v7
with:
name: compare-markdown.md
path: scripts/analyzer
retention-days: 1
update-comment:
name: Post PR comment with results
runs-on: ubuntu-latest
needs: [analyze]
permissions:
contents: read
pull-requests: write
steps:
- name: Download comparison markdown to GitHub Actions Artifacts
uses: actions/download-artifact@v8
with:
path: scripts/analyzer
name: compare-markdown.md
- name: Find Comment
uses: peter-evans/find-comment@v4
id: fc
with:
issue-number: ${{ github.event.pull_request.number }}
comment-author: "github-actions[bot]"
body-includes: Bundle Analysis Result
- name: Create or update comment
uses: peter-evans/create-or-update-comment@v5
with:
comment-id: ${{ steps.fc.outputs.comment-id }}
issue-number: ${{ github.event.pull_request.number }}
body-path: scripts/analyzer/compare-markdown.md
edit-mode: replace
+55
View File
@@ -0,0 +1,55 @@
name: Upload Figma token config to CDN
on:
workflow_dispatch:
push:
branches:
- "main"
paths:
- "@navikt/core/tokens/**"
jobs:
upload:
name: Build and upload token config
runs-on: ubuntu-latest
permissions:
contents: "read"
id-token: "write"
steps:
- name: Checkout code
uses: actions/checkout@v6
with:
fetch-depth: 1
- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: lts/*
cache: yarn
cache-dependency-path: "yarn.lock"
- name: Install dependencies
run: yarn
env:
NPM_AUTH_TOKEN: ${{ secrets.READER_TOKEN }}
- name: Build tokens
run: yarn workspace @navikt/ds-tokens build
- name: Upload config to CDN
id: upload
uses: nais/deploy/actions/cdn-upload/v2@master
with:
team: designsystem
source: "./@navikt/core/tokens/figma-config.json"
destination: "./@navikt/tokens"
project_id: ${{ vars.NAIS_MANAGEMENT_PROJECT_ID }}
identity_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
source_keep_parent_name: false
no_cache_paths: "@navikt/tokens/figma-config.json"
- name: Log uploaded file
run: echo uploaded file ${{ steps.upload.outputs.uploaded }}
shell: bash
+36
View File
@@ -0,0 +1,36 @@
name: Upload fonts to CDN
on:
workflow_dispatch:
push:
branches:
- "main"
paths:
- "fonts/**"
jobs:
upload:
name: Upload fonts to CDN
runs-on: ubuntu-latest
permissions:
contents: read
id-token: write
steps:
- name: Checkout code
uses: "actions/checkout@v6"
- name: Upload fonts to CDN
id: upload
uses: nais/deploy/actions/cdn-upload/v2@master
with:
team: aksel
source: ./fonts
destination: "" # uploads folder to team root
project_id: ${{ vars.NAIS_MANAGEMENT_PROJECT_ID }}
identity_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
- name: Log uploaded file
run: echo uploaded file ${{ steps.upload.outputs.uploaded }}
shell: bash
-108
View File
@@ -1,108 +0,0 @@
name: Visual Regression Tests
on:
push:
branches:
- "main"
paths:
- "@navikt/**"
pull_request:
branches: [main, next]
paths:
- "@navikt/**"
jobs:
visual_regression_test:
name: "visual regression test (chromatic)"
runs-on: ubuntu-latest
permissions:
issues: write
pull-requests: write
contents: write
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: actions/setup-node@v3
with:
node-version: "20"
cache: yarn
- name: Restore cache
uses: actions/cache@v3
with:
path: "**/node_modules"
key: ${{ runner.os }}-visual-regression-test-${{ github.sha }}
restore-keys: |
${{ runner.os }}-visual-regression-test-
- name: Install dependencies
run: yarn
- name: Build packages
run: yarn boot
- name: Chromatic
uses: chromaui/action@v1
id: chromatic_tests
continue-on-error: true
with:
autoAcceptChanges: "main"
token: ${{ secrets.GITHUB_TOKEN }}
projectToken: x3xqdfgkujg
exitZeroOnChanges: false
buildScriptName: "build:storybook"
env:
STORYBOOK_GITHUB_SHA: ${{ github.sha }}
- name: replace storybook url
if: "!contains(github.event.head_commit.message, '[ci skip]') && github.event_name != 'push'"
uses: frabert/replace-string-action@v2
id: storybook_url
with:
pattern: "(iframe.html)"
string: ${{ steps.chromatic_tests.outputs.storybookUrl }}
replace-with: ""
- name: Get commit sha
if: "!contains(github.event.head_commit.message, '[ci skip]') && github.event_name != 'push'"
id: vars
shell: bash
run: |
echo "::set-output name=sha_short::$(git rev-parse --short HEAD)"
- name: Find Comment
if: "!contains(github.event.head_commit.message, '[ci skip]') && github.event_name != 'push'"
uses: peter-evans/find-comment@v2
id: fc
with:
issue-number: ${{ github.event.pull_request.number }}
comment-author: "github-actions[bot]"
body-includes: Storybook demo
- name: Create or update comment
if: steps.chromatic_tests.outcome == 'success' && !contains(github.event.head_commit.message, '[ci skip]') && github.event_name != 'push'
uses: peter-evans/create-or-update-comment@v3
with:
comment-id: ${{ steps.fc.outputs.comment-id }}
issue-number: ${{ github.event.pull_request.number }}
body: |
## [Storybook demo](${{steps.storybook_url.outputs.replaced}})
[${{ steps.vars.outputs.sha_short }}](https://github.com/navikt/aksel/commit/${{ steps.vars.outputs.sha_short }}) | ${{steps.chromatic_tests.outputs.componentCount}} komponenter | ${{steps.chromatic_tests.outputs.specCount}} stories
edit-mode: replace
- name: Create or update failed comment
if: steps.chromatic_tests.outcome != 'success' && !contains(github.event.head_commit.message, '[ci skip]') && github.event_name != 'push'
uses: peter-evans/create-or-update-comment@v3
with:
comment-id: ${{ steps.fc.outputs.comment-id }}
issue-number: ${{ github.event.pull_request.number }}
body: |
## [Storybook demo](${{steps.storybook_url.outputs.replaced}})
### [Endringer til review](${{steps.chromatic_tests.outputs.url}}): ${{steps.chromatic_tests.outputs.changeCount}}
[${{ steps.vars.outputs.sha_short }}](https://github.com/navikt/aksel/commit/${{ steps.vars.outputs.sha_short }}) | ${{steps.chromatic_tests.outputs.componentCount}} komponenter | ${{steps.chromatic_tests.outputs.specCount}} stories
edit-mode: replace
-46
View File
@@ -1,46 +0,0 @@
name: CI
on:
push:
branches:
- main
- next
pull_request:
workflow_dispatch:
jobs:
build:
name: "Validate build"
if: "!contains(github.event.head_commit.message, '[ci skip]')"
runs-on: ubuntu-latest
permissions:
pull-requests: "write"
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: actions/setup-node@v3
with:
node-version: "20"
cache: yarn
- name: Restore cache
uses: actions/cache@v3
with:
path: "**/node_modules"
key: ${{ runner.os }}-test-${{ github.sha }}
restore-keys: |
${{ runner.os }}-test
- name: Install dependencies
run: yarn
- name: Boot (build packages)
run: yarn boot
- name: Lint
run: yarn lint
- name: Test
run: yarn test
+26
View File
@@ -0,0 +1,26 @@
name: Cleanup E2E Docker images
on:
schedule:
- cron: "0 4 * * 1"
workflow_dispatch:
permissions:
packages: write
jobs:
cleanup:
runs-on: ubuntu-latest
strategy:
matrix:
package-name:
- aksel-e2e
steps:
- name: Delete old container images
uses: actions/delete-package-versions@e5bc658cc4c965c472efe991f8beea3981499c55 # actions/delete-package-versions@v5
with:
package-name: ${{ matrix.package-name }}
package-type: container
delete-only-untagged-versions: false
min-versions-to-keep: 1
token: ${{ secrets.GITHUB_TOKEN }}
+54
View File
@@ -0,0 +1,54 @@
name: Deploy dev (aksel.ansatt.dev.nav.no)
on:
workflow_dispatch:
push:
branches:
- next
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: false
jobs:
build_and_deploy:
name: Build and deploy to dev-gcp
runs-on: ubuntu-latest
permissions:
packages: "write"
contents: "read"
id-token: "write"
deployments: "write"
steps:
- name: Checkout code
uses: actions/checkout@v6
with:
fetch-depth: 1
- name: Setup and build Next.js application
uses: ./.github/actions/build-website
with:
use_cdn_assets: true
npm_auth_token: ${{ secrets.READER_TOKEN }}
nais_id_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
nais_project_id: ${{ vars.NAIS_MANAGEMENT_PROJECT_ID }}
sanity_read_token: ${{ secrets.SANITY_READ }}
sanity_read_no_drafts_token: ${{ secrets.SANITY_READ_NO_DRAFTS }}
- name: Build and push Docker image
uses: nais/docker-build-push@v0
id: docker-push
with:
team: designsystem
push_image: true
dockerfile: aksel.nav.no/Dockerfile
project_id: ${{ vars.NAIS_MANAGEMENT_PROJECT_ID }}
identity_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
- name: Deploy to dev-gcp
uses: nais/deploy/actions/deploy@master
env:
APIKEY: ${{ secrets.NAIS_DEPLOY_APIKEY }}
RESOURCE: aksel.nav.no/nais-dev.yaml
CLUSTER: dev-gcp
IMAGE: ${{ steps.docker-push.outputs.image }}
+81
View File
@@ -0,0 +1,81 @@
name: Deploy prod (aksel.nav.no)
on:
push:
branches:
- main
paths:
- "aksel.nav.no/**"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: false
env:
IMAGE: ghcr.io/navikt/aksel
jobs:
sync_data_with_sanity:
name: Sync data to Sanity
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v6
- name: Setup project
uses: ./.github/actions/setup
with:
npm_auth_token: ${{ secrets.READER_TOKEN }}
- name: Run ts-docgen
run: yarn docgen
- name: Update Sanity
env:
SANITY_WRITE: ${{ secrets.SANITY_WRITE }}
run: yarn workspace aksel.nav.no sanity:update
build_and_deploy:
name: Build and deploy to prod-gcp
runs-on: ubuntu-latest
permissions:
packages: "write"
contents: "read"
id-token: "write"
deployments: "write"
steps:
- name: Checkout code
uses: actions/checkout@v6
with:
fetch-depth: 1
- name: Setup and build Next.js application
uses: ./.github/actions/build-website
with:
use_cdn_assets: true
production: true
npm_auth_token: ${{ secrets.READER_TOKEN }}
nais_id_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
nais_project_id: ${{ vars.NAIS_MANAGEMENT_PROJECT_ID }}
sanity_read_token: ${{ secrets.SANITY_READ }}
sanity_read_no_drafts_token: ${{ secrets.SANITY_READ_NO_DRAFTS }}
sanity_deploy_studio: ${{ secrets.SANITY_DEPLOY_STUDIO }}
next_encryption_key: ${{ secrets.NEXT_ENCRYPTION_KEY }}
- name: Build and push Docker image
uses: nais/docker-build-push@v0
id: docker-push
with:
team: designsystem
push_image: true
dockerfile: aksel.nav.no/Dockerfile
project_id: ${{ vars.NAIS_MANAGEMENT_PROJECT_ID }}
identity_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
- name: Deploy to prod-gcp
uses: nais/deploy/actions/deploy@master
env:
APIKEY: ${{ secrets.NAIS_DEPLOY_APIKEY }}
RESOURCE: aksel.nav.no/nais-prod.yaml
CLUSTER: prod-gcp
IMAGE: ${{ steps.docker-push.outputs.image }}
+62
View File
@@ -0,0 +1,62 @@
name: Deploy prod (aksel-v7.nav.no)
on:
workflow_dispatch:
push:
branches:
- v7-aksel.nav.no
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: false
jobs:
build_and_deploy:
name: Build and deploy to prod-gcp
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/v7-aksel.nav.no'
permissions:
packages: "write"
contents: "read"
id-token: "write"
steps:
- name: Checkout code
uses: actions/checkout@v6
with:
fetch-depth: 1
- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: lts/*
- name: Install dependencies
run: cd v7-aksel.nav.no && yarn --immutable
shell: bash
- name: Set production env var
run: |
echo "PRODUCTION=true" >> v7-aksel.nav.no/website/.env
shell: bash
- name: Build Next.js website
run: cd v7-aksel.nav.no && yarn build
shell: bash
- name: Build and push Docker image
uses: nais/docker-build-push@v0
id: docker-push
with:
team: designsystem
push_image: true
dockerfile: v7-aksel.nav.no/Dockerfile
project_id: ${{ vars.NAIS_MANAGEMENT_PROJECT_ID }}
identity_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
- name: Deploy to prod-gcp
uses: nais/deploy/actions/deploy@master
env:
APIKEY: ${{ secrets.NAIS_DEPLOY_APIKEY }}
RESOURCE: v7-aksel.nav.no/nais-prod.yaml
CLUSTER: prod-gcp
IMAGE: ${{ steps.docker-push.outputs.image }}
-54
View File
@@ -1,54 +0,0 @@
name: E2E / Playwright Tests
on:
push:
branches: [main, next]
paths:
- "aksel.nav.no/**"
pull_request:
branches: [main, next]
paths:
- "aksel.nav.no/**"
jobs:
playwright:
runs-on: ubuntu-latest
container:
image: mcr.microsoft.com/playwright:v1.35.1-jammy
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: "20"
- name: add tokens to .env
run: |
echo "SANITY_WRITE_KEY=${{ secrets.SANITY_FEEDBACK_WRITE_KEY }}" >> aksel.nav.no/website/.env
echo "SANITY_PREVIEW_TOKEN=${{ secrets.SANITY_PREVIEW_TOKEN }}" >> aksel.nav.no/website/.env
echo "SANITY_PRIVATE_NO_DRAFTS=${{ secrets.SANITY_PRIVATE_NO_DRAFTS }}" >> aksel.nav.no/website/.env
- name: Restore cache
uses: actions/cache@v3
with:
path: "**/node_modules"
key: ${{ runner.os }}-e2e-${{ github.sha }}
restore-keys: |
${{ runner.os }}-e2e-
- name: Install dependencies
run: yarn
- name: Build packages
run: |
yarn boot
- name: Build application
run: yarn workspace aksel.nav.no build:next
- name: Run Playwright tests
run: yarn workspace website e2e:ci-full
- uses: actions/upload-artifact@v3
if: always()
with:
name: playwright-report
path: aksel.nav.no/website/playwright-report/
retention-days: 10
-30
View File
@@ -1,30 +0,0 @@
name: "push-to-cdn"
on:
workflow_dispatch:
push:
branches:
- "main"
paths:
- "fonts/**"
jobs:
upload:
runs-on: ubuntu-latest
permissions:
contents: "read"
id-token: "write"
steps:
- uses: "actions/checkout@v3"
- id: upload
uses: navikt/frontend/actions/cdn-upload/v1@main
with:
cdn-team-name: aksel
source: ./fonts
destination: "" # uploads folder to team root
- run: echo uploaded file ${{ steps.upload.outputs.uploaded }}
shell: bash
+34 -27
View File
@@ -1,7 +1,10 @@
name: Release
name: Release packages
on:
push:
paths:
- ".changeset/**"
- "@navikt/**"
branches:
- main
workflow_dispatch:
@@ -10,8 +13,8 @@ concurrency: ${{ github.workflow }}-${{ github.ref }}
jobs:
build:
name: "Release packages"
if: ${{!contains(github.event.head_commit.message, '[ci skip]')}}
name: Release packages
if: ${{ !contains(github.event.head_commit.message, '[ci skip]') }}
runs-on: ubuntu-latest
permissions:
id-token: "write"
@@ -19,43 +22,43 @@ jobs:
packages: "write"
pull-requests: "write"
steps:
- uses: actions/checkout@v3
- name: Checkout code
uses: actions/checkout@v6
with:
fetch-depth: 0
- uses: actions/setup-node@v3
- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: "20"
node-version: lts/*
cache: yarn
cache-dependency-path: "yarn.lock"
- uses: denoland/setup-deno@v1
- name: Setup Deno
uses: denoland/setup-deno@v2
with:
deno-version: v1.x
- name: Restore cache
uses: actions/cache@v3
with:
path: "**/node_modules"
key: ${{ runner.os }}-prod-${{ github.sha }}
restore-keys: |
${{ runner.os }}-prod
- name: Install dependencies
run: yarn
env:
NPM_AUTH_TOKEN: ${{ secrets.READER_TOKEN }}
- name: Create release Pull Request or publish to NPM
id: changesets
uses: changesets/action@v1
with:
version: yarn version
version: yarn create-version
publish: yarn release
createGithubReleases: false
env:
NPM_TOKEN: ${{ secrets.NPM_AUTOMATION }}
# Use OIDC for npm authentication instead of NPM_TOKEN
# https://github.com/changesets/changesets/issues/1152#issuecomment-3190884868
NPM_TOKEN: ""
# Needed for push to main
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTOMATION }}
- name: Creating .npmrc
- name: Create .npmrc for GPR
run: |
cat << EOF > "$HOME/.npmrc"
@navikt:registry=https://npm.pkg.github.com
@@ -72,21 +75,23 @@ jobs:
publish: yarn changeset publish
createGithubReleases: false
env:
NPM_TOKEN: ${{ secrets.NPM_AUTOMATION }}
NPM_TOKEN: ""
# Needed for push to main
GITHUB_TOKEN: ${{ secrets.GIT_REPO }}
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTOMATION }}
- name: Generate icon.zip
if: steps.changesets.outputs.published == 'true'
run: yarn zip:icons
- name: Upload updated icon.zip to NAV CDN
- name: Upload updated icon.zip to Nav CDN
if: steps.changesets.outputs.published == 'true'
uses: navikt/frontend/actions/cdn-upload/v1@main
uses: nais/deploy/actions/cdn-upload/v2@master
with:
cdn-team-name: aksel
team: aksel
source: ./@navikt/aksel-icons/aksel-icons.zip
destination: "/icons/zip"
project_id: ${{ vars.NAIS_MANAGEMENT_PROJECT_ID }}
identity_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
- name: Get @navikt/ds-css version
run: |
@@ -94,10 +99,12 @@ jobs:
echo "version=$VERSION" >> $GITHUB_ENV
echo "Version of @navikt/ds-css: ${{ env.version }}"
- name: Upload CSS to NAV CDN
- name: Upload CSS to Nav CDN
if: steps.changesets.outputs.published == 'true'
uses: navikt/frontend/actions/cdn-upload/v1@main
uses: nais/deploy/actions/cdn-upload/v2@master
with:
cdn-team-name: aksel
team: aksel
source: ./@navikt/core/css/dist/version/${{env.version}}
destination: "@navikt/ds-css"
project_id: ${{ vars.NAIS_MANAGEMENT_PROJECT_ID }}
identity_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
-48
View File
@@ -1,48 +0,0 @@
name: Smoketest aksel.nav.no
on:
push:
branches:
- main
paths:
- "aksel.nav.no/**"
env:
IMAGE: ghcr.io/navikt/aksel
jobs:
smoketest:
name: Smoketest Aksel
runs-on: ubuntu-latest
container:
image: mcr.microsoft.com/playwright:v1.35.1-jammy
steps:
- uses: actions/setup-node@v3
with:
node-version: "20"
- uses: actions/checkout@v3
- name: add tokens to .env
run: |
echo "SANITY_WRITE_KEY=${{ secrets.SANITY_FEEDBACK_WRITE_KEY }}" >> aksel.nav.no/website/.env
echo "SANITY_PREVIEW_TOKEN=${{ secrets.SANITY_PREVIEW_TOKEN }}" >> aksel.nav.no/website/.env
echo "SANITY_PRIVATE_NO_DRAFTS=${{ secrets.SANITY_PRIVATE_NO_DRAFTS }}" >> aksel.nav.no/website/.env
- name: Restore cache
uses: actions/cache@v3
with:
path: "**/node_modules"
key: ${{ runner.os }}-prod-${{ github.sha }}
restore-keys: |
${{ runner.os }}-prod-
- name: Install dependencies
run: yarn
- name: build packages
run: |
yarn boot
- name: Build application
run: yarn workspace aksel.nav.no build:next
- name: E2E smoketest
run: yarn workspace website e2e:ci
@@ -0,0 +1,34 @@
name: Update article views (Naisjob)
on:
workflow_dispatch:
jobs:
execute:
name: Build and deploy article views job
runs-on: ubuntu-latest
permissions:
contents: read
id-token: write
steps:
- name: Checkout code
uses: actions/checkout@v6
with:
fetch-depth: 1
- name: Build and push Docker image
uses: nais/docker-build-push@v0
id: docker-push
with:
team: designsystem
push_image: true
dockerfile: scripts/deno/article-views/Dockerfile.update-article-views
project_id: ${{ vars.NAIS_MANAGEMENT_PROJECT_ID }}
identity_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
- name: Deploy Naisjob to prod-gcp
uses: nais/deploy/actions/deploy@master
env:
APIKEY: ${{ secrets.NAIS_DEPLOY_APIKEY }}
RESOURCE: scripts/deno/article-views/nais-update-views-job.yml
CLUSTER: prod-gcp
IMAGE: ${{ steps.docker-push.outputs.image }}
+2 -2
View File
@@ -76,9 +76,9 @@ yarn-error.log
# Transpiled package files
packages/**/lib
*.d.ts
.vscode
.nvim.lua
# File created on build in nav-frontend-core
*-exports.less
@@ -151,4 +151,4 @@ playwright-report/
backup-*.tar.gz
sitemap-urls.json
*.tar.gz
searchindex.json
aksel.nav.no/website/public/rss
+9
View File
@@ -0,0 +1,9 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"
CHANGED=`git diff $1 $2 --stat -- yarn.lock | wc -l`
if [ $CHANGED -gt 0 ];
then
echo
echo "*** 🟡 yarn.lock has changed 🟡 ***"
fi
+9
View File
@@ -0,0 +1,9 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"
CHANGED=`git diff HEAD@{1} --stat -- yarn.lock | wc -l`
if [ $CHANGED -gt 0 ];
then
echo
echo "*** 🟡 yarn.lock has changed 🟡 ***"
fi
+1 -1
View File
@@ -1,4 +1,4 @@
#!/bin/sh
. "$(dirname $0)/_/husky.sh"
yarn pretty-quick --staged && yarn lint-staged
yarn lint-staged
+13
View File
@@ -0,0 +1,13 @@
#!/bin/sh
. "$(dirname $0)/_/husky.sh"
# Only run tests when pushing to main branch
while read local_ref local_sha remote_ref remote_sha; do
if [ "$remote_ref" = "refs/heads/main" ]; then
echo "Pushing to main branch - running tests...\n"
yarn test
exit $?
fi
done
exit 0
+8
View File
@@ -0,0 +1,8 @@
designsystemet:
# commits: ""
# issues: ""
pulls: "#aksel-issues-pr"
workflows: "#aksel-issues-pr"
releases: "#aksel-github-releases"
config:
silenceDependabot: "always"
+15 -2
View File
@@ -1,2 +1,15 @@
**/nais-dev.yaml
**/nais-prod.yaml
**/nais*.yaml
**/nais*.yml
**/codemod/**/tests/**/*.js
**/@navikt/aksel/**/*.input.*
**/@navikt/aksel/**/*.output.*
node_modules
.next
dist
public
static
cjs
esm
aksel-icons/template
aksel-icons/icons/*.svg
File renamed without changes.
File renamed without changes.
+175
View File
@@ -0,0 +1,175 @@
import { Meta } from "@storybook/addon-docs/blocks";
import AkselThumbnail from "./assets/aksel-thumbnail.png";
import Components from "./assets/components.png";
import Setup from "./assets/setup.png";
<Meta title="Docs/Getting started" />
<div className="sb-container">
<div className='sb-section-title'>
# Getting started
Aksel is the toolbox for product development <a href="https://aksel.nav.no"target="_blank">@Nav</a> (Norwegian Labour and Welfare Administration)
This includes a designsystem, best practices for product-development, principles for user-experience and a blog. <a href="https://aksel.nav.no/god-praksis/artikler/om-aksel" target="_blank">
Read more about Aksel.</a>
</div>
<div className="sb-section">
<div className="sb-section-item">
<img
src={AkselThumbnail}
alt="Aksel-thumbnail"
aria-hidden
/>
<h3 className="sb-section-item-heading"><a
href="https://aksel.nav.no"
target="_blank"
className="sb-link"
>Website</a></h3>
<p className="sb-section-item-paragraph">Includes everything you need to get started building and developing digital products for Nav today.</p>
</div>
<div className="sb-section-item">
<img
src={Setup}
alt="Setup-thumbnail"
aria-hidden
/>
<h3 className="sb-section-item-heading"><a
href="https://aksel.nav.no/grunnleggende/introduksjon/kom-i-gang-med-kodepakkene"
target="_blank"
className="sb-link"
>Setup</a></h3>
<p className="sb-section-item-paragraph">Get started developing using our solutions. How to install, setup and use our React, CSS and Icons.</p>
</div>
<div className="sb-section-item">
<img
src={Components}
alt="Components-thumbnail"
aria-hidden
/>
<h3 className="sb-section-item-heading"><a
href="https://aksel.nav.no/komponenter"
target="_blank"
className="sb-link"
>Components</a></h3>
<p className="sb-section-item-paragraph">Browse trough 40+ components with examples, do and don't, props and accessibility information.</p>
</div>
</div>
</div>
<div className="sb-container">
<div className='sb-section-title'>
## More than just a component library
Aksel offers tools that makes developing frontend-applications easier.
</div>
<div className="sb-section">
<div className="sb-section-item">
<h3 className="sb-section-item-heading"><a
href="https://aksel.nav.no/ikoner"
target="_blank"
className="sb-link"
>Icons</a></h3>
<p className="sb-section-item-paragraph">We provide an icon library with 800+ open-source icons.</p>
</div>
<div className="sb-section-item">
<h3 className="sb-section-item-heading"><a
href="https://aksel.nav.no/grunnleggende/styling/design-tokens"
target="_blank"
className="sb-link"
>Tokens</a></h3>
<p className="sb-section-item-paragraph">Colors, spacing, shadows and more. All available for CSS, SASS, Less and JS.</p>
</div>
<div className="sb-section-item">
<h3 className="sb-section-item-heading"><a
href="https://aksel.nav.no/grunnleggende/kode/stylelint"
target="_blank"
className="sb-link"
>Stylelint</a></h3>
<p className="sb-section-item-paragraph">Using our Stylelint-plugin helps keep your code free from bugs and makes adopting updates safer.</p>
</div>
<div className="sb-section-item">
<h3 className="sb-section-item-heading"><a
href="https://aksel.nav.no/grunnleggende/kode/tailwind"
target="_blank"
className="sb-link"
>Tailwind</a></h3>
<p className="sb-section-item-paragraph">Our tokens made available as a simple tailwind-config.</p>
</div>
<div className="sb-section-item">
<h3 className="sb-section-item-heading"><a
href="https://aksel.nav.no/grunnleggende/kode/kommandolinje"
target="_blank"
className="sb-link"
>CLI</a></h3>
<p className="sb-section-item-paragraph">CLI for codemods</p>
</div>
</div>
</div>
<style>
{`
.sb-container {
margin-bottom: 48px;
}
.sb-section {
width: 100%;
display: grid;
grid-template-columns: repeat(3, 1fr);
grid-gap: 1.5rem;
}
.sb-link{
text-decoration: underline;
color: #111;
}
img {
object-fit: cover;
padding-bottom: 1.25rem;
border-radius: 8px;
}
.sb-section-title {
margin-bottom: 2rem;
}
.sb-section-item-heading {
padding-bottom: 0.25rem
margin: 0 !important;
}
.sb-section-item-paragraph {
margin: 0;
padding-bottom: 0.75rem;
}
@media screen and (max-width: 768px) {
.sb-section {
grid-template-columns: repeat(1, 1fr);
}
}
`}
</style>
-175
View File
@@ -1,175 +0,0 @@
import { Meta } from "@storybook/blocks";
import AkselThumbnail from "./assets/aksel-thumbnail.png";
import Setup from "./assets/setup.png";
import Components from "./assets/components.png";
<Meta title="Getting started" />
<div className="sb-container">
<div className='sb-section-title'>
# Getting started
Aksel is the toolbox for product development <a href="https://aksel.nav.no"target="_blank">@NAV</a> (Norwegian Labour and Welfare Administration)
This includes a designsystem, best practices for product-development, principles for user-experience and a blog. <a href="https://aksel.nav.no/god-praksis/artikler/om-aksel" target="_blank">
Read more about Aksel.</a>
</div>
<div className="sb-section">
<div className="sb-section-item">
<img
src={AkselThumbnail}
alt="Aksel-thumbnail"
aria-hidden
/>
<h3 className="sb-section-item-heading"><a
href="https://aksel.nav.no"
target="_blank"
className="sb-link"
>Website</a></h3>
<p className="sb-section-item-paragraph">Includes everything you need to get started building and developing digital products for NAV today.</p>
</div>
<div className="sb-section-item">
<img
src={Setup}
alt="Setup-thumbnail"
aria-hidden
/>
<h3 className="sb-section-item-heading"><a
href="https://aksel.nav.no/grunnleggende/introduksjon/kom-i-gang-med-kodepakkene"
target="_blank"
className="sb-link"
>Setup</a></h3>
<p className="sb-section-item-paragraph">Get started developing using our solutions. How to install, setup and use our React, CSS and Icons.</p>
</div>
<div className="sb-section-item">
<img
src={Components}
alt="Components-thumbnail"
aria-hidden
/>
<h3 className="sb-section-item-heading"><a
href="https://aksel.nav.no/komponenter"
target="_blank"
className="sb-link"
>Components</a></h3>
<p className="sb-section-item-paragraph">Browse trough 40+ components with examples, do and don't, props and accessibility information.</p>
</div>
</div>
</div>
<div className="sb-container">
<div className='sb-section-title'>
## More than just a component library
Aksel offers tools that makes developing frontend-applications easier.
</div>
<div className="sb-section">
<div className="sb-section-item">
<h3 className="sb-section-item-heading"><a
href="https://aksel.nav.no/ikoner"
target="_blank"
className="sb-link"
>Icons</a></h3>
<p className="sb-section-item-paragraph">We provide an icon library with 800+ open-source icons.</p>
</div>
<div className="sb-section-item">
<h3 className="sb-section-item-heading"><a
href="https://aksel.nav.no/grunnleggende/styling/design-tokens"
target="_blank"
className="sb-link"
>Tokens</a></h3>
<p className="sb-section-item-paragraph">Colors, spacing, shadows and more. All available for CSS, SASS, Less and JS.</p>
</div>
<div className="sb-section-item">
<h3 className="sb-section-item-heading"><a
href="https://aksel.nav.no/grunnleggende/kode/stylelint"
target="_blank"
className="sb-link"
>Stylelint</a></h3>
<p className="sb-section-item-paragraph">Using our Stylelint-plugin helps keep your code free from bugs and makes adopting updates safer.</p>
</div>
<div className="sb-section-item">
<h3 className="sb-section-item-heading"><a
href="https://aksel.nav.no/grunnleggende/kode/tailwind"
target="_blank"
className="sb-link"
>Tailwind</a></h3>
<p className="sb-section-item-paragraph">Our tokens made available as a simple tailwind-config.</p>
</div>
<div className="sb-section-item">
<h3 className="sb-section-item-heading"><a
href="https://aksel.nav.no/grunnleggende/kode/kommandolinje"
target="_blank"
className="sb-link"
>CLI</a></h3>
<p className="sb-section-item-paragraph">CLI for codemods and advanced CSS-imports</p>
</div>
</div>
</div>
<style>
{`
.sb-container {
margin-bottom: 48px;
}
.sb-section {
width: 100%;
display: grid;
grid-template-columns: repeat(3, 1fr);
grid-gap: var(--a-spacing-6);
}
.sb-link{
text-decoration: underline;
color: var(--a-text-default);
}
img {
object-fit: cover;
padding-bottom: var(--a-spacing-5);
border-radius: 8px;
}
.sb-section-title {
margin-bottom: var(--a-spacing-8);
}
.sb-section-item-heading {
padding-bottom: var(--a-spacing-1);
margin: 0 !important;
}
.sb-section-item-paragraph {
margin: 0;
padding-bottom: var(--a-spacing-3);
}
@media screen and (max-width: 768px) {
.sb-section {
grid-template-columns: repeat(1, 1fr);
}
}
`}
</style>
+23 -5
View File
@@ -1,3 +1,7 @@
body {
background-color: var(--ax-bg-default);
}
.rowgap {
display: flex;
gap: 1rem;
@@ -11,11 +15,25 @@
padding: 1rem;
}
.colgap[data-theme="dark"],
.rowgap[data-theme="dark"] {
background-color: var(--a-gray-900);
}
.rowgap-wrap {
flex-wrap: wrap;
}
.storyheading {
font-size: 18px;
background: lightblue;
color: #23262a;
padding: 2px 4px;
}
.sbdocs-content:not(.sb-unstyled) :is(p, li) {
font-size: 1.125rem;
}
.sbdocs-content:not(.sb-unstyled) li > p {
margin-bottom: 0;
}
.sbdocs-content:not(.sb-unstyled) li > ul {
margin-top: 0.25rem;
}
+146 -34
View File
@@ -1,45 +1,157 @@
module.exports = {
import { defineMain } from "@storybook/react-vite/node";
import FG from "fast-glob";
import { readFileSync } from "node:fs";
import { createRequire } from "node:module";
import { dirname, join } from "node:path";
import { fileURLToPath } from "node:url";
import { loadCsf } from "storybook/internal/csf-tools";
import { InlineConfig } from "vite";
import turbosnap from "vite-plugin-turbosnap";
import TsconfigPathsPlugin from "vite-tsconfig-paths";
const __filename = fileURLToPath(import.meta.url);
const __dirname = dirname(__filename);
const require = createRequire(import.meta.url);
const includeWebsiteStories = process.env.WITH_WEBSITE === "true";
const indexRegex = /export const args = {\s+index: (\d+),/;
export default defineMain({
experimental_indexers: (indexers) => {
// Changes here might need to be reflected in aksel.nav.no/website/.storybook/main.ts
const customIndexer = async (fileName: string, opts: any) => {
try {
let code = readFileSync(fileName, "utf-8").toString();
const index = indexRegex.exec(code)?.[1];
code = code.split(
/\/\/ EXAMPLES DO NOT INCLUDE CONTENT BELOW THIS LINE/,
)[0];
const templatePath = fileName.split(`pages/templates/`)[1];
if (!templatePath) {
console.warn(`[Storybook] Invalid template path: ${fileName}`);
return [];
}
const [templateName, name] = templatePath
.replace(".tsx", "")
.split("/");
if (!templateName || !name) {
console.warn(
`[Storybook] Could not parse template name from: ${fileName}`,
);
return [];
}
const storyName = process.env.CHROMATIC
? `${templateName} [${index ?? "0"}] ${name}` // Chromatic does not support folders, and doesn't like |
: `${index ?? "0"} | ${name}`;
code += `
export default { title: "Templates/${templateName}/${storyName}" };
export const Demo = { render: Example };
Demo.storyName = "${storyName}";`;
return loadCsf(code, {
...opts,
fileName,
}).parse().indexInputs;
} catch (error) {
console.error(`[Storybook] Failed to index ${fileName}:`, error);
return [];
}
};
return [
...(indexers || []),
{
test: /pages\/templates\/.+?.tsx$/,
createIndex: customIndexer,
},
];
},
staticDirs: ["./public"],
stories: () => [
"../@navikt/**/*.stories.@(js|jsx|ts|tsx|mdx)",
"./*.stories.mdx",
],
stories: resolveStoriesPaths(),
addons: [
"@storybook/addon-a11y",
"@whitespace/storybook-addon-html",
"@storybook/addon-interactions",
{
name: "@storybook/addon-storysource",
options: {
loaderOptions: {
injectStoryParameters: false,
},
},
},
{
name: "@storybook/addon-essentials",
options: {
actions: false,
controls: {
hideNoControlsWarning: true,
},
},
},
getAbsolutePath("@storybook/addon-a11y"),
getAbsolutePath("@storybook/addon-themes"),
getAbsolutePath("@storybook/addon-docs"),
getAbsolutePath("@storybook/addon-vitest"),
],
framework: {
name: "@storybook/react-vite",
name: getAbsolutePath("@storybook/react-vite"),
options: {},
},
features: {
storyStoreV7: true,
},
docs: {
autodocs: "tag",
},
typescript: {
check: false,
checkOptions: {},
reactDocgen: false,
},
};
async viteFinal(config, { configType }) {
const { mergeConfig } = await import("vite");
// The TsconfigPathsPlugin is only used to silence errors when importing nextjs components, but the imports does not acutally work.
const tsConfigPathsPluginOpts = { root: "aksel.nav.no/website/" };
return mergeConfig(config, {
build: { cssMinify: "lightningcss" },
plugins:
configType === "PRODUCTION"
? [
TsconfigPathsPlugin(tsConfigPathsPluginOpts),
turbosnap({
rootDir: config.root ?? process.cwd(),
}),
]
: [TsconfigPathsPlugin(tsConfigPathsPluginOpts)],
} satisfies InlineConfig);
},
/* Lets us preview Roboto-flex font in storybook. */
previewHead: (head) => `
${head}
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Open+Sans:ital,wght@0,300..800;1,300..800&display=swap" rel="stylesheet">`,
features: {
actions: false,
},
});
function getAbsolutePath(value: string) {
return dirname(require.resolve(join(value, "package.json")));
}
function resolveStoriesPaths() {
const paths = [
"../@navikt/**/*.stories.@(js|jsx|ts|tsx|mdx)",
"./docs/*.mdx",
"./docs/*.stories.tsx",
];
if (includeWebsiteStories) {
paths.push("../aksel.nav.no/website/pages/templates/**/*.tsx");
}
return FG.sync(paths, {
cwd: __dirname,
ignore: [
"../**/node_modules/**",
"**/dist",
"**/build",
"**/.next",
"**/esm",
"**/cjs",
],
});
}
+1 -1
View File
@@ -1,4 +1,4 @@
import { addons } from "@storybook/manager-api";
import { addons } from "storybook/manager-api";
import AkselTheme from "./theme.js";
addons.setConfig({
-59
View File
@@ -1,59 +0,0 @@
import React from "react";
import "@navikt/ds-css/index.css";
import "./layout.css";
export const parameters = {
options: {
storySort: {
method: "alphabetical",
order: [
"Getting started",
"ds-react",
["Primitives"],
["Default"],
"Aksel-icons",
],
},
},
layout: "centered",
backgrounds: {
values: [
{
name: "Canvas",
value: "#ffffff",
},
{
name: "Darkmode",
value: "#23262a",
},
],
},
};
export const globalTypes = {
theme: {
name: "Theme",
toolbar: {
icon: "circlehollow",
items: [
{ value: "light", icon: "circlehollow", title: "light" },
{ value: "dark", icon: "circle", title: "dark" },
],
showName: true,
},
},
};
export const withTheme = (StoryFn, context) => {
return (
<div
data-theme={context.parameters.theme || context.globals.theme || "light"}
lang="no"
id="root"
>
<StoryFn />
</div>
);
};
export const decorators = [withTheme];
+139
View File
@@ -0,0 +1,139 @@
import addonA11y from "@storybook/addon-a11y";
import addonDocs from "@storybook/addon-docs";
import addonThemes, { withThemeByClassName } from "@storybook/addon-themes";
import addonVitest from "@storybook/addon-vitest";
import { definePreview } from "@storybook/react-vite";
import React, { useEffect } from "react";
import "../@navikt/core/css/src/data-table.css";
import "../@navikt/core/css/src/data-token-filter.css";
import "../@navikt/core/css/src/data-toolbar.css";
import "../@navikt/core/css/src/index.css";
import "../@navikt/core/css/src/listbox.css";
import { Provider } from "../@navikt/core/react/src/provider";
import { Translations } from "../@navikt/core/react/src/utils/i18n/i18n.types";
import { en, nb, nn } from "../@navikt/core/react/src/utils/i18n/locales";
import "./layout.css";
type Language = "nb" | "nn" | "en";
const locales: Record<Language, Translations> = {
nb,
nn,
en,
};
const LanguageDecorator = ({
children,
lang,
}: {
children: React.ReactNode;
lang: Language | undefined;
}) => {
useEffect(() => {
document.documentElement.lang = lang || "nb";
}, [lang]);
return (
<Provider locale={lang ? locales[lang] : undefined}>{children}</Provider>
);
};
const fonts = ["Source Sans 3", "Open Sans"];
const TypoDecorator = ({
children,
font,
}: {
children: React.ReactNode;
font: string;
}) => {
useEffect(() => {
const fontVariable = fonts.includes(font) ? `"${font}", sans-serif` : null;
document.body.style.setProperty("--ax-font-family", fontVariable);
return () => {
document.body.style.removeProperty("--ax-font-family");
};
}, [font]);
return <>{children}</>;
};
export default definePreview({
addons: [addonA11y(), addonThemes(), addonDocs(), addonVitest()],
parameters: {
options: {
storySort: {
method: "alphabetical",
order: [
"Docs",
["Getting started"],
"ds-react",
["Primitives"],
["Default", "Controls"],
"Aksel-icons",
],
},
},
layout: "centered",
backgrounds: { disable: true },
docs: {
codePanel: true,
},
a11y: {
// 'todo' - show a11y violations in the test UI only
// 'error' - fail CI on a11y violations
// 'off' - skip a11y checks entirely
test: "todo",
},
},
globalTypes: {
language: {
toolbar: {
icon: "globe",
items: [
{ value: undefined, title: "Unset" },
{ value: "nb", right: "🇳🇴", title: "Norsk bokmål" },
{ value: "nn", right: "🇳🇴", title: "Norsk nynorsk" },
{ value: "en", right: "🇬🇧", title: "English" },
],
dynamicTitle: true,
},
},
font: {
toolbar: {
icon: "edit",
items: fonts.map((font) => ({ value: font, title: font })),
dynamicTitle: true,
},
},
},
initialGlobals: {
mode: "default",
font: "Source Sans 3",
},
decorators: [
(StoryFn, context) => (
<TypoDecorator font={context.globals.font}>
<StoryFn />
</TypoDecorator>
),
(StoryFn, context) => (
<LanguageDecorator lang={context.globals.language}>
<StoryFn />
</LanguageDecorator>
),
withThemeByClassName({
themes: {
light: "light",
dark: "dark",
},
defaultTheme: "light",
}),
],
});
+1 -1
View File
@@ -1,4 +1,4 @@
import { create } from "@storybook/theming";
import { create } from "storybook/theming";
import logoUrl from "./public/logo.svg";
export default create({
+7
View File
@@ -0,0 +1,7 @@
import * as a11yAddonAnnotations from "@storybook/addon-a11y/preview";
import { setProjectAnnotations } from "@storybook/react-vite";
import * as projectAnnotations from "./preview";
// This is an important step to apply the right configuration when testing your stories.
// More info at: https://storybook.js.org/docs/api/portable-stories/portable-stories-vitest#setprojectannotations
setProjectAnnotations([a11yAddonAnnotations, projectAnnotations]);
+13
View File
@@ -0,0 +1,13 @@
{
"recommendations": [
"dbaeumer.vscode-eslint",
"stylelint.vscode-stylelint",
"biomejs.biome",
"esbenp.prettier-vscode",
"denoland.vscode-deno",
"github.vscode-github-actions",
"ms-playwright.playwright",
"sanity-io.vscode-sanity",
"vunguyentuan.vscode-css-variables"
]
}
+14
View File
@@ -0,0 +1,14 @@
{
"cssVariables.lookupFiles": ["@navikt/core/tokens/dist/tokens.css"],
"eslint.problems.shortenToSingleLine": true,
"editor.defaultFormatter": "esbenp.prettier-vscode",
"files.watcherExclude": {
"**/.yarn/**": true,
"**/dist": true,
"**/esm": true,
"**/cjs": true
},
"playwright.reuseBrowser": true,
"js/ts.tsdk.path": "node_modules/typescript/lib",
"deno.enablePaths": ["./scripts/deno"]
}
-28
View File
@@ -1,28 +0,0 @@
/* eslint-disable */
//prettier-ignore
module.exports = {
name: "@yarnpkg/plugin-workspace-tools",
factory: function (require) {
var plugin=(()=>{var wr=Object.create,me=Object.defineProperty,Sr=Object.defineProperties,vr=Object.getOwnPropertyDescriptor,Hr=Object.getOwnPropertyDescriptors,$r=Object.getOwnPropertyNames,et=Object.getOwnPropertySymbols,kr=Object.getPrototypeOf,tt=Object.prototype.hasOwnProperty,Tr=Object.prototype.propertyIsEnumerable;var rt=(e,t,r)=>t in e?me(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,B=(e,t)=>{for(var r in t||(t={}))tt.call(t,r)&&rt(e,r,t[r]);if(et)for(var r of et(t))Tr.call(t,r)&&rt(e,r,t[r]);return e},Q=(e,t)=>Sr(e,Hr(t)),Lr=e=>me(e,"__esModule",{value:!0});var K=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Or=(e,t)=>{for(var r in t)me(e,r,{get:t[r],enumerable:!0})},Nr=(e,t,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of $r(t))!tt.call(e,n)&&n!=="default"&&me(e,n,{get:()=>t[n],enumerable:!(r=vr(t,n))||r.enumerable});return e},X=e=>Nr(Lr(me(e!=null?wr(kr(e)):{},"default",e&&e.__esModule&&"default"in e?{get:()=>e.default,enumerable:!0}:{value:e,enumerable:!0})),e);var $e=K(te=>{"use strict";te.isInteger=e=>typeof e=="number"?Number.isInteger(e):typeof e=="string"&&e.trim()!==""?Number.isInteger(Number(e)):!1;te.find=(e,t)=>e.nodes.find(r=>r.type===t);te.exceedsLimit=(e,t,r=1,n)=>n===!1||!te.isInteger(e)||!te.isInteger(t)?!1:(Number(t)-Number(e))/Number(r)>=n;te.escapeNode=(e,t=0,r)=>{let n=e.nodes[t];!n||(r&&n.type===r||n.type==="open"||n.type==="close")&&n.escaped!==!0&&(n.value="\\"+n.value,n.escaped=!0)};te.encloseBrace=e=>e.type!=="brace"?!1:e.commas>>0+e.ranges>>0==0?(e.invalid=!0,!0):!1;te.isInvalidBrace=e=>e.type!=="brace"?!1:e.invalid===!0||e.dollar?!0:e.commas>>0+e.ranges>>0==0||e.open!==!0||e.close!==!0?(e.invalid=!0,!0):!1;te.isOpenOrClose=e=>e.type==="open"||e.type==="close"?!0:e.open===!0||e.close===!0;te.reduce=e=>e.reduce((t,r)=>(r.type==="text"&&t.push(r.value),r.type==="range"&&(r.type="text"),t),[]);te.flatten=(...e)=>{let t=[],r=n=>{for(let s=0;s<n.length;s++){let a=n[s];Array.isArray(a)?r(a,t):a!==void 0&&t.push(a)}return t};return r(e),t}});var ke=K((is,at)=>{"use strict";var it=$e();at.exports=(e,t={})=>{let r=(n,s={})=>{let a=t.escapeInvalid&&it.isInvalidBrace(s),i=n.invalid===!0&&t.escapeInvalid===!0,o="";if(n.value)return(a||i)&&it.isOpenOrClose(n)?"\\"+n.value:n.value;if(n.value)return n.value;if(n.nodes)for(let h of n.nodes)o+=r(h);return o};return r(e)}});var ct=K((os,ot)=>{"use strict";ot.exports=function(e){return typeof e=="number"?e-e==0:typeof e=="string"&&e.trim()!==""?Number.isFinite?Number.isFinite(+e):isFinite(+e):!1}});var At=K((cs,ut)=>{"use strict";var lt=ct(),pe=(e,t,r)=>{if(lt(e)===!1)throw new TypeError("toRegexRange: expected the first argument to be a number");if(t===void 0||e===t)return String(e);if(lt(t)===!1)throw new TypeError("toRegexRange: expected the second argument to be a number.");let n=B({relaxZeros:!0},r);typeof n.strictZeros=="boolean"&&(n.relaxZeros=n.strictZeros===!1);let s=String(n.relaxZeros),a=String(n.shorthand),i=String(n.capture),o=String(n.wrap),h=e+":"+t+"="+s+a+i+o;if(pe.cache.hasOwnProperty(h))return pe.cache[h].result;let g=Math.min(e,t),f=Math.max(e,t);if(Math.abs(g-f)===1){let R=e+"|"+t;return n.capture?`(${R})`:n.wrap===!1?R:`(?:${R})`}let A=ft(e)||ft(t),p={min:e,max:t,a:g,b:f},k=[],y=[];if(A&&(p.isPadded=A,p.maxLen=String(p.max).length),g<0){let R=f<0?Math.abs(f):1;y=pt(R,Math.abs(g),p,n),g=p.a=0}return f>=0&&(k=pt(g,f,p,n)),p.negatives=y,p.positives=k,p.result=Ir(y,k,n),n.capture===!0?p.result=`(${p.result})`:n.wrap!==!1&&k.length+y.length>1&&(p.result=`(?:${p.result})`),pe.cache[h]=p,p.result};function Ir(e,t,r){let n=Pe(e,t,"-",!1,r)||[],s=Pe(t,e,"",!1,r)||[],a=Pe(e,t,"-?",!0,r)||[];return n.concat(a).concat(s).join("|")}function Mr(e,t){let r=1,n=1,s=ht(e,r),a=new Set([t]);for(;e<=s&&s<=t;)a.add(s),r+=1,s=ht(e,r);for(s=dt(t+1,n)-1;e<s&&s<=t;)a.add(s),n+=1,s=dt(t+1,n)-1;return a=[...a],a.sort(Br),a}function Ur(e,t,r){if(e===t)return{pattern:e,count:[],digits:0};let n=Pr(e,t),s=n.length,a="",i=0;for(let o=0;o<s;o++){let[h,g]=n[o];h===g?a+=h:h!=="0"||g!=="9"?a+=Dr(h,g,r):i++}return i&&(a+=r.shorthand===!0?"\\d":"[0-9]"),{pattern:a,count:[i],digits:s}}function pt(e,t,r,n){let s=Mr(e,t),a=[],i=e,o;for(let h=0;h<s.length;h++){let g=s[h],f=Ur(String(i),String(g),n),A="";if(!r.isPadded&&o&&o.pattern===f.pattern){o.count.length>1&&o.count.pop(),o.count.push(f.count[0]),o.string=o.pattern+gt(o.count),i=g+1;continue}r.isPadded&&(A=Gr(g,r,n)),f.string=A+f.pattern+gt(f.count),a.push(f),i=g+1,o=f}return a}function Pe(e,t,r,n,s){let a=[];for(let i of e){let{string:o}=i;!n&&!mt(t,"string",o)&&a.push(r+o),n&&mt(t,"string",o)&&a.push(r+o)}return a}function Pr(e,t){let r=[];for(let n=0;n<e.length;n++)r.push([e[n],t[n]]);return r}function Br(e,t){return e>t?1:t>e?-1:0}function mt(e,t,r){return e.some(n=>n[t]===r)}function ht(e,t){return Number(String(e).slice(0,-t)+"9".repeat(t))}function dt(e,t){return e-e%Math.pow(10,t)}function gt(e){let[t=0,r=""]=e;return r||t>1?`{${t+(r?","+r:"")}}`:""}fuLine truncated
`,CHAR_NO_BREAK_SPACE:"\xA0",CHAR_PERCENT:"%",CHAR_PLUS:"+",CHAR_QUESTION_MARK:"?",CHAR_RIGHT_ANGLE_BRACKET:">",CHAR_RIGHT_CURLY_BRACE:"}",CHAR_RIGHT_SQUARE_BRACKET:"]",CHAR_SEMICOLON:";",CHAR_SINGLE_QUOTE:"'",CHAR_SPACE:" ",CHAR_TAB:" ",CHAR_UNDERSCORE:"_",CHAR_VERTICAL_LINE:"|",CHAR_ZERO_WIDTH_NOBREAK_SPACE:"\uFEFF"}});var Pt=K((hs,Nt)=>{"use strict";var en=ke(),{MAX_LENGTH:It,CHAR_BACKSLASH:qe,CHAR_BACKTICK:tn,CHAR_COMMA:rn,CHAR_DOT:nn,CHAR_LEFT_PARENTHESES:sn,CHAR_RIGHT_PARENTHESES:an,CHAR_LEFT_CURLY_BRACE:on,CHAR_RIGHT_CURLY_BRACE:cn,CHAR_LEFT_SQUARE_BRACKET:Bt,CHAR_RIGHT_SQUARE_BRACKET:Mt,CHAR_DOUBLE_QUOTE:un,CHAR_SINGLE_QUOTE:ln,CHAR_NO_BREAK_SPACE:pn,CHAR_ZERO_WIDTH_NOBREAK_SPACE:fn}=Ot(),hn=(e,t={})=>{if(typeof e!="string")throw new TypeError("Expected a string");let r=t||{},n=typeof r.maxLength=="number"?Math.min(It,r.maxLength):It;if(e.length>n)throw new SyntaxError(`Input length (${e.length}), exceeds max characters (${n})`);let s={type:"root",input:e,nodes:[]},a=[s],i=s,o=s,h=0,g=e.length,f=0,A=0,p,k={},y=()=>e[f++],R=_=>{if(_.type==="text"&&o.type==="dot"&&(o.type="text"),o&&o.type==="text"&&_.type==="text"){o.value+=_.value;return}return i.nodes.push(_),_.parent=i,_.prev=o,o=_,_};for(R({type:"bos"});f<g;)if(i=a[a.length-1],p=y(),!(p===fn||p===pn)){if(p===qe){R({type:"text",value:(t.keepEscaping?p:"")+y()});continue}if(p===Mt){R({type:"text",value:"\\"+p});continue}if(p===Bt){h++;let _=!0,x;for(;f<g&&(x=y());){if(p+=x,x===Bt){h++;continue}if(x===qe){p+=y();continue}if(x===Mt&&(h--,h===0))break}R({type:"text",value:p});continue}if(p===sn){i=R({type:"paren",nodes:[]}),a.push(i),R({type:"text",value:p});continue}if(p===an){if(i.type!=="paren"){R({type:"text",value:p});continue}i=a.pop(),R({type:"text",value:p}),i=a[a.length-1];continue}if(p===un||p===ln||p===tn){let _=p,x;for(t.keepQuotes!==!0&&(p="");f<g&&(x=y());){if(x===qe){p+=x+y();continue}if(x===_){t.keepQuotes===!0&&(p+=x);break}p+=x}R({type:"text",value:p});continue}if(p===on){A++;let _=o.value&&o.value.slice(-1)==="$"||i.dollar===!0;i=R({type:"brace",open:!0,close:!1,dollar:_,depth:A,commas:0,ranges:0,nodes:[]}),a.push(i),R({type:"open",value:p});continue}if(p===cn){if(i.type!=="brace"){R({type:"text",value:p});continue}let _="close";i=a.pop(),i.close=!0,R({type:_,value:p}),A--,i=a[a.length-1];continue}if(p===rn&&A>0){if(i.ranges>0){i.ranges=0;let _=i.nodes.shift();i.nodes=[_,{type:"text",value:en(i)}]}R({type:"comma",value:p}),i.commas++;continue}if(p===nn&&A>0&&i.commas===0){let _=i.nodes;if(A===0||_.length===0){R({type:"text",value:p});continue}if(o.type==="dot"){if(i.range=[],o.value+=p,o.type="range",i.nodes.length!==3&&i.nodes.length!==5){i.invalid=!0,i.ranges=0,o.type="text";continue}i.ranges++,i.args=[];continue}if(o.type==="range"){_.pop();let x=_[_.length-1];x.value+=o.value+p,o=x,i.ranges--;continue}R({type:"dot",value:p});continue}R({type:"text",value:p})}do if(i=a.pop(),i.type!=="root"){i.nodes.forEach(T=>{T.nodes||(T.type==="open"&&(T.isOpen=!0),T.type==="close"&&(T.isClose=!0),T.nodes||(T.type="text"),T.invalid=!0)});let _=a[a.length-1],x=_.nodes.indexOf(i);_.nodes.splice(x,1,...i.nodes)}while(a.length>0);return R({type:"eos"}),s};Nt.exports=hn});var Gt=K((ds,Dt)=>{"use strict";var Ut=ke(),dn=Ht(),gn=Tt(),mn=Pt(),V=(e,t={})=>{let r=[];if(Array.isArray(e))for(let n of e){let s=V.create(n,t);Array.isArray(s)?r.push(...s):r.push(s)}else r=[].concat(V.create(e,t));return t&&t.expand===!0&&t.nodupes===!0&&(r=[...new Set(r)]),r};V.parse=(e,t={})=>mn(e,t);V.stringify=(e,t={})=>typeof e=="string"?Ut(V.parse(e,t),t):Ut(e,t);V.compile=(e,t={})=>(typeof e=="string"&&(e=V.parse(e,t)),dn(e,t));V.expand=(e,t={})=>{typeof e=="string"&&(e=V.parse(e,t));let r=gn(e,t);return t.noempty===!0&&(r=r.filter(Boolean)),t.nodupes===!0&&(r=[...new Set(r)]),r};V.create=(e,t={})=>e===""||e.length<3?[e]:t.expand!==!0?V.compile(e,t):V.expand(e,t);Dt.exports=V});var ye=K((gs,qt)=>{"use strict";var An=require("path"),ie="\\\\/",Kt=`[^${ie}]`,ce="\\.",Rn="\\+",yn="\\?",Le="\\/",bn="(?=.)",Wt="[^/]",Ke=`(?:${Le}|$)`,jt=`(?:^|${Le})`,We=`${ce}{1,2}${Ke}`,_n=`(?!${ce})`,En=`(?!${jt}${We})`,xn=`(?!${ce}{0,1}${Ke})`,Cn=`(?!${We})`,wn=`[^.${Le}]`,Sn=`${Wt}*?`,Ft={DOT_LITERAL:ce,PLUS_LITERAL:Rn,QMARK_LITERAL:yn,SLASH_LITERAL:Le,ONE_CHAR:bn,QMARK:Wt,END_ANCHOR:Ke,DOTS_SLASH:We,NO_DOT:_n,NO_DOTS:En,NO_DOT_SLASH:xn,NO_DOTS_SLASH:Cn,QMARK_NO_DOT:wn,STAR:Sn,START_ANCHOR:jt},vn=Q(B({},Ft),{SLASH_LITERAL:`[${ie}]`,QMARK:Kt,STAR:`${Kt}*?`,DOTS_SLASH:`${ce}{1,2}(?:[${ie}]|$)`,NO_DOT:`(?!${ce})`,NO_DOTS:`(?!(?:^|[${ie}])${ce}{1,2}(?:[${ie}]|$))`,NO_DOT_SLASH:`(?!${ce}{0,1}(?:[${ie}]|$))`,NO_DOTS_SLASH:`(?!${ce}{1,2}(?:[${ie}]|$))`,QMARK_NO_DOT:`[^.${ie}]`,START_ANCHOR:`(?:^|[${ie}])`,END_ANCHOR:`(?:[${ie}]|$)`}),Hn={alnum:"a-zA-Z0-9",alpha:"a-zA-Z",ascii:"\\x00-\\x7F",blank:" \\t",cntrl:"\\x00-\\x1F\\x7F",digit:"0-9",graph:"\\x21-\\x7E",lower:"a-z",print:"\\x20-\\x7E ",punct:"\\-!\"#$%&'()\\*+,./:;<=>?@[\\]^_`{|}~",space:" \\t\\r\\n\\v\\f",upper:"A-Z",word:"A-Za-z0-9_",xdLine truncated
/*!
* fill-range <https://github.com/jonschlinkert/fill-range>
*
* Copyright (c) 2014-present, Jon Schlinkert.
* Licensed under the MIT License.
*/
/*!
* is-number <https://github.com/jonschlinkert/is-number>
*
* Copyright (c) 2014-present, Jon Schlinkert.
* Released under the MIT License.
*/
/*!
* to-regex-range <https://github.com/micromatch/to-regex-range>
*
* Copyright (c) 2015-present, Jon Schlinkert.
* Released under the MIT License.
*/
return plugin;
}
};
-786
View File
@@ -1,786 +0,0 @@
#!/usr/bin/env node
/* eslint-disable */
//prettier-ignore
(()=>{var ofe=Object.create,Kh=Object.defineProperty,afe=Object.defineProperties,Afe=Object.getOwnPropertyDescriptor,lfe=Object.getOwnPropertyDescriptors,cfe=Object.getOwnPropertyNames,ME=Object.getOwnPropertySymbols,ufe=Object.getPrototypeOf,gQ=Object.prototype.hasOwnProperty,nM=Object.prototype.propertyIsEnumerable;var sM=(t,e,r)=>e in t?Kh(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,N=(t,e)=>{for(var r in e||(e={}))gQ.call(e,r)&&sM(t,r,e[r]);if(ME)for(var r of ME(e))nM.call(e,r)&&sM(t,r,e[r]);return t},ie=(t,e)=>afe(t,lfe(e)),gfe=t=>Kh(t,"__esModule",{value:!0});var Tr=(t,e)=>{var r={};for(var i in t)gQ.call(t,i)&&e.indexOf(i)<0&&(r[i]=t[i]);if(t!=null&&ME)for(var i of ME(t))e.indexOf(i)<0&&nM.call(t,i)&&(r[i]=t[i]);return r},ffe=(t,e)=>()=>(t&&(e=t(t=0)),e),w=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),ft=(t,e)=>{for(var r in e)Kh(t,r,{get:e[r],enumerable:!0})},hfe=(t,e,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of cfe(e))!gQ.call(t,i)&&i!=="default"&&Kh(t,i,{get:()=>e[i],enumerable:!(r=Afe(e,i))||r.enumerable});return t},ge=t=>hfe(gfe(Kh(t!=null?ofe(ufe(t)):{},"default",t&&t.__esModule&&"default"in t?{get:()=>t.default,enumerable:!0}:{value:t,enumerable:!0})),t);var DM=w((ZXe,SM)=>{SM.exports=kM;kM.sync=Dfe;var xM=require("fs");function Rfe(t,e){var r=e.pathExt!==void 0?e.pathExt:process.env.PATHEXT;if(!r||(r=r.split(";"),r.indexOf("")!==-1))return!0;for(var i=0;i<r.length;i++){var n=r[i].toLowerCase();if(n&&t.substr(-n.length).toLowerCase()===n)return!0}return!1}function PM(t,e,r){return!t.isSymbolicLink()&&!t.isFile()?!1:Rfe(e,r)}function kM(t,e,r){xM.stat(t,function(i,n){r(i,i?!1:PM(n,t,e))})}function Dfe(t,e){return PM(xM.statSync(t),t,e)}});var TM=w(($Xe,RM)=>{RM.exports=FM;FM.sync=Ffe;var NM=require("fs");function FM(t,e,r){NM.stat(t,function(i,n){r(i,i?!1:LM(n,e))})}function Ffe(t,e){return LM(NM.statSync(t),e)}function LM(t,e){return t.isFile()&&Nfe(t,e)}function Nfe(t,e){var r=t.mode,i=t.uid,n=t.gid,s=e.uid!==void 0?e.uid:process.getuid&&process.getuid(),o=e.gid!==void 0?e.gid:process.getgid&&process.getgid(),a=parseInt("100",8),l=parseInt("010",8),c=parseInt("001",8),u=a|l,g=r&c||r&l&&n===o||r&a&&i===s||r&u&&s===0;return g}});var MM=w((tZe,OM)=>{var eZe=require("fs"),ZE;process.platform==="win32"||global.TESTING_WINDOWS?ZE=DM():ZE=TM();OM.exports=xQ;xQ.sync=Lfe;function xQ(t,e,r){if(typeof e=="function"&&(r=e,e={}),!r){if(typeof Promise!="function")throw new TypeError("callback not provided");return new Promise(function(i,n){xQ(t,e||{},function(s,o){s?n(s):i(o)})})}ZE(t,e||{},function(i,n){i&&(i.code==="EACCES"||e&&e.ignoreErrors)&&(i=null,n=!1),r(i,n)})}function Lfe(t,e){try{return ZE.sync(t,e||{})}catch(r){if(e&&e.ignoreErrors||r.code==="EACCES")return!1;throw r}}});var qM=w((rZe,KM)=>{var zu=process.platform==="win32"||process.env.OSTYPE==="cygwin"||process.env.OSTYPE==="msys",UM=require("path"),Tfe=zu?";":":",HM=MM(),GM=t=>Object.assign(new Error(`not found: ${t}`),{code:"ENOENT"}),jM=(t,e)=>{let r=e.colon||Tfe,i=t.match(/\//)||zu&&t.match(/\\/)?[""]:[...zu?[process.cwd()]:[],...(e.path||process.env.PATH||"").split(r)],n=zu?e.pathExt||process.env.PATHEXT||".EXE;.CMD;.BAT;.COM":"",s=zu?n.split(r):[""];return zu&&t.indexOf(".")!==-1&&s[0]!==""&&s.unshift(""),{pathEnv:i,pathExt:s,pathExtExe:n}},YM=(t,e,r)=>{typeof e=="function"&&(r=e,e={}),e||(e={});let{pathEnv:i,pathExt:n,pathExtExe:s}=jM(t,e),o=[],a=c=>new Promise((u,g)=>{if(c===i.length)return e.all&&o.length?u(o):g(GM(t));let f=i[c],h=/^".*"$/.test(f)?f.slice(1,-1):f,p=UM.join(h,t),m=!h&&/^\.[\\\/]/.test(t)?t.slice(0,2)+p:p;u(l(m,c,0))}),l=(c,u,g)=>new Promise((f,h)=>{if(g===n.length)return f(a(u+1));let p=n[g];HM(c+p,{pathExt:s},(m,y)=>{if(!m&&y)if(e.all)o.push(c+p);else return f(c+p);return f(l(c,u,g+1))})});return r?a(0).then(c=>r(null,c),r):a(0)},Ofe=(t,e)=>{e=e||{};let{pathEnv:r,pathExt:i,pathExtExe:n}=jM(t,e),s=[];for(let o=0;o<r.length;o++){let a=r[o],l=/^".*"$/.test(a)?a.slice(1,-1):a,c=UM.join(l,t),u=!l&&/^\.[\\\/]/.test(t)?t.slice(0,2)+c:c;for(let g=0;g<i.length;g++){let f=u+i[g];try{if(HM.sync(f,{pathExt:n}))if(e.all)s.push(f);else return f}catch(h){}}}if(e.all&&s.length)return s;if(e.nothrow)return null;throw GM(t)};KM.exports=YM;YM.sync=Ofe});var WM=w((iZe,PQ)=>{"use strict";var JM=(t={})=>{let e=t.env||process.env;return(t.platform||process.platform)!=="win32"?"PATH":Object.keys(e).reverse().find(i=>i.toUpperCase()==="PATH")||"Path"};PQ.exports=JM;PQ.exports.default=JM});var XM=w((nZe,zM)=>{"use strict";var _M=require("path"),Mfe=qM(),Kfe=WM();function VM(t,e){let r=t.options.env||process.env,i=process.cwd(),n=t.options.cwd!=null,s=n&&process.chdir!==void 0&&!process.chdir.disabled;if(s)try{process.chdir(t.options.cwd)}catch(a){}let o;try{o=Mfe.sync(t.command,{path:r[Kfe({env:r})],pathExt:e?_M.delimiter:void 0})}catch(a){}finally{s&&process.chdir(i)}return o&&(o=_M.resolve(n?t.options.cwd:"",o)),o}function Ufe(t){return VM(t)||VM(t,!0)}zM.exports=Ufe});var ZM=w((sZe,DQ)=>{Line truncated
`,Yn=Ee(`\\
`,!1),hs=function(){return""},ps="\\",pt=Ee("\\",!1),xo=/^[\\$"`]/,lt=_e(["\\","$",'"',"`"],!1,!1),mn=function(C){return C},v="\\a",Tt=Ee("\\a",!1),Ou=function(){return"a"},ql="\\b",xh=Ee("\\b",!1),Ph=function(){return"\b"},Dh=/^[Ee]/,Rh=_e(["E","e"],!1,!1),Fh=function(){return""},G="\\f",yt=Ee("\\f",!1),RA=function(){return"\f"},$i="\\n",Jl=Ee("\\n",!1),$e=function(){return`
`},Ba="\\r",Mu=Ee("\\r",!1),kE=function(){return"\r"},Nh="\\t",xE=Ee("\\t",!1),gr=function(){return" "},qn="\\v",Wl=Ee("\\v",!1),Lh=function(){return"\v"},Xs=/^[\\'"?]/,ba=_e(["\\","'",'"',"?"],!1,!1),En=function(C){return String.fromCharCode(parseInt(C,16))},Me="\\x",Ku=Ee("\\x",!1),zl="\\u",Zs=Ee("\\u",!1),_l="\\U",FA=Ee("\\U",!1),Uu=function(C){return String.fromCodePoint(parseInt(C,16))},Hu=/^[0-7]/,Qa=_e([["0","7"]],!1,!1),va=/^[0-9a-fA-f]/,it=_e([["0","9"],["a","f"],["A","f"]],!1,!1),Po=ot(),NA="-",Vl=Ee("-",!1),$s="+",Xl=Ee("+",!1),PE=".",Th=Ee(".",!1),Gu=function(C,Q,F){return{type:"number",value:(C==="-"?-1:1)*parseFloat(Q.join("")+"."+F.join(""))}},Oh=function(C,Q){return{type:"number",value:(C==="-"?-1:1)*parseInt(Q.join(""))}},DE=function(C){return N({type:"variable"},C)},Zl=function(C){return{type:"variable",name:C}},RE=function(C){return C},ju="*",LA=Ee("*",!1),Lr="/",FE=Ee("/",!1),eo=function(C,Q,F){return{type:Q==="*"?"multiplication":"division",right:F}},to=function(C,Q){return Q.reduce((F,U)=>N({left:F},U),C)},Yu=function(C,Q,F){return{type:Q==="+"?"addition":"subtraction",right:F}},TA="$((",R=Ee("$((",!1),q="))",me=Ee("))",!1),Ge=function(C){return C},Te="$(",Xe=Ee("$(",!1),Et=function(C){return C},Rt="${",Jn=Ee("${",!1),_b=":-",PO=Ee(":-",!1),DO=function(C,Q){return{name:C,defaultValue:Q}},Vb=":-}",RO=Ee(":-}",!1),FO=function(C){return{name:C,defaultValue:[]}},Xb=":+",NO=Ee(":+",!1),LO=function(C,Q){return{name:C,alternativeValue:Q}},Zb=":+}",TO=Ee(":+}",!1),OO=function(C){return{name:C,alternativeValue:[]}},$b=function(C){return{name:C}},MO="$",KO=Ee("$",!1),UO=function(C){return e.isGlobPattern(C)},HO=function(C){return C},eQ=/^[a-zA-Z0-9_]/,tQ=_e([["a","z"],["A","Z"],["0","9"],"_"],!1,!1),rQ=function(){return M()},iQ=/^[$@*?#a-zA-Z0-9_\-]/,nQ=_e(["$","@","*","?","#",["a","z"],["A","Z"],["0","9"],"_","-"],!1,!1),GO=/^[(){}<>$|&; \t"']/,qu=_e(["(",")","{","}","<",">","$","|","&",";"," "," ",'"',"'"],!1,!1),sQ=/^[<>&; \t"']/,oQ=_e(["<",">","&",";"," "," ",'"',"'"],!1,!1),NE=/^[ \t]/,LE=_e([" "," "],!1,!1),B=0,He=0,OA=[{line:1,column:1}],d=0,E=[],I=0,D;if("startRule"in e){if(!(e.startRule in i))throw new Error(`Can't start parsing from rule "`+e.startRule+'".');n=i[e.startRule]}function M(){return t.substring(He,B)}function _(){return It(He,B)}function ne(C,Q){throw Q=Q!==void 0?Q:It(He,B),Mi([ut(C)],t.substring(He,B),Q)}function Be(C,Q){throw Q=Q!==void 0?Q:It(He,B),Wn(C,Q)}function Ee(C,Q){return{type:"literal",text:C,ignoreCase:Q}}function _e(C,Q,F){return{type:"class",parts:C,inverted:Q,ignoreCase:F}}function ot(){return{type:"any"}}function wt(){return{type:"end"}}function ut(C){return{type:"other",description:C}}function nt(C){var Q=OA[C],F;if(Q)return Q;for(F=C-1;!OA[F];)F--;for(Q=OA[F],Q={line:Q.line,column:Q.column};F<C;)t.charCodeAt(F)===10?(Q.line++,Q.column=1):Q.column++,F++;return OA[C]=Q,Q}function It(C,Q){var F=nt(C),U=nt(Q);return{start:{offset:C,line:F.line,column:F.column},end:{offset:Q,line:U.line,column:U.column}}}function ke(C){B<d||(B>d&&(d=B,E=[]),E.push(C))}function Wn(C,Q){return new sc(C,null,null,Q)}function Mi(C,Q,F){return new sc(sc.buildMessage(C,Q),C,Q,F)}function MA(){var C,Q;return C=B,Q=Yr(),Q===r&&(Q=null),Q!==r&&(He=C,Q=s(Q)),C=Q,C}function Yr(){var C,Q,F,U,ue;if(C=B,Q=qr(),Q!==r){for(F=[],U=je();U!==r;)F.push(U),U=je();F!==r?(U=Sa(),U!==r?(ue=ds(),ue===r&&(ue=null),ue!==r?(He=C,Q=o(Q,U,ue),C=Q):(B=C,C=r)):(B=C,C=r)):(B=C,C=r)}else B=C,C=r;if(C===r)if(C=B,Q=qr(),Q!==r){for(F=[],U=je();U!==r;)F.push(U),U=je();F!==r?(U=Sa(),U===r&&(U=null),U!==r?(He=C,Q=a(Q,U),C=Q):(B=C,C=r)):(B=C,C=r)}else B=C,C=r;return C}function ds(){var C,Q,F,U,ue;for(C=B,Q=[],F=je();F!==r;)Q.push(F),F=je();if(Q!==r)if(F=Yr(),F!==r){for(U=[],ue=je();ue!==r;)U.push(ue),ue=je();U!==r?(He=C,Q=l(F),C=Q):(B=C,C=r)}else B=C,C=r;else B=C,C=r;return C}function Sa(){var C;return t.charCodeAt(B)===59?(C=c,B++):(C=r,I===0&&ke(u)),C===r&&(t.charCodeAt(B)===38?(C=g,B++):(C=r,I===0&&ke(f))),C}function qr(){var C,Q,F;return C=B,Q=jO(),Q!==r?(F=jge(),F===r&&(F=null),F!==r?(He=C,Q=h(Q,F),C=Q):(B=C,C=r)):(B=C,C=r),C}function jge(){var C,Q,F,U,ue,De,Ct;for(C=B,Q=[],F=je();F!==r;)Q.push(F),F=je();if(Q!==r)if(F=Yge(),F!==r){for(U=[],ue=je();ue!==r;)U.push(ue),ue=je();if(U!==r)if(ue=qr(),ue!==r){for(De=[],Ct=je();Ct!==r;)De.push(Ct),Ct=je();De!==r?(He=C,Q=p(F,ue),C=Q):(B=C,C=r)}else B=C,C=r;else B=C,C=r}else B=C,C=r;else B=C,C=r;return C}function Yge(){var C;return t.substr(B,2)===m?(C=m,B+=2):(C=r,I===0&&ke(y)),C===r&&(t.substr(B,2)===b?(C=b,B+=2):(C=r,I===0&&ke(S))),C}function jO(){var C,Q,F;return C=B,Q=Wge(),Q!==r?(F=qge(),F===r&&(F=null),F!==r?(He=C,Q=k(Q,F),C=Q):(B=C,C=r)):(B=C,C=r),C}function qge(){var C,Q,F,U,ue,De,Ct;for(C=B,Q=[],F=je();F!==r;)Q.push(F),F=je();if(Q!==r)if(F=Jge(),F!==r){for(U=[],ue=je();ue!==r;)U.push(ue),ue=je();if(U!==r)if(ue=jO(),ue!==r){for(De=[],Ct=je();Ct!==r;)De.push(Ct),Ct=je();De!==r?(He=C,Q=T(F,ue),C=Q):(B=C,C=r)}else B=C,C=r;else B=C,C=r}else B=C,C=r;else B=C,C=r;retuLine truncated
\x85\u2028\u2029`.indexOf(this.buffer.charAt(n-1))===-1;)if(n-=1,this.position-n>r/2-1){i=" ... ",n+=5;break}for(s="",o=this.position;o<this.buffer.length&&`\0\r
\x85\u2028\u2029`.indexOf(this.buffer.charAt(o))===-1;)if(o+=1,o-this.position>r/2-1){s=" ... ",o-=5;break}return a=this.buffer.slice(n,o),BK.repeat(" ",e)+i+a+s+`
`+BK.repeat(" ",e+this.position-n+i.length)+"^"};YQ.prototype.toString=function(e){var r,i="";return this.name&&(i+='in "'+this.name+'" '),i+="at line "+(this.line+1)+", column "+(this.column+1),e||(r=this.getSnippet(),r&&(i+=`:
`+r)),i};wK.exports=YQ});var li=w((DZe,QK)=>{"use strict";var vK=Zu(),ghe=["kind","resolve","construct","instanceOf","predicate","represent","defaultStyle","styleAliases"],fhe=["scalar","sequence","mapping"];function hhe(t){var e={};return t!==null&&Object.keys(t).forEach(function(r){t[r].forEach(function(i){e[String(i)]=r})}),e}function phe(t,e){if(e=e||{},Object.keys(e).forEach(function(r){if(ghe.indexOf(r)===-1)throw new vK('Unknown option "'+r+'" is met in definition of "'+t+'" YAML type.')}),this.tag=t,this.kind=e.kind||null,this.resolve=e.resolve||function(){return!0},this.construct=e.construct||function(r){return r},this.instanceOf=e.instanceOf||null,this.predicate=e.predicate||null,this.represent=e.represent||null,this.defaultStyle=e.defaultStyle||null,this.styleAliases=hhe(e.styleAliases||null),fhe.indexOf(this.kind)===-1)throw new vK('Unknown kind "'+this.kind+'" is specified for "'+t+'" YAML type.')}QK.exports=phe});var cc=w((RZe,SK)=>{"use strict";var kK=lc(),sI=Zu(),dhe=li();function qQ(t,e,r){var i=[];return t.include.forEach(function(n){r=qQ(n,e,r)}),t[e].forEach(function(n){r.forEach(function(s,o){s.tag===n.tag&&s.kind===n.kind&&i.push(o)}),r.push(n)}),r.filter(function(n,s){return i.indexOf(s)===-1})}function Che(){var t={scalar:{},sequence:{},mapping:{},fallback:{}},e,r;function i(n){t[n.kind][n.tag]=t.fallback[n.tag]=n}for(e=0,r=arguments.length;e<r;e+=1)arguments[e].forEach(i);return t}function $u(t){this.include=t.include||[],this.implicit=t.implicit||[],this.explicit=t.explicit||[],this.implicit.forEach(function(e){if(e.loadKind&&e.loadKind!=="scalar")throw new sI("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.")}),this.compiledImplicit=qQ(this,"implicit",[]),this.compiledExplicit=qQ(this,"explicit",[]),this.compiledTypeMap=Che(this.compiledImplicit,this.compiledExplicit)}$u.DEFAULT=null;$u.create=function(){var e,r;switch(arguments.length){case 1:e=$u.DEFAULT,r=arguments[0];break;case 2:e=arguments[0],r=arguments[1];break;default:throw new sI("Wrong number of arguments for Schema.create function")}if(e=kK.toArray(e),r=kK.toArray(r),!e.every(function(i){return i instanceof $u}))throw new sI("Specified list of super schemas (or a single Schema object) contains a non-Schema object.");if(!r.every(function(i){return i instanceof dhe}))throw new sI("Specified list of YAML types (or a single Type object) contains a non-Type object.");return new $u({include:e,explicit:r})};SK.exports=$u});var PK=w((FZe,xK)=>{"use strict";var mhe=li();xK.exports=new mhe("tag:yaml.org,2002:str",{kind:"scalar",construct:function(t){return t!==null?t:""}})});var RK=w((NZe,DK)=>{"use strict";var Ehe=li();DK.exports=new Ehe("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(t){return t!==null?t:[]}})});var NK=w((LZe,FK)=>{"use strict";var Ihe=li();FK.exports=new Ihe("tag:yaml.org,2002:map",{kind:"mapping",construct:function(t){return t!==null?t:{}}})});var oI=w((TZe,LK)=>{"use strict";var yhe=cc();LK.exports=new yhe({explicit:[PK(),RK(),NK()]})});var OK=w((OZe,TK)=>{"use strict";var whe=li();function Bhe(t){if(t===null)return!0;var e=t.length;return e===1&&t==="~"||e===4&&(t==="null"||t==="Null"||t==="NULL")}function bhe(){return null}function Qhe(t){return t===null}TK.exports=new whe("tag:yaml.org,2002:null",{kind:"scalar",resolve:Bhe,construct:bhe,predicate:Qhe,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"}},defaultStyle:"lowercase"})});var KK=w((MZe,MK)=>{"use strict";var vhe=li();function She(t){if(t===null)return!1;var e=t.length;return e===4&&(t==="true"||t==="True"||t==="TRUE")||e===5&&(t==="false"||t==="False"||t==="FALSE")}function khe(t){return t==="true"||t==="True"||t==="TRUE"}function xhe(t){return Object.prototype.toString.call(t)==="[object Boolean]"}MK.exports=new vhe("tag:yaml.org,2002:bool",{kind:"scalar",resolve:She,construct:khe,predicate:xhe,represent:{lowercase:function(t){return t?"true":"false"},uppercase:function(t){return t?"TRUE":"FALSE"},camelcase:function(t){return t?"True":"False"}},defaultStyle:"lowercase"})});var HK=w((KZe,UK)=>{"use strict";var Phe=lc(),Dhe=li();function Rhe(t){return 48<=t&&t<=57||65<=t&&t<=70||97<=t&&t<=102}function Fhe(t){return 48<=t&&t<=55}function Nhe(t){return 48<=t&&t<=57}function Lhe(t){if(t===null)return!1;var e=t.length,r=0,i=!1,n;if(!e)return!1;if(n=t[r],(n==="-"||n==="+")&&(n=t[++r]),n==="0"){if(r+1===e)return!0;if(n=t[++r],n==="b"){for(r++;r<e;r++)if(n=t[r],n!=="_"){if(n!=="0"&&n!=="1")return!1;i=!0}return i&&n!=="_"}if(n==="x"){for(r++;r<e;r++)if(n=t[r],n!=="_"){if(!Rhe(t.charCodeAt(r)))return!1;i=!0}return i&&n!=="_"}for(;r<e;r++)if(n=t[r],n!=="_"){if(!Fhe(t.charCodeAt(r)))return!1;i=!0}return i&&n!=="_"}if(n==="_")return!1;for(;r<e;r++)if(n=t[r],n!=="_"){if(n===":")break;if(!Nhe(t.charCodeAt(r)))return!1;i=!0}return!i||n==="_"?!1:n!==":"?!0:/^(:[0-5]?[0-9])+$/.test(t.slice(r)) Line truncated
\r`;function epe(t){if(t===null)return!1;var e,r,i=0,n=t.length,s=zQ;for(r=0;r<n;r++)if(e=s.indexOf(t.charAt(r)),!(e>64)){if(e<0)return!1;i+=6}return i%8==0}function tpe(t){var e,r,i=t.replace(/[\r\n=]/g,""),n=i.length,s=zQ,o=0,a=[];for(e=0;e<n;e++)e%4==0&&e&&(a.push(o>>16&255),a.push(o>>8&255),a.push(o&255)),o=o<<6|s.indexOf(i.charAt(e));return r=n%4*6,r===0?(a.push(o>>16&255),a.push(o>>8&255),a.push(o&255)):r===18?(a.push(o>>10&255),a.push(o>>2&255)):r===12&&a.push(o>>4&255),uc?uc.from?uc.from(a):new uc(a):a}function rpe(t){var e="",r=0,i,n,s=t.length,o=zQ;for(i=0;i<s;i++)i%3==0&&i&&(e+=o[r>>18&63],e+=o[r>>12&63],e+=o[r>>6&63],e+=o[r&63]),r=(r<<8)+t[i];return n=s%3,n===0?(e+=o[r>>18&63],e+=o[r>>12&63],e+=o[r>>6&63],e+=o[r&63]):n===2?(e+=o[r>>10&63],e+=o[r>>4&63],e+=o[r<<2&63],e+=o[64]):n===1&&(e+=o[r>>2&63],e+=o[r<<4&63],e+=o[64],e+=o[64]),e}function ipe(t){return uc&&uc.isBuffer(t)}$K.exports=new $he("tag:yaml.org,2002:binary",{kind:"scalar",resolve:epe,construct:tpe,predicate:ipe,represent:rpe})});var i1=w((JZe,r1)=>{"use strict";var npe=li(),spe=Object.prototype.hasOwnProperty,ope=Object.prototype.toString;function ape(t){if(t===null)return!0;var e=[],r,i,n,s,o,a=t;for(r=0,i=a.length;r<i;r+=1){if(n=a[r],o=!1,ope.call(n)!=="[object Object]")return!1;for(s in n)if(spe.call(n,s))if(!o)o=!0;else return!1;if(!o)return!1;if(e.indexOf(s)===-1)e.push(s);else return!1}return!0}function Ape(t){return t!==null?t:[]}r1.exports=new npe("tag:yaml.org,2002:omap",{kind:"sequence",resolve:ape,construct:Ape})});var s1=w((WZe,n1)=>{"use strict";var lpe=li(),cpe=Object.prototype.toString;function upe(t){if(t===null)return!0;var e,r,i,n,s,o=t;for(s=new Array(o.length),e=0,r=o.length;e<r;e+=1){if(i=o[e],cpe.call(i)!=="[object Object]"||(n=Object.keys(i),n.length!==1))return!1;s[e]=[n[0],i[n[0]]]}return!0}function gpe(t){if(t===null)return[];var e,r,i,n,s,o=t;for(s=new Array(o.length),e=0,r=o.length;e<r;e+=1)i=o[e],n=Object.keys(i),s[e]=[n[0],i[n[0]]];return s}n1.exports=new lpe("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:upe,construct:gpe})});var a1=w((zZe,o1)=>{"use strict";var fpe=li(),hpe=Object.prototype.hasOwnProperty;function ppe(t){if(t===null)return!0;var e,r=t;for(e in r)if(hpe.call(r,e)&&r[e]!==null)return!1;return!0}function dpe(t){return t!==null?t:{}}o1.exports=new fpe("tag:yaml.org,2002:set",{kind:"mapping",resolve:ppe,construct:dpe})});var eg=w((_Ze,A1)=>{"use strict";var Cpe=cc();A1.exports=new Cpe({include:[WQ()],implicit:[VK(),ZK()],explicit:[t1(),i1(),s1(),a1()]})});var c1=w((VZe,l1)=>{"use strict";var mpe=li();function Epe(){return!0}function Ipe(){}function ype(){return""}function wpe(t){return typeof t=="undefined"}l1.exports=new mpe("tag:yaml.org,2002:js/undefined",{kind:"scalar",resolve:Epe,construct:Ipe,predicate:wpe,represent:ype})});var g1=w((XZe,u1)=>{"use strict";var Bpe=li();function bpe(t){if(t===null||t.length===0)return!1;var e=t,r=/\/([gim]*)$/.exec(t),i="";return!(e[0]==="/"&&(r&&(i=r[1]),i.length>3||e[e.length-i.length-1]!=="/"))}function Qpe(t){var e=t,r=/\/([gim]*)$/.exec(t),i="";return e[0]==="/"&&(r&&(i=r[1]),e=e.slice(1,e.length-i.length-1)),new RegExp(e,i)}function vpe(t){var e="/"+t.source+"/";return t.global&&(e+="g"),t.multiline&&(e+="m"),t.ignoreCase&&(e+="i"),e}function Spe(t){return Object.prototype.toString.call(t)==="[object RegExp]"}u1.exports=new Bpe("tag:yaml.org,2002:js/regexp",{kind:"scalar",resolve:bpe,construct:Qpe,predicate:Spe,represent:vpe})});var p1=w((ZZe,f1)=>{"use strict";var aI;try{h1=require,aI=h1("esprima")}catch(t){typeof window!="undefined"&&(aI=window.esprima)}var h1,kpe=li();function xpe(t){if(t===null)return!1;try{var e="("+t+")",r=aI.parse(e,{range:!0});return!(r.type!=="Program"||r.body.length!==1||r.body[0].type!=="ExpressionStatement"||r.body[0].expression.type!=="ArrowFunctionExpression"&&r.body[0].expression.type!=="FunctionExpression")}catch(i){return!1}}function Ppe(t){var e="("+t+")",r=aI.parse(e,{range:!0}),i=[],n;if(r.type!=="Program"||r.body.length!==1||r.body[0].type!=="ExpressionStatement"||r.body[0].expression.type!=="ArrowFunctionExpression"&&r.body[0].expression.type!=="FunctionExpression")throw new Error("Failed to resolve function");return r.body[0].expression.params.forEach(function(s){i.push(s.name)}),n=r.body[0].expression.body.range,r.body[0].expression.body.type==="BlockStatement"?new Function(i,e.slice(n[0]+1,n[1]-1)):new Function(i,"return "+e.slice(n[0],n[1]))}function Dpe(t){return t.toString()}function Rpe(t){return Object.prototype.toString.call(t)==="[object Function]"}f1.exports=new kpe("tag:yaml.org,2002:js/function",{kind:"scalar",resolve:xpe,construct:Ppe,predicate:Rpe,represent:Dpe})});var rp=w(($Ze,d1)=>{"use strict";var C1=cc();d1.exports=C1.DEFAULT=new C1({include:[eg()],explicit:[c1(),g1(),p1()]})});var T1=w((e$e,ip)=>{"use strict";var Na=lc(),m1=Zu(),Fpe=bK(),E1=eg(),Npe=rp(),GA=Object.prototype.hasOwnProperty,AI=1,I1=2,y1=3,lI=4,_Q=1,Lpe=2,w1=3,Tpe=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFF Line truncated
`:t===118?"\v":t===102?"\f":t===114?"\r":t===101?"":t===32?" ":t===34?'"':t===47?"/":t===92?"\\":t===78?"\x85":t===95?"\xA0":t===76?"\u2028":t===80?"\u2029":""}function Gpe(t){return t<=65535?String.fromCharCode(t):String.fromCharCode((t-65536>>10)+55296,(t-65536&1023)+56320)}var S1=new Array(256),k1=new Array(256);for(var rg=0;rg<256;rg++)S1[rg]=v1(rg)?1:0,k1[rg]=v1(rg);function jpe(t,e){this.input=t,this.filename=e.filename||null,this.schema=e.schema||Npe,this.onWarning=e.onWarning||null,this.legacy=e.legacy||!1,this.json=e.json||!1,this.listener=e.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=t.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.documents=[]}function x1(t,e){return new m1(e,new Fpe(t.filename,t.input,t.position,t.line,t.position-t.lineStart))}function dt(t,e){throw x1(t,e)}function cI(t,e){t.onWarning&&t.onWarning.call(null,x1(t,e))}var P1={YAML:function(e,r,i){var n,s,o;e.version!==null&&dt(e,"duplication of %YAML directive"),i.length!==1&&dt(e,"YAML directive accepts exactly one argument"),n=/^([0-9]+)\.([0-9]+)$/.exec(i[0]),n===null&&dt(e,"ill-formed argument of the YAML directive"),s=parseInt(n[1],10),o=parseInt(n[2],10),s!==1&&dt(e,"unacceptable YAML version of the document"),e.version=i[0],e.checkLineBreaks=o<2,o!==1&&o!==2&&cI(e,"unsupported YAML version of the document")},TAG:function(e,r,i){var n,s;i.length!==2&&dt(e,"TAG directive accepts exactly two arguments"),n=i[0],s=i[1],B1.test(n)||dt(e,"ill-formed tag handle (first argument) of the TAG directive"),GA.call(e.tagMap,n)&&dt(e,'there is a previously declared suffix for "'+n+'" tag handle'),b1.test(s)||dt(e,"ill-formed tag prefix (second argument) of the TAG directive"),e.tagMap[n]=s}};function jA(t,e,r,i){var n,s,o,a;if(e<r){if(a=t.input.slice(e,r),i)for(n=0,s=a.length;n<s;n+=1)o=a.charCodeAt(n),o===9||32<=o&&o<=1114111||dt(t,"expected valid JSON character");else Tpe.test(a)&&dt(t,"the stream contains non-printable characters");t.result+=a}}function D1(t,e,r,i){var n,s,o,a;for(Na.isObject(r)||dt(t,"cannot merge mappings; the provided source object is unacceptable"),n=Object.keys(r),o=0,a=n.length;o<a;o+=1)s=n[o],GA.call(e,s)||(e[s]=r[s],i[s]=!0)}function ig(t,e,r,i,n,s,o,a){var l,c;if(Array.isArray(n))for(n=Array.prototype.slice.call(n),l=0,c=n.length;l<c;l+=1)Array.isArray(n[l])&&dt(t,"nested arrays are not supported inside keys"),typeof n=="object"&&Q1(n[l])==="[object Object]"&&(n[l]="[object Object]");if(typeof n=="object"&&Q1(n)==="[object Object]"&&(n="[object Object]"),n=String(n),e===null&&(e={}),i==="tag:yaml.org,2002:merge")if(Array.isArray(s))for(l=0,c=s.length;l<c;l+=1)D1(t,e,s[l],r);else D1(t,e,s,r);else!t.json&&!GA.call(r,n)&&GA.call(e,n)&&(t.line=o||t.line,t.position=a||t.position,dt(t,"duplicated mapping key")),e[n]=s,delete r[n];return e}function VQ(t){var e;e=t.input.charCodeAt(t.position),e===10?t.position++:e===13?(t.position++,t.input.charCodeAt(t.position)===10&&t.position++):dt(t,"a line break is expected"),t.line+=1,t.lineStart=t.position}function ei(t,e,r){for(var i=0,n=t.input.charCodeAt(t.position);n!==0;){for(;gc(n);)n=t.input.charCodeAt(++t.position);if(e&&n===35)do n=t.input.charCodeAt(++t.position);while(n!==10&&n!==13&&n!==0);if(Ro(n))for(VQ(t),n=t.input.charCodeAt(t.position),i++,t.lineIndent=0;n===32;)t.lineIndent++,n=t.input.charCodeAt(++t.position);else break}return r!==-1&&i!==0&&t.lineIndent<r&&cI(t,"deficient indentation"),i}function uI(t){var e=t.position,r;return r=t.input.charCodeAt(e),!!((r===45||r===46)&&r===t.input.charCodeAt(e+1)&&r===t.input.charCodeAt(e+2)&&(e+=3,r=t.input.charCodeAt(e),r===0||yn(r)))}function XQ(t,e){e===1?t.result+=" ":e>1&&(t.result+=Na.repeat(`
`,e-1))}function Ype(t,e,r){var i,n,s,o,a,l,c,u,g=t.kind,f=t.result,h;if(h=t.input.charCodeAt(t.position),yn(h)||tg(h)||h===35||h===38||h===42||h===33||h===124||h===62||h===39||h===34||h===37||h===64||h===96||(h===63||h===45)&&(n=t.input.charCodeAt(t.position+1),yn(n)||r&&tg(n)))return!1;for(t.kind="scalar",t.result="",s=o=t.position,a=!1;h!==0;){if(h===58){if(n=t.input.charCodeAt(t.position+1),yn(n)||r&&tg(n))break}else if(h===35){if(i=t.input.charCodeAt(t.position-1),yn(i))break}else{if(t.position===t.lineStart&&uI(t)||r&&tg(h))break;if(Ro(h))if(l=t.line,c=t.lineStart,u=t.lineIndent,ei(t,!1,-1),t.lineIndent>=e){a=!0,h=t.input.charCodeAt(t.position);continue}else{t.position=o,t.line=l,t.lineStart=c,t.lineIndent=u;break}}a&&(jA(t,s,o,!1),XQ(t,t.line-l),s=o=t.position,a=!1),gc(h)||(o=t.position+1),h=t.input.charCodeAt(++t.position)}return jA(t,s,o,!1),t.result?!0:(t.kind=g,t.result=f,!1)}function qpe(t,e){var r,i,n;if(r=t.input.charCodeAt(t.position),r!==39)return!1;for(t.kind="scalar",t.result="",t.position++,i=n=t.position;(r=t.input.charCodeAt(t.position))!==0;)if(r===39)if(jA(t,i,t.position,!0),r=t.input.charCodeAt(++t.position),r===39)i=t.position,t.position++,n=t.position;else return!0;else Ro(r)?(jA(t,i,n,!0),XQ(t,ei(t,!1,e)),i=n=t.position):t.position===t.lineStart&&uI(t)?dt(t,"unexpected end of the document within a single quoted scalar"):(t.position++,n=t.position);dt(t,"unexpected end of the stream within a single quoted scalar")}function Jpe(t,e){var r,i,n,s,o,a;if(a=t.input.charCodeAt(t.position),a!==34)return!1;for(t.kind="scalar",t.result="",t.position++,r=i=t.position;(a=t.input.charCodeAt(t.position))!==0;){if(a===34)return jA(t,r,t.position,!0),t.position++,!0;if(a===92){if(jA(t,r,t.position,!0),a=t.input.charCodeAt(++t.position),Ro(a))ei(t,!1,e);else if(a<256&&S1[a])t.result+=k1[a],t.position++;else if((o=Upe(a))>0){for(n=o,s=0;n>0;n--)a=t.input.charCodeAt(++t.position),(o=Kpe(a))>=0?s=(s<<4)+o:dt(t,"expected hexadecimal character");t.result+=Gpe(s),t.position++}else dt(t,"unknown escape sequence");r=i=t.position}else Ro(a)?(jA(t,r,i,!0),XQ(t,ei(t,!1,e)),r=i=t.position):t.position===t.lineStart&&uI(t)?dt(t,"unexpected end of the document within a double quoted scalar"):(t.position++,i=t.position)}dt(t,"unexpected end of the stream within a double quoted scalar")}function Wpe(t,e){var r=!0,i,n=t.tag,s,o=t.anchor,a,l,c,u,g,f={},h,p,m,y;if(y=t.input.charCodeAt(t.position),y===91)l=93,g=!1,s=[];else if(y===123)l=125,g=!0,s={};else return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=s),y=t.input.charCodeAt(++t.position);y!==0;){if(ei(t,!0,e),y=t.input.charCodeAt(t.position),y===l)return t.position++,t.tag=n,t.anchor=o,t.kind=g?"mapping":"sequence",t.result=s,!0;r||dt(t,"missed comma between flow collection entries"),p=h=m=null,c=u=!1,y===63&&(a=t.input.charCodeAt(t.position+1),yn(a)&&(c=u=!0,t.position++,ei(t,!0,e))),i=t.line,ng(t,e,AI,!1,!0),p=t.tag,h=t.result,ei(t,!0,e),y=t.input.charCodeAt(t.position),(u||t.line===i)&&y===58&&(c=!0,y=t.input.charCodeAt(++t.position),ei(t,!0,e),ng(t,e,AI,!1,!0),m=t.result),g?ig(t,s,f,p,h,m):c?s.push(ig(t,null,f,p,h,m)):s.push(h),ei(t,!0,e),y=t.input.charCodeAt(t.position),y===44?(r=!0,y=t.input.charCodeAt(++t.position)):r=!1}dt(t,"unexpected end of the stream within a flow collection")}function zpe(t,e){var r,i,n=_Q,s=!1,o=!1,a=e,l=0,c=!1,u,g;if(g=t.input.charCodeAt(t.position),g===124)i=!1;else if(g===62)i=!0;else return!1;for(t.kind="scalar",t.result="";g!==0;)if(g=t.input.charCodeAt(++t.position),g===43||g===45)_Q===n?n=g===43?w1:Lpe:dt(t,"repeat of a chomping mode identifier");else if((u=Hpe(g))>=0)u===0?dt(t,"bad explicit indentation width of a block scalar; it cannot be less than one"):o?dt(t,"repeat of an indentation width identifier"):(a=e+u-1,o=!0);else break;if(gc(g)){do g=t.input.charCodeAt(++t.position);while(gc(g));if(g===35)do g=t.input.charCodeAt(++t.position);while(!Ro(g)&&g!==0)}for(;g!==0;){for(VQ(t),t.lineIndent=0,g=t.input.charCodeAt(t.position);(!o||t.lineIndent<a)&&g===32;)t.lineIndent++,g=t.input.charCodeAt(++t.position);if(!o&&t.lineIndent>a&&(a=t.lineIndent),Ro(g)){l++;continue}if(t.lineIndent<a){n===w1?t.result+=Na.repeat(`
`,s?1+l:l):n===_Q&&s&&(t.result+=`
`);break}for(i?gc(g)?(c=!0,t.result+=Na.repeat(`
`,s?1+l:l)):c?(c=!1,t.result+=Na.repeat(`
`,l+1)):l===0?s&&(t.result+=" "):t.result+=Na.repeat(`
`,l):t.result+=Na.repeat(`
`,s?1+l:l),s=!0,o=!0,l=0,r=t.position;!Ro(g)&&g!==0;)g=t.input.charCodeAt(++t.position);jA(t,r,t.position,!1)}return!0}function R1(t,e){var r,i=t.tag,n=t.anchor,s=[],o,a=!1,l;for(t.anchor!==null&&(t.anchorMap[t.anchor]=s),l=t.input.charCodeAt(t.position);l!==0&&!(l!==45||(o=t.input.charCodeAt(t.position+1),!yn(o)));){if(a=!0,t.position++,ei(t,!0,-1)&&t.lineIndent<=e){s.push(null),l=t.input.charCodeAt(t.position);continue}if(r=t.line,ng(t,e,y1,!1,!0),s.push(t.result),ei(t,!0,-1),l=t.input.charCodeAt(t.position),(t.line===r||t.lineIndent>e)&&l!==0)dt(t,"bad indentation of a sequence entry");else if(t.lineIndent<e)break}return a?(t.tag=i,t.anchor=n,t.kind="sequence",t.result=s,!0):!1}function _pe(t,e,r){var i,n,s,o,a=t.tag,l=t.anchor,c={},u={},g=null,f=null,h=null,p=!1,m=!1,y;for(t.anchor!==null&&(t.anchorMap[t.anchor]=c),y=t.input.charCodeAt(t.position);y!==0;){if(i=t.input.charCodeAt(t.position+1),s=t.line,o=t.position,(y===63||y===58)&&yn(i))y===63?(p&&(ig(t,c,u,g,f,null),g=f=h=null),m=!0,p=!0,n=!0):p?(p=!1,n=!0):dt(t,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),t.position+=1,y=i;else if(ng(t,r,I1,!1,!0))if(t.line===s){for(y=t.input.charCodeAt(t.position);gc(y);)y=t.input.charCodeAt(++t.position);if(y===58)y=t.input.charCodeAt(++t.position),yn(y)||dt(t,"a whitespace character is expected after the key-value separator within a block mapping"),p&&(ig(t,c,u,g,f,null),g=f=h=null),m=!0,p=!1,n=!1,g=t.tag,f=t.result;else if(m)dt(t,"can not read an implicit mapping pair; a colon is missed");else return t.tag=a,t.anchor=l,!0}else if(m)dt(t,"can not read a block mapping entry; a multiline key may not be an implicit key");else return t.tag=a,t.anchor=l,!0;else break;if((t.line===s||t.lineIndent>e)&&(ng(t,e,lI,!0,n)&&(p?f=t.result:h=t.result),p||(ig(t,c,u,g,f,h,s,o),g=f=h=null),ei(t,!0,-1),y=t.input.charCodeAt(t.position)),t.lineIndent>e&&y!==0)dt(t,"bad indentation of a mapping entry");else if(t.lineIndent<e)break}return p&&ig(t,c,u,g,f,null),m&&(t.tag=a,t.anchor=l,t.kind="mapping",t.result=c),m}function Vpe(t){var e,r=!1,i=!1,n,s,o;if(o=t.input.charCodeAt(t.position),o!==33)return!1;if(t.tag!==null&&dt(t,"duplication of a tag property"),o=t.input.charCodeAt(++t.position),o===60?(r=!0,o=t.input.charCodeAt(++t.position)):o===33?(i=!0,n="!!",o=t.input.charCodeAt(++t.position)):n="!",e=t.position,r){do o=t.input.charCodeAt(++t.position);while(o!==0&&o!==62);t.position<t.length?(s=t.input.slice(e,t.position),o=t.input.charCodeAt(++t.position)):dt(t,"unexpected end of the stream within a verbatim tag")}else{for(;o!==0&&!yn(o);)o===33&&(i?dt(t,"tag suffix cannot contain exclamation marks"):(n=t.input.slice(e-1,t.position+1),B1.test(n)||dt(t,"named tag handle cannot contain such characters"),i=!0,e=t.position+1)),o=t.input.charCodeAt(++t.position);s=t.input.slice(e,t.position),Mpe.test(s)&&dt(t,"tag suffix cannot contain flow indicator characters")}return s&&!b1.test(s)&&dt(t,"tag name cannot contain such characters: "+s),r?t.tag=s:GA.call(t.tagMap,n)?t.tag=t.tagMap[n]+s:n==="!"?t.tag="!"+s:n==="!!"?t.tag="tag:yaml.org,2002:"+s:dt(t,'undeclared tag handle "'+n+'"'),!0}function Xpe(t){var e,r;if(r=t.input.charCodeAt(t.position),r!==38)return!1;for(t.anchor!==null&&dt(t,"duplication of an anchor property"),r=t.input.charCodeAt(++t.position),e=t.position;r!==0&&!yn(r)&&!tg(r);)r=t.input.charCodeAt(++t.position);return t.position===e&&dt(t,"name of an anchor node must contain at least one character"),t.anchor=t.input.slice(e,t.position),!0}function Zpe(t){var e,r,i;if(i=t.input.charCodeAt(t.position),i!==42)return!1;for(i=t.input.charCodeAt(++t.position),e=t.position;i!==0&&!yn(i)&&!tg(i);)i=t.input.charCodeAt(++t.position);return t.position===e&&dt(t,"name of an alias node must contain at least one character"),r=t.input.slice(e,t.position),GA.call(t.anchorMap,r)||dt(t,'unidentified alias "'+r+'"'),t.result=t.anchorMap[r],ei(t,!0,-1),!0}function ng(t,e,r,i,n){var s,o,a,l=1,c=!1,u=!1,g,f,h,p,m;if(t.listener!==null&&t.listener("open",t),t.tag=null,t.anchor=null,t.kind=null,t.result=null,s=o=a=lI===r||y1===r,i&&ei(t,!0,-1)&&(c=!0,t.lineIndent>e?l=1:t.lineIndent===e?l=0:t.lineIndent<e&&(l=-1)),l===1)for(;Vpe(t)||Xpe(t);)ei(t,!0,-1)?(c=!0,a=s,t.lineIndent>e?l=1:t.lineIndent===e?l=0:t.lineIndent<e&&(l=-1)):a=!1;if(a&&(a=c||n),(l===1||lI===r)&&(AI===r||I1===r?p=e:p=e+1,m=t.position-t.lineStart,l===1?a&&(R1(t,m)||_pe(t,m,p))||Wpe(t,p)?u=!0:(o&&zpe(t,p)||qpe(t,p)||Jpe(t,p)?u=!0:Zpe(t)?(u=!0,(t.tag!==null||t.anchor!==null)&&dt(t,"alias node should not have any properties")):Ype(t,p,AI===r)&&(u=!0,t.tag===null&&(t.tag="?")),t.anchor!==null&&(t.anchorMap[t.anchor]=t.result)):l===0&&(u=a&&R1(t,m))),t.tag!==null&&t.tag!=="!")if(t.tag==="?"){for(t.result!==null&&t.kind!=="scalar"&&dt(t,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+t.kind+'"'),g=0,f=t.implicitTypes.length;g<f;g+=1)if(h=t.implicitTypes[g],h.resolve(t.result)){t.result=h.construct(t.result),t.tag=h.tag Line truncated
`),t.charCodeAt(0)===65279&&(t=t.slice(1)));var r=new jpe(t,e),i=t.indexOf("\0");for(i!==-1&&(r.position=i,dt(r,"null byte is not allowed in input")),r.input+="\0";r.input.charCodeAt(r.position)===32;)r.lineIndent+=1,r.position+=1;for(;r.position<r.length-1;)$pe(r);return r.documents}function N1(t,e,r){e!==null&&typeof e=="object"&&typeof r=="undefined"&&(r=e,e=null);var i=F1(t,r);if(typeof e!="function")return i;for(var n=0,s=i.length;n<s;n+=1)e(i[n])}function L1(t,e){var r=F1(t,e);if(r.length!==0){if(r.length===1)return r[0];throw new m1("expected a single document in the stream, but found more")}}function ede(t,e,r){return typeof e=="object"&&e!==null&&typeof r=="undefined"&&(r=e,e=null),N1(t,e,Na.extend({schema:E1},r))}function tde(t,e){return L1(t,Na.extend({schema:E1},e))}ip.exports.loadAll=N1;ip.exports.load=L1;ip.exports.safeLoadAll=ede;ip.exports.safeLoad=tde});var sU=w((t$e,ZQ)=>{"use strict";var np=lc(),sp=Zu(),rde=rp(),ide=eg(),O1=Object.prototype.toString,M1=Object.prototype.hasOwnProperty,nde=9,op=10,sde=13,ode=32,ade=33,Ade=34,K1=35,lde=37,cde=38,ude=39,gde=42,U1=44,fde=45,H1=58,hde=61,pde=62,dde=63,Cde=64,G1=91,j1=93,mde=96,Y1=123,Ede=124,q1=125,Ki={};Ki[0]="\\0";Ki[7]="\\a";Ki[8]="\\b";Ki[9]="\\t";Ki[10]="\\n";Ki[11]="\\v";Ki[12]="\\f";Ki[13]="\\r";Ki[27]="\\e";Ki[34]='\\"';Ki[92]="\\\\";Ki[133]="\\N";Ki[160]="\\_";Ki[8232]="\\L";Ki[8233]="\\P";var Ide=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"];function yde(t,e){var r,i,n,s,o,a,l;if(e===null)return{};for(r={},i=Object.keys(e),n=0,s=i.length;n<s;n+=1)o=i[n],a=String(e[o]),o.slice(0,2)==="!!"&&(o="tag:yaml.org,2002:"+o.slice(2)),l=t.compiledTypeMap.fallback[o],l&&M1.call(l.styleAliases,a)&&(a=l.styleAliases[a]),r[o]=a;return r}function J1(t){var e,r,i;if(e=t.toString(16).toUpperCase(),t<=255)r="x",i=2;else if(t<=65535)r="u",i=4;else if(t<=4294967295)r="U",i=8;else throw new sp("code point within a string may not be greater than 0xFFFFFFFF");return"\\"+r+np.repeat("0",i-e.length)+e}function wde(t){this.schema=t.schema||rde,this.indent=Math.max(1,t.indent||2),this.noArrayIndent=t.noArrayIndent||!1,this.skipInvalid=t.skipInvalid||!1,this.flowLevel=np.isNothing(t.flowLevel)?-1:t.flowLevel,this.styleMap=yde(this.schema,t.styles||null),this.sortKeys=t.sortKeys||!1,this.lineWidth=t.lineWidth||80,this.noRefs=t.noRefs||!1,this.noCompatMode=t.noCompatMode||!1,this.condenseFlow=t.condenseFlow||!1,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}function W1(t,e){for(var r=np.repeat(" ",e),i=0,n=-1,s="",o,a=t.length;i<a;)n=t.indexOf(`
`,i),n===-1?(o=t.slice(i),i=a):(o=t.slice(i,n+1),i=n+1),o.length&&o!==`
`&&(s+=r),s+=o;return s}function $Q(t,e){return`
`+np.repeat(" ",t.indent*e)}function Bde(t,e){var r,i,n;for(r=0,i=t.implicitTypes.length;r<i;r+=1)if(n=t.implicitTypes[r],n.resolve(e))return!0;return!1}function ev(t){return t===ode||t===nde}function sg(t){return 32<=t&&t<=126||161<=t&&t<=55295&&t!==8232&&t!==8233||57344<=t&&t<=65533&&t!==65279||65536<=t&&t<=1114111}function bde(t){return sg(t)&&!ev(t)&&t!==65279&&t!==sde&&t!==op}function z1(t,e){return sg(t)&&t!==65279&&t!==U1&&t!==G1&&t!==j1&&t!==Y1&&t!==q1&&t!==H1&&(t!==K1||e&&bde(e))}function Qde(t){return sg(t)&&t!==65279&&!ev(t)&&t!==fde&&t!==dde&&t!==H1&&t!==U1&&t!==G1&&t!==j1&&t!==Y1&&t!==q1&&t!==K1&&t!==cde&&t!==gde&&t!==ade&&t!==Ede&&t!==hde&&t!==pde&&t!==ude&&t!==Ade&&t!==lde&&t!==Cde&&t!==mde}function _1(t){var e=/^\n* /;return e.test(t)}var V1=1,X1=2,Z1=3,$1=4,gI=5;function vde(t,e,r,i,n){var s,o,a,l=!1,c=!1,u=i!==-1,g=-1,f=Qde(t.charCodeAt(0))&&!ev(t.charCodeAt(t.length-1));if(e)for(s=0;s<t.length;s++){if(o=t.charCodeAt(s),!sg(o))return gI;a=s>0?t.charCodeAt(s-1):null,f=f&&z1(o,a)}else{for(s=0;s<t.length;s++){if(o=t.charCodeAt(s),o===op)l=!0,u&&(c=c||s-g-1>i&&t[g+1]!==" ",g=s);else if(!sg(o))return gI;a=s>0?t.charCodeAt(s-1):null,f=f&&z1(o,a)}c=c||u&&s-g-1>i&&t[g+1]!==" "}return!l&&!c?f&&!n(t)?V1:X1:r>9&&_1(t)?gI:c?$1:Z1}function xde(t,e,r,i){t.dump=function(){if(e.length===0)return"''";if(!t.noCompatMode&&Ide.indexOf(e)!==-1)return"'"+e+"'";var n=t.indent*Math.max(1,r),s=t.lineWidth===-1?-1:Math.max(Math.min(t.lineWidth,40),t.lineWidth-n),o=i||t.flowLevel>-1&&r>=t.flowLevel;function a(l){return Bde(t,l)}switch(vde(e,o,t.indent,s,a)){case V1:return e;case X1:return"'"+e.replace(/'/g,"''")+"'";case Z1:return"|"+eU(e,t.indent)+tU(W1(e,n));case $1:return">"+eU(e,t.indent)+tU(W1(Sde(e,s),n));case gI:return'"'+kde(e,s)+'"';default:throw new sp("impossible error: invalid scalar style")}}()}function eU(t,e){var r=_1(t)?String(e):"",i=t[t.length-1]===`
`,n=i&&(t[t.length-2]===`
`||t===`
`),s=n?"+":i?"":"-";return r+s+`
`}function tU(t){return t[t.length-1]===`
`?t.slice(0,-1):t}function Sde(t,e){for(var r=/(\n+)([^\n]*)/g,i=function(){var c=t.indexOf(`
`);return c=c!==-1?c:t.length,r.lastIndex=c,rU(t.slice(0,c),e)}(),n=t[0]===`
`||t[0]===" ",s,o;o=r.exec(t);){var a=o[1],l=o[2];s=l[0]===" ",i+=a+(!n&&!s&&l!==""?`
`:"")+rU(l,e),n=s}return i}function rU(t,e){if(t===""||t[0]===" ")return t;for(var r=/ [^ ]/g,i,n=0,s,o=0,a=0,l="";i=r.exec(t);)a=i.index,a-n>e&&(s=o>n?o:a,l+=`
`+t.slice(n,s),n=s+1),o=a;return l+=`
`,t.length-n>e&&o>n?l+=t.slice(n,o)+`
`+t.slice(o+1):l+=t.slice(n),l.slice(1)}function kde(t){for(var e="",r,i,n,s=0;s<t.length;s++){if(r=t.charCodeAt(s),r>=55296&&r<=56319&&(i=t.charCodeAt(s+1),i>=56320&&i<=57343)){e+=J1((r-55296)*1024+i-56320+65536),s++;continue}n=Ki[r],e+=!n&&sg(r)?t[s]:n||J1(r)}return e}function Pde(t,e,r){var i="",n=t.tag,s,o;for(s=0,o=r.length;s<o;s+=1)fc(t,e,r[s],!1,!1)&&(s!==0&&(i+=","+(t.condenseFlow?"":" ")),i+=t.dump);t.tag=n,t.dump="["+i+"]"}function Dde(t,e,r,i){var n="",s=t.tag,o,a;for(o=0,a=r.length;o<a;o+=1)fc(t,e+1,r[o],!0,!0)&&((!i||o!==0)&&(n+=$Q(t,e)),t.dump&&op===t.dump.charCodeAt(0)?n+="-":n+="- ",n+=t.dump);t.tag=s,t.dump=n||"[]"}function Rde(t,e,r){var i="",n=t.tag,s=Object.keys(r),o,a,l,c,u;for(o=0,a=s.length;o<a;o+=1)u="",o!==0&&(u+=", "),t.condenseFlow&&(u+='"'),l=s[o],c=r[l],!!fc(t,e,l,!1,!1)&&(t.dump.length>1024&&(u+="? "),u+=t.dump+(t.condenseFlow?'"':"")+":"+(t.condenseFlow?"":" "),!!fc(t,e,c,!1,!1)&&(u+=t.dump,i+=u));t.tag=n,t.dump="{"+i+"}"}function Fde(t,e,r,i){var n="",s=t.tag,o=Object.keys(r),a,l,c,u,g,f;if(t.sortKeys===!0)o.sort();else if(typeof t.sortKeys=="function")o.sort(t.sortKeys);else if(t.sortKeys)throw new sp("sortKeys must be a boolean or a function");for(a=0,l=o.length;a<l;a+=1)f="",(!i||a!==0)&&(f+=$Q(t,e)),c=o[a],u=r[c],!!fc(t,e+1,c,!0,!0,!0)&&(g=t.tag!==null&&t.tag!=="?"||t.dump&&t.dump.length>1024,g&&(t.dump&&op===t.dump.charCodeAt(0)?f+="?":f+="? "),f+=t.dump,g&&(f+=$Q(t,e)),!!fc(t,e+1,u,!0,g)&&(t.dump&&op===t.dump.charCodeAt(0)?f+=":":f+=": ",f+=t.dump,n+=f));t.tag=s,t.dump=n||"{}"}function iU(t,e,r){var i,n,s,o,a,l;for(n=r?t.explicitTypes:t.implicitTypes,s=0,o=n.length;s<o;s+=1)if(a=n[s],(a.instanceOf||a.predicate)&&(!a.instanceOf||typeof e=="object"&&e instanceof a.instanceOf)&&(!a.predicate||a.predicate(e))){if(t.tag=r?a.tag:"?",a.represent){if(l=t.styleMap[a.tag]||a.defaultStyle,O1.call(a.represent)==="[object Function]")i=a.represent(e,l);else if(M1.call(a.represent,l))i=a.represent[l](e,l);else throw new sp("!<"+a.tag+'> tag resolver accepts not "'+l+'" style');t.dump=i}return!0}return!1}function fc(t,e,r,i,n,s){t.tag=null,t.dump=r,iU(t,r,!1)||iU(t,r,!0);var o=O1.call(t.dump);i&&(i=t.flowLevel<0||t.flowLevel>e);var a=o==="[object Object]"||o==="[object Array]",l,c;if(a&&(l=t.duplicates.indexOf(r),c=l!==-1),(t.tag!==null&&t.tag!=="?"||c||t.indent!==2&&e>0)&&(n=!1),c&&t.usedDuplicates[l])t.dump="*ref_"+l;else{if(a&&c&&!t.usedDuplicates[l]&&(t.usedDuplicates[l]=!0),o==="[object Object]")i&&Object.keys(t.dump).length!==0?(Fde(t,e,t.dump,n),c&&(t.dump="&ref_"+l+t.dump)):(Rde(t,e,t.dump),c&&(t.dump="&ref_"+l+" "+t.dump));else if(o==="[object Array]"){var u=t.noArrayIndent&&e>0?e-1:e;i&&t.dump.length!==0?(Dde(t,u,t.dump,n),c&&(t.dump="&ref_"+l+t.dump)):(Pde(t,u,t.dump),c&&(t.dump="&ref_"+l+" "+t.dump))}else if(o==="[object String]")t.tag!=="?"&&xde(t,t.dump,e,s);else{if(t.skipInvalid)return!1;throw new sp("unacceptable kind of an object to dump "+o)}t.tag!==null&&t.tag!=="?"&&(t.dump="!<"+t.tag+"> "+t.dump)}return!0}function Nde(t,e){var r=[],i=[],n,s;for(tv(t,r,i),n=0,s=i.length;n<s;n+=1)e.duplicates.push(r[i[n]]);e.usedDuplicates=new Array(s)}function tv(t,e,r){var i,n,s;if(t!==null&&typeof t=="object")if(n=e.indexOf(t),n!==-1)r.indexOf(n)===-1&&r.push(n);else if(e.push(t),Array.isArray(t))for(n=0,s=t.length;n<s;n+=1)tv(t[n],e,r);else for(i=Object.keys(t),n=0,s=i.length;n<s;n+=1)tv(t[i[n]],e,r)}function nU(t,e){e=e||{};var r=new wde(e);return r.noRefs||Nde(t,r),fc(r,0,t,!0,!0)?r.dump+`
`:""}function Lde(t,e){return nU(t,np.extend({schema:ide},e))}ZQ.exports.dump=nU;ZQ.exports.safeDump=Lde});var aU=w((r$e,Or)=>{"use strict";var fI=T1(),oU=sU();function hI(t){return function(){throw new Error("Function "+t+" is deprecated and cannot be used.")}}Or.exports.Type=li();Or.exports.Schema=cc();Or.exports.FAILSAFE_SCHEMA=oI();Or.exports.JSON_SCHEMA=JQ();Or.exports.CORE_SCHEMA=WQ();Or.exports.DEFAULT_SAFE_SCHEMA=eg();Or.exports.DEFAULT_FULL_SCHEMA=rp();Or.exports.load=fI.load;Or.exports.loadAll=fI.loadAll;Or.exports.safeLoad=fI.safeLoad;Or.exports.safeLoadAll=fI.safeLoadAll;Or.exports.dump=oU.dump;Or.exports.safeDump=oU.safeDump;Or.exports.YAMLException=Zu();Or.exports.MINIMAL_SCHEMA=oI();Or.exports.SAFE_SCHEMA=eg();Or.exports.DEFAULT_SCHEMA=rp();Or.exports.scan=hI("scan");Or.exports.parse=hI("parse");Or.exports.compose=hI("compose");Or.exports.addConstructor=hI("addConstructor")});var lU=w((i$e,AU)=>{"use strict";var Tde=aU();AU.exports=Tde});var uU=w((n$e,cU)=>{"use strict";function Ode(t,e){function r(){this.constructor=t}r.prototype=e.prototype,t.prototype=new r}function hc(t,e,r,i){this.message=t,this.expected=e,this.found=r,this.location=i,this.name="SyntaxError",typeof Error.captureStackTrace=="function"&&Error.captureStackTrace(this,hc)}Ode(hc,Error);hc.buildMessage=function(t,e){var r={literal:function(c){return'"'+n(c.text)+'"'},class:function(c){var u="",g;for(g=0;g<c.parts.length;g++)u+=c.parts[g]instanceof Array?s(c.parts[g][0])+"-"+s(c.parts[g][1]):s(c.parts[g]);return"["+(c.inverted?"^":"")+u+"]"},any:function(c){return"any character"},end:function(c){return"end of input"},other:function(c){return c.description}};function i(c){return c.charCodeAt(0).toString(16).toUpperCase()}function n(c){return c.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,function(u){return"\\x0"+i(u)}).replace(/[\x10-\x1F\x7F-\x9F]/g,function(u){return"\\x"+i(u)})}function s(c){return c.replace(/\\/g,"\\\\").replace(/\]/g,"\\]").replace(/\^/g,"\\^").replace(/-/g,"\\-").replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,function(u){return"\\x0"+i(u)}).replace(/[\x10-\x1F\x7F-\x9F]/g,function(u){return"\\x"+i(u)})}function o(c){return r[c.type](c)}function a(c){var u=new Array(c.length),g,f;for(g=0;g<c.length;g++)u[g]=o(c[g]);if(u.sort(),u.length>0){for(g=1,f=1;g<u.length;g++)u[g-1]!==u[g]&&(u[f]=u[g],f++);u.length=f}switch(u.length){case 1:return u[0];case 2:return u[0]+" or "+u[1];default:return u.slice(0,-1).join(", ")+", or "+u[u.length-1]}}function l(c){return c?'"'+n(c)+'"':"end of input"}return"Expected "+a(t)+" but "+l(e)+" found."};function Mde(t,e){e=e!==void 0?e:{};var r={},i={Start:Zs},n=Zs,s=function(R){return[].concat(...R)},o="-",a=gr("-",!1),l=function(R){return R},c=function(R){return Object.assign({},...R)},u="#",g=gr("#",!1),f=Wl(),h=function(){return{}},p=":",m=gr(":",!1),y=function(R,q){return{[R]:q}},b=",",S=gr(",",!1),k=function(R,q){return q},T=function(R,q,me){return Object.assign({},...[R].concat(q).map(Ge=>({[Ge]:me})))},Y=function(R){return R},j=function(R){return R},Z=Xs("correct indentation"),J=" ",re=gr(" ",!1),ee=function(R){return R.length===TA*Yu},A=function(R){return R.length===(TA+1)*Yu},oe=function(){return TA++,!0},le=function(){return TA--,!0},X=function(){return Mu()},O=Xs("pseudostring"),L=/^[^\r\n\t ?:,\][{}#&*!|>'"%@`\-]/,pe=qn(["\r",`
`," "," ","?",":",",","]","[","{","}","#","&","*","!","|",">","'",'"',"%","@","`","-"],!0,!1),Ce=/^[^\r\n\t ,\][{}:#"']/,Oe=qn(["\r",`
`," "," ",",","]","[","{","}",":","#",'"',"'"],!0,!1),te=function(){return Mu().replace(/^ *| *$/g,"")},se="--",be=gr("--",!1),he=/^[a-zA-Z\/0-9]/,Fe=qn([["a","z"],["A","Z"],"/",["0","9"]],!1,!1),Ue=/^[^\r\n\t :,]/,xe=qn(["\r",`
`," "," ",":",","],!0,!1),Se="null",de=gr("null",!1),V=function(){return null},Qe="true",ce=gr("true",!1),fe=function(){return!0},gt="false",Ht=gr("false",!1),Mt=function(){return!1},mi=Xs("string"),Gt='"',Qr=gr('"',!1),Ti=function(){return""},Vs=function(R){return R},Un=function(R){return R.join("")},Hn=/^[^"\\\0-\x1F\x7F]/,vr=qn(['"',"\\",["\0",""],"\x7F"],!0,!1),Gn='\\"',gs=gr('\\"',!1),ya=function(){return'"'},kA="\\\\",Ru=gr("\\\\",!1),fs=function(){return"\\"},xA="\\/",wa=gr("\\/",!1),Fu=function(){return"/"},PA="\\b",DA=gr("\\b",!1),Sr=function(){return"\b"},jl="\\f",Nu=gr("\\f",!1),So=function(){return"\f"},Lu="\\n",Sh=gr("\\n",!1),kh=function(){return`
`},ae="\\r",Oi=gr("\\r",!1),ko=function(){return"\r"},jn="\\t",Tu=gr("\\t",!1),vt=function(){return" "},Yl="\\u",Yn=gr("\\u",!1),hs=function(R,q,me,Ge){return String.fromCharCode(parseInt(`0x${R}${q}${me}${Ge}`))},ps=/^[0-9a-fA-F]/,pt=qn([["0","9"],["a","f"],["A","F"]],!1,!1),xo=Xs("blank space"),lt=/^[ \t]/,mn=qn([" "," "],!1,!1),v=Xs("white space"),Tt=/^[ \t\n\r]/,Ou=qn([" "," ",`
`,"\r"],!1,!1),ql=`\r
`,xh=gr(`\r
`,!1),Ph=`
`,Dh=gr(`
`,!1),Rh="\r",Fh=gr("\r",!1),G=0,yt=0,RA=[{line:1,column:1}],$i=0,Jl=[],$e=0,Ba;if("startRule"in e){if(!(e.startRule in i))throw new Error(`Can't start parsing from rule "`+e.startRule+'".');n=i[e.startRule]}function Mu(){return t.substring(yt,G)}function kE(){return En(yt,G)}function Nh(R,q){throw q=q!==void 0?q:En(yt,G),zl([Xs(R)],t.substring(yt,G),q)}function xE(R,q){throw q=q!==void 0?q:En(yt,G),Ku(R,q)}function gr(R,q){return{type:"literal",text:R,ignoreCase:q}}function qn(R,q,me){return{type:"class",parts:R,inverted:q,ignoreCase:me}}function Wl(){return{type:"any"}}function Lh(){return{type:"end"}}function Xs(R){return{type:"other",description:R}}function ba(R){var q=RA[R],me;if(q)return q;for(me=R-1;!RA[me];)me--;for(q=RA[me],q={line:q.line,column:q.column};me<R;)t.charCodeAt(me)===10?(q.line++,q.column=1):q.column++,me++;return RA[R]=q,q}function En(R,q){var me=ba(R),Ge=ba(q);return{start:{offset:R,line:me.line,column:me.column},end:{offset:q,line:Ge.line,column:Ge.column}}}function Me(R){G<$i||(G>$i&&($i=G,Jl=[]),Jl.push(R))}function Ku(R,q){return new hc(R,null,null,q)}function zl(R,q,me){return new hc(hc.buildMessage(R,q),R,q,me)}function Zs(){var R;return R=Uu(),R}function _l(){var R,q,me;for(R=G,q=[],me=FA();me!==r;)q.push(me),me=FA();return q!==r&&(yt=R,q=s(q)),R=q,R}function FA(){var R,q,me,Ge,Te;return R=G,q=va(),q!==r?(t.charCodeAt(G)===45?(me=o,G++):(me=r,$e===0&&Me(a)),me!==r?(Ge=Lr(),Ge!==r?(Te=Qa(),Te!==r?(yt=R,q=l(Te),R=q):(G=R,R=r)):(G=R,R=r)):(G=R,R=r)):(G=R,R=r),R}function Uu(){var R,q,me;for(R=G,q=[],me=Hu();me!==r;)q.push(me),me=Hu();return q!==r&&(yt=R,q=c(q)),R=q,R}function Hu(){var R,q,me,Ge,Te,Xe,Et,Rt,Jn;if(R=G,q=Lr(),q===r&&(q=null),q!==r){if(me=G,t.charCodeAt(G)===35?(Ge=u,G++):(Ge=r,$e===0&&Me(g)),Ge!==r){if(Te=[],Xe=G,Et=G,$e++,Rt=to(),$e--,Rt===r?Et=void 0:(G=Et,Et=r),Et!==r?(t.length>G?(Rt=t.charAt(G),G++):(Rt=r,$e===0&&Me(f)),Rt!==r?(Et=[Et,Rt],Xe=Et):(G=Xe,Xe=r)):(G=Xe,Xe=r),Xe!==r)for(;Xe!==r;)Te.push(Xe),Xe=G,Et=G,$e++,Rt=to(),$e--,Rt===r?Et=void 0:(G=Et,Et=r),Et!==r?(t.length>G?(Rt=t.charAt(G),G++):(Rt=r,$e===0&&Me(f)),Rt!==r?(Et=[Et,Rt],Xe=Et):(G=Xe,Xe=r)):(G=Xe,Xe=r);else Te=r;Te!==r?(Ge=[Ge,Te],me=Ge):(G=me,me=r)}else G=me,me=r;if(me===r&&(me=null),me!==r){if(Ge=[],Te=eo(),Te!==r)for(;Te!==r;)Ge.push(Te),Te=eo();else Ge=r;Ge!==r?(yt=R,q=h(),R=q):(G=R,R=r)}else G=R,R=r}else G=R,R=r;if(R===r&&(R=G,q=va(),q!==r?(me=Vl(),me!==r?(Ge=Lr(),Ge===r&&(Ge=null),Ge!==r?(t.charCodeAt(G)===58?(Te=p,G++):(Te=r,$e===0&&Me(m)),Te!==r?(Xe=Lr(),Xe===r&&(Xe=null),Xe!==r?(Et=Qa(),Et!==r?(yt=R,q=y(me,Et),R=q):(G=R,R=r)):(G=R,R=r)):(G=R,R=r)):(G=R,R=r)):(G=R,R=r)):(G=R,R=r),R===r&&(R=G,q=va(),q!==r?(me=$s(),me!==r?(Ge=Lr(),Ge===r&&(Ge=null),Ge!==r?(t.charCodeAt(G)===58?(Te=p,G++):(Te=r,$e===0&&Me(m)),Te!==r?(Xe=Lr(),Xe===r&&(Xe=null),Xe!==r?(Et=Qa(),Et!==r?(yt=R,q=y(me,Et),R=q):(G=R,R=r)):(G=R,R=r)):(G=R,R=r)):(G=R,R=r)):(G=R,R=r)):(G=R,R=r),R===r))){if(R=G,q=va(),q!==r)if(me=$s(),me!==r)if(Ge=Lr(),Ge!==r)if(Te=PE(),Te!==r){if(Xe=[],Et=eo(),Et!==r)for(;Et!==r;)Xe.push(Et),Et=eo();else Xe=r;Xe!==r?(yt=R,q=y(me,Te),R=q):(G=R,R=r)}else G=R,R=r;else G=R,R=r;else G=R,R=r;else G=R,R=r;if(R===r)if(R=G,q=va(),q!==r)if(me=$s(),me!==r){if(Ge=[],Te=G,Xe=Lr(),Xe===r&&(Xe=null),Xe!==r?(t.charCodeAt(G)===44?(Et=b,G++):(Et=r,$e===0&&Me(S)),Et!==r?(Rt=Lr(),Rt===r&&(Rt=null),Rt!==r?(Jn=$s(),Jn!==r?(yt=Te,Xe=k(me,Jn),Te=Xe):(G=Te,Te=r)):(G=Te,Te=r)):(G=Te,Te=r)):(G=Te,Te=r),Te!==r)for(;Te!==r;)Ge.push(Te),Te=G,Xe=Lr(),Xe===r&&(Xe=null),Xe!==r?(t.charCodeAt(G)===44?(Et=b,G++):(Et=r,$e===0&&Me(S)),Et!==r?(Rt=Lr(),Rt===r&&(Rt=null),Rt!==r?(Jn=$s(),Jn!==r?(yt=Te,Xe=k(me,Jn),Te=Xe):(G=Te,Te=r)):(G=Te,Te=r)):(G=Te,Te=r)):(G=Te,Te=r);else Ge=r;Ge!==r?(Te=Lr(),Te===r&&(Te=null),Te!==r?(t.charCodeAt(G)===58?(Xe=p,G++):(Xe=r,$e===0&&Me(m)),Xe!==r?(Et=Lr(),Et===r&&(Et=null),Et!==r?(Rt=Qa(),Rt!==r?(yt=R,q=T(me,Ge,Rt),R=q):(G=R,R=r)):(G=R,R=r)):(G=R,R=r)):(G=R,R=r)):(G=R,R=r)}else G=R,R=r;else G=R,R=r}return R}function Qa(){var R,q,me,Ge,Te,Xe,Et;if(R=G,q=G,$e++,me=G,Ge=to(),Ge!==r?(Te=it(),Te!==r?(t.charCodeAt(G)===45?(Xe=o,G++):(Xe=r,$e===0&&Me(a)),Xe!==r?(Et=Lr(),Et!==r?(Ge=[Ge,Te,Xe,Et],me=Ge):(G=me,me=r)):(G=me,me=r)):(G=me,me=r)):(G=me,me=r),$e--,me!==r?(G=q,q=void 0):q=r,q!==r?(me=eo(),me!==r?(Ge=Po(),Ge!==r?(Te=_l(),Te!==r?(Xe=NA(),Xe!==r?(yt=R,q=Y(Te),R=q):(G=R,R=r)):(G=R,R=r)):(G=R,R=r)):(G=R,R=r)):(G=R,R=r),R===r&&(R=G,q=to(),q!==r?(me=Po(),me!==r?(Ge=Uu(),Ge!==r?(Te=NA(),Te!==r?(yt=R,q=Y(Ge),R=q):(G=R,R=r)):(G=R,R=r)):(G=R,R=r)):(G=R,R=r),R===r))if(R=G,q=Xl(),q!==r){if(me=[],Ge=eo(),Ge!==r)for(;Ge!==r;)me.push(Ge),Ge=eo();else me=r;me!==r?(yt=R,q=j(q),R=q):(G=R,R=r)}else G=R,R=r;return R}function va(){var R,q,me;for($e++,R=G,q=[],t.charCodeAt(G)===32?(me=J,G++):(me=r,$e===0&&Me(re));me!==r;)q.push(me),t.charCodeAt(G)===32?(me=J,G++):(me=r,$e===0&&Me(re));return q!==r?(yt=G,me=ee(q),me?me=void 0:me=r,me!==r?(q=[q,me],R=q):(G=R,R=r)):(G=R,R=r),$e--,R===r&&(q=r,$e===0&&Me(Z)),R}function it(){var R,q,me;foLine truncated
`),n("\r"),n("\u2028"),n("\u2029")]}},t.prototype.atomEscape=function(){switch(this.consumeChar("\\"),this.peekChar()){case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":return this.decimalEscapeAtom();case"d":case"D":case"s":case"S":case"w":case"W":return this.characterClassEscape();case"f":case"n":case"r":case"t":case"v":return this.controlEscapeAtom();case"c":return this.controlLetterEscapeAtom();case"0":return this.nulCharacterAtom();case"x":return this.hexEscapeSequenceAtom();case"u":return this.regExpUnicodeEscapeSequenceAtom();default:return this.identityEscapeAtom()}},t.prototype.decimalEscapeAtom=function(){var p=this.positiveInteger();return{type:"GroupBackReference",value:p}},t.prototype.characterClassEscape=function(){var p,m=!1;switch(this.popChar()){case"d":p=u;break;case"D":p=u,m=!0;break;case"s":p=f;break;case"S":p=f,m=!0;break;case"w":p=g;break;case"W":p=g,m=!0;break}return a(p),{type:"Set",value:p,complement:m}},t.prototype.controlEscapeAtom=function(){var p;switch(this.popChar()){case"f":p=n("\f");break;case"n":p=n(`
`);break;case"r":p=n("\r");break;case"t":p=n(" ");break;case"v":p=n("\v");break}return a(p),{type:"Character",value:p}},t.prototype.controlLetterEscapeAtom=function(){this.consumeChar("c");var p=this.popChar();if(/[a-zA-Z]/.test(p)===!1)throw Error("Invalid ");var m=p.toUpperCase().charCodeAt(0)-64;return{type:"Character",value:m}},t.prototype.nulCharacterAtom=function(){return this.consumeChar("0"),{type:"Character",value:n("\0")}},t.prototype.hexEscapeSequenceAtom=function(){return this.consumeChar("x"),this.parseHexDigits(2)},t.prototype.regExpUnicodeEscapeSequenceAtom=function(){return this.consumeChar("u"),this.parseHexDigits(4)},t.prototype.identityEscapeAtom=function(){var p=this.popChar();return{type:"Character",value:n(p)}},t.prototype.classPatternCharacterAtom=function(){switch(this.peekChar()){case`
`:case"\r":case"\u2028":case"\u2029":case"\\":case"]":throw Error("TBD");default:var p=this.popChar();return{type:"Character",value:n(p)}}},t.prototype.characterClass=function(){var p=[],m=!1;for(this.consumeChar("["),this.peekChar(0)==="^"&&(this.consumeChar("^"),m=!0);this.isClassAtom();){var y=this.classAtom(),b=y.type==="Character";if(b&&this.isRangeDash()){this.consumeChar("-");var S=this.classAtom(),k=S.type==="Character";if(k){if(S.value<y.value)throw Error("Range out of order in character class");p.push({from:y.value,to:S.value})}else s(y.value,p),p.push(n("-")),s(S.value,p)}else s(y.value,p)}return this.consumeChar("]"),{type:"Set",complement:m,value:p}},t.prototype.classAtom=function(){switch(this.peekChar()){case"]":case`
`:case"\r":case"\u2028":case"\u2029":throw Error("TBD");case"\\":return this.classEscape();default:return this.classPatternCharacterAtom()}},t.prototype.classEscape=function(){switch(this.consumeChar("\\"),this.peekChar()){case"b":return this.consumeChar("b"),{type:"Character",value:n("\b")};case"d":case"D":case"s":case"S":case"w":case"W":return this.characterClassEscape();case"f":case"n":case"r":case"t":case"v":return this.controlEscapeAtom();case"c":return this.controlLetterEscapeAtom();case"0":return this.nulCharacterAtom();case"x":return this.hexEscapeSequenceAtom();case"u":return this.regExpUnicodeEscapeSequenceAtom();default:return this.identityEscapeAtom()}},t.prototype.group=function(){var p=!0;switch(this.consumeChar("("),this.peekChar(0)){case"?":this.consumeChar("?"),this.consumeChar(":"),p=!1;break;default:this.groupIdx++;break}var m=this.disjunction();this.consumeChar(")");var y={type:"Group",capturing:p,value:m};return p&&(y.idx=this.groupIdx),y},t.prototype.positiveInteger=function(){var p=this.popChar();if(i.test(p)===!1)throw Error("Expecting a positive integer");for(;r.test(this.peekChar(0));)p+=this.popChar();return parseInt(p,10)},t.prototype.integerIncludingZero=function(){var p=this.popChar();if(r.test(p)===!1)throw Error("Expecting an integer");for(;r.test(this.peekChar(0));)p+=this.popChar();return parseInt(p,10)},t.prototype.patternCharacter=function(){var p=this.popChar();switch(p){case`
`:case"\r":case"\u2028":case"\u2029":case"^":case"$":case"\\":case".":case"*":case"+":case"?":case"(":case")":case"[":case"|":throw Error("TBD");default:return{type:"Character",value:n(p)}}},t.prototype.isRegExpFlag=function(){switch(this.peekChar(0)){case"g":case"i":case"m":case"u":case"y":return!0;default:return!1}},t.prototype.isRangeDash=function(){return this.peekChar()==="-"&&this.isClassAtom(1)},t.prototype.isDigit=function(){return r.test(this.peekChar(0))},t.prototype.isClassAtom=function(p){switch(p===void 0&&(p=0),this.peekChar(p)){case"]":case`
`:case"\r":case"\u2028":case"\u2029":return!1;default:return!0}},t.prototype.isTerm=function(){return this.isAtom()||this.isAssertion()},t.prototype.isAtom=function(){if(this.isPatternCharacter())return!0;switch(this.peekChar(0)){case".":case"\\":case"[":case"(":return!0;default:return!1}},t.prototype.isAssertion=function(){switch(this.peekChar(0)){case"^":case"$":return!0;case"\\":switch(this.peekChar(1)){case"b":case"B":return!0;default:return!1}case"(":return this.peekChar(1)==="?"&&(this.peekChar(2)==="="||this.peekChar(2)==="!");default:return!1}},t.prototype.isQuantifier=function(){var p=this.saveState();try{return this.quantifier(!0)!==void 0}catch(m){return!1}finally{this.restoreState(p)}},t.prototype.isPatternCharacter=function(){switch(this.peekChar()){case"^":case"$":case"\\":case".":case"*":case"+":case"?":case"(":case")":case"[":case"|":case"/":case`
`:case"\r":case"\u2028":case"\u2029":return!1;default:return!0}},t.prototype.parseHexDigits=function(p){for(var m="",y=0;y<p;y++){var b=this.popChar();if(e.test(b)===!1)throw Error("Expecting a HexDecimal digits");m+=b}var S=parseInt(m,16);return{type:"Character",value:S}},t.prototype.peekChar=function(p){return p===void 0&&(p=0),this.input[this.idx+p]},t.prototype.popChar=function(){var p=this.peekChar(0);return this.consumeChar(),p},t.prototype.consumeChar=function(p){if(p!==void 0&&this.input[this.idx]!==p)throw Error("Expected: '"+p+"' but found: '"+this.input[this.idx]+"' at offset: "+this.idx);if(this.idx>=this.input.length)throw Error("Unexpected end of input");this.idx++},t.prototype.loc=function(p){return{begin:p,end:this.idx}};var e=/[0-9a-fA-F]/,r=/[0-9]/,i=/[1-9]/;function n(p){return p.charCodeAt(0)}function s(p,m){p.length!==void 0?p.forEach(function(y){m.push(y)}):m.push(p)}function o(p,m){if(p[m]===!0)throw"duplicate flag "+m;p[m]=!0}function a(p){if(p===void 0)throw Error("Internal Error - Should never get here!")}function l(){throw Error("Internal Error - Should never get here!")}var c,u=[];for(c=n("0");c<=n("9");c++)u.push(c);var g=[n("_")].concat(u);for(c=n("a");c<=n("z");c++)g.push(c);for(c=n("A");c<=n("Z");c++)g.push(c);var f=[n(" "),n("\f"),n(`
`),n("\r"),n(" "),n("\v"),n(" "),n("\xA0"),n("\u1680"),n("\u2000"),n("\u2001"),n("\u2002"),n("\u2003"),n("\u2004"),n("\u2005"),n("\u2006"),n("\u2007"),n("\u2008"),n("\u2009"),n("\u200A"),n("\u2028"),n("\u2029"),n("\u202F"),n("\u205F"),n("\u3000"),n("\uFEFF")];function h(){}return h.prototype.visitChildren=function(p){for(var m in p){var y=p[m];p.hasOwnProperty(m)&&(y.type!==void 0?this.visit(y):Array.isArray(y)&&y.forEach(function(b){this.visit(b)},this))}},h.prototype.visit=function(p){switch(p.type){case"Pattern":this.visitPattern(p);break;case"Flags":this.visitFlags(p);break;case"Disjunction":this.visitDisjunction(p);break;case"Alternative":this.visitAlternative(p);break;case"StartAnchor":this.visitStartAnchor(p);break;case"EndAnchor":this.visitEndAnchor(p);break;case"WordBoundary":this.visitWordBoundary(p);break;case"NonWordBoundary":this.visitNonWordBoundary(p);break;case"Lookahead":this.visitLookahead(p);break;case"NegativeLookahead":this.visitNegativeLookahead(p);break;case"Character":this.visitCharacter(p);break;case"Set":this.visitSet(p);break;case"Group":this.visitGroup(p);break;case"GroupBackReference":this.visitGroupBackReference(p);break;case"Quantifier":this.visitQuantifier(p);break}this.visitChildren(p)},h.prototype.visitPattern=function(p){},h.prototype.visitFlags=function(p){},h.prototype.visitDisjunction=function(p){},h.prototype.visitAlternative=function(p){},h.prototype.visitStartAnchor=function(p){},h.prototype.visitEndAnchor=function(p){},h.prototype.visitWordBoundary=function(p){},h.prototype.visitNonWordBoundary=function(p){},h.prototype.visitLookahead=function(p){},h.prototype.visitNegativeLookahead=function(p){},h.prototype.visitCharacter=function(p){},h.prototype.visitSet=function(p){},h.prototype.visitGroup=function(p){},h.prototype.visitGroupBackReference=function(p){},h.prototype.visitQuantifier=function(p){},{RegExpParser:t,BaseRegExpVisitor:h,VERSION:"0.5.0"}})});var GI=w(fg=>{"use strict";Object.defineProperty(fg,"__esModule",{value:!0});fg.clearRegExpParserCache=fg.getRegExpAst=void 0;var _Ee=UI(),HI={},VEe=new _Ee.RegExpParser;function XEe(t){var e=t.toString();if(HI.hasOwnProperty(e))return HI[e];var r=VEe.pattern(e);return HI[e]=r,r}fg.getRegExpAst=XEe;function ZEe(){HI={}}fg.clearRegExpParserCache=ZEe});var ZH=w(Bn=>{"use strict";var $Ee=Bn&&Bn.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(Bn,"__esModule",{value:!0});Bn.canMatchCharCode=Bn.firstCharOptimizedIndices=Bn.getOptimizedStartCodesIndices=Bn.failedOptimizationPrefixMsg=void 0;var zH=UI(),Qs=Yt(),_H=GI(),Ka=Fv(),VH="Complement Sets are not supported for first char optimization";Bn.failedOptimizationPrefixMsg=`Unable to use "first char" lexer optimizations:
`;function eIe(t,e){e===void 0&&(e=!1);try{var r=(0,_H.getRegExpAst)(t),i=jI(r.value,{},r.flags.ignoreCase);return i}catch(s){if(s.message===VH)e&&(0,Qs.PRINT_WARNING)(""+Bn.failedOptimizationPrefixMsg+(" Unable to optimize: < "+t.toString()+` >
`)+` Complement Sets cannot be automatically optimized.
This will disable the lexer's first char optimizations.
See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#COMPLEMENT for details.`);else{var n="";e&&(n=`
This will disable the lexer's first char optimizations.
See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#REGEXP_PARSING for details.`),(0,Qs.PRINT_ERROR)(Bn.failedOptimizationPrefixMsg+`
`+(" Failed parsing: < "+t.toString()+` >
`)+(" Using the regexp-to-ast library version: "+zH.VERSION+`
`)+" Please open an issue at: https://github.com/bd82/regexp-to-ast/issues"+n)}}return[]}Bn.getOptimizedStartCodesIndices=eIe;function jI(t,e,r){switch(t.type){case"Disjunction":for(var i=0;i<t.value.length;i++)jI(t.value[i],e,r);break;case"Alternative":for(var n=t.value,i=0;i<n.length;i++){var s=n[i];switch(s.type){case"EndAnchor":case"GroupBackReference":case"Lookahead":case"NegativeLookahead":case"StartAnchor":case"WordBoundary":case"NonWordBoundary":continue}var o=s;switch(o.type){case"Character":YI(o.value,e,r);break;case"Set":if(o.complement===!0)throw Error(VH);(0,Qs.forEach)(o.value,function(c){if(typeof c=="number")YI(c,e,r);else{var u=c;if(r===!0)for(var g=u.from;g<=u.to;g++)YI(g,e,r);else{for(var g=u.from;g<=u.to&&g<Ka.minOptimizationVal;g++)YI(g,e,r);if(u.to>=Ka.minOptimizationVal)for(var f=u.from>=Ka.minOptimizationVal?u.from:Ka.minOptimizationVal,h=u.to,p=(0,Ka.charCodeToOptimizedIndex)(f),m=(0,Ka.charCodeToOptimizedIndex)(h),y=p;y<=m;y++)e[y]=y}}});break;case"Group":jI(o.value,e,r);break;default:throw Error("Non Exhaustive Match")}var a=o.quantifier!==void 0&&o.quantifier.atLeast===0;if(o.type==="Group"&&Nv(o)===!1||o.type!=="Group"&&a===!1)break}break;default:throw Error("non exhaustive match!")}return(0,Qs.values)(e)}Bn.firstCharOptimizedIndices=jI;function YI(t,e,r){var i=(0,Ka.charCodeToOptimizedIndex)(t);e[i]=i,r===!0&&tIe(t,e)}function tIe(t,e){var r=String.fromCharCode(t),i=r.toUpperCase();if(i!==r){var n=(0,Ka.charCodeToOptimizedIndex)(i.charCodeAt(0));e[n]=n}else{var s=r.toLowerCase();if(s!==r){var n=(0,Ka.charCodeToOptimizedIndex)(s.charCodeAt(0));e[n]=n}}}function XH(t,e){return(0,Qs.find)(t.value,function(r){if(typeof r=="number")return(0,Qs.contains)(e,r);var i=r;return(0,Qs.find)(e,function(n){return i.from<=n&&n<=i.to})!==void 0})}function Nv(t){return t.quantifier&&t.quantifier.atLeast===0?!0:t.value?(0,Qs.isArray)(t.value)?(0,Qs.every)(t.value,Nv):Nv(t.value):!1}var rIe=function(t){$Ee(e,t);function e(r){var i=t.call(this)||this;return i.targetCharCodes=r,i.found=!1,i}return e.prototype.visitChildren=function(r){if(this.found!==!0){switch(r.type){case"Lookahead":this.visitLookahead(r);return;case"NegativeLookahead":this.visitNegativeLookahead(r);return}t.prototype.visitChildren.call(this,r)}},e.prototype.visitCharacter=function(r){(0,Qs.contains)(this.targetCharCodes,r.value)&&(this.found=!0)},e.prototype.visitSet=function(r){r.complement?XH(r,this.targetCharCodes)===void 0&&(this.found=!0):XH(r,this.targetCharCodes)!==void 0&&(this.found=!0)},e}(zH.BaseRegExpVisitor);function iIe(t,e){if(e instanceof RegExp){var r=(0,_H.getRegExpAst)(e),i=new rIe(t);return i.visit(r),i.found}else return(0,Qs.find)(e,function(n){return(0,Qs.contains)(t,n.charCodeAt(0))})!==void 0}Bn.canMatchCharCode=iIe});var Fv=w(Ze=>{"use strict";var $H=Ze&&Ze.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(Ze,"__esModule",{value:!0});Ze.charCodeToOptimizedIndex=Ze.minOptimizationVal=Ze.buildLineBreakIssueMessage=Ze.LineTerminatorOptimizedTester=Ze.isShortPattern=Ze.isCustomPattern=Ze.cloneEmptyGroups=Ze.performWarningRuntimeChecks=Ze.performRuntimeChecks=Ze.addStickyFlag=Ze.addStartOfInput=Ze.findUnreachablePatterns=Ze.findModesThatDoNotExist=Ze.findInvalidGroupType=Ze.findDuplicatePatterns=Ze.findUnsupportedFlags=Ze.findStartOfInputAnchor=Ze.findEmptyMatchRegExps=Ze.findEndOfInputAnchor=Ze.findInvalidPatterns=Ze.findMissingPatterns=Ze.validatePatterns=Ze.analyzeTokenTypes=Ze.enableSticky=Ze.disableSticky=Ze.SUPPORT_STICKY=Ze.MODES=Ze.DEFAULT_MODE=void 0;var eG=UI(),Ar=Rp(),Ne=Yt(),hg=ZH(),tG=GI(),Lo="PATTERN";Ze.DEFAULT_MODE="defaultMode";Ze.MODES="modes";Ze.SUPPORT_STICKY=typeof new RegExp("(?:)").sticky=="boolean";function nIe(){Ze.SUPPORT_STICKY=!1}Ze.disableSticky=nIe;function sIe(){Ze.SUPPORT_STICKY=!0}Ze.enableSticky=sIe;function aIe(t,e){e=(0,Ne.defaults)(e,{useSticky:Ze.SUPPORT_STICKY,debug:!1,safeMode:!1,positionTracking:"full",lineTerminatorCharacters:["\r",`
`],tracer:function(S,k){return k()}});var r=e.tracer;r("initCharCodeToOptimizedIndexMap",function(){oIe()});var i;r("Reject Lexer.NA",function(){i=(0,Ne.reject)(t,function(S){return S[Lo]===Ar.Lexer.NA})});var n=!1,s;r("Transform Patterns",function(){n=!1,s=(0,Ne.map)(i,function(S){var k=S[Lo];if((0,Ne.isRegExp)(k)){var T=k.source;return T.length===1&&T!=="^"&&T!=="$"&&T!=="."&&!k.ignoreCase?T:T.length===2&&T[0]==="\\"&&!(0,Ne.contains)(["d","D","s","S","t","r","n","t","0","c","b","B","f","v","w","W"],T[1])?T[1]:e.useSticky?Tv(k):Lv(k)}else{if((0,Ne.isFunction)(k))return n=!0,{exec:k};if((0,Ne.has)(k,"exec"))return n=!0,k;if(typeof k=="string"){if(k.length===1)return k;var Y=k.replace(/[\\^$.*+?()[\]{}|]/g,"\\$&"),j=new RegExp(Y);return e.useSticky?Tv(j):Lv(j)}else throw Error("non exhaustive match")}})});var o,a,l,c,u;r("misc mapping",function(){o=(0,Ne.map)(i,function(S){return S.tokenTypeIdx}),a=(0,Ne.map)(i,function(S){var k=S.GROUP;if(k!==Ar.Lexer.SKIPPED){if((0,Ne.isString)(k))return k;if((0,Ne.isUndefined)(k))return!1;throw Error("non exhaustive match")}}),l=(0,Ne.map)(i,function(S){var k=S.LONGER_ALT;if(k){var T=(0,Ne.isArray)(k)?(0,Ne.map)(k,function(Y){return(0,Ne.indexOf)(i,Y)}):[(0,Ne.indexOf)(i,k)];return T}}),c=(0,Ne.map)(i,function(S){return S.PUSH_MODE}),u=(0,Ne.map)(i,function(S){return(0,Ne.has)(S,"POP_MODE")})});var g;r("Line Terminator Handling",function(){var S=nG(e.lineTerminatorCharacters);g=(0,Ne.map)(i,function(k){return!1}),e.positionTracking!=="onlyOffset"&&(g=(0,Ne.map)(i,function(k){if((0,Ne.has)(k,"LINE_BREAKS"))return k.LINE_BREAKS;if(iG(k,S)===!1)return(0,hg.canMatchCharCode)(S,k.PATTERN)}))});var f,h,p,m;r("Misc Mapping #2",function(){f=(0,Ne.map)(i,Ov),h=(0,Ne.map)(s,rG),p=(0,Ne.reduce)(i,function(S,k){var T=k.GROUP;return(0,Ne.isString)(T)&&T!==Ar.Lexer.SKIPPED&&(S[T]=[]),S},{}),m=(0,Ne.map)(s,function(S,k){return{pattern:s[k],longerAlt:l[k],canLineTerminator:g[k],isCustom:f[k],short:h[k],group:a[k],push:c[k],pop:u[k],tokenTypeIdx:o[k],tokenType:i[k]}})});var y=!0,b=[];return e.safeMode||r("First Char Optimization",function(){b=(0,Ne.reduce)(i,function(S,k,T){if(typeof k.PATTERN=="string"){var Y=k.PATTERN.charCodeAt(0),j=Kv(Y);Mv(S,j,m[T])}else if((0,Ne.isArray)(k.START_CHARS_HINT)){var Z;(0,Ne.forEach)(k.START_CHARS_HINT,function(re){var ee=typeof re=="string"?re.charCodeAt(0):re,A=Kv(ee);Z!==A&&(Z=A,Mv(S,A,m[T]))})}else if((0,Ne.isRegExp)(k.PATTERN))if(k.PATTERN.unicode)y=!1,e.ensureOptimizations&&(0,Ne.PRINT_ERROR)(""+hg.failedOptimizationPrefixMsg+(" Unable to analyze < "+k.PATTERN.toString()+` > pattern.
`)+` The regexp unicode flag is not currently supported by the regexp-to-ast library.
This will disable the lexer's first char optimizations.
For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#UNICODE_OPTIMIZE`);else{var J=(0,hg.getOptimizedStartCodesIndices)(k.PATTERN,e.ensureOptimizations);(0,Ne.isEmpty)(J)&&(y=!1),(0,Ne.forEach)(J,function(re){Mv(S,re,m[T])})}else e.ensureOptimizations&&(0,Ne.PRINT_ERROR)(""+hg.failedOptimizationPrefixMsg+(" TokenType: <"+k.name+`> is using a custom token pattern without providing <start_chars_hint> parameter.
`)+` This will disable the lexer's first char optimizations.
For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_OPTIMIZE`),y=!1;return S},[])}),r("ArrayPacking",function(){b=(0,Ne.packArray)(b)}),{emptyGroups:p,patternIdxToConfig:m,charCodeToPatternIdxToConfig:b,hasCustom:n,canBeOptimized:y}}Ze.analyzeTokenTypes=aIe;function lIe(t,e){var r=[],i=sG(t);r=r.concat(i.errors);var n=oG(i.valid),s=n.valid;return r=r.concat(n.errors),r=r.concat(AIe(s)),r=r.concat(aG(s)),r=r.concat(AG(s,e)),r=r.concat(lG(s)),r}Ze.validatePatterns=lIe;function AIe(t){var e=[],r=(0,Ne.filter)(t,function(i){return(0,Ne.isRegExp)(i[Lo])});return e=e.concat(cG(r)),e=e.concat(gG(r)),e=e.concat(fG(r)),e=e.concat(hG(r)),e=e.concat(uG(r)),e}function sG(t){var e=(0,Ne.filter)(t,function(n){return!(0,Ne.has)(n,Lo)}),r=(0,Ne.map)(e,function(n){return{message:"Token Type: ->"+n.name+"<- missing static 'PATTERN' property",type:Ar.LexerDefinitionErrorType.MISSING_PATTERN,tokenTypes:[n]}}),i=(0,Ne.difference)(t,e);return{errors:r,valid:i}}Ze.findMissingPatterns=sG;function oG(t){var e=(0,Ne.filter)(t,function(n){var s=n[Lo];return!(0,Ne.isRegExp)(s)&&!(0,Ne.isFunction)(s)&&!(0,Ne.has)(s,"exec")&&!(0,Ne.isString)(s)}),r=(0,Ne.map)(e,function(n){return{message:"Token Type: ->"+n.name+"<- static 'PATTERN' can only be a RegExp, a Function matching the {CustomPatternMatcherFunc} type or an Object matching the {ICustomPattern} interface.",type:Ar.LexerDefinitionErrorType.INVALID_PATTERN,tokenTypes:[n]}}),i=(0,Ne.difference)(t,e);return{errors:r,valid:i}}Ze.findInvalidPatterns=oG;var cIe=/[^\\][\$]/;function cG(t){var e=function(n){$H(s,n);function s(){var o=n!==null&&n.apply(this,arguments)||this;return o.found=!1,o}return s.prototype.visitEndAnchor=function(o){this.found=!0},s}(eG.BaseRegExpVisitor),r=(0,Ne.filter)(t,function(n){var s=n[Lo];try{var o=(0,tG.getRegExpAst)(s),a=new e;return a.visit(o),a.found}catch(l){return cIe.test(s.source)}}),i=(0,Ne.map)(r,function(n){return{message:`Unexpected RegExp Anchor Error:
Token Type: ->`+n.name+`<- static 'PATTERN' cannot contain end of input anchor '$'
See chevrotain.io/docs/guide/resolving_lexer_errors.html#ANCHORS for details.`,type:Ar.LexerDefinitionErrorType.EOI_ANCHOR_FOUND,tokenTypes:[n]}});return i}Ze.findEndOfInputAnchor=cG;function uG(t){var e=(0,Ne.filter)(t,function(i){var n=i[Lo];return n.test("")}),r=(0,Ne.map)(e,function(i){return{message:"Token Type: ->"+i.name+"<- static 'PATTERN' must not match an empty string",type:Ar.LexerDefinitionErrorType.EMPTY_MATCH_PATTERN,tokenTypes:[i]}});return r}Ze.findEmptyMatchRegExps=uG;var uIe=/[^\\[][\^]|^\^/;function gG(t){var e=function(n){$H(s,n);function s(){var o=n!==null&&n.apply(this,arguments)||this;return o.found=!1,o}return s.prototype.visitStartAnchor=function(o){this.found=!0},s}(eG.BaseRegExpVisitor),r=(0,Ne.filter)(t,function(n){var s=n[Lo];try{var o=(0,tG.getRegExpAst)(s),a=new e;return a.visit(o),a.found}catch(l){return uIe.test(s.source)}}),i=(0,Ne.map)(r,function(n){return{message:`Unexpected RegExp Anchor Error:
Token Type: ->`+n.name+`<- static 'PATTERN' cannot contain start of input anchor '^'
See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#ANCHORS for details.`,type:Ar.LexerDefinitionErrorType.SOI_ANCHOR_FOUND,tokenTypes:[n]}});return i}Ze.findStartOfInputAnchor=gG;function fG(t){var e=(0,Ne.filter)(t,function(i){var n=i[Lo];return n instanceof RegExp&&(n.multiline||n.global)}),r=(0,Ne.map)(e,function(i){return{message:"Token Type: ->"+i.name+"<- static 'PATTERN' may NOT contain global('g') or multiline('m')",type:Ar.LexerDefinitionErrorType.UNSUPPORTED_FLAGS_FOUND,tokenTypes:[i]}});return r}Ze.findUnsupportedFlags=fG;function hG(t){var e=[],r=(0,Ne.map)(t,function(s){return(0,Ne.reduce)(t,function(o,a){return s.PATTERN.source===a.PATTERN.source&&!(0,Ne.contains)(e,a)&&a.PATTERN!==Ar.Lexer.NA&&(e.push(a),o.push(a)),o},[])});r=(0,Ne.compact)(r);var i=(0,Ne.filter)(r,function(s){return s.length>1}),n=(0,Ne.map)(i,function(s){var o=(0,Ne.map)(s,function(l){return l.name}),a=(0,Ne.first)(s).PATTERN;return{message:"The same RegExp pattern ->"+a+"<-"+("has been used in all of the following Token Types: "+o.join(", ")+" <-"),type:Ar.LexerDefinitionErrorType.DUPLICATE_PATTERNS_FOUND,tokenTypes:s}});return n}Ze.findDuplicatePatterns=hG;function aG(t){var e=(0,Ne.filter)(t,function(i){if(!(0,Ne.has)(i,"GROUP"))return!1;var n=i.GROUP;return n!==Ar.Lexer.SKIPPED&&n!==Ar.Lexer.NA&&!(0,Ne.isString)(n)}),r=(0,Ne.map)(e,function(i){return{message:"Token Type: ->"+i.name+"<- static 'GROUP' can only be Lexer.SKIPPED/Lexer.NA/A String",type:Ar.LexerDefinitionErrorType.INVALID_GROUP_TYPE_FOUND,tokenTypes:[i]}});return r}Ze.findInvalidGroupType=aG;function AG(t,e){var r=(0,Ne.filter)(t,function(n){return n.PUSH_MODE!==void 0&&!(0,Ne.contains)(e,n.PUSH_MODE)}),i=(0,Ne.map)(r,function(n){var s="Token Type: ->"+n.name+"<- static 'PUSH_MODE' value cannot refer to a Lexer Mode ->"+n.PUSH_MODE+"<-which does not exist";return{message:s,type:Ar.LexerDefinitionErrorType.PUSH_MODE_DOES_NOT_EXIST,tokenTypes:[n]}});return i}Ze.findModesThatDoNotExist=AG;function lG(t){var e=[],r=(0,Ne.reduce)(t,function(i,n,s){var o=n.PATTERN;return o===Ar.Lexer.NA||((0,Ne.isString)(o)?i.push({str:o,idx:s,tokenType:n}):(0,Ne.isRegExp)(o)&&fIe(o)&&i.push({str:o.source,idx:s,tokenType:n})),i},[]);return(0,Ne.forEach)(t,function(i,n){(0,Ne.forEach)(r,function(s){var o=s.str,a=s.idx,l=s.tokenType;if(n<a&&gIe(o,i.PATTERN)){var c="Token: ->"+l.name+`<- can never be matched.
`+("Because it appears AFTER the Token Type ->"+i.name+"<-")+`in the lexer's definition.
See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#UNREACHABLE`;e.push({message:c,type:Ar.LexerDefinitionErrorType.UNREACHABLE_PATTERN,tokenTypes:[i,l]})}})}),e}Ze.findUnreachablePatterns=lG;function gIe(t,e){if((0,Ne.isRegExp)(e)){var r=e.exec(t);return r!==null&&r.index===0}else{if((0,Ne.isFunction)(e))return e(t,0,[],{});if((0,Ne.has)(e,"exec"))return e.exec(t,0,[],{});if(typeof e=="string")return e===t;throw Error("non exhaustive match")}}function fIe(t){var e=[".","\\","[","]","|","^","$","(",")","?","*","+","{"];return(0,Ne.find)(e,function(r){return t.source.indexOf(r)!==-1})===void 0}function Lv(t){var e=t.ignoreCase?"i":"";return new RegExp("^(?:"+t.source+")",e)}Ze.addStartOfInput=Lv;function Tv(t){var e=t.ignoreCase?"iy":"y";return new RegExp(""+t.source,e)}Ze.addStickyFlag=Tv;function hIe(t,e,r){var i=[];return(0,Ne.has)(t,Ze.DEFAULT_MODE)||i.push({message:"A MultiMode Lexer cannot be initialized without a <"+Ze.DEFAULT_MODE+`> property in its definition
`,type:Ar.LexerDefinitionErrorType.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE}),(0,Ne.has)(t,Ze.MODES)||i.push({message:"A MultiMode Lexer cannot be initialized without a <"+Ze.MODES+`> property in its definition
`,type:Ar.LexerDefinitionErrorType.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY}),(0,Ne.has)(t,Ze.MODES)&&(0,Ne.has)(t,Ze.DEFAULT_MODE)&&!(0,Ne.has)(t.modes,t.defaultMode)&&i.push({message:"A MultiMode Lexer cannot be initialized with a "+Ze.DEFAULT_MODE+": <"+t.defaultMode+`>which does not exist
`,type:Ar.LexerDefinitionErrorType.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST}),(0,Ne.has)(t,Ze.MODES)&&(0,Ne.forEach)(t.modes,function(n,s){(0,Ne.forEach)(n,function(o,a){(0,Ne.isUndefined)(o)&&i.push({message:"A Lexer cannot be initialized using an undefined Token Type. Mode:"+("<"+s+"> at index: <"+a+`>
`),type:Ar.LexerDefinitionErrorType.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED})})}),i}Ze.performRuntimeChecks=hIe;function pIe(t,e,r){var i=[],n=!1,s=(0,Ne.compact)((0,Ne.flatten)((0,Ne.mapValues)(t.modes,function(l){return l}))),o=(0,Ne.reject)(s,function(l){return l[Lo]===Ar.Lexer.NA}),a=nG(r);return e&&(0,Ne.forEach)(o,function(l){var c=iG(l,a);if(c!==!1){var u=pG(l,c),g={message:u,type:c.issue,tokenType:l};i.push(g)}else(0,Ne.has)(l,"LINE_BREAKS")?l.LINE_BREAKS===!0&&(n=!0):(0,hg.canMatchCharCode)(a,l.PATTERN)&&(n=!0)}),e&&!n&&i.push({message:`Warning: No LINE_BREAKS Found.
This Lexer has been defined to track line and column information,
But none of the Token Types can be identified as matching a line terminator.
See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#LINE_BREAKS
for details.`,type:Ar.LexerDefinitionErrorType.NO_LINE_BREAKS_FLAGS}),i}Ze.performWarningRuntimeChecks=pIe;function dIe(t){var e={},r=(0,Ne.keys)(t);return(0,Ne.forEach)(r,function(i){var n=t[i];if((0,Ne.isArray)(n))e[i]=[];else throw Error("non exhaustive match")}),e}Ze.cloneEmptyGroups=dIe;function Ov(t){var e=t.PATTERN;if((0,Ne.isRegExp)(e))return!1;if((0,Ne.isFunction)(e))return!0;if((0,Ne.has)(e,"exec"))return!0;if((0,Ne.isString)(e))return!1;throw Error("non exhaustive match")}Ze.isCustomPattern=Ov;function rG(t){return(0,Ne.isString)(t)&&t.length===1?t.charCodeAt(0):!1}Ze.isShortPattern=rG;Ze.LineTerminatorOptimizedTester={test:function(t){for(var e=t.length,r=this.lastIndex;r<e;r++){var i=t.charCodeAt(r);if(i===10)return this.lastIndex=r+1,!0;if(i===13)return t.charCodeAt(r+1)===10?this.lastIndex=r+2:this.lastIndex=r+1,!0}return!1},lastIndex:0};function iG(t,e){if((0,Ne.has)(t,"LINE_BREAKS"))return!1;if((0,Ne.isRegExp)(t.PATTERN)){try{(0,hg.canMatchCharCode)(e,t.PATTERN)}catch(r){return{issue:Ar.LexerDefinitionErrorType.IDENTIFY_TERMINATOR,errMsg:r.message}}return!1}else{if((0,Ne.isString)(t.PATTERN))return!1;if(Ov(t))return{issue:Ar.LexerDefinitionErrorType.CUSTOM_LINE_BREAK};throw Error("non exhaustive match")}}function pG(t,e){if(e.issue===Ar.LexerDefinitionErrorType.IDENTIFY_TERMINATOR)return`Warning: unable to identify line terminator usage in pattern.
`+(" The problem is in the <"+t.name+`> Token Type
`)+(" Root cause: "+e.errMsg+`.
`)+" For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#IDENTIFY_TERMINATOR";if(e.issue===Ar.LexerDefinitionErrorType.CUSTOM_LINE_BREAK)return`Warning: A Custom Token Pattern should specify the <line_breaks> option.
`+(" The problem is in the <"+t.name+`> Token Type
`)+" For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_LINE_BREAK";throw Error("non exhaustive match")}Ze.buildLineBreakIssueMessage=pG;function nG(t){var e=(0,Ne.map)(t,function(r){return(0,Ne.isString)(r)&&r.length>0?r.charCodeAt(0):r});return e}function Mv(t,e,r){t[e]===void 0?t[e]=[r]:t[e].push(r)}Ze.minOptimizationVal=256;var qI=[];function Kv(t){return t<Ze.minOptimizationVal?t:qI[t]}Ze.charCodeToOptimizedIndex=Kv;function oIe(){if((0,Ne.isEmpty)(qI)){qI=new Array(65536);for(var t=0;t<65536;t++)qI[t]=t>255?255+~~(t/255):t}}});var pg=w(Ft=>{"use strict";Object.defineProperty(Ft,"__esModule",{value:!0});Ft.isTokenType=Ft.hasExtendingTokensTypesMapProperty=Ft.hasExtendingTokensTypesProperty=Ft.hasCategoriesProperty=Ft.hasShortKeyProperty=Ft.singleAssignCategoriesToksMap=Ft.assignCategoriesMapProp=Ft.assignCategoriesTokensProp=Ft.assignTokenDefaultProps=Ft.expandCategories=Ft.augmentTokenTypes=Ft.tokenIdxToClass=Ft.tokenShortNameIdx=Ft.tokenStructuredMatcherNoCategories=Ft.tokenStructuredMatcher=void 0;var ii=Yt();function CIe(t,e){var r=t.tokenTypeIdx;return r===e.tokenTypeIdx?!0:e.isParent===!0&&e.categoryMatchesMap[r]===!0}Ft.tokenStructuredMatcher=CIe;function mIe(t,e){return t.tokenTypeIdx===e.tokenTypeIdx}Ft.tokenStructuredMatcherNoCategories=mIe;Ft.tokenShortNameIdx=1;Ft.tokenIdxToClass={};function EIe(t){var e=dG(t);CG(e),EG(e),mG(e),(0,ii.forEach)(e,function(r){r.isParent=r.categoryMatches.length>0})}Ft.augmentTokenTypes=EIe;function dG(t){for(var e=(0,ii.cloneArr)(t),r=t,i=!0;i;){r=(0,ii.compact)((0,ii.flatten)((0,ii.map)(r,function(s){return s.CATEGORIES})));var n=(0,ii.difference)(r,e);e=e.concat(n),(0,ii.isEmpty)(n)?i=!1:r=n}return e}Ft.expandCategories=dG;function CG(t){(0,ii.forEach)(t,function(e){IG(e)||(Ft.tokenIdxToClass[Ft.tokenShortNameIdx]=e,e.tokenTypeIdx=Ft.tokenShortNameIdx++),Uv(e)&&!(0,ii.isArray)(e.CATEGORIES)&&(e.CATEGORIES=[e.CATEGORIES]),Uv(e)||(e.CATEGORIES=[]),yG(e)||(e.categoryMatches=[]),wG(e)||(e.categoryMatchesMap={})})}Ft.assignTokenDefaultProps=CG;function mG(t){(0,ii.forEach)(t,function(e){e.categoryMatches=[],(0,ii.forEach)(e.categoryMatchesMap,function(r,i){e.categoryMatches.push(Ft.tokenIdxToClass[i].tokenTypeIdx)})})}Ft.assignCategoriesTokensProp=mG;function EG(t){(0,ii.forEach)(t,function(e){Hv([],e)})}Ft.assignCategoriesMapProp=EG;function Hv(t,e){(0,ii.forEach)(t,function(r){e.categoryMatchesMap[r.tokenTypeIdx]=!0}),(0,ii.forEach)(e.CATEGORIES,function(r){var i=t.concat(e);(0,ii.contains)(i,r)||Hv(i,r)})}Ft.singleAssignCategoriesToksMap=Hv;function IG(t){return(0,ii.has)(t,"tokenTypeIdx")}Ft.hasShortKeyProperty=IG;function Uv(t){return(0,ii.has)(t,"CATEGORIES")}Ft.hasCategoriesProperty=Uv;function yG(t){return(0,ii.has)(t,"categoryMatches")}Ft.hasExtendingTokensTypesProperty=yG;function wG(t){return(0,ii.has)(t,"categoryMatchesMap")}Ft.hasExtendingTokensTypesMapProperty=wG;function IIe(t){return(0,ii.has)(t,"tokenTypeIdx")}Ft.isTokenType=IIe});var Gv=w(JI=>{"use strict";Object.defineProperty(JI,"__esModule",{value:!0});JI.defaultLexerErrorProvider=void 0;JI.defaultLexerErrorProvider={buildUnableToPopLexerModeMessage:function(t){return"Unable to pop Lexer Mode after encountering Token ->"+t.image+"<- The Mode Stack is empty"},buildUnexpectedCharactersMessage:function(t,e,r,i,n){return"unexpected character: ->"+t.charAt(e)+"<- at offset: "+e+","+(" skipped "+r+" characters.")}}});var Rp=w(bc=>{"use strict";Object.defineProperty(bc,"__esModule",{value:!0});bc.Lexer=bc.LexerDefinitionErrorType=void 0;var oo=Fv(),lr=Yt(),yIe=pg(),wIe=Gv(),BIe=GI(),bIe;(function(t){t[t.MISSING_PATTERN=0]="MISSING_PATTERN",t[t.INVALID_PATTERN=1]="INVALID_PATTERN",t[t.EOI_ANCHOR_FOUND=2]="EOI_ANCHOR_FOUND",t[t.UNSUPPORTED_FLAGS_FOUND=3]="UNSUPPORTED_FLAGS_FOUND",t[t.DUPLICATE_PATTERNS_FOUND=4]="DUPLICATE_PATTERNS_FOUND",t[t.INVALID_GROUP_TYPE_FOUND=5]="INVALID_GROUP_TYPE_FOUND",t[t.PUSH_MODE_DOES_NOT_EXIST=6]="PUSH_MODE_DOES_NOT_EXIST",t[t.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE=7]="MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE",t[t.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY=8]="MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY",t[t.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST=9]="MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST",t[t.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED=10]="LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED",t[t.SOI_ANCHOR_FOUND=11]="SOI_ANCHOR_FOUND",t[t.EMPTY_MATCH_PATTERN=12]="EMPTY_MATCH_PATTERN",t[t.NO_LINE_BREAKS_FLAGS=13]="NO_LINE_BREAKS_FLAGS",t[t.UNREACHABLE_PATTERN=14]="UNREACHABLE_PATTERN",t[t.IDENTIFY_TERMINATOR=15]="IDENTIFY_TERMINATOR",t[t.CUSTOM_LINE_BREAK=16]="CUSTOM_LINE_BREAK"})(bIe=bc.LexerDefinitionErrorType||(bc.LexerDefinitionErrorType={}));var Fp={deferDefinitionErrorsHandling:!1,positionTracking:"full",lineTerminatorsPattern:/\n|\r\n?/g,lineTerminatorCharacters:[`
`,"\r"],ensureOptimizations:!1,safeMode:!1,errorMessageProvider:wIe.defaultLexerErrorProvider,traceInitPerf:!1,skipValidations:!1};Object.freeze(Fp);var QIe=function(){function t(e,r){var i=this;if(r===void 0&&(r=Fp),this.lexerDefinition=e,this.lexerDefinitionErrors=[],this.lexerDefinitionWarning=[],this.patternIdxToConfig={},this.charCodeToPatternIdxToConfig={},this.modes=[],this.emptyGroups={},this.config=void 0,this.trackStartLines=!0,this.trackEndLines=!0,this.hasCustom=!1,this.canModeBeOptimized={},typeof r=="boolean")throw Error(`The second argument to the Lexer constructor is now an ILexerConfig Object.
a boolean 2nd argument is no longer supported`);this.config=(0,lr.merge)(Fp,r);var n=this.config.traceInitPerf;n===!0?(this.traceInitMaxIdent=Infinity,this.traceInitPerf=!0):typeof n=="number"&&(this.traceInitMaxIdent=n,this.traceInitPerf=!0),this.traceInitIndent=-1,this.TRACE_INIT("Lexer Constructor",function(){var s,o=!0;i.TRACE_INIT("Lexer Config handling",function(){if(i.config.lineTerminatorsPattern===Fp.lineTerminatorsPattern)i.config.lineTerminatorsPattern=oo.LineTerminatorOptimizedTester;else if(i.config.lineTerminatorCharacters===Fp.lineTerminatorCharacters)throw Error(`Error: Missing <lineTerminatorCharacters> property on the Lexer config.
For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#MISSING_LINE_TERM_CHARS`);if(r.safeMode&&r.ensureOptimizations)throw Error('"safeMode" and "ensureOptimizations" flags are mutually exclusive.');i.trackStartLines=/full|onlyStart/i.test(i.config.positionTracking),i.trackEndLines=/full/i.test(i.config.positionTracking),(0,lr.isArray)(e)?(s={modes:{}},s.modes[oo.DEFAULT_MODE]=(0,lr.cloneArr)(e),s[oo.DEFAULT_MODE]=oo.DEFAULT_MODE):(o=!1,s=(0,lr.cloneObj)(e))}),i.config.skipValidations===!1&&(i.TRACE_INIT("performRuntimeChecks",function(){i.lexerDefinitionErrors=i.lexerDefinitionErrors.concat((0,oo.performRuntimeChecks)(s,i.trackStartLines,i.config.lineTerminatorCharacters))}),i.TRACE_INIT("performWarningRuntimeChecks",function(){i.lexerDefinitionWarning=i.lexerDefinitionWarning.concat((0,oo.performWarningRuntimeChecks)(s,i.trackStartLines,i.config.lineTerminatorCharacters))})),s.modes=s.modes?s.modes:{},(0,lr.forEach)(s.modes,function(u,g){s.modes[g]=(0,lr.reject)(u,function(f){return(0,lr.isUndefined)(f)})});var a=(0,lr.keys)(s.modes);if((0,lr.forEach)(s.modes,function(u,g){i.TRACE_INIT("Mode: <"+g+"> processing",function(){if(i.modes.push(g),i.config.skipValidations===!1&&i.TRACE_INIT("validatePatterns",function(){i.lexerDefinitionErrors=i.lexerDefinitionErrors.concat((0,oo.validatePatterns)(u,a))}),(0,lr.isEmpty)(i.lexerDefinitionErrors)){(0,yIe.augmentTokenTypes)(u);var f;i.TRACE_INIT("analyzeTokenTypes",function(){f=(0,oo.analyzeTokenTypes)(u,{lineTerminatorCharacters:i.config.lineTerminatorCharacters,positionTracking:r.positionTracking,ensureOptimizations:r.ensureOptimizations,safeMode:r.safeMode,tracer:i.TRACE_INIT.bind(i)})}),i.patternIdxToConfig[g]=f.patternIdxToConfig,i.charCodeToPatternIdxToConfig[g]=f.charCodeToPatternIdxToConfig,i.emptyGroups=(0,lr.merge)(i.emptyGroups,f.emptyGroups),i.hasCustom=f.hasCustom||i.hasCustom,i.canModeBeOptimized[g]=f.canBeOptimized}})}),i.defaultMode=s.defaultMode,!(0,lr.isEmpty)(i.lexerDefinitionErrors)&&!i.config.deferDefinitionErrorsHandling){var l=(0,lr.map)(i.lexerDefinitionErrors,function(u){return u.message}),c=l.join(`-----------------------
`);throw new Error(`Errors detected in definition of Lexer:
`+c)}(0,lr.forEach)(i.lexerDefinitionWarning,function(u){(0,lr.PRINT_WARNING)(u.message)}),i.TRACE_INIT("Choosing sub-methods implementations",function(){if(oo.SUPPORT_STICKY?(i.chopInput=lr.IDENTITY,i.match=i.matchWithTest):(i.updateLastIndex=lr.NOOP,i.match=i.matchWithExec),o&&(i.handleModes=lr.NOOP),i.trackStartLines===!1&&(i.computeNewColumn=lr.IDENTITY),i.trackEndLines===!1&&(i.updateTokenEndLineColumnLocation=lr.NOOP),/full/i.test(i.config.positionTracking))i.createTokenInstance=i.createFullToken;else if(/onlyStart/i.test(i.config.positionTracking))i.createTokenInstance=i.createStartOnlyToken;else if(/onlyOffset/i.test(i.config.positionTracking))i.createTokenInstance=i.createOffsetOnlyToken;else throw Error('Invalid <positionTracking> config option: "'+i.config.positionTracking+'"');i.hasCustom?(i.addToken=i.addTokenUsingPush,i.handlePayload=i.handlePayloadWithCustom):(i.addToken=i.addTokenUsingMemberAccess,i.handlePayload=i.handlePayloadNoCustom)}),i.TRACE_INIT("Failed Optimization Warnings",function(){var u=(0,lr.reduce)(i.canModeBeOptimized,function(g,f,h){return f===!1&&g.push(h),g},[]);if(r.ensureOptimizations&&!(0,lr.isEmpty)(u))throw Error("Lexer Modes: < "+u.join(", ")+` > cannot be optimized.
Disable the "ensureOptimizations" lexer config flag to silently ignore this and run the lexer in an un-optimized mode.
Or inspect the console log for details on how to resolve these issues.`)}),i.TRACE_INIT("clearRegExpParserCache",function(){(0,BIe.clearRegExpParserCache)()}),i.TRACE_INIT("toFastProperties",function(){(0,lr.toFastProperties)(i)})})}return t.prototype.tokenize=function(e,r){if(r===void 0&&(r=this.defaultMode),!(0,lr.isEmpty)(this.lexerDefinitionErrors)){var i=(0,lr.map)(this.lexerDefinitionErrors,function(o){return o.message}),n=i.join(`-----------------------
`);throw new Error(`Unable to Tokenize because Errors detected in definition of Lexer:
`+n)}var s=this.tokenizeInternal(e,r);return s},t.prototype.tokenizeInternal=function(e,r){var i=this,n,s,o,a,l,c,u,g,f,h,p,m,y,b,S,k,T=e,Y=T.length,j=0,Z=0,J=this.hasCustom?0:Math.floor(e.length/10),re=new Array(J),ee=[],A=this.trackStartLines?1:void 0,oe=this.trackStartLines?1:void 0,le=(0,oo.cloneEmptyGroups)(this.emptyGroups),X=this.trackStartLines,O=this.config.lineTerminatorsPattern,L=0,pe=[],Ce=[],Oe=[],te=[];Object.freeze(te);var se=void 0;function be(){return pe}function he(vr){var Gn=(0,oo.charCodeToOptimizedIndex)(vr),gs=Ce[Gn];return gs===void 0?te:gs}var Fe=function(vr){if(Oe.length===1&&vr.tokenType.PUSH_MODE===void 0){var Gn=i.config.errorMessageProvider.buildUnableToPopLexerModeMessage(vr);ee.push({offset:vr.startOffset,line:vr.startLine!==void 0?vr.startLine:void 0,column:vr.startColumn!==void 0?vr.startColumn:void 0,length:vr.image.length,message:Gn})}else{Oe.pop();var gs=(0,lr.last)(Oe);pe=i.patternIdxToConfig[gs],Ce=i.charCodeToPatternIdxToConfig[gs],L=pe.length;var ya=i.canModeBeOptimized[gs]&&i.config.safeMode===!1;Ce&&ya?se=he:se=be}};function Ue(vr){Oe.push(vr),Ce=this.charCodeToPatternIdxToConfig[vr],pe=this.patternIdxToConfig[vr],L=pe.length,L=pe.length;var Gn=this.canModeBeOptimized[vr]&&this.config.safeMode===!1;Ce&&Gn?se=he:se=be}Ue.call(this,r);for(var xe;j<Y;){c=null;var Se=T.charCodeAt(j),de=se(Se),V=de.length;for(n=0;n<V;n++){xe=de[n];var Qe=xe.pattern;u=null;var ce=xe.short;if(ce!==!1?Se===ce&&(c=Qe):xe.isCustom===!0?(k=Qe.exec(T,j,re,le),k!==null?(c=k[0],k.payload!==void 0&&(u=k.payload)):c=null):(this.updateLastIndex(Qe,j),c=this.match(Qe,e,j)),c!==null){if(l=xe.longerAlt,l!==void 0){var fe=l.length;for(o=0;o<fe;o++){var gt=pe[l[o]],Ht=gt.pattern;if(g=null,gt.isCustom===!0?(k=Ht.exec(T,j,re,le),k!==null?(a=k[0],k.payload!==void 0&&(g=k.payload)):a=null):(this.updateLastIndex(Ht,j),a=this.match(Ht,e,j)),a&&a.length>c.length){c=a,u=g,xe=gt;break}}}break}}if(c!==null){if(f=c.length,h=xe.group,h!==void 0&&(p=xe.tokenTypeIdx,m=this.createTokenInstance(c,j,p,xe.tokenType,A,oe,f),this.handlePayload(m,u),h===!1?Z=this.addToken(re,Z,m):le[h].push(m)),e=this.chopInput(e,f),j=j+f,oe=this.computeNewColumn(oe,f),X===!0&&xe.canLineTerminator===!0){var Mt=0,mi=void 0,Gt=void 0;O.lastIndex=0;do mi=O.test(c),mi===!0&&(Gt=O.lastIndex-1,Mt++);while(mi===!0);Mt!==0&&(A=A+Mt,oe=f-Gt,this.updateTokenEndLineColumnLocation(m,h,Gt,Mt,A,oe,f))}this.handleModes(xe,Fe,Ue,m)}else{for(var Qr=j,Ti=A,Vs=oe,Un=!1;!Un&&j<Y;)for(b=T.charCodeAt(j),e=this.chopInput(e,1),j++,s=0;s<L;s++){var Hn=pe[s],Qe=Hn.pattern,ce=Hn.short;if(ce!==!1?T.charCodeAt(j)===ce&&(Un=!0):Hn.isCustom===!0?Un=Qe.exec(T,j,re,le)!==null:(this.updateLastIndex(Qe,j),Un=Qe.exec(e)!==null),Un===!0)break}y=j-Qr,S=this.config.errorMessageProvider.buildUnexpectedCharactersMessage(T,Qr,y,Ti,Vs),ee.push({offset:Qr,line:Ti,column:Vs,length:y,message:S})}}return this.hasCustom||(re.length=Z),{tokens:re,groups:le,errors:ee}},t.prototype.handleModes=function(e,r,i,n){if(e.pop===!0){var s=e.push;r(n),s!==void 0&&i.call(this,s)}else e.push!==void 0&&i.call(this,e.push)},t.prototype.chopInput=function(e,r){return e.substring(r)},t.prototype.updateLastIndex=function(e,r){e.lastIndex=r},t.prototype.updateTokenEndLineColumnLocation=function(e,r,i,n,s,o,a){var l,c;r!==void 0&&(l=i===a-1,c=l?-1:0,n===1&&l===!0||(e.endLine=s+c,e.endColumn=o-1+-c))},t.prototype.computeNewColumn=function(e,r){return e+r},t.prototype.createTokenInstance=function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];return null},t.prototype.createOffsetOnlyToken=function(e,r,i,n){return{image:e,startOffset:r,tokenTypeIdx:i,tokenType:n}},t.prototype.createStartOnlyToken=function(e,r,i,n,s,o){return{image:e,startOffset:r,startLine:s,startColumn:o,tokenTypeIdx:i,tokenType:n}},t.prototype.createFullToken=function(e,r,i,n,s,o,a){return{image:e,startOffset:r,endOffset:r+a-1,startLine:s,endLine:s,startColumn:o,endColumn:o+a-1,tokenTypeIdx:i,tokenType:n}},t.prototype.addToken=function(e,r,i){return 666},t.prototype.addTokenUsingPush=function(e,r,i){return e.push(i),r},t.prototype.addTokenUsingMemberAccess=function(e,r,i){return e[r]=i,r++,r},t.prototype.handlePayload=function(e,r){},t.prototype.handlePayloadNoCustom=function(e,r){},t.prototype.handlePayloadWithCustom=function(e,r){r!==null&&(e.payload=r)},t.prototype.match=function(e,r,i){return null},t.prototype.matchWithTest=function(e,r,i){var n=e.test(r);return n===!0?r.substring(i,e.lastIndex):null},t.prototype.matchWithExec=function(e,r){var i=e.exec(r);return i!==null?i[0]:i},t.prototype.TRACE_INIT=function(e,r){if(this.traceInitPerf===!0){this.traceInitIndent++;var i=new Array(this.traceInitIndent+1).join(" ");this.traceInitIndent<this.traceInitMaxIdent&&console.log(i+"--> <"+e+">");var n=(0,lr.timer)(r),s=n.time,o=n.value,a=s>10?console.warn:console.log;return this.traceInitIndent<this.traceInitMaxIdent&&a(i+"<-- <"+e+"> time: "+s+"ms"),this.traceInitIndent--,o}else return r()},t.SKIPPED="This marks a skipped Token pat Line truncated
See: https://github.com/chevrotain/chevrotain/issues/564#issuecomment-349062346 for details.`;return(0,ao.has)(t,bG)&&(r.CATEGORIES=t[bG]),(0,jv.augmentTokenTypes)([r]),(0,ao.has)(t,QG)&&(r.LABEL=t[QG]),(0,ao.has)(t,vG)&&(r.GROUP=t[vG]),(0,ao.has)(t,kG)&&(r.POP_MODE=t[kG]),(0,ao.has)(t,SG)&&(r.PUSH_MODE=t[SG]),(0,ao.has)(t,xG)&&(r.LONGER_ALT=t[xG]),(0,ao.has)(t,PG)&&(r.LINE_BREAKS=t[PG]),(0,ao.has)(t,DG)&&(r.START_CHARS_HINT=t[DG]),r}xi.EOF=RG({name:"EOF",pattern:vIe.Lexer.NA});(0,jv.augmentTokenTypes)([xi.EOF]);function DIe(t,e,r,i,n,s,o,a){return{image:e,startOffset:r,endOffset:i,startLine:n,endLine:s,startColumn:o,endColumn:a,tokenTypeIdx:t.tokenTypeIdx,tokenType:t}}xi.createTokenInstance=DIe;function RIe(t,e){return(0,jv.tokenStructuredMatcher)(t,e)}xi.tokenMatcher=RIe});var bn=w(Vt=>{"use strict";var Ua=Vt&&Vt.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(Vt,"__esModule",{value:!0});Vt.serializeProduction=Vt.serializeGrammar=Vt.Terminal=Vt.Alternation=Vt.RepetitionWithSeparator=Vt.Repetition=Vt.RepetitionMandatoryWithSeparator=Vt.RepetitionMandatory=Vt.Option=Vt.Alternative=Vt.Rule=Vt.NonTerminal=Vt.AbstractProduction=void 0;var fr=Yt(),FIe=WA(),To=function(){function t(e){this._definition=e}return Object.defineProperty(t.prototype,"definition",{get:function(){return this._definition},set:function(e){this._definition=e},enumerable:!1,configurable:!0}),t.prototype.accept=function(e){e.visit(this),(0,fr.forEach)(this.definition,function(r){r.accept(e)})},t}();Vt.AbstractProduction=To;var FG=function(t){Ua(e,t);function e(r){var i=t.call(this,[])||this;return i.idx=1,(0,fr.assign)(i,(0,fr.pick)(r,function(n){return n!==void 0})),i}return Object.defineProperty(e.prototype,"definition",{get:function(){return this.referencedRule!==void 0?this.referencedRule.definition:[]},set:function(r){},enumerable:!1,configurable:!0}),e.prototype.accept=function(r){r.visit(this)},e}(To);Vt.NonTerminal=FG;var NG=function(t){Ua(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.orgText="",(0,fr.assign)(i,(0,fr.pick)(r,function(n){return n!==void 0})),i}return e}(To);Vt.Rule=NG;var LG=function(t){Ua(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.ignoreAmbiguities=!1,(0,fr.assign)(i,(0,fr.pick)(r,function(n){return n!==void 0})),i}return e}(To);Vt.Alternative=LG;var TG=function(t){Ua(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.idx=1,(0,fr.assign)(i,(0,fr.pick)(r,function(n){return n!==void 0})),i}return e}(To);Vt.Option=TG;var OG=function(t){Ua(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.idx=1,(0,fr.assign)(i,(0,fr.pick)(r,function(n){return n!==void 0})),i}return e}(To);Vt.RepetitionMandatory=OG;var MG=function(t){Ua(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.idx=1,(0,fr.assign)(i,(0,fr.pick)(r,function(n){return n!==void 0})),i}return e}(To);Vt.RepetitionMandatoryWithSeparator=MG;var KG=function(t){Ua(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.idx=1,(0,fr.assign)(i,(0,fr.pick)(r,function(n){return n!==void 0})),i}return e}(To);Vt.Repetition=KG;var UG=function(t){Ua(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.idx=1,(0,fr.assign)(i,(0,fr.pick)(r,function(n){return n!==void 0})),i}return e}(To);Vt.RepetitionWithSeparator=UG;var HG=function(t){Ua(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.idx=1,i.ignoreAmbiguities=!1,i.hasPredicates=!1,(0,fr.assign)(i,(0,fr.pick)(r,function(n){return n!==void 0})),i}return Object.defineProperty(e.prototype,"definition",{get:function(){return this._definition},set:function(r){this._definition=r},enumerable:!1,configurable:!0}),e}(To);Vt.Alternation=HG;var WI=function(){function t(e){this.idx=1,(0,fr.assign)(this,(0,fr.pick)(e,function(r){return r!==void 0}))}return t.prototype.accept=function(e){e.visit(this)},t}();Vt.Terminal=WI;function NIe(t){return(0,fr.map)(t,Np)}Vt.serializeGrammar=NIe;function Np(t){function e(s){return(0,fr.map)(s,Np)}if(t instanceof FG){var r={type:"NonTerminal",name:t.nonTerminalName,idx:t.idx};return(0,fr.isString)(t.label)&&(r.label=t.label),r}else{if(t instanceof LG)return{type:"Alternative",definition:e(t.definition)};if(t instanceof TG)return{type:"Option",idx:t.idx,definition:e(t.definition)};if(t instanceof OG)return{type:"RepetitionMandatory",idx:t.idx,definition:e(t.definition)};if(t instanceof MG)return{type:"RepetitionMandatoryWithSeparator",idx:t.idx,separator:Np(new WI({terminalType:t.separator})),definition:e(t.definition)};if(t instanceo Line truncated
but found: '`+a+"'";if(n)return o+n+l;var c=(0,Ao.reduce)(e,function(h,p){return h.concat(p)},[]),u=(0,Ao.map)(c,function(h){return"["+(0,Ao.map)(h,function(p){return(0,Cg.tokenLabel)(p)}).join(", ")+"]"}),g=(0,Ao.map)(u,function(h,p){return" "+(p+1)+". "+h}),f=`one of these possible Token sequences:
`+g.join(`
`);return o+f+l},buildEarlyExitMessage:function(t){var e=t.expectedIterationPaths,r=t.actual,i=t.customUserDescription,n=t.ruleName,s="Expecting: ",o=(0,Ao.first)(r).image,a=`
but found: '`+o+"'";if(i)return s+i+a;var l=(0,Ao.map)(e,function(u){return"["+(0,Ao.map)(u,function(g){return(0,Cg.tokenLabel)(g)}).join(",")+"]"}),c=`expecting at least one iteration which starts with one of these possible Token sequences::
`+("<"+l.join(" ,")+">");return s+c+a}};Object.freeze(Ha.defaultParserErrorProvider);Ha.defaultGrammarResolverErrorProvider={buildRuleNotFoundError:function(t,e){var r="Invalid grammar, reference to a rule which is not defined: ->"+e.nonTerminalName+`<-
inside top level rule: ->`+t.name+"<-";return r}};Ha.defaultGrammarValidatorErrorProvider={buildDuplicateFoundError:function(t,e){function r(u){return u instanceof _v.Terminal?u.terminalType.name:u instanceof _v.NonTerminal?u.nonTerminalName:""}var i=t.name,n=(0,Ao.first)(e),s=n.idx,o=(0,$G.getProductionDslName)(n),a=r(n),l=s>0,c="->"+o+(l?s:"")+"<- "+(a?"with argument: ->"+a+"<-":"")+`
appears more than once (`+e.length+" times) in the top level rule: ->"+i+`<-.
For further details see: https://chevrotain.io/docs/FAQ.html#NUMERICAL_SUFFIXES
`;return c=c.replace(/[ \t]+/g," "),c=c.replace(/\s\s+/g,`
`),c},buildNamespaceConflictError:function(t){var e=`Namespace conflict found in grammar.
`+("The grammar has both a Terminal(Token) and a Non-Terminal(Rule) named: <"+t.name+`>.
`)+`To resolve this make sure each Terminal and Non-Terminal names are unique
This is easy to accomplish by using the convention that Terminal names start with an uppercase letter
and Non-Terminal names start with a lower case letter.`;return e},buildAlternationPrefixAmbiguityError:function(t){var e=(0,Ao.map)(t.prefixPath,function(n){return(0,Cg.tokenLabel)(n)}).join(", "),r=t.alternation.idx===0?"":t.alternation.idx,i="Ambiguous alternatives: <"+t.ambiguityIndices.join(" ,")+`> due to common lookahead prefix
`+("in <OR"+r+"> inside <"+t.topLevelRule.name+`> Rule,
`)+("<"+e+`> may appears as a prefix path in all these alternatives.
`)+`See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#COMMON_PREFIX
For Further details.`;return i},buildAlternationAmbiguityError:function(t){var e=(0,Ao.map)(t.prefixPath,function(n){return(0,Cg.tokenLabel)(n)}).join(", "),r=t.alternation.idx===0?"":t.alternation.idx,i="Ambiguous Alternatives Detected: <"+t.ambiguityIndices.join(" ,")+"> in <OR"+r+">"+(" inside <"+t.topLevelRule.name+`> Rule,
`)+("<"+e+`> may appears as a prefix path in all these alternatives.
`);return i=i+`See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#AMBIGUOUS_ALTERNATIVES
For Further details.`,i},buildEmptyRepetitionError:function(t){var e=(0,$G.getProductionDslName)(t.repetition);t.repetition.idx!==0&&(e+=t.repetition.idx);var r="The repetition <"+e+"> within Rule <"+t.topLevelRule.name+`> can never consume any tokens.
This could lead to an infinite loop.`;return r},buildTokenNameError:function(t){return"deprecated"},buildEmptyAlternationError:function(t){var e="Ambiguous empty alternative: <"+(t.emptyChoiceIdx+1)+">"+(" in <OR"+t.alternation.idx+"> inside <"+t.topLevelRule.name+`> Rule.
`)+"Only the last alternative may be an empty alternative.";return e},buildTooManyAlternativesError:function(t){var e=`An Alternation cannot have more than 256 alternatives:
`+("<OR"+t.alternation.idx+"> inside <"+t.topLevelRule.name+`> Rule.
has `+(t.alternation.definition.length+1)+" alternatives.");return e},buildLeftRecursionError:function(t){var e=t.topLevelRule.name,r=_Ie.map(t.leftRecursionPath,function(s){return s.name}),i=e+" --> "+r.concat([e]).join(" --> "),n=`Left Recursion found in grammar.
`+("rule: <"+e+`> can be invoked from itself (directly or indirectly)
`)+(`without consuming any Tokens. The grammar path that causes this is:
`+i+`
`)+` To fix this refactor your grammar to remove the left recursion.
see: https://en.wikipedia.org/wiki/LL_parser#Left_Factoring.`;return n},buildInvalidRuleNameError:function(t){return"deprecated"},buildDuplicateRuleNameError:function(t){var e;t.topLevelRule instanceof _v.Rule?e=t.topLevelRule.name:e=t.topLevelRule;var r="Duplicate definition, rule: ->"+e+"<- is already defined in the grammar: ->"+t.grammarName+"<-";return r}}});var rj=w(zA=>{"use strict";var VIe=zA&&zA.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(zA,"__esModule",{value:!0});zA.GastRefResolverVisitor=zA.resolveGrammar=void 0;var XIe=Zn(),ej=Yt(),ZIe=dg();function $Ie(t,e){var r=new tj(t,e);return r.resolveRefs(),r.errors}zA.resolveGrammar=$Ie;var tj=function(t){VIe(e,t);function e(r,i){var n=t.call(this)||this;return n.nameToTopRule=r,n.errMsgProvider=i,n.errors=[],n}return e.prototype.resolveRefs=function(){var r=this;(0,ej.forEach)((0,ej.values)(this.nameToTopRule),function(i){r.currTopLevel=i,i.accept(r)})},e.prototype.visitNonTerminal=function(r){var i=this.nameToTopRule[r.nonTerminalName];if(i)r.referencedRule=i;else{var n=this.errMsgProvider.buildRuleNotFoundError(this.currTopLevel,r);this.errors.push({message:n,type:XIe.ParserDefinitionErrorType.UNRESOLVED_SUBRULE_REF,ruleName:this.currTopLevel.name,unresolvedRefName:r.nonTerminalName})}},e}(ZIe.GAstVisitor);zA.GastRefResolverVisitor=tj});var Kp=w(Mr=>{"use strict";var Qc=Mr&&Mr.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(Mr,"__esModule",{value:!0});Mr.nextPossibleTokensAfter=Mr.possiblePathsFrom=Mr.NextTerminalAfterAtLeastOneSepWalker=Mr.NextTerminalAfterAtLeastOneWalker=Mr.NextTerminalAfterManySepWalker=Mr.NextTerminalAfterManyWalker=Mr.AbstractNextTerminalAfterProductionWalker=Mr.NextAfterTokenWalker=Mr.AbstractNextPossibleTokensWalker=void 0;var ij=_I(),Kt=Yt(),eye=Wv(),Dt=bn(),nj=function(t){Qc(e,t);function e(r,i){var n=t.call(this)||this;return n.topProd=r,n.path=i,n.possibleTokTypes=[],n.nextProductionName="",n.nextProductionOccurrence=0,n.found=!1,n.isAtEndOfPath=!1,n}return e.prototype.startWalking=function(){if(this.found=!1,this.path.ruleStack[0]!==this.topProd.name)throw Error("The path does not start with the walker's top Rule!");return this.ruleStack=(0,Kt.cloneArr)(this.path.ruleStack).reverse(),this.occurrenceStack=(0,Kt.cloneArr)(this.path.occurrenceStack).reverse(),this.ruleStack.pop(),this.occurrenceStack.pop(),this.updateExpectedNext(),this.walk(this.topProd),this.possibleTokTypes},e.prototype.walk=function(r,i){i===void 0&&(i=[]),this.found||t.prototype.walk.call(this,r,i)},e.prototype.walkProdRef=function(r,i,n){if(r.referencedRule.name===this.nextProductionName&&r.idx===this.nextProductionOccurrence){var s=i.concat(n);this.updateExpectedNext(),this.walk(r.referencedRule,s)}},e.prototype.updateExpectedNext=function(){(0,Kt.isEmpty)(this.ruleStack)?(this.nextProductionName="",this.nextProductionOccurrence=0,this.isAtEndOfPath=!0):(this.nextProductionName=this.ruleStack.pop(),this.nextProductionOccurrence=this.occurrenceStack.pop())},e}(ij.RestWalker);Mr.AbstractNextPossibleTokensWalker=nj;var tye=function(t){Qc(e,t);function e(r,i){var n=t.call(this,r,i)||this;return n.path=i,n.nextTerminalName="",n.nextTerminalOccurrence=0,n.nextTerminalName=n.path.lastTok.name,n.nextTerminalOccurrence=n.path.lastTokOccurrence,n}return e.prototype.walkTerminal=function(r,i,n){if(this.isAtEndOfPath&&r.terminalType.name===this.nextTerminalName&&r.idx===this.nextTerminalOccurrence&&!this.found){var s=i.concat(n),o=new Dt.Alternative({definition:s});this.possibleTokTypes=(0,eye.first)(o),this.found=!0}},e}(nj);Mr.NextAfterTokenWalker=tye;var Mp=function(t){Qc(e,t);function e(r,i){var n=t.call(this)||this;return n.topRule=r,n.occurrence=i,n.result={token:void 0,occurrence:void 0,isEndOfRule:void 0},n}return e.prototype.startWalking=function(){return this.walk(this.topRule),this.result},e}(ij.RestWalker);Mr.AbstractNextTerminalAfterProductionWalker=Mp;var rye=function(t){Qc(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.walkMany=function(r,i,n){if(r.idx===this.occurrence){var s=(0,Kt.first)(i.concat(n));this.r Line truncated
`+(""+s.join(`
`).replace(/\n/g,`
`)))}}};return r.prototype=i,r.prototype.constructor=r,r._RULE_NAMES=e,r}Pi.createBaseSemanticVisitorConstructor=Wye;function zye(t,e,r){var i=function(){};(0,jp.defineNameProp)(i,t+"BaseSemanticsWithDefaults");var n=Object.create(r.prototype);return(0,ks.forEach)(e,function(s){n[s]=Tj}),i.prototype=n,i.prototype.constructor=i,i}Pi.createBaseVisitorConstructorWithDefaults=zye;var lS;(function(t){t[t.REDUNDANT_METHOD=0]="REDUNDANT_METHOD",t[t.MISSING_METHOD=1]="MISSING_METHOD"})(lS=Pi.CstVisitorDefinitionError||(Pi.CstVisitorDefinitionError={}));function Oj(t,e){var r=Mj(t,e),i=Kj(t,e);return r.concat(i)}Pi.validateVisitor=Oj;function Mj(t,e){var r=(0,ks.map)(e,function(i){if(!(0,ks.isFunction)(t[i]))return{msg:"Missing visitor method: <"+i+"> on "+(0,jp.functionName)(t.constructor)+" CST Visitor.",type:lS.MISSING_METHOD,methodName:i}});return(0,ks.compact)(r)}Pi.validateMissingCstMethods=Mj;var _ye=["constructor","visit","validateVisitor"];function Kj(t,e){var r=[];for(var i in t)(0,ks.isFunction)(t[i])&&!(0,ks.contains)(_ye,i)&&!(0,ks.contains)(e,i)&&r.push({msg:"Redundant visitor method: <"+i+"> on "+(0,jp.functionName)(t.constructor)+` CST Visitor
There is no Grammar Rule corresponding to this method's name.
`,type:lS.REDUNDANT_METHOD,methodName:i});return r}Pi.validateRedundantMethods=Kj});var Gj=w(oy=>{"use strict";Object.defineProperty(oy,"__esModule",{value:!0});oy.TreeBuilder=void 0;var yg=Fj(),ni=Yt(),Hj=Uj(),Vye=Zn(),Xye=function(){function t(){}return t.prototype.initTreeBuilder=function(e){if(this.CST_STACK=[],this.outputCst=e.outputCst,this.nodeLocationTracking=(0,ni.has)(e,"nodeLocationTracking")?e.nodeLocationTracking:Vye.DEFAULT_PARSER_CONFIG.nodeLocationTracking,!this.outputCst)this.cstInvocationStateUpdate=ni.NOOP,this.cstFinallyStateUpdate=ni.NOOP,this.cstPostTerminal=ni.NOOP,this.cstPostNonTerminal=ni.NOOP,this.cstPostRule=ni.NOOP;else if(/full/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=yg.setNodeLocationFull,this.setNodeLocationFromNode=yg.setNodeLocationFull,this.cstPostRule=ni.NOOP,this.setInitialNodeLocation=this.setInitialNodeLocationFullRecovery):(this.setNodeLocationFromToken=ni.NOOP,this.setNodeLocationFromNode=ni.NOOP,this.cstPostRule=this.cstPostRuleFull,this.setInitialNodeLocation=this.setInitialNodeLocationFullRegular);else if(/onlyOffset/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=yg.setNodeLocationOnlyOffset,this.setNodeLocationFromNode=yg.setNodeLocationOnlyOffset,this.cstPostRule=ni.NOOP,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRecovery):(this.setNodeLocationFromToken=ni.NOOP,this.setNodeLocationFromNode=ni.NOOP,this.cstPostRule=this.cstPostRuleOnlyOffset,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRegular);else if(/none/i.test(this.nodeLocationTracking))this.setNodeLocationFromToken=ni.NOOP,this.setNodeLocationFromNode=ni.NOOP,this.cstPostRule=ni.NOOP,this.setInitialNodeLocation=ni.NOOP;else throw Error('Invalid <nodeLocationTracking> config option: "'+e.nodeLocationTracking+'"')},t.prototype.setInitialNodeLocationOnlyOffsetRecovery=function(e){e.location={startOffset:NaN,endOffset:NaN}},t.prototype.setInitialNodeLocationOnlyOffsetRegular=function(e){e.location={startOffset:this.LA(1).startOffset,endOffset:NaN}},t.prototype.setInitialNodeLocationFullRecovery=function(e){e.location={startOffset:NaN,startLine:NaN,startColumn:NaN,endOffset:NaN,endLine:NaN,endColumn:NaN}},t.prototype.setInitialNodeLocationFullRegular=function(e){var r=this.LA(1);e.location={startOffset:r.startOffset,startLine:r.startLine,startColumn:r.startColumn,endOffset:NaN,endLine:NaN,endColumn:NaN}},t.prototype.cstInvocationStateUpdate=function(e,r){var i={name:e,children:{}};this.setInitialNodeLocation(i),this.CST_STACK.push(i)},t.prototype.cstFinallyStateUpdate=function(){this.CST_STACK.pop()},t.prototype.cstPostRuleFull=function(e){var r=this.LA(0),i=e.location;i.startOffset<=r.startOffset?(i.endOffset=r.endOffset,i.endLine=r.endLine,i.endColumn=r.endColumn):(i.startOffset=NaN,i.startLine=NaN,i.startColumn=NaN)},t.prototype.cstPostRuleOnlyOffset=function(e){var r=this.LA(0),i=e.location;i.startOffset<=r.startOffset?i.endOffset=r.endOffset:i.startOffset=NaN},t.prototype.cstPostTerminal=function(e,r){var i=this.CST_STACK[this.CST_STACK.length-1];(0,yg.addTerminalToCst)(i,r,e),this.setNodeLocationFromToken(i.location,r)},t.prototype.cstPostNonTerminal=function(e,r){var i=this.CST_STACK[this.CST_STACK.length-1];(0,yg.addNoneTerminalToCst)(i,r,e),this.setNodeLocationFromNode(i.location,e.location)},t.prototype.getBaseCstVisitorConstructor=function(){if((0,ni.isUndefined)(this.baseCstVisitorConstructor)){var e=(0,Hj.createBaseSemanticVisitorConstructor)(this.className,(0,ni.keys)(this.gastProductionsCache));return this.baseCstVisitorConstructor=e,e}return this.baseCstVisitorConstructor},t.prototype.getBaseCstVisitorConstructorWithDefaults=function(){if((0,ni.isUndefined)(this.baseCstVisitorWithDefaultsConstructor)){var e=(0,Hj.createBaseVisitorConstructorWithDefaults)(this.className,(0,ni.keys)(this.gastProductionsCache),this.getBaseCstVisitorConstructor());return this.baseCstVisitorWithDefaultsConstructor=e,e}return this.baseCstVisitorWithDefaultsConstructor},t.prototype.getLastExplicitRuleShortName=function(){var e=this.RULE_STACK;return e[e.length-1]},t.prototype.getPreviousExplicitRuleShortName=function(){var e=this.RULE_STACK;return e[e.length-2]},t.prototype.getLastExplicitRuleOccurrenceIndex=function(){var e=this.RULE_OCCURRENCE_STACK;return e[e.length-1]},t}();oy.TreeBuilder=Xye});var Yj=w(ay=>{"use strict";Object.defineProperty(ay,"__esModule",{value:!0});ay.LexerAdapter=void 0;var jj=Zn(),Zye=function(){function t(){}return t.prototype.initLexerAdapter=function(){this.tokVector=[],this.tokVectorLength=0,this.currIdx=-1},Object.defineProperty(t.prototype,"input",{get:function(){return this.tokVector},set:function(e){if(this.selfAnalysisDone!==!0)throw Error("Missing <performSelfAnalysis> invocation at the end of the Parser's constructor.");this.reset(),this.tokVector=e,this.tokVectorLength=e.length},enumerable:!1,configurable:!0}),t.prototype.SKIP_TOKEN=function(){return this Line truncated
See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_6-0-0
For Further details.`);if((0,Rr.isArray)(e)){if((0,Rr.isEmpty)(e))throw Error(`A Token Vocabulary cannot be empty.
Note that the first argument for the parser constructor
is no longer a Token vector (since v4.0).`);if(typeof e[0].startOffset=="number")throw Error(`The Parser constructor no longer accepts a token vector as the first argument.
See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_4-0-0
For Further details.`)}if((0,Rr.isArray)(e))this.tokensMap=(0,Rr.reduce)(e,function(o,a){return o[a.name]=a,o},{});else if((0,Rr.has)(e,"modes")&&(0,Rr.every)((0,Rr.flatten)((0,Rr.values)(e.modes)),Yp.isTokenType)){var i=(0,Rr.flatten)((0,Rr.values)(e.modes)),n=(0,Rr.uniq)(i);this.tokensMap=(0,Rr.reduce)(n,function(o,a){return o[a.name]=a,o},{})}else if((0,Rr.isObject)(e))this.tokensMap=(0,Rr.cloneObj)(e);else throw new Error("<tokensDictionary> argument must be An Array of Token constructors, A dictionary of Token constructors or an IMultiModeLexerDefinition");this.tokensMap.EOF=_j.EOF;var s=(0,Rr.every)((0,Rr.values)(e),function(o){return(0,Rr.isEmpty)(o.categoryMatches)});this.tokenMatcher=s?Yp.tokenStructuredMatcherNoCategories:Yp.tokenStructuredMatcher,(0,Yp.augmentTokenTypes)((0,Rr.values)(this.tokensMap))},t.prototype.defineRule=function(e,r,i){if(this.selfAnalysisDone)throw Error("Grammar rule <"+e+`> may not be defined after the 'performSelfAnalysis' method has been called'
Make sure that all grammar rule definitions are done before 'performSelfAnalysis' is called.`);var n=(0,Rr.has)(i,"resyncEnabled")?i.resyncEnabled:zj.DEFAULT_RULE_CONFIG.resyncEnabled,s=(0,Rr.has)(i,"recoveryValueFunc")?i.recoveryValueFunc:zj.DEFAULT_RULE_CONFIG.recoveryValueFunc,o=this.ruleShortNameIdx<<$n.BITS_FOR_METHOD_TYPE+$n.BITS_FOR_OCCURRENCE_IDX;this.ruleShortNameIdx++,this.shortRuleNameToFull[o]=e,this.fullRuleNameToShort[e]=o;function a(u){try{if(this.outputCst===!0){r.apply(this,u);var g=this.CST_STACK[this.CST_STACK.length-1];return this.cstPostRule(g),g}else return r.apply(this,u)}catch(f){return this.invokeRuleCatch(f,n,s)}finally{this.ruleFinallyStateUpdate()}}var l=function(u,g){return u===void 0&&(u=0),this.ruleInvocationStateUpdate(o,e,u),a.call(this,g)},c="ruleName";return l[c]=e,l.originalGrammarAction=r,l},t.prototype.invokeRuleCatch=function(e,r,i){var n=this.RULE_STACK.length===1,s=r&&!this.isBackTracking()&&this.recoveryEnabled;if((0,cy.isRecognitionException)(e)){var o=e;if(s){var a=this.findReSyncTokenType();if(this.isInCurrentRuleReSyncSet(a))if(o.resyncedTokens=this.reSyncTo(a),this.outputCst){var l=this.CST_STACK[this.CST_STACK.length-1];return l.recoveredNode=!0,l}else return i();else{if(this.outputCst){var l=this.CST_STACK[this.CST_STACK.length-1];l.recoveredNode=!0,o.partialCstResult=l}throw o}}else{if(n)return this.moveToTerminatedState(),i();throw o}}else throw e},t.prototype.optionInternal=function(e,r){var i=this.getKeyForAutomaticLookahead($n.OPTION_IDX,r);return this.optionInternalLogic(e,r,i)},t.prototype.optionInternalLogic=function(e,r,i){var n=this,s=this.getLaFuncFromCache(i),o,a;if(e.DEF!==void 0){if(o=e.DEF,a=e.GATE,a!==void 0){var l=s;s=function(){return a.call(n)&&l.call(n)}}}else o=e;if(s.call(this)===!0)return o.call(this)},t.prototype.atLeastOneInternal=function(e,r){var i=this.getKeyForAutomaticLookahead($n.AT_LEAST_ONE_IDX,e);return this.atLeastOneInternalLogic(e,r,i)},t.prototype.atLeastOneInternalLogic=function(e,r,i){var n=this,s=this.getLaFuncFromCache(i),o,a;if(r.DEF!==void 0){if(o=r.DEF,a=r.GATE,a!==void 0){var l=s;s=function(){return a.call(n)&&l.call(n)}}}else o=r;if(s.call(this)===!0)for(var c=this.doSingleRepetition(o);s.call(this)===!0&&c===!0;)c=this.doSingleRepetition(o);else throw this.raiseEarlyExitException(e,Wj.PROD_TYPE.REPETITION_MANDATORY,r.ERR_MSG);this.attemptInRepetitionRecovery(this.atLeastOneInternal,[e,r],s,$n.AT_LEAST_ONE_IDX,e,wg.NextTerminalAfterAtLeastOneWalker)},t.prototype.atLeastOneSepFirstInternal=function(e,r){var i=this.getKeyForAutomaticLookahead($n.AT_LEAST_ONE_SEP_IDX,e);this.atLeastOneSepFirstInternalLogic(e,r,i)},t.prototype.atLeastOneSepFirstInternalLogic=function(e,r,i){var n=this,s=r.DEF,o=r.SEP,a=this.getLaFuncFromCache(i);if(a.call(this)===!0){s.call(this);for(var l=function(){return n.tokenMatcher(n.LA(1),o)};this.tokenMatcher(this.LA(1),o)===!0;)this.CONSUME(o),s.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[e,o,l,s,wg.NextTerminalAfterAtLeastOneSepWalker],l,$n.AT_LEAST_ONE_SEP_IDX,e,wg.NextTerminalAfterAtLeastOneSepWalker)}else throw this.raiseEarlyExitException(e,Wj.PROD_TYPE.REPETITION_MANDATORY_WITH_SEPARATOR,r.ERR_MSG)},t.prototype.manyInternal=function(e,r){var i=this.getKeyForAutomaticLookahead($n.MANY_IDX,e);return this.manyInternalLogic(e,r,i)},t.prototype.manyInternalLogic=function(e,r,i){var n=this,s=this.getLaFuncFromCache(i),o,a;if(r.DEF!==void 0){if(o=r.DEF,a=r.GATE,a!==void 0){var l=s;s=function(){return a.call(n)&&l.call(n)}}}else o=r;for(var c=!0;s.call(this)===!0&&c===!0;)c=this.doSingleRepetition(o);this.attemptInRepetitionRecovery(this.manyInternal,[e,r],s,$n.MANY_IDX,e,wg.NextTerminalAfterManyWalker,c)},t.prototype.manySepFirstInternal=function(e,r){var i=this.getKeyForAutomaticLookahead($n.MANY_SEP_IDX,e);this.manySepFirstInternalLogic(e,r,i)},t.prototype.manySepFirstInternalLogic=function(e,r,i){var n=this,s=r.DEF,o=r.SEP,a=this.getLaFuncFromCache(i);if(a.call(this)===!0){s.call(this);for(var l=function(){return n.tokenMatcher(n.LA(1),o)};this.tokenMatcher(this.LA(1),o)===!0;)this.CONSUME(o),s.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[e,o,l,s,wg.NextTerminalAfterManySepWalker],l,$n.MANY_SEP_IDX,e,wg.NextTerminalAfterManySepWalker)}},t.prototype.repetitionSepSecondInternal=function(e,r,i,n,s){for(;i();)this.CONSUME(r),n.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[e,r,i,n,s],i,$n.AT_LEAST_ONE_SEP_IDX,e,s)},t.prototype.doSingleRepetition=function(e){var r=this.getLexerPosition();e.call(this);var i=this.getLexerPosition();return i>r},t.prototype.orInternal=function(e,r){var i=this.getKeyForAutomaticLookahead($n.OR_IDX,r),n=(0,Rr.isArray)(e)?e:e.DEF,s=this.getLaFuncFromCache(i),o=s.call(this,n);if(o!==void 0){var a=n[o];return a.ALT.call(this)}this.raiseNoAltException(r,e.ERR_MSG)},t.prototype.ruleFinallyStateUpdate=function(){if(this.RULE_STACK.pop(),this.RULE_OCCURRENCE_STACK.pop(),this. Line truncated
See: https://chevrotain.io/docs/guide/internals.html#grammar-recording for details`,-1,-1,-1,-1,-1,-1);Object.freeze(aY);var fwe={name:`This CSTNode indicates the Parser is in Recording Phase
See: https://chevrotain.io/docs/guide/internals.html#grammar-recording for details`,children:{}},pwe=function(){function t(){}return t.prototype.initGastRecorder=function(e){this.recordingProdStack=[],this.RECORDING_PHASE=!1},t.prototype.enableRecording=function(){var e=this;this.RECORDING_PHASE=!0,this.TRACE_INIT("Enable Recording",function(){for(var r=function(n){var s=n>0?n:"";e["CONSUME"+s]=function(o,a){return this.consumeInternalRecord(o,n,a)},e["SUBRULE"+s]=function(o,a){return this.subruleInternalRecord(o,n,a)},e["OPTION"+s]=function(o){return this.optionInternalRecord(o,n)},e["OR"+s]=function(o){return this.orInternalRecord(o,n)},e["MANY"+s]=function(o){this.manyInternalRecord(n,o)},e["MANY_SEP"+s]=function(o){this.manySepFirstInternalRecord(n,o)},e["AT_LEAST_ONE"+s]=function(o){this.atLeastOneInternalRecord(n,o)},e["AT_LEAST_ONE_SEP"+s]=function(o){this.atLeastOneSepFirstInternalRecord(n,o)}},i=0;i<10;i++)r(i);e.consume=function(n,s,o){return this.consumeInternalRecord(s,n,o)},e.subrule=function(n,s,o){return this.subruleInternalRecord(s,n,o)},e.option=function(n,s){return this.optionInternalRecord(s,n)},e.or=function(n,s){return this.orInternalRecord(s,n)},e.many=function(n,s){this.manyInternalRecord(n,s)},e.atLeastOne=function(n,s){this.atLeastOneInternalRecord(n,s)},e.ACTION=e.ACTION_RECORD,e.BACKTRACK=e.BACKTRACK_RECORD,e.LA=e.LA_RECORD})},t.prototype.disableRecording=function(){var e=this;this.RECORDING_PHASE=!1,this.TRACE_INIT("Deleting Recording methods",function(){for(var r=0;r<10;r++){var i=r>0?r:"";delete e["CONSUME"+i],delete e["SUBRULE"+i],delete e["OPTION"+i],delete e["OR"+i],delete e["MANY"+i],delete e["MANY_SEP"+i],delete e["AT_LEAST_ONE"+i],delete e["AT_LEAST_ONE_SEP"+i]}delete e.consume,delete e.subrule,delete e.option,delete e.or,delete e.many,delete e.atLeastOne,delete e.ACTION,delete e.BACKTRACK,delete e.LA})},t.prototype.ACTION_RECORD=function(e){},t.prototype.BACKTRACK_RECORD=function(e,r){return function(){return!0}},t.prototype.LA_RECORD=function(e){return uwe.END_OF_FILE},t.prototype.topLevelRuleRecord=function(e,r){try{var i=new Ho.Rule({definition:[],name:e});return i.name=e,this.recordingProdStack.push(i),r.call(this),this.recordingProdStack.pop(),i}catch(n){if(n.KNOWN_RECORDER_ERROR!==!0)try{n.message=n.message+`
This error was thrown during the "grammar recording phase" For more info see:
https://chevrotain.io/docs/guide/internals.html#grammar-recording`}catch(s){throw n}throw n}},t.prototype.optionInternalRecord=function(e,r){return qp.call(this,Ho.Option,e,r)},t.prototype.atLeastOneInternalRecord=function(e,r){qp.call(this,Ho.RepetitionMandatory,r,e)},t.prototype.atLeastOneSepFirstInternalRecord=function(e,r){qp.call(this,Ho.RepetitionMandatoryWithSeparator,r,e,nY)},t.prototype.manyInternalRecord=function(e,r){qp.call(this,Ho.Repetition,r,e)},t.prototype.manySepFirstInternalRecord=function(e,r){qp.call(this,Ho.RepetitionWithSeparator,r,e,nY)},t.prototype.orInternalRecord=function(e,r){return hwe.call(this,e,r)},t.prototype.subruleInternalRecord=function(e,r,i){if(py(r),!e||(0,Sn.has)(e,"ruleName")===!1){var n=new Error("<SUBRULE"+AY(r)+"> argument is invalid"+(" expecting a Parser method reference but got: <"+JSON.stringify(e)+">")+(`
inside top level rule: <`+this.recordingProdStack[0].name+">"));throw n.KNOWN_RECORDER_ERROR=!0,n}var s=(0,Sn.peek)(this.recordingProdStack),o=e.ruleName,a=new Ho.NonTerminal({idx:r,nonTerminalName:o,label:i==null?void 0:i.LABEL,referencedRule:void 0});return s.definition.push(a),this.outputCst?fwe:hy},t.prototype.consumeInternalRecord=function(e,r,i){if(py(r),!(0,rY.hasShortKeyProperty)(e)){var n=new Error("<CONSUME"+AY(r)+"> argument is invalid"+(" expecting a TokenType reference but got: <"+JSON.stringify(e)+">")+(`
inside top level rule: <`+this.recordingProdStack[0].name+">"));throw n.KNOWN_RECORDER_ERROR=!0,n}var s=(0,Sn.peek)(this.recordingProdStack),o=new Ho.Terminal({idx:r,terminalType:e,label:i==null?void 0:i.LABEL});return s.definition.push(o),aY},t}();fy.GastRecorder=pwe;function qp(t,e,r,i){i===void 0&&(i=!1),py(r);var n=(0,Sn.peek)(this.recordingProdStack),s=(0,Sn.isFunction)(e)?e:e.DEF,o=new t({definition:[],idx:r});return i&&(o.separator=e.SEP),(0,Sn.has)(e,"MAX_LOOKAHEAD")&&(o.maxLookahead=e.MAX_LOOKAHEAD),this.recordingProdStack.push(o),s.call(this),n.definition.push(o),this.recordingProdStack.pop(),hy}function hwe(t,e){var r=this;py(e);var i=(0,Sn.peek)(this.recordingProdStack),n=(0,Sn.isArray)(t)===!1,s=n===!1?t:t.DEF,o=new Ho.Alternation({definition:[],idx:e,ignoreAmbiguities:n&&t.IGNORE_AMBIGUITIES===!0});(0,Sn.has)(t,"MAX_LOOKAHEAD")&&(o.maxLookahead=t.MAX_LOOKAHEAD);var a=(0,Sn.some)(s,function(l){return(0,Sn.isFunction)(l.GATE)});return o.hasPredicates=a,i.definition.push(o),(0,Sn.forEach)(s,function(l){var c=new Ho.Alternative({definition:[]});o.definition.push(c),(0,Sn.has)(l,"IGNORE_AMBIGUITIES")?c.ignoreAmbiguities=l.IGNORE_AMBIGUITIES:(0,Sn.has)(l,"GATE")&&(c.ignoreAmbiguities=!0),r.recordingProdStack.push(c),l.ALT.call(r),r.recordingProdStack.pop()}),hy}function AY(t){return t===0?"":""+t}function py(t){if(t<0||t>sY){var e=new Error("Invalid DSL Method idx value: <"+t+`>
`+("Idx value must be a none negative value smaller than "+(sY+1)));throw e.KNOWN_RECORDER_ERROR=!0,e}}});var uY=w(dy=>{"use strict";Object.defineProperty(dy,"__esModule",{value:!0});dy.PerformanceTracer=void 0;var cY=Yt(),dwe=Zn(),Cwe=function(){function t(){}return t.prototype.initPerformanceTracer=function(e){if((0,cY.has)(e,"traceInitPerf")){var r=e.traceInitPerf,i=typeof r=="number";this.traceInitMaxIdent=i?r:Infinity,this.traceInitPerf=i?r>0:r}else this.traceInitMaxIdent=0,this.traceInitPerf=dwe.DEFAULT_PARSER_CONFIG.traceInitPerf;this.traceInitIndent=-1},t.prototype.TRACE_INIT=function(e,r){if(this.traceInitPerf===!0){this.traceInitIndent++;var i=new Array(this.traceInitIndent+1).join(" ");this.traceInitIndent<this.traceInitMaxIdent&&console.log(i+"--> <"+e+">");var n=(0,cY.timer)(r),s=n.time,o=n.value,a=s>10?console.warn:console.log;return this.traceInitIndent<this.traceInitMaxIdent&&a(i+"<-- <"+e+"> time: "+s+"ms"),this.traceInitIndent--,o}else return r()},t}();dy.PerformanceTracer=Cwe});var gY=w(Cy=>{"use strict";Object.defineProperty(Cy,"__esModule",{value:!0});Cy.applyMixins=void 0;function mwe(t,e){e.forEach(function(r){var i=r.prototype;Object.getOwnPropertyNames(i).forEach(function(n){if(n!=="constructor"){var s=Object.getOwnPropertyDescriptor(i,n);s&&(s.get||s.set)?Object.defineProperty(t.prototype,n,s):t.prototype[n]=r.prototype[n]}})})}Cy.applyMixins=mwe});var Zn=w(Er=>{"use strict";var fY=Er&&Er.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(Er,"__esModule",{value:!0});Er.EmbeddedActionsParser=Er.CstParser=Er.Parser=Er.EMPTY_ALT=Er.ParserDefinitionErrorType=Er.DEFAULT_RULE_CONFIG=Er.DEFAULT_PARSER_CONFIG=Er.END_OF_FILE=void 0;var an=Yt(),Ewe=ZG(),hY=WA(),pY=Op(),dY=bj(),Iwe=aS(),ywe=Rj(),wwe=Gj(),Bwe=Yj(),bwe=Jj(),Qwe=Vj(),vwe=Zj(),Swe=tY(),kwe=lY(),xwe=uY(),Pwe=gY();Er.END_OF_FILE=(0,hY.createTokenInstance)(hY.EOF,"",NaN,NaN,NaN,NaN,NaN,NaN);Object.freeze(Er.END_OF_FILE);Er.DEFAULT_PARSER_CONFIG=Object.freeze({recoveryEnabled:!1,maxLookahead:3,dynamicTokensEnabled:!1,outputCst:!0,errorMessageProvider:pY.defaultParserErrorProvider,nodeLocationTracking:"none",traceInitPerf:!1,skipValidations:!1});Er.DEFAULT_RULE_CONFIG=Object.freeze({recoveryValueFunc:function(){},resyncEnabled:!0});var Dwe;(function(t){t[t.INVALID_RULE_NAME=0]="INVALID_RULE_NAME",t[t.DUPLICATE_RULE_NAME=1]="DUPLICATE_RULE_NAME",t[t.INVALID_RULE_OVERRIDE=2]="INVALID_RULE_OVERRIDE",t[t.DUPLICATE_PRODUCTIONS=3]="DUPLICATE_PRODUCTIONS",t[t.UNRESOLVED_SUBRULE_REF=4]="UNRESOLVED_SUBRULE_REF",t[t.LEFT_RECURSION=5]="LEFT_RECURSION",t[t.NONE_LAST_EMPTY_ALT=6]="NONE_LAST_EMPTY_ALT",t[t.AMBIGUOUS_ALTS=7]="AMBIGUOUS_ALTS",t[t.CONFLICT_TOKENS_RULES_NAMESPACE=8]="CONFLICT_TOKENS_RULES_NAMESPACE",t[t.INVALID_TOKEN_NAME=9]="INVALID_TOKEN_NAME",t[t.NO_NON_EMPTY_LOOKAHEAD=10]="NO_NON_EMPTY_LOOKAHEAD",t[t.AMBIGUOUS_PREFIX_ALTS=11]="AMBIGUOUS_PREFIX_ALTS",t[t.TOO_MANY_ALTS=12]="TOO_MANY_ALTS"})(Dwe=Er.ParserDefinitionErrorType||(Er.ParserDefinitionErrorType={}));function Rwe(t){return t===void 0&&(t=void 0),function(){return t}}Er.EMPTY_ALT=Rwe;var my=function(){function t(e,r){this.definitionErrors=[],this.selfAnalysisDone=!1;var i=this;if(i.initErrorHandler(r),i.initLexerAdapter(),i.initLooksAhead(r),i.initRecognizerEngine(e,r),i.initRecoverable(r),i.initTreeBuilder(r),i.initContentAssist(),i.initGastRecorder(r),i.initPerformanceTracer(r),(0,an.has)(r,"ignoredIssues"))throw new Error(`The <ignoredIssues> IParserConfig property has been deprecated.
Please use the <IGNORE_AMBIGUITIES> flag on the relevant DSL method instead.
See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#IGNORING_AMBIGUITIES
For further details.`);this.skipValidations=(0,an.has)(r,"skipValidations")?r.skipValidations:Er.DEFAULT_PARSER_CONFIG.skipValidations}return t.performSelfAnalysis=function(e){throw Error("The **static** `performSelfAnalysis` method has been deprecated. \nUse the **instance** method with the same name instead.")},t.prototype.performSelfAnalysis=function(){var e=this;this.TRACE_INIT("performSelfAnalysis",function(){var r;e.selfAnalysisDone=!0;var i=e.className;e.TRACE_INIT("toFastProps",function(){(0,an.toFastProperties)(e)}),e.TRACE_INIT("Grammar Recording",function(){try{e.enableRecording(),(0,an.forEach)(e.definedRulesNames,function(s){var o=e[s],a=o.originalGrammarAction,l=void 0;e.TRACE_INIT(s+" Rule",function(){l=e.topLevelRuleRecord(s,a)}),e.gastProductionsCache[s]=l})}finally{e.disableRecording()}});var n=[];if(e.TRACE_INIT("Grammar Resolving",function(){n=(0,dY.resolveGrammar)({rules:(0,an.values)(e.gastProductionsCache)}),e.definitionErrors=e.definitionErrors.concat(n)}),e.TRACE_INIT("Grammar Validations",function(){if((0,an.isEmpty)(n)&&e.skipValidations===!1){var s=(0,dY.validateGrammar)({rules:(0,an.values)(e.gastProductionsCache),maxLookahead:e.maxLookahead,tokenTypes:(0,an.values)(e.tokensMap),errMsgProvider:pY.defaultGrammarValidatorErrorProvider,grammarName:i});e.definitionErrors=e.definitionErrors.concat(s)}}),(0,an.isEmpty)(e.definitionErrors)&&(e.recoveryEnabled&&e.TRACE_INIT("computeAllProdsFollows",function(){var s=(0,Ewe.computeAllProdsFollows)((0,an.values)(e.gastProductionsCache));e.resyncFollows=s}),e.TRACE_INIT("ComputeLookaheadFunctions",function(){e.preComputeLookaheadFunctions((0,an.values)(e.gastProductionsCache))})),!t.DEFER_DEFINITION_ERRORS_HANDLING&&!(0,an.isEmpty)(e.definitionErrors))throw r=(0,an.map)(e.definitionErrors,function(s){return s.message}),new Error(`Parser Definition Errors detected:
`+r.join(`
-------------------------------
`))})},t.DEFER_DEFINITION_ERRORS_HANDLING=!1,t}();Er.Parser=my;(0,Pwe.applyMixins)(my,[Iwe.Recoverable,ywe.LooksAhead,wwe.TreeBuilder,Bwe.LexerAdapter,Qwe.RecognizerEngine,bwe.RecognizerApi,vwe.ErrorHandler,Swe.ContentAssist,kwe.GastRecorder,xwe.PerformanceTracer]);var Fwe=function(t){fY(e,t);function e(r,i){i===void 0&&(i=Er.DEFAULT_PARSER_CONFIG);var n=this,s=(0,an.cloneObj)(i);return s.outputCst=!0,n=t.call(this,r,s)||this,n}return e}(my);Er.CstParser=Fwe;var Nwe=function(t){fY(e,t);function e(r,i){i===void 0&&(i=Er.DEFAULT_PARSER_CONFIG);var n=this,s=(0,an.cloneObj)(i);return s.outputCst=!1,n=t.call(this,r,s)||this,n}return e}(my);Er.EmbeddedActionsParser=Nwe});var mY=w(Ey=>{"use strict";Object.defineProperty(Ey,"__esModule",{value:!0});Ey.createSyntaxDiagramsCode=void 0;var CY=Rv();function Lwe(t,e){var r=e===void 0?{}:e,i=r.resourceBase,n=i===void 0?"https://unpkg.com/chevrotain@"+CY.VERSION+"/diagrams/":i,s=r.css,o=s===void 0?"https://unpkg.com/chevrotain@"+CY.VERSION+"/diagrams/diagrams.css":s,a=`
<!-- This is a generated file -->
<!DOCTYPE html>
<meta charset="utf-8">
<style>
body {
background-color: hsl(30, 20%, 95%)
}
</style>
`,l=`
<link rel='stylesheet' href='`+o+`'>
`,c=`
<script src='`+n+`vendor/railroad-diagrams.js'></script>
<script src='`+n+`src/diagrams_builder.js'></script>
<script src='`+n+`src/diagrams_behavior.js'></script>
<script src='`+n+`src/main.js'></script>
`,u=`
<div id="diagrams" align="center"></div>
`,g=`
<script>
window.serializedGrammar = `+JSON.stringify(t,null," ")+`;
</script>
`,f=`
<script>
var diagramsDiv = document.getElementById("diagrams");
main.drawDiagramsFromSerializedGrammar(serializedGrammar, diagramsDiv);
</script>
`;return a+l+c+u+g+f}Ey.createSyntaxDiagramsCode=Lwe});var yY=w(Ve=>{"use strict";Object.defineProperty(Ve,"__esModule",{value:!0});Ve.Parser=Ve.createSyntaxDiagramsCode=Ve.clearCache=Ve.GAstVisitor=Ve.serializeProduction=Ve.serializeGrammar=Ve.Terminal=Ve.Rule=Ve.RepetitionWithSeparator=Ve.RepetitionMandatoryWithSeparator=Ve.RepetitionMandatory=Ve.Repetition=Ve.Option=Ve.NonTerminal=Ve.Alternative=Ve.Alternation=Ve.defaultLexerErrorProvider=Ve.NoViableAltException=Ve.NotAllInputParsedException=Ve.MismatchedTokenException=Ve.isRecognitionException=Ve.EarlyExitException=Ve.defaultParserErrorProvider=Ve.tokenName=Ve.tokenMatcher=Ve.tokenLabel=Ve.EOF=Ve.createTokenInstance=Ve.createToken=Ve.LexerDefinitionErrorType=Ve.Lexer=Ve.EMPTY_ALT=Ve.ParserDefinitionErrorType=Ve.EmbeddedActionsParser=Ve.CstParser=Ve.VERSION=void 0;var Twe=Rv();Object.defineProperty(Ve,"VERSION",{enumerable:!0,get:function(){return Twe.VERSION}});var Iy=Zn();Object.defineProperty(Ve,"CstParser",{enumerable:!0,get:function(){return Iy.CstParser}});Object.defineProperty(Ve,"EmbeddedActionsParser",{enumerable:!0,get:function(){return Iy.EmbeddedActionsParser}});Object.defineProperty(Ve,"ParserDefinitionErrorType",{enumerable:!0,get:function(){return Iy.ParserDefinitionErrorType}});Object.defineProperty(Ve,"EMPTY_ALT",{enumerable:!0,get:function(){return Iy.EMPTY_ALT}});var EY=Rp();Object.defineProperty(Ve,"Lexer",{enumerable:!0,get:function(){return EY.Lexer}});Object.defineProperty(Ve,"LexerDefinitionErrorType",{enumerable:!0,get:function(){return EY.LexerDefinitionErrorType}});var Bg=WA();Object.defineProperty(Ve,"createToken",{enumerable:!0,get:function(){return Bg.createToken}});Object.defineProperty(Ve,"createTokenInstance",{enumerable:!0,get:function(){return Bg.createTokenInstance}});Object.defineProperty(Ve,"EOF",{enumerable:!0,get:function(){return Bg.EOF}});Object.defineProperty(Ve,"tokenLabel",{enumerable:!0,get:function(){return Bg.tokenLabel}});Object.defineProperty(Ve,"tokenMatcher",{enumerable:!0,get:function(){return Bg.tokenMatcher}});Object.defineProperty(Ve,"tokenName",{enumerable:!0,get:function(){return Bg.tokenName}});var Owe=Op();Object.defineProperty(Ve,"defaultParserErrorProvider",{enumerable:!0,get:function(){return Owe.defaultParserErrorProvider}});var Jp=Ig();Object.defineProperty(Ve,"EarlyExitException",{enumerable:!0,get:function(){return Jp.EarlyExitException}});Object.defineProperty(Ve,"isRecognitionException",{enumerable:!0,get:function(){return Jp.isRecognitionException}});Object.defineProperty(Ve,"MismatchedTokenException",{enumerable:!0,get:function(){return Jp.MismatchedTokenException}});Object.defineProperty(Ve,"NotAllInputParsedException",{enumerable:!0,get:function(){return Jp.NotAllInputParsedException}});Object.defineProperty(Ve,"NoViableAltException",{enumerable:!0,get:function(){return Jp.NoViableAltException}});var Mwe=Gv();Object.defineProperty(Ve,"defaultLexerErrorProvider",{enumerable:!0,get:function(){return Mwe.defaultLexerErrorProvider}});var Go=bn();Object.defineProperty(Ve,"Alternation",{enumerable:!0,get:function(){return Go.Alternation}});Object.defineProperty(Ve,"Alternative",{enumerable:!0,get:function(){return Go.Alternative}});Object.defineProperty(Ve,"NonTerminal",{enumerable:!0,get:function(){return Go.NonTerminal}});Object.defineProperty(Ve,"Option",{enumerable:!0,get:function(){return Go.Option}});Object.defineProperty(Ve,"Repetition",{enumerable:!0,get:function(){return Go.Repetition}});Object.defineProperty(Ve,"RepetitionMandatory",{enumerable:!0,get:function(){return Go.RepetitionMandatory}});Object.defineProperty(Ve,"RepetitionMandatoryWithSeparator",{enumerable:!0,get:function(){return Go.RepetitionMandatoryWithSeparator}});Object.defineProperty(Ve,"RepetitionWithSeparator",{enumerable:!0,get:function(){return Go.RepetitionWithSeparator}});Object.defineProperty(Ve,"Rule",{enumerable:!0,get:function(){return Go.Rule}});Object.defineProperty(Ve,"Terminal",{enumerable:!0,get:function(){return Go.Terminal}});var IY=bn();Object.defineProperty(Ve,"serializeGrammar",{enumerable:!0,get:function(){return IY.serializeGrammar}});Object.defineProperty(Ve,"serializeProduction",{enumerable:!0,get:function(){return IY.serializeProduction}});var Kwe=dg();Object.defineProperty(Ve,"GAstVisitor",{enumerable:!0,get:function(){return Kwe.GAstVisitor}});function Uwe(){console.warn(`The clearCache function was 'soft' removed from the Chevrotain API.
It performs no action other than printing this message.
Please avoid using it as it will be completely removed in the future`)}Ve.clearCache=Uwe;var Hwe=mY();Object.defineProperty(Ve,"createSyntaxDiagramsCode",{enumerable:!0,get:function(){return Hwe.createSyntaxDiagramsCode}});var Gwe=function(){function t(){throw new Error(`The Parser class has been deprecated, use CstParser or EmbeddedActionsParser instead.
See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_7-0-0`)}return t}();Ve.Parser=Gwe});var bY=w((_tt,wY)=>{var yy=yY(),Ya=yy.createToken,BY=yy.tokenMatcher,fS=yy.Lexer,jwe=yy.EmbeddedActionsParser;wY.exports=t=>{let e=Ya({name:"LogicalOperator",pattern:fS.NA}),r=Ya({name:"Or",pattern:/\|/,categories:e}),i=Ya({name:"Xor",pattern:/\^/,categories:e}),n=Ya({name:"And",pattern:/&/,categories:e}),s=Ya({name:"Not",pattern:/!/}),o=Ya({name:"LParen",pattern:/\(/}),a=Ya({name:"RParen",pattern:/\)/}),l=Ya({name:"Query",pattern:t}),u=[Ya({name:"WhiteSpace",pattern:/\s+/,group:fS.SKIPPED}),r,i,n,o,a,s,e,l],g=new fS(u);class f extends jwe{constructor(p){super(u);this.RULE("expression",()=>this.SUBRULE(this.logicalExpression)),this.RULE("logicalExpression",()=>{let y=this.SUBRULE(this.atomicExpression);return this.MANY(()=>{let b=y,S=this.CONSUME(e),k=this.SUBRULE2(this.atomicExpression);BY(S,r)?y=T=>b(T)||k(T):BY(S,i)?y=T=>!!(b(T)^k(T)):y=T=>b(T)&&k(T)}),y}),this.RULE("atomicExpression",()=>this.OR([{ALT:()=>this.SUBRULE(this.parenthesisExpression)},{ALT:()=>{let{image:m}=this.CONSUME(l);return y=>y(m)}},{ALT:()=>{this.CONSUME(s);let m=this.SUBRULE(this.atomicExpression);return y=>!m(y)}}])),this.RULE("parenthesisExpression",()=>{let m;return this.CONSUME(o),m=this.SUBRULE(this.expression),this.CONSUME(a),m}),this.performSelfAnalysis()}}return{TinylogicLexer:g,TinylogicParser:f}}});var QY=w(wy=>{var Ywe=bY();wy.makeParser=(t=/[a-z]+/)=>{let{TinylogicLexer:e,TinylogicParser:r}=Ywe(t),i=new r;return(n,s)=>{let o=e.tokenize(n);return i.input=o.tokens,i.expression()(s)}};wy.parse=wy.makeParser()});var SY=w((Xtt,vY)=>{"use strict";vY.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke Line truncated
`:`
`)+r,n=i+1,i=t.indexOf(`
`,n)}while(i!==-1);return s+=t.substr(n),s};qY.exports={stringReplaceAll:iBe,stringEncaseCRLFWithFirstIndex:nBe}});var XY=w((srt,WY)=>{"use strict";var sBe=/(?:\\(u(?:[a-f\d]{4}|\{[a-f\d]{1,6}\})|x[a-f\d]{2}|.))|(?:\{(~)?(\w+(?:\([^)]*\))?(?:\.\w+(?:\([^)]*\))?)*)(?:[ \t]|(?=\r?\n)))|(\})|((?:.|[\r\n\f])+?)/gi,zY=/(?:^|\.)(\w+)(?:\(([^)]*)\))?/g,oBe=/^(['"])((?:\\.|(?!\1)[^\\])*)\1$/,aBe=/\\(u(?:[a-f\d]{4}|\{[a-f\d]{1,6}\})|x[a-f\d]{2}|.)|([^\\])/gi,ABe=new Map([["n",`
`],["r","\r"],["t"," "],["b","\b"],["f","\f"],["v","\v"],["0","\0"],["\\","\\"],["e",""],["a","\x07"]]);function _Y(t){let e=t[0]==="u",r=t[1]==="{";return e&&!r&&t.length===5||t[0]==="x"&&t.length===3?String.fromCharCode(parseInt(t.slice(1),16)):e&&r?String.fromCodePoint(parseInt(t.slice(2,-1),16)):ABe.get(t)||t}function lBe(t,e){let r=[],i=e.trim().split(/\s*,\s*/g),n;for(let s of i){let o=Number(s);if(!Number.isNaN(o))r.push(o);else if(n=s.match(oBe))r.push(n[2].replace(aBe,(a,l,c)=>l?_Y(l):c));else throw new Error(`Invalid Chalk template style argument: ${s} (in style '${t}')`)}return r}function cBe(t){zY.lastIndex=0;let e=[],r;for(;(r=zY.exec(t))!==null;){let i=r[1];if(r[2]){let n=lBe(i,r[2]);e.push([i].concat(n))}else e.push([i])}return e}function VY(t,e){let r={};for(let n of e)for(let s of n.styles)r[s[0]]=n.inverse?null:s.slice(1);let i=t;for(let[n,s]of Object.entries(r))if(!!Array.isArray(s)){if(!(n in i))throw new Error(`Unknown Chalk style: ${n}`);i=s.length>0?i[n](...s):i[n]}return i}WY.exports=(t,e)=>{let r=[],i=[],n=[];if(e.replace(sBe,(s,o,a,l,c,u)=>{if(o)n.push(_Y(o));else if(l){let g=n.join("");n=[],i.push(r.length===0?g:VY(t,r)(g)),r.push({inverse:a,styles:cBe(l)})}else if(c){if(r.length===0)throw new Error("Found extraneous } in Chalk template literal");i.push(VY(t,r)(n.join(""))),n=[],r.pop()}else n.push(u)}),i.push(n.join("")),r.length>0){let s=`Chalk template literal is missing ${r.length} closing bracket${r.length===1?"":"s"} (\`}\`)`;throw new Error(s)}return i.join("")}});var BS=w((ort,ZY)=>{"use strict";var zp=KY(),{stdout:ES,stderr:IS}=YY(),{stringReplaceAll:uBe,stringEncaseCRLFWithFirstIndex:gBe}=JY(),$Y=["ansi","ansi","ansi256","ansi16m"],Sg=Object.create(null),fBe=(t,e={})=>{if(e.level>3||e.level<0)throw new Error("The `level` option should be an integer from 0 to 3");let r=ES?ES.level:0;t.level=e.level===void 0?r:e.level},eq=class{constructor(e){return tq(e)}},tq=t=>{let e={};return fBe(e,t),e.template=(...r)=>hBe(e.template,...r),Object.setPrototypeOf(e,Qy.prototype),Object.setPrototypeOf(e.template,e),e.template.constructor=()=>{throw new Error("`chalk.constructor()` is deprecated. Use `new chalk.Instance()` instead.")},e.template.Instance=eq,e.template};function Qy(t){return tq(t)}for(let[t,e]of Object.entries(zp))Sg[t]={get(){let r=vy(this,yS(e.open,e.close,this._styler),this._isEmpty);return Object.defineProperty(this,t,{value:r}),r}};Sg.visible={get(){let t=vy(this,this._styler,!0);return Object.defineProperty(this,"visible",{value:t}),t}};var rq=["rgb","hex","keyword","hsl","hsv","hwb","ansi","ansi256"];for(let t of rq)Sg[t]={get(){let{level:e}=this;return function(...r){let i=yS(zp.color[$Y[e]][t](...r),zp.color.close,this._styler);return vy(this,i,this._isEmpty)}}};for(let t of rq){let e="bg"+t[0].toUpperCase()+t.slice(1);Sg[e]={get(){let{level:r}=this;return function(...i){let n=yS(zp.bgColor[$Y[r]][t](...i),zp.bgColor.close,this._styler);return vy(this,n,this._isEmpty)}}}}var pBe=Object.defineProperties(()=>{},ie(N({},Sg),{level:{enumerable:!0,get(){return this._generator.level},set(t){this._generator.level=t}}})),yS=(t,e,r)=>{let i,n;return r===void 0?(i=t,n=e):(i=r.openAll+t,n=e+r.closeAll),{open:t,close:e,openAll:i,closeAll:n,parent:r}},vy=(t,e,r)=>{let i=(...n)=>dBe(i,n.length===1?""+n[0]:n.join(" "));return i.__proto__=pBe,i._generator=t,i._styler=e,i._isEmpty=r,i},dBe=(t,e)=>{if(t.level<=0||!e)return t._isEmpty?"":e;let r=t._styler;if(r===void 0)return e;let{openAll:i,closeAll:n}=r;if(e.indexOf("")!==-1)for(;r!==void 0;)e=uBe(e,r.close,r.open),r=r.parent;let s=e.indexOf(`
`);return s!==-1&&(e=gBe(e,n,i,s)),i+e+n},wS,hBe=(t,...e)=>{let[r]=e;if(!Array.isArray(r))return e.join(" ");let i=e.slice(1),n=[r.raw[0]];for(let s=1;s<r.length;s++)n.push(String(i[s-1]).replace(/[{}\\]/g,"\\$&"),String(r.raw[s]));return wS===void 0&&(wS=XY()),wS(t,n.join(""))};Object.defineProperties(Qy.prototype,Sg);var _p=Qy();_p.supportsColor=ES;_p.stderr=Qy({level:IS?IS.level:0});_p.stderr.supportsColor=IS;_p.Level={None:0,Basic:1,Ansi256:2,TrueColor:3,0:"None",1:"Basic",2:"Ansi256",3:"TrueColor"};ZY.exports=_p});var Sy=w(Ps=>{"use strict";Ps.isInteger=t=>typeof t=="number"?Number.isInteger(t):typeof t=="string"&&t.trim()!==""?Number.isInteger(Number(t)):!1;Ps.find=(t,e)=>t.nodes.find(r=>r.type===e);Ps.exceedsLimit=(t,e,r=1,i)=>i===!1||!Ps.isInteger(t)||!Ps.isInteger(e)?!1:(Number(e)-Number(t))/Number(r)>=i;Ps.escapeNode=(t,e=0,r)=>{let i=t.nodes[e];!i||(r&&i.type===r||i.type==="open"||i.type==="close")&&i.escaped!==!0&&(i.value="\\"+i.value,i.escaped=!0)};Ps.encloseBrace=t=>t.type!=="brace"?!1:t.commas>>0+t.ranges>>0==0?(t.invalid=!0,!0):!1;Ps.isInvalidBrace=t=>t.type!=="brace"?!1:t.invalid===!0||t.dollar?!0:t.commas>>0+t.ranges>>0==0||t.open!==!0||t.close!==!0?(t.invalid=!0,!0):!1;Ps.isOpenOrClose=t=>t.type==="open"||t.type==="close"?!0:t.open===!0||t.close===!0;Ps.reduce=t=>t.reduce((e,r)=>(r.type==="text"&&e.push(r.value),r.type==="range"&&(r.type="text"),e),[]);Ps.flatten=(...t)=>{let e=[],r=i=>{for(let n=0;n<i.length;n++){let s=i[n];Array.isArray(s)?r(s,e):s!==void 0&&e.push(s)}return e};return r(t),e}});var ky=w((Art,iq)=>{"use strict";var nq=Sy();iq.exports=(t,e={})=>{let r=(i,n={})=>{let s=e.escapeInvalid&&nq.isInvalidBrace(n),o=i.invalid===!0&&e.escapeInvalid===!0,a="";if(i.value)return(s||o)&&nq.isOpenOrClose(i)?"\\"+i.value:i.value;if(i.value)return i.value;if(i.nodes)for(let l of i.nodes)a+=r(l);return a};return r(t)}});var oq=w((lrt,sq)=>{"use strict";sq.exports=function(t){return typeof t=="number"?t-t==0:typeof t=="string"&&t.trim()!==""?Number.isFinite?Number.isFinite(+t):isFinite(+t):!1}});var pq=w((crt,aq)=>{"use strict";var Aq=oq(),Sc=(t,e,r)=>{if(Aq(t)===!1)throw new TypeError("toRegexRange: expected the first argument to be a number");if(e===void 0||t===e)return String(t);if(Aq(e)===!1)throw new TypeError("toRegexRange: expected the second argument to be a number.");let i=N({relaxZeros:!0},r);typeof i.strictZeros=="boolean"&&(i.relaxZeros=i.strictZeros===!1);let n=String(i.relaxZeros),s=String(i.shorthand),o=String(i.capture),a=String(i.wrap),l=t+":"+e+"="+n+s+o+a;if(Sc.cache.hasOwnProperty(l))return Sc.cache[l].result;let c=Math.min(t,e),u=Math.max(t,e);if(Math.abs(c-u)===1){let m=t+"|"+e;return i.capture?`(${m})`:i.wrap===!1?m:`(?:${m})`}let g=cq(t)||cq(e),f={min:t,max:e,a:c,b:u},h=[],p=[];if(g&&(f.isPadded=g,f.maxLen=String(f.max).length),c<0){let m=u<0?Math.abs(u):1;p=lq(m,Math.abs(c),f,i),c=f.a=0}return u>=0&&(h=lq(c,u,f,i)),f.negatives=p,f.positives=h,f.result=CBe(p,h,i),i.capture===!0?f.result=`(${f.result})`:i.wrap!==!1&&h.length+p.length>1&&(f.result=`(?:${f.result})`),Sc.cache[l]=f,f.result};function CBe(t,e,r){let i=bS(t,e,"-",!1,r)||[],n=bS(e,t,"",!1,r)||[],s=bS(t,e,"-?",!0,r)||[];return i.concat(s).concat(n).join("|")}function EBe(t,e){let r=1,i=1,n=uq(t,r),s=new Set([e]);for(;t<=n&&n<=e;)s.add(n),r+=1,n=uq(t,r);for(n=gq(e+1,i)-1;t<n&&n<=e;)s.add(n),i+=1,n=gq(e+1,i)-1;return s=[...s],s.sort(mBe),s}function wBe(t,e,r){if(t===e)return{pattern:t,count:[],digits:0};let i=IBe(t,e),n=i.length,s="",o=0;for(let a=0;a<n;a++){let[l,c]=i[a];l===c?s+=l:l!=="0"||c!=="9"?s+=yBe(l,c,r):o++}return o&&(s+=r.shorthand===!0?"\\d":"[0-9]"),{pattern:s,count:[o],digits:n}}function lq(t,e,r,i){let n=EBe(t,e),s=[],o=t,a;for(let l=0;l<n.length;l++){let c=n[l],u=wBe(String(o),String(c),i),g="";if(!r.isPadded&&a&&a.pattern===u.pattern){a.count.length>1&&a.count.pop(),a.count.push(u.count[0]),a.string=a.pattern+fq(a.count),o=c+1;continue}r.isPadded&&(g=BBe(c,r,i)),u.string=g+u.pattern+fq(u.count),s.push(u),o=c+1,a=u}return s}function bS(t,e,r,i,n){let s=[];for(let o of t){let{string:a}=o;!i&&!hq(e,"string",a)&&s.push(r+a),i&&hq(e,"string",a)&&s.push(r+a)}return s}function IBe(t,e){let r=[];for(let i=0;i<t.length;i++)r.push([t[i],e[i]]);return r}function mBe(t,e){return t>e?1:e>t?-1:0}function hq(t,e,r){return t.some(i=>i[e]===r)}function uq(t,e){return Number(String(t).slice(0,-e)+"9".repeat(e))}function gq(t,e){return t-t%Math.pow(10,e)}function fq(t){let[e=0,r=""]=t;return r||e>1?`{${e+(r?","+r:"")}}`:""}function yBe(t,e,r){return`[${t}${e-t==1?"":"-"}${e}]`}function cq(t){return/^-?(0+)\d/.test(t)}function BBe(t,e,r){if(!e.isPadded)return t;let i=Math.abs(e.maxLen-String(t).length),n=r.relaxZeros!==!1;switch(i){case 0:return"";case 1:return n?"0?":"0";case 2:return n?"0{0,2}":"00";default:return n?`0{0,${i}}`:`0{${i}}`}}Sc.cache={};Sc.clearCache=()=>Sc.cache={};aq.exports=Sc});var SS=w((urt,dq)=>{"use strict";var bBe=require("util"),Cq=pq(),mq=t=>t!==null&&typeof t=="object"&&!Array.isArray Line truncated
`,CHAR_NO_BREAK_SPACE:"\xA0",CHAR_PERCENT:"%",CHAR_PLUS:"+",CHAR_QUESTION_MARK:"?",CHAR_RIGHT_ANGLE_BRACKET:">",CHAR_RIGHT_CURLY_BRACE:"}",CHAR_RIGHT_SQUARE_BRACKET:"]",CHAR_SEMICOLON:";",CHAR_SINGLE_QUOTE:"'",CHAR_SPACE:" ",CHAR_TAB:" ",CHAR_UNDERSCORE:"_",CHAR_VERTICAL_LINE:"|",CHAR_ZERO_WIDTH_NOBREAK_SPACE:"\uFEFF"}});var Tq=w((prt,Rq)=>{"use strict";var TBe=ky(),{MAX_LENGTH:Fq,CHAR_BACKSLASH:kS,CHAR_BACKTICK:OBe,CHAR_COMMA:MBe,CHAR_DOT:KBe,CHAR_LEFT_PARENTHESES:UBe,CHAR_RIGHT_PARENTHESES:HBe,CHAR_LEFT_CURLY_BRACE:GBe,CHAR_RIGHT_CURLY_BRACE:jBe,CHAR_LEFT_SQUARE_BRACKET:Nq,CHAR_RIGHT_SQUARE_BRACKET:Lq,CHAR_DOUBLE_QUOTE:YBe,CHAR_SINGLE_QUOTE:qBe,CHAR_NO_BREAK_SPACE:JBe,CHAR_ZERO_WIDTH_NOBREAK_SPACE:WBe}=Dq(),zBe=(t,e={})=>{if(typeof t!="string")throw new TypeError("Expected a string");let r=e||{},i=typeof r.maxLength=="number"?Math.min(Fq,r.maxLength):Fq;if(t.length>i)throw new SyntaxError(`Input length (${t.length}), exceeds max characters (${i})`);let n={type:"root",input:t,nodes:[]},s=[n],o=n,a=n,l=0,c=t.length,u=0,g=0,f,h={},p=()=>t[u++],m=y=>{if(y.type==="text"&&a.type==="dot"&&(a.type="text"),a&&a.type==="text"&&y.type==="text"){a.value+=y.value;return}return o.nodes.push(y),y.parent=o,y.prev=a,a=y,y};for(m({type:"bos"});u<c;)if(o=s[s.length-1],f=p(),!(f===WBe||f===JBe)){if(f===kS){m({type:"text",value:(e.keepEscaping?f:"")+p()});continue}if(f===Lq){m({type:"text",value:"\\"+f});continue}if(f===Nq){l++;let y=!0,b;for(;u<c&&(b=p());){if(f+=b,b===Nq){l++;continue}if(b===kS){f+=p();continue}if(b===Lq&&(l--,l===0))break}m({type:"text",value:f});continue}if(f===UBe){o=m({type:"paren",nodes:[]}),s.push(o),m({type:"text",value:f});continue}if(f===HBe){if(o.type!=="paren"){m({type:"text",value:f});continue}o=s.pop(),m({type:"text",value:f}),o=s[s.length-1];continue}if(f===YBe||f===qBe||f===OBe){let y=f,b;for(e.keepQuotes!==!0&&(f="");u<c&&(b=p());){if(b===kS){f+=b+p();continue}if(b===y){e.keepQuotes===!0&&(f+=b);break}f+=b}m({type:"text",value:f});continue}if(f===GBe){g++;let y=a.value&&a.value.slice(-1)==="$"||o.dollar===!0;o=m({type:"brace",open:!0,close:!1,dollar:y,depth:g,commas:0,ranges:0,nodes:[]}),s.push(o),m({type:"open",value:f});continue}if(f===jBe){if(o.type!=="brace"){m({type:"text",value:f});continue}let y="close";o=s.pop(),o.close=!0,m({type:y,value:f}),g--,o=s[s.length-1];continue}if(f===MBe&&g>0){if(o.ranges>0){o.ranges=0;let y=o.nodes.shift();o.nodes=[y,{type:"text",value:TBe(o)}]}m({type:"comma",value:f}),o.commas++;continue}if(f===KBe&&g>0&&o.commas===0){let y=o.nodes;if(g===0||y.length===0){m({type:"text",value:f});continue}if(a.type==="dot"){if(o.range=[],a.value+=f,a.type="range",o.nodes.length!==3&&o.nodes.length!==5){o.invalid=!0,o.ranges=0,a.type="text";continue}o.ranges++,o.args=[];continue}if(a.type==="range"){y.pop();let b=y[y.length-1];b.value+=a.value+f,a=b,o.ranges--;continue}m({type:"dot",value:f});continue}m({type:"text",value:f})}do if(o=s.pop(),o.type!=="root"){o.nodes.forEach(S=>{S.nodes||(S.type==="open"&&(S.isOpen=!0),S.type==="close"&&(S.isClose=!0),S.nodes||(S.type="text"),S.invalid=!0)});let y=s[s.length-1],b=y.nodes.indexOf(o);y.nodes.splice(b,1,...o.nodes)}while(s.length>0);return m({type:"eos"}),n};Rq.exports=zBe});var Kq=w((drt,Oq)=>{"use strict";var Mq=ky(),_Be=vq(),VBe=xq(),XBe=Tq(),es=(t,e={})=>{let r=[];if(Array.isArray(t))for(let i of t){let n=es.create(i,e);Array.isArray(n)?r.push(...n):r.push(n)}else r=[].concat(es.create(t,e));return e&&e.expand===!0&&e.nodupes===!0&&(r=[...new Set(r)]),r};es.parse=(t,e={})=>XBe(t,e);es.stringify=(t,e={})=>typeof t=="string"?Mq(es.parse(t,e),e):Mq(t,e);es.compile=(t,e={})=>(typeof t=="string"&&(t=es.parse(t,e)),_Be(t,e));es.expand=(t,e={})=>{typeof t=="string"&&(t=es.parse(t,e));let r=VBe(t,e);return e.noempty===!0&&(r=r.filter(Boolean)),e.nodupes===!0&&(r=[...new Set(r)]),r};es.create=(t,e={})=>t===""||t.length<3?[t]:e.expand!==!0?es.compile(t,e):es.expand(t,e);Oq.exports=es});var Xp=w((Crt,Uq)=>{"use strict";var ZBe=require("path"),jo="\\\\/",Hq=`[^${jo}]`,qa="\\.",$Be="\\+",e0e="\\?",Py="\\/",t0e="(?=.)",Gq="[^/]",xS=`(?:${Py}|$)`,jq=`(?:^|${Py})`,PS=`${qa}{1,2}${xS}`,r0e=`(?!${qa})`,i0e=`(?!${jq}${PS})`,n0e=`(?!${qa}{0,1}${xS})`,s0e=`(?!${PS})`,o0e=`[^.${Py}]`,a0e=`${Gq}*?`,Yq={DOT_LITERAL:qa,PLUS_LITERAL:$Be,QMARK_LITERAL:e0e,SLASH_LITERAL:Py,ONE_CHAR:t0e,QMARK:Gq,END_ANCHOR:xS,DOTS_SLASH:PS,NO_DOT:r0e,NO_DOTS:i0e,NO_DOT_SLASH:n0e,NO_DOTS_SLASH:s0e,QMARK_NO_DOT:o0e,STAR:a0e,START_ANCHOR:jq},A0e=ie(N({},Yq),{SLASH_LITERAL:`[${jo}]`,QMARK:Hq,STAR:`${Hq}*?`,DOTS_SLASH:`${qa}{1,2}(?:[${jo}]|$)`,NO_DOT:`(?!${qa})`,NO_DOTS:`(?!(?:^|[${jo}])${qa}{1,2}(?:[${jo}]|$))`,NO_DOT_SLASH:`(?!${qa}{0,1}(?:[${jo}]|$))`,NO_DOTS_SLASH:`(?!${qa}{1,2}(?:[${jo}]|$))`,QMARK_NO_DOT:`[^.${jo}]`,START_ANCHOR:`(?:^|[${jo}])`,END_ANCHOR:`(?:[${jo}]|$)`}),l0e={alnum:"a-zA-Z0-9",alpha:"a-zA-Z",ascii:"\\x00-\\x7F",blank:" \\t",cntrl:"\\x00-\\x1F\\x7F",digit:"0-9",graph:"\\x21-\\x7E",lower:"a-z",print:"\\x20-\\x7E ",punct:"\\-!\"#$%&'()\\*+,./:;<=>? Line truncated
Please report this to https://github.com/szmarczak/http2-wrapper/`);p(m)}return}i[0].resolve(h);return}}if(o in this.queue){if(a in this.queue[o]){this.queue[o][a].listeners.push(...i),this._tryToCreateNewSession(o,a);return}}else this.queue[o]={};let l=()=>{o in this.queue&&this.queue[o][a]===c&&(delete this.queue[o][a],Object.keys(this.queue[o]).length===0&&delete this.queue[o])},c=()=>{let u=`${a}:${o}`,g=!1;try{let f=Fxe.connect(e,N({createConnection:this.createConnection,settings:this.settings,session:this.tlsSessionCache.get(u)},r));f[gn]=0,f[Xg]=!1;let h=()=>f[gn]<f.remoteSettings.maxConcurrentStreams,p=!0;f.socket.once("session",y=>{this.tlsSessionCache.set(u,y)}),f.once("error",y=>{for(let{reject:b}of i)b(y);this.tlsSessionCache.delete(u)}),f.setTimeout(this.timeout,()=>{f.destroy()}),f.once("close",()=>{if(g){p&&this._freeSessionsCount--,this._sessionsCount--;let y=this.sessions[o];y.splice(y.indexOf(f),1),y.length===0&&delete this.sessions[o]}else{let y=new Error("Session closed without receiving a SETTINGS frame");y.code="HTTP2WRAPPER_NOSETTINGS";for(let{reject:b}of i)b(y);l()}this._tryToCreateNewSession(o,a)});let m=()=>{if(!(!(o in this.queue)||!h())){for(let y of f[Ns])if(y in this.queue[o]){let{listeners:b}=this.queue[o][y];for(;b.length!==0&&h();)b.shift().resolve(f);let S=this.queue[o];if(S[y].listeners.length===0&&(delete S[y],Object.keys(S).length===0)){delete this.queue[o];break}if(!h())break}}};f.on("origin",()=>{f[Ns]=f.originSet,!!h()&&(m(),sP(this.sessions[o],f))}),f.once("remoteSettings",()=>{if(f.ref(),f.unref(),this._sessionsCount++,c.destroyed){let y=new Error("Agent has been destroyed");for(let b of i)b.reject(y);f.destroy();return}f[Ns]=f.originSet;{let y=this.sessions;if(o in y){let b=y[o];b.splice(Txe(b,f,Oxe),0,f)}else y[o]=[f]}this._freeSessionsCount+=1,g=!0,this.emit("session",f),m(),l(),f[gn]===0&&this._freeSessionsCount>this.maxFreeSessions&&f.close(),i.length!==0&&(this.getSession(a,r,i),i.length=0),f.on("remoteSettings",()=>{m(),sP(this.sessions[o],f)})}),f[oz]=f.request,f.request=(y,b)=>{if(f[Xg])throw new Error("The session is gracefully closing. No new streams are allowed.");let S=f[oz](y,b);return f.ref(),++f[gn],f[gn]===f.remoteSettings.maxConcurrentStreams&&this._freeSessionsCount--,S.once("close",()=>{if(p=h(),--f[gn],!f.destroyed&&!f.closed&&(Mxe(this.sessions[o],f),h()&&!f.closed)){p||(this._freeSessionsCount++,p=!0);let k=f[gn]===0;k&&f.unref(),k&&(this._freeSessionsCount>this.maxFreeSessions||f[Xg])?f.close():(sP(this.sessions[o],f),m())}}),S}}catch(f){for(let h of i)h.reject(f);l()}};c.listeners=i,c.completed=!1,c.destroyed=!1,this.queue[o][a]=c,this._tryToCreateNewSession(o,a)})}request(e,r,i,n){return new Promise((s,o)=>{this.getSession(e,r,[{reject:o,resolve:a=>{try{s(a.request(i,n))}catch(l){o(l)}}}])})}createConnection(e,r){return tA.connect(e,r)}static connect(e,r){r.ALPNProtocols=["h2"];let i=e.port||443,n=e.hostname||e.host;return typeof r.servername=="undefined"&&(r.servername=n),Rxe.connect(i,n,r)}closeFreeSessions(){for(let e of Object.values(this.sessions))for(let r of e)r[gn]===0&&r.close()}destroy(e){for(let r of Object.values(this.sessions))for(let i of r)i.destroy(e);for(let r of Object.values(this.queue))for(let i of Object.values(r))i.destroyed=!0;this.queue={}}get freeSessions(){return Az({agent:this,isFree:!0})}get busySessions(){return Az({agent:this,isFree:!1})}};tA.kCurrentStreamsCount=gn;tA.kGracefullyClosing=Xg;sz.exports={Agent:tA,globalAgent:new tA}});var aP=w((cot,lz)=>{"use strict";var{Readable:Kxe}=require("stream"),cz=class extends Kxe{constructor(e,r){super({highWaterMark:r,autoDestroy:!1});this.statusCode=null,this.statusMessage="",this.httpVersion="2.0",this.httpVersionMajor=2,this.httpVersionMinor=0,this.headers={},this.trailers={},this.req=null,this.aborted=!1,this.complete=!1,this.upgrade=null,this.rawHeaders=[],this.rawTrailers=[],this.socket=e,this.connection=e,this._dumped=!1}_destroy(e){this.req._request.destroy(e)}setTimeout(e,r){return this.req.setTimeout(e,r),this}_dump(){this._dumped||(this._dumped=!0,this.removeAllListeners("data"),this.resume())}_read(){this.req&&this.req._request.resume()}};lz.exports=cz});var AP=w((uot,uz)=>{"use strict";uz.exports=t=>{let e={protocol:t.protocol,hostname:typeof t.hostname=="string"&&t.hostname.startsWith("[")?t.hostname.slice(1,-1):t.hostname,host:t.host,hash:t.hash,search:t.search,pathname:t.pathname,href:t.href,path:`${t.pathname||""}${t.search||""}`};return typeof t.port=="string"&&t.port.length!==0&&(e.port=Number(t.port)),(t.username||t.password)&&(e.auth=`${t.username||""}:${t.password||""}`),e}});var fz=w((got,gz)=>{"use strict";gz.exports=(t,e,r)=>{for(let i of r)t.on(i,(...n)=>e.emit(i,...n))}});var pz=w((fot,hz)=>{"use strict";hz.exports=t=>{switch(t){case":method":case":scheme":case":authority":case":path":return!0;default:return!1}}});var Cz=w((pot,dz)=>{"use strict";var Zg=(t,e,r)=>{dz.exports[e]=class extends t{constructor(...n){super(typeof r=="string"?r:r(n) Line truncated
`).reverse(),a=r.stack.slice(r.stack.indexOf(r.message)+r.message.length).split(`
`).reverse();for(;a.length!==0&&a[0]===o[0];)o.shift();this.stack=`${this.stack.slice(0,s)}${o.reverse().join(`
`)}${a.reverse().join(`
`)}`}}};qt.RequestError=fi;var TP=class extends fi{constructor(e){super(`Redirected ${e.options.maxRedirects} times. Aborting.`,{},e);this.name="MaxRedirectsError"}};qt.MaxRedirectsError=TP;var OP=class extends fi{constructor(e){super(`Response code ${e.statusCode} (${e.statusMessage})`,{},e.request);this.name="HTTPError"}};qt.HTTPError=OP;var MP=class extends fi{constructor(e,r){super(e.message,e,r);this.name="CacheError"}};qt.CacheError=MP;var KP=class extends fi{constructor(e,r){super(e.message,e,r);this.name="UploadError"}};qt.UploadError=KP;var UP=class extends fi{constructor(e,r,i){super(e.message,e,i);this.name="TimeoutError",this.event=e.event,this.timings=r}};qt.TimeoutError=UP;var Kw=class extends fi{constructor(e,r){super(e.message,e,r);this.name="ReadError"}};qt.ReadError=Kw;var HP=class extends fi{constructor(e){super(`Unsupported protocol "${e.url.protocol}"`,{},e);this.name="UnsupportedProtocolError"}};qt.UnsupportedProtocolError=HP;var JPe=["socket","connect","continue","information","upgrade","timeout"],LP=class extends t5.Duplex{constructor(e,r={},i){super({autoDestroy:!1,highWaterMark:0});this[ef]=0,this[rf]=0,this.requestInitialized=!1,this[Ow]=new Set,this.redirects=[],this[nf]=!1,this[Mw]=!1,this[Ld]=[],this.retryCount=0,this._progressCallbacks=[];let n=()=>this._unlockWrite(),s=()=>this._lockWrite();this.on("pipe",c=>{c.prependListener("data",n),c.on("data",s),c.prependListener("end",n),c.on("end",s)}),this.on("unpipe",c=>{c.off("data",n),c.off("data",s),c.off("end",n),c.off("end",s)}),this.on("pipe",c=>{c instanceof DP.IncomingMessage&&(this.options.headers=N(N({},c.headers),this.options.headers))});let{json:o,body:a,form:l}=r;if((o||a||l)&&this._lockWrite(),qt.kIsNormalizedAlready in r)this.options=r;else try{this.options=this.constructor.normalizeArguments(e,r,i)}catch(c){Ie.default.nodeStream(r.body)&&r.body.destroy(),this.destroy(c);return}(async()=>{var c;try{this.options.body instanceof QPe.ReadStream&&await jPe(this.options.body);let{url:u}=this.options;if(!u)throw new TypeError("Missing `url` property");if(this.requestUrl=u.toString(),decodeURI(this.requestUrl),await this._finalizeBody(),await this._makeRequest(),this.destroyed){(c=this[Ri])===null||c===void 0||c.destroy();return}for(let g of this[Ld])g();this[Ld].length=0,this.requestInitialized=!0}catch(u){if(u instanceof fi){this._beforeError(u);return}this.destroyed||this.destroy(u)}})()}static normalizeArguments(e,r,i){var n,s,o,a,l;let c=r;if(Ie.default.object(e)&&!Ie.default.urlInstance(e))r=N(N(N({},i),e),r);else{if(e&&r&&r.url!==void 0)throw new TypeError("The `url` option is mutually exclusive with the `input` argument");r=N(N({},i),r),e!==void 0&&(r.url=e),Ie.default.urlInstance(r.url)&&(r.url=new Al.URL(r.url.toString()))}if(r.cache===!1&&(r.cache=void 0),r.dnsCache===!1&&(r.dnsCache=void 0),Ie.assert.any([Ie.default.string,Ie.default.undefined],r.method),Ie.assert.any([Ie.default.object,Ie.default.undefined],r.headers),Ie.assert.any([Ie.default.string,Ie.default.urlInstance,Ie.default.undefined],r.prefixUrl),Ie.assert.any([Ie.default.object,Ie.default.undefined],r.cookieJar),Ie.assert.any([Ie.default.object,Ie.default.string,Ie.default.undefined],r.searchParams),Ie.assert.any([Ie.default.object,Ie.default.string,Ie.default.undefined],r.cache),Ie.assert.any([Ie.default.object,Ie.default.number,Ie.default.undefined],r.timeout),Ie.assert.any([Ie.default.object,Ie.default.undefined],r.context),Ie.assert.any([Ie.default.object,Ie.default.undefined],r.hooks),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.decompress),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.ignoreInvalidCookies),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.followRedirect),Ie.assert.any([Ie.default.number,Ie.default.undefined],r.maxRedirects),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.throwHttpErrors),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.http2),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.allowGetBody),Ie.assert.any([Ie.default.string,Ie.default.undefined],r.localAddress),Ie.assert.any([a5.isDnsLookupIpVersion,Ie.default.undefined],r.dnsLookupIpVersion),Ie.assert.any([Ie.default.object,Ie.default.undefined],r.https),Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.rejectUnauthorized),r.https&&(Ie.assert.any([Ie.default.boolean,Ie.default.undefined],r.https.rejectUnauthorized),Ie.assert.any([Ie.default.function_,Ie.default.undefined],r.https.checkServerIdentity),Ie.assert.any([Ie.default.string,Ie.default.object,Ie.default.array,Ie.default.undefined],r.https.certificateAuthority),Ie.assert.any([Ie.default.string,Ie.default.object,Ie.default.array,Ie.default.undefined],r.https.key),Ie.assert.any([Ie.default.string,Ie.default.object,Ie.default.array,Ie.default.undefined],r.https.certificate),Ie.assert.any([Ie.default.string,Ie.default.undefined],r.https.passphrase),Ie.assert.any([Ie.default.string,Ie.default.buffer,Ie.default.array,Ie.default.undefined],r.httLine truncated
`,g.message,g.stack);var f=new Error("tunneling socket could not be established, cause="+g.message);f.code="ECONNRESET",e.request.emit("error",f),i.removeSocket(n)}};iA.prototype.removeSocket=function(e){var r=this.sockets.indexOf(e);if(r!==-1){this.sockets.splice(r,1);var i=this.requests.shift();i&&this.createSocket(i,function(n){i.request.onSocket(n)})}};function L5(t,e){var r=this;iA.prototype.createSocket.call(r,t,function(i){var n=t.request.getHeader("host"),s=_P({},r.options,{socket:i,servername:n?n.replace(/:.*$/,""):t.host}),o=mDe.connect(0,s);r.sockets[r.sockets.indexOf(i)]=o,e(o)})}function T5(t,e,r){return typeof t=="string"?{host:t,port:e,localAddress:r}:t}function _P(t){for(var e=1,r=arguments.length;e<r;++e){var i=arguments[e];if(typeof i=="object")for(var n=Object.keys(i),s=0,o=n.length;s<o;++s){var a=n[s];i[a]!==void 0&&(t[a]=i[a])}}return t}var gl;process.env.NODE_DEBUG&&/\btunnel\b/.test(process.env.NODE_DEBUG)?gl=function(){var t=Array.prototype.slice.call(arguments);typeof t[0]=="string"?t[0]="TUNNEL: "+t[0]:t.unshift("TUNNEL:"),console.error.apply(console,t)}:gl=function(){};sf.debug=gl});var K5=w((Jot,M5)=>{M5.exports=O5()});var _5=w((Ww,eD)=>{var z5=Object.assign({},require("fs")),tD=function(){var t=typeof document!="undefined"&&document.currentScript?document.currentScript.src:void 0;return typeof __filename!="undefined"&&(t=t||__filename),function(e){e=e||{};var r=typeof e!="undefined"?e:{},i,n;r.ready=new Promise(function(d,E){i=d,n=E});var s={},o;for(o in r)r.hasOwnProperty(o)&&(s[o]=r[o]);var a=[],l="./this.program",c=function(d,E){throw E},u=!1,g=!0,f="";function h(d){return r.locateFile?r.locateFile(d,f):f+d}var p,m,y,b;g&&(u?f=require("path").dirname(f)+"/":f=__dirname+"/",p=function(E,I){var D=Qa(E);return D?I?D:D.toString():(y||(y=z5),b||(b=require("path")),E=b.normalize(E),y.readFileSync(E,I?null:"utf8"))},m=function(E){var I=p(E,!0);return I.buffer||(I=new Uint8Array(I)),X(I.buffer),I},process.argv.length>1&&(l=process.argv[1].replace(/\\/g,"/")),a=process.argv.slice(2),c=function(d){process.exit(d)},r.inspect=function(){return"[Emscripten Module object]"});var S=r.print||console.log.bind(console),k=r.printErr||console.warn.bind(console);for(o in s)s.hasOwnProperty(o)&&(r[o]=s[o]);s=null,r.arguments&&(a=r.arguments),r.thisProgram&&(l=r.thisProgram),r.quit&&(c=r.quit);var T=16;function Y(d,E){return E||(E=T),Math.ceil(d/E)*E}var j=0,Z=function(d){j=d},J;r.wasmBinary&&(J=r.wasmBinary);var re=r.noExitRuntime||!0;typeof WebAssembly!="object"&&Sr("no native wasm support detected");function ee(d,E,I){switch(E=E||"i8",E.charAt(E.length-1)==="*"&&(E="i32"),E){case"i1":return de[d>>0];case"i8":return de[d>>0];case"i16":return Qe[d>>1];case"i32":return fe[d>>2];case"i64":return fe[d>>2];case"float":return Ht[d>>2];case"double":return Mt[d>>3];default:Sr("invalid type for getValue: "+E)}return null}var A,oe=!1,le;function X(d,E){d||Sr("Assertion failed: "+E)}function O(d){var E=r["_"+d];return X(E,"Cannot call unknown function "+d+", make sure it is exported"),E}function L(d,E,I,D,M){var _={string:function(nt){var It=0;if(nt!=null&&nt!==0){var ke=(nt.length<<2)+1;It=B(ke),be(nt,It,ke)}return It},array:function(nt){var It=B(nt.length);return Ue(nt,It),It}};function ne(nt){return E==="string"?te(nt):E==="boolean"?Boolean(nt):nt}var Be=O(d),Ee=[],_e=0;if(D)for(var ot=0;ot<D.length;ot++){var wt=_[I[ot]];wt?(_e===0&&(_e=NE()),Ee[ot]=wt(D[ot])):Ee[ot]=D[ot]}var ut=Be.apply(null,Ee);return ut=ne(ut),_e!==0&&LE(_e),ut}function pe(d,E,I,D){I=I||[];var M=I.every(function(ne){return ne==="number"}),_=E!=="string";return _&&M&&!D?O(d):function(){return L(d,E,I,arguments,D)}}var Ce=typeof TextDecoder!="undefined"?new TextDecoder("utf8"):void 0;function Oe(d,E,I){for(var D=E+I,M=E;d[M]&&!(M>=D);)++M;if(M-E>16&&d.subarray&&Ce)return Ce.decode(d.subarray(E,M));for(var _="";E<M;){var ne=d[E++];if(!(ne&128)){_+=String.fromCharCode(ne);continue}var Be=d[E++]&63;if((ne&224)==192){_+=String.fromCharCode((ne&31)<<6|Be);continue}var Ee=d[E++]&63;if((ne&240)==224?ne=(ne&15)<<12|Be<<6|Ee:ne=(ne&7)<<18|Be<<12|Ee<<6|d[E++]&63,ne<65536)_+=String.fromCharCode(ne);else{var _e=ne-65536;_+=String.fromCharCode(55296|_e>>10,56320|_e&1023)}}return _}function te(d,E){return d?Oe(V,d,E):""}function se(d,E,I,D){if(!(D>0))return 0;for(var M=I,_=I+D-1,ne=0;ne<d.length;++ne){var Be=d.charCodeAt(ne);if(Be>=55296&&Be<=57343){var Ee=d.charCodeAt(++ne);Be=65536+((Be&1023)<<10)|Ee&1023}if(Be<=127){if(I>=_)break;E[I++]=Be}else if(Be<=2047){if(I+1>=_)break;E[I++]=192|Be>>6,E[I++]=128|Be&63}else if(Be<=65535){if(I+2>=_)break;E[I++]=224|Be>>12,E[I++]=128|Be>>6&63,E[I++]=128|Be&63}else{if(I+3>=_)break;E[I++]=240|Be>>18,E[I++]=128|Be>>12&63,E[I++]=128|Be>>6&63,E[I++]=128|Be&63}}return E[I]=0,I-M}function be(d,E,I){return se(d,V,E,I)}function he(d){for(var E=0,I=0;I<d.length;++I){var D=d.charCodeAt(I);D>=55296&&D<=57343&&(D=65536+((D&1023)<<10)|d.charCodeAt(++I)&1023),D<=127?++E:D<=2047?E+=2:D<=65535?E+=3:E+=4}return E}function Fe(d) Line truncated
`)):typeof readline=="function"&&(E=readline(),E!==null&&(E+=`
`));if(!E)return null;d.input=FA(E,!0)}return d.input.shift()},put_char:function(d,E){E===null||E===10?(S(Oe(d.output,0)),d.output=[]):E!=0&&d.output.push(E)},flush:function(d){d.output&&d.output.length>0&&(S(Oe(d.output,0)),d.output=[])}},default_tty1_ops:{put_char:function(d,E){E===null||E===10?(k(Oe(d.output,0)),d.output=[]):E!=0&&d.output.push(E)},flush:function(d){d.output&&d.output.length>0&&(k(Oe(d.output,0)),d.output=[])}}};function ps(d){for(var E=Y(d,65536),I=Et(E);d<E;)de[I+d++]=0;return I}var pt={ops_table:null,mount:function(d){return pt.createNode(null,"/",16384|511,0)},createNode:function(d,E,I,D){if(v.isBlkdev(I)||v.isFIFO(I))throw new v.ErrnoError(63);pt.ops_table||(pt.ops_table={dir:{node:{getattr:pt.node_ops.getattr,setattr:pt.node_ops.setattr,lookup:pt.node_ops.lookup,mknod:pt.node_ops.mknod,rename:pt.node_ops.rename,unlink:pt.node_ops.unlink,rmdir:pt.node_ops.rmdir,readdir:pt.node_ops.readdir,symlink:pt.node_ops.symlink},stream:{llseek:pt.stream_ops.llseek}},file:{node:{getattr:pt.node_ops.getattr,setattr:pt.node_ops.setattr},stream:{llseek:pt.stream_ops.llseek,read:pt.stream_ops.read,write:pt.stream_ops.write,allocate:pt.stream_ops.allocate,mmap:pt.stream_ops.mmap,msync:pt.stream_ops.msync}},link:{node:{getattr:pt.node_ops.getattr,setattr:pt.node_ops.setattr,readlink:pt.node_ops.readlink},stream:{}},chrdev:{node:{getattr:pt.node_ops.getattr,setattr:pt.node_ops.setattr},stream:v.chrdev_stream_ops}});var M=v.createNode(d,E,I,D);return v.isDir(M.mode)?(M.node_ops=pt.ops_table.dir.node,M.stream_ops=pt.ops_table.dir.stream,M.contents={}):v.isFile(M.mode)?(M.node_ops=pt.ops_table.file.node,M.stream_ops=pt.ops_table.file.stream,M.usedBytes=0,M.contents=null):v.isLink(M.mode)?(M.node_ops=pt.ops_table.link.node,M.stream_ops=pt.ops_table.link.stream):v.isChrdev(M.mode)&&(M.node_ops=pt.ops_table.chrdev.node,M.stream_ops=pt.ops_table.chrdev.stream),M.timestamp=Date.now(),d&&(d.contents[E]=M,d.timestamp=M.timestamp),M},getFileDataAsTypedArray:function(d){return d.contents?d.contents.subarray?d.contents.subarray(0,d.usedBytes):new Uint8Array(d.contents):new Uint8Array(0)},expandFileStorage:function(d,E){var I=d.contents?d.contents.length:0;if(!(I>=E)){var D=1024*1024;E=Math.max(E,I*(I<D?2:1.125)>>>0),I!=0&&(E=Math.max(E,256));var M=d.contents;d.contents=new Uint8Array(E),d.usedBytes>0&&d.contents.set(M.subarray(0,d.usedBytes),0)}},resizeFileStorage:function(d,E){if(d.usedBytes!=E)if(E==0)d.contents=null,d.usedBytes=0;else{var I=d.contents;d.contents=new Uint8Array(E),I&&d.contents.set(I.subarray(0,Math.min(E,d.usedBytes))),d.usedBytes=E}},node_ops:{getattr:function(d){var E={};return E.dev=v.isChrdev(d.mode)?d.id:1,E.ino=d.id,E.mode=d.mode,E.nlink=1,E.uid=0,E.gid=0,E.rdev=d.rdev,v.isDir(d.mode)?E.size=4096:v.isFile(d.mode)?E.size=d.usedBytes:v.isLink(d.mode)?E.size=d.link.length:E.size=0,E.atime=new Date(d.timestamp),E.mtime=new Date(d.timestamp),E.ctime=new Date(d.timestamp),E.blksize=4096,E.blocks=Math.ceil(E.size/E.blksize),E},setattr:function(d,E){E.mode!==void 0&&(d.mode=E.mode),E.timestamp!==void 0&&(d.timestamp=E.timestamp),E.size!==void 0&&pt.resizeFileStorage(d,E.size)},lookup:function(d,E){throw v.genericErrors[44]},mknod:function(d,E,I,D){return pt.createNode(d,E,I,D)},rename:function(d,E,I){if(v.isDir(d.mode)){var D;try{D=v.lookupNode(E,I)}catch(_){}if(D)for(var M in D.contents)throw new v.ErrnoError(55)}delete d.parent.contents[d.name],d.parent.timestamp=Date.now(),d.name=I,E.contents[I]=d,E.timestamp=d.parent.timestamp,d.parent=E},unlink:function(d,E){delete d.contents[E],d.timestamp=Date.now()},rmdir:function(d,E){var I=v.lookupNode(d,E);for(var D in I.contents)throw new v.ErrnoError(55);delete d.contents[E],d.timestamp=Date.now()},readdir:function(d){var E=[".",".."];for(var I in d.contents)!d.contents.hasOwnProperty(I)||E.push(I);return E},symlink:function(d,E,I){var D=pt.createNode(d,E,511|40960,0);return D.link=I,D},readlink:function(d){if(!v.isLink(d.mode))throw new v.ErrnoError(28);return d.link}},stream_ops:{read:function(d,E,I,D,M){var _=d.node.contents;if(M>=d.node.usedBytes)return 0;var ne=Math.min(d.node.usedBytes-M,D);if(ne>8&&_.subarray)E.set(_.subarray(M,M+ne),I);else for(var Be=0;Be<ne;Be++)E[I+Be]=_[M+Be];return ne},write:function(d,E,I,D,M,_){if(E.buffer===de.buffer&&(_=!1),!D)return 0;var ne=d.node;if(ne.timestamp=Date.now(),E.subarray&&(!ne.contents||ne.contents.subarray)){if(_)return ne.contents=E.subarray(I,I+D),ne.usedBytes=D,D;if(ne.usedBytes===0&&M===0)return ne.contents=E.slice(I,I+D),ne.usedBytes=D,D;if(M+D<=ne.usedBytes)return ne.contents.set(E.subarray(I,I+D),M),D}if(pt.expandFileStorage(ne,M+D),ne.contents.subarray&&E.subarray)ne.contents.set(E.subarray(I,I+D),M);else for(var Be=0;Be<D;Be++)ne.contents[M+Be]=E[I+Be];return ne.usedBytes=Math.max(ne.usedBytes,M+D),D},llseek:function(d,E,I){var D=E;if(I===1?D+=d.position:I===2&&v.isFile(d.node.mode)&&(D+=d.node.usedBytes),D<0)throw new v.ErrnoError(28);return D},allocate:function(d,E,I){pt.expandFileStorage( Line truncated
`,n=Buffer.byteLength(i),s=Math.floor(Math.log(n)/Math.log(10))+1;return n+s>=Math.pow(10,s)&&(s+=1),s+n+i}};pB.parse=(t,e,r)=>new pB(yFe(wFe(t),e),r);var yFe=(t,e)=>e?Object.keys(t).reduce((r,i)=>(r[i]=t[i],r),e):t,wFe=t=>t.replace(/\n$/,"").split(`
`).reduce(BFe,Object.create(null)),BFe=(t,e)=>{let r=parseInt(e,10);if(r!==Buffer.byteLength(e)+1)return t;e=e.substr((r+" ").length);let i=e.split("="),n=i.shift().replace(/^SCHILY\.(dev|ino|nlink)/,"$1");if(!n)return t;let s=i.join("=");return t[n]=/^([A-Z]+\.)?([mac]|birth|creation)time$/.test(n)?new Date(s*1e3):/^[0-9]+$/.test(s)?+s:s,t};Y6.exports=pB});var CB=w((RAt,q6)=>{"use strict";q6.exports=t=>class extends t{warn(e,r,i={}){this.file&&(i.file=this.file),this.cwd&&(i.cwd=this.cwd),i.code=r instanceof Error&&r.code||e,i.tarCode=e,!this.strict&&i.recoverable!==!1?(r instanceof Error&&(i=Object.assign(r,i),r=r.message),this.emit("warn",i.tarCode,r,i)):r instanceof Error?this.emit("error",Object.assign(r,i)):this.emit("error",Object.assign(new Error(`${e}: ${r}`),i))}}});var FD=w((FAt,J6)=>{"use strict";var mB=["|","<",">","?",":"],RD=mB.map(t=>String.fromCharCode(61440+t.charCodeAt(0))),bFe=new Map(mB.map((t,e)=>[t,RD[e]])),QFe=new Map(RD.map((t,e)=>[t,mB[e]]));J6.exports={encode:t=>mB.reduce((e,r)=>e.split(r).join(bFe.get(r)),t),decode:t=>RD.reduce((e,r)=>e.split(r).join(QFe.get(r)),t)}});var z6=w((NAt,W6)=>{"use strict";W6.exports=(t,e,r)=>(t&=4095,r&&(t=(t|384)&~18),e&&(t&256&&(t|=64),t&32&&(t|=8),t&4&&(t|=1)),t)});var UD=w((KAt,_6)=>{"use strict";var V6=Af(),X6=dB(),Z6=uf(),LAt=$d(),ra=require("fs"),gf=require("path"),TAt=Zd(),vFe=16*1024*1024,$6=Symbol("process"),eV=Symbol("file"),tV=Symbol("directory"),ND=Symbol("symlink"),rV=Symbol("hardlink"),eC=Symbol("header"),EB=Symbol("read"),LD=Symbol("lstat"),IB=Symbol("onlstat"),TD=Symbol("onread"),OD=Symbol("onreadlink"),MD=Symbol("openfile"),KD=Symbol("onopenfile"),Zc=Symbol("close"),yB=Symbol("mode"),iV=CB(),SFe=FD(),nV=z6(),wB=iV(class extends V6{constructor(e,r){if(r=r||{},super(r),typeof e!="string")throw new TypeError("path is required");this.path=e,this.portable=!!r.portable,this.myuid=process.getuid&&process.getuid(),this.myuser=process.env.USER||"",this.maxReadSize=r.maxReadSize||vFe,this.linkCache=r.linkCache||new Map,this.statCache=r.statCache||new Map,this.preservePaths=!!r.preservePaths,this.cwd=r.cwd||process.cwd(),this.strict=!!r.strict,this.noPax=!!r.noPax,this.noMtime=!!r.noMtime,this.mtime=r.mtime||null,typeof r.onwarn=="function"&&this.on("warn",r.onwarn);let i=!1;if(!this.preservePaths&&gf.win32.isAbsolute(e)){let n=gf.win32.parse(e);this.path=e.substr(n.root.length),i=n.root}this.win32=!!r.win32||process.platform==="win32",this.win32&&(this.path=SFe.decode(this.path.replace(/\\/g,"/")),e=e.replace(/\\/g,"/")),this.absolute=r.absolute||gf.resolve(this.cwd,e),this.path===""&&(this.path="./"),i&&this.warn("TAR_ENTRY_INFO",`stripping ${i} from absolute path`,{entry:this,path:i+this.path}),this.statCache.has(this.absolute)?this[IB](this.statCache.get(this.absolute)):this[LD]()}[LD](){ra.lstat(this.absolute,(e,r)=>{if(e)return this.emit("error",e);this[IB](r)})}[IB](e){this.statCache.set(this.absolute,e),this.stat=e,e.isFile()||(e.size=0),this.type=kFe(e),this.emit("stat",e),this[$6]()}[$6](){switch(this.type){case"File":return this[eV]();case"Directory":return this[tV]();case"SymbolicLink":return this[ND]();default:return this.end()}}[yB](e){return nV(e,this.type==="Directory",this.portable)}[eC](){this.type==="Directory"&&this.portable&&(this.noMtime=!0),this.header=new Z6({path:this.path,linkpath:this.linkpath,mode:this[yB](this.stat.mode),uid:this.portable?null:this.stat.uid,gid:this.portable?null:this.stat.gid,size:this.stat.size,mtime:this.noMtime?null:this.mtime||this.stat.mtime,type:this.type,uname:this.portable?null:this.stat.uid===this.myuid?this.myuser:"",atime:this.portable?null:this.stat.atime,ctime:this.portable?null:this.stat.ctime}),this.header.encode()&&!this.noPax&&this.write(new X6({atime:this.portable?null:this.header.atime,ctime:this.portable?null:this.header.ctime,gid:this.portable?null:this.header.gid,mtime:this.noMtime?null:this.mtime||this.header.mtime,path:this.path,linkpath:this.linkpath,size:this.header.size,uid:this.portable?null:this.header.uid,uname:this.portable?null:this.header.uname,dev:this.portable?null:this.stat.dev,ino:this.portable?null:this.stat.ino,nlink:this.portable?null:this.stat.nlink}).encode()),this.write(this.header.block)}[tV](){this.path.substr(-1)!=="/"&&(this.path+="/"),this.stat.size=0,this[eC](),this.end()}[ND](){ra.readlink(this.absolute,(e,r)=>{if(e)return this.emit("error",e);this[OD](r)})}[OD](e){this.linkpath=e.replace(/\\/g,"/"),this[eC](),this.end()}[rV](e){this.type="Link",this.linkpath=gf.relative(this.cwd,e).replace(/\\/g,"/"),this.stat.size=0,this[eC](),this.end()}[eV](){if(this.stat.nlink>1){let e=this.stat.dev+":"+this.stat.ino;if(this.linkCache.has(e)){let r=this.linkCache.get(e);if(r.indexOf(this.cwd)===0)return this[rV](r)}this.linkCache.set(e,this.absolute)}if(this[eC](),this.stat.size===0)return this.end();this[MD]()}[MD](){ra.open(this.absolute,"r",(e,r)=>{if(e)return this.emit("error",e);this[KD](r)})}[KD](e){let r=512*Math.ceil(this.stat.size/512),i=Math.min(r,th Line truncated
`}),a},i})});var fA=w(RR=>{"use strict";Object.defineProperty(RR,"__esModule",{value:!0});RR.default=h7;function h7(){}h7.prototype={diff:function(e,r){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=i.callback;typeof i=="function"&&(n=i,i={}),this.options=i;var s=this;function o(m){return n?(setTimeout(function(){n(void 0,m)},0),!0):m}e=this.castInput(e),r=this.castInput(r),e=this.removeEmpty(this.tokenize(e)),r=this.removeEmpty(this.tokenize(r));var a=r.length,l=e.length,c=1,u=a+l,g=[{newPos:-1,components:[]}],f=this.extractCommon(g[0],r,e,0);if(g[0].newPos+1>=a&&f+1>=l)return o([{value:this.join(r),count:r.length}]);function h(){for(var m=-1*c;m<=c;m+=2){var y=void 0,b=g[m-1],S=g[m+1],k=(S?S.newPos:0)-m;b&&(g[m-1]=void 0);var T=b&&b.newPos+1<a,Y=S&&0<=k&&k<l;if(!T&&!Y){g[m]=void 0;continue}if(!T||Y&&b.newPos<S.newPos?(y=fLe(S),s.pushComponent(y.components,void 0,!0)):(y=b,y.newPos++,s.pushComponent(y.components,!0,void 0)),k=s.extractCommon(y,r,e,m),y.newPos+1>=a&&k+1>=l)return o(gLe(s,y.components,r,e,s.useLongestToken));g[m]=y}c++}if(n)(function m(){setTimeout(function(){if(c>u)return n();h()||m()},0)})();else for(;c<=u;){var p=h();if(p)return p}},pushComponent:function(e,r,i){var n=e[e.length-1];n&&n.added===r&&n.removed===i?e[e.length-1]={count:n.count+1,added:r,removed:i}:e.push({count:1,added:r,removed:i})},extractCommon:function(e,r,i,n){for(var s=r.length,o=i.length,a=e.newPos,l=a-n,c=0;a+1<s&&l+1<o&&this.equals(r[a+1],i[l+1]);)a++,l++,c++;return c&&e.components.push({count:c}),e.newPos=a,l},equals:function(e,r){return this.options.comparator?this.options.comparator(e,r):e===r||this.options.ignoreCase&&e.toLowerCase()===r.toLowerCase()},removeEmpty:function(e){for(var r=[],i=0;i<e.length;i++)e[i]&&r.push(e[i]);return r},castInput:function(e){return e},tokenize:function(e){return e.split("")},join:function(e){return e.join("")}};function gLe(t,e,r,i,n){for(var s=0,o=e.length,a=0,l=0;s<o;s++){var c=e[s];if(c.removed){if(c.value=t.join(i.slice(l,l+c.count)),l+=c.count,s&&e[s-1].added){var g=e[s-1];e[s-1]=e[s],e[s]=g}}else{if(!c.added&&n){var u=r.slice(a,a+c.count);u=u.map(function(h,p){var m=i[l+p];return m.length>h.length?m:h}),c.value=t.join(u)}else c.value=t.join(r.slice(a,a+c.count));a+=c.count,c.added||(l+=c.count)}}var f=e[o-1];return o>1&&typeof f.value=="string"&&(f.added||f.removed)&&t.equals("",f.value)&&(e[o-2].value+=f.value,e.pop()),e}function fLe(t){return{newPos:t.newPos,components:t.components.slice(0)}}});var d7=w(cC=>{"use strict";Object.defineProperty(cC,"__esModule",{value:!0});cC.diffChars=hLe;cC.characterDiff=void 0;var dLe=pLe(fA());function pLe(t){return t&&t.__esModule?t:{default:t}}var p7=new dLe.default;cC.characterDiff=p7;function hLe(t,e,r){return p7.diff(t,e,r)}});var NR=w(FR=>{"use strict";Object.defineProperty(FR,"__esModule",{value:!0});FR.generateOptions=CLe;function CLe(t,e){if(typeof t=="function")e.callback=t;else if(t)for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r]);return e}});var E7=w(vf=>{"use strict";Object.defineProperty(vf,"__esModule",{value:!0});vf.diffWords=mLe;vf.diffWordsWithSpace=ELe;vf.wordDiff=void 0;var yLe=ILe(fA()),wLe=NR();function ILe(t){return t&&t.__esModule?t:{default:t}}var C7=/^[A-Za-z\xC0-\u02C6\u02C8-\u02D7\u02DE-\u02FF\u1E00-\u1EFF]+$/,m7=/\S/,uC=new yLe.default;vf.wordDiff=uC;uC.equals=function(t,e){return this.options.ignoreCase&&(t=t.toLowerCase(),e=e.toLowerCase()),t===e||this.options.ignoreWhitespace&&!m7.test(t)&&!m7.test(e)};uC.tokenize=function(t){for(var e=t.split(/(\s+|[()[\]{}'"]|\b)/),r=0;r<e.length-1;r++)!e[r+1]&&e[r+2]&&C7.test(e[r])&&C7.test(e[r+2])&&(e[r]+=e[r+2],e.splice(r+1,2),r--);return e};function mLe(t,e,r){return r=(0,wLe.generateOptions)(r,{ignoreWhitespace:!0}),uC.diff(t,e,r)}function ELe(t,e,r){return uC.diff(t,e,r)}});var $B=w(Sf=>{"use strict";Object.defineProperty(Sf,"__esModule",{value:!0});Sf.diffLines=BLe;Sf.diffTrimmedLines=bLe;Sf.lineDiff=void 0;var vLe=QLe(fA()),SLe=NR();function QLe(t){return t&&t.__esModule?t:{default:t}}var ZB=new vLe.default;Sf.lineDiff=ZB;ZB.tokenize=function(t){var e=[],r=t.split(/(\n|\r\n)/);r[r.length-1]||r.pop();for(var i=0;i<r.length;i++){var n=r[i];i%2&&!this.options.newlineIsToken?e[e.length-1]+=n:(this.options.ignoreWhitespace&&(n=n.trim()),e.push(n))}return e};function BLe(t,e,r){return ZB.diff(t,e,r)}function bLe(t,e,r){var i=(0,SLe.generateOptions)(r,{ignoreWhitespace:!0});return ZB.diff(t,e,i)}});var I7=w(gC=>{"use strict";Object.defineProperty(gC,"__esModule",{value:!0});gC.diffSentences=kLe;gC.sentenceDiff=void 0;var PLe=xLe(fA());function xLe(t){return t&&t.__esModule?t:{default:t}}var LR=new PLe.default;gC.sentenceDiff=LR;LR.tokenize=function(t){return t.split(/(\S.+?[.!?])(?=\s+|$)/)};function kLe(t,e,r){return LR.diff(t,e,r)}});var y7=w(fC=>{"use strict";Object.defineProperty(fC,"__esModule",{value:!0});fC.diffCss=DLe;fC.cssDiff=void 0;var FLe=RLe(fA());function RLe(t){return t&&t.__esModule?t:{default:t}}var TR=new FLe.default;fC.cssDiff=TR;TR Line truncated
`),m==="+"?h++:m==="-"?p++:m===" "&&(h++,p++);else break}if(!h&&f.newLines===1&&(f.newLines=0),!p&&f.oldLines===1&&(f.oldLines=0),e.strict){if(h!==f.newLines)throw new Error("Added line count did not match for hunk at line "+(c+1));if(p!==f.oldLines)throw new Error("Removed line count did not match for hunk at line "+(c+1))}return f}for(;s<r.length;)o();return n}});var Q7=w(MR=>{"use strict";Object.defineProperty(MR,"__esModule",{value:!0});MR.default=GLe;function GLe(t,e,r){var i=!0,n=!1,s=!1,o=1;return function a(){if(i&&!s){if(n?o++:i=!1,t+o<=r)return o;s=!0}if(!n)return s||(i=!0),e<=t-o?-o++:(n=!0,a())}}});var k7=w(i0=>{"use strict";Object.defineProperty(i0,"__esModule",{value:!0});i0.applyPatch=v7;i0.applyPatches=jLe;var S7=r0(),qLe=YLe(Q7());function YLe(t){return t&&t.__esModule?t:{default:t}}function v7(t,e){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(typeof e=="string"&&(e=(0,S7.parsePatch)(e)),Array.isArray(e)){if(e.length>1)throw new Error("applyPatch only works with a single input.");e=e[0]}var i=t.split(/\r\n|[\n\v\f\r\x85]/),n=t.match(/\r\n|[\n\v\f\r\x85]/g)||[],s=e.hunks,o=r.compareLine||function(O,L,pe,Ce){return L===Ce},a=0,l=r.fuzzFactor||0,c=0,u=0,g,f;function h(O,L){for(var pe=0;pe<O.lines.length;pe++){var Ce=O.lines[pe],Oe=Ce.length>0?Ce[0]:" ",te=Ce.length>0?Ce.substr(1):Ce;if(Oe===" "||Oe==="-"){if(!o(L+1,i[L],Oe,te)&&(a++,a>l))return!1;L++}}return!0}for(var p=0;p<s.length;p++){for(var m=s[p],y=i.length-m.oldLines,b=0,S=u+m.oldStart-1,k=(0,qLe.default)(S,c,y);b!==void 0;b=k())if(h(m,S+b)){m.offset=u+=b;break}if(b===void 0)return!1;c=m.offset+m.oldStart+m.oldLines}for(var T=0,Y=0;Y<s.length;Y++){var j=s[Y],Z=j.oldStart+j.offset+T-1;T+=j.newLines-j.oldLines,Z<0&&(Z=0);for(var J=0;J<j.lines.length;J++){var re=j.lines[J],ee=re.length>0?re[0]:" ",A=re.length>0?re.substr(1):re,oe=j.linedelimiters[J];if(ee===" ")Z++;else if(ee==="-")i.splice(Z,1),n.splice(Z,1);else if(ee==="+")i.splice(Z,0,A),n.splice(Z,0,oe),Z++;else if(ee==="\\"){var le=j.lines[J-1]?j.lines[J-1][0]:null;le==="+"?g=!0:le==="-"&&(f=!0)}}}if(g)for(;!i[i.length-1];)i.pop(),n.pop();else f&&(i.push(""),n.push(`
`));for(var X=0;X<i.length-1;X++)i[X]=i[X]+n[X];return i.join("")}function jLe(t,e){typeof t=="string"&&(t=(0,S7.parsePatch)(t));var r=0;function i(){var n=t[r++];if(!n)return e.complete();e.loadFile(n,function(s,o){if(s)return e.complete(s);var a=v7(o,n,e);e.patched(n,a,function(l){if(l)return e.complete(l);i()})})}i()}});var UR=w(dC=>{"use strict";Object.defineProperty(dC,"__esModule",{value:!0});dC.structuredPatch=x7;dC.createTwoFilesPatch=P7;dC.createPatch=JLe;var WLe=$B();function KR(t){return VLe(t)||_Le(t)||zLe()}function zLe(){throw new TypeError("Invalid attempt to spread non-iterable instance")}function _Le(t){if(Symbol.iterator in Object(t)||Object.prototype.toString.call(t)==="[object Arguments]")return Array.from(t)}function VLe(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e<t.length;e++)r[e]=t[e];return r}}function x7(t,e,r,i,n,s,o){o||(o={}),typeof o.context=="undefined"&&(o.context=4);var a=(0,WLe.diffLines)(r,i,o);a.push({value:"",lines:[]});function l(b){return b.map(function(S){return" "+S})}for(var c=[],u=0,g=0,f=[],h=1,p=1,m=function(S){var k=a[S],T=k.lines||k.value.replace(/\n$/,"").split(`
`);if(k.lines=T,k.added||k.removed){var Y;if(!u){var j=a[S-1];u=h,g=p,j&&(f=o.context>0?l(j.lines.slice(-o.context)):[],u-=f.length,g-=f.length)}(Y=f).push.apply(Y,KR(T.map(function(X){return(k.added?"+":"-")+X}))),k.added?p+=T.length:h+=T.length}else{if(u)if(T.length<=o.context*2&&S<a.length-2){var Z;(Z=f).push.apply(Z,KR(l(T)))}else{var J,re=Math.min(T.length,o.context);(J=f).push.apply(J,KR(l(T.slice(0,re))));var ee={oldStart:u,oldLines:h-u+re,newStart:g,newLines:p-g+re,lines:f};if(S>=a.length-2&&T.length<=o.context){var A=/\n$/.test(r),oe=/\n$/.test(i),le=T.length==0&&f.length>ee.oldLines;!A&&le&&f.splice(ee.oldLines,0,"\\ No newline at end of file"),(!A&&!le||!oe)&&f.push("\\ No newline at end of file")}c.push(ee),u=0,g=0,f=[]}h+=T.length,p+=T.length}},y=0;y<a.length;y++)m(y);return{oldFileName:t,newFileName:e,oldHeader:n,newHeader:s,hunks:c}}function P7(t,e,r,i,n,s,o){var a=x7(t,e,r,i,n,s,o),l=[];t==e&&l.push("Index: "+t),l.push("==================================================================="),l.push("--- "+a.oldFileName+(typeof a.oldHeader=="undefined"?"":" "+a.oldHeader)),l.push("+++ "+a.newFileName+(typeof a.newHeader=="undefined"?"":" "+a.newHeader));for(var c=0;c<a.hunks.length;c++){var u=a.hunks[c];l.push("@@ -"+u.oldStart+","+u.oldLines+" +"+u.newStart+","+u.newLines+" @@"),l.push.apply(l,u.lines)}return l.join(`
`)+`
`}function JLe(t,e,r,i,n,s){return P7(t,t,e,r,i,n,s)}});var R7=w(n0=>{"use strict";Object.defineProperty(n0,"__esModule",{value:!0});n0.arrayEqual=XLe;n0.arrayStartsWith=D7;function XLe(t,e){return t.length!==e.length?!1:D7(t,e)}function D7(t,e){if(e.length>t.length)return!1;for(var r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}});var j7=w(s0=>{"use strict";Object.defineProperty(s0,"__esModule",{value:!0});s0.calcLineCount=F7;s0.merge=ZLe;var $Le=UR(),eTe=r0(),HR=R7();function xf(t){return iTe(t)||rTe(t)||tTe()}function tTe(){throw new TypeError("Invalid attempt to spread non-iterable instance")}function rTe(t){if(Symbol.iterator in Object(t)||Object.prototype.toString.call(t)==="[object Arguments]")return Array.from(t)}function iTe(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e<t.length;e++)r[e]=t[e];return r}}function F7(t){var e=GR(t.lines),r=e.oldLines,i=e.newLines;r!==void 0?t.oldLines=r:delete t.oldLines,i!==void 0?t.newLines=i:delete t.newLines}function ZLe(t,e,r){t=N7(t,r),e=N7(e,r);var i={};(t.index||e.index)&&(i.index=t.index||e.index),(t.newFileName||e.newFileName)&&(L7(t)?L7(e)?(i.oldFileName=o0(i,t.oldFileName,e.oldFileName),i.newFileName=o0(i,t.newFileName,e.newFileName),i.oldHeader=o0(i,t.oldHeader,e.oldHeader),i.newHeader=o0(i,t.newHeader,e.newHeader)):(i.oldFileName=t.oldFileName,i.newFileName=t.newFileName,i.oldHeader=t.oldHeader,i.newHeader=t.newHeader):(i.oldFileName=e.oldFileName||t.oldFileName,i.newFileName=e.newFileName||t.newFileName,i.oldHeader=e.oldHeader||t.oldHeader,i.newHeader=e.newHeader||t.newHeader)),i.hunks=[];for(var n=0,s=0,o=0,a=0;n<t.hunks.length||s<e.hunks.length;){var l=t.hunks[n]||{oldStart:Infinity},c=e.hunks[s]||{oldStart:Infinity};if(T7(l,c))i.hunks.push(O7(l,o)),n++,a+=l.newLines-l.oldLines;else if(T7(c,l))i.hunks.push(O7(c,a)),s++,o+=c.newLines-c.oldLines;else{var u={oldStart:Math.min(l.oldStart,c.oldStart),oldLines:0,newStart:Math.min(l.newStart+o,c.oldStart+a),newLines:0,lines:[]};nTe(u,l.oldStart,l.lines,c.oldStart,c.lines),s++,n++,i.hunks.push(u)}}return i}function N7(t,e){if(typeof t=="string"){if(/^@@/m.test(t)||/^Index:/m.test(t))return(0,eTe.parsePatch)(t)[0];if(!e)throw new Error("Must provide a base reference or pass in a patch");return(0,$Le.structuredPatch)(void 0,void 0,e,t)}return t}function L7(t){return t.newFileName&&t.newFileName!==t.oldFileName}function o0(t,e,r){return e===r?e:(t.conflict=!0,{mine:e,theirs:r})}function T7(t,e){return t.oldStart<e.oldStart&&t.oldStart+t.oldLines<e.oldStart}function O7(t,e){return{oldStart:t.oldStart,oldLines:t.oldLines,newStart:t.newStart+e,newLines:t.newLines,lines:t.lines}}function nTe(t,e,r,i,n){var s={offset:e,lines:r,index:0},o={offset:i,lines:n,index:0};for(K7(t,s,o),K7(t,o,s);s.index<s.lines.length&&o.index<o.lines.length;){var a=s.lines[s.index],l=o.lines[o.index];if((a[0]==="-"||a[0]==="+")&&(l[0]==="-"||l[0]==="+"))sTe(t,s,o);else if(a[0]==="+"&&l[0]===" "){var c;(c=t.lines).push.apply(c,xf(lu(s)))}else if(l[0]==="+"&&a[0]===" "){var u;(u=t.lines).push.apply(u,xf(lu(o)))}else a[0]==="-"&&l[0]===" "?M7(t,s,o):l[0]==="-"&&a[0]===" "?M7(t,o,s,!0):a===l?(t.lines.push(a),s.index++,o.index++):jR(t,lu(s),lu(o))}U7(t,s),U7(t,o),F7(t)}function sTe(t,e,r){var i=lu(e),n=lu(r);if(H7(i)&&H7(n)){if((0,HR.arrayStartsWith)(i,n)&&G7(r,i,i.length-n.length)){var s;(s=t.lines).push.apply(s,xf(i));return}else if((0,HR.arrayStartsWith)(n,i)&&G7(e,n,n.length-i.length)){var o;(o=t.lines).push.apply(o,xf(n));return}}else if((0,HR.arrayEqual)(i,n)){var a;(a=t.lines).push.apply(a,xf(i));return}jR(t,i,n)}function M7(t,e,r,i){var n=lu(e),s=oTe(r,n);if(s.merged){var o;(o=t.lines).push.apply(o,xf(s.merged))}else jR(t,i?s:n,i?n:s)}function jR(t,e,r){t.conflict=!0,t.lines.push({conflict:!0,mine:e,theirs:r})}function K7(t,e,r){for(;e.offset<r.offset&&e.index<e.lines.length;){var i=e.lines[e.index++];t.lines.push(i),e.offset++}}function U7(t,e){for(;e.index<e.lines.length;){var r=e.lines[e.index++];t.lines.push(r)}}function lu(t){for(var e=[],r=t.lines[t.index][0];t.index<t.lines.length;){var i=t.lines[t.index];if(r==="-"&&i[0]==="+"&&(r="+"),r===i[0])e.push(i),t.index++;else break}return e}function oTe(t,e){for(var r=[],i=[],n=0,s=!1,o=!1;n<e.length&&t.index<t.lines.length;){var a=t.lines[t.index],l=e[n];if(l[0]==="+")break;if(s=s||a[0]!==" ",i.push(l),n++,a[0]==="+")for(o=!0;a[0]==="+";)r.push(a),a=t.lines[++t.index];l.substr(1)===a.substr(1)?(r.push(a),t.index++):o=!0}if((e[n]||"")[0]==="+"&&s&&(o=!0),o)return r;for(;n<e.length;)i.push(e[n++]);return{merged:i,changes:r}}function H7(t){return t.reduce(function(e,r){return e&&r[0]==="-"},!0)}function G7(t,e,r){for(var i=0;i<r;i++){var n=e[e.length-r+i].substr(1);if(t.lines[t.index+i]!==" "+n)return!1}return t.index+=r,!0}function GR(t){var e=0,r=0;return t.forEach(function(i){if(typeof i!="string"){var n=GR(i.mine),s=GR(i.theirs);e!==void 0&&(n.oldLines===s.oldLines?e+=n.oldLines:e=void 0),r!==void 0&&(n.newLines===s.newLines?r+=n.newLines:r=void 0)}else r!==void 0& Line truncated
attempted value: ${s}
`+(o!==s?`result of cast: ${o}`:""))}return n}_cast(e,r){let i=e===void 0?e:this.transforms.reduce((n,s)=>s.call(this,n,e,this),e);return i===void 0&&(i=this.getDefault()),i}_validate(e,r={},i){let{sync:n,path:s,from:o=[],originalValue:a=e,strict:l=this.spec.strict,abortEarly:c=this.spec.abortEarly}=r,u=e;l||(u=this._cast(u,qs({assert:!1},r)));let g={value:u,path:s,options:r,originalValue:a,schema:this,label:this.spec.label,sync:n,from:o},f=[];this._typeError&&f.push(this._typeError),this._whitelistError&&f.push(this._whitelistError),this._blacklistError&&f.push(this._blacklistError),(0,zte.default)({args:g,value:u,path:s,sync:n,tests:f,endEarly:c},h=>{if(h)return void i(h,u);(0,zte.default)({tests:this.tests,args:g,path:s,sync:n,value:u,endEarly:c},i)})}validate(e,r,i){let n=this.resolve(qs({},r,{value:e}));return typeof i=="function"?n._validate(e,r,i):new Promise((s,o)=>n._validate(e,r,(a,l)=>{a?o(a):s(l)}))}validateSync(e,r){let i=this.resolve(qs({},r,{value:e})),n;return i._validate(e,qs({},r,{sync:!0}),(s,o)=>{if(s)throw s;n=o}),n}isValid(e,r){return this.validate(e,r).then(()=>!0,i=>{if(Vte.default.isError(i))return!1;throw i})}isValidSync(e,r){try{return this.validateSync(e,r),!0}catch(i){if(Vte.default.isError(i))return!1;throw i}}_getDefault(){let e=this.spec.default;return e==null?e:typeof e=="function"?e.call(this):(0,Wte.default)(e)}getDefault(e){return this.resolve(e||{})._getDefault()}default(e){return arguments.length===0?this._getDefault():this.clone({default:e})}strict(e=!0){var r=this.clone();return r.spec.strict=e,r}_isPresent(e){return e!=null}defined(e=jf.mixed.defined){return this.test({message:e,name:"defined",exclusive:!0,test(r){return r!==void 0}})}required(e=jf.mixed.required){return this.clone({presence:"required"}).withMutation(r=>r.test({message:e,name:"required",exclusive:!0,test(i){return this.schema._isPresent(i)}}))}notRequired(){var e=this.clone({presence:"optional"});return e.tests=e.tests.filter(r=>r.OPTIONS.name!=="required"),e}nullable(e=!0){var r=this.clone({nullable:e!==!1});return r}transform(e){var r=this.clone();return r.transforms.push(e),r}test(...e){let r;if(e.length===1?typeof e[0]=="function"?r={test:e[0]}:r=e[0]:e.length===2?r={name:e[0],test:e[1]}:r={name:e[0],message:e[1],test:e[2]},r.message===void 0&&(r.message=jf.mixed.default),typeof r.test!="function")throw new TypeError("`test` is a required parameters");let i=this.clone(),n=(0,O0.default)(r),s=r.exclusive||r.name&&i.exclusiveTests[r.name]===!0;if(r.exclusive&&!r.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return r.name&&(i.exclusiveTests[r.name]=!!r.exclusive),i.tests=i.tests.filter(o=>!(o.OPTIONS.name===r.name&&(s||o.OPTIONS.test===n.OPTIONS.test))),i.tests.push(n),i}when(e,r){!Array.isArray(e)&&typeof e!="string"&&(r=e,e=".");let i=this.clone(),n=(0,zGe.default)(e).map(s=>new JGe.default(s));return n.forEach(s=>{s.isSibling&&i.deps.push(s.key)}),i.conditions.push(new qGe.default(n,r)),i}typeError(e){var r=this.clone();return r._typeError=(0,O0.default)({message:e,name:"typeError",test(i){return i!==void 0&&!this.schema.isType(i)?this.createError({params:{type:this.schema._type}}):!0}}),r}oneOf(e,r=jf.mixed.oneOf){var i=this.clone();return e.forEach(n=>{i._whitelist.add(n),i._blacklist.delete(n)}),i._whitelistError=(0,O0.default)({message:r,name:"oneOf",test(n){if(n===void 0)return!0;let s=this.schema._whitelist;return s.has(n,this.resolve)?!0:this.createError({params:{values:s.toArray().join(", ")}})}}),i}notOneOf(e,r=jf.mixed.notOneOf){var i=this.clone();return e.forEach(n=>{i._blacklist.add(n),i._whitelist.delete(n)}),i._blacklistError=(0,O0.default)({message:r,name:"notOneOf",test(n){let s=this.schema._blacklist;return s.has(n,this.resolve)?this.createError({params:{values:s.toArray().join(", ")}}):!0}}),i}strip(e=!0){let r=this.clone();return r.spec.strip=e,r}describe(){let e=this.clone(),{label:r,meta:i}=e.spec;return{meta:i,label:r,type:e.type,oneOf:e._whitelist.describe(),notOneOf:e._blacklist.describe(),tests:e.tests.map(s=>({name:s.OPTIONS.name,params:s.OPTIONS.params})).filter((s,o,a)=>a.findIndex(l=>l.name===s.name)===o)}}};T0.default=Aa;Aa.prototype.__isYupSchema__=!0;for(let t of["validate","validateSync"])Aa.prototype[`${t}At`]=function(e,r,i={}){let{parent:n,parentPath:s,schema:o}=(0,WGe.getIn)(this,e,r,i.context);return o[t](n&&n[s],qs({},i,{parent:n,path:e}))};for(let t of["equals","is"])Aa.prototype[t]=Aa.prototype.oneOf;for(let t of["not","nope"])Aa.prototype[t]=Aa.prototype.notOneOf;Aa.prototype.optional=Aa.prototype.notRequired});var $te=w(UC=>{"use strict";Object.defineProperty(UC,"__esModule",{value:!0});UC.create=Zte;UC.default=void 0;var VGe=_Ge(dA());function _Ge(t){return t&&t.__esModule?t:{default:t}}var zF=VGe.default,XGe=zF;UC.default=XGe;function Zte(){return new zF}Zte.prototype=zF.prototype});var Yf=w(M0=>{"use strict";Object.defineProperty(M0,"__esModule",{value:!0});M0.default=void 0;var ZGe=t=>t==null;M0.defaul Line truncated
`),c=o.length;for(c>0&&o.includes("unstyle")&&(o=[...new Set(["unstyle",...o])].reverse());c-- >0;)a=r(t.styles[o[c]],a,l);return a},n=(s,o,a)=>{t.styles[s]=e({name:s,codes:o}),(t.keys[a]||(t.keys[a]=[])).push(s),Reflect.defineProperty(t,s,{configurable:!0,enumerable:!0,set(c){t.alias(s,c)},get(){let c=u=>i(u,c.stack);return Reflect.setPrototypeOf(c,t),c.stack=this.stack?this.stack.concat(s):[s],c}})};return n("reset",[0,0],"modifier"),n("bold",[1,22],"modifier"),n("dim",[2,22],"modifier"),n("italic",[3,23],"modifier"),n("underline",[4,24],"modifier"),n("inverse",[7,27],"modifier"),n("hidden",[8,28],"modifier"),n("strikethrough",[9,29],"modifier"),n("black",[30,39],"color"),n("red",[31,39],"color"),n("green",[32,39],"color"),n("yellow",[33,39],"color"),n("blue",[34,39],"color"),n("magenta",[35,39],"color"),n("cyan",[36,39],"color"),n("white",[37,39],"color"),n("gray",[90,39],"color"),n("grey",[90,39],"color"),n("bgBlack",[40,49],"bg"),n("bgRed",[41,49],"bg"),n("bgGreen",[42,49],"bg"),n("bgYellow",[43,49],"bg"),n("bgBlue",[44,49],"bg"),n("bgMagenta",[45,49],"bg"),n("bgCyan",[46,49],"bg"),n("bgWhite",[47,49],"bg"),n("blackBright",[90,39],"bright"),n("redBright",[91,39],"bright"),n("greenBright",[92,39],"bright"),n("yellowBright",[93,39],"bright"),n("blueBright",[94,39],"bright"),n("magentaBright",[95,39],"bright"),n("cyanBright",[96,39],"bright"),n("whiteBright",[97,39],"bright"),n("bgBlackBright",[100,49],"bgBright"),n("bgRedBright",[101,49],"bgBright"),n("bgGreenBright",[102,49],"bgBright"),n("bgYellowBright",[103,49],"bgBright"),n("bgBlueBright",[104,49],"bgBright"),n("bgMagentaBright",[105,49],"bgBright"),n("bgCyanBright",[106,49],"bgBright"),n("bgWhiteBright",[107,49],"bgBright"),t.ansiRegex=uqe,t.hasColor=t.hasAnsi=s=>(t.ansiRegex.lastIndex=0,typeof s=="string"&&s!==""&&t.ansiRegex.test(s)),t.alias=(s,o)=>{let a=typeof o=="string"?t[o]:o;if(typeof a!="function")throw new TypeError("Expected alias to be the name of an existing color (string) or a function");a.stack||(Reflect.defineProperty(a,"name",{value:s}),t.styles[s]=a,a.stack=[s]),Reflect.defineProperty(t,s,{configurable:!0,enumerable:!0,set(l){t.alias(s,l)},get(){let l=c=>i(c,l.stack);return Reflect.setPrototypeOf(l,t),l.stack=this.stack?this.stack.concat(a.stack):a.stack,l}})},t.theme=s=>{if(!cqe(s))throw new TypeError("Expected theme to be an object");for(let o of Object.keys(s))t.alias(o,s[o]);return t},t.alias("unstyle",s=>typeof s=="string"&&s!==""?(t.ansiRegex.lastIndex=0,s.replace(t.ansiRegex,"")):""),t.alias("noop",s=>s),t.none=t.clear=t.noop,t.stripColor=t.unstyle,t.symbols=xie(),t.define=n,t};cN.exports=Pie();cN.exports.create=Pie});var Xi=w(Lt=>{"use strict";var gqe=Object.prototype.toString,Js=mo(),Die=!1,uN=[],Rie={yellow:"blue",cyan:"red",green:"magenta",black:"white",blue:"yellow",red:"cyan",magenta:"green",white:"black"};Lt.longest=(t,e)=>t.reduce((r,i)=>Math.max(r,e?i[e].length:i.length),0);Lt.hasColor=t=>!!t&&Js.hasColor(t);var z0=Lt.isObject=t=>t!==null&&typeof t=="object"&&!Array.isArray(t);Lt.nativeType=t=>gqe.call(t).slice(8,-1).toLowerCase().replace(/\s/g,"");Lt.isAsyncFn=t=>Lt.nativeType(t)==="asyncfunction";Lt.isPrimitive=t=>t!=null&&typeof t!="object"&&typeof t!="function";Lt.resolve=(t,e,...r)=>typeof e=="function"?e.call(t,...r):e;Lt.scrollDown=(t=[])=>[...t.slice(1),t[0]];Lt.scrollUp=(t=[])=>[t.pop(),...t];Lt.reorder=(t=[])=>{let e=t.slice();return e.sort((r,i)=>r.index>i.index?1:r.index<i.index?-1:0),e};Lt.swap=(t,e,r)=>{let i=t.length,n=r===i?0:r<0?i-1:r,s=t[e];t[e]=t[n],t[n]=s};Lt.width=(t,e=80)=>{let r=t&&t.columns?t.columns:e;return t&&typeof t.getWindowSize=="function"&&(r=t.getWindowSize()[0]),process.platform==="win32"?r-1:r};Lt.height=(t,e=20)=>{let r=t&&t.rows?t.rows:e;return t&&typeof t.getWindowSize=="function"&&(r=t.getWindowSize()[1]),r};Lt.wordWrap=(t,e={})=>{if(!t)return t;typeof e=="number"&&(e={width:e});let{indent:r="",newline:i=`
`+r,width:n=80}=e;n-=((i+r).match(/[^\S\n]/g)||[]).length;let o=`.{1,${n}}([\\s\\u200B]+|$)|[^\\s\\u200B]+?([\\s\\u200B]+|$)`,a=t.trim(),l=new RegExp(o,"g"),c=a.match(l)||[];return c=c.map(u=>u.replace(/\n$/,"")),e.padEnd&&(c=c.map(u=>u.padEnd(n," "))),e.padStart&&(c=c.map(u=>u.padStart(n," "))),r+c.join(i)};Lt.unmute=t=>{let e=t.stack.find(i=>Js.keys.color.includes(i));return e?Js[e]:t.stack.find(i=>i.slice(2)==="bg")?Js[e.slice(2)]:i=>i};Lt.pascal=t=>t?t[0].toUpperCase()+t.slice(1):"";Lt.inverse=t=>{if(!t||!t.stack)return t;let e=t.stack.find(i=>Js.keys.color.includes(i));if(e){let i=Js["bg"+Lt.pascal(e)];return i?i.black:t}let r=t.stack.find(i=>i.slice(0,2)==="bg");return r?Js[r.slice(2).toLowerCase()]||t:Js.none};Lt.complement=t=>{if(!t||!t.stack)return t;let e=t.stack.find(i=>Js.keys.color.includes(i)),r=t.stack.find(i=>i.slice(0,2)==="bg");if(e&&!r)return Js[Rie[e]||e];if(r){let i=r.slice(2).toLowerCase(),n=Rie[i];return n&&Js["bg"+Lt.pascal(n)]||t}return Js.none};Lt.meridiem=t=>{let e=t.getHours(),r=t.getMinutes(),i=e>=12?"pm":"am";e=e%12;let n=e===0?12:e,s=r<10?"0"+r:r;return n+":"+s+" "+i};Lt.set=(t={},e="",r)=>e.split(".").reduce((i,n,s,o)=>{let a=o.length-1>s?i[n]||{}:r;return!Lt.isObject(a)&&s<o.length-1&&(a={}),i[n]=a},t);Lt.get=(t={},e="",r)=>{let i=t[e]==null?e.split(".").reduce((n,s)=>n&&n[s],t):t[e];return i==null?r:i};Lt.mixin=(t,e)=>{if(!z0(t))return e;if(!z0(e))return t;for(let r of Object.keys(e)){let i=Object.getOwnPropertyDescriptor(e,r);if(i.hasOwnProperty("value"))if(t.hasOwnProperty(r)&&z0(i.value)){let n=Object.getOwnPropertyDescriptor(t,r);z0(n.value)?t[r]=Lt.merge({},t[r],e[r]):Reflect.defineProperty(t,r,i)}else Reflect.defineProperty(t,r,i);else Reflect.defineProperty(t,r,i)}return t};Lt.merge=(...t)=>{let e={};for(let r of t)Lt.mixin(e,r);return e};Lt.mixinEmitter=(t,e)=>{let r=e.constructor.prototype;for(let i of Object.keys(r)){let n=r[i];typeof n=="function"?Lt.define(t,i,n.bind(e)):Lt.define(t,i,n)}};Lt.onExit=t=>{let e=(r,i)=>{Die||(Die=!0,uN.forEach(n=>n()),r===!0&&process.exit(128+i))};uN.length===0&&(process.once("SIGTERM",e.bind(null,!0,15)),process.once("SIGINT",e.bind(null,!0,2)),process.once("exit",e)),uN.push(t)};Lt.define=(t,e,r)=>{Reflect.defineProperty(t,e,{value:r})};Lt.defineExport=(t,e,r)=>{let i;Reflect.defineProperty(t,e,{enumerable:!0,configurable:!0,set(n){i=n},get(){return i?i():r()}})}});var Fie=w(_f=>{"use strict";_f.ctrl={a:"first",b:"backward",c:"cancel",d:"deleteForward",e:"last",f:"forward",g:"reset",i:"tab",k:"cutForward",l:"reset",n:"newItem",m:"cancel",j:"submit",p:"search",r:"remove",s:"save",u:"undo",w:"cutLeft",x:"toggleCursor",v:"paste"};_f.shift={up:"shiftUp",down:"shiftDown",left:"shiftLeft",right:"shiftRight",tab:"prev"};_f.fn={up:"pageUp",down:"pageDown",left:"pageLeft",right:"pageRight",delete:"deleteForward"};_f.option={b:"backward",f:"forward",d:"cutRight",left:"cutLeft",up:"altUp",down:"altDown"};_f.keys={pageup:"pageUp",pagedown:"pageDown",home:"home",end:"end",cancel:"cancel",delete:"deleteForward",backspace:"delete",down:"down",enter:"submit",escape:"cancel",left:"left",space:"space",number:"number",return:"submit",right:"right",tab:"next",up:"up"}});var Tie=w((kpt,Nie)=>{"use strict";var Lie=require("readline"),fqe=Fie(),hqe=/^(?:\x1b)([a-zA-Z0-9])$/,pqe=/^(?:\x1b+)(O|N|\[|\[\[)(?:(\d+)(?:;(\d+))?([~^$])|(?:1;)?(\d+)?([a-zA-Z]))/,dqe={OP:"f1",OQ:"f2",OR:"f3",OS:"f4","[11~":"f1","[12~":"f2","[13~":"f3","[14~":"f4","[[A":"f1","[[B":"f2","[[C":"f3","[[D":"f4","[[E":"f5","[15~":"f5","[17~":"f6","[18~":"f7","[19~":"f8","[20~":"f9","[21~":"f10","[23~":"f11","[24~":"f12","[A":"up","[B":"down","[C":"right","[D":"left","[E":"clear","[F":"end","[H":"home",OA:"up",OB:"down",OC:"right",OD:"left",OE:"clear",OF:"end",OH:"home","[1~":"home","[2~":"insert","[3~":"delete","[4~":"end","[5~":"pageup","[6~":"pagedown","[[5~":"pageup","[[6~":"pagedown","[7~":"home","[8~":"end","[a":"up","[b":"down","[c":"right","[d":"left","[e":"clear","[2$":"insert","[3$":"delete","[5$":"pageup","[6$":"pagedown","[7$":"home","[8$":"end",Oa:"up",Ob:"down",Oc:"right",Od:"left",Oe:"clear","[2^":"insert","[3^":"delete","[5^":"pageup","[6^":"pagedown","[7^":"home","[8^":"end","[Z":"tab"};function Cqe(t){return["[a","[b","[c","[d","[e","[2$","[3$","[5$","[6$","[7$","[8$","[Z"].includes(t)}function mqe(t){return["Oa","Ob","Oc","Od","Oe","[2^","[3^","[5^","[6^","[7^","[8^"].includes(t)}var _0=(t="",e={})=>{let r,i=N({name:e.name,ctrl:!1,meta:!1,shift:!1,option:!1,sequence:t,raw:t},e);if(Buffer.isBuffer(t)?t[0]>127&&t[1]===void 0?(t[0]-=128,t=""+String(t)):t=String(t):t!==void 0&&typeof t!="string"?t=String(t):t||(t=i.sequence||""),i.sequence=i.sequence||t||i.name,t==="\r")i.raw=void 0,i.name="return";else if(t===`
`)i.name="enter";else if(t===" ")i.name="tab";else if(t==="\b"||t==="\x7F"||t==="\x7F"||t==="\b")i.name="backspace",i.meta=t.charAt(0)==="";else if(t===""||t==="")i.name="escape",i.meta=t.length===2;else if(t===" "||t===" ")i.name="space",i.meta=t.length===2;else if(t<="")i.name=String.fromCharCode(t.charCodeAt(0)+"a".charCodeAt(0)-1),i.ctrl=!0;else if(t.length===1&&t>="0"&&t<="9")i.name="number";else if(t.length===1&&t>="a"&&t<="z")i.name=t;else if(t.length===1&&t>="A"&&t<="Z")i.name=t.toLowerCase(),i.shift=!0;else if(r=hqe.exec(t))i.meta=!0,i.shift=/^[A-Z]$/.test(r[1]);else if(r=pqe.exec(t)){let n=[...t];n[0]===""&&n[1]===""&&(i.option=!0);let s=[r[1],r[2],r[4],r[6]].filter(Boolean).join(""),o=(r[3]||r[5]||1)-1;i.ctrl=!!(o&4),i.meta=!!(o&10),i.shift=!!(o&1),i.code=s,i.name=dqe[s],i.shift=Cqe(s)||i.shift,i.ctrl=mqe(s)||i.ctrl}return i};_0.listen=(t={},e)=>{let{stdin:r}=t;if(!r||r!==process.stdin&&!r.isTTY)throw new Error("Invalid stream passed");let i=Lie.createInterface({terminal:!0,input:r});Lie.emitKeypressEvents(r,i);let n=(a,l)=>e(a,_0(a,l),i),s=r.isRaw;return r.isTTY&&r.setRawMode(!0),r.on("keypress",n),i.resume(),()=>{r.isTTY&&r.setRawMode(s),r.removeListener("keypress",n),i.pause(),i.close()}};_0.action=(t,e,r)=>{let i=N(N({},fqe),r);return e.ctrl?(e.action=i.ctrl[e.name],e):e.option&&i.option?(e.action=i.option[e.name],e):e.shift?(e.action=i.shift[e.name],e):(e.action=i.keys[e.name],e)};Nie.exports=_0});var Mie=w((xpt,Oie)=>{"use strict";Oie.exports=t=>{t.timers=t.timers||{};let e=t.options.timers;if(!!e)for(let r of Object.keys(e)){let i=e[r];typeof i=="number"&&(i={interval:i}),Eqe(t,r,i)}};function Eqe(t,e,r={}){let i=t.timers[e]={name:e,start:Date.now(),ms:0,tick:0},n=r.interval||120;i.frames=r.frames||[],i.loading=!0;let s=setInterval(()=>{i.ms=Date.now()-i.start,i.tick++,t.render()},n);return i.stop=()=>{i.loading=!1,clearInterval(s)},Reflect.defineProperty(i,"interval",{value:s}),t.once("close",()=>i.stop()),i.stop}});var Hie=w((Ppt,Kie)=>{"use strict";var{define:Iqe,width:yqe}=Xi(),Uie=class{constructor(e){let r=e.options;Iqe(this,"_prompt",e),this.type=e.type,this.name=e.name,this.message="",this.header="",this.footer="",this.error="",this.hint="",this.input="",this.cursor=0,this.index=0,this.lines=0,this.tick=0,this.prompt="",this.buffer="",this.width=yqe(r.stdout||process.stdout),Object.assign(this,r),this.name=this.name||this.message,this.message=this.message||this.name,this.symbols=e.symbols,this.styles=e.styles,this.required=new Set,this.cancelled=!1,this.submitted=!1}clone(){let e=N({},this);return e.status=this.status,e.buffer=Buffer.from(e.buffer),delete e.clone,e}set color(e){this._color=e}get color(){let e=this.prompt.styles;if(this.cancelled)return e.cancelled;if(this.submitted)return e.submitted;let r=this._color||e[this.status];return typeof r=="function"?r:e.pending}set loading(e){this._loading=e}get loading(){return typeof this._loading=="boolean"?this._loading:this.loadingChoices?"choices":!1}get status(){return this.cancelled?"cancelled":this.submitted?"submitted":"pending"}};Kie.exports=Uie});var jie=w((Dpt,Gie)=>{"use strict";var gN=Xi(),Fi=mo(),fN={default:Fi.noop,noop:Fi.noop,set inverse(t){this._inverse=t},get inverse(){return this._inverse||gN.inverse(this.primary)},set complement(t){this._complement=t},get complement(){return this._complement||gN.complement(this.primary)},primary:Fi.cyan,success:Fi.green,danger:Fi.magenta,strong:Fi.bold,warning:Fi.yellow,muted:Fi.dim,disabled:Fi.gray,dark:Fi.dim.gray,underline:Fi.underline,set info(t){this._info=t},get info(){return this._info||this.primary},set em(t){this._em=t},get em(){return this._em||this.primary.underline},set heading(t){this._heading=t},get heading(){return this._heading||this.muted.underline},set pending(t){this._pending=t},get pending(){return this._pending||this.primary},set submitted(t){this._submitted=t},get submitted(){return this._submitted||this.success},set cancelled(t){this._cancelled=t},get cancelled(){return this._cancelled||this.danger},set typing(t){this._typing=t},get typing(){return this._typing||this.dim},set placeholder(t){this._placeholder=t},get placeholder(){return this._placeholder||this.primary.dim},set highlight(t){this._highlight=t},get highlight(){return this._highlight||this.inverse}};fN.merge=(t={})=>{t.styles&&typeof t.styles.enabled=="boolean"&&(Fi.enabled=t.styles.enabled),t.styles&&typeof t.styles.visible=="boolean"&&(Fi.visible=t.styles.visible);let e=gN.merge({},fN,t.styles);delete e.merge;for(let r of Object.keys(Fi))e.hasOwnProperty(r)||Reflect.defineProperty(e,r,{get:()=>Fi[r]});for(let r of Object.keys(Fi.styles))e.hasOwnProperty(r)||Reflect.defineProperty(e,r,{get:()=>Fi[r]});return e};Gie.exports=fN});var qie=w((Rpt,Yie)=>{"use strict";var hN=process.platform==="win32",mA=mo(),wqe=Xi(),pN=ie(N({},mA.symbols),{upDownDoubleArrow:"\u21D5",upDownDoubleArrow2:"\u2B0D",upDownArrow:"\u2195",asterisk:"*",asterism:"\u2042",bulletWhite:"\u25E6",electricArrow:"\u2301", Line truncated
`),c=l[0],u=l[l.length-1],f=(i+(r?" "+r:"")).length,h=f<c.length?c.slice(f+1):"";return{header:o,prompt:c,after:h,rest:l.slice(1),last:u}}async submit(){this.state.submitted=!0,this.state.validating=!0,this.options.onSubmit&&await this.options.onSubmit.call(this,this.name,this.value,this);let e=this.state.error||await this.validate(this.value,this.state);if(e!==!0){let r=`
`+this.symbols.pointer+" ";typeof e=="string"?r+=e.trim():r+="Invalid input",this.state.error=`
`+this.styles.danger(r),this.state.submitted=!1,await this.render(),await this.alert(),this.state.validating=!1,this.state.error=void 0;return}this.state.validating=!1,await this.render(),await this.close(),this.value=await this.result(this.value),this.emit("submit",this.value)}async cancel(e){this.state.cancelled=this.state.submitted=!0,await this.render(),await this.close(),typeof this.options.onCancel=="function"&&await this.options.onCancel.call(this,this.name,this.value,this),this.emit("cancel",await this.error(e))}async close(){this.state.closed=!0;try{let e=this.sections(),r=Math.ceil(e.prompt.length/this.width);e.rest&&this.write(Eu.cursor.down(e.rest.length)),this.write(`
`.repeat(r))}catch(e){}this.emit("close")}start(){!this.stop&&this.options.show!==!1&&(this.stop=EN.listen(this,this.keypress.bind(this)),this.once("close",this.stop))}async skip(){return this.skipped=this.options.skip===!0,typeof this.options.skip=="function"&&(this.skipped=await this.options.skip.call(this,this.name,this.value)),this.skipped}async initialize(){let{format:e,options:r,result:i}=this;if(this.format=()=>e.call(this,this.value),this.result=()=>i.call(this,this.value),typeof r.initial=="function"&&(this.initial=await r.initial.call(this,this)),typeof r.onRun=="function"&&await r.onRun.call(this,this),typeof r.onSubmit=="function"){let n=r.onSubmit.bind(this),s=this.submit.bind(this);delete this.options.onSubmit,this.submit=async()=>(await n(this.name,this.value,this),s())}await this.start(),await this.render()}render(){throw new Error("expected prompt to have a custom render method")}run(){return new Promise(async(e,r)=>{if(this.once("submit",e),this.once("cancel",r),await this.skip())return this.render=()=>{},this.submit();await this.initialize(),this.emit("run")})}async element(e,r,i){let{options:n,state:s,symbols:o,timers:a}=this,l=a&&a[e];s.timer=l;let c=n[e]||s[e]||o[e],u=r&&r[e]!=null?r[e]:await c;if(u==="")return u;let g=await this.resolve(u,s,r,i);return!g&&r&&r[e]?this.resolve(c,s,r,i):g}async prefix(){let e=await this.element("prefix")||this.symbols,r=this.timers&&this.timers.prefix,i=this.state;return i.timer=r,Tn.isObject(e)&&(e=e[i.status]||e.pending),Tn.hasColor(e)?e:(this.styles[i.status]||this.styles.pending)(e)}async message(){let e=await this.element("message");return Tn.hasColor(e)?e:this.styles.strong(e)}async separator(){let e=await this.element("separator")||this.symbols,r=this.timers&&this.timers.separator,i=this.state;i.timer=r;let n=e[i.status]||e.pending||i.separator,s=await this.resolve(n,i);return Tn.isObject(s)&&(s=s[i.status]||s.pending),Tn.hasColor(s)?s:this.styles.muted(s)}async pointer(e,r){let i=await this.element("pointer",e,r);if(typeof i=="string"&&Tn.hasColor(i))return i;if(i){let n=this.styles,s=this.index===r,o=s?n.primary:c=>c,a=await this.resolve(i[s?"on":"off"]||i,this.state),l=Tn.hasColor(a)?a:o(a);return s?l:" ".repeat(a.length)}}async indicator(e,r){let i=await this.element("indicator",e,r);if(typeof i=="string"&&Tn.hasColor(i))return i;if(i){let n=this.styles,s=e.enabled===!0,o=s?n.success:n.dark,a=i[s?"on":"off"]||i;return Tn.hasColor(a)?a:o(a)}return""}body(){return null}footer(){if(this.state.status==="pending")return this.element("footer")}header(){if(this.state.status==="pending")return this.element("header")}async hint(){if(this.state.status==="pending"&&!this.isValue(this.state.input)){let e=await this.element("hint");return Tn.hasColor(e)?e:this.styles.muted(e)}}error(e){return this.state.submitted?"":e||this.state.error}format(e){return e}result(e){return e}validate(e){return this.options.required===!0?this.isValue(e):!0}isValue(e){return e!=null&&e!==""}resolve(e,...r){return Tn.resolve(this,e,...r)}get base(){return V0.prototype}get style(){return this.styles[this.state.status]}get height(){return this.options.rows||Tn.height(this.stdout,25)}get width(){return this.options.columns||Tn.width(this.stdout,80)}get size(){return{width:this.width,height:this.height}}set cursor(e){this.state.cursor=e}get cursor(){return this.state.cursor}set input(e){this.state.input=e}get input(){return this.state.input}set value(e){this.state.value=e}get value(){let{input:e,value:r}=this.state,i=[r,e].find(this.isValue.bind(this));return this.isValue(i)?i:this.initial}static get prompt(){return e=>new this(e).run()}};function Dqe(t){let e=n=>t[n]===void 0||typeof t[n]=="function",r=["actions","choices","initial","margin","roles","styles","symbols","theme","timers","value"],i=["body","footer","error","header","hint","indicator","message","prefix","separator","skip"];for(let n of Object.keys(t.options)){if(r.includes(n)||/^on[A-Z]/.test(n))continue;let s=t.options[n];typeof s=="function"&&e(n)?i.includes(n)||(t[n]=s.bind(t)):typeof t[n]!="function"&&(t[n]=s)}}function Rqe(t){typeof t=="number"&&(t=[t,t,t,t]);let e=[].concat(t||[]),r=n=>n%2==0?`
`:" ",i=[];for(let n=0;n<4;n++){let s=r(n);e[n]?i.push(s.repeat(e[n])):i.push("")}return i}$ie.exports=V0});var ine=w((Lpt,tne)=>{"use strict";var Fqe=Xi(),rne={default(t,e){return e},checkbox(t,e){throw new Error("checkbox role is not implemented yet")},editable(t,e){throw new Error("editable role is not implemented yet")},expandable(t,e){throw new Error("expandable role is not implemented yet")},heading(t,e){return e.disabled="",e.indicator=[e.indicator," "].find(r=>r!=null),e.message=e.message||"",e},input(t,e){throw new Error("input role is not implemented yet")},option(t,e){return rne.default(t,e)},radio(t,e){throw new Error("radio role is not implemented yet")},separator(t,e){return e.disabled="",e.indicator=[e.indicator," "].find(r=>r!=null),e.message=e.message||t.symbols.line.repeat(5),e},spacer(t,e){return e}};tne.exports=(t,e={})=>{let r=Fqe.merge({},rne,e.roles);return r[t]||r.default}});var ZC=w((Tpt,nne)=>{"use strict";var Nqe=mo(),Lqe=Vf(),Tqe=ine(),X0=Xi(),{reorder:IN,scrollUp:Oqe,scrollDown:Mqe,isObject:sne,swap:Kqe}=X0,one=class extends Lqe{constructor(e){super(e);this.cursorHide(),this.maxSelected=e.maxSelected||Infinity,this.multiple=e.multiple||!1,this.initial=e.initial||0,this.delay=e.delay||0,this.longest=0,this.num=""}async initialize(){typeof this.options.initial=="function"&&(this.initial=await this.options.initial.call(this)),await this.reset(!0),await super.initialize()}async reset(){let{choices:e,initial:r,autofocus:i,suggest:n}=this.options;if(this.state._choices=[],this.state.choices=[],this.choices=await Promise.all(await this.toChoices(e)),this.choices.forEach(s=>s.enabled=!1),typeof n!="function"&&this.selectable.length===0)throw new Error("At least one choice must be selectable");sne(r)&&(r=Object.keys(r)),Array.isArray(r)?(i!=null&&(this.index=this.findIndex(i)),r.forEach(s=>this.enable(this.find(s))),await this.render()):(i!=null&&(r=i),typeof r=="string"&&(r=this.findIndex(r)),typeof r=="number"&&r>-1&&(this.index=Math.max(0,Math.min(r,this.choices.length)),this.enable(this.find(this.index)))),this.isDisabled(this.focused)&&await this.down()}async toChoices(e,r){this.state.loadingChoices=!0;let i=[],n=0,s=async(o,a)=>{typeof o=="function"&&(o=await o.call(this)),o instanceof Promise&&(o=await o);for(let l=0;l<o.length;l++){let c=o[l]=await this.toChoice(o[l],n++,a);i.push(c),c.choices&&await s(c.choices,c)}return i};return s(e,r).then(o=>(this.state.loadingChoices=!1,o))}async toChoice(e,r,i){if(typeof e=="function"&&(e=await e.call(this,this)),e instanceof Promise&&(e=await e),typeof e=="string"&&(e={name:e}),e.normalized)return e;e.normalized=!0;let n=e.value;if(e=Tqe(e.role,this.options)(this,e),typeof e.disabled=="string"&&!e.hint&&(e.hint=e.disabled,e.disabled=!0),e.disabled===!0&&e.hint==null&&(e.hint="(disabled)"),e.index!=null)return e;e.name=e.name||e.key||e.title||e.value||e.message,e.message=e.message||e.name||"",e.value=[e.value,e.name].find(this.isValue.bind(this)),e.input="",e.index=r,e.cursor=0,X0.define(e,"parent",i),e.level=i?i.level+1:1,e.indent==null&&(e.indent=i?i.indent+" ":e.indent||""),e.path=i?i.path+"."+e.name:e.name,e.enabled=!!(this.multiple&&!this.isDisabled(e)&&(e.enabled||this.isSelected(e))),this.isDisabled(e)||(this.longest=Math.max(this.longest,Nqe.unstyle(e.message).length));let o=N({},e);return e.reset=(a=o.input,l=o.value)=>{for(let c of Object.keys(o))e[c]=o[c];e.input=a,e.value=l},n==null&&typeof e.initial=="function"&&(e.input=await e.initial.call(this,this.state,e,r)),e}async onChoice(e,r){this.emit("choice",e,r,this),typeof e.onChoice=="function"&&await e.onChoice.call(this,this.state,e,r)}async addChoice(e,r,i){let n=await this.toChoice(e,r,i);return this.choices.push(n),this.index=this.choices.length-1,this.limit=this.choices.length,n}async newItem(e,r,i){let n=N({name:"New choice name?",editable:!0,newChoice:!0},e),s=await this.addChoice(n,r,i);return s.updateChoice=()=>{delete s.newChoice,s.name=s.message=s.input,s.input="",s.cursor=0},this.render()}indent(e){return e.indent==null?e.level>1?" ".repeat(e.level-1):"":e.indent}dispatch(e,r){if(this.multiple&&this[r.name])return this[r.name]();this.alert()}focus(e,r){return typeof r!="boolean"&&(r=e.enabled),r&&!e.enabled&&this.selected.length>=this.maxSelected?this.alert():(this.index=e.index,e.enabled=r&&!this.isDisabled(e),e)}space(){return this.multiple?(this.toggle(this.focused),this.render()):this.alert()}a(){if(this.maxSelected<this.choices.length)return this.alert();let e=this.selectable.every(r=>r.enabled);return this.choices.forEach(r=>r.enabled=!e),this.render()}i(){return this.choices.length-this.selected.length>this.maxSelected?this.alert():(this.choices.forEach(e=>e.enabled=!e.enabled),this.render())}g(e=this.focused){return this.choices.some(r=>!!r.parent)?(this.toggle(e.parent&&!e.choices?e.parent:e),this.render()):this.a()}toggle(e,r){if(!e.enabled&&this.selected.length>=this.maxSelected)return this.alert();typeof r!="boolean"&&(r=!e.enabled),e.enabled=r,e.choi Line truncated
`),n;return this.options.choicesHeader&&(n=await this.resolve(this.options.choicesHeader,this.state)),[n,i].filter(Boolean).join(`
`)}format(){return!this.state.submitted||this.state.cancelled?"":Array.isArray(this.selected)?this.selected.map(e=>this.styles.primary(e.name)).join(", "):this.styles.primary(this.selected.name)}async render(){let{submitted:e,size:r}=this.state,i="",n=await this.header(),s=await this.prefix(),o=await this.separator(),a=await this.message();this.options.promptLine!==!1&&(i=[s,a,o,""].join(" "),this.state.prompt=i);let l=await this.format(),c=await this.error()||await this.hint(),u=await this.renderChoices(),g=await this.footer();l&&(i+=l),c&&!i.includes(c)&&(i+=" "+c),e&&!l&&!u.trim()&&this.multiple&&this.emptyError!=null&&(i+=this.styles.danger(this.emptyError)),this.clear(r),this.write([n,i,u,g].filter(Boolean).join(`
`)),this.write(this.margin[2]),this.restore()}};Ane.exports=lne});var gne=w((Mpt,cne)=>{"use strict";var Hqe=xl(),Gqe=(t,e)=>{let r=t.toLowerCase();return i=>{let s=i.toLowerCase().indexOf(r),o=e(i.slice(s,s+r.length));return s>=0?i.slice(0,s)+o+i.slice(s+r.length):i}},une=class extends Hqe{constructor(e){super(e);this.cursorShow()}moveCursor(e){this.state.cursor+=e}dispatch(e){return this.append(e)}space(e){return this.options.multiple?super.space(e):this.append(e)}append(e){let{cursor:r,input:i}=this.state;return this.input=i.slice(0,r)+e+i.slice(r),this.moveCursor(1),this.complete()}delete(){let{cursor:e,input:r}=this.state;return r?(this.input=r.slice(0,e-1)+r.slice(e),this.moveCursor(-1),this.complete()):this.alert()}deleteForward(){let{cursor:e,input:r}=this.state;return r[e]===void 0?this.alert():(this.input=`${r}`.slice(0,e)+`${r}`.slice(e+1),this.complete())}number(e){return this.append(e)}async complete(){this.completing=!0,this.choices=await this.suggest(this.input,this.state._choices),this.state.limit=void 0,this.index=Math.min(Math.max(this.visible.length-1,0),this.index),await this.render(),this.completing=!1}suggest(e=this.input,r=this.state._choices){if(typeof this.options.suggest=="function")return this.options.suggest.call(this,e,r);let i=e.toLowerCase();return r.filter(n=>n.message.toLowerCase().includes(i))}pointer(){return""}format(){if(!this.focused)return this.input;if(this.options.multiple&&this.state.submitted)return this.selected.map(e=>this.styles.primary(e.message)).join(", ");if(this.state.submitted){let e=this.value=this.input=this.focused.value;return this.styles.primary(e)}return this.input}async render(){if(this.state.status!=="pending")return super.render();let e=this.options.highlight?this.options.highlight.bind(this):this.styles.placeholder,r=Gqe(this.input,e),i=this.choices;this.choices=i.map(n=>ie(N({},n),{message:r(n.message)})),await super.render(),this.choices=i}submit(){return this.options.multiple&&(this.value=this.selected.map(e=>e.name)),super.submit()}};cne.exports=une});var BN=w((Kpt,fne)=>{"use strict";var wN=Xi();fne.exports=(t,e={})=>{t.cursorHide();let{input:r="",initial:i="",pos:n,showCursor:s=!0,color:o}=e,a=o||t.styles.placeholder,l=wN.inverse(t.styles.primary),c=m=>l(t.styles.black(m)),u=r,g=" ",f=c(g);if(t.blink&&t.blink.off===!0&&(c=m=>m,f=""),s&&n===0&&i===""&&r==="")return c(g);if(s&&n===0&&(r===i||r===""))return c(i[0])+a(i.slice(1));i=wN.isPrimitive(i)?`${i}`:"",r=wN.isPrimitive(r)?`${r}`:"";let h=i&&i.startsWith(r)&&i!==r,p=h?c(i[r.length]):f;if(n!==r.length&&s===!0&&(u=r.slice(0,n)+c(r[n])+r.slice(n+1),p=""),s===!1&&(p=""),h){let m=t.styles.unstyle(u+p);return u+p+a(i.slice(m.length))}return u+p}});var Z0=w((Upt,hne)=>{"use strict";var jqe=mo(),Yqe=xl(),qqe=BN(),pne=class extends Yqe{constructor(e){super(ie(N({},e),{multiple:!0}));this.type="form",this.initial=this.options.initial,this.align=[this.options.align,"right"].find(r=>r!=null),this.emptyError="",this.values={}}async reset(e){return await super.reset(),e===!0&&(this._index=this.index),this.index=this._index,this.values={},this.choices.forEach(r=>r.reset&&r.reset()),this.render()}dispatch(e){return!!e&&this.append(e)}append(e){let r=this.focused;if(!r)return this.alert();let{cursor:i,input:n}=r;return r.value=r.input=n.slice(0,i)+e+n.slice(i),r.cursor++,this.render()}delete(){let e=this.focused;if(!e||e.cursor<=0)return this.alert();let{cursor:r,input:i}=e;return e.value=e.input=i.slice(0,r-1)+i.slice(r),e.cursor--,this.render()}deleteForward(){let e=this.focused;if(!e)return this.alert();let{cursor:r,input:i}=e;if(i[r]===void 0)return this.alert();let n=`${i}`.slice(0,r)+`${i}`.slice(r+1);return e.value=e.input=n,this.render()}right(){let e=this.focused;return e?e.cursor>=e.input.length?this.alert():(e.cursor++,this.render()):this.alert()}left(){let e=this.focused;return e?e.cursor<=0?this.alert():(e.cursor--,this.render()):this.alert()}space(e,r){return this.dispatch(e,r)}number(e,r){return this.dispatch(e,r)}next(){let e=this.focused;if(!e)return this.alert();let{initial:r,input:i}=e;return r&&r.startsWith(i)&&i!==r?(e.value=e.input=r,e.cursor=e.value.length,this.render()):super.next()}prev(){let e=this.focused;return e?e.cursor===0?super.prev():(e.value=e.input="",e.cursor=0,this.render()):this.alert()}separator(){return""}format(e){return this.state.submitted?"":super.format(e)}pointer(){return""}indicator(e){return e.input?"\u29BF":"\u2299"}async choiceSeparator(e,r){let i=await this.resolve(e.separator,this.state,e,r)||":";return i?" "+this.styles.disabled(i):""}async renderChoice(e,r){await this.onChoice(e,r);let{state:i,styles:n}=this,{cursor:s,initial:o="",name:a,hint:l,input:c=""}=e,{muted:u,submitted:g,primary:f,danger:h}=n,p=l,m=this.index===r,y=e.validate||(()=>!0),b=await this.choiceSeparator(e,r),S=e.message;this.align==="right"&&(S=S.padStart(this.longest+1," ")),this.align==="left"&&(S=S.padEnd(this.longest+1," "));let k=this.values[a]=c||o,T=c?"success":"dark";await y Line truncated
`)),this.restore()}set value(e){super.value=e}get value(){return this.cast(super.value)}};yne.exports=wne});var Qne=w((Ypt,Bne)=>{"use strict";var $qe=$0(),bne=class extends $qe{constructor(e){super(e);this.default=this.options.default||(this.initial?"(Y/n)":"(y/N)")}};Bne.exports=bne});var kne=w((qpt,vne)=>{"use strict";var eJe=xl(),tJe=Z0(),Xf=tJe.prototype,Sne=class extends eJe{constructor(e){super(ie(N({},e),{multiple:!0}));this.align=[this.options.align,"left"].find(r=>r!=null),this.emptyError="",this.values={}}dispatch(e,r){let i=this.focused,n=i.parent||{};return!i.editable&&!n.editable&&(e==="a"||e==="i")?super[e]():Xf.dispatch.call(this,e,r)}append(e,r){return Xf.append.call(this,e,r)}delete(e,r){return Xf.delete.call(this,e,r)}space(e){return this.focused.editable?this.append(e):super.space()}number(e){return this.focused.editable?this.append(e):super.number(e)}next(){return this.focused.editable?Xf.next.call(this):super.next()}prev(){return this.focused.editable?Xf.prev.call(this):super.prev()}async indicator(e,r){let i=e.indicator||"",n=e.editable?i:super.indicator(e,r);return await this.resolve(n,this.state,e,r)||""}indent(e){return e.role==="heading"?"":e.editable?" ":" "}async renderChoice(e,r){return e.indent="",e.editable?Xf.renderChoice.call(this,e,r):super.renderChoice(e,r)}error(){return""}footer(){return this.state.error}async validate(){let e=!0;for(let r of this.choices){if(typeof r.validate!="function"||r.role==="heading")continue;let i=r.parent?this.value[r.parent.name]:this.value;if(r.editable?i=r.value===r.name?r.initial||"":r.value:this.isDisabled(r)||(i=r.enabled===!0),e=await r.validate(i,this.state),e!==!0)break}return e!==!0&&(this.state.error=typeof e=="string"?e:"Invalid Input"),e}submit(){if(this.focused.newChoice===!0)return super.submit();if(this.choices.some(e=>e.newChoice))return this.alert();this.value={};for(let e of this.choices){let r=e.parent?this.value[e.parent.name]:this.value;if(e.role==="heading"){this.value[e.name]={};continue}e.editable?r[e.name]=e.value===e.name?e.initial||"":e.value:this.isDisabled(e)||(r[e.name]=e.enabled===!0)}return this.base.submit.call(this)}};vne.exports=Sne});var Iu=w((Jpt,xne)=>{"use strict";var rJe=Vf(),iJe=BN(),{isPrimitive:nJe}=Xi(),Pne=class extends rJe{constructor(e){super(e);this.initial=nJe(this.initial)?String(this.initial):"",this.initial&&this.cursorHide(),this.state.prevCursor=0,this.state.clipboard=[]}async keypress(e,r={}){let i=this.state.prevKeypress;return this.state.prevKeypress=r,this.options.multiline===!0&&r.name==="return"&&(!i||i.name!=="return")?this.append(`
`,r):super.keypress(e,r)}moveCursor(e){this.cursor+=e}reset(){return this.input=this.value="",this.cursor=0,this.render()}dispatch(e,r){if(!e||r.ctrl||r.code)return this.alert();this.append(e)}append(e){let{cursor:r,input:i}=this.state;this.input=`${i}`.slice(0,r)+e+`${i}`.slice(r),this.moveCursor(String(e).length),this.render()}insert(e){this.append(e)}delete(){let{cursor:e,input:r}=this.state;if(e<=0)return this.alert();this.input=`${r}`.slice(0,e-1)+`${r}`.slice(e),this.moveCursor(-1),this.render()}deleteForward(){let{cursor:e,input:r}=this.state;if(r[e]===void 0)return this.alert();this.input=`${r}`.slice(0,e)+`${r}`.slice(e+1),this.render()}cutForward(){let e=this.cursor;if(this.input.length<=e)return this.alert();this.state.clipboard.push(this.input.slice(e)),this.input=this.input.slice(0,e),this.render()}cutLeft(){let e=this.cursor;if(e===0)return this.alert();let r=this.input.slice(0,e),i=this.input.slice(e),n=r.split(" ");this.state.clipboard.push(n.pop()),this.input=n.join(" "),this.cursor=this.input.length,this.input+=i,this.render()}paste(){if(!this.state.clipboard.length)return this.alert();this.insert(this.state.clipboard.pop()),this.render()}toggleCursor(){this.state.prevCursor?(this.cursor=this.state.prevCursor,this.state.prevCursor=0):(this.state.prevCursor=this.cursor,this.cursor=0),this.render()}first(){this.cursor=0,this.render()}last(){this.cursor=this.input.length-1,this.render()}next(){let e=this.initial!=null?String(this.initial):"";if(!e||!e.startsWith(this.input))return this.alert();this.input=this.initial,this.cursor=this.initial.length,this.render()}prev(){if(!this.input)return this.alert();this.reset()}backward(){return this.left()}forward(){return this.right()}right(){return this.cursor>=this.input.length?this.alert():(this.moveCursor(1),this.render())}left(){return this.cursor<=0?this.alert():(this.moveCursor(-1),this.render())}isValue(e){return!!e}async format(e=this.value){let r=await this.resolve(this.initial,this.state);return this.state.submitted?this.styles.submitted(e||r):iJe(this,{input:e,initial:r,pos:this.cursor})}async render(){let e=this.state.size,r=await this.prefix(),i=await this.separator(),n=await this.message(),s=[r,n,i].filter(Boolean).join(" ");this.state.prompt=s;let o=await this.header(),a=await this.format(),l=await this.error()||await this.hint(),c=await this.footer();l&&!a.includes(l)&&(a+=" "+l),s+=" "+a,this.clear(e),this.write([o,s,c].filter(Boolean).join(`
`)),this.restore()}};xne.exports=Pne});var Rne=w((Wpt,Dne)=>{"use strict";var sJe=t=>t.filter((e,r)=>t.lastIndexOf(e)===r),eb=t=>sJe(t).filter(Boolean);Dne.exports=(t,e={},r="")=>{let{past:i=[],present:n=""}=e,s,o;switch(t){case"prev":case"undo":return s=i.slice(0,i.length-1),o=i[i.length-1]||"",{past:eb([r,...s]),present:o};case"next":case"redo":return s=i.slice(1),o=i[0]||"",{past:eb([...s,r]),present:o};case"save":return{past:eb([...i,r]),present:""};case"remove":return o=eb(i.filter(a=>a!==r)),n="",o.length&&(n=o.pop()),{past:o,present:n};default:throw new Error(`Invalid action: "${t}"`)}}});var QN=w((zpt,Fne)=>{"use strict";var oJe=Iu(),Nne=Rne(),Lne=class extends oJe{constructor(e){super(e);let r=this.options.history;if(r&&r.store){let i=r.values||this.initial;this.autosave=!!r.autosave,this.store=r.store,this.data=this.store.get("values")||{past:[],present:i},this.initial=this.data.present||this.data.past[this.data.past.length-1]}}completion(e){return this.store?(this.data=Nne(e,this.data,this.input),this.data.present?(this.input=this.data.present,this.cursor=this.input.length,this.render()):this.alert()):this.alert()}altUp(){return this.completion("prev")}altDown(){return this.completion("next")}prev(){return this.save(),super.prev()}save(){!this.store||(this.data=Nne("save",this.data,this.input),this.store.set("values",this.data))}submit(){return this.store&&this.autosave===!0&&this.save(),super.submit()}};Fne.exports=Lne});var Mne=w((_pt,Tne)=>{"use strict";var aJe=Iu(),One=class extends aJe{format(){return""}};Tne.exports=One});var Hne=w((Vpt,Kne)=>{"use strict";var AJe=Iu(),Une=class extends AJe{constructor(e={}){super(e);this.sep=this.options.separator||/, */,this.initial=e.initial||""}split(e=this.value){return e?String(e).split(this.sep):[]}format(){let e=this.state.submitted?this.styles.primary:r=>r;return this.list.map(e).join(", ")}async submit(e){let r=this.state.error||await this.validate(this.list,this.state);return r!==!0?(this.state.error=r,super.submit()):(this.value=this.list,super.submit())}get list(){return this.split()}};Kne.exports=Une});var Yne=w((Xpt,Gne)=>{"use strict";var lJe=xl(),jne=class extends lJe{constructor(e){super(ie(N({},e),{multiple:!0}))}};Gne.exports=jne});var vN=w((Zpt,qne)=>{"use strict";var cJe=Iu(),Jne=class extends cJe{constructor(e={}){super(N({style:"number"},e));this.min=this.isValue(e.min)?this.toNumber(e.min):-Infinity,this.max=this.isValue(e.max)?this.toNumber(e.max):Infinity,this.delay=e.delay!=null?e.delay:1e3,this.float=e.float!==!1,this.round=e.round===!0||e.float===!1,this.major=e.major||10,this.minor=e.minor||1,this.initial=e.initial!=null?e.initial:"",this.input=String(this.initial),this.cursor=this.input.length,this.cursorShow()}append(e){return!/[-+.]/.test(e)||e==="."&&this.input.includes(".")?this.alert("invalid number"):super.append(e)}number(e){return super.append(e)}next(){return this.input&&this.input!==this.initial?this.alert():this.isValue(this.initial)?(this.input=this.initial,this.cursor=String(this.initial).length,this.render()):this.alert()}up(e){let r=e||this.minor,i=this.toNumber(this.input);return i>this.max+r?this.alert():(this.input=`${i+r}`,this.render())}down(e){let r=e||this.minor,i=this.toNumber(this.input);return i<this.min-r?this.alert():(this.input=`${i-r}`,this.render())}shiftDown(){return this.down(this.major)}shiftUp(){return this.up(this.major)}format(e=this.input){return typeof this.options.format=="function"?this.options.format.call(this,e):this.styles.info(e)}toNumber(e=""){return this.float?+e:Math.round(+e)}isValue(e){return/^[-+]?[0-9]+((\.)|(\.[0-9]+))?$/.test(e)}submit(){let e=[this.input,this.initial].find(r=>this.isValue(r));return this.value=this.toNumber(e||0),super.submit()}};qne.exports=Jne});var zne=w(($pt,Wne)=>{Wne.exports=vN()});var Xne=w((edt,_ne)=>{"use strict";var uJe=Iu(),Vne=class extends uJe{constructor(e){super(e);this.cursorShow()}format(e=this.input){return this.keypressed?(this.state.submitted?this.styles.primary:this.styles.muted)(this.symbols.asterisk.repeat(e.length)):""}};_ne.exports=Vne});var tse=w((tdt,Zne)=>{"use strict";var gJe=mo(),fJe=ZC(),$ne=Xi(),ese=class extends fJe{constructor(e={}){super(e);this.widths=[].concat(e.messageWidth||50),this.align=[].concat(e.align||"left"),this.linebreak=e.linebreak||!1,this.edgeLength=e.edgeLength||3,this.newline=e.newline||`
`;let r=e.startNumber||1;typeof this.scale=="number"&&(this.scaleKey=!1,this.scale=Array(this.scale).fill(0).map((i,n)=>({name:n+r})))}async reset(){return this.tableized=!1,await super.reset(),this.render()}tableize(){if(this.tableized===!0)return;this.tableized=!0;let e=0;for(let r of this.choices){e=Math.max(e,r.message.length),r.scaleIndex=r.initial||2,r.scale=[];for(let i=0;i<this.scale.length;i++)r.scale.push({index:i})}this.widths[0]=Math.min(this.widths[0],e+3)}async dispatch(e,r){if(this.multiple)return this[r.name]?await this[r.name](e,r):await super.dispatch(e,r);this.alert()}heading(e,r,i){return this.styles.strong(e)}separator(){return this.styles.muted(this.symbols.ellipsis)}right(){let e=this.focused;return e.scaleIndex>=this.scale.length-1?this.alert():(e.scaleIndex++,this.render())}left(){let e=this.focused;return e.scaleIndex<=0?this.alert():(e.scaleIndex--,this.render())}indent(){return""}format(){return this.state.submitted?this.choices.map(r=>this.styles.info(r.index)).join(", "):""}pointer(){return""}renderScaleKey(){if(this.scaleKey===!1||this.state.submitted)return"";let e=this.scale.map(i=>` ${i.name} - ${i.message}`);return["",...e].map(i=>this.styles.muted(i)).join(`
`)}renderScaleHeading(e){let r=this.scale.map(l=>l.name);typeof this.options.renderScaleHeading=="function"&&(r=this.options.renderScaleHeading.call(this,e));let i=this.scaleLength-r.join("").length,n=Math.round(i/(r.length-1)),o=r.map(l=>this.styles.strong(l)).join(" ".repeat(n)),a=" ".repeat(this.widths[0]);return this.margin[3]+a+this.margin[1]+o}scaleIndicator(e,r,i){if(typeof this.options.scaleIndicator=="function")return this.options.scaleIndicator.call(this,e,r,i);let n=e.scaleIndex===r.index;return r.disabled?this.styles.hint(this.symbols.radio.disabled):n?this.styles.success(this.symbols.radio.on):this.symbols.radio.off}renderScale(e,r){let i=e.scale.map(s=>this.scaleIndicator(e,s,r)),n=this.term==="Hyper"?"":" ";return i.join(n+this.symbols.line.repeat(this.edgeLength))}async renderChoice(e,r){await this.onChoice(e,r);let i=this.index===r,n=await this.pointer(e,r),s=await e.hint;s&&!$ne.hasColor(s)&&(s=this.styles.muted(s));let o=p=>this.margin[3]+p.replace(/\s+$/,"").padEnd(this.widths[0]," "),a=this.newline,l=this.indent(e),c=await this.resolve(e.message,this.state,e,r),u=await this.renderScale(e,r),g=this.margin[1]+this.margin[3];this.scaleLength=gJe.unstyle(u).length,this.widths[0]=Math.min(this.widths[0],this.width-this.scaleLength-g.length);let h=$ne.wordWrap(c,{width:this.widths[0],newline:a}).split(`
`).map(p=>o(p)+this.margin[1]);return i&&(u=this.styles.info(u),h=h.map(p=>this.styles.info(p))),h[0]+=u,this.linebreak&&h.push(""),[l+n,h.join(`
`)].filter(Boolean)}async renderChoices(){if(this.state.submitted)return"";this.tableize();let e=this.visible.map(async(n,s)=>await this.renderChoice(n,s)),r=await Promise.all(e),i=await this.renderScaleHeading();return this.margin[0]+[i,...r.map(n=>n.join(" "))].join(`
`)}async render(){let{submitted:e,size:r}=this.state,i=await this.prefix(),n=await this.separator(),s=await this.message(),o="";this.options.promptLine!==!1&&(o=[i,s,n,""].join(" "),this.state.prompt=o);let a=await this.header(),l=await this.format(),c=await this.renderScaleKey(),u=await this.error()||await this.hint(),g=await this.renderChoices(),f=await this.footer(),h=this.emptyError;l&&(o+=l),u&&!o.includes(u)&&(o+=" "+u),e&&!l&&!g.trim()&&this.multiple&&h!=null&&(o+=this.styles.danger(h)),this.clear(r),this.write([a,o,c,g,f].filter(Boolean).join(`
`)),this.state.submitted||this.write(this.margin[2]),this.restore()}submit(){this.value={};for(let e of this.choices)this.value[e.name]=e.scaleIndex;return this.base.submit.call(this)}};Zne.exports=ese});var sse=w((rdt,rse)=>{"use strict";var ise=mo(),hJe=(t="")=>typeof t=="string"?t.replace(/^['"]|['"]$/g,""):"",nse=class{constructor(e){this.name=e.key,this.field=e.field||{},this.value=hJe(e.initial||this.field.initial||""),this.message=e.message||this.name,this.cursor=0,this.input="",this.lines=[]}},pJe=async(t={},e={},r=i=>i)=>{let i=new Set,n=t.fields||[],s=t.template,o=[],a=[],l=[],c=1;typeof s=="function"&&(s=await s());let u=-1,g=()=>s[++u],f=()=>s[u+1],h=p=>{p.line=c,o.push(p)};for(h({type:"bos",value:""});u<s.length-1;){let p=g();if(/^[^\S\n ]$/.test(p)){h({type:"text",value:p});continue}if(p===`
`){h({type:"newline",value:p}),c++;continue}if(p==="\\"){p+=g(),h({type:"text",value:p});continue}if((p==="$"||p==="#"||p==="{")&&f()==="{"){p+=g();let b={type:"template",open:p,inner:"",close:"",value:p},S;for(;S=g();){if(S==="}"){f()==="}"&&(S+=g()),b.value+=S,b.close=S;break}S===":"?(b.initial="",b.key=b.inner):b.initial!==void 0&&(b.initial+=S),b.value+=S,b.inner+=S}b.template=b.open+(b.initial||b.inner)+b.close,b.key=b.key||b.inner,e.hasOwnProperty(b.key)&&(b.initial=e[b.key]),b=r(b),h(b),l.push(b.key),i.add(b.key);let k=a.find(T=>T.name===b.key);b.field=n.find(T=>T.name===b.key),k||(k=new nse(b),a.push(k)),k.lines.push(b.line-1);continue}let m=o[o.length-1];m.type==="text"&&m.line===c?m.value+=p:h({type:"text",value:p})}return h({type:"eos",value:""}),{input:s,tabstops:o,unique:i,keys:l,items:a}};rse.exports=async t=>{let e=t.options,r=new Set(e.required===!0?[]:e.required||[]),i=N(N({},e.values),e.initial),{tabstops:n,items:s,keys:o}=await pJe(e,i),a=SN("result",t,e),l=SN("format",t,e),c=SN("validate",t,e,!0),u=t.isValue.bind(t);return async(g={},f=!1)=>{let h=0;g.required=r,g.items=s,g.keys=o,g.output="";let p=async(S,k,T,Y)=>{let j=await c(S,k,T,Y);return j===!1?"Invalid field "+T.name:j};for(let S of n){let k=S.value,T=S.key;if(S.type!=="template"){k&&(g.output+=k);continue}if(S.type==="template"){let Y=s.find(ee=>ee.name===T);e.required===!0&&g.required.add(Y.name);let j=[Y.input,g.values[Y.value],Y.value,k].find(u),J=(Y.field||{}).message||S.inner;if(f){let ee=await p(g.values[T],g,Y,h);if(ee&&typeof ee=="string"||ee===!1){g.invalid.set(T,ee);continue}g.invalid.delete(T);let A=await a(g.values[T],g,Y,h);g.output+=ise.unstyle(A);continue}Y.placeholder=!1;let re=k;k=await l(k,g,Y,h),j!==k?(g.values[T]=j,k=t.styles.typing(j),g.missing.delete(J)):(g.values[T]=void 0,j=`<${J}>`,k=t.styles.primary(j),Y.placeholder=!0,g.required.has(T)&&g.missing.add(J)),g.missing.has(J)&&g.validating&&(k=t.styles.warning(j)),g.invalid.has(T)&&g.validating&&(k=t.styles.danger(j)),h===g.index&&(re!==k?k=t.styles.underline(k):k=t.styles.heading(ise.unstyle(k))),h++}k&&(g.output+=k)}let m=g.output.split(`
`).map(S=>" "+S),y=s.length,b=0;for(let S of s)g.invalid.has(S.name)&&S.lines.forEach(k=>{m[k][0]===" "&&(m[k]=g.styles.danger(g.symbols.bullet)+m[k].slice(1))}),t.isValue(g.values[S.name])&&b++;return g.completed=(b/y*100).toFixed(0),g.output=m.join(`
`),g.output}};function SN(t,e,r,i){return(n,s,o,a)=>typeof o.field[t]=="function"?o.field[t].call(e,n,s,o,a):[i,n].find(l=>e.isValue(l))}});var Ase=w((idt,ose)=>{"use strict";var dJe=mo(),CJe=sse(),mJe=Vf(),ase=class extends mJe{constructor(e){super(e);this.cursorHide(),this.reset(!0)}async initialize(){this.interpolate=await CJe(this),await super.initialize()}async reset(e){this.state.keys=[],this.state.invalid=new Map,this.state.missing=new Set,this.state.completed=0,this.state.values={},e!==!0&&(await this.initialize(),await this.render())}moveCursor(e){let r=this.getItem();this.cursor+=e,r.cursor+=e}dispatch(e,r){if(!r.code&&!r.ctrl&&e!=null&&this.getItem()){this.append(e,r);return}this.alert()}append(e,r){let i=this.getItem(),n=i.input.slice(0,this.cursor),s=i.input.slice(this.cursor);this.input=i.input=`${n}${e}${s}`,this.moveCursor(1),this.render()}delete(){let e=this.getItem();if(this.cursor<=0||!e.input)return this.alert();let r=e.input.slice(this.cursor),i=e.input.slice(0,this.cursor-1);this.input=e.input=`${i}${r}`,this.moveCursor(-1),this.render()}increment(e){return e>=this.state.keys.length-1?0:e+1}decrement(e){return e<=0?this.state.keys.length-1:e-1}first(){this.state.index=0,this.render()}last(){this.state.index=this.state.keys.length-1,this.render()}right(){if(this.cursor>=this.input.length)return this.alert();this.moveCursor(1),this.render()}left(){if(this.cursor<=0)return this.alert();this.moveCursor(-1),this.render()}prev(){this.state.index=this.decrement(this.state.index),this.getItem(),this.render()}next(){this.state.index=this.increment(this.state.index),this.getItem(),this.render()}up(){this.prev()}down(){this.next()}format(e){let r=this.state.completed<100?this.styles.warning:this.styles.success;return this.state.submitted===!0&&this.state.completed!==100&&(r=this.styles.danger),r(`${this.state.completed}% completed`)}async render(){let{index:e,keys:r=[],submitted:i,size:n}=this.state,s=[this.options.newline,`
`].find(S=>S!=null),o=await this.prefix(),a=await this.separator(),l=await this.message(),c=[o,l,a].filter(Boolean).join(" ");this.state.prompt=c;let u=await this.header(),g=await this.error()||"",f=await this.hint()||"",h=i?"":await this.interpolate(this.state),p=this.state.key=r[e]||"",m=await this.format(p),y=await this.footer();m&&(c+=" "+m),f&&!m&&this.state.completed===0&&(c+=" "+f),this.clear(n);let b=[u,c,h,y,g.trim()];this.write(b.filter(Boolean).join(s)),this.restore()}getItem(e){let{items:r,keys:i,index:n}=this.state,s=r.find(o=>o.name===i[n]);return s&&s.input!=null&&(this.input=s.input,this.cursor=s.cursor),s}async submit(){typeof this.interpolate!="function"&&await this.initialize(),await this.interpolate(this.state,!0);let{invalid:e,missing:r,output:i,values:n}=this.state;if(e.size){let a="";for(let[l,c]of e)a+=`Invalid ${l}: ${c}
`;return this.state.error=a,super.submit()}if(r.size)return this.state.error="Required: "+[...r.keys()].join(", "),super.submit();let o=dJe.unstyle(i).split(`
`).map(a=>a.slice(1)).join(`
`);return this.value={values:n,result:o},super.submit()}};ose.exports=ase});var use=w((ndt,lse)=>{"use strict";var EJe="(Use <shift>+<up/down> to sort)",IJe=xl(),cse=class extends IJe{constructor(e){super(ie(N({},e),{reorder:!1,sort:!0,multiple:!0}));this.state.hint=[this.options.hint,EJe].find(this.isValue.bind(this))}indicator(){return""}async renderChoice(e,r){let i=await super.renderChoice(e,r),n=this.symbols.identicalTo+" ",s=this.index===r&&this.sorting?this.styles.muted(n):" ";return this.options.drag===!1&&(s=""),this.options.numbered===!0?s+`${r+1} - `+i:s+i}get selected(){return this.choices}submit(){return this.value=this.choices.map(e=>e.value),super.submit()}};lse.exports=cse});var hse=w((sdt,gse)=>{"use strict";var yJe=ZC(),fse=class extends yJe{constructor(e={}){super(e);if(this.emptyError=e.emptyError||"No items were selected",this.term=process.env.TERM_PROGRAM,!this.options.header){let r=["","4 - Strongly Agree","3 - Agree","2 - Neutral","1 - Disagree","0 - Strongly Disagree",""];r=r.map(i=>this.styles.muted(i)),this.state.header=r.join(`
`)}}async toChoices(...e){if(this.createdScales)return!1;this.createdScales=!0;let r=await super.toChoices(...e);for(let i of r)i.scale=wJe(5,this.options),i.scaleIdx=2;return r}dispatch(){this.alert()}space(){let e=this.focused,r=e.scale[e.scaleIdx],i=r.selected;return e.scale.forEach(n=>n.selected=!1),r.selected=!i,this.render()}indicator(){return""}pointer(){return""}separator(){return this.styles.muted(this.symbols.ellipsis)}right(){let e=this.focused;return e.scaleIdx>=e.scale.length-1?this.alert():(e.scaleIdx++,this.render())}left(){let e=this.focused;return e.scaleIdx<=0?this.alert():(e.scaleIdx--,this.render())}indent(){return" "}async renderChoice(e,r){await this.onChoice(e,r);let i=this.index===r,n=this.term==="Hyper",s=n?9:8,o=n?"":" ",a=this.symbols.line.repeat(s),l=" ".repeat(s+(n?0:1)),c=k=>(k?this.styles.success("\u25C9"):"\u25EF")+o,u=r+1+".",g=i?this.styles.heading:this.styles.noop,f=await this.resolve(e.message,this.state,e,r),h=this.indent(e),p=h+e.scale.map((k,T)=>c(T===e.scaleIdx)).join(a),m=k=>k===e.scaleIdx?g(k):k,y=h+e.scale.map((k,T)=>m(T)).join(l),b=()=>[u,f].filter(Boolean).join(" "),S=()=>[b(),p,y," "].filter(Boolean).join(`
`);return i&&(p=this.styles.cyan(p),y=this.styles.cyan(y)),S()}async renderChoices(){if(this.state.submitted)return"";let e=this.visible.map(async(i,n)=>await this.renderChoice(i,n)),r=await Promise.all(e);return r.length||r.push(this.styles.danger("No matching choices")),r.join(`
`)}format(){return this.state.submitted?this.choices.map(r=>this.styles.info(r.scaleIdx)).join(", "):""}async render(){let{submitted:e,size:r}=this.state,i=await this.prefix(),n=await this.separator(),s=await this.message(),o=[i,s,n].filter(Boolean).join(" ");this.state.prompt=o;let a=await this.header(),l=await this.format(),c=await this.error()||await this.hint(),u=await this.renderChoices(),g=await this.footer();(l||!c)&&(o+=" "+l),c&&!o.includes(c)&&(o+=" "+c),e&&!l&&!u&&this.multiple&&this.type!=="form"&&(o+=this.styles.danger(this.emptyError)),this.clear(r),this.write([o,a,u,g].filter(Boolean).join(`
`)),this.restore()}submit(){this.value={};for(let e of this.choices)this.value[e.name]=e.scaleIdx;return this.base.submit.call(this)}};function wJe(t,e={}){if(Array.isArray(e.scale))return e.scale.map(i=>N({},i));let r=[];for(let i=1;i<t+1;i++)r.push({i,selected:!1});return r}gse.exports=fse});var dse=w((odt,pse)=>{pse.exports=QN()});var Ese=w((adt,Cse)=>{"use strict";var BJe=$0(),mse=class extends BJe{async initialize(){await super.initialize(),this.value=this.initial=!!this.options.initial,this.disabled=this.options.disabled||"no",this.enabled=this.options.enabled||"yes",await this.render()}reset(){this.value=this.initial,this.render()}delete(){this.alert()}toggle(){this.value=!this.value,this.render()}enable(){if(this.value===!0)return this.alert();this.value=!0,this.render()}disable(){if(this.value===!1)return this.alert();this.value=!1,this.render()}up(){this.toggle()}down(){this.toggle()}right(){this.toggle()}left(){this.toggle()}next(){this.toggle()}prev(){this.toggle()}dispatch(e="",r){switch(e.toLowerCase()){case" ":return this.toggle();case"1":case"y":case"t":return this.enable();case"0":case"n":case"f":return this.disable();default:return this.alert()}}format(){let e=i=>this.styles.primary.underline(i);return[this.value?this.disabled:e(this.disabled),this.value?e(this.enabled):this.enabled].join(this.styles.muted(" / "))}async render(){let{size:e}=this.state,r=await this.header(),i=await this.prefix(),n=await this.separator(),s=await this.message(),o=await this.format(),a=await this.error()||await this.hint(),l=await this.footer(),c=[i,s,n,o].join(" ");this.state.prompt=c,a&&!c.includes(a)&&(c+=" "+a),this.clear(e),this.write([r,c,l].filter(Boolean).join(`
`)),this.write(this.margin[2]),this.restore()}};Cse.exports=mse});var wse=w((Adt,Ise)=>{"use strict";var bJe=xl(),yse=class extends bJe{constructor(e){super(e);if(typeof this.options.correctChoice!="number"||this.options.correctChoice<0)throw new Error("Please specify the index of the correct answer from the list of choices")}async toChoices(e,r){let i=await super.toChoices(e,r);if(i.length<2)throw new Error("Please give at least two choices to the user");if(this.options.correctChoice>i.length)throw new Error("Please specify the index of the correct answer from the list of choices");return i}check(e){return e.index===this.options.correctChoice}async result(e){return{selectedAnswer:e,correctAnswer:this.options.choices[this.options.correctChoice].value,correct:await this.check(this.state)}}};Ise.exports=yse});var bse=w(kN=>{"use strict";var Bse=Xi(),Ci=(t,e)=>{Bse.defineExport(kN,t,e),Bse.defineExport(kN,t.toLowerCase(),e)};Ci("AutoComplete",()=>gne());Ci("BasicAuth",()=>Ine());Ci("Confirm",()=>Qne());Ci("Editable",()=>kne());Ci("Form",()=>Z0());Ci("Input",()=>QN());Ci("Invisible",()=>Mne());Ci("List",()=>Hne());Ci("MultiSelect",()=>Yne());Ci("Numeral",()=>zne());Ci("Password",()=>Xne());Ci("Scale",()=>tse());Ci("Select",()=>xl());Ci("Snippet",()=>Ase());Ci("Sort",()=>use());Ci("Survey",()=>hse());Ci("Text",()=>dse());Ci("Toggle",()=>Ese());Ci("Quiz",()=>wse())});var vse=w((cdt,Qse)=>{Qse.exports={ArrayPrompt:ZC(),AuthPrompt:bN(),BooleanPrompt:$0(),NumberPrompt:vN(),StringPrompt:Iu()}});var em=w((udt,Sse)=>{"use strict";var kse=require("assert"),xN=require("events"),Pl=Xi(),ua=class extends xN{constructor(e,r){super();this.options=Pl.merge({},e),this.answers=N({},r)}register(e,r){if(Pl.isObject(e)){for(let n of Object.keys(e))this.register(n,e[n]);return this}kse.equal(typeof r,"function","expected a function");let i=e.toLowerCase();return r.prototype instanceof this.Prompt?this.prompts[i]=r:this.prompts[i]=r(this.Prompt,this),this}async prompt(e=[]){for(let r of[].concat(e))try{typeof r=="function"&&(r=await r.call(this)),await this.ask(Pl.merge({},this.options,r))}catch(i){return Promise.reject(i)}return this.answers}async ask(e){typeof e=="function"&&(e=await e.call(this));let r=Pl.merge({},this.options,e),{type:i,name:n}=e,{set:s,get:o}=Pl;if(typeof i=="function"&&(i=await i.call(this,e,this.answers)),!i)return this.answers[n];kse(this.prompts[i],`Prompt "${i}" is not registered`);let a=new this.prompts[i](r),l=o(this.answers,n);a.state.answers=this.answers,a.enquirer=this,n&&a.on("submit",u=>{this.emit("answer",n,u,a),s(this.answers,n,u)});let c=a.emit.bind(a);return a.emit=(...u)=>(this.emit.call(this,...u),c(...u)),this.emit("prompt",a,this),r.autofill&&l!=null?(a.value=a.input=l,r.autofill==="show"&&await a.submit()):l=a.value=await a.run(),l}use(e){return e.call(this,this),this}set Prompt(e){this._Prompt=e}get Prompt(){return this._Prompt||this.constructor.Prompt}get prompts(){return this.constructor.prompts}static set Prompt(e){this._Prompt=e}static get Prompt(){return this._Prompt||Vf()}static get prompts(){return bse()}static get types(){return vse()}static get prompt(){let e=(r,...i)=>{let n=new this(...i),s=n.emit.bind(n);return n.emit=(...o)=>(e.emit(...o),s(...o)),n.prompt(r)};return Pl.mixinEmitter(e,new xN),e}};Pl.mixinEmitter(ua,new xN);var PN=ua.prompts;for(let t of Object.keys(PN)){let e=t.toLowerCase(),r=i=>new PN[t](i).run();ua.prompt[e]=r,ua[e]=r,ua[t]||Reflect.defineProperty(ua,t,{get:()=>PN[t]})}var $C=t=>{Pl.defineExport(ua,t,()=>ua.types[t])};$C("ArrayPrompt");$C("AuthPrompt");$C("BooleanPrompt");$C("NumberPrompt");$C("StringPrompt");Sse.exports=ua});var Hse=w((eCt,Use)=>{function xJe(t,e){for(var r=-1,i=t==null?0:t.length;++r<i&&e(t[r],r,t)!==!1;);return t}Use.exports=xJe});var $f=w((tCt,Gse)=>{var PJe=u0(),DJe=Lf();function RJe(t,e,r,i){var n=!r;r||(r={});for(var s=-1,o=e.length;++s<o;){var a=e[s],l=i?i(r[a],t[a],a,r,t):void 0;l===void 0&&(l=t[a]),n?DJe(r,a,l):PJe(r,a,l)}return r}Gse.exports=RJe});var Yse=w((rCt,jse)=>{var FJe=$f(),NJe=Uf();function LJe(t,e){return t&&FJe(e,NJe(e),t)}jse.exports=LJe});var Jse=w((iCt,qse)=>{function TJe(t){var e=[];if(t!=null)for(var r in Object(t))e.push(r);return e}qse.exports=TJe});var zse=w((nCt,Wse)=>{var OJe=Rn(),MJe=Q0(),KJe=Jse(),UJe=Object.prototype,HJe=UJe.hasOwnProperty;function GJe(t){if(!OJe(t))return KJe(t);var e=MJe(t),r=[];for(var i in t)i=="constructor"&&(e||!HJe.call(t,i))||r.push(i);return r}Wse.exports=GJe});var eh=w((sCt,_se)=>{var jJe=yF(),YJe=zse(),qJe=NC();function JJe(t){return qJe(t)?jJe(t,!0):YJe(t)}_se.exports=JJe});var Xse=w((oCt,Vse)=>{var WJe=$f(),zJe=eh();function _Je(t,e){return t&&WJe(e,zJe(e),t)}Vse.exports=_Je});var TN=w((am,th)=>{var VJe=Fs(),Zse=typeof am=="object"&&am&&!am.nodeType&&am,$se=Zse&&typeof th=="object"&&th&&!th.nodeType&&th,XJe=$se&&$se.exports===Zse,eoe=XJe?VJe.Buffer:void 0,toe=eoe?eoe.allocUnsafe:void 0;function ZJe(t,e){if(e)return t.slice();var r=t.length,i=toe?toe(r):new t.constructor(r);re Line truncated
`:"";return o?g+=`@IF EXIST ${o} (\r
${o} ${l} ${n} ${u}%*\r
) ELSE (\r
@SETLOCAL\r
@SET PATHEXT=%PATHEXT:;.JS;=;%\r
${a} ${l} ${n} ${u}%*\r
)\r
`:g+=`@${a} ${l} ${n} ${u}%*\r
`,g}function x5e(t,e,r){let i=Ws.relative(Ws.dirname(e),t),n=r.prog&&r.prog.split("\\").join("/"),s;i=i.split("\\").join("/");let o=Ws.isAbsolute(i)?`"${i}"`:`"$basedir/${i}"`,a=r.args||"",l=oT(r.nodePath).posix;n?(s=`"$basedir/${r.prog}"`,i=o):(n=o,a="",i="");let c=r.progArgs?`${r.progArgs.join(" ")} `:"",u=`#!/bin/sh
basedir=$(dirname "$(echo "$0" | sed -e 's,\\\\,/,g')")
case \`uname\` in
*CYGWIN*) basedir=\`cygpath -w "$basedir"\`;;
esac
`,g=r.nodePath?`export NODE_PATH="${l}"
`:"";return s?u+=`${g}if [ -x ${s} ]; then
exec ${s} ${a} ${i} ${c}"$@"
else
exec ${n} ${a} ${i} ${c}"$@"
fi
`:u+=`${g}${n} ${a} ${i} ${c}"$@"
exit $?
`,u}function P5e(t,e,r){let i=Ws.relative(Ws.dirname(e),t),n=r.prog&&r.prog.split("\\").join("/"),s=n&&`"${n}$exe"`,o;i=i.split("\\").join("/");let a=Ws.isAbsolute(i)?`"${i}"`:`"$basedir/${i}"`,l=r.args||"",c=oT(r.nodePath),u=c.win32,g=c.posix;s?(o=`"$basedir/${r.prog}$exe"`,i=a):(s=a,l="",i="");let f=r.progArgs?`${r.progArgs.join(" ")} `:"",h=`#!/usr/bin/env pwsh
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
$exe=""
${r.nodePath?`$env_node_path=$env:NODE_PATH
$env:NODE_PATH="${u}"
`:""}if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
# Fix case when both the Windows and Linux builds of Node
# are installed in the same directory
$exe=".exe"
}`;return r.nodePath&&(h+=` else {
$env:NODE_PATH="${g}"
}`),o?h+=`
$ret=0
if (Test-Path ${o}) {
# Support pipeline input
if ($MyInvocation.ExpectingInput) {
$input | & ${o} ${l} ${i} ${f}$args
} else {
& ${o} ${l} ${i} ${f}$args
}
$ret=$LASTEXITCODE
} else {
# Support pipeline input
if ($MyInvocation.ExpectingInput) {
$input | & ${s} ${l} ${i} ${f}$args
} else {
& ${s} ${l} ${i} ${f}$args
}
$ret=$LASTEXITCODE
}
${r.nodePath?`$env:NODE_PATH=$env_node_path
`:""}exit $ret
`:h+=`
# Support pipeline input
if ($MyInvocation.ExpectingInput) {
$input | & ${s} ${l} ${i} ${f}$args
} else {
& ${s} ${l} ${i} ${f}$args
}
${r.nodePath?`$env:NODE_PATH=$env_node_path
`:""}exit $LASTEXITCODE
`,h}function R5e(t,e){return e.fs_.chmod(t,493)}function oT(t){if(!t)return{win32:"",posix:""};let e=typeof t=="string"?t.split(Ws.delimiter):Array.from(t),r={};for(let i=0;i<e.length;i++){let n=e[i].split("/").join("\\"),s=zle()?e[i].split("\\").join("/").replace(/^([^:\\/]*):/,(o,a)=>`/mnt/${a.toLowerCase()}`):e[i];r.win32=r.win32?`${r.win32};${n}`:n,r.posix=r.posix?`${r.posix}:${s}`:s,r[i]={win32:n,posix:s}}return r}Wle.exports=sT});var yT=w((Kkt,dce)=>{dce.exports=require("stream")});var Ice=w((Ukt,Cce)=>{"use strict";function mce(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),r.push.apply(r,i)}return r}function $5e(t){for(var e=1;e<arguments.length;e++){var r=arguments[e]!=null?arguments[e]:{};e%2?mce(Object(r),!0).forEach(function(i){Z5e(t,i,r[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):mce(Object(r)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(r,i))})}return t}function Z5e(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function e_e(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Ece(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function t_e(t,e,r){return e&&Ece(t.prototype,e),r&&Ece(t,r),t}var r_e=require("buffer"),yb=r_e.Buffer,i_e=require("util"),wT=i_e.inspect,n_e=wT&&wT.custom||"inspect";function s_e(t,e,r){yb.prototype.copy.call(t,e,r)}Cce.exports=function(){function t(){e_e(this,t),this.head=null,this.tail=null,this.length=0}return t_e(t,[{key:"push",value:function(r){var i={data:r,next:null};this.length>0?this.tail.next=i:this.head=i,this.tail=i,++this.length}},{key:"unshift",value:function(r){var i={data:r,next:this.head};this.length===0&&(this.tail=i),this.head=i,++this.length}},{key:"shift",value:function(){if(this.length!==0){var r=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,r}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(r){if(this.length===0)return"";for(var i=this.head,n=""+i.data;i=i.next;)n+=r+i.data;return n}},{key:"concat",value:function(r){if(this.length===0)return yb.alloc(0);for(var i=yb.allocUnsafe(r>>>0),n=this.head,s=0;n;)s_e(n.data,i,s),s+=n.data.length,n=n.next;return i}},{key:"consume",value:function(r,i){var n;return r<this.head.data.length?(n=this.head.data.slice(0,r),this.head.data=this.head.data.slice(r)):r===this.head.data.length?n=this.shift():n=i?this._getString(r):this._getBuffer(r),n}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(r){var i=this.head,n=1,s=i.data;for(r-=s.length;i=i.next;){var o=i.data,a=r>o.length?o.length:r;if(a===o.length?s+=o:s+=o.slice(0,r),r-=a,r===0){a===o.length?(++n,i.next?this.head=i.next:this.head=this.tail=null):(this.head=i,i.data=o.slice(a));break}++n}return this.length-=n,s}},{key:"_getBuffer",value:function(r){var i=yb.allocUnsafe(r),n=this.head,s=1;for(n.data.copy(i),r-=n.data.length;n=n.next;){var o=n.data,a=r>o.length?o.length:r;if(o.copy(i,i.length-r,0,a),r-=a,r===0){a===o.length?(++s,n.next?this.head=n.next:this.head=this.tail=null):(this.head=n,n.data=o.slice(a));break}++s}return this.length-=s,i}},{key:n_e,value:function(r,i){return wT(this,$5e({},i,{depth:0,customInspect:!1}))}}]),t}()});var bT=w((Hkt,yce)=>{"use strict";function o_e(t,e){var r=this,i=this._readableState&&this._readableState.destroyed,n=this._writableState&&this._writableState.destroyed;return i||n?(e?e(t):t&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,process.nextTick(BT,this,t)):process.nextTick(BT,this,t)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(t||null,function(s){!e&&s?r._writableState?r._writableState.errorEmitted?process.nextTick(wb,r):(r._writableState.errorEmitted=!0,process.nextTick(wce,r,s)):process.nextTick(wce,r,s):e?(process.nextTick(wb,r),e(s)):process.nextTick(wb,r)}),this)}function wce(t,e){BT(t,e),wb(t)}function wb(t){t._writableState&&!t._writableState.emitClose||t._readableState&&!t._readableState.emitClose||t.emit("close")}function a_e(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function BT(t,e){t.emit("error",e)}function A_e(t,e){var r=t._readableState,i=t._wr Line truncated
`)),t.linkname&&(e+=$T(" linkpath="+t.linkname+`
`));var r=t.pax;if(r)for(var i in r)e+=$T(" "+i+"="+r[i]+`
`);return Buffer.from(e)};Ch.decodePax=function(t){for(var e={};t.length;){for(var r=0;r<t.length&&t[r]!==32;)r++;var i=parseInt(t.slice(0,r).toString(),10);if(!i)return e;var n=t.slice(r+1,i-1).toString(),s=n.indexOf("=");if(s===-1)return e;e[n.slice(0,s)]=n.slice(s+1),t=t.slice(i)}return e};Ch.encode=function(t){var e=eVe(512),r=t.name,i="";if(t.typeflag===5&&r[r.length-1]!=="/"&&(r+="/"),Buffer.byteLength(r)!==r.length)return null;for(;Buffer.byteLength(r)>100;){var n=r.indexOf("/");if(n===-1)return null;i+=i?"/"+r.slice(0,n):r.slice(0,n),r=r.slice(n+1)}return Buffer.byteLength(r)>100||Buffer.byteLength(i)>155||t.linkname&&Buffer.byteLength(t.linkname)>100?null:(e.write(r),e.write(Hl(t.mode&oVe,6),100),e.write(Hl(t.uid,6),108),e.write(Hl(t.gid,6),116),e.write(Hl(t.size,11),124),e.write(Hl(t.mtime.getTime()/1e3|0,11),136),e[156]=wue+lVe(t.type),t.linkname&&e.write(t.linkname,157),Bue.copy(e,oE),iVe.copy(e,ZT),t.uname&&e.write(t.uname,265),t.gname&&e.write(t.gname,297),e.write(Hl(t.devmajor||0,6),329),e.write(Hl(t.devminor||0,6),337),i&&e.write(i,345),e.write(Hl(Que(e),6),148),e)};Ch.decode=function(t,e,r){var i=t[156]===0?0:t[156]-wue,n=mh(t,0,100,e),s=Gl(t,100,8),o=Gl(t,108,8),a=Gl(t,116,8),l=Gl(t,124,12),c=Gl(t,136,12),u=AVe(i),g=t[157]===0?null:mh(t,157,100,e),f=mh(t,265,32),h=mh(t,297,32),p=Gl(t,329,8),m=Gl(t,337,8),y=Que(t);if(y===8*32)return null;if(y!==Gl(t,148,8))throw new Error("Invalid tar header. Maybe the tar is corrupted or it needs to be gunzipped?");if(Bue.compare(t,oE,oE+6)===0)t[345]&&(n=mh(t,345,155,e)+"/"+n);else if(!(nVe.compare(t,oE,oE+6)===0&&sVe.compare(t,ZT,ZT+2)===0)){if(!r)throw new Error("Invalid tar header: unknown format.")}return i===0&&n&&n[n.length-1]==="/"&&(i=5),{name:n,mode:s,uid:o,gid:a,size:l,mtime:new Date(1e3*c),type:u,linkname:g,uname:f,gname:h,devmajor:p,devminor:m}}});var Rue=w((axt,vue)=>{var Sue=require("util"),uVe=yue(),aE=eO(),kue=dh().Writable,xue=dh().PassThrough,Pue=function(){},Due=function(t){return t&=511,t&&512-t},gVe=function(t,e){var r=new Ob(t,e);return r.end(),r},fVe=function(t,e){return e.path&&(t.name=e.path),e.linkpath&&(t.linkname=e.linkpath),e.size&&(t.size=parseInt(e.size,10)),t.pax=e,t},Ob=function(t,e){this._parent=t,this.offset=e,xue.call(this,{autoDestroy:!1})};Sue.inherits(Ob,xue);Ob.prototype.destroy=function(t){this._parent.destroy(t)};var vA=function(t){if(!(this instanceof vA))return new vA(t);kue.call(this,t),t=t||{},this._offset=0,this._buffer=uVe(),this._missing=0,this._partial=!1,this._onparse=Pue,this._header=null,this._stream=null,this._overflow=null,this._cb=null,this._locked=!1,this._destroyed=!1,this._pax=null,this._paxGlobal=null,this._gnuLongPath=null,this._gnuLongLinkPath=null;var e=this,r=e._buffer,i=function(){e._continue()},n=function(f){if(e._locked=!1,f)return e.destroy(f);e._stream||i()},s=function(){e._stream=null;var f=Due(e._header.size);f?e._parse(f,o):e._parse(512,g),e._locked||i()},o=function(){e._buffer.consume(Due(e._header.size)),e._parse(512,g),i()},a=function(){var f=e._header.size;e._paxGlobal=aE.decodePax(r.slice(0,f)),r.consume(f),s()},l=function(){var f=e._header.size;e._pax=aE.decodePax(r.slice(0,f)),e._paxGlobal&&(e._pax=Object.assign({},e._paxGlobal,e._pax)),r.consume(f),s()},c=function(){var f=e._header.size;this._gnuLongPath=aE.decodeLongPath(r.slice(0,f),t.filenameEncoding),r.consume(f),s()},u=function(){var f=e._header.size;this._gnuLongLinkPath=aE.decodeLongPath(r.slice(0,f),t.filenameEncoding),r.consume(f),s()},g=function(){var f=e._offset,h;try{h=e._header=aE.decode(r.slice(0,512),t.filenameEncoding,t.allowUnknownFormat)}catch(p){e.emit("error",p)}if(r.consume(512),!h){e._parse(512,g),i();return}if(h.type==="gnu-long-path"){e._parse(h.size,c),i();return}if(h.type==="gnu-long-link-path"){e._parse(h.size,u),i();return}if(h.type==="pax-global-header"){e._parse(h.size,a),i();return}if(h.type==="pax-header"){e._parse(h.size,l),i();return}if(e._gnuLongPath&&(h.name=e._gnuLongPath,e._gnuLongPath=null),e._gnuLongLinkPath&&(h.linkname=e._gnuLongLinkPath,e._gnuLongLinkPath=null),e._pax&&(e._header=h=fVe(h,e._pax),e._pax=null),e._locked=!0,!h.size||h.type==="directory"){e._parse(512,g),e.emit("entry",h,gVe(e,f),n);return}e._stream=new Ob(e,f),e.emit("entry",h,e._stream,n),e._parse(h.size,s),i()};this._onheader=g,this._parse(512,g)};Sue.inherits(vA,kue);vA.prototype.destroy=function(t){this._destroyed||(this._destroyed=!0,t&&this.emit("error",t),this.emit("close"),this._stream&&this._stream.emit("close"))};vA.prototype._parse=function(t,e){this._destroyed||(this._offset+=t,this._missing=t,e===this._onheader&&(this._partial=!1),this._onparse=e)};vA.prototype._continue=function(){if(!this._destroyed){var t=this._cb;this._cb=Pue,this._overflow?this._write(this._overflow,void 0,t):t()}};vA.prototype._write=function(t,e,r){if(!this._destroyed){var i=this._stream,n=this._buffer,s=this._missing;if(t.length&&(this._partial=!0),t.length<s)return this._missing-=t.length,this._overflow=null,i?i.write(t,r):(n.appen Line truncated
Wanted: ${r.size}
Found: ${t.length}`);throw a.code="EBADSIZE",a.found=t.length,a.expected=r.size,a.sri=e,a}else{let a=new Error(`Integrity checksum failed when using ${i}: Wanted ${e}, but got ${s}. (${t.length} bytes)`);throw a.code="EINTEGRITY",a.found=s,a.expected=e,a.algorithm=i,a.sri=e,a}}ma.exports.checkStream=qVe;function qVe(t,e,r){r=Cn(r);let i=r.Promise||Promise,n=uO(r.concat({integrity:e}));return new i((s,o)=>{t.pipe(n),t.on("error",o),n.on("error",o);let a;n.on("verified",l=>{a=l}),n.on("end",()=>s(a)),n.on("data",()=>{})})}ma.exports.integrityStream=uO;function uO(t){t=Cn(t);let e=t.integrity&&Ea(t.integrity,t),r=e&&Object.keys(e).length,i=r&&e.pickAlgorithm(t),n=r&&e[i],s=Array.from(new Set(t.algorithms.concat(i?[i]:[]))),o=s.map(cE.createHash),a=0,l=new LVe({transform(c,u,g){a+=c.length,o.forEach(f=>f.update(c,u)),g(null,c,u)}}).on("end",()=>{let c=t.options&&t.options.length?`?${t.options.join("?")}`:"",u=Ea(o.map((f,h)=>`${s[h]}-${f.digest("base64")}${c}`).join(" "),t),g=r&&u.match(e,t);if(typeof t.size=="number"&&a!==t.size){let f=new Error(`stream size mismatch when checking ${e}.
Wanted: ${t.size}
Found: ${a}`);f.code="EBADSIZE",f.found=a,f.expected=t.size,f.sri=e,l.emit("error",f)}else if(t.integrity&&!g){let f=new Error(`${e} integrity checksum failed when using ${i}: wanted ${n} but got ${u}. (${a} bytes)`);f.code="EINTEGRITY",f.found=u,f.expected=n,f.algorithm=i,f.sri=e,l.emit("error",f)}else l.emit("size",a),l.emit("integrity",u),g&&l.emit("verified",g)});return l}ma.exports.create=JVe;function JVe(t){t=Cn(t);let e=t.algorithms,r=t.options.length?`?${t.options.join("?")}`:"",i=e.map(cE.createHash);return{update:function(n,s){return i.forEach(o=>o.update(n,s)),this},digest:function(n){return e.reduce((o,a)=>{let l=i.shift().digest("base64"),c=new Du(`${a}-${l}${r}`,t);if(c.algorithm&&c.digest){let u=c.algorithm;o[u]||(o[u]=[]),o[u].push(c)}return o},new wh)}}}var WVe=new Set(cE.getHashes()),tge=["md5","whirlpool","sha1","sha224","sha256","sha384","sha512","sha3","sha3-256","sha3-384","sha3-512","sha3_256","sha3_384","sha3_512"].filter(t=>WVe.has(t));function UVe(t,e){return tge.indexOf(t.toLowerCase())>=tge.indexOf(e.toLowerCase())?t:e}});var vC={};ft(vC,{BuildType:()=>ls,Cache:()=>Nt,Configuration:()=>we,DEFAULT_LOCK_FILENAME:()=>Qx,DEFAULT_RC_FILENAME:()=>bx,FormatType:()=>Di,InstallMode:()=>di,LightReport:()=>gA,LinkType:()=>Qt,Manifest:()=>At,MessageName:()=>$,MultiFetcher:()=>wd,PackageExtensionStatus:()=>qi,PackageExtensionType:()=>yi,Project:()=>ze,ProjectLookup:()=>al,Report:()=>Ji,ReportError:()=>ct,SettingsType:()=>ye,StreamReport:()=>Je,TAG_REGEXP:()=>qg,TelemetryManager:()=>QC,ThrowReport:()=>pi,VirtualFetcher:()=>bd,Workspace:()=>bC,WorkspaceFetcher:()=>Qd,WorkspaceResolver:()=>oi,YarnVersion:()=>Kr,execUtils:()=>Fr,folderUtils:()=>Cx,formatUtils:()=>Ae,hashUtils:()=>Dn,httpUtils:()=>ir,miscUtils:()=>ve,nodeUtils:()=>Wg,parseMessageName:()=>bI,scriptUtils:()=>Zt,semverUtils:()=>Wt,stringifyMessageName:()=>qA,structUtils:()=>P,tgzUtils:()=>wi,treeUtils:()=>As});var Fr={};ft(Fr,{EndStrategy:()=>ns,ExecError:()=>Rx,PipeError:()=>vw,execvp:()=>mke,pipevp:()=>$o});var $h={};ft($h,{AliasFS:()=>Da,CwdFS:()=>_t,DEFAULT_COMPRESSION_LEVEL:()=>nc,FakeFS:()=>HA,Filename:()=>Pt,JailFS:()=>Ra,LazyFS:()=>Vh,LinkStrategy:()=>Yh,NoFS:()=>_E,NodeFS:()=>ar,PortablePath:()=>Ke,PosixFS:()=>Xh,ProxiedFS:()=>bi,VirtualFS:()=>Wr,ZipFS:()=>Ai,ZipOpenFS:()=>Es,constants:()=>Dr,extendFs:()=>XE,normalizeLineEndings:()=>ec,npath:()=>H,opendir:()=>JE,patchFs:()=>SQ,ppath:()=>x,statUtils:()=>hQ,toFilename:()=>Jr,xfs:()=>K});var Dr={};ft(Dr,{SAFE_TIME:()=>fQ,S_IFDIR:()=>ka,S_IFLNK:()=>Pa,S_IFMT:()=>_n,S_IFREG:()=>xa});var _n=61440,ka=16384,xa=32768,Pa=40960,fQ=456789e3;var hQ={};ft(hQ,{BigIntStatsEntry:()=>Hh,DEFAULT_MODE:()=>Uh,DirEntry:()=>oM,StatEntry:()=>KA,areStatsEqual:()=>dQ,clearStats:()=>KE,convertToBigIntStats:()=>UE,makeDefaultStats:()=>Gh,makeEmptyStats:()=>pfe});var pQ=ge(require("util"));var Uh=xa|420,oM=class{constructor(){this.name="";this.mode=0}isBlockDevice(){return!1}isCharacterDevice(){return!1}isDirectory(){return(this.mode&_n)===ka}isFIFO(){return!1}isFile(){return(this.mode&_n)===xa}isSocket(){return!1}isSymbolicLink(){return(this.mode&_n)===Pa}},KA=class{constructor(){this.uid=0;this.gid=0;this.size=0;this.blksize=0;this.atimeMs=0;this.mtimeMs=0;this.ctimeMs=0;this.birthtimeMs=0;this.atime=new Date(0);this.mtime=new Date(0);this.ctime=new Date(0);this.birthtime=new Date(0);this.dev=0;this.ino=0;this.mode=Uh;this.nlink=1;this.rdev=0;this.blocks=1}isBlockDevice(){return!1}isCharacterDevice(){return!1}isDirectory(){return(this.mode&_n)===ka}isFIFO(){return!1}isFile(){return(this.mode&_n)===xa}isSocket(){return!1}isSymbolicLink(){return(this.mode&_n)===Pa}},Hh=class{constructor(){this.uid=BigInt(0);this.gid=BigInt(0);this.size=BigInt(0);this.blksize=BigInt(0);this.atimeMs=BigInt(0);this.mtimeMs=BigInt(0);this.ctimeMs=BigInt(0);this.birthtimeMs=BigInt(0);this.atimeNs=BigInt(0);this.mtimeNs=BigInt(0);this.ctimeNs=BigInt(0);this.birthtimeNs=BigInt(0);this.atime=new Date(0);this.mtime=new Date(0);this.ctime=new Date(0);this.birthtime=new Date(0);this.dev=BigInt(0);this.ino=BigInt(0);this.mode=BigInt(Uh);this.nlink=BigInt(1);this.rdev=BigInt(0);this.blocks=BigInt(1)}isBlockDevice(){return!1}isCharacterDevice(){return!1}isDirectory(){return(this.mode&BigInt(_n))===BigInt(ka)}isFIFO(){return!1}isFile(){return(this.mode&BigInt(_n))===BigInt(xa)}isSocket(){return!1}isSymbolicLink(){return(this.mode&BigInt(_n))===BigInt(Pa)}};function Gh(){return new KA}function pfe(){return KE(Gh())}function KE(t){for(let e in t)if(Object.prototype.hasOwnProperty.call(t,e)){let r=t[e];typeof r=="number"?t[e]=0:typeof r=="bigint"?t[e]=BigInt(0):pQ.types.isDate(r)&&(t[e]=new Date(0))}return t}function UE(t){let e=new Hh;for(let r in t)if(Object.prototype.hasOwnProperty.call(t,r)){let i=t[r];typeof i=="number"?e[r]=BigInt(i):pQ.types.isDate(i)&&(e[r]=new Date(i))}return e.atimeNs=e.atimeMs*BigInt(1e6),e.mtimeNs=e.mtimeMs*BigInt(1e6),e.ctimeNs=e.ctimeMs*BigInt(1e6),e.birthtimeNs=e.birthtimeMs*BigInt(1e6),e}function dQ(t, Line truncated
`)}writeJsonSync(e,r){return this.writeFileSync(e,`${JSON.stringify(r,null,2)}
`)}async preserveTimePromise(e,r){let i=await this.lstatPromise(e),n=await r();typeof n!="undefined"&&(e=n),this.lutimesPromise?await this.lutimesPromise(e,i.atime,i.mtime):i.isSymbolicLink()||await this.utimesPromise(e,i.atime,i.mtime)}async preserveTimeSync(e,r){let i=this.lstatSync(e),n=r();typeof n!="undefined"&&(e=n),this.lutimesSync?this.lutimesSync(e,i.atime,i.mtime):i.isSymbolicLink()||this.utimesSync(e,i.atime,i.mtime)}},tc=class extends HA{constructor(){super(x)}};function Qfe(t){let e=t.match(/\r?\n/g);if(e===null)return pM.EOL;let r=e.filter(n=>n===`\r
`).length,i=e.length-r;return r>i?`\r
`:`
`}function ec(t,e){return e.replace(/\r?\n/g,Qfe(t))}var Ju=ge(require("fs")),wQ=ge(require("stream")),EM=ge(require("util")),BQ=ge(require("zlib"));var dM=ge(require("fs"));var ar=class extends tc{constructor(e=dM.default){super();this.realFs=e,typeof this.realFs.lutimes!="undefined"&&(this.lutimesPromise=this.lutimesPromiseImpl,this.lutimesSync=this.lutimesSyncImpl)}getExtractHint(){return!1}getRealPath(){return Ke.root}resolve(e){return x.resolve(e)}async openPromise(e,r,i){return await new Promise((n,s)=>{this.realFs.open(H.fromPortablePath(e),r,i,this.makeCallback(n,s))})}openSync(e,r,i){return this.realFs.openSync(H.fromPortablePath(e),r,i)}async opendirPromise(e,r){return await new Promise((i,n)=>{typeof r!="undefined"?this.realFs.opendir(H.fromPortablePath(e),r,this.makeCallback(i,n)):this.realFs.opendir(H.fromPortablePath(e),this.makeCallback(i,n))}).then(i=>Object.defineProperty(i,"path",{value:e,configurable:!0,writable:!0}))}opendirSync(e,r){let i=typeof r!="undefined"?this.realFs.opendirSync(H.fromPortablePath(e),r):this.realFs.opendirSync(H.fromPortablePath(e));return Object.defineProperty(i,"path",{value:e,configurable:!0,writable:!0})}async readPromise(e,r,i=0,n=0,s=-1){return await new Promise((o,a)=>{this.realFs.read(e,r,i,n,s,(l,c)=>{l?a(l):o(c)})})}readSync(e,r,i,n,s){return this.realFs.readSync(e,r,i,n,s)}async writePromise(e,r,i,n,s){return await new Promise((o,a)=>typeof r=="string"?this.realFs.write(e,r,i,this.makeCallback(o,a)):this.realFs.write(e,r,i,n,s,this.makeCallback(o,a)))}writeSync(e,r,i,n,s){return typeof r=="string"?this.realFs.writeSync(e,r,i):this.realFs.writeSync(e,r,i,n,s)}async closePromise(e){await new Promise((r,i)=>{this.realFs.close(e,this.makeCallback(r,i))})}closeSync(e){this.realFs.closeSync(e)}createReadStream(e,r){let i=e!==null?H.fromPortablePath(e):e;return this.realFs.createReadStream(i,r)}createWriteStream(e,r){let i=e!==null?H.fromPortablePath(e):e;return this.realFs.createWriteStream(i,r)}async realpathPromise(e){return await new Promise((r,i)=>{this.realFs.realpath(H.fromPortablePath(e),{},this.makeCallback(r,i))}).then(r=>H.toPortablePath(r))}realpathSync(e){return H.toPortablePath(this.realFs.realpathSync(H.fromPortablePath(e),{}))}async existsPromise(e){return await new Promise(r=>{this.realFs.exists(H.fromPortablePath(e),r)})}accessSync(e,r){return this.realFs.accessSync(H.fromPortablePath(e),r)}async accessPromise(e,r){return await new Promise((i,n)=>{this.realFs.access(H.fromPortablePath(e),r,this.makeCallback(i,n))})}existsSync(e){return this.realFs.existsSync(H.fromPortablePath(e))}async statPromise(e,r){return await new Promise((i,n)=>{r?this.realFs.stat(H.fromPortablePath(e),r,this.makeCallback(i,n)):this.realFs.stat(H.fromPortablePath(e),this.makeCallback(i,n))})}statSync(e,r){return r?this.realFs.statSync(H.fromPortablePath(e),r):this.realFs.statSync(H.fromPortablePath(e))}async fstatPromise(e,r){return await new Promise((i,n)=>{r?this.realFs.fstat(e,r,this.makeCallback(i,n)):this.realFs.fstat(e,this.makeCallback(i,n))})}fstatSync(e,r){return r?this.realFs.fstatSync(e,r):this.realFs.fstatSync(e)}async lstatPromise(e,r){return await new Promise((i,n)=>{r?this.realFs.lstat(H.fromPortablePath(e),r,this.makeCallback(i,n)):this.realFs.lstat(H.fromPortablePath(e),this.makeCallback(i,n))})}lstatSync(e,r){return r?this.realFs.lstatSync(H.fromPortablePath(e),r):this.realFs.lstatSync(H.fromPortablePath(e))}async chmodPromise(e,r){return await new Promise((i,n)=>{this.realFs.chmod(H.fromPortablePath(e),r,this.makeCallback(i,n))})}chmodSync(e,r){return this.realFs.chmodSync(H.fromPortablePath(e),r)}async chownPromise(e,r,i){return await new Promise((n,s)=>{this.realFs.chown(H.fromPortablePath(e),r,i,this.makeCallback(n,s))})}chownSync(e,r,i){return this.realFs.chownSync(H.fromPortablePath(e),r,i)}async renamePromise(e,r){return await new Promise((i,n)=>{this.realFs.rename(H.fromPortablePath(e),H.fromPortablePath(r),this.makeCallback(i,n))})}renameSync(e,r){return this.realFs.renameSync(H.fromPortablePath(e),H.fromPortablePath(r))}async copyFilePromise(e,r,i=0){return await new Promise((n,s)=>{this.realFs.copyFile(H.fromPortablePath(e),H.fromPortablePath(r),i,this.makeCallback(n,s))})}copyFileSync(e,r,i=0){return this.realFs.copyFileSync(H.fromPortablePath(e),H.fromPortablePath(r),i)}async appendFilePromise(e,r,i){return await new Promise((n,s)=>{let o=typeof e=="string"?H.fromPortablePath(e):e;i?this.realFs.appendFile(o,r,i,this.makeCallback(n,s)):this.realFs.appendFile(o,r,this.makeCallback(n,s))})}appendFileSync(e,r,i){let n=typeof e=="string"?H.fromPortablePath(e):e;i?this.realFs.appendFileSync(n,r,i):this.realFs.appendFileSync(n,r)}async writeFilePromise(e,r,i){return await new Promise((n,s)=>{let o=typeof e=="string"?H.fromPortablePath(e):e;i?this.realFs.writeFile(o,r,i,this.makeCallback(n,s)):this.realFs.writeFile(o,r,this.makeCallback(n,s))})}writeFileSync(e,r,i){let n=typeof e=="string"?H.fromPortablePath(e):e;i?this.realFs.writeFileSync(n,r,i Line truncated
`;if(typeof t=="number"||typeof t=="boolean")return`${t.toString()}
`;if(typeof t=="string")return`${hU(t)}
`;if(Array.isArray(t)){if(t.length===0)return`[]
`;let i=" ".repeat(e);return`
${t.map(s=>`${i}- ${iv(s,e+1,!1)}`).join("")}`}if(typeof t=="object"&&t){let i,n;t instanceof rv?(i=t.data,n=!1):(i=t,n=!0);let s=" ".repeat(e),o=Object.keys(i);n&&o.sort((l,c)=>{let u=fU.indexOf(l),g=fU.indexOf(c);return u===-1&&g===-1?l<c?-1:l>c?1:0:u!==-1&&g===-1?-1:u===-1&&g!==-1?1:u-g});let a=o.filter(l=>!pU(i[l])).map((l,c)=>{let u=i[l],g=hU(l),f=iv(u,e+1,!0),h=c>0||r?s:"",p=g.length>1024?`? ${g}
${h}:`:`${g}:`,m=f.startsWith(`
`)?f:` ${f}`;return`${h}${p}${m}`}).join(e===0?`
`:"")||`
`;return r?`
${a}`:`${a}`}throw new Error(`Unsupported value type (${t})`)}function La(t){try{let e=iv(t,0,!1);return e!==`
`?e:""}catch(e){throw e.location&&(e.message=e.message.replace(/(\.)?$/,` (line ${e.location.start.line}, column ${e.location.start.column})$1`)),e}}La.PreserveOrdering=rv;function Ude(t){return t.endsWith(`
`)||(t+=`
`),(0,gU.parse)(t)}var Hde=/^(#.*(\r?\n))*?#\s+yarn\s+lockfile\s+v1\r?\n/i;function Gde(t){if(Hde.test(t))return Ude(t);let e=(0,pI.safeLoad)(t,{schema:pI.FAILSAFE_SCHEMA,json:!0});if(e==null)return{};if(typeof e!="object")throw new Error(`Expected an indexed object, got a ${typeof e} instead. Does your file follow Yaml's rules?`);if(Array.isArray(e))throw new Error("Expected an indexed object, got an array instead. Does your file follow Yaml's rules?");return e}function Qi(t){return Gde(t)}var i4=ge(CU()),ww=ge(pc());var mp={};ft(mp,{Builtins:()=>mv,Cli:()=>ys,Command:()=>Re,Option:()=>W,UsageError:()=>Pe,formatMarkdownish:()=>Ui});var dc=0,Ap=1,tn=2,sv="",vi="\0",og=-1,ov=/^(-h|--help)(?:=([0-9]+))?$/,dI=/^(--[a-z]+(?:-[a-z]+)*|-[a-zA-Z]+)$/,wU=/^-[a-zA-Z]{2,}$/,av=/^([^=]+)=([\s\S]*)$/,Av=process.env.DEBUG_CLI==="1";var Pe=class extends Error{constructor(e){super(e);this.clipanion={type:"usage"},this.name="UsageError"}},lp=class extends Error{constructor(e,r){super();if(this.input=e,this.candidates=r,this.clipanion={type:"none"},this.name="UnknownSyntaxError",this.candidates.length===0)this.message="Command not found, but we're not sure what's the alternative.";else if(this.candidates.every(i=>i.reason!==null&&i.reason===r[0].reason)){let[{reason:i}]=this.candidates;this.message=`${i}
${this.candidates.map(({usage:n})=>`$ ${n}`).join(`
`)}`}else if(this.candidates.length===1){let[{usage:i}]=this.candidates;this.message=`Command not found; did you mean:
$ ${i}
${lv(e)}`}else this.message=`Command not found; did you mean one of:
${this.candidates.map(({usage:i},n)=>`${`${n}.`.padStart(4)} ${i}`).join(`
`)}
${lv(e)}`}},cv=class extends Error{constructor(e,r){super();this.input=e,this.usages=r,this.clipanion={type:"none"},this.name="AmbiguousSyntaxError",this.message=`Cannot find which to pick amongst the following alternatives:
${this.usages.map((i,n)=>`${`${n}.`.padStart(4)} ${i}`).join(`
`)}
${lv(e)}`}},lv=t=>`While running ${t.filter(e=>e!==vi).map(e=>{let r=JSON.stringify(e);return e.match(/\s/)||e.length===0||r!==`"${e}"`?r:e}).join(" ")}`;var cp=Symbol("clipanion/isOption");function rn(t){return ie(N({},t),{[cp]:!0})}function No(t,e){return typeof t=="undefined"?[t,e]:typeof t=="object"&&t!==null&&!Array.isArray(t)?[void 0,t]:[t,e]}function CI(t,e=!1){let r=t.replace(/^\.: /,"");return e&&(r=r[0].toLowerCase()+r.slice(1)),r}function up(t,e){return e.length===1?new Pe(`${t}: ${CI(e[0],!0)}`):new Pe(`${t}:
${e.map(r=>`
- ${CI(r)}`).join("")}`)}function gp(t,e,r){if(typeof r=="undefined")return e;let i=[],n=[],s=a=>{let l=e;return e=a,s.bind(null,l)};if(!r(e,{errors:i,coercions:n,coercion:s}))throw up(`Invalid value for ${t}`,i);for(let[,a]of n)a();return e}var Re=class{constructor(){this.help=!1}static Usage(e){return e}async catch(e){throw e}async validateAndExecute(){let r=this.constructor.schema;if(Array.isArray(r)){let{isDict:n,isUnknown:s,applyCascade:o}=await Promise.resolve().then(()=>(Is(),ag)),a=o(n(s()),r),l=[],c=[];if(!a(this,{errors:l,coercions:c}))throw up("Invalid option schema",l);for(let[,g]of c)g()}else if(r!=null)throw new Error("Invalid command schema");let i=await this.execute();return typeof i!="undefined"?i:0}};Re.isOption=cp;Re.Default=[];var RU=80,fv=Array(RU).fill("\u2501");for(let t=0;t<=24;++t)fv[fv.length-t]=`[38;5;${232+t}m\u2501`;var hv={header:t=>`\u2501\u2501\u2501 ${t}${t.length<RU-5?` ${fv.slice(t.length+5).join("")}`:":"}`,bold:t=>`${t}`,error:t=>`${t}`,code:t=>`${t}`},FU={header:t=>t,bold:t=>t,error:t=>t,code:t=>t};function bCe(t){let e=t.split(`
`),r=e.filter(n=>n.match(/\S/)),i=r.length>0?r.reduce((n,s)=>Math.min(n,s.length-s.trimStart().length),Number.MAX_VALUE):0;return e.map(n=>n.slice(i).trimRight()).join(`
`)}function Ui(t,{format:e,paragraphs:r}){return t=t.replace(/\r\n?/g,`
`),t=bCe(t),t=t.replace(/^\n+|\n+$/g,""),t=t.replace(/^(\s*)-([^\n]*?)\n+/gm,`$1-$2
`),t=t.replace(/\n(\n)?\n*/g,"$1"),r&&(t=t.split(/\n/).map(i=>{let n=i.match(/^\s*[*-][\t ]+(.*)/);if(!n)return i.match(/(.{1,80})(?: |$)/g).join(`
`);let s=i.length-i.trimStart().length;return n[1].match(new RegExp(`(.{1,${78-s}})(?: |$)`,"g")).map((o,a)=>" ".repeat(s)+(a===0?"- ":" ")+o).join(`
`)}).join(`
`)),t=t.replace(/(`+)((?:.|[\n])*?)\1/g,(i,n,s)=>e.code(n+s+n)),t=t.replace(/(\*\*)((?:.|[\n])*?)\1/g,(i,n,s)=>e.bold(n+s+n)),t?`${t}
`:""}var Cv=ge(require("tty"));function wn(t){Av&&console.log(t)}var NU={candidateUsage:null,requiredOptions:[],errorMessage:null,ignoreOptions:!1,path:[],positionals:[],options:[],remainder:null,selectedIndex:og};function LU(){return{nodes:[sn(),sn(),sn()]}}function vCe(t){let e=LU(),r=[],i=e.nodes.length;for(let n of t){r.push(i);for(let s=0;s<n.nodes.length;++s)TU(s)||e.nodes.push(QCe(n.nodes[s],i));i+=n.nodes.length-2}for(let n of r)Ag(e,dc,n);return e}function no(t,e){return t.nodes.push(e),t.nodes.length-1}function SCe(t){let e=new Set,r=i=>{if(e.has(i))return;e.add(i);let n=t.nodes[i];for(let o of Object.values(n.statics))for(let{to:a}of o)r(a);for(let[,{to:o}]of n.dynamics)r(o);for(let{to:o}of n.shortcuts)r(o);let s=new Set(n.shortcuts.map(({to:o})=>o));for(;n.shortcuts.length>0;){let{to:o}=n.shortcuts.shift(),a=t.nodes[o];for(let[l,c]of Object.entries(a.statics)){let u=Object.prototype.hasOwnProperty.call(n.statics,l)?n.statics[l]:n.statics[l]=[];for(let g of c)u.some(({to:f})=>g.to===f)||u.push(g)}for(let[l,c]of a.dynamics)n.dynamics.some(([u,{to:g}])=>l===u&&c.to===g)||n.dynamics.push([l,c]);for(let l of a.shortcuts)s.has(l.to)||(n.shortcuts.push(l),s.add(l.to))}};r(dc)}function kCe(t,{prefix:e=""}={}){if(Av){wn(`${e}Nodes are:`);for(let r=0;r<t.nodes.length;++r)wn(`${e} ${r}: ${JSON.stringify(t.nodes[r])}`)}}function OU(t,e,r=!1){wn(`Running a vm on ${JSON.stringify(e)}`);let i=[{node:dc,state:{candidateUsage:null,requiredOptions:[],errorMessage:null,ignoreOptions:!1,options:[],path:[],positionals:[],remainder:null,selectedIndex:null}}];kCe(t,{prefix:" "});let n=[sv,...e];for(let s=0;s<n.length;++s){let o=n[s];wn(` Processing ${JSON.stringify(o)}`);let a=[];for(let{node:l,state:c}of i){wn(` Current node is ${l}`);let u=t.nodes[l];if(l===tn){a.push({node:l,state:c});continue}console.assert(u.shortcuts.length===0,"Shortcuts should have been eliminated by now");let g=Object.prototype.hasOwnProperty.call(u.statics,o);if(!r||s<n.length-1||g)if(g){let f=u.statics[o];for(let{to:h,reducer:p}of f)a.push({node:h,state:typeof p!="undefined"?EI(pv,p,c,o):c}),wn(` Static transition to ${h} found`)}else wn(" No static transition found");else{let f=!1;for(let h of Object.keys(u.statics))if(!!h.startsWith(o)){if(o===h)for(let{to:p,reducer:m}of u.statics[h])a.push({node:p,state:typeof m!="undefined"?EI(pv,m,c,o):c}),wn(` Static transition to ${p} found`);else for(let{to:p}of u.statics[h])a.push({node:p,state:ie(N({},c),{remainder:h.slice(o.length)})}),wn(` Static transition to ${p} found (partial match)`);f=!0}f||wn(" No partial static transition found")}if(o!==vi)for(let[f,{to:h,reducer:p}]of u.dynamics)EI(II,f,c,o)&&(a.push({node:h,state:typeof p!="undefined"?EI(pv,p,c,o):c}),wn(` Dynamic transition to ${h} found (via ${f})`))}if(a.length===0&&o===vi&&e.length===1)return[{node:dc,state:NU}];if(a.length===0)throw new lp(e,i.filter(({node:l})=>l!==tn).map(({state:l})=>({usage:l.candidateUsage,reason:null})));if(a.every(({node:l})=>l===tn))throw new lp(e,a.map(({state:l})=>({usage:l.candidateUsage,reason:l.errorMessage})));i=xCe(a)}if(i.length>0){wn(" Results:");for(let s of i)wn(` - ${s.node} -> ${JSON.stringify(s.state)}`)}else wn(" No results");return i}function PCe(t,e){if(e.selectedIndex!==null)return!0;if(Object.prototype.hasOwnProperty.call(t.statics,vi)){for(let{to:r}of t.statics[vi])if(r===Ap)return!0}return!1}function RCe(t,e,r){let i=r&&e.length>0?[""]:[],n=OU(t,e,r),s=[],o=new Set,a=(l,c,u=!0)=>{let g=[c];for(;g.length>0;){let h=g;g=[];for(let p of h){let m=t.nodes[p],y=Object.keys(m.statics);for(let b of Object.keys(m.statics)){let S=y[0];for(let{to:k,reducer:T}of m.statics[S])T==="pushPath"&&(u||l.push(S),g.push(k))}}u=!1}let f=JSON.stringify(l);o.has(f)||(s.push(l),o.add(f))};for(let{node:l,state:c}of n){if(c.remainder!==null){a([c.remainder],l);continue}let u=t.nodes[l],g=PCe(u,c);for(let[f,h]of Object.entries(u.statics))(g&&f!==vi||!f.startsWith("-")&&h.some(({reducer:p})=>p==="pushPath"))&&a([...i,f],l);if(!!g)for(let[f,{to:h}]of u.dynamics){if(h===tn)continue;let p=DCe(f,c);if(p!==null)for(let m of p)a([...i,m],l)}}return[...s].sort()}function NCe(t,e){let r=OU(t,[...e,vi]);return FCe(e,r.map(({state:i})=>i))}function xCe(t){let e=0;for(let{state:r}of t)r.path.length>e&&(e=r.path.length);return t.filter(({state:r})=>r.path.length===e)}function FCe(t,e){let r=e.filter(g=>g.selectedIndex!==null);if(r.length===0)throw new Error;let i=r.filter(g=>g.requiredOptions.every(f=>f.some(h=>g.options.find(p=>p.name===h))));if(i.length===0)throw new lp(t,r.map(g=>({usage:g.candidateUsage,reason:null})));let n=0;for(let g of i)g.path.length>n&&(n=g.path.length);let s=i.filter(g=>g.path.length===n),o=g=>g.positionals.filter(({extra:f})=>!f).length+g.options.length,a=s.map(g=>({state:g,positionalCount:o(g)})),l=0;for(let{positionalCount:g}of a)g>l&&(l=g);let c=a.filter(({positionalCount:g})=>g===l).map(({state:g})=>g),u=LCe(c);if(u.length>1)throw new cv(t,u.map(g=>g.ca Line truncated
`),this.context.stdout.write(`
`);let r=0;for(let i of this.commands)this.context.stdout.write(this.cli.usage(this.contexts[i].commandClass,{prefix:`${r++}. `.padStart(5)}));this.context.stdout.write(`
`),this.context.stdout.write(`Run again with -h=<index> to see the longer details of any of those commands.
`)}}};var UU=Symbol("clipanion/errorCommand");function TCe(){return process.env.FORCE_COLOR==="0"?1:process.env.FORCE_COLOR==="1"||typeof process.stdout!="undefined"&&process.stdout.isTTY?8:1}var ys=class{constructor({binaryLabel:e,binaryName:r="...",binaryVersion:i,enableCapture:n=!1,enableColors:s}={}){this.registrations=new Map,this.builder=new dp({binaryName:r}),this.binaryLabel=e,this.binaryName=r,this.binaryVersion=i,this.enableCapture=n,this.enableColors=s}static from(e,r={}){let i=new ys(r);for(let n of e)i.register(n);return i}register(e){var r;let i=new Map,n=new e;for(let l in n){let c=n[l];typeof c=="object"&&c!==null&&c[Re.isOption]&&i.set(l,c)}let s=this.builder.command(),o=s.cliIndex,a=(r=e.paths)!==null&&r!==void 0?r:n.paths;if(typeof a!="undefined")for(let l of a)s.addPath(l);this.registrations.set(e,{specs:i,builder:s,index:o});for(let[l,{definition:c}]of i.entries())c(s,l);s.setContext({commandClass:e})}process(e){let{contexts:r,process:i}=this.builder.compile(),n=i(e);switch(n.selectedIndex){case og:return Cp.from(n,r);default:{let{commandClass:s}=r[n.selectedIndex],o=this.registrations.get(s);if(typeof o=="undefined")throw new Error("Assertion failed: Expected the command class to have been registered.");let a=new s;a.path=n.path;try{for(let[l,{transformer:c}]of o.specs.entries())a[l]=c(o.builder,l,n);return a}catch(l){throw l[UU]=a,l}}break}}async run(e,r){var i;let n,s=N(N({},ys.defaultContext),r),o=(i=this.enableColors)!==null&&i!==void 0?i:s.colorDepth>1;if(!Array.isArray(e))n=e;else try{n=this.process(e)}catch(c){return s.stdout.write(this.error(c,{colored:o})),1}if(n.help)return s.stdout.write(this.usage(n,{colored:o,detailed:!0})),0;n.context=s,n.cli={binaryLabel:this.binaryLabel,binaryName:this.binaryName,binaryVersion:this.binaryVersion,enableCapture:this.enableCapture,enableColors:this.enableColors,definitions:()=>this.definitions(),error:(c,u)=>this.error(c,u),format:c=>this.format(c),process:c=>this.process(c),run:(c,u)=>this.run(c,N(N({},s),u)),usage:(c,u)=>this.usage(c,u)};let a=this.enableCapture?OCe(s):HU,l;try{l=await a(()=>n.validateAndExecute().catch(c=>n.catch(c).then(()=>0)))}catch(c){return s.stdout.write(this.error(c,{colored:o,command:n})),1}return l}async runExit(e,r){process.exitCode=await this.run(e,r)}suggest(e,r){let{suggest:i}=this.builder.compile();return i(e,r)}definitions({colored:e=!1}={}){let r=[];for(let[i,{index:n}]of this.registrations){if(typeof i.usage=="undefined")continue;let{usage:s}=this.getUsageByIndex(n,{detailed:!1}),{usage:o,options:a}=this.getUsageByIndex(n,{detailed:!0,inlineOptions:!1}),l=typeof i.usage.category!="undefined"?Ui(i.usage.category,{format:this.format(e),paragraphs:!1}):void 0,c=typeof i.usage.description!="undefined"?Ui(i.usage.description,{format:this.format(e),paragraphs:!1}):void 0,u=typeof i.usage.details!="undefined"?Ui(i.usage.details,{format:this.format(e),paragraphs:!0}):void 0,g=typeof i.usage.examples!="undefined"?i.usage.examples.map(([f,h])=>[Ui(f,{format:this.format(e),paragraphs:!1}),h.replace(/\$0/g,this.binaryName)]):void 0;r.push({path:s,usage:o,category:l,description:c,details:u,examples:g,options:a})}return r}usage(e=null,{colored:r,detailed:i=!1,prefix:n="$ "}={}){var s;if(e===null){for(let l of this.registrations.keys()){let c=l.paths,u=typeof l.usage!="undefined";if(!c||c.length===0||c.length===1&&c[0].length===0||((s=c==null?void 0:c.some(h=>h.length===0))!==null&&s!==void 0?s:!1))if(e){e=null;break}else e=l;else if(u){e=null;continue}}e&&(i=!0)}let o=e!==null&&e instanceof Re?e.constructor:e,a="";if(o)if(i){let{description:l="",details:c="",examples:u=[]}=o.usage||{};l!==""&&(a+=Ui(l,{format:this.format(r),paragraphs:!1}).replace(/^./,h=>h.toUpperCase()),a+=`
`),(c!==""||u.length>0)&&(a+=`${this.format(r).header("Usage")}
`,a+=`
`);let{usage:g,options:f}=this.getUsageByRegistration(o,{inlineOptions:!1});if(a+=`${this.format(r).bold(n)}${g}
`,f.length>0){a+=`
`,a+=`${hv.header("Options")}
`;let h=f.reduce((p,m)=>Math.max(p,m.definition.length),0);a+=`
`;for(let{definition:p,description:m}of f)a+=` ${this.format(r).bold(p.padEnd(h))} ${Ui(m,{format:this.format(r),paragraphs:!1})}`}if(c!==""&&(a+=`
`,a+=`${this.format(r).header("Details")}
`,a+=`
`,a+=Ui(c,{format:this.format(r),paragraphs:!0})),u.length>0){a+=`
`,a+=`${this.format(r).header("Examples")}
`;for(let[h,p]of u)a+=`
`,a+=Ui(h,{format:this.format(r),paragraphs:!1}),a+=`${p.replace(/^/m,` ${this.format(r).bold(n)}`).replace(/\$0/g,this.binaryName)}
`}}else{let{usage:l}=this.getUsageByRegistration(o);a+=`${this.format(r).bold(n)}${l}
`}else{let l=new Map;for(let[f,{index:h}]of this.registrations.entries()){if(typeof f.usage=="undefined")continue;let p=typeof f.usage.category!="undefined"?Ui(f.usage.category,{format:this.format(r),paragraphs:!1}):null,m=l.get(p);typeof m=="undefined"&&l.set(p,m=[]);let{usage:y}=this.getUsageByIndex(h);m.push({commandClass:f,usage:y})}let c=Array.from(l.keys()).sort((f,h)=>f===null?-1:h===null?1:f.localeCompare(h,"en",{usage:"sort",caseFirst:"upper"})),u=typeof this.binaryLabel!="undefined",g=typeof this.binaryVersion!="undefined";u||g?(u&&g?a+=`${this.format(r).header(`${this.binaryLabel} - ${this.binaryVersion}`)}
`:u?a+=`${this.format(r).header(`${this.binaryLabel}`)}
`:a+=`${this.format(r).header(`${this.binaryVersion}`)}
`,a+=` ${this.format(r).bold(n)}${this.binaryName} <command>
`):a+=`${this.format(r).bold(n)}${this.binaryName} <command>
`;for(let f of c){let h=l.get(f).slice().sort((m,y)=>m.usage.localeCompare(y.usage,"en",{usage:"sort",caseFirst:"upper"})),p=f!==null?f.trim():"General commands";a+=`
`,a+=`${this.format(r).header(`${p}`)}
`;for(let{commandClass:m,usage:y}of h){let b=m.usage.description||"undocumented";a+=`
`,a+=` ${this.format(r).bold(y)}
`,a+=` ${Ui(b,{format:this.format(r),paragraphs:!1})}`}}a+=`
`,a+=Ui("You can also print more details about any of these commands by calling them with the `-h,--help` flag right after the command name.",{format:this.format(r),paragraphs:!0})}return a}error(e,r){var i,{colored:n,command:s=(i=e[UU])!==null&&i!==void 0?i:null}=r===void 0?{}:r;e instanceof Error||(e=new Error(`Execution failed with a non-error rejection (rejected value: ${JSON.stringify(e)})`));let o="",a=e.name.replace(/([a-z])([A-Z])/g,"$1 $2");a==="Error"&&(a="Internal Error"),o+=`${this.format(n).error(a)}: ${e.message}
`;let l=e.clipanion;return typeof l!="undefined"?l.type==="usage"&&(o+=`
`,o+=this.usage(s)):e.stack&&(o+=`${e.stack.replace(/^.*\n/,"")}
`),o}format(e){var r;return((r=e!=null?e:this.enableColors)!==null&&r!==void 0?r:ys.defaultContext.colorDepth>1)?hv:FU}getUsageByRegistration(e,r){let i=this.registrations.get(e);if(typeof i=="undefined")throw new Error("Assertion failed: Unregistered command");return this.getUsageByIndex(i.index,r)}getUsageByIndex(e,r){return this.builder.getBuilderByIndex(e).usage(r)}};ys.defaultContext={stdin:process.stdin,stdout:process.stdout,stderr:process.stderr,colorDepth:"getColorDepth"in Cv.default.WriteStream.prototype?Cv.default.WriteStream.prototype.getColorDepth():TCe()};var GU;function OCe(t){let e=GU;if(typeof e=="undefined"){if(t.stdout===process.stdout&&t.stderr===process.stderr)return HU;let{AsyncLocalStorage:r}=require("async_hooks");e=GU=new r;let i=process.stdout._write;process.stdout._write=function(s,o,a){let l=e.getStore();return typeof l=="undefined"?i.call(this,s,o,a):l.stdout.write(s,o,a)};let n=process.stderr._write;process.stderr._write=function(s,o,a){let l=e.getStore();return typeof l=="undefined"?n.call(this,s,o,a):l.stderr.write(s,o,a)}}return r=>e.run(t,r)}function HU(t){return t()}var mv={};ft(mv,{DefinitionsCommand:()=>yI,HelpCommand:()=>wI,VersionCommand:()=>BI});var yI=class extends Re{async execute(){this.context.stdout.write(`${JSON.stringify(this.cli.definitions(),null,2)}
`)}};yI.paths=[["--clipanion=definitions"]];var wI=class extends Re{async execute(){this.context.stdout.write(this.cli.usage())}};wI.paths=[["-h"],["--help"]];var BI=class extends Re{async execute(){var e;this.context.stdout.write(`${(e=this.cli.binaryVersion)!==null&&e!==void 0?e:"<unknown>"}
`)}};BI.paths=[["-v"],["--version"]];var W={};ft(W,{Array:()=>jU,Boolean:()=>YU,Counter:()=>qU,Proxy:()=>JU,Rest:()=>WU,String:()=>zU,applyValidator:()=>gp,cleanValidationError:()=>CI,formatError:()=>up,isOptionSymbol:()=>cp,makeCommandOption:()=>rn,rerouteArguments:()=>No});function jU(t,e,r){let[i,n]=No(e,r!=null?r:{}),{arity:s=1}=n,o=t.split(","),a=new Set(o);return rn({definition(l){l.addOption({names:o,arity:s,hidden:n==null?void 0:n.hidden,description:n==null?void 0:n.description,required:n.required})},transformer(l,c,u){let g=typeof i!="undefined"?[...i]:void 0;for(let{name:f,value:h}of u.options)!a.has(f)||(g=g!=null?g:[],g.push(h));return g}})}function YU(t,e,r){let[i,n]=No(e,r!=null?r:{}),s=t.split(","),o=new Set(s);return rn({definition(a){a.addOption({names:s,allowBinding:!1,arity:0,hidden:n.hidden,description:n.description,required:n.required})},transformer(a,l,c){let u=i;for(let{name:g,value:f}of c.options)!o.has(g)||(u=f);return u}})}function qU(t,e,r){let[i,n]=No(e,r!=null?r:{}),s=t.split(","),o=new Set(s);return rn({definition(a){a.addOption({names:s,allowBinding:!1,arity:0,hidden:n.hidden,description:n.description,required:n.required})},transformer(a,l,c){let u=i;for(let{name:g,value:f}of c.options)!o.has(g)||(u!=null||(u=0),f?u+=1:u=0);return u}})}function JU(t={}){return rn({definition(e,r){var i;e.addProxy({name:(i=t.name)!==null&&i!==void 0?i:r,required:t.required})},transformer(e,r,i){return i.positionals.map(({value:n})=>n)}})}function WU(t={}){return rn({definition(e,r){var i;e.addRest({name:(i=t.name)!==null&&i!==void 0?i:r,required:t.required})},transformer(e,r,i){let n=o=>{let a=i.positionals[o];return a.extra===Xn||a.extra===!1&&o<e.arity.leading.length},s=0;for(;s<i.positionals.length&&n(s);)s+=1;return i.positionals.splice(0,s).map(({value:o})=>o)}})}function MCe(t,e,r){let[i,n]=No(e,r!=null?r:{}),{arity:s=1}=n,o=t.split(","),a=new Set(o);return rn({definition(l){l.addOption({names:o,arity:n.tolerateBoolean?0:s,hidden:n.hidden,description:n.description,required:n.required})},transformer(l,c,u){let g,f=i;for(let{name:h,value:p}of u.options)!a.has(h)||(g=h,f=p);return typeof f=="string"?gp(g!=null?g:c,f,n.validator):f}})}function KCe(t={}){let{required:e=!0}=t;return rn({definition(r,i){var n;r.addPositional({name:(n=t.name)!==null&&n!==void 0?n:i,required:t.required})},transformer(r,i,n){var s;for(let o=0;o<n.positionals.length;++o){if(n.positionals[o].extra===Xn||e&&n.positionals[o].extra===!0||!e&&n.positionals[o].extra===!1)continue;let[a]=n.positionals.splice(o,1);return gp((s=t.name)!==null&&s!==void 0?s:i,a.value,t.validator)}}})}function zU(t,...e){return typeof t=="string"?MCe(t,...e):KCe(t)}var n4=ge(lg()),Bx=ge(require("stream"));var $;(function(ae){ae[ae.UNNAMED=0]="UNNAMED",ae[ae.EXCEPTION=1]="EXCEPTION",ae[ae.MISSING_PEER_DEPENDENCY=2]="MISSING_PEER_DEPENDENCY",ae[ae.CYCLIC_DEPENDENCIES=3]="CYCLIC_DEPENDENCIES",ae[ae.DISABLED_BUILD_SCRIPTS=4]="DISABLED_BUILD_SCRIPTS",ae[ae.BUILD_DISABLED=5]="BUILD_DISABLED",ae[ae.SOFT_LINK_BUILD=6]="SOFT_LINK_BUILD",ae[ae.MUST_BUILD=7]="MUST_BUILD",ae[ae.MUST_REBUILD=8]="MUST_REBUILD",ae[ae.BUILD_FAILED=9]="BUILD_FAILED",ae[ae.RESOLVER_NOT_FOUND=10]="RESOLVER_NOT_FOUND",ae[ae.FETCHER_NOT_FOUND=11]="FETCHER_NOT_FOUND",ae[ae.LINKER_NOT_FOUND=12]="LINKER_NOT_FOUND",ae[ae.FETCH_NOT_CACHED=13]="FETCH_NOT_CACHED",ae[ae.YARN_IMPORT_FAILED=14]="YARN_IMPORT_FAILED",ae[ae.REMOTE_INVALID=15]="REMOTE_INVALID",ae[ae.REMOTE_NOT_FOUND=16]="REMOTE_NOT_FOUND",ae[ae.RESOLUTION_PACK=17]="RESOLUTION_PACK",ae[ae.CACHE_CHECKSUM_MISMATCH=18]="CACHE_CHECKSUM_MISMATCH",ae[ae.UNUSED_CACHE_ENTRY=19]="UNUSED_CACHE_ENTRY",ae[ae.MISSING_LOCKFILE_ENTRY=20]="MISSING_LOCKFILE_ENTRY",ae[ae.WORKSPACE_NOT_FOUND=21]="WORKSPACE_NOT_FOUND",ae[ae.TOO_MANY_MATCHING_WORKSPACES=22]="TOO_MANY_MATCHING_WORKSPACES",ae[ae.CONSTRAINTS_MISSING_DEPENDENCY=23]="CONSTRAINTS_MISSING_DEPENDENCY",ae[ae.CONSTRAINTS_INCOMPATIBLE_DEPENDENCY=24]="CONSTRAINTS_INCOMPATIBLE_DEPENDENCY",ae[ae.CONSTRAINTS_EXTRANEOUS_DEPENDENCY=25]="CONSTRAINTS_EXTRANEOUS_DEPENDENCY",ae[ae.CONSTRAINTS_INVALID_DEPENDENCY=26]="CONSTRAINTS_INVALID_DEPENDENCY",ae[ae.CANT_SUGGEST_RESOLUTIONS=27]="CANT_SUGGEST_RESOLUTIONS",ae[ae.FROZEN_LOCKFILE_EXCEPTION=28]="FROZEN_LOCKFILE_EXCEPTION",ae[ae.CROSS_DRIVE_VIRTUAL_LOCAL=29]="CROSS_DRIVE_VIRTUAL_LOCAL",ae[ae.FETCH_FAILED=30]="FETCH_FAILED",ae[ae.DANGEROUS_NODE_MODULES=31]="DANGEROUS_NODE_MODULES",ae[ae.NODE_GYP_INJECTED=32]="NODE_GYP_INJECTED",ae[ae.AUTHENTICATION_NOT_FOUND=33]="AUTHENTICATION_NOT_FOUND",ae[ae.INVALID_CONFIGURATION_KEY=34]="INVALID_CONFIGURATION_KEY",ae[ae.NETWORK_ERROR=35]="NETWORK_ERROR",ae[ae.LIFECYCLE_SCRIPT=36]="LIFECYCLE_SCRIPT",ae[ae.CONSTRAINTS_MISSING_FIELD=37]="CONSTRAINTS_MISSING_FIELD",ae[ae.CONSTRAINTS_INCOMPATIBLE_FIELD=38]="CONSTRAINTS_INCOMPATIBLE_FIELD",ae[ae.CONSTRAINTS_EXTRANEOUS_FIELD=39]="CONSTRAINTS_EXTRANEOUS_FIELD",ae[ae.CONSTRAINTS_INVALID_FIELD=40]="CONSTRAINTS_INVALID_FIELD",ae[ae.AUTHENTICATION_INVALID=41]="AUTHENTICATION_INVA Line truncated
`),a!==-1){let l=n+o.substring(0,a);o=o.substring(a+1),n="",e!==null?this.reportInfo(null,`${e} ${l}`):this.reportInfo(null,l)}while(a!==-1);n+=o}),r.on("end",()=>{let s=i.end();s!==""&&(e!==null?this.reportInfo(null,`${e} ${s}`):this.reportInfo(null,s))}),r}};var wd=class{constructor(e){this.fetchers=e}supports(e,r){return!!this.tryFetcher(e,r)}getLocalPath(e,r){return this.getFetcher(e,r).getLocalPath(e,r)}async fetch(e,r){return await this.getFetcher(e,r).fetch(e,r)}tryFetcher(e,r){let i=this.fetchers.find(n=>n.supports(e,r));return i||null}getFetcher(e,r){let i=this.fetchers.find(n=>n.supports(e,r));if(!i)throw new ct($.FETCHER_NOT_FOUND,`${Bt(r.project.configuration,e)} isn't supported by any available fetcher`);return i}};var Bd=class{constructor(e){this.resolvers=e.filter(r=>r)}supportsDescriptor(e,r){return!!this.tryResolverByDescriptor(e,r)}supportsLocator(e,r){return!!this.tryResolverByLocator(e,r)}shouldPersistResolution(e,r){return this.getResolverByLocator(e,r).shouldPersistResolution(e,r)}bindDescriptor(e,r,i){return this.getResolverByDescriptor(e,i).bindDescriptor(e,r,i)}getResolutionDependencies(e,r){return this.getResolverByDescriptor(e,r).getResolutionDependencies(e,r)}async getCandidates(e,r,i){return await this.getResolverByDescriptor(e,i).getCandidates(e,r,i)}async getSatisfying(e,r,i){return this.getResolverByDescriptor(e,i).getSatisfying(e,r,i)}async resolve(e,r){return await this.getResolverByLocator(e,r).resolve(e,r)}tryResolverByDescriptor(e,r){let i=this.resolvers.find(n=>n.supportsDescriptor(e,r));return i||null}getResolverByDescriptor(e,r){let i=this.resolvers.find(n=>n.supportsDescriptor(e,r));if(!i)throw new Error(`${sr(r.project.configuration,e)} isn't supported by any available resolver`);return i}tryResolverByLocator(e,r){let i=this.resolvers.find(n=>n.supportsLocator(e,r));return i||null}getResolverByLocator(e,r){let i=this.resolvers.find(n=>n.supportsLocator(e,r));if(!i)throw new Error(`${Bt(r.project.configuration,e)} isn't supported by any available resolver`);return i}};var t4=ge(ri());var qg=/^(?!v)[a-z0-9._-]+$/i,dx=class{supportsDescriptor(e,r){return!!(ho(e.range)||qg.test(e.range))}supportsLocator(e,r){return!!(t4.default.valid(e.reference)||qg.test(e.reference))}shouldPersistResolution(e,r){return r.resolver.shouldPersistResolution(this.forwardLocator(e,r),r)}bindDescriptor(e,r,i){return i.resolver.bindDescriptor(this.forwardDescriptor(e,i),r,i)}getResolutionDependencies(e,r){return r.resolver.getResolutionDependencies(this.forwardDescriptor(e,r),r)}async getCandidates(e,r,i){return await i.resolver.getCandidates(this.forwardDescriptor(e,i),r,i)}async getSatisfying(e,r,i){return await i.resolver.getSatisfying(this.forwardDescriptor(e,i),r,i)}async resolve(e,r){let i=await r.resolver.resolve(this.forwardLocator(e,r),r);return cd(i,e)}forwardDescriptor(e,r){return rr(e,`${r.project.configuration.get("defaultProtocol")}${e.range}`)}forwardLocator(e,r){return cn(e,`${r.project.configuration.get("defaultProtocol")}${e.reference}`)}};var bd=class{supports(e){return!!e.reference.startsWith("virtual:")}getLocalPath(e,r){let i=e.reference.indexOf("#");if(i===-1)throw new Error("Invalid virtual package reference");let n=e.reference.slice(i+1),s=cn(e,n);return r.fetcher.getLocalPath(s,r)}async fetch(e,r){let i=e.reference.indexOf("#");if(i===-1)throw new Error("Invalid virtual package reference");let n=e.reference.slice(i+1),s=cn(e,n),o=await r.fetcher.fetch(s,r);return await this.ensureVirtualLink(e,o,r)}getLocatorFilename(e){return jg(e)}async ensureVirtualLink(e,r,i){let n=r.packageFs.getRealPath(),s=i.project.configuration.get("virtualFolder"),o=this.getLocatorFilename(e),a=Wr.makeVirtualPath(s,o,n),l=new Da(a,{baseFs:r.packageFs,pathUtils:x});return ie(N({},r),{packageFs:l})}};var Jg=class{static isVirtualDescriptor(e){return!!e.range.startsWith(Jg.protocol)}static isVirtualLocator(e){return!!e.reference.startsWith(Jg.protocol)}supportsDescriptor(e,r){return Jg.isVirtualDescriptor(e)}supportsLocator(e,r){return Jg.isVirtualLocator(e)}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,i){throw new Error('Assertion failed: calling "bindDescriptor" on a virtual descriptor is unsupported')}getResolutionDependencies(e,r){throw new Error('Assertion failed: calling "getResolutionDependencies" on a virtual descriptor is unsupported')}async getCandidates(e,r,i){throw new Error('Assertion failed: calling "getCandidates" on a virtual descriptor is unsupported')}async getSatisfying(e,r,i){throw new Error('Assertion failed: calling "getSatisfying" on a virtual descriptor is unsupported')}async resolve(e,r){throw new Error('Assertion failed: calling "resolve" on a virtual locator is unsupported')}},Ew=Jg;Ew.protocol="virtual:";var Qd=class{supports(e){return!!e.reference.startsWith(oi.protocol)}getLocalPath(e,r){return this.getWorkspace(e,r).cwd}async fetch(e,r){let i=this.getWorkspace(e,r).cwd;return{packageFs:new _t(i),prefixPath:Ke.dot,localPath:i}}getWorkspace(e,r){returnLine truncated
`);return{stdout:s,stderr:o}}makeResolver(){let e=[];for(let r of this.plugins.values())for(let i of r.resolvers||[])e.push(new i);return new Bd([new Ew,new oi,new dx,...e])}makeFetcher(){let e=[];for(let r of this.plugins.values())for(let i of r.fetchers||[])e.push(new i);return new wd([new bd,new Qd,...e])}getLinkers(){let e=[];for(let r of this.plugins.values())for(let i of r.linkers||[])e.push(new i);return e}getSupportedArchitectures(){let e=Sd(),r=this.get("supportedArchitectures"),i=r.get("os");i!==null&&(i=i.map(o=>o==="current"?e.os:o));let n=r.get("cpu");n!==null&&(n=n.map(o=>o==="current"?e.cpu:o));let s=r.get("libc");return s!==null&&(s=qo(s,o=>{var a;return o==="current"?(a=e.libc)!=null?a:qo.skip:o})),{os:i,cpu:n,libc:s}}async refreshPackageExtensions(){this.packageExtensions=new Map;let e=this.packageExtensions,r=(i,n,{userProvided:s=!1}={})=>{if(!ho(i.range))throw new Error("Only semver ranges are allowed as keys for the packageExtensions setting");let o=new At;o.load(n,{yamlCompatibilityMode:!0});let a=Pg(e,i.identHash),l=[];a.push([i.range,l]);let c={status:qi.Inactive,userProvided:s,parentDescriptor:i};for(let u of o.dependencies.values())l.push(ie(N({},c),{type:yi.Dependency,descriptor:u}));for(let u of o.peerDependencies.values())l.push(ie(N({},c),{type:yi.PeerDependency,descriptor:u}));for(let[u,g]of o.peerDependenciesMeta)for(let[f,h]of Object.entries(g))l.push(ie(N({},c),{type:yi.PeerDependencyMeta,selector:u,key:f,value:h}))};await this.triggerHook(i=>i.registerPackageExtensions,this,r);for(let[i,n]of this.get("packageExtensions"))r(sl(i,!0),Fy(n),{userProvided:!0})}normalizePackage(e){let r=ud(e);if(this.packageExtensions==null)throw new Error("refreshPackageExtensions has to be called before normalizing packages");let i=this.packageExtensions.get(e.identHash);if(typeof i!="undefined"){let s=e.version;if(s!==null){for(let[o,a]of i)if(!!Uc(s,o))for(let l of a)switch(l.status===qi.Inactive&&(l.status=qi.Redundant),l.type){case yi.Dependency:typeof r.dependencies.get(l.descriptor.identHash)=="undefined"&&(l.status=qi.Active,r.dependencies.set(l.descriptor.identHash,l.descriptor));break;case yi.PeerDependency:typeof r.peerDependencies.get(l.descriptor.identHash)=="undefined"&&(l.status=qi.Active,r.peerDependencies.set(l.descriptor.identHash,l.descriptor));break;case yi.PeerDependencyMeta:{let c=r.peerDependenciesMeta.get(l.selector);(typeof c=="undefined"||!Object.prototype.hasOwnProperty.call(c,l.key)||c[l.key]!==l.value)&&(l.status=qi.Active,Ja(r.peerDependenciesMeta,l.selector,()=>({}))[l.key]=l.value)}break;default:GS(l);break}}}let n=s=>s.scope?`${s.scope}__${s.name}`:`${s.name}`;for(let s of r.peerDependenciesMeta.keys()){let o=An(s);r.peerDependencies.has(o.identHash)||r.peerDependencies.set(o.identHash,rr(o,"*"))}for(let s of r.peerDependencies.values()){if(s.scope==="types")continue;let o=n(s),a=Vo("types",o),l=Ot(a);r.peerDependencies.has(a.identHash)||r.peerDependenciesMeta.has(l)||(r.peerDependencies.set(a.identHash,rr(a,"*")),r.peerDependenciesMeta.set(l,{optional:!0}))}return r.dependencies=new Map(xn(r.dependencies,([,s])=>Pn(s))),r.peerDependencies=new Map(xn(r.peerDependencies,([,s])=>Pn(s))),r}getLimit(e){return Ja(this.limits,e,()=>(0,n4.default)(this.get(e)))}async triggerHook(e,...r){for(let i of this.plugins.values()){let n=i.hooks;if(!n)continue;let s=e(n);!s||await s(...r)}}async triggerMultipleHooks(e,r){for(let i of r)await this.triggerHook(e,...i)}async reduceHook(e,r,...i){let n=r;for(let s of this.plugins.values()){let o=s.hooks;if(!o)continue;let a=e(o);!a||(n=await a(n,...i))}return n}async firstHook(e,...r){for(let i of this.plugins.values()){let n=i.hooks;if(!n)continue;let s=e(n);if(!s)continue;let o=await s(...r);if(typeof o!="undefined")return o}return null}},we=Za;we.telemetry=null;var ns;(function(i){i[i.Never=0]="Never",i[i.ErrorCode=1]="ErrorCode",i[i.Always=2]="Always"})(ns||(ns={}));var vw=class extends ct{constructor({fileName:e,code:r,signal:i}){let n=we.create(x.cwd()),s=et(n,e,Ye.PATH);super($.EXCEPTION,`Child ${s} reported an error`,o=>{Cke(r,i,{configuration:n,report:o})});this.code=Dx(r,i)}},Rx=class extends vw{constructor({fileName:e,code:r,signal:i,stdout:n,stderr:s}){super({fileName:e,code:r,signal:i});this.stdout=n,this.stderr=s}};function jc(t){return t!==null&&typeof t.fd=="number"}var Yc=new Set;function Fx(){}function Nx(){for(let t of Yc)t.kill()}async function $o(t,e,{cwd:r,env:i=process.env,strict:n=!1,stdin:s=null,stdout:o,stderr:a,end:l=2}){let c=["pipe","pipe","pipe"];s===null?c[0]="ignore":jc(s)&&(c[0]=s),jc(o)&&(c[1]=o),jc(a)&&(c[2]=a);let u=(0,Px.default)(t,e,{cwd:H.fromPortablePath(r),env:ie(N({},i),{PWD:H.fromPortablePath(r)}),stdio:c});Yc.add(u),Yc.size===1&&(process.on("SIGINT",Fx),process.on("SIGTERM",Nx)),!jc(s)&&s!==null&&s.pipe(u.stdin),jc(o)||u.stdout.pipe(o,{end:!1}),jc(a)||u.stderr.pipe(a,{end:!1});let g=()=>{for(let f of new Set([o,a]))jc(f)||f.end()};return new Promise((f,h)=>{u.on("error",p=>{Yc.delete(u), Line truncated
`),c(127);break;case"EACCES":n[2].write(`permission denied: ${t}
`),c(128);break;default:n[2].write(`uncaught error: ${u.message}
`),c(1);break}}),l.on("exit",u=>{Jc.delete(l),Jc.size===0&&(process.off("SIGINT",nD),process.off("SIGTERM",sD)),c(u!==null?u:129)})})}}}function o_(t){return e=>{let r=e[0]==="pipe"?new ta.PassThrough:e[0];return{stdin:r,promise:Promise.resolve().then(()=>t({stdin:r,stdout:e[1],stderr:e[2]}))}}}var Co=class{constructor(e){this.stream=e}close(){}get(){return this.stream}},a_=class{constructor(){this.stream=null}close(){if(this.stream===null)throw new Error("Assertion failed: No stream attached");this.stream.end()}attach(e){this.stream=e}get(){if(this.stream===null)throw new Error("Assertion failed: No stream attached");return this.stream}},Ud=class{constructor(e,r){this.stdin=null;this.stdout=null;this.stderr=null;this.pipe=null;this.ancestor=e,this.implementation=r}static start(e,{stdin:r,stdout:i,stderr:n}){let s=new Ud(null,e);return s.stdin=r,s.stdout=i,s.stderr=n,s}pipeTo(e,r=1){let i=new Ud(this,e),n=new a_;return i.pipe=n,i.stdout=this.stdout,i.stderr=this.stderr,(r&1)==1?this.stdout=n:this.ancestor!==null&&(this.stderr=this.ancestor.stdout),(r&2)==2?this.stderr=n:this.ancestor!==null&&(this.stderr=this.ancestor.stderr),i}async exec(){let e=["ignore","ignore","ignore"];if(this.pipe)e[0]="pipe";else{if(this.stdin===null)throw new Error("Assertion failed: No input stream registered");e[0]=this.stdin.get()}let r;if(this.stdout===null)throw new Error("Assertion failed: No output stream registered");r=this.stdout,e[1]=r.get();let i;if(this.stderr===null)throw new Error("Assertion failed: No error stream registered");i=this.stderr,e[2]=i.get();let n=this.implementation(e);return this.pipe&&this.pipe.attach(n.stdin),await n.promise.then(s=>(r.close(),i.close(),s))}async run(){let e=[];for(let i=this;i;i=i.ancestor)e.push(i.exec());return(await Promise.all(e))[0]}};function Xw(t,e){return Ud.start(t,e)}function A_(t,e=null){let r=new ta.PassThrough,i=new n_.StringDecoder,n="";return r.on("data",s=>{let o=i.write(s),a;do if(a=o.indexOf(`
`),a!==-1){let l=n+o.substring(0,a);o=o.substring(a+1),n="",t(e!==null?`${e} ${l}`:l)}while(a!==-1);n+=o}),r.on("end",()=>{let s=i.end();s!==""&&t(e!==null?`${e} ${s}`:s)}),r}function l_(t,{prefix:e}){return{stdout:A_(r=>t.stdout.write(`${r}
`),t.stdout.isTTY?e:null),stderr:A_(r=>t.stderr.write(`${r}
`),t.stderr.isTTY?e:null)}}var NDe=(0,g_.promisify)(setTimeout);var zi;(function(r){r[r.Readable=1]="Readable",r[r.Writable=2]="Writable"})(zi||(zi={}));function f_(t,e,r){let i=new ss.PassThrough({autoDestroy:!0});switch(t){case Fn.STDIN:(e&1)==1&&r.stdin.pipe(i,{end:!1}),(e&2)==2&&r.stdin instanceof ss.Writable&&i.pipe(r.stdin,{end:!1});break;case Fn.STDOUT:(e&1)==1&&r.stdout.pipe(i,{end:!1}),(e&2)==2&&i.pipe(r.stdout,{end:!1});break;case Fn.STDERR:(e&1)==1&&r.stderr.pipe(i,{end:!1}),(e&2)==2&&i.pipe(r.stderr,{end:!1});break;default:throw new Os(`Bad file descriptor: "${t}"`)}return i}function Zw(t,e={}){let r=N(N({},t),e);return r.environment=N(N({},t.environment),e.environment),r.variables=N(N({},t.variables),e.variables),r}var LDe=new Map([["cd",async([t=(0,u_.homedir)(),...e],r,i)=>{let n=x.resolve(i.cwd,H.toPortablePath(t));if(!(await r.baseFs.statPromise(n).catch(o=>{throw o.code==="ENOENT"?new Os(`cd: no such file or directory: ${t}`):o})).isDirectory())throw new Os(`cd: not a directory: ${t}`);return i.cwd=n,0}],["pwd",async(t,e,r)=>(r.stdout.write(`${H.fromPortablePath(r.cwd)}
`),0)],[":",async(t,e,r)=>0],["true",async(t,e,r)=>0],["false",async(t,e,r)=>1],["exit",async([t,...e],r,i)=>i.exitCode=parseInt(t!=null?t:i.variables["?"],10)],["echo",async(t,e,r)=>(r.stdout.write(`${t.join(" ")}
`),0)],["sleep",async([t],e,r)=>{if(typeof t=="undefined")throw new Os("sleep: missing operand");let i=Number(t);if(Number.isNaN(i))throw new Os(`sleep: invalid time interval '${t}'`);return await NDe(1e3*i,0)}],["__ysh_run_procedure",async(t,e,r)=>{let i=r.procedures[t[0]];return await Xw(i,{stdin:new Co(r.stdin),stdout:new Co(r.stdout),stderr:new Co(r.stderr)}).run()}],["__ysh_set_redirects",async(t,e,r)=>{let i=r.stdin,n=r.stdout,s=r.stderr,o=[],a=[],l=[],c=0;for(;t[c]!=="--";){let g=t[c++],{type:f,fd:h}=JSON.parse(g),p=S=>{switch(h){case null:case 0:o.push(S);break;default:throw new Error(`Unsupported file descriptor: "${h}"`)}},m=S=>{switch(h){case null:case 1:a.push(S);break;case 2:l.push(S);break;default:throw new Error(`Unsupported file descriptor: "${h}"`)}},y=Number(t[c++]),b=c+y;for(let S=c;S<b;++c,++S)switch(f){case"<":p(()=>e.baseFs.createReadStream(x.resolve(r.cwd,H.toPortablePath(t[S]))));break;case"<<<":p(()=>{let k=new ss.PassThrough;return process.nextTick(()=>{k.write(`${t[S]}
`),k.end()}),k});break;case"<&":p(()=>f_(Number(t[S]),1,r));break;case">":case">>":{let k=x.resolve(r.cwd,H.toPortablePath(t[S]));m(k==="/dev/null"?new ss.Writable({autoDestroy:!0,emitClose:!0,write(T,Y,j){setImmediate(j)}}):e.baseFs.createWriteStream(k,f===">>"?{flags:"a"}:void 0))}break;case">&":m(f_(Number(t[S]),2,r));break;default:throw new Error(`Assertion failed: Unsupported redirection type: "${f}"`)}}if(o.length>0){let g=new ss.PassThrough;i=g;let f=h=>{if(h===o.length)g.end();else{let p=o[h]();p.pipe(g,{end:!1}),p.on("end",()=>{f(h+1)})}};f(0)}if(a.length>0){let g=new ss.PassThrough;n=g;for(let f of a)g.pipe(f)}if(l.length>0){let g=new ss.PassThrough;s=g;for(let f of l)g.pipe(f)}let u=await Xw(Gd(t.slice(c+1),e,r),{stdin:new Co(i),stdout:new Co(n),stderr:new Co(s)}).run();return await Promise.all(a.map(g=>new Promise((f,h)=>{g.on("error",p=>{h(p)}),g.on("close",()=>{f()}),g.end()}))),await Promise.all(l.map(g=>new Promise((f,h)=>{g.on("error",p=>{h(p)}),g.on("close",()=>{f()}),g.end()}))),u}]]);async function TDe(t,e,r){let i=[],n=new ss.PassThrough;return n.on("data",s=>i.push(s)),await $w(t,e,Zw(r,{stdout:n})),Buffer.concat(i).toString().replace(/[\r\n]+$/,"")}async function h_(t,e,r){let i=t.map(async s=>{let o=await nA(s.args,e,r);return{name:s.name,value:o.join(" ")}});return(await Promise.all(i)).reduce((s,o)=>(s[o.name]=o.value,s),{})}function eB(t){return t.match(/[^ \r\n\t]+/g)||[]}async function p_(t,e,r,i,n=i){switch(t.name){case"$":i(String(process.pid));break;case"#":i(String(e.args.length));break;case"@":if(t.quoted)for(let s of e.args)n(s);else for(let s of e.args){let o=eB(s);for(let a=0;a<o.length-1;++a)n(o[a]);i(o[o.length-1])}break;case"*":{let s=e.args.join(" ");if(t.quoted)i(s);else for(let o of eB(s))n(o)}break;case"PPID":i(String(process.ppid));break;case"RANDOM":i(String(Math.floor(Math.random()*32768)));break;default:{let s=parseInt(t.name,10),o;if(Number.isFinite(s))if(s>=0&&s<e.args.length)o=e.args[s];else if(t.defaultValue)o=(await nA(t.defaultValue,e,r)).join(" ");else if(t.alternativeValue)o=(await nA(t.alternativeValue,e,r)).join(" ");else throw new Os(`Unbound argument #${s}`);else if(Object.prototype.hasOwnProperty.call(r.variables,t.name))o=r.variables[t.name];else if(Object.prototype.hasOwnProperty.call(r.environment,t.name))o=r.environment[t.name];else if(t.defaultValue)o=(await nA(t.defaultValue,e,r)).join(" ");else throw new Os(`Unbound variable "${t.name}"`);if(typeof o!="undefined"&&t.alternativeValue&&(o=(await nA(t.alternativeValue,e,r)).join(" ")),t.quoted)i(o);else{let a=eB(o);for(let c=0;c<a.length-1;++c)n(a[c]);let l=a[a.length-1];typeof l!="undefined"&&i(l)}}break}}var ODe={addition:(t,e)=>t+e,subtraction:(t,e)=>t-e,multiplication:(t,e)=>t*e,division:(t,e)=>Math.trunc(t/e)};async function jd(t,e,r){if(t.type==="number"){if(Number.isInteger(t.value))return t.value;throw new Error(`Invalid number: "${t.value}", only integers are allowed`)}else if(t.type==="variable"){let i=[];await p_(ie(N({},t),{quoted:!0}),e,r,s=>i.push(s));let n=Number(i.join(" "));return Number.isNaN(n)?jd({type:"variable",name:i.join(" ")},e,r):jd({type:"number",value:n},e,r)}else return ODe[t.type](await jd(t.left,e,r),await jd(t.right,e,r))}async function nA(t,e,r){let i=new Map,n=[],s=[],o=u=>{s.push(u)},a=()=>{s.length>0&&n.push(s.join("")),s=[]},l=u=>{o(u),a()},c=(u,g,f)=>{let h=JSON.stringify({type:u,fd:g}),p=i.get(h);typeof p=="undefined"&&i.set(h,p=[]),p.push(f)};for(let u of t){let g=!1;switch(u.type){case"redirection":{let f=await nA(u.args,e,r);for(let h of f)c(u.subtype,u.fd,h)}break;case"argument":for(let f of u.segments)switch(f.type){case"text":o(f.text);break;case"glob":o(f.pattern),g=!0;break;case"shell":{let h=await TDe(f.shell,e,r);if(f.quoted)o(h);else{let p=eB(h);for(let m=0;m<p.length-1;++m)l(p[m]);o(p[p.length-1])}}break;case"variable":await p_(f,e,r,o,l);break;case"arithmetic":o(String(await jd(f.arithmetic,e,r)));break}break}if(a(),g){let f=n.pop();if(typeof f=="undefined")throw new Error("Assertion failed: Expected a glob pattern to have been set");let h=await e.glob.match(f,{cwd:r.cwd,baseFs:e.baseFs});if(h.length===0){let p=r_(f)?". Note: Brace expansion of arbitrary strings isn't currently supported. For more details, please read this issue: https://github.com/yarnpkg/berry/issues/22":"";throw new Os(`No matches found: "${f}"${p}`)}for(let p of h.sort())l(p)}}if(i.size>0){let u=[];for(let[g,f]of i.entries())u.splice(u.length,0,g,String(f.length),...f);n.splice(0,0,"__ysh_set_redirects",...u,"--")}return n}function Gd(t,e,r){e.builtins.has(t[0])||(t=["command",...t]);let i=H.fromPortablePath(r.cwd),n=r.environment;typeof n.PWD!="undefined"&&(n=ie(N({},n),{PWD:i}));let[s,...o]=t;if(s==="command")return s_(o[0],o.slice(1),e,{cwd:i,env:n});let a=e.builtins.get(s);if(typeof a=="undefined")throw new Error(`Assertion failed: A builtin should exist for "${s}"`);return o_(async({stdin:l,stdout:c,stderr:u})=>{let{stdin:g,stdout:f,stderr:h}=r;r.stdin=l,r.stdout=c, Line truncated
`)).finally(()=>{r.stdout.isTTY&&r.stdout.write(`Job ${l}, '${o(Xu(t))}' has ended
`)})),0}return await C_(t,e,r)}async function HDe(t,e,r,{background:i=!1}={}){let n,s=a=>{n=a,r.variables["?"]=String(a)},o=async a=>{try{return await UDe(a.chain,e,r,{background:i&&typeof a.then=="undefined"})}catch(l){if(!(l instanceof Os))throw l;return r.stderr.write(`${l.message}
`),1}};for(s(await o(t));t.then;){if(r.exitCode!==null)return r.exitCode;switch(t.then.type){case"&&":n===0&&s(await o(t.then.line));break;case"||":n!==0&&s(await o(t.then.line));break;default:throw new Error(`Assertion failed: Unsupported command type: "${t.then.type}"`)}t=t.then.line}return n}async function $w(t,e,r){let i=r.backgroundJobs;r.backgroundJobs=[];let n=0;for(let{command:s,type:o}of t){if(n=await HDe(s,e,r,{background:o==="&"}),r.exitCode!==null)return r.exitCode;r.variables["?"]=String(n)}return await Promise.all(r.backgroundJobs),r.backgroundJobs=i,n}function m_(t){switch(t.type){case"variable":return t.name==="@"||t.name==="#"||t.name==="*"||Number.isFinite(parseInt(t.name,10))||"defaultValue"in t&&!!t.defaultValue&&t.defaultValue.some(e=>Yd(e))||"alternativeValue"in t&&!!t.alternativeValue&&t.alternativeValue.some(e=>Yd(e));case"arithmetic":return oD(t.arithmetic);case"shell":return aD(t.shell);default:return!1}}function Yd(t){switch(t.type){case"redirection":return t.args.some(e=>Yd(e));case"argument":return t.segments.some(e=>m_(e));default:throw new Error(`Assertion failed: Unsupported argument type: "${t.type}"`)}}function oD(t){switch(t.type){case"variable":return m_(t);case"number":return!1;default:return oD(t.left)||oD(t.right)}}function aD(t){return t.some(({command:e})=>{for(;e;){let r=e.chain;for(;r;){let i;switch(r.type){case"subshell":i=aD(r.subshell);break;case"command":i=r.envs.some(n=>n.args.some(s=>Yd(s)))||r.args.some(n=>Yd(n));break}if(i)return!0;if(!r.then)break;r=r.then.chain}if(!e.then)break;e=e.then.line}return!1})}async function tB(t,e=[],{baseFs:r=new ar,builtins:i={},cwd:n=H.toPortablePath(process.cwd()),env:s=process.env,stdin:o=process.stdin,stdout:a=process.stdout,stderr:l=process.stderr,variables:c={},glob:u=zw}={}){let g={};for(let[p,m]of Object.entries(s))typeof m!="undefined"&&(g[p]=m);let f=new Map(LDe);for(let[p,m]of Object.entries(i))f.set(p,m);o===null&&(o=new ss.PassThrough,o.end());let h=$E(t,u);if(!aD(h)&&h.length>0&&e.length>0){let{command:p}=h[h.length-1];for(;p.then;)p=p.then.line;let m=p.chain;for(;m.then;)m=m.then.chain;m.type==="command"&&(m.args=m.args.concat(e.map(y=>({type:"argument",segments:[{type:"text",text:y}]}))))}return await $w(h,{args:e,baseFs:r,builtins:f,initialStdin:o,initialStdout:a,initialStderr:l,glob:u},{cwd:n,environment:g,exitCode:null,procedures:{},stdin:o,stdout:a,stderr:l,variables:Object.assign({},c,{["?"]:0}),nextBackgroundJobIndex:1,backgroundJobs:[]})}var n6=ge(rB()),s6=ge(lg()),Wc=ge(require("stream"));var $_=ge(Z_()),sB=ge(pc());var e6=["\u280B","\u2819","\u2839","\u2838","\u283C","\u2834","\u2826","\u2827","\u2807","\u280F"],t6=80,KRe=new Set([$.FETCH_NOT_CACHED,$.UNUSED_CACHE_ENTRY]),URe=5,oB=sB.default.GITHUB_ACTIONS?{start:t=>`::group::${t}
`,end:t=>`::endgroup::
`}:sB.default.TRAVIS?{start:t=>`travis_fold:start:${t}
`,end:t=>`travis_fold:end:${t}
`}:sB.default.GITLAB?{start:t=>`section_start:${Math.floor(Date.now()/1e3)}:${t.toLowerCase().replace(/\W+/g,"_")}[collapsed=true]\r${t}
`,end:t=>`section_end:${Math.floor(Date.now()/1e3)}:${t.toLowerCase().replace(/\W+/g,"_")}\r`}:null,r6=new Date,HRe=["iTerm.app","Apple_Terminal"].includes(process.env.TERM_PROGRAM)||!!process.env.WT_SESSION,GRe=t=>t,aB=GRe({patrick:{date:[17,3],chars:["\u{1F340}","\u{1F331}"],size:40},simba:{date:[19,7],chars:["\u{1F981}","\u{1F334}"],size:40},jack:{date:[31,10],chars:["\u{1F383}","\u{1F987}"],size:40},hogsfather:{date:[31,12],chars:["\u{1F389}","\u{1F384}"],size:40},default:{chars:["=","-"],size:80}}),jRe=HRe&&Object.keys(aB).find(t=>{let e=aB[t];return!(e.date&&(e.date[0]!==r6.getDate()||e.date[1]!==r6.getMonth()+1))})||"default";function i6(t,{configuration:e,json:r}){if(!e.get("enableMessageNames"))return"";let n=qA(t===null?0:t);return!r&&t===null?et(e,n,"grey"):n}function gD(t,{configuration:e,json:r}){let i=i6(t,{configuration:e,json:r});if(!i||t===null||t===$.UNNAMED)return i;let n=$[t],s=`https://yarnpkg.com/advanced/error-codes#${i}---${n}`.toLowerCase();return Lg(e,i,s)}var Je=class extends Ji{constructor({configuration:e,stdout:r,json:i=!1,includeFooter:n=!0,includeLogs:s=!i,includeInfos:o=s,includeWarnings:a=s,forgettableBufferSize:l=URe,forgettableNames:c=new Set}){super();this.uncommitted=new Set;this.cacheHitCount=0;this.cacheMissCount=0;this.lastCacheMiss=null;this.warningCount=0;this.errorCount=0;this.startTime=Date.now();this.indent=0;this.progress=new Map;this.progressTime=0;this.progressFrame=0;this.progressTimeout=null;this.progressStyle=null;this.progressMaxScaledSize=null;this.forgettableLines=[];if(sd(this,{configuration:e}),this.configuration=e,this.forgettableBufferSize=l,this.forgettableNames=new Set([...c,...KRe]),this.includeFooter=n,this.includeInfos=o,this.includeWarnings=a,this.json=i,this.stdout=r,e.get("enableProgressBars")&&!i&&r.isTTY&&r.columns>22){let u=e.get("progressBarStyle")||jRe;if(!Object.prototype.hasOwnProperty.call(aB,u))throw new Error("Assertion failed: Invalid progress bar style");this.progressStyle=aB[u];let g="\u27A4 YN0000: \u250C ".length,f=Math.max(0,Math.min(r.columns-g,80));this.progressMaxScaledSize=Math.floor(this.progressStyle.size*f/80)}}static async start(e,r){let i=new this(e),n=process.emitWarning;process.emitWarning=(s,o)=>{if(typeof s!="string"){let l=s;s=l.message,o=o!=null?o:l.name}let a=typeof o!="undefined"?`${o}: ${s}`:s;i.reportWarning($.UNNAMED,a)};try{await r(i)}catch(s){i.reportExceptionOnce(s)}finally{await i.finalize(),process.emitWarning=n}return i}hasErrors(){return this.errorCount>0}exitCode(){return this.hasErrors()?1:0}reportCacheHit(e){this.cacheHitCount+=1}reportCacheMiss(e,r){this.lastCacheMiss=e,this.cacheMissCount+=1,typeof r!="undefined"&&!this.configuration.get("preferAggregateCacheInfo")&&this.reportInfo($.FETCH_NOT_CACHED,r)}startSectionSync({reportHeader:e,reportFooter:r,skipIfEmpty:i},n){let s={committed:!1,action:()=>{e==null||e()}};i?this.uncommitted.add(s):(s.action(),s.committed=!0);let o=Date.now();try{return n()}catch(a){throw this.reportExceptionOnce(a),a}finally{let a=Date.now();this.uncommitted.delete(s),s.committed&&(r==null||r(a-o))}}async startSectionPromise({reportHeader:e,reportFooter:r,skipIfEmpty:i},n){let s={committed:!1,action:()=>{e==null||e()}};i?this.uncommitted.add(s):(s.action(),s.committed=!0);let o=Date.now();try{return await n()}catch(a){throw this.reportExceptionOnce(a),a}finally{let a=Date.now();this.uncommitted.delete(s),s.committed&&(r==null||r(a-o))}}startTimerImpl(e,r,i){let n=typeof r=="function"?{}:r;return{cb:typeof r=="function"?r:i,reportHeader:()=>{this.reportInfo(null,`\u250C ${e}`),this.indent+=1,oB!==null&&!this.json&&this.includeInfos&&this.stdout.write(oB.start(e))},reportFooter:o=>{this.indent-=1,oB!==null&&!this.json&&this.includeInfos&&this.stdout.write(oB.end(e)),this.configuration.get("enableTimers")&&o>200?this.reportInfo(null,`\u2514 Completed in ${et(this.configuration,o,Ye.DURATION)}`):this.reportInfo(null,"\u2514 Completed")},skipIfEmpty:n.skipIfEmpty}}startTimerSync(e,r,i){let o=this.startTimerImpl(e,r,i),{cb:n}=o,s=Tr(o,["cb"]);return this.startSectionSync(s,n)}async startTimerPromise(e,r,i){let o=this.startTimerImpl(e,r,i),{cb:n}=o,s=Tr(o,["cb"]);return this.startSectionPromise(s,n)}async startCacheReport(e){let r=this.configuration.get("preferAggregateCacheInfo")?{cacheHitCount:this.cacheHitCount,cacheMissCount:this.cacheMissCount}:null;try{return await e()}catch(i){throw this.reportExceptionOnce(i),i}finally{r!==null&&this.reportCacheChanges(r)}}reportSeparator(){this.indent===0?this.writeLineWithForgettableReset(""):this.reportInfo(null,"")}reportInfo(e,r){if(!this.includeInfos)return;this.commit();let i=this.formatNameWithHyperlink(e),n=i?`${i}: `:"",s=`${et(this.configuration,"\u27A4","blueBright")} ${n}${this.formatIndent()}${r}`;if(this.json)this.reportJson({type:"info",name:e,displayName:this.formatName(e),indent:this.formatIndent(),data:r});else if(this.forgettableNames.has(e))if(this.forgettableLines.push(s),this.forgettableLines.length>this.fo Line truncated
`),this.writeProgress()}writeLineWithForgettableReset(e,{truncate:r}={}){this.forgettableLines=[],this.writeLine(e,{truncate:r})}writeLines(e,{truncate:r}={}){this.clearProgress({delta:e.length});for(let i of e)this.stdout.write(`${this.truncate(i,{truncate:r})}
`);this.writeProgress()}reportCacheChanges({cacheHitCount:e,cacheMissCount:r}){let i=this.cacheHitCount-e,n=this.cacheMissCount-r;if(i===0&&n===0)return;let s="";this.cacheHitCount>1?s+=`${this.cacheHitCount} packages were already cached`:this.cacheHitCount===1?s+=" - one package was already cached":s+="No packages were cached",this.cacheHitCount>0?this.cacheMissCount>1?s+=`, ${this.cacheMissCount} had to be fetched`:this.cacheMissCount===1&&(s+=`, one had to be fetched (${Bt(this.configuration,this.lastCacheMiss)})`):this.cacheMissCount>1?s+=` - ${this.cacheMissCount} packages had to be fetched`:this.cacheMissCount===1&&(s+=` - one package had to be fetched (${Bt(this.configuration,this.lastCacheMiss)})`),this.reportInfo($.FETCH_NOT_CACHED,s)}commit(){let e=this.uncommitted;this.uncommitted=new Set;for(let r of e)r.committed=!0,r.action()}clearProgress({delta:e=0,clear:r=!1}){this.progressStyle!==null&&this.progress.size+e>0&&(this.stdout.write(`[${this.progress.size+e}A`),(e>0||r)&&this.stdout.write(""))}writeProgress(){if(this.progressStyle===null||(this.progressTimeout!==null&&clearTimeout(this.progressTimeout),this.progressTimeout=null,this.progress.size===0))return;let e=Date.now();e-this.progressTime>t6&&(this.progressFrame=(this.progressFrame+1)%e6.length,this.progressTime=e);let r=e6[this.progressFrame];for(let i of this.progress.values()){let n="";if(typeof i.lastScaledSize!="undefined"){let l=this.progressStyle.chars[0].repeat(i.lastScaledSize),c=this.progressStyle.chars[1].repeat(this.progressMaxScaledSize-i.lastScaledSize);n=` ${l}${c}`}let s=this.formatName(null),o=s?`${s}: `:"",a=i.definition.title?` ${i.definition.title}`:"";this.stdout.write(`${et(this.configuration,"\u27A4","blueBright")} ${o}${r}${n}${a}
`)}this.progressTimeout=setTimeout(()=>{this.refreshProgress({force:!0})},t6)}refreshProgress({delta:e=0,force:r=!1}={}){let i=!1,n=!1;if(r||this.progress.size===0)i=!0;else for(let s of this.progress.values()){let o=typeof s.definition.progress!="undefined"?Math.trunc(this.progressMaxScaledSize*s.definition.progress):void 0,a=s.lastScaledSize;s.lastScaledSize=o;let l=s.lastTitle;if(s.lastTitle=s.definition.title,o!==a||(n=l!==s.definition.title)){i=!0;break}}i&&(this.clearProgress({delta:e,clear:n}),this.writeProgress())}truncate(e,{truncate:r}={}){return this.progressStyle===null&&(r=!1),typeof r=="undefined"&&(r=this.configuration.get("preferTruncatedLines")),r&&(e=(0,$_.default)(e,0,this.stdout.columns-1)),e}formatName(e){return i6(e,{configuration:this.configuration,json:this.json})}formatNameWithHyperlink(e){return gD(e,{configuration:this.configuration,json:this.json})}formatIndent(){return"\u2502 ".repeat(this.indent)}};var Kr="3.2.1";var hn;(function(n){n.Yarn1="Yarn Classic",n.Yarn2="Yarn",n.Npm="npm",n.Pnpm="pnpm"})(hn||(hn={}));async function sA(t,e,r,i=[]){if(process.platform==="win32"){let n=`@goto #_undefined_# 2>NUL || @title %COMSPEC% & @setlocal & @"${r}" ${i.map(s=>`"${s.replace('"','""')}"`).join(" ")} %*`;await K.writeFilePromise(x.format({dir:t,name:e,ext:".cmd"}),n)}await K.writeFilePromise(x.join(t,e),`#!/bin/sh
exec "${r}" ${i.map(n=>`'${n.replace(/'/g,`'"'"'`)}'`).join(" ")} "$@"
`,{mode:493})}async function o6(t){let e=await At.tryFind(t);if(e==null?void 0:e.packageManager){let i=fw(e.packageManager);if(i==null?void 0:i.name){let n=`found ${JSON.stringify({packageManager:e.packageManager})} in manifest`,[s]=i.reference.split(".");switch(i.name){case"yarn":return{packageManager:Number(s)===1?hn.Yarn1:hn.Yarn2,reason:n};case"npm":return{packageManager:hn.Npm,reason:n};case"pnpm":return{packageManager:hn.Pnpm,reason:n}}}}let r;try{r=await K.readFilePromise(x.join(t,Pt.lockfile),"utf8")}catch{}return r!==void 0?r.match(/^__metadata:$/m)?{packageManager:hn.Yarn2,reason:'"__metadata" key found in yarn.lock'}:{packageManager:hn.Yarn1,reason:'"__metadata" key not found in yarn.lock, must be a Yarn classic lockfile'}:K.existsSync(x.join(t,"package-lock.json"))?{packageManager:hn.Npm,reason:`found npm's "package-lock.json" lockfile`}:K.existsSync(x.join(t,"pnpm-lock.yaml"))?{packageManager:hn.Pnpm,reason:`found pnpm's "pnpm-lock.yaml" lockfile`}:null}async function qd({project:t,locator:e,binFolder:r,lifecycleScript:i}){var l,c;let n={};for(let[u,g]of Object.entries(process.env))typeof g!="undefined"&&(n[u.toLowerCase()!=="path"?u:"PATH"]=g);let s=H.fromPortablePath(r);n.BERRY_BIN_FOLDER=H.fromPortablePath(s);let o=process.env.COREPACK_ROOT?H.join(process.env.COREPACK_ROOT,"dist/yarn.js"):process.argv[1];if(await Promise.all([sA(r,"node",process.execPath),...Kr!==null?[sA(r,"run",process.execPath,[o,"run"]),sA(r,"yarn",process.execPath,[o]),sA(r,"yarnpkg",process.execPath,[o]),sA(r,"node-gyp",process.execPath,[o,"run","--top-level","node-gyp"])]:[]]),t&&(n.INIT_CWD=H.fromPortablePath(t.configuration.startingCwd),n.PROJECT_CWD=H.fromPortablePath(t.cwd)),n.PATH=n.PATH?`${s}${H.delimiter}${n.PATH}`:`${s}`,n.npm_execpath=`${s}${H.sep}yarn`,n.npm_node_execpath=`${s}${H.sep}node`,e){if(!t)throw new Error("Assertion failed: Missing project");let u=t.tryWorkspaceByLocator(e),g=u?(l=u.manifest.version)!=null?l:"":(c=t.storedPackages.get(e.locatorHash).version)!=null?c:"";n.npm_package_name=Ot(e),n.npm_package_version=g}let a=Kr!==null?`yarn/${Kr}`:`yarn/${Ng("@yarnpkg/core").version}-core`;return n.npm_config_user_agent=`${a} npm/? node/${process.version} ${process.platform} ${process.arch}`,i&&(n.npm_lifecycle_event=i),t&&await t.configuration.triggerHook(u=>u.setupScriptEnvironment,t,n,async(u,g,f)=>await sA(r,Jr(u),g,f)),n}var YRe=2,qRe=(0,s6.default)(YRe);async function JRe(t,e,{configuration:r,report:i,workspace:n=null,locator:s=null}){await qRe(async()=>{await K.mktempPromise(async o=>{let a=x.join(o,"pack.log"),l=null,{stdout:c,stderr:u}=r.getSubprocessStreams(a,{prefix:H.fromPortablePath(t),report:i}),g=s&&Xo(s)?fd(s):s,f=g?Ds(g):"an external project";c.write(`Packing ${f} from sources
`);let h=await o6(t),p;h!==null?(c.write(`Using ${h.packageManager} for bootstrap. Reason: ${h.reason}
`),p=h.packageManager):(c.write(`No package manager configuration detected; defaulting to Yarn
`),p=hn.Yarn2),await K.mktempPromise(async m=>{let y=await qd({binFolder:m}),S=new Map([[hn.Yarn1,async()=>{let T=n!==null?["workspace",n]:[],Y=await $o("yarn",["set","version","classic","--only-if-needed"],{cwd:t,env:y,stdin:l,stdout:c,stderr:u,end:ns.ErrorCode});if(Y.code!==0)return Y.code;await K.appendFilePromise(x.join(t,".npmignore"),`/.yarn
`),c.write(`
`),delete y.NODE_ENV;let j=await $o("yarn",["install"],{cwd:t,env:y,stdin:l,stdout:c,stderr:u,end:ns.ErrorCode});if(j.code!==0)return j.code;c.write(`
`);let Z=await $o("yarn",[...T,"pack","--filename",H.fromPortablePath(e)],{cwd:t,env:y,stdin:l,stdout:c,stderr:u});return Z.code!==0?Z.code:0}],[hn.Yarn2,async()=>{let T=n!==null?["workspace",n]:[];y.YARN_ENABLE_INLINE_BUILDS="1";let Y=x.join(t,Pt.lockfile);await K.existsPromise(Y)||await K.writeFilePromise(Y,"");let j=await $o("yarn",[...T,"pack","--install-if-needed","--filename",H.fromPortablePath(e)],{cwd:t,env:y,stdin:l,stdout:c,stderr:u});return j.code!==0?j.code:0}],[hn.Npm,async()=>{if(n!==null){let A=new Wc.PassThrough,oe=Fg(A);A.pipe(c,{end:!1});let le=await $o("npm",["--version"],{cwd:t,env:y,stdin:l,stdout:A,stderr:u,end:ns.Never});if(A.end(),le.code!==0)return c.end(),u.end(),le.code;let X=(await oe).toString().trim();if(!Uc(X,">=7.x")){let O=Vo(null,"npm"),L=rr(O,X),pe=rr(O,">=7.x");throw new Error(`Workspaces aren't supported by ${sr(r,L)}; please upgrade to ${sr(r,pe)} (npm has been detected as the primary package manager for ${et(r,t,Ye.PATH)})`)}}let T=n!==null?["--workspace",n]:[];delete y.npm_config_user_agent,delete y.npm_config_production,delete y.NPM_CONFIG_PRODUCTION,delete y.NODE_ENV;let Y=await $o("npm",["install"],{cwd:t,env:y,stdin:l,stdout:c,stderr:u,end:ns.ErrorCode});if(Y.code!==0)return Y.code;let j=new Wc.PassThrough,Z=Fg(j);j.pipe(c);let J=await $o("npm",["pack","--silent",...T],{cwd:t,env:y,stdin:l,stdout:j,stderr:u});if(J.code!==0)return J.code;let re=(await Z).toString().trim().replace(/^.*\n/s,""),ee=x.resolve(t,H.toPortablePath(re));return await K.renamePromise(ee,e),0}]]).get(p);if(typeof S=="undefined")throw new Error("Assertion failed: Unsupported workflow");let k=await S();if(!(k===0||typeof k=="undefined"))throw K.detachTemp(o),new ct($.PACKAGE_PREPARATION_FAILED,`Packing the package failed (exit code ${k}, logs can be found here: ${et(r,a,Ye.PATH)})`)})})})}async function WRe(t,e,{project:r}){let i=r.tryWorkspaceByLocator(t);if(i!==null)return fD(i,e);let n=r.storedPackages.get(t.locatorHash);if(!n)throw new Error(`Package for ${Bt(r.configuration,t)} not found in the project`);return await Es.openPromise(async s=>{let o=r.configuration,a=r.configuration.getLinkers(),l={project:r,report:new Je({stdout:new Wc.PassThrough,configuration:o})},c=a.find(h=>h.supportsPackage(n,l));if(!c)throw new Error(`The package ${Bt(r.configuration,n)} isn't supported by any of the available linkers`);let u=await c.findPackageLocation(n,l),g=new _t(u,{baseFs:s});return(await At.find(Ke.dot,{baseFs:g})).scripts.has(e)},{libzip:await fn()})}async function AB(t,e,r,{cwd:i,project:n,stdin:s,stdout:o,stderr:a}){return await K.mktempPromise(async l=>{let{manifest:c,env:u,cwd:g}=await a6(t,{project:n,binFolder:l,cwd:i,lifecycleScript:e}),f=c.scripts.get(e);if(typeof f=="undefined")return 1;let h=async()=>await tB(f,r,{cwd:g,env:u,stdin:s,stdout:o,stderr:a});return await(await n.configuration.reduceHook(m=>m.wrapScriptExecution,h,n,t,e,{script:f,args:r,cwd:g,env:u,stdin:s,stdout:o,stderr:a}))()})}async function hD(t,e,r,{cwd:i,project:n,stdin:s,stdout:o,stderr:a}){return await K.mktempPromise(async l=>{let{env:c,cwd:u}=await a6(t,{project:n,binFolder:l,cwd:i});return await tB(e,r,{cwd:u,env:c,stdin:s,stdout:o,stderr:a})})}async function zRe(t,{binFolder:e,cwd:r,lifecycleScript:i}){let n=await qd({project:t.project,locator:t.anchoredLocator,binFolder:e,lifecycleScript:i});return await Promise.all(Array.from(await A6(t),([s,[,o]])=>sA(e,Jr(s),process.execPath,[o]))),typeof r=="undefined"&&(r=x.dirname(await K.realpathPromise(x.join(t.cwd,"package.json")))),{manifest:t.manifest,binFolder:e,env:n,cwd:r}}async function a6(t,{project:e,binFolder:r,cwd:i,lifecycleScript:n}){let s=e.tryWorkspaceByLocator(t);if(s!==null)return zRe(s,{binFolder:r,cwd:i,lifecycleScript:n});let o=e.storedPackages.get(t.locatorHash);if(!o)throw new Error(`Package for ${Bt(e.configuration,t)} not found in the project`);return await Es.openPromise(async a=>{let l=e.configuration,c=e.configuration.getLinkers(),u={project:e,report:new Je({stdout:new Wc.PassThrough,configuration:l})},g=c.find(y=>y.supportsPackage(o,u));if(!g)throw new Error(`The package ${Bt(e.configuration,o)} isn't supported by any of the available linkers`);let f=await qd({project:e,locator:t,binFolder:r,lifecycleScript:n});await Promise.all(Array.from(await lB(t,{project:e}),([y,[,b]])=>sA(r,Jr(y),process.execPath,[b])));let h=await g.findPackageLocation(o,u),p=new _t(h,{baseFs:a}),m=await At.find(Ke.dot,{baseFs:p});return typeof i=="undefined"&&(i=h),{manifest:m,binFolder:r,env:f,cwd:i}},{libzip:await fn()})}async function l6(t,e,r,{cwd:i,stdin:n,stdout:s,stderr:o}){return await AB(t.anchoredLocator,e,r,{cwd:i,project:t.project,stdin:n,stdout:s,stderr:o})}function fD(t,e){return t.manifest.scripts.has(e)}async function c6(t,e,{cwd:r,report:i}){let{configuration:n}=t.project,s=null;await K.mktempPromise(async o=>{let a=x.join(o,`${e}.log`),l=`# This file contains the result of Yarn calling the "${e}" lifecycle script inside a workspace ("${H.fromPortablLine truncated
`,{stdout:c,stderr:u}=n.getSubprocessStreams(a,{report:i,prefix:Bt(n,t.anchoredLocator),header:l});i.reportInfo($.LIFECYCLE_SCRIPT,`Calling the "${e}" lifecycle script`);let g=await l6(t,e,[],{cwd:r,stdin:s,stdout:c,stderr:u});if(c.end(),u.end(),g!==0)throw K.detachTemp(o),new ct($.LIFECYCLE_SCRIPT,`${(0,n6.default)(e)} script failed (exit code ${et(n,g,Ye.NUMBER)}, logs can be found here: ${et(n,a,Ye.PATH)}); run ${et(n,`yarn ${e}`,Ye.CODE)} to investigate`)})}async function _Re(t,e,r){fD(t,e)&&await c6(t,e,r)}async function lB(t,{project:e}){let r=e.configuration,i=new Map,n=e.storedPackages.get(t.locatorHash);if(!n)throw new Error(`Package for ${Bt(r,t)} not found in the project`);let s=new Wc.Writable,o=r.getLinkers(),a={project:e,report:new Je({configuration:r,stdout:s})},l=new Set([t.locatorHash]);for(let u of n.dependencies.values()){let g=e.storedResolutions.get(u.descriptorHash);if(!g)throw new Error(`Assertion failed: The resolution (${sr(r,u)}) should have been registered`);l.add(g)}let c=await Promise.all(Array.from(l,async u=>{let g=e.storedPackages.get(u);if(!g)throw new Error(`Assertion failed: The package (${u}) should have been registered`);if(g.bin.size===0)return qo.skip;let f=o.find(p=>p.supportsPackage(g,a));if(!f)return qo.skip;let h=null;try{h=await f.findPackageLocation(g,a)}catch(p){if(p.code==="LOCATOR_NOT_INSTALLED")return qo.skip;throw p}return{dependency:g,packageLocation:h}}));for(let u of c){if(u===qo.skip)continue;let{dependency:g,packageLocation:f}=u;for(let[h,p]of g.bin)i.set(h,[g,H.fromPortablePath(x.resolve(f,p))])}return i}async function A6(t){return await lB(t.anchoredLocator,{project:t.project})}async function u6(t,e,r,{cwd:i,project:n,stdin:s,stdout:o,stderr:a,nodeArgs:l=[],packageAccessibleBinaries:c}){c!=null||(c=await lB(t,{project:n}));let u=c.get(e);if(!u)throw new Error(`Binary not found (${e}) for ${Bt(n.configuration,t)}`);return await K.mktempPromise(async g=>{let[,f]=u,h=await qd({project:n,locator:t,binFolder:g});await Promise.all(Array.from(c,([m,[,y]])=>sA(h.BERRY_BIN_FOLDER,Jr(m),process.execPath,[y])));let p;try{p=await $o(process.execPath,[...l,f,...r],{cwd:i,env:h,stdin:s,stdout:o,stderr:a})}finally{await K.removePromise(h.BERRY_BIN_FOLDER)}return p.code})}async function VRe(t,e,r,{cwd:i,stdin:n,stdout:s,stderr:o,packageAccessibleBinaries:a}){return await u6(t.anchoredLocator,e,r,{project:t.project,cwd:i,stdin:n,stdout:s,stderr:o,packageAccessibleBinaries:a})}var wi={};ft(wi,{convertToZip:()=>oLe,extractArchiveTo:()=>ALe,makeArchiveFromDirectory:()=>sLe});var i7=ge(require("stream")),n7=ge(X9());var Z9=ge(require("os")),$9=ge(lg()),e7=ge(require("worker_threads")),vl=Symbol("kTaskInfo"),SR=class{constructor(e){this.source=e;this.workers=[];this.limit=(0,$9.default)(Math.max(1,(0,Z9.cpus)().length));this.cleanupInterval=setInterval(()=>{if(this.limit.pendingCount===0&&this.limit.activeCount===0){let r=this.workers.pop();r?r.terminate():clearInterval(this.cleanupInterval)}},5e3).unref()}createWorker(){this.cleanupInterval.refresh();let e=new e7.Worker(this.source,{eval:!0,execArgv:[...process.execArgv,"--unhandled-rejections=strict"]});return e.on("message",r=>{if(!e[vl])throw new Error("Assertion failed: Worker sent a result without having a task assigned");e[vl].resolve(r),e[vl]=null,e.unref(),this.workers.push(e)}),e.on("error",r=>{var i;(i=e[vl])==null||i.reject(r),e[vl]=null}),e.on("exit",r=>{var i;r!==0&&((i=e[vl])==null||i.reject(new Error(`Worker exited with code ${r}`))),e[vl]=null}),e}run(e){return this.limit(()=>{var i;let r=(i=this.workers.pop())!=null?i:this.createWorker();return r.ref(),new Promise((n,s)=>{r[vl]={resolve:n,reject:s},r.postMessage(e)})})}};var s7=ge(r7());async function sLe(t,{baseFs:e=new ar,prefixPath:r=Ke.root,compressionLevel:i,inMemory:n=!1}={}){let s=await fn(),o;if(n)o=new Ai(null,{libzip:s,level:i});else{let l=await K.mktempPromise(),c=x.join(l,"archive.zip");o=new Ai(c,{create:!0,libzip:s,level:i})}let a=x.resolve(Ke.root,r);return await o.copyPromise(a,t,{baseFs:e,stableTime:!0,stableSort:!0}),o}var o7;async function oLe(t,e){let r=await K.mktempPromise(),i=x.join(r,"archive.zip");return o7||(o7=new SR((0,s7.getContent)())),await o7.run({tmpFile:i,tgz:t,opts:e}),new Ai(i,{libzip:await fn(),level:e.compressionLevel})}async function*aLe(t){let e=new n7.default.Parse,r=new i7.PassThrough({objectMode:!0,autoDestroy:!0,emitClose:!0});e.on("entry",i=>{r.write(i)}),e.on("error",i=>{r.destroy(i)}),e.on("close",()=>{r.destroyed||r.end()}),e.end(t);for await(let i of r){let n=i;yield n,n.resume()}}async function ALe(t,e,{stripComponents:r=0,prefixPath:i=Ke.dot}={}){var s,o;function n(a){if(a.path[0]==="/")return!0;let l=a.path.split(/\//g);return!!(l.some(c=>c==="..")||l.length<=r)}for await(let a of aLe(t)){if(n(a))continue;let l=x.normalize(H.toPortablePath(a.path)).replace(/\/$/,"").split(/\//g);if(l.length<=r)continue;let c=l.slice(r).join("/"),u=x.join(i,c),g=420;switch((a.type==="Directory"||(((s=a.mode)!=null?s:0)&7 Line truncated
`);return}let s=(0,l7.asTree)(c7(t,{configuration:e}),!1,!1);if(n>=1&&(s=s.replace(/^([├└]─)/gm,`\u2502
$1`).replace(/^│\n/,"")),n>=2)for(let a=0;a<2;++a)s=s.replace(/^([│ ].{2}[├│ ].{2}[^\n]+\n)(([│ ]).{2}[├└].{2}[^\n]*\n[│ ].{2}[│ ].{2}[├└]─)/gm,`$1$3 \u2502
$2`).replace(/^│\n/,"");if(n>=3)throw new Error("Only the first two levels are accepted by treeUtils.emitTree");r.write(s)}var f7=ge(require("crypto")),PR=ge(require("fs"));var cLe=8,Nt=class{constructor(e,{configuration:r,immutable:i=r.get("enableImmutableCache"),check:n=!1}){this.markedFiles=new Set;this.mutexes=new Map;this.cacheId=`-${(0,f7.randomBytes)(8).toString("hex")}.tmp`;this.configuration=r,this.cwd=e,this.immutable=i,this.check=n;let s=r.get("cacheKeyOverride");if(s!==null)this.cacheKey=`${s}`;else{let o=r.get("compressionLevel"),a=o!==nc?`c${o}`:"";this.cacheKey=[cLe,a].join("")}}static async find(e,{immutable:r,check:i}={}){let n=new Nt(e.get("cacheFolder"),{configuration:e,immutable:r,check:i});return await n.setup(),n}get mirrorCwd(){if(!this.configuration.get("enableMirror"))return null;let e=`${this.configuration.get("globalFolder")}/cache`;return e!==this.cwd?e:null}getVersionFilename(e){return`${jg(e)}-${this.cacheKey}.zip`}getChecksumFilename(e,r){let n=uLe(r).slice(0,10);return`${jg(e)}-${n}.zip`}getLocatorPath(e,r,i={}){var s;return this.mirrorCwd===null||((s=i.unstablePackages)==null?void 0:s.has(e.locatorHash))?x.resolve(this.cwd,this.getVersionFilename(e)):r===null||DR(r)!==this.cacheKey?null:x.resolve(this.cwd,this.getChecksumFilename(e,r))}getLocatorMirrorPath(e){let r=this.mirrorCwd;return r!==null?x.resolve(r,this.getVersionFilename(e)):null}async setup(){if(!this.configuration.get("enableGlobalCache"))if(this.immutable){if(!await K.existsPromise(this.cwd))throw new ct($.IMMUTABLE_CACHE,"Cache path does not exist.")}else{await K.mkdirPromise(this.cwd,{recursive:!0});let e=x.resolve(this.cwd,".gitignore");await K.changeFilePromise(e,`/.gitignore
*.flock
*.tmp
`)}(this.mirrorCwd||!this.immutable)&&await K.mkdirPromise(this.mirrorCwd||this.cwd,{recursive:!0})}async fetchPackageFromCache(e,r,a){var l=a,{onHit:i,onMiss:n,loader:s}=l,o=Tr(l,["onHit","onMiss","loader"]);var A;let c=this.getLocatorMirrorPath(e),u=new ar,g=()=>{let oe=new Ai(null,{libzip:Y}),le=x.join(Ke.root,gx(e));return oe.mkdirSync(le,{recursive:!0}),oe.writeJsonSync(x.join(le,Pt.manifest),{name:Ot(e),mocked:!0}),oe},f=async(oe,le=null)=>{var O;if(le===null&&((O=o.unstablePackages)==null?void 0:O.has(e.locatorHash)))return null;let X=!o.skipIntegrityCheck||!r?`${this.cacheKey}/${await lw(oe)}`:r;if(le!==null){let L=!o.skipIntegrityCheck||!r?`${this.cacheKey}/${await lw(le)}`:r;if(X!==L)throw new ct($.CACHE_CHECKSUM_MISMATCH,"The remote archive doesn't match the local checksum - has the local cache been corrupted?")}if(r!==null&&X!==r){let L;switch(this.check?L="throw":DR(r)!==DR(X)?L="update":L=this.configuration.get("checksumBehavior"),L){case"ignore":return r;case"update":return X;default:case"throw":throw new ct($.CACHE_CHECKSUM_MISMATCH,"The remote archive doesn't match the expected checksum")}}return X},h=async oe=>{if(!s)throw new Error(`Cache check required but no loader configured for ${Bt(this.configuration,e)}`);let le=await s(),X=le.getRealPath();return le.saveAndClose(),await K.chmodPromise(X,420),await f(oe,X)},p=async()=>{if(c===null||!await K.existsPromise(c)){let oe=await s(),le=oe.getRealPath();return oe.saveAndClose(),{source:"loader",path:le}}return{source:"mirror",path:c}},m=async()=>{if(!s)throw new Error(`Cache entry required but missing for ${Bt(this.configuration,e)}`);if(this.immutable)throw new ct($.IMMUTABLE_CACHE,`Cache entry required but missing for ${Bt(this.configuration,e)}`);let{path:oe,source:le}=await p(),X=await f(oe),O=this.getLocatorPath(e,X,o);if(!O)throw new Error("Assertion failed: Expected the cache path to be available");let L=[];le!=="mirror"&&c!==null&&L.push(async()=>{let Ce=`${c}${this.cacheId}`;await K.copyFilePromise(oe,Ce,PR.default.constants.COPYFILE_FICLONE),await K.chmodPromise(Ce,420),await K.renamePromise(Ce,c)}),(!o.mirrorWriteOnly||c===null)&&L.push(async()=>{let Ce=`${O}${this.cacheId}`;await K.copyFilePromise(oe,Ce,PR.default.constants.COPYFILE_FICLONE),await K.chmodPromise(Ce,420),await K.renamePromise(Ce,O)});let pe=o.mirrorWriteOnly&&c!=null?c:O;return await Promise.all(L.map(Ce=>Ce())),[!1,pe,X]},y=async()=>{let le=(async()=>{var Oe;let X=this.getLocatorPath(e,r,o),O=X!==null?await u.existsPromise(X):!1,L=!!((Oe=o.mockedPackages)==null?void 0:Oe.has(e.locatorHash))&&(!this.check||!O),pe=L||O,Ce=pe?i:n;if(Ce&&Ce(),pe){let te=null,se=X;return L||(te=this.check?await h(se):await f(se)),[L,se,te]}else return m()})();this.mutexes.set(e.locatorHash,le);try{return await le}finally{this.mutexes.delete(e.locatorHash)}};for(let oe;oe=this.mutexes.get(e.locatorHash);)await oe;let[b,S,k]=await y();this.markedFiles.add(S);let T,Y=await fn(),j=b?()=>g():()=>new Ai(S,{baseFs:u,libzip:Y,readOnly:!0}),Z=new Vh(()=>YS(()=>T=j(),oe=>`Failed to open the cache entry for ${Bt(this.configuration,e)}: ${oe}`),x),J=new Da(S,{baseFs:Z,pathUtils:x}),re=()=>{T==null||T.discardAndClose()},ee=((A=o.unstablePackages)==null?void 0:A.has(e.locatorHash))?null:k;return[J,re,ee]}};function DR(t){let e=t.indexOf("/");return e!==-1?t.slice(0,e):null}function uLe(t){let e=t.indexOf("/");return e!==-1?t.slice(e+1):t}var ls;(function(r){r[r.SCRIPT=0]="SCRIPT",r[r.SHELLCODE=1]="SHELLCODE"})(ls||(ls={}));var gA=class extends Ji{constructor({configuration:e,stdout:r,suggestInstall:i=!0}){super();this.errorCount=0;sd(this,{configuration:e}),this.configuration=e,this.stdout=r,this.suggestInstall=i}static async start(e,r){let i=new this(e);try{await r(i)}catch(n){i.reportExceptionOnce(n)}finally{await i.finalize()}return i}hasErrors(){return this.errorCount>0}exitCode(){return this.hasErrors()?1:0}reportCacheHit(e){}reportCacheMiss(e){}startSectionSync(e,r){return r()}async startSectionPromise(e,r){return await r()}startTimerSync(e,r,i){return(typeof r=="function"?r:i)()}async startTimerPromise(e,r,i){return await(typeof r=="function"?r:i)()}async startCacheReport(e){return await e()}reportSeparator(){}reportInfo(e,r){}reportWarning(e,r){}reportError(e,r){this.errorCount+=1,this.stdout.write(`${et(this.configuration,"\u27A4","redBright")} ${this.formatNameWithHyperlink(e)}: ${r}
`)}reportProgress(e){let r=Promise.resolve().then(async()=>{for await(let{}of e);}),i=()=>{};return ie(N({},r),{stop:i})}reportJson(e){}async finalize(){this.errorCount>0&&(this.stdout.write(`
`),this.stdout.write(`${et(this.configuration,"\u27A4","redBright")} Errors happened when preparing the environment required to run this command.
`),this.suggestInstall&&this.stdout.write(`${et(this.configuration,"\u27A4","redBright")} This might be caused by packages being missing from the lockfile, in which case running "yarn install" might help.
`))}formatNameWithHyperlink(e){return gD(e,{configuration:this.configuration,json:!1})}};var p0=ge(require("crypto")),n$=ge(V7()),d0=ge(r$()),s$=ge(lg()),o$=ge(ri()),sF=ge(require("util")),oF=ge(require("v8")),aF=ge(require("zlib"));var WKe=[[/^(git(?:\+(?:https|ssh))?:\/\/.*(?:\.git)?)#(.*)$/,(t,e,r,i)=>`${r}#commit=${i}`],[/^https:\/\/((?:[^/]+?)@)?codeload\.github\.com\/([^/]+\/[^/]+)\/tar\.gz\/([0-9a-f]+)$/,(t,e,r="",i,n)=>`https://${r}github.com/${i}.git#commit=${n}`],[/^https:\/\/((?:[^/]+?)@)?github\.com\/([^/]+\/[^/]+?)(?:\.git)?#([0-9a-f]+)$/,(t,e,r="",i,n)=>`https://${r}github.com/${i}.git#commit=${n}`],[/^https?:\/\/[^/]+\/(?:[^/]+\/)*(?:@.+(?:\/|(?:%2f)))?([^/]+)\/(?:-|download)\/\1-[^/]+\.tgz(?:#|$)/,t=>`npm:${t}`],[/^https:\/\/npm\.pkg\.github\.com\/download\/(?:@[^/]+)\/(?:[^/]+)\/(?:[^/]+)\/(?:[0-9a-f]+)(?:#|$)/,t=>`npm:${t}`],[/^https:\/\/npm\.fontawesome\.com\/(?:@[^/]+)\/([^/]+)\/-\/([^/]+)\/\1-\2.tgz(?:#|$)/,t=>`npm:${t}`],[/^https?:\/\/(?:[^\\.]+)\.jfrog\.io\/.*\/(@[^/]+)\/([^/]+)\/-\/\1\/\2-(?:[.\d\w-]+)\.tgz(?:#|$)/,(t,e)=>hw({protocol:"npm:",source:null,selector:t,params:{__archiveUrl:e}})],[/^[^/]+\.tgz#[0-9a-f]+$/,t=>`npm:${t}`]],rF=class{constructor(e){this.resolver=e;this.resolutions=null}async setup(e,{report:r}){let i=x.join(e.cwd,e.configuration.get("lockfileFilename"));if(!K.existsSync(i))return;let n=await K.readFilePromise(i,"utf8"),s=Qi(n);if(Object.prototype.hasOwnProperty.call(s,"__metadata"))return;let o=this.resolutions=new Map;for(let a of Object.keys(s)){let l=dd(a);if(!l){r.reportWarning($.YARN_IMPORT_FAILED,`Failed to parse the string "${a}" into a proper descriptor`);continue}ho(l.range)&&(l=rr(l,`npm:${l.range}`));let{version:c,resolved:u}=s[a];if(!u)continue;let g;for(let[h,p]of WKe){let m=u.match(h);if(m){g=p(c,...m);break}}if(!g){r.reportWarning($.YARN_IMPORT_FAILED,`${sr(e.configuration,l)}: Only some patterns can be imported from legacy lockfiles (not "${u}")`);continue}let f=l;try{let h=Gg(l.range),p=dd(h.selector,!0);p&&(f=p)}catch{}o.set(l.descriptorHash,cn(f,g))}}supportsDescriptor(e,r){return this.resolutions?this.resolutions.has(e.descriptorHash):!1}supportsLocator(e,r){return!1}shouldPersistResolution(e,r){throw new Error("Assertion failed: This resolver doesn't support resolving locators to packages")}bindDescriptor(e,r,i){return e}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){if(!this.resolutions)throw new Error("Assertion failed: The resolution store should have been setup");let n=this.resolutions.get(e.descriptorHash);if(!n)throw new Error("Assertion failed: The resolution should have been registered");return await this.resolver.getCandidates(ax(n),r,i)}async getSatisfying(e,r,i){return null}async resolve(e,r){throw new Error("Assertion failed: This resolver doesn't support resolving locators to packages")}};var iF=class{constructor(e){this.resolver=e}supportsDescriptor(e,r){return!!(r.project.storedResolutions.get(e.descriptorHash)||r.project.originalPackages.has(gw(e).locatorHash))}supportsLocator(e,r){return!!(r.project.originalPackages.has(e.locatorHash)&&!r.project.lockfileNeedsRefresh)}shouldPersistResolution(e,r){throw new Error("The shouldPersistResolution method shouldn't be called on the lockfile resolver, which would always answer yes")}bindDescriptor(e,r,i){return e}getResolutionDependencies(e,r){return this.resolver.getResolutionDependencies(e,r)}async getCandidates(e,r,i){let n=i.project.originalPackages.get(gw(e).locatorHash);if(n)return[n];let s=i.project.storedResolutions.get(e.descriptorHash);if(!s)throw new Error("Expected the resolution to have been successful - resolution not found");if(n=i.project.originalPackages.get(s),!n)throw new Error("Expected the resolution to have been successful - package not found");return[n]}async getSatisfying(e,r,i){return null}async resolve(e,r){let i=r.project.originalPackages.get(e.locatorHash);if(!i)throw new Error("The lockfile resolver isn't meant to resolve packages - they should already have been stored into a cache");return i}};var nF=class{constructor(e){this.resolver=e}supportsDescriptor(e,r){return this.resolver.supportsDescriptor(e,r)}supportsLocator(e,r){return this.resolver.supportsLocator(e,r)}shouldPersistResolution(e,r){return this.resolver.shouldPersistResolution(e,r)}bindDescriptor(e,r,i){return this.resolver.bindDescriptor(e,r,i)}getResolutionDependencies(e,r){return this.resolver.getResolutionDependencies(e,r)}async getCandidates(e,r,i){throw new ct($.MISSING_LOCKFILE_ENTRY,`This package doesn't seem to be present in your lockfile; run "yarn install" to update the lockfile`)}async getSatisfying(e,r,i){throw new ct($.MISSING_LOCKFILE_ENTRY,`This package doesn't seem to be present in your lockfile; run "yarn install" to update the lockfile`)}async resolve(e,r){throw new ct($.MISSING_LOCKFILE_ENTRY,`This package doesn't seem to be present in your lockfile; run "yarn install" to update the lockfile`)}};var pi=class extends Ji{reportCacheHit(e){}reportCacheM Line truncated
`;await K.changeFilePromise(r,i,{automaticNewlines:!0}),this.manifest.raw=e}};var a$=6,zKe=1,_Ke=/ *, */g,A$=/\/$/,VKe=32,XKe=(0,sF.promisify)(aF.default.gzip),ZKe=(0,sF.promisify)(aF.default.gunzip),di;(function(r){r.UpdateLockfile="update-lockfile",r.SkipBuild="skip-build"})(di||(di={}));var AF={restoreInstallersCustomData:["installersCustomData"],restoreResolutions:["accessibleLocators","conditionalLocators","disabledLocators","optionalBuilds","storedDescriptors","storedResolutions","storedPackages","lockFileChecksum"],restoreBuildState:["storedBuildState"]},l$=t=>ln(`${zKe}`,t),ze=class{constructor(e,{configuration:r}){this.resolutionAliases=new Map;this.workspaces=[];this.workspacesByCwd=new Map;this.workspacesByIdent=new Map;this.storedResolutions=new Map;this.storedDescriptors=new Map;this.storedPackages=new Map;this.storedChecksums=new Map;this.storedBuildState=new Map;this.accessibleLocators=new Set;this.conditionalLocators=new Set;this.disabledLocators=new Set;this.originalPackages=new Map;this.optionalBuilds=new Set;this.lockfileNeedsRefresh=!1;this.peerRequirements=new Map;this.installersCustomData=new Map;this.lockFileChecksum=null;this.installStateChecksum=null;this.configuration=r,this.cwd=e}static async find(e,r){var p,m,y;if(!e.projectCwd)throw new Pe(`No project found in ${r}`);let i=e.projectCwd,n=r,s=null;for(;s!==e.projectCwd;){if(s=n,K.existsSync(x.join(s,Pt.manifest))){i=s;break}n=x.dirname(s)}let o=new ze(e.projectCwd,{configuration:e});(p=we.telemetry)==null||p.reportProject(o.cwd),await o.setupResolutions(),await o.setupWorkspaces(),(m=we.telemetry)==null||m.reportWorkspaceCount(o.workspaces.length),(y=we.telemetry)==null||y.reportDependencyCount(o.workspaces.reduce((b,S)=>b+S.manifest.dependencies.size+S.manifest.devDependencies.size,0));let a=o.tryWorkspaceByCwd(i);if(a)return{project:o,workspace:a,locator:a.anchoredLocator};let l=await o.findLocatorForLocation(`${i}/`,{strict:!0});if(l)return{project:o,locator:l,workspace:null};let c=et(e,o.cwd,Ye.PATH),u=et(e,x.relative(o.cwd,i),Ye.PATH),g=`- If ${c} isn't intended to be a project, remove any yarn.lock and/or package.json file there.`,f=`- If ${c} is intended to be a project, it might be that you forgot to list ${u} in its workspace configuration.`,h=`- Finally, if ${c} is fine and you intend ${u} to be treated as a completely separate project (not even a workspace), create an empty yarn.lock file in it.`;throw new Pe(`The nearest package directory (${et(e,i,Ye.PATH)}) doesn't seem to be part of the project declared in ${et(e,o.cwd,Ye.PATH)}.
${[g,f,h].join(`
`)}`)}async setupResolutions(){var i;this.storedResolutions=new Map,this.storedDescriptors=new Map,this.storedPackages=new Map,this.lockFileChecksum=null;let e=x.join(this.cwd,this.configuration.get("lockfileFilename")),r=this.configuration.get("defaultLanguageName");if(K.existsSync(e)){let n=await K.readFilePromise(e,"utf8");this.lockFileChecksum=l$(n);let s=Qi(n);if(s.__metadata){let o=s.__metadata.version,a=s.__metadata.cacheKey;this.lockfileNeedsRefresh=o<a$;for(let l of Object.keys(s)){if(l==="__metadata")continue;let c=s[l];if(typeof c.resolution=="undefined")throw new Error(`Assertion failed: Expected the lockfile entry to have a resolution field (${l})`);let u=Kc(c.resolution,!0),g=new At;g.load(c,{yamlCompatibilityMode:!0});let f=g.version,h=g.languageName||r,p=c.linkType.toUpperCase(),m=(i=c.conditions)!=null?i:null,y=g.dependencies,b=g.peerDependencies,S=g.dependenciesMeta,k=g.peerDependenciesMeta,T=g.bin;if(c.checksum!=null){let j=typeof a!="undefined"&&!c.checksum.includes("/")?`${a}/${c.checksum}`:c.checksum;this.storedChecksums.set(u.locatorHash,j)}let Y=ie(N({},u),{version:f,languageName:h,linkType:p,conditions:m,dependencies:y,peerDependencies:b,dependenciesMeta:S,peerDependenciesMeta:k,bin:T});this.originalPackages.set(Y.locatorHash,Y);for(let j of l.split(_Ke)){let Z=sl(j);this.storedDescriptors.set(Z.descriptorHash,Z),this.storedResolutions.set(Z.descriptorHash,u.locatorHash)}}}}}async setupWorkspaces(){this.workspaces=[],this.workspacesByCwd=new Map,this.workspacesByIdent=new Map;let e=[this.cwd];for(;e.length>0;){let r=e;e=[];for(let i of r){if(this.workspacesByCwd.has(i))continue;let n=await this.addWorkspace(i),s=this.storedPackages.get(n.anchoredLocator.locatorHash);s&&(n.dependencies=s.dependencies);for(let o of n.workspacesCwds)e.push(o)}}}async addWorkspace(e){let r=new bC(e,{project:this});await r.setup();let i=this.workspacesByIdent.get(r.locator.identHash);if(typeof i!="undefined")throw new Error(`Duplicate workspace name ${gi(this.configuration,r.locator)}: ${H.fromPortablePath(e)} conflicts with ${H.fromPortablePath(i.cwd)}`);return this.workspaces.push(r),this.workspacesByCwd.set(e,r),this.workspacesByIdent.set(r.locator.identHash,r),r}get topLevelWorkspace(){return this.getWorkspaceByCwd(this.cwd)}tryWorkspaceByCwd(e){x.isAbsolute(e)||(e=x.resolve(this.cwd,e)),e=x.normalize(e).replace(/\/+$/,"");let r=this.workspacesByCwd.get(e);return r||null}getWorkspaceByCwd(e){let r=this.tryWorkspaceByCwd(e);if(!r)throw new Error(`Workspace not found (${e})`);return r}tryWorkspaceByFilePath(e){let r=null;for(let i of this.workspaces)x.relative(i.cwd,e).startsWith("../")||r&&r.cwd.length>=i.cwd.length||(r=i);return r||null}getWorkspaceByFilePath(e){let r=this.tryWorkspaceByFilePath(e);if(!r)throw new Error(`Workspace not found (${e})`);return r}tryWorkspaceByIdent(e){let r=this.workspacesByIdent.get(e.identHash);return typeof r=="undefined"?null:r}getWorkspaceByIdent(e){let r=this.tryWorkspaceByIdent(e);if(!r)throw new Error(`Workspace not found (${gi(this.configuration,e)})`);return r}tryWorkspaceByDescriptor(e){let r=this.tryWorkspaceByIdent(e);return r===null||(nl(e)&&(e=gd(e)),!r.accepts(e.range))?null:r}getWorkspaceByDescriptor(e){let r=this.tryWorkspaceByDescriptor(e);if(r===null)throw new Error(`Workspace not found (${sr(this.configuration,e)})`);return r}tryWorkspaceByLocator(e){let r=this.tryWorkspaceByIdent(e);return r===null||(Xo(e)&&(e=fd(e)),r.locator.locatorHash!==e.locatorHash&&r.anchoredLocator.locatorHash!==e.locatorHash)?null:r}getWorkspaceByLocator(e){let r=this.tryWorkspaceByLocator(e);if(!r)throw new Error(`Workspace not found (${Bt(this.configuration,e)})`);return r}refreshWorkspaceDependencies(){for(let e of this.workspaces){let r=this.storedPackages.get(e.anchoredLocator.locatorHash);if(!r)throw new Error(`Assertion failed: Expected workspace ${md(this.configuration,e)} (${et(this.configuration,x.join(e.cwd,Pt.manifest),Ye.PATH)}) to have been resolved. Run "yarn install" to update the lockfile`);e.dependencies=new Map(r.dependencies)}}forgetResolution(e){let r=n=>{this.storedResolutions.delete(n),this.storedDescriptors.delete(n)},i=n=>{this.originalPackages.delete(n),this.storedPackages.delete(n),this.accessibleLocators.delete(n)};if("descriptorHash"in e){let n=this.storedResolutions.get(e.descriptorHash);r(e.descriptorHash);let s=new Set(this.storedResolutions.values());typeof n!="undefined"&&!s.has(n)&&i(n)}if("locatorHash"in e){i(e.locatorHash);for(let[n,s]of this.storedResolutions)s===e.locatorHash&&r(n)}}forgetTransientResolutions(){let e=this.configuration.makeResolver();for(let r of this.originalPackages.values()){let i;try{i=e.shouldPersistResolution(r,{project:this,resolver:e})}catch{i=!1}i||this.forgetResolution(r)}}forgetVirtualResolutions(){for(let e of this.storedPackages.values())for(let[r,i]of e.dependencies)nl(i)&&e.dependencies.set(r,gd(i))}getDependencyMeta(e,r){let i={},s=this.topLevelWorkspace.manifest.dependenciesMeta.get(Ot(e));if(!s)returLine truncated
`;switch(be){case ls.SCRIPT:Fe+=`# Script name: ${he}
`;break;case ls.SHELLCODE:Fe+=`# Script code: ${he}
`;break}let Ue=null;if(!await K.mktempPromise(async Se=>{let de=x.join(Se,"build.log"),{stdout:V,stderr:Qe}=this.configuration.getSubprocessStreams(de,{header:Fe,prefix:Bt(this.configuration,pe),report:r}),ce;try{switch(be){case ls.SCRIPT:ce=await AB(pe,he,[],{cwd:se,project:this,stdin:Ue,stdout:V,stderr:Qe});break;case ls.SHELLCODE:ce=await hD(pe,he,[],{cwd:se,project:this,stdin:Ue,stdout:V,stderr:Qe});break}}catch(gt){Qe.write(gt.stack),ce=1}if(V.end(),Qe.end(),ce===0)return re.set(pe.locatorHash,te),!0;K.detachTemp(Se);let fe=`${Bt(this.configuration,pe)} couldn't be built successfully (exit code ${et(this.configuration,ce,Ye.NUMBER)}, logs can be found here: ${et(this.configuration,de,Ye.PATH)})`;return this.optionalBuilds.has(pe.locatorHash)?(r.reportInfo($.BUILD_FAILED,fe),re.set(pe.locatorHash,te),!0):(r.reportError($.BUILD_FAILED,fe),!1)}))return}})())}}if(await uo(O),X===k.size){let L=Array.from(k).map(pe=>{let Ce=this.storedPackages.get(pe);if(!Ce)throw new Error("Assertion failed: The package should have been registered");return Bt(this.configuration,Ce)}).join(", ");r.reportError($.CYCLIC_DEPENDENCIES,`Some packages have circular dependencies that make their build order unsatisfiable - as a result they won't be built (affected packages are: ${L})`);break}}this.storedBuildState=re}async install(e){var a,l;let r=this.configuration.get("nodeLinker");(a=we.telemetry)==null||a.reportInstall(r),await e.report.startTimerPromise("Project validation",{skipIfEmpty:!0},async()=>{await this.configuration.triggerHook(c=>c.validateProject,this,{reportWarning:e.report.reportWarning.bind(e.report),reportError:e.report.reportError.bind(e.report)})});for(let c of this.configuration.packageExtensions.values())for(let[,u]of c)for(let g of u)g.status=qi.Inactive;let i=x.join(this.cwd,this.configuration.get("lockfileFilename")),n=null;if(e.immutable)try{n=await K.readFilePromise(i,"utf8")}catch(c){throw c.code==="ENOENT"?new ct($.FROZEN_LOCKFILE_EXCEPTION,"The lockfile would have been created by this install, which is explicitly forbidden."):c}await e.report.startTimerPromise("Resolution step",async()=>{await this.resolveEverything(e)}),await e.report.startTimerPromise("Post-resolution validation",{skipIfEmpty:!0},async()=>{for(let[,c]of this.configuration.packageExtensions)for(let[,u]of c)for(let g of u)if(g.userProvided){let f=et(this.configuration,g,Ye.PACKAGE_EXTENSION);switch(g.status){case qi.Inactive:e.report.reportWarning($.UNUSED_PACKAGE_EXTENSION,`${f}: No matching package in the dependency tree; you may not need this rule anymore.`);break;case qi.Redundant:e.report.reportWarning($.REDUNDANT_PACKAGE_EXTENSION,`${f}: This rule seems redundant when applied on the original package; the extension may have been applied upstream.`);break}}if(n!==null){let c=ec(n,this.generateLockfile());if(c!==n){let u=(0,n$.structuredPatch)(i,i,n,c);e.report.reportSeparator();for(let g of u.hunks){e.report.reportInfo(null,`@@ -${g.oldStart},${g.oldLines} +${g.newStart},${g.newLines} @@`);for(let f of g.lines)f.startsWith("+")?e.report.reportError($.FROZEN_LOCKFILE_EXCEPTION,et(this.configuration,f,Ye.ADDED)):f.startsWith("-")?e.report.reportError($.FROZEN_LOCKFILE_EXCEPTION,et(this.configuration,f,Ye.REMOVED)):e.report.reportInfo(null,et(this.configuration,f,"grey"))}throw e.report.reportSeparator(),new ct($.FROZEN_LOCKFILE_EXCEPTION,"The lockfile would have been modified by this install, which is explicitly forbidden.")}}});for(let c of this.configuration.packageExtensions.values())for(let[,u]of c)for(let g of u)g.userProvided&&g.status===qi.Active&&((l=we.telemetry)==null||l.reportPackageExtension(Rc(g,Ye.PACKAGE_EXTENSION)));await e.report.startTimerPromise("Fetch step",async()=>{await this.fetchEverything(e),(typeof e.persistProject=="undefined"||e.persistProject)&&e.mode!==di.UpdateLockfile&&await this.cacheCleanup(e)});let s=e.immutable?[...new Set(this.configuration.get("immutablePatterns"))].sort():[],o=await Promise.all(s.map(async c=>cw(c,{cwd:this.cwd})));(typeof e.persistProject=="undefined"||e.persistProject)&&await this.persist(),await e.report.startTimerPromise("Link step",async()=>{if(e.mode===di.UpdateLockfile){e.report.reportWarning($.UPDATE_LOCKFILE_ONLY_SKIP_LINK,`Skipped due to ${et(this.configuration,"mode=update-lockfile",Ye.CODE)}`);return}await this.linkEverything(e);let c=await Promise.all(s.map(async u=>cw(u,{cwd:this.cwd})));for(let u=0;u<s.length;++u)o[u]!==c[u]&&e.report.reportError($.FROZEN_ARTIFACT_EXCEPTION,`The checksum for ${s[u]} has been modified by this install, which is explicitly forbidden.`)}),await this.persistInstallStateFile(),await this.configuration.triggerHook(c=>c.afterAllInstalled,this,e)}generateLockfile(){let e=new Map;for(let[n,s]of this.storedResolutions.entries()){let o=e.get(s);o||e.set(s,o=new Set),o.add(n)}let r={};r.__metadata={version:a$,cacheKey:void 0};for(let[n,s]of e.entries()){let o=this.originalPackages.get(n);if(!o)continue;let a=[];for(let f of s){let h=this.sto Line truncated
`,`# Manual changes might be lost - proceed with caution!
`].join("")}
`+La(r)}async persistLockfile(){let e=x.join(this.cwd,this.configuration.get("lockfileFilename")),r="";try{r=await K.readFilePromise(e,"utf8")}catch(s){}let i=this.generateLockfile(),n=ec(r,i);n!==r&&(await K.writeFilePromise(e,n),this.lockFileChecksum=l$(n),this.lockfileNeedsRefresh=!1)}async persistInstallStateFile(){let e=[];for(let o of Object.values(AF))e.push(...o);let r=(0,d0.default)(this,e),i=oF.default.serialize(r),n=ln(i);if(this.installStateChecksum===n)return;let s=this.configuration.get("installStatePath");await K.mkdirPromise(x.dirname(s),{recursive:!0}),await K.writeFilePromise(s,await XKe(i)),this.installStateChecksum=n}async restoreInstallState({restoreInstallersCustomData:e=!0,restoreResolutions:r=!0,restoreBuildState:i=!0}={}){let n=this.configuration.get("installStatePath"),s;try{let o=await ZKe(await K.readFilePromise(n));s=oF.default.deserialize(o),this.installStateChecksum=ln(o)}catch{r&&await this.applyLightResolution();return}e&&typeof s.installersCustomData!="undefined"&&(this.installersCustomData=s.installersCustomData),i&&Object.assign(this,(0,d0.default)(s,AF.restoreBuildState)),r&&(s.lockFileChecksum===this.lockFileChecksum?(Object.assign(this,(0,d0.default)(s,AF.restoreResolutions)),this.refreshWorkspaceDependencies()):await this.applyLightResolution())}async applyLightResolution(){await this.resolveEverything({lockfileOnly:!0,report:new pi}),await this.persistInstallStateFile()}async persist(){await this.persistLockfile();for(let e of this.workspacesByCwd.values())await e.persistManifest()}async cacheCleanup({cache:e,report:r}){if(this.configuration.get("enableGlobalCache"))return;let i=new Set([".gitignore"]);if(!Ix(e.cwd,this.cwd)||!await K.existsPromise(e.cwd))return;let n=this.configuration.get("preferAggregateCacheInfo"),s=0,o=null;for(let a of await K.readdirPromise(e.cwd)){if(i.has(a))continue;let l=x.resolve(e.cwd,a);e.markedFiles.has(l)||(o=a,e.immutable?r.reportError($.IMMUTABLE_CACHE,`${et(this.configuration,x.basename(l),"magenta")} appears to be unused and would be marked for deletion, but the cache is immutable`):(n?s+=1:r.reportInfo($.UNUSED_CACHE_ENTRY,`${et(this.configuration,x.basename(l),"magenta")} appears to be unused - removing`),await K.removePromise(l)))}n&&s!==0&&r.reportInfo($.UNUSED_CACHE_ENTRY,s>1?`${s} packages appeared to be unused and were removed`:`${o} appeared to be unused and was removed`),e.markedFiles.clear()}};function $Ke({project:t,allDescriptors:e,allResolutions:r,allPackages:i,accessibleLocators:n=new Set,optionalBuilds:s=new Set,peerRequirements:o=new Map,volatileDescriptors:a=new Set,report:l,tolerateMissingPackages:c=!1}){var re;let u=new Map,g=[],f=new Map,h=new Map,p=new Map,m=new Map,y=new Map,b=new Map(t.workspaces.map(ee=>{let A=ee.anchoredLocator.locatorHash,oe=i.get(A);if(typeof oe=="undefined"){if(c)return[A,null];throw new Error("Assertion failed: The workspace should have an associated package")}return[A,ud(oe)]})),S=()=>{let ee=K.mktempSync(),A=x.join(ee,"stacktrace.log"),oe=String(g.length+1).length,le=g.map((X,O)=>`${`${O+1}.`.padStart(oe," ")} ${Ds(X)}
`).join("");throw K.writeFileSync(A,le),K.detachTemp(ee),new ct($.STACK_OVERFLOW_RESOLUTION,`Encountered a stack overflow when resolving peer dependencies; cf ${H.fromPortablePath(A)}`)},k=ee=>{let A=r.get(ee.descriptorHash);if(typeof A=="undefined")throw new Error("Assertion failed: The resolution should have been registered");let oe=i.get(A);if(!oe)throw new Error("Assertion failed: The package could not be found");return oe},T=(ee,A,oe,{top:le,optional:X})=>{g.length>1e3&&S(),g.push(A);let O=Y(ee,A,oe,{top:le,optional:X});return g.pop(),O},Y=(ee,A,oe,{top:le,optional:X})=>{if(n.has(A.locatorHash))return;n.add(A.locatorHash),X||s.delete(A.locatorHash);let O=i.get(A.locatorHash);if(!O){if(c)return;throw new Error(`Assertion failed: The package (${Bt(t.configuration,A)}) should have been registered`)}let L=[],pe=[],Ce=[],Oe=[],te=[];for(let be of Array.from(O.dependencies.values())){if(O.peerDependencies.has(be.identHash)&&O.locatorHash!==le)continue;if(nl(be))throw new Error("Assertion failed: Virtual packages shouldn't be encountered when virtualizing a branch");a.delete(be.descriptorHash);let he=X;if(!he){let Qe=O.dependenciesMeta.get(Ot(be));if(typeof Qe!="undefined"){let ce=Qe.get(null);typeof ce!="undefined"&&ce.optional&&(he=!0)}}let Fe=r.get(be.descriptorHash);if(!Fe){if(c)continue;throw new Error(`Assertion failed: The resolution (${sr(t.configuration,be)}) should have been registered`)}let Ue=b.get(Fe)||i.get(Fe);if(!Ue)throw new Error(`Assertion failed: The package (${Fe}, resolved from ${sr(t.configuration,be)}) should have been registered`);if(Ue.peerDependencies.size===0){T(be,Ue,new Map,{top:le,optional:he});continue}let xe,Se,de=new Set,V;pe.push(()=>{xe=Ax(be,A.locatorHash),Se=lx(Ue,A.locatorHash),O.dependencies.delete(be.identHash),O.dependencies.set(xe.identHash,xe),r.set(xe.descriptorHash,Se.locatorHash),e.set(xe.descriptorHash,xe),i.set(Se.locatorHash,Se),L.push([Ue,xe,Se])}),Ce.push(()=>{var Qe;V=new Map;for(let ce of Se.peerDependencies.values()){let fe=O.dependencies.get(ce.identHash);if(!fe&&hd(A,ce)&&(ee.identHash===A.identHash?fe=ee:(fe=rr(A,ee.range),e.set(fe.descriptorHash,fe),r.set(fe.descriptorHash,A.locatorHash),a.delete(fe.descriptorHash))),(!fe||fe.range==="missing:")&&Se.dependencies.has(ce.identHash)){Se.peerDependencies.delete(ce.identHash);continue}fe||(fe=rr(ce,"missing:")),Se.dependencies.set(fe.identHash,fe),nl(fe)&&xc(p,fe.descriptorHash).add(Se.locatorHash),f.set(fe.identHash,fe),fe.range==="missing:"&&de.add(fe.identHash),V.set(ce.identHash,(Qe=oe.get(ce.identHash))!=null?Qe:Se.locatorHash)}Se.dependencies=new Map(xn(Se.dependencies,([ce,fe])=>Ot(fe)))}),Oe.push(()=>{if(!i.has(Se.locatorHash))return;let Qe=u.get(Ue.locatorHash);typeof Qe=="number"&&Qe>=2&&S();let ce=u.get(Ue.locatorHash),fe=typeof ce!="undefined"?ce+1:1;u.set(Ue.locatorHash,fe),T(xe,Se,V,{top:le,optional:he}),u.set(Ue.locatorHash,fe-1)}),te.push(()=>{let Qe=O.dependencies.get(be.identHash);if(typeof Qe=="undefined")throw new Error("Assertion failed: Expected the peer dependency to have been turned into a dependency");let ce=r.get(Qe.descriptorHash);if(typeof ce=="undefined")throw new Error("Assertion failed: Expected the descriptor to be registered");if(xc(y,ce).add(A.locatorHash),!!i.has(Se.locatorHash)){for(let fe of Se.peerDependencies.values()){let gt=V.get(fe.identHash);if(typeof gt=="undefined")throw new Error("Assertion failed: Expected the peer dependency ident to be registered");Pg(Dg(m,gt),Ot(fe)).push(Se.locatorHash)}for(let fe of de)Se.dependencies.delete(fe)}})}for(let be of[...pe,...Ce])be();let se;do{se=!0;for(let[be,he,Fe]of L){let Ue=Dg(h,be.locatorHash),xe=ln(...[...Fe.dependencies.values()].map(Qe=>{let ce=Qe.range!=="missing:"?r.get(Qe.descriptorHash):"missing:";if(typeof ce=="undefined")throw new Error(`Assertion failed: Expected the resolution for ${sr(t.configuration,Qe)} to have been registered`);return ce===le?`${ce} (top)`:ce}),he.identHash),Se=Ue.get(xe);if(typeof Se=="undefined"){Ue.set(xe,he);continue}if(Se===he)continue;i.delete(Fe.locatorHash),e.delete(he.descriptorHash),r.delete(he.descriptorHash),n.delete(Fe.locatorHash);let de=p.get(he.descriptorHash)||[],V=[O.locatorHash,...de];p.delete(he.descriptorHash);for(let Qe of V){let ce=i.get(Qe);typeof ce!="undefined"&&(ce.dependencies.get(he.identHash).descriptorHash!==Se.descriptorHash&&(se=!1),ce.dependencies.set(he.identHash,Se))}}}while(!se);for(let be of[...Oe,...te])be()};for(let ee of t.workspaces){let A=ee.anchoredLocator;a.delete(ee.anchoredDescriptor.descriptorHash),T(ee.anchoredDescriptor,A,new Map,{top:A.locatorHash,optional:!1})}var j;(function(oe){oe[oe.NotProvided=0]="NotProvided",oe[oe.NotCompatible=1]="NotCompatible"})(j||(j={}));let Z=[];for(let[ee,A]of y){let oe=i.get(ee);if(typeof oe=="undefined")throw new Error("Assertion failed: Expected the root to be registered");let le=m.get(ee);if(typeof le!="undefined")for(let X of A){let O=i.get(X);if(typeof O!="undefined")for(let[L,pe]of le){let Ce=An(L);i Line truncated
Try running the command again with the package name prefixed: ${Ae.pretty(e,"yarn add",Di.CODE)} ${Ae.pretty(e,P.makeDescriptor(P.makeIdent(null,"my-package"),`${S[0]}...`),Di.DESCRIPTOR)}`);if(!b)throw new Pe(`The ${Ae.pretty(e,y,Di.CODE)} string didn't match the required format (package-name@range). Did you perhaps forget to explicitly reference the package name?`);let k=kJe(i,b,{dev:this.dev,peer:this.peer,preferDev:this.preferDev,optional:this.optional}),T=await rm(b,{project:r,workspace:i,cache:n,target:k,modifier:o,strategies:a,maxResults:l});return[b,T,k]})),u=await gA.start({configuration:e,stdout:this.context.stdout,suggestInstall:!1},async y=>{for(let[b,{suggestions:S,rejections:k}]of c)if(S.filter(Y=>Y.descriptor!==null).length===0){let[Y]=k;if(typeof Y=="undefined")throw new Error("Assertion failed: Expected an error to have been set");r.configuration.get("enableNetwork")?y.reportError($.CANT_SUGGEST_RESOLUTIONS,`${P.prettyDescriptor(e,b)} can't be resolved to a satisfying range`):y.reportError($.CANT_SUGGEST_RESOLUTIONS,`${P.prettyDescriptor(e,b)} can't be resolved to a satisfying range (note: network resolution has been disabled)`),y.reportSeparator(),y.reportExceptionOnce(Y)}});if(u.hasErrors())return u.exitCode();let g=!1,f=[],h=[];for(let[,{suggestions:y},b]of c){let S,k=y.filter(Z=>Z.descriptor!==null),T=k[0].descriptor,Y=k.every(Z=>P.areDescriptorsEqual(Z.descriptor,T));k.length===1||Y?S=T:(g=!0,{answer:S}=await(0,Nse.prompt)({type:"select",name:"answer",message:"Which range do you want to use?",choices:y.map(({descriptor:Z,name:J,reason:re})=>Z?{name:J,hint:re,descriptor:Z}:{name:J,hint:re,disabled:!0}),onCancel:()=>process.exit(130),result(Z){return this.find(Z,"descriptor")},stdin:this.context.stdin,stdout:this.context.stdout}));let j=i.manifest[b].get(S.identHash);(typeof j=="undefined"||j.descriptorHash!==S.descriptorHash)&&(i.manifest[b].set(S.identHash,S),this.optional&&(b==="dependencies"?i.manifest.ensureDependencyMeta(ie(N({},S),{range:"unknown"})).optional=!0:b==="peerDependencies"&&(i.manifest.ensurePeerDependencyMeta(ie(N({},S),{range:"unknown"})).optional=!0)),typeof j=="undefined"?f.push([i,b,S,a]):h.push([i,b,j,S]))}return await e.triggerMultipleHooks(y=>y.afterWorkspaceDependencyAddition,f),await e.triggerMultipleHooks(y=>y.afterWorkspaceDependencyReplacement,h),g&&this.context.stdout.write(`
`),(await Je.start({configuration:e,json:this.json,stdout:this.context.stdout,includeLogs:!this.context.quiet},async y=>{await r.install({cache:n,report:y,mode:this.mode})})).exitCode()}};im.paths=[["add"]],im.usage=Re.Usage({description:"add dependencies to the project",details:"\n This command adds a package to the package.json for the nearest workspace.\n\n - If it didn't exist before, the package will by default be added to the regular `dependencies` field, but this behavior can be overriden thanks to the `-D,--dev` flag (which will cause the dependency to be added to the `devDependencies` field instead) and the `-P,--peer` flag (which will do the same but for `peerDependencies`).\n\n - If the package was already listed in your dependencies, it will by default be upgraded whether it's part of your `dependencies` or `devDependencies` (it won't ever update `peerDependencies`, though).\n\n - If set, the `--prefer-dev` flag will operate as a more flexible `-D,--dev` in that it will add the package to your `devDependencies` if it isn't already listed in either `dependencies` or `devDependencies`, but it will also happily upgrade your `dependencies` if that's what you already use (whereas `-D,--dev` would throw an exception).\n\n - If set, the `-O,--optional` flag will add the package to the `optionalDependencies` field and, in combination with the `-P,--peer` flag, it will add the package as an optional peer dependency. If the package was already listed in your `dependencies`, it will be upgraded to `optionalDependencies`. If the package was already listed in your `peerDependencies`, in combination with the `-P,--peer` flag, it will be upgraded to an optional peer dependency: `\"peerDependenciesMeta\": { \"<package>\": { \"optional\": true } }`\n\n - If the added package doesn't specify a range at all its `latest` tag will be resolved and the returned version will be used to generate a new semver range (using the `^` modifier by default unless otherwise configured via the `defaultSemverRangePrefix` configuration, or the `~` modifier if `-T,--tilde` is specified, or no modifier at all if `-E,--exact` is specified). Two exceptions to this rule: the first one is that if the package is a workspace then its local version will be used, and the second one is that if you use `-P,--peer` the default range will be `*` and won't be resolved at all.\n\n - If the added package specifies a range (such as `^1.0.0`, `latest`, or `rc`), Yarn will add this range as-is in the resulting package.json entry (in particular, tags such as `rc` will be encoded as-is rather than being converted into a semver range).\n\n If the `--cached` option is used, Yarn will preferably reuse the highest version already used somewhere within the project, even if through a transitive dependency.\n\n If the `-i,--interactive` option is used (or if the `preferInteractive` settings is toggled on) the command will first try to check whether other workspaces in the project use the specified package and, if so, will offer to reuse them.\n\n If the `--mode=<mode>` option is set, Yarn will change which artifacts are generated. The modes currently supported are:\n\n - `skip-build` will not run the build scripts at all. Note that this is different from setting `enableScripts` to false because the later will disable build scripts, and thus affect the content of the artifacts generated on disk, whereas the former will just disable the build step - but not the scripts themselves, which just won't run.\n\n - `update-lockfile` will skip the link step altogether, and only fetch packages that are missing from the lockfile (or that have no associated checksums). This mode is typically used by tools like Renovate or Dependabot to keep a lockfile up-to-date without incurring the full install cost.\n\n For a compilation of all the supported protocols, please consult the dedicated page from our website: https://yarnpkg.com/features/protocols.\n ",examples:[["Add a regular package to the current workspace","$0 add lodash"],["Add a specific version for a package to the current workspace","$0 add lodash@1.2.3"],["Add a package from a GitHub repository (the master branch) to the current workspace using a URL","$0 add lodash@https://github.com/lodash/lodash"],["Add a package from a GitHub repository (the master branch) to the current workspace using the GitHub protocol","$0 add lodash@github:lodash/lodash"],["Add a package from a GitHub repository (the master branch) to the current workspace using the GitHub protocol (shorthand)","$0 add lodash@lodash/lodash"],["Add a package from a specific branch of a GitHub repository to the current workspace using the GitHub protocol (shorthand)","$0 add lodash-es@lodash/lodash#es"]]});var Lse=im;function kJe(t,e,{dev:r,peer:i,preferDev:n,optional:s}){let o=t.manifest[Hr.REGULAR].has(e.identHash),a=t.manifest[Hr.DEVELOPMENT].has(e.identHash),l=t.manifest[Hr.PEER].has(e.Line truncated
`),0}return(await Je.start({configuration:e,json:this.json,stdout:this.context.stdout},async s=>{let o=await Zt.getPackageAccessibleBinaries(i,{project:r}),l=Array.from(o.keys()).reduce((c,u)=>Math.max(c,u.length),0);for(let[c,[u,g]]of o)s.reportJson({name:c,source:P.stringifyIdent(u),path:g});if(this.verbose)for(let[c,[u]]of o)s.reportInfo(null,`${c.padEnd(l," ")} ${P.prettyLocator(e,u)}`);else for(let c of o.keys())s.reportInfo(null,c)})).exitCode()}};nm.paths=[["bin"]],nm.usage=Re.Usage({description:"get the path to a binary script",details:`
When used without arguments, this command will print the list of all the binaries available in the current workspace. Adding the \`-v,--verbose\` flag will cause the output to contain both the binary name and the locator of the package that provides the binary.
When an argument is specified, this command will just print the path to the binary on the standard output and exit. Note that the reported path may be stored within a zip archive.
`,examples:[["List all the available binaries","$0 bin"],["Print the path to a specific binary","$0 bin eslint"]]});var Tse=nm;var sm=class extends Le{constructor(){super(...arguments);this.mirror=W.Boolean("--mirror",!1,{description:"Remove the global cache files instead of the local cache files"});this.all=W.Boolean("--all",!1,{description:"Remove both the global cache files and the local cache files of the current project"})}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),r=await Nt.find(e);return(await Je.start({configuration:e,stdout:this.context.stdout},async()=>{let n=(this.all||this.mirror)&&r.mirrorCwd!==null,s=!this.mirror;n&&(await K.removePromise(r.mirrorCwd),await e.triggerHook(o=>o.cleanGlobalArtifacts,e)),s&&await K.removePromise(r.cwd)})).exitCode()}};sm.paths=[["cache","clean"],["cache","clear"]],sm.usage=Re.Usage({description:"remove the shared cache files",details:`
This command will remove all the files from the cache.
`,examples:[["Remove all the local archives","$0 cache clean"],["Remove all the archives stored in the ~/.yarn directory","$0 cache clean --mirror"]]});var Ose=sm;var Mse=ge(x0()),LN=ge(require("util")),om=class extends Le{constructor(){super(...arguments);this.json=W.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.unsafe=W.Boolean("--no-redacted",!1,{description:"Don't redact secrets (such as tokens) from the output"});this.name=W.String()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),r=this.name.replace(/[.[].*$/,""),i=this.name.replace(/^[^.[]*/,"");if(typeof e.settings.get(r)=="undefined")throw new Pe(`Couldn't find a configuration settings named "${r}"`);let s=e.getSpecial(r,{hideSecrets:!this.unsafe,getNativePaths:!0}),o=ve.convertMapsToIndexableObjects(s),a=i?(0,Mse.default)(o,i):o,l=await Je.start({configuration:e,includeFooter:!1,json:this.json,stdout:this.context.stdout},async c=>{c.reportJson(a)});if(!this.json){if(typeof a=="string")return this.context.stdout.write(`${a}
`),l.exitCode();LN.inspect.styles.name="cyan",this.context.stdout.write(`${(0,LN.inspect)(a,{depth:Infinity,colors:e.get("enableColors"),compact:!1})}
`)}return l.exitCode()}};om.paths=[["config","get"]],om.usage=Re.Usage({description:"read a configuration settings",details:`
This command will print a configuration setting.
Secrets (such as tokens) will be redacted from the output by default. If this behavior isn't desired, set the \`--no-redacted\` to get the untransformed value.
`,examples:[["Print a simple configuration setting","yarn config get yarnPath"],["Print a complex configuration setting","yarn config get packageExtensions"],["Print a nested field from the configuration",`yarn config get 'npmScopes["my-company"].npmRegistryServer'`],["Print a token from the configuration","yarn config get npmAuthToken --no-redacted"],["Print a configuration setting as JSON","yarn config get packageExtensions --json"]]});var Kse=om;var Xoe=ge(HN()),Zoe=ge(x0()),$oe=ge(Voe()),GN=ge(require("util")),Am=class extends Le{constructor(){super(...arguments);this.json=W.Boolean("--json",!1,{description:"Set complex configuration settings to JSON values"});this.home=W.Boolean("-H,--home",!1,{description:"Update the home configuration instead of the project configuration"});this.name=W.String();this.value=W.String()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),r=()=>{if(!e.projectCwd)throw new Pe("This command must be run from within a project folder");return e.projectCwd},i=this.name.replace(/[.[].*$/,""),n=this.name.replace(/^[^.[]*\.?/,"");if(typeof e.settings.get(i)=="undefined")throw new Pe(`Couldn't find a configuration settings named "${i}"`);if(i==="enableStrictSettings")throw new Pe("This setting only affects the file it's in, and thus cannot be set from the CLI");let o=this.json?JSON.parse(this.value):this.value;await(this.home?h=>we.updateHomeConfiguration(h):h=>we.updateConfiguration(r(),h))(h=>{if(n){let p=(0,Xoe.default)(h);return(0,$oe.default)(p,this.name,o),p}else return ie(N({},h),{[i]:o})});let c=(await we.find(this.context.cwd,this.context.plugins)).getSpecial(i,{hideSecrets:!0,getNativePaths:!0}),u=ve.convertMapsToIndexableObjects(c),g=n?(0,Zoe.default)(u,n):u;return(await Je.start({configuration:e,includeFooter:!1,stdout:this.context.stdout},async h=>{GN.inspect.styles.name="cyan",h.reportInfo($.UNNAMED,`Successfully set ${this.name} to ${(0,GN.inspect)(g,{depth:Infinity,colors:e.get("enableColors"),compact:!1})}`)})).exitCode()}};Am.paths=[["config","set"]],Am.usage=Re.Usage({description:"change a configuration settings",details:`
This command will set a configuration setting.
When used without the \`--json\` flag, it can only set a simple configuration setting (a string, a number, or a boolean).
When used with the \`--json\` flag, it can set both simple and complex configuration settings, including Arrays and Objects.
`,examples:[["Set a simple configuration setting (a string, a number, or a boolean)","yarn config set initScope myScope"],["Set a simple configuration setting (a string, a number, or a boolean) using the `--json` flag",'yarn config set initScope --json \\"myScope\\"'],["Set a complex configuration setting (an Array) using the `--json` flag",`yarn config set unsafeHttpWhitelist --json '["*.example.com", "example.com"]'`],["Set a complex configuration setting (an Object) using the `--json` flag",`yarn config set packageExtensions --json '{ "@babel/parser@*": { "dependencies": { "@babel/types": "*" } } }'`],["Set a nested configuration setting",'yarn config set npmScopes.company.npmRegistryServer "https://npm.example.com"'],["Set a nested configuration setting using indexed access for non-simple keys",`yarn config set 'npmRegistries["//npm.example.com"].npmAuthToken' "ffffffff-ffff-ffff-ffff-ffffffffffff"`]]});var eae=Am;var lae=ge(HN()),cae=ge(kC()),uae=ge(Aae()),lm=class extends Le{constructor(){super(...arguments);this.home=W.Boolean("-H,--home",!1,{description:"Update the home configuration instead of the project configuration"});this.name=W.String()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),r=()=>{if(!e.projectCwd)throw new Pe("This command must be run from within a project folder");return e.projectCwd},i=this.name.replace(/[.[].*$/,""),n=this.name.replace(/^[^.[]*\.?/,"");if(typeof e.settings.get(i)=="undefined")throw new Pe(`Couldn't find a configuration settings named "${i}"`);let o=this.home?l=>we.updateHomeConfiguration(l):l=>we.updateConfiguration(r(),l);return(await Je.start({configuration:e,includeFooter:!1,stdout:this.context.stdout},async l=>{let c=!1;await o(u=>{if(!(0,cae.default)(u,this.name))return l.reportWarning($.UNNAMED,`Configuration doesn't contain setting ${this.name}; there is nothing to unset`),c=!0,u;let g=n?(0,lae.default)(u):N({},u);return(0,uae.default)(g,this.name),g}),c||l.reportInfo($.UNNAMED,`Successfully unset ${this.name}`)})).exitCode()}};lm.paths=[["config","unset"]],lm.usage=Re.Usage({description:"unset a configuration setting",details:`
This command will unset a configuration setting.
`,examples:[["Unset a simple configuration setting","yarn config unset initScope"],["Unset a complex configuration setting","yarn config unset packageExtensions"],["Unset a nested configuration setting","yarn config unset npmScopes.company.npmRegistryServer"]]});var gae=lm;var jN=ge(require("util")),cm=class extends Le{constructor(){super(...arguments);this.verbose=W.Boolean("-v,--verbose",!1,{description:"Print the setting description on top of the regular key/value information"});this.why=W.Boolean("--why",!1,{description:"Print the reason why a setting is set a particular way"});this.json=W.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"})}async execute(){let e=await we.find(this.context.cwd,this.context.plugins,{strict:!1});return(await Je.start({configuration:e,json:this.json,stdout:this.context.stdout},async i=>{if(e.invalid.size>0&&!this.json){for(let[n,s]of e.invalid)i.reportError($.INVALID_CONFIGURATION_KEY,`Invalid configuration key "${n}" in ${s}`);i.reportSeparator()}if(this.json){let n=ve.sortMap(e.settings.keys(),s=>s);for(let s of n){let o=e.settings.get(s),a=e.getSpecial(s,{hideSecrets:!0,getNativePaths:!0}),l=e.sources.get(s);this.verbose?i.reportJson({key:s,effective:a,source:l}):i.reportJson(N({key:s,effective:a,source:l},o))}}else{let n=ve.sortMap(e.settings.keys(),a=>a),s=n.reduce((a,l)=>Math.max(a,l.length),0),o={breakLength:Infinity,colors:e.get("enableColors"),maxArrayLength:2};if(this.why||this.verbose){let a=n.map(c=>{let u=e.settings.get(c);if(!u)throw new Error(`Assertion failed: This settings ("${c}") should have been registered`);let g=this.why?e.sources.get(c)||"<default>":u.description;return[c,g]}),l=a.reduce((c,[,u])=>Math.max(c,u.length),0);for(let[c,u]of a)i.reportInfo(null,`${c.padEnd(s," ")} ${u.padEnd(l," ")} ${(0,jN.inspect)(e.getSpecial(c,{hideSecrets:!0,getNativePaths:!0}),o)}`)}else for(let a of n)i.reportInfo(null,`${a.padEnd(s," ")} ${(0,jN.inspect)(e.getSpecial(a,{hideSecrets:!0,getNativePaths:!0}),o)}`)}})).exitCode()}};cm.paths=[["config"]],cm.usage=Re.Usage({description:"display the current configuration",details:`
This command prints the current active configuration settings.
`,examples:[["Print the active configuration settings","$0 config"]]});var fae=cm;Is();var YN={};ft(YN,{Strategy:()=>yu,acceptedStrategies:()=>D8e,dedupe:()=>qN});var hae=ge(rs()),yu;(function(e){e.HIGHEST="highest"})(yu||(yu={}));var D8e=new Set(Object.values(yu)),R8e={highest:async(t,e,{resolver:r,fetcher:i,resolveOptions:n,fetchOptions:s})=>{let o=new Map;for(let[a,l]of t.storedResolutions){let c=t.storedDescriptors.get(a);if(typeof c=="undefined")throw new Error(`Assertion failed: The descriptor (${a}) should have been registered`);ve.getSetWithDefault(o,c.identHash).add(l)}return Array.from(t.storedDescriptors.values(),async a=>{if(e.length&&!hae.default.isMatch(P.stringifyIdent(a),e))return null;let l=t.storedResolutions.get(a.descriptorHash);if(typeof l=="undefined")throw new Error(`Assertion failed: The resolution (${a.descriptorHash}) should have been registered`);let c=t.originalPackages.get(l);if(typeof c=="undefined"||!r.shouldPersistResolution(c,n))return null;let u=o.get(a.identHash);if(typeof u=="undefined")throw new Error(`Assertion failed: The resolutions (${a.identHash}) should have been registered`);if(u.size===1)return null;let g=[...u].map(y=>{let b=t.originalPackages.get(y);if(typeof b=="undefined")throw new Error(`Assertion failed: The package (${y}) should have been registered`);return b.reference}),f=await r.getSatisfying(a,g,n),h=f==null?void 0:f[0];if(typeof h=="undefined")return null;let p=h.locatorHash,m=t.originalPackages.get(p);if(typeof m=="undefined")throw new Error(`Assertion failed: The package (${p}) should have been registered`);return p===l?null:{descriptor:a,currentPackage:c,updatedPackage:m}})}};async function qN(t,{strategy:e,patterns:r,cache:i,report:n}){let{configuration:s}=t,o=new pi,a=s.makeResolver(),l=s.makeFetcher(),c={cache:i,checksums:t.storedChecksums,fetcher:l,project:t,report:o,skipIntegrityCheck:!0,cacheOptions:{skipIntegrityCheck:!0}},u={project:t,resolver:a,report:o,fetchOptions:c};return await n.startTimerPromise("Deduplication step",async()=>{let f=await R8e[e](t,r,{resolver:a,resolveOptions:u,fetcher:l,fetchOptions:c}),h=Ji.progressViaCounter(f.length);n.reportProgress(h);let p=0;await Promise.all(f.map(b=>b.then(S=>{if(S===null)return;p++;let{descriptor:k,currentPackage:T,updatedPackage:Y}=S;n.reportInfo($.UNNAMED,`${P.prettyDescriptor(s,k)} can be deduped from ${P.prettyLocator(s,T)} to ${P.prettyLocator(s,Y)}`),n.reportJson({descriptor:P.stringifyDescriptor(k),currentResolution:P.stringifyLocator(T),updatedResolution:P.stringifyLocator(Y)}),t.storedResolutions.set(k.descriptorHash,Y.locatorHash)}).finally(()=>h.tick())));let m;switch(p){case 0:m="No packages";break;case 1:m="One package";break;default:m=`${p} packages`}let y=Ae.pretty(s,e,Ae.Type.CODE);return n.reportInfo($.UNNAMED,`${m} can be deduped using the ${y} strategy`),p})}var um=class extends Le{constructor(){super(...arguments);this.strategy=W.String("-s,--strategy",yu.HIGHEST,{description:"The strategy to use when deduping dependencies",validator:nn(yu)});this.check=W.Boolean("-c,--check",!1,{description:"Exit with exit code 1 when duplicates are found, without persisting the dependency tree"});this.json=W.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.mode=W.String("--mode",{description:"Change what artifacts installs generate",validator:nn(di)});this.patterns=W.Rest()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),{project:r}=await ze.find(e,this.context.cwd),i=await Nt.find(e);await r.restoreInstallState({restoreResolutions:!1});let n=0,s=await Je.start({configuration:e,includeFooter:!1,stdout:this.context.stdout,json:this.json},async o=>{n=await qN(r,{strategy:this.strategy,patterns:this.patterns,cache:i,report:o})});return s.hasErrors()?s.exitCode():this.check?n?1:0:(await Je.start({configuration:e,stdout:this.context.stdout,json:this.json},async a=>{await r.install({cache:i,report:a,mode:this.mode})})).exitCode()}};um.paths=[["dedupe"]],um.usage=Re.Usage({description:"deduplicate dependencies with overlapping ranges",details:"\n Duplicates are defined as descriptors with overlapping ranges being resolved and locked to different locators. They are a natural consequence of Yarn's deterministic installs, but they can sometimes pile up and unnecessarily increase the size of your project.\n\n This command dedupes dependencies in the current project using different strategies (only one is implemented at the moment):\n\n - `highest`: Reuses (where possible) the locators with the highest versions. This means that dependencies can only be upgraded, never downgraded. It's also guaranteed that it never takes more than a single pass to dedupe the entire dependency tree.\n\n **Note:** Even though it never produces a wrong dependency tree, this command should be used with caution, as it modifies the dependency tree, which can sometimes cause problems when packages don't strictly follow semver recommendations Line truncated
`)}};nb.paths=[["--clipanion=definitions"]];var mae=nb;var sb=class extends Le{async execute(){this.context.stdout.write(this.cli.usage(null))}};sb.paths=[["help"],["--help"],["-h"]];var Eae=sb;var JN=class extends Le{constructor(){super(...arguments);this.leadingArgument=W.String();this.args=W.Proxy()}async execute(){if(this.leadingArgument.match(/[\\/]/)&&!P.tryParseIdent(this.leadingArgument)){let e=x.resolve(this.context.cwd,H.toPortablePath(this.leadingArgument));return await this.cli.run(this.args,{cwd:e})}else return await this.cli.run(["run",this.leadingArgument,...this.args])}},Iae=JN;var ob=class extends Le{async execute(){this.context.stdout.write(`${Kr||"<unknown>"}
`)}};ob.paths=[["-v"],["--version"]];var yae=ob;var gm=class extends Le{constructor(){super(...arguments);this.commandName=W.String();this.args=W.Proxy()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),{project:r,locator:i}=await ze.find(e,this.context.cwd);return await r.restoreInstallState(),await Zt.executePackageShellcode(i,this.commandName,this.args,{cwd:this.context.cwd,stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr,project:r})}};gm.paths=[["exec"]],gm.usage=Re.Usage({description:"execute a shell script",details:`
This command simply executes a shell script within the context of the root directory of the active workspace using the portable shell.
It also makes sure to call it in a way that's compatible with the current project (for example, on PnP projects the environment will be setup in such a way that PnP will be correctly injected into the environment).
`,examples:[["Execute a single shell command","$0 exec echo Hello World"],["Execute a shell script",'$0 exec "tsc & babel src --out-dir lib"']]});var wae=gm;Is();var fm=class extends Le{constructor(){super(...arguments);this.hash=W.String({required:!1,validator:hp(fp(),[pp(/^p[0-9a-f]{5}$/)])})}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),{project:r}=await ze.find(e,this.context.cwd);return await r.restoreInstallState({restoreResolutions:!1}),await r.applyLightResolution(),typeof this.hash!="undefined"?await F8e(this.hash,r,{stdout:this.context.stdout}):(await Je.start({configuration:e,stdout:this.context.stdout,includeFooter:!1},async n=>{var o;let s=[([,a])=>P.stringifyLocator(r.storedPackages.get(a.subject)),([,a])=>P.stringifyIdent(a.requested)];for(let[a,l]of ve.sortMap(r.peerRequirements,s)){let c=r.storedPackages.get(l.subject);if(typeof c=="undefined")throw new Error("Assertion failed: Expected the subject package to have been registered");let u=r.storedPackages.get(l.rootRequester);if(typeof u=="undefined")throw new Error("Assertion failed: Expected the root package to have been registered");let g=(o=c.dependencies.get(l.requested.identHash))!=null?o:null,f=Ae.pretty(e,a,Ae.Type.CODE),h=P.prettyLocator(e,c),p=P.prettyIdent(e,l.requested),m=P.prettyIdent(e,u),y=l.allRequesters.length-1,b=`descendant${y===1?"":"s"}`,S=y>0?` and ${y} ${b}`:"",k=g!==null?"provides":"doesn't provide";n.reportInfo(null,`${f} \u2192 ${h} ${k} ${p} to ${m}${S}`)}})).exitCode()}};fm.paths=[["explain","peer-requirements"]],fm.usage=Re.Usage({description:"explain a set of peer requirements",details:`
A set of peer requirements represents all peer requirements that a dependent must satisfy when providing a given peer request to a requester and its descendants.
When the hash argument is specified, this command prints a detailed explanation of all requirements of the set corresponding to the hash and whether they're satisfied or not.
When used without arguments, this command lists all sets of peer requirements and the corresponding hash that can be used to get detailed information about a given set.
**Note:** A hash is a six-letter p-prefixed code that can be obtained from peer dependency warnings or from the list of all peer requirements (\`yarn explain peer-requirements\`).
`,examples:[["Explain the corresponding set of peer requirements for a hash","$0 explain peer-requirements p1a4ed"],["List all sets of peer requirements","$0 explain peer-requirements"]]});var Bae=fm;async function F8e(t,e,r){let{configuration:i}=e,n=e.peerRequirements.get(t);if(typeof n=="undefined")throw new Error(`No peerDependency requirements found for hash: "${t}"`);return(await Je.start({configuration:i,stdout:r.stdout,includeFooter:!1},async o=>{var b,S;let a=e.storedPackages.get(n.subject);if(typeof a=="undefined")throw new Error("Assertion failed: Expected the subject package to have been registered");let l=e.storedPackages.get(n.rootRequester);if(typeof l=="undefined")throw new Error("Assertion failed: Expected the root package to have been registered");let c=(b=a.dependencies.get(n.requested.identHash))!=null?b:null,u=c!==null?e.storedResolutions.get(c.descriptorHash):null;if(typeof u=="undefined")throw new Error("Assertion failed: Expected the resolution to have been registered");let g=u!==null?e.storedPackages.get(u):null;if(typeof g=="undefined")throw new Error("Assertion failed: Expected the provided package to have been registered");let f=[...n.allRequesters.values()].map(k=>{let T=e.storedPackages.get(k);if(typeof T=="undefined")throw new Error("Assertion failed: Expected the package to be registered");let Y=P.devirtualizeLocator(T),j=e.storedPackages.get(Y.locatorHash);if(typeof j=="undefined")throw new Error("Assertion failed: Expected the package to be registered");let Z=j.peerDependencies.get(n.requested.identHash);if(typeof Z=="undefined")throw new Error("Assertion failed: Expected the peer dependency to be registered");return{pkg:T,peerDependency:Z}});if(g!==null){let k=f.every(({peerDependency:T})=>Wt.satisfiesWithPrereleases(g.version,T.range));o.reportInfo($.UNNAMED,`${P.prettyLocator(i,a)} provides ${P.prettyLocator(i,g)} with version ${P.prettyReference(i,(S=g.version)!=null?S:"<missing>")}, which ${k?"satisfies":"doesn't satisfy"} the following requirements:`)}else o.reportInfo($.UNNAMED,`${P.prettyLocator(i,a)} doesn't provide ${P.prettyIdent(i,n.requested)}, breaking the following requirements:`);o.reportSeparator();let h=Ae.mark(i),p=[];for(let{pkg:k,peerDependency:T}of ve.sortMap(f,Y=>P.stringifyLocator(Y.pkg))){let j=(g!==null?Wt.satisfiesWithPrereleases(g.version,T.range):!1)?h.Check:h.Cross;p.push({stringifiedLocator:P.stringifyLocator(k),prettyLocator:P.prettyLocator(i,k),prettyRange:P.prettyRange(i,T.range),mark:j})}let m=Math.max(...p.map(({stringifiedLocator:k})=>k.length)),y=Math.max(...p.map(({prettyRange:k})=>k.length));for(let{stringifiedLocator:k,prettyLocator:T,prettyRange:Y,mark:j}of ve.sortMap(p,({stringifiedLocator:Z})=>Z))o.reportInfo(null,`${T.padEnd(m+(T.length-k.length)," ")} \u2192 ${Y.padEnd(y," ")} ${j}`);p.length>1&&(o.reportSeparator(),o.reportInfo($.UNNAMED,`Note: these requirements start with ${P.prettyLocator(e.configuration,l)}`))})).exitCode()}Is();var bae=ge(ri()),hm=class extends Le{constructor(){super(...arguments);this.onlyIfNeeded=W.Boolean("--only-if-needed",!1,{description:"Only lock the Yarn version if it isn't already locked"});this.version=W.String()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins);if(e.get("yarnPath")&&this.onlyIfNeeded)return 0;let r=()=>{if(typeof Kr=="undefined")throw new Pe("The --install flag can only be used without explicit version specifier from the Yarn CLI");return`file://${process.argv[1]}`},i;if(this.version==="self")i=r();else if(this.version==="latest"||this.version==="berry"||this.version==="stable")i=`https://repo.yarnpkg.com/${await pm(e,"stable")}/packages/yarnpkg-cli/bin/yarn.js`;else if(this.version==="canary")i=`https://repo.yarnpkg.com/${await pm(e,"canary")}/packages/yarnpkg-cli/bin/yarn.js`;else if(this.version==="classic")i="https://nightly.yarnpkg.com/latest.js";else if(this.version.match(/^https?:/))i=this.version;else if(this.version.match(/^\.{0,2}[\\/]/)||H.isAbsolute(this.version))i=`file://${H.resolve(this.version)}`;else if(Wt.satisfiesWithPrereleases(this.version,">=2.0.0"))i=`https://repo.yarnpkg.com/${this.version}/packages/yarnpkg-cli/bin/yarn.js`;else if(Wt.satisfiesWithPrereleases(this.version,"^0.x || ^1.x"))i=`https://github.com/yarnpkg/yarn/releases/download/v${this.version}/yarn-${this.version}.js`;else if(Wt.validRange(this.version))i=`https://repo.yarnpkg.com/${await N8e(e,this.version)}/packages/yarnpkg-cli/bin/yarn.js`;else throw new Pe(`Invalid version descriptor "${this.version}"`);return(await Je.start({configuration:e,stdout:this.context.stdout,includeLogs:!this.context.quiet},async s=>{let o="file://",a;i.startsWith(o)?(s.reportInfo($.UNNAMED,`Downloading ${Ae.pretty(e,i,Di.URL)}`),a=await K.readFilePromise(H.toPortablePath(i.slice(o.length)))):(s.reportInfo($.UNNAMED,`Retrieving ${Ae.pretty(e,i,Di.PATH)}`),a=await ir.get(i,{configuration:e})),await WN(e,null,a,{report:s})})).exitCode()}};hm.paths=[["set","version"]],hm.usage=Re.Usage( Line truncated
${e}`)});let n=(g=t.projectCwd)!=null?g:t.startingCwd,s=x.resolve(n,".yarn/releases"),o=x.resolve(s,`yarn-${e}.cjs`),a=x.relative(t.startingCwd,o),l=x.relative(n,o),c=t.get("yarnPath"),u=c===null||c.startsWith(`${s}/`);if(i.reportInfo($.UNNAMED,`Saving the new release in ${Ae.pretty(t,a,"magenta")}`),await K.removePromise(x.dirname(o)),await K.mkdirPromise(x.dirname(o),{recursive:!0}),await K.writeFilePromise(o,r,{mode:493}),u){await we.updateConfiguration(n,{yarnPath:l});let f=await At.tryFind(n)||new At;f.packageManager=`yarn@${e&&ve.isTaggedYarnVersion(e)?e:await pm(t,"stable")}`;let h={};f.exportTo(h);let p=x.join(n,At.fileName),m=`${JSON.stringify(h,null,f.indent)}
`;await K.changeFilePromise(p,m,{automaticNewlines:!0})}}function vae(t){return $[bI(t)]}var L8e=/## (?<code>YN[0-9]{4}) - `(?<name>[A-Z_]+)`\n\n(?<details>(?:.(?!##))+)/gs;async function T8e(t){let r=`https://repo.yarnpkg.com/${ve.isTaggedYarnVersion(Kr)?Kr:await pm(t,"canary")}/packages/gatsby/content/advanced/error-codes.md`,i=await ir.get(r,{configuration:t});return new Map(Array.from(i.toString().matchAll(L8e),({groups:n})=>{if(!n)throw new Error("Assertion failed: Expected the match to have been successful");let s=vae(n.code);if(n.name!==s)throw new Error(`Assertion failed: Invalid error code data: Expected "${n.name}" to be named "${s}"`);return[n.code,n.details]}))}var dm=class extends Le{constructor(){super(...arguments);this.code=W.String({required:!1,validator:hp(fp(),[pp(/^YN[0-9]{4}$/)])});this.json=W.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"})}async execute(){let e=await we.find(this.context.cwd,this.context.plugins);if(typeof this.code!="undefined"){let r=vae(this.code),i=Ae.pretty(e,r,Ae.Type.CODE),n=this.cli.format().header(`${this.code} - ${i}`),o=(await T8e(e)).get(this.code),a=typeof o!="undefined"?Ae.jsonOrPretty(this.json,e,Ae.tuple(Ae.Type.MARKDOWN,{text:o,format:this.cli.format(),paragraphs:!0})):`This error code does not have a description.
You can help us by editing this page on GitHub \u{1F642}:
${Ae.jsonOrPretty(this.json,e,Ae.tuple(Ae.Type.URL,"https://github.com/yarnpkg/berry/blob/master/packages/gatsby/content/advanced/error-codes.md"))}
`;this.json?this.context.stdout.write(`${JSON.stringify({code:this.code,name:r,details:a})}
`):this.context.stdout.write(`${n}
${a}
`)}else{let r={children:ve.mapAndFilter(Object.entries($),([i,n])=>Number.isNaN(Number(i))?ve.mapAndFilter.skip:{label:qA(Number(i)),value:Ae.tuple(Ae.Type.CODE,n)})};As.emitTree(r,{configuration:e,stdout:this.context.stdout,json:this.json})}}};dm.paths=[["explain"]],dm.usage=Re.Usage({description:"explain an error code",details:`
When the code argument is specified, this command prints its name and its details.
When used without arguments, this command lists all error codes and their names.
`,examples:[["Explain an error code","$0 explain YN0006"],["List all error codes","$0 explain"]]});var Sae=dm;var kae=ge(rs()),Cm=class extends Le{constructor(){super(...arguments);this.all=W.Boolean("-A,--all",!1,{description:"Print versions of a package from the whole project"});this.recursive=W.Boolean("-R,--recursive",!1,{description:"Print information for all packages, including transitive dependencies"});this.extra=W.Array("-X,--extra",[],{description:"An array of requests of extra data provided by plugins"});this.cache=W.Boolean("--cache",!1,{description:"Print information about the cache entry of a package (path, size, checksum)"});this.dependents=W.Boolean("--dependents",!1,{description:"Print all dependents for each matching package"});this.manifest=W.Boolean("--manifest",!1,{description:"Print data obtained by looking at the package archive (license, homepage, ...)"});this.nameOnly=W.Boolean("--name-only",!1,{description:"Only print the name for the matching packages"});this.virtuals=W.Boolean("--virtuals",!1,{description:"Print each instance of the virtual packages"});this.json=W.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.patterns=W.Rest()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await ze.find(e,this.context.cwd),n=await Nt.find(e);if(!i&&!this.all)throw new ht(r.cwd,this.context.cwd);await r.restoreInstallState();let s=new Set(this.extra);this.cache&&s.add("cache"),this.dependents&&s.add("dependents"),this.manifest&&s.add("manifest");let o=(k,{recursive:T})=>{let Y=k.anchoredLocator.locatorHash,j=new Map,Z=[Y];for(;Z.length>0;){let J=Z.shift();if(j.has(J))continue;let re=r.storedPackages.get(J);if(typeof re=="undefined")throw new Error("Assertion failed: Expected the package to be registered");if(j.set(J,re),P.isVirtualLocator(re)&&Z.push(P.devirtualizeLocator(re).locatorHash),!(!T&&J!==Y))for(let ee of re.dependencies.values()){let A=r.storedResolutions.get(ee.descriptorHash);if(typeof A=="undefined")throw new Error("Assertion failed: Expected the resolution to be registered");Z.push(A)}}return j.values()},a=({recursive:k})=>{let T=new Map;for(let Y of r.workspaces)for(let j of o(Y,{recursive:k}))T.set(j.locatorHash,j);return T.values()},l=({all:k,recursive:T})=>k&&T?r.storedPackages.values():k?a({recursive:T}):o(i,{recursive:T}),c=({all:k,recursive:T})=>{let Y=l({all:k,recursive:T}),j=this.patterns.map(re=>{let ee=P.parseLocator(re),A=kae.default.makeRe(P.stringifyIdent(ee)),oe=P.isVirtualLocator(ee),le=oe?P.devirtualizeLocator(ee):ee;return X=>{let O=P.stringifyIdent(X);if(!A.test(O))return!1;if(ee.reference==="unknown")return!0;let L=P.isVirtualLocator(X),pe=L?P.devirtualizeLocator(X):X;return!(oe&&L&&ee.reference!==X.reference||le.reference!==pe.reference)}}),Z=ve.sortMap([...Y],re=>P.stringifyLocator(re));return{selection:Z.filter(re=>j.length===0||j.some(ee=>ee(re))),sortedLookup:Z}},{selection:u,sortedLookup:g}=c({all:this.all,recursive:this.recursive});if(u.length===0)throw new Pe("No package matched your request");let f=new Map;if(this.dependents)for(let k of g)for(let T of k.dependencies.values()){let Y=r.storedResolutions.get(T.descriptorHash);if(typeof Y=="undefined")throw new Error("Assertion failed: Expected the resolution to be registered");ve.getArrayWithDefault(f,Y).push(k)}let h=new Map;for(let k of g){if(!P.isVirtualLocator(k))continue;let T=P.devirtualizeLocator(k);ve.getArrayWithDefault(h,T.locatorHash).push(k)}let p={},m={children:p},y=e.makeFetcher(),b={project:r,fetcher:y,cache:n,checksums:r.storedChecksums,report:new pi,cacheOptions:{skipIntegrityCheck:!0},skipIntegrityCheck:!0},S=[async(k,T,Y)=>{var J,re;if(!T.has("manifest"))return;let j=await y.fetch(k,b),Z;try{Z=await At.find(j.prefixPath,{baseFs:j.packageFs})}finally{(J=j.releaseFs)==null||J.call(j)}Y("Manifest",{License:Ae.tuple(Ae.Type.NO_HINT,Z.license),Homepage:Ae.tuple(Ae.Type.URL,(re=Z.raw.homepage)!=null?re:null)})},async(k,T,Y)=>{var A;if(!T.has("cache"))return;let j={mockedPackages:r.disabledLocators,unstablePackages:r.conditionalLocators},Z=(A=r.storedChecksums.get(k.locatorHash))!=null?A:null,J=n.getLocatorPath(k,Z,j),re;if(J!==null)try{re=K.statSync(J)}catch{}let ee=typeof re!="undefined"?[re.size,Ae.Type.SIZE]:void 0;Y("Cache",{Checksum:Ae.tuple(Ae.Type.NO_HINT,Z),Path:Ae.tuple(Ae.Type.PATH,J),Size:ee})}];for(let k of u){let T=P.isVirtualLocator(k);if(!this.virtuals&&T)continue;let Y={},j={value:[k,Ae.Type.LOCATOR],children:Y};if(p[P.stringifyLocator(k)]=j,this.nameOnly){delete j.children;continue}let Z=h.get(k.locatorHash);typeof Z!="undefined"&&(Y.Instances={label:"Instances",value:Ae.tuple(Ae.Type.NUMBER,Z.length)}),Y.Version={label:"Version",value:Ae.tuple(Ae.Type.NO_HINT,k.version)};let J=(ee,A)=>{let oe={};if(Y[ee]=oe,Array.isArray(A))oe.children=A.map(le=>({value:le}));else{let le={};oe.children=le;for(let[X,O]of Object.entries(A))typeof O!="undefined"&&(le[X]={label:X,value:O})}};if(!T){for(let Line truncated
This command sets up your project if needed. The installation is split into four different steps that each have their own characteristics:
- **Resolution:** First the package manager will resolve your dependencies. The exact way a dependency version is privileged over another isn't standardized outside of the regular semver guarantees. If a package doesn't resolve to what you would expect, check that all dependencies are correctly declared (also check our website for more information: ).
- **Fetch:** Then we download all the dependencies if needed, and make sure that they're all stored within our cache (check the value of \`cacheFolder\` in \`yarn config\` to see where the cache files are stored).
- **Link:** Then we send the dependency tree information to internal plugins tasked with writing them on the disk in some form (for example by generating the .pnp.cjs file you might know).
- **Build:** Once the dependency tree has been written on the disk, the package manager will now be free to run the build scripts for all packages that might need it, in a topological order compatible with the way they depend on one another. See https://yarnpkg.com/advanced/lifecycle-scripts for detail.
Note that running this command is not part of the recommended workflow. Yarn supports zero-installs, which means that as long as you store your cache and your .pnp.cjs file inside your repository, everything will work without requiring any install right after cloning your repository or switching branches.
If the \`--immutable\` option is set (defaults to true on CI), Yarn will abort with an error exit code if the lockfile was to be modified (other paths can be added using the \`immutablePatterns\` configuration setting). For backward compatibility we offer an alias under the name of \`--frozen-lockfile\`, but it will be removed in a later release.
If the \`--immutable-cache\` option is set, Yarn will abort with an error exit code if the cache folder was to be modified (either because files would be added, or because they'd be removed).
If the \`--check-cache\` option is set, Yarn will always refetch the packages and will ensure that their checksum matches what's 1/ described in the lockfile 2/ inside the existing cache files (if present). This is recommended as part of your CI workflow if you're both following the Zero-Installs model and accepting PRs from third-parties, as they'd otherwise have the ability to alter the checked-in packages before submitting them.
If the \`--inline-builds\` option is set, Yarn will verbosely print the output of the build steps of your dependencies (instead of writing them into individual files). This is likely useful mostly for debug purposes only when using Docker-like environments.
If the \`--mode=<mode>\` option is set, Yarn will change which artifacts are generated. The modes currently supported are:
- \`skip-build\` will not run the build scripts at all. Note that this is different from setting \`enableScripts\` to false because the later will disable build scripts, and thus affect the content of the artifacts generated on disk, whereas the former will just disable the build step - but not the scripts themselves, which just won't run.
- \`update-lockfile\` will skip the link step altogether, and only fetch packages that are missing from the lockfile (or that have no associated checksums). This mode is typically used by tools like Renovate or Dependabot to keep a lockfile up-to-date without incurring the full install cost.
`,examples:[["Install the project","$0 install"],["Validate a project when using Zero-Installs","$0 install --immutable --immutable-cache"],["Validate a project when using Zero-Installs (slightly safer if you accept external PRs)","$0 install --immutable --immutable-cache --check-cache"]]});var Pae=mm,M8e="|||||||",K8e=">>>>>>>",U8e="=======",Dae="<<<<<<<";async function O8e(t,e){if(!t.projectCwd)return!1;let r=x.join(t.projectCwd,t.get("lockfileFilename"));if(!await K.existsPromise(r))return!1;let i=await K.readFilePromise(r,"utf8");if(!i.includes(Dae))return!1;if(e)throw new ct($.AUTOMERGE_IMMUTABLE,"Cannot autofix a lockfile when running an immutable install");let[n,s]=H8e(i),o,a;try{o=Qi(n),a=Qi(s)}catch(c){throw new ct($.AUTOMERGE_FAILED_TO_PARSE,"The individual variants of the lockfile failed to parse")}let l=N(N({},o),a);for(let[c,u]of Object.entries(l))typeof u=="string"&&delete l[c];return await K.changeFilePromise(r,La(l),{automaticNewlines:!0}),!0}function H8e(t){let e=[[],[]],r=t.split(/\r?\n/g),i=!1;for(;r.length>0;){let n=r.shift();if(typeof n=="undefined")throw new Error("Assertion failed: Some lines should remain");if(n.startsWith(Dae)){for(;r.length>0;){let s=r.shift();if(typeof s=="undefined")throw new Error("Assertion failed: Some lines should remain");if(s===U8e){i=!1;break}else if(i||s.startsWith(M8e)){i=!0;continue}else e[0].push(s)}for(;r.length>0;){let s=r.shift();if(typeof s=="undefined")throw new Error("Assertion failed: Some lines should remain");if(s.startsWith(K8e))break;e[1].push(s)}}else e[0].push(n),e[1].push(n)}return[e[0].join(`
`),e[1].join(`
`)]}var Em=class extends Le{constructor(){super(...arguments);this.all=W.Boolean("-A,--all",!1,{description:"Link all workspaces belonging to the target project to the current one"});this.private=W.Boolean("-p,--private",!1,{description:"Also link private workspaces belonging to the target project to the current one"});this.relative=W.Boolean("-r,--relative",!1,{description:"Link workspaces using relative paths instead of absolute paths"});this.destination=W.String()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await ze.find(e,this.context.cwd),n=await Nt.find(e);if(!i)throw new ht(r.cwd,this.context.cwd);await r.restoreInstallState({restoreResolutions:!1});let s=x.resolve(this.context.cwd,H.toPortablePath(this.destination)),o=await we.find(s,this.context.plugins,{useRc:!1,strict:!1}),{project:a,workspace:l}=await ze.find(o,s);if(r.cwd===a.cwd)throw new Pe("Invalid destination; Can't link the project to itself");if(!l)throw new ht(a.cwd,s);let c=r.topLevelWorkspace,u=[];if(this.all){for(let f of a.workspaces)f.manifest.name&&(!f.manifest.private||this.private)&&u.push(f);if(u.length===0)throw new Pe("No workspace found to be linked in the target project")}else{if(!l.manifest.name)throw new Pe("The target workspace doesn't have a name and thus cannot be linked");if(l.manifest.private&&!this.private)throw new Pe("The target workspace is marked private - use the --private flag to link it anyway");u.push(l)}for(let f of u){let h=P.stringifyIdent(f.locator),p=this.relative?x.relative(r.cwd,f.cwd):f.cwd;c.manifest.resolutions.push({pattern:{descriptor:{fullName:h}},reference:`portal:${p}`})}return(await Je.start({configuration:e,stdout:this.context.stdout},async f=>{await r.install({cache:n,report:f})})).exitCode()}};Em.paths=[["link"]],Em.usage=Re.Usage({description:"connect the local project to another one",details:"\n This command will set a new `resolutions` field in the project-level manifest and point it to the workspace at the specified location (even if part of another project).\n ",examples:[["Register a remote workspace for use in the current project","$0 link ~/ts-loader"],["Register all workspaces from a remote project for use in the current project","$0 link ~/jest --all"]]});var Rae=Em;var Im=class extends Le{constructor(){super(...arguments);this.args=W.Proxy()}async execute(){return this.cli.run(["exec","node",...this.args])}};Im.paths=[["node"]],Im.usage=Re.Usage({description:"run node with the hook already setup",details:`
This command simply runs Node. It also makes sure to call it in a way that's compatible with the current project (for example, on PnP projects the environment will be setup in such a way that PnP will be correctly injected into the environment).
The Node process will use the exact same version of Node as the one used to run Yarn itself, which might be a good way to ensure that your commands always use a consistent Node version.
`,examples:[["Run a Node script","$0 node ./my-script.js"]]});var Fae=Im;var Gae=ge(require("os"));var Lae=ge(require("os"));var G8e="https://raw.githubusercontent.com/yarnpkg/berry/master/plugins.yml";async function wu(t){let e=await ir.get(G8e,{configuration:t});return Qi(e.toString())}var ym=class extends Le{constructor(){super(...arguments);this.json=W.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"})}async execute(){let e=await we.find(this.context.cwd,this.context.plugins);return(await Je.start({configuration:e,json:this.json,stdout:this.context.stdout},async i=>{let n=await wu(e);for(let s of Object.entries(n)){let[l,o]=s,a=o,{experimental:c}=a,u=Tr(a,["experimental"]);let g=l;c&&(g+=" [experimental]"),i.reportJson(N({name:l,experimental:c},u)),i.reportInfo(null,g)}})).exitCode()}};ym.paths=[["plugin","list"]],ym.usage=Re.Usage({category:"Plugin-related commands",description:"list the available official plugins",details:"\n This command prints the plugins available directly from the Yarn repository. Only those plugins can be referenced by name in `yarn plugin import`.\n ",examples:[["List the official plugins","$0 plugin list"]]});var Nae=ym;var j8e=/^[0-9]+$/;function Tae(t){return j8e.test(t)?`pull/${t}/head`:t}var Y8e=({repository:t,branch:e},r)=>[["git","init",H.fromPortablePath(r)],["git","remote","add","origin",t],["git","fetch","origin","--depth=1",Tae(e)],["git","reset","--hard","FETCH_HEAD"]],q8e=({branch:t})=>[["git","fetch","origin","--depth=1",Tae(t),"--force"],["git","reset","--hard","FETCH_HEAD"],["git","clean","-dfx"]],J8e=({plugins:t,noMinify:e},r)=>[["yarn","build:cli",...new Array().concat(...t.map(i=>["--plugin",x.resolve(r,i)])),...e?["--no-minify"]:[],"|"]],wm=class extends Le{constructor(){super(...arguments);this.installPath=W.String("--path",{description:"The path where the repository should be cloned to"});this.repository=W.String("--repository","https://github.com/yarnpkg/berry.git",{description:"The repository that should be cloned"});this.branch=W.String("--branch","master",{description:"The branch of the repository that should be cloned"});this.plugins=W.Array("--plugin",[],{description:"An array of additional plugins that should be included in the bundle"});this.noMinify=W.Boolean("--no-minify",!1,{description:"Build a bundle for development (debugging) - non-minified and non-mangled"});this.force=W.Boolean("-f,--force",!1,{description:"Always clone the repository instead of trying to fetch the latest commits"});this.skipPlugins=W.Boolean("--skip-plugins",!1,{description:"Skip updating the contrib plugins"})}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),{project:r}=await ze.find(e,this.context.cwd),i=typeof this.installPath!="undefined"?x.resolve(this.context.cwd,H.toPortablePath(this.installPath)):x.resolve(H.toPortablePath((0,Lae.tmpdir)()),"yarnpkg-sources",Dn.makeHash(this.repository).slice(0,6));return(await Je.start({configuration:e,stdout:this.context.stdout},async s=>{await _N(this,{configuration:e,report:s,target:i}),s.reportSeparator(),s.reportInfo($.UNNAMED,"Building a fresh bundle"),s.reportSeparator(),await Bm(J8e(this,i),{configuration:e,context:this.context,target:i}),s.reportSeparator();let o=x.resolve(i,"packages/yarnpkg-cli/bundles/yarn.js"),a=await K.readFilePromise(o);await WN(e,"sources",a,{report:s}),this.skipPlugins||await W8e(this,{project:r,report:s,target:i})})).exitCode()}};wm.paths=[["set","version","from","sources"]],wm.usage=Re.Usage({description:"build Yarn from master",details:`
This command will clone the Yarn repository into a temporary folder, then build it. The resulting bundle will then be copied into the local project.
By default, it also updates all contrib plugins to the same commit the bundle is built from. This behavior can be disabled by using the \`--skip-plugins\` flag.
`,examples:[["Build Yarn from master","$0 set version from sources"]]});var Oae=wm;async function Bm(t,{configuration:e,context:r,target:i}){for(let[n,...s]of t){let o=s[s.length-1]==="|";if(o&&s.pop(),o)await Fr.pipevp(n,s,{cwd:i,stdin:r.stdin,stdout:r.stdout,stderr:r.stderr,strict:!0});else{r.stdout.write(`${Ae.pretty(e,` $ ${[n,...s].join(" ")}`,"grey")}
`);try{await Fr.execvp(n,s,{cwd:i,strict:!0})}catch(a){throw r.stdout.write(a.stdout||a.stack),a}}}}async function _N(t,{configuration:e,report:r,target:i}){let n=!1;if(!t.force&&K.existsSync(x.join(i,".git"))){r.reportInfo($.UNNAMED,"Fetching the latest commits"),r.reportSeparator();try{await Bm(q8e(t),{configuration:e,context:t.context,target:i}),n=!0}catch(s){r.reportSeparator(),r.reportWarning($.UNNAMED,"Repository update failed; we'll try to regenerate it")}}n||(r.reportInfo($.UNNAMED,"Cloning the remote repository"),r.reportSeparator(),await K.removePromise(i),await K.mkdirPromise(i,{recursive:!0}),await Bm(Y8e(t,i),{configuration:e,context:t.context,target:i}))}async function W8e(t,{project:e,report:r,target:i}){let n=await wu(e.configuration),s=new Set(Object.keys(n));for(let o of e.configuration.plugins.keys())!s.has(o)||await zN(o,t,{project:e,report:r,target:i})}var Mae=ge(ri()),Kae=ge(require("url")),Uae=ge(require("vm"));var bm=class extends Le{constructor(){super(...arguments);this.name=W.String()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins);return(await Je.start({configuration:e,stdout:this.context.stdout},async i=>{let{project:n}=await ze.find(e,this.context.cwd),s,o;if(this.name.match(/^\.{0,2}[\\/]/)||H.isAbsolute(this.name)){let a=x.resolve(this.context.cwd,H.toPortablePath(this.name));i.reportInfo($.UNNAMED,`Reading ${Ae.pretty(e,a,Ae.Type.PATH)}`),s=x.relative(n.cwd,a),o=await K.readFilePromise(a)}else{let a;if(this.name.match(/^https?:/)){try{new Kae.URL(this.name)}catch{throw new ct($.INVALID_PLUGIN_REFERENCE,`Plugin specifier "${this.name}" is neither a plugin name nor a valid url`)}s=this.name,a=this.name}else{let l=P.parseLocator(this.name.replace(/^((@yarnpkg\/)?plugin-)?/,"@yarnpkg/plugin-"));if(l.reference!=="unknown"&&!Mae.default.valid(l.reference))throw new ct($.UNNAMED,"Official plugins only accept strict version references. Use an explicit URL if you wish to download them from another location.");let c=P.stringifyIdent(l),u=await wu(e);if(!Object.prototype.hasOwnProperty.call(u,c))throw new ct($.PLUGIN_NAME_NOT_FOUND,`Couldn't find a plugin named "${c}" on the remote registry. Note that only the plugins referenced on our website (https://github.com/yarnpkg/berry/blob/master/plugins.yml) can be referenced by their name; any other plugin will have to be referenced through its public url (for example https://github.com/yarnpkg/berry/raw/master/packages/plugin-typescript/bin/%40yarnpkg/plugin-typescript.js).`);s=c,a=u[c].url,l.reference!=="unknown"?a=a.replace(/\/master\//,`/${c}/${l.reference}/`):Kr!==null&&(a=a.replace(/\/master\//,`/@yarnpkg/cli/${Kr}/`))}i.reportInfo($.UNNAMED,`Downloading ${Ae.pretty(e,a,"green")}`),o=await ir.get(a,{configuration:e})}await VN(s,o,{project:n,report:i})})).exitCode()}};bm.paths=[["plugin","import"]],bm.usage=Re.Usage({category:"Plugin-related commands",description:"download a plugin",details:`
This command downloads the specified plugin from its remote location and updates the configuration to reference it in further CLI invocations.
Three types of plugin references are accepted:
- If the plugin is stored within the Yarn repository, it can be referenced by name.
- Third-party plugins can be referenced directly through their public urls.
- Local plugins can be referenced by their path on the disk.
Plugins cannot be downloaded from the npm registry, and aren't allowed to have dependencies (they need to be bundled into a single file, possibly thanks to the \`@yarnpkg/builder\` package).
`,examples:[['Download and activate the "@yarnpkg/plugin-exec" plugin',"$0 plugin import @yarnpkg/plugin-exec"],['Download and activate the "@yarnpkg/plugin-exec" plugin (shorthand)',"$0 plugin import exec"],["Download and activate a community plugin","$0 plugin import https://example.org/path/to/plugin.js"],["Activate a local plugin","$0 plugin import ./path/to/plugin.js"]]});var Hae=bm;async function VN(t,e,{project:r,report:i}){let{configuration:n}=r,s={},o={exports:s};(0,Uae.runInNewContext)(e.toString(),{module:o,exports:s});let a=o.exports.name,l=`.yarn/plugins/${a}.cjs`,c=x.resolve(r.cwd,l);i.reportInfo($.UNNAMED,`Saving the new plugin in ${Ae.pretty(n,l,"magenta")}`),await K.mkdirPromise(x.dirname(c),{recursive:!0}),await K.writeFilePromise(c,e);let u={path:l,spec:t};await we.updateConfiguration(r.cwd,g=>{let f=[],h=!1;for(let p of g.plugins||[]){let m=typeof p!="string"?p.path:p,y=x.resolve(r.cwd,H.toPortablePath(m)),{name:b}=ve.dynamicRequire(y);b!==a?f.push(p):(f.push(u),h=!0)}return h||f.push(u),ie(N({},g),{plugins:f})})}var z8e=({pluginName:t,noMinify:e},r)=>[["yarn",`build:${t}`,...e?["--no-minify"]:[],"|"]],Qm=class extends Le{constructor(){super(...arguments);this.installPath=W.String("--path",{description:"The path where the repository should be cloned to"});this.repository=W.String("--repository","https://github.com/yarnpkg/berry.git",{description:"The repository that should be cloned"});this.branch=W.String("--branch","master",{description:"The branch of the repository that should be cloned"});this.noMinify=W.Boolean("--no-minify",!1,{description:"Build a plugin for development (debugging) - non-minified and non-mangled"});this.force=W.Boolean("-f,--force",!1,{description:"Always clone the repository instead of trying to fetch the latest commits"});this.name=W.String()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),r=typeof this.installPath!="undefined"?x.resolve(this.context.cwd,H.toPortablePath(this.installPath)):x.resolve(H.toPortablePath((0,Gae.tmpdir)()),"yarnpkg-sources",Dn.makeHash(this.repository).slice(0,6));return(await Je.start({configuration:e,stdout:this.context.stdout},async n=>{let{project:s}=await ze.find(e,this.context.cwd),o=P.parseIdent(this.name.replace(/^((@yarnpkg\/)?plugin-)?/,"@yarnpkg/plugin-")),a=P.stringifyIdent(o),l=await wu(e);if(!Object.prototype.hasOwnProperty.call(l,a))throw new ct($.PLUGIN_NAME_NOT_FOUND,`Couldn't find a plugin named "${a}" on the remote registry. Note that only the plugins referenced on our website (https://github.com/yarnpkg/berry/blob/master/plugins.yml) can be built and imported from sources.`);let c=a;await _N(this,{configuration:e,report:n,target:r}),await zN(c,this,{project:s,report:n,target:r})})).exitCode()}};Qm.paths=[["plugin","import","from","sources"]],Qm.usage=Re.Usage({category:"Plugin-related commands",description:"build a plugin from sources",details:`
This command clones the Yarn repository into a temporary folder, builds the specified contrib plugin and updates the configuration to reference it in further CLI invocations.
The plugins can be referenced by their short name if sourced from the official Yarn repository.
`,examples:[['Build and activate the "@yarnpkg/plugin-exec" plugin',"$0 plugin import from sources @yarnpkg/plugin-exec"],['Build and activate the "@yarnpkg/plugin-exec" plugin (shorthand)',"$0 plugin import from sources exec"]]});var jae=Qm;async function zN(t,{context:e,noMinify:r},{project:i,report:n,target:s}){let o=t.replace(/@yarnpkg\//,""),{configuration:a}=i;n.reportSeparator(),n.reportInfo($.UNNAMED,`Building a fresh ${o}`),n.reportSeparator(),await Bm(z8e({pluginName:o,noMinify:r},s),{configuration:a,context:e,target:s}),n.reportSeparator();let l=x.resolve(s,`packages/${o}/bundles/${t}.js`),c=await K.readFilePromise(l);await VN(t,c,{project:i,report:n})}var vm=class extends Le{constructor(){super(...arguments);this.name=W.String()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),{project:r}=await ze.find(e,this.context.cwd);return(await Je.start({configuration:e,stdout:this.context.stdout},async n=>{let s=this.name,o=P.parseIdent(s);if(!e.plugins.has(s))throw new Pe(`${P.prettyIdent(e,o)} isn't referenced by the current configuration`);let a=`.yarn/plugins/${s}.cjs`,l=x.resolve(r.cwd,a);K.existsSync(l)&&(n.reportInfo($.UNNAMED,`Removing ${Ae.pretty(e,a,Ae.Type.PATH)}...`),await K.removePromise(l)),n.reportInfo($.UNNAMED,"Updating the configuration..."),await we.updateConfiguration(r.cwd,c=>{if(!Array.isArray(c.plugins))return c;let u=c.plugins.filter(g=>g.path!==a);return c.plugins.length===u.length?c:ie(N({},c),{plugins:u})})})).exitCode()}};vm.paths=[["plugin","remove"]],vm.usage=Re.Usage({category:"Plugin-related commands",description:"remove a plugin",details:`
This command deletes the specified plugin from the .yarn/plugins folder and removes it from the configuration.
**Note:** The plugins have to be referenced by their name property, which can be obtained using the \`yarn plugin runtime\` command. Shorthands are not allowed.
`,examples:[["Remove a plugin imported from the Yarn repository","$0 plugin remove @yarnpkg/plugin-typescript"],["Remove a plugin imported from a local file","$0 plugin remove my-local-plugin"]]});var Yae=vm;var Sm=class extends Le{constructor(){super(...arguments);this.json=W.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"})}async execute(){let e=await we.find(this.context.cwd,this.context.plugins);return(await Je.start({configuration:e,json:this.json,stdout:this.context.stdout},async i=>{for(let n of e.plugins.keys()){let s=this.context.plugins.plugins.has(n),o=n;s&&(o+=" [builtin]"),i.reportJson({name:n,builtin:s}),i.reportInfo(null,`${o}`)}})).exitCode()}};Sm.paths=[["plugin","runtime"]],Sm.usage=Re.Usage({category:"Plugin-related commands",description:"list the active plugins",details:`
This command prints the currently active plugins. Will be displayed both builtin plugins and external plugins.
`,examples:[["List the currently active plugins","$0 plugin runtime"]]});var qae=Sm;var km=class extends Le{constructor(){super(...arguments);this.idents=W.Rest()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await ze.find(e,this.context.cwd),n=await Nt.find(e);if(!i)throw new ht(r.cwd,this.context.cwd);let s=new Set;for(let a of this.idents)s.add(P.parseIdent(a).identHash);if(await r.restoreInstallState({restoreResolutions:!1}),await r.resolveEverything({cache:n,report:new pi}),s.size>0)for(let a of r.storedPackages.values())s.has(a.identHash)&&r.storedBuildState.delete(a.locatorHash);else r.storedBuildState.clear();return(await Je.start({configuration:e,stdout:this.context.stdout,includeLogs:!this.context.quiet},async a=>{await r.install({cache:n,report:a})})).exitCode()}};km.paths=[["rebuild"]],km.usage=Re.Usage({description:"rebuild the project's native packages",details:`
This command will automatically cause Yarn to forget about previous compilations of the given packages and to run them again.
Note that while Yarn forgets the compilation, the previous artifacts aren't erased from the filesystem and may affect the next builds (in good or bad). To avoid this, you may remove the .yarn/unplugged folder, or any other relevant location where packages might have been stored (Yarn may offer a way to do that automatically in the future).
By default all packages will be rebuilt, but you can filter the list by specifying the names of the packages you want to clear from memory.
`,examples:[["Rebuild all packages","$0 rebuild"],["Rebuild fsevents only","$0 rebuild fsevents"]]});var Jae=km;var XN=ge(rs());Is();var xm=class extends Le{constructor(){super(...arguments);this.all=W.Boolean("-A,--all",!1,{description:"Apply the operation to all workspaces from the current project"});this.mode=W.String("--mode",{description:"Change what artifacts installs generate",validator:nn(di)});this.patterns=W.Rest()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await ze.find(e,this.context.cwd),n=await Nt.find(e);if(!i)throw new ht(r.cwd,this.context.cwd);await r.restoreInstallState({restoreResolutions:!1});let s=this.all?r.workspaces:[i],o=[Hr.REGULAR,Hr.DEVELOPMENT,Hr.PEER],a=[],l=!1,c=[];for(let h of this.patterns){let p=!1,m=P.parseIdent(h);for(let y of s){let b=[...y.manifest.peerDependenciesMeta.keys()];for(let S of(0,XN.default)(b,h))y.manifest.peerDependenciesMeta.delete(S),l=!0,p=!0;for(let S of o){let k=y.manifest.getForScope(S),T=[...k.values()].map(Y=>P.stringifyIdent(Y));for(let Y of(0,XN.default)(T,P.stringifyIdent(m))){let{identHash:j}=P.parseIdent(Y),Z=k.get(j);if(typeof Z=="undefined")throw new Error("Assertion failed: Expected the descriptor to be registered");y.manifest[S].delete(j),c.push([y,S,Z]),l=!0,p=!0}}}p||a.push(h)}let u=a.length>1?"Patterns":"Pattern",g=a.length>1?"don't":"doesn't",f=this.all?"any":"this";if(a.length>0)throw new Pe(`${u} ${Ae.prettyList(e,a,Di.CODE)} ${g} match any packages referenced by ${f} workspace`);return l?(await e.triggerMultipleHooks(p=>p.afterWorkspaceDependencyRemoval,c),(await Je.start({configuration:e,stdout:this.context.stdout},async p=>{await r.install({cache:n,report:p,mode:this.mode})})).exitCode()):0}};xm.paths=[["remove"]],xm.usage=Re.Usage({description:"remove dependencies from the project",details:`
This command will remove the packages matching the specified patterns from the current workspace.
If the \`--mode=<mode>\` option is set, Yarn will change which artifacts are generated. The modes currently supported are:
- \`skip-build\` will not run the build scripts at all. Note that this is different from setting \`enableScripts\` to false because the later will disable build scripts, and thus affect the content of the artifacts generated on disk, whereas the former will just disable the build step - but not the scripts themselves, which just won't run.
- \`update-lockfile\` will skip the link step altogether, and only fetch packages that are missing from the lockfile (or that have no associated checksums). This mode is typically used by tools like Renovate or Dependabot to keep a lockfile up-to-date without incurring the full install cost.
This command accepts glob patterns as arguments (if valid Idents and supported by [micromatch](https://github.com/micromatch/micromatch)). Make sure to escape the patterns, to prevent your own shell from trying to expand them.
`,examples:[["Remove a dependency from the current project","$0 remove lodash"],["Remove a dependency from all workspaces at once","$0 remove lodash --all"],["Remove all dependencies starting with `eslint-`","$0 remove 'eslint-*'"],["Remove all dependencies with the `@babel` scope","$0 remove '@babel/*'"],["Remove all dependencies matching `react-dom` or `react-helmet`","$0 remove 'react-{dom,helmet}'"]]});var Wae=xm;var zae=ge(require("util")),Ab=class extends Le{async execute(){let e=await we.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await ze.find(e,this.context.cwd);if(!i)throw new ht(r.cwd,this.context.cwd);return(await Je.start({configuration:e,stdout:this.context.stdout},async s=>{let o=i.manifest.scripts,a=ve.sortMap(o.keys(),u=>u),l={breakLength:Infinity,colors:e.get("enableColors"),maxArrayLength:2},c=a.reduce((u,g)=>Math.max(u,g.length),0);for(let[u,g]of o.entries())s.reportInfo(null,`${u.padEnd(c," ")} ${(0,zae.inspect)(g,l)}`)})).exitCode()}};Ab.paths=[["run"]];var _ae=Ab;var Pm=class extends Le{constructor(){super(...arguments);this.inspect=W.String("--inspect",!1,{tolerateBoolean:!0,description:"Forwarded to the underlying Node process when executing a binary"});this.inspectBrk=W.String("--inspect-brk",!1,{tolerateBoolean:!0,description:"Forwarded to the underlying Node process when executing a binary"});this.topLevel=W.Boolean("-T,--top-level",!1,{description:"Check the root workspace for scripts and/or binaries instead of the current one"});this.binariesOnly=W.Boolean("-B,--binaries-only",!1,{description:"Ignore any user defined scripts and only check for binaries"});this.silent=W.Boolean("--silent",{hidden:!0});this.scriptName=W.String();this.args=W.Proxy()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),{project:r,workspace:i,locator:n}=await ze.find(e,this.context.cwd);await r.restoreInstallState();let s=this.topLevel?r.topLevelWorkspace.anchoredLocator:n;if(!this.binariesOnly&&await Zt.hasPackageScript(s,this.scriptName,{project:r}))return await Zt.executePackageScript(s,this.scriptName,this.args,{project:r,stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr});let o=await Zt.getPackageAccessibleBinaries(s,{project:r});if(o.get(this.scriptName)){let l=[];return this.inspect&&(typeof this.inspect=="string"?l.push(`--inspect=${this.inspect}`):l.push("--inspect")),this.inspectBrk&&(typeof this.inspectBrk=="string"?l.push(`--inspect-brk=${this.inspectBrk}`):l.push("--inspect-brk")),await Zt.executePackageAccessibleBinary(s,this.scriptName,this.args,{cwd:this.context.cwd,project:r,stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr,nodeArgs:l,packageAccessibleBinaries:o})}if(!this.topLevel&&!this.binariesOnly&&i&&this.scriptName.includes(":")){let c=(await Promise.all(r.workspaces.map(async u=>u.manifest.scripts.has(this.scriptName)?u:null))).filter(u=>u!==null);if(c.length===1)return await Zt.executeWorkspaceScript(c[0],this.scriptName,this.args,{stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr})}if(this.topLevel)throw this.scriptName==="node-gyp"?new Pe(`Couldn't find a script name "${this.scriptName}" in the top-level (used by ${P.prettyLocator(e,n)}). This typically happens because some package depends on "node-gyp" to build itself, but didn't list it in their dependencies. To fix that, please run "yarn add node-gyp" into your top-level workspace. You also can open an issue on the repository of the specified package to suggest them to use an optional peer dependency.`):new Pe(`Couldn't find a script name "${this.scriptName}" in the top-level (used by ${P.prettyLocator(e,n)}).`);{if(this.scriptName==="global")throw new Pe("The 'yarn global' commands have been removed in 2.x - consider using 'yarn dlx' or a third-party plugin instead");let l=[this.scriptName].concat(this.args);for(let[c,u]of Tf)for(let g of u)if(l.length>=g.length&&JSON.stringify(l.slice(0,g.length))===JSON.stringify(g))throw new Pe(`Couldn't find a script named "${this.scriptName}", but a matching command can be found in the ${c} plugin. You can install it with "yarn plugin import ${c}".`);throw new Pe(`Couldn't find a script named "${this.scriptName}".`)}}};Pm.paths=[["run"]],Pm.usage=Re.Usage({description:"run a script defined in the package.json",details:`
This command will run a tool. The exact tool that will be executed will depend on the current state of your workspace:
- If the \`scripts\` field from your local package.json contains a matching script name, its definition will get executed.
- Otherwise, if one of the local workspace's dependencies exposes a binary with a matching name, this binary will get executed.
- Otherwise, if the specified name contains a colon character and if one of the workspaces in the project contains exactly one script with a matching name, then this script will get executed.
Whatever happens, the cwd of the spawned process will be the workspace that declares the script (which makes it possible to call commands cross-workspaces using the third syntax).
`,examples:[["Run the tests from the local workspace","$0 run test"],['Same thing, but without the "run" keyword',"$0 test"],["Inspect Webpack while running","$0 run --inspect-brk webpack"]]});var Vae=Pm;var Dm=class extends Le{constructor(){super(...arguments);this.save=W.Boolean("-s,--save",!1,{description:"Persist the resolution inside the top-level manifest"});this.descriptor=W.String();this.resolution=W.String()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await ze.find(e,this.context.cwd),n=await Nt.find(e);if(await r.restoreInstallState({restoreResolutions:!1}),!i)throw new ht(r.cwd,this.context.cwd);let s=P.parseDescriptor(this.descriptor,!0),o=P.makeDescriptor(s,this.resolution);return r.storedDescriptors.set(s.descriptorHash,s),r.storedDescriptors.set(o.descriptorHash,o),r.resolutionAliases.set(s.descriptorHash,o.descriptorHash),(await Je.start({configuration:e,stdout:this.context.stdout},async l=>{await r.install({cache:n,report:l})})).exitCode()}};Dm.paths=[["set","resolution"]],Dm.usage=Re.Usage({description:"enforce a package resolution",details:'\n This command updates the resolution table so that `descriptor` is resolved by `resolution`.\n\n Note that by default this command only affect the current resolution table - meaning that this "manual override" will disappear if you remove the lockfile, or if the package disappear from the table. If you wish to make the enforced resolution persist whatever happens, add the `-s,--save` flag which will also edit the `resolutions` field from your top-level manifest.\n\n Note that no attempt is made at validating that `resolution` is a valid resolution entry for `descriptor`.\n ',examples:[["Force all instances of lodash@npm:^1.2.3 to resolve to 1.5.0","$0 set resolution lodash@npm:^1.2.3 1.5.0"]]});var Xae=Dm;var Zae=ge(rs()),Rm=class extends Le{constructor(){super(...arguments);this.all=W.Boolean("-A,--all",!1,{description:"Unlink all workspaces belonging to the target project from the current one"});this.leadingArguments=W.Rest()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await ze.find(e,this.context.cwd),n=await Nt.find(e);if(!i)throw new ht(r.cwd,this.context.cwd);let s=r.topLevelWorkspace,o=new Set;if(this.leadingArguments.length===0&&this.all)for(let{pattern:l,reference:c}of s.manifest.resolutions)c.startsWith("portal:")&&o.add(l.descriptor.fullName);if(this.leadingArguments.length>0)for(let l of this.leadingArguments){let c=x.resolve(this.context.cwd,H.toPortablePath(l));if(ve.isPathLike(l)){let u=await we.find(c,this.context.plugins,{useRc:!1,strict:!1}),{project:g,workspace:f}=await ze.find(u,c);if(!f)throw new ht(g.cwd,c);if(this.all){for(let h of g.workspaces)h.manifest.name&&o.add(P.stringifyIdent(h.locator));if(o.size===0)throw new Pe("No workspace found to be unlinked in the target project")}else{if(!f.manifest.name)throw new Pe("The target workspace doesn't have a name and thus cannot be unlinked");o.add(P.stringifyIdent(f.locator))}}else{let u=[...s.manifest.resolutions.map(({pattern:g})=>g.descriptor.fullName)];for(let g of(0,Zae.default)(u,l))o.add(g)}}return s.manifest.resolutions=s.manifest.resolutions.filter(({pattern:l})=>!o.has(l.descriptor.fullName)),(await Je.start({configuration:e,stdout:this.context.stdout},async l=>{await r.install({cache:n,report:l})})).exitCode()}};Rm.paths=[["unlink"]],Rm.usage=Re.Usage({description:"disconnect the local project from another one",details:`
This command will remove any resolutions in the project-level manifest that would have been added via a yarn link with similar arguments.
`,examples:[["Unregister a remote workspace in the current project","$0 unlink ~/ts-loader"],["Unregister all workspaces from a remote project in the current project","$0 unlink ~/jest --all"],["Unregister all previously linked workspaces","$0 unlink --all"],["Unregister all workspaces matching a glob","$0 unlink '@babel/*' 'pkg-{a,b}'"]]});var $ae=Rm;var eAe=ge(em()),ZN=ge(rs());Is();var rh=class extends Le{constructor(){super(...arguments);this.interactive=W.Boolean("-i,--interactive",{description:"Offer various choices, depending on the detected upgrade paths"});this.exact=W.Boolean("-E,--exact",!1,{description:"Don't use any semver modifier on the resolved range"});this.tilde=W.Boolean("-T,--tilde",!1,{description:"Use the `~` semver modifier on the resolved range"});this.caret=W.Boolean("-C,--caret",!1,{description:"Use the `^` semver modifier on the resolved range"});this.recursive=W.Boolean("-R,--recursive",!1,{description:"Resolve again ALL resolutions for those packages"});this.mode=W.String("--mode",{description:"Change what artifacts installs generate",validator:nn(di)});this.patterns=W.Rest()}async execute(){return this.recursive?await this.executeUpRecursive():await this.executeUpClassic()}async executeUpRecursive(){let e=await we.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await ze.find(e,this.context.cwd),n=await Nt.find(e);if(!i)throw new ht(r.cwd,this.context.cwd);await r.restoreInstallState({restoreResolutions:!1});let s=[...r.storedDescriptors.values()],o=s.map(u=>P.stringifyIdent(u)),a=new Set;for(let u of this.patterns){if(P.parseDescriptor(u).range!=="unknown")throw new Pe("Ranges aren't allowed when using --recursive");for(let g of(0,ZN.default)(o,u)){let f=P.parseIdent(g);a.add(f.identHash)}}let l=s.filter(u=>a.has(u.identHash));for(let u of l)r.storedDescriptors.delete(u.descriptorHash),r.storedResolutions.delete(u.descriptorHash);return(await Je.start({configuration:e,stdout:this.context.stdout},async u=>{await r.install({cache:n,report:u})})).exitCode()}async executeUpClassic(){var m;let e=await we.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await ze.find(e,this.context.cwd),n=await Nt.find(e);if(!i)throw new ht(r.cwd,this.context.cwd);await r.restoreInstallState({restoreResolutions:!1});let s=(m=this.interactive)!=null?m:e.get("preferInteractive"),o=tm(this,r),a=s?[Vr.KEEP,Vr.REUSE,Vr.PROJECT,Vr.LATEST]:[Vr.PROJECT,Vr.LATEST],l=[],c=[];for(let y of this.patterns){let b=!1,S=P.parseDescriptor(y);for(let k of r.workspaces)for(let T of[Hr.REGULAR,Hr.DEVELOPMENT]){let j=[...k.manifest.getForScope(T).values()].map(Z=>P.stringifyIdent(Z));for(let Z of(0,ZN.default)(j,P.stringifyIdent(S))){let J=P.parseIdent(Z),re=k.manifest[T].get(J.identHash);if(typeof re=="undefined")throw new Error("Assertion failed: Expected the descriptor to be registered");let ee=P.makeDescriptor(J,S.range);l.push(Promise.resolve().then(async()=>[k,T,re,await rm(ee,{project:r,workspace:k,cache:n,target:T,modifier:o,strategies:a})])),b=!0}}b||c.push(y)}if(c.length>1)throw new Pe(`Patterns ${Ae.prettyList(e,c,Di.CODE)} don't match any packages referenced by any workspace`);if(c.length>0)throw new Pe(`Pattern ${Ae.prettyList(e,c,Di.CODE)} doesn't match any packages referenced by any workspace`);let u=await Promise.all(l),g=await gA.start({configuration:e,stdout:this.context.stdout,suggestInstall:!1},async y=>{for(let[,,b,{suggestions:S,rejections:k}]of u){let T=S.filter(Y=>Y.descriptor!==null);if(T.length===0){let[Y]=k;if(typeof Y=="undefined")throw new Error("Assertion failed: Expected an error to have been set");let j=this.cli.error(Y);r.configuration.get("enableNetwork")?y.reportError($.CANT_SUGGEST_RESOLUTIONS,`${P.prettyDescriptor(e,b)} can't be resolved to a satisfying range
${j}`):y.reportError($.CANT_SUGGEST_RESOLUTIONS,`${P.prettyDescriptor(e,b)} can't be resolved to a satisfying range (note: network resolution has been disabled)
${j}`)}else T.length>1&&!s&&y.reportError($.CANT_SUGGEST_RESOLUTIONS,`${P.prettyDescriptor(e,b)} has multiple possible upgrade strategies; use -i to disambiguate manually`)}});if(g.hasErrors())return g.exitCode();let f=!1,h=[];for(let[y,b,,{suggestions:S}]of u){let k,T=S.filter(J=>J.descriptor!==null),Y=T[0].descriptor,j=T.every(J=>P.areDescriptorsEqual(J.descriptor,Y));T.length===1||j?k=Y:(f=!0,{answer:k}=await(0,eAe.prompt)({type:"select",name:"answer",message:`Which range to you want to use in ${P.prettyWorkspace(e,y)} \u276F ${b}?`,choices:S.map(({descriptor:J,name:re,reason:ee})=>J?{name:re,hint:ee,descriptor:J}:{name:re,hint:ee,disabled:!0}),onCancel:()=>process.exit(130),result(J){return this.find(J,"descriptor")},stdin:this.context.stdin,stdout:this.context.stdout}));let Z=y.manifest[b].get(k.identHash);if(typeof Z=="undefined")throw new Error("Assertion failed: This descriptor should have a matching entry");if(Z.descriptorHash!==k.descriptorHash)y.manifest[b].set(k.identHash,k),h.push([y,b,Z,k]);else{let J=e.makeResolver(),re={project:r,resolver:J},ee=J.bindDescriptor(Z,y.anchoredLocator,re);r.forgetResolution(ee)}}return await e.triggerMultipleHooks(y=>y.afterWorkspaceDependencyReplacement,h),f&&this.context.stdout.write(`
`),(await Je.start({configuration:e,stdout:this.context.stdout},async y=>{await r.install({cache:n,report:y,mode:this.mode})})).exitCode()}};rh.paths=[["up"]],rh.usage=Re.Usage({description:"upgrade dependencies across the project",details:"\n This command upgrades the packages matching the list of specified patterns to their latest available version across the whole project (regardless of whether they're part of `dependencies` or `devDependencies` - `peerDependencies` won't be affected). This is a project-wide command: all workspaces will be upgraded in the process.\n\n If `-R,--recursive` is set the command will change behavior and no other switch will be allowed. When operating under this mode `yarn up` will force all ranges matching the selected packages to be resolved again (often to the highest available versions) before being stored in the lockfile. It however won't touch your manifests anymore, so depending on your needs you might want to run both `yarn up` and `yarn up -R` to cover all bases.\n\n If `-i,--interactive` is set (or if the `preferInteractive` settings is toggled on) the command will offer various choices, depending on the detected upgrade paths. Some upgrades require this flag in order to resolve ambiguities.\n\n The, `-C,--caret`, `-E,--exact` and `-T,--tilde` options have the same meaning as in the `add` command (they change the modifier used when the range is missing or a tag, and are ignored when the range is explicitly set).\n\n If the `--mode=<mode>` option is set, Yarn will change which artifacts are generated. The modes currently supported are:\n\n - `skip-build` will not run the build scripts at all. Note that this is different from setting `enableScripts` to false because the later will disable build scripts, and thus affect the content of the artifacts generated on disk, whereas the former will just disable the build step - but not the scripts themselves, which just won't run.\n\n - `update-lockfile` will skip the link step altogether, and only fetch packages that are missing from the lockfile (or that have no associated checksums). This mode is typically used by tools like Renovate or Dependabot to keep a lockfile up-to-date without incurring the full install cost.\n\n Generally you can see `yarn up` as a counterpart to what was `yarn upgrade --latest` in Yarn 1 (ie it ignores the ranges previously listed in your manifests), but unlike `yarn upgrade` which only upgraded dependencies in the current workspace, `yarn up` will upgrade all workspaces at the same time.\n\n This command accepts glob patterns as arguments (if valid Descriptors and supported by [micromatch](https://github.com/micromatch/micromatch)). Make sure to escape the patterns, to prevent your own shell from trying to expand them.\n\n **Note:** The ranges have to be static, only the package scopes and names can contain glob patterns.\n ",examples:[["Upgrade all instances of lodash to the latest release","$0 up lodash"],["Upgrade all instances of lodash to the latest release, but ask confirmation for each","$0 up lodash -i"],["Upgrade all instances of lodash to 1.2.3","$0 up lodash@1.2.3"],["Upgrade all instances of packages with the `@babel` scope to the latest release","$0 up '@babel/*'"],["Upgrade all instances of packages containing the word `jest` to the latest release","$0 up '*jest*'"],["Upgrade all instances of packages with the `@babel` scope to 7.0.0","$0 up '@babel/*@7.0.0'"]]}),rh.schema=[gv("recursive",mc.Forbids,["interactive","exact","tilde","caret"],{ignore:[void 0,!1]})];var tAe=rh;var Fm=class extends Le{constructor(){super(...arguments);this.recursive=W.Boolean("-R,--recursive",!1,{description:"List, for each workspace, what are all the paths that lead to the dependency"});this.json=W.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.peers=W.Boolean("--peers",!1,{description:"Also print the peer dependencies that match the specified name"});this.package=W.String()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await ze.find(e,this.context.cwd);if(!i)throw new ht(r.cwd,this.context.cwd);await r.restoreInstallState();let n=P.parseIdent(this.package).identHash,s=this.recursive?V8e(r,n,{configuration:e,peers:this.peers}):_8e(r,n,{configuration:e,peers:this.peers});As.emitTree(s,{configuration:e,stdout:this.context.stdout,json:this.json,separators:1})}};Fm.paths=[["why"]],Fm.usage=Re.Usage({description:"display the reason why a package is needed",details:`
This command prints the exact reasons why a package appears in the dependency tree.
If \`-R,--recursive\` is set, the listing will go in depth and will list, for each workspaces, what are all the paths that lead to the dependency. Note that the display is somewhat optimized in that it will not print the package listing twice for a single package, so if you see a leaf named "Foo" when looking for "Bar", it means that "Foo" already got printed higher in the tree.
`,examples:[["Explain why lodash is used in your project","$0 why lodash"]]});var rAe=Fm;function _8e(t,e,{configuration:r,peers:i}){let n=ve.sortMap(t.storedPackages.values(),a=>P.stringifyLocator(a)),s={},o={children:s};for(let a of n){let l={},c=null;for(let u of a.dependencies.values()){if(!i&&a.peerDependencies.has(u.identHash))continue;let g=t.storedResolutions.get(u.descriptorHash);if(!g)throw new Error("Assertion failed: The resolution should have been registered");let f=t.storedPackages.get(g);if(!f)throw new Error("Assertion failed: The package should have been registered");if(f.identHash!==e)continue;if(c===null){let p=P.stringifyLocator(a);s[p]={value:[a,Ae.Type.LOCATOR],children:l}}let h=P.stringifyLocator(f);l[h]={value:[{descriptor:u,locator:f},Ae.Type.DEPENDENT]}}}return o}function V8e(t,e,{configuration:r,peers:i}){let n=ve.sortMap(t.workspaces,f=>P.stringifyLocator(f.anchoredLocator)),s=new Set,o=new Set,a=f=>{if(s.has(f.locatorHash))return o.has(f.locatorHash);if(s.add(f.locatorHash),f.identHash===e)return o.add(f.locatorHash),!0;let h=!1;f.identHash===e&&(h=!0);for(let p of f.dependencies.values()){if(!i&&f.peerDependencies.has(p.identHash))continue;let m=t.storedResolutions.get(p.descriptorHash);if(!m)throw new Error("Assertion failed: The resolution should have been registered");let y=t.storedPackages.get(m);if(!y)throw new Error("Assertion failed: The package should have been registered");a(y)&&(h=!0)}return h&&o.add(f.locatorHash),h};for(let f of n){let h=t.storedPackages.get(f.anchoredLocator.locatorHash);if(!h)throw new Error("Assertion failed: The package should have been registered");a(h)}let l=new Set,c={},u={children:c},g=(f,h,p)=>{if(!o.has(f.locatorHash))return;let m=p!==null?Ae.tuple(Ae.Type.DEPENDENT,{locator:f,descriptor:p}):Ae.tuple(Ae.Type.LOCATOR,f),y={},b={value:m,children:y},S=P.stringifyLocator(f);if(h[S]=b,!l.has(f.locatorHash)&&(l.add(f.locatorHash),!(p!==null&&t.tryWorkspaceByLocator(f))))for(let k of f.dependencies.values()){if(!i&&f.peerDependencies.has(k.identHash))continue;let T=t.storedResolutions.get(k.descriptorHash);if(!T)throw new Error("Assertion failed: The resolution should have been registered");let Y=t.storedPackages.get(T);if(!Y)throw new Error("Assertion failed: The package should have been registered");g(Y,y,k)}};for(let f of n){let h=t.storedPackages.get(f.anchoredLocator.locatorHash);if(!h)throw new Error("Assertion failed: The package should have been registered");g(h,c,null)}return u}var cL={};ft(cL,{default:()=>C4e,gitUtils:()=>Bu});var Bu={};ft(Bu,{TreeishProtocols:()=>On,clone:()=>aL,fetchBase:()=>BAe,fetchChangedFiles:()=>bAe,fetchChangedWorkspaces:()=>p4e,fetchRoot:()=>wAe,isGitUrl:()=>nh,lsRemote:()=>yAe,normalizeLocator:()=>nL,normalizeRepoUrl:()=>Nm,resolveUrl:()=>oL,splitRepoUrl:()=>Lm});var rL=ge(CAe()),mAe=ge(rB()),ih=ge(require("querystring")),iL=ge(ri()),EAe=ge(require("url"));function IAe(){return ie(N({},process.env),{GIT_SSH_COMMAND:process.env.GIT_SSH_COMMAND||`${process.env.GIT_SSH||"ssh"} -o BatchMode=yes`})}var h4e=[/^ssh:/,/^git(?:\+[^:]+)?:/,/^(?:git\+)?https?:[^#]+\/[^#]+(?:\.git)(?:#.*)?$/,/^git@[^#]+\/[^#]+\.git(?:#.*)?$/,/^(?:github:|https:\/\/github\.com\/)?(?!\.{1,2}\/)([a-zA-Z._0-9-]+)\/(?!\.{1,2}(?:#|$))([a-zA-Z._0-9-]+?)(?:\.git)?(?:#.*)?$/,/^https:\/\/github\.com\/(?!\.{1,2}\/)([a-zA-Z0-9._-]+)\/(?!\.{1,2}(?:#|$))([a-zA-Z0-9._-]+?)\/tarball\/(.+)?$/],On;(function(n){n.Commit="commit",n.Head="head",n.Tag="tag",n.Semver="semver"})(On||(On={}));function nh(t){return t?h4e.some(e=>!!t.match(e)):!1}function Lm(t){t=Nm(t);let e=t.indexOf("#");if(e===-1)return{repo:t,treeish:{protocol:On.Head,request:"HEAD"},extra:{}};let r=t.slice(0,e),i=t.slice(e+1);if(i.match(/^[a-z]+=/)){let n=ih.default.parse(i);for(let[l,c]of Object.entries(n))if(typeof c!="string")throw new Error(`Assertion failed: The ${l} parameter must be a literal string`);let s=Object.values(On).find(l=>Object.prototype.hasOwnProperty.call(n,l)),o,a;typeof s!="undefined"?(o=s,a=n[s]):(o=On.Head,a="HEAD");for(let l of Object.values(On))delete n[l];return{repo:r,treeish:{protocol:o,request:a},extra:n}}else{let n=i.indexOf(":"),s,o;return n===-1?(s=null,o=i):(s=i.slice(0,n),o=i.slice(n+1)),{repo:r,treeish:{protocol:s,request:o},extra:{}}}}function Nm(t,{git:e=!1}={}){var r;if(t=t.replace(/^git\+https:/,"https:"),t=t.replace(/^(?:github:|https:\/\/github\.com\/)?(?!\.{1,2}\/)([a-zA-Z0-9._-]+)\/(?!\.{1,2}(?:#|$))([a-zA-Z0-9._-]+?)(?:\.git)?(#.*)?$/,"https://github.com/$1/$2.git$3"),t=t.replace(/^https:\/\/github\.com\/(?!\.{1,2}\/)([a-zA-Z0-9._-]+)\/(?!\.{1,2}(?:#|$))([a-zA-Z0-9._-]+?)\/tarball\/(.+)?$/,"https://github.com/$1/$2.git#$3"),e){t=t.replace(/^git\+([^:]+):/,"$1:");let i;try{i=EAe.default.parse(t)}catch{i=null}i&&i.protocol==="ssh:"&&((r=i.path)==null?void 0:r.startsWith("/:"))&&(t=t.replace(/^ssh:\/\//,""))}return t}function nL(t){return P.makeLocator(t,Nm(t.reference))}async function yAe(t,e){let r=Nm(t,{git:!0});if(!ir.getNetworkSettings(`httpLine truncated
- ${a.join(`
- `)}?`)}return this.cli.run([this.commandName,...this.args],{cwd:o.cwd})}};Om.paths=[["workspace"]],Om.usage=Re.Usage({category:"Workspace-related commands",description:"run a command within the specified workspace",details:`
This command will run a given sub-command on a single workspace.
`,examples:[["Add a package to a single workspace","yarn workspace components add -D react"],["Run build script on a single workspace","yarn workspace components run build"]]});var vAe=Om;var m4e={configuration:{enableImmutableInstalls:{description:"If true (the default on CI), prevents the install command from modifying the lockfile",type:ye.BOOLEAN,default:SAe.isCI},defaultSemverRangePrefix:{description:"The default save prefix: '^', '~' or ''",type:ye.STRING,values:["^","~",""],default:ga.CARET}},commands:[Ose,Kse,eae,gae,Xae,Oae,Qae,QAe,mae,Eae,Iae,yae,Lse,Tse,fae,pae,wae,Bae,Sae,xae,Pae,Rae,$ae,Fae,jae,Hae,Yae,Nae,qae,Jae,Wae,_ae,Vae,tAe,rAe,vAe]},E4e=m4e;var pL={};ft(pL,{default:()=>y4e});var qe={optional:!0},kAe=[["@tailwindcss/aspect-ratio@<0.2.1",{peerDependencies:{tailwindcss:"^2.0.2"}}],["@tailwindcss/line-clamp@<0.2.1",{peerDependencies:{tailwindcss:"^2.0.2"}}],["@fullhuman/postcss-purgecss@3.1.3 || 3.1.3-alpha.0",{peerDependencies:{postcss:"^8.0.0"}}],["@samverschueren/stream-to-observable@<0.3.1",{peerDependenciesMeta:{rxjs:qe,zenObservable:qe}}],["any-observable@<0.5.1",{peerDependenciesMeta:{rxjs:qe,zenObservable:qe}}],["@pm2/agent@<1.0.4",{dependencies:{debug:"*"}}],["debug@<4.2.0",{peerDependenciesMeta:{["supports-color"]:qe}}],["got@<11",{dependencies:{["@types/responselike"]:"^1.0.0",["@types/keyv"]:"^3.1.1"}}],["cacheable-lookup@<4.1.2",{dependencies:{["@types/keyv"]:"^3.1.1"}}],["http-link-dataloader@*",{peerDependencies:{graphql:"^0.13.1 || ^14.0.0"}}],["typescript-language-server@*",{dependencies:{["vscode-jsonrpc"]:"^5.0.1",["vscode-languageserver-protocol"]:"^3.15.0"}}],["postcss-syntax@*",{peerDependenciesMeta:{["postcss-html"]:qe,["postcss-jsx"]:qe,["postcss-less"]:qe,["postcss-markdown"]:qe,["postcss-scss"]:qe}}],["jss-plugin-rule-value-function@<=10.1.1",{dependencies:{["tiny-warning"]:"^1.0.2"}}],["ink-select-input@<4.1.0",{peerDependencies:{react:"^16.8.2"}}],["license-webpack-plugin@<2.3.18",{peerDependenciesMeta:{webpack:qe}}],["snowpack@>=3.3.0",{dependencies:{["node-gyp"]:"^7.1.0"}}],["promise-inflight@*",{peerDependenciesMeta:{bluebird:qe}}],["reactcss@*",{peerDependencies:{react:"*"}}],["react-color@<=2.19.0",{peerDependencies:{react:"*"}}],["gatsby-plugin-i18n@*",{dependencies:{ramda:"^0.24.1"}}],["useragent@^2.0.0",{dependencies:{request:"^2.88.0",yamlparser:"0.0.x",semver:"5.5.x"}}],["@apollographql/apollo-tools@*",{peerDependencies:{graphql:"^14.2.1 || ^15.0.0"}}],["material-table@^2.0.0",{dependencies:{"@babel/runtime":"^7.11.2"}}],["@babel/parser@*",{dependencies:{"@babel/types":"^7.8.3"}}],["fork-ts-checker-webpack-plugin@<=6.3.4",{peerDependencies:{eslint:">= 6",typescript:">= 2.7",webpack:">= 4","vue-template-compiler":"*"},peerDependenciesMeta:{eslint:qe,"vue-template-compiler":qe}}],["rc-animate@<=3.1.1",{peerDependencies:{react:">=16.9.0","react-dom":">=16.9.0"}}],["react-bootstrap-table2-paginator@*",{dependencies:{classnames:"^2.2.6"}}],["react-draggable@<=4.4.3",{peerDependencies:{react:">= 16.3.0","react-dom":">= 16.3.0"}}],["apollo-upload-client@<14",{peerDependencies:{graphql:"14 - 15"}}],["react-instantsearch-core@<=6.7.0",{peerDependencies:{algoliasearch:">= 3.1 < 5"}}],["react-instantsearch-dom@<=6.7.0",{dependencies:{"react-fast-compare":"^3.0.0"}}],["ws@<7.2.1",{peerDependencies:{bufferutil:"^4.0.1","utf-8-validate":"^5.0.2"},peerDependenciesMeta:{bufferutil:qe,"utf-8-validate":qe}}],["react-portal@*",{peerDependencies:{"react-dom":"^15.0.0-0 || ^16.0.0-0 || ^17.0.0-0"}}],["react-scripts@<=4.0.1",{peerDependencies:{react:"*"}}],["testcafe@<=1.10.1",{dependencies:{"@babel/plugin-transform-for-of":"^7.12.1","@babel/runtime":"^7.12.5"}}],["testcafe-legacy-api@<=4.2.0",{dependencies:{"testcafe-hammerhead":"^17.0.1","read-file-relative":"^1.2.0"}}],["@google-cloud/firestore@<=4.9.3",{dependencies:{protobufjs:"^6.8.6"}}],["gatsby-source-apiserver@*",{dependencies:{["babel-polyfill"]:"^6.26.0"}}],["@webpack-cli/package-utils@<=1.0.1-alpha.4",{dependencies:{["cross-spawn"]:"^7.0.3"}}],["gatsby-remark-prismjs@<3.3.28",{dependencies:{lodash:"^4"}}],["gatsby-plugin-favicon@*",{peerDependencies:{webpack:"*"}}],["gatsby-plugin-sharp@<=4.6.0-next.3",{dependencies:{debug:"^4.3.1"}}],["gatsby-react-router-scroll@<=5.6.0-next.0",{dependencies:{["prop-types"]:"^15.7.2"}}],["@rebass/forms@*",{dependencies:{["@styled-system/should-forward-prop"]:"^5.0.0"},peerDependencies:{react:"^16.8.6"}}],["rebass@*",{peerDependencies:{react:"^16.8.6"}}],["@ant-design/react-slick@<=0.28.3",{peerDependencies:{react:">=16.0.0"}}],["mqtt@<4.2.7",{dependencies:{duplexify:"^4.1.1"}}],["vue-cli-plugin-vuetify@<=2.0.3",{dependencies:{semver:"^6.3.0"},peerDependenciesMeta:{"sass-loader":qe,"vuetify-loader":qe}}],["vue-cli-plugin-vuetify@<=2.0.4",{dependencies:{"null-loader":"^3.0.0"}}],["@vuetify/cli-plugin-utils@<=0.0.4",{dependencies:{semver:"^6.3.0"},peerDependenciesMeta:{"sass-loader":qe}}],["@vue/cli-plugin-typescript@<=5.0.0-alpha.0",{dependencies:{"babel-loader":"^8.1.0"}}],[" Line truncated
`),await K.writeFilePromise(x.join(r,"yarn.lock"),"");let i=x.join(r,".yarnrc.yml"),n=await we.findProjectCwd(this.context.cwd,Pt.lockfile),s=!(await we.find(this.context.cwd,null,{strict:!1})).get("enableGlobalCache"),o=n!==null?x.join(n,".yarnrc.yml"):null;o!==null&&K.existsSync(o)?(await K.copyFilePromise(o,i),await we.updateConfiguration(r,m=>{let y=ie(N({},m),{enableGlobalCache:s,enableTelemetry:!1});return Array.isArray(m.plugins)&&(y.plugins=m.plugins.map(b=>{let S=typeof b=="string"?b:b.path,k=H.isAbsolute(S)?S:H.resolve(H.fromPortablePath(n),S);return typeof b=="string"?k:{path:k,spec:b.spec}})),y})):await K.writeFilePromise(i,`enableGlobalCache: ${s}
enableTelemetry: false
`);let a=(p=this.packages)!=null?p:[this.command],l=P.parseDescriptor(this.command).name,c=await this.cli.run(["add","--",...a],{cwd:r,quiet:this.quiet});if(c!==0)return c;this.quiet||this.context.stdout.write(`
`);let u=await we.find(r,this.context.plugins),{project:g,workspace:f}=await ze.find(u,r);if(f===null)throw new ht(g.cwd,r);await g.restoreInstallState();let h=await Zt.getWorkspaceAccessibleBinaries(f);return h.has(l)===!1&&h.size===1&&typeof this.packages=="undefined"&&(l=Array.from(h)[0][0]),await Zt.executeWorkspaceAccessibleBinary(f,l,this.args,{packageAccessibleBinaries:h,cwd:this.context.cwd,stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr})})}};Mm.paths=[["dlx"]],Mm.usage=Re.Usage({description:"run a package in a temporary environment",details:"\n This command will install a package within a temporary environment, and run its binary script if it contains any. The binary will run within the current cwd.\n\n By default Yarn will download the package named `command`, but this can be changed through the use of the `-p,--package` flag which will instruct Yarn to still run the same command but from a different package.\n\n Using `yarn dlx` as a replacement of `yarn add` isn't recommended, as it makes your project non-deterministic (Yarn doesn't keep track of the packages installed through `dlx` - neither their name, nor their version).\n ",examples:[["Use create-react-app to create a new React app","yarn dlx create-react-app ./my-app"],["Install multiple packages for a single command",`yarn dlx -p typescript -p ts-node ts-node --transpile-only -e "console.log('hello!')"`]]});var NAe=Mm;var w4e={commands:[FAe,NAe]},B4e=w4e;var QL={};ft(QL,{default:()=>v4e,fileUtils:()=>CL});var sh=/^(?:[a-zA-Z]:[\\/]|\.{0,2}\/)/,Km=/^[^?]*\.(?:tar\.gz|tgz)(?:::.*)?$/,Xr="file:";var CL={};ft(CL,{makeArchiveFromLocator:()=>cb,makeBufferFromLocator:()=>IL,makeLocator:()=>EL,makeSpec:()=>LAe,parseSpec:()=>mL});function mL(t){let{params:e,selector:r}=P.parseRange(t),i=H.toPortablePath(r);return{parentLocator:e&&typeof e.locator=="string"?P.parseLocator(e.locator):null,path:i}}function LAe({parentLocator:t,path:e,folderHash:r,protocol:i}){let n=t!==null?{locator:P.stringifyLocator(t)}:{},s=typeof r!="undefined"?{hash:r}:{};return P.makeRange({protocol:i,source:e,selector:e,params:N(N({},s),n)})}function EL(t,{parentLocator:e,path:r,folderHash:i,protocol:n}){return P.makeLocator(t,LAe({parentLocator:e,path:r,folderHash:i,protocol:n}))}async function cb(t,{protocol:e,fetchOptions:r,inMemory:i=!1}){let{parentLocator:n,path:s}=P.parseFileStyleRange(t.reference,{protocol:e}),o=x.isAbsolute(s)?{packageFs:new _t(Ke.root),prefixPath:Ke.dot,localPath:Ke.root}:await r.fetcher.fetch(n,r),a=o.localPath?{packageFs:new _t(Ke.root),prefixPath:x.relative(Ke.root,o.localPath)}:o;o!==a&&o.releaseFs&&o.releaseFs();let l=a.packageFs,c=x.join(a.prefixPath,s);return await ve.releaseAfterUseAsync(async()=>await wi.makeArchiveFromDirectory(c,{baseFs:l,prefixPath:P.getIdentVendorPath(t),compressionLevel:r.project.configuration.get("compressionLevel"),inMemory:i}),a.releaseFs)}async function IL(t,{protocol:e,fetchOptions:r}){return(await cb(t,{protocol:e,fetchOptions:r,inMemory:!0})).getBufferAndClose()}var yL=class{supports(e,r){return!!e.reference.startsWith(Xr)}getLocalPath(e,r){let{parentLocator:i,path:n}=P.parseFileStyleRange(e.reference,{protocol:Xr});if(x.isAbsolute(n))return n;let s=r.fetcher.getLocalPath(i,r);return s===null?null:x.resolve(s,n)}async fetch(e,r){let i=r.checksums.get(e.locatorHash)||null,[n,s,o]=await r.cache.fetchPackageFromCache(e,i,N({onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${P.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the disk`),loader:()=>this.fetchFromDisk(e,r),skipIntegrityCheck:r.skipIntegrityCheck},r.cacheOptions));return{packageFs:n,releaseFs:s,prefixPath:P.getIdentVendorPath(e),localPath:this.getLocalPath(e,r),checksum:o}}async fetchFromDisk(e,r){return cb(e,{protocol:Xr,fetchOptions:r})}};var b4e=2,wL=class{supportsDescriptor(e,r){return e.range.match(sh)?!0:!!e.range.startsWith(Xr)}supportsLocator(e,r){return!!e.reference.startsWith(Xr)}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,i){return sh.test(e.range)&&(e=P.makeDescriptor(e,`${Xr}${e.range}`)),P.bindDescriptor(e,{locator:P.stringifyLocator(r)})}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){if(!i.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let{path:n,parentLocator:s}=mL(e.range);if(s===null)throw new Error("Assertion failed: The descriptor should have been bound");let o=await IL(P.makeLocator(e,P.makeRange({protocol:Xr,source:n,selector:n,params:{locator:P.stringifyLocator(s)}})),{protocol:Xr,fetchOptions:i.fetchOptions}),a=Dn.makeHash(`${b4e}`,o).slice(0,6);return[EL(e,{parentLocator:s,path:n,folderHash:a,protocol:Xr})]}async getSatisfying(e,r,i){return null}async resolve(e,r){if(!r.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let i=await r.fetchOptions.fetcher.fet Line truncated
`);let o=x.join(this.context.cwd,At.fileName);await K.changeFilePromise(o,`${JSON.stringify(s,null,2)}
`,{automaticNewlines:!0});let a=x.join(this.context.cwd,"README.md");if(K.existsSync(a)||await K.writeFilePromise(a,`# ${P.stringifyIdent(i.name)}
`),!r||r.cwd===this.context.cwd){let c=x.join(this.context.cwd,Pt.lockfile);K.existsSync(c)||await K.writeFilePromise(c,"");let g=[".yarn/*","!.yarn/patches","!.yarn/plugins","!.yarn/releases","!.yarn/sdks","!.yarn/versions","","# Swap the comments on the following lines if you don't wish to use zero-installs","# Documentation here: https://yarnpkg.com/features/zero-installs","!.yarn/cache","#.pnp.*"].map(y=>`${y}
`).join(""),f=x.join(this.context.cwd,".gitignore");K.existsSync(f)||await K.writeFilePromise(f,g);let h={["*"]:{endOfLine:"lf",insertFinalNewline:!0},["*.{js,json,yml}"]:{charset:"utf-8",indentStyle:"space",indentSize:2}};(0,gle.default)(h,e.get("initEditorConfig"));let p=`root = true
`;for(let[y,b]of Object.entries(h)){p+=`
[${y}]
`;for(let[S,k]of Object.entries(b))p+=`${S.replace(/[A-Z]/g,Y=>`_${Y.toLowerCase()}`)} = ${k}
`}let m=x.join(this.context.cwd,".editorconfig");K.existsSync(m)||await K.writeFilePromise(m,p),K.existsSync(x.join(this.context.cwd,".git"))||await Fr.execvp("git",["init"],{cwd:this.context.cwd})}}};Gm.paths=[["init"]],Gm.usage=Re.Usage({description:"create a new package",details:"\n This command will setup a new package in your local directory.\n\n If the `-p,--private` or `-w,--workspace` options are set, the package will be private by default.\n\n If the `-w,--workspace` option is set, the package will be configured to accept a set of workspaces in the `packages/` directory.\n\n If the `-i,--install` option is given a value, Yarn will first download it using `yarn set version` and only then forward the init call to the newly downloaded bundle. Without arguments, the downloaded bundle will be `latest`.\n\n The initial settings of the manifest can be changed by using the `initScope` and `initFields` configuration values. Additionally, Yarn will generate an EditorConfig file whose rules can be altered via `initEditorConfig`, and will initialize a Git repository in the current directory.\n ",examples:[["Create a new package in the local directory","yarn init"],["Create a new private package in the local directory","yarn init -p"],["Create a new package and store the Yarn release inside","yarn init -i=latest"],["Create a new private package and defines it as a workspace root","yarn init -w"]]});var fle=Gm;var Dze={configuration:{initScope:{description:"Scope used when creating packages via the init command",type:ye.STRING,default:null},initFields:{description:"Additional fields to set when creating packages via the init command",type:ye.MAP,valueDefinition:{description:"",type:ye.ANY}},initEditorConfig:{description:"Extra rules to define in the generator editorconfig",type:ye.MAP,valueDefinition:{description:"",type:ye.ANY}}},commands:[fle]},Rze=Dze;var KL={};ft(KL,{default:()=>Nze});var EA="portal:",IA="link:";var LL=class{supports(e,r){return!!e.reference.startsWith(EA)}getLocalPath(e,r){let{parentLocator:i,path:n}=P.parseFileStyleRange(e.reference,{protocol:EA});if(x.isAbsolute(n))return n;let s=r.fetcher.getLocalPath(i,r);return s===null?null:x.resolve(s,n)}async fetch(e,r){var c;let{parentLocator:i,path:n}=P.parseFileStyleRange(e.reference,{protocol:EA}),s=x.isAbsolute(n)?{packageFs:new _t(Ke.root),prefixPath:Ke.dot,localPath:Ke.root}:await r.fetcher.fetch(i,r),o=s.localPath?{packageFs:new _t(Ke.root),prefixPath:x.relative(Ke.root,s.localPath),localPath:Ke.root}:s;s!==o&&s.releaseFs&&s.releaseFs();let a=o.packageFs,l=x.resolve((c=o.localPath)!=null?c:o.packageFs.getRealPath(),o.prefixPath,n);return s.localPath?{packageFs:new _t(l,{baseFs:a}),releaseFs:o.releaseFs,prefixPath:Ke.dot,localPath:l}:{packageFs:new Ra(l,{baseFs:a}),releaseFs:o.releaseFs,prefixPath:Ke.dot}}};var TL=class{supportsDescriptor(e,r){return!!e.range.startsWith(EA)}supportsLocator(e,r){return!!e.reference.startsWith(EA)}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,i){return P.bindDescriptor(e,{locator:P.stringifyLocator(r)})}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){let n=e.range.slice(EA.length);return[P.makeLocator(e,`${EA}${H.toPortablePath(n)}`)]}async getSatisfying(e,r,i){return null}async resolve(e,r){if(!r.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let i=await r.fetchOptions.fetcher.fetch(e,r.fetchOptions),n=await ve.releaseAfterUseAsync(async()=>await At.find(i.prefixPath,{baseFs:i.packageFs}),i.releaseFs);return ie(N({},e),{version:n.version||"0.0.0",languageName:n.languageName||r.project.configuration.get("defaultLanguageName"),linkType:Qt.SOFT,conditions:n.getConditions(),dependencies:new Map([...n.dependencies]),peerDependencies:n.peerDependencies,dependenciesMeta:n.dependenciesMeta,peerDependenciesMeta:n.peerDependenciesMeta,bin:n.bin})}};var OL=class{supports(e,r){return!!e.reference.startsWith(IA)}getLocalPath(e,r){let{parentLocator:i,path:n}=P.parseFileStyleRange(e.reference,{protocol:IA});if(x.isAbsolute(n))return n;let s=r.fetcher.getLocalPath(i,r);return s===null?null:x.resolve(s,n)}async fetch(e,r){var c;let{parentLocator:i,path:n}=P.parseFileStyleRange(e.reference,{protocol:IA}),s=x.isAbsolute(n)?{packageFs:new _t(Ke.root),prefixPath:Ke.dot,localPath:Ke.root}:await r.fetcher.fetch(i,r),o=s.localPath?{packageFs:new _t(Ke.root),prefixPath:x.relative(Ke.root,s.localPath),localPath:Ke.root}:s;s!==o&&s.releaseFs&&s.releaseFs();let a=o.packageFs,l=x.resolve((c=o.localPath)!=null?c:o.packageFs.getRealPath(),o.prefixPath,n);return s.localPath?{packageFs:new _t(l,{baseFs:a}),releaseFs:o.releaseFs,prefixPath:Ke.dot,discardFromLookup:!0,localPath:l}:{packageFs:new Ra(l,{baseFs:a}),releaseFs:o.releaseFs,prefixPath:Ke.dot,discardFromLookup:!0}}};var ML=class{supportsDescriptor(e,r){return!!e.range.startsWith(IA)}supportsLocator(e,r){return!!e.reference.startsWith(IA)}shouldPersistResolution(e,r) Line truncated
${u}, next tree:
${jm(a)}`);let f=ple(a);if(f)throw new Error(`${f}, after hoisting finished:
${jm(a)}`)}return s.debugLevel>=2&&console.log(jm(a)),Tze(a)},Oze=t=>{let e=t[t.length-1],r=new Map,i=new Set,n=s=>{if(!i.has(s)){i.add(s);for(let o of s.hoistedDependencies.values())r.set(o.name,o);for(let o of s.dependencies.values())s.peerNames.has(o.name)||n(o)}};return n(e),r},Mze=t=>{let e=t[t.length-1],r=new Map,i=new Set,n=new Set,s=(o,a)=>{if(i.has(o))return;i.add(o);for(let c of o.hoistedDependencies.values())if(!a.has(c.name)){let u;for(let g of t)u=g.dependencies.get(c.name),u&&r.set(u.name,u)}let l=new Set;for(let c of o.dependencies.values())l.add(c.name);for(let c of o.dependencies.values())o.peerNames.has(c.name)||s(c,l)};return s(e,n),r},Cle=(t,e)=>{if(e.decoupled)return e;let{name:r,references:i,ident:n,locator:s,dependencies:o,originalDependencies:a,hoistedDependencies:l,peerNames:c,reasons:u,isHoistBorder:g,hoistPriority:f,dependencyKind:h,hoistedFrom:p,hoistedTo:m}=e,y={name:r,references:new Set(i),ident:n,locator:s,dependencies:new Map(o),originalDependencies:new Map(a),hoistedDependencies:new Map(l),peerNames:new Set(c),reasons:new Map(u),decoupled:!0,isHoistBorder:g,hoistPriority:f,dependencyKind:h,hoistedFrom:new Map(p),hoistedTo:new Map(m)},b=y.dependencies.get(r);return b&&b.ident==y.ident&&y.dependencies.set(r,y),t.dependencies.set(y.name,y),y},Kze=(t,e)=>{let r=new Map([[t.name,[t.ident]]]);for(let n of t.dependencies.values())t.peerNames.has(n.name)||r.set(n.name,[n.ident]);let i=Array.from(e.keys());i.sort((n,s)=>{let o=e.get(n),a=e.get(s);return a.hoistPriority!==o.hoistPriority?a.hoistPriority-o.hoistPriority:a.peerDependents.size!==o.peerDependents.size?a.peerDependents.size-o.peerDependents.size:a.dependents.size-o.dependents.size});for(let n of i){let s=n.substring(0,n.indexOf("@",1)),o=n.substring(s.length+1);if(!t.peerNames.has(s)){let a=r.get(s);a||(a=[],r.set(s,a)),a.indexOf(o)<0&&a.push(o)}}return r},GL=t=>{let e=new Set,r=(i,n=new Set)=>{if(!n.has(i)){n.add(i);for(let s of i.peerNames)if(!t.peerNames.has(s)){let o=t.dependencies.get(s);o&&!e.has(o)&&r(o,n)}e.add(i)}};for(let i of t.dependencies.values())t.peerNames.has(i.name)||r(i);return e},HL=(t,e,r,i,n,s=new Set)=>{let o=e[e.length-1];if(s.has(o))return{anotherRoundNeeded:!1,isGraphChanged:!1};s.add(o);let a=Hze(o),l=Kze(o,a),c=t==o?new Map:n.fastLookupPossible?Oze(e):Mze(e),u,g=!1,f=!1,h=new Map(Array.from(l.entries()).map(([m,y])=>[m,y[0]])),p=new Map;do{let m=Uze(t,e,r,c,h,l,i,p,n);m.isGraphChanged&&(f=!0),m.anotherRoundNeeded&&(g=!0),u=!1;for(let[y,b]of l)b.length>1&&!o.dependencies.has(y)&&(h.delete(y),b.shift(),h.set(y,b[0]),u=!0)}while(u);for(let m of o.dependencies.values())if(!o.peerNames.has(m.name)&&!r.has(m.locator)){r.add(m.locator);let y=HL(t,[...e,m],r,p,n);y.isGraphChanged&&(f=!0),y.anotherRoundNeeded&&(g=!0),r.delete(m.locator)}return{anotherRoundNeeded:g,isGraphChanged:f}},Gze=t=>{for(let[e,r]of t.dependencies)if(!t.peerNames.has(e)&&r.ident!==t.ident)return!0;return!1},jze=(t,e,r,i,n,s,o,a,{outputReason:l,fastLookupPossible:c})=>{let u,g=null,f=new Set;l&&(u=`${Array.from(e).map(y=>Ni(y)).join("\u2192")}`);let h=r[r.length-1],m=!(i.ident===h.ident);if(l&&!m&&(g="- self-reference"),m&&(m=i.dependencyKind!==1,l&&!m&&(g="- workspace")),m&&i.dependencyKind===2&&(m=!Gze(i),l&&!m&&(g="- external soft link with unhoisted dependencies")),m&&(m=h.dependencyKind!==1||h.hoistedFrom.has(i.name)||e.size===1,l&&!m&&(g=h.reasons.get(i.name))),m&&(m=!t.peerNames.has(i.name),l&&!m&&(g=`- cannot shadow peer: ${Ni(t.originalDependencies.get(i.name).locator)} at ${u}`)),m){let y=!1,b=n.get(i.name);if(y=!b||b.ident===i.ident,l&&!y&&(g=`- filled by: ${Ni(b.locator)} at ${u}`),y)for(let S=r.length-1;S>=1;S--){let T=r[S].dependencies.get(i.name);if(T&&T.ident!==i.ident){y=!1;let Y=a.get(h);Y||(Y=new Set,a.set(h,Y)),Y.add(i.name),l&&(g=`- filled by ${Ni(T.locator)} at ${r.slice(0,S).map(j=>Ni(j.locator)).join("\u2192")}`);break}}m=y}if(m&&(m=s.get(i.name)===i.ident,l&&!m&&(g=`- filled by: ${Ni(o.get(i.name)[0])} at ${u}`)),m){let y=!0,b=new Set(i.peerNames);for(let S=r.length-1;S>=1;S--){let k=r[S];for(let T of b){if(k.peerNames.has(T)&&k.originalDependencies.has(T))continue;let Y=k.dependencies.get(T);Y&&t.dependencies.get(T)!==Y&&(S===r.length-1?f.add(Y):(f=null,y=!1,l&&(g=`- peer dependency ${Ni(Y.locator)} from parent ${Ni(k.locator)} was not hoisted to ${u}`))),b.delete(T)}if(!y)break}m=y}if(m&&!c)for(let y of i.hoistedDependencies.values()){let b=n.get(y.name)||t.dependencies.get(y.name);if(!b||y.ident!==b.ident){m=!1,l&&(g=`- previously hoisted dependency mismatch, needed: ${Ni(y.locator)}, available: ${Ni(b==null?void 0:b.locator)}`);break}}return f!==null&&f.size>0?{isHoistable:2,dependsOn:f,reason:g}:{isHoistable:m?0:1,reason:g}},ub=t=>`${t.name}@${t.locator}`,Uze=(t,e,r,i,n,s,o,a,l)=>{let c=e[e.length-1],u=new Set,g=!1,f=!1,h=(b,S,k,T,Y)=>{if(u.has(T))return;let j=[...S,ub(T)],Z=[...k,ub(T)],J=new Map,re=new Map;for(let X of GL(T)){let O=jze(c,r,[c,...b,T],X,i,n,s,a,{outputReason:l.debugLevel>=2,fastLookup Line truncated
${jm(t)}`)}let le=GL(T);for(let X of le)if(ee.has(X)){let O=re.get(X);if((n.get(X.name)===X.ident||!T.reasons.has(X.name))&&O.isHoistable!==0&&T.reasons.set(X.name,O.reason),!X.isHoistBorder&&Z.indexOf(ub(X))<0){u.add(T);let pe=Cle(T,X);h([...b,T],j,Z,pe,m),u.delete(T)}}},p,m=new Set(GL(c)),y=Array.from(e).map(b=>ub(b));do{p=m,m=new Set;for(let b of p){if(b.locator===c.locator||b.isHoistBorder)continue;let S=Cle(c,b);h([],Array.from(r),y,S,m)}}while(m.size>0);return{anotherRoundNeeded:g,isGraphChanged:f}},ple=t=>{let e=[],r=new Set,i=new Set,n=(s,o,a)=>{if(r.has(s)||(r.add(s),i.has(s)))return;let l=new Map(o);for(let c of s.dependencies.values())s.peerNames.has(c.name)||l.set(c.name,c);for(let c of s.originalDependencies.values()){let u=l.get(c.name),g=()=>`${Array.from(i).concat([s]).map(f=>Ni(f.locator)).join("\u2192")}`;if(s.peerNames.has(c.name)){let f=o.get(c.name);(f!==u||!f||f.ident!==c.ident)&&e.push(`${g()} - broken peer promise: expected ${c.ident} but found ${f&&f.ident}`)}else{let f=a.hoistedFrom.get(s.name),h=s.hoistedTo.get(c.name),p=`${f?` hoisted from ${f.join(", ")}`:""}`,m=`${h?` hoisted to ${h}`:""}`,y=`${g()}${p}`;u?u.ident!==c.ident&&e.push(`${y} - broken require promise for ${c.name}${m}: expected ${c.ident}, but found: ${u.ident}`):e.push(`${y} - broken require promise: no required dependency ${c.name}${m} found`)}}i.add(s);for(let c of s.dependencies.values())s.peerNames.has(c.name)||n(c,l,s);i.delete(s)};return n(t,t.dependencies,t),e.join(`
`)},Lze=(t,e)=>{let{identName:r,name:i,reference:n,peerNames:s}=t,o={name:i,references:new Set([n]),locator:UL(r,n),ident:hle(r,n),dependencies:new Map,originalDependencies:new Map,hoistedDependencies:new Map,peerNames:new Set(s),reasons:new Map,decoupled:!0,isHoistBorder:!0,hoistPriority:0,dependencyKind:1,hoistedFrom:new Map,hoistedTo:new Map},a=new Map([[t,o]]),l=(c,u)=>{let g=a.get(c),f=!!g;if(!g){let{name:h,identName:p,reference:m,peerNames:y,hoistPriority:b,dependencyKind:S}=c,k=e.hoistingLimits.get(u.locator);g={name:h,references:new Set([m]),locator:UL(p,m),ident:hle(p,m),dependencies:new Map,originalDependencies:new Map,hoistedDependencies:new Map,peerNames:new Set(y),reasons:new Map,decoupled:!0,isHoistBorder:k?k.has(h):!1,hoistPriority:b||0,dependencyKind:S||0,hoistedFrom:new Map,hoistedTo:new Map},a.set(c,g)}if(u.dependencies.set(c.name,g),u.originalDependencies.set(c.name,g),f){let h=new Set,p=m=>{if(!h.has(m)){h.add(m),m.decoupled=!1;for(let y of m.dependencies.values())m.peerNames.has(y.name)||p(y)}};p(g)}else for(let h of c.dependencies)l(h,g)};for(let c of t.dependencies)l(c,o);return o},jL=t=>t.substring(0,t.indexOf("@",1)),Tze=t=>{let e={name:t.name,identName:jL(t.locator),references:new Set(t.references),dependencies:new Set},r=new Set([t]),i=(n,s,o)=>{let a=r.has(n),l;if(s===n)l=o;else{let{name:c,references:u,locator:g}=n;l={name:c,identName:jL(g),references:u,dependencies:new Set}}if(o.dependencies.add(l),!a){r.add(n);for(let c of n.dependencies.values())n.peerNames.has(c.name)||i(c,n,l);r.delete(n)}};for(let n of t.dependencies.values())i(n,t,e);return e},Hze=t=>{let e=new Map,r=new Set([t]),i=o=>`${o.name}@${o.ident}`,n=o=>{let a=i(o),l=e.get(a);return l||(l={dependents:new Set,peerDependents:new Set,hoistPriority:0},e.set(a,l)),l},s=(o,a)=>{let l=!!r.has(a);if(n(a).dependents.add(o.ident),!l){r.add(a);for(let u of a.dependencies.values()){let g=n(u);g.hoistPriority=Math.max(g.hoistPriority,u.hoistPriority),a.peerNames.has(u.name)?g.peerDependents.add(a.ident):s(a,u)}}};for(let o of t.dependencies.values())t.peerNames.has(o.name)||s(t,o);return e},Ni=t=>{if(!t)return"none";let e=t.indexOf("@",1),r=t.substring(0,e);r.endsWith("$wsroot$")&&(r=`wh:${r.replace("$wsroot$","")}`);let i=t.substring(e+1);if(i==="workspace:.")return".";if(i){let n=(i.indexOf("#")>0?i.split("#")[1]:i).replace("npm:","");return i.startsWith("virtual")&&(r=`v:${r}`),n.startsWith("workspace")&&(r=`w:${r}`,n=""),`${r}${n?`@${n}`:""}`}else return`${r}`},mle=5e4,jm=t=>{let e=0,r=(n,s,o="")=>{if(e>mle||s.has(n))return"";e++;let a=Array.from(n.dependencies.values()).sort((c,u)=>c.name===u.name?0:c.name>u.name?1:-1),l="";s.add(n);for(let c=0;c<a.length;c++){let u=a[c];if(!n.peerNames.has(u.name)&&u!==n){let g=n.reasons.get(u.name),f=jL(u.locator);l+=`${o}${c<a.length-1?"\u251C\u2500":"\u2514\u2500"}${(s.has(u)?">":"")+(f!==u.name?`a:${u.name}:`:"")+Ni(u.locator)+(g?` ${g}`:"")}
`,l+=r(u,s,`${o}${c<a.length-1?"\u2502 ":" "}`)}}return s.delete(n),l};return r(t,new Set)+(e>mle?`
Tree is too large, part of the tree has been dunped
`:"")};var yo;(function(r){r.HARD="HARD",r.SOFT="SOFT"})(yo||(yo={}));var Kn;(function(i){i.WORKSPACES="workspaces",i.DEPENDENCIES="dependencies",i.NONE="none"})(Kn||(Kn={}));var Ele="node_modules",bu="$wsroot$";var Ym=(t,e)=>{let{packageTree:r,hoistingLimits:i,errors:n,preserveSymlinksRequired:s}=Yze(t,e),o=null;if(n.length===0){let a=dle(r,{hoistingLimits:i});o=qze(t,a,e)}return{tree:o,errors:n,preserveSymlinksRequired:s}},fa=t=>`${t.name}@${t.reference}`,YL=t=>{let e=new Map;for(let[r,i]of t.entries())if(!i.dirList){let n=e.get(i.locator);n||(n={target:i.target,linkType:i.linkType,locations:[],aliases:i.aliases},e.set(i.locator,n)),n.locations.push(r)}for(let r of e.values())r.locations=r.locations.sort((i,n)=>{let s=i.split(x.delimiter).length,o=n.split(x.delimiter).length;return n===i?0:s!==o?o-s:n>i?1:-1});return e},Ile=(t,e)=>{let r=P.isVirtualLocator(t)?P.devirtualizeLocator(t):t,i=P.isVirtualLocator(e)?P.devirtualizeLocator(e):e;return P.areLocatorsEqual(r,i)},qL=(t,e,r,i)=>{if(t.linkType!==yo.SOFT)return!1;let n=H.toPortablePath(r.resolveVirtual&&e.reference&&e.reference.startsWith("virtual:")?r.resolveVirtual(t.packageLocation):t.packageLocation);return x.contains(i,n)===null},Jze=t=>{let e=t.getPackageInformation(t.topLevel);if(e===null)throw new Error("Assertion failed: Expected the top-level package to have been registered");if(t.findPackageLocator(e.packageLocation)===null)throw new Error("Assertion failed: Expected the top-level package to have a physical locator");let i=H.toPortablePath(e.packageLocation.slice(0,-1)),n=new Map,s={children:new Map},o=t.getDependencyTreeRoots(),a=new Map,l=new Set,c=(f,h)=>{let p=fa(f);if(l.has(p))return;l.add(p);let m=t.getPackageInformation(f);if(m){let y=h?fa(h):"";if(fa(f)!==y&&m.linkType===yo.SOFT&&!qL(m,f,t,i)){let b=yle(m,f,t);(!a.get(b)||f.reference.startsWith("workspace:"))&&a.set(b,f)}for(let[b,S]of m.packageDependencies)S!==null&&(m.packagePeers.has(b)||c(t.getLocator(b,S),f))}};for(let f of o)c(f,null);let u=i.split(x.sep);for(let f of a.values()){let h=t.getPackageInformation(f),m=H.toPortablePath(h.packageLocation.slice(0,-1)).split(x.sep).slice(u.length),y=s;for(let b of m){let S=y.children.get(b);S||(S={children:new Map},y.children.set(b,S)),y=S}y.workspaceLocator=f}let g=(f,h)=>{if(f.workspaceLocator){let p=fa(h),m=n.get(p);m||(m=new Set,n.set(p,m)),m.add(f.workspaceLocator)}for(let p of f.children.values())g(p,f.workspaceLocator||h)};for(let f of s.children.values())g(f,s.workspaceLocator);return n},Yze=(t,e)=>{let r=[],i=!1,n=new Map,s=Jze(t),o=t.getPackageInformation(t.topLevel);if(o===null)throw new Error("Assertion failed: Expected the top-level package to have been registered");let a=t.findPackageLocator(o.packageLocation);if(a===null)throw new Error("Assertion failed: Expected the top-level package to have a physical locator");let l=H.toPortablePath(o.packageLocation.slice(0,-1)),c={name:a.name,identName:a.name,reference:a.reference,peerNames:o.packagePeers,dependencies:new Set,dependencyKind:Mn.WORKSPACE},u=new Map,g=(h,p)=>`${fa(p)}:${h}`,f=(h,p,m,y,b,S,k,T)=>{var X,O;let Y=g(h,m),j=u.get(Y),Z=!!j;!Z&&m.name===a.name&&m.reference===a.reference&&(j=c,u.set(Y,c));let J=qL(p,m,t,l);if(!j){let L=Mn.REGULAR;J?L=Mn.EXTERNAL_SOFT_LINK:p.linkType===yo.SOFT&&m.name.endsWith(bu)&&(L=Mn.WORKSPACE),j={name:h,identName:m.name,reference:m.reference,dependencies:new Set,peerNames:L===Mn.WORKSPACE?new Set:p.packagePeers,dependencyKind:L},u.set(Y,j)}let re;if(J?re=2:b.linkType===yo.SOFT?re=1:re=0,j.hoistPriority=Math.max(j.hoistPriority||0,re),T&&!J){let L=fa({name:y.identName,reference:y.reference}),pe=n.get(L)||new Set;n.set(L,pe),pe.add(j.name)}let ee=new Map(p.packageDependencies);if(e.project){let L=e.project.workspacesByCwd.get(H.toPortablePath(p.packageLocation.slice(0,-1)));if(L){let pe=new Set([...Array.from(L.manifest.peerDependencies.values(),Ce=>P.stringifyIdent(Ce)),...Array.from(L.manifest.peerDependenciesMeta.keys())]);for(let Ce of pe)ee.has(Ce)||(ee.set(Ce,S.get(Ce)||null),j.peerNames.add(Ce))}}let A=fa({name:m.name.replace(bu,""),reference:m.reference}),oe=s.get(A);if(oe)for(let L of oe)ee.set(`${L.name}${bu}`,L.reference);(p!==b||p.linkType!==yo.SOFT||!J&&(!e.selfReferencesByCwd||e.selfReferencesByCwd.get(k)))&&y.dependencies.add(j);let le=m!==a&&p.linkType===yo.SOFT&&!m.name.endsWith(bu)&&!J;if(!Z&&!le){let L=new Map;for(let[pe,Ce]of ee)if(Ce!==null){let Oe=t.getLocator(pe,Ce),te=t.getLocator(pe.replace(bu,""),Ce),se=t.getPackageInformation(te);if(se===null)throw new Error("Assertion failed: Expected the package to have been registered");let be=qL(se,Oe,t,l);if(e.validateExternalSoftLinks&&e.project&&be){se.packageDependencies.size>0&&(i=!0);for(let[Se,de]of se.packageDependencies)if(de!==null){let V=P.parseLocator(Array.isArray(de)?`${de[0]}@${de[1]}`:`${Se}@${de}`);if(fa(V)!==fa(Oe)){let Qe=ee.get(Se);if(Qe){let ce=P.parseLocator(Array.isArray(Qe)?`${Qe[0]}@${Qe[1]}`:`${Se}@${Qe}`);Ile(ce,V)||r.push({messageName:$.NM_CANT_INSTA Line truncated
`;for(let s=0,o=t.length;s<o;++s)n+=i+gb(String(s),t[s],e,i).replace(/^ +/,""),s+1<o&&(n+=","),n+=`
`;return n+=r,n+="]",n}function Vze(t,e,r){let i=Object.keys(t),n="";n+="{";for(let s=0,o=i.length,a=0;s<o;++s){let l=i[s],c=t[l];typeof c!="undefined"&&(a!==0&&(n+=", "),n+=JSON.stringify(l),n+=": ",n+=gb(l,c,e,r).replace(/^ +/g,""),a+=1)}return n+="}",n}function Xze(t,e,r){let i=Object.keys(t),n=`${r} `,s="";s+=r,s+=`{
`;let o=0;for(let a=0,l=i.length;a<l;++a){let c=i[a],u=t[c];typeof u!="undefined"&&(o!==0&&(s+=",",s+=`
`),s+=n,s+=JSON.stringify(c),s+=": ",s+=gb(c,u,e,n).replace(/^ +/g,""),o+=1)}return o!==0&&(s+=`
`),s+=r,s+="}",s}function gb(t,e,r,i){let{next:n}=Ble[r],s=n[t]||n["*"];return ble(e,s,i)}function ble(t,e,r){let{collapsed:i}=Ble[e];return Array.isArray(t)?i?zze(t,e,r):_ze(t,e,r):typeof t=="object"&&t!==null?i?Vze(t,e,r):Xze(t,e,r):JSON.stringify(t)}function Qle(t){return ble(t,er.TOP_LEVEL,"")}function qm(t,e){let r=Array.from(t);Array.isArray(e)||(e=[e]);let i=[];for(let s of e)i.push(r.map(o=>s(o)));let n=r.map((s,o)=>o);return n.sort((s,o)=>{for(let a of i){let l=a[s]<a[o]?-1:a[s]>a[o]?1:0;if(l!==0)return l}return 0}),n.map(s=>r[s])}function Zze(t){let e=new Map,r=qm(t.fallbackExclusionList||[],[({name:i,reference:n})=>i,({name:i,reference:n})=>n]);for(let{name:i,reference:n}of r){let s=e.get(i);typeof s=="undefined"&&e.set(i,s=new Set),s.add(n)}return Array.from(e).map(([i,n])=>[i,Array.from(n)])}function $ze(t){return qm(t.fallbackPool||[],([e])=>e)}function e5e(t){let e=[];for(let[r,i]of qm(t.packageRegistry,([n])=>n===null?"0":`1${n}`)){let n=[];e.push([r,n]);for(let[s,{packageLocation:o,packageDependencies:a,packagePeers:l,linkType:c,discardFromLookup:u}]of qm(i,([g])=>g===null?"0":`1${g}`)){let g=[];r!==null&&s!==null&&!a.has(r)&&g.push([r,s]);for(let[p,m]of qm(a.entries(),([y])=>y))g.push([p,m]);let f=l&&l.size>0?Array.from(l):void 0,h=u||void 0;n.push([s,{packageLocation:o,packageDependencies:g,packagePeers:f,linkType:c,discardFromLookup:h}])}}return e}function Jm(t){return{__info:["This file is automatically generated. Do not touch it, or risk","your modifications being lost. We also recommend you not to read","it either without using the @yarnpkg/pnp package, as the data layout","is entirely unspecified and WILL change from a version to another."],dependencyTreeRoots:t.dependencyTreeRoots,enableTopLevelFallback:t.enableTopLevelFallback||!1,ignorePatternData:t.ignorePattern||null,fallbackExclusionList:Zze(t),fallbackPool:$ze(t),packageRegistryData:e5e(t)}}var kle=ge(Sle());function xle(t,e){return[t?`${t}
`:"",`/* eslint-disable */
`,`try {
`,` Object.freeze({}).detectStrictMode = true;
`,`} catch (error) {
`," throw new Error(`The whole PnP file got strict-mode-ified, which is known to break (Emscripten libraries aren't strict mode). This usually happens when the file goes through Babel.`);\n",`}
`,`
`,`function $$SETUP_STATE(hydrateRuntimeState, basePath) {
`,e.replace(/^/gm," "),`}
`,`
`,(0,kle.default)()].join("")}function t5e(t){return JSON.stringify(t,null,2)}function r5e(t){return`'${t.replace(/\\/g,"\\\\").replace(/'/g,"\\'").replace(/\n/g,`\\
`)}'`}function i5e(t){return[`return hydrateRuntimeState(JSON.parse(${r5e(Qle(t))}), {basePath: basePath || __dirname});
`].join("")}function n5e(t){return[`var path = require('path');
`,`var dataLocation = path.resolve(__dirname, ${JSON.stringify(t)});
`,`return hydrateRuntimeState(require(dataLocation), {basePath: basePath || path.dirname(dataLocation)});
`].join("")}function Ple(t){let e=Jm(t),r=i5e(e);return xle(t.shebang,r)}function Dle(t){let e=Jm(t),r=n5e(t.dataLocation),i=xle(t.shebang,r);return{dataFile:t5e(e),loaderFile:i}}var Nle=ge(require("fs")),c5e=ge(require("path")),Lle=ge(require("util"));function WL(t,{basePath:e}){let r=H.toPortablePath(e),i=x.resolve(r),n=t.ignorePatternData!==null?new RegExp(t.ignorePatternData):null,s=new Map,o=new Map(t.packageRegistryData.map(([g,f])=>[g,new Map(f.map(([h,p])=>{var k;if(g===null!=(h===null))throw new Error("Assertion failed: The name and reference should be null, or neither should");let m=(k=p.discardFromLookup)!=null?k:!1,y={name:g,reference:h},b=s.get(p.packageLocation);b?(b.discardFromLookup=b.discardFromLookup&&m,m||(b.locator=y)):s.set(p.packageLocation,{locator:y,discardFromLookup:m});let S=null;return[h,{packageDependencies:new Map(p.packageDependencies),packagePeers:new Set(p.packagePeers),linkType:p.linkType,discardFromLookup:m,get packageLocation(){return S||(S=x.join(i,p.packageLocation))}}]}))])),a=new Map(t.fallbackExclusionList.map(([g,f])=>[g,new Set(f)])),l=new Map(t.fallbackPool),c=t.dependencyTreeRoots,u=t.enableTopLevelFallback;return{basePath:r,dependencyTreeRoots:c,enableTopLevelFallback:u,fallbackExclusionList:a,fallbackPool:l,ignorePattern:n,packageLocatorsByLocations:s,packageRegistry:o}}var Wm=ge(require("module"));function oh(t,e){if(typeof t=="string")return t;if(t){let r,i;if(Array.isArray(t)){for(r=0;r<t.length;r++)if(i=oh(t[r],e))return i}else for(r in t)if(e.has(r))return oh(t[r],e)}}function Qu(t,e,r){throw new Error(r?`No known conditions for "${e}" entry in "${t}" package`:`Missing "${e}" export in "${t}" package`)}function s5e(t,e){return e===t?".":e[0]==="."?e:e.replace(new RegExp("^"+t+"/"),"./")}function Rle(t,e=".",r={}){let{name:i,exports:n}=t;if(n){let{browser:s,require:o,unsafe:a,conditions:l=[]}=r,c=s5e(i,e);if(c[0]!=="."&&(c="./"+c),typeof n=="string")return c==="."?n:Qu(i,c);let u=new Set(["default",...l]);a||u.add(o?"require":"import"),a||u.add(s?"browser":"node");let g,f,h=!1;for(g in n){h=g[0]!==".";break}if(h)return c==="."?oh(n,u)||Qu(i,c,1):Qu(i,c);if(f=n[c])return oh(f,u)||Qu(i,c,1);for(g in n){if(f=g[g.length-1],f==="/"&&c.startsWith(g))return(f=oh(n[g],u))?f+c.substring(g.length):Qu(i,c,1);if(f==="*"&&c.startsWith(g.slice(0,-1))&&c.substring(g.length-1).length>0)return(f=oh(n[g],u))?f.replace("*",c.substring(g.length-1)):Qu(i,c,1)}return Qu(i,c)}}var zL=ge(require("util"));var ur;(function(c){c.API_ERROR="API_ERROR",c.BUILTIN_NODE_RESOLUTION_FAILED="BUILTIN_NODE_RESOLUTION_FAILED",c.EXPORTS_RESOLUTION_FAILED="EXPORTS_RESOLUTION_FAILED",c.MISSING_DEPENDENCY="MISSING_DEPENDENCY",c.MISSING_PEER_DEPENDENCY="MISSING_PEER_DEPENDENCY",c.QUALIFIED_PATH_RESOLUTION_FAILED="QUALIFIED_PATH_RESOLUTION_FAILED",c.INTERNAL="INTERNAL",c.UNDECLARED_DEPENDENCY="UNDECLARED_DEPENDENCY",c.UNSUPPORTED="UNSUPPORTED"})(ur||(ur={}));var o5e=new Set([ur.BUILTIN_NODE_RESOLUTION_FAILED,ur.MISSING_DEPENDENCY,ur.MISSING_PEER_DEPENDENCY,ur.QUALIFIED_PATH_RESOLUTION_FAILED,ur.UNDECLARED_DEPENDENCY]);function ai(t,e,r={},i){i!=null||(i=o5e.has(t)?"MODULE_NOT_FOUND":t);let n={configurable:!0,writable:!0,enumerable:!1};return Object.defineProperties(new Error(e),{code:ie(N({},n),{value:i}),pnpCode:ie(N({},n),{value:t}),data:ie(N({},n),{value:r})})}function wo(t){return H.normalize(H.fromPortablePath(t))}var a5e=ge(require("fs")),Fle=ge(require("module")),A5e=ge(require("path")),l5e=new Set(Fle.Module.builtinModules||Object.keys(process.binding("natives"))),fb=t=>t.startsWith("node:")||l5e.has(t);function _L(t,e){let r=Number(process.env.PNP_ALWAYS_WARN_ON_FALLBACK)>0,i=Number(process.env.PNP_DEBUG_LEVEL),n=/^(?![a-zA-Z]:[\\/]|\\\\|\.{0,2}(?:\/|$))((?:node:)?(?:@[^/]+\/)?[^/]+)\/*(.*|)$/,s=/^(\/|\.{1,2}(\/|$))/,o=/\/$/,a=/^\.{0,2}\//,l={name:null,reference:null},c=[],u=new Set;if(t.enableTopLevelFallback===!0&&c.push(l),e.compatibilityMode!==!1)for(let te of["react-scripts","gatsby"]){let se=t.packageRegistry.get(te);if(se)for(let be of se.keys()){if(be===null)throw new Error("Assertion failed: This reference shouldn't be null");c.push({name:te,reference:be})}}let{ignorePattern:g,packageRegistry:f,packageLocatorsByLocations:h}=t;function p(te,se){return{fn:te,args:se,error:null,result:null}}function m(te){var Ue,xe,Se,de,V,Qe;let se=(Se=(xe=(Ue=process.stderr)==null?void 0:Ue.hasColors)==null?void 0:xe.call(Ue))!=null?Se:process.stdout.isTTY,be=(ce,fe)=>`[${ce}m${fe}`,he=te.error;console.error(he?be("31;1",`\u2716 ${(de=te.error)==null?void 0:de.message.replace(/\n.*/s,"")}`):be("33;1","\u203C Resolution")),te.args.length>0&&console.error();for(let ce of te.args)console.error(` ${be("37;1","In \u2190")} ${(0,zL.inspect)(ce,{colors:se,compact:!0})}`);te.result&&(console.error(),console.error(` ${be("37;1","Out \u2192")} ${(0,zL.inspect)(te.result,{colors:se,compact:!0})}`));let Fe=(Qe=(V=new Error().stack.match(/(?<=^ +)at.*/gm))==null?void 0:V.slice(2))!=null?Qe:[];if(Fe.length>Line truncated
Require request: "${he}"
Required by: ${Fe}
`,{request:he,issuer:Fe});return H.toPortablePath(Se)}let Ue,xe=te.match(n);if(xe){if(!se)throw ai(ur.API_ERROR,"The resolveToUnqualified function must be called with a valid issuer when the path isn't a builtin nor absolute",{request:he,issuer:Fe});let[,Se,de]=xe,V=X(se);if(!V){let Gt=Z(te,se);if(Gt===!1)throw ai(ur.BUILTIN_NODE_RESOLUTION_FAILED,`The builtin node resolution algorithm was unable to resolve the requested module (it didn't go through the pnp resolver because the issuer doesn't seem to be part of the Yarn-managed dependency tree).
Require path: "${he}"
Required by: ${Fe}
`,{request:he,issuer:Fe});return H.toPortablePath(Gt)}let ce=b(V).packageDependencies.get(Se),fe=null;if(ce==null&&V.name!==null){let Gt=t.fallbackExclusionList.get(V.name);if(!Gt||!Gt.has(V.reference)){for(let Ti=0,Vs=c.length;Ti<Vs;++Ti){let Hn=b(c[Ti]).packageDependencies.get(Se);if(Hn!=null){r?fe=Hn:ce=Hn;break}}if(t.enableTopLevelFallback&&ce==null&&fe===null){let Ti=t.fallbackPool.get(Se);Ti!=null&&(fe=Ti)}}}let gt=null;if(ce===null)if(S(V))gt=ai(ur.MISSING_PEER_DEPENDENCY,`Your application tried to access ${Se} (a peer dependency); this isn't allowed as there is no ancestor to satisfy the requirement. Use a devDependency if needed.
Required package: ${Se}${Se!==he?` (via "${he}")`:""}
Required by: ${Fe}
`,{request:he,issuer:Fe,dependencyName:Se});else{let Gt=le(Se,V);Gt.every(Qr=>S(Qr))?gt=ai(ur.MISSING_PEER_DEPENDENCY,`${V.name} tried to access ${Se} (a peer dependency) but it isn't provided by your application; this makes the require call ambiguous and unsound.
Required package: ${Se}${Se!==he?` (via "${he}")`:""}
Required by: ${V.name}@${V.reference} (via ${Fe})
${Gt.map(Qr=>`Ancestor breaking the chain: ${Qr.name}@${Qr.reference}
`).join("")}
`,{request:he,issuer:Fe,issuerLocator:Object.assign({},V),dependencyName:Se,brokenAncestors:Gt}):gt=ai(ur.MISSING_PEER_DEPENDENCY,`${V.name} tried to access ${Se} (a peer dependency) but it isn't provided by its ancestors; this makes the require call ambiguous and unsound.
Required package: ${Se}${Se!==he?` (via "${he}")`:""}
Required by: ${V.name}@${V.reference} (via ${Fe})
${Gt.map(Qr=>`Ancestor breaking the chain: ${Qr.name}@${Qr.reference}
`).join("")}
`,{request:he,issuer:Fe,issuerLocator:Object.assign({},V),dependencyName:Se,brokenAncestors:Gt})}else ce===void 0&&(!be&&fb(te)?S(V)?gt=ai(ur.UNDECLARED_DEPENDENCY,`Your application tried to access ${Se}. While this module is usually interpreted as a Node builtin, your resolver is running inside a non-Node resolution context where such builtins are ignored. Since ${Se} isn't otherwise declared in your dependencies, this makes the require call ambiguous and unsound.
Required package: ${Se}${Se!==he?` (via "${he}")`:""}
Required by: ${Fe}
`,{request:he,issuer:Fe,dependencyName:Se}):gt=ai(ur.UNDECLARED_DEPENDENCY,`${V.name} tried to access ${Se}. While this module is usually interpreted as a Node builtin, your resolver is running inside a non-Node resolution context where such builtins are ignored. Since ${Se} isn't otherwise declared in ${V.name}'s dependencies, this makes the require call ambiguous and unsound.
Required package: ${Se}${Se!==he?` (via "${he}")`:""}
Required by: ${Fe}
`,{request:he,issuer:Fe,issuerLocator:Object.assign({},V),dependencyName:Se}):S(V)?gt=ai(ur.UNDECLARED_DEPENDENCY,`Your application tried to access ${Se}, but it isn't declared in your dependencies; this makes the require call ambiguous and unsound.
Required package: ${Se}${Se!==he?` (via "${he}")`:""}
Required by: ${Fe}
`,{request:he,issuer:Fe,dependencyName:Se}):gt=ai(ur.UNDECLARED_DEPENDENCY,`${V.name} tried to access ${Se}, but it isn't declared in its dependencies; this makes the require call ambiguous and unsound.
Required package: ${Se}${Se!==he?` (via "${he}")`:""}
Required by: ${V.name}@${V.reference} (via ${Fe})
`,{request:he,issuer:Fe,issuerLocator:Object.assign({},V),dependencyName:Se}));if(ce==null){if(fe===null||gt===null)throw gt||new Error("Assertion failed: Expected an error to have been set");ce=fe;let Gt=gt.message.replace(/\n.*/g,"");gt.message=Gt,!u.has(Gt)&&i!==0&&(u.add(Gt),process.emitWarning(gt))}let Ht=Array.isArray(ce)?{name:ce[0],reference:ce[1]}:{name:Se,reference:ce},Mt=b(Ht);if(!Mt.packageLocation)throw ai(ur.MISSING_DEPENDENCY,`A dependency seems valid but didn't get installed for some reason. This might be caused by a partial install, such as dev vs prod.
Required package: ${Ht.name}@${Ht.reference}${Ht.name!==he?` (via "${he}")`:""}
Required by: ${V.name}@${V.reference} (via ${Fe})
`,{request:he,issuer:Fe,dependencyLocator:Object.assign({},Ht)});let mi=Mt.packageLocation;de?Ue=x.join(mi,de):Ue=mi}else if(x.isAbsolute(te))Ue=x.normalize(te);else{if(!se)throw ai(ur.API_ERROR,"The resolveToUnqualified function must be called with a valid issuer when the path isn't a builtin nor absolute",{request:he,issuer:Fe});let Se=x.resolve(se);se.match(o)?Ue=x.normalize(x.join(Se,te)):Ue=x.normalize(x.join(x.dirname(Se),te))}return x.normalize(Ue)}function L(te,se,be=k){if(s.test(te))return se;let he=T(se,be);return he?x.normalize(he):se}function pe(te,{extensions:se=Object.keys(Wm.Module._extensions)}={}){var Fe,Ue;let be=[],he=Y(te,be,{extensions:se});if(he)return x.normalize(he);{let xe=wo(te),Se=X(te);if(Se){let{packageLocation:de}=b(Se),V=!0;try{e.fakeFs.accessSync(de)}catch(Qe){if((Qe==null?void 0:Qe.code)==="ENOENT")V=!1;else{let ce=((Ue=(Fe=Qe==null?void 0:Qe.message)!=null?Fe:Qe)!=null?Ue:"empty exception thrown").replace(/^[A-Z]/,fe=>fe.toLowerCase());throw ai(ur.QUALIFIED_PATH_RESOLUTION_FAILED,`Required package exists but could not be accessed (${ce}).
Missing package: ${Se.name}@${Se.reference}
Expected package location: ${wo(de)}
`,{unqualifiedPath:xe,extensions:se})}}if(!V){let Qe=de.includes("/unplugged/")?"Required unplugged package missing from disk. This may happen when switching branches without running installs (unplugged packages must be fully materialized on disk to work).":"Required package missing from disk. If you keep your packages inside your repository then restarting the Node process may be enough. Otherwise, try to run an install first.";throw ai(ur.QUALIFIED_PATH_RESOLUTION_FAILED,`${Qe}
Missing package: ${Se.name}@${Se.reference}
Expected package location: ${wo(de)}
`,{unqualifiedPath:xe,extensions:se})}}throw ai(ur.QUALIFIED_PATH_RESOLUTION_FAILED,`Qualified path resolution failed: we looked for the following paths, but none could be accessed.
Source path: ${xe}
${be.map(de=>`Not found: ${wo(de)}
`).join("")}`,{unqualifiedPath:xe,extensions:se})}}function Ce(te,se,{considerBuiltins:be,extensions:he,conditions:Fe}={}){try{let Ue=O(te,se,{considerBuiltins:be});if(te==="pnpapi")return Ue;if(Ue===null)return null;let xe=()=>se!==null?J(se):!1,Se=(!be||!fb(te))&&!xe()?L(te,Ue,Fe):Ue;return pe(Se,{extensions:he})}catch(Ue){throw Object.prototype.hasOwnProperty.call(Ue,"pnpCode")&&Object.assign(Ue.data,{request:wo(te),issuer:se&&wo(se)}),Ue}}function Oe(te){let se=x.normalize(te),be=Wr.resolveVirtual(se);return be!==se?be:null}return{VERSIONS:re,topLevel:ee,getLocator:(te,se)=>Array.isArray(se)?{name:se[0],reference:se[1]}:{name:te,reference:se},getDependencyTreeRoots:()=>[...t.dependencyTreeRoots],getAllLocators(){let te=[];for(let[se,be]of f)for(let he of be.keys())se!==null&&he!==null&&te.push({name:se,reference:he});return te},getPackageInformation:te=>{let se=A(te);if(se===null)return null;let be=H.fromPortablePath(se.packageLocation);return ie(N({},se),{packageLocation:be})},findPackageLocator:te=>X(H.toPortablePath(te)),resolveToUnqualified:y("resolveToUnqualified",(te,se,be)=>{let he=se!==null?H.toPortablePath(se):null,Fe=O(H.toPortablePath(te),he,be);return Fe===null?null:H.fromPortablePath(Fe)}),resolveUnqualified:y("resolveUnqualified",(te,se)=>H.fromPortablePath(pe(H.toPortablePath(te),se))),resolveRequest:y("resolveRequest",(te,se,be)=>{let he=se!==null?H.toPortablePath(se):null,Fe=Ce(H.toPortablePath(te),he,be);return Fe===null?null:H.fromPortablePath(Fe)}),resolveVirtual:y("resolveVirtual",te=>{let se=Oe(H.toPortablePath(te));return se!==null?H.fromPortablePath(se):null})}}var YQt=(0,Lle.promisify)(Nle.readFile);var Tle=(t,e,r)=>{let i=Jm(t),n=WL(i,{basePath:e}),s=H.join(e,Pt.pnpCjs);return _L(n,{fakeFs:r,pnpapiResolution:s})};var XL=ge(Mle());var ha={};ft(ha,{checkAndReportManifestCompatibility:()=>Ule,checkManifestCompatibility:()=>Kle,extractBuildScripts:()=>hb,getExtractHint:()=>ZL,hasBindingGyp:()=>$L});function Kle(t){return P.isPackageCompatible(t,Wg.getArchitectureSet())}function Ule(t,e,{configuration:r,report:i}){return Kle(t)?!0:(i==null||i.reportWarningOnce($.INCOMPATIBLE_ARCHITECTURE,`${P.prettyLocator(r,t)} The ${Wg.getArchitectureName()} architecture is incompatible with this package, ${e} skipped.`),!1)}function hb(t,e,r,{configuration:i,report:n}){let s=[];for(let a of["preinstall","install","postinstall"])e.manifest.scripts.has(a)&&s.push([ls.SCRIPT,a]);return!e.manifest.scripts.has("install")&&e.misc.hasBindingGyp&&s.push([ls.SHELLCODE,"node-gyp rebuild"]),s.length===0?[]:t.linkType!==Qt.HARD?(n==null||n.reportWarningOnce($.SOFT_LINK_BUILD,`${P.prettyLocator(i,t)} lists build scripts, but is referenced through a soft link. Soft links don't support build scripts, so they'll be ignored.`),[]):r&&r.built===!1?(n==null||n.reportInfoOnce($.BUILD_DISABLED,`${P.prettyLocator(i,t)} lists build scripts, but its build has been explicitly disabled through configuration.`),[]):!i.get("enableScripts")&&!r.built?(n==null||n.reportWarningOnce($.DISABLED_BUILD_SCRIPTS,`${P.prettyLocator(i,t)} lists build scripts, but all build scripts have been disabled.`),[]):Ule(t,"build",{configuration:i,report:n})?s:[]}var u5e=new Set([".exe",".h",".hh",".hpp",".c",".cc",".cpp",".java",".jar",".node"]);function ZL(t){return t.packageFs.getExtractHint({relevantExtensions:u5e})}function $L(t){let e=x.join(t.prefixPath,"binding.gyp");return t.packageFs.existsSync(e)}var eT={};ft(eT,{getUnpluggedPath:()=>zm});function zm(t,{configuration:e}){return x.resolve(e.get("pnpUnpluggedFolder"),P.slugifyLocator(t))}var g5e=new Set([P.makeIdent(null,"nan").identHash,P.makeIdent(null,"node-gyp").identHash,P.makeIdent(null,"node-pre-gyp").identHash,P.makeIdent(null,"node-addon-api").identHash,P.makeIdent(null,"fsevents").identHash]),vu=class{constructor(){this.mode="strict";this.pnpCache=new Map}supportsPackage(e,r){return this.isEnabled(r)}async findPackageLocation(e,r){if(!this.isEnabled(r))throw new Error("Assertion failed: Expected the PnP linker to be enabled");let i=Dl(r.project).cjs;if(!K.existsSync(i))throw new Pe(`The project in ${Ae.pretty(r.project.configuration,`${r.project.cwd}/package.json`,Ae.Type.PATH)} doesn't seem to have been installed - running an install there might help`);let n=ve.getFactoryWithDefault(this.pnpCache,i,()=>ve.dynamicRequire(i,{cachingStrategy:ve.CachingStrategy.FsTime})),s={name:P.stringifyIdent(e),reference:e.reference},o=n.getPackageInformation(s);if(!o)throw new Pe(`Couldn't find ${P.prettyLocator(r.project.configuration,e)} in the currently installed PnP map - running an install might help`);return H.toPortablePath(o.packageLocation)}async findPackageLocator(e,r){if(!this.isEnabled(r))return null;let i=Dl(r.project).cjs;if(!K.existsSync(i))return null;let s=ve.getFactoryWithDefault(this.pnpCache,i,()=>ve.dynamicRequire(i,{cachingStrategy:ve.CachingStrategy.FsTime})).findPackageLocator(H.fromPortablePath(e));return s?P.makeLocator(P.parseIdent(s.name),s.reference):null}makeInLine truncated
`,s+=`# cause your node_modules installation to become invalidated.
`,s+=`
`,s+=`__metadata:
`,s+=` version: ${$le}
`,s+=` nmMode: ${i.value}
`;let o=Array.from(e.keys()).sort(),a=P.stringifyLocator(t.topLevelWorkspace.anchoredLocator);for(let u of o){let g=e.get(u);s+=`
`,s+=`${JSON.stringify(u)}:
`,s+=` locations:
`;for(let f of g.locations){let h=x.contains(t.cwd,f);if(h===null)throw new Error(`Assertion failed: Expected the path to be within the project (${f})`);s+=` - ${JSON.stringify(h)}
`}if(g.aliases.length>0){s+=` aliases:
`;for(let f of g.aliases)s+=` - ${JSON.stringify(f)}
`}if(u===a&&r.size>0){s+=` bin:
`;for(let[f,h]of r){let p=x.contains(t.cwd,f);if(p===null)throw new Error(`Assertion failed: Expected the path to be within the project (${f})`);s+=` ${JSON.stringify(p)}:
`;for(let[m,y]of h){let b=x.relative(x.join(f,Gr),y);s+=` ${JSON.stringify(m)}: ${JSON.stringify(b)}
`}}}}let l=t.cwd,c=x.join(l,Gr,ece);n&&await K.removePromise(c),await K.changeFilePromise(c,s,{automaticNewlines:!0})}async function lT(t,{unrollAliases:e=!1}={}){let r=t.cwd,i=x.join(r,Gr,ece),n;try{n=await K.statPromise(i)}catch(c){}if(!n)return null;let s=Qi(await K.readFilePromise(i,"utf8"));if(s.__metadata.version>$le)return null;let o=s.__metadata.nmMode||Li.CLASSIC,a=new Map,l=new Map;delete s.__metadata;for(let[c,u]of Object.entries(s)){let g=u.locations.map(h=>x.join(r,h)),f=u.bin;if(f)for(let[h,p]of Object.entries(f)){let m=x.join(r,H.toPortablePath(h)),y=ve.getMapWithDefault(l,m);for(let[b,S]of Object.entries(p))y.set(Jr(b),H.toPortablePath([m,Gr,S].join(x.sep)))}if(a.set(c,{target:Ke.dot,linkType:Qt.HARD,locations:g,aliases:u.aliases||[]}),e&&u.aliases)for(let h of u.aliases){let{scope:p,name:m}=P.parseLocator(c),y=P.makeLocator(P.makeIdent(p,m),h),b=P.stringifyLocator(y);a.set(b,{target:Ke.dot,linkType:Qt.HARD,locations:g,aliases:[]})}}return{locatorMap:a,binSymlinks:l,locationTree:ice(a,{skipPrefix:t.cwd}),nmMode:o,mtimeMs:n.mtimeMs}}var lh=async(t,e)=>{if(t.split(x.sep).indexOf(Gr)<0)throw new Error(`Assertion failed: trying to remove dir that doesn't contain node_modules: ${t}`);try{if(!e.innerLoop){let i=e.allowSymlink?await K.statPromise(t):await K.lstatPromise(t);if(e.allowSymlink&&!i.isDirectory()||!e.allowSymlink&&i.isSymbolicLink()){await K.unlinkPromise(t);return}}let r=await K.readdirPromise(t,{withFileTypes:!0});for(let i of r){let n=x.join(t,Jr(i.name));i.isDirectory()?(i.name!==Gr||e&&e.innerLoop)&&await lh(n,{innerLoop:!0,contentsOnly:!1}):await K.unlinkPromise(n)}e.contentsOnly||await K.rmdirPromise(t)}catch(r){if(r.code!=="ENOENT"&&r.code!=="ENOTEMPTY")throw r}},nce=4,db=(t,{skipPrefix:e})=>{let r=x.contains(e,t);if(r===null)throw new Error(`Assertion failed: Writing attempt prevented to ${t} which is outside project root: ${e}`);let i=r.split(x.sep).filter(l=>l!==""),n=i.indexOf(Gr),s=i.slice(0,n).join(x.sep),o=x.join(e,s),a=i.slice(n);return{locationRoot:o,segments:a}},ice=(t,{skipPrefix:e})=>{let r=new Map;if(t===null)return r;let i=()=>({children:new Map,linkType:Qt.HARD});for(let[n,s]of t.entries()){if(s.linkType===Qt.SOFT&&x.contains(e,s.target)!==null){let a=ve.getFactoryWithDefault(r,s.target,i);a.locator=n,a.linkType=s.linkType}for(let o of s.locations){let{locationRoot:a,segments:l}=db(o,{skipPrefix:e}),c=ve.getFactoryWithDefault(r,a,i);for(let u=0;u<l.length;++u){let g=l[u];if(g!=="."){let f=ve.getFactoryWithDefault(c.children,g,i);c.children.set(g,f),c=f}u===l.length-1&&(c.locator=n,c.linkType=s.linkType)}}}return r},cT=async(t,e)=>{let r;try{process.platform==="win32"&&(r=await K.lstatPromise(t))}catch(i){}process.platform=="win32"&&(!r||r.isDirectory())?await K.symlinkPromise(t,e,"junction"):await K.symlinkPromise(x.relative(x.dirname(e),t),e)};async function sce(t,e,r){let i=x.join(t,Jr(`${aT.default.randomBytes(16).toString("hex")}.tmp`));try{await K.writeFilePromise(i,r);try{await K.linkPromise(i,e)}catch(n){}}finally{await K.unlinkPromise(i)}}async function O5e({srcPath:t,dstPath:e,srcMode:r,globalHardlinksStore:i,baseFs:n,nmMode:s,digest:o}){if(s.value===Li.HARDLINKS_GLOBAL&&i&&o){let l=x.join(i,o.substring(0,2),`${o.substring(2)}.dat`),c;try{if(await Dn.checksumFile(l,{baseFs:K,algorithm:"sha1"})!==o){let g=x.join(i,Jr(`${aT.default.randomBytes(16).toString("hex")}.tmp`));await K.renamePromise(l,g);let f=await n.readFilePromise(t);await K.writeFilePromise(g,f);try{await K.linkPromise(g,l),await K.unlinkPromise(g)}catch(h){}}await K.linkPromise(l,e),c=!0}catch(u){c=!1}if(!c){let u=await n.readFilePromise(t);await sce(i,l,u);try{await K.linkPromise(l,e)}catch(g){g&&g.code&&g.code=="EXDEV"&&(s.value=Li.HARDLINKS_LOCAL,await n.copyFilePromise(t,e))}}}else await n.copyFilePromise(t,e);let a=r&511;a!==420&&await K.chmodPromise(e,a)}var Rl;(function(i){i.FILE="file",i.DIRECTORY="directory",i.SYMLINK="symlink"})(Rl||(Rl={}));var M5e=async(t,e,{baseFs:r,globalHardlinksStore:i,nmMode:n,packageChecksum:s})=>{await K.mkdirPromise(t,{recursive:!0});let o=async(l=Ke.dot)=>{let c=x.join(e,l),u=await r.readdirPromise(c,{withFileTypes:!0}),g=new Map;for(let f of u){let h=x.join(l,f.name),p,m=x.join(c,f.name);if(f.isFile()){if(p={kind:Rl.FILE,mode:(await r.lstatPromise(m)).mode},n.value===Li.HARDLINKS_GLOBAL){let y=await Dn.checksumFile(m,{baseFs:r,algorithm:"sha1"});p.digest=y}}else if(f.isDirectory())p={kind:Rl.DIRECTORY};else if(f.isSymbolicLink())p={kind:Rl.SYMLINK,symlinkTo:await r.readlinkPromise(m)};else throw new Error(`Unsupported file type (file: ${m}, mode: 0o${await r.statSync(m).mode.toString(8).padStart(6,"0")})`);if(g.set(h,p),f.isDirectory()&&h!==Gr){let y=await o(h);for(let[b,S]of y)g.set(b,S)}}return g},a;if(n.value===Li.HARDLINKS_GLOBAL&&i&&s){let l=x.join(i,s.substring(0,2),`${s.substring(2)}.json`);try{a=new Map(Object.entries(JSON.parse(await K.readFilePromise(l,"utf8"))))}catch(c){a=await o(),await sce(i,l,Buffer.from(JSON.stringify(Object.fromEntries( Line truncated
This command checks for known security reports on the packages you use. The reports are by default extracted from the npm registry, and may or may not be relevant to your actual program (not all vulnerabilities affect all code paths).
For consistency with our other commands the default is to only check the direct dependencies for the active workspace. To extend this search to all workspaces, use \`-A,--all\`. To extend this search to both direct and transitive dependencies, use \`-R,--recursive\`.
Applying the \`--severity\` flag will limit the audit table to vulnerabilities of the corresponding severity and above. Valid values are ${Yb.map(e=>`\`${e}\``).join(", ")}.
If the \`--json\` flag is set, Yarn will print the output exactly as received from the registry. Regardless of this flag, the process will exit with a non-zero exit code if a report is found for the selected packages.
To understand the dependency tree requiring vulnerable packages, check the raw report with the \`--json\` flag or use \`yarn why <package>\` to get more information as to who depends on them.
`,examples:[["Checks for known security issues with the installed packages. The output is a list of known issues.","yarn npm audit"],["Audit dependencies in all workspaces","yarn npm audit --all"],["Limit auditing to `dependencies` (excludes `devDependencies`)","yarn npm audit --environment production"],["Show audit report as valid JSON","yarn npm audit --json"],["Audit all direct and transitive dependencies","yarn npm audit --recursive"],["Output moderate (or more severe) vulnerabilities","yarn npm audit --severity moderate"]]});var hge=gE;var hO=ge(ri()),pO=ge(require("util")),fE=class extends Le{constructor(){super(...arguments);this.fields=W.String("-f,--fields",{description:"A comma-separated list of manifest fields that should be displayed"});this.json=W.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.packages=W.Rest()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),{project:r}=await ze.find(e,this.context.cwd),i=typeof this.fields!="undefined"?new Set(["name",...this.fields.split(/\s*,\s*/)]):null,n=[],s=!1,o=await Je.start({configuration:e,includeFooter:!1,json:this.json,stdout:this.context.stdout},async a=>{for(let l of this.packages){let c;if(l==="."){let k=r.topLevelWorkspace;if(!k.manifest.name)throw new Pe(`Missing ${Ae.pretty(e,"name",Ae.Type.CODE)} field in ${H.fromPortablePath(x.join(k.cwd,Pt.manifest))}`);c=P.makeDescriptor(k.manifest.name,"unknown")}else c=P.parseDescriptor(l);let u=zt.getIdentUrl(c),g=dO(await zt.get(u,{configuration:e,ident:c,jsonResponse:!0,customErrorMessage:zt.customPackageError})),f=Object.keys(g.versions).sort(hO.default.compareLoose),p=g["dist-tags"].latest||f[f.length-1],m=Wt.validRange(c.range);if(m){let k=hO.default.maxSatisfying(f,m);k!==null?p=k:(a.reportWarning($.UNNAMED,`Unmet range ${P.prettyRange(e,c.range)}; falling back to the latest version`),s=!0)}else Object.prototype.hasOwnProperty.call(g["dist-tags"],c.range)?p=g["dist-tags"][c.range]:c.range!=="unknown"&&(a.reportWarning($.UNNAMED,`Unknown tag ${P.prettyRange(e,c.range)}; falling back to the latest version`),s=!0);let y=g.versions[p],b=ie(N(N({},g),y),{version:p,versions:f}),S;if(i!==null){S={};for(let k of i){let T=b[k];if(typeof T!="undefined")S[k]=T;else{a.reportWarning($.EXCEPTION,`The ${Ae.pretty(e,k,Ae.Type.CODE)} field doesn't exist inside ${P.prettyIdent(e,c)}'s information`),s=!0;continue}}}else this.json||(delete b.dist,delete b.readme,delete b.users),S=b;a.reportJson(S),this.json||n.push(S)}});pO.inspect.styles.name="cyan";for(let a of n)(a!==n[0]||s)&&this.context.stdout.write(`
`),this.context.stdout.write(`${(0,pO.inspect)(a,{depth:Infinity,colors:!0,compact:!1})}
`);return o.exitCode()}};fE.paths=[["npm","info"]],fE.usage=Re.Usage({category:"Npm-related commands",description:"show information about a package",details:"\n This command fetches information about a package from the npm registry and prints it in a tree format.\n\n The package does not have to be installed locally, but needs to have been published (in particular, local changes will be ignored even for workspaces).\n\n Append `@<range>` to the package argument to provide information specific to the latest version that satisfies the range or to the corresponding tagged version. If the range is invalid or if there is no version satisfying the range, the command will print a warning and fall back to the latest version.\n\n If the `-f,--fields` option is set, it's a comma-separated list of fields which will be used to only display part of the package information.\n\n By default, this command won't return the `dist`, `readme`, and `users` fields, since they are often very long. To explicitly request those fields, explicitly list them with the `--fields` flag or request the output in JSON mode.\n ",examples:[["Show all available information about react (except the `dist`, `readme`, and `users` fields)","yarn npm info react"],["Show all available information about react as valid JSON (including the `dist`, `readme`, and `users` fields)","yarn npm info react --json"],["Show all available information about react@16.12.0","yarn npm info react@16.12.0"],["Show all available information about react@next","yarn npm info react@next"],["Show the description of react","yarn npm info react --fields description"],["Show all available versions of react","yarn npm info react --fields versions"],["Show the readme of react","yarn npm info react --fields readme"],["Show a few fields of react","yarn npm info react --fields homepage,repository"]]});var pge=fE;function dO(t){if(Array.isArray(t)){let e=[];for(let r of t)r=dO(r),r&&e.push(r);return e}else if(typeof t=="object"&&t!==null){let e={};for(let r of Object.keys(t)){if(r.startsWith("_"))continue;let i=dO(t[r]);i&&(e[r]=i)}return e}else return t||null}var dge=ge(em()),hE=class extends Le{constructor(){super(...arguments);this.scope=W.String("-s,--scope",{description:"Login to the registry configured for a given scope"});this.publish=W.Boolean("--publish",!1,{description:"Login to the publish registry"})}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),r=await qb({configuration:e,cwd:this.context.cwd,publish:this.publish,scope:this.scope});return(await Je.start({configuration:e,stdout:this.context.stdout},async n=>{let s=await r9e({registry:r,report:n,stdin:this.context.stdin,stdout:this.context.stdout}),o=`/-/user/org.couchdb.user:${encodeURIComponent(s.name)}`,a=await zt.put(o,s,{attemptedAs:s.name,configuration:e,registry:r,jsonResponse:!0,authType:zt.AuthType.NO_AUTH});return await t9e(r,a.token,{configuration:e,scope:this.scope}),n.reportInfo($.UNNAMED,"Successfully logged in")})).exitCode()}};hE.paths=[["npm","login"]],hE.usage=Re.Usage({category:"Npm-related commands",description:"store new login info to access the npm registry",details:"\n This command will ask you for your username, password, and 2FA One-Time-Password (when it applies). It will then modify your local configuration (in your home folder, never in the project itself) to reference the new tokens thus generated.\n\n Adding the `-s,--scope` flag will cause the authentication to be done against whatever registry is configured for the associated scope (see also `npmScopes`).\n\n Adding the `--publish` flag will cause the authentication to be done against the registry used when publishing the package (see also `publishConfig.registry` and `npmPublishRegistry`).\n ",examples:[["Login to the default registry","yarn npm login"],["Login to the registry linked to the @my-scope registry","yarn npm login --scope my-scope"],["Login to the publish registry for the current package","yarn npm login --publish"]]});var Cge=hE;async function qb({scope:t,publish:e,configuration:r,cwd:i}){return t&&e?br.getScopeRegistry(t,{configuration:r,type:br.RegistryType.PUBLISH_REGISTRY}):t?br.getScopeRegistry(t,{configuration:r}):e?br.getPublishRegistry((await zf(r,i)).manifest,{configuration:r}):br.getDefaultRegistry({configuration:r})}async function t9e(t,e,{configuration:r,scope:i}){let n=o=>a=>{let l=ve.isIndexableObject(a)?a:{},c=l[o],u=ve.isIndexableObject(c)?c:{};return ie(N({},l),{[o]:ie(N({},u),{npmAuthToken:e})})},s=i?{npmScopes:n(i)}:{npmRegistries:n(t)};return await we.updateHomeConfiguration(s)}async function r9e({registry:t,report:e,stdin:r,stdout:i}){if(process.env.TEST_ENV)return{name:process.env.TEST_NPM_USER||"",password:process.env.TEST_NPM_PASSWORD||""};e.reportInfo($.UNNAMED,`Logging in to ${t}`);let n=!1;t.match(/^https:\/\/npm\.pkg\.github\.com(\/|$)/)&&(e.reportInfo($.UNNAMED,"You seem to be using the GitHub Package Registry. Tokens must beLine truncated
This command will list all tags of a package from the npm registry.
If the package is not specified, Yarn will default to the current workspace.
`,examples:[["List all tags of package `my-pkg`","yarn npm tag list my-pkg"]]});var yge=CE;async function mE(t,e){let r=`/-/package${zt.getIdentUrl(t)}/dist-tags`;return zt.get(r,{configuration:e,ident:t,jsonResponse:!0,customErrorMessage:zt.customPackageError})}var EE=class extends Le{constructor(){super(...arguments);this.package=W.String();this.tag=W.String()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await ze.find(e,this.context.cwd);if(!i)throw new ht(r.cwd,this.context.cwd);let n=P.parseDescriptor(this.package,!0),s=n.range;if(!wge.default.valid(s))throw new Pe(`The range ${Ae.pretty(e,n.range,Ae.Type.RANGE)} must be a valid semver version`);let o=br.getPublishRegistry(i.manifest,{configuration:e}),a=Ae.pretty(e,n,Ae.Type.IDENT),l=Ae.pretty(e,s,Ae.Type.RANGE),c=Ae.pretty(e,this.tag,Ae.Type.CODE);return(await Je.start({configuration:e,stdout:this.context.stdout},async g=>{let f=await mE(n,e);Object.prototype.hasOwnProperty.call(f,this.tag)&&f[this.tag]===s&&g.reportWarning($.UNNAMED,`Tag ${c} is already set to version ${l}`);let h=`/-/package${zt.getIdentUrl(n)}/dist-tags/${encodeURIComponent(this.tag)}`;await zt.put(h,s,{configuration:e,registry:o,ident:n,jsonRequest:!0,jsonResponse:!0}),g.reportInfo($.UNNAMED,`Tag ${c} added to version ${l} of package ${a}`)})).exitCode()}};EE.paths=[["npm","tag","add"]],EE.usage=Re.Usage({category:"Npm-related commands",description:"add a tag for a specific version of a package",details:`
This command will add a tag to the npm registry for a specific version of a package. If the tag already exists, it will be overwritten.
`,examples:[["Add a `beta` tag for version `2.3.4-beta.4` of package `my-pkg`","yarn npm tag add my-pkg@2.3.4-beta.4 beta"]]});var Bge=EE;var IE=class extends Le{constructor(){super(...arguments);this.package=W.String();this.tag=W.String()}async execute(){if(this.tag==="latest")throw new Pe("The 'latest' tag cannot be removed.");let e=await we.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await ze.find(e,this.context.cwd);if(!i)throw new ht(r.cwd,this.context.cwd);let n=P.parseIdent(this.package),s=br.getPublishRegistry(i.manifest,{configuration:e}),o=Ae.pretty(e,this.tag,Ae.Type.CODE),a=Ae.pretty(e,n,Ae.Type.IDENT),l=await mE(n,e);if(!Object.prototype.hasOwnProperty.call(l,this.tag))throw new Pe(`${o} is not a tag of package ${a}`);return(await Je.start({configuration:e,stdout:this.context.stdout},async u=>{let g=`/-/package${zt.getIdentUrl(n)}/dist-tags/${encodeURIComponent(this.tag)}`;await zt.del(g,{configuration:e,registry:s,ident:n,jsonResponse:!0}),u.reportInfo($.UNNAMED,`Tag ${o} removed from package ${a}`)})).exitCode()}};IE.paths=[["npm","tag","remove"]],IE.usage=Re.Usage({category:"Npm-related commands",description:"remove a tag from a package",details:`
This command will remove a tag from a package from the npm registry.
`,examples:[["Remove the `beta` tag from package `my-pkg`","yarn npm tag remove my-pkg beta"]]});var bge=IE;var yE=class extends Le{constructor(){super(...arguments);this.scope=W.String("-s,--scope",{description:"Print username for the registry configured for a given scope"});this.publish=W.Boolean("--publish",!1,{description:"Print username for the publish registry"})}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),r;return this.scope&&this.publish?r=br.getScopeRegistry(this.scope,{configuration:e,type:br.RegistryType.PUBLISH_REGISTRY}):this.scope?r=br.getScopeRegistry(this.scope,{configuration:e}):this.publish?r=br.getPublishRegistry((await zf(e,this.context.cwd)).manifest,{configuration:e}):r=br.getDefaultRegistry({configuration:e}),(await Je.start({configuration:e,stdout:this.context.stdout},async n=>{var o,a;let s;try{s=await zt.get("/-/whoami",{configuration:e,registry:r,authType:zt.AuthType.ALWAYS_AUTH,jsonResponse:!0,ident:this.scope?P.makeIdent(this.scope,""):void 0})}catch(l){if(((o=l.response)==null?void 0:o.statusCode)===401||((a=l.response)==null?void 0:a.statusCode)===403){n.reportError($.AUTHENTICATION_INVALID,"Authentication failed - your credentials may have expired");return}else throw l}n.reportInfo($.UNNAMED,s.username)})).exitCode()}};yE.paths=[["npm","whoami"]],yE.usage=Re.Usage({category:"Npm-related commands",description:"display the name of the authenticated user",details:"\n Print the username associated with the current authentication settings to the standard output.\n\n When using `-s,--scope`, the username printed will be the one that matches the authentication settings of the registry associated with the given scope (those settings can be overriden using the `npmRegistries` map, and the registry associated with the scope is configured via the `npmScopes` map).\n\n When using `--publish`, the registry we'll select will by default be the one used when publishing packages (`publishConfig.registry` or `npmPublishRegistry` if available, otherwise we'll fallback to the regular `npmRegistryServer`).\n ",examples:[["Print username for the default registry","yarn npm whoami"],["Print username for the registry on a given scope","yarn npm whoami --scope company"]]});var Qge=yE;var s9e={configuration:{npmPublishAccess:{description:"Default access of the published packages",type:ye.STRING,default:null}},commands:[hge,pge,Cge,Ege,Ige,Bge,yge,bge,Qge]},o9e=s9e;var QO={};ft(QO,{default:()=>w9e,patchUtils:()=>mO});var mO={};ft(mO,{applyPatchFile:()=>zb,diffFolders:()=>wO,extractPackageToDisk:()=>yO,extractPatchFlags:()=>Fge,isParentRequired:()=>IO,loadPatchFiles:()=>QE,makeDescriptor:()=>E9e,makeLocator:()=>EO,parseDescriptor:()=>BE,parseLocator:()=>bE,parsePatchFile:()=>Wb});var wE=class extends Error{constructor(e,r){super(`Cannot apply hunk #${e+1}`);this.hunk=r}};var a9e=/^@@ -(\d+)(,(\d+))? \+(\d+)(,(\d+))? @@.*/;function Qh(t){return x.relative(Ke.root,x.resolve(Ke.root,H.toPortablePath(t)))}function A9e(t){let e=t.trim().match(a9e);if(!e)throw new Error(`Bad header line: '${t}'`);return{original:{start:Math.max(Number(e[1]),1),length:Number(e[3]||1)},patched:{start:Math.max(Number(e[4]),1),length:Number(e[6]||1)}}}var l9e=420,c9e=493,Zr;(function(i){i.Context="context",i.Insertion="insertion",i.Deletion="deletion"})(Zr||(Zr={}));var vge=()=>({semverExclusivity:null,diffLineFromPath:null,diffLineToPath:null,oldMode:null,newMode:null,deletedFileMode:null,newFileMode:null,renameFrom:null,renameTo:null,beforeHash:null,afterHash:null,fromPath:null,toPath:null,hunks:null}),u9e=t=>({header:A9e(t),parts:[]}),g9e={["@"]:"header",["-"]:Zr.Deletion,["+"]:Zr.Insertion,[" "]:Zr.Context,["\\"]:"pragma",undefined:Zr.Context};function h9e(t){let e=[],r=vge(),i="parsing header",n=null,s=null;function o(){n&&(s&&(n.parts.push(s),s=null),r.hunks.push(n),n=null)}function a(){o(),e.push(r),r=vge()}for(let l=0;l<t.length;l++){let c=t[l];if(i==="parsing header")if(c.startsWith("@@"))i="parsing hunks",r.hunks=[],l-=1;else if(c.startsWith("diff --git ")){r&&r.diffLineFromPath&&a();let u=c.match(/^diff --git a\/(.*?) b\/(.*?)\s*$/);if(!u)throw new Error(`Bad diff line: ${c}`);r.diffLineFromPath=u[1],r.diffLineToPath=u[2]}else if(c.startsWith("old mode "))r.oldMode=c.slice("old mode ".length).trim();else if(c.startsWith("new mode "))r.newMode=c.slice("new mode ".length).trim();else if(c.startsWith("deleted file mode "))r.deletedFileMode=c.slice("deleted file mode ".length).trim();else if(c.startsWith("new file mode "))r.newFileMode=c.slice("new file mode ".length).trim();else if(c.startsWith("rename from "))r.renameFrom=c.slice("rename from ".length).trim();else if(c.startsWith("rename to "))r.renameTo=c.slice("rename to ".length).trim();else if(c.startsWith("index ")){let u=c.match(/(\w+)\.\.(\w+)/);if(!u)continue;r.beforeHash=u[1],r.afterHash=u[2]}else c.startsWith("semver exclusivity ")?r.semverExclusivity=c.slice("semver exclusivity ".length).trim():c.startsWith Line truncated
`)+(n.hunk.parts[0].noNewlineAtEndOfFile?"":`
`):"";await e.mkdirpPromise(x.dirname(n.path),{chmod:493,utimes:[Dr.SAFE_TIME,Dr.SAFE_TIME]}),await e.writeFilePromise(n.path,s,{mode:n.mode}),await e.utimesPromise(n.path,Dr.SAFE_TIME,Dr.SAFE_TIME)}break;case"patch":await vh(e,n.path,async()=>{await d9e(n,{baseFs:e,dryRun:r})});break;case"mode change":{let o=(await e.statPromise(n.path)).mode;if(Sge(n.newMode)!==Sge(o))continue;await vh(e,n.path,async()=>{await e.chmodPromise(n.path,n.newMode)})}break;default:ve.assertNever(n);break}}function Sge(t){return(t&64)>0}function kge(t){return t.replace(/\s+$/,"")}function C9e(t,e){return kge(t)===kge(e)}async function d9e({hunks:t,path:e},{baseFs:r,dryRun:i=!1}){let n=await r.statSync(e).mode,o=(await r.readFileSync(e,"utf8")).split(/\n/),a=[],l=0,c=0;for(let g of t){let f=Math.max(c,g.header.patched.start+l),h=Math.max(0,f-c),p=Math.max(0,o.length-f-g.header.original.length),m=Math.max(h,p),y=0,b=0,S=null;for(;y<=m;){if(y<=h&&(b=f-y,S=xge(g,o,b),S!==null)){y=-y;break}if(y<=p&&(b=f+y,S=xge(g,o,b),S!==null))break;y+=1}if(S===null)throw new wE(t.indexOf(g),g);a.push(S),l+=y,c=b+g.header.original.length}if(i)return;let u=0;for(let g of a)for(let f of g)switch(f.type){case"splice":{let h=f.index+u;o.splice(h,f.numToDelete,...f.linesToInsert),u+=f.linesToInsert.length-f.numToDelete}break;case"pop":o.pop();break;case"push":o.push(f.line);break;default:ve.assertNever(f);break}await r.writeFilePromise(e,o.join(`
`),{mode:n})}function xge(t,e,r){let i=[];for(let n of t.parts)switch(n.type){case Zr.Context:case Zr.Deletion:{for(let s of n.lines){let o=e[r];if(o==null||!C9e(o,s))return null;r+=1}n.type===Zr.Deletion&&(i.push({type:"splice",index:r-n.lines.length,numToDelete:n.lines.length,linesToInsert:[]}),n.noNewlineAtEndOfFile&&i.push({type:"push",line:""}))}break;case Zr.Insertion:i.push({type:"splice",index:r,numToDelete:0,linesToInsert:n.lines}),n.noNewlineAtEndOfFile&&i.push({type:"pop"});break;default:ve.assertNever(n.type);break}return i}var m9e=/^builtin<([^>]+)>$/;function Pge(t,e){let{source:r,selector:i,params:n}=P.parseRange(t);if(r===null)throw new Error("Patch locators must explicitly define their source");let s=i?i.split(/&/).map(c=>H.toPortablePath(c)):[],o=n&&typeof n.locator=="string"?P.parseLocator(n.locator):null,a=n&&typeof n.version=="string"?n.version:null,l=e(r);return{parentLocator:o,sourceItem:l,patchPaths:s,sourceVersion:a}}function BE(t){let i=Pge(t.range,P.parseDescriptor),{sourceItem:e}=i,r=Tr(i,["sourceItem"]);return ie(N({},r),{sourceDescriptor:e})}function bE(t){let i=Pge(t.reference,P.parseLocator),{sourceItem:e}=i,r=Tr(i,["sourceItem"]);return ie(N({},r),{sourceLocator:e})}function Dge({parentLocator:t,sourceItem:e,patchPaths:r,sourceVersion:i,patchHash:n},s){let o=t!==null?{locator:P.stringifyLocator(t)}:{},a=typeof i!="undefined"?{version:i}:{},l=typeof n!="undefined"?{hash:n}:{};return P.makeRange({protocol:"patch:",source:s(e),selector:r.join("&"),params:N(N(N({},a),l),o)})}function E9e(t,{parentLocator:e,sourceDescriptor:r,patchPaths:i}){return P.makeLocator(t,Dge({parentLocator:e,sourceItem:r,patchPaths:i},P.stringifyDescriptor))}function EO(t,{parentLocator:e,sourcePackage:r,patchPaths:i,patchHash:n}){return P.makeLocator(t,Dge({parentLocator:e,sourceItem:r,sourceVersion:r.version,patchPaths:i,patchHash:n},P.stringifyLocator))}function Rge({onAbsolute:t,onRelative:e,onBuiltin:r},i){i.startsWith("~")&&(i=i.slice(1));let s=i.match(m9e);return s!==null?r(s[1]):x.isAbsolute(i)?t(i):e(i)}function Fge(t){let e=t.startsWith("~");return e&&(t=t.slice(1)),{optional:e}}function IO(t){return Rge({onAbsolute:()=>!1,onRelative:()=>!0,onBuiltin:()=>!1},t)}async function QE(t,e,r){let i=t!==null?await r.fetcher.fetch(t,r):null,n=i&&i.localPath?{packageFs:new _t(Ke.root),prefixPath:x.relative(Ke.root,i.localPath)}:i;i&&i!==n&&i.releaseFs&&i.releaseFs();let s=await ve.releaseAfterUseAsync(async()=>await Promise.all(e.map(async o=>{let a=Fge(o),l=await Rge({onAbsolute:async()=>await K.readFilePromise(o,"utf8"),onRelative:async()=>{if(n===null)throw new Error("Assertion failed: The parent locator should have been fetched");return await n.packageFs.readFilePromise(x.join(n.prefixPath,o),"utf8")},onBuiltin:async c=>await r.project.configuration.firstHook(u=>u.getBuiltinPatch,r.project,c)},o);return ie(N({},a),{source:l})})));for(let o of s)typeof o.source=="string"&&(o.source=o.source.replace(/\r\n?/g,`
`));return s}async function yO(t,{cache:e,project:r}){let i=r.storedPackages.get(t.locatorHash);if(typeof i=="undefined")throw new Error("Assertion failed: Expected the package to be registered");let n=r.storedChecksums,s=new pi,o=r.configuration.makeFetcher(),a=await o.fetch(t,{cache:e,project:r,fetcher:o,checksums:n,report:s}),l=await K.mktempPromise(),c=x.join(l,"source"),u=x.join(l,"user"),g=x.join(l,".yarn-patch.json");return await Promise.all([K.copyPromise(c,a.prefixPath,{baseFs:a.packageFs}),K.copyPromise(u,a.prefixPath,{baseFs:a.packageFs}),K.writeJsonPromise(g,{locator:P.stringifyLocator(t),version:i.version})]),K.detachTemp(l),u}async function wO(t,e){let r=H.fromPortablePath(t).replace(/\\/g,"/"),i=H.fromPortablePath(e).replace(/\\/g,"/"),{stdout:n,stderr:s}=await Fr.execvp("git",["-c","core.safecrlf=false","diff","--src-prefix=a/","--dst-prefix=b/","--ignore-cr-at-eol","--full-index","--no-index","--text",r,i],{cwd:H.toPortablePath(process.cwd()),env:ie(N({},process.env),{GIT_CONFIG_NOSYSTEM:"1",HOME:"",XDG_CONFIG_HOME:"",USERPROFILE:""})});if(s.length>0)throw new Error(`Unable to diff directories. Make sure you have a recent version of 'git' available in PATH.
The following error was reported by 'git':
${s}`);let o=r.startsWith("/")?a=>a.slice(1):a=>a;return n.replace(new RegExp(`(a|b)(${ve.escapeRegExp(`/${o(r)}/`)})`,"g"),"$1/").replace(new RegExp(`(a|b)${ve.escapeRegExp(`/${o(i)}/`)}`,"g"),"$1/").replace(new RegExp(ve.escapeRegExp(`${r}/`),"g"),"").replace(new RegExp(ve.escapeRegExp(`${i}/`),"g"),"")}function Nge(t,{configuration:e,report:r}){for(let i of t.parts)for(let n of i.lines)switch(i.type){case Zr.Context:r.reportInfo(null,` ${Ae.pretty(e,n,"grey")}`);break;case Zr.Deletion:r.reportError($.FROZEN_LOCKFILE_EXCEPTION,`- ${Ae.pretty(e,n,Ae.Type.REMOVED)}`);break;case Zr.Insertion:r.reportError($.FROZEN_LOCKFILE_EXCEPTION,`+ ${Ae.pretty(e,n,Ae.Type.ADDED)}`);break;default:ve.assertNever(i.type)}}var BO=class{supports(e,r){return!!e.reference.startsWith("patch:")}getLocalPath(e,r){return null}async fetch(e,r){let i=r.checksums.get(e.locatorHash)||null,[n,s,o]=await r.cache.fetchPackageFromCache(e,i,N({onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${P.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the disk`),loader:()=>this.patchPackage(e,r),skipIntegrityCheck:r.skipIntegrityCheck},r.cacheOptions));return{packageFs:n,releaseFs:s,prefixPath:P.getIdentVendorPath(e),localPath:this.getLocalPath(e,r),checksum:o}}async patchPackage(e,r){let{parentLocator:i,sourceLocator:n,sourceVersion:s,patchPaths:o}=bE(e),a=await QE(i,o,r),l=await K.mktempPromise(),c=x.join(l,"current.zip"),u=await r.fetcher.fetch(n,r),g=P.getIdentVendorPath(e),f=await fn(),h=new Ai(c,{libzip:f,create:!0,level:r.project.configuration.get("compressionLevel")});await ve.releaseAfterUseAsync(async()=>{await h.copyPromise(g,u.prefixPath,{baseFs:u.packageFs,stableSort:!0})},u.releaseFs),h.saveAndClose();for(let{source:p,optional:m}of a){if(p===null)continue;let y=new Ai(c,{libzip:f,level:r.project.configuration.get("compressionLevel")}),b=new _t(x.resolve(Ke.root,g),{baseFs:y});try{await zb(Wb(p),{baseFs:b,version:s})}catch(S){if(!(S instanceof wE))throw S;let k=r.project.configuration.get("enableInlineHunks"),T=!k&&!m?" (set enableInlineHunks for details)":"",Y=`${P.prettyLocator(r.project.configuration,e)}: ${S.message}${T}`,j=Z=>{!k||Nge(S.hunk,{configuration:r.project.configuration,report:Z})};if(y.discardAndClose(),m){r.report.reportWarningOnce($.PATCH_HUNK_FAILED,Y,{reportExtra:j});continue}else throw new ct($.PATCH_HUNK_FAILED,Y,j)}y.saveAndClose()}return new Ai(c,{libzip:f,level:r.project.configuration.get("compressionLevel")})}};var I9e=3,bO=class{supportsDescriptor(e,r){return!!e.range.startsWith("patch:")}supportsLocator(e,r){return!!e.reference.startsWith("patch:")}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,i){let{patchPaths:n}=BE(e);return n.every(s=>!IO(s))?e:P.bindDescriptor(e,{locator:P.stringifyLocator(r)})}getResolutionDependencies(e,r){let{sourceDescriptor:i}=BE(e);return[i]}async getCandidates(e,r,i){if(!i.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let{parentLocator:n,sourceDescriptor:s,patchPaths:o}=BE(e),a=await QE(n,o,i.fetchOptions),l=r.get(s.descriptorHash);if(typeof l=="undefined")throw new Error("Assertion failed: The dependency should have been resolved");let c=Dn.makeHash(`${I9e}`,...a.map(u=>JSON.stringify(u))).slice(0,6);return[EO(e,{parentLocator:n,sourcePackage:l,patchPaths:o,patchHash:c})]}async getSatisfying(e,r,i){return null}async resolve(e,r){let{sourceLocator:i}=bE(e),n=await r.resolver.resolve(i,r);return N(N({},n),e)}};var vE=class extends Le{constructor(){super(...arguments);this.save=W.Boolean("-s,--save",!1,{description:"Add the patch to your resolution entries"});this.patchFolder=W.String()}async execute(){let e=await we.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await ze.find(e,this.context.cwd);if(!i)throw new ht(r.cwd,this.context.cwd);await r.restoreInstallState();let n=x.resolve(this.context.cwd,H.toPortablePath(this.patchFolder)),s=x.join(n,"../source"),o=x.join(n,"../.yarn-patch.json");if(!K.existsSync(s))throw new Pe("The argument folder didn't get created by 'yarn patch'");let a=await wO(s,n),l=await K.readJsonPromise(o),c=P.parseLocator(l.locator,!0);if(!r.storedPackages.has(c.locatorHash))throw new Pe("No package found in the project for the given locator");if(!this.save){this.context.stdout.write(a);return}let u=e.get("patchFolder"),g=x.join(u,`${P.slugifyLocator(c)}.patch`);await K.mkdirPromise(u,{recursive:!0}),await K.writeFilePromise(g,a);let f=x.relative(r.cwd,g);r.topLevelWorkspace.manifest.resolutions.push({pattern:{descriptor:{fullName:P.stringifyIdent(c),description:l.version}},reference:`patch:${P.stringifyLocator(c)}#${f}`}),await r.persist()}};vE.paths=[["patch-commit"]],vE.usage=Re.Usage({description:"generate a patch out of a directory",details:"\n By default, this will print a patchfile on stdout based on the diff between the folder passed in and the original version of the package. Line truncated
${o.map(a=>`
- ${P.prettyLocator(e,a)}`).join("")}`);s=o[0]}if(!r.storedPackages.has(s.locatorHash))throw new Pe("No package found in the project for the given locator");await Je.start({configuration:e,json:this.json,stdout:this.context.stdout},async o=>{let a=await yO(s,{cache:n,project:r});o.reportJson({locator:P.stringifyLocator(s),path:H.fromPortablePath(a)}),o.reportInfo($.UNNAMED,`Package ${P.prettyLocator(e,s)} got extracted with success!`),o.reportInfo($.UNNAMED,`You can now edit the following folder: ${Ae.pretty(e,H.fromPortablePath(a),"magenta")}`),o.reportInfo($.UNNAMED,`Once you are done run ${Ae.pretty(e,`yarn patch-commit -s ${process.platform==="win32"?'"':""}${H.fromPortablePath(a)}${process.platform==="win32"?'"':""}`,"cyan")} and Yarn will store a patchfile based on your changes.`)})}};SE.paths=[["patch"]],SE.usage=Re.Usage({description:"prepare a package for patching",details:"\n This command will cause a package to be extracted in a temporary directory intended to be editable at will.\n \n Once you're done with your changes, run `yarn patch-commit -s <path>` (with `<path>` being the temporary directory you received) to generate a patchfile and register it into your top-level manifest via the `patch:` protocol. Run `yarn patch-commit -h` for more details.\n "});var Tge=SE;var y9e={configuration:{enableInlineHunks:{description:"If true, the installs will print unmatched patch hunks",type:ye.BOOLEAN,default:!1},patchFolder:{description:"Folder where the patch files must be written",type:ye.ABSOLUTE_PATH,default:"./.yarn/patches"}},commands:[Lge,Tge],fetchers:[BO],resolvers:[bO]},w9e=y9e;var xO={};ft(xO,{default:()=>Q9e});var vO=class{supportsPackage(e,r){return this.isEnabled(r)}async findPackageLocation(e,r){if(!this.isEnabled(r))throw new Error("Assertion failed: Expected the pnpm linker to be enabled");let i=SO(),n=r.project.installersCustomData.get(i);if(!n)throw new Pe(`The project in ${Ae.pretty(r.project.configuration,`${r.project.cwd}/package.json`,Ae.Type.PATH)} doesn't seem to have been installed - running an install there might help`);let s=n.pathByLocator.get(e.locatorHash);if(typeof s=="undefined")throw new Pe(`Couldn't find ${P.prettyLocator(r.project.configuration,e)} in the currently installed pnpm map - running an install might help`);return s}async findPackageLocator(e,r){if(!this.isEnabled(r))return null;let i=SO(),n=r.project.installersCustomData.get(i);if(!n)throw new Pe(`The project in ${Ae.pretty(r.project.configuration,`${r.project.cwd}/package.json`,Ae.Type.PATH)} doesn't seem to have been installed - running an install there might help`);let s=e.match(/(^.*\/node_modules\/(@[^/]*\/)?[^/]+)(\/.*$)/);if(s){let l=n.locatorByPath.get(s[1]);if(l)return l}let o=e,a=e;do{a=o,o=x.dirname(a);let l=n.locatorByPath.get(a);if(l)return l}while(o!==a);return null}makeInstaller(e){return new Oge(e)}isEnabled(e){return e.project.configuration.get("nodeLinker")==="pnpm"}},Oge=class{constructor(e){this.opts=e;this.asyncActions=new ve.AsyncActions(10);this.customData={pathByLocator:new Map,locatorByPath:new Map}}getCustomDataKey(){return SO()}attachCustomData(e){}async installPackage(e,r,i){switch(e.linkType){case Qt.SOFT:return this.installPackageSoft(e,r,i);case Qt.HARD:return this.installPackageHard(e,r,i)}throw new Error("Assertion failed: Unsupported package link type")}async installPackageSoft(e,r,i){let n=x.resolve(r.packageFs.getRealPath(),r.prefixPath);return this.customData.pathByLocator.set(e.locatorHash,n),{packageLocation:n,buildDirective:null}}async installPackageHard(e,r,i){var u;let n=B9e(e,{project:this.opts.project});this.customData.locatorByPath.set(n,P.stringifyLocator(e)),this.customData.pathByLocator.set(e.locatorHash,n),i.holdFetchResult(this.asyncActions.set(e.locatorHash,async()=>{await K.mkdirPromise(n,{recursive:!0}),await K.copyPromise(n,r.prefixPath,{baseFs:r.packageFs,overwrite:!1})}));let o=P.isVirtualLocator(e)?P.devirtualizeLocator(e):e,a={manifest:(u=await At.tryFind(r.prefixPath,{baseFs:r.packageFs}))!=null?u:new At,misc:{hasBindingGyp:ha.hasBindingGyp(r)}},l=this.opts.project.getDependencyMeta(o,e.version),c=ha.extractBuildScripts(e,a,l,{configuration:this.opts.project.configuration,report:this.opts.report});return{packageLocation:n,buildDirective:c}}async attachInternalDependencies(e,r){this.opts.project.configuration.get("nodeLinker")==="pnpm"&&(!Uge(e,{project:this.opts.project})||this.asyncActions.reduce(e.locatorHash,async i=>{await i;let n=this.customData.pathByLocator.get(e.locatorHash);if(typeof n=="undefined")throw new Error(`Assertion failed: Expected the package to have been registered (${P.stringifyLocator(e)})`);let s=x.join(n,Pt.nodeModules),o=[],a=await Hge(s);for(let[l,c]of r){let u=c;Uge(c,{project:this.opts.project})||(this.opts.report.reportWarning($.UNNAMED,"The pnpm linker doesn't support providing different versions to workspaces' peer dependencies"),u=P.devirtualizeLocator(c));let g=this.customData.pathByLocator.get(u.lLine truncated
/*!
* buildToken
* Builds OAuth token prefix (helper function)
*
* @name buildToken
* @function
* @param {GitUrl} obj The parsed Git url object.
* @return {String} token prefix
*/
/*!
* fill-range <https://github.com/jonschlinkert/fill-range>
*
* Copyright (c) 2014-present, Jon Schlinkert.
* Licensed under the MIT License.
*/
/*!
* is-extglob <https://github.com/jonschlinkert/is-extglob>
*
* Copyright (c) 2014-2016, Jon Schlinkert.
* Licensed under the MIT License.
*/
/*!
* is-glob <https://github.com/jonschlinkert/is-glob>
*
* Copyright (c) 2014-2017, Jon Schlinkert.
* Released under the MIT License.
*/
/*!
* is-number <https://github.com/jonschlinkert/is-number>
*
* Copyright (c) 2014-present, Jon Schlinkert.
* Released under the MIT License.
*/
/*!
* is-windows <https://github.com/jonschlinkert/is-windows>
*
* Copyright © 2015-2018, Jon Schlinkert.
* Released under the MIT License.
*/
/*!
* to-regex-range <https://github.com/micromatch/to-regex-range>
*
* Copyright (c) 2015-present, Jon Schlinkert.
* Released under the MIT License.
*/
+942
View File
@@ -0,0 +1,942 @@
#!/usr/bin/env node
/* eslint-disable */
//prettier-ignore
(()=>{var xGe=Object.create;var mU=Object.defineProperty;var kGe=Object.getOwnPropertyDescriptor;var QGe=Object.getOwnPropertyNames;var TGe=Object.getPrototypeOf,RGe=Object.prototype.hasOwnProperty;var Ie=(t=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(t,{get:(e,r)=>(typeof require<"u"?require:e)[r]}):t)(function(t){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+t+'" is not supported')});var Xe=(t,e)=>()=>(t&&(e=t(t=0)),e);var _=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),Vt=(t,e)=>{for(var r in e)mU(t,r,{get:e[r],enumerable:!0})},FGe=(t,e,r,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of QGe(e))!RGe.call(t,a)&&a!==r&&mU(t,a,{get:()=>e[a],enumerable:!(s=kGe(e,a))||s.enumerable});return t};var ut=(t,e,r)=>(r=t!=null?xGe(TGe(t)):{},FGe(e||!t||!t.__esModule?mU(r,"default",{value:t,enumerable:!0}):r,t));var fi={};Vt(fi,{SAFE_TIME:()=>WZ,S_IFDIR:()=>JP,S_IFLNK:()=>KP,S_IFMT:()=>Mf,S_IFREG:()=>N2});var Mf,JP,N2,KP,WZ,YZ=Xe(()=>{Mf=61440,JP=16384,N2=32768,KP=40960,WZ=456789e3});var or={};Vt(or,{EBADF:()=>Mo,EBUSY:()=>NGe,EEXIST:()=>HGe,EINVAL:()=>LGe,EISDIR:()=>_Ge,ENOENT:()=>MGe,ENOSYS:()=>OGe,ENOTDIR:()=>UGe,ENOTEMPTY:()=>GGe,EOPNOTSUPP:()=>qGe,EROFS:()=>jGe,ERR_DIR_CLOSED:()=>yU});function Cc(t,e){return Object.assign(new Error(`${t}: ${e}`),{code:t})}function NGe(t){return Cc("EBUSY",t)}function OGe(t,e){return Cc("ENOSYS",`${t}, ${e}`)}function LGe(t){return Cc("EINVAL",`invalid argument, ${t}`)}function Mo(t){return Cc("EBADF",`bad file descriptor, ${t}`)}function MGe(t){return Cc("ENOENT",`no such file or directory, ${t}`)}function UGe(t){return Cc("ENOTDIR",`not a directory, ${t}`)}function _Ge(t){return Cc("EISDIR",`illegal operation on a directory, ${t}`)}function HGe(t){return Cc("EEXIST",`file already exists, ${t}`)}function jGe(t){return Cc("EROFS",`read-only filesystem, ${t}`)}function GGe(t){return Cc("ENOTEMPTY",`directory not empty, ${t}`)}function qGe(t){return Cc("EOPNOTSUPP",`operation not supported, ${t}`)}function yU(){return Cc("ERR_DIR_CLOSED","Directory handle was closed")}var zP=Xe(()=>{});var $a={};Vt($a,{BigIntStatsEntry:()=>iE,DEFAULT_MODE:()=>CU,DirEntry:()=>EU,StatEntry:()=>nE,areStatsEqual:()=>wU,clearStats:()=>XP,convertToBigIntStats:()=>YGe,makeDefaultStats:()=>VZ,makeEmptyStats:()=>WGe});function VZ(){return new nE}function WGe(){return XP(VZ())}function XP(t){for(let e in t)if(Object.hasOwn(t,e)){let r=t[e];typeof r=="number"?t[e]=0:typeof r=="bigint"?t[e]=BigInt(0):IU.types.isDate(r)&&(t[e]=new Date(0))}return t}function YGe(t){let e=new iE;for(let r in t)if(Object.hasOwn(t,r)){let s=t[r];typeof s=="number"?e[r]=BigInt(s):IU.types.isDate(s)&&(e[r]=new Date(s))}return e.atimeNs=e.atimeMs*BigInt(1e6),e.mtimeNs=e.mtimeMs*BigInt(1e6),e.ctimeNs=e.ctimeMs*BigInt(1e6),e.birthtimeNs=e.birthtimeMs*BigInt(1e6),e}function wU(t,e){if(t.atimeMs!==e.atimeMs||t.birthtimeMs!==e.birthtimeMs||t.blksize!==e.blksize||t.blocks!==e.blocks||t.ctimeMs!==e.ctimeMs||t.dev!==e.dev||t.gid!==e.gid||t.ino!==e.ino||t.isBlockDevice()!==e.isBlockDevice()||t.isCharacterDevice()!==e.isCharacterDevice()||t.isDirectory()!==e.isDirectory()||t.isFIFO()!==e.isFIFO()||t.isFile()!==e.isFile()||t.isSocket()!==e.isSocket()||t.isSymbolicLink()!==e.isSymbolicLink()||t.mode!==e.mode||t.mtimeMs!==e.mtimeMs||t.nlink!==e.nlink||t.rdev!==e.rdev||t.size!==e.size||t.uid!==e.uid)return!1;let r=t,s=e;return!(r.atimeNs!==s.atimeNs||r.mtimeNs!==s.mtimeNs||r.ctimeNs!==s.ctimeNs||r.birthtimeNs!==s.birthtimeNs)}var IU,CU,EU,nE,iE,BU=Xe(()=>{IU=ut(Ie("util")),CU=33188,EU=class{constructor(){this.name="";this.path="";this.mode=0}isBlockDevice(){return!1}isCharacterDevice(){return!1}isDirectory(){return(this.mode&61440)===16384}isFIFO(){return!1}isFile(){return(this.mode&61440)===32768}isSocket(){return!1}isSymbolicLink(){return(this.mode&61440)===40960}},nE=class{constructor(){this.uid=0;this.gid=0;this.size=0;this.blksize=0;this.atimeMs=0;this.mtimeMs=0;this.ctimeMs=0;this.birthtimeMs=0;this.atime=new Date(0);this.mtime=new Date(0);this.ctime=new Date(0);this.birthtime=new Date(0);this.dev=0;this.ino=0;this.mode=CU;this.nlink=1;this.rdev=0;this.blocks=1}isBlockDevice(){return!1}isCharacterDevice(){return!1}isDirectory(){return(this.mode&61440)===16384}isFIFO(){return!1}isFile(){return(this.mode&61440)===32768}isSocket(){return!1}isSymbolicLink(){return(this.mode&61440)===40960}},iE=class{constructor(){this.uid=BigInt(0);this.gid=BigInt(0);this.size=BigInt(0);this.blksize=BigInt(0);this.atimeMs=BigInt(0);this.mtimeMs=BigInt(0);this.ctimeMs=BigInt(0);this.birthtimeMs=BigInt(0);this.atimeNs=BigInt(0);this.mtimeNs=BigInt(0);this.ctimeNs=BigInt(0);this.birthtimeNs=BigInt(0);this.atime=new Date(0);this.mtime=new Date(0);this.ctime=new Date(0);this.birthtime=new Date(0);this.dev=BigInt(0);this.ino=BigInt(0);this.mode=BigInt(CU);this.nlink=BigInt(1);this.rdev=BigInt(0);this.blocks=BigInt(1)}isBlockDevice(){return!1}isCharacterDevice(){return!1}isDirectory(){reLine truncated
`).length,s=e.length-r;return r>s?`\r
`:`
`}function Ed(t,e){return e.replace(/\r?\n/g,s5e(t))}var r$,n$,mp,Uf,Id=Xe(()=>{r$=Ie("crypto"),n$=Ie("os");DU();el();mp=class{constructor(e){this.pathUtils=e}async*genTraversePromise(e,{stableSort:r=!1}={}){let s=[e];for(;s.length>0;){let a=s.shift();if((await this.lstatPromise(a)).isDirectory()){let c=await this.readdirPromise(a);if(r)for(let f of c.sort())s.push(this.pathUtils.join(a,f));else throw new Error("Not supported")}else yield a}}async checksumFilePromise(e,{algorithm:r="sha512"}={}){let s=await this.openPromise(e,"r");try{let n=Buffer.allocUnsafeSlow(65536),c=(0,r$.createHash)(r),f=0;for(;(f=await this.readPromise(s,n,0,65536))!==0;)c.update(f===65536?n:n.slice(0,f));return c.digest("hex")}finally{await this.closePromise(s)}}async removePromise(e,{recursive:r=!0,maxRetries:s=5}={}){let a;try{a=await this.lstatPromise(e)}catch(n){if(n.code==="ENOENT")return;throw n}if(a.isDirectory()){if(r){let n=await this.readdirPromise(e);await Promise.all(n.map(c=>this.removePromise(this.pathUtils.resolve(e,c))))}for(let n=0;n<=s;n++)try{await this.rmdirPromise(e);break}catch(c){if(c.code!=="EBUSY"&&c.code!=="ENOTEMPTY")throw c;n<s&&await new Promise(f=>setTimeout(f,n*100))}}else await this.unlinkPromise(e)}removeSync(e,{recursive:r=!0}={}){let s;try{s=this.lstatSync(e)}catch(a){if(a.code==="ENOENT")return;throw a}if(s.isDirectory()){if(r)for(let a of this.readdirSync(e))this.removeSync(this.pathUtils.resolve(e,a));this.rmdirSync(e)}else this.unlinkSync(e)}async mkdirpPromise(e,{chmod:r,utimes:s}={}){if(e=this.resolve(e),e===this.pathUtils.dirname(e))return;let a=e.split(this.pathUtils.sep),n;for(let c=2;c<=a.length;++c){let f=a.slice(0,c).join(this.pathUtils.sep);if(!this.existsSync(f)){try{await this.mkdirPromise(f)}catch(p){if(p.code==="EEXIST")continue;throw p}if(n??=f,r!=null&&await this.chmodPromise(f,r),s!=null)await this.utimesPromise(f,s[0],s[1]);else{let p=await this.statPromise(this.pathUtils.dirname(f));await this.utimesPromise(f,p.atime,p.mtime)}}}return n}mkdirpSync(e,{chmod:r,utimes:s}={}){if(e=this.resolve(e),e===this.pathUtils.dirname(e))return;let a=e.split(this.pathUtils.sep),n;for(let c=2;c<=a.length;++c){let f=a.slice(0,c).join(this.pathUtils.sep);if(!this.existsSync(f)){try{this.mkdirSync(f)}catch(p){if(p.code==="EEXIST")continue;throw p}if(n??=f,r!=null&&this.chmodSync(f,r),s!=null)this.utimesSync(f,s[0],s[1]);else{let p=this.statSync(this.pathUtils.dirname(f));this.utimesSync(f,p.atime,p.mtime)}}}return n}async copyPromise(e,r,{baseFs:s=this,overwrite:a=!0,stableSort:n=!1,stableTime:c=!1,linkStrategy:f=null}={}){return await zZ(this,e,s,r,{overwrite:a,stableSort:n,stableTime:c,linkStrategy:f})}copySync(e,r,{baseFs:s=this,overwrite:a=!0}={}){let n=s.lstatSync(r),c=this.existsSync(e);if(n.isDirectory()){this.mkdirpSync(e);let p=s.readdirSync(r);for(let h of p)this.copySync(this.pathUtils.join(e,h),s.pathUtils.join(r,h),{baseFs:s,overwrite:a})}else if(n.isFile()){if(!c||a){c&&this.removeSync(e);let p=s.readFileSync(r);this.writeFileSync(e,p)}}else if(n.isSymbolicLink()){if(!c||a){c&&this.removeSync(e);let p=s.readlinkSync(r);this.symlinkSync(ZP(this.pathUtils,p),e)}}else throw new Error(`Unsupported file type (file: ${r}, mode: 0o${n.mode.toString(8).padStart(6,"0")})`);let f=n.mode&511;this.chmodSync(e,f)}async changeFilePromise(e,r,s={}){return Buffer.isBuffer(r)?this.changeFileBufferPromise(e,r,s):this.changeFileTextPromise(e,r,s)}async changeFileBufferPromise(e,r,{mode:s}={}){let a=Buffer.alloc(0);try{a=await this.readFilePromise(e)}catch{}Buffer.compare(a,r)!==0&&await this.writeFilePromise(e,r,{mode:s})}async changeFileTextPromise(e,r,{automaticNewlines:s,mode:a}={}){let n="";try{n=await this.readFilePromise(e,"utf8")}catch{}let c=s?Ed(n,r):r;n!==c&&await this.writeFilePromise(e,c,{mode:a})}changeFileSync(e,r,s={}){return Buffer.isBuffer(r)?this.changeFileBufferSync(e,r,s):this.changeFileTextSync(e,r,s)}changeFileBufferSync(e,r,{mode:s}={}){let a=Buffer.alloc(0);try{a=this.readFileSync(e)}catch{}Buffer.compare(a,r)!==0&&this.writeFileSync(e,r,{mode:s})}changeFileTextSync(e,r,{automaticNewlines:s=!1,mode:a}={}){let n="";try{n=this.readFileSync(e,"utf8")}catch{}let c=s?Ed(n,r):r;n!==c&&this.writeFileSync(e,c,{mode:a})}async movePromise(e,r){try{await this.renamePromise(e,r)}catch(s){if(s.code==="EXDEV")await this.copyPromise(r,e),await this.removePromise(e);else throw s}}moveSync(e,r){try{this.renameSync(e,r)}catch(s){if(s.code==="EXDEV")this.copySync(r,e),this.removeSync(e);else throw s}}async lockPromise(e,r){let s=`${e}.flock`,a=1e3/60,n=Date.now(),c=null,f=async()=>{let p;try{[p]=await this.readJsonPromise(s)}catch{return Date.now()-n<500}try{return process.kill(p,0),!0}catch{return!1}};for(;c===null;)try{c=await this.openPromise(s,"wx")}catch(p){if(p.code==="EEXIST"){if(!await f())try{await this.unlinkPromise(s);continue}catch{}if(Date.now()-n<60*1e3)await new Promise(h=>setTimeout(h,a));else throw new Error(`Couldn't acquire a lock in a reasonable time (via ${s})`)}else throw Line truncated
`)}writeJsonSync(e,r,{compact:s=!1}={}){let a=s?0:2;return this.writeFileSync(e,`${JSON.stringify(r,null,a)}
`)}async preserveTimePromise(e,r){let s=await this.lstatPromise(e),a=await r();typeof a<"u"&&(e=a),await this.lutimesPromise(e,s.atime,s.mtime)}async preserveTimeSync(e,r){let s=this.lstatSync(e),a=r();typeof a<"u"&&(e=a),this.lutimesSync(e,s.atime,s.mtime)}},Uf=class extends mp{constructor(){super(J)}}});var _s,yp=Xe(()=>{Id();_s=class extends mp{getExtractHint(e){return this.baseFs.getExtractHint(e)}resolve(e){return this.mapFromBase(this.baseFs.resolve(this.mapToBase(e)))}getRealPath(){return this.mapFromBase(this.baseFs.getRealPath())}async openPromise(e,r,s){return this.baseFs.openPromise(this.mapToBase(e),r,s)}openSync(e,r,s){return this.baseFs.openSync(this.mapToBase(e),r,s)}async opendirPromise(e,r){return Object.assign(await this.baseFs.opendirPromise(this.mapToBase(e),r),{path:e})}opendirSync(e,r){return Object.assign(this.baseFs.opendirSync(this.mapToBase(e),r),{path:e})}async readPromise(e,r,s,a,n){return await this.baseFs.readPromise(e,r,s,a,n)}readSync(e,r,s,a,n){return this.baseFs.readSync(e,r,s,a,n)}async writePromise(e,r,s,a,n){return typeof r=="string"?await this.baseFs.writePromise(e,r,s):await this.baseFs.writePromise(e,r,s,a,n)}writeSync(e,r,s,a,n){return typeof r=="string"?this.baseFs.writeSync(e,r,s):this.baseFs.writeSync(e,r,s,a,n)}async closePromise(e){return this.baseFs.closePromise(e)}closeSync(e){this.baseFs.closeSync(e)}createReadStream(e,r){return this.baseFs.createReadStream(e!==null?this.mapToBase(e):e,r)}createWriteStream(e,r){return this.baseFs.createWriteStream(e!==null?this.mapToBase(e):e,r)}async realpathPromise(e){return this.mapFromBase(await this.baseFs.realpathPromise(this.mapToBase(e)))}realpathSync(e){return this.mapFromBase(this.baseFs.realpathSync(this.mapToBase(e)))}async existsPromise(e){return this.baseFs.existsPromise(this.mapToBase(e))}existsSync(e){return this.baseFs.existsSync(this.mapToBase(e))}accessSync(e,r){return this.baseFs.accessSync(this.mapToBase(e),r)}async accessPromise(e,r){return this.baseFs.accessPromise(this.mapToBase(e),r)}async statPromise(e,r){return this.baseFs.statPromise(this.mapToBase(e),r)}statSync(e,r){return this.baseFs.statSync(this.mapToBase(e),r)}async fstatPromise(e,r){return this.baseFs.fstatPromise(e,r)}fstatSync(e,r){return this.baseFs.fstatSync(e,r)}lstatPromise(e,r){return this.baseFs.lstatPromise(this.mapToBase(e),r)}lstatSync(e,r){return this.baseFs.lstatSync(this.mapToBase(e),r)}async fchmodPromise(e,r){return this.baseFs.fchmodPromise(e,r)}fchmodSync(e,r){return this.baseFs.fchmodSync(e,r)}async chmodPromise(e,r){return this.baseFs.chmodPromise(this.mapToBase(e),r)}chmodSync(e,r){return this.baseFs.chmodSync(this.mapToBase(e),r)}async fchownPromise(e,r,s){return this.baseFs.fchownPromise(e,r,s)}fchownSync(e,r,s){return this.baseFs.fchownSync(e,r,s)}async chownPromise(e,r,s){return this.baseFs.chownPromise(this.mapToBase(e),r,s)}chownSync(e,r,s){return this.baseFs.chownSync(this.mapToBase(e),r,s)}async renamePromise(e,r){return this.baseFs.renamePromise(this.mapToBase(e),this.mapToBase(r))}renameSync(e,r){return this.baseFs.renameSync(this.mapToBase(e),this.mapToBase(r))}async copyFilePromise(e,r,s=0){return this.baseFs.copyFilePromise(this.mapToBase(e),this.mapToBase(r),s)}copyFileSync(e,r,s=0){return this.baseFs.copyFileSync(this.mapToBase(e),this.mapToBase(r),s)}async appendFilePromise(e,r,s){return this.baseFs.appendFilePromise(this.fsMapToBase(e),r,s)}appendFileSync(e,r,s){return this.baseFs.appendFileSync(this.fsMapToBase(e),r,s)}async writeFilePromise(e,r,s){return this.baseFs.writeFilePromise(this.fsMapToBase(e),r,s)}writeFileSync(e,r,s){return this.baseFs.writeFileSync(this.fsMapToBase(e),r,s)}async unlinkPromise(e){return this.baseFs.unlinkPromise(this.mapToBase(e))}unlinkSync(e){return this.baseFs.unlinkSync(this.mapToBase(e))}async utimesPromise(e,r,s){return this.baseFs.utimesPromise(this.mapToBase(e),r,s)}utimesSync(e,r,s){return this.baseFs.utimesSync(this.mapToBase(e),r,s)}async lutimesPromise(e,r,s){return this.baseFs.lutimesPromise(this.mapToBase(e),r,s)}lutimesSync(e,r,s){return this.baseFs.lutimesSync(this.mapToBase(e),r,s)}async mkdirPromise(e,r){return this.baseFs.mkdirPromise(this.mapToBase(e),r)}mkdirSync(e,r){return this.baseFs.mkdirSync(this.mapToBase(e),r)}async rmdirPromise(e,r){return this.baseFs.rmdirPromise(this.mapToBase(e),r)}rmdirSync(e,r){return this.baseFs.rmdirSync(this.mapToBase(e),r)}async rmPromise(e,r){return this.baseFs.rmPromise(this.mapToBase(e),r)}rmSync(e,r){return this.baseFs.rmSync(this.mapToBase(e),r)}async linkPromise(e,r){return this.baseFs.linkPromise(this.mapToBase(e),this.mapToBase(r))}linkSync(e,r){return this.baseFs.linkSync(this.mapToBase(e),this.mapToBase(r))}async symlinkPromise(e,r,s){let a=this.mapToBase(r);if(this.pathUtils.isAbsolute(e))return this.baseFs.symlinkPromise(this.mapToBase(e),a,s);let n=this.mapToBase(this.pathUtils.join(this.pathUtils.dirname(r),e)),c=this.baseFs.pathUtils.relative(this.baseFs.pathUtils.dirname(a),n);return this.baseFs.symlinkP Line truncated
`,TA=ur(`\\
`,!1),RA=function(){return""},oa="\\",aa=ur("\\",!1),FA=/^[\\$"`]/,gr=zi(["\\","$",'"',"`"],!1,!1),Bo=function(O){return O},Me="\\a",cu=ur("\\a",!1),Cr=function(){return"a"},pf="\\b",NA=ur("\\b",!1),OA=function(){return"\b"},uu=/^[Ee]/,fu=zi(["E","e"],!1,!1),oc=function(){return"\x1B"},ve="\\f",Nt=ur("\\f",!1),ac=function(){return"\f"},Oi="\\n",no=ur("\\n",!1),Rt=function(){return`
`},xn="\\r",la=ur("\\r",!1),Gi=function(){return"\r"},Li="\\t",Na=ur("\\t",!1),dn=function(){return" "},Kn="\\v",Au=ur("\\v",!1),yh=function(){return"\v"},Oa=/^[\\'"?]/,La=zi(["\\","'",'"',"?"],!1,!1),Ma=function(O){return String.fromCharCode(parseInt(O,16))},$e="\\x",Ua=ur("\\x",!1),hf="\\u",lc=ur("\\u",!1),wn="\\U",ca=ur("\\U",!1),LA=function(O){return String.fromCodePoint(parseInt(O,16))},MA=/^[0-7]/,ua=zi([["0","7"]],!1,!1),Bl=/^[0-9a-fA-f]/,Mt=zi([["0","9"],["a","f"],["A","f"]],!1,!1),kn=yf(),fa="{}",Ha=ur("{}",!1),ns=function(){return"{}"},cc="-",pu=ur("-",!1),uc="+",ja=ur("+",!1),Mi=".",Is=ur(".",!1),vl=function(O,K,re){return{type:"number",value:(O==="-"?-1:1)*parseFloat(K.join("")+"."+re.join(""))}},gf=function(O,K){return{type:"number",value:(O==="-"?-1:1)*parseInt(K.join(""))}},fc=function(O){return{type:"variable",...O}},wi=function(O){return{type:"variable",name:O}},Qn=function(O){return O},Ac="*",Ke=ur("*",!1),st="/",St=ur("/",!1),lr=function(O,K,re){return{type:K==="*"?"multiplication":"division",right:re}},te=function(O,K){return K.reduce((re,de)=>({left:re,...de}),O)},Ee=function(O,K,re){return{type:K==="+"?"addition":"subtraction",right:re}},Oe="$((",dt=ur("$((",!1),Et="))",bt=ur("))",!1),tr=function(O){return O},An="$(",li=ur("$(",!1),qi=function(O){return O},Tn="${",Ga=ur("${",!1),my=":-",Z1=ur(":-",!1),vo=function(O,K){return{name:O,defaultValue:K}},yy=":-}",Eh=ur(":-}",!1),$1=function(O){return{name:O,defaultValue:[]}},So=":+",Ih=ur(":+",!1),Ch=function(O,K){return{name:O,alternativeValue:K}},hu=":+}",wh=ur(":+}",!1),Fg=function(O){return{name:O,alternativeValue:[]}},Ng=function(O){return{name:O}},Og="$",Ey=ur("$",!1),df=function(O){return e.isGlobPattern(O)},Do=function(O){return O},Sl=/^[a-zA-Z0-9_]/,Bh=zi([["a","z"],["A","Z"],["0","9"],"_"],!1,!1),Lg=function(){return By()},Dl=/^[$@*?#a-zA-Z0-9_\-]/,bl=zi(["$","@","*","?","#",["a","z"],["A","Z"],["0","9"],"_","-"],!1,!1),Iy=/^[()}<>$|&; \t"']/,UA=zi(["(",")","}","<",">","$","|","&",";"," "," ",'"',"'"],!1,!1),Cy=/^[<>&; \t"']/,wy=zi(["<",">","&",";"," "," ",'"',"'"],!1,!1),_A=/^[ \t]/,HA=zi([" "," "],!1,!1),Y=0,xt=0,jA=[{line:1,column:1}],bo=0,mf=[],yt=0,gu;if("startRule"in e){if(!(e.startRule in s))throw new Error(`Can't start parsing from rule "`+e.startRule+'".');a=s[e.startRule]}function By(){return t.substring(xt,Y)}function Mg(){return Ef(xt,Y)}function e2(O,K){throw K=K!==void 0?K:Ef(xt,Y),GA([Ug(O)],t.substring(xt,Y),K)}function vh(O,K){throw K=K!==void 0?K:Ef(xt,Y),di(O,K)}function ur(O,K){return{type:"literal",text:O,ignoreCase:K}}function zi(O,K,re){return{type:"class",parts:O,inverted:K,ignoreCase:re}}function yf(){return{type:"any"}}function qa(){return{type:"end"}}function Ug(O){return{type:"other",description:O}}function du(O){var K=jA[O],re;if(K)return K;for(re=O-1;!jA[re];)re--;for(K=jA[re],K={line:K.line,column:K.column};re<O;)t.charCodeAt(re)===10?(K.line++,K.column=1):K.column++,re++;return jA[O]=K,K}function Ef(O,K){var re=du(O),de=du(K);return{start:{offset:O,line:re.line,column:re.column},end:{offset:K,line:de.line,column:de.column}}}function wt(O){Y<bo||(Y>bo&&(bo=Y,mf=[]),mf.push(O))}function di(O,K){return new Bd(O,null,null,K)}function GA(O,K,re){return new Bd(Bd.buildMessage(O,K),O,K,re)}function Wa(){var O,K,re;for(O=Y,K=[],re=kt();re!==r;)K.push(re),re=kt();return K!==r?(re=Aa(),re===r&&(re=null),re!==r?(xt=O,K=n(re),O=K):(Y=O,O=r)):(Y=O,O=r),O}function Aa(){var O,K,re,de,Je;if(O=Y,K=Sh(),K!==r){for(re=[],de=kt();de!==r;)re.push(de),de=kt();re!==r?(de=_g(),de!==r?(Je=Ya(),Je===r&&(Je=null),Je!==r?(xt=O,K=c(K,de,Je),O=K):(Y=O,O=r)):(Y=O,O=r)):(Y=O,O=r)}else Y=O,O=r;if(O===r)if(O=Y,K=Sh(),K!==r){for(re=[],de=kt();de!==r;)re.push(de),de=kt();re!==r?(de=_g(),de===r&&(de=null),de!==r?(xt=O,K=f(K,de),O=K):(Y=O,O=r)):(Y=O,O=r)}else Y=O,O=r;return O}function Ya(){var O,K,re,de,Je;for(O=Y,K=[],re=kt();re!==r;)K.push(re),re=kt();if(K!==r)if(re=Aa(),re!==r){for(de=[],Je=kt();Je!==r;)de.push(Je),Je=kt();de!==r?(xt=O,K=p(re),O=K):(Y=O,O=r)}else Y=O,O=r;else Y=O,O=r;return O}function _g(){var O;return t.charCodeAt(Y)===59?(O=h,Y++):(O=r,yt===0&&wt(E)),O===r&&(t.charCodeAt(Y)===38?(O=C,Y++):(O=r,yt===0&&wt(S))),O}function Sh(){var O,K,re;return O=Y,K=qA(),K!==r?(re=Hg(),re===r&&(re=null),re!==r?(xt=O,K=P(K,re),O=K):(Y=O,O=r)):(Y=O,O=r),O}function Hg(){var O,K,re,de,Je,At,dr;for(O=Y,K=[],re=kt();re!==r;)K.push(re),re=kt();if(K!==r)if(re=vy(),re!==r){for(de=[],Je=kt();Je!==r;)de.push(Je),Je=kt();if(de!==r)if(Je=Sh(),Je!==r){for(At=[],dr=kt();dr!==r;)At.push(dr),dr=kt();At!==r?(xt=O,K=I(re,Je),O=K):(Y=O,O=r)}else Y=O,O=r;else Y=O,O=r}else Y=O,O=r;else Y=O,O=r;return O}function vy(){var O;return t.substr(Y,2)===R?(O=R,Y+=2):(O=r,yt===0&&wt(N)),O===r&&(t.substr(Y,2)===U?(O=U,Y+=2):(O=r,yt===0&&wt(W))),O}function qA(){var O,K,re;return O=Y,K=If(),K!==r?(re=jg(),re===r&&(re=null),re!==r?(xt=O,K=ee(K,re),O=K):(Y=O,O=r)):(Y=O,O=r),O}function jg(){var O,K,re,de,Je,At,dr;for(O=Y,K=[],re=kt();re!==r;)K.push(re),re=kt();if(K!==r)Line truncated
`,"\\n"],["\r","\\r"],[" ","\\t"],["\v","\\v"],["\0","\\0"]]),M5e=new Map([["\\","\\\\"],["$","\\$"],['"','\\"'],...Array.from(Iee,([t,e])=>[t,`"$'${e}'"`])]),Cee=t=>Iee.get(t)??`\\x${t.charCodeAt(0).toString(16).padStart(2,"0")}`,U5e=t=>M5e.get(t)??`"$'${Cee(t)}'"`});var vee=_((eQt,Bee)=>{"use strict";function _5e(t,e){function r(){this.constructor=t}r.prototype=e.prototype,t.prototype=new r}function Sd(t,e,r,s){this.message=t,this.expected=e,this.found=r,this.location=s,this.name="SyntaxError",typeof Error.captureStackTrace=="function"&&Error.captureStackTrace(this,Sd)}_5e(Sd,Error);Sd.buildMessage=function(t,e){var r={literal:function(h){return'"'+a(h.text)+'"'},class:function(h){var E="",C;for(C=0;C<h.parts.length;C++)E+=h.parts[C]instanceof Array?n(h.parts[C][0])+"-"+n(h.parts[C][1]):n(h.parts[C]);return"["+(h.inverted?"^":"")+E+"]"},any:function(h){return"any character"},end:function(h){return"end of input"},other:function(h){return h.description}};function s(h){return h.charCodeAt(0).toString(16).toUpperCase()}function a(h){return h.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,function(E){return"\\x0"+s(E)}).replace(/[\x10-\x1F\x7F-\x9F]/g,function(E){return"\\x"+s(E)})}function n(h){return h.replace(/\\/g,"\\\\").replace(/\]/g,"\\]").replace(/\^/g,"\\^").replace(/-/g,"\\-").replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,function(E){return"\\x0"+s(E)}).replace(/[\x10-\x1F\x7F-\x9F]/g,function(E){return"\\x"+s(E)})}function c(h){return r[h.type](h)}function f(h){var E=new Array(h.length),C,S;for(C=0;C<h.length;C++)E[C]=c(h[C]);if(E.sort(),E.length>0){for(C=1,S=1;C<E.length;C++)E[C-1]!==E[C]&&(E[S]=E[C],S++);E.length=S}switch(E.length){case 1:return E[0];case 2:return E[0]+" or "+E[1];default:return E.slice(0,-1).join(", ")+", or "+E[E.length-1]}}function p(h){return h?'"'+a(h)+'"':"end of input"}return"Expected "+f(t)+" but "+p(e)+" found."};function H5e(t,e){e=e!==void 0?e:{};var r={},s={resolution:Ne},a=Ne,n="/",c=ye("/",!1),f=function(Ue,x){return{from:Ue,descriptor:x}},p=function(Ue){return{descriptor:Ue}},h="@",E=ye("@",!1),C=function(Ue,x){return{fullName:Ue,description:x}},S=function(Ue){return{fullName:Ue}},P=function(){return Be()},I=/^[^\/@]/,R=Ae(["/","@"],!0,!1),N=/^[^\/]/,U=Ae(["/"],!0,!1),W=0,ee=0,ie=[{line:1,column:1}],ue=0,le=[],me=0,pe;if("startRule"in e){if(!(e.startRule in s))throw new Error(`Can't start parsing from rule "`+e.startRule+'".');a=s[e.startRule]}function Be(){return t.substring(ee,W)}function Ce(){return mt(ee,W)}function g(Ue,x){throw x=x!==void 0?x:mt(ee,W),Fe([De(Ue)],t.substring(ee,W),x)}function we(Ue,x){throw x=x!==void 0?x:mt(ee,W),rt(Ue,x)}function ye(Ue,x){return{type:"literal",text:Ue,ignoreCase:x}}function Ae(Ue,x,w){return{type:"class",parts:Ue,inverted:x,ignoreCase:w}}function se(){return{type:"any"}}function Z(){return{type:"end"}}function De(Ue){return{type:"other",description:Ue}}function Re(Ue){var x=ie[Ue],w;if(x)return x;for(w=Ue-1;!ie[w];)w--;for(x=ie[w],x={line:x.line,column:x.column};w<Ue;)t.charCodeAt(w)===10?(x.line++,x.column=1):x.column++,w++;return ie[Ue]=x,x}function mt(Ue,x){var w=Re(Ue),b=Re(x);return{start:{offset:Ue,line:w.line,column:w.column},end:{offset:x,line:b.line,column:b.column}}}function j(Ue){W<ue||(W>ue&&(ue=W,le=[]),le.push(Ue))}function rt(Ue,x){return new Sd(Ue,null,null,x)}function Fe(Ue,x,w){return new Sd(Sd.buildMessage(Ue,x),Ue,x,w)}function Ne(){var Ue,x,w,b;return Ue=W,x=Pe(),x!==r?(t.charCodeAt(W)===47?(w=n,W++):(w=r,me===0&&j(c)),w!==r?(b=Pe(),b!==r?(ee=Ue,x=f(x,b),Ue=x):(W=Ue,Ue=r)):(W=Ue,Ue=r)):(W=Ue,Ue=r),Ue===r&&(Ue=W,x=Pe(),x!==r&&(ee=Ue,x=p(x)),Ue=x),Ue}function Pe(){var Ue,x,w,b;return Ue=W,x=Ve(),x!==r?(t.charCodeAt(W)===64?(w=h,W++):(w=r,me===0&&j(E)),w!==r?(b=it(),b!==r?(ee=Ue,x=C(x,b),Ue=x):(W=Ue,Ue=r)):(W=Ue,Ue=r)):(W=Ue,Ue=r),Ue===r&&(Ue=W,x=Ve(),x!==r&&(ee=Ue,x=S(x)),Ue=x),Ue}function Ve(){var Ue,x,w,b,y;return Ue=W,t.charCodeAt(W)===64?(x=h,W++):(x=r,me===0&&j(E)),x!==r?(w=ke(),w!==r?(t.charCodeAt(W)===47?(b=n,W++):(b=r,me===0&&j(c)),b!==r?(y=ke(),y!==r?(ee=Ue,x=P(),Ue=x):(W=Ue,Ue=r)):(W=Ue,Ue=r)):(W=Ue,Ue=r)):(W=Ue,Ue=r),Ue===r&&(Ue=W,x=ke(),x!==r&&(ee=Ue,x=P()),Ue=x),Ue}function ke(){var Ue,x,w;if(Ue=W,x=[],I.test(t.charAt(W))?(w=t.charAt(W),W++):(w=r,me===0&&j(R)),w!==r)for(;w!==r;)x.push(w),I.test(t.charAt(W))?(w=t.charAt(W),W++):(w=r,me===0&&j(R));else x=r;return x!==r&&(ee=Ue,x=P()),Ue=x,Ue}function it(){var Ue,x,w;if(Ue=W,x=[],N.test(t.charAt(W))?(w=t.charAt(W),W++):(w=r,me===0&&j(U)),w!==r)for(;w!==r;)x.push(w),N.test(t.charAt(W))?(w=t.charAt(W),W++):(w=r,me===0&&j(U));else x=r;return x!==r&&(ee=Ue,x=P()),Ue=x,Ue}if(pe=a(),pe!==r&&W===t.length)return pe;throw pe!==r&&W<t.length&&j(Z()),Fe(le,ue<t.length?t.charAt(ue):null,ue<t.length?mt(ue,ue+1):mt(ue,ue))}Bee.exports={SyntaxError:Sd,parse:H5e}});function px(t){let e=t.match(/^\*{1,Line truncated
\x85\u2028\u2029`.indexOf(this.buffer.charAt(a-1))===-1;)if(a-=1,this.position-a>r/2-1){s=" ... ",a+=5;break}for(n="",c=this.position;c<this.buffer.length&&`\0\r
\x85\u2028\u2029`.indexOf(this.buffer.charAt(c))===-1;)if(c+=1,c-this.position>r/2-1){n=" ... ",c-=5;break}return f=this.buffer.slice(a,c),xee.repeat(" ",e)+s+f+n+`
`+xee.repeat(" ",e+this.position-a+s.length)+"^"};YU.prototype.toString=function(e){var r,s="";return this.name&&(s+='in "'+this.name+'" '),s+="at line "+(this.line+1)+", column "+(this.column+1),e||(r=this.getSnippet(),r&&(s+=`:
`+r)),s};kee.exports=YU});var Ss=_((sQt,Ree)=>{"use strict";var Tee=pE(),V5e=["kind","resolve","construct","instanceOf","predicate","represent","defaultStyle","styleAliases"],J5e=["scalar","sequence","mapping"];function K5e(t){var e={};return t!==null&&Object.keys(t).forEach(function(r){t[r].forEach(function(s){e[String(s)]=r})}),e}function z5e(t,e){if(e=e||{},Object.keys(e).forEach(function(r){if(V5e.indexOf(r)===-1)throw new Tee('Unknown option "'+r+'" is met in definition of "'+t+'" YAML type.')}),this.tag=t,this.kind=e.kind||null,this.resolve=e.resolve||function(){return!0},this.construct=e.construct||function(r){return r},this.instanceOf=e.instanceOf||null,this.predicate=e.predicate||null,this.represent=e.represent||null,this.defaultStyle=e.defaultStyle||null,this.styleAliases=K5e(e.styleAliases||null),J5e.indexOf(this.kind)===-1)throw new Tee('Unknown kind "'+this.kind+'" is specified for "'+t+'" YAML type.')}Ree.exports=z5e});var Pd=_((oQt,Nee)=>{"use strict";var Fee=bd(),gx=pE(),X5e=Ss();function VU(t,e,r){var s=[];return t.include.forEach(function(a){r=VU(a,e,r)}),t[e].forEach(function(a){r.forEach(function(n,c){n.tag===a.tag&&n.kind===a.kind&&s.push(c)}),r.push(a)}),r.filter(function(a,n){return s.indexOf(n)===-1})}function Z5e(){var t={scalar:{},sequence:{},mapping:{},fallback:{}},e,r;function s(a){t[a.kind][a.tag]=t.fallback[a.tag]=a}for(e=0,r=arguments.length;e<r;e+=1)arguments[e].forEach(s);return t}function hE(t){this.include=t.include||[],this.implicit=t.implicit||[],this.explicit=t.explicit||[],this.implicit.forEach(function(e){if(e.loadKind&&e.loadKind!=="scalar")throw new gx("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.")}),this.compiledImplicit=VU(this,"implicit",[]),this.compiledExplicit=VU(this,"explicit",[]),this.compiledTypeMap=Z5e(this.compiledImplicit,this.compiledExplicit)}hE.DEFAULT=null;hE.create=function(){var e,r;switch(arguments.length){case 1:e=hE.DEFAULT,r=arguments[0];break;case 2:e=arguments[0],r=arguments[1];break;default:throw new gx("Wrong number of arguments for Schema.create function")}if(e=Fee.toArray(e),r=Fee.toArray(r),!e.every(function(s){return s instanceof hE}))throw new gx("Specified list of super schemas (or a single Schema object) contains a non-Schema object.");if(!r.every(function(s){return s instanceof X5e}))throw new gx("Specified list of YAML types (or a single Type object) contains a non-Type object.");return new hE({include:e,explicit:r})};Nee.exports=hE});var Lee=_((aQt,Oee)=>{"use strict";var $5e=Ss();Oee.exports=new $5e("tag:yaml.org,2002:str",{kind:"scalar",construct:function(t){return t!==null?t:""}})});var Uee=_((lQt,Mee)=>{"use strict";var eqe=Ss();Mee.exports=new eqe("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(t){return t!==null?t:[]}})});var Hee=_((cQt,_ee)=>{"use strict";var tqe=Ss();_ee.exports=new tqe("tag:yaml.org,2002:map",{kind:"mapping",construct:function(t){return t!==null?t:{}}})});var dx=_((uQt,jee)=>{"use strict";var rqe=Pd();jee.exports=new rqe({explicit:[Lee(),Uee(),Hee()]})});var qee=_((fQt,Gee)=>{"use strict";var nqe=Ss();function iqe(t){if(t===null)return!0;var e=t.length;return e===1&&t==="~"||e===4&&(t==="null"||t==="Null"||t==="NULL")}function sqe(){return null}function oqe(t){return t===null}Gee.exports=new nqe("tag:yaml.org,2002:null",{kind:"scalar",resolve:iqe,construct:sqe,predicate:oqe,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"}},defaultStyle:"lowercase"})});var Yee=_((AQt,Wee)=>{"use strict";var aqe=Ss();function lqe(t){if(t===null)return!1;var e=t.length;return e===4&&(t==="true"||t==="True"||t==="TRUE")||e===5&&(t==="false"||t==="False"||t==="FALSE")}function cqe(t){return t==="true"||t==="True"||t==="TRUE"}function uqe(t){return Object.prototype.toString.call(t)==="[object Boolean]"}Wee.exports=new aqe("tag:yaml.org,2002:bool",{kind:"scalar",resolve:lqe,construct:cqe,predicate:uqe,represent:{lowercase:function(t){return t?"true":"false"},uppercase:function(t){return t?"TRUE":"FALSE"},camelcase:function(t){return t?"True":"False"}},defaultStyle:"lowercase"})});var Jee=_((pQt,Vee)=>{"use strict";var fqe=bd(),Aqe=Ss();function pqe(t){return 48<=t&&t<=57||65<=t&&t<=70||97<=t&&t<=102}function hqe(t){return 48<=t&&t<=55}function gqe(t){return 48<=t&&t<=57}function dqe(t){if(t===null)return!1;var e=t.length,r=0,s=!1,a;if(!e)return!1;if(a=t[r],(a==="-"||a==="+")&&(a=t[++r]),a==="0"){if(r+1===e)return!0;if(a=t[++r],a==="b"){for(r++;r<e;r++)if(a=t[r],a!=="_"){if(a!=="0"&&a!=="1")return!1;s=!0}return s&&a!=="_"}if(a==="x"){for(r++;r<e;r++)if(a=t[r],a!=="_"){if(!pqe(t.charCodeAt(r)))return!1;s=!0}return s&&a!=="_"}for(;r<e;r++)if(a=t[r],a!=="_"){if(!hqe(t.charCodeAt(r)))return!1;s=!0}return s&&a!=="_"}if(a==="_")return!1;for(;r<e;r++)if(a=t[r],a!=="_"){if(a===":")break;if(!gqe(t.charCodeAt(r)))return!1;s=!0}return!s||a==="_"?!1:a!==":"?!0:/^( Line truncated
\r`;function Nqe(t){if(t===null)return!1;var e,r,s=0,a=t.length,n=zU;for(r=0;r<a;r++)if(e=n.indexOf(t.charAt(r)),!(e>64)){if(e<0)return!1;s+=6}return s%8===0}function Oqe(t){var e,r,s=t.replace(/[\r\n=]/g,""),a=s.length,n=zU,c=0,f=[];for(e=0;e<a;e++)e%4===0&&e&&(f.push(c>>16&255),f.push(c>>8&255),f.push(c&255)),c=c<<6|n.indexOf(s.charAt(e));return r=a%4*6,r===0?(f.push(c>>16&255),f.push(c>>8&255),f.push(c&255)):r===18?(f.push(c>>10&255),f.push(c>>2&255)):r===12&&f.push(c>>4&255),xd?xd.from?xd.from(f):new xd(f):f}function Lqe(t){var e="",r=0,s,a,n=t.length,c=zU;for(s=0;s<n;s++)s%3===0&&s&&(e+=c[r>>18&63],e+=c[r>>12&63],e+=c[r>>6&63],e+=c[r&63]),r=(r<<8)+t[s];return a=n%3,a===0?(e+=c[r>>18&63],e+=c[r>>12&63],e+=c[r>>6&63],e+=c[r&63]):a===2?(e+=c[r>>10&63],e+=c[r>>4&63],e+=c[r<<2&63],e+=c[64]):a===1&&(e+=c[r>>2&63],e+=c[r<<4&63],e+=c[64],e+=c[64]),e}function Mqe(t){return xd&&xd.isBuffer(t)}ate.exports=new Fqe("tag:yaml.org,2002:binary",{kind:"scalar",resolve:Nqe,construct:Oqe,predicate:Mqe,represent:Lqe})});var ute=_((CQt,cte)=>{"use strict";var Uqe=Ss(),_qe=Object.prototype.hasOwnProperty,Hqe=Object.prototype.toString;function jqe(t){if(t===null)return!0;var e=[],r,s,a,n,c,f=t;for(r=0,s=f.length;r<s;r+=1){if(a=f[r],c=!1,Hqe.call(a)!=="[object Object]")return!1;for(n in a)if(_qe.call(a,n))if(!c)c=!0;else return!1;if(!c)return!1;if(e.indexOf(n)===-1)e.push(n);else return!1}return!0}function Gqe(t){return t!==null?t:[]}cte.exports=new Uqe("tag:yaml.org,2002:omap",{kind:"sequence",resolve:jqe,construct:Gqe})});var Ate=_((wQt,fte)=>{"use strict";var qqe=Ss(),Wqe=Object.prototype.toString;function Yqe(t){if(t===null)return!0;var e,r,s,a,n,c=t;for(n=new Array(c.length),e=0,r=c.length;e<r;e+=1){if(s=c[e],Wqe.call(s)!=="[object Object]"||(a=Object.keys(s),a.length!==1))return!1;n[e]=[a[0],s[a[0]]]}return!0}function Vqe(t){if(t===null)return[];var e,r,s,a,n,c=t;for(n=new Array(c.length),e=0,r=c.length;e<r;e+=1)s=c[e],a=Object.keys(s),n[e]=[a[0],s[a[0]]];return n}fte.exports=new qqe("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:Yqe,construct:Vqe})});var hte=_((BQt,pte)=>{"use strict";var Jqe=Ss(),Kqe=Object.prototype.hasOwnProperty;function zqe(t){if(t===null)return!0;var e,r=t;for(e in r)if(Kqe.call(r,e)&&r[e]!==null)return!1;return!0}function Xqe(t){return t!==null?t:{}}pte.exports=new Jqe("tag:yaml.org,2002:set",{kind:"mapping",resolve:zqe,construct:Xqe})});var gE=_((vQt,gte)=>{"use strict";var Zqe=Pd();gte.exports=new Zqe({include:[KU()],implicit:[nte(),ste()],explicit:[lte(),ute(),Ate(),hte()]})});var mte=_((SQt,dte)=>{"use strict";var $qe=Ss();function e9e(){return!0}function t9e(){}function r9e(){return""}function n9e(t){return typeof t>"u"}dte.exports=new $qe("tag:yaml.org,2002:js/undefined",{kind:"scalar",resolve:e9e,construct:t9e,predicate:n9e,represent:r9e})});var Ete=_((DQt,yte)=>{"use strict";var i9e=Ss();function s9e(t){if(t===null||t.length===0)return!1;var e=t,r=/\/([gim]*)$/.exec(t),s="";return!(e[0]==="/"&&(r&&(s=r[1]),s.length>3||e[e.length-s.length-1]!=="/"))}function o9e(t){var e=t,r=/\/([gim]*)$/.exec(t),s="";return e[0]==="/"&&(r&&(s=r[1]),e=e.slice(1,e.length-s.length-1)),new RegExp(e,s)}function a9e(t){var e="/"+t.source+"/";return t.global&&(e+="g"),t.multiline&&(e+="m"),t.ignoreCase&&(e+="i"),e}function l9e(t){return Object.prototype.toString.call(t)==="[object RegExp]"}yte.exports=new i9e("tag:yaml.org,2002:js/regexp",{kind:"scalar",resolve:s9e,construct:o9e,predicate:l9e,represent:a9e})});var wte=_((bQt,Cte)=>{"use strict";var mx;try{Ite=Ie,mx=Ite("esprima")}catch{typeof window<"u"&&(mx=window.esprima)}var Ite,c9e=Ss();function u9e(t){if(t===null)return!1;try{var e="("+t+")",r=mx.parse(e,{range:!0});return!(r.type!=="Program"||r.body.length!==1||r.body[0].type!=="ExpressionStatement"||r.body[0].expression.type!=="ArrowFunctionExpression"&&r.body[0].expression.type!=="FunctionExpression")}catch{return!1}}function f9e(t){var e="("+t+")",r=mx.parse(e,{range:!0}),s=[],a;if(r.type!=="Program"||r.body.length!==1||r.body[0].type!=="ExpressionStatement"||r.body[0].expression.type!=="ArrowFunctionExpression"&&r.body[0].expression.type!=="FunctionExpression")throw new Error("Failed to resolve function");return r.body[0].expression.params.forEach(function(n){s.push(n.name)}),a=r.body[0].expression.body.range,r.body[0].expression.body.type==="BlockStatement"?new Function(s,e.slice(a[0]+1,a[1]-1)):new Function(s,"return "+e.slice(a[0],a[1]))}function A9e(t){return t.toString()}function p9e(t){return Object.prototype.toString.call(t)==="[object Function]"}Cte.exports=new c9e("tag:yaml.org,2002:js/function",{kind:"scalar",resolve:u9e,construct:f9e,predicate:p9e,represent:A9e})});var G2=_((xQt,vte)=>{"use strict";var Bte=Pd();vte.exports=Bte.DEFAULT=new Bte({include:[gE()],explicit:[mte(),Ete(),wte()]})});var Gte=_((kQt,q2)=>{"use strict";var Ip=bd(),Qte=pE(),h9e=Qee(),Tte=gE(),g9e=G2(),i0=Object.prototype.hasOwnProperty,yx=1,Rte=2,Fte=3,Ex=4,XU=1,d9e=2,Ste=3,m9e=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84 Line truncated
`:t===118?"\v":t===102?"\f":t===114?"\r":t===101?"\x1B":t===32?" ":t===34?'"':t===47?"/":t===92?"\\":t===78?"\x85":t===95?"\xA0":t===76?"\u2028":t===80?"\u2029":""}function B9e(t){return t<=65535?String.fromCharCode(t):String.fromCharCode((t-65536>>10)+55296,(t-65536&1023)+56320)}var Lte=new Array(256),Mte=new Array(256);for(kd=0;kd<256;kd++)Lte[kd]=bte(kd)?1:0,Mte[kd]=bte(kd);var kd;function v9e(t,e){this.input=t,this.filename=e.filename||null,this.schema=e.schema||g9e,this.onWarning=e.onWarning||null,this.legacy=e.legacy||!1,this.json=e.json||!1,this.listener=e.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=t.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.documents=[]}function Ute(t,e){return new Qte(e,new h9e(t.filename,t.input,t.position,t.line,t.position-t.lineStart))}function Rr(t,e){throw Ute(t,e)}function Ix(t,e){t.onWarning&&t.onWarning.call(null,Ute(t,e))}var Pte={YAML:function(e,r,s){var a,n,c;e.version!==null&&Rr(e,"duplication of %YAML directive"),s.length!==1&&Rr(e,"YAML directive accepts exactly one argument"),a=/^([0-9]+)\.([0-9]+)$/.exec(s[0]),a===null&&Rr(e,"ill-formed argument of the YAML directive"),n=parseInt(a[1],10),c=parseInt(a[2],10),n!==1&&Rr(e,"unacceptable YAML version of the document"),e.version=s[0],e.checkLineBreaks=c<2,c!==1&&c!==2&&Ix(e,"unsupported YAML version of the document")},TAG:function(e,r,s){var a,n;s.length!==2&&Rr(e,"TAG directive accepts exactly two arguments"),a=s[0],n=s[1],Nte.test(a)||Rr(e,"ill-formed tag handle (first argument) of the TAG directive"),i0.call(e.tagMap,a)&&Rr(e,'there is a previously declared suffix for "'+a+'" tag handle'),Ote.test(n)||Rr(e,"ill-formed tag prefix (second argument) of the TAG directive"),e.tagMap[a]=n}};function n0(t,e,r,s){var a,n,c,f;if(e<r){if(f=t.input.slice(e,r),s)for(a=0,n=f.length;a<n;a+=1)c=f.charCodeAt(a),c===9||32<=c&&c<=1114111||Rr(t,"expected valid JSON character");else m9e.test(f)&&Rr(t,"the stream contains non-printable characters");t.result+=f}}function xte(t,e,r,s){var a,n,c,f;for(Ip.isObject(r)||Rr(t,"cannot merge mappings; the provided source object is unacceptable"),a=Object.keys(r),c=0,f=a.length;c<f;c+=1)n=a[c],i0.call(e,n)||(e[n]=r[n],s[n]=!0)}function mE(t,e,r,s,a,n,c,f){var p,h;if(Array.isArray(a))for(a=Array.prototype.slice.call(a),p=0,h=a.length;p<h;p+=1)Array.isArray(a[p])&&Rr(t,"nested arrays are not supported inside keys"),typeof a=="object"&&Dte(a[p])==="[object Object]"&&(a[p]="[object Object]");if(typeof a=="object"&&Dte(a)==="[object Object]"&&(a="[object Object]"),a=String(a),e===null&&(e={}),s==="tag:yaml.org,2002:merge")if(Array.isArray(n))for(p=0,h=n.length;p<h;p+=1)xte(t,e,n[p],r);else xte(t,e,n,r);else!t.json&&!i0.call(r,a)&&i0.call(e,a)&&(t.line=c||t.line,t.position=f||t.position,Rr(t,"duplicated mapping key")),e[a]=n,delete r[a];return e}function ZU(t){var e;e=t.input.charCodeAt(t.position),e===10?t.position++:e===13?(t.position++,t.input.charCodeAt(t.position)===10&&t.position++):Rr(t,"a line break is expected"),t.line+=1,t.lineStart=t.position}function as(t,e,r){for(var s=0,a=t.input.charCodeAt(t.position);a!==0;){for(;Qd(a);)a=t.input.charCodeAt(++t.position);if(e&&a===35)do a=t.input.charCodeAt(++t.position);while(a!==10&&a!==13&&a!==0);if(jf(a))for(ZU(t),a=t.input.charCodeAt(t.position),s++,t.lineIndent=0;a===32;)t.lineIndent++,a=t.input.charCodeAt(++t.position);else break}return r!==-1&&s!==0&&t.lineIndent<r&&Ix(t,"deficient indentation"),s}function Cx(t){var e=t.position,r;return r=t.input.charCodeAt(e),!!((r===45||r===46)&&r===t.input.charCodeAt(e+1)&&r===t.input.charCodeAt(e+2)&&(e+=3,r=t.input.charCodeAt(e),r===0||rl(r)))}function $U(t,e){e===1?t.result+=" ":e>1&&(t.result+=Ip.repeat(`
`,e-1))}function S9e(t,e,r){var s,a,n,c,f,p,h,E,C=t.kind,S=t.result,P;if(P=t.input.charCodeAt(t.position),rl(P)||dE(P)||P===35||P===38||P===42||P===33||P===124||P===62||P===39||P===34||P===37||P===64||P===96||(P===63||P===45)&&(a=t.input.charCodeAt(t.position+1),rl(a)||r&&dE(a)))return!1;for(t.kind="scalar",t.result="",n=c=t.position,f=!1;P!==0;){if(P===58){if(a=t.input.charCodeAt(t.position+1),rl(a)||r&&dE(a))break}else if(P===35){if(s=t.input.charCodeAt(t.position-1),rl(s))break}else{if(t.position===t.lineStart&&Cx(t)||r&&dE(P))break;if(jf(P))if(p=t.line,h=t.lineStart,E=t.lineIndent,as(t,!1,-1),t.lineIndent>=e){f=!0,P=t.input.charCodeAt(t.position);continue}else{t.position=c,t.line=p,t.lineStart=h,t.lineIndent=E;break}}f&&(n0(t,n,c,!1),$U(t,t.line-p),n=c=t.position,f=!1),Qd(P)||(c=t.position+1),P=t.input.charCodeAt(++t.position)}return n0(t,n,c,!1),t.result?!0:(t.kind=C,t.result=S,!1)}function D9e(t,e){var r,s,a;if(r=t.input.charCodeAt(t.position),r!==39)return!1;for(t.kind="scalar",t.result="",t.position++,s=a=t.position;(r=t.input.charCodeAt(t.position))!==0;)if(r===39)if(n0(t,s,t.position,!0),r=t.input.charCodeAt(++t.position),r===39)s=t.position,t.position++,a=t.position;else return!0;else jf(r)?(n0(t,s,a,!0),$U(t,as(t,!1,e)),s=a=t.position):t.position===t.lineStart&&Cx(t)?Rr(t,"unexpected end of the document within a single quoted scalar"):(t.position++,a=t.position);Rr(t,"unexpected end of the stream within a single quoted scalar")}function b9e(t,e){var r,s,a,n,c,f;if(f=t.input.charCodeAt(t.position),f!==34)return!1;for(t.kind="scalar",t.result="",t.position++,r=s=t.position;(f=t.input.charCodeAt(t.position))!==0;){if(f===34)return n0(t,r,t.position,!0),t.position++,!0;if(f===92){if(n0(t,r,t.position,!0),f=t.input.charCodeAt(++t.position),jf(f))as(t,!1,e);else if(f<256&&Lte[f])t.result+=Mte[f],t.position++;else if((c=C9e(f))>0){for(a=c,n=0;a>0;a--)f=t.input.charCodeAt(++t.position),(c=I9e(f))>=0?n=(n<<4)+c:Rr(t,"expected hexadecimal character");t.result+=B9e(n),t.position++}else Rr(t,"unknown escape sequence");r=s=t.position}else jf(f)?(n0(t,r,s,!0),$U(t,as(t,!1,e)),r=s=t.position):t.position===t.lineStart&&Cx(t)?Rr(t,"unexpected end of the document within a double quoted scalar"):(t.position++,s=t.position)}Rr(t,"unexpected end of the stream within a double quoted scalar")}function P9e(t,e){var r=!0,s,a=t.tag,n,c=t.anchor,f,p,h,E,C,S={},P,I,R,N;if(N=t.input.charCodeAt(t.position),N===91)p=93,C=!1,n=[];else if(N===123)p=125,C=!0,n={};else return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=n),N=t.input.charCodeAt(++t.position);N!==0;){if(as(t,!0,e),N=t.input.charCodeAt(t.position),N===p)return t.position++,t.tag=a,t.anchor=c,t.kind=C?"mapping":"sequence",t.result=n,!0;r||Rr(t,"missed comma between flow collection entries"),I=P=R=null,h=E=!1,N===63&&(f=t.input.charCodeAt(t.position+1),rl(f)&&(h=E=!0,t.position++,as(t,!0,e))),s=t.line,yE(t,e,yx,!1,!0),I=t.tag,P=t.result,as(t,!0,e),N=t.input.charCodeAt(t.position),(E||t.line===s)&&N===58&&(h=!0,N=t.input.charCodeAt(++t.position),as(t,!0,e),yE(t,e,yx,!1,!0),R=t.result),C?mE(t,n,S,I,P,R):h?n.push(mE(t,null,S,I,P,R)):n.push(P),as(t,!0,e),N=t.input.charCodeAt(t.position),N===44?(r=!0,N=t.input.charCodeAt(++t.position)):r=!1}Rr(t,"unexpected end of the stream within a flow collection")}function x9e(t,e){var r,s,a=XU,n=!1,c=!1,f=e,p=0,h=!1,E,C;if(C=t.input.charCodeAt(t.position),C===124)s=!1;else if(C===62)s=!0;else return!1;for(t.kind="scalar",t.result="";C!==0;)if(C=t.input.charCodeAt(++t.position),C===43||C===45)XU===a?a=C===43?Ste:d9e:Rr(t,"repeat of a chomping mode identifier");else if((E=w9e(C))>=0)E===0?Rr(t,"bad explicit indentation width of a block scalar; it cannot be less than one"):c?Rr(t,"repeat of an indentation width identifier"):(f=e+E-1,c=!0);else break;if(Qd(C)){do C=t.input.charCodeAt(++t.position);while(Qd(C));if(C===35)do C=t.input.charCodeAt(++t.position);while(!jf(C)&&C!==0)}for(;C!==0;){for(ZU(t),t.lineIndent=0,C=t.input.charCodeAt(t.position);(!c||t.lineIndent<f)&&C===32;)t.lineIndent++,C=t.input.charCodeAt(++t.position);if(!c&&t.lineIndent>f&&(f=t.lineIndent),jf(C)){p++;continue}if(t.lineIndent<f){a===Ste?t.result+=Ip.repeat(`
`,n?1+p:p):a===XU&&n&&(t.result+=`
`);break}for(s?Qd(C)?(h=!0,t.result+=Ip.repeat(`
`,n?1+p:p)):h?(h=!1,t.result+=Ip.repeat(`
`,p+1)):p===0?n&&(t.result+=" "):t.result+=Ip.repeat(`
`,p):t.result+=Ip.repeat(`
`,n?1+p:p),n=!0,c=!0,p=0,r=t.position;!jf(C)&&C!==0;)C=t.input.charCodeAt(++t.position);n0(t,r,t.position,!1)}return!0}function kte(t,e){var r,s=t.tag,a=t.anchor,n=[],c,f=!1,p;for(t.anchor!==null&&(t.anchorMap[t.anchor]=n),p=t.input.charCodeAt(t.position);p!==0&&!(p!==45||(c=t.input.charCodeAt(t.position+1),!rl(c)));){if(f=!0,t.position++,as(t,!0,-1)&&t.lineIndent<=e){n.push(null),p=t.input.charCodeAt(t.position);continue}if(r=t.line,yE(t,e,Fte,!1,!0),n.push(t.result),as(t,!0,-1),p=t.input.charCodeAt(t.position),(t.line===r||t.lineIndent>e)&&p!==0)Rr(t,"bad indentation of a sequence entry");else if(t.lineIndent<e)break}return f?(t.tag=s,t.anchor=a,t.kind="sequence",t.result=n,!0):!1}function k9e(t,e,r){var s,a,n,c,f=t.tag,p=t.anchor,h={},E={},C=null,S=null,P=null,I=!1,R=!1,N;for(t.anchor!==null&&(t.anchorMap[t.anchor]=h),N=t.input.charCodeAt(t.position);N!==0;){if(s=t.input.charCodeAt(t.position+1),n=t.line,c=t.position,(N===63||N===58)&&rl(s))N===63?(I&&(mE(t,h,E,C,S,null),C=S=P=null),R=!0,I=!0,a=!0):I?(I=!1,a=!0):Rr(t,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),t.position+=1,N=s;else if(yE(t,r,Rte,!1,!0))if(t.line===n){for(N=t.input.charCodeAt(t.position);Qd(N);)N=t.input.charCodeAt(++t.position);if(N===58)N=t.input.charCodeAt(++t.position),rl(N)||Rr(t,"a whitespace character is expected after the key-value separator within a block mapping"),I&&(mE(t,h,E,C,S,null),C=S=P=null),R=!0,I=!1,a=!1,C=t.tag,S=t.result;else if(R)Rr(t,"can not read an implicit mapping pair; a colon is missed");else return t.tag=f,t.anchor=p,!0}else if(R)Rr(t,"can not read a block mapping entry; a multiline key may not be an implicit key");else return t.tag=f,t.anchor=p,!0;else break;if((t.line===n||t.lineIndent>e)&&(yE(t,e,Ex,!0,a)&&(I?S=t.result:P=t.result),I||(mE(t,h,E,C,S,P,n,c),C=S=P=null),as(t,!0,-1),N=t.input.charCodeAt(t.position)),t.lineIndent>e&&N!==0)Rr(t,"bad indentation of a mapping entry");else if(t.lineIndent<e)break}return I&&mE(t,h,E,C,S,null),R&&(t.tag=f,t.anchor=p,t.kind="mapping",t.result=h),R}function Q9e(t){var e,r=!1,s=!1,a,n,c;if(c=t.input.charCodeAt(t.position),c!==33)return!1;if(t.tag!==null&&Rr(t,"duplication of a tag property"),c=t.input.charCodeAt(++t.position),c===60?(r=!0,c=t.input.charCodeAt(++t.position)):c===33?(s=!0,a="!!",c=t.input.charCodeAt(++t.position)):a="!",e=t.position,r){do c=t.input.charCodeAt(++t.position);while(c!==0&&c!==62);t.position<t.length?(n=t.input.slice(e,t.position),c=t.input.charCodeAt(++t.position)):Rr(t,"unexpected end of the stream within a verbatim tag")}else{for(;c!==0&&!rl(c);)c===33&&(s?Rr(t,"tag suffix cannot contain exclamation marks"):(a=t.input.slice(e-1,t.position+1),Nte.test(a)||Rr(t,"named tag handle cannot contain such characters"),s=!0,e=t.position+1)),c=t.input.charCodeAt(++t.position);n=t.input.slice(e,t.position),E9e.test(n)&&Rr(t,"tag suffix cannot contain flow indicator characters")}return n&&!Ote.test(n)&&Rr(t,"tag name cannot contain such characters: "+n),r?t.tag=n:i0.call(t.tagMap,a)?t.tag=t.tagMap[a]+n:a==="!"?t.tag="!"+n:a==="!!"?t.tag="tag:yaml.org,2002:"+n:Rr(t,'undeclared tag handle "'+a+'"'),!0}function T9e(t){var e,r;if(r=t.input.charCodeAt(t.position),r!==38)return!1;for(t.anchor!==null&&Rr(t,"duplication of an anchor property"),r=t.input.charCodeAt(++t.position),e=t.position;r!==0&&!rl(r)&&!dE(r);)r=t.input.charCodeAt(++t.position);return t.position===e&&Rr(t,"name of an anchor node must contain at least one character"),t.anchor=t.input.slice(e,t.position),!0}function R9e(t){var e,r,s;if(s=t.input.charCodeAt(t.position),s!==42)return!1;for(s=t.input.charCodeAt(++t.position),e=t.position;s!==0&&!rl(s)&&!dE(s);)s=t.input.charCodeAt(++t.position);return t.position===e&&Rr(t,"name of an alias node must contain at least one character"),r=t.input.slice(e,t.position),i0.call(t.anchorMap,r)||Rr(t,'unidentified alias "'+r+'"'),t.result=t.anchorMap[r],as(t,!0,-1),!0}function yE(t,e,r,s,a){var n,c,f,p=1,h=!1,E=!1,C,S,P,I,R;if(t.listener!==null&&t.listener("open",t),t.tag=null,t.anchor=null,t.kind=null,t.result=null,n=c=f=Ex===r||Fte===r,s&&as(t,!0,-1)&&(h=!0,t.lineIndent>e?p=1:t.lineIndent===e?p=0:t.lineIndent<e&&(p=-1)),p===1)for(;Q9e(t)||T9e(t);)as(t,!0,-1)?(h=!0,f=n,t.lineIndent>e?p=1:t.lineIndent===e?p=0:t.lineIndent<e&&(p=-1)):f=!1;if(f&&(f=h||a),(p===1||Ex===r)&&(yx===r||Rte===r?I=e:I=e+1,R=t.position-t.lineStart,p===1?f&&(kte(t,R)||k9e(t,R,I))||P9e(t,I)?E=!0:(c&&x9e(t,I)||D9e(t,I)||b9e(t,I)?E=!0:R9e(t)?(E=!0,(t.tag!==null||t.anchor!==null)&&Rr(t,"alias node should not have any properties")):S9e(t,I,yx===r)&&(E=!0,t.tag===null&&(t.tag="?")),t.anchor!==null&&(t.anchorMap[t.anchor]=t.result)):p===0&&(E=f&&kte(t,R))),t.tag!==null&&t.tag!=="!")if(t.tag==="?"){for(t.result!==null&&t.kind!=="scalar"&&Rr(t,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+t.kind+'"'),C=0,S=t.implicitTypes.length;C<S;C+=1)if(P=t.implicitTypes[C],P.resolve(t.result)){t.result=P.construct(t.result),t. Line truncated
`),t.charCodeAt(0)===65279&&(t=t.slice(1)));var r=new v9e(t,e),s=t.indexOf("\0");for(s!==-1&&(r.position=s,Rr(r,"null byte is not allowed in input")),r.input+="\0";r.input.charCodeAt(r.position)===32;)r.lineIndent+=1,r.position+=1;for(;r.position<r.length-1;)F9e(r);return r.documents}function Hte(t,e,r){e!==null&&typeof e=="object"&&typeof r>"u"&&(r=e,e=null);var s=_te(t,r);if(typeof e!="function")return s;for(var a=0,n=s.length;a<n;a+=1)e(s[a])}function jte(t,e){var r=_te(t,e);if(r.length!==0){if(r.length===1)return r[0];throw new Qte("expected a single document in the stream, but found more")}}function N9e(t,e,r){return typeof e=="object"&&e!==null&&typeof r>"u"&&(r=e,e=null),Hte(t,e,Ip.extend({schema:Tte},r))}function O9e(t,e){return jte(t,Ip.extend({schema:Tte},e))}q2.exports.loadAll=Hte;q2.exports.load=jte;q2.exports.safeLoadAll=N9e;q2.exports.safeLoad=O9e});var Are=_((QQt,n_)=>{"use strict";var Y2=bd(),V2=pE(),L9e=G2(),M9e=gE(),Xte=Object.prototype.toString,Zte=Object.prototype.hasOwnProperty,U9e=9,W2=10,_9e=13,H9e=32,j9e=33,G9e=34,$te=35,q9e=37,W9e=38,Y9e=39,V9e=42,ere=44,J9e=45,tre=58,K9e=61,z9e=62,X9e=63,Z9e=64,rre=91,nre=93,$9e=96,ire=123,eWe=124,sre=125,_o={};_o[0]="\\0";_o[7]="\\a";_o[8]="\\b";_o[9]="\\t";_o[10]="\\n";_o[11]="\\v";_o[12]="\\f";_o[13]="\\r";_o[27]="\\e";_o[34]='\\"';_o[92]="\\\\";_o[133]="\\N";_o[160]="\\_";_o[8232]="\\L";_o[8233]="\\P";var tWe=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"];function rWe(t,e){var r,s,a,n,c,f,p;if(e===null)return{};for(r={},s=Object.keys(e),a=0,n=s.length;a<n;a+=1)c=s[a],f=String(e[c]),c.slice(0,2)==="!!"&&(c="tag:yaml.org,2002:"+c.slice(2)),p=t.compiledTypeMap.fallback[c],p&&Zte.call(p.styleAliases,f)&&(f=p.styleAliases[f]),r[c]=f;return r}function qte(t){var e,r,s;if(e=t.toString(16).toUpperCase(),t<=255)r="x",s=2;else if(t<=65535)r="u",s=4;else if(t<=4294967295)r="U",s=8;else throw new V2("code point within a string may not be greater than 0xFFFFFFFF");return"\\"+r+Y2.repeat("0",s-e.length)+e}function nWe(t){this.schema=t.schema||L9e,this.indent=Math.max(1,t.indent||2),this.noArrayIndent=t.noArrayIndent||!1,this.skipInvalid=t.skipInvalid||!1,this.flowLevel=Y2.isNothing(t.flowLevel)?-1:t.flowLevel,this.styleMap=rWe(this.schema,t.styles||null),this.sortKeys=t.sortKeys||!1,this.lineWidth=t.lineWidth||80,this.noRefs=t.noRefs||!1,this.noCompatMode=t.noCompatMode||!1,this.condenseFlow=t.condenseFlow||!1,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}function Wte(t,e){for(var r=Y2.repeat(" ",e),s=0,a=-1,n="",c,f=t.length;s<f;)a=t.indexOf(`
`,s),a===-1?(c=t.slice(s),s=f):(c=t.slice(s,a+1),s=a+1),c.length&&c!==`
`&&(n+=r),n+=c;return n}function e_(t,e){return`
`+Y2.repeat(" ",t.indent*e)}function iWe(t,e){var r,s,a;for(r=0,s=t.implicitTypes.length;r<s;r+=1)if(a=t.implicitTypes[r],a.resolve(e))return!0;return!1}function r_(t){return t===H9e||t===U9e}function EE(t){return 32<=t&&t<=126||161<=t&&t<=55295&&t!==8232&&t!==8233||57344<=t&&t<=65533&&t!==65279||65536<=t&&t<=1114111}function sWe(t){return EE(t)&&!r_(t)&&t!==65279&&t!==_9e&&t!==W2}function Yte(t,e){return EE(t)&&t!==65279&&t!==ere&&t!==rre&&t!==nre&&t!==ire&&t!==sre&&t!==tre&&(t!==$te||e&&sWe(e))}function oWe(t){return EE(t)&&t!==65279&&!r_(t)&&t!==J9e&&t!==X9e&&t!==tre&&t!==ere&&t!==rre&&t!==nre&&t!==ire&&t!==sre&&t!==$te&&t!==W9e&&t!==V9e&&t!==j9e&&t!==eWe&&t!==K9e&&t!==z9e&&t!==Y9e&&t!==G9e&&t!==q9e&&t!==Z9e&&t!==$9e}function ore(t){var e=/^\n* /;return e.test(t)}var are=1,lre=2,cre=3,ure=4,wx=5;function aWe(t,e,r,s,a){var n,c,f,p=!1,h=!1,E=s!==-1,C=-1,S=oWe(t.charCodeAt(0))&&!r_(t.charCodeAt(t.length-1));if(e)for(n=0;n<t.length;n++){if(c=t.charCodeAt(n),!EE(c))return wx;f=n>0?t.charCodeAt(n-1):null,S=S&&Yte(c,f)}else{for(n=0;n<t.length;n++){if(c=t.charCodeAt(n),c===W2)p=!0,E&&(h=h||n-C-1>s&&t[C+1]!==" ",C=n);else if(!EE(c))return wx;f=n>0?t.charCodeAt(n-1):null,S=S&&Yte(c,f)}h=h||E&&n-C-1>s&&t[C+1]!==" "}return!p&&!h?S&&!a(t)?are:lre:r>9&&ore(t)?wx:h?ure:cre}function lWe(t,e,r,s){t.dump=function(){if(e.length===0)return"''";if(!t.noCompatMode&&tWe.indexOf(e)!==-1)return"'"+e+"'";var a=t.indent*Math.max(1,r),n=t.lineWidth===-1?-1:Math.max(Math.min(t.lineWidth,40),t.lineWidth-a),c=s||t.flowLevel>-1&&r>=t.flowLevel;function f(p){return iWe(t,p)}switch(aWe(e,c,t.indent,n,f)){case are:return e;case lre:return"'"+e.replace(/'/g,"''")+"'";case cre:return"|"+Vte(e,t.indent)+Jte(Wte(e,a));case ure:return">"+Vte(e,t.indent)+Jte(Wte(cWe(e,n),a));case wx:return'"'+uWe(e,n)+'"';default:throw new V2("impossible error: invalid scalar style")}}()}function Vte(t,e){var r=ore(t)?String(e):"",s=t[t.length-1]===`
`,a=s&&(t[t.length-2]===`
`||t===`
`),n=a?"+":s?"":"-";return r+n+`
`}function Jte(t){return t[t.length-1]===`
`?t.slice(0,-1):t}function cWe(t,e){for(var r=/(\n+)([^\n]*)/g,s=function(){var h=t.indexOf(`
`);return h=h!==-1?h:t.length,r.lastIndex=h,Kte(t.slice(0,h),e)}(),a=t[0]===`
`||t[0]===" ",n,c;c=r.exec(t);){var f=c[1],p=c[2];n=p[0]===" ",s+=f+(!a&&!n&&p!==""?`
`:"")+Kte(p,e),a=n}return s}function Kte(t,e){if(t===""||t[0]===" ")return t;for(var r=/ [^ ]/g,s,a=0,n,c=0,f=0,p="";s=r.exec(t);)f=s.index,f-a>e&&(n=c>a?c:f,p+=`
`+t.slice(a,n),a=n+1),c=f;return p+=`
`,t.length-a>e&&c>a?p+=t.slice(a,c)+`
`+t.slice(c+1):p+=t.slice(a),p.slice(1)}function uWe(t){for(var e="",r,s,a,n=0;n<t.length;n++){if(r=t.charCodeAt(n),r>=55296&&r<=56319&&(s=t.charCodeAt(n+1),s>=56320&&s<=57343)){e+=qte((r-55296)*1024+s-56320+65536),n++;continue}a=_o[r],e+=!a&&EE(r)?t[n]:a||qte(r)}return e}function fWe(t,e,r){var s="",a=t.tag,n,c;for(n=0,c=r.length;n<c;n+=1)Td(t,e,r[n],!1,!1)&&(n!==0&&(s+=","+(t.condenseFlow?"":" ")),s+=t.dump);t.tag=a,t.dump="["+s+"]"}function AWe(t,e,r,s){var a="",n=t.tag,c,f;for(c=0,f=r.length;c<f;c+=1)Td(t,e+1,r[c],!0,!0)&&((!s||c!==0)&&(a+=e_(t,e)),t.dump&&W2===t.dump.charCodeAt(0)?a+="-":a+="- ",a+=t.dump);t.tag=n,t.dump=a||"[]"}function pWe(t,e,r){var s="",a=t.tag,n=Object.keys(r),c,f,p,h,E;for(c=0,f=n.length;c<f;c+=1)E="",c!==0&&(E+=", "),t.condenseFlow&&(E+='"'),p=n[c],h=r[p],Td(t,e,p,!1,!1)&&(t.dump.length>1024&&(E+="? "),E+=t.dump+(t.condenseFlow?'"':"")+":"+(t.condenseFlow?"":" "),Td(t,e,h,!1,!1)&&(E+=t.dump,s+=E));t.tag=a,t.dump="{"+s+"}"}function hWe(t,e,r,s){var a="",n=t.tag,c=Object.keys(r),f,p,h,E,C,S;if(t.sortKeys===!0)c.sort();else if(typeof t.sortKeys=="function")c.sort(t.sortKeys);else if(t.sortKeys)throw new V2("sortKeys must be a boolean or a function");for(f=0,p=c.length;f<p;f+=1)S="",(!s||f!==0)&&(S+=e_(t,e)),h=c[f],E=r[h],Td(t,e+1,h,!0,!0,!0)&&(C=t.tag!==null&&t.tag!=="?"||t.dump&&t.dump.length>1024,C&&(t.dump&&W2===t.dump.charCodeAt(0)?S+="?":S+="? "),S+=t.dump,C&&(S+=e_(t,e)),Td(t,e+1,E,!0,C)&&(t.dump&&W2===t.dump.charCodeAt(0)?S+=":":S+=": ",S+=t.dump,a+=S));t.tag=n,t.dump=a||"{}"}function zte(t,e,r){var s,a,n,c,f,p;for(a=r?t.explicitTypes:t.implicitTypes,n=0,c=a.length;n<c;n+=1)if(f=a[n],(f.instanceOf||f.predicate)&&(!f.instanceOf||typeof e=="object"&&e instanceof f.instanceOf)&&(!f.predicate||f.predicate(e))){if(t.tag=r?f.tag:"?",f.represent){if(p=t.styleMap[f.tag]||f.defaultStyle,Xte.call(f.represent)==="[object Function]")s=f.represent(e,p);else if(Zte.call(f.represent,p))s=f.represent[p](e,p);else throw new V2("!<"+f.tag+'> tag resolver accepts not "'+p+'" style');t.dump=s}return!0}return!1}function Td(t,e,r,s,a,n){t.tag=null,t.dump=r,zte(t,r,!1)||zte(t,r,!0);var c=Xte.call(t.dump);s&&(s=t.flowLevel<0||t.flowLevel>e);var f=c==="[object Object]"||c==="[object Array]",p,h;if(f&&(p=t.duplicates.indexOf(r),h=p!==-1),(t.tag!==null&&t.tag!=="?"||h||t.indent!==2&&e>0)&&(a=!1),h&&t.usedDuplicates[p])t.dump="*ref_"+p;else{if(f&&h&&!t.usedDuplicates[p]&&(t.usedDuplicates[p]=!0),c==="[object Object]")s&&Object.keys(t.dump).length!==0?(hWe(t,e,t.dump,a),h&&(t.dump="&ref_"+p+t.dump)):(pWe(t,e,t.dump),h&&(t.dump="&ref_"+p+" "+t.dump));else if(c==="[object Array]"){var E=t.noArrayIndent&&e>0?e-1:e;s&&t.dump.length!==0?(AWe(t,E,t.dump,a),h&&(t.dump="&ref_"+p+t.dump)):(fWe(t,E,t.dump),h&&(t.dump="&ref_"+p+" "+t.dump))}else if(c==="[object String]")t.tag!=="?"&&lWe(t,t.dump,e,n);else{if(t.skipInvalid)return!1;throw new V2("unacceptable kind of an object to dump "+c)}t.tag!==null&&t.tag!=="?"&&(t.dump="!<"+t.tag+"> "+t.dump)}return!0}function gWe(t,e){var r=[],s=[],a,n;for(t_(t,r,s),a=0,n=s.length;a<n;a+=1)e.duplicates.push(r[s[a]]);e.usedDuplicates=new Array(n)}function t_(t,e,r){var s,a,n;if(t!==null&&typeof t=="object")if(a=e.indexOf(t),a!==-1)r.indexOf(a)===-1&&r.push(a);else if(e.push(t),Array.isArray(t))for(a=0,n=t.length;a<n;a+=1)t_(t[a],e,r);else for(s=Object.keys(t),a=0,n=s.length;a<n;a+=1)t_(t[s[a]],e,r)}function fre(t,e){e=e||{};var r=new nWe(e);return r.noRefs||gWe(t,r),Td(r,0,t,!0,!0)?r.dump+`
`:""}function dWe(t,e){return fre(t,Y2.extend({schema:M9e},e))}n_.exports.dump=fre;n_.exports.safeDump=dWe});var hre=_((TQt,Wi)=>{"use strict";var Bx=Gte(),pre=Are();function vx(t){return function(){throw new Error("Function "+t+" is deprecated and cannot be used.")}}Wi.exports.Type=Ss();Wi.exports.Schema=Pd();Wi.exports.FAILSAFE_SCHEMA=dx();Wi.exports.JSON_SCHEMA=JU();Wi.exports.CORE_SCHEMA=KU();Wi.exports.DEFAULT_SAFE_SCHEMA=gE();Wi.exports.DEFAULT_FULL_SCHEMA=G2();Wi.exports.load=Bx.load;Wi.exports.loadAll=Bx.loadAll;Wi.exports.safeLoad=Bx.safeLoad;Wi.exports.safeLoadAll=Bx.safeLoadAll;Wi.exports.dump=pre.dump;Wi.exports.safeDump=pre.safeDump;Wi.exports.YAMLException=pE();Wi.exports.MINIMAL_SCHEMA=dx();Wi.exports.SAFE_SCHEMA=gE();Wi.exports.DEFAULT_SCHEMA=G2();Wi.exports.scan=vx("scan");Wi.exports.parse=vx("parse");Wi.exports.compose=vx("compose");Wi.exports.addConstructor=vx("addConstructor")});var dre=_((RQt,gre)=>{"use strict";var mWe=hre();gre.exports=mWe});var yre=_((FQt,mre)=>{"use strict";function yWe(t,e){function r(){this.constructor=t}r.prototype=e.prototype,t.prototype=new r}function Rd(t,e,r,s){this.message=t,this.expected=e,this.found=r,this.location=s,this.name="SyntaxError",typeof Error.captureStackTrace=="function"&&Error.captureStackTrace(this,Rd)}yWe(Rd,Error);Rd.buildMessage=function(t,e){var r={literal:function(h){return'"'+a(h.text)+'"'},class:function(h){var E="",C;for(C=0;C<h.parts.length;C++)E+=h.parts[C]instanceof Array?n(h.parts[C][0])+"-"+n(h.parts[C][1]):n(h.parts[C]);return"["+(h.inverted?"^":"")+E+"]"},any:function(h){return"any character"},end:function(h){return"end of input"},other:function(h){return h.description}};function s(h){return h.charCodeAt(0).toString(16).toUpperCase()}function a(h){return h.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,function(E){return"\\x0"+s(E)}).replace(/[\x10-\x1F\x7F-\x9F]/g,function(E){return"\\x"+s(E)})}function n(h){return h.replace(/\\/g,"\\\\").replace(/\]/g,"\\]").replace(/\^/g,"\\^").replace(/-/g,"\\-").replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,function(E){return"\\x0"+s(E)}).replace(/[\x10-\x1F\x7F-\x9F]/g,function(E){return"\\x"+s(E)})}function c(h){return r[h.type](h)}function f(h){var E=new Array(h.length),C,S;for(C=0;C<h.length;C++)E[C]=c(h[C]);if(E.sort(),E.length>0){for(C=1,S=1;C<E.length;C++)E[C-1]!==E[C]&&(E[S]=E[C],S++);E.length=S}switch(E.length){case 1:return E[0];case 2:return E[0]+" or "+E[1];default:return E.slice(0,-1).join(", ")+", or "+E[E.length-1]}}function p(h){return h?'"'+a(h)+'"':"end of input"}return"Expected "+f(t)+" but "+p(e)+" found."};function EWe(t,e){e=e!==void 0?e:{};var r={},s={Start:lc},a=lc,n=function(te){return[].concat(...te)},c="-",f=dn("-",!1),p=function(te){return te},h=function(te){return Object.assign({},...te)},E="#",C=dn("#",!1),S=Au(),P=function(){return{}},I=":",R=dn(":",!1),N=function(te,Ee){return{[te]:Ee}},U=",",W=dn(",",!1),ee=function(te,Ee){return Ee},ie=function(te,Ee,Oe){return Object.assign({},...[te].concat(Ee).map(dt=>({[dt]:Oe})))},ue=function(te){return te},le=function(te){return te},me=Oa("correct indentation"),pe=" ",Be=dn(" ",!1),Ce=function(te){return te.length===lr*St},g=function(te){return te.length===(lr+1)*St},we=function(){return lr++,!0},ye=function(){return lr--,!0},Ae=function(){return la()},se=Oa("pseudostring"),Z=/^[^\r\n\t ?:,\][{}#&*!|>'"%@`\-]/,De=Kn(["\r",`
`," "," ","?",":",",","]","[","{","}","#","&","*","!","|",">","'",'"',"%","@","`","-"],!0,!1),Re=/^[^\r\n\t ,\][{}:#"']/,mt=Kn(["\r",`
`," "," ",",","]","[","{","}",":","#",'"',"'"],!0,!1),j=function(){return la().replace(/^ *| *$/g,"")},rt="--",Fe=dn("--",!1),Ne=/^[a-zA-Z\/0-9]/,Pe=Kn([["a","z"],["A","Z"],"/",["0","9"]],!1,!1),Ve=/^[^\r\n\t :,]/,ke=Kn(["\r",`
`," "," ",":",","],!0,!1),it="null",Ue=dn("null",!1),x=function(){return null},w="true",b=dn("true",!1),y=function(){return!0},F="false",z=dn("false",!1),X=function(){return!1},$=Oa("string"),oe='"',xe=dn('"',!1),Te=function(){return""},lt=function(te){return te},Ct=function(te){return te.join("")},qt=/^[^"\\\0-\x1F\x7F]/,ir=Kn(['"',"\\",["\0",""],"\x7F"],!0,!1),Pt='\\"',gn=dn('\\"',!1),Pr=function(){return'"'},Ir="\\\\",Or=dn("\\\\",!1),on=function(){return"\\"},ai="\\/",Io=dn("\\/",!1),rs=function(){return"/"},$s="\\b",Co=dn("\\b",!1),ji=function(){return"\b"},eo="\\f",wo=dn("\\f",!1),QA=function(){return"\f"},Af="\\n",dh=dn("\\n",!1),mh=function(){return`
`},to="\\r",jn=dn("\\r",!1),Ts=function(){return"\r"},ro="\\t",ou=dn("\\t",!1),au=function(){return" "},lu="\\u",TA=dn("\\u",!1),RA=function(te,Ee,Oe,dt){return String.fromCharCode(parseInt(`0x${te}${Ee}${Oe}${dt}`))},oa=/^[0-9a-fA-F]/,aa=Kn([["0","9"],["a","f"],["A","F"]],!1,!1),FA=Oa("blank space"),gr=/^[ \t]/,Bo=Kn([" "," "],!1,!1),Me=Oa("white space"),cu=/^[ \t\n\r]/,Cr=Kn([" "," ",`
`,"\r"],!1,!1),pf=`\r
`,NA=dn(`\r
`,!1),OA=`
`,uu=dn(`
`,!1),fu="\r",oc=dn("\r",!1),ve=0,Nt=0,ac=[{line:1,column:1}],Oi=0,no=[],Rt=0,xn;if("startRule"in e){if(!(e.startRule in s))throw new Error(`Can't start parsing from rule "`+e.startRule+'".');a=s[e.startRule]}function la(){return t.substring(Nt,ve)}function Gi(){return Ma(Nt,ve)}function Li(te,Ee){throw Ee=Ee!==void 0?Ee:Ma(Nt,ve),hf([Oa(te)],t.substring(Nt,ve),Ee)}function Na(te,Ee){throw Ee=Ee!==void 0?Ee:Ma(Nt,ve),Ua(te,Ee)}function dn(te,Ee){return{type:"literal",text:te,ignoreCase:Ee}}function Kn(te,Ee,Oe){return{type:"class",parts:te,inverted:Ee,ignoreCase:Oe}}function Au(){return{type:"any"}}function yh(){return{type:"end"}}function Oa(te){return{type:"other",description:te}}function La(te){var Ee=ac[te],Oe;if(Ee)return Ee;for(Oe=te-1;!ac[Oe];)Oe--;for(Ee=ac[Oe],Ee={line:Ee.line,column:Ee.column};Oe<te;)t.charCodeAt(Oe)===10?(Ee.line++,Ee.column=1):Ee.column++,Oe++;return ac[te]=Ee,Ee}function Ma(te,Ee){var Oe=La(te),dt=La(Ee);return{start:{offset:te,line:Oe.line,column:Oe.column},end:{offset:Ee,line:dt.line,column:dt.column}}}function $e(te){ve<Oi||(ve>Oi&&(Oi=ve,no=[]),no.push(te))}function Ua(te,Ee){return new Rd(te,null,null,Ee)}function hf(te,Ee,Oe){return new Rd(Rd.buildMessage(te,Ee),te,Ee,Oe)}function lc(){var te;return te=LA(),te}function wn(){var te,Ee,Oe;for(te=ve,Ee=[],Oe=ca();Oe!==r;)Ee.push(Oe),Oe=ca();return Ee!==r&&(Nt=te,Ee=n(Ee)),te=Ee,te}function ca(){var te,Ee,Oe,dt,Et;return te=ve,Ee=Bl(),Ee!==r?(t.charCodeAt(ve)===45?(Oe=c,ve++):(Oe=r,Rt===0&&$e(f)),Oe!==r?(dt=Qn(),dt!==r?(Et=ua(),Et!==r?(Nt=te,Ee=p(Et),te=Ee):(ve=te,te=r)):(ve=te,te=r)):(ve=te,te=r)):(ve=te,te=r),te}function LA(){var te,Ee,Oe;for(te=ve,Ee=[],Oe=MA();Oe!==r;)Ee.push(Oe),Oe=MA();return Ee!==r&&(Nt=te,Ee=h(Ee)),te=Ee,te}function MA(){var te,Ee,Oe,dt,Et,bt,tr,An,li;if(te=ve,Ee=Qn(),Ee===r&&(Ee=null),Ee!==r){if(Oe=ve,t.charCodeAt(ve)===35?(dt=E,ve++):(dt=r,Rt===0&&$e(C)),dt!==r){if(Et=[],bt=ve,tr=ve,Rt++,An=st(),Rt--,An===r?tr=void 0:(ve=tr,tr=r),tr!==r?(t.length>ve?(An=t.charAt(ve),ve++):(An=r,Rt===0&&$e(S)),An!==r?(tr=[tr,An],bt=tr):(ve=bt,bt=r)):(ve=bt,bt=r),bt!==r)for(;bt!==r;)Et.push(bt),bt=ve,tr=ve,Rt++,An=st(),Rt--,An===r?tr=void 0:(ve=tr,tr=r),tr!==r?(t.length>ve?(An=t.charAt(ve),ve++):(An=r,Rt===0&&$e(S)),An!==r?(tr=[tr,An],bt=tr):(ve=bt,bt=r)):(ve=bt,bt=r);else Et=r;Et!==r?(dt=[dt,Et],Oe=dt):(ve=Oe,Oe=r)}else ve=Oe,Oe=r;if(Oe===r&&(Oe=null),Oe!==r){if(dt=[],Et=Ke(),Et!==r)for(;Et!==r;)dt.push(Et),Et=Ke();else dt=r;dt!==r?(Nt=te,Ee=P(),te=Ee):(ve=te,te=r)}else ve=te,te=r}else ve=te,te=r;if(te===r&&(te=ve,Ee=Bl(),Ee!==r?(Oe=Ha(),Oe!==r?(dt=Qn(),dt===r&&(dt=null),dt!==r?(t.charCodeAt(ve)===58?(Et=I,ve++):(Et=r,Rt===0&&$e(R)),Et!==r?(bt=Qn(),bt===r&&(bt=null),bt!==r?(tr=ua(),tr!==r?(Nt=te,Ee=N(Oe,tr),te=Ee):(ve=te,te=r)):(ve=te,te=r)):(ve=te,te=r)):(ve=te,te=r)):(ve=te,te=r)):(ve=te,te=r),te===r&&(te=ve,Ee=Bl(),Ee!==r?(Oe=ns(),Oe!==r?(dt=Qn(),dt===r&&(dt=null),dt!==r?(t.charCodeAt(ve)===58?(Et=I,ve++):(Et=r,Rt===0&&$e(R)),Et!==r?(bt=Qn(),bt===r&&(bt=null),bt!==r?(tr=ua(),tr!==r?(Nt=te,Ee=N(Oe,tr),te=Ee):(ve=te,te=r)):(ve=te,te=r)):(ve=te,te=r)):(ve=te,te=r)):(ve=te,te=r)):(ve=te,te=r),te===r))){if(te=ve,Ee=Bl(),Ee!==r)if(Oe=ns(),Oe!==r)if(dt=Qn(),dt!==r)if(Et=pu(),Et!==r){if(bt=[],tr=Ke(),tr!==r)for(;tr!==r;)bt.push(tr),tr=Ke();else bt=r;bt!==r?(Nt=te,Ee=N(Oe,Et),te=Ee):(ve=te,te=r)}else ve=te,te=r;else ve=te,te=r;else ve=te,te=r;else ve=te,te=r;if(te===r)if(te=ve,Ee=Bl(),Ee!==r)if(Oe=ns(),Oe!==r){if(dt=[],Et=ve,bt=Qn(),bt===r&&(bt=null),bt!==r?(t.charCodeAt(ve)===44?(tr=U,ve++):(tr=r,Rt===0&&$e(W)),tr!==r?(An=Qn(),An===r&&(An=null),An!==r?(li=ns(),li!==r?(Nt=Et,bt=ee(Oe,li),Et=bt):(ve=Et,Et=r)):(ve=Et,Et=r)):(ve=Et,Et=r)):(ve=Et,Et=r),Et!==r)for(;Et!==r;)dt.push(Et),Et=ve,bt=Qn(),bt===r&&(bt=null),bt!==r?(t.charCodeAt(ve)===44?(tr=U,ve++):(tr=r,Rt===0&&$e(W)),tr!==r?(An=Qn(),An===r&&(An=null),An!==r?(li=ns(),li!==r?(Nt=Et,bt=ee(Oe,li),Et=bt):(ve=Et,Et=r)):(ve=Et,Et=r)):(ve=Et,Et=r)):(ve=Et,Et=r);else dt=r;dt!==r?(Et=Qn(),Et===r&&(Et=null),Et!==r?(t.charCodeAt(ve)===58?(bt=I,ve++):(bt=r,Rt===0&&$e(R)),bt!==r?(tr=Qn(),tr===r&&(tr=null),tr!==r?(An=ua(),An!==r?(Nt=te,Ee=ie(Oe,dt,An),te=Ee):(ve=te,te=r)):(ve=te,te=r)):(ve=te,te=r)):(ve=te,te=r)):(ve=te,te=r)}else ve=te,te=r;else ve=te,te=r}return te}function ua(){var te,Ee,Oe,dt,Et,bt,tr;if(te=ve,Ee=ve,Rt++,Oe=ve,dt=st(),dt!==r?(Et=Mt(),Et!==r?(t.charCodeAt(ve)===45?(bt=c,ve++):(bt=r,Rt===0&&$e(f)),bt!==r?(tr=Qn(),tr!==r?(dt=[dt,Et,bt,tr],Oe=dt):(ve=Oe,Oe=r)):(ve=Oe,Oe=r)):(ve=Oe,Oe=r)):(ve=Oe,Oe=r),Rt--,Oe!==r?(ve=Ee,Ee=void 0):Ee=r,Ee!==r?(Oe=Ke(),Oe!==r?(dt=kn(),dt!==r?(Et=wn(),Et!==r?(bt=fa(),bt!==r?(Nt=te,Ee=ue(Et),te=Ee):(ve=te,te=r)):(ve=te,te=r)):(ve=te,te=r)):(ve=te,te=r)):(ve=te,te=r),te===r&&(te=ve,Ee=st(),Ee!==r?(Oe=kn(),Oe!==r?(dt=LA(),dt!==r?(Et=fa(),Et!==r?(Nt=te,Ee=ue(dt),te=Ee):(ve=te,te=r)):(ve=te,te=r)):(ve=te,te=r)):(ve=te,te=r),te===r))if(te=ve,Ee=cc(),Ee!==r){if(Oe=[],dt=Ke(),dt!==r)for(;dt!==r;)Oe.push(dt),dt=Ke();else Oe=r;Oe!==r?(Nt=te,EeLine truncated
`;if(typeof t=="number"||typeof t=="boolean")return`${t.toString()}
`;if(typeof t=="string")return`${Ire(t)}
`;if(Array.isArray(t)){if(t.length===0)return`[]
`;let s=" ".repeat(e);return`
${t.map(n=>`${s}- ${i_(n,e+1,!1)}`).join("")}`}if(typeof t=="object"&&t){let[s,a]=t instanceof Sx?[t.data,!1]:[t,!0],n=" ".repeat(e),c=Object.keys(s);a&&c.sort((p,h)=>{let E=Ere.indexOf(p),C=Ere.indexOf(h);return E===-1&&C===-1?p<h?-1:p>h?1:0:E!==-1&&C===-1?-1:E===-1&&C!==-1?1:E-C});let f=c.filter(p=>!wre(s[p])).map((p,h)=>{let E=s[p],C=Ire(p),S=i_(E,e+1,!0),P=h>0||r?n:"",I=C.length>1024?`? ${C}
${P}:`:`${C}:`,R=S.startsWith(`
`)?S:` ${S}`;return`${P}${I}${R}`}).join(e===0?`
`:"")||`
`;return r?`
${f}`:`${f}`}throw new Error(`Unsupported value type (${t})`)}function nl(t){try{let e=i_(t,0,!1);return e!==`
`?e:""}catch(e){throw e.location&&(e.message=e.message.replace(/(\.)?$/,` (line ${e.location.start.line}, column ${e.location.start.column})$1`)),e}}function CWe(t){return t.endsWith(`
`)||(t+=`
`),(0,Cre.parse)(t)}function BWe(t){if(wWe.test(t))return CWe(t);let e=(0,Dx.safeLoad)(t,{schema:Dx.FAILSAFE_SCHEMA,json:!0});if(e==null)return{};if(typeof e!="object")throw new Error(`Expected an indexed object, got a ${typeof e} instead. Does your file follow Yaml's rules?`);if(Array.isArray(e))throw new Error("Expected an indexed object, got an array instead. Does your file follow Yaml's rules?");return e}function ls(t){return BWe(t)}var Dx,Cre,IWe,Ere,Sx,wWe,Bre=Xe(()=>{Dx=ut(dre()),Cre=ut(yre()),IWe=/^(?![-?:,\][{}#&*!|>'"%@` \t\r\n]).([ \t]*(?![,\][{}:# \t\r\n]).)*$/,Ere=["__metadata","version","resolution","dependencies","peerDependencies","dependenciesMeta","peerDependenciesMeta","binaries"],Sx=class{constructor(e){this.data=e}};nl.PreserveOrdering=Sx;wWe=/^(#.*(\r?\n))*?#\s+yarn\s+lockfile\s+v1\r?\n/i});var J2={};Vt(J2,{parseResolution:()=>px,parseShell:()=>ux,parseSyml:()=>ls,stringifyArgument:()=>qU,stringifyArgumentSegment:()=>WU,stringifyArithmeticExpression:()=>Ax,stringifyCommand:()=>GU,stringifyCommandChain:()=>AE,stringifyCommandChainThen:()=>jU,stringifyCommandLine:()=>fx,stringifyCommandLineThen:()=>HU,stringifyEnvSegment:()=>cx,stringifyRedirectArgument:()=>H2,stringifyResolution:()=>hx,stringifyShell:()=>fE,stringifyShellLine:()=>fE,stringifySyml:()=>nl,stringifyValueArgument:()=>vd});var wc=Xe(()=>{wee();Dee();Bre()});var Sre=_((UQt,s_)=>{"use strict";var vWe=t=>{let e=!1,r=!1,s=!1;for(let a=0;a<t.length;a++){let n=t[a];e&&/[a-zA-Z]/.test(n)&&n.toUpperCase()===n?(t=t.slice(0,a)+"-"+t.slice(a),e=!1,s=r,r=!0,a++):r&&s&&/[a-zA-Z]/.test(n)&&n.toLowerCase()===n?(t=t.slice(0,a-1)+"-"+t.slice(a-1),s=r,r=!1,e=!0):(e=n.toLowerCase()===n&&n.toUpperCase()!==n,s=r,r=n.toUpperCase()===n&&n.toLowerCase()!==n)}return t},vre=(t,e)=>{if(!(typeof t=="string"||Array.isArray(t)))throw new TypeError("Expected the input to be `string | string[]`");e=Object.assign({pascalCase:!1},e);let r=a=>e.pascalCase?a.charAt(0).toUpperCase()+a.slice(1):a;return Array.isArray(t)?t=t.map(a=>a.trim()).filter(a=>a.length).join("-"):t=t.trim(),t.length===0?"":t.length===1?e.pascalCase?t.toUpperCase():t.toLowerCase():(t!==t.toLowerCase()&&(t=vWe(t)),t=t.replace(/^[_.\- ]+/,"").toLowerCase().replace(/[_.\- ]+(\w|$)/g,(a,n)=>n.toUpperCase()).replace(/\d+(\w|$)/g,a=>a.toUpperCase()),r(t))};s_.exports=vre;s_.exports.default=vre});var Dre=_((_Qt,SWe)=>{SWe.exports=[{name:"Agola CI",constant:"AGOLA",env:"AGOLA_GIT_REF",pr:"AGOLA_PULL_REQUEST_ID"},{name:"Appcircle",constant:"APPCIRCLE",env:"AC_APPCIRCLE"},{name:"AppVeyor",constant:"APPVEYOR",env:"APPVEYOR",pr:"APPVEYOR_PULL_REQUEST_NUMBER"},{name:"AWS CodeBuild",constant:"CODEBUILD",env:"CODEBUILD_BUILD_ARN"},{name:"Azure Pipelines",constant:"AZURE_PIPELINES",env:"TF_BUILD",pr:{BUILD_REASON:"PullRequest"}},{name:"Bamboo",constant:"BAMBOO",env:"bamboo_planKey"},{name:"Bitbucket Pipelines",constant:"BITBUCKET",env:"BITBUCKET_COMMIT",pr:"BITBUCKET_PR_ID"},{name:"Bitrise",constant:"BITRISE",env:"BITRISE_IO",pr:"BITRISE_PULL_REQUEST"},{name:"Buddy",constant:"BUDDY",env:"BUDDY_WORKSPACE_ID",pr:"BUDDY_EXECUTION_PULL_REQUEST_ID"},{name:"Buildkite",constant:"BUILDKITE",env:"BUILDKITE",pr:{env:"BUILDKITE_PULL_REQUEST",ne:"false"}},{name:"CircleCI",constant:"CIRCLE",env:"CIRCLECI",pr:"CIRCLE_PULL_REQUEST"},{name:"Cirrus CI",constant:"CIRRUS",env:"CIRRUS_CI",pr:"CIRRUS_PR"},{name:"Codefresh",constant:"CODEFRESH",env:"CF_BUILD_ID",pr:{any:["CF_PULL_REQUEST_NUMBER","CF_PULL_REQUEST_ID"]}},{name:"Codemagic",constant:"CODEMAGIC",env:"CM_BUILD_ID",pr:"CM_PULL_REQUEST"},{name:"Codeship",constant:"CODESHIP",env:{CI_NAME:"codeship"}},{name:"Drone",constant:"DRONE",env:"DRONE",pr:{DRONE_BUILD_EVENT:"pull_request"}},{name:"dsari",constant:"DSARI",env:"DSARI"},{name:"Earthly",constant:"EARTHLY",env:"EARTHLY_CI"},{name:"Expo Application Services",constant:"EAS",env:"EAS_BUILD"},{name:"Gerrit",constant:"GERRIT",env:"GERRIT_PROJECT"},{name:"Gitea Actions",constant:"GITEA_ACTIONS",env:"GITEA_ACTIONS"},{name:"GitHub Actions",constant:"GITHUB_ACTIONS",env:"GITHUB_ACTIONS",pr:{GITHUB_EVENT_NAME:"pull_request"}},{name:"GitLab CI",constant:"GITLAB",env:"GITLAB_CI",pr:"CI_MERGE_REQUEST_ID"},{name:"GoCD",constant:"GOCD",env:"GO_PIPELINE_LABEL"},{name:"Google Cloud Build",constant:"GOOGLE_CLOUD_BUILD",env:"BUILDER_OUTPUT"},{name:"Harness CI",constant:"HARNESS",env:"HARNESS_BUILD_ID"},{name:"Heroku",constant:"HEROKU",env:{env:"NODE",includes:"/app/.heroku/node/bin/node"}},{name:"Hudson",constant:"HUDSON",env:"HUDSON_URL"},{name:"Jenkins",constant:"JENKINS",env:["JENKINS_URL","BUILD_ID"],pr:{any:["ghprbPullId","CHANGE_ID"]}},{name:"LayerCI",constant:"LAYERCI",env:"LAYERCI",pr:"LAYERCI_PULL_REQUEST"},{name:"Magnum CI",constant:"MAGNUM",env:"MAGNUM"},{name:"Netlify CI",constant:"NETLIFY",env:"NETLIFY",pr:{env:"PULL_REQUEST",ne:"false"}},{name:"Nevercode",constant:"NEVERCODE",env:"NEVERCODE",pr:{env:"NEVERCODE_PULL_REQUEST",ne:"false"}},{name:"Prow",constant:"PROW",env:"PROW_JOB_ID"},{name:"ReleaseHub",constant:"RELEASEH Line truncated
${this.candidates.map(({usage:a})=>`$ ${a}`).join(`
`)}`}else if(this.candidates.length===1){let[{usage:s}]=this.candidates;this.message=`Command not found; did you mean:
$ ${s}
${c_(e)}`}else this.message=`Command not found; did you mean one of:
${this.candidates.map(({usage:s},a)=>`${`${a}.`.padStart(4)} ${s}`).join(`
`)}
${c_(e)}`}},xx=class extends Error{constructor(e,r){super(),this.input=e,this.usages=r,this.clipanion={type:"none"},this.name="AmbiguousSyntaxError",this.message=`Cannot find which to pick amongst the following alternatives:
${this.usages.map((s,a)=>`${`${a}.`.padStart(4)} ${s}`).join(`
`)}
${c_(e)}`}},c_=t=>`While running ${t.filter(e=>e!==ei.EndOfInput&&e!==ei.EndOfPartialInput).map(e=>{let r=JSON.stringify(e);return e.match(/\s/)||e.length===0||r!==`"${e}"`?r:e}).join(" ")}`});function DWe(t){let e=t.split(`
`),r=e.filter(a=>a.match(/\S/)),s=r.length>0?r.reduce((a,n)=>Math.min(a,n.length-n.trimStart().length),Number.MAX_VALUE):0;return e.map(a=>a.slice(s).trimRight()).join(`
`)}function Ho(t,{format:e,paragraphs:r}){return t=t.replace(/\r\n?/g,`
`),t=DWe(t),t=t.replace(/^\n+|\n+$/g,""),t=t.replace(/^(\s*)-([^\n]*?)\n+/gm,`$1-$2
`),t=t.replace(/\n(\n)?\n*/g,(s,a)=>a||" "),r&&(t=t.split(/\n/).map(s=>{let a=s.match(/^\s*[*-][\t ]+(.*)/);if(!a)return s.match(/(.{1,80})(?: |$)/g).join(`
`);let n=s.length-s.trimStart().length;return a[1].match(new RegExp(`(.{1,${78-n}})(?: |$)`,"g")).map((c,f)=>" ".repeat(n)+(f===0?"- ":" ")+c).join(`
`)}).join(`
`)),t=t.replace(/(`+)((?:.|[\n])*?)\1/g,(s,a,n)=>e.code(a+n+a)),t=t.replace(/(\*\*)((?:.|[\n])*?)\1/g,(s,a,n)=>e.bold(a+n+a)),t?`${t}
`:""}var u_,kre,Qre,f_=Xe(()=>{u_=Array(80).fill("\u2501");for(let t=0;t<=24;++t)u_[u_.length-t]=`\x1B[38;5;${232+t}m\u2501`;kre={header:t=>`\x1B[1m\u2501\u2501\u2501 ${t}${t.length<75?` ${u_.slice(t.length+5).join("")}`:":"}\x1B[0m`,bold:t=>`\x1B[1m${t}\x1B[22m`,error:t=>`\x1B[31m\x1B[1m${t}\x1B[22m\x1B[39m`,code:t=>`\x1B[36m${t}\x1B[39m`},Qre={header:t=>t,bold:t=>t,error:t=>t,code:t=>t}});function ya(t){return{...t,[K2]:!0}}function Gf(t,e){return typeof t>"u"?[t,e]:typeof t=="object"&&t!==null&&!Array.isArray(t)?[void 0,t]:[t,e]}function Qx(t,{mergeName:e=!1}={}){let r=t.match(/^([^:]+): (.*)$/m);if(!r)return"validation failed";let[,s,a]=r;return e&&(a=a[0].toLowerCase()+a.slice(1)),a=s!=="."||!e?`${s.replace(/^\.(\[|$)/,"$1")}: ${a}`:`: ${a}`,a}function z2(t,e){return e.length===1?new nt(`${t}${Qx(e[0],{mergeName:!0})}`):new nt(`${t}:
${e.map(r=>`
- ${Qx(r)}`).join("")}`)}function Od(t,e,r){if(typeof r>"u")return e;let s=[],a=[],n=f=>{let p=e;return e=f,n.bind(null,p)};if(!r(e,{errors:s,coercions:a,coercion:n}))throw z2(`Invalid value for ${t}`,s);for(let[,f]of a)f();return e}var K2,Cp=Xe(()=>{kx();K2=Symbol("clipanion/isOption")});var Ea={};Vt(Ea,{KeyRelationship:()=>qf,TypeAssertionError:()=>o0,applyCascade:()=>$2,as:()=>WWe,assert:()=>jWe,assertWithErrors:()=>GWe,cascade:()=>Nx,fn:()=>YWe,hasAtLeastOneKey:()=>y_,hasExactLength:()=>Ore,hasForbiddenKeys:()=>fYe,hasKeyRelationship:()=>tB,hasMaxLength:()=>JWe,hasMinLength:()=>VWe,hasMutuallyExclusiveKeys:()=>AYe,hasRequiredKeys:()=>uYe,hasUniqueItems:()=>KWe,isArray:()=>Tx,isAtLeast:()=>d_,isAtMost:()=>ZWe,isBase64:()=>oYe,isBoolean:()=>FWe,isDate:()=>OWe,isDict:()=>UWe,isEnum:()=>fo,isHexColor:()=>sYe,isISO8601:()=>iYe,isInExclusiveRange:()=>eYe,isInInclusiveRange:()=>$We,isInstanceOf:()=>HWe,isInteger:()=>m_,isJSON:()=>aYe,isLiteral:()=>Rre,isLowerCase:()=>tYe,isMap:()=>MWe,isNegative:()=>zWe,isNullable:()=>cYe,isNumber:()=>h_,isObject:()=>Fre,isOneOf:()=>g_,isOptional:()=>lYe,isPartial:()=>_We,isPayload:()=>NWe,isPositive:()=>XWe,isRecord:()=>Fx,isSet:()=>LWe,isString:()=>wE,isTuple:()=>Rx,isUUID4:()=>nYe,isUnknown:()=>p_,isUpperCase:()=>rYe,makeTrait:()=>Nre,makeValidator:()=>Wr,matchesRegExp:()=>Z2,softAssert:()=>qWe});function ti(t){return t===null?"null":t===void 0?"undefined":t===""?"an empty string":typeof t=="symbol"?`<${t.toString()}>`:Array.isArray(t)?"an array":JSON.stringify(t)}function CE(t,e){if(t.length===0)return"nothing";if(t.length===1)return ti(t[0]);let r=t.slice(0,-1),s=t[t.length-1],a=t.length>2?`, ${e} `:` ${e} `;return`${r.map(n=>ti(n)).join(", ")}${a}${ti(s)}`}function s0(t,e){var r,s,a;return typeof e=="number"?`${(r=t?.p)!==null&&r!==void 0?r:"."}[${e}]`:bWe.test(e)?`${(s=t?.p)!==null&&s!==void 0?s:""}.${e}`:`${(a=t?.p)!==null&&a!==void 0?a:"."}[${JSON.stringify(e)}]`}function A_(t,e,r){return t===1?e:r}function mr({errors:t,p:e}={},r){return t?.push(`${e??"."}: ${r}`),!1}function TWe(t,e){return r=>{t[e]=r}}function Wf(t,e){return r=>{let s=t[e];return t[e]=r,Wf(t,e).bind(null,s)}}function X2(t,e,r){let s=()=>(t(r()),a),a=()=>(t(e),s);return s}function p_(){return Wr({test:(t,e)=>!0})}function Rre(t){return Wr({test:(e,r)=>e!==t?mr(r,`Expected ${ti(t)} (got ${ti(e)})`):!0})}function wE(){return Wr({test:(t,e)=>typeof t!="string"?mr(e,`Expected a string (got ${ti(t)})`):!0})}function fo(t){let e=Array.isArray(t)?t:Object.values(t),r=e.every(a=>typeof a=="string"||typeof a=="number"),s=new Set(e);return s.size===1?Rre([...s][0]):Wr({test:(a,n)=>s.has(a)?!0:r?mr(n,`Expected one of ${CE(e,"or")} (got ${ti(a)})`):mr(n,`Expected a valid enumeration value (got ${ti(a)})`)})}function FWe(){return Wr({test:(t,e)=>{var r;if(typeof t!="boolean"){if(typeof e?.coercions<"u"){if(typeof e?.coercion>"u")return mr(e,"Unbound coercion result");let s=RWe.get(t);if(typeof s<"u")return e.coercions.push([(r=e.p)!==null&&r!==void 0?r:".",e.coercion.bind(null,s)]),!0}return mr(e,`Expected a boolean (got ${ti(t)})`)}return!0}})}function h_(){return Wr({test:(t,e)=>{var r;if(typeof t!="number"){if(typeof e?.coercions<"u"){if(typeof e?.coercion>"u")return mr(e,"Unbound coercion result");let s;if(typeof t=="string"){let a;try{a=JSON.parse(t)}catch{}if(typeof a=="number")if(JSON.stringify(a)===t)s=a;else return mr(e,`Received a number that can't be safely represented by the runtime (${t})`)}if(typeof s<"u")return e.coercions.push([(r=e.p)!==null&&r!==void 0?r:".",e.coercion.bind(null,s)]),!0}return mr(e,`Expected a number (got ${ti(t)})`)}return!0}})}function NWe(t){return Wr({test:(e,r)=>{var s;if(typeof r?.coercions>"u")return mr(r,"The isPayload predicate can only be used with coercion enabled");if(typeof r.coercion>"u")return mr(r,"Unbound coercion result");if(typeof e!="string")return mr(r,`Expected a string (got ${ti(e)})`);let a;try{a=JSON.parse(e)}catch{return mr(r,`Expected a JSON string (got ${ti(e)})`)}let n={value:a};return t(a,Object.assign(Object.assign({},r),{coercion:Wf(n,"value")}))?(r.coercions.push([(s=r.p)!==null&&s!==void 0?s:".",r.coercion.bind(null,n.value)]),!0):!1}})}function OWe(){return Wr({test:(t,e)=>{var r;if(!(t instanceof Date)){if(typeof e?.coercions<"u"){if(typeof e?.coercion>"u")return mr(e,"Unbound coercion result");let s;if(typeof t=="string"&&Tre.test(t))s=new Date(t);else{let a;if(typeof t=="string"){let n;try{n=JSON.parse(t)}catch{}typeof n=="number"&&(a=n)}else typeof t=="number"&&(a=t);if(typeof a<"u")if(Number.isSafeInteger(a)||!Number.isSafeInteger(a*1e3))s=new Date(a*1e3);else return mr(e,`Received a timestamp that can't be safely represented by the runtime (${t})`)}if(typeof s<"u")return e.coercions.push([(r=e.p)!==null&&r!==void 0?r:".",e.coercion.bind(null,s)]),!0}return mr(e,`Expected a date (got ${ti(t)})`)}return!0}})}function Tx(t,{delimiter:e}={}){return Wr({test:(r,s)=>{var a;let n=r;if(typeof r=="string"&&typeof e<"u"&&typeof s?.coercions<"u"){iLine truncated
`;for(let s of e)r+=`
- ${s}`}super(r)}};eB={missing:(t,e)=>t.has(e),undefined:(t,e,r)=>t.has(e)&&typeof r[e]<"u",nil:(t,e,r)=>t.has(e)&&r[e]!=null,falsy:(t,e,r)=>t.has(e)&&!!r[e]};(function(t){t.Forbids="Forbids",t.Requires="Requires"})(qf||(qf={}));pYe={[qf.Forbids]:{expect:!1,message:"forbids using"},[qf.Requires]:{expect:!0,message:"requires using"}}});var ot,a0=Xe(()=>{Cp();ot=class{constructor(){this.help=!1}static Usage(e){return e}async catch(e){throw e}async validateAndExecute(){let r=this.constructor.schema;if(Array.isArray(r)){let{isDict:a,isUnknown:n,applyCascade:c}=await Promise.resolve().then(()=>(Ul(),Ea)),f=c(a(n()),r),p=[],h=[];if(!f(this,{errors:p,coercions:h}))throw z2("Invalid option schema",p);for(let[,C]of h)C()}else if(r!=null)throw new Error("Invalid command schema");let s=await this.execute();return typeof s<"u"?s:0}};ot.isOption=K2;ot.Default=[]});function il(t){l_&&console.log(t)}function Mre(){let t={nodes:[]};for(let e=0;e<En.CustomNode;++e)t.nodes.push(_l());return t}function hYe(t){let e=Mre(),r=[],s=e.nodes.length;for(let a of t){r.push(s);for(let n=0;n<a.nodes.length;++n)_re(n)||e.nodes.push(wYe(a.nodes[n],s));s+=a.nodes.length-En.CustomNode+1}for(let a of r)BE(e,En.InitialNode,a);return e}function Ou(t,e){return t.nodes.push(e),t.nodes.length-1}function gYe(t){let e=new Set,r=s=>{if(e.has(s))return;e.add(s);let a=t.nodes[s];for(let c of Object.values(a.statics))for(let{to:f}of c)r(f);for(let[,{to:c}]of a.dynamics)r(c);for(let{to:c}of a.shortcuts)r(c);let n=new Set(a.shortcuts.map(({to:c})=>c));for(;a.shortcuts.length>0;){let{to:c}=a.shortcuts.shift(),f=t.nodes[c];for(let[p,h]of Object.entries(f.statics)){let E=Object.prototype.hasOwnProperty.call(a.statics,p)?a.statics[p]:a.statics[p]=[];for(let C of h)E.some(({to:S})=>C.to===S)||E.push(C)}for(let[p,h]of f.dynamics)a.dynamics.some(([E,{to:C}])=>p===E&&h.to===C)||a.dynamics.push([p,h]);for(let p of f.shortcuts)n.has(p.to)||(a.shortcuts.push(p),n.add(p.to))}};r(En.InitialNode)}function dYe(t,{prefix:e=""}={}){if(l_){il(`${e}Nodes are:`);for(let r=0;r<t.nodes.length;++r)il(`${e} ${r}: ${JSON.stringify(t.nodes[r])}`)}}function mYe(t,e,r=!1){il(`Running a vm on ${JSON.stringify(e)}`);let s=[{node:En.InitialNode,state:{candidateUsage:null,requiredOptions:[],errorMessage:null,ignoreOptions:!1,options:[],path:[],positionals:[],remainder:null,selectedIndex:null,partial:!1,tokens:[]}}];dYe(t,{prefix:" "});let a=[ei.StartOfInput,...e];for(let n=0;n<a.length;++n){let c=a[n],f=c===ei.EndOfInput||c===ei.EndOfPartialInput,p=n-1;il(` Processing ${JSON.stringify(c)}`);let h=[];for(let{node:E,state:C}of s){il(` Current node is ${E}`);let S=t.nodes[E];if(E===En.ErrorNode){h.push({node:E,state:C});continue}console.assert(S.shortcuts.length===0,"Shortcuts should have been eliminated by now");let P=Object.prototype.hasOwnProperty.call(S.statics,c);if(!r||n<a.length-1||P)if(P){let I=S.statics[c];for(let{to:R,reducer:N}of I)h.push({node:R,state:typeof N<"u"?Ox(I_,N,C,c,p):C}),il(` Static transition to ${R} found`)}else il(" No static transition found");else{let I=!1;for(let R of Object.keys(S.statics))if(R.startsWith(c)){if(c===R)for(let{to:N,reducer:U}of S.statics[R])h.push({node:N,state:typeof U<"u"?Ox(I_,U,C,c,p):C}),il(` Static transition to ${N} found`);else for(let{to:N}of S.statics[R])h.push({node:N,state:{...C,remainder:R.slice(c.length)}}),il(` Static transition to ${N} found (partial match)`);I=!0}I||il(" No partial static transition found")}if(!f)for(let[I,{to:R,reducer:N}]of S.dynamics)Ox(BYe,I,C,c,p)&&(h.push({node:R,state:typeof N<"u"?Ox(I_,N,C,c,p):C}),il(` Dynamic transition to ${R} found (via ${I})`))}if(h.length===0&&f&&e.length===1)return[{node:En.InitialNode,state:Lre}];if(h.length===0)throw new IE(e,s.filter(({node:E})=>E!==En.ErrorNode).map(({state:E})=>({usage:E.candidateUsage,reason:null})));if(h.every(({node:E})=>E===En.ErrorNode))throw new IE(e,h.map(({state:E})=>({usage:E.candidateUsage,reason:E.errorMessage})));s=EYe(h)}if(s.length>0){il(" Results:");for(let n of s)il(` - ${n.node} -> ${JSON.stringify(n.state)}`)}else il(" No results");return s}function yYe(t,e,{endToken:r=ei.EndOfInput}={}){let s=mYe(t,[...e,r]);return IYe(e,s.map(({state:a})=>a))}function EYe(t){let e=0;for(let{state:r}of t)r.path.length>e&&(e=r.path.length);return t.filter(({state:r})=>r.path.length===e)}function IYe(t,e){let r=e.filter(S=>S.selectedIndex!==null),s=r.filter(S=>!S.partial);if(s.length>0&&(r=s),r.length===0)throw new Error;let a=r.filter(S=>S.selectedIndex===Nd||S.requiredOptions.every(P=>P.some(I=>S.options.find(R=>R.name===I))));if(a.length===0)throw new IE(t,r.map(S=>({usage:S.candidateUsage,reason:null})));let n=0;for(let S of a)S.path.length>n&&(n=S.path.length);let c=a.filter(S=>S.path.length===n),f=S=>S.positionals.filter(({extra:P})=>!P).length+S.options.length,p=c.map(S=>({state:S,positionalCount:f(S)})),h=0;for(let{positionalCount:S}of p)S>h&&(h=S);let E=p.filter(({positionalCount:S})=>S===h).map(({state:S Line truncated
`),this.context.stdout.write(`
`);let r=0;for(let s of this.commands)this.context.stdout.write(this.cli.usage(this.contexts[s].commandClass,{prefix:`${r++}. `.padStart(5)}));this.context.stdout.write(`
`),this.context.stdout.write(`Run again with -h=<index> to see the longer details of any of those commands.
`)}}}});async function Jre(...t){let{resolvedOptions:e,resolvedCommandClasses:r,resolvedArgv:s,resolvedContext:a}=zre(t);return Ca.from(r,e).runExit(s,a)}async function Kre(...t){let{resolvedOptions:e,resolvedCommandClasses:r,resolvedArgv:s,resolvedContext:a}=zre(t);return Ca.from(r,e).run(s,a)}function zre(t){let e,r,s,a;switch(typeof process<"u"&&typeof process.argv<"u"&&(s=process.argv.slice(2)),t.length){case 1:r=t[0];break;case 2:t[0]&&t[0].prototype instanceof ot||Array.isArray(t[0])?(r=t[0],Array.isArray(t[1])?s=t[1]:a=t[1]):(e=t[0],r=t[1]);break;case 3:Array.isArray(t[2])?(e=t[0],r=t[1],s=t[2]):t[0]&&t[0].prototype instanceof ot||Array.isArray(t[0])?(r=t[0],s=t[1],a=t[2]):(e=t[0],r=t[1],a=t[2]);break;default:e=t[0],r=t[1],s=t[2],a=t[3];break}if(typeof s>"u")throw new Error("The argv parameter must be provided when running Clipanion outside of a Node context");return{resolvedOptions:e,resolvedCommandClasses:r,resolvedArgv:s,resolvedContext:a}}function Vre(t){return t()}var Yre,Ca,Xre=Xe(()=>{Px();Mx();f_();qre();a0();Wre();Yre=Symbol("clipanion/errorCommand");Ca=class t{constructor({binaryLabel:e,binaryName:r="...",binaryVersion:s,enableCapture:a=!1,enableColors:n}={}){this.registrations=new Map,this.builder=new Lx({binaryName:r}),this.binaryLabel=e,this.binaryName=r,this.binaryVersion=s,this.enableCapture=a,this.enableColors=n}static from(e,r={}){let s=new t(r),a=Array.isArray(e)?e:[e];for(let n of a)s.register(n);return s}register(e){var r;let s=new Map,a=new e;for(let p in a){let h=a[p];typeof h=="object"&&h!==null&&h[ot.isOption]&&s.set(p,h)}let n=this.builder.command(),c=n.cliIndex,f=(r=e.paths)!==null&&r!==void 0?r:a.paths;if(typeof f<"u")for(let p of f)n.addPath(p);this.registrations.set(e,{specs:s,builder:n,index:c});for(let[p,{definition:h}]of s.entries())h(n,p);n.setContext({commandClass:e})}process(e,r){let{input:s,context:a,partial:n}=typeof e=="object"&&Array.isArray(e)?{input:e,context:r}:e,{contexts:c,process:f}=this.builder.compile(),p=f(s,{partial:n}),h={...t.defaultContext,...a};switch(p.selectedIndex){case Nd:{let E=_x.from(p,c);return E.context=h,E.tokens=p.tokens,E}default:{let{commandClass:E}=c[p.selectedIndex],C=this.registrations.get(E);if(typeof C>"u")throw new Error("Assertion failed: Expected the command class to have been registered.");let S=new E;S.context=h,S.tokens=p.tokens,S.path=p.path;try{for(let[P,{transformer:I}]of C.specs.entries())S[P]=I(C.builder,P,p,h);return S}catch(P){throw P[Yre]=S,P}}break}}async run(e,r){var s,a;let n,c={...t.defaultContext,...r},f=(s=this.enableColors)!==null&&s!==void 0?s:c.colorDepth>1;if(!Array.isArray(e))n=e;else try{n=this.process(e,c)}catch(E){return c.stdout.write(this.error(E,{colored:f})),1}if(n.help)return c.stdout.write(this.usage(n,{colored:f,detailed:!0})),0;n.context=c,n.cli={binaryLabel:this.binaryLabel,binaryName:this.binaryName,binaryVersion:this.binaryVersion,enableCapture:this.enableCapture,enableColors:this.enableColors,definitions:()=>this.definitions(),definition:E=>this.definition(E),error:(E,C)=>this.error(E,C),format:E=>this.format(E),process:(E,C)=>this.process(E,{...c,...C}),run:(E,C)=>this.run(E,{...c,...C}),usage:(E,C)=>this.usage(E,C)};let p=this.enableCapture&&(a=Gre(c))!==null&&a!==void 0?a:Vre,h;try{h=await p(()=>n.validateAndExecute().catch(E=>n.catch(E).then(()=>0)))}catch(E){return c.stdout.write(this.error(E,{colored:f,command:n})),1}return h}async runExit(e,r){process.exitCode=await this.run(e,r)}definition(e,{colored:r=!1}={}){if(!e.usage)return null;let{usage:s}=this.getUsageByRegistration(e,{detailed:!1}),{usage:a,options:n}=this.getUsageByRegistration(e,{detailed:!0,inlineOptions:!1}),c=typeof e.usage.category<"u"?Ho(e.usage.category,{format:this.format(r),paragraphs:!1}):void 0,f=typeof e.usage.description<"u"?Ho(e.usage.description,{format:this.format(r),paragraphs:!1}):void 0,p=typeof e.usage.details<"u"?Ho(e.usage.details,{format:this.format(r),paragraphs:!0}):void 0,h=typeof e.usage.examples<"u"?e.usage.examples.map(([E,C])=>[Ho(E,{format:this.format(r),paragraphs:!1}),C.replace(/\$0/g,this.binaryName)]):void 0;return{path:s,usage:a,category:c,description:f,details:p,examples:h,options:n}}definitions({colored:e=!1}={}){let r=[];for(let s of this.registrations.keys()){let a=this.definition(s,{colored:e});a&&r.push(a)}return r}usage(e=null,{colored:r,detailed:s=!1,prefix:a="$ "}={}){var n;if(e===null){for(let p of this.registrations.keys()){let h=p.paths,E=typeof p.usage<"u";if(!h||h.length===0||h.length===1&&h[0].length===0||((n=h?.some(P=>P.length===0))!==null&&n!==void 0?n:!1))if(e){e=null;break}else e=p;else if(E){e=null;continue}}e&&(s=!0)}let c=e!==null&&e instanceof ot?e.constructor:e,f="";if(c)if(s){let{description:p="",details:h="",examples:E=[]}=c.usage||{};p!==""&&(f+=Ho(p,{format:this.format(r),paragraphs:!1}).replace(/^./,P=>P.toUpperCase()),f+=`
`),(h!==""||E.length>0)&&(f+=`${this.format(r).header("Usage")}
`,f+=`
`);let{usage:C,options:S}=this.getUsageByRegistration(c,{inlineOptions:!1});if(f+=`${this.format(r).bold(a)}${C}
`,S.length>0){f+=`
`,f+=`${this.format(r).header("Options")}
`;let P=S.reduce((I,R)=>Math.max(I,R.definition.length),0);f+=`
`;for(let{definition:I,description:R}of S)f+=` ${this.format(r).bold(I.padEnd(P))} ${Ho(R,{format:this.format(r),paragraphs:!1})}`}if(h!==""&&(f+=`
`,f+=`${this.format(r).header("Details")}
`,f+=`
`,f+=Ho(h,{format:this.format(r),paragraphs:!0})),E.length>0){f+=`
`,f+=`${this.format(r).header("Examples")}
`;for(let[P,I]of E)f+=`
`,f+=Ho(P,{format:this.format(r),paragraphs:!1}),f+=`${I.replace(/^/m,` ${this.format(r).bold(a)}`).replace(/\$0/g,this.binaryName)}
`}}else{let{usage:p}=this.getUsageByRegistration(c);f+=`${this.format(r).bold(a)}${p}
`}else{let p=new Map;for(let[S,{index:P}]of this.registrations.entries()){if(typeof S.usage>"u")continue;let I=typeof S.usage.category<"u"?Ho(S.usage.category,{format:this.format(r),paragraphs:!1}):null,R=p.get(I);typeof R>"u"&&p.set(I,R=[]);let{usage:N}=this.getUsageByIndex(P);R.push({commandClass:S,usage:N})}let h=Array.from(p.keys()).sort((S,P)=>S===null?-1:P===null?1:S.localeCompare(P,"en",{usage:"sort",caseFirst:"upper"})),E=typeof this.binaryLabel<"u",C=typeof this.binaryVersion<"u";E||C?(E&&C?f+=`${this.format(r).header(`${this.binaryLabel} - ${this.binaryVersion}`)}
`:E?f+=`${this.format(r).header(`${this.binaryLabel}`)}
`:f+=`${this.format(r).header(`${this.binaryVersion}`)}
`,f+=` ${this.format(r).bold(a)}${this.binaryName} <command>
`):f+=`${this.format(r).bold(a)}${this.binaryName} <command>
`;for(let S of h){let P=p.get(S).slice().sort((R,N)=>R.usage.localeCompare(N.usage,"en",{usage:"sort",caseFirst:"upper"})),I=S!==null?S.trim():"General commands";f+=`
`,f+=`${this.format(r).header(`${I}`)}
`;for(let{commandClass:R,usage:N}of P){let U=R.usage.description||"undocumented";f+=`
`,f+=` ${this.format(r).bold(N)}
`,f+=` ${Ho(U,{format:this.format(r),paragraphs:!1})}`}}f+=`
`,f+=Ho("You can also print more details about any of these commands by calling them with the `-h,--help` flag right after the command name.",{format:this.format(r),paragraphs:!0})}return f}error(e,r){var s,{colored:a,command:n=(s=e[Yre])!==null&&s!==void 0?s:null}=r===void 0?{}:r;(!e||typeof e!="object"||!("stack"in e))&&(e=new Error(`Execution failed with a non-error rejection (rejected value: ${JSON.stringify(e)})`));let c="",f=e.name.replace(/([a-z])([A-Z])/g,"$1 $2");f==="Error"&&(f="Internal Error"),c+=`${this.format(a).error(f)}: ${e.message}
`;let p=e.clipanion;return typeof p<"u"?p.type==="usage"&&(c+=`
`,c+=this.usage(n)):e.stack&&(c+=`${e.stack.replace(/^.*\n/,"")}
`),c}format(e){var r;return((r=e??this.enableColors)!==null&&r!==void 0?r:t.defaultContext.colorDepth>1)?kre:Qre}getUsageByRegistration(e,r){let s=this.registrations.get(e);if(typeof s>"u")throw new Error("Assertion failed: Unregistered command");return this.getUsageByIndex(s.index,r)}getUsageByIndex(e,r){return this.builder.getBuilderByIndex(e).usage(r)}};Ca.defaultContext={env:process.env,stdin:process.stdin,stdout:process.stdout,stderr:process.stderr,colorDepth:jre()}});var rB,Zre=Xe(()=>{a0();rB=class extends ot{async execute(){this.context.stdout.write(`${JSON.stringify(this.cli.definitions(),null,2)}
`)}};rB.paths=[["--clipanion=definitions"]]});var nB,$re=Xe(()=>{a0();nB=class extends ot{async execute(){this.context.stdout.write(this.cli.usage())}};nB.paths=[["-h"],["--help"]]});function Hx(t={}){return ya({definition(e,r){var s;e.addProxy({name:(s=t.name)!==null&&s!==void 0?s:r,required:t.required})},transformer(e,r,s){return s.positionals.map(({value:a})=>a)}})}var w_=Xe(()=>{Cp()});var iB,ene=Xe(()=>{a0();w_();iB=class extends ot{constructor(){super(...arguments),this.args=Hx()}async execute(){this.context.stdout.write(`${JSON.stringify(this.cli.process(this.args).tokens,null,2)}
`)}};iB.paths=[["--clipanion=tokens"]]});var sB,tne=Xe(()=>{a0();sB=class extends ot{async execute(){var e;this.context.stdout.write(`${(e=this.cli.binaryVersion)!==null&&e!==void 0?e:"<unknown>"}
`)}};sB.paths=[["-v"],["--version"]]});var B_={};Vt(B_,{DefinitionsCommand:()=>rB,HelpCommand:()=>nB,TokensCommand:()=>iB,VersionCommand:()=>sB});var rne=Xe(()=>{Zre();$re();ene();tne()});function nne(t,e,r){let[s,a]=Gf(e,r??{}),{arity:n=1}=a,c=t.split(","),f=new Set(c);return ya({definition(p){p.addOption({names:c,arity:n,hidden:a?.hidden,description:a?.description,required:a.required})},transformer(p,h,E){let C,S=typeof s<"u"?[...s]:void 0;for(let{name:P,value:I}of E.options)f.has(P)&&(C=P,S=S??[],S.push(I));return typeof S<"u"?Od(C??h,S,a.validator):S}})}var ine=Xe(()=>{Cp()});function sne(t,e,r){let[s,a]=Gf(e,r??{}),n=t.split(","),c=new Set(n);return ya({definition(f){f.addOption({names:n,allowBinding:!1,arity:0,hidden:a.hidden,description:a.description,required:a.required})},transformer(f,p,h){let E=s;for(let{name:C,value:S}of h.options)c.has(C)&&(E=S);return E}})}var one=Xe(()=>{Cp()});function ane(t,e,r){let[s,a]=Gf(e,r??{}),n=t.split(","),c=new Set(n);return ya({definition(f){f.addOption({names:n,allowBinding:!1,arity:0,hidden:a.hidden,description:a.description,required:a.required})},transformer(f,p,h){let E=s;for(let{name:C,value:S}of h.options)c.has(C)&&(E??(E=0),S?E+=1:E=0);return E}})}var lne=Xe(()=>{Cp()});function cne(t={}){return ya({definition(e,r){var s;e.addRest({name:(s=t.name)!==null&&s!==void 0?s:r,required:t.required})},transformer(e,r,s){let a=c=>{let f=s.positionals[c];return f.extra===Hl||f.extra===!1&&c<e.arity.leading.length},n=0;for(;n<s.positionals.length&&a(n);)n+=1;return s.positionals.splice(0,n).map(({value:c})=>c)}})}var une=Xe(()=>{Mx();Cp()});function vYe(t,e,r){let[s,a]=Gf(e,r??{}),{arity:n=1}=a,c=t.split(","),f=new Set(c);return ya({definition(p){p.addOption({names:c,arity:a.tolerateBoolean?0:n,hidden:a.hidden,description:a.description,required:a.required})},transformer(p,h,E,C){let S,P=s;typeof a.env<"u"&&C.env[a.env]&&(S=a.env,P=C.env[a.env]);for(let{name:I,value:R}of E.options)f.has(I)&&(S=I,P=R);return typeof P=="string"?Od(S??h,P,a.validator):P}})}function SYe(t={}){let{required:e=!0}=t;return ya({definition(r,s){var a;r.addPositional({name:(a=t.name)!==null&&a!==void 0?a:s,required:t.required})},transformer(r,s,a){var n;for(let c=0;c<a.positionals.length;++c){if(a.positionals[c].extra===Hl||e&&a.positionals[c].extra===!0||!e&&a.positionals[c].extra===!1)continue;let[f]=a.positionals.splice(c,1);return Od((n=t.name)!==null&&n!==void 0?n:s,f.value,t.validator)}}})}function fne(t,...e){return typeof t=="string"?vYe(t,...e):SYe(t)}var Ane=Xe(()=>{Mx();Cp()});var ge={};Vt(ge,{Array:()=>nne,Boolean:()=>sne,Counter:()=>ane,Proxy:()=>Hx,Rest:()=>cne,String:()=>fne,applyValidator:()=>Od,cleanValidationError:()=>Qx,formatError:()=>z2,isOptionSymbol:()=>K2,makeCommandOption:()=>ya,rerouteArguments:()=>Gf});var pne=Xe(()=>{Cp();w_();ine();one();lne();une();Ane()});var oB={};Vt(oB,{Builtins:()=>B_,Cli:()=>Ca,Command:()=>ot,Option:()=>ge,UsageError:()=>nt,formatMarkdownish:()=>Ho,run:()=>Kre,runExit:()=>Jre});var Yt=Xe(()=>{kx();f_();a0();Xre();rne();pne()});var hne=_((VTt,DYe)=>{DYe.exports={name:"dotenv",version:"16.3.1",description:"Loads environment variables from .env file",main:"lib/main.js",types:"lib/main.d.ts",exports:{".":{types:"./lib/main.d.ts",require:"./lib/main.js",default:"./lib/main.js"},"./config":"./config.js","./config.js":"./config.js","./lib/env-options":"./lib/env-options.js","./lib/env-options.js":"./lib/env-options.js","./lib/cli-options":"./lib/cli-options.js","./lib/cli-options.js":"./lib/cli-options.js","./package.json":"./package.json"},scripts:{"dts-check":"tsc --project tests/types/tsconfig.json",lint:"standard","lint-readme":"standard-markdown",pretest:"npm run lint && npm run dts-check",test:"tap tests/*.js --100 -Rspec",prerelease:"npm test",release:"standard-version"},repository:{type:"git",url:"git://github.com/motdotla/dotenv.git"},funding:"https://github.com/motdotla/dotenv?sponsor=1",keywords:["dotenv","env",".env","environment","variables","config","settings"],readmeFilename:"README.md",license:"BSD-2-Clause",devDependencies:{"@definitelytyped/dtslint":"^0.0.133","@types/node":"^18.11.3",decache:"^4.6.1",sinon:"^14.0.1",standard:"^17.0.0","standard-markdown":"^7.1.0","standard-version":"^9.5.0",tap:"^16.3.0",tar:"^6.1.11",typescript:"^4.8.4"},engines:{node:">=12"},browser:{fs:!1}}});var yne=_((JTt,wp)=>{var gne=Ie("fs"),S_=Ie("path"),bYe=Ie("os"),PYe=Ie("crypto"),xYe=hne(),D_=xYe.version,kYe=/(?:^|^)\s*(?:export\s+)?([\w.-]+)(?:\s*=\s*?|:\s+?)(\s*'(?:\\'|[^'])*'|\s*"(?:\\"|[^"])*"|\s*`(?:\\`|[^`])*`|[^#\r\n]+)?\s*(?:#.*)?(?:$|$)/mg;function QYe(t){let e={},r=t.toString();r=r.replace(/\r\n?/mg,`
`);let s;for(;(s=kYe.exec(r))!=null;){let a=s[1],n=s[2]||"";n=n.trim();let c=n[0];n=n.replace(/^(['"`])([\s\S]*)\1$/mg,"$2"),c==='"'&&(n=n.replace(/\\n/g,`
`),n=n.replace(/\\r/g,"\r")),e[a]=n}return e}function TYe(t){let e=mne(t),r=js.configDotenv({path:e});if(!r.parsed)throw new Error(`MISSING_DATA: Cannot parse ${e} for an unknown reason`);let s=dne(t).split(","),a=s.length,n;for(let c=0;c<a;c++)try{let f=s[c].trim(),p=NYe(r,f);n=js.decrypt(p.ciphertext,p.key);break}catch(f){if(c+1>=a)throw f}return js.parse(n)}function RYe(t){console.log(`[dotenv@${D_}][INFO] ${t}`)}function FYe(t){console.log(`[dotenv@${D_}][WARN] ${t}`)}function v_(t){console.log(`[dotenv@${D_}][DEBUG] ${t}`)}function dne(t){return t&&t.DOTENV_KEY&&t.DOTENV_KEY.length>0?t.DOTENV_KEY:process.env.DOTENV_KEY&&process.env.DOTENV_KEY.length>0?process.env.DOTENV_KEY:""}function NYe(t,e){let r;try{r=new URL(e)}catch(f){throw f.code==="ERR_INVALID_URL"?new Error("INVALID_DOTENV_KEY: Wrong format. Must be in valid uri format like dotenv://:key_1234@dotenv.org/vault/.env.vault?environment=development"):f}let s=r.password;if(!s)throw new Error("INVALID_DOTENV_KEY: Missing key part");let a=r.searchParams.get("environment");if(!a)throw new Error("INVALID_DOTENV_KEY: Missing environment part");let n=`DOTENV_VAULT_${a.toUpperCase()}`,c=t.parsed[n];if(!c)throw new Error(`NOT_FOUND_DOTENV_ENVIRONMENT: Cannot locate environment ${n} in your .env.vault file.`);return{ciphertext:c,key:s}}function mne(t){let e=S_.resolve(process.cwd(),".env");return t&&t.path&&t.path.length>0&&(e=t.path),e.endsWith(".vault")?e:`${e}.vault`}function OYe(t){return t[0]==="~"?S_.join(bYe.homedir(),t.slice(1)):t}function LYe(t){RYe("Loading env from encrypted .env.vault");let e=js._parseVault(t),r=process.env;return t&&t.processEnv!=null&&(r=t.processEnv),js.populate(r,e,t),{parsed:e}}function MYe(t){let e=S_.resolve(process.cwd(),".env"),r="utf8",s=!!(t&&t.debug);t&&(t.path!=null&&(e=OYe(t.path)),t.encoding!=null&&(r=t.encoding));try{let a=js.parse(gne.readFileSync(e,{encoding:r})),n=process.env;return t&&t.processEnv!=null&&(n=t.processEnv),js.populate(n,a,t),{parsed:a}}catch(a){return s&&v_(`Failed to load ${e} ${a.message}`),{error:a}}}function UYe(t){let e=mne(t);return dne(t).length===0?js.configDotenv(t):gne.existsSync(e)?js._configVault(t):(FYe(`You set DOTENV_KEY but you are missing a .env.vault file at ${e}. Did you forget to build it?`),js.configDotenv(t))}function _Ye(t,e){let r=Buffer.from(e.slice(-64),"hex"),s=Buffer.from(t,"base64"),a=s.slice(0,12),n=s.slice(-16);s=s.slice(12,-16);try{let c=PYe.createDecipheriv("aes-256-gcm",r,a);return c.setAuthTag(n),`${c.update(s)}${c.final()}`}catch(c){let f=c instanceof RangeError,p=c.message==="Invalid key length",h=c.message==="Unsupported state or unable to authenticate data";if(f||p){let E="INVALID_DOTENV_KEY: It must be 64 characters long (or more)";throw new Error(E)}else if(h){let E="DECRYPTION_FAILED: Please check your DOTENV_KEY";throw new Error(E)}else throw console.error("Error: ",c.code),console.error("Error: ",c.message),c}}function HYe(t,e,r={}){let s=!!(r&&r.debug),a=!!(r&&r.override);if(typeof e!="object")throw new Error("OBJECT_REQUIRED: Please check the processEnv argument being passed to populate");for(let n of Object.keys(e))Object.prototype.hasOwnProperty.call(t,n)?(a===!0&&(t[n]=e[n]),s&&v_(a===!0?`"${n}" is already defined and WAS overwritten`:`"${n}" is already defined and was NOT overwritten`)):t[n]=e[n]}var js={configDotenv:MYe,_configVault:LYe,_parseVault:TYe,config:UYe,decrypt:_Ye,parse:QYe,populate:HYe};wp.exports.configDotenv=js.configDotenv;wp.exports._configVault=js._configVault;wp.exports._parseVault=js._parseVault;wp.exports.config=js.config;wp.exports.decrypt=js.decrypt;wp.exports.parse=js.parse;wp.exports.populate=js.populate;wp.exports=js});var Ine=_((KTt,Ene)=>{"use strict";Ene.exports=(t,...e)=>new Promise(r=>{r(t(...e))})});var Ld=_((zTt,b_)=>{"use strict";var jYe=Ine(),Cne=t=>{if(t<1)throw new TypeError("Expected `concurrency` to be a number from 1 and up");let e=[],r=0,s=()=>{r--,e.length>0&&e.shift()()},a=(f,p,...h)=>{r++;let E=jYe(f,...h);p(E),E.then(s,s)},n=(f,p,...h)=>{r<t?a(f,p,...h):e.push(a.bind(null,f,p,...h))},c=(f,...p)=>new Promise(h=>n(f,h,...p));return Object.defineProperties(c,{activeCount:{get:()=>r},pendingCount:{get:()=>e.length}}),c};b_.exports=Cne;b_.exports.default=Cne});function Yf(t){return`YN${t.toString(10).padStart(4,"0")}`}function jx(t){let e=Number(t.slice(2));if(typeof Br[e]>"u")throw new Error(`Unknown message name: "${t}"`);return e}var Br,Gx=Xe(()=>{Br=(Me=>(Me[Me.UNNAMED=0]="UNNAMED",Me[Me.EXCEPTION=1]="EXCEPTION",Me[Me.MISSING_PEER_DEPENDENCY=2]="MISSING_PEER_DEPENDENCY",Me[Me.CYCLIC_DEPENDENCIES=3]="CYCLIC_DEPENDENCIES",Me[Me.DISABLED_BUILD_SCRIPTS=4]="DISABLED_BUILD_SCRIPTS",Me[Me.BUILD_DISABLED=5]="BUILD_DISABLED",Me[Me.SOFT_LINK_BUILD=6]="SOFT_LINK_BUILD",Me[Me.MUST_BUILD=7]="MUST_BUILD",Me[Me.MUST_REBUILD=8]="MUST_REBUILD",Me[Me.BUILD_FAILED=9]="BUILD_FAILED",Me[Me.RESOLVER_NOT_FOUND=10]="RESOLVER_NOT_FOUND",Me[Me.FETCHER_NOT_FOUND=11]="FETCHER_NOT_FOUND",Me[Me.LINKER_NOT_FOUND=12]="LINKER_NOT_FO Line truncated
`,"\r","(",")","!","|","&","^"],!0,!1),le=function($){return e.queryPattern.test($)},me=function($){return e.checkFn($)},pe=ke("whitespace"),Be=/^[ \t\n\r]/,Ce=Ne([" "," ",`
`,"\r"],!1,!1),g=0,we=0,ye=[{line:1,column:1}],Ae=0,se=[],Z=0,De;if("startRule"in e){if(!(e.startRule in s))throw new Error(`Can't start parsing from rule "`+e.startRule+'".');a=s[e.startRule]}function Re(){return t.substring(we,g)}function mt(){return Ue(we,g)}function j($,oe){throw oe=oe!==void 0?oe:Ue(we,g),b([ke($)],t.substring(we,g),oe)}function rt($,oe){throw oe=oe!==void 0?oe:Ue(we,g),w($,oe)}function Fe($,oe){return{type:"literal",text:$,ignoreCase:oe}}function Ne($,oe,xe){return{type:"class",parts:$,inverted:oe,ignoreCase:xe}}function Pe(){return{type:"any"}}function Ve(){return{type:"end"}}function ke($){return{type:"other",description:$}}function it($){var oe=ye[$],xe;if(oe)return oe;for(xe=$-1;!ye[xe];)xe--;for(oe=ye[xe],oe={line:oe.line,column:oe.column};xe<$;)t.charCodeAt(xe)===10?(oe.line++,oe.column=1):oe.column++,xe++;return ye[$]=oe,oe}function Ue($,oe){var xe=it($),Te=it(oe);return{start:{offset:$,line:xe.line,column:xe.column},end:{offset:oe,line:Te.line,column:Te.column}}}function x($){g<Ae||(g>Ae&&(Ae=g,se=[]),se.push($))}function w($,oe){return new jd($,null,null,oe)}function b($,oe,xe){return new jd(jd.buildMessage($,oe),$,oe,xe)}function y(){var $,oe,xe,Te,lt,Ct,qt,ir;if($=g,oe=F(),oe!==r){for(xe=[],Te=g,lt=X(),lt!==r?(t.charCodeAt(g)===124?(Ct=n,g++):(Ct=r,Z===0&&x(c)),Ct===r&&(t.charCodeAt(g)===38?(Ct=f,g++):(Ct=r,Z===0&&x(p)),Ct===r&&(t.charCodeAt(g)===94?(Ct=h,g++):(Ct=r,Z===0&&x(E)))),Ct!==r?(qt=X(),qt!==r?(ir=F(),ir!==r?(lt=[lt,Ct,qt,ir],Te=lt):(g=Te,Te=r)):(g=Te,Te=r)):(g=Te,Te=r)):(g=Te,Te=r);Te!==r;)xe.push(Te),Te=g,lt=X(),lt!==r?(t.charCodeAt(g)===124?(Ct=n,g++):(Ct=r,Z===0&&x(c)),Ct===r&&(t.charCodeAt(g)===38?(Ct=f,g++):(Ct=r,Z===0&&x(p)),Ct===r&&(t.charCodeAt(g)===94?(Ct=h,g++):(Ct=r,Z===0&&x(E)))),Ct!==r?(qt=X(),qt!==r?(ir=F(),ir!==r?(lt=[lt,Ct,qt,ir],Te=lt):(g=Te,Te=r)):(g=Te,Te=r)):(g=Te,Te=r)):(g=Te,Te=r);xe!==r?(we=$,oe=C(oe,xe),$=oe):(g=$,$=r)}else g=$,$=r;return $}function F(){var $,oe,xe,Te,lt,Ct;return $=g,t.charCodeAt(g)===33?(oe=S,g++):(oe=r,Z===0&&x(P)),oe!==r?(xe=F(),xe!==r?(we=$,oe=I(xe),$=oe):(g=$,$=r)):(g=$,$=r),$===r&&($=g,t.charCodeAt(g)===40?(oe=R,g++):(oe=r,Z===0&&x(N)),oe!==r?(xe=X(),xe!==r?(Te=y(),Te!==r?(lt=X(),lt!==r?(t.charCodeAt(g)===41?(Ct=U,g++):(Ct=r,Z===0&&x(W)),Ct!==r?(we=$,oe=ee(Te),$=oe):(g=$,$=r)):(g=$,$=r)):(g=$,$=r)):(g=$,$=r)):(g=$,$=r),$===r&&($=z())),$}function z(){var $,oe,xe,Te,lt;if($=g,oe=X(),oe!==r){if(xe=g,Te=[],ie.test(t.charAt(g))?(lt=t.charAt(g),g++):(lt=r,Z===0&&x(ue)),lt!==r)for(;lt!==r;)Te.push(lt),ie.test(t.charAt(g))?(lt=t.charAt(g),g++):(lt=r,Z===0&&x(ue));else Te=r;Te!==r?xe=t.substring(xe,g):xe=Te,xe!==r?(we=g,Te=le(xe),Te?Te=void 0:Te=r,Te!==r?(we=$,oe=me(xe),$=oe):(g=$,$=r)):(g=$,$=r)}else g=$,$=r;return $}function X(){var $,oe;for(Z++,$=[],Be.test(t.charAt(g))?(oe=t.charAt(g),g++):(oe=r,Z===0&&x(Ce));oe!==r;)$.push(oe),Be.test(t.charAt(g))?(oe=t.charAt(g),g++):(oe=r,Z===0&&x(Ce));return Z--,$===r&&(oe=r,Z===0&&x(pe)),$}if(De=a(),De!==r&&g===t.length)return De;throw De!==r&&g<t.length&&x(Ve()),b(se,Ae<t.length?t.charAt(Ae):null,Ae<t.length?Ue(Ae,Ae+1):Ue(Ae,Ae))}yse.exports={SyntaxError:jd,parse:HJe}});var Ise=_(rk=>{var{parse:jJe}=Ese();rk.makeParser=(t=/[a-z]+/)=>(e,r)=>jJe(e,{queryPattern:t,checkFn:r});rk.parse=rk.makeParser()});var wse=_((YRt,Cse)=>{"use strict";Cse.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightLine truncated
`:`
`)+r,a=s+1,s=t.indexOf(`
`,a)}while(s!==-1);return n+=t.substr(a),n};Use.exports={stringReplaceAll:tKe,stringEncaseCRLFWithFirstIndex:rKe}});var Wse=_((eFt,qse)=>{"use strict";var nKe=/(?:\\(u(?:[a-f\d]{4}|\{[a-f\d]{1,6}\})|x[a-f\d]{2}|.))|(?:\{(~)?(\w+(?:\([^)]*\))?(?:\.\w+(?:\([^)]*\))?)*)(?:[ \t]|(?=\r?\n)))|(\})|((?:.|[\r\n\f])+?)/gi,Hse=/(?:^|\.)(\w+)(?:\(([^)]*)\))?/g,iKe=/^(['"])((?:\\.|(?!\1)[^\\])*)\1$/,sKe=/\\(u(?:[a-f\d]{4}|{[a-f\d]{1,6}})|x[a-f\d]{2}|.)|([^\\])/gi,oKe=new Map([["n",`
`],["r","\r"],["t"," "],["b","\b"],["f","\f"],["v","\v"],["0","\0"],["\\","\\"],["e","\x1B"],["a","\x07"]]);function Gse(t){let e=t[0]==="u",r=t[1]==="{";return e&&!r&&t.length===5||t[0]==="x"&&t.length===3?String.fromCharCode(parseInt(t.slice(1),16)):e&&r?String.fromCodePoint(parseInt(t.slice(2,-1),16)):oKe.get(t)||t}function aKe(t,e){let r=[],s=e.trim().split(/\s*,\s*/g),a;for(let n of s){let c=Number(n);if(!Number.isNaN(c))r.push(c);else if(a=n.match(iKe))r.push(a[2].replace(sKe,(f,p,h)=>p?Gse(p):h));else throw new Error(`Invalid Chalk template style argument: ${n} (in style '${t}')`)}return r}function lKe(t){Hse.lastIndex=0;let e=[],r;for(;(r=Hse.exec(t))!==null;){let s=r[1];if(r[2]){let a=aKe(s,r[2]);e.push([s].concat(a))}else e.push([s])}return e}function jse(t,e){let r={};for(let a of e)for(let n of a.styles)r[n[0]]=a.inverse?null:n.slice(1);let s=t;for(let[a,n]of Object.entries(r))if(Array.isArray(n)){if(!(a in s))throw new Error(`Unknown Chalk style: ${a}`);s=n.length>0?s[a](...n):s[a]}return s}qse.exports=(t,e)=>{let r=[],s=[],a=[];if(e.replace(nKe,(n,c,f,p,h,E)=>{if(c)a.push(Gse(c));else if(p){let C=a.join("");a=[],s.push(r.length===0?C:jse(t,r)(C)),r.push({inverse:f,styles:lKe(p)})}else if(h){if(r.length===0)throw new Error("Found extraneous } in Chalk template literal");s.push(jse(t,r)(a.join(""))),a=[],r.pop()}else a.push(E)}),s.push(a.join("")),r.length>0){let n=`Chalk template literal is missing ${r.length} closing bracket${r.length===1?"":"s"} (\`}\`)`;throw new Error(n)}return s.join("")}});var TE=_((tFt,Xse)=>{"use strict";var mB=sk(),{stdout:t4,stderr:r4}=Mse(),{stringReplaceAll:cKe,stringEncaseCRLFWithFirstIndex:uKe}=_se(),{isArray:ok}=Array,Vse=["ansi","ansi","ansi256","ansi16m"],QE=Object.create(null),fKe=(t,e={})=>{if(e.level&&!(Number.isInteger(e.level)&&e.level>=0&&e.level<=3))throw new Error("The `level` option should be an integer from 0 to 3");let r=t4?t4.level:0;t.level=e.level===void 0?r:e.level},n4=class{constructor(e){return Jse(e)}},Jse=t=>{let e={};return fKe(e,t),e.template=(...r)=>zse(e.template,...r),Object.setPrototypeOf(e,ak.prototype),Object.setPrototypeOf(e.template,e),e.template.constructor=()=>{throw new Error("`chalk.constructor()` is deprecated. Use `new chalk.Instance()` instead.")},e.template.Instance=n4,e.template};function ak(t){return Jse(t)}for(let[t,e]of Object.entries(mB))QE[t]={get(){let r=lk(this,i4(e.open,e.close,this._styler),this._isEmpty);return Object.defineProperty(this,t,{value:r}),r}};QE.visible={get(){let t=lk(this,this._styler,!0);return Object.defineProperty(this,"visible",{value:t}),t}};var Kse=["rgb","hex","keyword","hsl","hsv","hwb","ansi","ansi256"];for(let t of Kse)QE[t]={get(){let{level:e}=this;return function(...r){let s=i4(mB.color[Vse[e]][t](...r),mB.color.close,this._styler);return lk(this,s,this._isEmpty)}}};for(let t of Kse){let e="bg"+t[0].toUpperCase()+t.slice(1);QE[e]={get(){let{level:r}=this;return function(...s){let a=i4(mB.bgColor[Vse[r]][t](...s),mB.bgColor.close,this._styler);return lk(this,a,this._isEmpty)}}}}var AKe=Object.defineProperties(()=>{},{...QE,level:{enumerable:!0,get(){return this._generator.level},set(t){this._generator.level=t}}}),i4=(t,e,r)=>{let s,a;return r===void 0?(s=t,a=e):(s=r.openAll+t,a=e+r.closeAll),{open:t,close:e,openAll:s,closeAll:a,parent:r}},lk=(t,e,r)=>{let s=(...a)=>ok(a[0])&&ok(a[0].raw)?Yse(s,zse(s,...a)):Yse(s,a.length===1?""+a[0]:a.join(" "));return Object.setPrototypeOf(s,AKe),s._generator=t,s._styler=e,s._isEmpty=r,s},Yse=(t,e)=>{if(t.level<=0||!e)return t._isEmpty?"":e;let r=t._styler;if(r===void 0)return e;let{openAll:s,closeAll:a}=r;if(e.indexOf("\x1B")!==-1)for(;r!==void 0;)e=cKe(e,r.close,r.open),r=r.parent;let n=e.indexOf(`
`);return n!==-1&&(e=uKe(e,a,s,n)),s+e+a},e4,zse=(t,...e)=>{let[r]=e;if(!ok(r)||!ok(r.raw))return e.join(" ");let s=e.slice(1),a=[r.raw[0]];for(let n=1;n<r.length;n++)a.push(String(s[n-1]).replace(/[{}\\]/g,"\\$&"),String(r.raw[n]));return e4===void 0&&(e4=Wse()),e4(t,a.join(""))};Object.defineProperties(ak.prototype,QE);var ck=ak();ck.supportsColor=t4;ck.stderr=ak({level:r4?r4.level:0});ck.stderr.supportsColor=r4;Xse.exports=ck});var uk=_(Dc=>{"use strict";Dc.isInteger=t=>typeof t=="number"?Number.isInteger(t):typeof t=="string"&&t.trim()!==""?Number.isInteger(Number(t)):!1;Dc.find=(t,e)=>t.nodes.find(r=>r.type===e);Dc.exceedsLimit=(t,e,r=1,s)=>s===!1||!Dc.isInteger(t)||!Dc.isInteger(e)?!1:(Number(e)-Number(t))/Number(r)>=s;Dc.escapeNode=(t,e=0,r)=>{let s=t.nodes[e];s&&(r&&s.type===r||s.type==="open"||s.type==="close")&&s.escaped!==!0&&(s.value="\\"+s.value,s.escaped=!0)};Dc.encloseBrace=t=>t.type!=="brace"||t.commas>>0+t.ranges>>0?!1:(t.invalid=!0,!0);Dc.isInvalidBrace=t=>t.type!=="brace"?!1:t.invalid===!0||t.dollar?!0:!(t.commas>>0+t.ranges>>0)||t.open!==!0||t.close!==!0?(t.invalid=!0,!0):!1;Dc.isOpenOrClose=t=>t.type==="open"||t.type==="close"?!0:t.open===!0||t.close===!0;Dc.reduce=t=>t.reduce((e,r)=>(r.type==="text"&&e.push(r.value),r.type==="range"&&(r.type="text"),e),[]);Dc.flatten=(...t)=>{let e=[],r=s=>{for(let a=0;a<s.length;a++){let n=s[a];Array.isArray(n)?r(n,e):n!==void 0&&e.push(n)}return e};return r(t),e}});var fk=_((nFt,$se)=>{"use strict";var Zse=uk();$se.exports=(t,e={})=>{let r=(s,a={})=>{let n=e.escapeInvalid&&Zse.isInvalidBrace(a),c=s.invalid===!0&&e.escapeInvalid===!0,f="";if(s.value)return(n||c)&&Zse.isOpenOrClose(s)?"\\"+s.value:s.value;if(s.value)return s.value;if(s.nodes)for(let p of s.nodes)f+=r(p);return f};return r(t)}});var toe=_((iFt,eoe)=>{"use strict";eoe.exports=function(t){return typeof t=="number"?t-t===0:typeof t=="string"&&t.trim()!==""?Number.isFinite?Number.isFinite(+t):isFinite(+t):!1}});var uoe=_((sFt,coe)=>{"use strict";var roe=toe(),Gd=(t,e,r)=>{if(roe(t)===!1)throw new TypeError("toRegexRange: expected the first argument to be a number");if(e===void 0||t===e)return String(t);if(roe(e)===!1)throw new TypeError("toRegexRange: expected the second argument to be a number.");let s={relaxZeros:!0,...r};typeof s.strictZeros=="boolean"&&(s.relaxZeros=s.strictZeros===!1);let a=String(s.relaxZeros),n=String(s.shorthand),c=String(s.capture),f=String(s.wrap),p=t+":"+e+"="+a+n+c+f;if(Gd.cache.hasOwnProperty(p))return Gd.cache[p].result;let h=Math.min(t,e),E=Math.max(t,e);if(Math.abs(h-E)===1){let R=t+"|"+e;return s.capture?`(${R})`:s.wrap===!1?R:`(?:${R})`}let C=loe(t)||loe(e),S={min:t,max:e,a:h,b:E},P=[],I=[];if(C&&(S.isPadded=C,S.maxLen=String(S.max).length),h<0){let R=E<0?Math.abs(E):1;I=noe(R,Math.abs(h),S,s),h=S.a=0}return E>=0&&(P=noe(h,E,S,s)),S.negatives=I,S.positives=P,S.result=pKe(I,P,s),s.capture===!0?S.result=`(${S.result})`:s.wrap!==!1&&P.length+I.length>1&&(S.result=`(?:${S.result})`),Gd.cache[p]=S,S.result};function pKe(t,e,r){let s=s4(t,e,"-",!1,r)||[],a=s4(e,t,"",!1,r)||[],n=s4(t,e,"-?",!0,r)||[];return s.concat(n).concat(a).join("|")}function hKe(t,e){let r=1,s=1,a=soe(t,r),n=new Set([e]);for(;t<=a&&a<=e;)n.add(a),r+=1,a=soe(t,r);for(a=ooe(e+1,s)-1;t<a&&a<=e;)n.add(a),s+=1,a=ooe(e+1,s)-1;return n=[...n],n.sort(mKe),n}function gKe(t,e,r){if(t===e)return{pattern:t,count:[],digits:0};let s=dKe(t,e),a=s.length,n="",c=0;for(let f=0;f<a;f++){let[p,h]=s[f];p===h?n+=p:p!=="0"||h!=="9"?n+=yKe(p,h,r):c++}return c&&(n+=r.shorthand===!0?"\\d":"[0-9]"),{pattern:n,count:[c],digits:a}}function noe(t,e,r,s){let a=hKe(t,e),n=[],c=t,f;for(let p=0;p<a.length;p++){let h=a[p],E=gKe(String(c),String(h),s),C="";if(!r.isPadded&&f&&f.pattern===E.pattern){f.count.length>1&&f.count.pop(),f.count.push(E.count[0]),f.string=f.pattern+aoe(f.count),c=h+1;continue}r.isPadded&&(C=EKe(h,r,s)),E.string=C+E.pattern+aoe(E.count),n.push(E),c=h+1,f=E}return n}function s4(t,e,r,s,a){let n=[];for(let c of t){let{string:f}=c;!s&&!ioe(e,"string",f)&&n.push(r+f),s&&ioe(e,"string",f)&&n.push(r+f)}return n}function dKe(t,e){let r=[];for(let s=0;s<t.length;s++)r.push([t[s],e[s]]);return r}function mKe(t,e){return t>e?1:e>t?-1:0}function ioe(t,e,r){return t.some(s=>s[e]===r)}function soe(t,e){return Number(String(t).slice(0,-e)+"9".repeat(e))}function ooe(t,e){return t-t%Math.pow(10,e)}function aoe(t){let[e=0,r=""]=t;return r||e>1?`{${e+(r?","+r:"")}}`:""}function yKe(t,e,r){return`[${t}${e-t===1?"":"-"}${e}]`}function loe(t){return/^-?(0+)\d/.test(t)}function EKe(t,e,r){if(!e.isPadded)return t;let s=Math.abs(e.maxLen-String(t).length),a=r.relaxZeros!==!1;switch(s){case 0:return"";case 1:return a?"0?":"0";case 2:return a?"0{0,2}":"00";default:return a?`0{0,${s}}`:`0{${s}}`}}Gd.cache={};Gd.clearCache=()=>Gd.cache={};coe.exports=Gd});var l4=_((oFt,yoe)=>{"use strict";var IKe=Ie("util"),poe=uoe(),foe=t=>t!==null&&typeof t=="object"&&!Array.isArray(t),CKe=t=>e=>t===!0?Number(e):String(e),o4=t=>typeof t=="numb Line truncated
`,CHAR_NO_BREAK_SPACE:"\xA0",CHAR_PERCENT:"%",CHAR_PLUS:"+",CHAR_QUESTION_MARK:"?",CHAR_RIGHT_ANGLE_BRACKET:">",CHAR_RIGHT_CURLY_BRACE:"}",CHAR_RIGHT_SQUARE_BRACKET:"]",CHAR_SEMICOLON:";",CHAR_SINGLE_QUOTE:"'",CHAR_SPACE:" ",CHAR_TAB:" ",CHAR_UNDERSCORE:"_",CHAR_VERTICAL_LINE:"|",CHAR_ZERO_WIDTH_NOBREAK_SPACE:"\uFEFF"}});var Qoe=_((uFt,koe)=>{"use strict";var TKe=fk(),{MAX_LENGTH:boe,CHAR_BACKSLASH:c4,CHAR_BACKTICK:RKe,CHAR_COMMA:FKe,CHAR_DOT:NKe,CHAR_LEFT_PARENTHESES:OKe,CHAR_RIGHT_PARENTHESES:LKe,CHAR_LEFT_CURLY_BRACE:MKe,CHAR_RIGHT_CURLY_BRACE:UKe,CHAR_LEFT_SQUARE_BRACKET:Poe,CHAR_RIGHT_SQUARE_BRACKET:xoe,CHAR_DOUBLE_QUOTE:_Ke,CHAR_SINGLE_QUOTE:HKe,CHAR_NO_BREAK_SPACE:jKe,CHAR_ZERO_WIDTH_NOBREAK_SPACE:GKe}=Doe(),qKe=(t,e={})=>{if(typeof t!="string")throw new TypeError("Expected a string");let r=e||{},s=typeof r.maxLength=="number"?Math.min(boe,r.maxLength):boe;if(t.length>s)throw new SyntaxError(`Input length (${t.length}), exceeds max characters (${s})`);let a={type:"root",input:t,nodes:[]},n=[a],c=a,f=a,p=0,h=t.length,E=0,C=0,S,P={},I=()=>t[E++],R=N=>{if(N.type==="text"&&f.type==="dot"&&(f.type="text"),f&&f.type==="text"&&N.type==="text"){f.value+=N.value;return}return c.nodes.push(N),N.parent=c,N.prev=f,f=N,N};for(R({type:"bos"});E<h;)if(c=n[n.length-1],S=I(),!(S===GKe||S===jKe)){if(S===c4){R({type:"text",value:(e.keepEscaping?S:"")+I()});continue}if(S===xoe){R({type:"text",value:"\\"+S});continue}if(S===Poe){p++;let N=!0,U;for(;E<h&&(U=I());){if(S+=U,U===Poe){p++;continue}if(U===c4){S+=I();continue}if(U===xoe&&(p--,p===0))break}R({type:"text",value:S});continue}if(S===OKe){c=R({type:"paren",nodes:[]}),n.push(c),R({type:"text",value:S});continue}if(S===LKe){if(c.type!=="paren"){R({type:"text",value:S});continue}c=n.pop(),R({type:"text",value:S}),c=n[n.length-1];continue}if(S===_Ke||S===HKe||S===RKe){let N=S,U;for(e.keepQuotes!==!0&&(S="");E<h&&(U=I());){if(U===c4){S+=U+I();continue}if(U===N){e.keepQuotes===!0&&(S+=U);break}S+=U}R({type:"text",value:S});continue}if(S===MKe){C++;let U={type:"brace",open:!0,close:!1,dollar:f.value&&f.value.slice(-1)==="$"||c.dollar===!0,depth:C,commas:0,ranges:0,nodes:[]};c=R(U),n.push(c),R({type:"open",value:S});continue}if(S===UKe){if(c.type!=="brace"){R({type:"text",value:S});continue}let N="close";c=n.pop(),c.close=!0,R({type:N,value:S}),C--,c=n[n.length-1];continue}if(S===FKe&&C>0){if(c.ranges>0){c.ranges=0;let N=c.nodes.shift();c.nodes=[N,{type:"text",value:TKe(c)}]}R({type:"comma",value:S}),c.commas++;continue}if(S===NKe&&C>0&&c.commas===0){let N=c.nodes;if(C===0||N.length===0){R({type:"text",value:S});continue}if(f.type==="dot"){if(c.range=[],f.value+=S,f.type="range",c.nodes.length!==3&&c.nodes.length!==5){c.invalid=!0,c.ranges=0,f.type="text";continue}c.ranges++,c.args=[];continue}if(f.type==="range"){N.pop();let U=N[N.length-1];U.value+=f.value+S,f=U,c.ranges--;continue}R({type:"dot",value:S});continue}R({type:"text",value:S})}do if(c=n.pop(),c.type!=="root"){c.nodes.forEach(W=>{W.nodes||(W.type==="open"&&(W.isOpen=!0),W.type==="close"&&(W.isClose=!0),W.nodes||(W.type="text"),W.invalid=!0)});let N=n[n.length-1],U=N.nodes.indexOf(c);N.nodes.splice(U,1,...c.nodes)}while(n.length>0);return R({type:"eos"}),a};koe.exports=qKe});var Foe=_((fFt,Roe)=>{"use strict";var Toe=fk(),WKe=Coe(),YKe=voe(),VKe=Qoe(),jl=(t,e={})=>{let r=[];if(Array.isArray(t))for(let s of t){let a=jl.create(s,e);Array.isArray(a)?r.push(...a):r.push(a)}else r=[].concat(jl.create(t,e));return e&&e.expand===!0&&e.nodupes===!0&&(r=[...new Set(r)]),r};jl.parse=(t,e={})=>VKe(t,e);jl.stringify=(t,e={})=>Toe(typeof t=="string"?jl.parse(t,e):t,e);jl.compile=(t,e={})=>(typeof t=="string"&&(t=jl.parse(t,e)),WKe(t,e));jl.expand=(t,e={})=>{typeof t=="string"&&(t=jl.parse(t,e));let r=YKe(t,e);return e.noempty===!0&&(r=r.filter(Boolean)),e.nodupes===!0&&(r=[...new Set(r)]),r};jl.create=(t,e={})=>t===""||t.length<3?[t]:e.expand!==!0?jl.compile(t,e):jl.expand(t,e);Roe.exports=jl});var EB=_((AFt,Uoe)=>{"use strict";var JKe=Ie("path"),Vf="\\\\/",Noe=`[^${Vf}]`,Dp="\\.",KKe="\\+",zKe="\\?",pk="\\/",XKe="(?=.)",Ooe="[^/]",u4=`(?:${pk}|$)`,Loe=`(?:^|${pk})`,f4=`${Dp}{1,2}${u4}`,ZKe=`(?!${Dp})`,$Ke=`(?!${Loe}${f4})`,eze=`(?!${Dp}{0,1}${u4})`,tze=`(?!${f4})`,rze=`[^.${pk}]`,nze=`${Ooe}*?`,Moe={DOT_LITERAL:Dp,PLUS_LITERAL:KKe,QMARK_LITERAL:zKe,SLASH_LITERAL:pk,ONE_CHAR:XKe,QMARK:Ooe,END_ANCHOR:u4,DOTS_SLASH:f4,NO_DOT:ZKe,NO_DOTS:$Ke,NO_DOT_SLASH:eze,NO_DOTS_SLASH:tze,QMARK_NO_DOT:rze,STAR:nze,START_ANCHOR:Loe},ize={...Moe,SLASH_LITERAL:`[${Vf}]`,QMARK:Noe,STAR:`${Noe}*?`,DOTS_SLASH:`${Dp}{1,2}(?:[${Vf}]|$)`,NO_DOT:`(?!${Dp})`,NO_DOTS:`(?!(?:^|[${Vf}])${Dp}{1,2}(?:[${Vf}]|$))`,NO_DOT_SLASH:`(?!${Dp}{0,1}(?:[${Vf}]|$))`,NO_DOTS_SLASH:`(?!${Dp}{1,2}(?:[${Vf}]|$))`,QMARK_NO_DOT:`[^.${Vf}]`,START_ANCHOR:`(?:^|[${Vf}])`,END_ANCHOR:`(?:[${Vf}]|$)`},sze={alnum:"a-zA-Z0-9",alpha:"a-zA-Z",ascii:"\\x00-\\x7F",blank:" \\t",cntrl:"\\x00-\\x1F\\x7F",digit:"0-9",graph:"\\x21-\\x7E",lower:"a-z",print:"\\x20-\\x7E ",punct:"\\-!\"#$%&' Line truncated
`),f!==-1){let p=a+c.substring(0,f);c=c.substring(f+1),a="",e!==null?this.reportInfo(null,`${e} ${p}`):this.reportInfo(null,p)}while(f!==-1);a+=c}),r.on("end",()=>{let n=s.end();n!==""&&(e!==null?this.reportInfo(null,`${e} ${n}`):this.reportInfo(null,n))}),r}}});var aI,R8=Xe(()=>{Tc();Wo();aI=class{constructor(e){this.fetchers=e}supports(e,r){return!!this.tryFetcher(e,r)}getLocalPath(e,r){return this.getFetcher(e,r).getLocalPath(e,r)}async fetch(e,r){return await this.getFetcher(e,r).fetch(e,r)}tryFetcher(e,r){let s=this.fetchers.find(a=>a.supports(e,r));return s||null}getFetcher(e,r){let s=this.fetchers.find(a=>a.supports(e,r));if(!s)throw new jt(11,`${Yr(r.project.configuration,e)} isn't supported by any available fetcher`);return s}}});var rm,F8=Xe(()=>{Wo();rm=class{constructor(e){this.resolvers=e.filter(r=>r)}supportsDescriptor(e,r){return!!this.tryResolverByDescriptor(e,r)}supportsLocator(e,r){return!!this.tryResolverByLocator(e,r)}shouldPersistResolution(e,r){return this.getResolverByLocator(e,r).shouldPersistResolution(e,r)}bindDescriptor(e,r,s){return this.getResolverByDescriptor(e,s).bindDescriptor(e,r,s)}getResolutionDependencies(e,r){return this.getResolverByDescriptor(e,r).getResolutionDependencies(e,r)}async getCandidates(e,r,s){return await this.getResolverByDescriptor(e,s).getCandidates(e,r,s)}async getSatisfying(e,r,s,a){return this.getResolverByDescriptor(e,a).getSatisfying(e,r,s,a)}async resolve(e,r){return await this.getResolverByLocator(e,r).resolve(e,r)}tryResolverByDescriptor(e,r){let s=this.resolvers.find(a=>a.supportsDescriptor(e,r));return s||null}getResolverByDescriptor(e,r){let s=this.resolvers.find(a=>a.supportsDescriptor(e,r));if(!s)throw new Error(`${ni(r.project.configuration,e)} isn't supported by any available resolver`);return s}tryResolverByLocator(e,r){let s=this.resolvers.find(a=>a.supportsLocator(e,r));return s||null}getResolverByLocator(e,r){let s=this.resolvers.find(a=>a.supportsLocator(e,r));if(!s)throw new Error(`${Yr(r.project.configuration,e)} isn't supported by any available resolver`);return s}}});var lI,N8=Xe(()=>{Dt();Wo();lI=class{supports(e){return!!e.reference.startsWith("virtual:")}getLocalPath(e,r){let s=e.reference.indexOf("#");if(s===-1)throw new Error("Invalid virtual package reference");let a=e.reference.slice(s+1),n=Ws(e,a);return r.fetcher.getLocalPath(n,r)}async fetch(e,r){let s=e.reference.indexOf("#");if(s===-1)throw new Error("Invalid virtual package reference");let a=e.reference.slice(s+1),n=Ws(e,a),c=await r.fetcher.fetch(n,r);return await this.ensureVirtualLink(e,c,r)}getLocatorFilename(e){return nI(e)}async ensureVirtualLink(e,r,s){let a=r.packageFs.getRealPath(),n=s.project.configuration.get("virtualFolder"),c=this.getLocatorFilename(e),f=uo.makeVirtualPath(n,c,a),p=new _f(f,{baseFs:r.packageFs,pathUtils:J});return{...r,packageFs:p}}}});var FQ,gue=Xe(()=>{FQ=class t{static{this.protocol="virtual:"}static isVirtualDescriptor(e){return!!e.range.startsWith(t.protocol)}static isVirtualLocator(e){return!!e.reference.startsWith(t.protocol)}supportsDescriptor(e,r){return t.isVirtualDescriptor(e)}supportsLocator(e,r){return t.isVirtualLocator(e)}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,s){throw new Error('Assertion failed: calling "bindDescriptor" on a virtual descriptor is unsupported')}getResolutionDependencies(e,r){throw new Error('Assertion failed: calling "getResolutionDependencies" on a virtual descriptor is unsupported')}async getCandidates(e,r,s){throw new Error('Assertion failed: calling "getCandidates" on a virtual descriptor is unsupported')}async getSatisfying(e,r,s,a){throw new Error('Assertion failed: calling "getSatisfying" on a virtual descriptor is unsupported')}async resolve(e,r){throw new Error('Assertion failed: calling "resolve" on a virtual locator is unsupported')}}});var cI,O8=Xe(()=>{Dt();tm();cI=class{supports(e){return!!e.reference.startsWith(Ei.protocol)}getLocalPath(e,r){return this.getWorkspace(e,r).cwd}async fetch(e,r){let s=this.getWorkspace(e,r).cwd;return{packageFs:new Sn(s),prefixPath:vt.dot,localPath:s}}getWorkspace(e,r){return r.project.getWorkspaceByCwd(e.reference.slice(Ei.protocol.length))}}});function WB(t){return typeof t=="object"&&t!==null&&!Array.isArray(t)}function due(t){return typeof t>"u"?3:WB(t)?0:Array.isArray(t)?1:2}function U8(t,e){return Object.hasOwn(t,e)}function het(t){return WB(t)&&U8(t,"onConflict")&&typeof t.onConflict=="string"}function get(t){if(typeof t>"u")return{onConflict:"default",value:t};if(!het(t))return{onConflict:"default",value:t};if(U8(t,"value"))return t;let{onConflict:e,...r}=t;return{onConflict:e,value:r}}function mue(t,e){let r=WB(t)&&U8(t,e)?t[e]:void 0;return get(r)}function uI(t,e){return[t,e,yue]}function _8(t){return Array.isArray(t)?t[2]===yue:!1}function L8(t,e){if(WB(t)){let r={};for(let s of Object.keys(t))r[s]=L8(t[s],e);return uI(e,r)}return Array.isArray(t)?uI(e,t.map(r=>L8(r,e))):uI(e,t)}function M8(t,e,r,s,a){let n,c=[],f=a,p=0;for(let E=a-Line truncated
Please report this to https://github.com/szmarczak/http2-wrapper/`);I(R)}return}s[0].resolve(P);return}}if(c in this.queue){if(f in this.queue[c]){this.queue[c][f].listeners.push(...s),this._tryToCreateNewSession(c,f);return}}else this.queue[c]={};let p=()=>{c in this.queue&&this.queue[c][f]===h&&(delete this.queue[c][f],Object.keys(this.queue[c]).length===0&&delete this.queue[c])},h=()=>{let E=`${f}:${c}`,C=!1;try{let S=Rtt.connect(e,{createConnection:this.createConnection,settings:this.settings,session:this.tlsSessionCache.get(E),...r});S[Pa]=0,S[gI]=!1;let P=()=>S[Pa]<S.remoteSettings.maxConcurrentStreams,I=!0;S.socket.once("session",N=>{this.tlsSessionCache.set(E,N)}),S.once("error",N=>{for(let{reject:U}of s)U(N);this.tlsSessionCache.delete(E)}),S.setTimeout(this.timeout,()=>{S.destroy()}),S.once("close",()=>{if(C){I&&this._freeSessionsCount--,this._sessionsCount--;let N=this.sessions[c];N.splice(N.indexOf(S),1),N.length===0&&delete this.sessions[c]}else{let N=new Error("Session closed without receiving a SETTINGS frame");N.code="HTTP2WRAPPER_NOSETTINGS";for(let{reject:U}of s)U(N);p()}this._tryToCreateNewSession(c,f)});let R=()=>{if(!(!(c in this.queue)||!P())){for(let N of S[Rc])if(N in this.queue[c]){let{listeners:U}=this.queue[c][N];for(;U.length!==0&&P();)U.shift().resolve(S);let W=this.queue[c];if(W[N].listeners.length===0&&(delete W[N],Object.keys(W).length===0)){delete this.queue[c];break}if(!P())break}}};S.on("origin",()=>{S[Rc]=S.originSet,P()&&(R(),IH(this.sessions[c],S))}),S.once("remoteSettings",()=>{if(S.ref(),S.unref(),this._sessionsCount++,h.destroyed){let N=new Error("Agent has been destroyed");for(let U of s)U.reject(N);S.destroy();return}S[Rc]=S.originSet;{let N=this.sessions;if(c in N){let U=N[c];U.splice(Ott(U,S,Ltt),0,S)}else N[c]=[S]}this._freeSessionsCount+=1,C=!0,this.emit("session",S),R(),p(),S[Pa]===0&&this._freeSessionsCount>this.maxFreeSessions&&S.close(),s.length!==0&&(this.getSession(f,r,s),s.length=0),S.on("remoteSettings",()=>{R(),IH(this.sessions[c],S)})}),S[Sfe]=S.request,S.request=(N,U)=>{if(S[gI])throw new Error("The session is gracefully closing. No new streams are allowed.");let W=S[Sfe](N,U);return S.ref(),++S[Pa],S[Pa]===S.remoteSettings.maxConcurrentStreams&&this._freeSessionsCount--,W.once("close",()=>{if(I=P(),--S[Pa],!S.destroyed&&!S.closed&&(Mtt(this.sessions[c],S),P()&&!S.closed)){I||(this._freeSessionsCount++,I=!0);let ee=S[Pa]===0;ee&&S.unref(),ee&&(this._freeSessionsCount>this.maxFreeSessions||S[gI])?S.close():(IH(this.sessions[c],S),R())}}),W}}catch(S){for(let P of s)P.reject(S);p()}};h.listeners=s,h.completed=!1,h.destroyed=!1,this.queue[c][f]=h,this._tryToCreateNewSession(c,f)})}request(e,r,s,a){return new Promise((n,c)=>{this.getSession(e,r,[{reject:c,resolve:f=>{try{n(f.request(s,a))}catch(p){c(p)}}}])})}createConnection(e,r){return t.connect(e,r)}static connect(e,r){r.ALPNProtocols=["h2"];let s=e.port||443,a=e.hostname||e.host;return typeof r.servername>"u"&&(r.servername=a),Ttt.connect(s,a,r)}closeFreeSessions(){for(let e of Object.values(this.sessions))for(let r of e)r[Pa]===0&&r.close()}destroy(e){for(let r of Object.values(this.sessions))for(let s of r)s.destroy(e);for(let r of Object.values(this.queue))for(let s of Object.values(r))s.destroyed=!0;this.queue={}}get freeSessions(){return Dfe({agent:this,isFree:!0})}get busySessions(){return Dfe({agent:this,isFree:!1})}};im.kCurrentStreamsCount=Pa;im.kGracefullyClosing=gI;Pfe.exports={Agent:im,globalAgent:new im}});var BH=_((YMt,xfe)=>{"use strict";var{Readable:Utt}=Ie("stream"),wH=class extends Utt{constructor(e,r){super({highWaterMark:r,autoDestroy:!1}),this.statusCode=null,this.statusMessage="",this.httpVersion="2.0",this.httpVersionMajor=2,this.httpVersionMinor=0,this.headers={},this.trailers={},this.req=null,this.aborted=!1,this.complete=!1,this.upgrade=null,this.rawHeaders=[],this.rawTrailers=[],this.socket=e,this.connection=e,this._dumped=!1}_destroy(e){this.req._request.destroy(e)}setTimeout(e,r){return this.req.setTimeout(e,r),this}_dump(){this._dumped||(this._dumped=!0,this.removeAllListeners("data"),this.resume())}_read(){this.req&&this.req._request.resume()}};xfe.exports=wH});var vH=_((VMt,kfe)=>{"use strict";kfe.exports=t=>{let e={protocol:t.protocol,hostname:typeof t.hostname=="string"&&t.hostname.startsWith("[")?t.hostname.slice(1,-1):t.hostname,host:t.host,hash:t.hash,search:t.search,pathname:t.pathname,href:t.href,path:`${t.pathname||""}${t.search||""}`};return typeof t.port=="string"&&t.port.length!==0&&(e.port=Number(t.port)),(t.username||t.password)&&(e.auth=`${t.username||""}:${t.password||""}`),e}});var Tfe=_((JMt,Qfe)=>{"use strict";Qfe.exports=(t,e,r)=>{for(let s of r)t.on(s,(...a)=>e.emit(s,...a))}});var Ffe=_((KMt,Rfe)=>{"use strict";Rfe.exports=t=>{switch(t){case":method":case":scheme":case":authority":case":path":return!0;default:return!1}}});var Ofe=_((XMt,Nfe)=>{"use strict";var dI=(t,e,r)=>{Nfe.exports[e]=class extends t{constructor(...a){super(typeof r=="string"?r: Line truncated
`).reverse(),f=r.stack.slice(r.stack.indexOf(r.message)+r.message.length).split(`
`).reverse();for(;f.length!==0&&f[0]===c[0];)c.shift();this.stack=`${this.stack.slice(0,n)}${c.reverse().join(`
`)}${f.reverse().join(`
`)}`}}};Ln.RequestError=fs;var tT=class extends fs{constructor(e){super(`Redirected ${e.options.maxRedirects} times. Aborting.`,{},e),this.name="MaxRedirectsError"}};Ln.MaxRedirectsError=tT;var rT=class extends fs{constructor(e){super(`Response code ${e.statusCode} (${e.statusMessage})`,{},e.request),this.name="HTTPError"}};Ln.HTTPError=rT;var nT=class extends fs{constructor(e,r){super(e.message,e,r),this.name="CacheError"}};Ln.CacheError=nT;var iT=class extends fs{constructor(e,r){super(e.message,e,r),this.name="UploadError"}};Ln.UploadError=iT;var sT=class extends fs{constructor(e,r,s){super(e.message,e,s),this.name="TimeoutError",this.event=e.event,this.timings=r}};Ln.TimeoutError=sT;var tv=class extends fs{constructor(e,r){super(e.message,e,r),this.name="ReadError"}};Ln.ReadError=tv;var oT=class extends fs{constructor(e){super(`Unsupported protocol "${e.url.protocol}"`,{},e),this.name="UnsupportedProtocolError"}};Ln.UnsupportedProtocolError=oT;var Yrt=["socket","connect","continue","information","upgrade","timeout"],aT=class extends yAe.Duplex{constructor(e,r={},s){super({autoDestroy:!1,highWaterMark:0}),this[yI]=0,this[II]=0,this.requestInitialized=!1,this[ZQ]=new Set,this.redirects=[],this[CI]=!1,this[$Q]=!1,this[ev]=[],this.retryCount=0,this._progressCallbacks=[];let a=()=>this._unlockWrite(),n=()=>this._lockWrite();this.on("pipe",h=>{h.prependListener("data",a),h.on("data",n),h.prependListener("end",a),h.on("end",n)}),this.on("unpipe",h=>{h.off("data",a),h.off("data",n),h.off("end",a),h.off("end",n)}),this.on("pipe",h=>{h instanceof JH.IncomingMessage&&(this.options.headers={...h.headers,...this.options.headers})});let{json:c,body:f,form:p}=r;if((c||f||p)&&this._lockWrite(),Ln.kIsNormalizedAlready in r)this.options=r;else try{this.options=this.constructor.normalizeArguments(e,r,s)}catch(h){at.default.nodeStream(r.body)&&r.body.destroy(),this.destroy(h);return}(async()=>{var h;try{this.options.body instanceof Srt.ReadStream&&await Grt(this.options.body);let{url:E}=this.options;if(!E)throw new TypeError("Missing `url` property");if(this.requestUrl=E.toString(),decodeURI(this.requestUrl),await this._finalizeBody(),await this._makeRequest(),this.destroyed){(h=this[po])===null||h===void 0||h.destroy();return}for(let C of this[ev])C();this[ev].length=0,this.requestInitialized=!0}catch(E){if(E instanceof fs){this._beforeError(E);return}this.destroyed||this.destroy(E)}})()}static normalizeArguments(e,r,s){var a,n,c,f,p;let h=r;if(at.default.object(e)&&!at.default.urlInstance(e))r={...s,...e,...r};else{if(e&&r&&r.url!==void 0)throw new TypeError("The `url` option is mutually exclusive with the `input` argument");r={...s,...r},e!==void 0&&(r.url=e),at.default.urlInstance(r.url)&&(r.url=new w0.URL(r.url.toString()))}if(r.cache===!1&&(r.cache=void 0),r.dnsCache===!1&&(r.dnsCache=void 0),at.assert.any([at.default.string,at.default.undefined],r.method),at.assert.any([at.default.object,at.default.undefined],r.headers),at.assert.any([at.default.string,at.default.urlInstance,at.default.undefined],r.prefixUrl),at.assert.any([at.default.object,at.default.undefined],r.cookieJar),at.assert.any([at.default.object,at.default.string,at.default.undefined],r.searchParams),at.assert.any([at.default.object,at.default.string,at.default.undefined],r.cache),at.assert.any([at.default.object,at.default.number,at.default.undefined],r.timeout),at.assert.any([at.default.object,at.default.undefined],r.context),at.assert.any([at.default.object,at.default.undefined],r.hooks),at.assert.any([at.default.boolean,at.default.undefined],r.decompress),at.assert.any([at.default.boolean,at.default.undefined],r.ignoreInvalidCookies),at.assert.any([at.default.boolean,at.default.undefined],r.followRedirect),at.assert.any([at.default.number,at.default.undefined],r.maxRedirects),at.assert.any([at.default.boolean,at.default.undefined],r.throwHttpErrors),at.assert.any([at.default.boolean,at.default.undefined],r.http2),at.assert.any([at.default.boolean,at.default.undefined],r.allowGetBody),at.assert.any([at.default.string,at.default.undefined],r.localAddress),at.assert.any([vAe.isDnsLookupIpVersion,at.default.undefined],r.dnsLookupIpVersion),at.assert.any([at.default.object,at.default.undefined],r.https),at.assert.any([at.default.boolean,at.default.undefined],r.rejectUnauthorized),r.https&&(at.assert.any([at.default.boolean,at.default.undefined],r.https.rejectUnauthorized),at.assert.any([at.default.function_,at.default.undefined],r.https.checkServerIdentity),at.assert.any([at.default.string,at.default.object,at.default.array,at.default.undefined],r.https.certificateAuthority),at.assert.any([at.default.string,at.default.object,at.default.array,at.default.undefined],r.https.key),at.assert.any([at.default.string,at.default.object,at.default.array,at.default.undefined],r.https.certificate),at.assert.any([at.default.string,at.default.undefined],r.https.passphrase),at.assert.any([at.default.string,at.default.buffer,at.default.array,at.default.undefined],r.httpLine truncated
`)[3];return Qnt(e)}function fj(){return typeof hT.default.availableParallelism<"u"?hT.default.availableParallelism():Math.max(1,hT.default.cpus().length)}var hT,vnt,rpe,Snt,Dnt,npe,ipe,xnt,knt,gT=Xe(()=>{Dt();hT=ut(Ie("os"));dT();Pc();vnt=Number(process.versions.node.split(".")[0]),rpe=new Map([["darwin","open"],["linux","xdg-open"],["win32","explorer.exe"]]).get(process.platform),Snt=typeof rpe<"u"?async t=>{try{return await Aj(rpe,[t],{cwd:J.cwd()}),!0}catch{return!1}}:void 0,Dnt="/usr/bin/ldd";xnt=/^\s*at (.*?) ?\(((?:file|https?|blob|chrome-extension|native|eval|webpack|<anonymous>|\/|[a-z]:\\|\\\\).*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,knt=/\((\S*)(?::(\d+))(?::(\d+))\)/});function yj(t,e,r,s,a){let n=YB(r);if(s.isArray||s.type==="ANY"&&Array.isArray(n))return Array.isArray(n)?n.map((c,f)=>pj(t,`${e}[${f}]`,c,s,a)):String(n).split(/,/).map(c=>pj(t,e,c,s,a));if(Array.isArray(n))throw new Error(`Non-array configuration settings "${e}" cannot be an array`);return pj(t,e,r,s,a)}function pj(t,e,r,s,a){let n=YB(r);switch(s.type){case"ANY":return NQ(n);case"SHAPE":return Ont(t,e,r,s,a);case"MAP":return Lnt(t,e,r,s,a)}if(n===null&&!s.isNullable&&s.default!==null)throw new Error(`Non-nullable configuration settings "${e}" cannot be set to null`);if("values"in s&&s.values?.includes(n))return n;let f=(()=>{if(s.type==="BOOLEAN"&&typeof n!="string")return kB(n);if(typeof n!="string")throw new Error(`Expected configuration setting "${e}" to be a string, got ${typeof n}`);let p=Vk(n,{env:t.env});switch(s.type){case"ABSOLUTE_PATH":{let h=a,E=H8(r);return E&&E[0]!=="<"&&(h=J.dirname(E)),J.resolve(h,fe.toPortablePath(p))}case"LOCATOR_LOOSE":return Qp(p,!1);case"NUMBER":return parseInt(p);case"LOCATOR":return Qp(p);case"BOOLEAN":return kB(p);case"DURATION":return Jk(p,s.unit);default:return p}})();if("values"in s&&s.values&&!s.values.includes(f))throw new Error(`Invalid value, expected one of ${s.values.join(", ")}`);return f}function Ont(t,e,r,s,a){let n=YB(r);if(typeof n!="object"||Array.isArray(n))throw new nt(`Object configuration settings "${e}" must be an object`);let c=Ej(t,s,{ignoreArrays:!0});if(n===null)return c;for(let[f,p]of Object.entries(n)){let h=`${e}.${f}`;if(!s.properties[f])throw new nt(`Unrecognized configuration settings found: ${e}.${f} - run "yarn config" to see the list of settings supported in Yarn`);c.set(f,yj(t,h,p,s.properties[f],a))}return c}function Lnt(t,e,r,s,a){let n=YB(r),c=new Map;if(typeof n!="object"||Array.isArray(n))throw new nt(`Map configuration settings "${e}" must be an object`);if(n===null)return c;for(let[f,p]of Object.entries(n)){let h=s.normalizeKeys?s.normalizeKeys(f):f,E=`${e}['${h}']`,C=s.valueDefinition;c.set(h,yj(t,E,p,C,a))}return c}function Ej(t,e,{ignoreArrays:r=!1}={}){switch(e.type){case"SHAPE":{if(e.isArray&&!r)return[];let s=new Map;for(let[a,n]of Object.entries(e.properties))s.set(a,Ej(t,n));return s}case"MAP":return e.isArray&&!r?[]:new Map;case"ABSOLUTE_PATH":return e.default===null?null:t.projectCwd===null?Array.isArray(e.default)?e.default.map(s=>J.normalize(s)):J.isAbsolute(e.default)?J.normalize(e.default):e.isNullable?null:void 0:Array.isArray(e.default)?e.default.map(s=>J.resolve(t.projectCwd,s)):J.resolve(t.projectCwd,e.default);case"DURATION":return Jk(e.default,e.unit);default:return e.default}}function yT(t,e,r){if(e.type==="SECRET"&&typeof t=="string"&&r.hideSecrets)return Nnt;if(e.type==="ABSOLUTE_PATH"&&typeof t=="string"&&r.getNativePaths)return fe.fromPortablePath(t);if(e.isArray&&Array.isArray(t)){let s=[];for(let a of t)s.push(yT(a,e,r));return s}if(e.type==="MAP"&&t instanceof Map){if(t.size===0)return;let s=new Map;for(let[a,n]of t.entries()){let c=yT(n,e.valueDefinition,r);typeof c<"u"&&s.set(a,c)}return s}if(e.type==="SHAPE"&&t instanceof Map){if(t.size===0)return;let s=new Map;for(let[a,n]of t.entries()){let c=e.properties[a],f=yT(n,c,r);typeof f<"u"&&s.set(a,f)}return s}return t}function Mnt(){let t={};for(let[e,r]of Object.entries(process.env))e=e.toLowerCase(),e.startsWith(ET)&&(e=(0,ope.default)(e.slice(ET.length)),t[e]=r);return t}function gj(){let t=`${ET}rc_filename`;for(let[e,r]of Object.entries(process.env))if(e.toLowerCase()===t&&typeof r=="string")return r;return dj}async function spe(t){try{return await ce.readFilePromise(t)}catch{return Buffer.of()}}async function Unt(t,e){return Buffer.compare(...await Promise.all([spe(t),spe(e)]))===0}async function _nt(t,e){let[r,s]=await Promise.all([ce.statPromise(t),ce.statPromise(e)]);return r.dev===s.dev&&r.ino===s.ino}async function jnt({configuration:t,selfPath:e}){let r=t.get("yarnPath");return t.get("ignorePath")||r===null||r===e||await Hnt(r,e)?null:r}var ope,Lp,ape,lpe,cpe,hj,Rnt,ov,Fnt,Mp,ET,dj,Nnt,wI,upe,mj,IT,mT,Hnt,ze,av=Xe(()=>{Dt();wc();ope=ut(Sre()),Lp=ut(Fd());Yt();ape=ut(yne()),lpe=Ie("module"),cpe=ut(Ld()),hj=Ie("stream");nue();oI();R8();F8();N8();gue();O8();tm();Iue();LQ();xc();I0();pT();Pc();gT();Rp();Wo();Rnt=function(){if(!Lp.GITHUB_ACTIONS||!process.env.GITHUB_EVE Line truncated
`);return{stdout:n,stderr:c}}makeResolver(){let e=[];for(let r of this.plugins.values())for(let s of r.resolvers||[])e.push(new s);return new rm([new FQ,new Ei,...e])}makeFetcher(){let e=[];for(let r of this.plugins.values())for(let s of r.fetchers||[])e.push(new s);return new aI([new lI,new cI,...e])}getLinkers(){let e=[];for(let r of this.plugins.values())for(let s of r.linkers||[])e.push(new s);return e}getSupportedArchitectures(){let e=sv(),r=this.get("supportedArchitectures"),s=r.get("os");s!==null&&(s=s.map(c=>c==="current"?e.os:c));let a=r.get("cpu");a!==null&&(a=a.map(c=>c==="current"?e.cpu:c));let n=r.get("libc");return n!==null&&(n=Wl(n,c=>c==="current"?e.libc??Wl.skip:c)),{os:s,cpu:a,libc:n}}isInteractive({interactive:e,stdout:r}){return r.isTTY?e??this.get("preferInteractive"):!1}async getPackageExtensions(){if(this.packageExtensions!==null)return this.packageExtensions;this.packageExtensions=new Map;let e=this.packageExtensions,r=(s,a,{userProvided:n=!1}={})=>{if(!cl(s.range))throw new Error("Only semver ranges are allowed as keys for the packageExtensions setting");let c=new Ut;c.load(a,{yamlCompatibilityMode:!0});let f=xB(e,s.identHash),p=[];f.push([s.range,p]);let h={status:"inactive",userProvided:n,parentDescriptor:s};for(let E of c.dependencies.values())p.push({...h,type:"Dependency",descriptor:E});for(let E of c.peerDependencies.values())p.push({...h,type:"PeerDependency",descriptor:E});for(let[E,C]of c.peerDependenciesMeta)for(let[S,P]of Object.entries(C))p.push({...h,type:"PeerDependencyMeta",selector:E,key:S,value:P})};await this.triggerHook(s=>s.registerPackageExtensions,this,r);for(let[s,a]of this.get("packageExtensions"))r(C0(s,!0),Yk(a),{userProvided:!0});return e}normalizeLocator(e){return cl(e.reference)?Ws(e,`${this.get("defaultProtocol")}${e.reference}`):Mp.test(e.reference)?Ws(e,`${this.get("defaultProtocol")}${e.reference}`):e}normalizeDependency(e){return cl(e.range)?On(e,`${this.get("defaultProtocol")}${e.range}`):Mp.test(e.range)?On(e,`${this.get("defaultProtocol")}${e.range}`):e}normalizeDependencyMap(e){return new Map([...e].map(([r,s])=>[r,this.normalizeDependency(s)]))}normalizePackage(e,{packageExtensions:r}){let s=LB(e),a=r.get(e.identHash);if(typeof a<"u"){let c=e.version;if(c!==null){for(let[f,p]of a)if(Zf(c,f))for(let h of p)switch(h.status==="inactive"&&(h.status="redundant"),h.type){case"Dependency":typeof s.dependencies.get(h.descriptor.identHash)>"u"&&(h.status="active",s.dependencies.set(h.descriptor.identHash,this.normalizeDependency(h.descriptor)));break;case"PeerDependency":typeof s.peerDependencies.get(h.descriptor.identHash)>"u"&&(h.status="active",s.peerDependencies.set(h.descriptor.identHash,h.descriptor));break;case"PeerDependencyMeta":{let E=s.peerDependenciesMeta.get(h.selector);(typeof E>"u"||!Object.hasOwn(E,h.key)||E[h.key]!==h.value)&&(h.status="active",Yl(s.peerDependenciesMeta,h.selector,()=>({}))[h.key]=h.value)}break;default:G4(h)}}}let n=c=>c.scope?`${c.scope}__${c.name}`:`${c.name}`;for(let c of s.peerDependenciesMeta.keys()){let f=Sa(c);s.peerDependencies.has(f.identHash)||s.peerDependencies.set(f.identHash,On(f,"*"))}for(let c of s.peerDependencies.values()){if(c.scope==="types")continue;let f=n(c),p=Da("types",f),h=un(p);s.peerDependencies.has(p.identHash)||s.peerDependenciesMeta.has(h)||s.dependencies.has(p.identHash)||(s.peerDependencies.set(p.identHash,On(p,"*")),s.peerDependenciesMeta.set(h,{optional:!0}))}return s.dependencies=new Map(qs(s.dependencies,([,c])=>al(c))),s.peerDependencies=new Map(qs(s.peerDependencies,([,c])=>al(c))),s}getLimit(e){return Yl(this.limits,e,()=>(0,cpe.default)(this.get(e)))}async triggerHook(e,...r){for(let s of this.plugins.values()){let a=s.hooks;if(!a)continue;let n=e(a);n&&await n(...r)}}async triggerMultipleHooks(e,r){for(let s of r)await this.triggerHook(e,...s)}async reduceHook(e,r,...s){let a=r;for(let n of this.plugins.values()){let c=n.hooks;if(!c)continue;let f=e(c);f&&(a=await f(a,...s))}return a}async firstHook(e,...r){for(let s of this.plugins.values()){let a=s.hooks;if(!a)continue;let n=e(a);if(!n)continue;let c=await n(...r);if(typeof c<"u")return c}return null}}});var qr={};Vt(qr,{EndStrategy:()=>Bj,ExecError:()=>CT,PipeError:()=>lv,execvp:()=>Aj,pipevp:()=>Wu});function om(t){return t!==null&&typeof t.fd=="number"}function Ij(){}function Cj(){for(let t of am)t.kill()}async function Wu(t,e,{cwd:r,env:s=process.env,strict:a=!1,stdin:n=null,stdout:c,stderr:f,end:p=2}){let h=["pipe","pipe","pipe"];n===null?h[0]="ignore":om(n)&&(h[0]=n),om(c)&&(h[1]=c),om(f)&&(h[2]=f);let E=(0,wj.default)(t,e,{cwd:fe.fromPortablePath(r),env:{...s,PWD:fe.fromPortablePath(r)},stdio:h});am.add(E),am.size===1&&(process.on("SIGINT",Ij),process.on("SIGTERM",Cj)),!om(n)&&n!==null&&n.pipe(E.stdin),om(c)||E.stdout.pipe(c,{end:!1}),om(f)||E.stderr.pipe(f,{end:!1});let C=()=>{for(let S of new Set([c,f]))om(S)||S.end()};return new Promise((S,P)=>{E.on("error",I=>{am.delete(E),am.size===0&&(process.off("SIGINT",Ij),pro Line truncated
This command will run a command using Yarn's portable shell.
Make sure to escape glob patterns, redirections, and other features that might be expanded by your own shell.
Note: To escape something from Yarn's shell, you might have to escape it twice, the first time from your own shell.
Note: Don't use this command in Yarn scripts, as Yarn's shell is automatically used.
For a list of features, visit: https://github.com/yarnpkg/berry/blob/master/packages/yarnpkg-shell/README.md.
`,examples:[["Run a simple command","$0 echo Hello"],["Run a command with a glob pattern","$0 echo '*.js'"],["Run a command with a redirection","$0 echo Hello World '>' hello.txt"],["Run a command with an escaped glob pattern (The double escape is needed in Unix shells)",`$0 echo '"*.js"'`],["Run a command with a variable (Double quotes are needed in Unix shells, to prevent them from expanding the variable)",'$0 "GREETING=Hello echo $GREETING World"']]}}async execute(){let r=this.args.length>0?`${this.commandName} ${this.args.join(" ")}`:this.commandName;return await vI(r,[],{cwd:fe.toPortablePath(this.cwd),stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr})}}});var Vl,bpe=Xe(()=>{Vl=class extends Error{constructor(e){super(e),this.name="ShellError"}}});var PT={};Vt(PT,{fastGlobOptions:()=>kpe,isBraceExpansion:()=>Lj,isGlobPattern:()=>Knt,match:()=>znt,micromatchOptions:()=>bT});function Knt(t){if(!DT.default.scan(t,bT).isGlob)return!1;try{DT.default.parse(t,bT)}catch{return!1}return!0}function znt(t,{cwd:e,baseFs:r}){return(0,Ppe.default)(t,{...kpe,cwd:fe.fromPortablePath(e),fs:ax(xpe.default,new t0(r))})}function Lj(t){return DT.default.scan(t,bT).isBrace}var Ppe,xpe,DT,bT,kpe,Qpe=Xe(()=>{Dt();Ppe=ut(BQ()),xpe=ut(Ie("fs")),DT=ut(Go()),bT={strictBrackets:!0},kpe={onlyDirectories:!1,onlyFiles:!1}});function Mj(){}function Uj(){for(let t of cm)t.kill()}function Npe(t,e,r,s){return a=>{let n=a[0]instanceof tA.Transform?"pipe":a[0],c=a[1]instanceof tA.Transform?"pipe":a[1],f=a[2]instanceof tA.Transform?"pipe":a[2],p=(0,Rpe.default)(t,e,{...s,stdio:[n,c,f]});return cm.add(p),cm.size===1&&(process.on("SIGINT",Mj),process.on("SIGTERM",Uj)),a[0]instanceof tA.Transform&&a[0].pipe(p.stdin),a[1]instanceof tA.Transform&&p.stdout.pipe(a[1],{end:!1}),a[2]instanceof tA.Transform&&p.stderr.pipe(a[2],{end:!1}),{stdin:p.stdin,promise:new Promise(h=>{p.on("error",E=>{switch(cm.delete(p),cm.size===0&&(process.off("SIGINT",Mj),process.off("SIGTERM",Uj)),E.code){case"ENOENT":a[2].write(`command not found: ${t}
`),h(127);break;case"EACCES":a[2].write(`permission denied: ${t}
`),h(128);break;default:a[2].write(`uncaught error: ${E.message}
`),h(1);break}}),p.on("close",E=>{cm.delete(p),cm.size===0&&(process.off("SIGINT",Mj),process.off("SIGTERM",Uj)),h(E!==null?E:129)})})}}}function Ope(t){return e=>{let r=e[0]==="pipe"?new tA.PassThrough:e[0];return{stdin:r,promise:Promise.resolve().then(()=>t({stdin:r,stdout:e[1],stderr:e[2]}))}}}function xT(t,e){return Hj.start(t,e)}function Tpe(t,e=null){let r=new tA.PassThrough,s=new Fpe.StringDecoder,a="";return r.on("data",n=>{let c=s.write(n),f;do if(f=c.indexOf(`
`),f!==-1){let p=a+c.substring(0,f);c=c.substring(f+1),a="",t(e!==null?`${e} ${p}`:p)}while(f!==-1);a+=c}),r.on("end",()=>{let n=s.end();n!==""&&t(e!==null?`${e} ${n}`:n)}),r}function Lpe(t,{prefix:e}){return{stdout:Tpe(r=>t.stdout.write(`${r}
`),t.stdout.isTTY?e:null),stderr:Tpe(r=>t.stderr.write(`${r}
`),t.stderr.isTTY?e:null)}}var Rpe,tA,Fpe,cm,Oc,_j,Hj,jj=Xe(()=>{Rpe=ut(_U()),tA=Ie("stream"),Fpe=Ie("string_decoder"),cm=new Set;Oc=class{constructor(e){this.stream=e}close(){}get(){return this.stream}},_j=class{constructor(){this.stream=null}close(){if(this.stream===null)throw new Error("Assertion failed: No stream attached");this.stream.end()}attach(e){this.stream=e}get(){if(this.stream===null)throw new Error("Assertion failed: No stream attached");return this.stream}},Hj=class t{constructor(e,r){this.stdin=null;this.stdout=null;this.stderr=null;this.pipe=null;this.ancestor=e,this.implementation=r}static start(e,{stdin:r,stdout:s,stderr:a}){let n=new t(null,e);return n.stdin=r,n.stdout=s,n.stderr=a,n}pipeTo(e,r=1){let s=new t(this,e),a=new _j;return s.pipe=a,s.stdout=this.stdout,s.stderr=this.stderr,(r&1)===1?this.stdout=a:this.ancestor!==null&&(this.stderr=this.ancestor.stdout),(r&2)===2?this.stderr=a:this.ancestor!==null&&(this.stderr=this.ancestor.stderr),s}async exec(){let e=["ignore","ignore","ignore"];if(this.pipe)e[0]="pipe";else{if(this.stdin===null)throw new Error("Assertion failed: No input stream registered");e[0]=this.stdin.get()}let r;if(this.stdout===null)throw new Error("Assertion failed: No output stream registered");r=this.stdout,e[1]=r.get();let s;if(this.stderr===null)throw new Error("Assertion failed: No error stream registered");s=this.stderr,e[2]=s.get();let a=this.implementation(e);return this.pipe&&this.pipe.attach(a.stdin),await a.promise.then(n=>(r.close(),s.close(),n))}async run(){let e=[];for(let s=this;s;s=s.ancestor)e.push(s.exec());return(await Promise.all(e))[0]}}});var mv={};Vt(mv,{EntryCommand:()=>Av,ShellError:()=>Vl,execute:()=>vI,globUtils:()=>PT});function Mpe(t,e,r){let s=new Jl.PassThrough({autoDestroy:!0});switch(t){case 0:(e&1)===1&&r.stdin.pipe(s,{end:!1}),(e&2)===2&&r.stdin instanceof Jl.Writable&&s.pipe(r.stdin,{end:!1});break;case 1:(e&1)===1&&r.stdout.pipe(s,{end:!1}),(e&2)===2&&s.pipe(r.stdout,{end:!1});break;case 2:(e&1)===1&&r.stderr.pipe(s,{end:!1}),(e&2)===2&&s.pipe(r.stderr,{end:!1});break;default:throw new Vl(`Bad file descriptor: "${t}"`)}return s}function QT(t,e={}){let r={...t,...e};return r.environment={...t.environment,...e.environment},r.variables={...t.variables,...e.variables},r}async function Znt(t,e,r){let s=[],a=new Jl.PassThrough;return a.on("data",n=>s.push(n)),await TT(t,e,QT(r,{stdout:a})),Buffer.concat(s).toString().replace(/[\r\n]+$/,"")}async function Upe(t,e,r){let s=t.map(async n=>{let c=await um(n.args,e,r);return{name:n.name,value:c.join(" ")}});return(await Promise.all(s)).reduce((n,c)=>(n[c.name]=c.value,n),{})}function kT(t){return t.match(/[^ \r\n\t]+/g)||[]}async function Wpe(t,e,r,s,a=s){switch(t.name){case"$":s(String(process.pid));break;case"#":s(String(e.args.length));break;case"@":if(t.quoted)for(let n of e.args)a(n);else for(let n of e.args){let c=kT(n);for(let f=0;f<c.length-1;++f)a(c[f]);s(c[c.length-1])}break;case"*":{let n=e.args.join(" ");if(t.quoted)s(n);else for(let c of kT(n))a(c)}break;case"PPID":s(String(process.ppid));break;case"RANDOM":s(String(Math.floor(Math.random()*32768)));break;default:{let n=parseInt(t.name,10),c,f=Number.isFinite(n);if(f?n>=0&&n<e.args.length&&(c=e.args[n]):Object.hasOwn(r.variables,t.name)?c=r.variables[t.name]:Object.hasOwn(r.environment,t.name)&&(c=r.environment[t.name]),typeof c<"u"&&t.alternativeValue?c=(await um(t.alternativeValue,e,r)).join(" "):typeof c>"u"&&(t.defaultValue?c=(await um(t.defaultValue,e,r)).join(" "):t.alternativeValue&&(c="")),typeof c>"u")throw f?new Vl(`Unbound argument #${n}`):new Vl(`Unbound variable "${t.name}"`);if(t.quoted)s(c);else{let p=kT(c);for(let E=0;E<p.length-1;++E)a(p[E]);let h=p[p.length-1];typeof h<"u"&&s(h)}}break}}async function hv(t,e,r){if(t.type==="number"){if(Number.isInteger(t.value))return t.value;throw new Error(`Invalid number: "${t.value}", only integers are allowed`)}else if(t.type==="variable"){let s=[];await Wpe({...t,quoted:!0},e,r,n=>s.push(n));let a=Number(s.join(" "));return Number.isNaN(a)?hv({type:"variable",name:s.join(" ")},e,r):hv({type:"number",value:a},e,r)}else return $nt[t.type](await hv(t.left,e,r),await hv(t.right,e,r))}async function um(t,e,r){let s=new Map,a=[],n=[],c=E=>{n.push(E)},f=()=>{n.length>0&&a.push(n.join("")),n=[]},p=E=>{c(E),f()},h=(E,C,S)=>{let P=JSON.stringify({type:E,fd:C}),I=s.get(P);typeof I>"u"&&s.set(P,I=[]),I.push(S)};for(let E of t){let C=!1;switch(E.type){case"redirection":{let S=await um(E.args,e,r);for(let P of S)h(E.subtype,E.fd,P)}break;case"argument":for(let S of E.segments)switch(S.type){case"text":c(S.text);break;case"glob":c(S.pattern),C=!0;break;case"shell":{let P=await Znt(S.shell,e,r);if(S.quoted)c(P);else{let I=kT(P);for(let R=0;R<I.length-1;++R)p(I[R]);c(I[I.length-1])}}break;case"variable":await Wpe(S,e,r,c,p);break;case"arithmetic":c(String(await hv(S.arithmetic,e,r)));break}break}if(f(),C){let S=a.pop();if(typeof S>"u")throw new Error("Assertion failed: Expected a glob pa Line truncated
`)).finally(()=>{r.stdout.isTTY&&r.stdout.write(`Job ${p}, '${c(AE(t))}' has ended
`)})),0}return await Hpe(t,e,r)}async function nit(t,e,r,{background:s=!1}={}){let a,n=f=>{a=f,r.variables["?"]=String(f)},c=async f=>{try{return await rit(f.chain,e,r,{background:s&&typeof f.then>"u"})}catch(p){if(!(p instanceof Vl))throw p;return r.stderr.write(`${p.message}
`),1}};for(n(await c(t));t.then;){if(r.exitCode!==null)return r.exitCode;switch(t.then.type){case"&&":a===0&&n(await c(t.then.line));break;case"||":a!==0&&n(await c(t.then.line));break;default:throw new Error(`Assertion failed: Unsupported command type: "${t.then.type}"`)}t=t.then.line}return a}async function TT(t,e,r){let s=r.backgroundJobs;r.backgroundJobs=[];let a=0;for(let{command:n,type:c}of t){if(a=await nit(n,e,r,{background:c==="&"}),r.exitCode!==null)return r.exitCode;r.variables["?"]=String(a)}return await Promise.all(r.backgroundJobs),r.backgroundJobs=s,a}function Ype(t){switch(t.type){case"variable":return t.name==="@"||t.name==="#"||t.name==="*"||Number.isFinite(parseInt(t.name,10))||"defaultValue"in t&&!!t.defaultValue&&t.defaultValue.some(e=>dv(e))||"alternativeValue"in t&&!!t.alternativeValue&&t.alternativeValue.some(e=>dv(e));case"arithmetic":return Gj(t.arithmetic);case"shell":return qj(t.shell);default:return!1}}function dv(t){switch(t.type){case"redirection":return t.args.some(e=>dv(e));case"argument":return t.segments.some(e=>Ype(e));default:throw new Error(`Assertion failed: Unsupported argument type: "${t.type}"`)}}function Gj(t){switch(t.type){case"variable":return Ype(t);case"number":return!1;default:return Gj(t.left)||Gj(t.right)}}function qj(t){return t.some(({command:e})=>{for(;e;){let r=e.chain;for(;r;){let s;switch(r.type){case"subshell":s=qj(r.subshell);break;case"command":s=r.envs.some(a=>a.args.some(n=>dv(n)))||r.args.some(a=>dv(a));break}if(s)return!0;if(!r.then)break;r=r.then.chain}if(!e.then)break;e=e.then.line}return!1})}async function vI(t,e=[],{baseFs:r=new Yn,builtins:s={},cwd:a=fe.toPortablePath(process.cwd()),env:n=process.env,stdin:c=process.stdin,stdout:f=process.stdout,stderr:p=process.stderr,variables:h={},glob:E=PT}={}){let C={};for(let[I,R]of Object.entries(n))typeof R<"u"&&(C[I]=R);let S=new Map(Xnt);for(let[I,R]of Object.entries(s))S.set(I,R);c===null&&(c=new Jl.PassThrough,c.end());let P=ux(t,E);if(!qj(P)&&P.length>0&&e.length>0){let{command:I}=P[P.length-1];for(;I.then;)I=I.then.line;let R=I.chain;for(;R.then;)R=R.then.chain;R.type==="command"&&(R.args=R.args.concat(e.map(N=>({type:"argument",segments:[{type:"text",text:N}]}))))}return await TT(P,{args:e,baseFs:r,builtins:S,initialStdin:c,initialStdout:f,initialStderr:p,glob:E},{cwd:a,environment:C,exitCode:null,procedures:{},stdin:c,stdout:f,stderr:p,variables:Object.assign({},h,{"?":0}),nextBackgroundJobIndex:1,backgroundJobs:[]})}var jpe,Gpe,Jl,qpe,Xnt,$nt,pv=Xe(()=>{Dt();wc();jpe=ut(TE()),Gpe=Ie("os"),Jl=Ie("stream"),qpe=Ie("timers/promises");Dpe();bpe();Qpe();jj();jj();Xnt=new Map([["cd",async([t=(0,Gpe.homedir)(),...e],r,s)=>{let a=J.resolve(s.cwd,fe.toPortablePath(t));if(!(await r.baseFs.statPromise(a).catch(c=>{throw c.code==="ENOENT"?new Vl(`cd: no such file or directory: ${t}`):c})).isDirectory())throw new Vl(`cd: not a directory: ${t}`);return s.cwd=a,0}],["pwd",async(t,e,r)=>(r.stdout.write(`${fe.fromPortablePath(r.cwd)}
`),0)],[":",async(t,e,r)=>0],["true",async(t,e,r)=>0],["false",async(t,e,r)=>1],["exit",async([t,...e],r,s)=>s.exitCode=parseInt(t??s.variables["?"],10)],["echo",async(t,e,r)=>(r.stdout.write(`${t.join(" ")}
`),0)],["sleep",async([t],e,r)=>{if(typeof t>"u")throw new Vl("sleep: missing operand");let s=Number(t);if(Number.isNaN(s))throw new Vl(`sleep: invalid time interval '${t}'`);return await(0,qpe.setTimeout)(1e3*s,0)}],["unset",async(t,e,r)=>{for(let s of t)delete r.environment[s],delete r.variables[s];return 0}],["__ysh_run_procedure",async(t,e,r)=>{let s=r.procedures[t[0]];return await xT(s,{stdin:new Oc(r.stdin),stdout:new Oc(r.stdout),stderr:new Oc(r.stderr)}).run()}],["__ysh_set_redirects",async(t,e,r)=>{let s=r.stdin,a=r.stdout,n=r.stderr,c=[],f=[],p=[],h=0;for(;t[h]!=="--";){let C=t[h++],{type:S,fd:P}=JSON.parse(C),I=W=>{switch(P){case null:case 0:c.push(W);break;default:throw new Error(`Unsupported file descriptor: "${P}"`)}},R=W=>{switch(P){case null:case 1:f.push(W);break;case 2:p.push(W);break;default:throw new Error(`Unsupported file descriptor: "${P}"`)}},N=Number(t[h++]),U=h+N;for(let W=h;W<U;++h,++W)switch(S){case"<":I(()=>e.baseFs.createReadStream(J.resolve(r.cwd,fe.toPortablePath(t[W]))));break;case"<<<":I(()=>{let ee=new Jl.PassThrough;return process.nextTick(()=>{ee.write(`${t[W]}
`),ee.end()}),ee});break;case"<&":I(()=>Mpe(Number(t[W]),1,r));break;case">":case">>":{let ee=J.resolve(r.cwd,fe.toPortablePath(t[W]));R(ee==="/dev/null"?new Jl.Writable({autoDestroy:!0,emitClose:!0,write(ie,ue,le){setImmediate(le)}}):e.baseFs.createWriteStream(ee,S===">>"?{flags:"a"}:void 0))}break;case">&":R(Mpe(Number(t[W]),2,r));break;default:throw new Error(`Assertion failed: Unsupported redirection type: "${S}"`)}}if(c.length>0){let C=new Jl.PassThrough;s=C;let S=P=>{if(P===c.length)C.end();else{let I=c[P]();I.pipe(C,{end:!1}),I.on("end",()=>{S(P+1)})}};S(0)}if(f.length>0){let C=new Jl.PassThrough;a=C;for(let S of f)C.pipe(S)}if(p.length>0){let C=new Jl.PassThrough;n=C;for(let S of p)C.pipe(S)}let E=await xT(gv(t.slice(h+1),e,r),{stdin:new Oc(s),stdout:new Oc(a),stderr:new Oc(n)}).run();return await Promise.all(f.map(C=>new Promise((S,P)=>{C.on("error",I=>{P(I)}),C.on("close",()=>{S()}),C.end()}))),await Promise.all(p.map(C=>new Promise((S,P)=>{C.on("error",I=>{P(I)}),C.on("close",()=>{S()}),C.end()}))),E}]]);$nt={addition:(t,e)=>t+e,subtraction:(t,e)=>t-e,multiplication:(t,e)=>t*e,division:(t,e)=>Math.trunc(t/e)}});var Vpe=_((S4t,RT)=>{function iit(){var t=0,e=1,r=2,s=3,a=4,n=5,c=6,f=7,p=8,h=9,E=10,C=11,S=12,P=13,I=14,R=15,N=16,U=17,W=0,ee=1,ie=2,ue=3,le=4;function me(g,we){return 55296<=g.charCodeAt(we)&&g.charCodeAt(we)<=56319&&56320<=g.charCodeAt(we+1)&&g.charCodeAt(we+1)<=57343}function pe(g,we){we===void 0&&(we=0);var ye=g.charCodeAt(we);if(55296<=ye&&ye<=56319&&we<g.length-1){var Ae=ye,se=g.charCodeAt(we+1);return 56320<=se&&se<=57343?(Ae-55296)*1024+(se-56320)+65536:Ae}if(56320<=ye&&ye<=57343&&we>=1){var Ae=g.charCodeAt(we-1),se=ye;return 55296<=Ae&&Ae<=56319?(Ae-55296)*1024+(se-56320)+65536:se}return ye}function Be(g,we,ye){var Ae=[g].concat(we).concat([ye]),se=Ae[Ae.length-2],Z=ye,De=Ae.lastIndexOf(I);if(De>1&&Ae.slice(1,De).every(function(j){return j==s})&&[s,P,U].indexOf(g)==-1)return ie;var Re=Ae.lastIndexOf(a);if(Re>0&&Ae.slice(1,Re).every(function(j){return j==a})&&[S,a].indexOf(se)==-1)return Ae.filter(function(j){return j==a}).length%2==1?ue:le;if(se==t&&Z==e)return W;if(se==r||se==t||se==e)return Z==I&&we.every(function(j){return j==s})?ie:ee;if(Z==r||Z==t||Z==e)return ee;if(se==c&&(Z==c||Z==f||Z==h||Z==E))return W;if((se==h||se==f)&&(Z==f||Z==p))return W;if((se==E||se==p)&&Z==p)return W;if(Z==s||Z==R)return W;if(Z==n)return W;if(se==S)return W;var mt=Ae.indexOf(s)!=-1?Ae.lastIndexOf(s)-1:Ae.length-2;return[P,U].indexOf(Ae[mt])!=-1&&Ae.slice(mt+1,-1).every(function(j){return j==s})&&Z==I||se==R&&[N,U].indexOf(Z)!=-1?W:we.indexOf(a)!=-1?ie:se==a&&Z==a?W:ee}this.nextBreak=function(g,we){if(we===void 0&&(we=0),we<0)return 0;if(we>=g.length-1)return g.length;for(var ye=Ce(pe(g,we)),Ae=[],se=we+1;se<g.length;se++)if(!me(g,se-1)){var Z=Ce(pe(g,se));if(Be(ye,Ae,Z))return se;Ae.push(Z)}return g.length},this.splitGraphemes=function(g){for(var we=[],ye=0,Ae;(Ae=this.nextBreak(g,ye))<g.length;)we.push(g.slice(ye,Ae)),ye=Ae;return ye<g.length&&we.push(g.slice(ye)),we},this.iterateGraphemes=function(g){var we=0,ye={next:function(){var Ae,se;return(se=this.nextBreak(g,we))<g.length?(Ae=g.slice(we,se),we=se,{value:Ae,done:!1}):we<g.length?(Ae=g.slice(we),we=g.length,{value:Ae,done:!1}):{value:void 0,done:!0}}.bind(this)};return typeof Symbol<"u"&&Symbol.iterator&&(ye[Symbol.iterator]=function(){return ye}),ye},this.countGraphemes=function(g){for(var we=0,ye=0,Ae;(Ae=this.nextBreak(g,ye))<g.length;)ye=Ae,we++;return ye<g.length&&we++,we};function Ce(g){return 1536<=g&&g<=1541||g==1757||g==1807||g==2274||g==3406||g==69821||70082<=g&&g<=70083||g==72250||72326<=g&&g<=72329||g==73030?S:g==13?t:g==10?e:0<=g&&g<=9||11<=g&&g<=12||14<=g&&g<=31||127<=g&&g<=159||g==173||g==1564||g==6158||g==8203||8206<=g&&g<=8207||g==8232||g==8233||8234<=g&&g<=8238||8288<=g&&g<=8292||g==8293||8294<=g&&g<=8303||55296<=g&&g<=57343||g==65279||65520<=g&&g<=65528||65529<=g&&g<=65531||113824<=g&&g<=113827||119155<=g&&g<=119162||g==917504||g==917505||917506<=g&&g<=917535||917632<=g&&g<=917759||918e3<=g&&g<=921599?r:768<=g&&g<=879||1155<=g&&g<=1159||1160<=g&&g<=1161||1425<=g&&g<=1469||g==1471||1473<=g&&g<=1474||1476<=g&&g<=1477||g==1479||1552<=g&&g<=1562||1611<=g&&g<=1631||g==1648||1750<=g&&g<=1756||1759<=g&&g<=1764||1767<=g&&g<=1768||1770<=g&&g<=1773||g==1809||1840<=g&&g<=1866||1958<=g&&g<=1968||2027<=g&&g<=2035||2070<=g&&g<=2073||2075<=g&&g<=2083||2085<=g&&g<=2087||2089<=g&&g<=2093||2137<=g&&g<=2139||2260<=g&&g<=2273||2275<=g&&g<=2306||g==2362||g==2364||2369<=g&&g<=2376||g==2381||2385<=g&&g<=2391||2402<=g&&g<=2403||g==2433||g==2492||g==2494||2497<=g&&g<=2500||g==2509||g==2519||2530<=g&&g<=2531||2561<=g&&g<=2562||g==2620||2625<=g&&g<=2626||2631<=g&&g<=2632||2635<=g&&g<=2637||g==2641||2672<=g&&g<=2673||g==2677||2689<=g&&g<=2690||g==2748||2753<=g&&g<=2757||2759<=g&&g<=2760||g==2765||2786<=g&&g<=2787||2810<=g&&g<=2815||g==2817||g==2876||g==2878||g==2879||2881<=g&&g<=2884||g==2893||g==2902||g==2903||2914<=g&&g<=2915||g==2946||g==3006|| Line truncated
`,end:t=>`::endgroup::
`}:NT.default.TRAVIS?{start:t=>`travis_fold:start:${t}
`,end:t=>`travis_fold:end:${t}
`}:NT.default.GITLAB?{start:t=>`section_start:${Math.floor(Date.now()/1e3)}:${t.toLowerCase().replace(/\W+/g,"_")}[collapsed=true]\r\x1B[0K${t}
`,end:t=>`section_end:${Math.floor(Date.now()/1e3)}:${t.toLowerCase().replace(/\W+/g,"_")}\r\x1B[0K`}:null,ehe=D0!==null,Zpe=new Date,lit=["iTerm.app","Apple_Terminal","WarpTerminal","vscode"].includes(process.env.TERM_PROGRAM)||!!process.env.WT_SESSION,cit=t=>t,OT=cit({patrick:{date:[17,3],chars:["\u{1F340}","\u{1F331}"],size:40},simba:{date:[19,7],chars:["\u{1F981}","\u{1F334}"],size:40},jack:{date:[31,10],chars:["\u{1F383}","\u{1F987}"],size:40},hogsfather:{date:[31,12],chars:["\u{1F389}","\u{1F384}"],size:40},default:{chars:["=","-"],size:80}}),uit=lit&&Object.keys(OT).find(t=>{let e=OT[t];return!(e.date&&(e.date[0]!==Zpe.getDate()||e.date[1]!==Zpe.getMonth()+1))})||"default";Ot=class extends Ao{constructor({configuration:r,stdout:s,json:a=!1,forceSectionAlignment:n=!1,includeNames:c=!0,includePrefix:f=!0,includeFooter:p=!0,includeLogs:h=!a,includeInfos:E=h,includeWarnings:C=h}){super();this.uncommitted=new Set;this.warningCount=0;this.errorCount=0;this.timerFooter=[];this.startTime=Date.now();this.indent=0;this.level=0;this.progress=new Map;this.progressTime=0;this.progressFrame=0;this.progressTimeout=null;this.progressStyle=null;this.progressMaxScaledSize=null;if(RB(this,{configuration:r}),this.configuration=r,this.forceSectionAlignment=n,this.includeNames=c,this.includePrefix=f,this.includeFooter=p,this.includeInfos=E,this.includeWarnings=C,this.json=a,this.stdout=s,r.get("enableProgressBars")&&!a&&s.isTTY&&s.columns>22){let S=r.get("progressBarStyle")||uit;if(!Object.hasOwn(OT,S))throw new Error("Assertion failed: Invalid progress bar style");this.progressStyle=OT[S];let P=Math.min(this.getRecommendedLength(),80);this.progressMaxScaledSize=Math.floor(this.progressStyle.size*P/80)}}static async start(r,s){let a=new this(r),n=process.emitWarning;process.emitWarning=(c,f)=>{if(typeof c!="string"){let h=c;c=h.message,f=f??h.name}let p=typeof f<"u"?`${f}: ${c}`:c;a.reportWarning(0,p)},r.includeVersion&&a.reportInfo(0,zd(r.configuration,`Yarn ${fn}`,2));try{await s(a)}catch(c){a.reportExceptionOnce(c)}finally{await a.finalize(),process.emitWarning=n}return a}hasErrors(){return this.errorCount>0}exitCode(){return this.hasErrors()?1:0}getRecommendedLength(){let s=this.progressStyle!==null?this.stdout.columns-1:super.getRecommendedLength();return Math.max(40,s-12-this.indent*2)}startSectionSync({reportHeader:r,reportFooter:s,skipIfEmpty:a},n){let c={committed:!1,action:()=>{r?.()}};a?this.uncommitted.add(c):(c.action(),c.committed=!0);let f=Date.now();try{return n()}catch(p){throw this.reportExceptionOnce(p),p}finally{let p=Date.now();this.uncommitted.delete(c),c.committed&&s?.(p-f)}}async startSectionPromise({reportHeader:r,reportFooter:s,skipIfEmpty:a},n){let c={committed:!1,action:()=>{r?.()}};a?this.uncommitted.add(c):(c.action(),c.committed=!0);let f=Date.now();try{return await n()}catch(p){throw this.reportExceptionOnce(p),p}finally{let p=Date.now();this.uncommitted.delete(c),c.committed&&s?.(p-f)}}startTimerImpl(r,s,a){return{cb:typeof s=="function"?s:a,reportHeader:()=>{this.level+=1,this.reportInfo(null,`\u250C ${r}`),this.indent+=1,D0!==null&&!this.json&&this.includeInfos&&this.stdout.write(D0.start(r))},reportFooter:f=>{if(this.indent-=1,D0!==null&&!this.json&&this.includeInfos){this.stdout.write(D0.end(r));for(let p of this.timerFooter)p()}this.configuration.get("enableTimers")&&f>200?this.reportInfo(null,`\u2514 Completed in ${Ht(this.configuration,f,ht.DURATION)}`):this.reportInfo(null,"\u2514 Completed"),this.level-=1},skipIfEmpty:(typeof s=="function"?{}:s).skipIfEmpty}}startTimerSync(r,s,a){let{cb:n,...c}=this.startTimerImpl(r,s,a);return this.startSectionSync(c,n)}async startTimerPromise(r,s,a){let{cb:n,...c}=this.startTimerImpl(r,s,a);return this.startSectionPromise(c,n)}reportSeparator(){this.indent===0?this.writeLine(""):this.reportInfo(null,"")}reportInfo(r,s){if(!this.includeInfos)return;this.commit();let a=this.formatNameWithHyperlink(r),n=a?`${a}: `:"",c=`${this.formatPrefix(n,"blueBright")}${s}`;this.json?this.reportJson({type:"info",name:r,displayName:this.formatName(r),indent:this.formatIndent(),data:s}):this.writeLine(c)}reportWarning(r,s){if(this.warningCount+=1,!this.includeWarnings)return;this.commit();let a=this.formatNameWithHyperlink(r),n=a?`${a}: `:"";this.json?this.reportJson({type:"warning",name:r,displayName:this.formatName(r),indent:this.formatIndent(),data:s}):this.writeLine(`${this.formatPrefix(n,"yellowBright")}${s}`)}reportError(r,s){this.errorCount+=1,this.timerFooter.push(()=>this.reportErrorImpl(r,s)),this.reportErrorImpl(r,s)}reportErrorImpl(r,s){this.commit();let a=this.formatNameWithHyperlink(r),n=a?`${a}: `:"";this.json?this.reportJson({type:"error",name:r,displayName:this.formatName(r),indent:this.formatIndent(),data:s}):this.writeLine(`${this.formatPrefix(n,"redBright")}${s}`,{truncate:!1})}reportFold(r,s){if(!D0)return;let a=`${D0.start(r)}${s}${D0.end(r)}`;this.timerFooter.push(()=>this.stdout.write(a))}reportProgress(r){if(this.progressStyle===null)ret Line truncated
`),this.writeProgress()}writeLines(r,{truncate:s}={}){this.clearProgress({delta:r.length});for(let a of r)this.stdout.write(`${this.truncate(a,{truncate:s})}
`);this.writeProgress()}commit(){let r=this.uncommitted;this.uncommitted=new Set;for(let s of r)s.committed=!0,s.action()}clearProgress({delta:r=0,clear:s=!1}){this.progressStyle!==null&&this.progress.size+r>0&&(this.stdout.write(`\x1B[${this.progress.size+r}A`),(r>0||s)&&this.stdout.write("\x1B[0J"))}writeProgress(){if(this.progressStyle===null||(this.progressTimeout!==null&&clearTimeout(this.progressTimeout),this.progressTimeout=null,this.progress.size===0))return;let r=Date.now();r-this.progressTime>Xpe&&(this.progressFrame=(this.progressFrame+1)%zpe.length,this.progressTime=r);let s=zpe[this.progressFrame];for(let a of this.progress.values()){let n="";if(typeof a.lastScaledSize<"u"){let h=this.progressStyle.chars[0].repeat(a.lastScaledSize),E=this.progressStyle.chars[1].repeat(this.progressMaxScaledSize-a.lastScaledSize);n=` ${h}${E}`}let c=this.formatName(null),f=c?`${c}: `:"",p=a.definition.title?` ${a.definition.title}`:"";this.stdout.write(`${Ht(this.configuration,"\u27A4","blueBright")} ${f}${s}${n}${p}
`)}this.progressTimeout=setTimeout(()=>{this.refreshProgress({force:!0})},Xpe)}refreshProgress({delta:r=0,force:s=!1}={}){let a=!1,n=!1;if(s||this.progress.size===0)a=!0;else for(let c of this.progress.values()){let f=typeof c.definition.progress<"u"?Math.trunc(this.progressMaxScaledSize*c.definition.progress):void 0,p=c.lastScaledSize;c.lastScaledSize=f;let h=c.lastTitle;if(c.lastTitle=c.definition.title,f!==p||(n=h!==c.definition.title)){a=!0;break}}a&&(this.clearProgress({delta:r,clear:n}),this.writeProgress())}truncate(r,{truncate:s}={}){return this.progressStyle===null&&(s=!1),typeof s>"u"&&(s=this.configuration.get("preferTruncatedLines")),s&&(r=(0,$pe.default)(r,0,this.stdout.columns-1)),r}formatName(r){return this.includeNames?the(r,{configuration:this.configuration,json:this.json}):""}formatPrefix(r,s){return this.includePrefix?`${Ht(this.configuration,"\u27A4",s)} ${r}${this.formatIndent()}`:""}formatNameWithHyperlink(r){return this.includeNames?Wj(r,{configuration:this.configuration,json:this.json}):""}formatIndent(){return this.level>0||!this.forceSectionAlignment?"\u2502 ".repeat(this.indent):`${ait} `}}});var In={};Vt(In,{PackageManager:()=>nhe,detectPackageManager:()=>ihe,executePackageAccessibleBinary:()=>che,executePackageScript:()=>LT,executePackageShellcode:()=>Yj,executeWorkspaceAccessibleBinary:()=>mit,executeWorkspaceLifecycleScript:()=>ahe,executeWorkspaceScript:()=>ohe,getPackageAccessibleBinaries:()=>MT,getWorkspaceAccessibleBinaries:()=>lhe,hasPackageScript:()=>hit,hasWorkspaceScript:()=>Vj,isNodeScript:()=>Jj,makeScriptEnv:()=>Iv,maybeExecuteWorkspaceLifecycleScript:()=>dit,prepareExternalProject:()=>pit});async function b0(t,e,r,s=[]){if(process.platform==="win32"){let a=`@goto #_undefined_# 2>NUL || @title %COMSPEC% & @setlocal & @"${r}" ${s.map(n=>`"${n.replace('"','""')}"`).join(" ")} %*`;await ce.writeFilePromise(J.format({dir:t,name:e,ext:".cmd"}),a)}await ce.writeFilePromise(J.join(t,e),`#!/bin/sh
exec "${r}" ${s.map(a=>`'${a.replace(/'/g,`'"'"'`)}'`).join(" ")} "$@"
`,{mode:493})}async function ihe(t){let e=await Ut.tryFind(t);if(e?.packageManager){let s=xQ(e.packageManager);if(s?.name){let a=`found ${JSON.stringify({packageManager:e.packageManager})} in manifest`,[n]=s.reference.split(".");switch(s.name){case"yarn":return{packageManagerField:!0,packageManager:Number(n)===1?"Yarn Classic":"Yarn",reason:a};case"npm":return{packageManagerField:!0,packageManager:"npm",reason:a};case"pnpm":return{packageManagerField:!0,packageManager:"pnpm",reason:a}}}}let r;try{r=await ce.readFilePromise(J.join(t,Er.lockfile),"utf8")}catch{}return r!==void 0?r.match(/^__metadata:$/m)?{packageManager:"Yarn",reason:'"__metadata" key found in yarn.lock'}:{packageManager:"Yarn Classic",reason:'"__metadata" key not found in yarn.lock, must be a Yarn classic lockfile'}:ce.existsSync(J.join(t,"package-lock.json"))?{packageManager:"npm",reason:`found npm's "package-lock.json" lockfile`}:ce.existsSync(J.join(t,"pnpm-lock.yaml"))?{packageManager:"pnpm",reason:`found pnpm's "pnpm-lock.yaml" lockfile`}:null}async function Iv({project:t,locator:e,binFolder:r,ignoreCorepack:s,lifecycleScript:a,baseEnv:n=t?.configuration.env??process.env}){let c={};for(let[E,C]of Object.entries(n))typeof C<"u"&&(c[E.toLowerCase()!=="path"?E:"PATH"]=C);let f=fe.fromPortablePath(r);c.BERRY_BIN_FOLDER=fe.fromPortablePath(f);let p=process.env.COREPACK_ROOT&&!s?fe.join(process.env.COREPACK_ROOT,"dist/yarn.js"):process.argv[1];if(await Promise.all([b0(r,"node",process.execPath),...fn!==null?[b0(r,"run",process.execPath,[p,"run"]),b0(r,"yarn",process.execPath,[p]),b0(r,"yarnpkg",process.execPath,[p]),b0(r,"node-gyp",process.execPath,[p,"run","--top-level","node-gyp"])]:[]]),t&&(c.INIT_CWD=fe.fromPortablePath(t.configuration.startingCwd),c.PROJECT_CWD=fe.fromPortablePath(t.cwd)),c.PATH=c.PATH?`${f}${fe.delimiter}${c.PATH}`:`${f}`,c.npm_execpath=`${f}${fe.sep}yarn`,c.npm_node_execpath=`${f}${fe.sep}node`,e){if(!t)throw new Error("Assertion failed: Missing project");let E=t.tryWorkspaceByLocator(e),C=E?E.manifest.version??"":t.storedPackages.get(e.locatorHash).version??"";c.npm_package_name=un(e),c.npm_package_version=C;let S;if(E)S=E.cwd;else{let P=t.storedPackages.get(e.locatorHash);if(!P)throw new Error(`Package for ${Yr(t.configuration,e)} not found in the project`);let I=t.configuration.getLinkers(),R={project:t,report:new Ot({stdout:new P0.PassThrough,configuration:t.configuration})},N=I.find(U=>U.supportsPackage(P,R));if(!N)throw new Error(`The package ${Yr(t.configuration,P)} isn't supported by any of the available linkers`);S=await N.findPackageLocation(P,R)}c.npm_package_json=fe.fromPortablePath(J.join(S,Er.manifest))}let h=fn!==null?`yarn/${fn}`:`yarn/${Pp("@yarnpkg/core").version}-core`;return c.npm_config_user_agent=`${h} npm/? node/${process.version} ${process.platform} ${process.arch}`,a&&(c.npm_lifecycle_event=a),t&&await t.configuration.triggerHook(E=>E.setupScriptEnvironment,t,c,async(E,C,S)=>await b0(r,E,C,S)),c}async function pit(t,e,{configuration:r,report:s,workspace:a=null,locator:n=null}){await Ait(async()=>{await ce.mktempPromise(async c=>{let f=J.join(c,"pack.log"),p=null,{stdout:h,stderr:E}=r.getSubprocessStreams(f,{prefix:fe.fromPortablePath(t),report:s}),C=n&&Gu(n)?rI(n):n,S=C?ll(C):"an external project";h.write(`Packing ${S} from sources
`);let P=await ihe(t),I;P!==null?(h.write(`Using ${P.packageManager} for bootstrap. Reason: ${P.reason}
`),I=P.packageManager):(h.write(`No package manager configuration detected; defaulting to Yarn
`),I="Yarn");let R=I==="Yarn"&&!P?.packageManagerField;await ce.mktempPromise(async N=>{let U=await Iv({binFolder:N,ignoreCorepack:R,baseEnv:{...process.env,COREPACK_ENABLE_AUTO_PIN:"0"}}),ee=new Map([["Yarn Classic",async()=>{let ue=a!==null?["workspace",a]:[],le=J.join(t,Er.manifest),me=await ce.readFilePromise(le),pe=await Wu(process.execPath,[process.argv[1],"set","version","classic","--only-if-needed","--yarn-path"],{cwd:t,env:U,stdin:p,stdout:h,stderr:E,end:1});if(pe.code!==0)return pe.code;await ce.writeFilePromise(le,me),await ce.appendFilePromise(J.join(t,".npmignore"),`/.yarn
`),h.write(`
`),delete U.NODE_ENV;let Be=await Wu("yarn",["install"],{cwd:t,env:U,stdin:p,stdout:h,stderr:E,end:1});if(Be.code!==0)return Be.code;h.write(`
`);let Ce=await Wu("yarn",[...ue,"pack","--filename",fe.fromPortablePath(e)],{cwd:t,env:U,stdin:p,stdout:h,stderr:E});return Ce.code!==0?Ce.code:0}],["Yarn",async()=>{let ue=a!==null?["workspace",a]:[];U.YARN_ENABLE_INLINE_BUILDS="1";let le=J.join(t,Er.lockfile);await ce.existsPromise(le)||await ce.writeFilePromise(le,"");let me=await Wu("yarn",[...ue,"pack","--install-if-needed","--filename",fe.fromPortablePath(e)],{cwd:t,env:U,stdin:p,stdout:h,stderr:E});return me.code!==0?me.code:0}],["npm",async()=>{if(a!==null){let we=new P0.PassThrough,ye=WE(we);we.pipe(h,{end:!1});let Ae=await Wu("npm",["--version"],{cwd:t,env:U,stdin:p,stdout:we,stderr:E,end:0});if(we.end(),Ae.code!==0)return h.end(),E.end(),Ae.code;let se=(await ye).toString().trim();if(!Zf(se,">=7.x")){let Z=Da(null,"npm"),De=On(Z,se),Re=On(Z,">=7.x");throw new Error(`Workspaces aren't supported by ${ni(r,De)}; please upgrade to ${ni(r,Re)} (npm has been detected as the primary package manager for ${Ht(r,t,ht.PATH)})`)}}let ue=a!==null?["--workspace",a]:[];delete U.npm_config_user_agent,delete U.npm_config_production,delete U.NPM_CONFIG_PRODUCTION,delete U.NODE_ENV;let le=await Wu("npm",["install","--legacy-peer-deps"],{cwd:t,env:U,stdin:p,stdout:h,stderr:E,end:1});if(le.code!==0)return le.code;let me=new P0.PassThrough,pe=WE(me);me.pipe(h);let Be=await Wu("npm",["pack","--silent",...ue],{cwd:t,env:U,stdin:p,stdout:me,stderr:E});if(Be.code!==0)return Be.code;let Ce=(await pe).toString().trim().replace(/^.*\n/s,""),g=J.resolve(t,fe.toPortablePath(Ce));return await ce.renamePromise(g,e),0}]]).get(I);if(typeof ee>"u")throw new Error("Assertion failed: Unsupported workflow");let ie=await ee();if(!(ie===0||typeof ie>"u"))throw ce.detachTemp(c),new jt(58,`Packing the package failed (exit code ${ie}, logs can be found here: ${Ht(r,f,ht.PATH)})`)})})})}async function hit(t,e,{project:r}){let s=r.tryWorkspaceByLocator(t);if(s!==null)return Vj(s,e);let a=r.storedPackages.get(t.locatorHash);if(!a)throw new Error(`Package for ${Yr(r.configuration,t)} not found in the project`);return await $f.openPromise(async n=>{let c=r.configuration,f=r.configuration.getLinkers(),p={project:r,report:new Ot({stdout:new P0.PassThrough,configuration:c})},h=f.find(P=>P.supportsPackage(a,p));if(!h)throw new Error(`The package ${Yr(r.configuration,a)} isn't supported by any of the available linkers`);let E=await h.findPackageLocation(a,p),C=new Sn(E,{baseFs:n});return(await Ut.find(vt.dot,{baseFs:C})).scripts.has(e)})}async function LT(t,e,r,{cwd:s,project:a,stdin:n,stdout:c,stderr:f}){return await ce.mktempPromise(async p=>{let{manifest:h,env:E,cwd:C}=await she(t,{project:a,binFolder:p,cwd:s,lifecycleScript:e}),S=h.scripts.get(e);if(typeof S>"u")return 1;let P=async()=>await vI(S,r,{cwd:C,env:E,stdin:n,stdout:c,stderr:f});return await(await a.configuration.reduceHook(R=>R.wrapScriptExecution,P,a,t,e,{script:S,args:r,cwd:C,env:E,stdin:n,stdout:c,stderr:f}))()})}async function Yj(t,e,r,{cwd:s,project:a,stdin:n,stdout:c,stderr:f}){return await ce.mktempPromise(async p=>{let{env:h,cwd:E}=await she(t,{project:a,binFolder:p,cwd:s});return await vI(e,r,{cwd:E,env:h,stdin:n,stdout:c,stderr:f})})}async function git(t,{binFolder:e,cwd:r,lifecycleScript:s}){let a=await Iv({project:t.project,locator:t.anchoredLocator,binFolder:e,lifecycleScript:s});return await Kj(e,await lhe(t)),typeof r>"u"&&(r=J.dirname(await ce.realpathPromise(J.join(t.cwd,"package.json")))),{manifest:t.manifest,binFolder:e,env:a,cwd:r}}async function she(t,{project:e,binFolder:r,cwd:s,lifecycleScript:a}){let n=e.tryWorkspaceByLocator(t);if(n!==null)return git(n,{binFolder:r,cwd:s,lifecycleScript:a});let c=e.storedPackages.get(t.locatorHash);if(!c)throw new Error(`Package for ${Yr(e.configuration,t)} not found in the project`);return await $f.openPromise(async f=>{let p=e.configuration,h=e.configuration.getLinkers(),E={project:e,report:new Ot({stdout:new P0.PassThrough,configuration:p})},C=h.find(N=>N.supportsPackage(c,E));if(!C)throw new Error(`The package ${Yr(e.configuration,c)} isn't supported by any of the available linkers`);let S=await Iv({project:e,locator:t,binFolder:r,lifecycleScript:a});await Kj(r,await MT(t,{project:e}));let P=await C.findPackageLocation(c,E),I=new Sn(P,{baseFs:f}),R=await Ut.find(vt.dot,{baseFs:I});return typeof s>"u"&&(s=P),{manifest:R,binFolder:r,env:S,cwd:s}})}async function ohe(t,e,r,{cwd:s,stdin:a,stdout:n,stderr:c}){return await LT(t.anchoredLocator,e,r,{cwd:s,project:t.project,stdin:a,stdout:n,stderr:c})}function Vj(t,e){return t.manifest.scripts.has(e)}async function ahe(t,e,{cwd:r,report:s}){let{configuration:a}=t.project,n=null;await ce.mktempPromise(async c=>{let f=J.join(c,`${e}.log`),p=`# This file contains the result of Yarn calling the "${e}" lifecycle script inside a workspace ("${fe.fromPortablePath(t.cwd)}")
`,{stdout:h,stderr:E}=a.getSubprocessStreams(f,{report:s,prefix:Yr(a,t.anchoredLocator),header:p});s.reportInfo(36,`Calling the "${e}" lifecycle script`);let C=await ohe(t,e,[],{cwd:r,stdin:n,stdout:h,stderr:E});if(h.end(),E.end(),C!==0)throw ce.detachTemp(c),new jt(36,`${bB(e)} script failed (exit code ${Ht(a,C,ht.NUMBER)}, logs can be found here: ${Ht(a,f,ht.PATH)}); run ${Ht(a,`yarn ${e}`,ht.CODE)} to investigate`)})}async function dit(t,e,r){Vj(t,e)&&await ahe(t,e,r)}function Jj(t){let e=J.extname(t);if(e.match(/\.[cm]?[jt]sx?$/))return!0;if(e===".exe"||e===".bin")return!1;let r=Buffer.alloc(4),s;try{s=ce.openSync(t,"r")}catch{return!0}try{ce.readSync(s,r,0,r.length,0)}finally{ce.closeSync(s)}let a=r.readUint32BE();return!(a===3405691582||a===3489328638||a===2135247942||(a&4294901760)===1297743872)}async function MT(t,{project:e}){let r=e.configuration,s=new Map,a=e.storedPackages.get(t.locatorHash);if(!a)throw new Error(`Package for ${Yr(r,t)} not found in the project`);let n=new P0.Writable,c=r.getLinkers(),f={project:e,report:new Ot({configuration:r,stdout:n})},p=new Set([t.locatorHash]);for(let E of a.dependencies.values()){let C=e.storedResolutions.get(E.descriptorHash);if(!C)throw new Error(`Assertion failed: The resolution (${ni(r,E)}) should have been registered`);p.add(C)}let h=await Promise.all(Array.from(p,async E=>{let C=e.storedPackages.get(E);if(!C)throw new Error(`Assertion failed: The package (${E}) should have been registered`);if(C.bin.size===0)return Wl.skip;let S=c.find(I=>I.supportsPackage(C,f));if(!S)return Wl.skip;let P=null;try{P=await S.findPackageLocation(C,f)}catch(I){if(I.code==="LOCATOR_NOT_INSTALLED")return Wl.skip;throw I}return{dependency:C,packageLocation:P}}));for(let E of h){if(E===Wl.skip)continue;let{dependency:C,packageLocation:S}=E;for(let[P,I]of C.bin){let R=J.resolve(S,I);s.set(P,[C,fe.fromPortablePath(R),Jj(R)])}}return s}async function lhe(t){return await MT(t.anchoredLocator,{project:t.project})}async function Kj(t,e){await Promise.all(Array.from(e,([r,[,s,a]])=>a?b0(t,r,process.execPath,[s]):b0(t,r,s,[])))}async function che(t,e,r,{cwd:s,project:a,stdin:n,stdout:c,stderr:f,nodeArgs:p=[],packageAccessibleBinaries:h}){h??=await MT(t,{project:a});let E=h.get(e);if(!E)throw new Error(`Binary not found (${e}) for ${Yr(a.configuration,t)}`);return await ce.mktempPromise(async C=>{let[,S]=E,P=await Iv({project:a,locator:t,binFolder:C});await Kj(P.BERRY_BIN_FOLDER,h);let I=Jj(fe.toPortablePath(S))?Wu(process.execPath,[...p,S,...r],{cwd:s,env:P,stdin:n,stdout:c,stderr:f}):Wu(S,r,{cwd:s,env:P,stdin:n,stdout:c,stderr:f}),R;try{R=await I}finally{await ce.removePromise(P.BERRY_BIN_FOLDER)}return R.code})}async function mit(t,e,r,{cwd:s,stdin:a,stdout:n,stderr:c,packageAccessibleBinaries:f}){return await che(t.anchoredLocator,e,r,{project:t.project,cwd:s,stdin:a,stdout:n,stderr:c,packageAccessibleBinaries:f})}var rhe,P0,nhe,fit,Ait,zj=Xe(()=>{Dt();Dt();eA();pv();ql();rhe=ut(Ld()),P0=Ie("stream");oI();Tc();Ev();yv();dT();xc();Pc();Rp();Wo();nhe=(a=>(a.Yarn1="Yarn Classic",a.Yarn2="Yarn",a.Npm="npm",a.Pnpm="pnpm",a))(nhe||{});fit=2,Ait=(0,rhe.default)(fit)});var DI=_((J4t,fhe)=>{"use strict";var uhe=new Map([["C","cwd"],["f","file"],["z","gzip"],["P","preservePaths"],["U","unlink"],["strip-components","strip"],["stripComponents","strip"],["keep-newer","newer"],["keepNewer","newer"],["keep-newer-files","newer"],["keepNewerFiles","newer"],["k","keep"],["keep-existing","keep"],["keepExisting","keep"],["m","noMtime"],["no-mtime","noMtime"],["p","preserveOwner"],["L","follow"],["h","follow"]]);fhe.exports=t=>t?Object.keys(t).map(e=>[uhe.has(e)?uhe.get(e):e,t[e]]).reduce((e,r)=>(e[r[0]]=r[1],e),Object.create(null)):{}});var PI=_((K4t,Ihe)=>{"use strict";var Ahe=typeof process=="object"&&process?process:{stdout:null,stderr:null},yit=Ie("events"),phe=Ie("stream"),hhe=Ie("string_decoder").StringDecoder,_p=Symbol("EOF"),Hp=Symbol("maybeEmitEnd"),x0=Symbol("emittedEnd"),UT=Symbol("emittingEnd"),Cv=Symbol("emittedError"),_T=Symbol("closed"),ghe=Symbol("read"),HT=Symbol("flush"),dhe=Symbol("flushChunk"),ul=Symbol("encoding"),jp=Symbol("decoder"),jT=Symbol("flowing"),wv=Symbol("paused"),bI=Symbol("resume"),Ys=Symbol("bufferLength"),Xj=Symbol("bufferPush"),Zj=Symbol("bufferShift"),Ko=Symbol("objectMode"),zo=Symbol("destroyed"),$j=Symbol("emitData"),mhe=Symbol("emitEnd"),e6=Symbol("emitEnd2"),Gp=Symbol("async"),Bv=t=>Promise.resolve().then(t),yhe=global._MP_NO_ITERATOR_SYMBOLS_!=="1",Eit=yhe&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),Iit=yhe&&Symbol.iterator||Symbol("iterator not implemented"),Cit=t=>t==="end"||t==="finish"||t==="prefinish",wit=t=>t instanceof ArrayBuffer||typeof t=="object"&&t.constructor&&t.constructor.name==="ArrayBuffer"&&t.byteLength>=0,Bit=t=>!Buffer.isBuffer(t)&&ArrayBuffer.isView(t),GT=class{constructor(e,r,s){this.src=e,this.dest=r,this.opts=s,this.ondrain=()=>e[bI](),r.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ond Line truncated
`,a=Buffer.byteLength(s),n=Math.floor(Math.log(a)/Math.log(10))+1;return a+n>=Math.pow(10,n)&&(n+=1),n+a+s}};Sv.parse=(t,e,r)=>new Sv(Yit(Vit(t),e),r);var Yit=(t,e)=>e?Object.keys(t).reduce((r,s)=>(r[s]=t[s],r),e):t,Vit=t=>t.replace(/\n$/,"").split(`
`).reduce(Jit,Object.create(null)),Jit=(t,e)=>{let r=parseInt(e,10);if(r!==Buffer.byteLength(e)+1)return t;e=e.substr((r+" ").length);let s=e.split("="),a=s.shift().replace(/^SCHILY\.(dev|ino|nlink)/,"$1");if(!a)return t;let n=s.join("=");return t[a]=/^([A-Z]+\.)?([mac]|birth|creation)time$/.test(a)?new Date(n*1e3):/^[0-9]+$/.test(n)?+n:n,t};Fhe.exports=Sv});var FI=_((a3t,Nhe)=>{Nhe.exports=t=>{let e=t.length-1,r=-1;for(;e>-1&&t.charAt(e)==="/";)r=e,e--;return r===-1?t:t.slice(0,r)}});var zT=_((l3t,Ohe)=>{"use strict";Ohe.exports=t=>class extends t{warn(e,r,s={}){this.file&&(s.file=this.file),this.cwd&&(s.cwd=this.cwd),s.code=r instanceof Error&&r.code||e,s.tarCode=e,!this.strict&&s.recoverable!==!1?(r instanceof Error&&(s=Object.assign(r,s),r=r.message),this.emit("warn",s.tarCode,r,s)):r instanceof Error?this.emit("error",Object.assign(r,s)):this.emit("error",Object.assign(new Error(`${e}: ${r}`),s))}}});var b6=_((u3t,Lhe)=>{"use strict";var XT=["|","<",">","?",":"],D6=XT.map(t=>String.fromCharCode(61440+t.charCodeAt(0))),Kit=new Map(XT.map((t,e)=>[t,D6[e]])),zit=new Map(D6.map((t,e)=>[t,XT[e]]));Lhe.exports={encode:t=>XT.reduce((e,r)=>e.split(r).join(Kit.get(r)),t),decode:t=>D6.reduce((e,r)=>e.split(r).join(zit.get(r)),t)}});var P6=_((f3t,Uhe)=>{var{isAbsolute:Xit,parse:Mhe}=Ie("path").win32;Uhe.exports=t=>{let e="",r=Mhe(t);for(;Xit(t)||r.root;){let s=t.charAt(0)==="/"&&t.slice(0,4)!=="//?/"?"/":r.root;t=t.substr(s.length),e+=s,r=Mhe(t)}return[e,t]}});var Hhe=_((A3t,_he)=>{"use strict";_he.exports=(t,e,r)=>(t&=4095,r&&(t=(t|384)&-19),e&&(t&256&&(t|=64),t&32&&(t|=8),t&4&&(t|=1)),t)});var M6=_((g3t,t0e)=>{"use strict";var Jhe=PI(),Khe=KT(),zhe=RI(),nA=Ie("fs"),jhe=Ie("path"),rA=QI(),Zit=FI(),Xhe=(t,e)=>e?(t=rA(t).replace(/^\.(\/|$)/,""),Zit(e)+"/"+t):rA(t),$it=16*1024*1024,Ghe=Symbol("process"),qhe=Symbol("file"),Whe=Symbol("directory"),k6=Symbol("symlink"),Yhe=Symbol("hardlink"),Dv=Symbol("header"),ZT=Symbol("read"),Q6=Symbol("lstat"),$T=Symbol("onlstat"),T6=Symbol("onread"),R6=Symbol("onreadlink"),F6=Symbol("openfile"),N6=Symbol("onopenfile"),R0=Symbol("close"),eR=Symbol("mode"),O6=Symbol("awaitDrain"),x6=Symbol("ondrain"),iA=Symbol("prefix"),Vhe=Symbol("hadError"),Zhe=zT(),est=b6(),$he=P6(),e0e=Hhe(),tR=Zhe(class extends Jhe{constructor(e,r){if(r=r||{},super(r),typeof e!="string")throw new TypeError("path is required");this.path=rA(e),this.portable=!!r.portable,this.myuid=process.getuid&&process.getuid()||0,this.myuser=process.env.USER||"",this.maxReadSize=r.maxReadSize||$it,this.linkCache=r.linkCache||new Map,this.statCache=r.statCache||new Map,this.preservePaths=!!r.preservePaths,this.cwd=rA(r.cwd||process.cwd()),this.strict=!!r.strict,this.noPax=!!r.noPax,this.noMtime=!!r.noMtime,this.mtime=r.mtime||null,this.prefix=r.prefix?rA(r.prefix):null,this.fd=null,this.blockLen=null,this.blockRemain=null,this.buf=null,this.offset=null,this.length=null,this.pos=null,this.remain=null,typeof r.onwarn=="function"&&this.on("warn",r.onwarn);let s=!1;if(!this.preservePaths){let[a,n]=$he(this.path);a&&(this.path=n,s=a)}this.win32=!!r.win32||process.platform==="win32",this.win32&&(this.path=est.decode(this.path.replace(/\\/g,"/")),e=e.replace(/\\/g,"/")),this.absolute=rA(r.absolute||jhe.resolve(this.cwd,e)),this.path===""&&(this.path="./"),s&&this.warn("TAR_ENTRY_INFO",`stripping ${s} from absolute path`,{entry:this,path:s+this.path}),this.statCache.has(this.absolute)?this[$T](this.statCache.get(this.absolute)):this[Q6]()}emit(e,...r){return e==="error"&&(this[Vhe]=!0),super.emit(e,...r)}[Q6](){nA.lstat(this.absolute,(e,r)=>{if(e)return this.emit("error",e);this[$T](r)})}[$T](e){this.statCache.set(this.absolute,e),this.stat=e,e.isFile()||(e.size=0),this.type=rst(e),this.emit("stat",e),this[Ghe]()}[Ghe](){switch(this.type){case"File":return this[qhe]();case"Directory":return this[Whe]();case"SymbolicLink":return this[k6]();default:return this.end()}}[eR](e){return e0e(e,this.type==="Directory",this.portable)}[iA](e){return Xhe(e,this.prefix)}[Dv](){this.type==="Directory"&&this.portable&&(this.noMtime=!0),this.header=new zhe({path:this[iA](this.path),linkpath:this.type==="Link"?this[iA](this.linkpath):this.linkpath,mode:this[eR](this.stat.mode),uid:this.portable?null:this.stat.uid,gid:this.portable?null:this.stat.gid,size:this.stat.size,mtime:this.noMtime?null:this.mtime||this.stat.mtime,type:this.type,uname:this.portable?null:this.stat.uid===this.myuid?this.myuser:"",atime:this.portable?null:this.stat.atime,ctime:this.portable?null:this.stat.ctime}),this.header.encode()&&!this.noPax&&super.write(new Khe({atime:this.portable?null:this.header.atime,ctime:this.portable?null:this.header.ctime,gid:this.portable?null:this.header.gid,mtime:this.noMtime?null:this.mtime||this.header.mtime,path:this[iA](this.path),linkpath:this.type==="Link"?this[iA](this.linkpath):this.linkpath,size:this.header.size,uid:this.portable?null:this.header.uid,uname:this.portable?null:this.header.uname,dev:this.portable?null:this.stat.dev,ino:this. Line truncated
`}),f},s})});var xs={};Vt(xs,{emitList:()=>Jot,emitTree:()=>cde,treeNodeToJson:()=>lde,treeNodeToTreeify:()=>ade});function ade(t,{configuration:e}){let r={},s=0,a=(n,c)=>{let f=Array.isArray(n)?n.entries():Object.entries(n);for(let[p,h]of f){if(!h)continue;let{label:E,value:C,children:S}=h,P=[];typeof E<"u"&&P.push(zd(e,E,2)),typeof C<"u"&&P.push(Ht(e,C[0],C[1])),P.length===0&&P.push(zd(e,`${p}`,2));let I=P.join(": ").trim(),R=`\0${s++}\0`,N=c[`${R}${I}`]={};typeof S<"u"&&a(S,N)}};if(typeof t.children>"u")throw new Error("The root node must only contain children");return a(t.children,r),r}function lde(t){let e=r=>{if(typeof r.children>"u"){if(typeof r.value>"u")throw new Error("Assertion failed: Expected a value to be set if the children are missing");return Xd(r.value[0],r.value[1])}let s=Array.isArray(r.children)?r.children.entries():Object.entries(r.children??{}),a=Array.isArray(r.children)?[]:{};for(let[n,c]of s)c&&(a[Kot(n)]=e(c));return typeof r.value>"u"?a:{value:Xd(r.value[0],r.value[1]),children:a}};return e(t)}function Jot(t,{configuration:e,stdout:r,json:s}){let a=t.map(n=>({value:n}));cde({children:a},{configuration:e,stdout:r,json:s})}function cde(t,{configuration:e,stdout:r,json:s,separators:a=0}){if(s){let c=Array.isArray(t.children)?t.children.values():Object.values(t.children??{});for(let f of c)f&&r.write(`${JSON.stringify(lde(f))}
`);return}let n=(0,ode.asTree)(ade(t,{configuration:e}),!1,!1);if(n=n.replace(/\0[0-9]+\0/g,""),a>=1&&(n=n.replace(/^([├└]─)/gm,`\u2502
$1`).replace(/^│\n/,"")),a>=2)for(let c=0;c<2;++c)n=n.replace(/^([│ ].{2}[├│ ].{2}[^\n]+\n)(([│ ]).{2}[├└].{2}[^\n]*\n[│ ].{2}[│ ].{2}[├└]─)/gm,`$1$3 \u2502
$2`).replace(/^│\n/,"");if(a>=3)throw new Error("Only the first two levels are accepted by treeUtils.emitTree");r.write(n)}function Kot(t){return typeof t=="string"?t.replace(/^\0[0-9]+\0/,""):t}var ode,ude=Xe(()=>{ode=ut(sde());xc()});var MR,fde=Xe(()=>{MR=class{constructor(e){this.releaseFunction=e;this.map=new Map}addOrCreate(e,r){let s=this.map.get(e);if(typeof s<"u"){if(s.refCount<=0)throw new Error(`Race condition in RefCountedMap. While adding a new key the refCount is: ${s.refCount} for ${JSON.stringify(e)}`);return s.refCount++,{value:s.value,release:()=>this.release(e)}}else{let a=r();return this.map.set(e,{refCount:1,value:a}),{value:a,release:()=>this.release(e)}}}release(e){let r=this.map.get(e);if(!r)throw new Error(`Unbalanced calls to release. No known instances of: ${JSON.stringify(e)}`);let s=r.refCount;if(s<=0)throw new Error(`Unbalanced calls to release. Too many release vs alloc refcount would become: ${s-1} of ${JSON.stringify(e)}`);s==1?(this.map.delete(e),this.releaseFunction(r.value)):r.refCount--}}});function _v(t){let e=t.match(zot);if(!e?.groups)throw new Error("Assertion failed: Expected the checksum to match the requested pattern");let r=e.groups.cacheVersion?parseInt(e.groups.cacheVersion):null;return{cacheKey:e.groups.cacheKey??null,cacheVersion:r,cacheSpec:e.groups.cacheSpec??null,hash:e.groups.hash}}var Ade,NG,OG,UR,Kr,zot,LG=Xe(()=>{Ge();Dt();Dt();eA();Ade=Ie("crypto"),NG=ut(Ie("fs"));fde();Tc();I0();Pc();Wo();OG=YE(process.env.YARN_CACHE_CHECKPOINT_OVERRIDE??process.env.YARN_CACHE_VERSION_OVERRIDE??9),UR=YE(process.env.YARN_CACHE_VERSION_OVERRIDE??10),Kr=class t{constructor(e,{configuration:r,immutable:s=r.get("enableImmutableCache"),check:a=!1}){this.markedFiles=new Set;this.mutexes=new Map;this.refCountedZipFsCache=new MR(e=>{e.discardAndClose()});this.cacheId=`-${(0,Ade.randomBytes)(8).toString("hex")}.tmp`;this.configuration=r,this.cwd=e,this.immutable=s,this.check=a;let{cacheSpec:n,cacheKey:c}=t.getCacheKey(r);this.cacheSpec=n,this.cacheKey=c}static async find(e,{immutable:r,check:s}={}){let a=new t(e.get("cacheFolder"),{configuration:e,immutable:r,check:s});return await a.setup(),a}static getCacheKey(e){let r=e.get("compressionLevel"),s=r!=="mixed"?`c${r}`:"";return{cacheKey:[UR,s].join(""),cacheSpec:s}}get mirrorCwd(){if(!this.configuration.get("enableMirror"))return null;let e=`${this.configuration.get("globalFolder")}/cache`;return e!==this.cwd?e:null}getVersionFilename(e){return`${nI(e)}-${this.cacheKey}.zip`}getChecksumFilename(e,r){let a=_v(r).hash.slice(0,10);return`${nI(e)}-${a}.zip`}isChecksumCompatible(e){if(e===null)return!1;let{cacheVersion:r,cacheSpec:s}=_v(e);if(r===null||r<OG)return!1;let a=this.configuration.get("cacheMigrationMode");return!(r<UR&&a==="always"||s!==this.cacheSpec&&a!=="required-only")}getLocatorPath(e,r){return this.mirrorCwd===null?J.resolve(this.cwd,this.getVersionFilename(e)):r===null?J.resolve(this.cwd,this.getVersionFilename(e)):J.resolve(this.cwd,this.getChecksumFilename(e,r))}getLocatorMirrorPath(e){let r=this.mirrorCwd;return r!==null?J.resolve(r,this.getVersionFilename(e)):null}async setup(){if(!this.configuration.get("enableGlobalCache"))if(this.immutable){if(!await ce.existsPromise(this.cwd))throw new jt(56,"Cache path does not exist.")}else{await ce.mkdirPromise(this.cwd,{recursive:!0});let e=J.resolve(this.cwd,".gitignore");await ce.changeFilePromise(e,`/.gitignore
*.flock
*.tmp
`)}(this.mirrorCwd||!this.immutable)&&await ce.mkdirPromise(this.mirrorCwd||this.cwd,{recursive:!0})}async fetchPackageFromCache(e,r,{onHit:s,onMiss:a,loader:n,...c}){let f=this.getLocatorMirrorPath(e),p=new Yn,h=()=>{let pe=new As,Be=J.join(vt.root,x8(e));return pe.mkdirSync(Be,{recursive:!0}),pe.writeJsonSync(J.join(Be,Er.manifest),{name:un(e),mocked:!0}),pe},E=async(pe,{isColdHit:Be,controlPath:Ce=null})=>{if(Ce===null&&c.unstablePackages?.has(e.locatorHash))return{isValid:!0,hash:null};let g=r&&!Be?_v(r).cacheKey:this.cacheKey,we=!c.skipIntegrityCheck||!r?`${g}/${await SQ(pe)}`:r;if(Ce!==null){let Ae=!c.skipIntegrityCheck||!r?`${this.cacheKey}/${await SQ(Ce)}`:r;if(we!==Ae)throw new jt(18,"The remote archive doesn't match the local checksum - has the local cache been corrupted?")}let ye=null;switch(r!==null&&we!==r&&(this.check?ye="throw":_v(r).cacheKey!==_v(we).cacheKey?ye="update":ye=this.configuration.get("checksumBehavior")),ye){case null:case"update":return{isValid:!0,hash:we};case"ignore":return{isValid:!0,hash:r};case"reset":return{isValid:!1,hash:r};default:case"throw":throw new jt(18,"The remote archive doesn't match the expected checksum")}},C=async pe=>{if(!n)throw new Error(`Cache check required but no loader configured for ${Yr(this.configuration,e)}`);let Be=await n(),Ce=Be.getRealPath();Be.saveAndClose(),await ce.chmodPromise(Ce,420);let g=await E(pe,{controlPath:Ce,isColdHit:!1});if(!g.isValid)throw new Error("Assertion failed: Expected a valid checksum");return g.hash},S=async()=>{if(f===null||!await ce.existsPromise(f)){let pe=await n(),Be=pe.getRealPath();return pe.saveAndClose(),{source:"loader",path:Be}}return{source:"mirror",path:f}},P=async()=>{if(!n)throw new Error(`Cache entry required but missing for ${Yr(this.configuration,e)}`);if(this.immutable)throw new jt(56,`Cache entry required but missing for ${Yr(this.configuration,e)}`);let{path:pe,source:Be}=await S(),{hash:Ce}=await E(pe,{isColdHit:!0}),g=this.getLocatorPath(e,Ce),we=[];Be!=="mirror"&&f!==null&&we.push(async()=>{let Ae=`${f}${this.cacheId}`;await ce.copyFilePromise(pe,Ae,NG.default.constants.COPYFILE_FICLONE),await ce.chmodPromise(Ae,420),await ce.renamePromise(Ae,f)}),(!c.mirrorWriteOnly||f===null)&&we.push(async()=>{let Ae=`${g}${this.cacheId}`;await ce.copyFilePromise(pe,Ae,NG.default.constants.COPYFILE_FICLONE),await ce.chmodPromise(Ae,420),await ce.renamePromise(Ae,g)});let ye=c.mirrorWriteOnly?f??g:g;return await Promise.all(we.map(Ae=>Ae())),[!1,ye,Ce]},I=async()=>{let Be=(async()=>{let Ce=c.unstablePackages?.has(e.locatorHash),g=Ce||!r||this.isChecksumCompatible(r)?this.getLocatorPath(e,r):null,we=g!==null?this.markedFiles.has(g)||await p.existsPromise(g):!1,ye=!!c.mockedPackages?.has(e.locatorHash)&&(!this.check||!we),Ae=ye||we,se=Ae?s:a;if(se&&se(),Ae){let Z=null,De=g;if(!ye)if(this.check)Z=await C(De);else{let Re=await E(De,{isColdHit:!1});if(Re.isValid)Z=Re.hash;else return P()}return[ye,De,Z]}else{if(this.immutable&&Ce)throw new jt(56,`Cache entry required but missing for ${Yr(this.configuration,e)}; consider defining ${he.pretty(this.configuration,"supportedArchitectures",he.Type.CODE)} to cache packages for multiple systems`);return P()}})();this.mutexes.set(e.locatorHash,Be);try{return await Be}finally{this.mutexes.delete(e.locatorHash)}};for(let pe;pe=this.mutexes.get(e.locatorHash);)await pe;let[R,N,U]=await I();R||this.markedFiles.add(N);let W=()=>this.refCountedZipFsCache.addOrCreate(N,()=>R?h():new As(N,{baseFs:p,readOnly:!0})),ee,ie=new oE(()=>W4(()=>(ee=W(),ee.value),pe=>`Failed to open the cache entry for ${Yr(this.configuration,e)}: ${pe}`),J),ue=new _f(N,{baseFs:ie,pathUtils:J}),le=()=>{ee?.release()},me=c.unstablePackages?.has(e.locatorHash)?null:U;return[ue,le,me]}},zot=/^(?:(?<cacheKey>(?<cacheVersion>[0-9]+)(?<cacheSpec>.*))\/)?(?<hash>.*)$/});var _R,pde=Xe(()=>{_R=(r=>(r[r.SCRIPT=0]="SCRIPT",r[r.SHELLCODE=1]="SHELLCODE",r))(_R||{})});var Xot,KI,MG=Xe(()=>{Dt();wc();Rp();Wo();Xot=[[/^(git(?:\+(?:https|ssh))?:\/\/.*(?:\.git)?)#(.*)$/,(t,e,r,s)=>`${r}#commit=${s}`],[/^https:\/\/((?:[^/]+?)@)?codeload\.github\.com\/([^/]+\/[^/]+)\/tar\.gz\/([0-9a-f]+)$/,(t,e,r="",s,a)=>`https://${r}github.com/${s}.git#commit=${a}`],[/^https:\/\/((?:[^/]+?)@)?github\.com\/([^/]+\/[^/]+?)(?:\.git)?#([0-9a-f]+)$/,(t,e,r="",s,a)=>`https://${r}github.com/${s}.git#commit=${a}`],[/^https?:\/\/[^/]+\/(?:[^/]+\/)*(?:@.+(?:\/|(?:%2f)))?([^/]+)\/(?:-|download)\/\1-[^/]+\.tgz(?:#|$)/,t=>`npm:${t}`],[/^https:\/\/npm\.pkg\.github\.com\/download\/(?:@[^/]+)\/(?:[^/]+)\/(?:[^/]+)\/(?:[0-9a-f]+)(?:#|$)/,t=>`npm:${t}`],[/^https:\/\/npm\.fontawesome\.com\/(?:@[^/]+)\/([^/]+)\/-\/([^/]+)\/\1-\2.tgz(?:#|$)/,t=>`npm:${t}`],[/^https?:\/\/[^/]+\/.*\/(@[^/]+)\/([^/]+)\/-\/\1\/\2-(?:[.\d\w-]+)\.tgz(?:#|$)/,(t,e)=>kQ({protocol:"npm:",source:null,selector:t,params:{__archiveUrl:e}})],[/^[^/]+\.tgz#[0-9a-f]+$/,t=>`npm:${t}`]],KI=class{constructor(e){this.resolver=e;this.resolutions=null}async setup(e,{report:r}){let s=J.join(e.cwd,Er Line truncated
`)}reportProgress(r){return{...Promise.resolve().then(async()=>{for await(let{}of r);}),stop:()=>{}}}reportJson(r){}reportFold(r,s){}async finalize(){this.errorCount>0&&(this.stdout.write(`
`),this.stdout.write(`${Ht(this.configuration,"\u27A4","redBright")} Errors happened when preparing the environment required to run this command.
`),this.suggestInstall&&this.stdout.write(`${Ht(this.configuration,"\u27A4","redBright")} This might be caused by packages being missing from the lockfile, in which case running "yarn install" might help.
`))}formatNameWithHyperlink(r){return Wj(r,{configuration:this.configuration,json:!1})}}});var zI,UG=Xe(()=>{Wo();zI=class{constructor(e){this.resolver=e}supportsDescriptor(e,r){return!!(r.project.storedResolutions.get(e.descriptorHash)||r.project.originalPackages.has(bQ(e).locatorHash))}supportsLocator(e,r){return!!(r.project.originalPackages.has(e.locatorHash)&&!r.project.lockfileNeedsRefresh)}shouldPersistResolution(e,r){throw new Error("The shouldPersistResolution method shouldn't be called on the lockfile resolver, which would always answer yes")}bindDescriptor(e,r,s){return e}getResolutionDependencies(e,r){return this.resolver.getResolutionDependencies(e,r)}async getCandidates(e,r,s){let a=s.project.storedResolutions.get(e.descriptorHash);if(a){let c=s.project.originalPackages.get(a);if(c)return[c]}let n=s.project.originalPackages.get(bQ(e).locatorHash);if(n)return[n];throw new Error("Resolution expected from the lockfile data")}async getSatisfying(e,r,s,a){let[n]=await this.getCandidates(e,r,a);return{locators:s.filter(c=>c.locatorHash===n.locatorHash),sorted:!1}}async resolve(e,r){let s=r.project.originalPackages.get(e.locatorHash);if(!s)throw new Error("The lockfile resolver isn't meant to resolve packages - they should already have been stored into a cache");return s}}});function Kp(){}function Zot(t,e,r,s,a){for(var n=0,c=e.length,f=0,p=0;n<c;n++){var h=e[n];if(h.removed){if(h.value=t.join(s.slice(p,p+h.count)),p+=h.count,n&&e[n-1].added){var C=e[n-1];e[n-1]=e[n],e[n]=C}}else{if(!h.added&&a){var E=r.slice(f,f+h.count);E=E.map(function(P,I){var R=s[p+I];return R.length>P.length?R:P}),h.value=t.join(E)}else h.value=t.join(r.slice(f,f+h.count));f+=h.count,h.added||(p+=h.count)}}var S=e[c-1];return c>1&&typeof S.value=="string"&&(S.added||S.removed)&&t.equals("",S.value)&&(e[c-2].value+=S.value,e.pop()),e}function $ot(t){return{newPos:t.newPos,components:t.components.slice(0)}}function eat(t,e){if(typeof t=="function")e.callback=t;else if(t)for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r]);return e}function mde(t,e,r){return r=eat(r,{ignoreWhitespace:!0}),qG.diff(t,e,r)}function tat(t,e,r){return WG.diff(t,e,r)}function HR(t){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?HR=function(e){return typeof e}:HR=function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},HR(t)}function _G(t){return iat(t)||sat(t)||oat(t)||aat()}function iat(t){if(Array.isArray(t))return HG(t)}function sat(t){if(typeof Symbol<"u"&&Symbol.iterator in Object(t))return Array.from(t)}function oat(t,e){if(t){if(typeof t=="string")return HG(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);if(r==="Object"&&t.constructor&&(r=t.constructor.name),r==="Map"||r==="Set")return Array.from(t);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return HG(t,e)}}function HG(t,e){(e==null||e>t.length)&&(e=t.length);for(var r=0,s=new Array(e);r<e;r++)s[r]=t[r];return s}function aat(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function jG(t,e,r,s,a){e=e||[],r=r||[],s&&(t=s(a,t));var n;for(n=0;n<e.length;n+=1)if(e[n]===t)return r[n];var c;if(lat.call(t)==="[object Array]"){for(e.push(t),c=new Array(t.length),r.push(c),n=0;n<t.length;n+=1)c[n]=jG(t[n],e,r,s,a);return e.pop(),r.pop(),c}if(t&&t.toJSON&&(t=t.toJSON()),HR(t)==="object"&&t!==null){e.push(t),c={},r.push(c);var f=[],p;for(p in t)t.hasOwnProperty(p)&&f.push(p);for(f.sort(),n=0;n<f.length;n+=1)p=f[n],c[p]=jG(t[p],e,r,s,p);e.pop(),r.pop()}else c=t;return c}function yde(t,e,r,s,a,n,c){c||(c={}),typeof c.context>"u"&&(c.context=4);var f=tat(r,s,c);if(!f)return;f.push({value:"",lines:[]});function p(U){return U.map(function(W){return" "+W})}for(var h=[],E=0,C=0,S=[],P=1,I=1,R=function(W){var ee=f[W],ie=ee.lines||ee.value.replace(/\n$/,"").split(`
`);if(ee.lines=ie,ee.added||ee.removed){var ue;if(!E){var le=f[W-1];E=P,C=I,le&&(S=c.context>0?p(le.lines.slice(-c.context)):[],E-=S.length,C-=S.length)}(ue=S).push.apply(ue,_G(ie.map(function(Ae){return(ee.added?"+":"-")+Ae}))),ee.added?I+=ie.length:P+=ie.length}else{if(E)if(ie.length<=c.context*2&&W<f.length-2){var me;(me=S).push.apply(me,_G(p(ie)))}else{var pe,Be=Math.min(ie.length,c.context);(pe=S).push.apply(pe,_G(p(ie.slice(0,Be))));var Ce={oldStart:E,oldLines:P-E+Be,newStart:C,newLines:I-C+Be,lines:S};if(W>=f.length-2&&ie.length<=c.context){var g=/\n$/.test(r),we=/\n$/.test(s),ye=ie.length==0&&S.length>Ce.oldLines;!g&&ye&&r.length>0&&S.splice(Ce.oldLines,0,"\\ No newline at end of file"),(!g&&!ye||!we)&&S.push("\\ No newline at end of file")}h.push(Ce),E=0,C=0,S=[]}P+=ie.length,I+=ie.length}},N=0;N<f.length;N++)R(N);return{oldFileName:t,newFileName:e,oldHeader:a,newHeader:n,hunks:h}}var y8t,gde,dde,qG,WG,rat,nat,lat,Hv,GG,YG=Xe(()=>{Kp.prototype={diff:function(e,r){var s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},a=s.callback;typeof s=="function"&&(a=s,s={}),this.options=s;var n=this;function c(R){return a?(setTimeout(function(){a(void 0,R)},0),!0):R}e=this.castInput(e),r=this.castInput(r),e=this.removeEmpty(this.tokenize(e)),r=this.removeEmpty(this.tokenize(r));var f=r.length,p=e.length,h=1,E=f+p;s.maxEditLength&&(E=Math.min(E,s.maxEditLength));var C=[{newPos:-1,components:[]}],S=this.extractCommon(C[0],r,e,0);if(C[0].newPos+1>=f&&S+1>=p)return c([{value:this.join(r),count:r.length}]);function P(){for(var R=-1*h;R<=h;R+=2){var N=void 0,U=C[R-1],W=C[R+1],ee=(W?W.newPos:0)-R;U&&(C[R-1]=void 0);var ie=U&&U.newPos+1<f,ue=W&&0<=ee&&ee<p;if(!ie&&!ue){C[R]=void 0;continue}if(!ie||ue&&U.newPos<W.newPos?(N=$ot(W),n.pushComponent(N.components,void 0,!0)):(N=U,N.newPos++,n.pushComponent(N.components,!0,void 0)),ee=n.extractCommon(N,r,e,R),N.newPos+1>=f&&ee+1>=p)return c(Zot(n,N.components,r,e,n.useLongestToken));C[R]=N}h++}if(a)(function R(){setTimeout(function(){if(h>E)return a();P()||R()},0)})();else for(;h<=E;){var I=P();if(I)return I}},pushComponent:function(e,r,s){var a=e[e.length-1];a&&a.added===r&&a.removed===s?e[e.length-1]={count:a.count+1,added:r,removed:s}:e.push({count:1,added:r,removed:s})},extractCommon:function(e,r,s,a){for(var n=r.length,c=s.length,f=e.newPos,p=f-a,h=0;f+1<n&&p+1<c&&this.equals(r[f+1],s[p+1]);)f++,p++,h++;return h&&e.components.push({count:h}),e.newPos=f,p},equals:function(e,r){return this.options.comparator?this.options.comparator(e,r):e===r||this.options.ignoreCase&&e.toLowerCase()===r.toLowerCase()},removeEmpty:function(e){for(var r=[],s=0;s<e.length;s++)e[s]&&r.push(e[s]);return r},castInput:function(e){return e},tokenize:function(e){return e.split("")},join:function(e){return e.join("")}};y8t=new Kp;gde=/^[A-Za-z\xC0-\u02C6\u02C8-\u02D7\u02DE-\u02FF\u1E00-\u1EFF]+$/,dde=/\S/,qG=new Kp;qG.equals=function(t,e){return this.options.ignoreCase&&(t=t.toLowerCase(),e=e.toLowerCase()),t===e||this.options.ignoreWhitespace&&!dde.test(t)&&!dde.test(e)};qG.tokenize=function(t){for(var e=t.split(/([^\S\r\n]+|[()[\]{}'"\r\n]|\b)/),r=0;r<e.length-1;r++)!e[r+1]&&e[r+2]&&gde.test(e[r])&&gde.test(e[r+2])&&(e[r]+=e[r+2],e.splice(r+1,2),r--);return e};WG=new Kp;WG.tokenize=function(t){var e=[],r=t.split(/(\n|\r\n)/);r[r.length-1]||r.pop();for(var s=0;s<r.length;s++){var a=r[s];s%2&&!this.options.newlineIsToken?e[e.length-1]+=a:(this.options.ignoreWhitespace&&(a=a.trim()),e.push(a))}return e};rat=new Kp;rat.tokenize=function(t){return t.split(/(\S.+?[.!?])(?=\s+|$)/)};nat=new Kp;nat.tokenize=function(t){return t.split(/([{}:;,]|\s+)/)};lat=Object.prototype.toString,Hv=new Kp;Hv.useLongestToken=!0;Hv.tokenize=WG.tokenize;Hv.castInput=function(t){var e=this.options,r=e.undefinedReplacement,s=e.stringifyReplacer,a=s===void 0?function(n,c){return typeof c>"u"?r:c}:s;return typeof t=="string"?t:JSON.stringify(jG(t,null,null,a),a," ")};Hv.equals=function(t,e){return Kp.prototype.equals.call(Hv,t.replace(/,([\r\n])/g,"$1"),e.replace(/,([\r\n])/g,"$1"))};GG=new Kp;GG.tokenize=function(t){return t.slice()};GG.join=GG.removeEmpty=function(t){return t}});var jR,Ede=Xe(()=>{Tc();jR=class{constructor(e){this.resolver=e}supportsDescriptor(e,r){return this.resolver.supportsDescriptor(e,r)}supportsLocator(e,r){return this.resolver.supportsLocator(e,r)}shouldPersistResolution(e,r){return this.resolver.shouldPersistResolution(e,r)}bindDescriptor(e,r,s){return this.resolver.bindDescriptor(e,r,s)}getResolutionDependencies(e,r){return this.resolver.getResolutionDependencies(e,r)}async getCandidates(e,r,s){throw new jt(20,`This package doesn't seem to be present in your lockfile; run "yarn install" to update the lockfile`)}async getSatisfying(e,r,s,a){throw new jt(20,`This package doesn't seem to be present in your lockfile; run "yarn install" to update the lockfile`)}async resolve(e,r){throw new jt(20,`This package doesn't seem to be present in your lockfile; run "yarn install" to update the lockfLine truncated
`;await ce.changeFilePromise(r,s,{automaticNewlines:!0}),this.manifest.raw=e}}});function hat({project:t,allDescriptors:e,allResolutions:r,allPackages:s,accessibleLocators:a=new Set,optionalBuilds:n=new Set,peerRequirements:c=new Map,peerWarnings:f=[],peerRequirementNodes:p=new Map,volatileDescriptors:h=new Set}){let E=new Map,C=[],S=new Map,P=new Map,I=new Map,R=new Map,N=new Map,U=new Map(t.workspaces.map(le=>{let me=le.anchoredLocator.locatorHash,pe=s.get(me);if(typeof pe>"u")throw new Error("Assertion failed: The workspace should have an associated package");return[me,LB(pe)]})),W=()=>{let le=ce.mktempSync(),me=J.join(le,"stacktrace.log"),pe=String(C.length+1).length,Be=C.map((Ce,g)=>`${`${g+1}.`.padStart(pe," ")} ${ll(Ce)}
`).join("");throw ce.writeFileSync(me,Be),ce.detachTemp(le),new jt(45,`Encountered a stack overflow when resolving peer dependencies; cf ${fe.fromPortablePath(me)}`)},ee=le=>{let me=r.get(le.descriptorHash);if(typeof me>"u")throw new Error("Assertion failed: The resolution should have been registered");let pe=s.get(me);if(!pe)throw new Error("Assertion failed: The package could not be found");return pe},ie=(le,me,pe,{top:Be,optional:Ce})=>{C.length>1e3&&W(),C.push(me);let g=ue(le,me,pe,{top:Be,optional:Ce});return C.pop(),g},ue=(le,me,pe,{top:Be,optional:Ce})=>{if(Ce||n.delete(me.locatorHash),a.has(me.locatorHash))return;a.add(me.locatorHash);let g=s.get(me.locatorHash);if(!g)throw new Error(`Assertion failed: The package (${Yr(t.configuration,me)}) should have been registered`);let we=new Set,ye=new Map,Ae=[],se=[],Z=[],De=[];for(let Re of Array.from(g.dependencies.values())){if(g.peerDependencies.has(Re.identHash)&&g.locatorHash!==Be)continue;if(kp(Re))throw new Error("Assertion failed: Virtual packages shouldn't be encountered when virtualizing a branch");h.delete(Re.descriptorHash);let mt=Ce;if(!mt){let ke=g.dependenciesMeta.get(un(Re));if(typeof ke<"u"){let it=ke.get(null);typeof it<"u"&&it.optional&&(mt=!0)}}let j=r.get(Re.descriptorHash);if(!j)throw new Error(`Assertion failed: The resolution (${ni(t.configuration,Re)}) should have been registered`);let rt=U.get(j)||s.get(j);if(!rt)throw new Error(`Assertion failed: The package (${j}, resolved from ${ni(t.configuration,Re)}) should have been registered`);if(rt.peerDependencies.size===0){ie(Re,rt,new Map,{top:Be,optional:mt});continue}let Fe,Ne,Pe=new Set,Ve=new Map;Ae.push(()=>{Fe=b8(Re,me.locatorHash),Ne=P8(rt,me.locatorHash),g.dependencies.set(Re.identHash,Fe),r.set(Fe.descriptorHash,Ne.locatorHash),e.set(Fe.descriptorHash,Fe),s.set(Ne.locatorHash,Ne),bp(R,Ne.locatorHash).add(Fe.descriptorHash),we.add(Ne.locatorHash)}),se.push(()=>{N.set(Ne.locatorHash,Ve);for(let ke of Ne.peerDependencies.values()){let Ue=Yl(ye,ke.identHash,()=>{let x=pe.get(ke.identHash)??null,w=g.dependencies.get(ke.identHash);return!w&&UB(me,ke)&&(le.identHash===me.identHash?w=le:(w=On(me,le.range),e.set(w.descriptorHash,w),r.set(w.descriptorHash,me.locatorHash),h.delete(w.descriptorHash),x=null)),w||(w=On(ke,"missing:")),{subject:me,ident:ke,provided:w,root:!x,requests:new Map,hash:`p${us(me.locatorHash,ke.identHash).slice(0,6)}`}}).provided;if(Ue.range==="missing:"&&Ne.dependencies.has(ke.identHash)){Ne.peerDependencies.delete(ke.identHash);continue}if(Ve.set(ke.identHash,{requester:Ne,descriptor:ke,meta:Ne.peerDependenciesMeta.get(un(ke)),children:new Map}),Ne.dependencies.set(ke.identHash,Ue),kp(Ue)){let x=r.get(Ue.descriptorHash);bp(I,x).add(Ne.locatorHash)}S.set(Ue.identHash,Ue),Ue.range==="missing:"&&Pe.add(Ue.identHash)}Ne.dependencies=new Map(qs(Ne.dependencies,([ke,it])=>un(it)))}),Z.push(()=>{if(!s.has(Ne.locatorHash))return;let ke=E.get(rt.locatorHash);typeof ke=="number"&&ke>=2&&W();let it=E.get(rt.locatorHash),Ue=typeof it<"u"?it+1:1;E.set(rt.locatorHash,Ue),ie(Fe,Ne,Ve,{top:Be,optional:mt}),E.set(rt.locatorHash,Ue-1)}),De.push(()=>{let ke=r.get(Fe.descriptorHash);if(typeof ke>"u")throw new Error("Assertion failed: Expected the descriptor to be registered");let it=N.get(ke);if(typeof it>"u")throw new Error("Assertion failed: Expected the peer requests to be registered");for(let Ue of ye.values()){let x=it.get(Ue.ident.identHash);x&&(Ue.requests.set(Fe.descriptorHash,x),p.set(Ue.hash,Ue),Ue.root||pe.get(Ue.ident.identHash)?.children.set(Fe.descriptorHash,x))}if(s.has(Ne.locatorHash))for(let Ue of Pe)Ne.dependencies.delete(Ue)})}for(let Re of[...Ae,...se])Re();for(let Re of we){we.delete(Re);let mt=s.get(Re),j=us(rI(mt).locatorHash,...Array.from(mt.dependencies.values(),Pe=>{let Ve=Pe.range!=="missing:"?r.get(Pe.descriptorHash):"missing:";if(typeof Ve>"u")throw new Error(`Assertion failed: Expected the resolution for ${ni(t.configuration,Pe)} to have been registered`);return Ve===Be?`${Ve} (top)`:Ve})),rt=P.get(j);if(typeof rt>"u"){P.set(j,mt);continue}let Fe=bp(R,rt.locatorHash);for(let Pe of R.get(mt.locatorHash)??[])r.set(Pe,rt.locatorHash),Fe.add(Pe);s.delete(mt.locatorHash),a.delete(mt.locatorHash),we.delete(mt.locatorHash);let Ne=I.get(mt.locatorHash);if(Ne!==void 0){let Pe=bp(I,rt.locatorHash);for(let Ve of Ne)Pe.add(Ve),we.add(Ve)}}for(let Re of[...Z,...De])Re()};for(let le of t.workspaces){let me=le.anchoredLocator;h.delete(le.anchoredDescriptor.descriptorHash),ie(le.anchoredDescriptor,me,new Map,{top:me.locatorHash,optional:!1})}for(let le of p.values()){if(!le.root)continue;let me=s.get(le.subject.locatorHash);if(typeof me>"u")continue;for(let Be of le.requests.values()){let Ce=`p${us(le.subject.locatorHash,un(le.ident),Be.requester.locatorHash).slice(0,6)}`;c.set(Ce,{subject:le.subject.locatorHash,requested:le.ident,rootRequester:Be.requester.locatorHash,allRequesters:Array.from(qB(Be),g=>g.requester.locatorHash)})}let pe=[...qB(le)];if(le.provided.rang Line truncated
${[C,S,P].join(`
`)}`)}async setupResolutions(){this.storedResolutions=new Map,this.storedDescriptors=new Map,this.storedPackages=new Map,this.lockFileChecksum=null;let e=J.join(this.cwd,Er.lockfile),r=this.configuration.get("defaultLanguageName");if(ce.existsSync(e)){let s=await ce.readFilePromise(e,"utf8");this.lockFileChecksum=wde(s);let a=ls(s);if(a.__metadata){let n=a.__metadata.version,c=a.__metadata.cacheKey;this.lockfileLastVersion=n,this.lockfileNeedsRefresh=n<WR;for(let f of Object.keys(a)){if(f==="__metadata")continue;let p=a[f];if(typeof p.resolution>"u")throw new Error(`Assertion failed: Expected the lockfile entry to have a resolution field (${f})`);let h=Qp(p.resolution,!0),E=new Ut;E.load(p,{yamlCompatibilityMode:!0});let C=E.version,S=E.languageName||r,P=p.linkType.toUpperCase(),I=p.conditions??null,R=E.dependencies,N=E.peerDependencies,U=E.dependenciesMeta,W=E.peerDependenciesMeta,ee=E.bin;if(p.checksum!=null){let ue=typeof c<"u"&&!p.checksum.includes("/")?`${c}/${p.checksum}`:p.checksum;this.storedChecksums.set(h.locatorHash,ue)}let ie={...h,version:C,languageName:S,linkType:P,conditions:I,dependencies:R,peerDependencies:N,dependenciesMeta:U,peerDependenciesMeta:W,bin:ee};this.originalPackages.set(ie.locatorHash,ie);for(let ue of f.split(uat)){let le=C0(ue);n<=6&&(le=this.configuration.normalizeDependency(le),le=On(le,le.range.replace(/^patch:[^@]+@(?!npm(:|%3A))/,"$1npm%3A"))),this.storedDescriptors.set(le.descriptorHash,le),this.storedResolutions.set(le.descriptorHash,h.locatorHash)}}}else s.includes("yarn lockfile v1")&&(this.lockfileLastVersion=-1)}}async setupWorkspaces(){this.workspaces=[],this.workspacesByCwd=new Map,this.workspacesByIdent=new Map;let e=new Set,r=(0,qR.default)(4),s=async(a,n)=>{if(e.has(n))return a;e.add(n);let c=new XI(n,{project:this});await r(()=>c.setup());let f=a.then(()=>{this.addWorkspace(c)});return Array.from(c.workspacesCwds).reduce(s,f)};await s(Promise.resolve(),this.cwd)}addWorkspace(e){let r=this.workspacesByIdent.get(e.anchoredLocator.identHash);if(typeof r<"u")throw new Error(`Duplicate workspace name ${$i(this.configuration,e.anchoredLocator)}: ${fe.fromPortablePath(e.cwd)} conflicts with ${fe.fromPortablePath(r.cwd)}`);this.workspaces.push(e),this.workspacesByCwd.set(e.cwd,e),this.workspacesByIdent.set(e.anchoredLocator.identHash,e)}get topLevelWorkspace(){return this.getWorkspaceByCwd(this.cwd)}tryWorkspaceByCwd(e){J.isAbsolute(e)||(e=J.resolve(this.cwd,e)),e=J.normalize(e).replace(/\/+$/,"");let r=this.workspacesByCwd.get(e);return r||null}getWorkspaceByCwd(e){let r=this.tryWorkspaceByCwd(e);if(!r)throw new Error(`Workspace not found (${e})`);return r}tryWorkspaceByFilePath(e){let r=null;for(let s of this.workspaces)J.relative(s.cwd,e).startsWith("../")||r&&r.cwd.length>=s.cwd.length||(r=s);return r||null}getWorkspaceByFilePath(e){let r=this.tryWorkspaceByFilePath(e);if(!r)throw new Error(`Workspace not found (${e})`);return r}tryWorkspaceByIdent(e){let r=this.workspacesByIdent.get(e.identHash);return typeof r>"u"?null:r}getWorkspaceByIdent(e){let r=this.tryWorkspaceByIdent(e);if(!r)throw new Error(`Workspace not found (${$i(this.configuration,e)})`);return r}tryWorkspaceByDescriptor(e){if(e.range.startsWith(Ei.protocol)){let s=e.range.slice(Ei.protocol.length);if(s!=="^"&&s!=="~"&&s!=="*"&&!cl(s))return this.tryWorkspaceByCwd(s)}let r=this.tryWorkspaceByIdent(e);return r===null||(kp(e)&&(e=MB(e)),!r.accepts(e.range))?null:r}getWorkspaceByDescriptor(e){let r=this.tryWorkspaceByDescriptor(e);if(r===null)throw new Error(`Workspace not found (${ni(this.configuration,e)})`);return r}tryWorkspaceByLocator(e){let r=this.tryWorkspaceByIdent(e);return r===null||(Gu(e)&&(e=rI(e)),r.anchoredLocator.locatorHash!==e.locatorHash)?null:r}getWorkspaceByLocator(e){let r=this.tryWorkspaceByLocator(e);if(!r)throw new Error(`Workspace not found (${Yr(this.configuration,e)})`);return r}deleteDescriptor(e){this.storedResolutions.delete(e),this.storedDescriptors.delete(e)}deleteLocator(e){this.originalPackages.delete(e),this.storedPackages.delete(e),this.accessibleLocators.delete(e)}forgetResolution(e){if("descriptorHash"in e){let r=this.storedResolutions.get(e.descriptorHash);this.deleteDescriptor(e.descriptorHash);let s=new Set(this.storedResolutions.values());typeof r<"u"&&!s.has(r)&&this.deleteLocator(r)}if("locatorHash"in e){this.deleteLocator(e.locatorHash);for(let[r,s]of this.storedResolutions)s===e.locatorHash&&this.deleteDescriptor(r)}}forgetTransientResolutions(){let e=this.configuration.makeResolver(),r=new Map;for(let[s,a]of this.storedResolutions.entries()){let n=r.get(a);n||r.set(a,n=new Set),n.add(s)}for(let s of this.originalPackages.values()){let a;try{a=e.shouldPersistResolution(s,{project:this,resolver:e})}catch{a=!1}if(!a){this.deleteLocator(s.locatorHash);let n=r.get(s.locatorHash);if(n){r.delete(s.locatorHash);for(let c of n)this.deleteDescriptor(c)}}}}forgetVirtualResolutions(){for(let e of this.storedPackages.values())for(let[r,s]of e.dependencies)kp(s)&&e.dLine truncated
`;switch(rt.type){case 0:Fe+=`# Script name: ${rt.script}
`;break;case 1:Fe+=`# Script code: ${rt.script}
`;break}let Ne=null;if(!await ce.mktempPromise(async Ve=>{let ke=J.join(Ve,"build.log"),{stdout:it,stderr:Ue}=this.configuration.getSubprocessStreams(ke,{header:Fe,prefix:Yr(this.configuration,Z),report:r}),x;try{switch(rt.type){case 0:x=await LT(Z,rt.script,[],{cwd:j,project:this,stdin:Ne,stdout:it,stderr:Ue});break;case 1:x=await Yj(Z,rt.script,[],{cwd:j,project:this,stdin:Ne,stdout:it,stderr:Ue});break}}catch(y){Ue.write(y.stack),x=1}if(it.end(),Ue.end(),x===0)return!0;ce.detachTemp(Ve);let w=`${Yr(this.configuration,Z)} couldn't be built successfully (exit code ${Ht(this.configuration,x,ht.NUMBER)}, logs can be found here: ${Ht(this.configuration,ke,ht.PATH)})`,b=this.optionalBuilds.has(Z.locatorHash);return b?r.reportInfo(9,w):r.reportError(9,w),ehe&&r.reportFold(fe.fromPortablePath(ke),ce.readFileSync(ke,"utf8")),b}))return!1}return!0});Ae.push(...mt,Promise.allSettled(mt).then(j=>{ie.delete(se),j.every(rt=>rt.status==="fulfilled"&&rt.value===!0)&&Ce.set(Z.locatorHash,Re)}))}if(await Uu(Ae),ye===ie.size){let se=Array.from(ie).map(Z=>{let De=this.storedPackages.get(Z);if(!De)throw new Error("Assertion failed: The package should have been registered");return Yr(this.configuration,De)}).join(", ");r.reportError(3,`Some packages have circular dependencies that make their build order unsatisfiable - as a result they won't be built (affected packages are: ${se})`);break}}this.storedBuildState=Ce,this.skippedBuilds=N}async installWithNewReport(e,r){return(await Ot.start({configuration:this.configuration,json:e.json,stdout:e.stdout,forceSectionAlignment:!0,includeLogs:!e.json&&!e.quiet,includeVersion:!0},async a=>{await this.install({...r,report:a})})).exitCode()}async install(e){let r=this.configuration.get("nodeLinker");ze.telemetry?.reportInstall(r);let s=!1;if(await e.report.startTimerPromise("Project validation",{skipIfEmpty:!0},async()=>{this.configuration.get("enableOfflineMode")&&e.report.reportWarning(90,"Offline work is enabled; Yarn won't fetch packages from the remote registry if it can avoid it"),await this.configuration.triggerHook(E=>E.validateProject,this,{reportWarning:(E,C)=>{e.report.reportWarning(E,C)},reportError:(E,C)=>{e.report.reportError(E,C),s=!0}})}),s)return;let a=await this.configuration.getPackageExtensions();for(let E of a.values())for(let[,C]of E)for(let S of C)S.status="inactive";let n=J.join(this.cwd,Er.lockfile),c=null;if(e.immutable)try{c=await ce.readFilePromise(n,"utf8")}catch(E){throw E.code==="ENOENT"?new jt(28,"The lockfile would have been created by this install, which is explicitly forbidden."):E}await e.report.startTimerPromise("Resolution step",async()=>{await this.resolveEverything(e)}),await e.report.startTimerPromise("Post-resolution validation",{skipIfEmpty:!0},async()=>{dat(this,e.report);for(let[,E]of a)for(let[,C]of E)for(let S of C)if(S.userProvided){let P=Ht(this.configuration,S,ht.PACKAGE_EXTENSION);switch(S.status){case"inactive":e.report.reportWarning(68,`${P}: No matching package in the dependency tree; you may not need this rule anymore.`);break;case"redundant":e.report.reportWarning(69,`${P}: This rule seems redundant when applied on the original package; the extension may have been applied upstream.`);break}}if(c!==null){let E=Ed(c,this.generateLockfile());if(E!==c){let C=yde(n,n,c,E,void 0,void 0,{maxEditLength:100});if(C){e.report.reportSeparator();for(let S of C.hunks){e.report.reportInfo(null,`@@ -${S.oldStart},${S.oldLines} +${S.newStart},${S.newLines} @@`);for(let P of S.lines)P.startsWith("+")?e.report.reportError(28,Ht(this.configuration,P,ht.ADDED)):P.startsWith("-")?e.report.reportError(28,Ht(this.configuration,P,ht.REMOVED)):e.report.reportInfo(null,Ht(this.configuration,P,"grey"))}e.report.reportSeparator()}throw new jt(28,"The lockfile would have been modified by this install, which is explicitly forbidden.")}}});for(let E of a.values())for(let[,C]of E)for(let S of C)S.userProvided&&S.status==="active"&&ze.telemetry?.reportPackageExtension(Xd(S,ht.PACKAGE_EXTENSION));await e.report.startTimerPromise("Fetch step",async()=>{await this.fetchEverything(e)});let f=e.immutable?[...new Set(this.configuration.get("immutablePatterns"))].sort():[],p=await Promise.all(f.map(async E=>DQ(E,{cwd:this.cwd})));(typeof e.persistProject>"u"||e.persistProject)&&await this.persist(),await e.report.startTimerPromise("Link step",async()=>{if(e.mode==="update-lockfile"){e.report.reportWarning(73,`Skipped due to ${Ht(this.configuration,"mode=update-lockfile",ht.CODE)}`);return}await this.linkEverything(e);let E=await Promise.all(f.map(async C=>DQ(C,{cwd:this.cwd})));for(let C=0;C<f.length;++C)p[C]!==E[C]&&e.report.reportError(64,`The checksum for ${f[C]} has been modified by this install, which is explicitly forbidden.`)}),await this.persistInstallStateFile();let h=!1;await e.report.startTimerPromise("Post-install validation",{skipIfEmpty:!0},async()=>{await this.configuration.triggerHook(E=>E.validateProjectAfterInstall,this,{reportWarning:(E,C)=>{e.report.r Line truncated
`,`# Manual changes might be lost - proceed with caution!
`].join("")}
`+nl(r)}async persistLockfile(){let e=J.join(this.cwd,Er.lockfile),r="";try{r=await ce.readFilePromise(e,"utf8")}catch{}let s=this.generateLockfile(),a=Ed(r,s);a!==r&&(await ce.writeFilePromise(e,a),this.lockFileChecksum=wde(a),this.lockfileNeedsRefresh=!1)}async persistInstallStateFile(){let e=[];for(let c of Object.values(KG))e.push(...c);let r=Kd(this,e),s=zG.default.serialize(r),a=us(s);if(this.installStateChecksum===a)return;let n=this.configuration.get("installStatePath");await ce.mkdirPromise(J.dirname(n),{recursive:!0}),await ce.writeFilePromise(n,await Aat(s)),this.installStateChecksum=a}async restoreInstallState({restoreLinkersCustomData:e=!0,restoreResolutions:r=!0,restoreBuildState:s=!0}={}){let a=this.configuration.get("installStatePath"),n;try{let c=await pat(await ce.readFilePromise(a));n=zG.default.deserialize(c),this.installStateChecksum=us(c)}catch{r&&await this.applyLightResolution();return}e&&typeof n.linkersCustomData<"u"&&(this.linkersCustomData=n.linkersCustomData),s&&Object.assign(this,Kd(n,KG.restoreBuildState)),r&&(n.lockFileChecksum===this.lockFileChecksum?Object.assign(this,Kd(n,KG.restoreResolutions)):await this.applyLightResolution())}async applyLightResolution(){await this.resolveEverything({lockfileOnly:!0,report:new ki}),await this.persistInstallStateFile()}async persist(){let e=(0,qR.default)(4);await Promise.all([this.persistLockfile(),...this.workspaces.map(r=>e(()=>r.persistManifest()))])}async cacheCleanup({cache:e,report:r}){if(this.configuration.get("enableGlobalCache"))return null;let s=new Set([".gitignore"]);if(!q8(e.cwd,this.cwd)||!await ce.existsPromise(e.cwd))return null;let a=[];for(let c of await ce.readdirPromise(e.cwd)){if(s.has(c))continue;let f=J.resolve(e.cwd,c);e.markedFiles.has(f)||(e.immutable?r.reportError(56,`${Ht(this.configuration,J.basename(f),"magenta")} appears to be unused and would be marked for deletion, but the cache is immutable`):a.push(ce.lstatPromise(f).then(async p=>(await ce.removePromise(f),p.size))))}if(a.length===0)return null;let n=await Promise.all(a);return{count:a.length,size:n.reduce((c,f)=>c+f,0)}}}});function mat(t){let s=Math.floor(t.timeNow/864e5),a=t.updateInterval*864e5,n=t.state.lastUpdate??t.timeNow+a+Math.floor(a*t.randomInitialInterval),c=n+a,f=t.state.lastTips??s*864e5,p=f+864e5+8*36e5-t.timeZone,h=c<=t.timeNow,E=p<=t.timeNow,C=null;return(h||E||!t.state.lastUpdate||!t.state.lastTips)&&(C={},C.lastUpdate=h?t.timeNow:n,C.lastTips=f,C.blocks=h?{}:t.state.blocks,C.displayedTips=t.state.displayedTips),{nextState:C,triggerUpdate:h,triggerTips:E,nextTips:E?s*864e5:f}}var ZI,Sde=Xe(()=>{Dt();yv();I0();pT();Pc();Rp();ZI=class{constructor(e,r){this.values=new Map;this.hits=new Map;this.enumerators=new Map;this.nextTips=0;this.displayedTips=[];this.shouldCommitTips=!1;this.configuration=e;let s=this.getRegistryPath();this.isNew=!ce.existsSync(s),this.shouldShowTips=!1,this.sendReport(r),this.startBuffer()}commitTips(){this.shouldShowTips&&(this.shouldCommitTips=!0)}selectTip(e){let r=new Set(this.displayedTips),s=f=>f&&fn?Zf(fn,f):!1,a=e.map((f,p)=>p).filter(f=>e[f]&&s(e[f]?.selector));if(a.length===0)return null;let n=a.filter(f=>!r.has(f));if(n.length===0){let f=Math.floor(a.length*.2);this.displayedTips=f>0?this.displayedTips.slice(-f):[],n=a.filter(p=>!r.has(p))}let c=n[Math.floor(Math.random()*n.length)];return this.displayedTips.push(c),this.commitTips(),e[c]}reportVersion(e){this.reportValue("version",e.replace(/-git\..*/,"-git"))}reportCommandName(e){this.reportValue("commandName",e||"<none>")}reportPluginName(e){this.reportValue("pluginName",e)}reportProject(e){this.reportEnumerator("projectCount",e)}reportInstall(e){this.reportHit("installCount",e)}reportPackageExtension(e){this.reportValue("packageExtension",e)}reportWorkspaceCount(e){this.reportValue("workspaceCount",String(e))}reportDependencyCount(e){this.reportValue("dependencyCount",String(e))}reportValue(e,r){bp(this.values,e).add(r)}reportEnumerator(e,r){bp(this.enumerators,e).add(us(r))}reportHit(e,r="*"){let s=q4(this.hits,e),a=Yl(s,r,()=>0);s.set(r,a+1)}getRegistryPath(){let e=this.configuration.get("globalFolder");return J.join(e,"telemetry.json")}sendReport(e){let r=this.getRegistryPath(),s;try{s=ce.readJsonSync(r)}catch{s={}}let{nextState:a,triggerUpdate:n,triggerTips:c,nextTips:f}=mat({state:s,timeNow:Date.now(),timeZone:new Date().getTimezoneOffset()*60*1e3,randomInitialInterval:Math.random(),updateInterval:this.configuration.get("telemetryInterval")});if(this.nextTips=f,this.displayedTips=s.displayedTips??[],a!==null)try{ce.mkdirSync(J.dirname(r),{recursive:!0}),ce.writeJsonSync(r,a)}catch{return!1}if(c&&this.configuration.get("enableTips")&&(this.shouldShowTips=!0),n){let p=s.blocks??{};if(Object.keys(p).length===0){let h=`https://browser-http-intake.logs.datadoghq.eu/v1/input/${e}?ddsource=yarn`,E=C=>cj(h,C,{configuration:this.configuration}).catch(()=>{});for(let[C,S]of Object.entries(s.blocks??{})){if(Object.keys(S).length===0)continue;let P=S;P Line truncated
`),h=c.length;for(h>0&&c.includes("unstyle")&&(c=[...new Set(["unstyle",...c])].reverse());h-- >0;)f=r(t.styles[c[h]],f,p);return f},a=(n,c,f)=>{t.styles[n]=e({name:n,codes:c}),(t.keys[f]||(t.keys[f]=[])).push(n),Reflect.defineProperty(t,n,{configurable:!0,enumerable:!0,set(h){t.alias(n,h)},get(){let h=E=>s(E,h.stack);return Reflect.setPrototypeOf(h,t),h.stack=this.stack?this.stack.concat(n):[n],h}})};return a("reset",[0,0],"modifier"),a("bold",[1,22],"modifier"),a("dim",[2,22],"modifier"),a("italic",[3,23],"modifier"),a("underline",[4,24],"modifier"),a("inverse",[7,27],"modifier"),a("hidden",[8,28],"modifier"),a("strikethrough",[9,29],"modifier"),a("black",[30,39],"color"),a("red",[31,39],"color"),a("green",[32,39],"color"),a("yellow",[33,39],"color"),a("blue",[34,39],"color"),a("magenta",[35,39],"color"),a("cyan",[36,39],"color"),a("white",[37,39],"color"),a("gray",[90,39],"color"),a("grey",[90,39],"color"),a("bgBlack",[40,49],"bg"),a("bgRed",[41,49],"bg"),a("bgGreen",[42,49],"bg"),a("bgYellow",[43,49],"bg"),a("bgBlue",[44,49],"bg"),a("bgMagenta",[45,49],"bg"),a("bgCyan",[46,49],"bg"),a("bgWhite",[47,49],"bg"),a("blackBright",[90,39],"bright"),a("redBright",[91,39],"bright"),a("greenBright",[92,39],"bright"),a("yellowBright",[93,39],"bright"),a("blueBright",[94,39],"bright"),a("magentaBright",[95,39],"bright"),a("cyanBright",[96,39],"bright"),a("whiteBright",[97,39],"bright"),a("bgBlackBright",[100,49],"bgBright"),a("bgRedBright",[101,49],"bgBright"),a("bgGreenBright",[102,49],"bgBright"),a("bgYellowBright",[103,49],"bgBright"),a("bgBlueBright",[104,49],"bgBright"),a("bgMagentaBright",[105,49],"bgBright"),a("bgCyanBright",[106,49],"bgBright"),a("bgWhiteBright",[107,49],"bgBright"),t.ansiRegex=wat,t.hasColor=t.hasAnsi=n=>(t.ansiRegex.lastIndex=0,typeof n=="string"&&n!==""&&t.ansiRegex.test(n)),t.alias=(n,c)=>{let f=typeof c=="string"?t[c]:c;if(typeof f!="function")throw new TypeError("Expected alias to be the name of an existing color (string) or a function");f.stack||(Reflect.defineProperty(f,"name",{value:n}),t.styles[n]=f,f.stack=[n]),Reflect.defineProperty(t,n,{configurable:!0,enumerable:!0,set(p){t.alias(n,p)},get(){let p=h=>s(h,p.stack);return Reflect.setPrototypeOf(p,t),p.stack=this.stack?this.stack.concat(f.stack):f.stack,p}})},t.theme=n=>{if(!Cat(n))throw new TypeError("Expected theme to be an object");for(let c of Object.keys(n))t.alias(c,n[c]);return t},t.alias("unstyle",n=>typeof n=="string"&&n!==""?(t.ansiRegex.lastIndex=0,n.replace(t.ansiRegex,"")):""),t.alias("noop",n=>n),t.none=t.clear=t.noop,t.stripColor=t.unstyle,t.symbols=Qde(),t.define=a,t};e5.exports=Tde();e5.exports.create=Tde});var Zo=_(pn=>{"use strict";var Bat=Object.prototype.toString,jc=Ju(),Rde=!1,t5=[],Fde={yellow:"blue",cyan:"red",green:"magenta",black:"white",blue:"yellow",red:"cyan",magenta:"green",white:"black"};pn.longest=(t,e)=>t.reduce((r,s)=>Math.max(r,e?s[e].length:s.length),0);pn.hasColor=t=>!!t&&jc.hasColor(t);var JR=pn.isObject=t=>t!==null&&typeof t=="object"&&!Array.isArray(t);pn.nativeType=t=>Bat.call(t).slice(8,-1).toLowerCase().replace(/\s/g,"");pn.isAsyncFn=t=>pn.nativeType(t)==="asyncfunction";pn.isPrimitive=t=>t!=null&&typeof t!="object"&&typeof t!="function";pn.resolve=(t,e,...r)=>typeof e=="function"?e.call(t,...r):e;pn.scrollDown=(t=[])=>[...t.slice(1),t[0]];pn.scrollUp=(t=[])=>[t.pop(),...t];pn.reorder=(t=[])=>{let e=t.slice();return e.sort((r,s)=>r.index>s.index?1:r.index<s.index?-1:0),e};pn.swap=(t,e,r)=>{let s=t.length,a=r===s?0:r<0?s-1:r,n=t[e];t[e]=t[a],t[a]=n};pn.width=(t,e=80)=>{let r=t&&t.columns?t.columns:e;return t&&typeof t.getWindowSize=="function"&&(r=t.getWindowSize()[0]),process.platform==="win32"?r-1:r};pn.height=(t,e=20)=>{let r=t&&t.rows?t.rows:e;return t&&typeof t.getWindowSize=="function"&&(r=t.getWindowSize()[1]),r};pn.wordWrap=(t,e={})=>{if(!t)return t;typeof e=="number"&&(e={width:e});let{indent:r="",newline:s=`
`+r,width:a=80}=e,n=(s+r).match(/[^\S\n]/g)||[];a-=n.length;let c=`.{1,${a}}([\\s\\u200B]+|$)|[^\\s\\u200B]+?([\\s\\u200B]+|$)`,f=t.trim(),p=new RegExp(c,"g"),h=f.match(p)||[];return h=h.map(E=>E.replace(/\n$/,"")),e.padEnd&&(h=h.map(E=>E.padEnd(a," "))),e.padStart&&(h=h.map(E=>E.padStart(a," "))),r+h.join(s)};pn.unmute=t=>{let e=t.stack.find(s=>jc.keys.color.includes(s));return e?jc[e]:t.stack.find(s=>s.slice(2)==="bg")?jc[e.slice(2)]:s=>s};pn.pascal=t=>t?t[0].toUpperCase()+t.slice(1):"";pn.inverse=t=>{if(!t||!t.stack)return t;let e=t.stack.find(s=>jc.keys.color.includes(s));if(e){let s=jc["bg"+pn.pascal(e)];return s?s.black:t}let r=t.stack.find(s=>s.slice(0,2)==="bg");return r?jc[r.slice(2).toLowerCase()]||t:jc.none};pn.complement=t=>{if(!t||!t.stack)return t;let e=t.stack.find(s=>jc.keys.color.includes(s)),r=t.stack.find(s=>s.slice(0,2)==="bg");if(e&&!r)return jc[Fde[e]||e];if(r){let s=r.slice(2).toLowerCase(),a=Fde[s];return a&&jc["bg"+pn.pascal(a)]||t}return jc.none};pn.meridiem=t=>{let e=t.getHours(),r=t.getMinutes(),s=e>=12?"pm":"am";e=e%12;let a=e===0?12:e,n=r<10?"0"+r:r;return a+":"+n+" "+s};pn.set=(t={},e="",r)=>e.split(".").reduce((s,a,n,c)=>{let f=c.length-1>n?s[a]||{}:r;return!pn.isObject(f)&&n<c.length-1&&(f={}),s[a]=f},t);pn.get=(t={},e="",r)=>{let s=t[e]==null?e.split(".").reduce((a,n)=>a&&a[n],t):t[e];return s??r};pn.mixin=(t,e)=>{if(!JR(t))return e;if(!JR(e))return t;for(let r of Object.keys(e)){let s=Object.getOwnPropertyDescriptor(e,r);if(s.hasOwnProperty("value"))if(t.hasOwnProperty(r)&&JR(s.value)){let a=Object.getOwnPropertyDescriptor(t,r);JR(a.value)?t[r]=pn.merge({},t[r],e[r]):Reflect.defineProperty(t,r,s)}else Reflect.defineProperty(t,r,s);else Reflect.defineProperty(t,r,s)}return t};pn.merge=(...t)=>{let e={};for(let r of t)pn.mixin(e,r);return e};pn.mixinEmitter=(t,e)=>{let r=e.constructor.prototype;for(let s of Object.keys(r)){let a=r[s];typeof a=="function"?pn.define(t,s,a.bind(e)):pn.define(t,s,a)}};pn.onExit=t=>{let e=(r,s)=>{Rde||(Rde=!0,t5.forEach(a=>a()),r===!0&&process.exit(128+s))};t5.length===0&&(process.once("SIGTERM",e.bind(null,!0,15)),process.once("SIGINT",e.bind(null,!0,2)),process.once("exit",e)),t5.push(t)};pn.define=(t,e,r)=>{Reflect.defineProperty(t,e,{value:r})};pn.defineExport=(t,e,r)=>{let s;Reflect.defineProperty(t,e,{enumerable:!0,configurable:!0,set(a){s=a},get(){return s?s():r()}})}});var Nde=_(rC=>{"use strict";rC.ctrl={a:"first",b:"backward",c:"cancel",d:"deleteForward",e:"last",f:"forward",g:"reset",i:"tab",k:"cutForward",l:"reset",n:"newItem",m:"cancel",j:"submit",p:"search",r:"remove",s:"save",u:"undo",w:"cutLeft",x:"toggleCursor",v:"paste"};rC.shift={up:"shiftUp",down:"shiftDown",left:"shiftLeft",right:"shiftRight",tab:"prev"};rC.fn={up:"pageUp",down:"pageDown",left:"pageLeft",right:"pageRight",delete:"deleteForward"};rC.option={b:"backward",f:"forward",d:"cutRight",left:"cutLeft",up:"altUp",down:"altDown"};rC.keys={pageup:"pageUp",pagedown:"pageDown",home:"home",end:"end",cancel:"cancel",delete:"deleteForward",backspace:"delete",down:"down",enter:"submit",escape:"cancel",left:"left",space:"space",number:"number",return:"submit",right:"right",tab:"next",up:"up"}});var Mde=_((KHt,Lde)=>{"use strict";var Ode=Ie("readline"),vat=Nde(),Sat=/^(?:\x1b)([a-zA-Z0-9])$/,Dat=/^(?:\x1b+)(O|N|\[|\[\[)(?:(\d+)(?:;(\d+))?([~^$])|(?:1;)?(\d+)?([a-zA-Z]))/,bat={OP:"f1",OQ:"f2",OR:"f3",OS:"f4","[11~":"f1","[12~":"f2","[13~":"f3","[14~":"f4","[[A":"f1","[[B":"f2","[[C":"f3","[[D":"f4","[[E":"f5","[15~":"f5","[17~":"f6","[18~":"f7","[19~":"f8","[20~":"f9","[21~":"f10","[23~":"f11","[24~":"f12","[A":"up","[B":"down","[C":"right","[D":"left","[E":"clear","[F":"end","[H":"home",OA:"up",OB:"down",OC:"right",OD:"left",OE:"clear",OF:"end",OH:"home","[1~":"home","[2~":"insert","[3~":"delete","[4~":"end","[5~":"pageup","[6~":"pagedown","[[5~":"pageup","[[6~":"pagedown","[7~":"home","[8~":"end","[a":"up","[b":"down","[c":"right","[d":"left","[e":"clear","[2$":"insert","[3$":"delete","[5$":"pageup","[6$":"pagedown","[7$":"home","[8$":"end",Oa:"up",Ob:"down",Oc:"right",Od:"left",Oe:"clear","[2^":"insert","[3^":"delete","[5^":"pageup","[6^":"pagedown","[7^":"home","[8^":"end","[Z":"tab"};function Pat(t){return["[a","[b","[c","[d","[e","[2$","[3$","[5$","[6$","[7$","[8$","[Z"].includes(t)}function xat(t){return["Oa","Ob","Oc","Od","Oe","[2^","[3^","[5^","[6^","[7^","[8^"].includes(t)}var KR=(t="",e={})=>{let r,s={name:e.name,ctrl:!1,meta:!1,shift:!1,option:!1,sequence:t,raw:t,...e};if(Buffer.isBuffer(t)?t[0]>127&&t[1]===void 0?(t[0]-=128,t="\x1B"+String(t)):t=String(t):t!==void 0&&typeof t!="string"?t=String(t):t||(t=s.sequence||""),s.sequence=s.sequence||t||s.name,t==="\r")s.raw=void 0,s.name="return";else if(t===`
`)s.name="enter";else if(t===" ")s.name="tab";else if(t==="\b"||t==="\x7F"||t==="\x1B\x7F"||t==="\x1B\b")s.name="backspace",s.meta=t.charAt(0)==="\x1B";else if(t==="\x1B"||t==="\x1B\x1B")s.name="escape",s.meta=t.length===2;else if(t===" "||t==="\x1B ")s.name="space",s.meta=t.length===2;else if(t<="")s.name=String.fromCharCode(t.charCodeAt(0)+97-1),s.ctrl=!0;else if(t.length===1&&t>="0"&&t<="9")s.name="number";else if(t.length===1&&t>="a"&&t<="z")s.name=t;else if(t.length===1&&t>="A"&&t<="Z")s.name=t.toLowerCase(),s.shift=!0;else if(r=Sat.exec(t))s.meta=!0,s.shift=/^[A-Z]$/.test(r[1]);else if(r=Dat.exec(t)){let a=[...t];a[0]==="\x1B"&&a[1]==="\x1B"&&(s.option=!0);let n=[r[1],r[2],r[4],r[6]].filter(Boolean).join(""),c=(r[3]||r[5]||1)-1;s.ctrl=!!(c&4),s.meta=!!(c&10),s.shift=!!(c&1),s.code=n,s.name=bat[n],s.shift=Pat(n)||s.shift,s.ctrl=xat(n)||s.ctrl}return s};KR.listen=(t={},e)=>{let{stdin:r}=t;if(!r||r!==process.stdin&&!r.isTTY)throw new Error("Invalid stream passed");let s=Ode.createInterface({terminal:!0,input:r});Ode.emitKeypressEvents(r,s);let a=(f,p)=>e(f,KR(f,p),s),n=r.isRaw;return r.isTTY&&r.setRawMode(!0),r.on("keypress",a),s.resume(),()=>{r.isTTY&&r.setRawMode(n),r.removeListener("keypress",a),s.pause(),s.close()}};KR.action=(t,e,r)=>{let s={...vat,...r};return e.ctrl?(e.action=s.ctrl[e.name],e):e.option&&s.option?(e.action=s.option[e.name],e):e.shift?(e.action=s.shift[e.name],e):(e.action=s.keys[e.name],e)};Lde.exports=KR});var _de=_((zHt,Ude)=>{"use strict";Ude.exports=t=>{t.timers=t.timers||{};let e=t.options.timers;if(e)for(let r of Object.keys(e)){let s=e[r];typeof s=="number"&&(s={interval:s}),kat(t,r,s)}};function kat(t,e,r={}){let s=t.timers[e]={name:e,start:Date.now(),ms:0,tick:0},a=r.interval||120;s.frames=r.frames||[],s.loading=!0;let n=setInterval(()=>{s.ms=Date.now()-s.start,s.tick++,t.render()},a);return s.stop=()=>{s.loading=!1,clearInterval(n)},Reflect.defineProperty(s,"interval",{value:n}),t.once("close",()=>s.stop()),s.stop}});var jde=_((XHt,Hde)=>{"use strict";var{define:Qat,width:Tat}=Zo(),r5=class{constructor(e){let r=e.options;Qat(this,"_prompt",e),this.type=e.type,this.name=e.name,this.message="",this.header="",this.footer="",this.error="",this.hint="",this.input="",this.cursor=0,this.index=0,this.lines=0,this.tick=0,this.prompt="",this.buffer="",this.width=Tat(r.stdout||process.stdout),Object.assign(this,r),this.name=this.name||this.message,this.message=this.message||this.name,this.symbols=e.symbols,this.styles=e.styles,this.required=new Set,this.cancelled=!1,this.submitted=!1}clone(){let e={...this};return e.status=this.status,e.buffer=Buffer.from(e.buffer),delete e.clone,e}set color(e){this._color=e}get color(){let e=this.prompt.styles;if(this.cancelled)return e.cancelled;if(this.submitted)return e.submitted;let r=this._color||e[this.status];return typeof r=="function"?r:e.pending}set loading(e){this._loading=e}get loading(){return typeof this._loading=="boolean"?this._loading:this.loadingChoices?"choices":!1}get status(){return this.cancelled?"cancelled":this.submitted?"submitted":"pending"}};Hde.exports=r5});var qde=_((ZHt,Gde)=>{"use strict";var n5=Zo(),ho=Ju(),i5={default:ho.noop,noop:ho.noop,set inverse(t){this._inverse=t},get inverse(){return this._inverse||n5.inverse(this.primary)},set complement(t){this._complement=t},get complement(){return this._complement||n5.complement(this.primary)},primary:ho.cyan,success:ho.green,danger:ho.magenta,strong:ho.bold,warning:ho.yellow,muted:ho.dim,disabled:ho.gray,dark:ho.dim.gray,underline:ho.underline,set info(t){this._info=t},get info(){return this._info||this.primary},set em(t){this._em=t},get em(){return this._em||this.primary.underline},set heading(t){this._heading=t},get heading(){return this._heading||this.muted.underline},set pending(t){this._pending=t},get pending(){return this._pending||this.primary},set submitted(t){this._submitted=t},get submitted(){return this._submitted||this.success},set cancelled(t){this._cancelled=t},get cancelled(){return this._cancelled||this.danger},set typing(t){this._typing=t},get typing(){return this._typing||this.dim},set placeholder(t){this._placeholder=t},get placeholder(){return this._placeholder||this.primary.dim},set highlight(t){this._highlight=t},get highlight(){return this._highlight||this.inverse}};i5.merge=(t={})=>{t.styles&&typeof t.styles.enabled=="boolean"&&(ho.enabled=t.styles.enabled),t.styles&&typeof t.styles.visible=="boolean"&&(ho.visible=t.styles.visible);let e=n5.merge({},i5,t.styles);delete e.merge;for(let r of Object.keys(ho))e.hasOwnProperty(r)||Reflect.defineProperty(e,r,{get:()=>ho[r]});for(let r of Object.keys(ho.styles))e.hasOwnProperty(r)||Reflect.defineProperty(e,r,{get:()=>ho[r]});return e};Gde.exports=i5});var Yde=_(($Ht,Wde)=>{"use strict";var s5=process.platform==="win32",zp=Ju(),Rat=Zo(),o5={...zp.symbols,upDownDoubleArrow:"\u21D5",upDownDoubleArrow2:"\u2B0D",upDownArrow:"\u2195",asterisk:"*",asterism:"\u2042",bulletWhite:"\u25E6",electricArrow:"\u2301", Line truncated
`),h=p[0],E=p[p.length-1],S=(s+(r?" "+r:"")).length,P=S<h.length?h.slice(S+1):"";return{header:c,prompt:h,after:P,rest:p.slice(1),last:E}}async submit(){this.state.submitted=!0,this.state.validating=!0,this.options.onSubmit&&await this.options.onSubmit.call(this,this.name,this.value,this);let e=this.state.error||await this.validate(this.value,this.state);if(e!==!0){let r=`
`+this.symbols.pointer+" ";typeof e=="string"?r+=e.trim():r+="Invalid input",this.state.error=`
`+this.styles.danger(r),this.state.submitted=!1,await this.render(),await this.alert(),this.state.validating=!1,this.state.error=void 0;return}this.state.validating=!1,await this.render(),await this.close(),this.value=await this.result(this.value),this.emit("submit",this.value)}async cancel(e){this.state.cancelled=this.state.submitted=!0,await this.render(),await this.close(),typeof this.options.onCancel=="function"&&await this.options.onCancel.call(this,this.name,this.value,this),this.emit("cancel",await this.error(e))}async close(){this.state.closed=!0;try{let e=this.sections(),r=Math.ceil(e.prompt.length/this.width);e.rest&&this.write(Bm.cursor.down(e.rest.length)),this.write(`
`.repeat(r))}catch{}this.emit("close")}start(){!this.stop&&this.options.show!==!1&&(this.stop=u5.listen(this,this.keypress.bind(this)),this.once("close",this.stop))}async skip(){return this.skipped=this.options.skip===!0,typeof this.options.skip=="function"&&(this.skipped=await this.options.skip.call(this,this.name,this.value)),this.skipped}async initialize(){let{format:e,options:r,result:s}=this;if(this.format=()=>e.call(this,this.value),this.result=()=>s.call(this,this.value),typeof r.initial=="function"&&(this.initial=await r.initial.call(this,this)),typeof r.onRun=="function"&&await r.onRun.call(this,this),typeof r.onSubmit=="function"){let a=r.onSubmit.bind(this),n=this.submit.bind(this);delete this.options.onSubmit,this.submit=async()=>(await a(this.name,this.value,this),n())}await this.start(),await this.render()}render(){throw new Error("expected prompt to have a custom render method")}run(){return new Promise(async(e,r)=>{if(this.once("submit",e),this.once("cancel",r),await this.skip())return this.render=()=>{},this.submit();await this.initialize(),this.emit("run")})}async element(e,r,s){let{options:a,state:n,symbols:c,timers:f}=this,p=f&&f[e];n.timer=p;let h=a[e]||n[e]||c[e],E=r&&r[e]!=null?r[e]:await h;if(E==="")return E;let C=await this.resolve(E,n,r,s);return!C&&r&&r[e]?this.resolve(h,n,r,s):C}async prefix(){let e=await this.element("prefix")||this.symbols,r=this.timers&&this.timers.prefix,s=this.state;return s.timer=r,pl.isObject(e)&&(e=e[s.status]||e.pending),pl.hasColor(e)?e:(this.styles[s.status]||this.styles.pending)(e)}async message(){let e=await this.element("message");return pl.hasColor(e)?e:this.styles.strong(e)}async separator(){let e=await this.element("separator")||this.symbols,r=this.timers&&this.timers.separator,s=this.state;s.timer=r;let a=e[s.status]||e.pending||s.separator,n=await this.resolve(a,s);return pl.isObject(n)&&(n=n[s.status]||n.pending),pl.hasColor(n)?n:this.styles.muted(n)}async pointer(e,r){let s=await this.element("pointer",e,r);if(typeof s=="string"&&pl.hasColor(s))return s;if(s){let a=this.styles,n=this.index===r,c=n?a.primary:h=>h,f=await this.resolve(s[n?"on":"off"]||s,this.state),p=pl.hasColor(f)?f:c(f);return n?p:" ".repeat(f.length)}}async indicator(e,r){let s=await this.element("indicator",e,r);if(typeof s=="string"&&pl.hasColor(s))return s;if(s){let a=this.styles,n=e.enabled===!0,c=n?a.success:a.dark,f=s[n?"on":"off"]||s;return pl.hasColor(f)?f:c(f)}return""}body(){return null}footer(){if(this.state.status==="pending")return this.element("footer")}header(){if(this.state.status==="pending")return this.element("header")}async hint(){if(this.state.status==="pending"&&!this.isValue(this.state.input)){let e=await this.element("hint");return pl.hasColor(e)?e:this.styles.muted(e)}}error(e){return this.state.submitted?"":e||this.state.error}format(e){return e}result(e){return e}validate(e){return this.options.required===!0?this.isValue(e):!0}isValue(e){return e!=null&&e!==""}resolve(e,...r){return pl.resolve(this,e,...r)}get base(){return t.prototype}get style(){return this.styles[this.state.status]}get height(){return this.options.rows||pl.height(this.stdout,25)}get width(){return this.options.columns||pl.width(this.stdout,80)}get size(){return{width:this.width,height:this.height}}set cursor(e){this.state.cursor=e}get cursor(){return this.state.cursor}set input(e){this.state.input=e}get input(){return this.state.input}set value(e){this.state.value=e}get value(){let{input:e,value:r}=this.state,s=[r,e].find(this.isValue.bind(this));return this.isValue(s)?s:this.initial}static get prompt(){return e=>new this(e).run()}};function jat(t){let e=a=>t[a]===void 0||typeof t[a]=="function",r=["actions","choices","initial","margin","roles","styles","symbols","theme","timers","value"],s=["body","footer","error","header","hint","indicator","message","prefix","separator","skip"];for(let a of Object.keys(t.options)){if(r.includes(a)||/^on[A-Z]/.test(a))continue;let n=t.options[a];typeof n=="function"&&e(a)?s.includes(a)||(t[a]=n.bind(t)):typeof t[a]!="function"&&(t[a]=n)}}function Gat(t){typeof t=="number"&&(t=[t,t,t,t]);let e=[].concat(t||[]),r=a=>a%2===0?`
`:" ",s=[];for(let a=0;a<4;a++){let n=r(a);e[a]?s.push(n.repeat(e[a])):s.push("")}return s}tme.exports=f5});var ime=_((rjt,nme)=>{"use strict";var qat=Zo(),rme={default(t,e){return e},checkbox(t,e){throw new Error("checkbox role is not implemented yet")},editable(t,e){throw new Error("editable role is not implemented yet")},expandable(t,e){throw new Error("expandable role is not implemented yet")},heading(t,e){return e.disabled="",e.indicator=[e.indicator," "].find(r=>r!=null),e.message=e.message||"",e},input(t,e){throw new Error("input role is not implemented yet")},option(t,e){return rme.default(t,e)},radio(t,e){throw new Error("radio role is not implemented yet")},separator(t,e){return e.disabled="",e.indicator=[e.indicator," "].find(r=>r!=null),e.message=e.message||t.symbols.line.repeat(5),e},spacer(t,e){return e}};nme.exports=(t,e={})=>{let r=qat.merge({},rme,e.roles);return r[t]||r.default}});var Wv=_((njt,ame)=>{"use strict";var Wat=Ju(),Yat=nC(),Vat=ime(),zR=Zo(),{reorder:A5,scrollUp:Jat,scrollDown:Kat,isObject:sme,swap:zat}=zR,p5=class extends Yat{constructor(e){super(e),this.cursorHide(),this.maxSelected=e.maxSelected||1/0,this.multiple=e.multiple||!1,this.initial=e.initial||0,this.delay=e.delay||0,this.longest=0,this.num=""}async initialize(){typeof this.options.initial=="function"&&(this.initial=await this.options.initial.call(this)),await this.reset(!0),await super.initialize()}async reset(){let{choices:e,initial:r,autofocus:s,suggest:a}=this.options;if(this.state._choices=[],this.state.choices=[],this.choices=await Promise.all(await this.toChoices(e)),this.choices.forEach(n=>n.enabled=!1),typeof a!="function"&&this.selectable.length===0)throw new Error("At least one choice must be selectable");sme(r)&&(r=Object.keys(r)),Array.isArray(r)?(s!=null&&(this.index=this.findIndex(s)),r.forEach(n=>this.enable(this.find(n))),await this.render()):(s!=null&&(r=s),typeof r=="string"&&(r=this.findIndex(r)),typeof r=="number"&&r>-1&&(this.index=Math.max(0,Math.min(r,this.choices.length)),this.enable(this.find(this.index)))),this.isDisabled(this.focused)&&await this.down()}async toChoices(e,r){this.state.loadingChoices=!0;let s=[],a=0,n=async(c,f)=>{typeof c=="function"&&(c=await c.call(this)),c instanceof Promise&&(c=await c);for(let p=0;p<c.length;p++){let h=c[p]=await this.toChoice(c[p],a++,f);s.push(h),h.choices&&await n(h.choices,h)}return s};return n(e,r).then(c=>(this.state.loadingChoices=!1,c))}async toChoice(e,r,s){if(typeof e=="function"&&(e=await e.call(this,this)),e instanceof Promise&&(e=await e),typeof e=="string"&&(e={name:e}),e.normalized)return e;e.normalized=!0;let a=e.value;if(e=Vat(e.role,this.options)(this,e),typeof e.disabled=="string"&&!e.hint&&(e.hint=e.disabled,e.disabled=!0),e.disabled===!0&&e.hint==null&&(e.hint="(disabled)"),e.index!=null)return e;e.name=e.name||e.key||e.title||e.value||e.message,e.message=e.message||e.name||"",e.value=[e.value,e.name].find(this.isValue.bind(this)),e.input="",e.index=r,e.cursor=0,zR.define(e,"parent",s),e.level=s?s.level+1:1,e.indent==null&&(e.indent=s?s.indent+" ":e.indent||""),e.path=s?s.path+"."+e.name:e.name,e.enabled=!!(this.multiple&&!this.isDisabled(e)&&(e.enabled||this.isSelected(e))),this.isDisabled(e)||(this.longest=Math.max(this.longest,Wat.unstyle(e.message).length));let c={...e};return e.reset=(f=c.input,p=c.value)=>{for(let h of Object.keys(c))e[h]=c[h];e.input=f,e.value=p},a==null&&typeof e.initial=="function"&&(e.input=await e.initial.call(this,this.state,e,r)),e}async onChoice(e,r){this.emit("choice",e,r,this),typeof e.onChoice=="function"&&await e.onChoice.call(this,this.state,e,r)}async addChoice(e,r,s){let a=await this.toChoice(e,r,s);return this.choices.push(a),this.index=this.choices.length-1,this.limit=this.choices.length,a}async newItem(e,r,s){let a={name:"New choice name?",editable:!0,newChoice:!0,...e},n=await this.addChoice(a,r,s);return n.updateChoice=()=>{delete n.newChoice,n.name=n.message=n.input,n.input="",n.cursor=0},this.render()}indent(e){return e.indent==null?e.level>1?" ".repeat(e.level-1):"":e.indent}dispatch(e,r){if(this.multiple&&this[r.name])return this[r.name]();this.alert()}focus(e,r){return typeof r!="boolean"&&(r=e.enabled),r&&!e.enabled&&this.selected.length>=this.maxSelected?this.alert():(this.index=e.index,e.enabled=r&&!this.isDisabled(e),e)}space(){return this.multiple?(this.toggle(this.focused),this.render()):this.alert()}a(){if(this.maxSelected<this.choices.length)return this.alert();let e=this.selectable.every(r=>r.enabled);return this.choices.forEach(r=>r.enabled=!e),this.render()}i(){return this.choices.length-this.selected.length>this.maxSelected?this.alert():(this.choices.forEach(e=>e.enabled=!e.enabled),this.render())}g(e=this.focused){return this.choices.some(r=>!!r.parent)?(this.toggle(e.parent&&!e.choices?e.parent:e),this.render()):this.a()}toggle(e,r){if(!e.enabled&&this.selected.length>=this.maxSelected)return this.alert();typeof r!="boolean"&&(r=!e.enabled),e.enabled=r,e.choices&&e. Line truncated
`),a;return this.options.choicesHeader&&(a=await this.resolve(this.options.choicesHeader,this.state)),[a,s].filter(Boolean).join(`
`)}format(){return!this.state.submitted||this.state.cancelled?"":Array.isArray(this.selected)?this.selected.map(e=>this.styles.primary(e.name)).join(", "):this.styles.primary(this.selected.name)}async render(){let{submitted:e,size:r}=this.state,s="",a=await this.header(),n=await this.prefix(),c=await this.separator(),f=await this.message();this.options.promptLine!==!1&&(s=[n,f,c,""].join(" "),this.state.prompt=s);let p=await this.format(),h=await this.error()||await this.hint(),E=await this.renderChoices(),C=await this.footer();p&&(s+=p),h&&!s.includes(h)&&(s+=" "+h),e&&!p&&!E.trim()&&this.multiple&&this.emptyError!=null&&(s+=this.styles.danger(this.emptyError)),this.clear(r),this.write([a,s,E,C].filter(Boolean).join(`
`)),this.write(this.margin[2]),this.restore()}};lme.exports=g5});var ume=_((sjt,cme)=>{"use strict";var Zat=G0(),$at=(t,e)=>{let r=t.toLowerCase();return s=>{let n=s.toLowerCase().indexOf(r),c=e(s.slice(n,n+r.length));return n>=0?s.slice(0,n)+c+s.slice(n+r.length):s}},d5=class extends Zat{constructor(e){super(e),this.cursorShow()}moveCursor(e){this.state.cursor+=e}dispatch(e){return this.append(e)}space(e){return this.options.multiple?super.space(e):this.append(e)}append(e){let{cursor:r,input:s}=this.state;return this.input=s.slice(0,r)+e+s.slice(r),this.moveCursor(1),this.complete()}delete(){let{cursor:e,input:r}=this.state;return r?(this.input=r.slice(0,e-1)+r.slice(e),this.moveCursor(-1),this.complete()):this.alert()}deleteForward(){let{cursor:e,input:r}=this.state;return r[e]===void 0?this.alert():(this.input=`${r}`.slice(0,e)+`${r}`.slice(e+1),this.complete())}number(e){return this.append(e)}async complete(){this.completing=!0,this.choices=await this.suggest(this.input,this.state._choices),this.state.limit=void 0,this.index=Math.min(Math.max(this.visible.length-1,0),this.index),await this.render(),this.completing=!1}suggest(e=this.input,r=this.state._choices){if(typeof this.options.suggest=="function")return this.options.suggest.call(this,e,r);let s=e.toLowerCase();return r.filter(a=>a.message.toLowerCase().includes(s))}pointer(){return""}format(){if(!this.focused)return this.input;if(this.options.multiple&&this.state.submitted)return this.selected.map(e=>this.styles.primary(e.message)).join(", ");if(this.state.submitted){let e=this.value=this.input=this.focused.value;return this.styles.primary(e)}return this.input}async render(){if(this.state.status!=="pending")return super.render();let e=this.options.highlight?this.options.highlight.bind(this):this.styles.placeholder,r=$at(this.input,e),s=this.choices;this.choices=s.map(a=>({...a,message:r(a.message)})),await super.render(),this.choices=s}submit(){return this.options.multiple&&(this.value=this.selected.map(e=>e.name)),super.submit()}};cme.exports=d5});var y5=_((ojt,fme)=>{"use strict";var m5=Zo();fme.exports=(t,e={})=>{t.cursorHide();let{input:r="",initial:s="",pos:a,showCursor:n=!0,color:c}=e,f=c||t.styles.placeholder,p=m5.inverse(t.styles.primary),h=R=>p(t.styles.black(R)),E=r,C=" ",S=h(C);if(t.blink&&t.blink.off===!0&&(h=R=>R,S=""),n&&a===0&&s===""&&r==="")return h(C);if(n&&a===0&&(r===s||r===""))return h(s[0])+f(s.slice(1));s=m5.isPrimitive(s)?`${s}`:"",r=m5.isPrimitive(r)?`${r}`:"";let P=s&&s.startsWith(r)&&s!==r,I=P?h(s[r.length]):S;if(a!==r.length&&n===!0&&(E=r.slice(0,a)+h(r[a])+r.slice(a+1),I=""),n===!1&&(I=""),P){let R=t.styles.unstyle(E+I);return E+I+f(s.slice(R.length))}return E+I}});var XR=_((ajt,Ame)=>{"use strict";var elt=Ju(),tlt=G0(),rlt=y5(),E5=class extends tlt{constructor(e){super({...e,multiple:!0}),this.type="form",this.initial=this.options.initial,this.align=[this.options.align,"right"].find(r=>r!=null),this.emptyError="",this.values={}}async reset(e){return await super.reset(),e===!0&&(this._index=this.index),this.index=this._index,this.values={},this.choices.forEach(r=>r.reset&&r.reset()),this.render()}dispatch(e){return!!e&&this.append(e)}append(e){let r=this.focused;if(!r)return this.alert();let{cursor:s,input:a}=r;return r.value=r.input=a.slice(0,s)+e+a.slice(s),r.cursor++,this.render()}delete(){let e=this.focused;if(!e||e.cursor<=0)return this.alert();let{cursor:r,input:s}=e;return e.value=e.input=s.slice(0,r-1)+s.slice(r),e.cursor--,this.render()}deleteForward(){let e=this.focused;if(!e)return this.alert();let{cursor:r,input:s}=e;if(s[r]===void 0)return this.alert();let a=`${s}`.slice(0,r)+`${s}`.slice(r+1);return e.value=e.input=a,this.render()}right(){let e=this.focused;return e?e.cursor>=e.input.length?this.alert():(e.cursor++,this.render()):this.alert()}left(){let e=this.focused;return e?e.cursor<=0?this.alert():(e.cursor--,this.render()):this.alert()}space(e,r){return this.dispatch(e,r)}number(e,r){return this.dispatch(e,r)}next(){let e=this.focused;if(!e)return this.alert();let{initial:r,input:s}=e;return r&&r.startsWith(s)&&s!==r?(e.value=e.input=r,e.cursor=e.value.length,this.render()):super.next()}prev(){let e=this.focused;return e?e.cursor===0?super.prev():(e.value=e.input="",e.cursor=0,this.render()):this.alert()}separator(){return""}format(e){return this.state.submitted?"":super.format(e)}pointer(){return""}indicator(e){return e.input?"\u29BF":"\u2299"}async choiceSeparator(e,r){let s=await this.resolve(e.separator,this.state,e,r)||":";return s?" "+this.styles.disabled(s):""}async renderChoice(e,r){await this.onChoice(e,r);let{state:s,styles:a}=this,{cursor:n,initial:c="",name:f,hint:p,input:h=""}=e,{muted:E,submitted:C,primary:S,danger:P}=a,I=p,R=this.index===r,N=e.validate||(()=>!0),U=await this.choiceSeparator(e,r),W=e.message;this.align==="right"&&(W=W.padStart(this.longest+1," ")),this.align==="left"&&(W=W.padEnd(this.longest+1," "));let ee=this.values[f]=h||c,ie=h?"success":"dark";await N.call(e,ee,thi Line truncated
`)),this.restore()}set value(e){super.value=e}get value(){return this.cast(super.value)}};yme.exports=C5});var Ime=_((fjt,Eme)=>{"use strict";var ult=ZR(),w5=class extends ult{constructor(e){super(e),this.default=this.options.default||(this.initial?"(Y/n)":"(y/N)")}};Eme.exports=w5});var wme=_((Ajt,Cme)=>{"use strict";var flt=G0(),Alt=XR(),iC=Alt.prototype,B5=class extends flt{constructor(e){super({...e,multiple:!0}),this.align=[this.options.align,"left"].find(r=>r!=null),this.emptyError="",this.values={}}dispatch(e,r){let s=this.focused,a=s.parent||{};return!s.editable&&!a.editable&&(e==="a"||e==="i")?super[e]():iC.dispatch.call(this,e,r)}append(e,r){return iC.append.call(this,e,r)}delete(e,r){return iC.delete.call(this,e,r)}space(e){return this.focused.editable?this.append(e):super.space()}number(e){return this.focused.editable?this.append(e):super.number(e)}next(){return this.focused.editable?iC.next.call(this):super.next()}prev(){return this.focused.editable?iC.prev.call(this):super.prev()}async indicator(e,r){let s=e.indicator||"",a=e.editable?s:super.indicator(e,r);return await this.resolve(a,this.state,e,r)||""}indent(e){return e.role==="heading"?"":e.editable?" ":" "}async renderChoice(e,r){return e.indent="",e.editable?iC.renderChoice.call(this,e,r):super.renderChoice(e,r)}error(){return""}footer(){return this.state.error}async validate(){let e=!0;for(let r of this.choices){if(typeof r.validate!="function"||r.role==="heading")continue;let s=r.parent?this.value[r.parent.name]:this.value;if(r.editable?s=r.value===r.name?r.initial||"":r.value:this.isDisabled(r)||(s=r.enabled===!0),e=await r.validate(s,this.state),e!==!0)break}return e!==!0&&(this.state.error=typeof e=="string"?e:"Invalid Input"),e}submit(){if(this.focused.newChoice===!0)return super.submit();if(this.choices.some(e=>e.newChoice))return this.alert();this.value={};for(let e of this.choices){let r=e.parent?this.value[e.parent.name]:this.value;if(e.role==="heading"){this.value[e.name]={};continue}e.editable?r[e.name]=e.value===e.name?e.initial||"":e.value:this.isDisabled(e)||(r[e.name]=e.enabled===!0)}return this.base.submit.call(this)}};Cme.exports=B5});var vm=_((pjt,Bme)=>{"use strict";var plt=nC(),hlt=y5(),{isPrimitive:glt}=Zo(),v5=class extends plt{constructor(e){super(e),this.initial=glt(this.initial)?String(this.initial):"",this.initial&&this.cursorHide(),this.state.prevCursor=0,this.state.clipboard=[]}async keypress(e,r={}){let s=this.state.prevKeypress;return this.state.prevKeypress=r,this.options.multiline===!0&&r.name==="return"&&(!s||s.name!=="return")?this.append(`
`,r):super.keypress(e,r)}moveCursor(e){this.cursor+=e}reset(){return this.input=this.value="",this.cursor=0,this.render()}dispatch(e,r){if(!e||r.ctrl||r.code)return this.alert();this.append(e)}append(e){let{cursor:r,input:s}=this.state;this.input=`${s}`.slice(0,r)+e+`${s}`.slice(r),this.moveCursor(String(e).length),this.render()}insert(e){this.append(e)}delete(){let{cursor:e,input:r}=this.state;if(e<=0)return this.alert();this.input=`${r}`.slice(0,e-1)+`${r}`.slice(e),this.moveCursor(-1),this.render()}deleteForward(){let{cursor:e,input:r}=this.state;if(r[e]===void 0)return this.alert();this.input=`${r}`.slice(0,e)+`${r}`.slice(e+1),this.render()}cutForward(){let e=this.cursor;if(this.input.length<=e)return this.alert();this.state.clipboard.push(this.input.slice(e)),this.input=this.input.slice(0,e),this.render()}cutLeft(){let e=this.cursor;if(e===0)return this.alert();let r=this.input.slice(0,e),s=this.input.slice(e),a=r.split(" ");this.state.clipboard.push(a.pop()),this.input=a.join(" "),this.cursor=this.input.length,this.input+=s,this.render()}paste(){if(!this.state.clipboard.length)return this.alert();this.insert(this.state.clipboard.pop()),this.render()}toggleCursor(){this.state.prevCursor?(this.cursor=this.state.prevCursor,this.state.prevCursor=0):(this.state.prevCursor=this.cursor,this.cursor=0),this.render()}first(){this.cursor=0,this.render()}last(){this.cursor=this.input.length-1,this.render()}next(){let e=this.initial!=null?String(this.initial):"";if(!e||!e.startsWith(this.input))return this.alert();this.input=this.initial,this.cursor=this.initial.length,this.render()}prev(){if(!this.input)return this.alert();this.reset()}backward(){return this.left()}forward(){return this.right()}right(){return this.cursor>=this.input.length?this.alert():(this.moveCursor(1),this.render())}left(){return this.cursor<=0?this.alert():(this.moveCursor(-1),this.render())}isValue(e){return!!e}async format(e=this.value){let r=await this.resolve(this.initial,this.state);return this.state.submitted?this.styles.submitted(e||r):hlt(this,{input:e,initial:r,pos:this.cursor})}async render(){let e=this.state.size,r=await this.prefix(),s=await this.separator(),a=await this.message(),n=[r,a,s].filter(Boolean).join(" ");this.state.prompt=n;let c=await this.header(),f=await this.format(),p=await this.error()||await this.hint(),h=await this.footer();p&&!f.includes(p)&&(f+=" "+p),n+=" "+f,this.clear(e),this.write([c,n,h].filter(Boolean).join(`
`)),this.restore()}};Bme.exports=v5});var Sme=_((hjt,vme)=>{"use strict";var dlt=t=>t.filter((e,r)=>t.lastIndexOf(e)===r),$R=t=>dlt(t).filter(Boolean);vme.exports=(t,e={},r="")=>{let{past:s=[],present:a=""}=e,n,c;switch(t){case"prev":case"undo":return n=s.slice(0,s.length-1),c=s[s.length-1]||"",{past:$R([r,...n]),present:c};case"next":case"redo":return n=s.slice(1),c=s[0]||"",{past:$R([...n,r]),present:c};case"save":return{past:$R([...s,r]),present:""};case"remove":return c=$R(s.filter(f=>f!==r)),a="",c.length&&(a=c.pop()),{past:c,present:a};default:throw new Error(`Invalid action: "${t}"`)}}});var D5=_((gjt,bme)=>{"use strict";var mlt=vm(),Dme=Sme(),S5=class extends mlt{constructor(e){super(e);let r=this.options.history;if(r&&r.store){let s=r.values||this.initial;this.autosave=!!r.autosave,this.store=r.store,this.data=this.store.get("values")||{past:[],present:s},this.initial=this.data.present||this.data.past[this.data.past.length-1]}}completion(e){return this.store?(this.data=Dme(e,this.data,this.input),this.data.present?(this.input=this.data.present,this.cursor=this.input.length,this.render()):this.alert()):this.alert()}altUp(){return this.completion("prev")}altDown(){return this.completion("next")}prev(){return this.save(),super.prev()}save(){this.store&&(this.data=Dme("save",this.data,this.input),this.store.set("values",this.data))}submit(){return this.store&&this.autosave===!0&&this.save(),super.submit()}};bme.exports=S5});var xme=_((djt,Pme)=>{"use strict";var ylt=vm(),b5=class extends ylt{format(){return""}};Pme.exports=b5});var Qme=_((mjt,kme)=>{"use strict";var Elt=vm(),P5=class extends Elt{constructor(e={}){super(e),this.sep=this.options.separator||/, */,this.initial=e.initial||""}split(e=this.value){return e?String(e).split(this.sep):[]}format(){let e=this.state.submitted?this.styles.primary:r=>r;return this.list.map(e).join(", ")}async submit(e){let r=this.state.error||await this.validate(this.list,this.state);return r!==!0?(this.state.error=r,super.submit()):(this.value=this.list,super.submit())}get list(){return this.split()}};kme.exports=P5});var Rme=_((yjt,Tme)=>{"use strict";var Ilt=G0(),x5=class extends Ilt{constructor(e){super({...e,multiple:!0})}};Tme.exports=x5});var Q5=_((Ejt,Fme)=>{"use strict";var Clt=vm(),k5=class extends Clt{constructor(e={}){super({style:"number",...e}),this.min=this.isValue(e.min)?this.toNumber(e.min):-1/0,this.max=this.isValue(e.max)?this.toNumber(e.max):1/0,this.delay=e.delay!=null?e.delay:1e3,this.float=e.float!==!1,this.round=e.round===!0||e.float===!1,this.major=e.major||10,this.minor=e.minor||1,this.initial=e.initial!=null?e.initial:"",this.input=String(this.initial),this.cursor=this.input.length,this.cursorShow()}append(e){return!/[-+.]/.test(e)||e==="."&&this.input.includes(".")?this.alert("invalid number"):super.append(e)}number(e){return super.append(e)}next(){return this.input&&this.input!==this.initial?this.alert():this.isValue(this.initial)?(this.input=this.initial,this.cursor=String(this.initial).length,this.render()):this.alert()}up(e){let r=e||this.minor,s=this.toNumber(this.input);return s>this.max+r?this.alert():(this.input=`${s+r}`,this.render())}down(e){let r=e||this.minor,s=this.toNumber(this.input);return s<this.min-r?this.alert():(this.input=`${s-r}`,this.render())}shiftDown(){return this.down(this.major)}shiftUp(){return this.up(this.major)}format(e=this.input){return typeof this.options.format=="function"?this.options.format.call(this,e):this.styles.info(e)}toNumber(e=""){return this.float?+e:Math.round(+e)}isValue(e){return/^[-+]?[0-9]+((\.)|(\.[0-9]+))?$/.test(e)}submit(){let e=[this.input,this.initial].find(r=>this.isValue(r));return this.value=this.toNumber(e||0),super.submit()}};Fme.exports=k5});var Ome=_((Ijt,Nme)=>{Nme.exports=Q5()});var Mme=_((Cjt,Lme)=>{"use strict";var wlt=vm(),T5=class extends wlt{constructor(e){super(e),this.cursorShow()}format(e=this.input){return this.keypressed?(this.state.submitted?this.styles.primary:this.styles.muted)(this.symbols.asterisk.repeat(e.length)):""}};Lme.exports=T5});var Hme=_((wjt,_me)=>{"use strict";var Blt=Ju(),vlt=Wv(),Ume=Zo(),R5=class extends vlt{constructor(e={}){super(e),this.widths=[].concat(e.messageWidth||50),this.align=[].concat(e.align||"left"),this.linebreak=e.linebreak||!1,this.edgeLength=e.edgeLength||3,this.newline=e.newline||`
`;let r=e.startNumber||1;typeof this.scale=="number"&&(this.scaleKey=!1,this.scale=Array(this.scale).fill(0).map((s,a)=>({name:a+r})))}async reset(){return this.tableized=!1,await super.reset(),this.render()}tableize(){if(this.tableized===!0)return;this.tableized=!0;let e=0;for(let r of this.choices){e=Math.max(e,r.message.length),r.scaleIndex=r.initial||2,r.scale=[];for(let s=0;s<this.scale.length;s++)r.scale.push({index:s})}this.widths[0]=Math.min(this.widths[0],e+3)}async dispatch(e,r){if(this.multiple)return this[r.name]?await this[r.name](e,r):await super.dispatch(e,r);this.alert()}heading(e,r,s){return this.styles.strong(e)}separator(){return this.styles.muted(this.symbols.ellipsis)}right(){let e=this.focused;return e.scaleIndex>=this.scale.length-1?this.alert():(e.scaleIndex++,this.render())}left(){let e=this.focused;return e.scaleIndex<=0?this.alert():(e.scaleIndex--,this.render())}indent(){return""}format(){return this.state.submitted?this.choices.map(r=>this.styles.info(r.index)).join(", "):""}pointer(){return""}renderScaleKey(){return this.scaleKey===!1||this.state.submitted?"":["",...this.scale.map(s=>` ${s.name} - ${s.message}`)].map(s=>this.styles.muted(s)).join(`
`)}renderScaleHeading(e){let r=this.scale.map(p=>p.name);typeof this.options.renderScaleHeading=="function"&&(r=this.options.renderScaleHeading.call(this,e));let s=this.scaleLength-r.join("").length,a=Math.round(s/(r.length-1)),c=r.map(p=>this.styles.strong(p)).join(" ".repeat(a)),f=" ".repeat(this.widths[0]);return this.margin[3]+f+this.margin[1]+c}scaleIndicator(e,r,s){if(typeof this.options.scaleIndicator=="function")return this.options.scaleIndicator.call(this,e,r,s);let a=e.scaleIndex===r.index;return r.disabled?this.styles.hint(this.symbols.radio.disabled):a?this.styles.success(this.symbols.radio.on):this.symbols.radio.off}renderScale(e,r){let s=e.scale.map(n=>this.scaleIndicator(e,n,r)),a=this.term==="Hyper"?"":" ";return s.join(a+this.symbols.line.repeat(this.edgeLength))}async renderChoice(e,r){await this.onChoice(e,r);let s=this.index===r,a=await this.pointer(e,r),n=await e.hint;n&&!Ume.hasColor(n)&&(n=this.styles.muted(n));let c=I=>this.margin[3]+I.replace(/\s+$/,"").padEnd(this.widths[0]," "),f=this.newline,p=this.indent(e),h=await this.resolve(e.message,this.state,e,r),E=await this.renderScale(e,r),C=this.margin[1]+this.margin[3];this.scaleLength=Blt.unstyle(E).length,this.widths[0]=Math.min(this.widths[0],this.width-this.scaleLength-C.length);let P=Ume.wordWrap(h,{width:this.widths[0],newline:f}).split(`
`).map(I=>c(I)+this.margin[1]);return s&&(E=this.styles.info(E),P=P.map(I=>this.styles.info(I))),P[0]+=E,this.linebreak&&P.push(""),[p+a,P.join(`
`)].filter(Boolean)}async renderChoices(){if(this.state.submitted)return"";this.tableize();let e=this.visible.map(async(a,n)=>await this.renderChoice(a,n)),r=await Promise.all(e),s=await this.renderScaleHeading();return this.margin[0]+[s,...r.map(a=>a.join(" "))].join(`
`)}async render(){let{submitted:e,size:r}=this.state,s=await this.prefix(),a=await this.separator(),n=await this.message(),c="";this.options.promptLine!==!1&&(c=[s,n,a,""].join(" "),this.state.prompt=c);let f=await this.header(),p=await this.format(),h=await this.renderScaleKey(),E=await this.error()||await this.hint(),C=await this.renderChoices(),S=await this.footer(),P=this.emptyError;p&&(c+=p),E&&!c.includes(E)&&(c+=" "+E),e&&!p&&!C.trim()&&this.multiple&&P!=null&&(c+=this.styles.danger(P)),this.clear(r),this.write([f,c,h,C,S].filter(Boolean).join(`
`)),this.state.submitted||this.write(this.margin[2]),this.restore()}submit(){this.value={};for(let e of this.choices)this.value[e.name]=e.scaleIndex;return this.base.submit.call(this)}};_me.exports=R5});var qme=_((Bjt,Gme)=>{"use strict";var jme=Ju(),Slt=(t="")=>typeof t=="string"?t.replace(/^['"]|['"]$/g,""):"",N5=class{constructor(e){this.name=e.key,this.field=e.field||{},this.value=Slt(e.initial||this.field.initial||""),this.message=e.message||this.name,this.cursor=0,this.input="",this.lines=[]}},Dlt=async(t={},e={},r=s=>s)=>{let s=new Set,a=t.fields||[],n=t.template,c=[],f=[],p=[],h=1;typeof n=="function"&&(n=await n());let E=-1,C=()=>n[++E],S=()=>n[E+1],P=I=>{I.line=h,c.push(I)};for(P({type:"bos",value:""});E<n.length-1;){let I=C();if(/^[^\S\n ]$/.test(I)){P({type:"text",value:I});continue}if(I===`
`){P({type:"newline",value:I}),h++;continue}if(I==="\\"){I+=C(),P({type:"text",value:I});continue}if((I==="$"||I==="#"||I==="{")&&S()==="{"){let N=C();I+=N;let U={type:"template",open:I,inner:"",close:"",value:I},W;for(;W=C();){if(W==="}"){S()==="}"&&(W+=C()),U.value+=W,U.close=W;break}W===":"?(U.initial="",U.key=U.inner):U.initial!==void 0&&(U.initial+=W),U.value+=W,U.inner+=W}U.template=U.open+(U.initial||U.inner)+U.close,U.key=U.key||U.inner,e.hasOwnProperty(U.key)&&(U.initial=e[U.key]),U=r(U),P(U),p.push(U.key),s.add(U.key);let ee=f.find(ie=>ie.name===U.key);U.field=a.find(ie=>ie.name===U.key),ee||(ee=new N5(U),f.push(ee)),ee.lines.push(U.line-1);continue}let R=c[c.length-1];R.type==="text"&&R.line===h?R.value+=I:P({type:"text",value:I})}return P({type:"eos",value:""}),{input:n,tabstops:c,unique:s,keys:p,items:f}};Gme.exports=async t=>{let e=t.options,r=new Set(e.required===!0?[]:e.required||[]),s={...e.values,...e.initial},{tabstops:a,items:n,keys:c}=await Dlt(e,s),f=F5("result",t,e),p=F5("format",t,e),h=F5("validate",t,e,!0),E=t.isValue.bind(t);return async(C={},S=!1)=>{let P=0;C.required=r,C.items=n,C.keys=c,C.output="";let I=async(W,ee,ie,ue)=>{let le=await h(W,ee,ie,ue);return le===!1?"Invalid field "+ie.name:le};for(let W of a){let ee=W.value,ie=W.key;if(W.type!=="template"){ee&&(C.output+=ee);continue}if(W.type==="template"){let ue=n.find(Ce=>Ce.name===ie);e.required===!0&&C.required.add(ue.name);let le=[ue.input,C.values[ue.value],ue.value,ee].find(E),pe=(ue.field||{}).message||W.inner;if(S){let Ce=await I(C.values[ie],C,ue,P);if(Ce&&typeof Ce=="string"||Ce===!1){C.invalid.set(ie,Ce);continue}C.invalid.delete(ie);let g=await f(C.values[ie],C,ue,P);C.output+=jme.unstyle(g);continue}ue.placeholder=!1;let Be=ee;ee=await p(ee,C,ue,P),le!==ee?(C.values[ie]=le,ee=t.styles.typing(le),C.missing.delete(pe)):(C.values[ie]=void 0,le=`<${pe}>`,ee=t.styles.primary(le),ue.placeholder=!0,C.required.has(ie)&&C.missing.add(pe)),C.missing.has(pe)&&C.validating&&(ee=t.styles.warning(le)),C.invalid.has(ie)&&C.validating&&(ee=t.styles.danger(le)),P===C.index&&(Be!==ee?ee=t.styles.underline(ee):ee=t.styles.heading(jme.unstyle(ee))),P++}ee&&(C.output+=ee)}let R=C.output.split(`
`).map(W=>" "+W),N=n.length,U=0;for(let W of n)C.invalid.has(W.name)&&W.lines.forEach(ee=>{R[ee][0]===" "&&(R[ee]=C.styles.danger(C.symbols.bullet)+R[ee].slice(1))}),t.isValue(C.values[W.name])&&U++;return C.completed=(U/N*100).toFixed(0),C.output=R.join(`
`),C.output}};function F5(t,e,r,s){return(a,n,c,f)=>typeof c.field[t]=="function"?c.field[t].call(e,a,n,c,f):[s,a].find(p=>e.isValue(p))}});var Yme=_((vjt,Wme)=>{"use strict";var blt=Ju(),Plt=qme(),xlt=nC(),O5=class extends xlt{constructor(e){super(e),this.cursorHide(),this.reset(!0)}async initialize(){this.interpolate=await Plt(this),await super.initialize()}async reset(e){this.state.keys=[],this.state.invalid=new Map,this.state.missing=new Set,this.state.completed=0,this.state.values={},e!==!0&&(await this.initialize(),await this.render())}moveCursor(e){let r=this.getItem();this.cursor+=e,r.cursor+=e}dispatch(e,r){if(!r.code&&!r.ctrl&&e!=null&&this.getItem()){this.append(e,r);return}this.alert()}append(e,r){let s=this.getItem(),a=s.input.slice(0,this.cursor),n=s.input.slice(this.cursor);this.input=s.input=`${a}${e}${n}`,this.moveCursor(1),this.render()}delete(){let e=this.getItem();if(this.cursor<=0||!e.input)return this.alert();let r=e.input.slice(this.cursor),s=e.input.slice(0,this.cursor-1);this.input=e.input=`${s}${r}`,this.moveCursor(-1),this.render()}increment(e){return e>=this.state.keys.length-1?0:e+1}decrement(e){return e<=0?this.state.keys.length-1:e-1}first(){this.state.index=0,this.render()}last(){this.state.index=this.state.keys.length-1,this.render()}right(){if(this.cursor>=this.input.length)return this.alert();this.moveCursor(1),this.render()}left(){if(this.cursor<=0)return this.alert();this.moveCursor(-1),this.render()}prev(){this.state.index=this.decrement(this.state.index),this.getItem(),this.render()}next(){this.state.index=this.increment(this.state.index),this.getItem(),this.render()}up(){this.prev()}down(){this.next()}format(e){let r=this.state.completed<100?this.styles.warning:this.styles.success;return this.state.submitted===!0&&this.state.completed!==100&&(r=this.styles.danger),r(`${this.state.completed}% completed`)}async render(){let{index:e,keys:r=[],submitted:s,size:a}=this.state,n=[this.options.newline,`
`].find(W=>W!=null),c=await this.prefix(),f=await this.separator(),p=await this.message(),h=[c,p,f].filter(Boolean).join(" ");this.state.prompt=h;let E=await this.header(),C=await this.error()||"",S=await this.hint()||"",P=s?"":await this.interpolate(this.state),I=this.state.key=r[e]||"",R=await this.format(I),N=await this.footer();R&&(h+=" "+R),S&&!R&&this.state.completed===0&&(h+=" "+S),this.clear(a);let U=[E,h,P,N,C.trim()];this.write(U.filter(Boolean).join(n)),this.restore()}getItem(e){let{items:r,keys:s,index:a}=this.state,n=r.find(c=>c.name===s[a]);return n&&n.input!=null&&(this.input=n.input,this.cursor=n.cursor),n}async submit(){typeof this.interpolate!="function"&&await this.initialize(),await this.interpolate(this.state,!0);let{invalid:e,missing:r,output:s,values:a}=this.state;if(e.size){let f="";for(let[p,h]of e)f+=`Invalid ${p}: ${h}
`;return this.state.error=f,super.submit()}if(r.size)return this.state.error="Required: "+[...r.keys()].join(", "),super.submit();let c=blt.unstyle(s).split(`
`).map(f=>f.slice(1)).join(`
`);return this.value={values:a,result:c},super.submit()}};Wme.exports=O5});var Jme=_((Sjt,Vme)=>{"use strict";var klt="(Use <shift>+<up/down> to sort)",Qlt=G0(),L5=class extends Qlt{constructor(e){super({...e,reorder:!1,sort:!0,multiple:!0}),this.state.hint=[this.options.hint,klt].find(this.isValue.bind(this))}indicator(){return""}async renderChoice(e,r){let s=await super.renderChoice(e,r),a=this.symbols.identicalTo+" ",n=this.index===r&&this.sorting?this.styles.muted(a):" ";return this.options.drag===!1&&(n=""),this.options.numbered===!0?n+`${r+1} - `+s:n+s}get selected(){return this.choices}submit(){return this.value=this.choices.map(e=>e.value),super.submit()}};Vme.exports=L5});var zme=_((Djt,Kme)=>{"use strict";var Tlt=Wv(),M5=class extends Tlt{constructor(e={}){if(super(e),this.emptyError=e.emptyError||"No items were selected",this.term=process.env.TERM_PROGRAM,!this.options.header){let r=["","4 - Strongly Agree","3 - Agree","2 - Neutral","1 - Disagree","0 - Strongly Disagree",""];r=r.map(s=>this.styles.muted(s)),this.state.header=r.join(`
`)}}async toChoices(...e){if(this.createdScales)return!1;this.createdScales=!0;let r=await super.toChoices(...e);for(let s of r)s.scale=Rlt(5,this.options),s.scaleIdx=2;return r}dispatch(){this.alert()}space(){let e=this.focused,r=e.scale[e.scaleIdx],s=r.selected;return e.scale.forEach(a=>a.selected=!1),r.selected=!s,this.render()}indicator(){return""}pointer(){return""}separator(){return this.styles.muted(this.symbols.ellipsis)}right(){let e=this.focused;return e.scaleIdx>=e.scale.length-1?this.alert():(e.scaleIdx++,this.render())}left(){let e=this.focused;return e.scaleIdx<=0?this.alert():(e.scaleIdx--,this.render())}indent(){return" "}async renderChoice(e,r){await this.onChoice(e,r);let s=this.index===r,a=this.term==="Hyper",n=a?9:8,c=a?"":" ",f=this.symbols.line.repeat(n),p=" ".repeat(n+(a?0:1)),h=ee=>(ee?this.styles.success("\u25C9"):"\u25EF")+c,E=r+1+".",C=s?this.styles.heading:this.styles.noop,S=await this.resolve(e.message,this.state,e,r),P=this.indent(e),I=P+e.scale.map((ee,ie)=>h(ie===e.scaleIdx)).join(f),R=ee=>ee===e.scaleIdx?C(ee):ee,N=P+e.scale.map((ee,ie)=>R(ie)).join(p),U=()=>[E,S].filter(Boolean).join(" "),W=()=>[U(),I,N," "].filter(Boolean).join(`
`);return s&&(I=this.styles.cyan(I),N=this.styles.cyan(N)),W()}async renderChoices(){if(this.state.submitted)return"";let e=this.visible.map(async(s,a)=>await this.renderChoice(s,a)),r=await Promise.all(e);return r.length||r.push(this.styles.danger("No matching choices")),r.join(`
`)}format(){return this.state.submitted?this.choices.map(r=>this.styles.info(r.scaleIdx)).join(", "):""}async render(){let{submitted:e,size:r}=this.state,s=await this.prefix(),a=await this.separator(),n=await this.message(),c=[s,n,a].filter(Boolean).join(" ");this.state.prompt=c;let f=await this.header(),p=await this.format(),h=await this.error()||await this.hint(),E=await this.renderChoices(),C=await this.footer();(p||!h)&&(c+=" "+p),h&&!c.includes(h)&&(c+=" "+h),e&&!p&&!E&&this.multiple&&this.type!=="form"&&(c+=this.styles.danger(this.emptyError)),this.clear(r),this.write([c,f,E,C].filter(Boolean).join(`
`)),this.restore()}submit(){this.value={};for(let e of this.choices)this.value[e.name]=e.scaleIdx;return this.base.submit.call(this)}};function Rlt(t,e={}){if(Array.isArray(e.scale))return e.scale.map(s=>({...s}));let r=[];for(let s=1;s<t+1;s++)r.push({i:s,selected:!1});return r}Kme.exports=M5});var Zme=_((bjt,Xme)=>{Xme.exports=D5()});var eye=_((Pjt,$me)=>{"use strict";var Flt=ZR(),U5=class extends Flt{async initialize(){await super.initialize(),this.value=this.initial=!!this.options.initial,this.disabled=this.options.disabled||"no",this.enabled=this.options.enabled||"yes",await this.render()}reset(){this.value=this.initial,this.render()}delete(){this.alert()}toggle(){this.value=!this.value,this.render()}enable(){if(this.value===!0)return this.alert();this.value=!0,this.render()}disable(){if(this.value===!1)return this.alert();this.value=!1,this.render()}up(){this.toggle()}down(){this.toggle()}right(){this.toggle()}left(){this.toggle()}next(){this.toggle()}prev(){this.toggle()}dispatch(e="",r){switch(e.toLowerCase()){case" ":return this.toggle();case"1":case"y":case"t":return this.enable();case"0":case"n":case"f":return this.disable();default:return this.alert()}}format(){let e=s=>this.styles.primary.underline(s);return[this.value?this.disabled:e(this.disabled),this.value?e(this.enabled):this.enabled].join(this.styles.muted(" / "))}async render(){let{size:e}=this.state,r=await this.header(),s=await this.prefix(),a=await this.separator(),n=await this.message(),c=await this.format(),f=await this.error()||await this.hint(),p=await this.footer(),h=[s,n,a,c].join(" ");this.state.prompt=h,f&&!h.includes(f)&&(h+=" "+f),this.clear(e),this.write([r,h,p].filter(Boolean).join(`
`)),this.write(this.margin[2]),this.restore()}};$me.exports=U5});var rye=_((xjt,tye)=>{"use strict";var Nlt=G0(),_5=class extends Nlt{constructor(e){if(super(e),typeof this.options.correctChoice!="number"||this.options.correctChoice<0)throw new Error("Please specify the index of the correct answer from the list of choices")}async toChoices(e,r){let s=await super.toChoices(e,r);if(s.length<2)throw new Error("Please give at least two choices to the user");if(this.options.correctChoice>s.length)throw new Error("Please specify the index of the correct answer from the list of choices");return s}check(e){return e.index===this.options.correctChoice}async result(e){return{selectedAnswer:e,correctAnswer:this.options.choices[this.options.correctChoice].value,correct:await this.check(this.state)}}};tye.exports=_5});var iye=_(H5=>{"use strict";var nye=Zo(),ks=(t,e)=>{nye.defineExport(H5,t,e),nye.defineExport(H5,t.toLowerCase(),e)};ks("AutoComplete",()=>ume());ks("BasicAuth",()=>mme());ks("Confirm",()=>Ime());ks("Editable",()=>wme());ks("Form",()=>XR());ks("Input",()=>D5());ks("Invisible",()=>xme());ks("List",()=>Qme());ks("MultiSelect",()=>Rme());ks("Numeral",()=>Ome());ks("Password",()=>Mme());ks("Scale",()=>Hme());ks("Select",()=>G0());ks("Snippet",()=>Yme());ks("Sort",()=>Jme());ks("Survey",()=>zme());ks("Text",()=>Zme());ks("Toggle",()=>eye());ks("Quiz",()=>rye())});var oye=_((Qjt,sye)=>{sye.exports={ArrayPrompt:Wv(),AuthPrompt:I5(),BooleanPrompt:ZR(),NumberPrompt:Q5(),StringPrompt:vm()}});var Vv=_((Tjt,lye)=>{"use strict";var aye=Ie("assert"),G5=Ie("events"),q0=Zo(),zu=class extends G5{constructor(e,r){super(),this.options=q0.merge({},e),this.answers={...r}}register(e,r){if(q0.isObject(e)){for(let a of Object.keys(e))this.register(a,e[a]);return this}aye.equal(typeof r,"function","expected a function");let s=e.toLowerCase();return r.prototype instanceof this.Prompt?this.prompts[s]=r:this.prompts[s]=r(this.Prompt,this),this}async prompt(e=[]){for(let r of[].concat(e))try{typeof r=="function"&&(r=await r.call(this)),await this.ask(q0.merge({},this.options,r))}catch(s){return Promise.reject(s)}return this.answers}async ask(e){typeof e=="function"&&(e=await e.call(this));let r=q0.merge({},this.options,e),{type:s,name:a}=e,{set:n,get:c}=q0;if(typeof s=="function"&&(s=await s.call(this,e,this.answers)),!s)return this.answers[a];aye(this.prompts[s],`Prompt "${s}" is not registered`);let f=new this.prompts[s](r),p=c(this.answers,a);f.state.answers=this.answers,f.enquirer=this,a&&f.on("submit",E=>{this.emit("answer",a,E,f),n(this.answers,a,E)});let h=f.emit.bind(f);return f.emit=(...E)=>(this.emit.call(this,...E),h(...E)),this.emit("prompt",f,this),r.autofill&&p!=null?(f.value=f.input=p,r.autofill==="show"&&await f.submit()):p=f.value=await f.run(),p}use(e){return e.call(this,this),this}set Prompt(e){this._Prompt=e}get Prompt(){return this._Prompt||this.constructor.Prompt}get prompts(){return this.constructor.prompts}static set Prompt(e){this._Prompt=e}static get Prompt(){return this._Prompt||nC()}static get prompts(){return iye()}static get types(){return oye()}static get prompt(){let e=(r,...s)=>{let a=new this(...s),n=a.emit.bind(a);return a.emit=(...c)=>(e.emit(...c),n(...c)),a.prompt(r)};return q0.mixinEmitter(e,new G5),e}};q0.mixinEmitter(zu,new G5);var j5=zu.prompts;for(let t of Object.keys(j5)){let e=t.toLowerCase(),r=s=>new j5[t](s).run();zu.prompt[e]=r,zu[e]=r,zu[t]||Reflect.defineProperty(zu,t,{get:()=>j5[t]})}var Yv=t=>{q0.defineExport(zu,t,()=>zu.types[t])};Yv("ArrayPrompt");Yv("AuthPrompt");Yv("BooleanPrompt");Yv("NumberPrompt");Yv("StringPrompt");lye.exports=zu});var dye=_((tGt,qlt)=>{qlt.exports={name:"@yarnpkg/cli",version:"4.12.0",license:"BSD-2-Clause",main:"./sources/index.ts",exports:{".":"./sources/index.ts","./polyfills":"./sources/polyfills.ts","./package.json":"./package.json"},dependencies:{"@yarnpkg/core":"workspace:^","@yarnpkg/fslib":"workspace:^","@yarnpkg/libzip":"workspace:^","@yarnpkg/parsers":"workspace:^","@yarnpkg/plugin-catalog":"workspace:^","@yarnpkg/plugin-compat":"workspace:^","@yarnpkg/plugin-constraints":"workspace:^","@yarnpkg/plugin-dlx":"workspace:^","@yarnpkg/plugin-essentials":"workspace:^","@yarnpkg/plugin-exec":"workspace:^","@yarnpkg/plugin-file":"workspace:^","@yarnpkg/plugin-git":"workspace:^","@yarnpkg/plugin-github":"workspace:^","@yarnpkg/plugin-http":"workspace:^","@yarnpkg/plugin-init":"workspace:^","@yarnpkg/plugin-interactive-tools":"workspace:^","@yarnpkg/plugin-jsr":"workspace:^","@yarnpkg/plugin-link":"workspace:^","@yarnpkg/plugin-nm":"workspace:^","@yarnpkg/plugin-npm":"workspace:^","@yarnpkg/plugin-npm-cli":"workspace:^","@yarnpkg/plugin-pack":"workspace:^","@yarnpkg/plugin-patch":"workspace:^","@yarnpkg/plugin-pnp":"workspace:^","@yarnpkg/plugin-pnpm":"workspace:^","@yarnpkg/plugin-stage":"workspace:^","@yarnpkg/plugin-typescript":"workspace:^","@yarnpkg/plugin-version":"workspace:^","@yarnpkg/plugin-workspace-tools":"workspace:^","@yarnpkg/shell":"workspa Line truncated
${W} at ${ee}`:`
${W}`}).join("");h.push({text:`Conflict detected in constraint targeting ${he.pretty(t.configuration,P,he.Type.CODE)}; conflicting values are:${R}`,fixable:!1})}else{let[[R]]=I,N=va(S,P);if(JSON.stringify(N)===JSON.stringify(R))continue;if(!s){let U=typeof N>"u"?`Missing field ${he.pretty(t.configuration,P,he.Type.CODE)}; expected ${he.pretty(t.configuration,R,he.Type.INSPECT)}`:typeof R>"u"?`Extraneous field ${he.pretty(t.configuration,P,he.Type.CODE)} currently set to ${he.pretty(t.configuration,N,he.Type.INSPECT)}`:`Invalid field ${he.pretty(t.configuration,P,he.Type.CODE)}; expected ${he.pretty(t.configuration,R,he.Type.INSPECT)}, found ${he.pretty(t.configuration,N,he.Type.INSPECT)}`;h.push({text:U,fixable:!0});continue}typeof R>"u"?A0(S,P):Jd(S,P,R),E=!0}E&&a.set(C,S)}h.length>0&&n.set(C,h)}return{changedWorkspaces:a,remainingErrors:n}}function rEe(t,{configuration:e}){let r={children:[]};for(let[s,a]of t){let n=[];for(let f of a){let p=f.text.split(/\n/);f.fixable&&(p[0]=`${he.pretty(e,"\u2699","gray")} ${p[0]}`),n.push({value:he.tuple(he.Type.NO_HINT,p[0]),children:p.slice(1).map(h=>({value:he.tuple(he.Type.NO_HINT,h)}))})}let c={value:he.tuple(he.Type.LOCATOR,s.anchoredLocator),children:je.sortMap(n,f=>f.value[1])};r.children.push(c)}return r.children=je.sortMap(r.children,s=>s.value[1]),r}var WC,Uct,_ct,Hct,iS=Xe(()=>{Ge();ql();WC=class{constructor(e){this.indexedFields=e;this.items=[];this.indexes={};this.clear()}clear(){this.items=[];for(let e of this.indexedFields)this.indexes[e]=new Map}insert(e){this.items.push(e);for(let r of this.indexedFields){let s=Object.hasOwn(e,r)?e[r]:void 0;if(typeof s>"u")continue;je.getArrayWithDefault(this.indexes[r],s).push(e)}return e}find(e){if(typeof e>"u")return this.items;let r=Object.entries(e);if(r.length===0)return this.items;let s=[],a;for(let[c,f]of r){let p=c,h=Object.hasOwn(this.indexes,p)?this.indexes[p]:void 0;if(typeof h>"u"){s.push([p,f]);continue}let E=new Set(h.get(f)??[]);if(E.size===0)return[];if(typeof a>"u")a=E;else for(let C of a)E.has(C)||a.delete(C);if(a.size===0)break}let n=[...a??[]];return s.length>0&&(n=n.filter(c=>{for(let[f,p]of s)if(!(typeof p<"u"?Object.hasOwn(c,f)&&c[f]===p:Object.hasOwn(c,f)===!1))return!1;return!0})),n}},Uct=/^[0-9]+$/,_ct=/^[a-zA-Z0-9_]+$/,Hct=new Set(["scripts",...Ut.allDependencies])});var nEe=_((_Yt,vq)=>{var qct;(function(t){var e=function(){return{"append/2":[new t.type.Rule(new t.type.Term("append",[new t.type.Var("X"),new t.type.Var("L")]),new t.type.Term("foldl",[new t.type.Term("append",[]),new t.type.Var("X"),new t.type.Term("[]",[]),new t.type.Var("L")]))],"append/3":[new t.type.Rule(new t.type.Term("append",[new t.type.Term("[]",[]),new t.type.Var("X"),new t.type.Var("X")]),null),new t.type.Rule(new t.type.Term("append",[new t.type.Term(".",[new t.type.Var("H"),new t.type.Var("T")]),new t.type.Var("X"),new t.type.Term(".",[new t.type.Var("H"),new t.type.Var("S")])]),new t.type.Term("append",[new t.type.Var("T"),new t.type.Var("X"),new t.type.Var("S")]))],"member/2":[new t.type.Rule(new t.type.Term("member",[new t.type.Var("X"),new t.type.Term(".",[new t.type.Var("X"),new t.type.Var("_")])]),null),new t.type.Rule(new t.type.Term("member",[new t.type.Var("X"),new t.type.Term(".",[new t.type.Var("_"),new t.type.Var("Xs")])]),new t.type.Term("member",[new t.type.Var("X"),new t.type.Var("Xs")]))],"permutation/2":[new t.type.Rule(new t.type.Term("permutation",[new t.type.Term("[]",[]),new t.type.Term("[]",[])]),null),new t.type.Rule(new t.type.Term("permutation",[new t.type.Term(".",[new t.type.Var("H"),new t.type.Var("T")]),new t.type.Var("S")]),new t.type.Term(",",[new t.type.Term("permutation",[new t.type.Var("T"),new t.type.Var("P")]),new t.type.Term(",",[new t.type.Term("append",[new t.type.Var("X"),new t.type.Var("Y"),new t.type.Var("P")]),new t.type.Term("append",[new t.type.Var("X"),new t.type.Term(".",[new t.type.Var("H"),new t.type.Var("Y")]),new t.type.Var("S")])])]))],"maplist/2":[new t.type.Rule(new t.type.Term("maplist",[new t.type.Var("_"),new t.type.Term("[]",[])]),null),new t.type.Rule(new t.type.Term("maplist",[new t.type.Var("P"),new t.type.Term(".",[new t.type.Var("X"),new t.type.Var("Xs")])]),new t.type.Term(",",[new t.type.Term("call",[new t.type.Var("P"),new t.type.Var("X")]),new t.type.Term("maplist",[new t.type.Var("P"),new t.type.Var("Xs")])]))],"maplist/3":[new t.type.Rule(new t.type.Term("maplist",[new t.type.Var("_"),new t.type.Term("[]",[]),new t.type.Term("[]",[])]),null),new t.type.Rule(new t.type.Term("maplist",[new t.type.Var("P"),new t.type.Term(".",[new t.type.Var("A"),new t.type.Var("As")]),new t.type.Term(".",[new t.type.Var("B"),new t.type.Var("Bs")])]),new t.type.Term(",",[new t.type.Term("call",[new t.type.Var("P"),new t.type.Var("A"),new t.type.Var("B")]),new t.type.Term("maplist",[new t.type.Var("P"),new t.type.Var("As"),new t.type.Var("Bs")])]))],"maplist/4":[new t.type.Rule(new t.type.Term("maplist",[new t.type.Var("_"),new t.type.Term("[]",[]),new t.type.Ter Line truncated
`+p:"")),c.error.method="_execFileSync",c.error.program=a,c.error.args=n,c.error.extMessage=p,c.error.exitCode=+f),si.unlinkSync(h),si.unlinkSync(E),si.unlinkSync(C),si.unlinkSync(S),c}function Jct(t){var e,r={},s,a={env:process.env,encoding:t.encoding};if(Y0||(bm?process.env.PSModulePath?(Y0="powershell.exe",oF=["-ExecutionPolicy","Bypass","-File",__dirname+"\\read.ps1"]):(Y0="cscript.exe",oF=["//nologo",__dirname+"\\read.cs.js"]):(Y0="/bin/sh",oF=[__dirname+"/read.sh"])),bm&&!process.env.PSModulePath&&(a.stdio=[process.stdin]),bq.execFileSync){e=lEe(t),sS&&sS("execFileSync",e);try{r.input=bq.execFileSync(Y0,e,a)}catch(n){s=n.stderr?(n.stderr+"").trim():"",r.error=new Error(oEe+(s?`
`+s:"")),r.error.method="execFileSync",r.error.program=Y0,r.error.args=e,r.error.extMessage=s,r.error.exitCode=n.status,r.error.code=n.code,r.error.signal=n.signal}}else r=Vct(t,a);return r.error||(r.input=r.input.replace(/^\s*'|'\s*$/g,""),t.display=""),r}function kq(t){var e="",r=t.display,s=!t.display&&t.keyIn&&t.hideEchoBack&&!t.mask;function a(){var n=Jct(t);if(n.error)throw n.error;return n.input}return xq&&xq(t),function(){var n,c,f;function p(){return n||(n=process.binding("fs"),c=process.binding("constants")),n}if(typeof Xp=="string")if(Xp=null,bm){if(f=function(h){var E=h.replace(/^\D+/,"").split("."),C=0;return(E[0]=+E[0])&&(C+=E[0]*1e4),(E[1]=+E[1])&&(C+=E[1]*100),(E[2]=+E[2])&&(C+=E[2]),C}(process.version),!(f>=20302&&f<40204||f>=5e4&&f<50100||f>=50600&&f<60200)&&process.stdin.isTTY)process.stdin.pause(),Xp=process.stdin.fd,VC=process.stdin._handle;else try{Xp=p().open("CONIN$",c.O_RDWR,parseInt("0666",8)),VC=new iEe(Xp,!0)}catch{}if(process.stdout.isTTY)Zu=process.stdout.fd;else{try{Zu=si.openSync("\\\\.\\CON","w")}catch{}if(typeof Zu!="number")try{Zu=p().open("CONOUT$",c.O_RDWR,parseInt("0666",8))}catch{}}}else{if(process.stdin.isTTY){process.stdin.pause();try{Xp=si.openSync("/dev/tty","r"),VC=process.stdin._handle}catch{}}else try{Xp=si.openSync("/dev/tty","r"),VC=new iEe(Xp,!1)}catch{}if(process.stdout.isTTY)Zu=process.stdout.fd;else try{Zu=si.openSync("/dev/tty","w")}catch{}}}(),function(){var n,c,f=!t.hideEchoBack&&!t.keyIn,p,h,E,C,S;aF="";function P(I){return I===sEe?!0:VC.setRawMode(I)!==0?!1:(sEe=I,!0)}if(aEe||!VC||typeof Zu!="number"&&(t.display||!f)){e=a();return}if(t.display&&(si.writeSync(Zu,t.display),t.display=""),!t.displayOnly){if(!P(!f)){e=a();return}for(h=t.keyIn?1:t.bufferSize,p=Buffer.allocUnsafe&&Buffer.alloc?Buffer.alloc(h):new Buffer(h),t.keyIn&&t.limit&&(c=new RegExp("[^"+t.limit+"]","g"+(t.caseSensitive?"":"i")));;){E=0;try{E=si.readSync(Xp,p,0,h)}catch(I){if(I.code!=="EOF"){P(!1),e+=a();return}}if(E>0?(C=p.toString(t.encoding,0,E),aF+=C):(C=`
`,aF+="\0"),C&&typeof(S=(C.match(/^(.*?)[\r\n]/)||[])[1])=="string"&&(C=S,n=!0),C&&(C=C.replace(/[\x00-\x08\x0b\x0c\x0e-\x1f\x7f]/g,"")),C&&c&&(C=C.replace(c,"")),C&&(f||(t.hideEchoBack?t.mask&&si.writeSync(Zu,new Array(C.length+1).join(t.mask)):si.writeSync(Zu,C)),e+=C),!t.keyIn&&n||t.keyIn&&e.length>=h)break}!f&&!s&&si.writeSync(Zu,`
`),P(!1)}}(),t.print&&!s&&t.print(r+(t.displayOnly?"":(t.hideEchoBack?new Array(e.length+1).join(t.mask):e)+`
`),t.encoding),t.displayOnly?"":Rq=t.keepWhitespace||t.keyIn?e:e.trim()}function Kct(t,e){var r=[];function s(a){a!=null&&(Array.isArray(a)?a.forEach(s):(!e||e(a))&&r.push(a))}return s(t),r}function Fq(t){return t.replace(/[\x00-\x7f]/g,function(e){return"\\x"+("00"+e.charCodeAt().toString(16)).substr(-2)})}function Vs(){var t=Array.prototype.slice.call(arguments),e,r;return t.length&&typeof t[0]=="boolean"&&(r=t.shift(),r&&(e=Object.keys(Pq),t.unshift(Pq))),t.reduce(function(s,a){return a==null||(a.hasOwnProperty("noEchoBack")&&!a.hasOwnProperty("hideEchoBack")&&(a.hideEchoBack=a.noEchoBack,delete a.noEchoBack),a.hasOwnProperty("noTrim")&&!a.hasOwnProperty("keepWhitespace")&&(a.keepWhitespace=a.noTrim,delete a.noTrim),r||(e=Object.keys(a)),e.forEach(function(n){var c;if(a.hasOwnProperty(n))switch(c=a[n],n){case"mask":case"limitMessage":case"defaultInput":case"encoding":c=c!=null?c+"":"",c&&n!=="limitMessage"&&(c=c.replace(/[\r\n]/g,"")),s[n]=c;break;case"bufferSize":!isNaN(c=parseInt(c,10))&&typeof c=="number"&&(s[n]=c);break;case"displayOnly":case"keyIn":case"hideEchoBack":case"caseSensitive":case"keepWhitespace":case"history":case"cd":s[n]=!!c;break;case"limit":case"trueValue":case"falseValue":s[n]=Kct(c,function(f){var p=typeof f;return p==="string"||p==="number"||p==="function"||f instanceof RegExp}).map(function(f){return typeof f=="string"?f.replace(/[\r\n]/g,""):f});break;case"print":case"phContent":case"preCheck":s[n]=typeof c=="function"?c:void 0;break;case"prompt":case"display":s[n]=c??"";break}})),s},{})}function Qq(t,e,r){return e.some(function(s){var a=typeof s;return a==="string"?r?t===s:t.toLowerCase()===s.toLowerCase():a==="number"?parseFloat(t)===s:a==="function"?s(t):s instanceof RegExp?s.test(t):!1})}function Nq(t,e){var r=V0.normalize(bm?(process.env.HOMEDRIVE||"")+(process.env.HOMEPATH||""):process.env.HOME||"").replace(/[\/\\]+$/,"");return t=V0.normalize(t),e?t.replace(/^~(?=\/|\\|$)/,r):t.replace(new RegExp("^"+Fq(r)+"(?=\\/|\\\\|$)",bm?"i":""),"~")}function JC(t,e){var r="(?:\\(([\\s\\S]*?)\\))?(\\w+|.-.)(?:\\(([\\s\\S]*?)\\))?",s=new RegExp("(\\$)?(\\$<"+r+">)","g"),a=new RegExp("(\\$)?(\\$\\{"+r+"\\})","g");function n(c,f,p,h,E,C){var S;return f||typeof(S=e(E))!="string"?p:S?(h||"")+S+(C||""):""}return t.replace(s,n).replace(a,n)}function cEe(t,e,r){var s,a=[],n=-1,c=0,f="",p;function h(E,C){return C.length>3?(E.push(C[0]+"..."+C[C.length-1]),p=!0):C.length&&(E=E.concat(C)),E}return s=t.reduce(function(E,C){return E.concat((C+"").split(""))},[]).reduce(function(E,C){var S,P;return e||(C=C.toLowerCase()),S=/^\d$/.test(C)?1:/^[A-Z]$/.test(C)?2:/^[a-z]$/.test(C)?3:0,r&&S===0?f+=C:(P=C.charCodeAt(0),S&&S===n&&P===c+1?a.push(C):(E=h(E,a),a=[C],n=S),c=P),E},[]),s=h(s,a),f&&(s.push(f),p=!0),{values:s,suppressed:p}}function uEe(t,e){return t.join(t.length>2?", ":e?" / ":"/")}function fEe(t,e){var r,s,a={},n;if(e.phContent&&(r=e.phContent(t,e)),typeof r!="string")switch(t){case"hideEchoBack":case"mask":case"defaultInput":case"caseSensitive":case"keepWhitespace":case"encoding":case"bufferSize":case"history":case"cd":r=e.hasOwnProperty(t)?typeof e[t]=="boolean"?e[t]?"on":"off":e[t]+"":"";break;case"limit":case"trueValue":case"falseValue":s=e[e.hasOwnProperty(t+"Src")?t+"Src":t],e.keyIn?(a=cEe(s,e.caseSensitive),s=a.values):s=s.filter(function(c){var f=typeof c;return f==="string"||f==="number"}),r=uEe(s,a.suppressed);break;case"limitCount":case"limitCountNotZero":r=e[e.hasOwnProperty("limitSrc")?"limitSrc":"limit"].length,r=r||t!=="limitCountNotZero"?r+"":"";break;case"lastInput":r=Rq;break;case"cwd":case"CWD":case"cwdHome":r=process.cwd(),t==="CWD"?r=V0.basename(r):t==="cwdHome"&&(r=Nq(r));break;case"date":case"time":case"localeDate":case"localeTime":r=new Date()["to"+t.replace(/^./,function(c){return c.toUpperCase()})+"String"]();break;default:typeof(n=(t.match(/^history_m(\d+)$/)||[])[1])=="string"&&(r=Dm[Dm.length-n]||"")}return r}function AEe(t){var e=/^(.)-(.)$/.exec(t),r="",s,a,n,c;if(!e)return null;for(s=e[1].charCodeAt(0),a=e[2].charCodeAt(0),c=s<a?1:-1,n=s;n!==a+c;n+=c)r+=String.fromCharCode(n);return r}function Tq(t){var e=new RegExp(/(\s*)(?:("|')(.*?)(?:\2|$)|(\S+))/g),r,s="",a=[],n;for(t=t.trim();r=e.exec(t);)n=r[3]||r[4]||"",r[1]&&(a.push(s),s=""),s+=n;return s&&a.push(s),a}function pEe(t,e){return e.trueValue.length&&Qq(t,e.trueValue,e.caseSensitive)?!0:e.falseValue.length&&Qq(t,e.falseValue,e.caseSensitive)?!1:t}function hEe(t){var e,r,s,a,n,c,f;function p(E){return fEe(E,t)}function h(E){t.display+=(/[^\r\n]$/.test(t.display)?`
`:"")+E}for(t.limitSrc=t.limit,t.displaySrc=t.display,t.limit="",t.display=JC(t.display+"",p);;){if(e=kq(t),r=!1,s="",t.defaultInput&&!e&&(e=t.defaultInput),t.history&&((a=/^\s*\!(?:\!|-1)(:p)?\s*$/.exec(e))?(n=Dm[0]||"",a[1]?r=!0:e=n,h(n+`
`),r||(t.displayOnly=!0,kq(t),t.displayOnly=!1)):e&&e!==Dm[Dm.length-1]&&(Dm=[e])),!r&&t.cd&&e)switch(c=Tq(e),c[0].toLowerCase()){case"cd":if(c[1])try{process.chdir(Nq(c[1],!0))}catch(E){h(E+"")}r=!0;break;case"pwd":h(process.cwd()),r=!0;break}if(!r&&t.preCheck&&(f=t.preCheck(e,t),e=f.res,f.forceNext&&(r=!0)),!r){if(!t.limitSrc.length||Qq(e,t.limitSrc,t.caseSensitive))break;t.limitMessage&&(s=JC(t.limitMessage,p))}h((s?s+`
`:"")+JC(t.displaySrc+"",p))}return pEe(e,t)}$r._DBG_set_useExt=function(t){aEe=t};$r._DBG_set_checkOptions=function(t){xq=t};$r._DBG_set_checkMethod=function(t){sS=t};$r._DBG_clearHistory=function(){Rq="",Dm=[]};$r.setDefaultOptions=function(t){return Pq=Vs(!0,t),Vs(!0)};$r.question=function(t,e){return hEe(Vs(Vs(!0,e),{display:t}))};$r.prompt=function(t){var e=Vs(!0,t);return e.display=e.prompt,hEe(e)};$r.keyIn=function(t,e){var r=Vs(Vs(!0,e),{display:t,keyIn:!0,keepWhitespace:!0});return r.limitSrc=r.limit.filter(function(s){var a=typeof s;return a==="string"||a==="number"}).map(function(s){return JC(s+"",AEe)}),r.limit=Fq(r.limitSrc.join("")),["trueValue","falseValue"].forEach(function(s){r[s]=r[s].reduce(function(a,n){var c=typeof n;return c==="string"||c==="number"?a=a.concat((n+"").split("")):a.push(n),a},[])}),r.display=JC(r.display+"",function(s){return fEe(s,r)}),pEe(kq(r),r)};$r.questionEMail=function(t,e){return t==null&&(t="Input e-mail address: "),$r.question(t,Vs({hideEchoBack:!1,limit:/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,limitMessage:"Input valid e-mail address, please.",trueValue:null,falseValue:null},e,{keepWhitespace:!1,cd:!1}))};$r.questionNewPassword=function(t,e){var r,s,a,n=Vs({hideEchoBack:!0,mask:"*",limitMessage:`It can include: $<charlist>
And the length must be: $<length>`,trueValue:null,falseValue:null,caseSensitive:!0},e,{history:!1,cd:!1,phContent:function(P){return P==="charlist"?r.text:P==="length"?s+"..."+a:null}}),c,f,p,h,E,C,S;for(e=e||{},c=JC(e.charlist?e.charlist+"":"$<!-~>",AEe),(isNaN(s=parseInt(e.min,10))||typeof s!="number")&&(s=12),(isNaN(a=parseInt(e.max,10))||typeof a!="number")&&(a=24),h=new RegExp("^["+Fq(c)+"]{"+s+","+a+"}$"),r=cEe([c],n.caseSensitive,!0),r.text=uEe(r.values,r.suppressed),f=e.confirmMessage!=null?e.confirmMessage:"Reinput a same one to confirm it: ",p=e.unmatchMessage!=null?e.unmatchMessage:"It differs from first one. Hit only the Enter key if you want to retry from first one.",t==null&&(t="Input new password: "),E=n.limitMessage;!S;)n.limit=h,n.limitMessage=E,C=$r.question(t,n),n.limit=[C,""],n.limitMessage=p,S=$r.question(f,n);return C};function gEe(t,e,r){var s;function a(n){return s=r(n),!isNaN(s)&&typeof s=="number"}return $r.question(t,Vs({limitMessage:"Input valid number, please."},e,{limit:a,cd:!1})),s}$r.questionInt=function(t,e){return gEe(t,e,function(r){return parseInt(r,10)})};$r.questionFloat=function(t,e){return gEe(t,e,parseFloat)};$r.questionPath=function(t,e){var r,s="",a=Vs({hideEchoBack:!1,limitMessage:`$<error(
)>Input valid path, please.$<( Min:)min>$<( Max:)max>`,history:!0,cd:!0},e,{keepWhitespace:!1,limit:function(n){var c,f,p;n=Nq(n,!0),s="";function h(E){E.split(/\/|\\/).reduce(function(C,S){var P=V0.resolve(C+=S+V0.sep);if(!si.existsSync(P))si.mkdirSync(P);else if(!si.statSync(P).isDirectory())throw new Error("Non directory already exists: "+P);return C},"")}try{if(c=si.existsSync(n),r=c?si.realpathSync(n):V0.resolve(n),!e.hasOwnProperty("exists")&&!c||typeof e.exists=="boolean"&&e.exists!==c)return s=(c?"Already exists":"No such file or directory")+": "+r,!1;if(!c&&e.create&&(e.isDirectory?h(r):(h(V0.dirname(r)),si.closeSync(si.openSync(r,"w"))),r=si.realpathSync(r)),c&&(e.min||e.max||e.isFile||e.isDirectory)){if(f=si.statSync(r),e.isFile&&!f.isFile())return s="Not file: "+r,!1;if(e.isDirectory&&!f.isDirectory())return s="Not directory: "+r,!1;if(e.min&&f.size<+e.min||e.max&&f.size>+e.max)return s="Size "+f.size+" is out of range: "+r,!1}if(typeof e.validate=="function"&&(p=e.validate(r))!==!0)return typeof p=="string"&&(s=p),!1}catch(E){return s=E+"",!1}return!0},phContent:function(n){return n==="error"?s:n!=="min"&&n!=="max"?null:e.hasOwnProperty(n)?e[n]+"":""}});return e=e||{},t==null&&(t='Input path (you can "cd" and "pwd"): '),$r.question(t,a),r};function dEe(t,e){var r={},s={};return typeof t=="object"?(Object.keys(t).forEach(function(a){typeof t[a]=="function"&&(s[e.caseSensitive?a:a.toLowerCase()]=t[a])}),r.preCheck=function(a){var n;return r.args=Tq(a),n=r.args[0]||"",e.caseSensitive||(n=n.toLowerCase()),r.hRes=n!=="_"&&s.hasOwnProperty(n)?s[n].apply(a,r.args.slice(1)):s.hasOwnProperty("_")?s._.apply(a,r.args):null,{res:a,forceNext:!1}},s.hasOwnProperty("_")||(r.limit=function(){var a=r.args[0]||"";return e.caseSensitive||(a=a.toLowerCase()),s.hasOwnProperty(a)})):r.preCheck=function(a){return r.args=Tq(a),r.hRes=typeof t=="function"?t.apply(a,r.args):!0,{res:a,forceNext:!1}},r}$r.promptCL=function(t,e){var r=Vs({hideEchoBack:!1,limitMessage:"Requested command is not available.",caseSensitive:!1,history:!0},e),s=dEe(t,r);return r.limit=s.limit,r.preCheck=s.preCheck,$r.prompt(r),s.args};$r.promptLoop=function(t,e){for(var r=Vs({hideEchoBack:!1,trueValue:null,falseValue:null,caseSensitive:!1,history:!0},e);!t($r.prompt(r)););};$r.promptCLLoop=function(t,e){var r=Vs({hideEchoBack:!1,limitMessage:"Requested command is not available.",caseSensitive:!1,history:!0},e),s=dEe(t,r);for(r.limit=s.limit,r.preCheck=s.preCheck;$r.prompt(r),!s.hRes;);};$r.promptSimShell=function(t){return $r.prompt(Vs({hideEchoBack:!1,history:!0},t,{prompt:function(){return bm?"$<cwd>>":(process.env.USER||"")+(process.env.HOSTNAME?"@"+process.env.HOSTNAME.replace(/\..*$/,""):"")+":$<cwdHome>$ "}()}))};function mEe(t,e,r){var s;return t==null&&(t="Are you sure? "),(!e||e.guide!==!1)&&(t+="")&&(t=t.replace(/\s*:?\s*$/,"")+" [y/n]: "),s=$r.keyIn(t,Vs(e,{hideEchoBack:!1,limit:r,trueValue:"y",falseValue:"n",caseSensitive:!1})),typeof s=="boolean"?s:""}$r.keyInYN=function(t,e){return mEe(t,e)};$r.keyInYNStrict=function(t,e){return mEe(t,e,"yn")};$r.keyInPause=function(t,e){t==null&&(t="Continue..."),(!e||e.guide!==!1)&&(t+="")&&(t=t.replace(/\s+$/,"")+" (Hit any key)"),$r.keyIn(t,Vs({limit:null},e,{hideEchoBack:!0,mask:""}))};$r.keyInSelect=function(t,e,r){var s=Vs({hideEchoBack:!1},r,{trueValue:null,falseValue:null,caseSensitive:!1,phContent:function(p){return p==="itemsCount"?t.length+"":p==="firstItem"?(t[0]+"").trim():p==="lastItem"?(t[t.length-1]+"").trim():null}}),a="",n={},c=49,f=`
`;if(!Array.isArray(t)||!t.length||t.length>35)throw"`items` must be Array (max length: 35).";return t.forEach(function(p,h){var E=String.fromCharCode(c);a+=E,n[E]=h,f+="["+E+"] "+(p+"").trim()+`
`,c=c===57?97:c+1}),(!r||r.cancel!==!1)&&(a+="0",n[0]=-1,f+="[0] "+(r&&r.cancel!=null&&typeof r.cancel!="boolean"?(r.cancel+"").trim():"CANCEL")+`
`),s.limit=a,f+=`
`,e==null&&(e="Choose one from list: "),(e+="")&&((!r||r.guide!==!1)&&(e=e.replace(/\s*:?\s*$/,"")+" [$<limit>]: "),f+=e),n[$r.keyIn(f,s).toLowerCase()]};$r.getRawInput=function(){return aF};function oS(t,e){var r;return e.length&&(r={},r[t]=e[0]),$r.setDefaultOptions(r)[t]}$r.setPrint=function(){return oS("print",arguments)};$r.setPrompt=function(){return oS("prompt",arguments)};$r.setEncoding=function(){return oS("encoding",arguments)};$r.setMask=function(){return oS("mask",arguments)};$r.setBufferSize=function(){return oS("bufferSize",arguments)}});var Oq=_((jYt,ec)=>{(function(){var t={major:0,minor:2,patch:66,status:"beta"};tau_file_system={files:{},open:function(w,b,y){var F=tau_file_system.files[w];if(!F){if(y==="read")return null;F={path:w,text:"",type:b,get:function(z,X){return X===this.text.length||X>this.text.length?"end_of_file":this.text.substring(X,X+z)},put:function(z,X){return X==="end_of_file"?(this.text+=z,!0):X==="past_end_of_file"?null:(this.text=this.text.substring(0,X)+z+this.text.substring(X+z.length),!0)},get_byte:function(z){if(z==="end_of_stream")return-1;var X=Math.floor(z/2);if(this.text.length<=X)return-1;var $=n(this.text[Math.floor(z/2)],0);return z%2===0?$&255:$/256>>>0},put_byte:function(z,X){var $=X==="end_of_stream"?this.text.length:Math.floor(X/2);if(this.text.length<$)return null;var oe=this.text.length===$?-1:n(this.text[Math.floor(X/2)],0);return X%2===0?(oe=oe/256>>>0,oe=(oe&255)<<8|z&255):(oe=oe&255,oe=(z&255)<<8|oe&255),this.text.length===$?this.text+=c(oe):this.text=this.text.substring(0,$)+c(oe)+this.text.substring($+1),!0},flush:function(){return!0},close:function(){var z=tau_file_system.files[this.path];return z?!0:null}},tau_file_system.files[w]=F}return y==="write"&&(F.text=""),F}},tau_user_input={buffer:"",get:function(w,b){for(var y;tau_user_input.buffer.length<w;)y=window.prompt(),y&&(tau_user_input.buffer+=y);return y=tau_user_input.buffer.substr(0,w),tau_user_input.buffer=tau_user_input.buffer.substr(w),y}},tau_user_output={put:function(w,b){return console.log(w),!0},flush:function(){return!0}},nodejs_file_system={open:function(w,b,y){var F=Ie("fs"),z=F.openSync(w,y[0]);return y==="read"&&!F.existsSync(w)?null:{get:function(X,$){var oe=new Buffer(X);return F.readSync(z,oe,0,X,$),oe.toString()},put:function(X,$){var oe=Buffer.from(X);if($==="end_of_file")F.writeSync(z,oe);else{if($==="past_end_of_file")return null;F.writeSync(z,oe,0,oe.length,$)}return!0},get_byte:function(X){return null},put_byte:function(X,$){return null},flush:function(){return!0},close:function(){return F.closeSync(z),!0}}}},nodejs_user_input={buffer:"",get:function(w,b){for(var y,F=yEe();nodejs_user_input.buffer.length<w;)nodejs_user_input.buffer+=F.question();return y=nodejs_user_input.buffer.substr(0,w),nodejs_user_input.buffer=nodejs_user_input.buffer.substr(w),y}},nodejs_user_output={put:function(w,b){return process.stdout.write(w),!0},flush:function(){return!0}};var e;Array.prototype.indexOf?e=function(w,b){return w.indexOf(b)}:e=function(w,b){for(var y=w.length,F=0;F<y;F++)if(b===w[F])return F;return-1};var r=function(w,b){if(w.length!==0){for(var y=w[0],F=w.length,z=1;z<F;z++)y=b(y,w[z]);return y}},s;Array.prototype.map?s=function(w,b){return w.map(b)}:s=function(w,b){for(var y=[],F=w.length,z=0;z<F;z++)y.push(b(w[z]));return y};var a;Array.prototype.filter?a=function(w,b){return w.filter(b)}:a=function(w,b){for(var y=[],F=w.length,z=0;z<F;z++)b(w[z])&&y.push(w[z]);return y};var n;String.prototype.codePointAt?n=function(w,b){return w.codePointAt(b)}:n=function(w,b){return w.charCodeAt(b)};var c;String.fromCodePoint?c=function(){return String.fromCodePoint.apply(null,arguments)}:c=function(){return String.fromCharCode.apply(null,arguments)};var f=0,p=1,h=/(\\a)|(\\b)|(\\f)|(\\n)|(\\r)|(\\t)|(\\v)|\\x([0-9a-fA-F]+)\\|\\([0-7]+)\\|(\\\\)|(\\')|('')|(\\")|(\\`)|(\\.)|(.)/g,E={"\\a":7,"\\b":8,"\\f":12,"\\n":10,"\\r":13,"\\t":9,"\\v":11};function C(w){var b=[],y=!1;return w.replace(h,function(F,z,X,$,oe,xe,Te,lt,Ct,qt,ir,Pt,gn,Pr,Ir,Or,on){switch(!0){case Ct!==void 0:return b.push(parseInt(Ct,16)),"";case qt!==void 0:return b.push(parseInt(qt,8)),"";case ir!==void 0:case Pt!==void 0:case gn!==void 0:case Pr!==void 0:case Ir!==void 0:return b.push(n(F.substr(1),0)),"";case on!==void 0:return b.push(n(on,0)),"";case Or!==void 0:y=!0;default:return b.push(E[F]),""}}),y?null:b}function S(w,b){var y="";if(w.length<2)return w;try{w=w.replace(/\\([0-7]+)\\/g,function($,oe){return c(parseInt(oe,8))}),w=w.replace(/\\x([0-9a-fA-F]+)\\/g,function($,oe){return c(parseInt(oe,16))})}catch{return null}for(var F=0;F<w.length;F++){var z=w.charAt(F),X=w.charAt(F+1);if(z===b&&X===b)F++,y+=b;else if(z==="\\")if(["a","b","f","n","r","t","v","'",'"',"\\","a","\b","\f",`
`,"\r"," ","\v"].indexOf(X)!==-1)switch(F+=1,X){case"a":y+="a";break;case"b":y+="\b";break;case"f":y+="\f";break;case"n":y+=`
`;break;case"r":y+="\r";break;case"t":y+=" ";break;case"v":y+="\v";break;case"'":y+="'";break;case'"':y+='"';break;case"\\":y+="\\";break}else return null;else y+=z}return y}function P(w){for(var b="",y=0;y<w.length;y++)switch(w.charAt(y)){case"'":b+="\\'";break;case"\\":b+="\\\\";break;case"\b":b+="\\b";break;case"\f":b+="\\f";break;case`
`:b+="\\n";break;case"\r":b+="\\r";break;case" ":b+="\\t";break;case"\v":b+="\\v";break;default:b+=w.charAt(y);break}return b}function I(w){var b=w.substr(2);switch(w.substr(0,2).toLowerCase()){case"0x":return parseInt(b,16);case"0b":return parseInt(b,2);case"0o":return parseInt(b,8);case"0'":return C(b)[0];default:return parseFloat(w)}}var R={whitespace:/^\s*(?:(?:%.*)|(?:\/\*(?:\n|\r|.)*?\*\/)|(?:\s+))\s*/,variable:/^(?:[A-Z_][a-zA-Z0-9_]*)/,atom:/^(\!|,|;|[a-z][0-9a-zA-Z_]*|[#\$\&\*\+\-\.\/\:\<\=\>\?\@\^\~\\]+|'(?:[^']*?(?:\\(?:x?\d+)?\\)*(?:'')*(?:\\')*)*')/,number:/^(?:0o[0-7]+|0x[0-9a-fA-F]+|0b[01]+|0'(?:''|\\[abfnrtv\\'"`]|\\x?\d+\\|[^\\])|\d+(?:\.\d+(?:[eE][+-]?\d+)?)?)/,string:/^(?:"([^"]|""|\\")*"|`([^`]|``|\\`)*`)/,l_brace:/^(?:\[)/,r_brace:/^(?:\])/,l_bracket:/^(?:\{)/,r_bracket:/^(?:\})/,bar:/^(?:\|)/,l_paren:/^(?:\()/,r_paren:/^(?:\))/};function N(w,b){return w.get_flag("char_conversion").id==="on"?b.replace(/./g,function(y){return w.get_char_conversion(y)}):b}function U(w){this.thread=w,this.text="",this.tokens=[]}U.prototype.set_last_tokens=function(w){return this.tokens=w},U.prototype.new_text=function(w){this.text=w,this.tokens=[]},U.prototype.get_tokens=function(w){var b,y=0,F=0,z=0,X=[],$=!1;if(w){var oe=this.tokens[w-1];y=oe.len,b=N(this.thread,this.text.substr(oe.len)),F=oe.line,z=oe.start}else b=this.text;if(/^\s*$/.test(b))return null;for(;b!=="";){var xe=[],Te=!1;if(/^\n/.exec(b)!==null){F++,z=0,y++,b=b.replace(/\n/,""),$=!0;continue}for(var lt in R)if(R.hasOwnProperty(lt)){var Ct=R[lt].exec(b);Ct&&xe.push({value:Ct[0],name:lt,matches:Ct})}if(!xe.length)return this.set_last_tokens([{value:b,matches:[],name:"lexical",line:F,start:z}]);var oe=r(xe,function(Pr,Ir){return Pr.value.length>=Ir.value.length?Pr:Ir});switch(oe.start=z,oe.line=F,b=b.replace(oe.value,""),z+=oe.value.length,y+=oe.value.length,oe.name){case"atom":oe.raw=oe.value,oe.value.charAt(0)==="'"&&(oe.value=S(oe.value.substr(1,oe.value.length-2),"'"),oe.value===null&&(oe.name="lexical",oe.value="unknown escape sequence"));break;case"number":oe.float=oe.value.substring(0,2)!=="0x"&&oe.value.match(/[.eE]/)!==null&&oe.value!=="0'.",oe.value=I(oe.value),oe.blank=Te;break;case"string":var qt=oe.value.charAt(0);oe.value=S(oe.value.substr(1,oe.value.length-2),qt),oe.value===null&&(oe.name="lexical",oe.value="unknown escape sequence");break;case"whitespace":var ir=X[X.length-1];ir&&(ir.space=!0),Te=!0;continue;case"r_bracket":X.length>0&&X[X.length-1].name==="l_bracket"&&(oe=X.pop(),oe.name="atom",oe.value="{}",oe.raw="{}",oe.space=!1);break;case"r_brace":X.length>0&&X[X.length-1].name==="l_brace"&&(oe=X.pop(),oe.name="atom",oe.value="[]",oe.raw="[]",oe.space=!1);break}oe.len=y,X.push(oe),Te=!1}var Pt=this.set_last_tokens(X);return Pt.length===0?null:Pt};function W(w,b,y,F,z){if(!b[y])return{type:f,value:x.error.syntax(b[y-1],"expression expected",!0)};var X;if(F==="0"){var $=b[y];switch($.name){case"number":return{type:p,len:y+1,value:new x.type.Num($.value,$.float)};case"variable":return{type:p,len:y+1,value:new x.type.Var($.value)};case"string":var oe;switch(w.get_flag("double_quotes").id){case"atom":oe=new j($.value,[]);break;case"codes":oe=new j("[]",[]);for(var xe=$.value.length-1;xe>=0;xe--)oe=new j(".",[new x.type.Num(n($.value,xe),!1),oe]);break;case"chars":oe=new j("[]",[]);for(var xe=$.value.length-1;xe>=0;xe--)oe=new j(".",[new x.type.Term($.value.charAt(xe),[]),oe]);break}return{type:p,len:y+1,value:oe};case"l_paren":var Pt=W(w,b,y+1,w.__get_max_priority(),!0);return Pt.type!==p?Pt:b[Pt.len]&&b[Pt.len].name==="r_paren"?(Pt.len++,Pt):{type:f,derived:!0,value:x.error.syntax(b[Pt.len]?b[Pt.len]:b[Pt.len-1],") or operator expected",!b[Pt.len])};case"l_bracket":var Pt=W(w,b,y+1,w.__get_max_priority(),!0);return Pt.type!==p?Pt:b[Pt.len]&&b[Pt.len].name==="r_bracket"?(Pt.len++,Pt.value=new j("{}",[Pt.value]),Pt):{type:f,derived:!0,value:x.error.syntax(b[Pt.len]?b[Pt.len]:b[Pt.len-1],"} or operator expected",!b[Pt.len])}}var Te=ee(w,b,y,z);return Te.type===p||Te.derived||(Te=ie(w,b,y),Te.type===p||Te.derived)?Te:{type:f,derived:!1,value:x.error.syntax(b[y],"unexpected token")}}var lt=w.__get_max_priority(),Ct=w.__get_next_priority(F),qt=y;if(b[y].name==="atom"&&b[y+1]&&(b[y].space||b[y+1].name!=="l_paren")){var $=b[y++],ir=w.__lookup_operator_classes(F,$.value);if(ir&&ir.indexOf("fy")>-1){var Pt=W(w,b,y,F,z);if(Pt.type!==f)return $.value==="-"&&!$.space&&x.type.is_number(Pt.value)?{value:new x.type.Num(-Pt.value.value,Pt.value.is_float),len:Pt.len,type:p}:{value:new x.type.Term($.value,[Pt.value]),len:Pt.len,type:p};X=Pt}else if(ir&&ir.indexOf("fx")>-1){var Pt=W(w,b,y,Ct,z);if(Pt.type!==f)return{value:new x.type.Term($.value,[Pt.value]),len:Pt.len,type:p};X=Pt}}y=qt;var Pt=W(w,b,y,Ct,z);if(Pt.type===p){y=Pt.len;var $=b[y];if(b[y]&&(b[y].name==="atom"&&w.__lookup_operator_classes(F,$.value)||b[y].name==="bar"&&w.__lookup_operator_classes(F,"|"))){var gn=Ct,Pr=F,ir=w.__lookup_operator_classes(F,$.value);if(ir.indexOf("xf")>-1Line truncated
`;b+=`
`;for(key in this.rules)for(y=0;y<this.rules[key].length;y++)b+=this.rules[key][y].toString(w),b+=`
`;return b},De.prototype.clone=function(){return new De(this.id)},Re.prototype.clone=function(){return new Re(this.value,this.is_float)},j.prototype.clone=function(){return new j(this.id,s(this.args,function(w){return w.clone()}))},Fe.prototype.clone=function(){return new Stram(this.stream,this.mode,this.alias,this.type,this.reposition,this.eof_action)},Ne.prototype.clone=function(){var w={};for(var b in this.links)this.links.hasOwnProperty(b)&&(w[b]=this.links[b].clone());return new Ne(w)},Pe.prototype.clone=function(){return new Pe(this.goal.clone(),this.substitution.clone(),this.parent)},Ve.prototype.clone=function(){return new Ve(this.head.clone(),this.body!==null?this.body.clone():null)},De.prototype.equals=function(w){return x.type.is_variable(w)&&this.id===w.id},Re.prototype.equals=function(w){return x.type.is_number(w)&&this.value===w.value&&this.is_float===w.is_float},j.prototype.equals=function(w){if(!x.type.is_term(w)||this.indicator!==w.indicator)return!1;for(var b=0;b<this.args.length;b++)if(!this.args[b].equals(w.args[b]))return!1;return!0},Fe.prototype.equals=function(w){return x.type.is_stream(w)&&this.id===w.id},Ne.prototype.equals=function(w){var b;if(!x.type.is_substitution(w))return!1;for(b in this.links)if(this.links.hasOwnProperty(b)&&(!w.links[b]||!this.links[b].equals(w.links[b])))return!1;for(b in w.links)if(w.links.hasOwnProperty(b)&&!this.links[b])return!1;return!0},Pe.prototype.equals=function(w){return x.type.is_state(w)&&this.goal.equals(w.goal)&&this.substitution.equals(w.substitution)&&this.parent===w.parent},Ve.prototype.equals=function(w){return x.type.is_rule(w)&&this.head.equals(w.head)&&(this.body===null&&w.body===null||this.body!==null&&this.body.equals(w.body))},De.prototype.rename=function(w){return w.get_free_variable(this)},Re.prototype.rename=function(w){return this},j.prototype.rename=function(w){return new j(this.id,s(this.args,function(b){return b.rename(w)}))},Fe.prototype.rename=function(w){return this},Ve.prototype.rename=function(w){return new Ve(this.head.rename(w),this.body!==null?this.body.rename(w):null)},De.prototype.variables=function(){return[this.id]},Re.prototype.variables=function(){return[]},j.prototype.variables=function(){return[].concat.apply([],s(this.args,function(w){return w.variables()}))},Fe.prototype.variables=function(){return[]},Ve.prototype.variables=function(){return this.body===null?this.head.variables():this.head.variables().concat(this.body.variables())},De.prototype.apply=function(w){return w.lookup(this.id)?w.lookup(this.id):this},Re.prototype.apply=function(w){return this},j.prototype.apply=function(w){if(this.indicator==="./2"){for(var b=[],y=this;y.indicator==="./2";)b.push(y.args[0].apply(w)),y=y.args[1];for(var F=y.apply(w),z=b.length-1;z>=0;z--)F=new j(".",[b[z],F]);return F}return new j(this.id,s(this.args,function(X){return X.apply(w)}),this.ref)},Fe.prototype.apply=function(w){return this},Ve.prototype.apply=function(w){return new Ve(this.head.apply(w),this.body!==null?this.body.apply(w):null)},Ne.prototype.apply=function(w){var b,y={};for(b in this.links)this.links.hasOwnProperty(b)&&(y[b]=this.links[b].apply(w));return new Ne(y)},j.prototype.select=function(){for(var w=this;w.indicator===",/2";)w=w.args[0];return w},j.prototype.replace=function(w){return this.indicator===",/2"?this.args[0].indicator===",/2"?new j(",",[this.args[0].replace(w),this.args[1]]):w===null?this.args[1]:new j(",",[w,this.args[1]]):w},j.prototype.search=function(w){if(x.type.is_term(w)&&w.ref!==void 0&&this.ref===w.ref)return!0;for(var b=0;b<this.args.length;b++)if(x.type.is_term(this.args[b])&&this.args[b].search(w))return!0;return!1},ke.prototype.get_current_input=function(){return this.current_input},it.prototype.get_current_input=function(){return this.session.get_current_input()},ke.prototype.get_current_output=function(){return this.current_output},it.prototype.get_current_output=function(){return this.session.get_current_output()},ke.prototype.set_current_input=function(w){this.current_input=w},it.prototype.set_current_input=function(w){return this.session.set_current_input(w)},ke.prototype.set_current_output=function(w){this.current_input=w},it.prototype.set_current_output=function(w){return this.session.set_current_output(w)},ke.prototype.get_stream_by_alias=function(w){return this.streams[w]},it.prototype.get_stream_by_alias=function(w){return this.session.get_stream_by_alias(w)},ke.prototype.file_system_open=function(w,b,y){return this.file_system.open(w,b,y)},it.prototype.file_system_open=function(w,b,y){return this.session.file_system_open(w,b,y)},ke.prototype.get_char_conversion=function(w){return this.__char_conversion[w]||w},it.prototype.get_char_conversion=function(w){return this.session.get_char_conversion(w)},ke.prototype.parse=function(w){return this.thread.parse(w)},it.prototype.parse=function(w){var b=new U(this);b.new_text(w);var y=b.get_tokens();if(y===null)return!1;var F=W(this,y,0,this.__get_max_priority(),!1);return F Line truncated
`,[])])])),b.substitution,b)])},"nl/1":function(w,b,y){var F=y.args[0];w.prepend([new Pe(b.goal.replace(new j("put_char",[F,new j(`
`,[])])),b.substitution,b)])},"get_byte/1":function(w,b,y){var F=y.args[0];w.prepend([new Pe(b.goal.replace(new j(",",[new j("current_input",[new De("S")]),new j("get_byte",[new De("S"),F])])),b.substitution,b)])},"get_byte/2":function(w,b,y){var F=y.args[0],z=y.args[1],X=x.type.is_stream(F)?F:w.get_stream_by_alias(F.id);if(x.type.is_variable(F))w.throw_error(x.error.instantiation(y.indicator));else if(!x.type.is_variable(z)&&!x.type.is_byte(z))w.throw_error(x.error.type("in_byte",char,y.indicator));else if(!x.type.is_stream(F)&&!x.type.is_atom(F))w.throw_error(x.error.domain("stream_or_alias",F,y.indicator));else if(!x.type.is_stream(X)||X.stream===null)w.throw_error(x.error.existence("stream",F,y.indicator));else if(X.output)w.throw_error(x.error.permission("input","stream",F,y.indicator));else if(X.type==="text")w.throw_error(x.error.permission("input","text_stream",F,y.indicator));else if(X.position==="past_end_of_stream"&&X.eof_action==="error")w.throw_error(x.error.permission("input","past_end_of_stream",F,y.indicator));else{var $;if(X.position==="end_of_stream")$="end_of_file",X.position="past_end_of_stream";else{if($=X.stream.get_byte(X.position),$===null){w.throw_error(x.error.representation("byte",y.indicator));return}X.position++}w.prepend([new Pe(b.goal.replace(new j("=",[new Re($,!1),z])),b.substitution,b)])}},"peek_byte/1":function(w,b,y){var F=y.args[0];w.prepend([new Pe(b.goal.replace(new j(",",[new j("current_input",[new De("S")]),new j("peek_byte",[new De("S"),F])])),b.substitution,b)])},"peek_byte/2":function(w,b,y){var F=y.args[0],z=y.args[1],X=x.type.is_stream(F)?F:w.get_stream_by_alias(F.id);if(x.type.is_variable(F))w.throw_error(x.error.instantiation(y.indicator));else if(!x.type.is_variable(z)&&!x.type.is_byte(z))w.throw_error(x.error.type("in_byte",char,y.indicator));else if(!x.type.is_stream(F)&&!x.type.is_atom(F))w.throw_error(x.error.domain("stream_or_alias",F,y.indicator));else if(!x.type.is_stream(X)||X.stream===null)w.throw_error(x.error.existence("stream",F,y.indicator));else if(X.output)w.throw_error(x.error.permission("input","stream",F,y.indicator));else if(X.type==="text")w.throw_error(x.error.permission("input","text_stream",F,y.indicator));else if(X.position==="past_end_of_stream"&&X.eof_action==="error")w.throw_error(x.error.permission("input","past_end_of_stream",F,y.indicator));else{var $;if(X.position==="end_of_stream")$="end_of_file",X.position="past_end_of_stream";else if($=X.stream.get_byte(X.position),$===null){w.throw_error(x.error.representation("byte",y.indicator));return}w.prepend([new Pe(b.goal.replace(new j("=",[new Re($,!1),z])),b.substitution,b)])}},"put_byte/1":function(w,b,y){var F=y.args[0];w.prepend([new Pe(b.goal.replace(new j(",",[new j("current_output",[new De("S")]),new j("put_byte",[new De("S"),F])])),b.substitution,b)])},"put_byte/2":function(w,b,y){var F=y.args[0],z=y.args[1],X=x.type.is_stream(F)?F:w.get_stream_by_alias(F.id);x.type.is_variable(F)||x.type.is_variable(z)?w.throw_error(x.error.instantiation(y.indicator)):x.type.is_byte(z)?!x.type.is_variable(F)&&!x.type.is_stream(F)&&!x.type.is_atom(F)?w.throw_error(x.error.domain("stream_or_alias",F,y.indicator)):!x.type.is_stream(X)||X.stream===null?w.throw_error(x.error.existence("stream",F,y.indicator)):X.input?w.throw_error(x.error.permission("output","stream",F,y.indicator)):X.type==="text"?w.throw_error(x.error.permission("output","text_stream",F,y.indicator)):X.stream.put_byte(z.value,X.position)&&(typeof X.position=="number"&&X.position++,w.success(b)):w.throw_error(x.error.type("byte",z,y.indicator))},"read/1":function(w,b,y){var F=y.args[0];w.prepend([new Pe(b.goal.replace(new j(",",[new j("current_input",[new De("S")]),new j("read_term",[new De("S"),F,new j("[]",[])])])),b.substitution,b)])},"read/2":function(w,b,y){var F=y.args[0],z=y.args[1];w.prepend([new Pe(b.goal.replace(new j("read_term",[F,z,new j("[]",[])])),b.substitution,b)])},"read_term/2":function(w,b,y){var F=y.args[0],z=y.args[1];w.prepend([new Pe(b.goal.replace(new j(",",[new j("current_input",[new De("S")]),new j("read_term",[new De("S"),F,z])])),b.substitution,b)])},"read_term/3":function(w,b,y){var F=y.args[0],z=y.args[1],X=y.args[2],$=x.type.is_stream(F)?F:w.get_stream_by_alias(F.id);if(x.type.is_variable(F)||x.type.is_variable(X))w.throw_error(x.error.instantiation(y.indicator));else if(!x.type.is_list(X))w.throw_error(x.error.type("list",X,y.indicator));else if(!x.type.is_stream(F)&&!x.type.is_atom(F))w.throw_error(x.error.domain("stream_or_alias",F,y.indicator));else if(!x.type.is_stream($)||$.stream===null)w.throw_error(x.error.existence("stream",F,y.indicator));else if($.output)w.throw_error(x.error.permission("input","stream",F,y.indicator));else if($.type==="binary")w.throw_error(x.error.permission("input","binary_stream",F,y.indicator));else if($.position==="past_end_of_stream"&&$.eof_action==="error")w.throw_error(x.error.permission("input","past_end_of_stream",F,y.indicator));else{for(var oe={},xe=X,Te; Line truncated
`;for(let r of this.project.workspacesByCwd.values()){let s=r.relativeCwd;e+=`workspace(${K0(s)}).
`,e+=`workspace_ident(${K0(s)}, ${K0(G.stringifyIdent(r.anchoredLocator))}).
`,e+=`workspace_version(${K0(s)}, ${K0(r.manifest.version)}).
`;for(let a of vEe)for(let n of r.manifest[a].values())e+=`workspace_has_dependency(${K0(s)}, ${K0(G.stringifyIdent(n))}, ${K0(n.range)}, ${a}).
`}return e+=`workspace(_) :- false.
`,e+=`workspace_ident(_, _) :- false.
`,e+=`workspace_version(_, _) :- false.
`,e+=`workspace_has_dependency(_, _, _, _) :- false.
`,e}getDeclarations(){let e="";return e+=`gen_enforced_dependency(_, _, _, _) :- false.
`,e+=`gen_enforced_field(_, _, _) :- false.
`,e}get fullSource(){return`${this.getProjectDatabase()}
${this.source}
${this.getDeclarations()}`}createSession(){return new Mq(this.project,this.fullSource)}async processClassic(){let e=this.createSession();return{enforcedDependencies:await this.genEnforcedDependencies(e),enforcedFields:await this.genEnforcedFields(e)}}async process(){let{enforcedDependencies:e,enforcedFields:r}=await this.processClassic(),s=new Map;for(let{workspace:a,dependencyIdent:n,dependencyRange:c,dependencyType:f}of e){let p=nS([f,G.stringifyIdent(n)]),h=je.getMapWithDefault(s,a.cwd);je.getMapWithDefault(h,p).set(c??void 0,new Set)}for(let{workspace:a,fieldPath:n,fieldValue:c}of r){let f=nS(n),p=je.getMapWithDefault(s,a.cwd);je.getMapWithDefault(p,f).set(JSON.parse(c)??void 0,new Set)}return{manifestUpdates:s,reportedErrors:new Map}}async genEnforcedDependencies(e){let r=[];for await(let s of e.makeQuery("workspace(WorkspaceCwd), dependency_type(DependencyType), gen_enforced_dependency(WorkspaceCwd, DependencyIdent, DependencyRange, DependencyType).")){let a=J.resolve(this.project.cwd,Pm(s.links.WorkspaceCwd)),n=Pm(s.links.DependencyIdent),c=Pm(s.links.DependencyRange),f=Pm(s.links.DependencyType);if(a===null||n===null)throw new Error("Invalid rule");let p=this.project.getWorkspaceByCwd(a),h=G.parseIdent(n);r.push({workspace:p,dependencyIdent:h,dependencyRange:c,dependencyType:f})}return je.sortMap(r,[({dependencyRange:s})=>s!==null?"0":"1",({workspace:s})=>G.stringifyIdent(s.anchoredLocator),({dependencyIdent:s})=>G.stringifyIdent(s)])}async genEnforcedFields(e){let r=[];for await(let s of e.makeQuery("workspace(WorkspaceCwd), gen_enforced_field(WorkspaceCwd, FieldPath, FieldValue).")){let a=J.resolve(this.project.cwd,Pm(s.links.WorkspaceCwd)),n=Pm(s.links.FieldPath),c=$ct(s.links.FieldValue);if(a===null||n===null)throw new Error("Invalid rule");let f=this.project.getWorkspaceByCwd(a);r.push({workspace:f,fieldPath:n,fieldValue:c})}return je.sortMap(r,[({workspace:s})=>G.stringifyIdent(s.anchoredLocator),({fieldPath:s})=>s])}async*query(e){let r=this.createSession();for await(let s of r.makeQuery(e)){let a={};for(let[n,c]of Object.entries(s.links))n!=="_"&&(a[n]=Pm(c));yield a}}}});var OEe=_(fF=>{"use strict";Object.defineProperty(fF,"__esModule",{value:!0});function BS(t){let e=[...t.caches],r=e.shift();return r===void 0?NEe():{get(s,a,n={miss:()=>Promise.resolve()}){return r.get(s,a,n).catch(()=>BS({caches:e}).get(s,a,n))},set(s,a){return r.set(s,a).catch(()=>BS({caches:e}).set(s,a))},delete(s){return r.delete(s).catch(()=>BS({caches:e}).delete(s))},clear(){return r.clear().catch(()=>BS({caches:e}).clear())}}}function NEe(){return{get(t,e,r={miss:()=>Promise.resolve()}){return e().then(a=>Promise.all([a,r.miss(a)])).then(([a])=>a)},set(t,e){return Promise.resolve(e)},delete(t){return Promise.resolve()},clear(){return Promise.resolve()}}}fF.createFallbackableCache=BS;fF.createNullCache=NEe});var MEe=_((BJt,LEe)=>{LEe.exports=OEe()});var UEe=_($q=>{"use strict";Object.defineProperty($q,"__esModule",{value:!0});function yut(t={serializable:!0}){let e={};return{get(r,s,a={miss:()=>Promise.resolve()}){let n=JSON.stringify(r);if(n in e)return Promise.resolve(t.serializable?JSON.parse(e[n]):e[n]);let c=s(),f=a&&a.miss||(()=>Promise.resolve());return c.then(p=>f(p)).then(()=>c)},set(r,s){return e[JSON.stringify(r)]=t.serializable?JSON.stringify(s):s,Promise.resolve(s)},delete(r){return delete e[JSON.stringify(r)],Promise.resolve()},clear(){return e={},Promise.resolve()}}}$q.createInMemoryCache=yut});var HEe=_((SJt,_Ee)=>{_Ee.exports=UEe()});var GEe=_($u=>{"use strict";Object.defineProperty($u,"__esModule",{value:!0});function Eut(t,e,r){let s={"x-algolia-api-key":r,"x-algolia-application-id":e};return{headers(){return t===e9.WithinHeaders?s:{}},queryParameters(){return t===e9.WithinQueryParameters?s:{}}}}function Iut(t){let e=0,r=()=>(e++,new Promise(s=>{setTimeout(()=>{s(t(r))},Math.min(100*e,1e3))}));return t(r)}function jEe(t,e=(r,s)=>Promise.resolve()){return Object.assign(t,{wait(r){return jEe(t.then(s=>Promise.all([e(s,r),s])).then(s=>s[1]))}})}function Cut(t){let e=t.length-1;for(e;e>0;e--){let r=Math.floor(Math.random()*(e+1)),s=t[e];t[e]=t[r],t[r]=s}return t}function wut(t,e){return e&&Object.keys(e).forEach(r=>{t[r]=e[r](t)}),t}function But(t,...e){let r=0;return t.replace(/%s/g,()=>encodeURIComponent(e[r++]))}var vut="4.22.1",Sut=t=>()=>t.transporter.requester.destroy(),e9={WithinQueryParameters:0,WithinHeaders:1};$u.AuthMode=e9;$u.addMethods=wut;$u.createAuth=Eut;$u.createRetryablePromise=Iut;$u.createWaitablePromise=jEe;$u.destroy=Sut;$u.encode=But;$u.shuffle=Cut;$u.version=vut});var vS=_((bJt,qEe)=>{qEe.exports=GEe()});var WEe=_(t9=>{"use strict";Object.defineProperty(t9,"__esModule",{value:!0});var Dut={Delete:"DELETE",Get:"GET",Post:"POST",Put:"PUT"};t9.MethodEnum=Dut});var SS=_((xJt,YEe)=>{YEe.exports=WEe()});var aIe=_(Yi=>{"use strict";Object.defineProperty(Yi,"__esModule",{value:!0});var JEe=SS();function r9(t,e){let r=t||{},s=r.data||{};return Object.keys(r).forEach(a=>{["timeout","head Line truncated
`;f!==s&&(s=f,t.write(iwe.default.eraseLines(r)+f),r=f.split(`
`).length)};return n.clear=()=>{t.write(iwe.default.eraseLines(r)),s="",r=0},n.done=()=>{s="",r=0,e||(swe.default.show(),a=!1)},n};LS.default={create:Ipt}});var lwe=_((mKt,Cpt)=>{Cpt.exports=[{name:"AppVeyor",constant:"APPVEYOR",env:"APPVEYOR",pr:"APPVEYOR_PULL_REQUEST_NUMBER"},{name:"Azure Pipelines",constant:"AZURE_PIPELINES",env:"SYSTEM_TEAMFOUNDATIONCOLLECTIONURI",pr:"SYSTEM_PULLREQUEST_PULLREQUESTID"},{name:"Bamboo",constant:"BAMBOO",env:"bamboo_planKey"},{name:"Bitbucket Pipelines",constant:"BITBUCKET",env:"BITBUCKET_COMMIT",pr:"BITBUCKET_PR_ID"},{name:"Bitrise",constant:"BITRISE",env:"BITRISE_IO",pr:"BITRISE_PULL_REQUEST"},{name:"Buddy",constant:"BUDDY",env:"BUDDY_WORKSPACE_ID",pr:"BUDDY_EXECUTION_PULL_REQUEST_ID"},{name:"Buildkite",constant:"BUILDKITE",env:"BUILDKITE",pr:{env:"BUILDKITE_PULL_REQUEST",ne:"false"}},{name:"CircleCI",constant:"CIRCLE",env:"CIRCLECI",pr:"CIRCLE_PULL_REQUEST"},{name:"Cirrus CI",constant:"CIRRUS",env:"CIRRUS_CI",pr:"CIRRUS_PR"},{name:"AWS CodeBuild",constant:"CODEBUILD",env:"CODEBUILD_BUILD_ARN"},{name:"Codeship",constant:"CODESHIP",env:{CI_NAME:"codeship"}},{name:"Drone",constant:"DRONE",env:"DRONE",pr:{DRONE_BUILD_EVENT:"pull_request"}},{name:"dsari",constant:"DSARI",env:"DSARI"},{name:"GitLab CI",constant:"GITLAB",env:"GITLAB_CI"},{name:"GoCD",constant:"GOCD",env:"GO_PIPELINE_LABEL"},{name:"Hudson",constant:"HUDSON",env:"HUDSON_URL"},{name:"Jenkins",constant:"JENKINS",env:["JENKINS_URL","BUILD_ID"],pr:{any:["ghprbPullId","CHANGE_ID"]}},{name:"Magnum CI",constant:"MAGNUM",env:"MAGNUM"},{name:"Netlify CI",constant:"NETLIFY",env:"NETLIFY_BUILD_BASE",pr:{env:"PULL_REQUEST",ne:"false"}},{name:"Sail CI",constant:"SAIL",env:"SAILCI",pr:"SAIL_PULL_REQUEST_NUMBER"},{name:"Semaphore",constant:"SEMAPHORE",env:"SEMAPHORE",pr:"PULL_REQUEST_NUMBER"},{name:"Shippable",constant:"SHIPPABLE",env:"SHIPPABLE",pr:{IS_PULL_REQUEST:"true"}},{name:"Solano CI",constant:"SOLANO",env:"TDDIUM",pr:"TDDIUM_PR_ID"},{name:"Strider CD",constant:"STRIDER",env:"STRIDER"},{name:"TaskCluster",constant:"TASKCLUSTER",env:["TASK_ID","RUN_ID"]},{name:"TeamCity",constant:"TEAMCITY",env:"TEAMCITY_VERSION"},{name:"Travis CI",constant:"TRAVIS",env:"TRAVIS",pr:{env:"TRAVIS_PULL_REQUEST",ne:"false"}}]});var fwe=_(tc=>{"use strict";var uwe=lwe(),uA=process.env;Object.defineProperty(tc,"_vendors",{value:uwe.map(function(t){return t.constant})});tc.name=null;tc.isPR=null;uwe.forEach(function(t){var e=Array.isArray(t.env)?t.env:[t.env],r=e.every(function(s){return cwe(s)});if(tc[t.constant]=r,r)switch(tc.name=t.name,typeof t.pr){case"string":tc.isPR=!!uA[t.pr];break;case"object":"env"in t.pr?tc.isPR=t.pr.env in uA&&uA[t.pr.env]!==t.pr.ne:"any"in t.pr?tc.isPR=t.pr.any.some(function(s){return!!uA[s]}):tc.isPR=cwe(t.pr);break;default:tc.isPR=null}});tc.isCI=!!(uA.CI||uA.CONTINUOUS_INTEGRATION||uA.BUILD_NUMBER||uA.RUN_ID||tc.name);function cwe(t){return typeof t=="string"?!!uA[t]:Object.keys(t).every(function(e){return uA[e]===t[e]})}});var pwe=_((EKt,Awe)=>{"use strict";Awe.exports=fwe().isCI});var gwe=_((IKt,hwe)=>{"use strict";var wpt=t=>{let e=new Set;do for(let r of Reflect.ownKeys(t))e.add([t,r]);while((t=Reflect.getPrototypeOf(t))&&t!==Object.prototype);return e};hwe.exports=(t,{include:e,exclude:r}={})=>{let s=a=>{let n=c=>typeof c=="string"?a===c:c.test(a);return e?e.some(n):r?!r.some(n):!0};for(let[a,n]of wpt(t.constructor.prototype)){if(n==="constructor"||!s(n))continue;let c=Reflect.getOwnPropertyDescriptor(a,n);c&&typeof c.value=="function"&&(t[n]=t[n].bind(t))}return t}});var Cwe=_(Vn=>{"use strict";var mw,_S,QF,H9;typeof performance=="object"&&typeof performance.now=="function"?(dwe=performance,Vn.unstable_now=function(){return dwe.now()}):(N9=Date,mwe=N9.now(),Vn.unstable_now=function(){return N9.now()-mwe});var dwe,N9,mwe;typeof window>"u"||typeof MessageChannel!="function"?(dw=null,O9=null,L9=function(){if(dw!==null)try{var t=Vn.unstable_now();dw(!0,t),dw=null}catch(e){throw setTimeout(L9,0),e}},mw=function(t){dw!==null?setTimeout(mw,0,t):(dw=t,setTimeout(L9,0))},_S=function(t,e){O9=setTimeout(t,e)},QF=function(){clearTimeout(O9)},Vn.unstable_shouldYield=function(){return!1},H9=Vn.unstable_forceFrameRate=function(){}):(ywe=window.setTimeout,Ewe=window.clearTimeout,typeof console<"u"&&(Iwe=window.cancelAnimationFrame,typeof window.requestAnimationFrame!="function"&&console.error("This browser doesn't support requestAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills"),typeof Iwe!="function"&&console.error("This browser doesn't support cancelAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills")),MS=!1,US=null,PF=-1,M9=5,U9=0,Vn.unstable_shouldYield=function(){return Vn.unstable_now()>=U9},H9=function(){},Vn.unstable_forceFrameRate=function(t){0>t||125<t?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):M9=0<t?Math Line truncated
`+fu+v}var ve=!1;function Nt(v,D){if(!v||ve)return"";ve=!0;var Q=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(D)if(D=function(){throw Error()},Object.defineProperty(D.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(D,[])}catch(pt){var H=pt}Reflect.construct(v,[],D)}else{try{D.call()}catch(pt){H=pt}v.call(D.prototype)}else{try{throw Error()}catch(pt){H=pt}v()}}catch(pt){if(pt&&H&&typeof pt.stack=="string"){for(var V=pt.stack.split(`
`),ne=H.stack.split(`
`),Se=V.length-1,_e=ne.length-1;1<=Se&&0<=_e&&V[Se]!==ne[_e];)_e--;for(;1<=Se&&0<=_e;Se--,_e--)if(V[Se]!==ne[_e]){if(Se!==1||_e!==1)do if(Se--,_e--,0>_e||V[Se]!==ne[_e])return`
`+V[Se].replace(" at new "," at ");while(1<=Se&&0<=_e);break}}}finally{ve=!1,Error.prepareStackTrace=Q}return(v=v?v.displayName||v.name:"")?oc(v):""}var ac=[],Oi=-1;function no(v){return{current:v}}function Rt(v){0>Oi||(v.current=ac[Oi],ac[Oi]=null,Oi--)}function xn(v,D){Oi++,ac[Oi]=v.current,v.current=D}var la={},Gi=no(la),Li=no(!1),Na=la;function dn(v,D){var Q=v.type.contextTypes;if(!Q)return la;var H=v.stateNode;if(H&&H.__reactInternalMemoizedUnmaskedChildContext===D)return H.__reactInternalMemoizedMaskedChildContext;var V={},ne;for(ne in Q)V[ne]=D[ne];return H&&(v=v.stateNode,v.__reactInternalMemoizedUnmaskedChildContext=D,v.__reactInternalMemoizedMaskedChildContext=V),V}function Kn(v){return v=v.childContextTypes,v!=null}function Au(){Rt(Li),Rt(Gi)}function yh(v,D,Q){if(Gi.current!==la)throw Error(c(168));xn(Gi,D),xn(Li,Q)}function Oa(v,D,Q){var H=v.stateNode;if(v=D.childContextTypes,typeof H.getChildContext!="function")return Q;H=H.getChildContext();for(var V in H)if(!(V in v))throw Error(c(108,g(D)||"Unknown",V));return s({},Q,H)}function La(v){return v=(v=v.stateNode)&&v.__reactInternalMemoizedMergedChildContext||la,Na=Gi.current,xn(Gi,v),xn(Li,Li.current),!0}function Ma(v,D,Q){var H=v.stateNode;if(!H)throw Error(c(169));Q?(v=Oa(v,D,Na),H.__reactInternalMemoizedMergedChildContext=v,Rt(Li),Rt(Gi),xn(Gi,v)):Rt(Li),xn(Li,Q)}var $e=null,Ua=null,hf=n.unstable_now;hf();var lc=0,wn=8;function ca(v){if(1&v)return wn=15,1;if(2&v)return wn=14,2;if(4&v)return wn=13,4;var D=24&v;return D!==0?(wn=12,D):v&32?(wn=11,32):(D=192&v,D!==0?(wn=10,D):v&256?(wn=9,256):(D=3584&v,D!==0?(wn=8,D):v&4096?(wn=7,4096):(D=4186112&v,D!==0?(wn=6,D):(D=62914560&v,D!==0?(wn=5,D):v&67108864?(wn=4,67108864):v&134217728?(wn=3,134217728):(D=805306368&v,D!==0?(wn=2,D):1073741824&v?(wn=1,1073741824):(wn=8,v))))))}function LA(v){switch(v){case 99:return 15;case 98:return 10;case 97:case 96:return 8;case 95:return 2;default:return 0}}function MA(v){switch(v){case 15:case 14:return 99;case 13:case 12:case 11:case 10:return 98;case 9:case 8:case 7:case 6:case 4:case 5:return 97;case 3:case 2:case 1:return 95;case 0:return 90;default:throw Error(c(358,v))}}function ua(v,D){var Q=v.pendingLanes;if(Q===0)return wn=0;var H=0,V=0,ne=v.expiredLanes,Se=v.suspendedLanes,_e=v.pingedLanes;if(ne!==0)H=ne,V=wn=15;else if(ne=Q&134217727,ne!==0){var pt=ne&~Se;pt!==0?(H=ca(pt),V=wn):(_e&=ne,_e!==0&&(H=ca(_e),V=wn))}else ne=Q&~Se,ne!==0?(H=ca(ne),V=wn):_e!==0&&(H=ca(_e),V=wn);if(H===0)return 0;if(H=31-ns(H),H=Q&((0>H?0:1<<H)<<1)-1,D!==0&&D!==H&&!(D&Se)){if(ca(D),V<=wn)return D;wn=V}if(D=v.entangledLanes,D!==0)for(v=v.entanglements,D&=H;0<D;)Q=31-ns(D),V=1<<Q,H|=v[Q],D&=~V;return H}function Bl(v){return v=v.pendingLanes&-1073741825,v!==0?v:v&1073741824?1073741824:0}function Mt(v,D){switch(v){case 15:return 1;case 14:return 2;case 12:return v=kn(24&~D),v===0?Mt(10,D):v;case 10:return v=kn(192&~D),v===0?Mt(8,D):v;case 8:return v=kn(3584&~D),v===0&&(v=kn(4186112&~D),v===0&&(v=512)),v;case 2:return D=kn(805306368&~D),D===0&&(D=268435456),D}throw Error(c(358,v))}function kn(v){return v&-v}function fa(v){for(var D=[],Q=0;31>Q;Q++)D.push(v);return D}function Ha(v,D,Q){v.pendingLanes|=D;var H=D-1;v.suspendedLanes&=H,v.pingedLanes&=H,v=v.eventTimes,D=31-ns(D),v[D]=Q}var ns=Math.clz32?Math.clz32:uc,cc=Math.log,pu=Math.LN2;function uc(v){return v===0?32:31-(cc(v)/pu|0)|0}var ja=n.unstable_runWithPriority,Mi=n.unstable_scheduleCallback,Is=n.unstable_cancelCallback,vl=n.unstable_shouldYield,gf=n.unstable_requestPaint,fc=n.unstable_now,wi=n.unstable_getCurrentPriorityLevel,Qn=n.unstable_ImmediatePriority,Ac=n.unstable_UserBlockingPriority,Ke=n.unstable_NormalPriority,st=n.unstable_LowPriority,St=n.unstable_IdlePriority,lr={},te=gf!==void 0?gf:function(){},Ee=null,Oe=null,dt=!1,Et=fc(),bt=1e4>Et?fc:function(){return fc()-Et};function tr(){switch(wi()){case Qn:return 99;case Ac:return 98;case Ke:return 97;case st:return 96;case St:return 95;default:throw Error(c(332))}}function An(v){switch(v){case 99:return Qn;case 98:return Ac;case 97:return Ke;case 96:return st;case 95:return St;default:throw Error(c(332))}}function li(v,D){return v=An(v),ja(v,D)}function qi(v,D,Q){return v=An(v),Mi(v,D,Q)}function Tn(){if(Oe!==null){var v=Oe;Oe=null,Is(v)}Ga()}function Ga(){if(!dt&&Ee!==null){dt=!0;var v=0;try{var D=Ee;li(99,function(){for(;v<D.length;v++){var Q=D[v];do Q=Q(!0);while(Q!==null)}}),Ee=null}catch(Q){throw Ee!==null&&(Ee=Ee.slice(v+1)),Mi(Qn,Tn),Q}finally{dt=!1}}}var my=f.ReactCurrentBatchConfig;function Z1(v,D){return v===D&&(v!==0||1/v===1/D)||v!==v&&D!==D}var vo=typeof Object.is=="function"?Object.is:Z1,yy=Object.prototype.hasOwnProperty;function Eh(v,D){if(vo(v,D))return!0;if(typeof v!="object"||v===null||typeof D!="object"||D===null)return!1;var Q=Object.keys(v),H=Object.keys(D);if(Q.length!==H.length)return!1;for(H=0;H<Q.length;H++)if(!yy.call(D,Q[H])||!vo(v[Q[H]],D[Q[H]]))return!1;return!0}function $1(v){switch(v.tag){case 5:return oc(v.type);case 16:return oc("Lazy" Line truncated
Error generating stack: `+ne.message+`
`+ne.stack}return{value:v,source:D,stack:V}}function Vg(v,D){try{console.error(D.value)}catch(Q){setTimeout(function(){throw Q})}}var WL=typeof WeakMap=="function"?WeakMap:Map;function i2(v,D,Q){Q=Dl(-1,Q),Q.tag=3,Q.payload={element:null};var H=D.value;return Q.callback=function(){_y||(_y=!0,y2=H),Vg(v,D)},Q}function Jg(v,D,Q){Q=Dl(-1,Q),Q.tag=3;var H=v.type.getDerivedStateFromError;if(typeof H=="function"){var V=D.value;Q.payload=function(){return Vg(v,D),H(V)}}var ne=v.stateNode;return ne!==null&&typeof ne.componentDidCatch=="function"&&(Q.callback=function(){typeof H!="function"&&(hc===null?hc=new Set([this]):hc.add(this),Vg(v,D));var Se=D.stack;this.componentDidCatch(D.value,{componentStack:Se!==null?Se:""})}),Q}var YL=typeof WeakSet=="function"?WeakSet:Set;function s2(v){var D=v.ref;if(D!==null)if(typeof D=="function")try{D(null)}catch(Q){xf(v,Q)}else D.current=null}function xy(v,D){switch(D.tag){case 0:case 11:case 15:case 22:return;case 1:if(D.flags&256&&v!==null){var Q=v.memoizedProps,H=v.memoizedState;v=D.stateNode,D=v.getSnapshotBeforeUpdate(D.elementType===D.type?Q:So(D.type,Q),H),v.__reactInternalSnapshotBeforeUpdate=D}return;case 3:F&&D.flags&256&&Ts(D.stateNode.containerInfo);return;case 5:case 6:case 4:case 17:return}throw Error(c(163))}function Th(v,D){if(D=D.updateQueue,D=D!==null?D.lastEffect:null,D!==null){var Q=D=D.next;do{if((Q.tag&v)===v){var H=Q.destroy;Q.destroy=void 0,H!==void 0&&H()}Q=Q.next}while(Q!==D)}}function uP(v,D,Q){switch(Q.tag){case 0:case 11:case 15:case 22:if(D=Q.updateQueue,D=D!==null?D.lastEffect:null,D!==null){v=D=D.next;do{if((v.tag&3)===3){var H=v.create;v.destroy=H()}v=v.next}while(v!==D)}if(D=Q.updateQueue,D=D!==null?D.lastEffect:null,D!==null){v=D=D.next;do{var V=v;H=V.next,V=V.tag,V&4&&V&1&&(vP(Q,v),tM(Q,v)),v=H}while(v!==D)}return;case 1:v=Q.stateNode,Q.flags&4&&(D===null?v.componentDidMount():(H=Q.elementType===Q.type?D.memoizedProps:So(Q.type,D.memoizedProps),v.componentDidUpdate(H,D.memoizedState,v.__reactInternalSnapshotBeforeUpdate))),D=Q.updateQueue,D!==null&&Cy(Q,D,v);return;case 3:if(D=Q.updateQueue,D!==null){if(v=null,Q.child!==null)switch(Q.child.tag){case 5:v=Re(Q.child.stateNode);break;case 1:v=Q.child.stateNode}Cy(Q,D,v)}return;case 5:v=Q.stateNode,D===null&&Q.flags&4&&$s(v,Q.type,Q.memoizedProps,Q);return;case 6:return;case 4:return;case 12:return;case 13:X&&Q.memoizedState===null&&(Q=Q.alternate,Q!==null&&(Q=Q.memoizedState,Q!==null&&(Q=Q.dehydrated,Q!==null&&uu(Q))));return;case 19:case 17:case 20:case 21:case 23:case 24:return}throw Error(c(163))}function fP(v,D){if(F)for(var Q=v;;){if(Q.tag===5){var H=Q.stateNode;D?dh(H):to(Q.stateNode,Q.memoizedProps)}else if(Q.tag===6)H=Q.stateNode,D?mh(H):jn(H,Q.memoizedProps);else if((Q.tag!==23&&Q.tag!==24||Q.memoizedState===null||Q===v)&&Q.child!==null){Q.child.return=Q,Q=Q.child;continue}if(Q===v)break;for(;Q.sibling===null;){if(Q.return===null||Q.return===v)return;Q=Q.return}Q.sibling.return=Q.return,Q=Q.sibling}}function ky(v,D){if(Ua&&typeof Ua.onCommitFiberUnmount=="function")try{Ua.onCommitFiberUnmount($e,D)}catch{}switch(D.tag){case 0:case 11:case 14:case 15:case 22:if(v=D.updateQueue,v!==null&&(v=v.lastEffect,v!==null)){var Q=v=v.next;do{var H=Q,V=H.destroy;if(H=H.tag,V!==void 0)if(H&4)vP(D,Q);else{H=D;try{V()}catch(ne){xf(H,ne)}}Q=Q.next}while(Q!==v)}break;case 1:if(s2(D),v=D.stateNode,typeof v.componentWillUnmount=="function")try{v.props=D.memoizedProps,v.state=D.memoizedState,v.componentWillUnmount()}catch(ne){xf(D,ne)}break;case 5:s2(D);break;case 4:F?gP(v,D):z&&z&&(D=D.stateNode.containerInfo,v=ou(D),TA(D,v))}}function AP(v,D){for(var Q=D;;)if(ky(v,Q),Q.child===null||F&&Q.tag===4){if(Q===D)break;for(;Q.sibling===null;){if(Q.return===null||Q.return===D)return;Q=Q.return}Q.sibling.return=Q.return,Q=Q.sibling}else Q.child.return=Q,Q=Q.child}function Qy(v){v.alternate=null,v.child=null,v.dependencies=null,v.firstEffect=null,v.lastEffect=null,v.memoizedProps=null,v.memoizedState=null,v.pendingProps=null,v.return=null,v.updateQueue=null}function pP(v){return v.tag===5||v.tag===3||v.tag===4}function hP(v){if(F){e:{for(var D=v.return;D!==null;){if(pP(D))break e;D=D.return}throw Error(c(160))}var Q=D;switch(D=Q.stateNode,Q.tag){case 5:var H=!1;break;case 3:D=D.containerInfo,H=!0;break;case 4:D=D.containerInfo,H=!0;break;default:throw Error(c(161))}Q.flags&16&&(Af(D),Q.flags&=-17);e:t:for(Q=v;;){for(;Q.sibling===null;){if(Q.return===null||pP(Q.return)){Q=null;break e}Q=Q.return}for(Q.sibling.return=Q.return,Q=Q.sibling;Q.tag!==5&&Q.tag!==6&&Q.tag!==18;){if(Q.flags&2||Q.child===null||Q.tag===4)continue t;Q.child.return=Q,Q=Q.child}if(!(Q.flags&2)){Q=Q.stateNode;break e}}H?o2(v,Q,D):a2(v,Q,D)}}function o2(v,D,Q){var H=v.tag,V=H===5||H===6;if(V)v=V?v.stateNode:v.stateNode.instance,D?eo(Q,v,D):Io(Q,v);else if(H!==4&&(v=v.child,v!==null))for(o2(v,D,Q),v=v.sibling;v!==null;)o2(v,D,Q),v=v.sibling}function a2(v,D,Q){var H=v.tag,V=H===5||H===6;if(V)v=V?v.stateNode:v.stateNode.instance,D?ji(Q,v,D):ai(Q,v);els Line truncated
Add a <Suspense fallback=...> component higher in the tree to provide a loading indicator or placeholder to display.`)}ws!==5&&(ws=2),pt=Yg(pt,_e),Zt=Se;do{switch(Zt.tag){case 3:ne=pt,Zt.flags|=4096,D&=-D,Zt.lanes|=D;var Zn=i2(Zt,ne,D);Iy(Zt,Zn);break e;case 1:ne=pt;var kr=Zt.type,Rn=Zt.stateNode;if(!(Zt.flags&64)&&(typeof kr.getDerivedStateFromError=="function"||Rn!==null&&typeof Rn.componentDidCatch=="function"&&(hc===null||!hc.has(Rn)))){Zt.flags|=4096,D&=-D,Zt.lanes|=D;var _n=Jg(Zt,ne,D);Iy(Zt,_n);break e}}Zt=Zt.return}while(Zt!==null)}BP(Q)}catch(zr){D=zr,Xi===Q&&Q!==null&&(Xi=Q=Q.return);continue}break}while(!0)}function CP(){var v=My.current;return My.current=kt,v===null?kt:v}function id(v,D){var Q=xr;xr|=16;var H=CP();so===v&&Ns===D||Oh(v,D);do try{XL();break}catch(V){IP(v,V)}while(!0);if(Fg(),xr=Q,My.current=H,Xi!==null)throw Error(c(261));return so=null,Ns=0,ws}function XL(){for(;Xi!==null;)wP(Xi)}function ZL(){for(;Xi!==null&&!vl();)wP(Xi)}function wP(v){var D=bP(v.alternate,v,ZA);v.memoizedProps=v.pendingProps,D===null?BP(v):Xi=D,f2.current=null}function BP(v){var D=v;do{var Q=D.alternate;if(v=D.return,D.flags&2048){if(Q=qL(D),Q!==null){Q.flags&=2047,Xi=Q;return}v!==null&&(v.firstEffect=v.lastEffect=null,v.flags|=2048)}else{if(Q=jL(Q,D,ZA),Q!==null){Xi=Q;return}if(Q=D,Q.tag!==24&&Q.tag!==23||Q.memoizedState===null||ZA&1073741824||!(Q.mode&4)){for(var H=0,V=Q.child;V!==null;)H|=V.lanes|V.childLanes,V=V.sibling;Q.childLanes=H}v!==null&&!(v.flags&2048)&&(v.firstEffect===null&&(v.firstEffect=D.firstEffect),D.lastEffect!==null&&(v.lastEffect!==null&&(v.lastEffect.nextEffect=D.firstEffect),v.lastEffect=D.lastEffect),1<D.flags&&(v.lastEffect!==null?v.lastEffect.nextEffect=D:v.firstEffect=D,v.lastEffect=D))}if(D=D.sibling,D!==null){Xi=D;return}Xi=D=v}while(D!==null);ws===0&&(ws=5)}function $A(v){var D=tr();return li(99,$L.bind(null,v,D)),null}function $L(v,D){do vu();while($g!==null);if(xr&48)throw Error(c(327));var Q=v.finishedWork;if(Q===null)return null;if(v.finishedWork=null,v.finishedLanes=0,Q===v.current)throw Error(c(177));v.callbackNode=null;var H=Q.lanes|Q.childLanes,V=H,ne=v.pendingLanes&~V;v.pendingLanes=V,v.suspendedLanes=0,v.pingedLanes=0,v.expiredLanes&=V,v.mutableReadLanes&=V,v.entangledLanes&=V,V=v.entanglements;for(var Se=v.eventTimes,_e=v.expirationTimes;0<ne;){var pt=31-ns(ne),Wt=1<<pt;V[pt]=0,Se[pt]=-1,_e[pt]=-1,ne&=~Wt}if(wu!==null&&!(H&24)&&wu.has(v)&&wu.delete(v),v===so&&(Xi=so=null,Ns=0),1<Q.flags?Q.lastEffect!==null?(Q.lastEffect.nextEffect=Q,H=Q.firstEffect):H=Q:H=Q.firstEffect,H!==null){V=xr,xr|=32,f2.current=null,rd=rt(v.containerInfo),nd=!1,sr=H;do try{eM()}catch(qe){if(sr===null)throw Error(c(330));xf(sr,qe),sr=sr.nextEffect}while(sr!==null);rd=null,sr=H;do try{for(Se=v;sr!==null;){var Sr=sr.flags;if(Sr&16&&F&&Af(sr.stateNode),Sr&128){var Lr=sr.alternate;if(Lr!==null){var Zt=Lr.ref;Zt!==null&&(typeof Zt=="function"?Zt(null):Zt.current=null)}}switch(Sr&1038){case 2:hP(sr),sr.flags&=-3;break;case 6:hP(sr),sr.flags&=-3,l2(sr.alternate,sr);break;case 1024:sr.flags&=-1025;break;case 1028:sr.flags&=-1025,l2(sr.alternate,sr);break;case 4:l2(sr.alternate,sr);break;case 8:_e=Se,ne=sr,F?gP(_e,ne):AP(_e,ne);var zn=ne.alternate;Qy(ne),zn!==null&&Qy(zn)}sr=sr.nextEffect}}catch(qe){if(sr===null)throw Error(c(330));xf(sr,qe),sr=sr.nextEffect}while(sr!==null);nd&&lt(),Fe(v.containerInfo),v.current=Q,sr=H;do try{for(Sr=v;sr!==null;){var yi=sr.flags;if(yi&36&&uP(Sr,sr.alternate,sr),yi&128){Lr=void 0;var za=sr.ref;if(za!==null){var et=sr.stateNode;switch(sr.tag){case 5:Lr=Re(et);break;default:Lr=et}typeof za=="function"?za(Lr):za.current=Lr}}sr=sr.nextEffect}}catch(qe){if(sr===null)throw Error(c(330));xf(sr,qe),sr=sr.nextEffect}while(sr!==null);sr=null,te(),xr=V}else v.current=Q;if(Pf)Pf=!1,$g=v,ed=D;else for(sr=H;sr!==null;)D=sr.nextEffect,sr.nextEffect=null,sr.flags&8&&(yi=sr,yi.sibling=null,yi.stateNode=null),sr=D;if(H=v.pendingLanes,H===0&&(hc=null),H===1?v===C2?td++:(td=0,C2=v):td=0,Q=Q.stateNode,Ua&&typeof Ua.onCommitFiberRoot=="function")try{Ua.onCommitFiberRoot($e,Q,void 0,(Q.current.flags&64)===64)}catch{}if(ga(v,bt()),_y)throw _y=!1,v=y2,y2=null,v;return xr&8||Tn(),null}function eM(){for(;sr!==null;){var v=sr.alternate;nd||rd===null||(sr.flags&8?De(sr,rd)&&(nd=!0,Te()):sr.tag===13&&VL(v,sr)&&De(sr,rd)&&(nd=!0,Te()));var D=sr.flags;D&256&&xy(v,sr),!(D&512)||Pf||(Pf=!0,qi(97,function(){return vu(),null})),sr=sr.nextEffect}}function vu(){if(ed!==90){var v=97<ed?97:ed;return ed=90,li(v,rM)}return!1}function tM(v,D){E2.push(D,v),Pf||(Pf=!0,qi(97,function(){return vu(),null}))}function vP(v,D){I2.push(D,v),Pf||(Pf=!0,qi(97,function(){return vu(),null}))}function rM(){if($g===null)return!1;var v=$g;if($g=null,xr&48)throw Error(c(331));var D=xr;xr|=32;var Q=I2;I2=[];for(var H=0;H<Q.length;H+=2){var V=Q[H],ne=Q[H+1],Se=V.destroy;if(V.destroy=void 0,typeof Se=="function")try{Se()}catch(pt){if(ne===null)throw Error(c(330));xf(ne,pt)}}for(Q=E2,E2=[],H=0;H<Q.length;H+=2){V=Q[H],ne=Q[H+1];try{va Line truncated
`+(H.join(" > ")+`
No matching component was found for:
`)+v.join(" > ")}return null},r.getPublicRootInstance=function(v){if(v=v.current,!v.child)return null;switch(v.child.tag){case 5:return Re(v.child.stateNode);default:return v.child.stateNode}},r.injectIntoDevTools=function(v){if(v={bundleType:v.bundleType,version:v.version,rendererPackageName:v.rendererPackageName,rendererConfig:v.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:f.ReactCurrentDispatcher,findHostInstanceByFiber:aM,findFiberByHostInstance:v.findFiberByHostInstance||lM,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null},typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u")v=!1;else{var D=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!D.isDisabled&&D.supportsFiber)try{$e=D.inject(v),Ua=D}catch{}v=!0}return v},r.observeVisibleRects=function(v,D,Q,H){if(!qt)throw Error(c(363));v=u2(v,D);var V=on(v,Q,H).disconnect;return{disconnect:function(){V()}}},r.registerMutableSourceForHydration=function(v,D){var Q=D._getVersion;Q=Q(D._source),v.mutableSourceEagerHydrationData==null?v.mutableSourceEagerHydrationData=[D,Q]:v.mutableSourceEagerHydrationData.push(D,Q)},r.runWithPriority=function(v,D){var Q=lc;try{return lc=v,D()}finally{lc=Q}},r.shouldSuspend=function(){return!1},r.unbatchedUpdates=function(v,D){var Q=xr;xr&=-2,xr|=8;try{return v(D)}finally{xr=Q,xr===0&&(bf(),Tn())}},r.updateContainer=function(v,D,Q,H){var V=D.current,ne=ko(),Se=Bs(V);e:if(Q){Q=Q._reactInternals;t:{if(we(Q)!==Q||Q.tag!==1)throw Error(c(170));var _e=Q;do{switch(_e.tag){case 3:_e=_e.stateNode.context;break t;case 1:if(Kn(_e.type)){_e=_e.stateNode.__reactInternalMemoizedMergedChildContext;break t}}_e=_e.return}while(_e!==null);throw Error(c(171))}if(Q.tag===1){var pt=Q.type;if(Kn(pt)){Q=Oa(Q,pt,_e);break e}}Q=_e}else Q=la;return D.context===null?D.context=Q:D.pendingContext=Q,D=Dl(ne,Se),D.payload={element:v},H=H===void 0?null:H,H!==null&&(D.callback=H),bl(V,D),Tl(V,Se,ne),Se},r}});var Swe=_((vKt,vwe)=>{"use strict";vwe.exports=Bwe()});var bwe=_((SKt,Dwe)=>{"use strict";var Spt={ALIGN_COUNT:8,ALIGN_AUTO:0,ALIGN_FLEX_START:1,ALIGN_CENTER:2,ALIGN_FLEX_END:3,ALIGN_STRETCH:4,ALIGN_BASELINE:5,ALIGN_SPACE_BETWEEN:6,ALIGN_SPACE_AROUND:7,DIMENSION_COUNT:2,DIMENSION_WIDTH:0,DIMENSION_HEIGHT:1,DIRECTION_COUNT:3,DIRECTION_INHERIT:0,DIRECTION_LTR:1,DIRECTION_RTL:2,DISPLAY_COUNT:2,DISPLAY_FLEX:0,DISPLAY_NONE:1,EDGE_COUNT:9,EDGE_LEFT:0,EDGE_TOP:1,EDGE_RIGHT:2,EDGE_BOTTOM:3,EDGE_START:4,EDGE_END:5,EDGE_HORIZONTAL:6,EDGE_VERTICAL:7,EDGE_ALL:8,EXPERIMENTAL_FEATURE_COUNT:1,EXPERIMENTAL_FEATURE_WEB_FLEX_BASIS:0,FLEX_DIRECTION_COUNT:4,FLEX_DIRECTION_COLUMN:0,FLEX_DIRECTION_COLUMN_REVERSE:1,FLEX_DIRECTION_ROW:2,FLEX_DIRECTION_ROW_REVERSE:3,JUSTIFY_COUNT:6,JUSTIFY_FLEX_START:0,JUSTIFY_CENTER:1,JUSTIFY_FLEX_END:2,JUSTIFY_SPACE_BETWEEN:3,JUSTIFY_SPACE_AROUND:4,JUSTIFY_SPACE_EVENLY:5,LOG_LEVEL_COUNT:6,LOG_LEVEL_ERROR:0,LOG_LEVEL_WARN:1,LOG_LEVEL_INFO:2,LOG_LEVEL_DEBUG:3,LOG_LEVEL_VERBOSE:4,LOG_LEVEL_FATAL:5,MEASURE_MODE_COUNT:3,MEASURE_MODE_UNDEFINED:0,MEASURE_MODE_EXACTLY:1,MEASURE_MODE_AT_MOST:2,NODE_TYPE_COUNT:2,NODE_TYPE_DEFAULT:0,NODE_TYPE_TEXT:1,OVERFLOW_COUNT:3,OVERFLOW_VISIBLE:0,OVERFLOW_HIDDEN:1,OVERFLOW_SCROLL:2,POSITION_TYPE_COUNT:2,POSITION_TYPE_RELATIVE:0,POSITION_TYPE_ABSOLUTE:1,PRINT_OPTIONS_COUNT:3,PRINT_OPTIONS_LAYOUT:1,PRINT_OPTIONS_STYLE:2,PRINT_OPTIONS_CHILDREN:4,UNIT_COUNT:4,UNIT_UNDEFINED:0,UNIT_POINT:1,UNIT_PERCENT:2,UNIT_AUTO:3,WRAP_COUNT:3,WRAP_NO_WRAP:0,WRAP_WRAP:1,WRAP_WRAP_REVERSE:2};Dwe.exports=Spt});var Qwe=_((DKt,kwe)=>{"use strict";var Dpt=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var s in r)Object.prototype.hasOwnProperty.call(r,s)&&(t[s]=r[s])}return t},FF=function(){function t(e,r){for(var s=0;s<r.length;s++){var a=r[s];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}return function(e,r,s){return r&&t(e.prototype,r),s&&t(e,s),e}}();function V9(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function J9(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var tf=bwe(),bpt=function(){function t(e,r,s,a,n,c){J9(this,t),this.left=e,this.right=r,this.top=s,this.bottom=a,this.width=n,this.height=c}return FF(t,[{key:"fromJS",value:function(r){r(this.left,this.right,this.top,this.bottom,this.width,this.height)}},{key:"toString",value:function(){return"<Layout#"+this.left+":"+this.right+";"+this.top+":"+this.bottom+";"+this.width+":"+this.height+">"}}]),t}(),Pwe=function(){FF(t,null,[{key:"fromJS",value:function(r){var s=r.width,a=r.height;return new t(s,a)}}]);function t(e,r){J9(this,t),this.width=e,this.height=r}return FF(t,[{key:"fromJS",value:function(r){r(this.width,this.height)}},{key:"toStri Line truncated
`+Module.extraStackTrace()),demangleAll(t)}Module.stackTrace=stackTrace;var HEAP,buffer,HEAP8,HEAPU8,HEAP16,HEAPU16,HEAP32,HEAPU32,HEAPF32,HEAPF64;function updateGlobalBufferViews(){Module.HEAP8=HEAP8=new Int8Array(buffer),Module.HEAP16=HEAP16=new Int16Array(buffer),Module.HEAP32=HEAP32=new Int32Array(buffer),Module.HEAPU8=HEAPU8=new Uint8Array(buffer),Module.HEAPU16=HEAPU16=new Uint16Array(buffer),Module.HEAPU32=HEAPU32=new Uint32Array(buffer),Module.HEAPF32=HEAPF32=new Float32Array(buffer),Module.HEAPF64=HEAPF64=new Float64Array(buffer)}var STATIC_BASE,STATICTOP,staticSealed,STACK_BASE,STACKTOP,STACK_MAX,DYNAMIC_BASE,DYNAMICTOP_PTR;STATIC_BASE=STATICTOP=STACK_BASE=STACKTOP=STACK_MAX=DYNAMIC_BASE=DYNAMICTOP_PTR=0,staticSealed=!1;function abortOnCannotGrowMemory(){abort("Cannot enlarge memory arrays. Either (1) compile with -s TOTAL_MEMORY=X with X higher than the current value "+TOTAL_MEMORY+", (2) compile with -s ALLOW_MEMORY_GROWTH=1 which allows increasing the size at runtime but prevents some optimizations, (3) set Module.TOTAL_MEMORY to a higher value before the program runs, or (4) if you want malloc to return NULL (0) instead of this abort, compile with -s ABORTING_MALLOC=0 ")}function enlargeMemory(){abortOnCannotGrowMemory()}var TOTAL_STACK=Module.TOTAL_STACK||5242880,TOTAL_MEMORY=Module.TOTAL_MEMORY||134217728;TOTAL_MEMORY<TOTAL_STACK&&Module.printErr("TOTAL_MEMORY should be larger than TOTAL_STACK, was "+TOTAL_MEMORY+"! (TOTAL_STACK="+TOTAL_STACK+")"),Module.buffer?buffer=Module.buffer:buffer=new ArrayBuffer(TOTAL_MEMORY),updateGlobalBufferViews();function getTotalMemory(){return TOTAL_MEMORY}if(HEAP32[0]=1668509029,HEAP16[1]=25459,HEAPU8[2]!==115||HEAPU8[3]!==99)throw"Runtime error: expected the system to be little-endian!";Module.HEAP=HEAP,Module.buffer=buffer,Module.HEAP8=HEAP8,Module.HEAP16=HEAP16,Module.HEAP32=HEAP32,Module.HEAPU8=HEAPU8,Module.HEAPU16=HEAPU16,Module.HEAPU32=HEAPU32,Module.HEAPF32=HEAPF32,Module.HEAPF64=HEAPF64;function callRuntimeCallbacks(t){for(;t.length>0;){var e=t.shift();if(typeof e=="function"){e();continue}var r=e.func;typeof r=="number"?e.arg===void 0?Module.dynCall_v(r):Module.dynCall_vi(r,e.arg):r(e.arg===void 0?null:e.arg)}}var __ATPRERUN__=[],__ATINIT__=[],__ATMAIN__=[],__ATEXIT__=[],__ATPOSTRUN__=[],runtimeInitialized=!1,runtimeExited=!1;function preRun(){if(Module.preRun)for(typeof Module.preRun=="function"&&(Module.preRun=[Module.preRun]);Module.preRun.length;)addOnPreRun(Module.preRun.shift());callRuntimeCallbacks(__ATPRERUN__)}function ensureInitRuntime(){runtimeInitialized||(runtimeInitialized=!0,callRuntimeCallbacks(__ATINIT__))}function preMain(){callRuntimeCallbacks(__ATMAIN__)}function exitRuntime(){callRuntimeCallbacks(__ATEXIT__),runtimeExited=!0}function postRun(){if(Module.postRun)for(typeof Module.postRun=="function"&&(Module.postRun=[Module.postRun]);Module.postRun.length;)addOnPostRun(Module.postRun.shift());callRuntimeCallbacks(__ATPOSTRUN__)}function addOnPreRun(t){__ATPRERUN__.unshift(t)}Module.addOnPreRun=addOnPreRun;function addOnInit(t){__ATINIT__.unshift(t)}Module.addOnInit=addOnInit;function addOnPreMain(t){__ATMAIN__.unshift(t)}Module.addOnPreMain=addOnPreMain;function addOnExit(t){__ATEXIT__.unshift(t)}Module.addOnExit=addOnExit;function addOnPostRun(t){__ATPOSTRUN__.unshift(t)}Module.addOnPostRun=addOnPostRun;function intArrayFromString(t,e,r){var s=r>0?r:lengthBytesUTF8(t)+1,a=new Array(s),n=stringToUTF8Array(t,a,0,a.length);return e&&(a.length=n),a}Module.intArrayFromString=intArrayFromString;function intArrayToString(t){for(var e=[],r=0;r<t.length;r++){var s=t[r];s>255&&(s&=255),e.push(String.fromCharCode(s))}return e.join("")}Module.intArrayToString=intArrayToString;function writeStringToMemory(t,e,r){Runtime.warnOnce("writeStringToMemory is deprecated and should not be called! Use stringToUTF8() instead!");var s,a;r&&(a=e+lengthBytesUTF8(t),s=HEAP8[a]),stringToUTF8(t,e,1/0),r&&(HEAP8[a]=s)}Module.writeStringToMemory=writeStringToMemory;function writeArrayToMemory(t,e){HEAP8.set(t,e)}Module.writeArrayToMemory=writeArrayToMemory;function writeAsciiToMemory(t,e,r){for(var s=0;s<t.length;++s)HEAP8[e++>>0]=t.charCodeAt(s);r||(HEAP8[e>>0]=0)}if(Module.writeAsciiToMemory=writeAsciiToMemory,(!Math.imul||Math.imul(4294967295,5)!==-5)&&(Math.imul=function t(e,r){var s=e>>>16,a=e&65535,n=r>>>16,c=r&65535;return a*c+(s*c+a*n<<16)|0}),Math.imul=Math.imul,!Math.fround){var froundBuffer=new Float32Array(1);Math.fround=function(t){return froundBuffer[0]=t,froundBuffer[0]}}Math.fround=Math.fround,Math.clz32||(Math.clz32=function(t){t=t>>>0;for(var e=0;e<32;e++)if(t&1<<31-e)return e;return 32}),Math.clz32=Math.clz32,Math.trunc||(Math.trunc=function(t){return t<0?Math.ceil(t):Math.floor(t)}),Math.trunc=Math.trunc;var Math_abs=Math.abs,Math_cos=Math.cos,Math_sin=Math.sin,Math_tan=Math.tan,Math_acos=Math.acos,Math_asin=Math.asin,Math_atan=Math.atan,Math_atan2=Math.atan2,Math_exp=Math.exp,Math_log=Math.log,Math_sqrt=Math.sqrt,Math_ceil=Math.cei Line truncated
If this abort() is unexpected, build with -s ASSERTIONS=1 which can give more information.`,r="abort("+t+") at "+stackTrace()+e;throw abortDecorators&&abortDecorators.forEach(function(s){r=s(r,t)}),r}if(Module.abort=Module.abort=abort,Module.preInit)for(typeof Module.preInit=="function"&&(Module.preInit=[Module.preInit]);Module.preInit.length>0;)Module.preInit.pop()();var shouldRunNow=!0;Module.noInitialRun&&(shouldRunNow=!1),run()})});var Fm=_((PKt,Rwe)=>{"use strict";var Ppt=Qwe(),xpt=Twe(),K9=!1,z9=null;xpt({},function(t,e){if(!K9){if(K9=!0,t)throw t;z9=e}});if(!K9)throw new Error("Failed to load the yoga module - it needed to be loaded synchronously, but didn't");Rwe.exports=Ppt(z9.bind,z9.lib)});var Z9=_((xKt,X9)=>{"use strict";var Fwe=t=>Number.isNaN(t)?!1:t>=4352&&(t<=4447||t===9001||t===9002||11904<=t&&t<=12871&&t!==12351||12880<=t&&t<=19903||19968<=t&&t<=42182||43360<=t&&t<=43388||44032<=t&&t<=55203||63744<=t&&t<=64255||65040<=t&&t<=65049||65072<=t&&t<=65131||65281<=t&&t<=65376||65504<=t&&t<=65510||110592<=t&&t<=110593||127488<=t&&t<=127569||131072<=t&&t<=262141);X9.exports=Fwe;X9.exports.default=Fwe});var Owe=_((kKt,Nwe)=>{"use strict";Nwe.exports=function(){return/\uD83C\uDFF4\uDB40\uDC67\uDB40\uDC62(?:\uDB40\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDB40\uDC73\uDB40\uDC63\uDB40\uDC74|\uDB40\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F|\uD83D\uDC68(?:\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68\uD83C\uDFFB|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFE])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83D\uDC68|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D[\uDC66\uDC67])|[\u2695\u2696\u2708]\uFE0F|\uD83D[\uDC66\uDC67]|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|(?:\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708])\uFE0F|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C[\uDFFB-\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFB\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)\uD83C\uDFFB|\uD83E\uDDD1(?:\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])|\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1)|(?:\uD83E\uDDD1\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFE])|(?:\uD83E\uDDD1\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)(?:\uD83C[\uDFFB\uDFFC])|\uD83D\uDC69(?:\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFC-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|(?:\uD83E Line truncated
`))e=Math.max(e,Rpt(r));return e};eW.exports=Mwe;eW.exports.default=Mwe});var Uwe=_(qS=>{"use strict";var Fpt=qS&&qS.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(qS,"__esModule",{value:!0});var Npt=Fpt(tW()),rW={};qS.default=t=>{if(t.length===0)return{width:0,height:0};if(rW[t])return rW[t];let e=Npt.default(t),r=t.split(`
`).length;return rW[t]={width:e,height:r},{width:e,height:r}}});var _we=_(WS=>{"use strict";var Opt=WS&&WS.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(WS,"__esModule",{value:!0});var bn=Opt(Fm()),Lpt=(t,e)=>{"position"in e&&t.setPositionType(e.position==="absolute"?bn.default.POSITION_TYPE_ABSOLUTE:bn.default.POSITION_TYPE_RELATIVE)},Mpt=(t,e)=>{"marginLeft"in e&&t.setMargin(bn.default.EDGE_START,e.marginLeft||0),"marginRight"in e&&t.setMargin(bn.default.EDGE_END,e.marginRight||0),"marginTop"in e&&t.setMargin(bn.default.EDGE_TOP,e.marginTop||0),"marginBottom"in e&&t.setMargin(bn.default.EDGE_BOTTOM,e.marginBottom||0)},Upt=(t,e)=>{"paddingLeft"in e&&t.setPadding(bn.default.EDGE_LEFT,e.paddingLeft||0),"paddingRight"in e&&t.setPadding(bn.default.EDGE_RIGHT,e.paddingRight||0),"paddingTop"in e&&t.setPadding(bn.default.EDGE_TOP,e.paddingTop||0),"paddingBottom"in e&&t.setPadding(bn.default.EDGE_BOTTOM,e.paddingBottom||0)},_pt=(t,e)=>{var r;"flexGrow"in e&&t.setFlexGrow((r=e.flexGrow)!==null&&r!==void 0?r:0),"flexShrink"in e&&t.setFlexShrink(typeof e.flexShrink=="number"?e.flexShrink:1),"flexDirection"in e&&(e.flexDirection==="row"&&t.setFlexDirection(bn.default.FLEX_DIRECTION_ROW),e.flexDirection==="row-reverse"&&t.setFlexDirection(bn.default.FLEX_DIRECTION_ROW_REVERSE),e.flexDirection==="column"&&t.setFlexDirection(bn.default.FLEX_DIRECTION_COLUMN),e.flexDirection==="column-reverse"&&t.setFlexDirection(bn.default.FLEX_DIRECTION_COLUMN_REVERSE)),"flexBasis"in e&&(typeof e.flexBasis=="number"?t.setFlexBasis(e.flexBasis):typeof e.flexBasis=="string"?t.setFlexBasisPercent(Number.parseInt(e.flexBasis,10)):t.setFlexBasis(NaN)),"alignItems"in e&&((e.alignItems==="stretch"||!e.alignItems)&&t.setAlignItems(bn.default.ALIGN_STRETCH),e.alignItems==="flex-start"&&t.setAlignItems(bn.default.ALIGN_FLEX_START),e.alignItems==="center"&&t.setAlignItems(bn.default.ALIGN_CENTER),e.alignItems==="flex-end"&&t.setAlignItems(bn.default.ALIGN_FLEX_END)),"alignSelf"in e&&((e.alignSelf==="auto"||!e.alignSelf)&&t.setAlignSelf(bn.default.ALIGN_AUTO),e.alignSelf==="flex-start"&&t.setAlignSelf(bn.default.ALIGN_FLEX_START),e.alignSelf==="center"&&t.setAlignSelf(bn.default.ALIGN_CENTER),e.alignSelf==="flex-end"&&t.setAlignSelf(bn.default.ALIGN_FLEX_END)),"justifyContent"in e&&((e.justifyContent==="flex-start"||!e.justifyContent)&&t.setJustifyContent(bn.default.JUSTIFY_FLEX_START),e.justifyContent==="center"&&t.setJustifyContent(bn.default.JUSTIFY_CENTER),e.justifyContent==="flex-end"&&t.setJustifyContent(bn.default.JUSTIFY_FLEX_END),e.justifyContent==="space-between"&&t.setJustifyContent(bn.default.JUSTIFY_SPACE_BETWEEN),e.justifyContent==="space-around"&&t.setJustifyContent(bn.default.JUSTIFY_SPACE_AROUND))},Hpt=(t,e)=>{var r,s;"width"in e&&(typeof e.width=="number"?t.setWidth(e.width):typeof e.width=="string"?t.setWidthPercent(Number.parseInt(e.width,10)):t.setWidthAuto()),"height"in e&&(typeof e.height=="number"?t.setHeight(e.height):typeof e.height=="string"?t.setHeightPercent(Number.parseInt(e.height,10)):t.setHeightAuto()),"minWidth"in e&&(typeof e.minWidth=="string"?t.setMinWidthPercent(Number.parseInt(e.minWidth,10)):t.setMinWidth((r=e.minWidth)!==null&&r!==void 0?r:0)),"minHeight"in e&&(typeof e.minHeight=="string"?t.setMinHeightPercent(Number.parseInt(e.minHeight,10)):t.setMinHeight((s=e.minHeight)!==null&&s!==void 0?s:0))},jpt=(t,e)=>{"display"in e&&t.setDisplay(e.display==="flex"?bn.default.DISPLAY_FLEX:bn.default.DISPLAY_NONE)},Gpt=(t,e)=>{if("borderStyle"in e){let r=typeof e.borderStyle=="string"?1:0;t.setBorder(bn.default.EDGE_TOP,r),t.setBorder(bn.default.EDGE_BOTTOM,r),t.setBorder(bn.default.EDGE_LEFT,r),t.setBorder(bn.default.EDGE_RIGHT,r)}};WS.default=(t,e={})=>{Lpt(t,e),Mpt(t,e),Upt(t,e),_pt(t,e),Hpt(t,e),jpt(t,e),Gpt(t,e)}});var Gwe=_((NKt,jwe)=>{"use strict";var YS=GS(),qpt=dk(),Wpt=sk(),iW=new Set(["\x1B","\x9B"]),Ypt=39,Hwe=t=>`${iW.values().next().value}[${t}m`,Vpt=t=>t.split(" ").map(e=>YS(e)),nW=(t,e,r)=>{let s=[...e],a=!1,n=YS(qpt(t[t.length-1]));for(let[c,f]of s.entries()){let p=YS(f);if(n+p<=r?t[t.length-1]+=f:(t.push(f),n=0),iW.has(f))a=!0;else if(a&&f==="m"){a=!1;continue}a||(n+=p,n===r&&c<s.length-1&&(t.push(""),n=0))}!n&&t[t.length-1].length>0&&t.length>1&&(t[t.length-2]+=t.pop())},Jpt=t=>{let e=t.split(" "),r=e.length;for(;r>0&&!(YS(e[r-1])>0);)r--;return r===e.length?t:e.slice(0,r).join(" ")+e.slice(r).join("")},Kpt=(t,e,r={})=>{if(r.trim!==!1&&t.trim()==="")return"";let s="",a="",n,c=Vpt(t),f=[""];for(let[p,h]of t.split(" ").entries()){r.trim!==!1&&(f[f.length-1]=f[f.length-1].trimLeft());let E=YS(f[f.length-1]);if(p!==0&&(E>=e&&(r.wordWrap===!1||r.trim===!1)&&(f.push(""),E=0),(E>0||r.trim===!1)&&(f[f.length-1]+=" ",E++)),r.hard&&c[p]>e){let C=e-E,S=1+Math.floor((c[p]-C-1)/e);Math.floor((c[p]-1)/e)<S&&f.push(""),nW(f,h,e);continue}if(E+c[p]>e&&E>0&&c[p]>0){if(r.wordWrap===!1&&E<e){nW(f,h,e);continue}f.push("")}if(E+c[p]>e&&r.wordWrap===!1){nW(f,h,e);continue}f[f. Line truncated
`);for(let[p,h]of[...s].entries()){if(a+=h,iW.has(h)){let C=parseFloat(/\d[^m]*/.exec(s.slice(p,p+4)));n=C===Ypt?null:C}let E=Wpt.codes.get(Number(n));n&&E&&(s[p+1]===`
`?a+=Hwe(E):h===`
`&&(a+=Hwe(n)))}return a};jwe.exports=(t,e,r)=>String(t).normalize().replace(/\r\n/g,`
`).split(`
`).map(s=>Kpt(s,e,r)).join(`
`)});var Ywe=_((OKt,Wwe)=>{"use strict";var qwe="[\uD800-\uDBFF][\uDC00-\uDFFF]",zpt=t=>t&&t.exact?new RegExp(`^${qwe}$`):new RegExp(qwe,"g");Wwe.exports=zpt});var sW=_((LKt,zwe)=>{"use strict";var Xpt=Z9(),Zpt=Ywe(),Vwe=sk(),Kwe=["\x1B","\x9B"],NF=t=>`${Kwe[0]}[${t}m`,Jwe=(t,e,r)=>{let s=[];t=[...t];for(let a of t){let n=a;a.match(";")&&(a=a.split(";")[0][0]+"0");let c=Vwe.codes.get(parseInt(a,10));if(c){let f=t.indexOf(c.toString());f>=0?t.splice(f,1):s.push(NF(e?c:n))}else if(e){s.push(NF(0));break}else s.push(NF(n))}if(e&&(s=s.filter((a,n)=>s.indexOf(a)===n),r!==void 0)){let a=NF(Vwe.codes.get(parseInt(r,10)));s=s.reduce((n,c)=>c===a?[c,...n]:[...n,c],[])}return s.join("")};zwe.exports=(t,e,r)=>{let s=[...t.normalize()],a=[];r=typeof r=="number"?r:s.length;let n=!1,c,f=0,p="";for(let[h,E]of s.entries()){let C=!1;if(Kwe.includes(E)){let S=/\d[^m]*/.exec(t.slice(h,h+18));c=S&&S.length>0?S[0]:void 0,f<r&&(n=!0,c!==void 0&&a.push(c))}else n&&E==="m"&&(n=!1,C=!0);if(!n&&!C&&++f,!Zpt({exact:!0}).test(E)&&Xpt(E.codePointAt())&&++f,f>e&&f<=r)p+=E;else if(f===e&&!n&&c!==void 0)p=Jwe(a);else if(f>=r){p+=Jwe(a,!0,c);break}}return p}});var Zwe=_((MKt,Xwe)=>{"use strict";var $0=sW(),$pt=GS();function OF(t,e,r){if(t.charAt(e)===" ")return e;for(let s=1;s<=3;s++)if(r){if(t.charAt(e+s)===" ")return e+s}else if(t.charAt(e-s)===" ")return e-s;return e}Xwe.exports=(t,e,r)=>{r={position:"end",preferTruncationOnSpace:!1,...r};let{position:s,space:a,preferTruncationOnSpace:n}=r,c="\u2026",f=1;if(typeof t!="string")throw new TypeError(`Expected \`input\` to be a string, got ${typeof t}`);if(typeof e!="number")throw new TypeError(`Expected \`columns\` to be a number, got ${typeof e}`);if(e<1)return"";if(e===1)return c;let p=$pt(t);if(p<=e)return t;if(s==="start"){if(n){let h=OF(t,p-e+1,!0);return c+$0(t,h,p).trim()}return a===!0&&(c+=" ",f=2),c+$0(t,p-e+f,p)}if(s==="middle"){a===!0&&(c=" "+c+" ",f=3);let h=Math.floor(e/2);if(n){let E=OF(t,h),C=OF(t,p-(e-h)+1,!0);return $0(t,0,E)+c+$0(t,C,p).trim()}return $0(t,0,h)+c+$0(t,p-(e-h)+f,p)}if(s==="end"){if(n){let h=OF(t,e-1);return $0(t,0,h)+c}return a===!0&&(c=" "+c,f=2),$0(t,0,e-f)+c}throw new Error(`Expected \`options.position\` to be either \`start\`, \`middle\` or \`end\`, got ${s}`)}});var aW=_(VS=>{"use strict";var $we=VS&&VS.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(VS,"__esModule",{value:!0});var eht=$we(Gwe()),tht=$we(Zwe()),oW={};VS.default=(t,e,r)=>{let s=t+String(e)+String(r);if(oW[s])return oW[s];let a=t;if(r==="wrap"&&(a=eht.default(t,e,{trim:!1,hard:!0})),r.startsWith("truncate")){let n="end";r==="truncate-middle"&&(n="middle"),r==="truncate-start"&&(n="start"),a=tht.default(t,e,{position:n})}return oW[s]=a,a}});var cW=_(lW=>{"use strict";Object.defineProperty(lW,"__esModule",{value:!0});var e1e=t=>{let e="";if(t.childNodes.length>0)for(let r of t.childNodes){let s="";r.nodeName==="#text"?s=r.nodeValue:((r.nodeName==="ink-text"||r.nodeName==="ink-virtual-text")&&(s=e1e(r)),s.length>0&&typeof r.internal_transform=="function"&&(s=r.internal_transform(s))),e+=s}return e};lW.default=e1e});var uW=_(bi=>{"use strict";var JS=bi&&bi.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(bi,"__esModule",{value:!0});bi.setTextNodeValue=bi.createTextNode=bi.setStyle=bi.setAttribute=bi.removeChildNode=bi.insertBeforeNode=bi.appendChildNode=bi.createNode=bi.TEXT_NAME=void 0;var rht=JS(Fm()),t1e=JS(Uwe()),nht=JS(_we()),iht=JS(aW()),sht=JS(cW());bi.TEXT_NAME="#text";bi.createNode=t=>{var e;let r={nodeName:t,style:{},attributes:{},childNodes:[],parentNode:null,yogaNode:t==="ink-virtual-text"?void 0:rht.default.Node.create()};return t==="ink-text"&&((e=r.yogaNode)===null||e===void 0||e.setMeasureFunc(oht.bind(null,r))),r};bi.appendChildNode=(t,e)=>{var r;e.parentNode&&bi.removeChildNode(e.parentNode,e),e.parentNode=t,t.childNodes.push(e),e.yogaNode&&((r=t.yogaNode)===null||r===void 0||r.insertChild(e.yogaNode,t.yogaNode.getChildCount())),(t.nodeName==="ink-text"||t.nodeName==="ink-virtual-text")&&LF(t)};bi.insertBeforeNode=(t,e,r)=>{var s,a;e.parentNode&&bi.removeChildNode(e.parentNode,e),e.parentNode=t;let n=t.childNodes.indexOf(r);if(n>=0){t.childNodes.splice(n,0,e),e.yogaNode&&((s=t.yogaNode)===null||s===void 0||s.insertChild(e.yogaNode,n));return}t.childNodes.push(e),e.yogaNode&&((a=t.yogaNode)===null||a===void 0||a.insertChild(e.yogaNode,t.yogaNode.getChildCount())),(t.nodeName==="ink-text"||t.nodeName==="ink-virtual-text")&&LF(t)};bi.removeChildNode=(t,e)=>{var r,s;e.yogaNode&&((s=(r=e.parentNode)===null||r===void 0?void 0:r.yogaNode)===null||s===void 0||s.removeChild(e.yogaNode)),e.parentNode=null;let a=t.childNodes.indexOf(e);a>=0&&t.childNodes.splice(a,1),(t.nodeName==="ink-text"||t.nodeName==="ink-virtual-text")&&LF(t)};bi.setAttribute=(t,e,r)=>{t.attributes[e]=r};bi.setStyle=(t,e)=>{t.style=e,t.yogaNode&&nht.default(t.yogaNode,e)};bi.createTextNode=t=>{let e={nodeName:"#text",nodeValue:t,yogaLine truncated
`).repeat(n-2),E=pW.default(f.bottomLeft+f.horizontal.repeat(a-2)+f.bottomRight,c,"foreground");s.write(t,e,p,{transformers:[]}),s.write(t,e+1,h,{transformers:[]}),s.write(t+a-1,e+1,h,{transformers:[]}),s.write(t,e+n-1,E,{transformers:[]})}}});var m1e=_(eD=>{"use strict";var Nm=eD&&eD.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(eD,"__esModule",{value:!0});var hht=Nm(Fm()),ght=Nm(tW()),dht=Nm(c1e()),mht=Nm(aW()),yht=Nm(u1e()),Eht=Nm(cW()),Iht=Nm(g1e()),Cht=(t,e)=>{var r;let s=(r=t.childNodes[0])===null||r===void 0?void 0:r.yogaNode;if(s){let a=s.getComputedLeft(),n=s.getComputedTop();e=`
`.repeat(n)+dht.default(e,a)}return e},d1e=(t,e,r)=>{var s;let{offsetX:a=0,offsetY:n=0,transformers:c=[],skipStaticElements:f}=r;if(f&&t.internal_static)return;let{yogaNode:p}=t;if(p){if(p.getDisplay()===hht.default.DISPLAY_NONE)return;let h=a+p.getComputedLeft(),E=n+p.getComputedTop(),C=c;if(typeof t.internal_transform=="function"&&(C=[t.internal_transform,...c]),t.nodeName==="ink-text"){let S=Eht.default(t);if(S.length>0){let P=ght.default(S),I=yht.default(p);if(P>I){let R=(s=t.style.textWrap)!==null&&s!==void 0?s:"wrap";S=mht.default(S,I,R)}S=Cht(t,S),e.write(h,E,S,{transformers:C})}return}if(t.nodeName==="ink-box"&&Iht.default(h,E,t,e),t.nodeName==="ink-root"||t.nodeName==="ink-box")for(let S of t.childNodes)d1e(S,e,{offsetX:h,offsetY:E,transformers:C,skipStaticElements:f})}};eD.default=d1e});var I1e=_(tD=>{"use strict";var E1e=tD&&tD.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(tD,"__esModule",{value:!0});var y1e=E1e(sW()),wht=E1e(GS()),hW=class{constructor(e){this.writes=[];let{width:r,height:s}=e;this.width=r,this.height=s}write(e,r,s,a){let{transformers:n}=a;s&&this.writes.push({x:e,y:r,text:s,transformers:n})}get(){let e=[];for(let s=0;s<this.height;s++)e.push(" ".repeat(this.width));for(let s of this.writes){let{x:a,y:n,text:c,transformers:f}=s,p=c.split(`
`),h=0;for(let E of p){let C=e[n+h];if(!C)continue;let S=wht.default(E);for(let P of f)E=P(E);e[n+h]=y1e.default(C,0,a)+E+y1e.default(C,a+S),h++}}return{output:e.map(s=>s.trimRight()).join(`
`),height:e.length}}};tD.default=hW});var B1e=_(rD=>{"use strict";var gW=rD&&rD.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(rD,"__esModule",{value:!0});var Bht=gW(Fm()),C1e=gW(m1e()),w1e=gW(I1e());rD.default=(t,e)=>{var r;if(t.yogaNode.setWidth(e),t.yogaNode){t.yogaNode.calculateLayout(void 0,void 0,Bht.default.DIRECTION_LTR);let s=new w1e.default({width:t.yogaNode.getComputedWidth(),height:t.yogaNode.getComputedHeight()});C1e.default(t,s,{skipStaticElements:!0});let a;!((r=t.staticNode)===null||r===void 0)&&r.yogaNode&&(a=new w1e.default({width:t.staticNode.yogaNode.getComputedWidth(),height:t.staticNode.yogaNode.getComputedHeight()}),C1e.default(t.staticNode,a,{skipStaticElements:!1}));let{output:n,height:c}=s.get();return{output:n,outputHeight:c,staticOutput:a?`${a.get().output}
`:""}}return{output:"",outputHeight:0,staticOutput:""}}});var b1e=_((ZKt,D1e)=>{"use strict";var v1e=Ie("stream"),S1e=["assert","count","countReset","debug","dir","dirxml","error","group","groupCollapsed","groupEnd","info","log","table","time","timeEnd","timeLog","trace","warn"],dW={},vht=t=>{let e=new v1e.PassThrough,r=new v1e.PassThrough;e.write=a=>t("stdout",a),r.write=a=>t("stderr",a);let s=new console.Console(e,r);for(let a of S1e)dW[a]=console[a],console[a]=s[a];return()=>{for(let a of S1e)console[a]=dW[a];dW={}}};D1e.exports=vht});var yW=_(mW=>{"use strict";Object.defineProperty(mW,"__esModule",{value:!0});mW.default=new WeakMap});var IW=_(EW=>{"use strict";Object.defineProperty(EW,"__esModule",{value:!0});var Sht=hn(),P1e=Sht.createContext({exit:()=>{}});P1e.displayName="InternalAppContext";EW.default=P1e});var wW=_(CW=>{"use strict";Object.defineProperty(CW,"__esModule",{value:!0});var Dht=hn(),x1e=Dht.createContext({stdin:void 0,setRawMode:()=>{},isRawModeSupported:!1,internal_exitOnCtrlC:!0});x1e.displayName="InternalStdinContext";CW.default=x1e});var vW=_(BW=>{"use strict";Object.defineProperty(BW,"__esModule",{value:!0});var bht=hn(),k1e=bht.createContext({stdout:void 0,write:()=>{}});k1e.displayName="InternalStdoutContext";BW.default=k1e});var DW=_(SW=>{"use strict";Object.defineProperty(SW,"__esModule",{value:!0});var Pht=hn(),Q1e=Pht.createContext({stderr:void 0,write:()=>{}});Q1e.displayName="InternalStderrContext";SW.default=Q1e});var _F=_(bW=>{"use strict";Object.defineProperty(bW,"__esModule",{value:!0});var xht=hn(),T1e=xht.createContext({activeId:void 0,add:()=>{},remove:()=>{},activate:()=>{},deactivate:()=>{},enableFocus:()=>{},disableFocus:()=>{},focusNext:()=>{},focusPrevious:()=>{},focus:()=>{}});T1e.displayName="InternalFocusContext";bW.default=T1e});var F1e=_((szt,R1e)=>{"use strict";var kht=/[|\\{}()[\]^$+*?.-]/g;R1e.exports=t=>{if(typeof t!="string")throw new TypeError("Expected a string");return t.replace(kht,"\\$&")}});var M1e=_((ozt,L1e)=>{"use strict";var Qht=F1e(),Tht=typeof process=="object"&&process&&typeof process.cwd=="function"?process.cwd():".",O1e=[].concat(Ie("module").builtinModules,"bootstrap_node","node").map(t=>new RegExp(`(?:\\((?:node:)?${t}(?:\\.js)?:\\d+:\\d+\\)$|^\\s*at (?:node:)?${t}(?:\\.js)?:\\d+:\\d+$)`));O1e.push(/\((?:node:)?internal\/[^:]+:\d+:\d+\)$/,/\s*at (?:node:)?internal\/[^:]+:\d+:\d+$/,/\/\.node-spawn-wrap-\w+-\w+\/node:\d+:\d+\)?$/);var PW=class t{constructor(e){e={ignoredPackages:[],...e},"internals"in e||(e.internals=t.nodeInternals()),"cwd"in e||(e.cwd=Tht),this._cwd=e.cwd.replace(/\\/g,"/"),this._internals=[].concat(e.internals,Rht(e.ignoredPackages)),this._wrapCallSite=e.wrapCallSite||!1}static nodeInternals(){return[...O1e]}clean(e,r=0){r=" ".repeat(r),Array.isArray(e)||(e=e.split(`
`)),!/^\s*at /.test(e[0])&&/^\s*at /.test(e[1])&&(e=e.slice(1));let s=!1,a=null,n=[];return e.forEach(c=>{if(c=c.replace(/\\/g,"/"),this._internals.some(p=>p.test(c)))return;let f=/^\s*at /.test(c);s?c=c.trimEnd().replace(/^(\s+)at /,"$1"):(c=c.trim(),f&&(c=c.slice(3))),c=c.replace(`${this._cwd}/`,""),c&&(f?(a&&(n.push(a),a=null),n.push(c)):(s=!0,a=c))}),n.map(c=>`${r}${c}
`).join("")}captureString(e,r=this.captureString){typeof e=="function"&&(r=e,e=1/0);let{stackTraceLimit:s}=Error;e&&(Error.stackTraceLimit=e);let a={};Error.captureStackTrace(a,r);let{stack:n}=a;return Error.stackTraceLimit=s,this.clean(n)}capture(e,r=this.capture){typeof e=="function"&&(r=e,e=1/0);let{prepareStackTrace:s,stackTraceLimit:a}=Error;Error.prepareStackTrace=(f,p)=>this._wrapCallSite?p.map(this._wrapCallSite):p,e&&(Error.stackTraceLimit=e);let n={};Error.captureStackTrace(n,r);let{stack:c}=n;return Object.assign(Error,{prepareStackTrace:s,stackTraceLimit:a}),c}at(e=this.at){let[r]=this.capture(1,e);if(!r)return{};let s={line:r.getLineNumber(),column:r.getColumnNumber()};N1e(s,r.getFileName(),this._cwd),r.isConstructor()&&(s.constructor=!0),r.isEval()&&(s.evalOrigin=r.getEvalOrigin()),r.isNative()&&(s.native=!0);let a;try{a=r.getTypeName()}catch{}a&&a!=="Object"&&a!=="[object Object]"&&(s.type=a);let n=r.getFunctionName();n&&(s.function=n);let c=r.getMethodName();return c&&n!==c&&(s.method=c),s}parseLine(e){let r=e&&e.match(Fht);if(!r)return null;let s=r[1]==="new",a=r[2],n=r[3],c=r[4],f=Number(r[5]),p=Number(r[6]),h=r[7],E=r[8],C=r[9],S=r[10]==="native",P=r[11]===")",I,R={};if(E&&(R.line=Number(E)),C&&(R.column=Number(C)),P&&h){let N=0;for(let U=h.length-1;U>0;U--)if(h.charAt(U)===")")N++;else if(h.charAt(U)==="("&&h.charAt(U-1)===" "&&(N--,N===-1&&h.charAt(U-1)===" ")){let W=h.slice(0,U-1);h=h.slice(U+1),a+=` (${W}`;break}}if(a){let N=a.match(Nht);N&&(a=N[1],I=N[2])}return N1e(R,h,this._cwd),s&&(R.constructor=!0),n&&(R.evalOrigin=n,R.evalLine=f,R.evalColumn=p,R.evalFile=c&&c.replace(/\\/g,"/")),S&&(R.native=!0),a&&(R.function=a),I&&a!==I&&(R.method=I),R}};function N1e(t,e,r){e&&(e=e.replace(/\\/g,"/"),e.startsWith(`${r}/`)&&(e=e.slice(r.length+1)),t.file=e)}function Rht(t){if(t.length===0)return[];let e=t.map(r=>Qht(r));return new RegExp(`[/\\\\]node_modules[/\\\\](?:${e.join("|")})[/\\\\][^:]+:\\d+:\\d+`)}var Fht=new RegExp("^(?:\\s*at )?(?:(new) )?(?:(.*?) \\()?(?:eval at ([^ ]+) \\((.+?):(\\d+):(\\d+)\\), )?(?:(.+?):(\\d+):(\\d+)|(native))(\\)?)$"),Nht=/^(.*?) \[as (.*?)\]$/;L1e.exports=PW});var _1e=_((azt,U1e)=>{"use strict";U1e.exports=(t,e)=>t.replace(/^\t+/gm,r=>" ".repeat(r.length*(e||2)))});var j1e=_((lzt,H1e)=>{"use strict";var Oht=_1e(),Lht=(t,e)=>{let r=[],s=t-e,a=t+e;for(let n=s;n<=a;n++)r.push(n);return r};H1e.exports=(t,e,r)=>{if(typeof t!="string")throw new TypeError("Source code is missing.");if(!e||e<1)throw new TypeError("Line number must start from `1`.");if(t=Oht(t).split(/\r?\n/),!(e>t.length))return r={around:3,...r},Lht(e,r.around).filter(s=>t[s-1]!==void 0).map(s=>({line:s,value:t[s-1]}))}});var HF=_(rf=>{"use strict";var Mht=rf&&rf.__createBinding||(Object.create?function(t,e,r,s){s===void 0&&(s=r),Object.defineProperty(t,s,{enumerable:!0,get:function(){return e[r]}})}:function(t,e,r,s){s===void 0&&(s=r),t[s]=e[r]}),Uht=rf&&rf.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e}),_ht=rf&&rf.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.hasOwnProperty.call(t,r)&&Mht(e,t,r);return Uht(e,t),e},Hht=rf&&rf.__rest||function(t,e){var r={};for(var s in t)Object.prototype.hasOwnProperty.call(t,s)&&e.indexOf(s)<0&&(r[s]=t[s]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,s=Object.getOwnPropertySymbols(t);a<s.length;a++)e.indexOf(s[a])<0&&Object.prototype.propertyIsEnumerable.call(t,s[a])&&(r[s[a]]=t[s[a]]);return r};Object.defineProperty(rf,"__esModule",{value:!0});var G1e=_ht(hn()),xW=G1e.forwardRef((t,e)=>{var{children:r}=t,s=Hht(t,["children"]);let a=Object.assign(Object.assign({},s),{marginLeft:s.marginLeft||s.marginX||s.margin||0,marginRight:s.marginRight||s.marginX||s.margin||0,marginTop:s.marginTop||s.marginY||s.margin||0,marginBottom:s.marginBottom||s.marginY||s.margin||0,paddingLeft:s.paddingLeft||s.paddingX||s.padding||0,paddingRight:s.paddingRight||s.paddingX||s.padding||0,paddingTop:s.paddingTop||s.paddingY||s.padding||0,paddingBottom:s.paddingBottom||s.paddingY||s.padding||0});return G1e.default.createElement("ink-box",{ref:e,style:a},r)});xW.displayName="Box";xW.defaultProps={flexDirection:"row",flexGrow:0,flexShrink:1};rf.default=xW});var TW=_(nD=>{"use strict";var kW=nD&&nD.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(nD,"__esModule",{value:!0});var jht=kW(hn()),yw=kW(TE()),q1e=kW(AW()),QW=({color:t,backgroundColor:e,dimColor:r,bold:s,italic:a,underline:n,strikethrough:c,inverse:f,wrap:p,children:h})=>{if(h==null)return null;let E=C=>(r&&(C=yw.default.dim(C)),t&&(C=q1e.default(C,t,"foreground")),e&&(C=q1e.default(C,e,"background")),s&&(C=yw.default.bold(C)),a&&(C=yw.default.italic(C)),n&&(C=yw.default.underline(C)),c&&(C=yw.default.strikethrough(C)),f&&(C=yw.default.inverse(C)),C);return jht.default.createElement("ink-text",{style:{flexGrow:0,flexSLine truncated
`).slice(1):void 0,r=e?V1e.parseLine(e[0]):void 0,s,a=0;if(r?.file&&r?.line&&W1e.existsSync(r.file)){let n=W1e.readFileSync(r.file,"utf8");if(s=Yht.default(n,r.line),s)for(let{line:c}of s)a=Math.max(a,String(c).length)}return Qs.default.createElement($p.default,{flexDirection:"column",padding:1},Qs.default.createElement($p.default,null,Qs.default.createElement(AA.default,{backgroundColor:"red",color:"white"}," ","ERROR"," "),Qs.default.createElement(AA.default,null," ",t.message)),r&&Qs.default.createElement($p.default,{marginTop:1},Qs.default.createElement(AA.default,{dimColor:!0},r.file,":",r.line,":",r.column)),r&&s&&Qs.default.createElement($p.default,{marginTop:1,flexDirection:"column"},s.map(({line:n,value:c})=>Qs.default.createElement($p.default,{key:n},Qs.default.createElement($p.default,{width:a+1},Qs.default.createElement(AA.default,{dimColor:n!==r.line,backgroundColor:n===r.line?"red":void 0,color:n===r.line?"white":void 0},String(n).padStart(a," "),":")),Qs.default.createElement(AA.default,{key:n,backgroundColor:n===r.line?"red":void 0,color:n===r.line?"white":void 0}," "+c)))),t.stack&&Qs.default.createElement($p.default,{marginTop:1,flexDirection:"column"},t.stack.split(`
`).slice(1).map(n=>{let c=V1e.parseLine(n);return c?Qs.default.createElement($p.default,{key:n},Qs.default.createElement(AA.default,{dimColor:!0},"- "),Qs.default.createElement(AA.default,{dimColor:!0,bold:!0},c.function),Qs.default.createElement(AA.default,{dimColor:!0,color:"gray"}," ","(",c.file,":",c.line,":",c.column,")")):Qs.default.createElement($p.default,{key:n},Qs.default.createElement(AA.default,{dimColor:!0},"- "),Qs.default.createElement(AA.default,{dimColor:!0,bold:!0},n))})))};nf.default=Vht});var z1e=_(sf=>{"use strict";var Jht=sf&&sf.__createBinding||(Object.create?function(t,e,r,s){s===void 0&&(s=r),Object.defineProperty(t,s,{enumerable:!0,get:function(){return e[r]}})}:function(t,e,r,s){s===void 0&&(s=r),t[s]=e[r]}),Kht=sf&&sf.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e}),zht=sf&&sf.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.hasOwnProperty.call(t,r)&&Jht(e,t,r);return Kht(e,t),e},Lm=sf&&sf.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(sf,"__esModule",{value:!0});var Om=zht(hn()),K1e=Lm(F9()),Xht=Lm(IW()),Zht=Lm(wW()),$ht=Lm(vW()),e0t=Lm(DW()),t0t=Lm(_F()),r0t=Lm(J1e()),n0t=" ",i0t="\x1B[Z",s0t="\x1B",jF=class extends Om.PureComponent{constructor(){super(...arguments),this.state={isFocusEnabled:!0,activeFocusId:void 0,focusables:[],error:void 0},this.rawModeEnabledCount=0,this.handleSetRawMode=e=>{let{stdin:r}=this.props;if(!this.isRawModeSupported())throw r===process.stdin?new Error(`Raw mode is not supported on the current process.stdin, which Ink uses as input stream by default.
Read about how to prevent this error on https://github.com/vadimdemedes/ink/#israwmodesupported`):new Error(`Raw mode is not supported on the stdin provided to Ink.
Read about how to prevent this error on https://github.com/vadimdemedes/ink/#israwmodesupported`);if(r.setEncoding("utf8"),e){this.rawModeEnabledCount===0&&(r.addListener("data",this.handleInput),r.resume(),r.setRawMode(!0)),this.rawModeEnabledCount++;return}--this.rawModeEnabledCount===0&&(r.setRawMode(!1),r.removeListener("data",this.handleInput),r.pause())},this.handleInput=e=>{e===""&&this.props.exitOnCtrlC&&this.handleExit(),e===s0t&&this.state.activeFocusId&&this.setState({activeFocusId:void 0}),this.state.isFocusEnabled&&this.state.focusables.length>0&&(e===n0t&&this.focusNext(),e===i0t&&this.focusPrevious())},this.handleExit=e=>{this.isRawModeSupported()&&this.handleSetRawMode(!1),this.props.onExit(e)},this.enableFocus=()=>{this.setState({isFocusEnabled:!0})},this.disableFocus=()=>{this.setState({isFocusEnabled:!1})},this.focus=e=>{this.setState(r=>r.focusables.some(a=>a?.id===e)?{activeFocusId:e}:r)},this.focusNext=()=>{this.setState(e=>{var r;let s=(r=e.focusables[0])===null||r===void 0?void 0:r.id;return{activeFocusId:this.findNextFocusable(e)||s}})},this.focusPrevious=()=>{this.setState(e=>{var r;let s=(r=e.focusables[e.focusables.length-1])===null||r===void 0?void 0:r.id;return{activeFocusId:this.findPreviousFocusable(e)||s}})},this.addFocusable=(e,{autoFocus:r})=>{this.setState(s=>{let a=s.activeFocusId;return!a&&r&&(a=e),{activeFocusId:a,focusables:[...s.focusables,{id:e,isActive:!0}]}})},this.removeFocusable=e=>{this.setState(r=>({activeFocusId:r.activeFocusId===e?void 0:r.activeFocusId,focusables:r.focusables.filter(s=>s.id!==e)}))},this.activateFocusable=e=>{this.setState(r=>({focusables:r.focusables.map(s=>s.id!==e?s:{id:e,isActive:!0})}))},this.deactivateFocusable=e=>{this.setState(r=>({activeFocusId:r.activeFocusId===e?void 0:r.activeFocusId,focusables:r.focusables.map(s=>s.id!==e?s:{id:e,isActive:!1})}))},this.findNextFocusable=e=>{var r;let s=e.focusables.findIndex(a=>a.id===e.activeFocusId);for(let a=s+1;a<e.focusables.length;a++)if(!((r=e.focusables[a])===null||r===void 0)&&r.isActive)return e.focusables[a].id},this.findPreviousFocusable=e=>{var r;let s=e.focusables.findIndex(a=>a.id===e.activeFocusId);for(let a=s-1;a>=0;a--)if(!((r=e.focusables[a])===null||r===void 0)&&r.isActive)return e.focusables[a].id}}static getDerivedStateFromError(e){return{error:e}}isRawModeSupported(){return this.props.stdin.isTTY}render(){return Om.default.createElement(Xht.default.Provider,{value:{exit:this.handleExit}},Om.default.createElement(Zht.default.Provider,{value:{stdin:this.props.stdin,setRawMode:this.handleSetRawMode,isRawModeSupported:this.isRawModeSupported(),internal_exitOnCtrlC:this.props.exitOnCtrlC}},Om.default.createElement($ht.default.Provider,{value:{stdout:this.props.stdout,write:this.props.writeToStdout}},Om.default.createElement(e0t.default.Provider,{value:{stderr:this.props.stderr,write:this.props.writeToStderr}},Om.default.createElement(t0t.default.Provider,{value:{activeId:this.state.activeFocusId,add:this.addFocusable,remove:this.removeFocusable,activate:this.activateFocusable,deactivate:this.deactivateFocusable,enableFocus:this.enableFocus,disableFocus:this.disableFocus,focusNext:this.focusNext,focusPrevious:this.focusPrevious,focus:this.focus}},this.state.error?Om.default.createElement(r0t.default,{error:this.state.error}):this.props.children)))))}componentDidMount(){K1e.default.hide(this.props.stdout)}componentWillUnmount(){K1e.default.show(this.props.stdout),this.isRawModeSupported()&&this.handleSetRawMode(!1)}componentDidCatch(e){this.handleExit(e)}};sf.default=jF;jF.displayName="InternalApp"});var $1e=_(of=>{"use strict";var o0t=of&&of.__createBinding||(Object.create?function(t,e,r,s){s===void 0&&(s=r),Object.defineProperty(t,s,{enumerable:!0,get:function(){return e[r]}})}:function(t,e,r,s){s===void 0&&(s=r),t[s]=e[r]}),a0t=of&&of.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e}),l0t=of&&of.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.hasOwnProperty.call(t,r)&&o0t(e,t,r);return a0t(e,t),e},af=of&&of.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(of,"__esModule",{value:!0});var c0t=af(hn()),X1e=WCe(),u0t=af(awe()),f0t=af(x9()),A0t=af(pwe()),p0t=af(gwe()),RW=af(a1e()),h0t=af(B1e()),g0t=af(R9()),d0t=af(b1e()),m0t=l0t(uW()),y0t=af(yW()),E0t=af(z1e()),Ew=process.env.CI==="false"?!1:A0t.default,Z1e=()=>{},FW=class{constructor(e){this.resolveExitPromise=()=>{},this.rejectExitPromise=()=>{},this.unsubscribeExit=()=>{},this.onRender=()=>{if(this.isUnmounted)return;let{output:r,outputHeight:s,staticOutput:a}=h0t.default(this.rootNode,this.options.stdout.columns||80),n=a&&a!==`
`;if(this.options.debug){n&&(this.fullStaticOutput+=a),this.options.stdout.write(this.fullStaticOutput+r);return}if(Ew){n&&this.options.stdout.write(a),this.lastOutput=r;return}if(n&&(this.fullStaticOutput+=a),s>=this.options.stdout.rows){this.options.stdout.write(f0t.default.clearTerminal+this.fullStaticOutput+r),this.lastOutput=r;return}n&&(this.log.clear(),this.options.stdout.write(a),this.log(r)),!n&&r!==this.lastOutput&&this.throttledLog(r),this.lastOutput=r},p0t.default(this),this.options=e,this.rootNode=m0t.createNode("ink-root"),this.rootNode.onRender=e.debug?this.onRender:X1e(this.onRender,32,{leading:!0,trailing:!0}),this.rootNode.onImmediateRender=this.onRender,this.log=u0t.default.create(e.stdout),this.throttledLog=e.debug?this.log:X1e(this.log,void 0,{leading:!0,trailing:!0}),this.isUnmounted=!1,this.lastOutput="",this.fullStaticOutput="",this.container=RW.default.createContainer(this.rootNode,0,!1,null),this.unsubscribeExit=g0t.default(this.unmount,{alwaysLast:!1}),e.patchConsole&&this.patchConsole(),Ew||(e.stdout.on("resize",this.onRender),this.unsubscribeResize=()=>{e.stdout.off("resize",this.onRender)})}render(e){let r=c0t.default.createElement(E0t.default,{stdin:this.options.stdin,stdout:this.options.stdout,stderr:this.options.stderr,writeToStdout:this.writeToStdout,writeToStderr:this.writeToStderr,exitOnCtrlC:this.options.exitOnCtrlC,onExit:this.unmount},e);RW.default.updateContainer(r,this.container,null,Z1e)}writeToStdout(e){if(!this.isUnmounted){if(this.options.debug){this.options.stdout.write(e+this.fullStaticOutput+this.lastOutput);return}if(Ew){this.options.stdout.write(e);return}this.log.clear(),this.options.stdout.write(e),this.log(this.lastOutput)}}writeToStderr(e){if(!this.isUnmounted){if(this.options.debug){this.options.stderr.write(e),this.options.stdout.write(this.fullStaticOutput+this.lastOutput);return}if(Ew){this.options.stderr.write(e);return}this.log.clear(),this.options.stderr.write(e),this.log(this.lastOutput)}}unmount(e){this.isUnmounted||(this.onRender(),this.unsubscribeExit(),typeof this.restoreConsole=="function"&&this.restoreConsole(),typeof this.unsubscribeResize=="function"&&this.unsubscribeResize(),Ew?this.options.stdout.write(this.lastOutput+`
`):this.options.debug||this.log.done(),this.isUnmounted=!0,RW.default.updateContainer(null,this.container,null,Z1e),y0t.default.delete(this.options.stdout),e instanceof Error?this.rejectExitPromise(e):this.resolveExitPromise())}waitUntilExit(){return this.exitPromise||(this.exitPromise=new Promise((e,r)=>{this.resolveExitPromise=e,this.rejectExitPromise=r})),this.exitPromise}clear(){!Ew&&!this.options.debug&&this.log.clear()}patchConsole(){this.options.debug||(this.restoreConsole=d0t.default((e,r)=>{e==="stdout"&&this.writeToStdout(r),e==="stderr"&&(r.startsWith("The above error occurred")||this.writeToStderr(r))}))}};of.default=FW});var t2e=_(sD=>{"use strict";var e2e=sD&&sD.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(sD,"__esModule",{value:!0});var I0t=e2e($1e()),GF=e2e(yW()),C0t=Ie("stream"),w0t=(t,e)=>{let r=Object.assign({stdout:process.stdout,stdin:process.stdin,stderr:process.stderr,debug:!1,exitOnCtrlC:!0,patchConsole:!0},B0t(e)),s=v0t(r.stdout,()=>new I0t.default(r));return s.render(t),{rerender:s.render,unmount:()=>s.unmount(),waitUntilExit:s.waitUntilExit,cleanup:()=>GF.default.delete(r.stdout),clear:s.clear}};sD.default=w0t;var B0t=(t={})=>t instanceof C0t.Stream?{stdout:t,stdin:process.stdin}:t,v0t=(t,e)=>{let r;return GF.default.has(t)?r=GF.default.get(t):(r=e(),GF.default.set(t,r)),r}});var n2e=_(eh=>{"use strict";var S0t=eh&&eh.__createBinding||(Object.create?function(t,e,r,s){s===void 0&&(s=r),Object.defineProperty(t,s,{enumerable:!0,get:function(){return e[r]}})}:function(t,e,r,s){s===void 0&&(s=r),t[s]=e[r]}),D0t=eh&&eh.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e}),b0t=eh&&eh.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.hasOwnProperty.call(t,r)&&S0t(e,t,r);return D0t(e,t),e};Object.defineProperty(eh,"__esModule",{value:!0});var oD=b0t(hn()),r2e=t=>{let{items:e,children:r,style:s}=t,[a,n]=oD.useState(0),c=oD.useMemo(()=>e.slice(a),[e,a]);oD.useLayoutEffect(()=>{n(e.length)},[e.length]);let f=c.map((h,E)=>r(h,a+E)),p=oD.useMemo(()=>Object.assign({position:"absolute",flexDirection:"column"},s),[s]);return oD.default.createElement("ink-box",{internal_static:!0,style:p},f)};r2e.displayName="Static";eh.default=r2e});var s2e=_(aD=>{"use strict";var P0t=aD&&aD.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(aD,"__esModule",{value:!0});var x0t=P0t(hn()),i2e=({children:t,transform:e})=>t==null?null:x0t.default.createElement("ink-text",{style:{flexGrow:0,flexShrink:1,flexDirection:"row"},internal_transform:e},t);i2e.displayName="Transform";aD.default=i2e});var a2e=_(lD=>{"use strict";var k0t=lD&&lD.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(lD,"__esModule",{value:!0});var Q0t=k0t(hn()),o2e=({count:t=1})=>Q0t.default.createElement("ink-text",null,`
`.repeat(t));o2e.displayName="Newline";lD.default=o2e});var u2e=_(cD=>{"use strict";var l2e=cD&&cD.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(cD,"__esModule",{value:!0});var T0t=l2e(hn()),R0t=l2e(HF()),c2e=()=>T0t.default.createElement(R0t.default,{flexGrow:1});c2e.displayName="Spacer";cD.default=c2e});var qF=_(uD=>{"use strict";var F0t=uD&&uD.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(uD,"__esModule",{value:!0});var N0t=hn(),O0t=F0t(wW()),L0t=()=>N0t.useContext(O0t.default);uD.default=L0t});var A2e=_(fD=>{"use strict";var M0t=fD&&fD.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(fD,"__esModule",{value:!0});var f2e=hn(),U0t=M0t(qF()),_0t=(t,e={})=>{let{stdin:r,setRawMode:s,internal_exitOnCtrlC:a}=U0t.default();f2e.useEffect(()=>{if(e.isActive!==!1)return s(!0),()=>{s(!1)}},[e.isActive,s]),f2e.useEffect(()=>{if(e.isActive===!1)return;let n=c=>{let f=String(c),p={upArrow:f==="\x1B[A",downArrow:f==="\x1B[B",leftArrow:f==="\x1B[D",rightArrow:f==="\x1B[C",pageDown:f==="\x1B[6~",pageUp:f==="\x1B[5~",return:f==="\r",escape:f==="\x1B",ctrl:!1,shift:!1,tab:f===" "||f==="\x1B[Z",backspace:f==="\b",delete:f==="\x7F"||f==="\x1B[3~",meta:!1};f<=""&&!p.return&&(f=String.fromCharCode(f.charCodeAt(0)+97-1),p.ctrl=!0),f.startsWith("\x1B")&&(f=f.slice(1),p.meta=!0);let h=f>="A"&&f<="Z",E=f>="\u0410"&&f<="\u042F";f.length===1&&(h||E)&&(p.shift=!0),p.tab&&f==="[Z"&&(p.shift=!0),(p.tab||p.backspace||p.delete)&&(f=""),(!(f==="c"&&p.ctrl)||!a)&&t(f,p)};return r?.on("data",n),()=>{r?.off("data",n)}},[e.isActive,r,a,t])};fD.default=_0t});var p2e=_(AD=>{"use strict";var H0t=AD&&AD.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(AD,"__esModule",{value:!0});var j0t=hn(),G0t=H0t(IW()),q0t=()=>j0t.useContext(G0t.default);AD.default=q0t});var h2e=_(pD=>{"use strict";var W0t=pD&&pD.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(pD,"__esModule",{value:!0});var Y0t=hn(),V0t=W0t(vW()),J0t=()=>Y0t.useContext(V0t.default);pD.default=J0t});var g2e=_(hD=>{"use strict";var K0t=hD&&hD.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(hD,"__esModule",{value:!0});var z0t=hn(),X0t=K0t(DW()),Z0t=()=>z0t.useContext(X0t.default);hD.default=Z0t});var m2e=_(dD=>{"use strict";var d2e=dD&&dD.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(dD,"__esModule",{value:!0});var gD=hn(),$0t=d2e(_F()),egt=d2e(qF()),tgt=({isActive:t=!0,autoFocus:e=!1,id:r}={})=>{let{isRawModeSupported:s,setRawMode:a}=egt.default(),{activeId:n,add:c,remove:f,activate:p,deactivate:h,focus:E}=gD.useContext($0t.default),C=gD.useMemo(()=>r??Math.random().toString().slice(2,7),[r]);return gD.useEffect(()=>(c(C,{autoFocus:e}),()=>{f(C)}),[C,e]),gD.useEffect(()=>{t?p(C):h(C)},[t,C]),gD.useEffect(()=>{if(!(!s||!t))return a(!0),()=>{a(!1)}},[t]),{isFocused:!!C&&n===C,focus:E}};dD.default=tgt});var y2e=_(mD=>{"use strict";var rgt=mD&&mD.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(mD,"__esModule",{value:!0});var ngt=hn(),igt=rgt(_F()),sgt=()=>{let t=ngt.useContext(igt.default);return{enableFocus:t.enableFocus,disableFocus:t.disableFocus,focusNext:t.focusNext,focusPrevious:t.focusPrevious,focus:t.focus}};mD.default=sgt});var E2e=_(NW=>{"use strict";Object.defineProperty(NW,"__esModule",{value:!0});NW.default=t=>{var e,r,s,a;return{width:(r=(e=t.yogaNode)===null||e===void 0?void 0:e.getComputedWidth())!==null&&r!==void 0?r:0,height:(a=(s=t.yogaNode)===null||s===void 0?void 0:s.getComputedHeight())!==null&&a!==void 0?a:0}}});var Wc=_(mo=>{"use strict";Object.defineProperty(mo,"__esModule",{value:!0});var ogt=t2e();Object.defineProperty(mo,"render",{enumerable:!0,get:function(){return ogt.default}});var agt=HF();Object.defineProperty(mo,"Box",{enumerable:!0,get:function(){return agt.default}});var lgt=TW();Object.defineProperty(mo,"Text",{enumerable:!0,get:function(){return lgt.default}});var cgt=n2e();Object.defineProperty(mo,"Static",{enumerable:!0,get:function(){return cgt.default}});var ugt=s2e();Object.defineProperty(mo,"Transform",{enumerable:!0,get:function(){return ugt.default}});var fgt=a2e();Object.defineProperty(mo,"Newline",{enumerable:!0,get:function(){return fgt.default}});var Agt=u2e();Object.defineProperty(mo,"Spacer",{enumerable:!0,get:function(){return Agt.default}});var pgt=A2e();Object.defineProperty(mo,"useInput",{enumerable:!0,get:function(){return pgt.default}});var hgt=p2e();Object.defineProperty(mo,"useApp",{enumerable:!0,get:function(){return hgt.default}});var ggt=qF();Object.defineProperty(mo,"useStdin",{enumerable:!0,get:function(){return ggt.default}});var dgt=h2e();Object.defineProperty(mo,"useStdout",{enumerable:!0,get:function(){return dgt.default}});var mgt=g2e();Object.defineProperty(mo,"useStderr",{enumerable:!0,get:function(){ Line truncated
`:"";return c?C+=`@IF EXIST ${c} (\r
${c} ${p} ${a} ${E}%*\r
) ELSE (\r
@SETLOCAL\r
@SET PATHEXT=%PATHEXT:;.JS;=;%\r
${f} ${p} ${a} ${E}%*\r
)\r
`:C+=`@${f} ${p} ${a} ${E}%*\r
`,C}function Ndt(t,e,r){let s=Vc.relative(Vc.dirname(e),t),a=r.prog&&r.prog.split("\\").join("/"),n;s=s.split("\\").join("/");let c=Vc.isAbsolute(s)?`"${s}"`:`"$basedir/${s}"`,f=r.args||"",p=DY(r.nodePath).posix;a?(n=`"$basedir/${r.prog}"`,s=c):(a=c,f="",s="");let h=r.progArgs?`${r.progArgs.join(" ")} `:"",E=`#!/bin/sh
basedir=$(dirname "$(echo "$0" | sed -e 's,\\\\,/,g')")
case \`uname\` in
*CYGWIN*) basedir=\`cygpath -w "$basedir"\`;;
esac
`,C=r.nodePath?`export NODE_PATH="${p}"
`:"";return n?E+=`${C}if [ -x ${n} ]; then
exec ${n} ${f} ${s} ${h}"$@"
else
exec ${a} ${f} ${s} ${h}"$@"
fi
`:E+=`${C}${a} ${f} ${s} ${h}"$@"
exit $?
`,E}function Odt(t,e,r){let s=Vc.relative(Vc.dirname(e),t),a=r.prog&&r.prog.split("\\").join("/"),n=a&&`"${a}$exe"`,c;s=s.split("\\").join("/");let f=Vc.isAbsolute(s)?`"${s}"`:`"$basedir/${s}"`,p=r.args||"",h=DY(r.nodePath),E=h.win32,C=h.posix;n?(c=`"$basedir/${r.prog}$exe"`,s=f):(n=f,p="",s="");let S=r.progArgs?`${r.progArgs.join(" ")} `:"",P=`#!/usr/bin/env pwsh
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
$exe=""
${r.nodePath?`$env_node_path=$env:NODE_PATH
$env:NODE_PATH="${E}"
`:""}if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
# Fix case when both the Windows and Linux builds of Node
# are installed in the same directory
$exe=".exe"
}`;return r.nodePath&&(P+=` else {
$env:NODE_PATH="${C}"
}`),c?P+=`
$ret=0
if (Test-Path ${c}) {
# Support pipeline input
if ($MyInvocation.ExpectingInput) {
$input | & ${c} ${p} ${s} ${S}$args
} else {
& ${c} ${p} ${s} ${S}$args
}
$ret=$LASTEXITCODE
} else {
# Support pipeline input
if ($MyInvocation.ExpectingInput) {
$input | & ${n} ${p} ${s} ${S}$args
} else {
& ${n} ${p} ${s} ${S}$args
}
$ret=$LASTEXITCODE
}
${r.nodePath?`$env:NODE_PATH=$env_node_path
`:""}exit $ret
`:P+=`
# Support pipeline input
if ($MyInvocation.ExpectingInput) {
$input | & ${n} ${p} ${s} ${S}$args
} else {
& ${n} ${p} ${s} ${S}$args
}
${r.nodePath?`$env:NODE_PATH=$env_node_path
`:""}exit $LASTEXITCODE
`,P}function Ldt(t,e){return e.fs_.chmod(t,493)}function DY(t){if(!t)return{win32:"",posix:""};let e=typeof t=="string"?t.split(Vc.delimiter):Array.from(t),r={};for(let s=0;s<e.length;s++){let a=e[s].split("/").join("\\"),n=RBe()?e[s].split("\\").join("/").replace(/^([^:\\/]*):/,(c,f)=>`/mnt/${f.toLowerCase()}`):e[s];r.win32=r.win32?`${r.win32};${a}`:a,r.posix=r.posix?`${r.posix}:${n}`:n,r[s]={win32:a,posix:n}}return r}NBe.exports=SY});var _Y=_((_tr,tve)=>{tve.exports=Ie("stream")});var sve=_((Htr,ive)=>{"use strict";function rve(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);e&&(s=s.filter(function(a){return Object.getOwnPropertyDescriptor(t,a).enumerable})),r.push.apply(r,s)}return r}function mmt(t){for(var e=1;e<arguments.length;e++){var r=arguments[e]!=null?arguments[e]:{};e%2?rve(Object(r),!0).forEach(function(s){ymt(t,s,r[s])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):rve(Object(r)).forEach(function(s){Object.defineProperty(t,s,Object.getOwnPropertyDescriptor(r,s))})}return t}function ymt(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function Emt(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function nve(t,e){for(var r=0;r<e.length;r++){var s=e[r];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(t,s.key,s)}}function Imt(t,e,r){return e&&nve(t.prototype,e),r&&nve(t,r),t}var Cmt=Ie("buffer"),pN=Cmt.Buffer,wmt=Ie("util"),HY=wmt.inspect,Bmt=HY&&HY.custom||"inspect";function vmt(t,e,r){pN.prototype.copy.call(t,e,r)}ive.exports=function(){function t(){Emt(this,t),this.head=null,this.tail=null,this.length=0}return Imt(t,[{key:"push",value:function(r){var s={data:r,next:null};this.length>0?this.tail.next=s:this.head=s,this.tail=s,++this.length}},{key:"unshift",value:function(r){var s={data:r,next:this.head};this.length===0&&(this.tail=s),this.head=s,++this.length}},{key:"shift",value:function(){if(this.length!==0){var r=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,r}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(r){if(this.length===0)return"";for(var s=this.head,a=""+s.data;s=s.next;)a+=r+s.data;return a}},{key:"concat",value:function(r){if(this.length===0)return pN.alloc(0);for(var s=pN.allocUnsafe(r>>>0),a=this.head,n=0;a;)vmt(a.data,s,n),n+=a.data.length,a=a.next;return s}},{key:"consume",value:function(r,s){var a;return r<this.head.data.length?(a=this.head.data.slice(0,r),this.head.data=this.head.data.slice(r)):r===this.head.data.length?a=this.shift():a=s?this._getString(r):this._getBuffer(r),a}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(r){var s=this.head,a=1,n=s.data;for(r-=n.length;s=s.next;){var c=s.data,f=r>c.length?c.length:r;if(f===c.length?n+=c:n+=c.slice(0,r),r-=f,r===0){f===c.length?(++a,s.next?this.head=s.next:this.head=this.tail=null):(this.head=s,s.data=c.slice(f));break}++a}return this.length-=a,n}},{key:"_getBuffer",value:function(r){var s=pN.allocUnsafe(r),a=this.head,n=1;for(a.data.copy(s),r-=a.data.length;a=a.next;){var c=a.data,f=r>c.length?c.length:r;if(c.copy(s,s.length-r,0,f),r-=f,r===0){f===c.length?(++n,a.next?this.head=a.next:this.head=this.tail=null):(this.head=a,a.data=c.slice(f));break}++n}return this.length-=n,s}},{key:Bmt,value:function(r,s){return HY(this,mmt({},s,{depth:0,customInspect:!1}))}}]),t}()});var GY=_((jtr,ave)=>{"use strict";function Smt(t,e){var r=this,s=this._readableState&&this._readableState.destroyed,a=this._writableState&&this._writableState.destroyed;return s||a?(e?e(t):t&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,process.nextTick(jY,this,t)):process.nextTick(jY,this,t)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(t||null,function(n){!e&&n?r._writableState?r._writableState.errorEmitted?process.nextTick(hN,r):(r._writableState.errorEmitted=!0,process.nextTick(ove,r,n)):process.nextTick(ove,r,n):e?(process.nextTick(hN,r),e(n)):process.nextTick(hN,r)}),this)}function ove(t,e){jY(t,e),hN(t)}function hN(t){t._writableState&&!t._writableState.emitClose||t._readableState&&!t._readableState.emitClose||t.emit("close")}function Dmt(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function jY(t,e){t.emit("error",e)}function bmt(t,e){var r=t._readableState,s=t._writableState;r&& Line truncated
`)),t.linkname&&(e+=mV(" linkpath="+t.linkname+`
`));var r=t.pax;if(r)for(var s in r)e+=mV(" "+s+"="+r[s]+`
`);return Buffer.from(e)};Uw.decodePax=function(t){for(var e={};t.length;){for(var r=0;r<t.length&&t[r]!==32;)r++;var s=parseInt(t.slice(0,r).toString(),10);if(!s)return e;var a=t.slice(r+1,s-1).toString(),n=a.indexOf("=");if(n===-1)return e;e[a.slice(0,n)]=a.slice(n+1),t=t.slice(s)}return e};Uw.encode=function(t){var e=EEt(512),r=t.name,s="";if(t.typeflag===5&&r[r.length-1]!=="/"&&(r+="/"),Buffer.byteLength(r)!==r.length)return null;for(;Buffer.byteLength(r)>100;){var a=r.indexOf("/");if(a===-1)return null;s+=s?"/"+r.slice(0,a):r.slice(0,a),r=r.slice(a+1)}return Buffer.byteLength(r)>100||Buffer.byteLength(s)>155||t.linkname&&Buffer.byteLength(t.linkname)>100?null:(e.write(r),e.write(hg(t.mode&SEt,6),100),e.write(hg(t.uid,6),108),e.write(hg(t.gid,6),116),e.write(hg(t.size,11),124),e.write(hg(t.mtime.getTime()/1e3|0,11),136),e[156]=aSe+PEt(t.type),t.linkname&&e.write(t.linkname,157),lSe.copy(e,ab),wEt.copy(e,yV),t.uname&&e.write(t.uname,265),t.gname&&e.write(t.gname,297),e.write(hg(t.devmajor||0,6),329),e.write(hg(t.devminor||0,6),337),s&&e.write(s,345),e.write(hg(uSe(e),6),148),e)};Uw.decode=function(t,e,r){var s=t[156]===0?0:t[156]-aSe,a=Mw(t,0,100,e),n=gg(t,100,8),c=gg(t,108,8),f=gg(t,116,8),p=gg(t,124,12),h=gg(t,136,12),E=bEt(s),C=t[157]===0?null:Mw(t,157,100,e),S=Mw(t,265,32),P=Mw(t,297,32),I=gg(t,329,8),R=gg(t,337,8),N=uSe(t);if(N===8*32)return null;if(N!==gg(t,148,8))throw new Error("Invalid tar header. Maybe the tar is corrupted or it needs to be gunzipped?");if(lSe.compare(t,ab,ab+6)===0)t[345]&&(a=Mw(t,345,155,e)+"/"+a);else if(!(BEt.compare(t,ab,ab+6)===0&&vEt.compare(t,yV,yV+2)===0)){if(!r)throw new Error("Invalid tar header: unknown format.")}return s===0&&a&&a[a.length-1]==="/"&&(s=5),{name:a,mode:n,uid:c,gid:f,size:p,mtime:new Date(1e3*h),type:E,linkname:C,uname:S,gname:P,devmajor:I,devminor:R}}});var mSe=_((crr,dSe)=>{var ASe=Ie("util"),kEt=oSe(),lb=EV(),pSe=Lw().Writable,hSe=Lw().PassThrough,gSe=function(){},fSe=function(t){return t&=511,t&&512-t},QEt=function(t,e){var r=new xN(t,e);return r.end(),r},TEt=function(t,e){return e.path&&(t.name=e.path),e.linkpath&&(t.linkname=e.linkpath),e.size&&(t.size=parseInt(e.size,10)),t.pax=e,t},xN=function(t,e){this._parent=t,this.offset=e,hSe.call(this,{autoDestroy:!1})};ASe.inherits(xN,hSe);xN.prototype.destroy=function(t){this._parent.destroy(t)};var ch=function(t){if(!(this instanceof ch))return new ch(t);pSe.call(this,t),t=t||{},this._offset=0,this._buffer=kEt(),this._missing=0,this._partial=!1,this._onparse=gSe,this._header=null,this._stream=null,this._overflow=null,this._cb=null,this._locked=!1,this._destroyed=!1,this._pax=null,this._paxGlobal=null,this._gnuLongPath=null,this._gnuLongLinkPath=null;var e=this,r=e._buffer,s=function(){e._continue()},a=function(S){if(e._locked=!1,S)return e.destroy(S);e._stream||s()},n=function(){e._stream=null;var S=fSe(e._header.size);S?e._parse(S,c):e._parse(512,C),e._locked||s()},c=function(){e._buffer.consume(fSe(e._header.size)),e._parse(512,C),s()},f=function(){var S=e._header.size;e._paxGlobal=lb.decodePax(r.slice(0,S)),r.consume(S),n()},p=function(){var S=e._header.size;e._pax=lb.decodePax(r.slice(0,S)),e._paxGlobal&&(e._pax=Object.assign({},e._paxGlobal,e._pax)),r.consume(S),n()},h=function(){var S=e._header.size;this._gnuLongPath=lb.decodeLongPath(r.slice(0,S),t.filenameEncoding),r.consume(S),n()},E=function(){var S=e._header.size;this._gnuLongLinkPath=lb.decodeLongPath(r.slice(0,S),t.filenameEncoding),r.consume(S),n()},C=function(){var S=e._offset,P;try{P=e._header=lb.decode(r.slice(0,512),t.filenameEncoding,t.allowUnknownFormat)}catch(I){e.emit("error",I)}if(r.consume(512),!P){e._parse(512,C),s();return}if(P.type==="gnu-long-path"){e._parse(P.size,h),s();return}if(P.type==="gnu-long-link-path"){e._parse(P.size,E),s();return}if(P.type==="pax-global-header"){e._parse(P.size,f),s();return}if(P.type==="pax-header"){e._parse(P.size,p),s();return}if(e._gnuLongPath&&(P.name=e._gnuLongPath,e._gnuLongPath=null),e._gnuLongLinkPath&&(P.linkname=e._gnuLongLinkPath,e._gnuLongLinkPath=null),e._pax&&(e._header=P=TEt(P,e._pax),e._pax=null),e._locked=!0,!P.size||P.type==="directory"){e._parse(512,C),e.emit("entry",P,QEt(e,S),a);return}e._stream=new xN(e,S),e.emit("entry",P,e._stream,a),e._parse(P.size,n),s()};this._onheader=C,this._parse(512,C)};ASe.inherits(ch,pSe);ch.prototype.destroy=function(t){this._destroyed||(this._destroyed=!0,t&&this.emit("error",t),this.emit("close"),this._stream&&this._stream.emit("close"))};ch.prototype._parse=function(t,e){this._destroyed||(this._offset+=t,this._missing=t,e===this._onheader&&(this._partial=!1),this._onparse=e)};ch.prototype._continue=function(){if(!this._destroyed){var t=this._cb;this._cb=gSe,this._overflow?this._write(this._overflow,void 0,t):t()}};ch.prototype._write=function(t,e,r){if(!this._destroyed){var s=this._stream,a=this._buffer,n=this._missing;if(t.length&&(this._partial=!0),t.length<n)return this._missing-=t.length,this._overflow=null,s?s.write(t,r):(a.append(t), Line truncated
Wanted: ${this.expectedSize}
Found: ${this.size}`);s.code="EBADSIZE",s.found=this.size,s.expected=this.expectedSize,s.sri=this.sri,this.emit("error",s)}else if(this.sri&&!r){let s=new Error(`${this.sri} integrity checksum failed when using ${this.algorithm}: wanted ${this.digests} but got ${e}. (${this.size} bytes)`);s.code="EINTEGRITY",s.found=e,s.expected=this.digests,s.algorithm=this.algorithm,s.sri=this.sri,this.emit("error",s)}else this.#r=this.size,this.emit("size",this.size),this.#t=e,this.emit("integrity",e),r&&(this.#i=r,this.emit("verified",r))}},Ah=class{get isHash(){return!0}constructor(e,r){let s=r?.strict;this.source=e.trim(),this.digest="",this.algorithm="",this.options=[];let a=this.source.match(s?uIt:cIt);if(!a||s&&!OV.includes(a[1]))return;this.algorithm=a[1],this.digest=a[2];let n=a[3];n&&(this.options=n.slice(1).split("?"))}hexDigest(){return this.digest&&Buffer.from(this.digest,"base64").toString("hex")}toJSON(){return this.toString()}match(e,r){let s=nc(e,r);if(!s)return!1;if(s.isIntegrity){let a=s.pickAlgorithm(r,[this.algorithm]);if(!a)return!1;let n=s[a].find(c=>c.digest===this.digest);return n||!1}return s.digest===this.digest?s:!1}toString(e){return e?.strict&&!(OV.includes(this.algorithm)&&this.digest.match(lIt)&&this.options.every(r=>r.match(fIt)))?"":`${this.algorithm}-${this.digest}${mb(this.options)}`}};function USe(t,e,r,s){let a=t!=="",n=!1,c="",f=s.length-1;for(let h=0;h<f;h++){let E=Ah.prototype.toString.call(s[h],r);E&&(n=!0,c+=E,c+=e)}let p=Ah.prototype.toString.call(s[f],r);return p&&(n=!0,c+=p),a&&n?t+e+c:t+c}var Xm=class{get isIntegrity(){return!0}toJSON(){return this.toString()}isEmpty(){return Object.keys(this).length===0}toString(e){let r=e?.sep||" ",s="";if(e?.strict){r=r.replace(/\S+/g," ");for(let a of OV)this[a]&&(s=USe(s,r,e,this[a]))}else for(let a of Object.keys(this))s=USe(s,r,e,this[a]);return s}concat(e,r){let s=typeof e=="string"?e:gb(e,r);return nc(`${this.toString(r)} ${s}`,r)}hexDigest(){return nc(this,{single:!0}).hexDigest()}merge(e,r){let s=nc(e,r);for(let a in s)if(this[a]){if(!this[a].find(n=>s[a].find(c=>n.digest===c.digest)))throw new Error("hashes do not match, cannot update integrity")}else this[a]=s[a]}match(e,r){let s=nc(e,r);if(!s)return!1;let a=s.pickAlgorithm(r,Object.keys(this));return!!a&&this[a]&&s[a]&&this[a].find(n=>s[a].find(c=>n.digest===c.digest))||!1}pickAlgorithm(e,r){let s=e?.pickAlgorithm||EIt,a=Object.keys(this).filter(n=>r?.length?r.includes(n):!0);return a.length?a.reduce((n,c)=>s(n,c)||n):null}};IA.exports.parse=nc;function nc(t,e){if(!t)return null;if(typeof t=="string")return NV(t,e);if(t.algorithm&&t.digest){let r=new Xm;return r[t.algorithm]=[t],NV(gb(r,e),e)}else return NV(gb(t,e),e)}function NV(t,e){if(e?.single)return new Ah(t,e);let r=t.trim().split(/\s+/).reduce((s,a)=>{let n=new Ah(a,e);if(n.algorithm&&n.digest){let c=n.algorithm;s[c]||(s[c]=[]),s[c].push(n)}return s},new Xm);return r.isEmpty()?null:r}IA.exports.stringify=gb;function gb(t,e){return t.algorithm&&t.digest?Ah.prototype.toString.call(t,e):typeof t=="string"?gb(nc(t,e),e):Xm.prototype.toString.call(t,e)}IA.exports.fromHex=AIt;function AIt(t,e,r){let s=mb(r?.options);return nc(`${e}-${Buffer.from(t,"hex").toString("base64")}${s}`,r)}IA.exports.fromData=pIt;function pIt(t,e){let r=e?.algorithms||[...MV],s=mb(e?.options);return r.reduce((a,n)=>{let c=db.createHash(n).update(t).digest("base64"),f=new Ah(`${n}-${c}${s}`,e);if(f.algorithm&&f.digest){let p=f.algorithm;a[p]||(a[p]=[]),a[p].push(f)}return a},new Xm)}IA.exports.fromStream=hIt;function hIt(t,e){let r=UV(e);return new Promise((s,a)=>{t.pipe(r),t.on("error",a),r.on("error",a);let n;r.on("integrity",c=>{n=c}),r.on("end",()=>s(n)),r.resume()})}IA.exports.checkData=gIt;function gIt(t,e,r){if(e=nc(e,r),!e||!Object.keys(e).length){if(r?.error)throw Object.assign(new Error("No valid integrity hashes to check against"),{code:"EINTEGRITY"});return!1}let s=e.pickAlgorithm(r),a=db.createHash(s).update(t).digest("base64"),n=nc({algorithm:s,digest:a}),c=n.match(e,r);if(r=r||{},c||!r.error)return c;if(typeof r.size=="number"&&t.length!==r.size){let f=new Error(`data size mismatch when checking ${e}.
Wanted: ${r.size}
Found: ${t.length}`);throw f.code="EBADSIZE",f.found=t.length,f.expected=r.size,f.sri=e,f}else{let f=new Error(`Integrity checksum failed when using ${s}: Wanted ${e}, but got ${n}. (${t.length} bytes)`);throw f.code="EINTEGRITY",f.found=n,f.expected=e,f.algorithm=s,f.sri=e,f}}IA.exports.checkStream=dIt;function dIt(t,e,r){if(r=r||Object.create(null),r.integrity=e,e=nc(e,r),!e||!Object.keys(e).length)return Promise.reject(Object.assign(new Error("No valid integrity hashes to check against"),{code:"EINTEGRITY"}));let s=UV(r);return new Promise((a,n)=>{t.pipe(s),t.on("error",n),s.on("error",n);let c;s.on("verified",f=>{c=f}),s.on("end",()=>a(c)),s.resume()})}IA.exports.integrityStream=UV;function UV(t=Object.create(null)){return new LV(t)}IA.exports.create=mIt;function mIt(t){let e=t?.algorithms||[...MV],r=mb(t?.options),s=e.map(db.createHash);return{update:function(a,n){return s.forEach(c=>c.update(a,n)),this},digest:function(){return e.reduce((n,c)=>{let f=s.shift().digest("base64"),p=new Ah(`${c}-${f}${r}`,t);if(p.algorithm&&p.digest){let h=p.algorithm;n[h]||(n[h]=[]),n[h].push(p)}return n},new Xm)}}}var yIt=db.getHashes(),_Se=["md5","whirlpool","sha1","sha224","sha256","sha384","sha512","sha3","sha3-256","sha3-384","sha3-512","sha3_256","sha3_384","sha3_512"].filter(t=>yIt.includes(t));function EIt(t,e){return _Se.indexOf(t.toLowerCase())>=_Se.indexOf(e.toLowerCase())?t:e}});var _V=_(mg=>{"use strict";Object.defineProperty(mg,"__esModule",{value:!0});mg.Signature=mg.Envelope=void 0;mg.Envelope={fromJSON(t){return{payload:GN(t.payload)?Buffer.from(jSe(t.payload)):Buffer.alloc(0),payloadType:GN(t.payloadType)?globalThis.String(t.payloadType):"",signatures:globalThis.Array.isArray(t?.signatures)?t.signatures.map(e=>mg.Signature.fromJSON(e)):[]}},toJSON(t){let e={};return t.payload.length!==0&&(e.payload=GSe(t.payload)),t.payloadType!==""&&(e.payloadType=t.payloadType),t.signatures?.length&&(e.signatures=t.signatures.map(r=>mg.Signature.toJSON(r))),e}};mg.Signature={fromJSON(t){return{sig:GN(t.sig)?Buffer.from(jSe(t.sig)):Buffer.alloc(0),keyid:GN(t.keyid)?globalThis.String(t.keyid):""}},toJSON(t){let e={};return t.sig.length!==0&&(e.sig=GSe(t.sig)),t.keyid!==""&&(e.keyid=t.keyid),e}};function jSe(t){return Uint8Array.from(globalThis.Buffer.from(t,"base64"))}function GSe(t){return globalThis.Buffer.from(t).toString("base64")}function GN(t){return t!=null}});var WSe=_(qN=>{"use strict";Object.defineProperty(qN,"__esModule",{value:!0});qN.Timestamp=void 0;qN.Timestamp={fromJSON(t){return{seconds:qSe(t.seconds)?globalThis.String(t.seconds):"0",nanos:qSe(t.nanos)?globalThis.Number(t.nanos):0}},toJSON(t){let e={};return t.seconds!=="0"&&(e.seconds=t.seconds),t.nanos!==0&&(e.nanos=Math.round(t.nanos)),e}};function qSe(t){return t!=null}});var Ww=_(Ur=>{"use strict";Object.defineProperty(Ur,"__esModule",{value:!0});Ur.TimeRange=Ur.X509CertificateChain=Ur.SubjectAlternativeName=Ur.X509Certificate=Ur.DistinguishedName=Ur.ObjectIdentifierValuePair=Ur.ObjectIdentifier=Ur.PublicKeyIdentifier=Ur.PublicKey=Ur.RFC3161SignedTimestamp=Ur.LogId=Ur.MessageSignature=Ur.HashOutput=Ur.SubjectAlternativeNameType=Ur.PublicKeyDetails=Ur.HashAlgorithm=void 0;Ur.hashAlgorithmFromJSON=VSe;Ur.hashAlgorithmToJSON=JSe;Ur.publicKeyDetailsFromJSON=KSe;Ur.publicKeyDetailsToJSON=zSe;Ur.subjectAlternativeNameTypeFromJSON=XSe;Ur.subjectAlternativeNameTypeToJSON=ZSe;var IIt=WSe(),yl;(function(t){t[t.HASH_ALGORITHM_UNSPECIFIED=0]="HASH_ALGORITHM_UNSPECIFIED",t[t.SHA2_256=1]="SHA2_256",t[t.SHA2_384=2]="SHA2_384",t[t.SHA2_512=3]="SHA2_512",t[t.SHA3_256=4]="SHA3_256",t[t.SHA3_384=5]="SHA3_384"})(yl||(Ur.HashAlgorithm=yl={}));function VSe(t){switch(t){case 0:case"HASH_ALGORITHM_UNSPECIFIED":return yl.HASH_ALGORITHM_UNSPECIFIED;case 1:case"SHA2_256":return yl.SHA2_256;case 2:case"SHA2_384":return yl.SHA2_384;case 3:case"SHA2_512":return yl.SHA2_512;case 4:case"SHA3_256":return yl.SHA3_256;case 5:case"SHA3_384":return yl.SHA3_384;default:throw new globalThis.Error("Unrecognized enum value "+t+" for enum HashAlgorithm")}}function JSe(t){switch(t){case yl.HASH_ALGORITHM_UNSPECIFIED:return"HASH_ALGORITHM_UNSPECIFIED";case yl.SHA2_256:return"SHA2_256";case yl.SHA2_384:return"SHA2_384";case yl.SHA2_512:return"SHA2_512";case yl.SHA3_256:return"SHA3_256";case yl.SHA3_384:return"SHA3_384";default:throw new globalThis.Error("Unrecognized enum value "+t+" for enum HashAlgorithm")}}var sn;(function(t){t[t.PUBLIC_KEY_DETAILS_UNSPECIFIED=0]="PUBLIC_KEY_DETAILS_UNSPECIFIED",t[t.PKCS1_RSA_PKCS1V5=1]="PKCS1_RSA_PKCS1V5",t[t.PKCS1_RSA_PSS=2]="PKCS1_RSA_PSS",t[t.PKIX_RSA_PKCS1V5=3]="PKIX_RSA_PKCS1V5",t[t.PKIX_RSA_PSS=4]="PKIX_RSA_PSS",t[t.PKIX_RSA_PKCS1V15_2048_SHA256=9]="PKIX_RSA_PKCS1V15_2048_SHA256",t[t.PKIX_RSA_PKCS1V15_3072_SHA256=10]="PKIX_RSA_PKCS1V15_3072_SHA256",t[t.PKIX_RSA_PKCS1V15_4096_SHA256=11]="PKIX_RSA_PKCS1V15_4096_SHA256",t[t.PKIX_RSA_PSS_2048_SHA256=16]="PKIX_RSA_PSS_2048_SHA256",t[t.PKIX_RSA_PSS_3072_SHA256=17]="PKIX_RSA_PSS_3072_SHA256",t[t.PKIX_RS Line truncated
`).forEach(r=>{r.match(ACt)||r.match(pCt)||(e+=r)}),Buffer.from(e,"base64")}function gCt(t,e="CERTIFICATE"){let s=t.toString("base64").match(/.{1,64}/g)||"";return[`-----BEGIN ${e}-----`,...s,`-----END ${e}-----`].join(`
`).concat(`
`)}});var AO=_(zw=>{"use strict";Object.defineProperty(zw,"__esModule",{value:!0});zw.SHA2_HASH_ALGOS=zw.ECDSA_SIGNATURE_ALGOS=void 0;zw.ECDSA_SIGNATURE_ALGOS={"1.2.840.10045.4.3.1":"sha224","1.2.840.10045.4.3.2":"sha256","1.2.840.10045.4.3.3":"sha384","1.2.840.10045.4.3.4":"sha512"};zw.SHA2_HASH_ALGOS={"2.16.840.1.101.3.4.2.1":"sha256","2.16.840.1.101.3.4.2.2":"sha384","2.16.840.1.101.3.4.2.3":"sha512"}});var s7=_(pO=>{"use strict";Object.defineProperty(pO,"__esModule",{value:!0});pO.RFC3161TimestampVerificationError=void 0;var i7=class extends Error{};pO.RFC3161TimestampVerificationError=i7});var PDe=_(vA=>{"use strict";var dCt=vA&&vA.__createBinding||(Object.create?function(t,e,r,s){s===void 0&&(s=r);var a=Object.getOwnPropertyDescriptor(e,r);(!a||("get"in a?!e.__esModule:a.writable||a.configurable))&&(a={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,s,a)}:function(t,e,r,s){s===void 0&&(s=r),t[s]=e[r]}),mCt=vA&&vA.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e}),yCt=vA&&vA.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&dCt(e,t,r);return mCt(e,t),e};Object.defineProperty(vA,"__esModule",{value:!0});vA.TSTInfo=void 0;var bDe=yCt(Kw()),ECt=AO(),ICt=s7(),o7=class{constructor(e){this.root=e}get version(){return this.root.subs[0].toInteger()}get genTime(){return this.root.subs[4].toDate()}get messageImprintHashAlgorithm(){let e=this.messageImprintObj.subs[0].subs[0].toOID();return ECt.SHA2_HASH_ALGOS[e]}get messageImprintHashedMessage(){return this.messageImprintObj.subs[1].value}get raw(){return this.root.toDER()}verify(e){let r=bDe.digest(this.messageImprintHashAlgorithm,e);if(!bDe.bufferEqual(r,this.messageImprintHashedMessage))throw new ICt.RFC3161TimestampVerificationError("message imprint does not match artifact")}get messageImprintObj(){return this.root.subs[2]}};vA.TSTInfo=o7});var kDe=_(SA=>{"use strict";var CCt=SA&&SA.__createBinding||(Object.create?function(t,e,r,s){s===void 0&&(s=r);var a=Object.getOwnPropertyDescriptor(e,r);(!a||("get"in a?!e.__esModule:a.writable||a.configurable))&&(a={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,s,a)}:function(t,e,r,s){s===void 0&&(s=r),t[s]=e[r]}),wCt=SA&&SA.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e}),BCt=SA&&SA.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&CCt(e,t,r);return wCt(e,t),e};Object.defineProperty(SA,"__esModule",{value:!0});SA.RFC3161Timestamp=void 0;var vCt=cO(),a7=BCt(Kw()),xDe=AO(),Bb=s7(),SCt=PDe(),DCt="1.2.840.113549.1.7.2",bCt="1.2.840.113549.1.9.16.1.4",PCt="1.2.840.113549.1.9.4",l7=class t{constructor(e){this.root=e}static parse(e){let r=vCt.ASN1Obj.parseBuffer(e);return new t(r)}get status(){return this.pkiStatusInfoObj.subs[0].toInteger()}get contentType(){return this.contentTypeObj.toOID()}get eContentType(){return this.eContentTypeObj.toOID()}get signingTime(){return this.tstInfo.genTime}get signerIssuer(){return this.signerSidObj.subs[0].value}get signerSerialNumber(){return this.signerSidObj.subs[1].value}get signerDigestAlgorithm(){let e=this.signerDigestAlgorithmObj.subs[0].toOID();return xDe.SHA2_HASH_ALGOS[e]}get signatureAlgorithm(){let e=this.signatureAlgorithmObj.subs[0].toOID();return xDe.ECDSA_SIGNATURE_ALGOS[e]}get signatureValue(){return this.signatureValueObj.value}get tstInfo(){return new SCt.TSTInfo(this.eContentObj.subs[0].subs[0])}verify(e,r){if(!this.timeStampTokenObj)throw new Bb.RFC3161TimestampVerificationError("timeStampToken is missing");if(this.contentType!==DCt)throw new Bb.RFC3161TimestampVerificationError(`incorrect content type: ${this.contentType}`);if(this.eContentType!==bCt)throw new Bb.RFC3161TimestampVerificationError(`incorrect encapsulated content type: ${this.eContentType}`);this.tstInfo.verify(e),this.verifyMessageDigest(),this.verifySignature(r)}verifyMessageDigest(){let e=a7.digest(this.signerDigestAlgorithm,this.tstInfo.raw),r=this.messageDigestAttributeObj.subs[1].subs[0].value;if(!a7.bufferEqual(e,r))throw new Bb.RFC3161TimestampVerificationError("signed data does not match tstInfo")}verifySignature(e){let r=this.signedAttrsObj.toDER();if(r[0]=49,!a7.verify(r,e,this.signatureValue,this.signatureAlgorithm))throw new Bb.RFC3161TimestampVerificationError("signature verification failed")}get pkiStatusInfoObj(){return this.root.subs[0]}get timeStampTokenObj(){return this.root.subs[1]}get contentTypeObj(){return this.timeStampTokenObj.subs[0]}get signedDataObj(){return this.timeStampTokenObj.subs.find(r=>r.tag.isContextSpecific(0)).subs[0]}get encapContentInfoObj(){return this.signedDataObj.subs[2]}get signerInfosObj(){let e=this.signedDataObj;return e.subs[e.subs.length-1]}get sig Line truncated
globstar while`,e,S,r,P,I),this.matchOne(e.slice(S),r.slice(P),s))return this.debug("globstar found match!",S,p,I),!0;if(I==="."||I===".."||!a.dot&&I.charAt(0)==="."){this.debug("dot detected!",e,S,r,P);break}this.debug("globstar swallow a segment, and continue"),S++}return!!(s&&(this.debug(`
>>> no match, partial?`,e,S,r,P),S===p))}let R;if(typeof E=="string"?(R=C===E,this.debug("string match",E,C,R)):(R=E.test(C),this.debug("pattern match",E,C,R)),!R)return!1}if(c===p&&f===h)return!0;if(c===p)return s;if(f===h)return c===p-1&&e[c]==="";throw new Error("wtf?")}braceExpand(){return(0,pr.braceExpand)(this.pattern,this.options)}parse(e){(0,qO.assertValidPattern)(e);let r=this.options;if(e==="**")return pr.GLOBSTAR;if(e==="")return"";let s,a=null;(s=e.match(V2t))?a=r.dot?K2t:J2t:(s=e.match(L2t))?a=(r.nocase?r.dot?H2t:_2t:r.dot?U2t:M2t)(s[1]):(s=e.match(z2t))?a=(r.nocase?r.dot?Z2t:X2t:r.dot?$2t:eBt)(s):(s=e.match(j2t))?a=r.dot?q2t:G2t:(s=e.match(W2t))&&(a=Y2t);let n=wPe.AST.fromGlob(e,this.options).toMMPattern();return a&&typeof n=="object"&&Reflect.defineProperty(n,"test",{value:a}),n}makeRe(){if(this.regexp||this.regexp===!1)return this.regexp;let e=this.set;if(!e.length)return this.regexp=!1,this.regexp;let r=this.options,s=r.noglobstar?rBt:r.dot?nBt:iBt,a=new Set(r.nocase?["i"]:[]),n=e.map(p=>{let h=p.map(E=>{if(E instanceof RegExp)for(let C of E.flags.split(""))a.add(C);return typeof E=="string"?uBt(E):E===pr.GLOBSTAR?pr.GLOBSTAR:E._src});return h.forEach((E,C)=>{let S=h[C+1],P=h[C-1];E!==pr.GLOBSTAR||P===pr.GLOBSTAR||(P===void 0?S!==void 0&&S!==pr.GLOBSTAR?h[C+1]="(?:\\/|"+s+"\\/)?"+S:h[C]=s:S===void 0?h[C-1]=P+"(?:\\/|"+s+")?":S!==pr.GLOBSTAR&&(h[C-1]=P+"(?:\\/|\\/"+s+"\\/)"+S,h[C+1]=pr.GLOBSTAR))}),h.filter(E=>E!==pr.GLOBSTAR).join("/")}).join("|"),[c,f]=e.length>1?["(?:",")"]:["",""];n="^"+c+n+f+"$",this.negate&&(n="^(?!"+n+").+$");try{this.regexp=new RegExp(n,[...a].join(""))}catch{this.regexp=!1}return this.regexp}slashSplit(e){return this.preserveMultipleSlashes?e.split("/"):this.isWindows&&/^\/\/[^\/]+/.test(e)?["",...e.split(/\/+/)]:e.split(/\/+/)}match(e,r=this.partial){if(this.debug("match",e,this.pattern),this.comment)return!1;if(this.empty)return e==="";if(e==="/"&&r)return!0;let s=this.options;this.isWindows&&(e=e.split("\\").join("/"));let a=this.slashSplit(e);this.debug(this.pattern,"split",a);let n=this.set;this.debug(this.pattern,"set",n);let c=a[a.length-1];if(!c)for(let f=a.length-2;!c&&f>=0;f--)c=a[f];for(let f=0;f<n.length;f++){let p=n[f],h=a;if(s.matchBase&&p.length===1&&(h=[c]),this.matchOne(h,p,r))return s.flipNegate?!0:!this.negate}return s.flipNegate?!1:this.negate}static defaults(e){return pr.minimatch.defaults(e).Minimatch}};pr.Minimatch=ly;var fBt=aJ();Object.defineProperty(pr,"AST",{enumerable:!0,get:function(){return fBt.AST}});var ABt=lJ();Object.defineProperty(pr,"escape",{enumerable:!0,get:function(){return ABt.escape}});var pBt=UO();Object.defineProperty(pr,"unescape",{enumerable:!0,get:function(){return pBt.unescape}});pr.minimatch.AST=wPe.AST;pr.minimatch.Minimatch=ly;pr.minimatch.escape=F2t.escape;pr.minimatch.unescape=N2t.unescape});var fJ=_(ru=>{"use strict";var bPe=ru&&ru.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(ru,"__esModule",{value:!0});ru.SuccinctRoles=ru.DelegatedRole=ru.Role=ru.TOP_LEVEL_ROLE_NAMES=void 0;var PPe=bPe(Ie("crypto")),hBt=DPe(),WO=bPe(Ie("util")),YO=PA(),cy=ff();ru.TOP_LEVEL_ROLE_NAMES=["root","targets","snapshot","timestamp"];var Mb=class t{constructor(e){let{keyIDs:r,threshold:s,unrecognizedFields:a}=e;if(gBt(r))throw new YO.ValueError("duplicate key IDs found");if(s<1)throw new YO.ValueError("threshold must be at least 1");this.keyIDs=r,this.threshold=s,this.unrecognizedFields=a||{}}equals(e){return e instanceof t?this.threshold===e.threshold&&WO.default.isDeepStrictEqual(this.keyIDs,e.keyIDs)&&WO.default.isDeepStrictEqual(this.unrecognizedFields,e.unrecognizedFields):!1}toJSON(){return{keyids:this.keyIDs,threshold:this.threshold,...this.unrecognizedFields}}static fromJSON(e){let{keyids:r,threshold:s,...a}=e;if(!cy.guard.isStringArray(r))throw new TypeError("keyids must be an array");if(typeof s!="number")throw new TypeError("threshold must be a number");return new t({keyIDs:r,threshold:s,unrecognizedFields:a})}};ru.Role=Mb;function gBt(t){return new Set(t).size!==t.length}var cJ=class t extends Mb{constructor(e){super(e);let{name:r,terminating:s,paths:a,pathHashPrefixes:n}=e;if(this.name=r,this.terminating=s,e.paths&&e.pathHashPrefixes)throw new YO.ValueError("paths and pathHashPrefixes are mutually exclusive");this.paths=a,this.pathHashPrefixes=n}equals(e){return e instanceof t?super.equals(e)&&this.name===e.name&&this.terminating===e.terminating&&WO.default.isDeepStrictEqual(this.paths,e.paths)&&WO.default.isDeepStrictEqual(this.pathHashPrefixes,e.pathHashPrefixes):!1}isDelegatedPath(e){if(this.paths)return this.paths.some(r=>mBt(e,r));if(this.pathHashPrefixes){let s=PPe.default.createHash("sha256").update(e).digest("hex");return this.pathHashPrefixes.some(a=>s.startsWith(a))}return!1}toJSON(){let e={...super.toJSON(),name:this.name,terminating:this.terminating};return this.paths&&(e.paths=this.paths),this.pathHashPrefixes&&(e.path_hash_prefixes=this.pathHashPrefixes),e}static fro Line truncated
`).join(`
`+n),t.push(a+"m+"+iL.exports.humanize(this.diff)+"\x1B[0m")}else t[0]=Evt()+e+" "+t[0]}function Evt(){return Zs.inspectOpts.hideDate?"":new Date().toISOString()+" "}function Ivt(...t){return process.stderr.write(nL.formatWithOptions(Zs.inspectOpts,...t)+`
`)}function Cvt(t){t?process.env.DEBUG=t:delete process.env.DEBUG}function wvt(){return process.env.DEBUG}function Bvt(t){t.inspectOpts={};let e=Object.keys(Zs.inspectOpts);for(let r=0;r<e.length;r++)t.inspectOpts[e[r]]=Zs.inspectOpts[e[r]]}iL.exports=QJ()(Zs);var{formatters:GPe}=iL.exports;GPe.o=function(t){return this.inspectOpts.colors=this.useColors,nL.inspect(t,this.inspectOpts).split(`
`).map(e=>e.trim()).join(" ")};GPe.O=function(t){return this.inspectOpts.colors=this.useColors,nL.inspect(t,this.inspectOpts)}});var RJ=_((Pir,TJ)=>{typeof process>"u"||process.type==="renderer"||process.browser===!0||process.__nwjs?TJ.exports=jPe():TJ.exports=qPe()});var oL=_(Ki=>{"use strict";Object.defineProperty(Ki,"__esModule",{value:!0});Ki.DownloadHTTPError=Ki.DownloadLengthMismatchError=Ki.DownloadError=Ki.ExpiredMetadataError=Ki.EqualVersionError=Ki.BadVersionError=Ki.RepositoryError=Ki.PersistError=Ki.RuntimeError=Ki.ValueError=void 0;var FJ=class extends Error{};Ki.ValueError=FJ;var NJ=class extends Error{};Ki.RuntimeError=NJ;var OJ=class extends Error{};Ki.PersistError=OJ;var _b=class extends Error{};Ki.RepositoryError=_b;var sL=class extends _b{};Ki.BadVersionError=sL;var LJ=class extends sL{};Ki.EqualVersionError=LJ;var MJ=class extends _b{};Ki.ExpiredMetadataError=MJ;var Hb=class extends Error{};Ki.DownloadError=Hb;var UJ=class extends Hb{};Ki.DownloadLengthMismatchError=UJ;var _J=class extends Hb{constructor(e,r){super(e),this.statusCode=r}};Ki.DownloadHTTPError=_J});var YPe=_(d1=>{"use strict";var jJ=d1&&d1.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(d1,"__esModule",{value:!0});d1.withTempFile=void 0;var HJ=jJ(Ie("fs/promises")),vvt=jJ(Ie("os")),WPe=jJ(Ie("path")),Svt=async t=>Dvt(async e=>t(WPe.default.join(e,"tempfile")));d1.withTempFile=Svt;var Dvt=async t=>{let e=await HJ.default.realpath(vvt.default.tmpdir()),r=await HJ.default.mkdtemp(e+WPe.default.sep);try{return await t(r)}finally{await HJ.default.rm(r,{force:!0,recursive:!0,maxRetries:3})}}});var qJ=_(kg=>{"use strict";var lL=kg&&kg.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(kg,"__esModule",{value:!0});kg.DefaultFetcher=kg.BaseFetcher=void 0;var bvt=lL(RJ()),VPe=lL(Ie("fs")),Pvt=lL(CO()),xvt=lL(Ie("util")),JPe=oL(),kvt=YPe(),Qvt=(0,bvt.default)("tuf:fetch"),aL=class{async downloadFile(e,r,s){return(0,kvt.withTempFile)(async a=>{let n=await this.fetch(e),c=0,f=VPe.default.createWriteStream(a);try{for await(let p of n){let h=Buffer.from(p);if(c+=h.length,c>r)throw new JPe.DownloadLengthMismatchError("Max length reached");await Tvt(f,h)}}finally{await xvt.default.promisify(f.close).bind(f)()}return s(a)})}async downloadBytes(e,r){return this.downloadFile(e,r,async s=>{let a=VPe.default.createReadStream(s),n=[];for await(let c of a)n.push(c);return Buffer.concat(n)})}};kg.BaseFetcher=aL;var GJ=class extends aL{constructor(e={}){super(),this.timeout=e.timeout,this.retry=e.retry}async fetch(e){Qvt("GET %s",e);let r=await(0,Pvt.default)(e,{timeout:this.timeout,retry:this.retry});if(!r.ok||!r?.body)throw new JPe.DownloadHTTPError("Failed to download",r.status);return r.body}};kg.DefaultFetcher=GJ;var Tvt=async(t,e)=>new Promise((r,s)=>{t.write(e,a=>{a&&s(a),r(!0)})})});var KPe=_(cL=>{"use strict";Object.defineProperty(cL,"__esModule",{value:!0});cL.defaultConfig=void 0;cL.defaultConfig={maxRootRotations:256,maxDelegations:32,rootMaxLength:512e3,timestampMaxLength:16384,snapshotMaxLength:2e6,targetsMaxLength:5e6,prefixTargetsWithHash:!0,fetchTimeout:1e5,fetchRetries:void 0,fetchRetry:2}});var zPe=_(uL=>{"use strict";Object.defineProperty(uL,"__esModule",{value:!0});uL.TrustedMetadataStore=void 0;var Es=eL(),Hi=oL(),WJ=class{constructor(e){this.trustedSet={},this.referenceTime=new Date,this.loadTrustedRoot(e)}get root(){if(!this.trustedSet.root)throw new ReferenceError("No trusted root metadata");return this.trustedSet.root}get timestamp(){return this.trustedSet.timestamp}get snapshot(){return this.trustedSet.snapshot}get targets(){return this.trustedSet.targets}getRole(e){return this.trustedSet[e]}updateRoot(e){let r=JSON.parse(e.toString("utf8")),s=Es.Metadata.fromJSON(Es.MetadataKind.Root,r);if(s.signed.type!=Es.MetadataKind.Root)throw new Hi.RepositoryError(`Expected 'root', got ${s.signed.type}`);if(this.root.verifyDelegate(Es.MetadataKind.Root,s),s.signed.version!=this.root.signed.version+1)throw new Hi.BadVersionError(`Expected version ${this.root.signed.version+1}, got ${s.signed.version}`);return s.verifyDelegate(Es.MetadataKind.Root,s),this.trustedSet.root=s,s}updateTimestamp(e){if(this.snapshot)throw new Hi.RuntimeError("Cannot update timestamp after snapshot");if(this.root.signed.isExpired(this.referenceTime))throw new Hi.ExpiredMetadataError("Final root.json is expired");let r=JSON.parse(e.toString("utf8")),s=Es.Metadata.fromJSON(Es.MetadataKind.Timestamp,r);if(s.signed.type!=Es.MetadataKind.Timestamp)throw new Hi.RepositoryError(`Expected 'timestamp', got ${s.signed.type}`);if(this.root.verifyDelegate(Es.MetadataKind.Timestamp,s),this.timestamp){if(s.signed.version<this.timestamp.signed.version)throw new Hi.BadVersionError(`New timestamp version ${s.signed.version} is less than current version ${this.timestamp.signed.version}`);if(s.signed.version===this.timestamp.signed.version)throw new Hi.EqualVersionError(`New timestamp version ${s.sLine truncated
`,_St=/\u2014 (\S+) (\S+)\n/g;function HSt(t,e){let r=(0,USt.filterTLogAuthorities)(e,{targetDate:new Date(Number(t.integratedTime)*1e3)}),s=t.inclusionProof,a=pK.fromString(s.checkpoint.envelope),n=hK.fromString(a.note);if(!jSt(a,r))throw new I1.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"invalid checkpoint signature"});if(!AK.crypto.bufferEqual(n.logHash,s.rootHash))throw new I1.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"root hash mismatch"})}function jSt(t,e){let r=Buffer.from(t.note,"utf-8");return t.signatures.every(s=>{let a=e.find(n=>AK.crypto.bufferEqual(n.logID.subarray(0,4),s.keyHint));return a?AK.crypto.verify(r,a.publicKey,s.signature):!1})}var pK=class t{constructor(e,r){this.note=e,this.signatures=r}static fromString(e){if(!e.includes(fK))throw new I1.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"missing checkpoint separator"});let r=e.indexOf(fK),s=e.slice(0,r+1),n=e.slice(r+fK.length).matchAll(_St),c=Array.from(n,f=>{let[,p,h]=f,E=Buffer.from(h,"base64");if(E.length<5)throw new I1.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"malformed checkpoint signature"});return{name:p,keyHint:E.subarray(0,4),signature:E.subarray(4)}});if(c.length===0)throw new I1.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"no signatures found in checkpoint"});return new t(s,c)}},hK=class t{constructor(e,r,s,a){this.origin=e,this.logSize=r,this.logHash=s,this.rest=a}static fromString(e){let r=e.trimEnd().split(`
`);if(r.length<3)throw new I1.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"too few lines in checkpoint header"});let s=r[0],a=BigInt(r[1]),n=Buffer.from(r[2],"base64"),c=r.slice(3);return new t(s,a,n,c)}}});var Exe=_(EK=>{"use strict";Object.defineProperty(EK,"__esModule",{value:!0});EK.verifyMerkleInclusion=WSt;var yK=Cl(),dK=Eo(),GSt=Buffer.from([0]),qSt=Buffer.from([1]);function WSt(t){let e=t.inclusionProof,r=BigInt(e.logIndex),s=BigInt(e.treeSize);if(r<0n||r>=s)throw new dK.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:`invalid index: ${r}`});let{inner:a,border:n}=YSt(r,s);if(e.hashes.length!==a+n)throw new dK.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"invalid hash count"});let c=e.hashes.slice(0,a),f=e.hashes.slice(a),p=ZSt(t.canonicalizedBody),h=JSt(VSt(p,c,r),f);if(!yK.crypto.bufferEqual(h,e.rootHash))throw new dK.VerificationError({code:"TLOG_INCLUSION_PROOF_ERROR",message:"calculated root hash does not match inclusion proof"})}function YSt(t,e){let r=KSt(t,e),s=zSt(t>>BigInt(r));return{inner:r,border:s}}function VSt(t,e,r){return e.reduce((s,a,n)=>r>>BigInt(n)&BigInt(1)?mK(a,s):mK(s,a),t)}function JSt(t,e){return e.reduce((r,s)=>mK(s,r),t)}function KSt(t,e){return XSt(t^e-BigInt(1))}function zSt(t){return t.toString(2).split("1").length-1}function XSt(t){return t===0n?0:t.toString(2).length}function mK(t,e){return yK.crypto.digest("sha256",qSt,t,e)}function ZSt(t){return yK.crypto.digest("sha256",GSt,t)}});var Cxe=_(IK=>{"use strict";Object.defineProperty(IK,"__esModule",{value:!0});IK.verifyTLogSET=tDt;var Ixe=Cl(),$St=Eo(),eDt=py();function tDt(t,e){if(!(0,eDt.filterTLogAuthorities)(e,{logID:t.logId.keyId,targetDate:new Date(Number(t.integratedTime)*1e3)}).some(a=>{let n=rDt(t),c=Buffer.from(Ixe.json.canonicalize(n),"utf8"),f=t.inclusionPromise.signedEntryTimestamp;return Ixe.crypto.verify(c,a.publicKey,f)}))throw new $St.VerificationError({code:"TLOG_INCLUSION_PROMISE_ERROR",message:"inclusion promise could not be verified"})}function rDt(t){let{integratedTime:e,logIndex:r,logId:s,canonicalizedBody:a}=t;return{body:a.toString("base64"),integratedTime:Number(e),logIndex:Number(r),logID:s.keyId.toString("hex")}}});var wxe=_(BK=>{"use strict";Object.defineProperty(BK,"__esModule",{value:!0});BK.verifyRFC3161Timestamp=sDt;var CK=Cl(),wK=Eo(),nDt=cK(),iDt=py();function sDt(t,e,r){let s=t.signingTime;if(r=(0,iDt.filterCertAuthorities)(r,{start:s,end:s}),r=aDt(r,{serialNumber:t.signerSerialNumber,issuer:t.signerIssuer}),!r.some(n=>{try{return oDt(t,e,n),!0}catch{return!1}}))throw new wK.VerificationError({code:"TIMESTAMP_ERROR",message:"timestamp could not be verified"})}function oDt(t,e,r){let[s,...a]=r.certChain,n=CK.crypto.createPublicKey(s.publicKey),c=t.signingTime;try{new nDt.CertificateChainVerifier({untrustedCert:s,trustedCerts:a}).verify()}catch{throw new wK.VerificationError({code:"TIMESTAMP_ERROR",message:"invalid certificate chain"})}if(!r.certChain.every(p=>p.validForDate(c)))throw new wK.VerificationError({code:"TIMESTAMP_ERROR",message:"timestamp was signed with an expired certificate"});t.verify(e,n)}function aDt(t,e){return t.filter(r=>r.certChain.length>0&&CK.crypto.bufferEqual(r.certChain[0].serialNumber,e.serialNumber)&&CK.crypto.bufferEqual(r.certChain[0].issuer,e.issuer))}});var Bxe=_(vL=>{"use strict";Object.defineProperty(vL,"__esModule",{value:!0});vL.verifyTSATimestamp=pDt;vL.verifyTLogTimestamp=hDt;var lDt=Eo(),cDt=yxe(),uDt=Exe(),fDt=Cxe(),ADt=wxe();function pDt(t,e,r){return(0,ADt.verifyRFC3161Timestamp)(t,e,r),{type:"timestamp-authority",logID:t.signerSerialNumber,timestamp:t.signingTime}}function hDt(t,e){let r=!1;if(gDt(t)&&((0,fDt.verifyTLogSET)(t,e),r=!0),dDt(t)&&((0,uDt.verifyMerkleInclusion)(t),(0,cDt.verifyCheckpoint)(t,e),r=!0),!r)throw new lDt.VerificationError({code:"TLOG_MISSING_INCLUSION_ERROR",message:"inclusion could not be verified"});return{type:"transparency-log",logID:t.logId.keyId,timestamp:new Date(Number(t.integratedTime)*1e3)}}function gDt(t){return t.inclusionPromise!==void 0}function dDt(t){return t.inclusionProof!==void 0}});var vxe=_(vK=>{"use strict";Object.defineProperty(vK,"__esModule",{value:!0});vK.verifyDSSETLogBody=mDt;var SL=Eo();function mDt(t,e){switch(t.apiVersion){case"0.0.1":return yDt(t,e);default:throw new SL.VerificationError({code:"TLOG_BODY_ERROR",message:`unsupported dsse version: ${t.apiVersion}`})}}function yDt(t,e){if(t.spec.signatures?.length!==1)throw new SL.VerificationError({code:"TLOG_BODY_ERROR",message:"signature count mismatch"});let r=t.spec.signatures[0].signature;if(!e.compareSignature(Buffer.from(r,"base64")))throw new SL.VerificationError({code:"TLOG_BODY_ERROR",message:"tlog entry signature mismatch"});let s=t.spec.payloadHash?.value||"";if(!e.compareDigest(Buffer.from(s,"hex")))throw new SL.VerificationError({code:"TLOG_BODY_ERROR",message:"DSSE payload hash mismatch"})}});var Sxe=_(DK=>{"use strict";Object.defineProperty(DK,"__esModule",{value:!0});DK.verify Line truncated
Try running the command again with the package name prefixed: ${he.pretty(r,"yarn add",he.Type.CODE)} ${he.pretty(r,G.makeDescriptor(G.makeIdent(null,"my-package"),`${ie[0]}...`),he.Type.DESCRIPTOR)}`);if(!ee)throw new nt(`The ${he.pretty(r,W,he.Type.CODE)} string didn't match the required format (package-name@range). Did you perhaps forget to explicitly reference the package name?`);let ue=Hlt(a,ee,{dev:this.dev,peer:this.peer,preferDev:this.preferDev,optional:this.optional});return await Promise.all(ue.map(async me=>{let pe=await zv(ee,{project:s,workspace:a,cache:n,fixed:c,target:me,modifier:h,strategies:E,maxResults:C});return{request:ee,suggestedDescriptors:pe,target:me}}))})).then(W=>W.flat()),I=await lA.start({configuration:r,stdout:this.context.stdout,suggestInstall:!1},async W=>{for(let{request:ee,suggestedDescriptors:{suggestions:ie,rejections:ue}}of P)if(ie.filter(me=>me.descriptor!==null).length===0){let[me]=ue;if(typeof me>"u")throw new Error("Assertion failed: Expected an error to have been set");s.configuration.get("enableNetwork")?W.reportError(27,`${G.prettyDescriptor(r,ee)} can't be resolved to a satisfying range`):W.reportError(27,`${G.prettyDescriptor(r,ee)} can't be resolved to a satisfying range (note: network resolution has been disabled)`),W.reportSeparator(),W.reportExceptionOnce(me)}});if(I.hasErrors())return I.exitCode();let R=!1,N=[],U=[];for(let{suggestedDescriptors:{suggestions:W},target:ee}of P){let ie,ue=W.filter(Be=>Be.descriptor!==null),le=ue[0].descriptor,me=ue.every(Be=>G.areDescriptorsEqual(Be.descriptor,le));ue.length===1||me?ie=le:(R=!0,{answer:ie}=await(0,hye.prompt)({type:"select",name:"answer",message:"Which range do you want to use?",choices:W.map(({descriptor:Be,name:Ce,reason:g})=>Be?{name:Ce,hint:g,descriptor:Be}:{name:Ce,hint:g,disabled:!0}),onCancel:()=>process.exit(130),result(Be){return this.find(Be,"descriptor")},stdin:this.context.stdin,stdout:this.context.stdout}));let pe=a.manifest[ee].get(ie.identHash);(typeof pe>"u"||pe.descriptorHash!==ie.descriptorHash)&&(a.manifest[ee].set(ie.identHash,ie),this.optional&&(ee==="dependencies"?a.manifest.ensureDependencyMeta({...ie,range:"unknown"}).optional=!0:ee==="peerDependencies"&&(a.manifest.ensurePeerDependencyMeta({...ie,range:"unknown"}).optional=!0)),typeof pe>"u"?N.push([a,ee,ie,E]):U.push([a,ee,pe,ie]))}return await r.triggerMultipleHooks(W=>W.afterWorkspaceDependencyAddition,N),await r.triggerMultipleHooks(W=>W.afterWorkspaceDependencyReplacement,U),R&&this.context.stdout.write(`
`),await s.installWithNewReport({json:this.json,stdout:this.context.stdout,quiet:this.context.quiet},{cache:n,mode:this.mode})}};function Hlt(t,e,{dev:r,peer:s,preferDev:a,optional:n}){let c=t.manifest.dependencies.has(e.identHash),f=t.manifest.devDependencies.has(e.identHash),p=t.manifest.peerDependencies.has(e.identHash);if((r||s)&&c)throw new nt(`Package "${G.prettyIdent(t.project.configuration,e)}" is already listed as a regular dependency - remove the -D,-P flags or remove it from your dependencies first`);if(!r&&!s&&p)throw new nt(`Package "${G.prettyIdent(t.project.configuration,e)}" is already listed as a peer dependency - use either of -D or -P, or remove it from your peer dependencies first`);if(n&&f)throw new nt(`Package "${G.prettyIdent(t.project.configuration,e)}" is already listed as a dev dependency - remove the -O flag or remove it from your dev dependencies first`);if(n&&!s&&p)throw new nt(`Package "${G.prettyIdent(t.project.configuration,e)}" is already listed as a peer dependency - remove the -O flag or add the -P flag or remove it from your peer dependencies first`);if((r||a)&&n)throw new nt(`Package "${G.prettyIdent(t.project.configuration,e)}" cannot simultaneously be a dev dependency and an optional dependency`);let h=[];return s&&h.push("peerDependencies"),(r||a)&&h.push("devDependencies"),n&&h.push("dependencies"),h.length>0?h:f?["devDependencies"]:p?["peerDependencies"]:["dependencies"]}Ge();Ge();Yt();var oC=class extends ft{constructor(){super(...arguments);this.verbose=ge.Boolean("-v,--verbose",!1,{description:"Print both the binary name and the locator of the package that provides the binary"});this.json=ge.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.name=ge.String({required:!1})}static{this.paths=[["bin"]]}static{this.usage=ot.Usage({description:"get the path to a binary script",details:`
When used without arguments, this command will print the list of all the binaries available in the current workspace. Adding the \`-v,--verbose\` flag will cause the output to contain both the binary name and the locator of the package that provides the binary.
When an argument is specified, this command will just print the path to the binary on the standard output and exit. Note that the reported path may be stored within a zip archive.
`,examples:[["List all the available binaries","$0 bin"],["Print the path to a specific binary","$0 bin eslint"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s,locator:a}=await Tt.find(r,this.context.cwd);if(await s.restoreInstallState(),this.name){let f=(await In.getPackageAccessibleBinaries(a,{project:s})).get(this.name);if(!f)throw new nt(`Couldn't find a binary named "${this.name}" for package "${G.prettyLocator(r,a)}"`);let[,p]=f;return this.context.stdout.write(`${p}
`),0}return(await Ot.start({configuration:r,json:this.json,stdout:this.context.stdout},async c=>{let f=await In.getPackageAccessibleBinaries(a,{project:s}),h=Array.from(f.keys()).reduce((E,C)=>Math.max(E,C.length),0);for(let[E,[C,S]]of f)c.reportJson({name:E,source:G.stringifyIdent(C),path:S});if(this.verbose)for(let[E,[C]]of f)c.reportInfo(null,`${E.padEnd(h," ")} ${G.prettyLocator(r,C)}`);else for(let E of f.keys())c.reportInfo(null,E)})).exitCode()}};Ge();Dt();Yt();var aC=class extends ft{constructor(){super(...arguments);this.mirror=ge.Boolean("--mirror",!1,{description:"Remove the global cache files instead of the local cache files"});this.all=ge.Boolean("--all",!1,{description:"Remove both the global cache files and the local cache files of the current project"})}static{this.paths=[["cache","clean"],["cache","clear"]]}static{this.usage=ot.Usage({description:"remove the shared cache files",details:`
This command will remove all the files from the cache.
`,examples:[["Remove all the local archives","$0 cache clean"],["Remove all the archives stored in the ~/.yarn directory","$0 cache clean --mirror"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins);if(!r.get("enableCacheClean"))throw new nt("Cache cleaning is currently disabled. To enable it, set `enableCacheClean: true` in your configuration file. Note: Cache cleaning is typically not required and should be avoided when using Zero-Installs.");let s=await Kr.find(r);return(await Ot.start({configuration:r,stdout:this.context.stdout},async()=>{let n=(this.all||this.mirror)&&s.mirrorCwd!==null,c=!this.mirror;n&&(await ce.removePromise(s.mirrorCwd),await r.triggerHook(f=>f.cleanGlobalArtifacts,r)),c&&await ce.removePromise(s.cwd)})).exitCode()}};Ge();Yt();ql();var J5=Ie("util"),lC=class extends ft{constructor(){super(...arguments);this.why=ge.Boolean("--why",!1,{description:"Print the explanation for why a setting has its value"});this.json=ge.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.unsafe=ge.Boolean("--no-redacted",!1,{description:"Don't redact secrets (such as tokens) from the output"});this.name=ge.String()}static{this.paths=[["config","get"]]}static{this.usage=ot.Usage({description:"read a configuration settings",details:`
This command will print a configuration setting.
Secrets (such as tokens) will be redacted from the output by default. If this behavior isn't desired, set the \`--no-redacted\` to get the untransformed value.
`,examples:[["Print a simple configuration setting","yarn config get yarnPath"],["Print a complex configuration setting","yarn config get packageExtensions"],["Print a nested field from the configuration",`yarn config get 'npmScopes["my-company"].npmRegistryServer'`],["Print a token from the configuration","yarn config get npmAuthToken --no-redacted"],["Print a configuration setting as JSON","yarn config get packageExtensions --json"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),s=this.name.replace(/[.[].*$/,""),a=this.name.replace(/^[^.[]*/,"");if(typeof r.settings.get(s)>"u")throw new nt(`Couldn't find a configuration settings named "${s}"`);let c=r.getSpecial(s,{hideSecrets:!this.unsafe,getNativePaths:!0}),f=je.convertMapsToIndexableObjects(c),p=a?va(f,a):f,h=await Ot.start({configuration:r,includeFooter:!1,json:this.json,stdout:this.context.stdout},async E=>{E.reportJson(p)});if(!this.json){if(typeof p=="string")return this.context.stdout.write(`${p}
`),h.exitCode();J5.inspect.styles.name="cyan",this.context.stdout.write(`${(0,J5.inspect)(p,{depth:1/0,colors:r.get("enableColors"),compact:!1})}
`)}return h.exitCode()}};Ge();Yt();ql();var K5=Ie("util"),cC=class extends ft{constructor(){super(...arguments);this.json=ge.Boolean("--json",!1,{description:"Set complex configuration settings to JSON values"});this.home=ge.Boolean("-H,--home",!1,{description:"Update the home configuration instead of the project configuration"});this.name=ge.String();this.value=ge.String()}static{this.paths=[["config","set"]]}static{this.usage=ot.Usage({description:"change a configuration settings",details:`
This command will set a configuration setting.
When used without the \`--json\` flag, it can only set a simple configuration setting (a string, a number, or a boolean).
When used with the \`--json\` flag, it can set both simple and complex configuration settings, including Arrays and Objects.
`,examples:[["Set a simple configuration setting (a string, a number, or a boolean)","yarn config set initScope myScope"],["Set a simple configuration setting (a string, a number, or a boolean) using the `--json` flag",'yarn config set initScope --json \\"myScope\\"'],["Set a complex configuration setting (an Array) using the `--json` flag",`yarn config set unsafeHttpWhitelist --json '["*.example.com", "example.com"]'`],["Set a complex configuration setting (an Object) using the `--json` flag",`yarn config set packageExtensions --json '{ "@babel/parser@*": { "dependencies": { "@babel/types": "*" } } }'`],["Set a nested configuration setting",'yarn config set npmScopes.company.npmRegistryServer "https://npm.example.com"'],["Set a nested configuration setting using indexed access for non-simple keys",`yarn config set 'npmRegistries["//npm.example.com"].npmAuthToken' "ffffffff-ffff-ffff-ffff-ffffffffffff"`]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),s=()=>{if(!r.projectCwd)throw new nt("This command must be run from within a project folder");return r.projectCwd},a=this.name.replace(/[.[].*$/,""),n=this.name.replace(/^[^.[]*\.?/,"");if(typeof r.settings.get(a)>"u")throw new nt(`Couldn't find a configuration settings named "${a}"`);if(a==="enableStrictSettings")throw new nt("This setting only affects the file it's in, and thus cannot be set from the CLI");let f=this.json?JSON.parse(this.value):this.value;await(this.home?I=>ze.updateHomeConfiguration(I):I=>ze.updateConfiguration(s(),I))(I=>{if(n){let R=f0(I);return Jd(R,this.name,f),R}else return{...I,[a]:f}});let E=(await ze.find(this.context.cwd,this.context.plugins)).getSpecial(a,{hideSecrets:!0,getNativePaths:!0}),C=je.convertMapsToIndexableObjects(E),S=n?va(C,n):C;return(await Ot.start({configuration:r,includeFooter:!1,stdout:this.context.stdout},async I=>{K5.inspect.styles.name="cyan",I.reportInfo(0,`Successfully set ${this.name} to ${(0,K5.inspect)(S,{depth:1/0,colors:r.get("enableColors"),compact:!1})}`)})).exitCode()}};Ge();Yt();ql();var uC=class extends ft{constructor(){super(...arguments);this.home=ge.Boolean("-H,--home",!1,{description:"Update the home configuration instead of the project configuration"});this.name=ge.String()}static{this.paths=[["config","unset"]]}static{this.usage=ot.Usage({description:"unset a configuration setting",details:`
This command will unset a configuration setting.
`,examples:[["Unset a simple configuration setting","yarn config unset initScope"],["Unset a complex configuration setting","yarn config unset packageExtensions"],["Unset a nested configuration setting","yarn config unset npmScopes.company.npmRegistryServer"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),s=()=>{if(!r.projectCwd)throw new nt("This command must be run from within a project folder");return r.projectCwd},a=this.name.replace(/[.[].*$/,""),n=this.name.replace(/^[^.[]*\.?/,"");if(typeof r.settings.get(a)>"u")throw new nt(`Couldn't find a configuration settings named "${a}"`);let f=this.home?h=>ze.updateHomeConfiguration(h):h=>ze.updateConfiguration(s(),h);return(await Ot.start({configuration:r,includeFooter:!1,stdout:this.context.stdout},async h=>{let E=!1;await f(C=>{if(!vB(C,this.name))return h.reportWarning(0,`Configuration doesn't contain setting ${this.name}; there is nothing to unset`),E=!0,C;let S=n?f0(C):{...C};return A0(S,this.name),S}),E||h.reportInfo(0,`Successfully unset ${this.name}`)})).exitCode()}};Ge();Dt();Yt();var tF=Ie("util"),fC=class extends ft{constructor(){super(...arguments);this.noDefaults=ge.Boolean("--no-defaults",!1,{description:"Omit the default values from the display"});this.json=ge.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.verbose=ge.Boolean("-v,--verbose",{hidden:!0});this.why=ge.Boolean("--why",{hidden:!0});this.names=ge.Rest()}static{this.paths=[["config"]]}static{this.usage=ot.Usage({description:"display the current configuration",details:`
This command prints the current active configuration settings.
`,examples:[["Print the active configuration settings","$0 config"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins,{strict:!1}),s=await SI({configuration:r,stdout:this.context.stdout,forceError:this.json},[{option:this.verbose,message:"The --verbose option is deprecated, the settings' descriptions are now always displayed"},{option:this.why,message:"The --why option is deprecated, the settings' sources are now always displayed"}]);if(s!==null)return s;let a=this.names.length>0?[...new Set(this.names)].sort():[...r.settings.keys()].sort(),n,c=await Ot.start({configuration:r,json:this.json,stdout:this.context.stdout,includeFooter:!1},async f=>{if(r.invalid.size>0&&!this.json){for(let[p,h]of r.invalid)f.reportError(34,`Invalid configuration key "${p}" in ${h}`);f.reportSeparator()}if(this.json)for(let p of a){if(this.noDefaults&&!r.sources.has(p))continue;let h=r.settings.get(p);typeof h>"u"&&f.reportError(34,`No configuration key named "${p}"`);let E=r.getSpecial(p,{hideSecrets:!0,getNativePaths:!0}),C=r.sources.get(p)??"<default>",S=C&&C[0]!=="<"?fe.fromPortablePath(C):C;f.reportJson({key:p,effective:E,source:S,...h})}else{let p={breakLength:1/0,colors:r.get("enableColors"),maxArrayLength:2},h={},E={children:h};for(let C of a){if(this.noDefaults&&!r.sources.has(C))continue;let S=r.settings.get(C),P=r.sources.get(C)??"<default>",I=r.getSpecial(C,{hideSecrets:!0,getNativePaths:!0}),R={Description:{label:"Description",value:he.tuple(he.Type.MARKDOWN,{text:S.description,format:this.cli.format(),paragraphs:!1})},Source:{label:"Source",value:he.tuple(P[0]==="<"?he.Type.CODE:he.Type.PATH,P)}};h[C]={value:he.tuple(he.Type.CODE,C),children:R};let N=(U,W)=>{for(let[ee,ie]of W)if(ie instanceof Map){let ue={};U[ee]={children:ue},N(ue,ie)}else U[ee]={label:ee,value:he.tuple(he.Type.NO_HINT,(0,tF.inspect)(ie,p))}};I instanceof Map?N(R,I):R.Value={label:"Value",value:he.tuple(he.Type.NO_HINT,(0,tF.inspect)(I,p))}}a.length!==1&&(n=void 0),xs.emitTree(E,{configuration:r,json:this.json,stdout:this.context.stdout,separators:2})}});if(!this.json&&typeof n<"u"){let f=a[0],p=(0,tF.inspect)(r.getSpecial(f,{hideSecrets:!0,getNativePaths:!0}),{colors:r.get("enableColors")});this.context.stdout.write(`
`),this.context.stdout.write(`${p}
`)}return c.exitCode()}};Ge();Yt();Ul();var rF={};Vt(rF,{Strategy:()=>Xv,acceptedStrategies:()=>jlt,dedupe:()=>z5});Ge();Ge();var gye=ut(Go()),Xv=(e=>(e.HIGHEST="highest",e))(Xv||{}),jlt=new Set(Object.values(Xv)),Glt={highest:async(t,e,{resolver:r,fetcher:s,resolveOptions:a,fetchOptions:n})=>{let c=new Map;for(let[p,h]of t.storedResolutions){let E=t.storedDescriptors.get(p);if(typeof E>"u")throw new Error(`Assertion failed: The descriptor (${p}) should have been registered`);je.getSetWithDefault(c,E.identHash).add(h)}let f=new Map(je.mapAndFilter(t.storedDescriptors.values(),p=>G.isVirtualDescriptor(p)?je.mapAndFilter.skip:[p.descriptorHash,je.makeDeferred()]));for(let p of t.storedDescriptors.values()){let h=f.get(p.descriptorHash);if(typeof h>"u")throw new Error(`Assertion failed: The descriptor (${p.descriptorHash}) should have been registered`);let E=t.storedResolutions.get(p.descriptorHash);if(typeof E>"u")throw new Error(`Assertion failed: The resolution (${p.descriptorHash}) should have been registered`);let C=t.originalPackages.get(E);if(typeof C>"u")throw new Error(`Assertion failed: The package (${E}) should have been registered`);Promise.resolve().then(async()=>{let S=r.getResolutionDependencies(p,a),P=Object.fromEntries(await je.allSettledSafe(Object.entries(S).map(async([ee,ie])=>{let ue=f.get(ie.descriptorHash);if(typeof ue>"u")throw new Error(`Assertion failed: The descriptor (${ie.descriptorHash}) should have been registered`);let le=await ue.promise;if(!le)throw new Error("Assertion failed: Expected the dependency to have been through the dedupe process itself");return[ee,le.updatedPackage]})));if(e.length&&!gye.default.isMatch(G.stringifyIdent(p),e)||!r.shouldPersistResolution(C,a))return C;let I=c.get(p.identHash);if(typeof I>"u")throw new Error(`Assertion failed: The resolutions (${p.identHash}) should have been registered`);if(I.size===1)return C;let R=[...I].map(ee=>{let ie=t.originalPackages.get(ee);if(typeof ie>"u")throw new Error(`Assertion failed: The package (${ee}) should have been registered`);return ie}),N=await r.getSatisfying(p,P,R,a),U=N.locators?.[0];if(typeof U>"u"||!N.sorted)return C;let W=t.originalPackages.get(U.locatorHash);if(typeof W>"u")throw new Error(`Assertion failed: The package (${U.locatorHash}) should have been registered`);return W}).then(async S=>{let P=await t.preparePackage(S,{resolver:r,resolveOptions:a});h.resolve({descriptor:p,currentPackage:C,updatedPackage:S,resolvedPackage:P})}).catch(S=>{h.reject(S)})}return[...f.values()].map(p=>p.promise)}};async function z5(t,{strategy:e,patterns:r,cache:s,report:a}){let{configuration:n}=t,c=new ki,f=n.makeResolver(),p=n.makeFetcher(),h={cache:s,checksums:t.storedChecksums,fetcher:p,project:t,report:c,cacheOptions:{skipIntegrityCheck:!0}},E={project:t,resolver:f,report:c,fetchOptions:h};return await a.startTimerPromise("Deduplication step",async()=>{let C=Glt[e],S=await C(t,r,{resolver:f,resolveOptions:E,fetcher:p,fetchOptions:h}),P=Ao.progressViaCounter(S.length);await a.reportProgress(P);let I=0;await Promise.all(S.map(U=>U.then(W=>{if(W===null||W.currentPackage.locatorHash===W.updatedPackage.locatorHash)return;I++;let{descriptor:ee,currentPackage:ie,updatedPackage:ue}=W;a.reportInfo(0,`${G.prettyDescriptor(n,ee)} can be deduped from ${G.prettyLocator(n,ie)} to ${G.prettyLocator(n,ue)}`),a.reportJson({descriptor:G.stringifyDescriptor(ee),currentResolution:G.stringifyLocator(ie),updatedResolution:G.stringifyLocator(ue)}),t.storedResolutions.set(ee.descriptorHash,ue.locatorHash)}).finally(()=>P.tick())));let R;switch(I){case 0:R="No packages";break;case 1:R="One package";break;default:R=`${I} packages`}let N=he.pretty(n,e,he.Type.CODE);return a.reportInfo(0,`${R} can be deduped using the ${N} strategy`),I})}var AC=class extends ft{constructor(){super(...arguments);this.strategy=ge.String("-s,--strategy","highest",{description:"The strategy to use when deduping dependencies",validator:fo(Xv)});this.check=ge.Boolean("-c,--check",!1,{description:"Exit with exit code 1 when duplicates are found, without persisting the dependency tree"});this.json=ge.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.mode=ge.String("--mode",{description:"Change what artifacts installs generate",validator:fo($l)});this.patterns=ge.Rest()}static{this.paths=[["dedupe"]]}static{this.usage=ot.Usage({description:"deduplicate dependencies with overlapping ranges",details:"\n Duplicates are defined as descriptors with overlapping ranges being resolved and locked to different locators. They are a natural consequence of Yarn's deterministic installs, but they can sometimes pile up and unnecessarily increase the size of your project.\n\n This command dedupes dependencies in the current project using different strategies (only one is implemented at the moment):\n\n - `highest`: Reuses (where possible) the locators with the highest versions. This means that dependencies can only be upgraded, never dow Line truncated
`)}};var hC=class extends ft{static{this.paths=[["help"],["--help"],["-h"]]}async execute(){this.context.stdout.write(this.cli.usage(null))}};Ge();Dt();Yt();var gC=class extends ft{constructor(){super(...arguments);this.leadingArgument=ge.String();this.args=ge.Proxy()}async execute(){if(this.leadingArgument.match(/[\\/]/)&&!G.tryParseIdent(this.leadingArgument)){let r=J.resolve(this.context.cwd,fe.toPortablePath(this.leadingArgument));return await this.cli.run(this.args,{cwd:r})}else return await this.cli.run(["run",this.leadingArgument,...this.args])}};Ge();var dC=class extends ft{static{this.paths=[["-v"],["--version"]]}async execute(){this.context.stdout.write(`${fn||"<unknown>"}
`)}};Ge();Ge();Yt();var mC=class extends ft{constructor(){super(...arguments);this.commandName=ge.String();this.args=ge.Proxy()}static{this.paths=[["exec"]]}static{this.usage=ot.Usage({description:"execute a shell script",details:`
This command simply executes a shell script within the context of the root directory of the active workspace using the portable shell.
It also makes sure to call it in a way that's compatible with the current project (for example, on PnP projects the environment will be setup in such a way that PnP will be correctly injected into the environment).
`,examples:[["Execute a single shell command","$0 exec echo Hello World"],["Execute a shell script",'$0 exec "tsc & babel src --out-dir lib"']]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s,locator:a}=await Tt.find(r,this.context.cwd);return await s.restoreInstallState(),await In.executePackageShellcode(a,this.commandName,this.args,{cwd:this.context.cwd,stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr,project:s})}};Ge();Yt();Ul();var yC=class extends ft{constructor(){super(...arguments);this.hash=ge.String({required:!1,validator:Nx(wE(),[Z2(/^p[0-9a-f]{6}$/)])})}static{this.paths=[["explain","peer-requirements"]]}static{this.usage=ot.Usage({description:"explain a set of peer requirements",details:`
A peer requirement represents all peer requests that a subject must satisfy when providing a requested package to requesters.
When the hash argument is specified, this command prints a detailed explanation of the peer requirement corresponding to the hash and whether it is satisfied or not.
When used without arguments, this command lists all peer requirements and the corresponding hash that can be used to get detailed information about a given requirement.
**Note:** A hash is a seven-letter code consisting of the letter 'p' followed by six characters that can be obtained from peer dependency warnings or from the list of all peer requirements(\`yarn explain peer-requirements\`).
`,examples:[["Explain the corresponding peer requirement for a hash","$0 explain peer-requirements p1a4ed"],["List all peer requirements","$0 explain peer-requirements"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s}=await Tt.find(r,this.context.cwd);return await s.restoreInstallState({restoreResolutions:!1}),await s.applyLightResolution(),typeof this.hash<"u"?await Wlt(this.hash,s,{stdout:this.context.stdout}):await Ylt(s,{stdout:this.context.stdout})}};async function Wlt(t,e,r){let s=e.peerRequirementNodes.get(t);if(typeof s>"u")throw new Error(`No peerDependency requirements found for hash: "${t}"`);let a=new Set,n=p=>a.has(p.requester.locatorHash)?{value:he.tuple(he.Type.DEPENDENT,{locator:p.requester,descriptor:p.descriptor}),children:p.children.size>0?[{value:he.tuple(he.Type.NO_HINT,"...")}]:[]}:(a.add(p.requester.locatorHash),{value:he.tuple(he.Type.DEPENDENT,{locator:p.requester,descriptor:p.descriptor}),children:Object.fromEntries(Array.from(p.children.values(),h=>[G.stringifyLocator(h.requester),n(h)]))}),c=e.peerWarnings.find(p=>p.hash===t);return(await Ot.start({configuration:e.configuration,stdout:r.stdout,includeFooter:!1,includePrefix:!1},async p=>{let h=he.mark(e.configuration),E=c?h.Cross:h.Check;if(p.reportInfo(0,`Package ${he.pretty(e.configuration,s.subject,he.Type.LOCATOR)} is requested to provide ${he.pretty(e.configuration,s.ident,he.Type.IDENT)} by its descendants`),p.reportSeparator(),p.reportInfo(0,he.pretty(e.configuration,s.subject,he.Type.LOCATOR)),xs.emitTree({children:Object.fromEntries(Array.from(s.requests.values(),C=>[G.stringifyLocator(C.requester),n(C)]))},{configuration:e.configuration,stdout:r.stdout,json:!1}),p.reportSeparator(),s.provided.range==="missing:"){let C=c?"":" , but all peer requests are optional";p.reportInfo(0,`${E} Package ${he.pretty(e.configuration,s.subject,he.Type.LOCATOR)} does not provide ${he.pretty(e.configuration,s.ident,he.Type.IDENT)}${C}.`)}else{let C=e.storedResolutions.get(s.provided.descriptorHash);if(!C)throw new Error("Assertion failed: Expected the descriptor to be registered");let S=e.storedPackages.get(C);if(!S)throw new Error("Assertion failed: Expected the package to be registered");p.reportInfo(0,`${E} Package ${he.pretty(e.configuration,s.subject,he.Type.LOCATOR)} provides ${he.pretty(e.configuration,s.ident,he.Type.IDENT)} with version ${G.prettyReference(e.configuration,S.version??"0.0.0")}, ${c?"which does not satisfy all requests.":"which satisfies all requests"}`),c?.type===3&&(c.range?p.reportInfo(0,` The combined requested range is ${he.pretty(e.configuration,c.range,he.Type.RANGE)}`):p.reportInfo(0," Unfortunately, the requested ranges have no overlap"))}})).exitCode()}async function Ylt(t,e){return(await Ot.start({configuration:t.configuration,stdout:e.stdout,includeFooter:!1,includePrefix:!1},async s=>{let a=he.mark(t.configuration),n=je.sortMap(t.peerRequirementNodes,[([,c])=>G.stringifyLocator(c.subject),([,c])=>G.stringifyIdent(c.ident)]);for(let[,c]of n.values()){if(!c.root)continue;let f=t.peerWarnings.find(E=>E.hash===c.hash),p=[...G.allPeerRequests(c)],h;if(p.length>2?h=` and ${p.length-1} other dependencies`:p.length===2?h=" and 1 other dependency":h="",c.provided.range!=="missing:"){let E=t.storedResolutions.get(c.provided.descriptorHash);if(!E)throw new Error("Assertion failed: Expected the resolution to have been registered");let C=t.storedPackages.get(E);if(!C)throw new Error("Assertion failed: Expected the provided package to have been registered");let S=`${he.pretty(t.configuration,c.hash,he.Type.CODE)} \u2192 ${f?a.Cross:a.Check} ${G.prettyLocator(t.configuration,c.subject)} provides ${G.prettyLocator(t.configuration,C)} to ${G.prettyLocator(t.configuration,p[0].requester)}${h}`;f?s.reportWarning(0,S):s.reportInfo(0,S)}else{let E=`${he.pretty(t.configuration,c.hash,he.Type.CODE)} \u2192 ${f?a.Cross:a.Check} ${G.prettyLocator(t.configuration,c.subject)} doesn't provide ${G.prettyIdent(t.configuration,c.ident)} to ${G.prettyLocator(t.configuration,p[0].requester)}${h}`;f?s.reportWarning(0,E):s.reportInfo(0,E)}}})).exitCode()}Ge();Yt();Ul();Ge();Ge();Dt();Yt();var mye=ut(Ai()),EC=class extends ft{constructor(){super(...arguments);this.useYarnPath=ge.Boolean("--yarn-path",{description:"Set the yarnPath setting even if the version can be accessed by Corepack"});this.onlyIfNeeded=ge.Boolean("--only-if-needed",!1,{description:"Only lock the Yarn version if it isn't already locked"});this.version=ge.String()}static{this.paths=[["set","version"]]}static{this.usage=ot.Usage({description:"lock the Yarn version used by the project",details:"\n This command will set a specific release of Yarn to be used by Corepack: https://nodejs.org/api/corepack.html.\n\n By default it only will set the `packageManager` field at the root of your project, but if the referenced release cannot be represented this way, if you already have `yarnPath` configured, or if you set th Line truncated
${e}`)})}let f=t.projectCwd??t.startingCwd,p=J.resolve(f,".yarn/releases"),h=J.resolve(p,`yarn-${e}.cjs`),E=J.relative(t.startingCwd,h),C=je.isTaggedYarnVersion(e),S=t.get("yarnPath"),P=!C,I=P||!!S||!!a;if(a===!1){if(P)throw new jt(0,"You explicitly opted out of yarnPath usage in your command line, but the version you specified cannot be represented by Corepack");I=!1}else!I&&!process.env.COREPACK_ROOT&&(s.reportWarning(0,`You don't seem to have ${he.applyHyperlink(t,"Corepack","https://nodejs.org/api/corepack.html")} enabled; we'll have to rely on ${he.applyHyperlink(t,"yarnPath","https://yarnpkg.com/configuration/yarnrc#yarnPath")} instead`),I=!0);if(I){let ee=await c();s.reportInfo(0,`Saving the new release in ${he.pretty(t,E,"magenta")}`),await ce.removePromise(J.dirname(h)),await ce.mkdirPromise(J.dirname(h),{recursive:!0}),await ce.writeFilePromise(h,ee,{mode:493}),await ze.updateConfiguration(f,{yarnPath:J.relative(f,h)})}else await ce.removePromise(J.dirname(h)),await ze.updateConfiguration(f,{yarnPath:ze.deleteProperty});let R=await Ut.tryFind(f)||new Ut;R.packageManager=`yarn@${C?e:await Zv(t,"stable")}`;let N={};R.exportTo(N);let U=J.join(f,Ut.fileName),W=`${JSON.stringify(N,null,R.indent)}
`;return await ce.changeFilePromise(U,W,{automaticNewlines:!0}),{bundleVersion:e}}function yye(t){return Br[jx(t)]}var Jlt=/## (?<code>YN[0-9]{4}) - `(?<name>[A-Z_]+)`\n\n(?<details>(?:.(?!##))+)/gs;async function Klt(t){let r=`https://repo.yarnpkg.com/${je.isTaggedYarnVersion(fn)?fn:await Zv(t,"canary")}/packages/docusaurus/docs/advanced/01-general-reference/error-codes.mdx`,s=await nn.get(r,{configuration:t});return new Map(Array.from(s.toString().matchAll(Jlt),({groups:a})=>{if(!a)throw new Error("Assertion failed: Expected the match to have been successful");let n=yye(a.code);if(a.name!==n)throw new Error(`Assertion failed: Invalid error code data: Expected "${a.name}" to be named "${n}"`);return[a.code,a.details]}))}var IC=class extends ft{constructor(){super(...arguments);this.code=ge.String({required:!1,validator:$2(wE(),[Z2(/^YN[0-9]{4}$/)])});this.json=ge.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"})}static{this.paths=[["explain"]]}static{this.usage=ot.Usage({description:"explain an error code",details:`
When the code argument is specified, this command prints its name and its details.
When used without arguments, this command lists all error codes and their names.
`,examples:[["Explain an error code","$0 explain YN0006"],["List all error codes","$0 explain"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins);if(typeof this.code<"u"){let s=yye(this.code),a=he.pretty(r,s,he.Type.CODE),n=this.cli.format().header(`${this.code} - ${a}`),f=(await Klt(r)).get(this.code),p=typeof f<"u"?he.jsonOrPretty(this.json,r,he.tuple(he.Type.MARKDOWN,{text:f,format:this.cli.format(),paragraphs:!0})):`This error code does not have a description.
You can help us by editing this page on GitHub \u{1F642}:
${he.jsonOrPretty(this.json,r,he.tuple(he.Type.URL,"https://github.com/yarnpkg/berry/blob/master/packages/docusaurus/docs/advanced/01-general-reference/error-codes.mdx"))}
`;this.json?this.context.stdout.write(`${JSON.stringify({code:this.code,name:s,details:p})}
`):this.context.stdout.write(`${n}
${p}
`)}else{let s={children:je.mapAndFilter(Object.entries(Br),([a,n])=>Number.isNaN(Number(a))?je.mapAndFilter.skip:{label:Yf(Number(a)),value:he.tuple(he.Type.CODE,n)})};xs.emitTree(s,{configuration:r,stdout:this.context.stdout,json:this.json})}}};Ge();Dt();Yt();var Eye=ut(Go()),CC=class extends ft{constructor(){super(...arguments);this.all=ge.Boolean("-A,--all",!1,{description:"Print versions of a package from the whole project"});this.recursive=ge.Boolean("-R,--recursive",!1,{description:"Print information for all packages, including transitive dependencies"});this.extra=ge.Array("-X,--extra",[],{description:"An array of requests of extra data provided by plugins"});this.cache=ge.Boolean("--cache",!1,{description:"Print information about the cache entry of a package (path, size, checksum)"});this.dependents=ge.Boolean("--dependents",!1,{description:"Print all dependents for each matching package"});this.manifest=ge.Boolean("--manifest",!1,{description:"Print data obtained by looking at the package archive (license, homepage, ...)"});this.nameOnly=ge.Boolean("--name-only",!1,{description:"Only print the name for the matching packages"});this.virtuals=ge.Boolean("--virtuals",!1,{description:"Print each instance of the virtual packages"});this.json=ge.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.patterns=ge.Rest()}static{this.paths=[["info"]]}static{this.usage=ot.Usage({description:"see information related to packages",details:"\n This command prints various information related to the specified packages, accepting glob patterns.\n\n By default, if the locator reference is missing, Yarn will default to print the information about all the matching direct dependencies of the package for the active workspace. To instead print all versions of the package that are direct dependencies of any of your workspaces, use the `-A,--all` flag. Adding the `-R,--recursive` flag will also report transitive dependencies.\n\n Some fields will be hidden by default in order to keep the output readable, but can be selectively displayed by using additional options (`--dependents`, `--manifest`, `--virtuals`, ...) described in the option descriptions.\n\n Note that this command will only print the information directly related to the selected packages - if you wish to know why the package is there in the first place, use `yarn why` which will do just that (it also provides a `-R,--recursive` flag that may be of some help).\n ",examples:[["Show information about Lodash","$0 info lodash"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s,workspace:a}=await Tt.find(r,this.context.cwd),n=await Kr.find(r);if(!a&&!this.all)throw new ar(s.cwd,this.context.cwd);await s.restoreInstallState();let c=new Set(this.extra);this.cache&&c.add("cache"),this.dependents&&c.add("dependents"),this.manifest&&c.add("manifest");let f=(ie,{recursive:ue})=>{let le=ie.anchoredLocator.locatorHash,me=new Map,pe=[le];for(;pe.length>0;){let Be=pe.shift();if(me.has(Be))continue;let Ce=s.storedPackages.get(Be);if(typeof Ce>"u")throw new Error("Assertion failed: Expected the package to be registered");if(me.set(Be,Ce),G.isVirtualLocator(Ce)&&pe.push(G.devirtualizeLocator(Ce).locatorHash),!(!ue&&Be!==le))for(let g of Ce.dependencies.values()){let we=s.storedResolutions.get(g.descriptorHash);if(typeof we>"u")throw new Error("Assertion failed: Expected the resolution to be registered");pe.push(we)}}return me.values()},p=({recursive:ie})=>{let ue=new Map;for(let le of s.workspaces)for(let me of f(le,{recursive:ie}))ue.set(me.locatorHash,me);return ue.values()},h=({all:ie,recursive:ue})=>ie&&ue?s.storedPackages.values():ie?p({recursive:ue}):f(a,{recursive:ue}),E=({all:ie,recursive:ue})=>{let le=h({all:ie,recursive:ue}),me=this.patterns.map(Ce=>{let g=G.parseLocator(Ce),we=Eye.default.makeRe(G.stringifyIdent(g)),ye=G.isVirtualLocator(g),Ae=ye?G.devirtualizeLocator(g):g;return se=>{let Z=G.stringifyIdent(se);if(!we.test(Z))return!1;if(g.reference==="unknown")return!0;let De=G.isVirtualLocator(se),Re=De?G.devirtualizeLocator(se):se;return!(ye&&De&&g.reference!==se.reference||Ae.reference!==Re.reference)}}),pe=je.sortMap([...le],Ce=>G.stringifyLocator(Ce));return{selection:pe.filter(Ce=>me.length===0||me.some(g=>g(Ce))),sortedLookup:pe}},{selection:C,sortedLookup:S}=E({all:this.all,recursive:this.recursive});if(C.length===0)throw new nt("No package matched your request");let P=new Map;if(this.dependents)for(let ie of S)for(let ue of ie.dependencies.values()){let le=s.storedResolutions.get(ue.descriptorHash);if(typeof le>"u")throw new Error("Assertion failed: Expected the resolution to be registered");je.getArrayWithDefault(P,le).push(ie)}let I=new Map;for(let ie of S){if(!G.isVirtualLocator(ie))continue;let ue=G.devirtualizeLocator(ie);je.getArrayWithDefault(I,ue.locatorHash).push(ie)}let R={},N={children:R},U=r.makeFetcher(),W={project:s,fetcher:U,cache:n,checksums:s.storedChecksum Line truncated
This command simply runs Node. It also makes sure to call it in a way that's compatible with the current project (for example, on PnP projects the environment will be setup in such a way that PnP will be correctly injected into the environment).
The Node process will use the exact same version of Node as the one used to run Yarn itself, which might be a good way to ensure that your commands always use a consistent Node version.
`,examples:[["Run a Node script","$0 node ./my-script.js"]]})}async execute(){return this.cli.run(["exec","node",...this.args])}};Ge();Yt();var SC=class extends ft{constructor(){super(...arguments);this.json=ge.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"})}static{this.paths=[["plugin","check"]]}static{this.usage=ot.Usage({category:"Plugin-related commands",description:"find all third-party plugins that differ from their own spec",details:`
Check only the plugins from https.
If this command detects any plugin differences in the CI environment, it will throw an error.
`,examples:[["find all third-party plugins that differ from their own spec","$0 plugin check"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),s=await ze.findRcFiles(this.context.cwd);return(await Ot.start({configuration:r,json:this.json,stdout:this.context.stdout},async n=>{for(let c of s)if(c.data?.plugins)for(let f of c.data.plugins){if(!f.checksum||!f.spec.match(/^https?:/))continue;let p=await nn.get(f.spec,{configuration:r}),h=Nn.makeHash(p);if(f.checksum===h)continue;let E=he.pretty(r,f.path,he.Type.PATH),C=he.pretty(r,f.spec,he.Type.URL),S=`${E} is different from the file provided by ${C}`;n.reportJson({...f,newChecksum:h}),n.reportError(0,S)}})).exitCode()}};Ge();Ge();Dt();Yt();var vye=Ie("os");Ge();Dt();Yt();var Iye=Ie("os");Ge();wc();Yt();var ect="https://raw.githubusercontent.com/yarnpkg/berry/master/plugins.yml";async function Sm(t,e){let r=await nn.get(ect,{configuration:t}),s=ls(r.toString());return Object.fromEntries(Object.entries(s).filter(([a,n])=>!e||Fr.satisfiesWithPrereleases(e,n.range??"<4.0.0-rc.1")))}var DC=class extends ft{constructor(){super(...arguments);this.json=ge.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"})}static{this.paths=[["plugin","list"]]}static{this.usage=ot.Usage({category:"Plugin-related commands",description:"list the available official plugins",details:"\n This command prints the plugins available directly from the Yarn repository. Only those plugins can be referenced by name in `yarn plugin import`.\n ",examples:[["List the official plugins","$0 plugin list"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins);return(await Ot.start({configuration:r,json:this.json,stdout:this.context.stdout},async a=>{let n=await Sm(r,fn);for(let[c,{experimental:f,...p}]of Object.entries(n)){let h=c;f&&(h+=" [experimental]"),a.reportJson({name:c,experimental:f,...p}),a.reportInfo(null,h)}})).exitCode()}};var tct=/^[0-9]+$/,rct=process.platform==="win32";function Cye(t){return tct.test(t)?`pull/${t}/head`:t}var nct=({repository:t,branch:e},r)=>[["git","init",fe.fromPortablePath(r)],["git","remote","add","origin",t],["git","fetch","origin","--depth=1",Cye(e)],["git","reset","--hard","FETCH_HEAD"]],ict=({branch:t})=>[["git","fetch","origin","--depth=1",Cye(t),"--force"],["git","reset","--hard","FETCH_HEAD"],["git","clean","-dfx","-e","packages/yarnpkg-cli/bundles"]],sct=({plugins:t,noMinify:e},r,s)=>[["yarn","build:cli",...new Array().concat(...t.map(a=>["--plugin",J.resolve(s,a)])),...e?["--no-minify"]:[],"|"],[rct?"move":"mv","packages/yarnpkg-cli/bundles/yarn.js",fe.fromPortablePath(r),"|"]],bC=class extends ft{constructor(){super(...arguments);this.installPath=ge.String("--path",{description:"The path where the repository should be cloned to"});this.repository=ge.String("--repository","https://github.com/yarnpkg/berry.git",{description:"The repository that should be cloned"});this.branch=ge.String("--branch","master",{description:"The branch of the repository that should be cloned"});this.plugins=ge.Array("--plugin",[],{description:"An array of additional plugins that should be included in the bundle"});this.dryRun=ge.Boolean("-n,--dry-run",!1,{description:"If set, the bundle will be built but not added to the project"});this.noMinify=ge.Boolean("--no-minify",!1,{description:"Build a bundle for development (debugging) - non-minified and non-mangled"});this.force=ge.Boolean("-f,--force",!1,{description:"Always clone the repository instead of trying to fetch the latest commits"});this.skipPlugins=ge.Boolean("--skip-plugins",!1,{description:"Skip updating the contrib plugins"})}static{this.paths=[["set","version","from","sources"]]}static{this.usage=ot.Usage({description:"build Yarn from master",details:`
This command will clone the Yarn repository into a temporary folder, then build it. The resulting bundle will then be copied into the local project.
By default, it also updates all contrib plugins to the same commit the bundle is built from. This behavior can be disabled by using the \`--skip-plugins\` flag.
`,examples:[["Build Yarn from master","$0 set version from sources"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s}=await Tt.find(r,this.context.cwd),a=typeof this.installPath<"u"?J.resolve(this.context.cwd,fe.toPortablePath(this.installPath)):J.resolve(fe.toPortablePath((0,Iye.tmpdir)()),"yarnpkg-sources",Nn.makeHash(this.repository).slice(0,6));return(await Ot.start({configuration:r,stdout:this.context.stdout},async c=>{await $5(this,{configuration:r,report:c,target:a}),c.reportSeparator(),c.reportInfo(0,"Building a fresh bundle"),c.reportSeparator();let f=await qr.execvp("git",["rev-parse","--short","HEAD"],{cwd:a,strict:!0}),p=J.join(a,`packages/yarnpkg-cli/bundles/yarn-${f.stdout.trim()}.js`);ce.existsSync(p)||(await $v(sct(this,p,a),{configuration:r,context:this.context,target:a}),c.reportSeparator());let h=await ce.readFilePromise(p);if(!this.dryRun){let{bundleVersion:E}=await X5(r,null,async()=>h,{report:c});this.skipPlugins||await oct(this,E,{project:s,report:c,target:a})}})).exitCode()}};async function $v(t,{configuration:e,context:r,target:s}){for(let[a,...n]of t){let c=n[n.length-1]==="|";if(c&&n.pop(),c)await qr.pipevp(a,n,{cwd:s,stdin:r.stdin,stdout:r.stdout,stderr:r.stderr,strict:!0});else{r.stdout.write(`${he.pretty(e,` $ ${[a,...n].join(" ")}`,"grey")}
`);try{await qr.execvp(a,n,{cwd:s,strict:!0})}catch(f){throw r.stdout.write(f.stdout||f.stack),f}}}}async function $5(t,{configuration:e,report:r,target:s}){let a=!1;if(!t.force&&ce.existsSync(J.join(s,".git"))){r.reportInfo(0,"Fetching the latest commits"),r.reportSeparator();try{await $v(ict(t),{configuration:e,context:t.context,target:s}),a=!0}catch{r.reportSeparator(),r.reportWarning(0,"Repository update failed; we'll try to regenerate it")}}a||(r.reportInfo(0,"Cloning the remote repository"),r.reportSeparator(),await ce.removePromise(s),await ce.mkdirPromise(s,{recursive:!0}),await $v(nct(t,s),{configuration:e,context:t.context,target:s}))}async function oct(t,e,{project:r,report:s,target:a}){let n=await Sm(r.configuration,e),c=new Set(Object.keys(n));for(let f of r.configuration.plugins.keys())c.has(f)&&await eq(f,t,{project:r,report:s,target:a})}Ge();Ge();Dt();Yt();var wye=ut(Ai()),Bye=Ie("vm");var PC=class extends ft{constructor(){super(...arguments);this.name=ge.String();this.checksum=ge.Boolean("--checksum",!0,{description:"Whether to care if this plugin is modified"})}static{this.paths=[["plugin","import"]]}static{this.usage=ot.Usage({category:"Plugin-related commands",description:"download a plugin",details:`
This command downloads the specified plugin from its remote location and updates the configuration to reference it in further CLI invocations.
Three types of plugin references are accepted:
- If the plugin is stored within the Yarn repository, it can be referenced by name.
- Third-party plugins can be referenced directly through their public urls.
- Local plugins can be referenced by their path on the disk.
If the \`--no-checksum\` option is set, Yarn will no longer care if the plugin is modified.
Plugins cannot be downloaded from the npm registry, and aren't allowed to have dependencies (they need to be bundled into a single file, possibly thanks to the \`@yarnpkg/builder\` package).
`,examples:[['Download and activate the "@yarnpkg/plugin-exec" plugin',"$0 plugin import @yarnpkg/plugin-exec"],['Download and activate the "@yarnpkg/plugin-exec" plugin (shorthand)',"$0 plugin import exec"],["Download and activate a community plugin","$0 plugin import https://example.org/path/to/plugin.js"],["Activate a local plugin","$0 plugin import ./path/to/plugin.js"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins);return(await Ot.start({configuration:r,stdout:this.context.stdout},async a=>{let{project:n}=await Tt.find(r,this.context.cwd),c,f;if(this.name.match(/^\.{0,2}[\\/]/)||fe.isAbsolute(this.name)){let p=J.resolve(this.context.cwd,fe.toPortablePath(this.name));a.reportInfo(0,`Reading ${he.pretty(r,p,he.Type.PATH)}`),c=J.relative(n.cwd,p),f=await ce.readFilePromise(p)}else{let p;if(this.name.match(/^https?:/)){try{new URL(this.name)}catch{throw new jt(52,`Plugin specifier "${this.name}" is neither a plugin name nor a valid url`)}c=this.name,p=this.name}else{let h=G.parseLocator(this.name.replace(/^((@yarnpkg\/)?plugin-)?/,"@yarnpkg/plugin-"));if(h.reference!=="unknown"&&!wye.default.valid(h.reference))throw new jt(0,"Official plugins only accept strict version references. Use an explicit URL if you wish to download them from another location.");let E=G.stringifyIdent(h),C=await Sm(r,fn);if(!Object.hasOwn(C,E)){let S=`Couldn't find a plugin named ${G.prettyIdent(r,h)} on the remote registry.
`;throw r.plugins.has(E)?S+=`A plugin named ${G.prettyIdent(r,h)} is already installed; possibly attempting to import a built-in plugin.`:S+=`Note that only the plugins referenced on our website (${he.pretty(r,"https://github.com/yarnpkg/berry/blob/master/plugins.yml",he.Type.URL)}) can be referenced by their name; any other plugin will have to be referenced through its public url (for example ${he.pretty(r,"https://github.com/yarnpkg/berry/raw/master/packages/plugin-typescript/bin/%40yarnpkg/plugin-typescript.js",he.Type.URL)}).`,new jt(51,S)}c=E,p=C[E].url,h.reference!=="unknown"?p=p.replace(/\/master\//,`/${E}/${h.reference}/`):fn!==null&&(p=p.replace(/\/master\//,`/@yarnpkg/cli/${fn}/`))}a.reportInfo(0,`Downloading ${he.pretty(r,p,"green")}`),f=await nn.get(p,{configuration:r})}await tq(c,f,{checksum:this.checksum,project:n,report:a})})).exitCode()}};async function tq(t,e,{checksum:r=!0,project:s,report:a}){let{configuration:n}=s,c={},f={exports:c};(0,Bye.runInNewContext)(e.toString(),{module:f,exports:c});let h=`.yarn/plugins/${f.exports.name}.cjs`,E=J.resolve(s.cwd,h);a.reportInfo(0,`Saving the new plugin in ${he.pretty(n,h,"magenta")}`),await ce.mkdirPromise(J.dirname(E),{recursive:!0}),await ce.writeFilePromise(E,e);let C={path:h,spec:t};r&&(C.checksum=Nn.makeHash(e)),await ze.addPlugin(s.cwd,[C])}var act=({pluginName:t,noMinify:e},r)=>[["yarn",`build:${t}`,...e?["--no-minify"]:[],"|"]],xC=class extends ft{constructor(){super(...arguments);this.installPath=ge.String("--path",{description:"The path where the repository should be cloned to"});this.repository=ge.String("--repository","https://github.com/yarnpkg/berry.git",{description:"The repository that should be cloned"});this.branch=ge.String("--branch","master",{description:"The branch of the repository that should be cloned"});this.noMinify=ge.Boolean("--no-minify",!1,{description:"Build a plugin for development (debugging) - non-minified and non-mangled"});this.force=ge.Boolean("-f,--force",!1,{description:"Always clone the repository instead of trying to fetch the latest commits"});this.name=ge.String()}static{this.paths=[["plugin","import","from","sources"]]}static{this.usage=ot.Usage({category:"Plugin-related commands",description:"build a plugin from sources",details:`
This command clones the Yarn repository into a temporary folder, builds the specified contrib plugin and updates the configuration to reference it in further CLI invocations.
The plugins can be referenced by their short name if sourced from the official Yarn repository.
`,examples:[['Build and activate the "@yarnpkg/plugin-exec" plugin',"$0 plugin import from sources @yarnpkg/plugin-exec"],['Build and activate the "@yarnpkg/plugin-exec" plugin (shorthand)',"$0 plugin import from sources exec"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),s=typeof this.installPath<"u"?J.resolve(this.context.cwd,fe.toPortablePath(this.installPath)):J.resolve(fe.toPortablePath((0,vye.tmpdir)()),"yarnpkg-sources",Nn.makeHash(this.repository).slice(0,6));return(await Ot.start({configuration:r,stdout:this.context.stdout},async n=>{let{project:c}=await Tt.find(r,this.context.cwd),f=G.parseIdent(this.name.replace(/^((@yarnpkg\/)?plugin-)?/,"@yarnpkg/plugin-")),p=G.stringifyIdent(f),h=await Sm(r,fn);if(!Object.hasOwn(h,p))throw new jt(51,`Couldn't find a plugin named "${p}" on the remote registry. Note that only the plugins referenced on our website (https://github.com/yarnpkg/berry/blob/master/plugins.yml) can be built and imported from sources.`);let E=p;await $5(this,{configuration:r,report:n,target:s}),await eq(E,this,{project:c,report:n,target:s})})).exitCode()}};async function eq(t,{context:e,noMinify:r},{project:s,report:a,target:n}){let c=t.replace(/@yarnpkg\//,""),{configuration:f}=s;a.reportSeparator(),a.reportInfo(0,`Building a fresh ${c}`),a.reportSeparator(),await $v(act({pluginName:c,noMinify:r},n),{configuration:f,context:e,target:n}),a.reportSeparator();let p=J.resolve(n,`packages/${c}/bundles/${t}.js`),h=await ce.readFilePromise(p);await tq(t,h,{project:s,report:a})}Ge();Dt();Yt();var kC=class extends ft{constructor(){super(...arguments);this.name=ge.String()}static{this.paths=[["plugin","remove"]]}static{this.usage=ot.Usage({category:"Plugin-related commands",description:"remove a plugin",details:`
This command deletes the specified plugin from the .yarn/plugins folder and removes it from the configuration.
**Note:** The plugins have to be referenced by their name property, which can be obtained using the \`yarn plugin runtime\` command. Shorthands are not allowed.
`,examples:[["Remove a plugin imported from the Yarn repository","$0 plugin remove @yarnpkg/plugin-typescript"],["Remove a plugin imported from a local file","$0 plugin remove my-local-plugin"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s}=await Tt.find(r,this.context.cwd);return(await Ot.start({configuration:r,stdout:this.context.stdout},async n=>{let c=this.name,f=G.parseIdent(c);if(!r.plugins.has(c))throw new nt(`${G.prettyIdent(r,f)} isn't referenced by the current configuration`);let p=`.yarn/plugins/${c}.cjs`,h=J.resolve(s.cwd,p);ce.existsSync(h)&&(n.reportInfo(0,`Removing ${he.pretty(r,p,he.Type.PATH)}...`),await ce.removePromise(h)),n.reportInfo(0,"Updating the configuration..."),await ze.updateConfiguration(s.cwd,{plugins:E=>{if(!Array.isArray(E))return E;let C=E.filter(S=>S.path!==p);return C.length===0?ze.deleteProperty:C.length===E.length?E:C}})})).exitCode()}};Ge();Yt();var QC=class extends ft{constructor(){super(...arguments);this.json=ge.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"})}static{this.paths=[["plugin","runtime"]]}static{this.usage=ot.Usage({category:"Plugin-related commands",description:"list the active plugins",details:`
This command prints the currently active plugins. Will be displayed both builtin plugins and external plugins.
`,examples:[["List the currently active plugins","$0 plugin runtime"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins);return(await Ot.start({configuration:r,json:this.json,stdout:this.context.stdout},async a=>{for(let n of r.plugins.keys()){let c=this.context.plugins.plugins.has(n),f=n;c&&(f+=" [builtin]"),a.reportJson({name:n,builtin:c}),a.reportInfo(null,`${f}`)}})).exitCode()}};Ge();Ge();Yt();var TC=class extends ft{constructor(){super(...arguments);this.idents=ge.Rest()}static{this.paths=[["rebuild"]]}static{this.usage=ot.Usage({description:"rebuild the project's native packages",details:`
This command will automatically cause Yarn to forget about previous compilations of the given packages and to run them again.
Note that while Yarn forgets the compilation, the previous artifacts aren't erased from the filesystem and may affect the next builds (in good or bad). To avoid this, you may remove the .yarn/unplugged folder, or any other relevant location where packages might have been stored (Yarn may offer a way to do that automatically in the future).
By default all packages will be rebuilt, but you can filter the list by specifying the names of the packages you want to clear from memory.
`,examples:[["Rebuild all packages","$0 rebuild"],["Rebuild fsevents only","$0 rebuild fsevents"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s,workspace:a}=await Tt.find(r,this.context.cwd),n=await Kr.find(r);if(!a)throw new ar(s.cwd,this.context.cwd);let c=new Set;for(let f of this.idents)c.add(G.parseIdent(f).identHash);if(await s.restoreInstallState({restoreResolutions:!1}),await s.resolveEverything({cache:n,report:new ki}),c.size>0)for(let f of s.storedPackages.values())c.has(f.identHash)&&(s.storedBuildState.delete(f.locatorHash),s.skippedBuilds.delete(f.locatorHash));else s.storedBuildState.clear(),s.skippedBuilds.clear();return await s.installWithNewReport({stdout:this.context.stdout,quiet:this.context.quiet},{cache:n})}};Ge();Ge();Ge();Yt();var rq=ut(Go());Ul();var RC=class extends ft{constructor(){super(...arguments);this.all=ge.Boolean("-A,--all",!1,{description:"Apply the operation to all workspaces from the current project"});this.mode=ge.String("--mode",{description:"Change what artifacts installs generate",validator:fo($l)});this.patterns=ge.Rest()}static{this.paths=[["remove"]]}static{this.usage=ot.Usage({description:"remove dependencies from the project",details:`
This command will remove the packages matching the specified patterns from the current workspace.
If the \`--mode=<mode>\` option is set, Yarn will change which artifacts are generated. The modes currently supported are:
- \`skip-build\` will not run the build scripts at all. Note that this is different from setting \`enableScripts\` to false because the latter will disable build scripts, and thus affect the content of the artifacts generated on disk, whereas the former will just disable the build step - but not the scripts themselves, which just won't run.
- \`update-lockfile\` will skip the link step altogether, and only fetch packages that are missing from the lockfile (or that have no associated checksums). This mode is typically used by tools like Renovate or Dependabot to keep a lockfile up-to-date without incurring the full install cost.
This command accepts glob patterns as arguments (if valid Idents and supported by [micromatch](https://github.com/micromatch/micromatch)). Make sure to escape the patterns, to prevent your own shell from trying to expand them.
`,examples:[["Remove a dependency from the current project","$0 remove lodash"],["Remove a dependency from all workspaces at once","$0 remove lodash --all"],["Remove all dependencies starting with `eslint-`","$0 remove 'eslint-*'"],["Remove all dependencies with the `@babel` scope","$0 remove '@babel/*'"],["Remove all dependencies matching `react-dom` or `react-helmet`","$0 remove 'react-{dom,helmet}'"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s,workspace:a}=await Tt.find(r,this.context.cwd),n=await Kr.find(r);if(!a)throw new ar(s.cwd,this.context.cwd);await s.restoreInstallState({restoreResolutions:!1});let c=this.all?s.workspaces:[a],f=["dependencies","devDependencies","peerDependencies"],p=[],h=!1,E=[];for(let I of this.patterns){let R=!1,N=G.parseIdent(I);for(let U of c){let W=[...U.manifest.peerDependenciesMeta.keys()];for(let ee of(0,rq.default)(W,I))U.manifest.peerDependenciesMeta.delete(ee),h=!0,R=!0;for(let ee of f){let ie=U.manifest.getForScope(ee),ue=[...ie.values()].map(le=>G.stringifyIdent(le));for(let le of(0,rq.default)(ue,G.stringifyIdent(N))){let{identHash:me}=G.parseIdent(le),pe=ie.get(me);if(typeof pe>"u")throw new Error("Assertion failed: Expected the descriptor to be registered");U.manifest[ee].delete(me),E.push([U,ee,pe]),h=!0,R=!0}}}R||p.push(I)}let C=p.length>1?"Patterns":"Pattern",S=p.length>1?"don't":"doesn't",P=this.all?"any":"this";if(p.length>0)throw new nt(`${C} ${he.prettyList(r,p,he.Type.CODE)} ${S} match any packages referenced by ${P} workspace`);return h?(await r.triggerMultipleHooks(I=>I.afterWorkspaceDependencyRemoval,E),await s.installWithNewReport({stdout:this.context.stdout},{cache:n,mode:this.mode})):0}};Ge();Ge();Yt();var Sye=Ie("util"),FC=class extends ft{constructor(){super(...arguments);this.json=ge.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"})}static{this.paths=[["run"]]}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s,workspace:a}=await Tt.find(r,this.context.cwd);if(!a)throw new ar(s.cwd,this.context.cwd);return(await Ot.start({configuration:r,stdout:this.context.stdout,json:this.json},async c=>{let f=a.manifest.scripts,p=je.sortMap(f.keys(),C=>C),h={breakLength:1/0,colors:r.get("enableColors"),maxArrayLength:2},E=p.reduce((C,S)=>Math.max(C,S.length),0);for(let[C,S]of f.entries())c.reportInfo(null,`${C.padEnd(E," ")} ${(0,Sye.inspect)(S,h)}`),c.reportJson({name:C,script:S})})).exitCode()}};Ge();Ge();Yt();var NC=class extends ft{constructor(){super(...arguments);this.inspect=ge.String("--inspect",!1,{tolerateBoolean:!0,description:"Forwarded to the underlying Node process when executing a binary"});this.inspectBrk=ge.String("--inspect-brk",!1,{tolerateBoolean:!0,description:"Forwarded to the underlying Node process when executing a binary"});this.topLevel=ge.Boolean("-T,--top-level",!1,{description:"Check the root workspace for scripts and/or binaries instead of the current one"});this.binariesOnly=ge.Boolean("-B,--binaries-only",!1,{description:"Ignore any user defined scripts and only check for binaries"});this.require=ge.String("--require",{description:"Forwarded to the underlying Node process when executing a binary"});this.silent=ge.Boolean("--silent",{hidden:!0});this.scriptName=ge.String();this.args=ge.Proxy()}static{this.paths=[["run"]]}static{this.usage=ot.Usage({description:"run a script defined in the package.json",details:`
This command will run a tool. The exact tool that will be executed will depend on the current state of your workspace:
- If the \`scripts\` field from your local package.json contains a matching script name, its definition will get executed.
- Otherwise, if one of the local workspace's dependencies exposes a binary with a matching name, this binary will get executed.
- Otherwise, if the specified name contains a colon character and if one of the workspaces in the project contains exactly one script with a matching name, then this script will get executed.
Whatever happens, the cwd of the spawned process will be the workspace that declares the script (which makes it possible to call commands cross-workspaces using the third syntax).
`,examples:[["Run the tests from the local workspace","$0 run test"],['Same thing, but without the "run" keyword',"$0 test"],["Inspect Webpack while running","$0 run --inspect-brk webpack"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s,workspace:a,locator:n}=await Tt.find(r,this.context.cwd);await s.restoreInstallState();let c=this.topLevel?s.topLevelWorkspace.anchoredLocator:n;if(!this.binariesOnly&&await In.hasPackageScript(c,this.scriptName,{project:s}))return await In.executePackageScript(c,this.scriptName,this.args,{project:s,stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr});let f=await In.getPackageAccessibleBinaries(c,{project:s});if(f.get(this.scriptName)){let h=[];return this.inspect&&(typeof this.inspect=="string"?h.push(`--inspect=${this.inspect}`):h.push("--inspect")),this.inspectBrk&&(typeof this.inspectBrk=="string"?h.push(`--inspect-brk=${this.inspectBrk}`):h.push("--inspect-brk")),this.require&&h.push(`--require=${this.require}`),await In.executePackageAccessibleBinary(c,this.scriptName,this.args,{cwd:this.context.cwd,project:s,stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr,nodeArgs:h,packageAccessibleBinaries:f})}if(!this.topLevel&&!this.binariesOnly&&a&&this.scriptName.includes(":")){let E=(await Promise.all(s.workspaces.map(async C=>C.manifest.scripts.has(this.scriptName)?C:null))).filter(C=>C!==null);if(E.length===1)return await In.executeWorkspaceScript(E[0],this.scriptName,this.args,{stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr})}if(this.topLevel)throw this.scriptName==="node-gyp"?new nt(`Couldn't find a script name "${this.scriptName}" in the top-level (used by ${G.prettyLocator(r,n)}). This typically happens because some package depends on "node-gyp" to build itself, but didn't list it in their dependencies. To fix that, please run "yarn add node-gyp" into your top-level workspace. You also can open an issue on the repository of the specified package to suggest them to use an optional peer dependency.`):new nt(`Couldn't find a script name "${this.scriptName}" in the top-level (used by ${G.prettyLocator(r,n)}).`);{if(this.scriptName==="global")throw new nt("The 'yarn global' commands have been removed in 2.x - consider using 'yarn dlx' or a third-party plugin instead");let h=[this.scriptName].concat(this.args);for(let[E,C]of $I)for(let S of C)if(h.length>=S.length&&JSON.stringify(h.slice(0,S.length))===JSON.stringify(S))throw new nt(`Couldn't find a script named "${this.scriptName}", but a matching command can be found in the ${E} plugin. You can install it with "yarn plugin import ${E}".`);throw new nt(`Couldn't find a script named "${this.scriptName}".`)}}};Ge();Ge();Yt();var OC=class extends ft{constructor(){super(...arguments);this.descriptor=ge.String();this.resolution=ge.String()}static{this.paths=[["set","resolution"]]}static{this.usage=ot.Usage({description:"enforce a package resolution",details:'\n This command updates the resolution table so that `descriptor` is resolved by `resolution`.\n\n Note that by default this command only affect the current resolution table - meaning that this "manual override" will disappear if you remove the lockfile, or if the package disappear from the table. If you wish to make the enforced resolution persist whatever happens, edit the `resolutions` field in your top-level manifest.\n\n Note that no attempt is made at validating that `resolution` is a valid resolution entry for `descriptor`.\n ',examples:[["Force all instances of lodash@npm:^1.2.3 to resolve to 1.5.0","$0 set resolution lodash@npm:^1.2.3 npm:1.5.0"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s,workspace:a}=await Tt.find(r,this.context.cwd),n=await Kr.find(r);if(await s.restoreInstallState({restoreResolutions:!1}),!a)throw new ar(s.cwd,this.context.cwd);let c=G.parseDescriptor(this.descriptor,!0),f=G.makeDescriptor(c,this.resolution);return s.storedDescriptors.set(c.descriptorHash,c),s.storedDescriptors.set(f.descriptorHash,f),s.resolutionAliases.set(c.descriptorHash,f.descriptorHash),await s.installWithNewReport({stdout:this.context.stdout},{cache:n})}};Ge();Dt();Yt();var Dye=ut(Go()),LC=class extends ft{constructor(){super(...arguments);this.all=ge.Boolean("-A,--all",!1,{description:"Unlink all workspaces belonging to the target project from the current one"});this.leadingArguments=ge.Rest()}static{this.paths=[["unlink"]]}static{this.usage=ot.Usage({description:"disconnect the local project from another one",details:`
This command will remove any resolutions in the project-level manifest that would have been added via a yarn link with similar arguments.
`,examples:[["Unregister a remote workspace in the current project","$0 unlink ~/ts-loader"],["Unregister all workspaces from a remote project in the current project","$0 unlink ~/jest --all"],["Unregister all previously linked workspaces","$0 unlink --all"],["Unregister all workspaces matching a glob","$0 unlink '@babel/*' 'pkg-{a,b}'"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s,workspace:a}=await Tt.find(r,this.context.cwd),n=await Kr.find(r);if(!a)throw new ar(s.cwd,this.context.cwd);let c=s.topLevelWorkspace,f=new Set;if(this.leadingArguments.length===0&&this.all)for(let{pattern:p,reference:h}of c.manifest.resolutions)h.startsWith("portal:")&&f.add(p.descriptor.fullName);if(this.leadingArguments.length>0)for(let p of this.leadingArguments){let h=J.resolve(this.context.cwd,fe.toPortablePath(p));if(je.isPathLike(p)){let E=await ze.find(h,this.context.plugins,{useRc:!1,strict:!1}),{project:C,workspace:S}=await Tt.find(E,h);if(!S)throw new ar(C.cwd,h);if(this.all){for(let P of C.workspaces)P.manifest.name&&f.add(G.stringifyIdent(P.anchoredLocator));if(f.size===0)throw new nt("No workspace found to be unlinked in the target project")}else{if(!S.manifest.name)throw new nt("The target workspace doesn't have a name and thus cannot be unlinked");f.add(G.stringifyIdent(S.anchoredLocator))}}else{let E=[...c.manifest.resolutions.map(({pattern:C})=>C.descriptor.fullName)];for(let C of(0,Dye.default)(E,p))f.add(C)}}return c.manifest.resolutions=c.manifest.resolutions.filter(({pattern:p})=>!f.has(p.descriptor.fullName)),await s.installWithNewReport({stdout:this.context.stdout,quiet:this.context.quiet},{cache:n})}};Ge();Ge();Ge();Yt();var bye=ut(Vv()),nq=ut(Go());Ul();var MC=class extends ft{constructor(){super(...arguments);this.interactive=ge.Boolean("-i,--interactive",{description:"Offer various choices, depending on the detected upgrade paths"});this.fixed=ge.Boolean("-F,--fixed",!1,{description:"Store dependency tags as-is instead of resolving them"});this.exact=ge.Boolean("-E,--exact",!1,{description:"Don't use any semver modifier on the resolved range"});this.tilde=ge.Boolean("-T,--tilde",!1,{description:"Use the `~` semver modifier on the resolved range"});this.caret=ge.Boolean("-C,--caret",!1,{description:"Use the `^` semver modifier on the resolved range"});this.recursive=ge.Boolean("-R,--recursive",!1,{description:"Resolve again ALL resolutions for those packages"});this.mode=ge.String("--mode",{description:"Change what artifacts installs generate",validator:fo($l)});this.patterns=ge.Rest()}static{this.paths=[["up"]]}static{this.usage=ot.Usage({description:"upgrade dependencies across the project",details:"\n This command upgrades the packages matching the list of specified patterns to their latest available version across the whole project (regardless of whether they're part of `dependencies` or `devDependencies` - `peerDependencies` won't be affected). This is a project-wide command: all workspaces will be upgraded in the process.\n\n If `-R,--recursive` is set the command will change behavior and no other switch will be allowed. When operating under this mode `yarn up` will force all ranges matching the selected packages to be resolved again (often to the highest available versions) before being stored in the lockfile. It however won't touch your manifests anymore, so depending on your needs you might want to run both `yarn up` and `yarn up -R` to cover all bases.\n\n If `-i,--interactive` is set (or if the `preferInteractive` settings is toggled on) the command will offer various choices, depending on the detected upgrade paths. Some upgrades require this flag in order to resolve ambiguities.\n\n The, `-C,--caret`, `-E,--exact` and `-T,--tilde` options have the same meaning as in the `add` command (they change the modifier used when the range is missing or a tag, and are ignored when the range is explicitly set).\n\n If the `--mode=<mode>` option is set, Yarn will change which artifacts are generated. The modes currently supported are:\n\n - `skip-build` will not run the build scripts at all. Note that this is different from setting `enableScripts` to false because the latter will disable build scripts, and thus affect the content of the artifacts generated on disk, whereas the former will just disable the build step - but not the scripts themselves, which just won't run.\n\n - `update-lockfile` will skip the link step altogether, and only fetch packages that are missing from the lockfile (or that have no associated checksums). This mode is typically used by tools like Renovate or Dependabot to keep a lockfile up-to-date without incurring the full install cost.\n\n Generally you can see `yarn up` as a counterpart to what was `yarn upgrade --latest` in Yarn 1 (ie it ignores the ranges previously listed in your manifests), but unlike `yarn upgrade` which only upgraded dependencies in the current workspace, `yarn up`Line truncated
${le}`):N.reportError(27,`${G.prettyDescriptor(r,U)} can't be resolved to a satisfying range (note: network resolution has been disabled)
${le}`)}else ie.length>1&&!f&&N.reportError(27,`${G.prettyDescriptor(r,U)} has multiple possible upgrade strategies; use -i to disambiguate manually`)}});if(P.hasErrors())return P.exitCode();let I=!1,R=[];for(let[N,U,,{suggestions:W}]of S){let ee,ie=W.filter(pe=>pe.descriptor!==null),ue=ie[0].descriptor,le=ie.every(pe=>G.areDescriptorsEqual(pe.descriptor,ue));ie.length===1||le?ee=ue:(I=!0,{answer:ee}=await(0,bye.prompt)({type:"select",name:"answer",message:`Which range do you want to use in ${G.prettyWorkspace(r,N)} \u276F ${U}?`,choices:W.map(({descriptor:pe,name:Be,reason:Ce})=>pe?{name:Be,hint:Ce,descriptor:pe}:{name:Be,hint:Ce,disabled:!0}),onCancel:()=>process.exit(130),result(pe){return this.find(pe,"descriptor")},stdin:this.context.stdin,stdout:this.context.stdout}));let me=N.manifest[U].get(ee.identHash);if(typeof me>"u")throw new Error("Assertion failed: This descriptor should have a matching entry");if(me.descriptorHash!==ee.descriptorHash)N.manifest[U].set(ee.identHash,ee),R.push([N,U,me,ee]);else{let pe=r.makeResolver(),Be={project:s,resolver:pe},Ce=r.normalizeDependency(me),g=pe.bindDescriptor(Ce,N.anchoredLocator,Be);s.forgetResolution(g)}}return await r.triggerMultipleHooks(N=>N.afterWorkspaceDependencyReplacement,R),I&&this.context.stdout.write(`
`),await s.installWithNewReport({stdout:this.context.stdout},{cache:n,mode:this.mode})}};Ge();Ge();Ge();Yt();var UC=class extends ft{constructor(){super(...arguments);this.recursive=ge.Boolean("-R,--recursive",!1,{description:"List, for each workspace, what are all the paths that lead to the dependency"});this.json=ge.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.peers=ge.Boolean("--peers",!1,{description:"Also print the peer dependencies that match the specified name"});this.package=ge.String()}static{this.paths=[["why"]]}static{this.usage=ot.Usage({description:"display the reason why a package is needed",details:`
This command prints the exact reasons why a package appears in the dependency tree.
If \`-R,--recursive\` is set, the listing will go in depth and will list, for each workspaces, what are all the paths that lead to the dependency. Note that the display is somewhat optimized in that it will not print the package listing twice for a single package, so if you see a leaf named "Foo" when looking for "Bar", it means that "Foo" already got printed higher in the tree.
`,examples:[["Explain why lodash is used in your project","$0 why lodash"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s,workspace:a}=await Tt.find(r,this.context.cwd);if(!a)throw new ar(s.cwd,this.context.cwd);await s.restoreInstallState();let n=G.parseIdent(this.package).identHash,c=this.recursive?cct(s,n,{configuration:r,peers:this.peers}):lct(s,n,{configuration:r,peers:this.peers});xs.emitTree(c,{configuration:r,stdout:this.context.stdout,json:this.json,separators:1})}};function lct(t,e,{configuration:r,peers:s}){let a=je.sortMap(t.storedPackages.values(),f=>G.stringifyLocator(f)),n={},c={children:n};for(let f of a){let p={};for(let E of f.dependencies.values()){if(!s&&f.peerDependencies.has(E.identHash))continue;let C=t.storedResolutions.get(E.descriptorHash);if(!C)throw new Error("Assertion failed: The resolution should have been registered");let S=t.storedPackages.get(C);if(!S)throw new Error("Assertion failed: The package should have been registered");if(S.identHash!==e)continue;{let I=G.stringifyLocator(f);n[I]={value:[f,he.Type.LOCATOR],children:p}}let P=G.stringifyLocator(S);p[P]={value:[{descriptor:E,locator:S},he.Type.DEPENDENT]}}}return c}function cct(t,e,{configuration:r,peers:s}){let a=je.sortMap(t.workspaces,S=>G.stringifyLocator(S.anchoredLocator)),n=new Set,c=new Set,f=S=>{if(n.has(S.locatorHash))return c.has(S.locatorHash);if(n.add(S.locatorHash),S.identHash===e)return c.add(S.locatorHash),!0;let P=!1;S.identHash===e&&(P=!0);for(let I of S.dependencies.values()){if(!s&&S.peerDependencies.has(I.identHash))continue;let R=t.storedResolutions.get(I.descriptorHash);if(!R)throw new Error("Assertion failed: The resolution should have been registered");let N=t.storedPackages.get(R);if(!N)throw new Error("Assertion failed: The package should have been registered");f(N)&&(P=!0)}return P&&c.add(S.locatorHash),P};for(let S of a)f(S.anchoredPackage);let p=new Set,h={},E={children:h},C=(S,P,I)=>{if(!c.has(S.locatorHash))return;let R=I!==null?he.tuple(he.Type.DEPENDENT,{locator:S,descriptor:I}):he.tuple(he.Type.LOCATOR,S),N={},U={value:R,children:N},W=G.stringifyLocator(S);if(P[W]=U,!(I!==null&&t.tryWorkspaceByLocator(S))&&!p.has(S.locatorHash)){p.add(S.locatorHash);for(let ee of S.dependencies.values()){if(!s&&S.peerDependencies.has(ee.identHash))continue;let ie=t.storedResolutions.get(ee.descriptorHash);if(!ie)throw new Error("Assertion failed: The resolution should have been registered");let ue=t.storedPackages.get(ie);if(!ue)throw new Error("Assertion failed: The package should have been registered");C(ue,N,ee)}}};for(let S of a)C(S.anchoredPackage,h,null);return E}Ge();var pq={};Vt(pq,{GitFetcher:()=>tS,GitResolver:()=>rS,default:()=>kct,gitUtils:()=>ka});Ge();Dt();var ka={};Vt(ka,{TreeishProtocols:()=>eS,clone:()=>Aq,fetchBase:()=>Jye,fetchChangedFiles:()=>Kye,fetchChangedWorkspaces:()=>Pct,fetchRoot:()=>Vye,isGitUrl:()=>jC,lsRemote:()=>Yye,normalizeLocator:()=>bct,normalizeRepoUrl:()=>_C,resolveUrl:()=>fq,splitRepoUrl:()=>W0,validateRepoUrl:()=>uq});Ge();Dt();Yt();ql();var qye=ut(Hye()),HC=ut(Ie("querystring")),lq=ut(Ai());function aq(t,e,r){let s=t.indexOf(r);return t.lastIndexOf(e,s>-1?s:1/0)}function jye(t){try{return new URL(t)}catch{return}}function Sct(t){let e=aq(t,"@","#"),r=aq(t,":","#");return r>e&&(t=`${t.slice(0,r)}/${t.slice(r+1)}`),aq(t,":","#")===-1&&t.indexOf("//")===-1&&(t=`ssh://${t}`),t}function Gye(t){return jye(t)||jye(Sct(t))}function _C(t,{git:e=!1}={}){if(t=t.replace(/^git\+https:/,"https:"),t=t.replace(/^(?:github:|https:\/\/github\.com\/|git:\/\/github\.com\/)?(?!\.{1,2}\/)([a-zA-Z0-9._-]+)\/(?!\.{1,2}(?:#|$))([a-zA-Z0-9._-]+?)(?:\.git)?(#.*)?$/,"https://github.com/$1/$2.git$3"),t=t.replace(/^https:\/\/github\.com\/(?!\.{1,2}\/)([a-zA-Z0-9._-]+)\/(?!\.{1,2}(?:#|$))([a-zA-Z0-9._-]+?)\/tarball\/(.+)?$/,"https://github.com/$1/$2.git#$3"),e){let r=Gye(t);r&&(t=r.href),t=t.replace(/^git\+([^:]+):/,"$1:")}return t}function Wye(){return{...process.env,GIT_SSH_COMMAND:process.env.GIT_SSH_COMMAND||`${process.env.GIT_SSH||"ssh"} -o BatchMode=yes`}}var Dct=[/^ssh:/,/^git(?:\+[^:]+)?:/,/^(?:git\+)?https?:[^#]+\/[^#]+(?:\.git)(?:#.*)?$/,/^git@[^#]+\/[^#]+\.git(?:#.*)?$/,/^(?:github:|https:\/\/github\.com\/)?(?!\.{1,2}\/)([a-zA-Z._0-9-]+)\/(?!\.{1,2}(?:#|$))([a-zA-Z._0-9-]+?)(?:\.git)?(?:#.*)?$/,/^https:\/\/github\.com\/(?!\.{1,2}\/)([a-zA-Z0-9._-]+)\/(?!\.{1,2}(?:#|$))([a-zA-Z0-9._-]+?)\/tarball\/(.+)?$/],eS=(a=>(a.Commit="commit",a.Head="head",a.Tag="tag",a.Semver="semver",a))(eS||{});function jC(t){return t?Dct.some(e=>!!t.match(e)):!1}function W0(t){t=_C(t);let e=t.indexOf("#");if(e===-1)return{repo:t,treeish:{protocol:"head",request:"HEAD"},extra:{}};let r=t.slice(0,e),s=t.slice(e+1);if(s.match(/^[a-z]+=/)){let a=HC.default.parse(s);for(let[p,h]of Object.entries(a))if(typeof h!="string")throw new Error(`Assertion failed: The ${p} parameter must be a literal string`);let n=Object.values(eS).find(p=>Object.hasOwn(a,p)),[c,f]=typeof n Line truncated
This command will run a given sub-command on a single workspace.
`,examples:[["Add a package to a single workspace","yarn workspace components add -D react"],["Run build script on a single workspace","yarn workspace components run build"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s,workspace:a}=await Tt.find(r,this.context.cwd);if(!a)throw new ar(s.cwd,this.context.cwd);let n=s.workspaces,c=new Map(n.map(p=>[G.stringifyIdent(p.anchoredLocator),p])),f=c.get(this.workspaceName);if(f===void 0){let p=Array.from(c.keys()).sort();throw new nt(`Workspace '${this.workspaceName}' not found. Did you mean any of the following:
- ${p.join(`
- `)}?`)}return this.cli.run([this.commandName,...this.args],{cwd:f.cwd})}};var Qct={configuration:{enableImmutableInstalls:{description:"If true (the default on CI), prevents the install command from modifying the lockfile",type:"BOOLEAN",default:zye.isCI},defaultSemverRangePrefix:{description:"The default save prefix: '^', '~' or ''",type:"STRING",values:["^","~",""],default:"^"},preferReuse:{description:"If true, `yarn add` will attempt to reuse the most common dependency range in other workspaces.",type:"BOOLEAN",default:!1}},commands:[aC,lC,cC,uC,OC,bC,EC,GC,pC,hC,gC,dC,sC,oC,fC,AC,mC,yC,IC,CC,wC,BC,LC,vC,SC,xC,PC,kC,DC,QC,TC,RC,FC,NC,MC,UC,qC]},Tct=Qct;var yq={};Vt(yq,{default:()=>Oct});Ge();Ge();var gq="catalog:";var dq=t=>t.startsWith(gq),Rct=t=>t.range.slice(gq.length)||null,Xye=t=>t===null?"default catalog":`catalog "${t}"`,Fct=t=>t.scope?`@${t.scope}/${t.name}`:t.name,mq=(t,e,r,s)=>{let a=Rct(e),n;if(a===null)n=t.configuration.get("catalog");else try{let E=t.configuration.get("catalogs");E&&(n=E.get(a))}catch{n=void 0}if(!n||n.size===0)throw new jt(82,`${G.prettyDescriptor(t.configuration,e)}: ${Xye(a)} not found or empty`);let c=Fct(e),f=n.get(c);if(!f)throw new jt(82,`${G.prettyDescriptor(t.configuration,e)}: entry not found in ${Xye(a)}`);let p=t.configuration.normalizeDependency(G.makeDescriptor(e,f));return r.supportsDescriptor(p,s)?r.bindDescriptor(p,t.topLevelWorkspace.anchoredLocator,s):p};var Nct={configuration:{catalog:{description:"The default catalog of packages",type:"MAP",valueDefinition:{description:"The catalog of packages",type:"STRING"}},catalogs:{description:"Named catalogs of packages",type:"MAP",valueDefinition:{description:"A named catalog",type:"MAP",valueDefinition:{description:"Package version in the catalog",type:"STRING"}}}},hooks:{beforeWorkspacePacking:(t,e)=>{let r=t.project,s=r.configuration.makeResolver(),a={project:r,resolver:s,report:new ki};for(let n of Ut.allDependencies){let c=e[n];if(c)for(let[f,p]of Object.entries(c)){if(typeof p!="string"||!dq(p))continue;let h=G.parseIdent(f),E=G.makeDescriptor(h,p),C=mq(r,E,s,a),{protocol:S,source:P,params:I,selector:R}=G.parseRange(G.convertToManifestRange(C.range));S===t.project.configuration.get("defaultProtocol")&&(S=null),c[f]=G.makeRange({protocol:S,source:P,params:I,selector:R})}}},reduceDependency:async(t,e,r,s,{resolver:a,resolveOptions:n})=>dq(t.range)?mq(e,t,a,n):t}},Oct=Nct;var Bq={};Vt(Bq,{default:()=>Mct});Ge();var Qt={optional:!0},Eq=[["@tailwindcss/aspect-ratio@<0.2.1",{peerDependencies:{tailwindcss:"^2.0.2"}}],["@tailwindcss/line-clamp@<0.2.1",{peerDependencies:{tailwindcss:"^2.0.2"}}],["@fullhuman/postcss-purgecss@3.1.3 || 3.1.3-alpha.0",{peerDependencies:{postcss:"^8.0.0"}}],["@samverschueren/stream-to-observable@<0.3.1",{peerDependenciesMeta:{rxjs:Qt,zenObservable:Qt}}],["any-observable@<0.5.1",{peerDependenciesMeta:{rxjs:Qt,zenObservable:Qt}}],["@pm2/agent@<1.0.4",{dependencies:{debug:"*"}}],["debug@<4.2.0",{peerDependenciesMeta:{"supports-color":Qt}}],["got@<11",{dependencies:{"@types/responselike":"^1.0.0","@types/keyv":"^3.1.1"}}],["cacheable-lookup@<4.1.2",{dependencies:{"@types/keyv":"^3.1.1"}}],["http-link-dataloader@*",{peerDependencies:{graphql:"^0.13.1 || ^14.0.0"}}],["typescript-language-server@*",{dependencies:{"vscode-jsonrpc":"^5.0.1","vscode-languageserver-protocol":"^3.15.0"}}],["postcss-syntax@*",{peerDependenciesMeta:{"postcss-html":Qt,"postcss-jsx":Qt,"postcss-less":Qt,"postcss-markdown":Qt,"postcss-scss":Qt}}],["jss-plugin-rule-value-function@<=10.1.1",{dependencies:{"tiny-warning":"^1.0.2"}}],["ink-select-input@<4.1.0",{peerDependencies:{react:"^16.8.2"}}],["license-webpack-plugin@<2.3.18",{peerDependenciesMeta:{webpack:Qt}}],["snowpack@>=3.3.0",{dependencies:{"node-gyp":"^7.1.0"}}],["promise-inflight@*",{peerDependenciesMeta:{bluebird:Qt}}],["reactcss@*",{peerDependencies:{react:"*"}}],["react-color@<=2.19.0",{peerDependencies:{react:"*"}}],["gatsby-plugin-i18n@*",{dependencies:{ramda:"^0.24.1"}}],["useragent@^2.0.0",{dependencies:{request:"^2.88.0",yamlparser:"0.0.x",semver:"5.5.x"}}],["@apollographql/apollo-tools@<=0.5.2",{peerDependencies:{graphql:"^14.2.1 || ^15.0.0"}}],["material-table@^2.0.0",{dependencies:{"@babel/runtime":"^7.11.2"}}],["@babel/parser@*",{dependencies:{"@babel/types":"^7.8.3"}}],["fork-ts-checker-webpack-plugin@<=6.3.4",{peerDependencies:{eslint:">= 6",typescript:">= 2.7",webpack:">= 4","vue-template-compiler":"*"},peerDependenciesMeta:{eslint:Qt,"vue-template-compiler":Qt}}],["rc-animate@<=3.1.1",{peerDependencies:{react:">=16.9.0","react-dom":">=16.9.0"}}],["react-bootstrap-table2-paginator@*",{dependencies:{classnames:"^2.2.6"}}],["react-draggable@<=4.4.3",{peerDependencies:{react:">= 16.3.0","react-dom":">= 16.3.0"}}],["apollo-upload-client@<14",{peerDependencies:{graphql:"14 - 15"}}],["react-instantsearch-core@<=6.7.0",{peerDependencies:{algoliasearch:">= 3.1 < 5"}}],["react-instantsearch-dom@<=6.7.0",{dependencies:{"react-fast-compare":"^3.0.0"}}],Line truncated
This command will output all matches to the given prolog query.
`,examples:[["List all dependencies throughout the workspace","yarn constraints query 'workspace_has_dependency(_, DependencyName, _, _).'"]]})}async execute(){let{Constraints:r}=await Promise.resolve().then(()=>(lS(),aS)),s=await ze.find(this.context.cwd,this.context.plugins),{project:a}=await Tt.find(s,this.context.cwd),n=await r.find(a),c=this.query;return c.endsWith(".")||(c=`${c}.`),(await Ot.start({configuration:s,json:this.json,stdout:this.context.stdout},async p=>{for await(let h of n.query(c)){let E=Array.from(Object.entries(h)),C=E.length,S=E.reduce((P,[I])=>Math.max(P,I.length),0);for(let P=0;P<C;P++){let[I,R]=E[P];p.reportInfo(null,`${tut(P,C)}${I.padEnd(S," ")} = ${eut(R)}`)}p.reportJson(h)}})).exitCode()}};function eut(t){return typeof t!="string"?`${t}`:t.match(/^[a-zA-Z][a-zA-Z0-9_]+$/)?t:`'${t}'`}function tut(t,e){let r=t===0,s=t===e-1;return r&&s?"":r?"\u250C ":s?"\u2514 ":"\u2502 "}Ge();Yt();var XC=class extends ft{constructor(){super(...arguments);this.verbose=ge.Boolean("-v,--verbose",!1,{description:"Also print the fact database automatically compiled from the workspace manifests"})}static{this.paths=[["constraints","source"]]}static{this.usage=ot.Usage({category:"Constraints-related commands",description:"print the source code for the constraints",details:"\n This command will print the Prolog source code used by the constraints engine. Adding the `-v,--verbose` flag will print the *full* source code, including the fact database automatically compiled from the workspace manifests.\n ",examples:[["Prints the source code","yarn constraints source"],["Print the source code and the fact database","yarn constraints source -v"]]})}async execute(){let{Constraints:r}=await Promise.resolve().then(()=>(lS(),aS)),s=await ze.find(this.context.cwd,this.context.plugins),{project:a}=await Tt.find(s,this.context.cwd),n=await r.find(a);this.context.stdout.write(this.verbose?n.fullSource:n.source)}};Ge();Ge();Yt();iS();var ZC=class extends ft{constructor(){super(...arguments);this.fix=ge.Boolean("--fix",!1,{description:"Attempt to automatically fix unambiguous issues, following a multi-pass process"});this.json=ge.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"})}static{this.paths=[["constraints"]]}static{this.usage=ot.Usage({category:"Constraints-related commands",description:"check that the project constraints are met",details:`
This command will run constraints on your project and emit errors for each one that is found but isn't met. If any error is emitted the process will exit with a non-zero exit code.
If the \`--fix\` flag is used, Yarn will attempt to automatically fix the issues the best it can, following a multi-pass process (with a maximum of 10 iterations). Some ambiguous patterns cannot be autofixed, in which case you'll have to manually specify the right resolution.
For more information as to how to write constraints, please consult our dedicated page on our website: https://yarnpkg.com/features/constraints.
`,examples:[["Check that all constraints are satisfied","yarn constraints"],["Autofix all unmet constraints","yarn constraints --fix"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s}=await Tt.find(r,this.context.cwd);await s.restoreInstallState();let a=await s.loadUserConfig(),n;if(a?.constraints)n=new YC(s);else{let{Constraints:h}=await Promise.resolve().then(()=>(lS(),aS));n=await h.find(s)}let c,f=!1,p=!1;for(let h=this.fix?10:1;h>0;--h){let E=await n.process();if(!E)break;let{changedWorkspaces:C,remainingErrors:S}=iF(s,E,{fix:this.fix}),P=[];for(let[I,R]of C){let N=I.manifest.indent;I.manifest=new Ut,I.manifest.indent=N,I.manifest.load(R),P.push(I.persistManifest())}if(await Promise.all(P),!(C.size>0&&h>1)){c=rEe(S,{configuration:r}),f=!1,p=!0;for(let[,I]of S)for(let R of I)R.fixable?f=!0:p=!1}}if(c.children.length===0)return 0;if(f){let h=p?`Those errors can all be fixed by running ${he.pretty(r,"yarn constraints --fix",he.Type.CODE)}`:`Errors prefixed by '\u2699' can be fixed by running ${he.pretty(r,"yarn constraints --fix",he.Type.CODE)}`;await Ot.start({configuration:r,stdout:this.context.stdout,includeNames:!1,includeFooter:!1},async E=>{E.reportInfo(0,h),E.reportSeparator()})}return c.children=je.sortMap(c.children,h=>h.value[1]),xs.emitTree(c,{configuration:r,stdout:this.context.stdout,json:this.json,separators:1}),1}};iS();var rut={configuration:{enableConstraintsChecks:{description:"If true, constraints will run during installs",type:"BOOLEAN",default:!1},constraintsPath:{description:"The path of the constraints file.",type:"ABSOLUTE_PATH",default:"./constraints.pro"}},commands:[zC,XC,ZC],hooks:{async validateProjectAfterInstall(t,{reportError:e}){if(!t.configuration.get("enableConstraintsChecks"))return;let r=await t.loadUserConfig(),s;if(r?.constraints)s=new YC(t);else{let{Constraints:c}=await Promise.resolve().then(()=>(lS(),aS));s=await c.find(t)}let a=await s.process();if(!a)return;let{remainingErrors:n}=iF(t,a);if(n.size!==0)if(t.configuration.isCI)for(let[c,f]of n)for(let p of f)e(84,`${he.pretty(t.configuration,c.anchoredLocator,he.Type.IDENT)}: ${p.text}`);else e(84,`Constraint check failed; run ${he.pretty(t.configuration,"yarn constraints",he.Type.CODE)} for more details`)}}},nut=rut;var Hq={};Vt(Hq,{CreateCommand:()=>$C,DlxCommand:()=>ew,default:()=>sut});Ge();Yt();var $C=class extends ft{constructor(){super(...arguments);this.pkg=ge.String("-p,--package",{description:"The package to run the provided command from"});this.quiet=ge.Boolean("-q,--quiet",!1,{description:"Only report critical errors instead of printing the full install logs"});this.command=ge.String();this.args=ge.Proxy()}static{this.paths=[["create"]]}async execute(){let r=[];this.pkg&&r.push("--package",this.pkg),this.quiet&&r.push("--quiet");let s=this.command.replace(/^(@[^@/]+)(@|$)/,"$1/create$2"),a=G.parseDescriptor(s),n=a.name.match(/^create(-|$)/)?a:a.scope?G.makeIdent(a.scope,`create-${a.name}`):G.makeIdent(null,`create-${a.name}`),c=G.stringifyIdent(n);return a.range!=="unknown"&&(c+=`@${a.range}`),this.cli.run(["dlx",...r,c,...this.args])}};Ge();Ge();Dt();Yt();var ew=class extends ft{constructor(){super(...arguments);this.packages=ge.Array("-p,--package",{description:"The package(s) to install before running the command"});this.quiet=ge.Boolean("-q,--quiet",!1,{description:"Only report critical errors instead of printing the full install logs"});this.command=ge.String();this.args=ge.Proxy()}static{this.paths=[["dlx"]]}static{this.usage=ot.Usage({description:"run a package in a temporary environment",details:"\n This command will install a package within a temporary environment, and run its binary script if it contains any. The binary will run within the current cwd.\n\n By default Yarn will download the package named `command`, but this can be changed through the use of the `-p,--package` flag which will instruct Yarn to still run the same command but from a different package.\n\n Using `yarn dlx` as a replacement of `yarn add` isn't recommended, as it makes your project non-deterministic (Yarn doesn't keep track of the packages installed through `dlx` - neither their name, nor their version).\n ",examples:[["Use create-vite to scaffold a new Vite project","yarn dlx create-vite"],["Install multiple packages for a single command",`yarn dlx -p typescript -p ts-node ts-node --transpile-only -e "console.log('hello!')"`]]})}async execute(){return ze.telemetry=null,await ce.mktempPromise(async r=>{let s=J.join(r,`dlx-${process.pid}`);await ce.mkdirPromise(s),await ce.writeFilePromise(J.join(s,"package.json"),`{}
`),await ce.writeFilePromise(J.join(s,"yarn.lock"),"");let a=J.join(s,".yarnrc.yml"),n=await ze.findProjectCwd(this.context.cwd),f={enableGlobalCache:!(await ze.find(this.context.cwd,null,{strict:!1})).get("enableGlobalCache"),enableTelemetry:!1,logFilters:[{code:Yf(68),level:he.LogLevel.Discard}]},p=n!==null?J.join(n,".yarnrc.yml"):null;p!==null&&ce.existsSync(p)?(await ce.copyFilePromise(p,a),await ze.updateConfiguration(s,N=>{let U=je.toMerged(N,f);return Array.isArray(N.plugins)&&(U.plugins=N.plugins.map(W=>{let ee=typeof W=="string"?W:W.path,ie=fe.isAbsolute(ee)?ee:fe.resolve(fe.fromPortablePath(n),ee);return typeof W=="string"?ie:{path:ie,spec:W.spec}})),U})):await ce.writeJsonPromise(a,f);let h=this.packages??[this.command],E=G.parseDescriptor(this.command).name,C=await this.cli.run(["add","--fixed","--",...h],{cwd:s,quiet:this.quiet});if(C!==0)return C;this.quiet||this.context.stdout.write(`
`);let S=await ze.find(s,this.context.plugins),{project:P,workspace:I}=await Tt.find(S,s);if(I===null)throw new ar(P.cwd,s);await P.restoreInstallState();let R=await In.getWorkspaceAccessibleBinaries(I);return R.has(E)===!1&&R.size===1&&typeof this.packages>"u"&&(E=Array.from(R)[0][0]),await In.executeWorkspaceAccessibleBinary(I,E,this.args,{packageAccessibleBinaries:R,cwd:this.context.cwd,stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr})})}};var iut={commands:[$C,ew]},sut=iut;var qq={};Vt(qq,{ExecFetcher:()=>uS,ExecResolver:()=>fS,default:()=>lut,execUtils:()=>lF});Ge();Ge();Dt();var cA="exec:";var lF={};Vt(lF,{loadGeneratorFile:()=>cS,makeLocator:()=>Gq,makeSpec:()=>PEe,parseSpec:()=>jq});Ge();Dt();function jq(t){let{params:e,selector:r}=G.parseRange(t),s=fe.toPortablePath(r);return{parentLocator:e&&typeof e.locator=="string"?G.parseLocator(e.locator):null,path:s}}function PEe({parentLocator:t,path:e,generatorHash:r,protocol:s}){let a=t!==null?{locator:G.stringifyLocator(t)}:{},n=typeof r<"u"?{hash:r}:{};return G.makeRange({protocol:s,source:e,selector:e,params:{...n,...a}})}function Gq(t,{parentLocator:e,path:r,generatorHash:s,protocol:a}){return G.makeLocator(t,PEe({parentLocator:e,path:r,generatorHash:s,protocol:a}))}async function cS(t,e,r){let{parentLocator:s,path:a}=G.parseFileStyleRange(t,{protocol:e}),n=J.isAbsolute(a)?{packageFs:new Sn(vt.root),prefixPath:vt.dot,localPath:vt.root}:await r.fetcher.fetch(s,r),c=n.localPath?{packageFs:new Sn(vt.root),prefixPath:J.relative(vt.root,n.localPath)}:n;n!==c&&n.releaseFs&&n.releaseFs();let f=c.packageFs,p=J.join(c.prefixPath,a);return await f.readFilePromise(p,"utf8")}var uS=class{supports(e,r){return!!e.reference.startsWith(cA)}getLocalPath(e,r){let{parentLocator:s,path:a}=G.parseFileStyleRange(e.reference,{protocol:cA});if(J.isAbsolute(a))return a;let n=r.fetcher.getLocalPath(s,r);return n===null?null:J.resolve(n,a)}async fetch(e,r){let s=r.checksums.get(e.locatorHash)||null,[a,n,c]=await r.cache.fetchPackageFromCache(e,s,{onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e),loader:()=>this.fetchFromDisk(e,r),...r.cacheOptions});return{packageFs:a,releaseFs:n,prefixPath:G.getIdentVendorPath(e),localPath:this.getLocalPath(e,r),checksum:c}}async fetchFromDisk(e,r){let s=await cS(e.reference,cA,r);return ce.mktempPromise(async a=>{let n=J.join(a,"generator.js");return await ce.writeFilePromise(n,s),ce.mktempPromise(async c=>{if(await this.generatePackage(c,e,n,r),!ce.existsSync(J.join(c,"build")))throw new Error("The script should have generated a build directory");return await ps.makeArchiveFromDirectory(J.join(c,"build"),{prefixPath:G.getIdentVendorPath(e),compressionLevel:r.project.configuration.get("compressionLevel")})})})}async generatePackage(e,r,s,a){return await ce.mktempPromise(async n=>{let c=await In.makeScriptEnv({project:a.project,binFolder:n}),f=J.join(e,"runtime.js");return await ce.mktempPromise(async p=>{let h=J.join(p,"buildfile.log"),E=J.join(e,"generator"),C=J.join(e,"build");await ce.mkdirPromise(E),await ce.mkdirPromise(C);let S={tempDir:fe.fromPortablePath(E),buildDir:fe.fromPortablePath(C),locator:G.stringifyLocator(r)};await ce.writeFilePromise(f,`
// Expose 'Module' as a global variable
Object.defineProperty(global, 'Module', {
get: () => require('module'),
configurable: true,
enumerable: false,
});
// Expose non-hidden built-in modules as global variables
for (const name of Module.builtinModules.filter((name) => name !== 'module' && !name.startsWith('_'))) {
Object.defineProperty(global, name, {
get: () => require(name),
configurable: true,
enumerable: false,
});
}
// Expose the 'execEnv' global variable
Object.defineProperty(global, 'execEnv', {
value: {
...${JSON.stringify(S)},
},
enumerable: true,
});
`);let P=c.NODE_OPTIONS||"",I=/\s*--require\s+\S*\.pnp\.c?js\s*/g;P=P.replace(I," ").trim(),c.NODE_OPTIONS=P;let{stdout:R,stderr:N}=a.project.configuration.getSubprocessStreams(h,{header:`# This file contains the result of Yarn generating a package (${G.stringifyLocator(r)})
`,prefix:G.prettyLocator(a.project.configuration,r),report:a.report}),{code:U}=await qr.pipevp(process.execPath,["--require",fe.fromPortablePath(f),fe.fromPortablePath(s),G.stringifyIdent(r)],{cwd:e,env:c,stdin:null,stdout:R,stderr:N});if(U!==0)throw ce.detachTemp(p),new Error(`Package generation failed (exit code ${U}, logs can be found here: ${he.pretty(a.project.configuration,h,he.Type.PATH)})`)})})}};Ge();Ge();var out=2,fS=class{supportsDescriptor(e,r){return!!e.range.startsWith(cA)}supportsLocator(e,r){return!!e.reference.startsWith(cA)}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,s){return G.bindDescriptor(e,{locator:G.stringifyLocator(r)})}getResolutionDependencies(e,r){return{}}async getCandidates(e,r,s){if(!s.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let{path:a,parentLocator:n}=jq(e.range);if(n===null)throw new Error("Assertion failed: The descriptor should have been bound");let c=await cS(G.makeRange({protocol:cA,source:a,selector:a,params:{locator:G.stringifyLocator(n)}}),cA,s.fetchOptions),f=Nn.makeHash(`${out}`,c).slice(0,6);return[Gq(e,{parentLocator:n,path:a,generatorHash:f,protocol:cA})]}async getSatisfying(e,r,s,a){let[n]=await this.getCandidates(e,r,a);return{locators:s.filter(c=>c.locatorHash===n.locatorHash),sorted:!1}}async resolve(e,r){if(!r.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let s=await r.fetchOptions.fetcher.fetch(e,r.fetchOptions),a=await je.releaseAfterUseAsync(async()=>await Ut.find(s.prefixPath,{baseFs:s.packageFs}),s.releaseFs);return{...e,version:a.version||"0.0.0",languageName:a.languageName||r.project.configuration.get("defaultLanguageName"),linkType:"HARD",conditions:a.getConditions(),dependencies:r.project.configuration.normalizeDependencyMap(a.dependencies),peerDependencies:a.peerDependencies,dependenciesMeta:a.dependenciesMeta,peerDependenciesMeta:a.peerDependenciesMeta,bin:a.bin}}};var aut={fetchers:[uS],resolvers:[fS]},lut=aut;var Yq={};Vt(Yq,{FileFetcher:()=>gS,FileResolver:()=>dS,TarballFileFetcher:()=>mS,TarballFileResolver:()=>yS,default:()=>fut,fileUtils:()=>xm});Ge();Dt();var tw=/^(?:[a-zA-Z]:[\\/]|\.{0,2}\/)/,AS=/^[^?]*\.(?:tar\.gz|tgz)(?:::.*)?$/,es="file:";var xm={};Vt(xm,{fetchArchiveFromLocator:()=>hS,makeArchiveFromLocator:()=>cF,makeBufferFromLocator:()=>Wq,makeLocator:()=>rw,makeSpec:()=>xEe,parseSpec:()=>pS});Ge();Dt();function pS(t){let{params:e,selector:r}=G.parseRange(t),s=fe.toPortablePath(r);return{parentLocator:e&&typeof e.locator=="string"?G.parseLocator(e.locator):null,path:s}}function xEe({parentLocator:t,path:e,hash:r,protocol:s}){let a=t!==null?{locator:G.stringifyLocator(t)}:{},n=typeof r<"u"?{hash:r}:{};return G.makeRange({protocol:s,source:e,selector:e,params:{...n,...a}})}function rw(t,{parentLocator:e,path:r,hash:s,protocol:a}){return G.makeLocator(t,xEe({parentLocator:e,path:r,hash:s,protocol:a}))}async function hS(t,e){let{parentLocator:r,path:s}=G.parseFileStyleRange(t.reference,{protocol:es}),a=J.isAbsolute(s)?{packageFs:new Sn(vt.root),prefixPath:vt.dot,localPath:vt.root}:await e.fetcher.fetch(r,e),n=a.localPath?{packageFs:new Sn(vt.root),prefixPath:J.relative(vt.root,a.localPath)}:a;a!==n&&a.releaseFs&&a.releaseFs();let c=n.packageFs,f=J.join(n.prefixPath,s);return await je.releaseAfterUseAsync(async()=>await c.readFilePromise(f),n.releaseFs)}async function cF(t,{protocol:e,fetchOptions:r,inMemory:s=!1}){let{parentLocator:a,path:n}=G.parseFileStyleRange(t.reference,{protocol:e}),c=J.isAbsolute(n)?{packageFs:new Sn(vt.root),prefixPath:vt.dot,localPath:vt.root}:await r.fetcher.fetch(a,r),f=c.localPath?{packageFs:new Sn(vt.root),prefixPath:J.relative(vt.root,c.localPath)}:c;c!==f&&c.releaseFs&&c.releaseFs();let p=f.packageFs,h=J.join(f.prefixPath,n);return await je.releaseAfterUseAsync(async()=>await ps.makeArchiveFromDirectory(h,{baseFs:p,prefixPath:G.getIdentVendorPath(t),compressionLevel:r.project.configuration.get("compressionLevel"),inMemory:s}),f.releaseFs)}async function Wq(t,{protocol:e,fetchOptions:r}){return(await cF(t,{protocol:e,fetchOptions:r,inMemory:!0})).getBufferAndClose()}var gS=class{supports(e,r){return!!e.reference.startsWith(es)}getLocalPath(e,r){let{parentLocator:s,path:a}=G.parseFileStyleRange(e.reference,{protocol:es});if(J.isAbsolute(a))return a;let n=r.fetcher.getLocalPath(s,r);return n===null?null:J.resolve(n,a)}async fetch(e,r){let s=r.checksums.get(e.locatorHash)||null,[a,n,c]=await r.cache.fetchPackageFromCache(e,s,{onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${G.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the disk`),loader:()=>this.fetchFromDisk(e,r),...r.cacheOptions});return{packageFs:a,releaseFs:n,prefixPath:G.getIdentVendorPath(e),localPath:this.getLocalPath(e,r),checksum:c}}async fetchFromDisk(e,r){return cF(e,{protocol:es,fetchOptions:r})}};Ge();Ge();var cut=2,dS=c Line truncated
`,{automaticNewlines:!0});let h=[p],E=J.join(this.context.cwd,"README.md");if(ce.existsSync(E)||(await ce.writeFilePromise(E,`# ${G.stringifyIdent(n.name)}
`),h.push(E)),!s||s.cwd===this.context.cwd){let C=J.join(this.context.cwd,Er.lockfile);ce.existsSync(C)||(await ce.writeFilePromise(C,""),h.push(C));let P=[".yarn/*","!.yarn/patches","!.yarn/plugins","!.yarn/releases","!.yarn/sdks","!.yarn/versions","","# Whether you use PnP or not, the node_modules folder is often used to store","# build artifacts that should be gitignored","node_modules","","# Swap the comments on the following lines if you wish to use zero-installs","# In that case, don't forget to run `yarn config set enableGlobalCache false`!","# Documentation here: https://yarnpkg.com/features/caching#zero-installs","","#!.yarn/cache",".pnp.*"].map(ue=>`${ue}
`).join(""),I=J.join(this.context.cwd,".gitignore");ce.existsSync(I)||(await ce.writeFilePromise(I,P),h.push(I));let N=["/.yarn/** linguist-vendored","/.yarn/releases/* binary","/.yarn/plugins/**/* binary","/.pnp.* binary linguist-generated"].map(ue=>`${ue}
`).join(""),U=J.join(this.context.cwd,".gitattributes");ce.existsSync(U)||(await ce.writeFilePromise(U,N),h.push(U));let W={"*":{charset:"utf-8",endOfLine:"lf",indentSize:2,indentStyle:"space",insertFinalNewline:!0}};je.mergeIntoTarget(W,r.get("initEditorConfig"));let ee=`root = true
`;for(let[ue,le]of Object.entries(W)){ee+=`
[${ue}]
`;for(let[me,pe]of Object.entries(le)){let Be=me.replace(/[A-Z]/g,Ce=>`_${Ce.toLowerCase()}`);ee+=`${Be} = ${pe}
`}}let ie=J.join(this.context.cwd,".editorconfig");ce.existsSync(ie)||(await ce.writeFilePromise(ie,ee),h.push(ie)),await this.cli.run(["install"],{quiet:!0}),await this.initialize(),ce.existsSync(J.join(this.context.cwd,".git"))||(await qr.execvp("git",["init"],{cwd:this.context.cwd}),await qr.execvp("git",["add","--",...h],{cwd:this.context.cwd}),await qr.execvp("git",["commit","--allow-empty","-m","First commit"],{cwd:this.context.cwd}))}}};var nw=class extends z0{constructor(){super(...arguments);this.initializer=ge.String();this.argv=ge.Proxy()}static{this.paths=[["init"]]}async initialize(){this.context.stdout.write(`
`),await this.cli.run(["dlx",this.initializer,...this.argv],{quiet:!0})}};var dut={configuration:{initScope:{description:"Scope used when creating packages via the init command",type:"STRING",default:null},initFields:{description:"Additional fields to set when creating packages via the init command",type:"MAP",valueDefinition:{description:"",type:"ANY"}},initEditorConfig:{description:"Extra rules to define in the generator editorconfig",type:"MAP",valueDefinition:{description:"",type:"ANY"}}},commands:[z0,nw]},mut=dut;var JW={};Vt(JW,{SearchCommand:()=>Iw,UpgradeInteractiveCommand:()=>Cw,default:()=>Dgt});Ge();var FEe=ut(Ie("os"));function iw({stdout:t}){if(FEe.default.endianness()==="BE")throw new Error("Interactive commands cannot be used on big-endian systems because ink depends on yoga-layout-prebuilt which only supports little-endian architectures");if(!t.isTTY)throw new Error("Interactive commands can only be used inside a TTY environment")}Yt();var YIe=ut(g9()),d9={appId:"OFCNCOG2CU",apiKey:"6fe4476ee5a1832882e326b506d14126",indexName:"npm-search"},hAt=(0,YIe.default)(d9.appId,d9.apiKey).initIndex(d9.indexName),m9=async(t,e=0)=>await hAt.search(t,{analyticsTags:["yarn-plugin-interactive-tools"],attributesToRetrieve:["name","version","owner","repository","humanDownloadsLast30Days"],page:e,hitsPerPage:10});var CD=["regular","dev","peer"],Iw=class extends ft{static{this.paths=[["search"]]}static{this.usage=ot.Usage({category:"Interactive commands",description:"open the search interface",details:`
This command opens a fullscreen terminal interface where you can search for and install packages from the npm registry.
`,examples:[["Open the search window","yarn search"]]})}async execute(){iw(this.context);let{Gem:e}=await Promise.resolve().then(()=>(WF(),LW)),{ScrollableItems:r}=await Promise.resolve().then(()=>(KF(),JF)),{useKeypress:s}=await Promise.resolve().then(()=>(yD(),w2e)),{useMinistore:a}=await Promise.resolve().then(()=>(GW(),jW)),{renderForm:n}=await Promise.resolve().then(()=>($F(),ZF)),{default:c}=await Promise.resolve().then(()=>ut(T2e())),{Box:f,Text:p}=await Promise.resolve().then(()=>ut(Wc())),{default:h,useEffect:E,useState:C}=await Promise.resolve().then(()=>ut(hn())),S=await ze.find(this.context.cwd,this.context.plugins),P=()=>h.createElement(f,{flexDirection:"row"},h.createElement(f,{flexDirection:"column",width:48},h.createElement(f,null,h.createElement(p,null,"Press ",h.createElement(p,{bold:!0,color:"cyanBright"},"<up>"),"/",h.createElement(p,{bold:!0,color:"cyanBright"},"<down>")," to move between packages.")),h.createElement(f,null,h.createElement(p,null,"Press ",h.createElement(p,{bold:!0,color:"cyanBright"},"<space>")," to select a package.")),h.createElement(f,null,h.createElement(p,null,"Press ",h.createElement(p,{bold:!0,color:"cyanBright"},"<space>")," again to change the target."))),h.createElement(f,{flexDirection:"column"},h.createElement(f,{marginLeft:1},h.createElement(p,null,"Press ",h.createElement(p,{bold:!0,color:"cyanBright"},"<enter>")," to install the selected packages.")),h.createElement(f,{marginLeft:1},h.createElement(p,null,"Press ",h.createElement(p,{bold:!0,color:"cyanBright"},"<ctrl+c>")," to abort.")))),I=()=>h.createElement(h.Fragment,null,h.createElement(f,{width:15},h.createElement(p,{bold:!0,underline:!0,color:"gray"},"Owner")),h.createElement(f,{width:11},h.createElement(p,{bold:!0,underline:!0,color:"gray"},"Version")),h.createElement(f,{width:10},h.createElement(p,{bold:!0,underline:!0,color:"gray"},"Downloads"))),R=()=>h.createElement(f,{width:17},h.createElement(p,{bold:!0,underline:!0,color:"gray"},"Target")),N=({hit:pe,active:Be})=>{let[Ce,g]=a(pe.name,null);s({active:Be},(Ae,se)=>{if(se.name!=="space")return;if(!Ce){g(CD[0]);return}let Z=CD.indexOf(Ce)+1;Z===CD.length?g(null):g(CD[Z])},[Ce,g]);let we=G.parseIdent(pe.name),ye=G.prettyIdent(S,we);return h.createElement(f,null,h.createElement(f,{width:45},h.createElement(p,{bold:!0,wrap:"wrap"},ye)),h.createElement(f,{width:14,marginLeft:1},h.createElement(p,{bold:!0,wrap:"truncate"},pe.owner.name)),h.createElement(f,{width:10,marginLeft:1},h.createElement(p,{italic:!0,wrap:"truncate"},pe.version)),h.createElement(f,{width:16,marginLeft:1},h.createElement(p,null,pe.humanDownloadsLast30Days)))},U=({name:pe,active:Be})=>{let[Ce]=a(pe,null),g=G.parseIdent(pe);return h.createElement(f,null,h.createElement(f,{width:47},h.createElement(p,{bold:!0}," - ",G.prettyIdent(S,g))),CD.map(we=>h.createElement(f,{key:we,width:14,marginLeft:1},h.createElement(p,null," ",h.createElement(e,{active:Ce===we})," ",h.createElement(p,{bold:!0},we)))))},W=()=>h.createElement(f,{marginTop:1},h.createElement(p,null,"Powered by Algolia.")),ie=await n(({useSubmit:pe})=>{let Be=a();pe(Be);let Ce=Array.from(Be.keys()).filter(j=>Be.get(j)!==null),[g,we]=C(""),[ye,Ae]=C(0),[se,Z]=C([]),De=j=>{j.match(/\t| /)||we(j)},Re=async()=>{Ae(0);let j=await m9(g);j.query===g&&Z(j.hits)},mt=async()=>{let j=await m9(g,ye+1);j.query===g&&j.page-1===ye&&(Ae(j.page),Z([...se,...j.hits]))};return E(()=>{g?Re():Z([])},[g]),h.createElement(f,{flexDirection:"column"},h.createElement(P,null),h.createElement(f,{flexDirection:"row",marginTop:1},h.createElement(p,{bold:!0},"Search: "),h.createElement(f,{width:41},h.createElement(c,{value:g,onChange:De,placeholder:"i.e. babel, webpack, react...",showCursor:!1})),h.createElement(I,null)),se.length?h.createElement(r,{radius:2,loop:!1,children:se.map(j=>h.createElement(N,{key:j.name,hit:j,active:!1})),willReachEnd:mt}):h.createElement(p,{color:"gray"},"Start typing..."),h.createElement(f,{flexDirection:"row",marginTop:1},h.createElement(f,{width:49},h.createElement(p,{bold:!0},"Selected:")),h.createElement(R,null)),Ce.length?Ce.map(j=>h.createElement(U,{key:j,name:j,active:!1})):h.createElement(p,{color:"gray"},"No selected packages..."),h.createElement(W,null))},{},{stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr});if(typeof ie>"u")return 1;let ue=Array.from(ie.keys()).filter(pe=>ie.get(pe)==="regular"),le=Array.from(ie.keys()).filter(pe=>ie.get(pe)==="dev"),me=Array.from(ie.keys()).filter(pe=>ie.get(pe)==="peer");return ue.length&&await this.cli.run(["add",...ue]),le.length&&await this.cli.run(["add","--dev",...le]),me&&await this.cli.run(["add","--peer",...me]),0}};Ge();Yt();YG();var U2e=ut(Ai()),M2e=/^((?:[\^~]|>=?)?)([0-9]+)(\.[0-9]+)(\.[0-9]+)((?:-\S+)?)$/;function _2e(t,e){return t.length>0?[t.slice(0,e)].concat(_2e(t.slice(e),e)):[]}var Cw=class extends ft{static{this.paths=[["upgrade-interactive"]]}static{this.usage=ot.Usage({category:"Interactive commands",description:"open Line truncated
This command opens a fullscreen terminal interface where you can see any out of date packages used by your application, their status compared to the latest versions available on the remote registry, and select packages to upgrade.
`,examples:[["Open the upgrade window","yarn upgrade-interactive"]]})}async execute(){iw(this.context);let{ItemOptions:e}=await Promise.resolve().then(()=>(L2e(),O2e)),{Pad:r}=await Promise.resolve().then(()=>(VW(),N2e)),{ScrollableItems:s}=await Promise.resolve().then(()=>(KF(),JF)),{useMinistore:a}=await Promise.resolve().then(()=>(GW(),jW)),{renderForm:n}=await Promise.resolve().then(()=>($F(),ZF)),{Box:c,Text:f}=await Promise.resolve().then(()=>ut(Wc())),{default:p,useEffect:h,useRef:E,useState:C}=await Promise.resolve().then(()=>ut(hn())),S=await ze.find(this.context.cwd,this.context.plugins),{project:P,workspace:I}=await Tt.find(S,this.context.cwd),R=await Kr.find(S);if(!I)throw new ar(P.cwd,this.context.cwd);await P.restoreInstallState({restoreResolutions:!1});let N=this.context.stdout.rows-7,U=(we,ye)=>{let Ae=mde(we,ye),se="";for(let Z of Ae)Z.added?se+=he.pretty(S,Z.value,"green"):Z.removed||(se+=Z.value);return se},W=(we,ye)=>{if(we===ye)return ye;let Ae=G.parseRange(we),se=G.parseRange(ye),Z=Ae.selector.match(M2e),De=se.selector.match(M2e);if(!Z||!De)return U(we,ye);let Re=["gray","red","yellow","green","magenta"],mt=null,j="";for(let rt=1;rt<Re.length;++rt)mt!==null||Z[rt]!==De[rt]?(mt===null&&(mt=Re[rt-1]),j+=he.pretty(S,De[rt],mt)):j+=De[rt];return j},ee=async(we,ye,Ae)=>{let se=await Xu.fetchDescriptorFrom(we,Ae,{project:P,cache:R,preserveModifier:ye,workspace:I});return se!==null?se.range:we.range},ie=async we=>{let ye=U2e.default.valid(we.range)?`^${we.range}`:we.range,[Ae,se]=await Promise.all([ee(we,we.range,ye).catch(()=>null),ee(we,we.range,"latest").catch(()=>null)]),Z=[{value:null,label:we.range}];return Ae&&Ae!==we.range?Z.push({value:Ae,label:W(we.range,Ae)}):Z.push({value:null,label:""}),se&&se!==Ae&&se!==we.range?Z.push({value:se,label:W(we.range,se)}):Z.push({value:null,label:""}),Z},ue=()=>p.createElement(c,{flexDirection:"row"},p.createElement(c,{flexDirection:"column",width:49},p.createElement(c,{marginLeft:1},p.createElement(f,null,"Press ",p.createElement(f,{bold:!0,color:"cyanBright"},"<up>"),"/",p.createElement(f,{bold:!0,color:"cyanBright"},"<down>")," to select packages.")),p.createElement(c,{marginLeft:1},p.createElement(f,null,"Press ",p.createElement(f,{bold:!0,color:"cyanBright"},"<left>"),"/",p.createElement(f,{bold:!0,color:"cyanBright"},"<right>")," to select versions."))),p.createElement(c,{flexDirection:"column"},p.createElement(c,{marginLeft:1},p.createElement(f,null,"Press ",p.createElement(f,{bold:!0,color:"cyanBright"},"<enter>")," to install.")),p.createElement(c,{marginLeft:1},p.createElement(f,null,"Press ",p.createElement(f,{bold:!0,color:"cyanBright"},"<ctrl+c>")," to abort.")))),le=()=>p.createElement(c,{flexDirection:"row",paddingTop:1,paddingBottom:1},p.createElement(c,{width:50},p.createElement(f,{bold:!0},p.createElement(f,{color:"greenBright"},"?")," Pick the packages you want to upgrade.")),p.createElement(c,{width:17},p.createElement(f,{bold:!0,underline:!0,color:"gray"},"Current")),p.createElement(c,{width:17},p.createElement(f,{bold:!0,underline:!0,color:"gray"},"Range")),p.createElement(c,{width:17},p.createElement(f,{bold:!0,underline:!0,color:"gray"},"Latest"))),me=({active:we,descriptor:ye,suggestions:Ae})=>{let[se,Z]=a(ye.descriptorHash,null),De=G.stringifyIdent(ye),Re=Math.max(0,45-De.length);return p.createElement(p.Fragment,null,p.createElement(c,null,p.createElement(c,{width:45},p.createElement(f,{bold:!0},G.prettyIdent(S,ye)),p.createElement(r,{active:we,length:Re})),p.createElement(e,{active:we,options:Ae,value:se,skewer:!0,onChange:Z,sizes:[17,17,17]})))},pe=({dependencies:we})=>{let[ye,Ae]=C(we.map(()=>null)),se=E(!0),Z=async De=>{let Re=await ie(De);return Re.filter(mt=>mt.label!=="").length<=1?null:{descriptor:De,suggestions:Re}};return h(()=>()=>{se.current=!1},[]),h(()=>{let De=Math.trunc(N*1.75),Re=we.slice(0,De),mt=we.slice(De),j=_2e(mt,N),rt=Re.map(Z).reduce(async(Fe,Ne)=>{await Fe;let Pe=await Ne;Pe!==null&&se.current&&Ae(Ve=>{let ke=Ve.findIndex(Ue=>Ue===null),it=[...Ve];return it[ke]=Pe,it})},Promise.resolve());j.reduce((Fe,Ne)=>Promise.all(Ne.map(Pe=>Promise.resolve().then(()=>Z(Pe)))).then(async Pe=>{Pe=Pe.filter(Ve=>Ve!==null),await Fe,se.current&&Ae(Ve=>{let ke=Ve.findIndex(it=>it===null);return Ve.slice(0,ke).concat(Pe).concat(Ve.slice(ke+Pe.length))})}),rt).then(()=>{se.current&&Ae(Fe=>Fe.filter(Ne=>Ne!==null))})},[]),ye.length?p.createElement(s,{radius:N>>1,children:ye.map((De,Re)=>De!==null?p.createElement(me,{key:Re,active:!1,descriptor:De.descriptor,suggestions:De.suggestions}):p.createElement(f,{key:Re},"Loading..."))}):p.createElement(f,null,"No upgrades found")},Ce=await n(({useSubmit:we})=>{we(a());let ye=new Map;for(let se of P.workspaces)for(let Z of["dependencies","devDependencies"])for(let De of se.manifest[Z].values())P.tryWorkspaceByDescriptor(De)===null&&(De.range.startsWith("link:")||ye.set(De.descriptorHash,De));let Ae=je.sortMap(ye.values(),se=>G.stringifyDescriptor(se));return p.createEleme Line truncated
${E}, next tree:
${PD(f)}`);let S=q2e(f);if(S)throw new Error(`${S}, after hoisting finished:
${PD(f)}`)}return n.debugLevel>=2&&console.log(PD(f)),_gt(f)},Rgt=t=>{let e=t[t.length-1],r=new Map,s=new Set,a=n=>{if(!s.has(n)){s.add(n);for(let c of n.hoistedDependencies.values())r.set(c.name,c);for(let c of n.dependencies.values())n.peerNames.has(c.name)||a(c)}};return a(e),r},Fgt=t=>{let e=t[t.length-1],r=new Map,s=new Set,a=new Set,n=(c,f)=>{if(s.has(c))return;s.add(c);for(let h of c.hoistedDependencies.values())if(!f.has(h.name)){let E;for(let C of t)E=C.dependencies.get(h.name),E&&r.set(E.name,E)}let p=new Set;for(let h of c.dependencies.values())p.add(h.name);for(let h of c.dependencies.values())c.peerNames.has(h.name)||n(h,p)};return n(e,a),r},j2e=(t,e)=>{if(e.decoupled)return e;let{name:r,references:s,ident:a,locator:n,dependencies:c,originalDependencies:f,hoistedDependencies:p,peerNames:h,reasons:E,isHoistBorder:C,hoistPriority:S,dependencyKind:P,hoistedFrom:I,hoistedTo:R}=e,N={name:r,references:new Set(s),ident:a,locator:n,dependencies:new Map(c),originalDependencies:new Map(f),hoistedDependencies:new Map(p),peerNames:new Set(h),reasons:new Map(E),decoupled:!0,isHoistBorder:C,hoistPriority:S,dependencyKind:P,hoistedFrom:new Map(I),hoistedTo:new Map(R)},U=N.dependencies.get(r);return U&&U.ident==N.ident&&N.dependencies.set(r,N),t.dependencies.set(N.name,N),N},Ngt=(t,e)=>{let r=new Map([[t.name,[t.ident]]]);for(let a of t.dependencies.values())t.peerNames.has(a.name)||r.set(a.name,[a.ident]);let s=Array.from(e.keys());s.sort((a,n)=>{let c=e.get(a),f=e.get(n);if(f.hoistPriority!==c.hoistPriority)return f.hoistPriority-c.hoistPriority;{let p=c.dependents.size+c.peerDependents.size;return f.dependents.size+f.peerDependents.size-p}});for(let a of s){let n=a.substring(0,a.indexOf("@",1)),c=a.substring(n.length+1);if(!t.peerNames.has(n)){let f=r.get(n);f||(f=[],r.set(n,f)),f.indexOf(c)<0&&f.push(c)}}return r},ZW=t=>{let e=new Set,r=(s,a=new Set)=>{if(!a.has(s)){a.add(s);for(let n of s.peerNames)if(!t.peerNames.has(n)){let c=t.dependencies.get(n);c&&!e.has(c)&&r(c,a)}e.add(s)}};for(let s of t.dependencies.values())t.peerNames.has(s.name)||r(s);return e},eY=(t,e,r,s,a,n=new Set)=>{let c=e[e.length-1];if(n.has(c))return{anotherRoundNeeded:!1,isGraphChanged:!1};n.add(c);let f=Hgt(c),p=Ngt(c,f),h=t==c?new Map:a.fastLookupPossible?Rgt(e):Fgt(e),E,C=!1,S=!1,P=new Map(Array.from(p.entries()).map(([R,N])=>[R,N[0]])),I=new Map;do{let R=Mgt(t,e,r,h,P,p,s,I,a);R.isGraphChanged&&(S=!0),R.anotherRoundNeeded&&(C=!0),E=!1;for(let[N,U]of p)U.length>1&&!c.dependencies.has(N)&&(P.delete(N),U.shift(),P.set(N,U[0]),E=!0)}while(E);for(let R of c.dependencies.values())if(!c.peerNames.has(R.name)&&!r.has(R.locator)){r.add(R.locator);let N=eY(t,[...e,R],r,I,a);N.isGraphChanged&&(S=!0),N.anotherRoundNeeded&&(C=!0),r.delete(R.locator)}return{anotherRoundNeeded:C,isGraphChanged:S}},Ogt=t=>{for(let[e,r]of t.dependencies)if(!t.peerNames.has(e)&&r.ident!==t.ident)return!0;return!1},Lgt=(t,e,r,s,a,n,c,f,{outputReason:p,fastLookupPossible:h})=>{let E,C=null,S=new Set;p&&(E=`${Array.from(e).map(N=>yo(N)).join("\u2192")}`);let P=r[r.length-1],R=!(s.ident===P.ident);if(p&&!R&&(C="- self-reference"),R&&(R=s.dependencyKind!==1,p&&!R&&(C="- workspace")),R&&s.dependencyKind===2&&(R=!Ogt(s),p&&!R&&(C="- external soft link with unhoisted dependencies")),R&&(R=!t.peerNames.has(s.name),p&&!R&&(C=`- cannot shadow peer: ${yo(t.originalDependencies.get(s.name).locator)} at ${E}`)),R){let N=!1,U=a.get(s.name);if(N=!U||U.ident===s.ident,p&&!N&&(C=`- filled by: ${yo(U.locator)} at ${E}`),N)for(let W=r.length-1;W>=1;W--){let ie=r[W].dependencies.get(s.name);if(ie&&ie.ident!==s.ident){N=!1;let ue=f.get(P);ue||(ue=new Set,f.set(P,ue)),ue.add(s.name),p&&(C=`- filled by ${yo(ie.locator)} at ${r.slice(0,W).map(le=>yo(le.locator)).join("\u2192")}`);break}}R=N}if(R&&(R=n.get(s.name)===s.ident,p&&!R&&(C=`- filled by: ${yo(c.get(s.name)[0])} at ${E}`)),R){let N=!0,U=new Set(s.peerNames);for(let W=r.length-1;W>=1;W--){let ee=r[W];for(let ie of U){if(ee.peerNames.has(ie)&&ee.originalDependencies.has(ie))continue;let ue=ee.dependencies.get(ie);ue&&t.dependencies.get(ie)!==ue&&(W===r.length-1?S.add(ue):(S=null,N=!1,p&&(C=`- peer dependency ${yo(ue.locator)} from parent ${yo(ee.locator)} was not hoisted to ${E}`))),U.delete(ie)}if(!N)break}R=N}if(R&&!h)for(let N of s.hoistedDependencies.values()){let U=a.get(N.name)||t.dependencies.get(N.name);if(!U||N.ident!==U.ident){R=!1,p&&(C=`- previously hoisted dependency mismatch, needed: ${yo(N.locator)}, available: ${yo(U?.locator)}`);break}}return S!==null&&S.size>0?{isHoistable:2,dependsOn:S,reason:C}:{isHoistable:R?0:1,reason:C}},rN=t=>`${t.name}@${t.locator}`,Mgt=(t,e,r,s,a,n,c,f,p)=>{let h=e[e.length-1],E=new Set,C=!1,S=!1,P=(U,W,ee,ie,ue)=>{if(E.has(ie))return;let le=[...W,rN(ie)],me=[...ee,rN(ie)],pe=new Map,Be=new Map;for(let Ae of ZW(ie)){let se=Lgt(h,r,[h,...U,ie],Ae,s,a,n,f,{outputReason:p.debugLevel>=2,fastLookupPossible:p.fastLookupPossible});if(Be.set(Ae,se),se.isHoistable===2)for(let Z of se.dependsOn){let Line truncated
${PD(t)}`)}let ye=ZW(ie);for(let Ae of ye)if(Ce.has(Ae)){let se=Be.get(Ae);if((a.get(Ae.name)===Ae.ident||!ie.reasons.has(Ae.name))&&se.isHoistable!==0&&ie.reasons.set(Ae.name,se.reason),!Ae.isHoistBorder&&me.indexOf(rN(Ae))<0){E.add(ie);let De=j2e(ie,Ae);P([...U,ie],le,me,De,R),E.delete(ie)}}},I,R=new Set(ZW(h)),N=Array.from(e).map(U=>rN(U));do{I=R,R=new Set;for(let U of I){if(U.locator===h.locator||U.isHoistBorder)continue;let W=j2e(h,U);P([],Array.from(r),N,W,R)}}while(R.size>0);return{anotherRoundNeeded:C,isGraphChanged:S}},q2e=t=>{let e=[],r=new Set,s=new Set,a=(n,c,f)=>{if(r.has(n)||(r.add(n),s.has(n)))return;let p=new Map(c);for(let h of n.dependencies.values())n.peerNames.has(h.name)||p.set(h.name,h);for(let h of n.originalDependencies.values()){let E=p.get(h.name),C=()=>`${Array.from(s).concat([n]).map(S=>yo(S.locator)).join("\u2192")}`;if(n.peerNames.has(h.name)){let S=c.get(h.name);(S!==E||!S||S.ident!==h.ident)&&e.push(`${C()} - broken peer promise: expected ${h.ident} but found ${S&&S.ident}`)}else{let S=f.hoistedFrom.get(n.name),P=n.hoistedTo.get(h.name),I=`${S?` hoisted from ${S.join(", ")}`:""}`,R=`${P?` hoisted to ${P}`:""}`,N=`${C()}${I}`;E?E.ident!==h.ident&&e.push(`${N} - broken require promise for ${h.name}${R}: expected ${h.ident}, but found: ${E.ident}`):e.push(`${N} - broken require promise: no required dependency ${h.name}${R} found`)}}s.add(n);for(let h of n.dependencies.values())n.peerNames.has(h.name)||a(h,p,n);s.delete(n)};return a(t,t.dependencies,t),e.join(`
`)},Ugt=(t,e)=>{let{identName:r,name:s,reference:a,peerNames:n}=t,c={name:s,references:new Set([a]),locator:$W(r,a),ident:H2e(r,a),dependencies:new Map,originalDependencies:new Map,hoistedDependencies:new Map,peerNames:new Set(n),reasons:new Map,decoupled:!0,isHoistBorder:!0,hoistPriority:0,dependencyKind:1,hoistedFrom:new Map,hoistedTo:new Map},f=new Map([[t,c]]),p=(h,E)=>{let C=f.get(h),S=!!C;if(!C){let{name:P,identName:I,reference:R,peerNames:N,hoistPriority:U,dependencyKind:W}=h,ee=e.hoistingLimits.get(E.locator);C={name:P,references:new Set([R]),locator:$W(I,R),ident:H2e(I,R),dependencies:new Map,originalDependencies:new Map,hoistedDependencies:new Map,peerNames:new Set(N),reasons:new Map,decoupled:!0,isHoistBorder:ee?ee.has(P):!1,hoistPriority:U||0,dependencyKind:W||0,hoistedFrom:new Map,hoistedTo:new Map},f.set(h,C)}if(E.dependencies.set(h.name,C),E.originalDependencies.set(h.name,C),S){let P=new Set,I=R=>{if(!P.has(R)){P.add(R),R.decoupled=!1;for(let N of R.dependencies.values())R.peerNames.has(N.name)||I(N)}};I(C)}else for(let P of h.dependencies)p(P,C)};for(let h of t.dependencies)p(h,c);return c},tY=t=>t.substring(0,t.indexOf("@",1)),_gt=t=>{let e={name:t.name,identName:tY(t.locator),references:new Set(t.references),dependencies:new Set},r=new Set([t]),s=(a,n,c)=>{let f=r.has(a),p;if(n===a)p=c;else{let{name:h,references:E,locator:C}=a;p={name:h,identName:tY(C),references:E,dependencies:new Set}}if(c.dependencies.add(p),!f){r.add(a);for(let h of a.dependencies.values())a.peerNames.has(h.name)||s(h,a,p);r.delete(a)}};for(let a of t.dependencies.values())s(a,t,e);return e},Hgt=t=>{let e=new Map,r=new Set([t]),s=c=>`${c.name}@${c.ident}`,a=c=>{let f=s(c),p=e.get(f);return p||(p={dependents:new Set,peerDependents:new Set,hoistPriority:0},e.set(f,p)),p},n=(c,f)=>{let p=!!r.has(f);if(a(f).dependents.add(c.ident),!p){r.add(f);for(let E of f.dependencies.values()){let C=a(E);C.hoistPriority=Math.max(C.hoistPriority,E.hoistPriority),f.peerNames.has(E.name)?C.peerDependents.add(f.ident):n(f,E)}}};for(let c of t.dependencies.values())t.peerNames.has(c.name)||n(t,c);return e},yo=t=>{if(!t)return"none";let e=t.indexOf("@",1),r=t.substring(0,e);r.endsWith("$wsroot$")&&(r=`wh:${r.replace("$wsroot$","")}`);let s=t.substring(e+1);if(s==="workspace:.")return".";if(s){let a=(s.indexOf("#")>0?s.split("#")[1]:s).replace("npm:","");return s.startsWith("virtual")&&(r=`v:${r}`),a.startsWith("workspace")&&(r=`w:${r}`,a=""),`${r}${a?`@${a}`:""}`}else return`${r}`};var PD=t=>{let e=0,r=(a,n,c="")=>{if(e>5e4||n.has(a))return"";e++;let f=Array.from(a.dependencies.values()).sort((h,E)=>h.name===E.name?0:h.name>E.name?1:-1),p="";n.add(a);for(let h=0;h<f.length;h++){let E=f[h];if(!a.peerNames.has(E.name)&&E!==a){let C=a.reasons.get(E.name),S=tY(E.locator);p+=`${c}${h<f.length-1?"\u251C\u2500":"\u2514\u2500"}${(n.has(E)?">":"")+(S!==E.name?`a:${E.name}:`:"")+yo(E.locator)+(C?` ${C}`:"")}
`,p+=r(E,n,`${c}${h<f.length-1?"\u2502 ":" "}`)}}return n.delete(a),p};return r(t,new Set)+(e>5e4?`
Tree is too large, part of the tree has been dunped
`:"")};var xD=(s=>(s.WORKSPACES="workspaces",s.DEPENDENCIES="dependencies",s.NONE="none",s))(xD||{}),W2e="node_modules",rg="$wsroot$";var kD=(t,e)=>{let{packageTree:r,hoistingLimits:s,errors:a,preserveSymlinksRequired:n}=Ggt(t,e),c=null;if(a.length===0){let f=G2e(r,{hoistingLimits:s});c=Wgt(t,f,e)}return{tree:c,errors:a,preserveSymlinksRequired:n}},pA=t=>`${t.name}@${t.reference}`,nY=t=>{let e=new Map;for(let[r,s]of t.entries())if(!s.dirList){let a=e.get(s.locator);a||(a={target:s.target,linkType:s.linkType,locations:[],aliases:s.aliases},e.set(s.locator,a)),a.locations.push(r)}for(let r of e.values())r.locations=r.locations.sort((s,a)=>{let n=s.split(J.delimiter).length,c=a.split(J.delimiter).length;return a===s?0:n!==c?c-n:a>s?1:-1});return e},Y2e=(t,e)=>{let r=G.isVirtualLocator(t)?G.devirtualizeLocator(t):t,s=G.isVirtualLocator(e)?G.devirtualizeLocator(e):e;return G.areLocatorsEqual(r,s)},rY=(t,e,r,s)=>{if(t.linkType!=="SOFT")return!1;let a=fe.toPortablePath(r.resolveVirtual&&e.reference&&e.reference.startsWith("virtual:")?r.resolveVirtual(t.packageLocation):t.packageLocation);return J.contains(s,a)===null},jgt=t=>{let e=t.getPackageInformation(t.topLevel);if(e===null)throw new Error("Assertion failed: Expected the top-level package to have been registered");if(t.findPackageLocator(e.packageLocation)===null)throw new Error("Assertion failed: Expected the top-level package to have a physical locator");let s=fe.toPortablePath(e.packageLocation.slice(0,-1)),a=new Map,n={children:new Map},c=t.getDependencyTreeRoots(),f=new Map,p=new Set,h=(S,P)=>{let I=pA(S);if(p.has(I))return;p.add(I);let R=t.getPackageInformation(S);if(R){let N=P?pA(P):"";if(pA(S)!==N&&R.linkType==="SOFT"&&!S.reference.startsWith("link:")&&!rY(R,S,t,s)){let U=V2e(R,S,t);(!f.get(U)||S.reference.startsWith("workspace:"))&&f.set(U,S)}for(let[U,W]of R.packageDependencies)W!==null&&(R.packagePeers.has(U)||h(t.getLocator(U,W),S))}};for(let S of c)h(S,null);let E=s.split(J.sep);for(let S of f.values()){let P=t.getPackageInformation(S),R=fe.toPortablePath(P.packageLocation.slice(0,-1)).split(J.sep).slice(E.length),N=n;for(let U of R){let W=N.children.get(U);W||(W={children:new Map},N.children.set(U,W)),N=W}N.workspaceLocator=S}let C=(S,P)=>{if(S.workspaceLocator){let I=pA(P),R=a.get(I);R||(R=new Set,a.set(I,R)),R.add(S.workspaceLocator)}for(let I of S.children.values())C(I,S.workspaceLocator||P)};for(let S of n.children.values())C(S,n.workspaceLocator);return a},Ggt=(t,e)=>{let r=[],s=!1,a=new Map,n=jgt(t),c=t.getPackageInformation(t.topLevel);if(c===null)throw new Error("Assertion failed: Expected the top-level package to have been registered");let f=t.findPackageLocator(c.packageLocation);if(f===null)throw new Error("Assertion failed: Expected the top-level package to have a physical locator");let p=fe.toPortablePath(c.packageLocation.slice(0,-1)),h={name:f.name,identName:f.name,reference:f.reference,peerNames:c.packagePeers,dependencies:new Set,dependencyKind:1},E=new Map,C=(P,I)=>`${pA(I)}:${P}`,S=(P,I,R,N,U,W,ee,ie)=>{let ue=C(P,R),le=E.get(ue),me=!!le;!me&&R.name===f.name&&R.reference===f.reference&&(le=h,E.set(ue,h));let pe=rY(I,R,t,p);if(!le){let Ae=0;pe?Ae=2:I.linkType==="SOFT"&&R.name.endsWith(rg)&&(Ae=1),le={name:P,identName:R.name,reference:R.reference,dependencies:new Set,peerNames:Ae===1?new Set:I.packagePeers,dependencyKind:Ae},E.set(ue,le)}let Be;if(pe?Be=2:U.linkType==="SOFT"?Be=1:Be=0,le.hoistPriority=Math.max(le.hoistPriority||0,Be),ie&&!pe){let Ae=pA({name:N.identName,reference:N.reference}),se=a.get(Ae)||new Set;a.set(Ae,se),se.add(le.name)}let Ce=new Map(I.packageDependencies);if(e.project){let Ae=e.project.workspacesByCwd.get(fe.toPortablePath(I.packageLocation.slice(0,-1)));if(Ae){let se=new Set([...Array.from(Ae.manifest.peerDependencies.values(),Z=>G.stringifyIdent(Z)),...Array.from(Ae.manifest.peerDependenciesMeta.keys())]);for(let Z of se)Ce.has(Z)||(Ce.set(Z,W.get(Z)||null),le.peerNames.add(Z))}}let g=pA({name:R.name.replace(rg,""),reference:R.reference}),we=n.get(g);if(we)for(let Ae of we)Ce.set(`${Ae.name}${rg}`,Ae.reference);(I!==U||I.linkType!=="SOFT"||!pe&&(!e.selfReferencesByCwd||e.selfReferencesByCwd.get(ee)))&&N.dependencies.add(le);let ye=R!==f&&I.linkType==="SOFT"&&!R.name.endsWith(rg)&&!pe;if(!me&&!ye){let Ae=new Map;for(let[se,Z]of Ce)if(Z!==null){let De=t.getLocator(se,Z),Re=t.getLocator(se.replace(rg,""),Z),mt=t.getPackageInformation(Re);if(mt===null)throw new Error("Assertion failed: Expected the package to have been registered");let j=rY(mt,De,t,p);if(e.validateExternalSoftLinks&&e.project&&j){mt.packageDependencies.size>0&&(s=!0);for(let[Ve,ke]of mt.packageDependencies)if(ke!==null){let it=G.parseLocator(Array.isArray(ke)?`${ke[0]}@${ke[1]}`:`${Ve}@${ke}`);if(pA(it)!==pA(De)){let Ue=Ce.get(Ve);if(Ue){let x=G.parseLocator(Array.isArray(Ue)?`${Ue[0]}@${Ue[1]}`:`${Ve}@${Ue}`);Y2e(x,it)||r.push({messageName:71,text:`Cannot link ${G.prettyIdent(e.project.configuration,G.parseIdent(De.name))} into ${G.pretLine truncated
`;for(let n=0,c=t.length;n<c;++n)a+=s+nN(String(n),t[n],e,s).replace(/^ +/,""),n+1<c&&(a+=","),a+=`
`;return a+=r,a+="]",a}function Jgt(t,e,r){let s=Object.keys(t),a="";a+="{";for(let n=0,c=s.length,f=0;n<c;++n){let p=s[n],h=t[p];typeof h>"u"||(f!==0&&(a+=", "),a+=JSON.stringify(p),a+=": ",a+=nN(p,h,e,r).replace(/^ +/g,""),f+=1)}return a+="}",a}function Kgt(t,e,r){let s=Object.keys(t),a=`${r} `,n="";n+=r,n+=`{
`;let c=0;for(let f=0,p=s.length;f<p;++f){let h=s[f],E=t[h];typeof E>"u"||(c!==0&&(n+=",",n+=`
`),n+=a,n+=JSON.stringify(h),n+=": ",n+=nN(h,E,e,a).replace(/^ +/g,""),c+=1)}return c!==0&&(n+=`
`),n+=r,n+="}",n}function nN(t,e,r,s){let{next:a}=J2e[r],n=a[t]||a["*"];return K2e(e,n,s)}function K2e(t,e,r){let{collapsed:s}=J2e[e];return Array.isArray(t)?s?Ygt(t,e,r):Vgt(t,e,r):typeof t=="object"&&t!==null?s?Jgt(t,e,r):Kgt(t,e,r):JSON.stringify(t)}function z2e(t){return K2e(t,"TOP_LEVEL","")}function QD(t,e){let r=Array.from(t);Array.isArray(e)||(e=[e]);let s=[];for(let n of e)s.push(r.map(c=>n(c)));let a=r.map((n,c)=>c);return a.sort((n,c)=>{for(let f of s){let p=f[n]<f[c]?-1:f[n]>f[c]?1:0;if(p!==0)return p}return 0}),a.map(n=>r[n])}function zgt(t){let e=new Map,r=QD(t.fallbackExclusionList||[],[({name:s,reference:a})=>s,({name:s,reference:a})=>a]);for(let{name:s,reference:a}of r){let n=e.get(s);typeof n>"u"&&e.set(s,n=new Set),n.add(a)}return Array.from(e).map(([s,a])=>[s,Array.from(a)])}function Xgt(t){return QD(t.fallbackPool||[],([e])=>e)}function Zgt(t){let e=[],r=t.dependencyTreeRoots.find(s=>t.packageRegistry.get(s.name)?.get(s.reference)?.packageLocation==="./");for(let[s,a]of QD(t.packageRegistry,([n])=>n===null?"0":`1${n}`)){if(s===null)continue;let n=[];e.push([s,n]);for(let[c,{packageLocation:f,packageDependencies:p,packagePeers:h,linkType:E,discardFromLookup:C}]of QD(a,([S])=>S===null?"0":`1${S}`)){if(c===null)continue;let S=[];s!==null&&c!==null&&!p.has(s)&&S.push([s,c]);for(let[U,W]of p)S.push([U,W]);let P=QD(S,([U])=>U),I=h&&h.size>0?Array.from(h):void 0,N={packageLocation:f,packageDependencies:P,packagePeers:I,linkType:E,discardFromLookup:C||void 0};n.push([c,N]),r&&s===r.name&&c===r.reference&&e.unshift([null,[[null,N]]])}}return e}function TD(t){return{__info:["This file is automatically generated. Do not touch it, or risk","your modifications being lost."],dependencyTreeRoots:t.dependencyTreeRoots,enableTopLevelFallback:t.enableTopLevelFallback||!1,ignorePatternData:t.ignorePattern||null,pnpZipBackend:t.pnpZipBackend,fallbackExclusionList:zgt(t),fallbackPool:Xgt(t),packageRegistryData:Zgt(t)}}var $2e=ut(Z2e());function eBe(t,e){return[t?`${t}
`:"",`/* eslint-disable */
`,`// @ts-nocheck
`,`"use strict";
`,`
`,e,`
`,(0,$2e.default)()].join("")}function $gt(t){return JSON.stringify(t,null,2)}function edt(t){return`'${t.replace(/\\/g,"\\\\").replace(/'/g,"\\'").replace(/\n/g,`\\
`)}'`}function tdt(t){return[`const RAW_RUNTIME_STATE =
`,`${edt(z2e(t))};
`,`function $$SETUP_STATE(hydrateRuntimeState, basePath) {
`,` return hydrateRuntimeState(JSON.parse(RAW_RUNTIME_STATE), {basePath: basePath || __dirname});
`,`}
`].join("")}function rdt(){return[`function $$SETUP_STATE(hydrateRuntimeState, basePath) {
`,` const fs = require('fs');
`,` const path = require('path');
`,` const pnpDataFilepath = path.resolve(__dirname, ${JSON.stringify(Er.pnpData)});
`,` return hydrateRuntimeState(JSON.parse(fs.readFileSync(pnpDataFilepath, 'utf8')), {basePath: basePath || __dirname});
`,`}
`].join("")}function tBe(t){let e=TD(t),r=tdt(e);return eBe(t.shebang,r)}function rBe(t){let e=TD(t),r=rdt(),s=eBe(t.shebang,r);return{dataFile:$gt(e),loaderFile:s}}Dt();function sY(t,{basePath:e}){let r=fe.toPortablePath(e),s=J.resolve(r),a=t.ignorePatternData!==null?new RegExp(t.ignorePatternData):null,n=new Map,c=new Map(t.packageRegistryData.map(([C,S])=>[C,new Map(S.map(([P,I])=>{if(C===null!=(P===null))throw new Error("Assertion failed: The name and reference should be null, or neither should");let R=I.discardFromLookup??!1,N={name:C,reference:P},U=n.get(I.packageLocation);U?(U.discardFromLookup=U.discardFromLookup&&R,R||(U.locator=N)):n.set(I.packageLocation,{locator:N,discardFromLookup:R});let W=null;return[P,{packageDependencies:new Map(I.packageDependencies),packagePeers:new Set(I.packagePeers),linkType:I.linkType,discardFromLookup:R,get packageLocation(){return W||(W=J.join(s,I.packageLocation))}}]}))])),f=new Map(t.fallbackExclusionList.map(([C,S])=>[C,new Set(S)])),p=new Map(t.fallbackPool),h=t.dependencyTreeRoots,E=t.enableTopLevelFallback;return{basePath:r,dependencyTreeRoots:h,enableTopLevelFallback:E,fallbackExclusionList:f,pnpZipBackend:t.pnpZipBackend,fallbackPool:p,ignorePattern:a,packageLocatorsByLocations:n,packageRegistry:c}}Dt();Dt();var sh=Ie("module"),jm=Ie("url"),gY=Ie("util");var ta=Ie("url");var oBe=ut(Ie("assert"));var oY=Array.isArray,RD=JSON.stringify,FD=Object.getOwnPropertyNames,Hm=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),aY=(t,e)=>RegExp.prototype.exec.call(t,e),lY=(t,...e)=>RegExp.prototype[Symbol.replace].apply(t,e),ng=(t,...e)=>String.prototype.endsWith.apply(t,e),cY=(t,...e)=>String.prototype.includes.apply(t,e),uY=(t,...e)=>String.prototype.lastIndexOf.apply(t,e),ND=(t,...e)=>String.prototype.indexOf.apply(t,e),nBe=(t,...e)=>String.prototype.replace.apply(t,e),ig=(t,...e)=>String.prototype.slice.apply(t,e),hA=(t,...e)=>String.prototype.startsWith.apply(t,e),iBe=Map,sBe=JSON.parse;function OD(t,e,r){return class extends r{constructor(...s){super(e(...s)),this.code=t,this.name=`${r.name} [${t}]`}}}var aBe=OD("ERR_PACKAGE_IMPORT_NOT_DEFINED",(t,e,r)=>`Package import specifier "${t}" is not defined${e?` in package ${e}package.json`:""} imported from ${r}`,TypeError),fY=OD("ERR_INVALID_MODULE_SPECIFIER",(t,e,r=void 0)=>`Invalid module "${t}" ${e}${r?` imported from ${r}`:""}`,TypeError),lBe=OD("ERR_INVALID_PACKAGE_TARGET",(t,e,r,s=!1,a=void 0)=>{let n=typeof r=="string"&&!s&&r.length&&!hA(r,"./");return e==="."?((0,oBe.default)(s===!1),`Invalid "exports" main target ${RD(r)} defined in the package config ${t}package.json${a?` imported from ${a}`:""}${n?'; targets must start with "./"':""}`):`Invalid "${s?"imports":"exports"}" target ${RD(r)} defined for '${e}' in the package config ${t}package.json${a?` imported from ${a}`:""}${n?'; targets must start with "./"':""}`},Error),LD=OD("ERR_INVALID_PACKAGE_CONFIG",(t,e,r)=>`Invalid package config ${t}${e?` while importing ${e}`:""}${r?`. ${r}`:""}`,Error),cBe=OD("ERR_PACKAGE_PATH_NOT_EXPORTED",(t,e,r=void 0)=>e==="."?`No "exports" main defined in ${t}package.json${r?` imported from ${r}`:""}`:`Package subpath '${e}' is not defined by "exports" in ${t}package.json${r?` imported from ${r}`:""}`,Error);var sN=Ie("url");function uBe(t,e){let r=Object.create(null);for(let s=0;s<e.length;s++){let a=e[s];Hm(t,a)&&(r[a]=t[a])}return r}var iN=new iBe;function ndt(t,e,r,s){let a=iN.get(t);if(a!==void 0)return a;let n=s(t);if(n===void 0){let P={pjsonPath:t,exists:!1,main:void 0,name:void 0,type:"none",exports:void 0,imports:void 0};return iN.set(t,P),P}let c;try{c=sBe(n)}catch(P){throw new LD(t,(r?`"${e}" from `:"")+(0,sN.fileURLToPath)(r||e),P.message)}let{imports:f,main:p,name:h,type:E}=uBe(c,["imports","main","name","type"]),C=Hm(c,"exports")?c.exports:void 0;(typeof f!="object"||f===null)&&(f=void 0),typeof p!="string"&&(p=void 0),typeof h!="string"&&(h=void 0),E!=="module"&&E!=="commonjs"&&(E="none");let S={pjsonPath:t,exists:!0,main:p,name:h,type:E,exports:C,imports:f};return iN.set(t,S),S}function fBe(t,e){let r=new URL("./package.json",t);for(;;){let n=r.pathname;if(ng(n,"node_modules/package.json"))break;let c=ndt((0,sN.fileURLToPath)(r),t,void 0,e);if(c.exists)return c;let f=r;if(r=new URL("../package.json",r),r.pathname===f.pathname)break}let s=(0,sN.fileURLToPath)(r),a={pjsonPath:s,exists:!1,main:void 0,name:void 0,type:"none",exports:void 0,imports:void 0};return iN.set(s,a),a}function idt(t,e,r){throw new aBe(t,e&&(0,ta.fileURLToPath)(new URL(".",e)),(0,ta.fileURLToPath)(r))}function sdt(t,e,r,s){let a=`request is not a valid subpath for the "${r?"imports":"exports"}" resolution of ${(0,ta.fileURLToPath)(e)}`;throw new fY(t,a,s&&(0,ta.fileURLToPath)(s))}function MD(t,e,r,s,a){throw typeof e=="object"&&e!==null?e=RD(e,null,""):e=`${e}`,new lBe((0,ta.fileURLToPath)(new URL(".",r)),t,e,s,a&&(0,ta.fileURLToPath)(a))}var ABe=/(^|\\|\/)((\.|%2e)(\.|%2e)?|(n|%6e|%4e)(o|%6f|%4f)(d|%64|%44)(e|%65|%45)(_|%5f)(m|%6d|%4d)(o|%6f Line truncated
`),r;c=t[++n]}else if(c===" "&&!s){a=!0;continue}else if(c==='"'){s=!s;continue}a?(r.push(c),a=!1):r[r.length-1]+=c}return s&&e.push(`invalid value for NODE_OPTIONS (unterminated string)
`),r}Dt();var[ml,ih]=process.versions.node.split(".").map(t=>parseInt(t,10)),BBe=ml>19||ml===19&&ih>=2||ml===18&&ih>=13,UZt=ml===20&&ih<6||ml===19&&ih>=3,_Zt=ml>19||ml===19&&ih>=6,HZt=ml>=21||ml===20&&ih>=10||ml===18&&ih>=19,jZt=ml>=21||ml===20&&ih>=10||ml===18&&ih>=20,GZt=ml>=22;function vBe(t){if(process.env.WATCH_REPORT_DEPENDENCIES&&process.send)if(t=t.map(e=>fe.fromPortablePath(uo.resolveVirtual(fe.toPortablePath(e)))),BBe)process.send({"watch:require":t});else for(let e of t)process.send({"watch:require":e})}function dY(t,e){let r=Number(process.env.PNP_ALWAYS_WARN_ON_FALLBACK)>0,s=Number(process.env.PNP_DEBUG_LEVEL),a=/^(?![a-zA-Z]:[\\/]|\\\\|\.{0,2}(?:\/|$))((?:node:)?(?:@[^/]+\/)?[^/]+)\/*(.*|)$/,n=/^(\/|\.{1,2}(\/|$))/,c=/\/$/,f=/^\.{0,2}\//,p={name:null,reference:null},h=[],E=new Set;if(t.enableTopLevelFallback===!0&&h.push(p),e.compatibilityMode!==!1)for(let Fe of["react-scripts","gatsby"]){let Ne=t.packageRegistry.get(Fe);if(Ne)for(let Pe of Ne.keys()){if(Pe===null)throw new Error("Assertion failed: This reference shouldn't be null");h.push({name:Fe,reference:Pe})}}let{ignorePattern:C,packageRegistry:S,packageLocatorsByLocations:P}=t;function I(Fe,Ne){return{fn:Fe,args:Ne,error:null,result:null}}function R(Fe){let Ne=process.stderr?.hasColors?.()??process.stdout.isTTY,Pe=(it,Ue)=>`\x1B[${it}m${Ue}\x1B[0m`,Ve=Fe.error;console.error(Ve?Pe("31;1",`\u2716 ${Fe.error?.message.replace(/\n.*/s,"")}`):Pe("33;1","\u203C Resolution")),Fe.args.length>0&&console.error();for(let it of Fe.args)console.error(` ${Pe("37;1","In \u2190")} ${(0,gY.inspect)(it,{colors:Ne,compact:!0})}`);Fe.result&&(console.error(),console.error(` ${Pe("37;1","Out \u2192")} ${(0,gY.inspect)(Fe.result,{colors:Ne,compact:!0})}`));let ke=new Error().stack.match(/(?<=^ +)at.*/gm)?.slice(2)??[];if(ke.length>0){console.error();for(let it of ke)console.error(` ${Pe("38;5;244",it)}`)}console.error()}function N(Fe,Ne){if(e.allowDebug===!1)return Ne;if(Number.isFinite(s)){if(s>=2)return(...Pe)=>{let Ve=I(Fe,Pe);try{return Ve.result=Ne(...Pe)}catch(ke){throw Ve.error=ke}finally{R(Ve)}};if(s>=1)return(...Pe)=>{try{return Ne(...Pe)}catch(Ve){let ke=I(Fe,Pe);throw ke.error=Ve,R(ke),Ve}}}return Ne}function U(Fe){let Ne=g(Fe);if(!Ne)throw gs("INTERNAL","Couldn't find a matching entry in the dependency tree for the specified parent (this is probably an internal error)");return Ne}function W(Fe){if(Fe.name===null)return!0;for(let Ne of t.dependencyTreeRoots)if(Ne.name===Fe.name&&Ne.reference===Fe.reference)return!0;return!1}let ee=new Set(["node","require",...wBe("--conditions")]);function ie(Fe,Ne=ee,Pe){let Ve=Ae(J.join(Fe,"internal.js"),{resolveIgnored:!0,includeDiscardFromLookup:!0});if(Ve===null)throw gs("INTERNAL",`The locator that owns the "${Fe}" path can't be found inside the dependency tree (this is probably an internal error)`);let{packageLocation:ke}=U(Ve),it=J.join(ke,Er.manifest);if(!e.fakeFs.existsSync(it))return null;let Ue=JSON.parse(e.fakeFs.readFileSync(it,"utf8"));if(Ue.exports==null)return null;let x=J.contains(ke,Fe);if(x===null)throw gs("INTERNAL","unqualifiedPath doesn't contain the packageLocation (this is probably an internal error)");x!=="."&&!f.test(x)&&(x=`./${x}`);try{let w=dBe({packageJSONUrl:(0,jm.pathToFileURL)(fe.fromPortablePath(it)),packageSubpath:x,exports:Ue.exports,base:Pe?(0,jm.pathToFileURL)(fe.fromPortablePath(Pe)):null,conditions:Ne});return fe.toPortablePath((0,jm.fileURLToPath)(w))}catch(w){throw gs("EXPORTS_RESOLUTION_FAILED",w.message,{unqualifiedPath:lf(Fe),locator:Ve,pkgJson:Ue,subpath:lf(x),conditions:Ne},w.code)}}function ue(Fe,Ne,{extensions:Pe}){let Ve;try{Ne.push(Fe),Ve=e.fakeFs.statSync(Fe)}catch{}if(Ve&&!Ve.isDirectory())return e.fakeFs.realpathSync(Fe);if(Ve&&Ve.isDirectory()){let ke;try{ke=JSON.parse(e.fakeFs.readFileSync(J.join(Fe,Er.manifest),"utf8"))}catch{}let it;if(ke&&ke.main&&(it=J.resolve(Fe,ke.main)),it&&it!==Fe){let Ue=ue(it,Ne,{extensions:Pe});if(Ue!==null)return Ue}}for(let ke=0,it=Pe.length;ke<it;ke++){let Ue=`${Fe}${Pe[ke]}`;if(Ne.push(Ue),e.fakeFs.existsSync(Ue))return Ue}if(Ve&&Ve.isDirectory())for(let ke=0,it=Pe.length;ke<it;ke++){let Ue=J.format({dir:Fe,name:"index",ext:Pe[ke]});if(Ne.push(Ue),e.fakeFs.existsSync(Ue))return Ue}return null}function le(Fe){let Ne=new sh.Module(Fe,null);return Ne.filename=Fe,Ne.paths=sh.Module._nodeModulePaths(Fe),Ne}function me(Fe,Ne){return Ne.endsWith("/")&&(Ne=J.join(Ne,"internal.js")),sh.Module._resolveFilename(fe.fromPortablePath(Fe),le(fe.fromPortablePath(Ne)),!1,{plugnplay:!1})}function pe(Fe){if(C===null)return!1;let Ne=J.contains(t.basePath,Fe);return Ne===null?!1:!!C.test(Ne.replace(/\/$/,""))}let Be={std:3,resolveVirtual:1,getAllLocators:1},Ce=p;function g({name:Fe,reference:Ne}){let Pe=S.get(Fe);if(!Pe)return null;let Ve=Pe.get(Ne);return Ve||null}function we({name:Fe,reference:Ne}){let Pe=[];for(let[Ve,ke]of S)if(Ve!==null)for(let[it,Ue]of ke)it===null||Ue.packageDependencies.get(Fe)!==Ne||Ve===Fe&&it===Ne||Pe.push({name:Ve,reLine truncated
Require request: "${Ve}"
Required by: ${ke}
`,{request:Ve,issuer:ke});return fe.toPortablePath(x)}let it,Ue=Fe.match(a);if(Ue){if(!Ne)throw gs("API_ERROR","The resolveToUnqualified function must be called with a valid issuer when the path isn't a builtin nor absolute",{request:Ve,issuer:ke});let[,x,w]=Ue,b=Ae(Ne);if(!b){let Te=me(Fe,Ne);if(Te===!1)throw gs("BUILTIN_NODE_RESOLUTION_FAILED",`The builtin node resolution algorithm was unable to resolve the requested module (it didn't go through the pnp resolver because the issuer doesn't seem to be part of the Yarn-managed dependency tree).
Require path: "${Ve}"
Required by: ${ke}
`,{request:Ve,issuer:ke});return fe.toPortablePath(Te)}let F=U(b).packageDependencies.get(x),z=null;if(F==null&&b.name!==null){let Te=t.fallbackExclusionList.get(b.name);if(!Te||!Te.has(b.reference)){for(let Ct=0,qt=h.length;Ct<qt;++Ct){let Pt=U(h[Ct]).packageDependencies.get(x);if(Pt!=null){r?z=Pt:F=Pt;break}}if(t.enableTopLevelFallback&&F==null&&z===null){let Ct=t.fallbackPool.get(x);Ct!=null&&(z=Ct)}}}let X=null;if(F===null)if(W(b))X=gs("MISSING_PEER_DEPENDENCY",`Your application tried to access ${x} (a peer dependency); this isn't allowed as there is no ancestor to satisfy the requirement. Use a devDependency if needed.
Required package: ${x}${x!==Ve?` (via "${Ve}")`:""}
Required by: ${ke}
`,{request:Ve,issuer:ke,dependencyName:x});else{let Te=ye(x,b);Te.every(lt=>W(lt))?X=gs("MISSING_PEER_DEPENDENCY",`${b.name} tried to access ${x} (a peer dependency) but it isn't provided by your application; this makes the require call ambiguous and unsound.
Required package: ${x}${x!==Ve?` (via "${Ve}")`:""}
Required by: ${b.name}@${b.reference} (via ${ke})
${Te.map(lt=>`Ancestor breaking the chain: ${lt.name}@${lt.reference}
`).join("")}
`,{request:Ve,issuer:ke,issuerLocator:Object.assign({},b),dependencyName:x,brokenAncestors:Te}):X=gs("MISSING_PEER_DEPENDENCY",`${b.name} tried to access ${x} (a peer dependency) but it isn't provided by its ancestors; this makes the require call ambiguous and unsound.
Required package: ${x}${x!==Ve?` (via "${Ve}")`:""}
Required by: ${b.name}@${b.reference} (via ${ke})
${Te.map(lt=>`Ancestor breaking the chain: ${lt.name}@${lt.reference}
`).join("")}
`,{request:Ve,issuer:ke,issuerLocator:Object.assign({},b),dependencyName:x,brokenAncestors:Te})}else F===void 0&&(!Pe&&(0,sh.isBuiltin)(Fe)?W(b)?X=gs("UNDECLARED_DEPENDENCY",`Your application tried to access ${x}. While this module is usually interpreted as a Node builtin, your resolver is running inside a non-Node resolution context where such builtins are ignored. Since ${x} isn't otherwise declared in your dependencies, this makes the require call ambiguous and unsound.
Required package: ${x}${x!==Ve?` (via "${Ve}")`:""}
Required by: ${ke}
`,{request:Ve,issuer:ke,dependencyName:x}):X=gs("UNDECLARED_DEPENDENCY",`${b.name} tried to access ${x}. While this module is usually interpreted as a Node builtin, your resolver is running inside a non-Node resolution context where such builtins are ignored. Since ${x} isn't otherwise declared in ${b.name}'s dependencies, this makes the require call ambiguous and unsound.
Required package: ${x}${x!==Ve?` (via "${Ve}")`:""}
Required by: ${ke}
`,{request:Ve,issuer:ke,issuerLocator:Object.assign({},b),dependencyName:x}):W(b)?X=gs("UNDECLARED_DEPENDENCY",`Your application tried to access ${x}, but it isn't declared in your dependencies; this makes the require call ambiguous and unsound.
Required package: ${x}${x!==Ve?` (via "${Ve}")`:""}
Required by: ${ke}
`,{request:Ve,issuer:ke,dependencyName:x}):X=gs("UNDECLARED_DEPENDENCY",`${b.name} tried to access ${x}, but it isn't declared in its dependencies; this makes the require call ambiguous and unsound.
Required package: ${x}${x!==Ve?` (via "${Ve}")`:""}
Required by: ${b.name}@${b.reference} (via ${ke})
`,{request:Ve,issuer:ke,issuerLocator:Object.assign({},b),dependencyName:x}));if(F==null){if(z===null||X===null)throw X||new Error("Assertion failed: Expected an error to have been set");F=z;let Te=X.message.replace(/\n.*/g,"");X.message=Te,!E.has(Te)&&s!==0&&(E.add(Te),process.emitWarning(X))}let $=Array.isArray(F)?{name:F[0],reference:F[1]}:{name:x,reference:F},oe=U($);if(!oe.packageLocation)throw gs("MISSING_DEPENDENCY",`A dependency seems valid but didn't get installed for some reason. This might be caused by a partial install, such as dev vs prod.
Required package: ${$.name}@${$.reference}${$.name!==Ve?` (via "${Ve}")`:""}
Required by: ${b.name}@${b.reference} (via ${ke})
`,{request:Ve,issuer:ke,dependencyLocator:Object.assign({},$)});let xe=oe.packageLocation;w?it=J.join(xe,w):it=xe}else if(J.isAbsolute(Fe))it=J.normalize(Fe);else{if(!Ne)throw gs("API_ERROR","The resolveToUnqualified function must be called with a valid issuer when the path isn't a builtin nor absolute",{request:Ve,issuer:ke});let x=J.resolve(Ne);Ne.match(c)?it=J.normalize(J.join(x,Fe)):it=J.normalize(J.join(J.dirname(x),Fe))}return J.normalize(it)}function De(Fe,Ne,Pe=ee,Ve){if(n.test(Fe))return Ne;let ke=ie(Ne,Pe,Ve);return ke?J.normalize(ke):Ne}function Re(Fe,{extensions:Ne=Object.keys(sh.Module._extensions)}={}){let Pe=[],Ve=ue(Fe,Pe,{extensions:Ne});if(Ve)return J.normalize(Ve);{vBe(Pe.map(Ue=>fe.fromPortablePath(Ue)));let ke=lf(Fe),it=Ae(Fe);if(it){let{packageLocation:Ue}=U(it),x=!0;try{e.fakeFs.accessSync(Ue)}catch(w){if(w?.code==="ENOENT")x=!1;else{let b=(w?.message??w??"empty exception thrown").replace(/^[A-Z]/,y=>y.toLowerCase());throw gs("QUALIFIED_PATH_RESOLUTION_FAILED",`Required package exists but could not be accessed (${b}).
Missing package: ${it.name}@${it.reference}
Expected package location: ${lf(Ue)}
`,{unqualifiedPath:ke,extensions:Ne})}}if(!x){let w=Ue.includes("/unplugged/")?"Required unplugged package missing from disk. This may happen when switching branches without running installs (unplugged packages must be fully materialized on disk to work).":"Required package missing from disk. If you keep your packages inside your repository then restarting the Node process may be enough. Otherwise, try to run an install first.";throw gs("QUALIFIED_PATH_RESOLUTION_FAILED",`${w}
Missing package: ${it.name}@${it.reference}
Expected package location: ${lf(Ue)}
`,{unqualifiedPath:ke,extensions:Ne})}}throw gs("QUALIFIED_PATH_RESOLUTION_FAILED",`Qualified path resolution failed: we looked for the following paths, but none could be accessed.
Source path: ${ke}
${Pe.map(Ue=>`Not found: ${lf(Ue)}
`).join("")}`,{unqualifiedPath:ke,extensions:Ne})}}function mt(Fe,Ne,Pe){if(!Ne)throw new Error("Assertion failed: An issuer is required to resolve private import mappings");let Ve=mBe({name:Fe,base:(0,jm.pathToFileURL)(fe.fromPortablePath(Ne)),conditions:Pe.conditions??ee,readFileSyncFn:se});if(Ve instanceof URL)return Re(fe.toPortablePath((0,jm.fileURLToPath)(Ve)),{extensions:Pe.extensions});if(Ve.startsWith("#"))throw new Error("Mapping from one private import to another isn't allowed");return j(Ve,Ne,Pe)}function j(Fe,Ne,Pe={}){try{if(Fe.startsWith("#"))return mt(Fe,Ne,Pe);let{considerBuiltins:Ve,extensions:ke,conditions:it}=Pe,Ue=Z(Fe,Ne,{considerBuiltins:Ve});if(Fe==="pnpapi")return Ue;if(Ue===null)return null;let x=()=>Ne!==null?pe(Ne):!1,w=(!Ve||!(0,sh.isBuiltin)(Fe))&&!x()?De(Fe,Ue,it,Ne):Ue;return Re(w,{extensions:ke})}catch(Ve){throw Object.hasOwn(Ve,"pnpCode")&&Object.assign(Ve.data,{request:lf(Fe),issuer:Ne&&lf(Ne)}),Ve}}function rt(Fe){let Ne=J.normalize(Fe),Pe=uo.resolveVirtual(Ne);return Pe!==Ne?Pe:null}return{VERSIONS:Be,topLevel:Ce,getLocator:(Fe,Ne)=>Array.isArray(Ne)?{name:Ne[0],reference:Ne[1]}:{name:Fe,reference:Ne},getDependencyTreeRoots:()=>[...t.dependencyTreeRoots],getAllLocators(){let Fe=[];for(let[Ne,Pe]of S)for(let Ve of Pe.keys())Ne!==null&&Ve!==null&&Fe.push({name:Ne,reference:Ve});return Fe},getPackageInformation:Fe=>{let Ne=g(Fe);if(Ne===null)return null;let Pe=fe.fromPortablePath(Ne.packageLocation);return{...Ne,packageLocation:Pe}},findPackageLocator:Fe=>Ae(fe.toPortablePath(Fe)),resolveToUnqualified:N("resolveToUnqualified",(Fe,Ne,Pe)=>{let Ve=Ne!==null?fe.toPortablePath(Ne):null,ke=Z(fe.toPortablePath(Fe),Ve,Pe);return ke===null?null:fe.fromPortablePath(ke)}),resolveUnqualified:N("resolveUnqualified",(Fe,Ne)=>fe.fromPortablePath(Re(fe.toPortablePath(Fe),Ne))),resolveRequest:N("resolveRequest",(Fe,Ne,Pe)=>{let Ve=Ne!==null?fe.toPortablePath(Ne):null,ke=j(fe.toPortablePath(Fe),Ve,Pe);return ke===null?null:fe.fromPortablePath(ke)}),resolveVirtual:N("resolveVirtual",Fe=>{let Ne=rt(fe.toPortablePath(Fe));return Ne!==null?fe.fromPortablePath(Ne):null})}}Dt();var SBe=(t,e,r)=>{let s=TD(t),a=sY(s,{basePath:e}),n=fe.join(e,Er.pnpCjs);return dY(a,{fakeFs:r,pnpapiResolution:n})};var yY=ut(bBe());Yt();var gA={};Vt(gA,{checkManifestCompatibility:()=>PBe,extractBuildRequest:()=>oN,getExtractHint:()=>EY,hasBindingGyp:()=>IY});Ge();Dt();function PBe(t){return G.isPackageCompatible(t,Ui.getArchitectureSet())}function oN(t,e,r,{configuration:s}){let a=[];for(let n of["preinstall","install","postinstall"])e.manifest.scripts.has(n)&&a.push({type:0,script:n});return!e.manifest.scripts.has("install")&&e.misc.hasBindingGyp&&a.push({type:1,script:"node-gyp rebuild"}),a.length===0?null:t.linkType!=="HARD"?{skipped:!0,explain:n=>n.reportWarningOnce(6,`${G.prettyLocator(s,t)} lists build scripts, but is referenced through a soft link. Soft links don't support build scripts, so they'll be ignored.`)}:r&&r.built===!1?{skipped:!0,explain:n=>n.reportInfoOnce(5,`${G.prettyLocator(s,t)} lists build scripts, but its build has been explicitly disabled through configuration.`)}:!s.get("enableScripts")&&!r.built?{skipped:!0,explain:n=>n.reportWarningOnce(4,`${G.prettyLocator(s,t)} lists build scripts, but all build scripts have been disabled.`)}:PBe(t)?{skipped:!1,directives:a}:{skipped:!0,explain:n=>n.reportWarningOnce(76,`${G.prettyLocator(s,t)} The ${Ui.getArchitectureName()} architecture is incompatible with this package, build skipped.`)}}var gdt=new Set([".exe",".bin",".h",".hh",".hpp",".c",".cc",".cpp",".java",".jar",".node"]);function EY(t){return t.packageFs.getExtractHint({relevantExtensions:gdt})}function IY(t){let e=J.join(t.prefixPath,"binding.gyp");return t.packageFs.existsSync(e)}var HD={};Vt(HD,{getUnpluggedPath:()=>_D});Ge();Dt();function _D(t,{configuration:e}){return J.resolve(e.get("pnpUnpluggedFolder"),G.slugifyLocator(t))}var ddt=new Set([G.makeIdent(null,"open").identHash,G.makeIdent(null,"opn").identHash]),sg=class{constructor(){this.mode="strict";this.pnpCache=new Map}getCustomDataKey(){return JSON.stringify({name:"PnpLinker",version:2})}supportsPackage(e,r){return this.isEnabled(r)}async findPackageLocation(e,r){if(!this.isEnabled(r))throw new Error("Assertion failed: Expected the PnP linker to be enabled");let s=og(r.project).cjs;if(!ce.existsSync(s))throw new nt(`The project in ${he.pretty(r.project.configuration,`${r.project.cwd}/package.json`,he.Type.PATH)} doesn't seem to have been installed - running an install there might help`);let a=je.getFactoryWithDefault(this.pnpCache,s,()=>je.dynamicRequire(s,{cachingStrategy:je.CachingStrategy.FsTime})),n={name:G.stringifyIdent(e),reference:e.reference},c=a.getPackageInformation(n);if(!c)throw new nt(`Couldn't find ${G.prettyLocator(r.project.configuration,e)} in the currently installed PnP map - running an install might help`);return fe.toPortablePath(c.packageLocation)}async findPackageLocator(e,r){if(!this.isEnabled(r))return nullLine truncated
`,n+=`# cause your node_modules installation to become invalidated.
`,n+=`
`,n+=`__metadata:
`,n+=` version: ${HBe}
`,n+=` nmMode: ${s.value}
`;let c=Array.from(e.keys()).sort(),f=G.stringifyLocator(t.topLevelWorkspace.anchoredLocator);for(let E of c){let C=e.get(E);n+=`
`,n+=`${JSON.stringify(E)}:
`,n+=` locations:
`;for(let S of C.locations){let P=J.contains(t.cwd,S);if(P===null)throw new Error(`Assertion failed: Expected the path to be within the project (${S})`);n+=` - ${JSON.stringify(P)}
`}if(C.aliases.length>0){n+=` aliases:
`;for(let S of C.aliases)n+=` - ${JSON.stringify(S)}
`}if(E===f&&r.size>0){n+=` bin:
`;for(let[S,P]of r){let I=J.contains(t.cwd,S);if(I===null)throw new Error(`Assertion failed: Expected the path to be within the project (${S})`);n+=` ${JSON.stringify(I)}:
`;for(let[R,N]of P){let U=J.relative(J.join(S,Ti),N);n+=` ${JSON.stringify(R)}: ${JSON.stringify(U)}
`}}}}let p=t.cwd,h=J.join(p,Ti,jBe);a&&await ce.removePromise(h),await ce.changeFilePromise(h,n,{automaticNewlines:!0})}async function PY(t,{unrollAliases:e=!1}={}){let r=t.cwd,s=J.join(r,Ti,jBe),a;try{a=await ce.statPromise(s)}catch{}if(!a)return null;let n=ls(await ce.readFilePromise(s,"utf8"));if(n.__metadata.version>HBe)return null;let c=n.__metadata.nmMode||"classic",f=new Map,p=new Map;delete n.__metadata;for(let[h,E]of Object.entries(n)){let C=E.locations.map(P=>J.join(r,P)),S=E.bin;if(S)for(let[P,I]of Object.entries(S)){let R=J.join(r,fe.toPortablePath(P)),N=je.getMapWithDefault(p,R);for(let[U,W]of Object.entries(I))N.set(U,fe.toPortablePath([R,Ti,W].join(J.sep)))}if(f.set(h,{target:vt.dot,linkType:"HARD",locations:C,aliases:E.aliases||[]}),e&&E.aliases)for(let P of E.aliases){let{scope:I,name:R}=G.parseLocator(h),N=G.makeLocator(G.makeIdent(I,R),P),U=G.stringifyLocator(N);f.set(U,{target:vt.dot,linkType:"HARD",locations:C,aliases:[]})}}return{locatorMap:f,binSymlinks:p,locationTree:GBe(f,{skipPrefix:t.cwd}),nmMode:c,mtimeMs:a.mtimeMs}}var bw=async(t,e)=>{if(t.split(J.sep).indexOf(Ti)<0)throw new Error(`Assertion failed: trying to remove dir that doesn't contain node_modules: ${t}`);try{let r;if(!e.innerLoop&&(r=await ce.lstatPromise(t),!r.isDirectory()&&!r.isSymbolicLink()||r.isSymbolicLink()&&!e.isWorkspaceDir)){await ce.unlinkPromise(t);return}let s=await ce.readdirPromise(t,{withFileTypes:!0});for(let n of s){let c=J.join(t,n.name);n.isDirectory()?(n.name!==Ti||e&&e.innerLoop)&&await bw(c,{innerLoop:!0,contentsOnly:!1}):await ce.unlinkPromise(c)}let a=!e.innerLoop&&e.isWorkspaceDir&&r?.isSymbolicLink();!e.contentsOnly&&!a&&await ce.rmdirPromise(t)}catch(r){if(r.code!=="ENOENT"&&r.code!=="ENOTEMPTY")throw r}},LBe=4,lN=(t,{skipPrefix:e})=>{let r=J.contains(e,t);if(r===null)throw new Error(`Assertion failed: Writing attempt prevented to ${t} which is outside project root: ${e}`);let s=r.split(J.sep).filter(p=>p!==""),a=s.indexOf(Ti),n=s.slice(0,a).join(J.sep),c=J.join(e,n),f=s.slice(a);return{locationRoot:c,segments:f}},GBe=(t,{skipPrefix:e})=>{let r=new Map;if(t===null)return r;let s=()=>({children:new Map,linkType:"HARD"});for(let[a,n]of t.entries()){if(n.linkType==="SOFT"&&J.contains(e,n.target)!==null){let f=je.getFactoryWithDefault(r,n.target,s);f.locator=a,f.linkType=n.linkType}for(let c of n.locations){let{locationRoot:f,segments:p}=lN(c,{skipPrefix:e}),h=je.getFactoryWithDefault(r,f,s);for(let E=0;E<p.length;++E){let C=p[E];if(C!=="."){let S=je.getFactoryWithDefault(h.children,C,s);h.children.set(C,S),h=S}E===p.length-1&&(h.locator=a,h.linkType=n.linkType)}}}return r},QY=async(t,e,r)=>{if(process.platform==="win32"&&r==="junctions"){let s;try{s=await ce.lstatPromise(t)}catch{}if(!s||s.isDirectory()){await ce.symlinkPromise(t,e,"junction");return}}await ce.symlinkPromise(J.relative(J.dirname(e),t),e)};async function qBe(t,e,r){let s=J.join(t,`${xY.default.randomBytes(16).toString("hex")}.tmp`);try{await ce.writeFilePromise(s,r);try{await ce.linkPromise(s,e)}catch{}}finally{await ce.unlinkPromise(s)}}async function Hdt({srcPath:t,dstPath:e,entry:r,globalHardlinksStore:s,baseFs:a,nmMode:n}){if(r.kind==="file"){if(n.value==="hardlinks-global"&&s&&r.digest){let f=J.join(s,r.digest.substring(0,2),`${r.digest.substring(2)}.dat`),p;try{let h=await ce.statPromise(f);if(h&&(!r.mtimeMs||h.mtimeMs>r.mtimeMs||h.mtimeMs<r.mtimeMs-Mdt))if(await Nn.checksumFile(f,{baseFs:ce,algorithm:"sha1"})!==r.digest){let C=J.join(s,`${xY.default.randomBytes(16).toString("hex")}.tmp`);await ce.renamePromise(f,C);let S=await a.readFilePromise(t);await ce.writeFilePromise(C,S);try{await ce.linkPromise(C,f),r.mtimeMs=new Date().getTime(),await ce.unlinkPromise(C)}catch{}}else r.mtimeMs||(r.mtimeMs=Math.ceil(h.mtimeMs));await ce.linkPromise(f,e),p=!0}catch{p=!1}if(!p){let h=await a.readFilePromise(t);await qBe(s,f,h),r.mtimeMs=new Date().getTime();try{await ce.linkPromise(f,e)}catch(E){E&&E.code&&E.code=="EXDEV"&&(n.value="hardlinks-local",await a.copyFilePromise(t,e))}}}else await a.copyFilePromise(t,e);let c=r.mode&511;c!==420&&await ce.chmodPromise(e,c)}}var jdt=async(t,e,{baseFs:r,globalHardlinksStore:s,nmMode:a,windowsLinkType:n,packageChecksum:c})=>{await ce.mkdirPromise(t,{recursive:!0});let f=async(E=vt.dot)=>{let C=J.join(e,E),S=await r.readdirPromise(C,{withFileTypes:!0}),P=new Map;for(let I of S){let R=J.join(E,I.name),N,U=J.join(C,I.name);if(I.isFile()){if(N={kind:"file",mode:(await r.lstatPromise(U)).mode},a.value==="hardlinks-global"){let W=await Nn.checksumFile(U,{baseFs:r,algorithm:"sha1"});N.digest=W}}else if(I.isDirectory())N={kind:"directory"};else if(I.isSymbolicLink())N={kind:"symlink",symlinkTo:await r.readlinkPromise(U)};else throw new Error(`Unsupported file type (file: ${U}, mode: 0o${await r.statSync(U).mode.toString(8).padStart(6,"0")})`);if(P.set(R,N),I.isDirectory()&&R!==Ti){let W=await f(R);for(let[ee,ie]of W)P.set(ee,ie)}}return P},p;if(a.value==="hardlinks-global"&&s&&c){let E=J.join(s,c.sub Line truncated
`)),process.env.YARN_IS_TEST_ENV)return process.env.YARN_INJECT_NPM_2FA_TOKEN||"";let{otp:s}=await(0,LY.prompt)({type:"password",name:"otp",message:"One-time password:",required:!0,onCancel:()=>process.exit(130)});return process.stdout.write(`
`),s}function uN(t){if(t.originalError?.name!=="HTTPError")return!1;try{return(t.originalError?.response.headers["www-authenticate"].split(/,\s*/).map(r=>r.toLowerCase())).includes("otp")}catch{return!1}}function kw(t){return{"npm-otp":t}}async function gmt(t,{configuration:e,ident:r}){let s=null;if(process.env.GITLAB_CI)s=process.env.NPM_ID_TOKEN||null;else if(process.env.GITHUB_ACTIONS){if(!(process.env.ACTIONS_ID_TOKEN_REQUEST_URL&&process.env.ACTIONS_ID_TOKEN_REQUEST_TOKEN))return null;let a=`npm:${new URL(t).host.replace("registry.yarnpkg.com","registry.npmjs.org").replace("yarn.npmjs.org","registry.npmjs.org")}`,n=new URL(process.env.ACTIONS_ID_TOKEN_REQUEST_URL);n.searchParams.append("audience",a),s=(await nn.get(n.href,{configuration:e,jsonResponse:!0,headers:{Authorization:`Bearer ${process.env.ACTIONS_ID_TOKEN_REQUEST_TOKEN}`}})).value}if(!s)return null;try{return(await nn.post(`${t}/-/npm/v1/oidc/token/exchange/package${WD(r)}`,null,{configuration:e,jsonResponse:!0,headers:{Authorization:`Bearer ${s}`}})).token||null}catch{}return null}var VD=class{supports(e,r){if(!e.reference.startsWith(oi))return!1;let{selector:s,params:a}=G.parseRange(e.reference);return!(!$Be.default.valid(s)||a===null||typeof a.__archiveUrl!="string")}getLocalPath(e,r){return null}async fetch(e,r){let s=r.checksums.get(e.locatorHash)||null,[a,n,c]=await r.cache.fetchPackageFromCache(e,s,{onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${G.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the remote server`),loader:()=>this.fetchFromNetwork(e,r),...r.cacheOptions});return{packageFs:a,releaseFs:n,prefixPath:G.getIdentVendorPath(e),checksum:c}}async fetchFromNetwork(e,r){let{params:s}=G.parseRange(e.reference);if(s===null||typeof s.__archiveUrl!="string")throw new Error("Assertion failed: The archiveUrl querystring parameter should have been available");let a=await Wm(s.__archiveUrl,{customErrorMessage:qm,configuration:r.project.configuration,ident:e});return await ps.convertToZip(a,{configuration:r.project.configuration,prefixPath:G.getIdentVendorPath(e),stripComponents:1})}};Ge();var JD=class{supportsDescriptor(e,r){return!(!e.range.startsWith(oi)||!G.tryParseDescriptor(e.range.slice(oi.length),!0))}supportsLocator(e,r){return!1}shouldPersistResolution(e,r){throw new Error("Unreachable")}bindDescriptor(e,r,s){return e}getResolutionDependencies(e,r){let s=r.project.configuration.normalizeDependency(G.parseDescriptor(e.range.slice(oi.length),!0));return r.resolver.getResolutionDependencies(s,r)}async getCandidates(e,r,s){let a=s.project.configuration.normalizeDependency(G.parseDescriptor(e.range.slice(oi.length),!0));return await s.resolver.getCandidates(a,r,s)}async getSatisfying(e,r,s,a){let n=a.project.configuration.normalizeDependency(G.parseDescriptor(e.range.slice(oi.length),!0));return a.resolver.getSatisfying(n,r,s,a)}resolve(e,r){throw new Error("Unreachable")}};Ge();Ge();var eve=ut(Ai());var oh=class t{supports(e,r){if(!e.reference.startsWith(oi))return!1;let s=new URL(e.reference);return!(!eve.default.valid(s.pathname)||s.searchParams.has("__archiveUrl"))}getLocalPath(e,r){return null}async fetch(e,r){let s=r.checksums.get(e.locatorHash)||null,[a,n,c]=await r.cache.fetchPackageFromCache(e,s,{onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${G.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the remote registry`),loader:()=>this.fetchFromNetwork(e,r),...r.cacheOptions});return{packageFs:a,releaseFs:n,prefixPath:G.getIdentVendorPath(e),checksum:c}}async fetchFromNetwork(e,r){let s;try{s=await Wm(t.getLocatorUrl(e),{customErrorMessage:qm,configuration:r.project.configuration,ident:e})}catch{s=await Wm(t.getLocatorUrl(e).replace(/%2f/g,"/"),{customErrorMessage:qm,configuration:r.project.configuration,ident:e})}return await ps.convertToZip(s,{configuration:r.project.configuration,prefixPath:G.getIdentVendorPath(e),stripComponents:1})}static isConventionalTarballUrl(e,r,{configuration:s}){let a=Pw(e.scope,{configuration:s}),n=t.getLocatorUrl(e);return r=r.replace(/^https?:(\/\/(?:[^/]+\.)?npmjs.org(?:$|\/))/,"https:$1"),a=a.replace(/^https:\/\/registry\.npmjs\.org($|\/)/,"https://registry.yarnpkg.com$1"),r=r.replace(/^https:\/\/registry\.npmjs\.org($|\/)/,"https://registry.yarnpkg.com$1"),r===a+n||r===a+n.replace(/%2f/g,"/")}static getLocatorUrl(e){let r=Fr.clean(e.reference.slice(oi.length));if(r===null)throw new jt(10,"The npm semver resolver got selected, but the version isn't semver");return`${WD(e)}/-/${e.name}-${r}.tgz`}};Ge();Ge();Ge();var UY=ut(Ai());var fN=G.makeIdent(null,"node-gyp"),dmt=/\b(node-gyp|prebuild-install)\b/,KD=class{supportsDescriptor(e,r){return e.range.startsWith(oi)?!!Fr.validRange(e.range.slice(oi.length)):!1}supportsLocator(e,r){if(!e.reference.startsWith(oi))return!1;let{selector:s}=G.parseRange(e.reference);return!!UY.default.valid(s)}shouldPersiLine truncated
https://docs.gitlab.com/ee/ci/secrets/id_token_authentication.html`);r={_type:ZDt,subject:t,predicateType:ebt,predicate:{buildType:`${ibt}/${sbt}`,builder:{id:`${Bt.CI_PROJECT_URL}/-/runners/${Bt.CI_RUNNER_ID}`},invocation:{configSource:{uri:`git+${Bt.CI_PROJECT_URL}`,digest:{sha1:Bt.CI_COMMIT_SHA},entryPoint:Bt.CI_JOB_NAME},parameters:{CI:Bt.CI,CI_API_GRAPHQL_URL:Bt.CI_API_GRAPHQL_URL,CI_API_V4_URL:Bt.CI_API_V4_URL,CI_BUILD_BEFORE_SHA:Bt.CI_BUILD_BEFORE_SHA,CI_BUILD_ID:Bt.CI_BUILD_ID,CI_BUILD_NAME:Bt.CI_BUILD_NAME,CI_BUILD_REF:Bt.CI_BUILD_REF,CI_BUILD_REF_NAME:Bt.CI_BUILD_REF_NAME,CI_BUILD_REF_SLUG:Bt.CI_BUILD_REF_SLUG,CI_BUILD_STAGE:Bt.CI_BUILD_STAGE,CI_COMMIT_BEFORE_SHA:Bt.CI_COMMIT_BEFORE_SHA,CI_COMMIT_BRANCH:Bt.CI_COMMIT_BRANCH,CI_COMMIT_REF_NAME:Bt.CI_COMMIT_REF_NAME,CI_COMMIT_REF_PROTECTED:Bt.CI_COMMIT_REF_PROTECTED,CI_COMMIT_REF_SLUG:Bt.CI_COMMIT_REF_SLUG,CI_COMMIT_SHA:Bt.CI_COMMIT_SHA,CI_COMMIT_SHORT_SHA:Bt.CI_COMMIT_SHORT_SHA,CI_COMMIT_TIMESTAMP:Bt.CI_COMMIT_TIMESTAMP,CI_COMMIT_TITLE:Bt.CI_COMMIT_TITLE,CI_CONFIG_PATH:Bt.CI_CONFIG_PATH,CI_DEFAULT_BRANCH:Bt.CI_DEFAULT_BRANCH,CI_DEPENDENCY_PROXY_DIRECT_GROUP_IMAGE_PREFIX:Bt.CI_DEPENDENCY_PROXY_DIRECT_GROUP_IMAGE_PREFIX,CI_DEPENDENCY_PROXY_GROUP_IMAGE_PREFIX:Bt.CI_DEPENDENCY_PROXY_GROUP_IMAGE_PREFIX,CI_DEPENDENCY_PROXY_SERVER:Bt.CI_DEPENDENCY_PROXY_SERVER,CI_DEPENDENCY_PROXY_USER:Bt.CI_DEPENDENCY_PROXY_USER,CI_JOB_ID:Bt.CI_JOB_ID,CI_JOB_NAME:Bt.CI_JOB_NAME,CI_JOB_NAME_SLUG:Bt.CI_JOB_NAME_SLUG,CI_JOB_STAGE:Bt.CI_JOB_STAGE,CI_JOB_STARTED_AT:Bt.CI_JOB_STARTED_AT,CI_JOB_URL:Bt.CI_JOB_URL,CI_NODE_TOTAL:Bt.CI_NODE_TOTAL,CI_PAGES_DOMAIN:Bt.CI_PAGES_DOMAIN,CI_PAGES_URL:Bt.CI_PAGES_URL,CI_PIPELINE_CREATED_AT:Bt.CI_PIPELINE_CREATED_AT,CI_PIPELINE_ID:Bt.CI_PIPELINE_ID,CI_PIPELINE_IID:Bt.CI_PIPELINE_IID,CI_PIPELINE_SOURCE:Bt.CI_PIPELINE_SOURCE,CI_PIPELINE_URL:Bt.CI_PIPELINE_URL,CI_PROJECT_CLASSIFICATION_LABEL:Bt.CI_PROJECT_CLASSIFICATION_LABEL,CI_PROJECT_DESCRIPTION:Bt.CI_PROJECT_DESCRIPTION,CI_PROJECT_ID:Bt.CI_PROJECT_ID,CI_PROJECT_NAME:Bt.CI_PROJECT_NAME,CI_PROJECT_NAMESPACE:Bt.CI_PROJECT_NAMESPACE,CI_PROJECT_NAMESPACE_ID:Bt.CI_PROJECT_NAMESPACE_ID,CI_PROJECT_PATH:Bt.CI_PROJECT_PATH,CI_PROJECT_PATH_SLUG:Bt.CI_PROJECT_PATH_SLUG,CI_PROJECT_REPOSITORY_LANGUAGES:Bt.CI_PROJECT_REPOSITORY_LANGUAGES,CI_PROJECT_ROOT_NAMESPACE:Bt.CI_PROJECT_ROOT_NAMESPACE,CI_PROJECT_TITLE:Bt.CI_PROJECT_TITLE,CI_PROJECT_URL:Bt.CI_PROJECT_URL,CI_PROJECT_VISIBILITY:Bt.CI_PROJECT_VISIBILITY,CI_REGISTRY:Bt.CI_REGISTRY,CI_REGISTRY_IMAGE:Bt.CI_REGISTRY_IMAGE,CI_REGISTRY_USER:Bt.CI_REGISTRY_USER,CI_RUNNER_DESCRIPTION:Bt.CI_RUNNER_DESCRIPTION,CI_RUNNER_ID:Bt.CI_RUNNER_ID,CI_RUNNER_TAGS:Bt.CI_RUNNER_TAGS,CI_SERVER_HOST:Bt.CI_SERVER_HOST,CI_SERVER_NAME:Bt.CI_SERVER_NAME,CI_SERVER_PORT:Bt.CI_SERVER_PORT,CI_SERVER_PROTOCOL:Bt.CI_SERVER_PROTOCOL,CI_SERVER_REVISION:Bt.CI_SERVER_REVISION,CI_SERVER_SHELL_SSH_HOST:Bt.CI_SERVER_SHELL_SSH_HOST,CI_SERVER_SHELL_SSH_PORT:Bt.CI_SERVER_SHELL_SSH_PORT,CI_SERVER_URL:Bt.CI_SERVER_URL,CI_SERVER_VERSION:Bt.CI_SERVER_VERSION,CI_SERVER_VERSION_MAJOR:Bt.CI_SERVER_VERSION_MAJOR,CI_SERVER_VERSION_MINOR:Bt.CI_SERVER_VERSION_MINOR,CI_SERVER_VERSION_PATCH:Bt.CI_SERVER_VERSION_PATCH,CI_TEMPLATE_REGISTRY_HOST:Bt.CI_TEMPLATE_REGISTRY_HOST,GITLAB_CI:Bt.GITLAB_CI,GITLAB_FEATURES:Bt.GITLAB_FEATURES,GITLAB_USER_ID:Bt.GITLAB_USER_ID,GITLAB_USER_LOGIN:Bt.GITLAB_USER_LOGIN,RUNNER_GENERATE_ARTIFACTS_METADATA:Bt.RUNNER_GENERATE_ARTIFACTS_METADATA},environment:{name:Bt.CI_RUNNER_DESCRIPTION,architecture:Bt.CI_RUNNER_EXECUTABLE_ARCH,server:Bt.CI_SERVER_URL,project:Bt.CI_PROJECT_PATH,job:{id:Bt.CI_JOB_ID},pipeline:{id:Bt.CI_PIPELINE_ID,ref:Bt.CI_CONFIG_PATH}}},metadata:{buildInvocationId:`${Bt.CI_JOB_URL}`,completeness:{parameters:!0,environment:!0,materials:!1},reproducible:!1},materials:[{uri:`git+${Bt.CI_PROJECT_URL}`,digest:{sha1:Bt.CI_COMMIT_SHA}}]}}}else throw new jt(91,"Provenance generation is only supported in GitHub Actions and GitLab CI");return Hxe.attest(Buffer.from(JSON.stringify(r)),XDt,e)};async function obt(t,e,{access:r,tag:s,registry:a,gitHead:n,provenance:c}){let f=t.manifest.name,p=t.manifest.version,h=G.stringifyIdent(f),E=Gxe.default.fromData(e,{algorithms:["sha1","sha512"]}),C=r??qxe(t,f),S=await Wxe(t),P=await yA.genPackageManifest(t),I=`${h}-${p}.tgz`,R=new URL(`${Jc(a)}/${h}/-/${I}`),N={[I]:{content_type:"application/octet-stream",data:e.toString("base64"),length:e.length}};if(c){let U={name:`pkg:npm/${h.replace(/^@/,"%40")}@${p}`,digest:{sha512:E.sha512[0].hexDigest()}},W=await jxe([U]),ee=JSON.stringify(W);N[`${h}-${p}.sigstore`]={content_type:W.mediaType,data:ee,length:ee.length}}return{_id:h,_attachments:N,name:h,access:C,"dist-tags":{[s]:p},versions:{[p]:{...P,_id:`${h}@${p}`,name:h,version:p,gitHead:n,dist:{shasum:E.sha1[0].hexDigest(),integrity:E.sha512[0].toString(),tarball:R.toString()}}},readme:S}}async function abt(t){try{let{stdout:e}=await qr.execvp("git",["rev-parse","--revs-only","HEAD"],{cwd:t});return e.trim()===""?void 0:e.trim()}catch{return} Line truncated
`;try{a=await ce.readFilePromise(e,"utf8")}catch(n){if(n.code==="ENOENT")return a;throw n}return a}var RK={npmAlwaysAuth:{description:"URL of the selected npm registry (note: npm enterprise isn't supported)",type:"BOOLEAN",default:!1},npmAuthIdent:{description:"Authentication identity for the npm registry (_auth in npm and yarn v1)",type:"SECRET",default:null},npmAuthToken:{description:"Authentication token for the npm registry (_authToken in npm and yarn v1)",type:"SECRET",default:null}},Yxe={npmAuditRegistry:{description:"Registry to query for audit reports",type:"STRING",default:null},npmPublishRegistry:{description:"Registry to push packages to",type:"STRING",default:null},npmRegistryServer:{description:"URL of the selected npm registry (note: npm enterprise isn't supported)",type:"STRING",default:"https://registry.yarnpkg.com"}},lbt={npmMinimalAgeGate:{description:"Minimum age of a package version according to the publish date on the npm registry to be considered for installation",type:"DURATION",unit:"m",default:"0m"},npmPreapprovedPackages:{description:"Array of package descriptors or package name glob patterns to exclude from the minimum release age check",type:"STRING",isArray:!0,default:[]}},cbt={configuration:{...RK,...Yxe,...lbt,npmScopes:{description:"Settings per package scope",type:"MAP",valueDefinition:{description:"",type:"SHAPE",properties:{...RK,...Yxe}}},npmRegistries:{description:"Settings per registry",type:"MAP",normalizeKeys:Jc,valueDefinition:{description:"",type:"SHAPE",properties:{...RK}}}},fetchers:[VD,oh],resolvers:[JD,KD,zD]},ubt=cbt;var qK={};Vt(qK,{NpmAuditCommand:()=>D1,NpmInfoCommand:()=>b1,NpmLoginCommand:()=>P1,NpmLogoutCommand:()=>k1,NpmPublishCommand:()=>Q1,NpmTagAddCommand:()=>R1,NpmTagListCommand:()=>T1,NpmTagRemoveCommand:()=>F1,NpmWhoamiCommand:()=>N1,default:()=>wbt,npmAuditTypes:()=>zb,npmAuditUtils:()=>kL});Ge();Ge();Yt();var UK=ut(Go());Ul();var zb={};Vt(zb,{Environment:()=>Jb,Severity:()=>Kb});var Jb=(s=>(s.All="all",s.Production="production",s.Development="development",s))(Jb||{}),Kb=(n=>(n.Info="info",n.Low="low",n.Moderate="moderate",n.High="high",n.Critical="critical",n))(Kb||{});var kL={};Vt(kL,{allSeverities:()=>S1,getPackages:()=>MK,getReportTree:()=>OK,getSeverityInclusions:()=>NK,getTopLevelDependencies:()=>LK});Ge();var Vxe=ut(Ai());var S1=["info","low","moderate","high","critical"];function NK(t){if(typeof t>"u")return new Set(S1);let e=S1.indexOf(t),r=S1.slice(e);return new Set(r)}function OK(t){let e={},r={children:e};for(let[s,a]of je.sortMap(Object.entries(t),n=>n[0]))for(let n of je.sortMap(a,c=>`${c.id}`))e[`${s}/${n.id}`]={value:he.tuple(he.Type.IDENT,G.parseIdent(s)),children:{ID:typeof n.id<"u"&&{label:"ID",value:he.tuple(he.Type.ID,n.id)},Issue:{label:"Issue",value:he.tuple(he.Type.NO_HINT,n.title)},URL:typeof n.url<"u"&&{label:"URL",value:he.tuple(he.Type.URL,n.url)},Severity:{label:"Severity",value:he.tuple(he.Type.NO_HINT,n.severity)},"Vulnerable Versions":{label:"Vulnerable Versions",value:he.tuple(he.Type.RANGE,n.vulnerable_versions)},"Tree Versions":{label:"Tree Versions",children:[...n.versions].sort(Vxe.default.compare).map(c=>({value:he.tuple(he.Type.REFERENCE,c)}))},Dependents:{label:"Dependents",children:je.sortMap(n.dependents,c=>G.stringifyLocator(c)).map(c=>({value:he.tuple(he.Type.LOCATOR,c)}))}}};return r}function LK(t,e,{all:r,environment:s}){let a=[],n=r?t.workspaces:[e],c=["all","production"].includes(s),f=["all","development"].includes(s);for(let p of n)for(let h of p.anchoredPackage.dependencies.values())(p.manifest.devDependencies.has(h.identHash)?!f:!c)||a.push({workspace:p,dependency:h});return a}function MK(t,e,{recursive:r}){let s=new Map,a=new Set,n=[],c=(f,p)=>{let h=t.storedResolutions.get(p.descriptorHash);if(typeof h>"u")throw new Error("Assertion failed: The resolution should have been registered");if(!a.has(h))a.add(h);else return;let E=t.storedPackages.get(h);if(typeof E>"u")throw new Error("Assertion failed: The package should have been registered");if(G.ensureDevirtualizedLocator(E).reference.startsWith("npm:")&&E.version!==null){let S=G.stringifyIdent(E),P=je.getMapWithDefault(s,S);je.getArrayWithDefault(P,E.version).push(f)}if(r)for(let S of E.dependencies.values())n.push([E,S])};for(let{workspace:f,dependency:p}of e)n.push([f.anchoredLocator,p]);for(;n.length>0;){let[f,p]=n.shift();c(f,p)}return s}var D1=class extends ft{constructor(){super(...arguments);this.all=ge.Boolean("-A,--all",!1,{description:"Audit dependencies from all workspaces"});this.recursive=ge.Boolean("-R,--recursive",!1,{description:"Audit transitive dependencies as well"});this.environment=ge.String("--environment","all",{description:"Which environments to cover",validator:fo(Jb)});this.json=ge.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.noDeprecations=ge.Boolean("--no-deprecations",!1,{description:"Don't warn about deprecated packages"});this.severity=ge.String("--severity","info",{description:"M Line truncated
This command checks for known security reports on the packages you use. The reports are by default extracted from the npm registry, and may or may not be relevant to your actual program (not all vulnerabilities affect all code paths).
For consistency with our other commands the default is to only check the direct dependencies for the active workspace. To extend this search to all workspaces, use \`-A,--all\`. To extend this search to both direct and transitive dependencies, use \`-R,--recursive\`.
Applying the \`--severity\` flag will limit the audit table to vulnerabilities of the corresponding severity and above. Valid values are ${S1.map(r=>`\`${r}\``).join(", ")}.
If the \`--json\` flag is set, Yarn will print the output exactly as received from the registry. Regardless of this flag, the process will exit with a non-zero exit code if a report is found for the selected packages.
If certain packages produce false positives for a particular environment, the \`--exclude\` flag can be used to exclude any number of packages from the audit. This can also be set in the configuration file with the \`npmAuditExcludePackages\` option.
If particular advisories are needed to be ignored, the \`--ignore\` flag can be used with Advisory ID's to ignore any number of advisories in the audit report. This can also be set in the configuration file with the \`npmAuditIgnoreAdvisories\` option.
To understand the dependency tree requiring vulnerable packages, check the raw report with the \`--json\` flag or use \`yarn why package\` to get more information as to who depends on them.
`,examples:[["Checks for known security issues with the installed packages. The output is a list of known issues.","yarn npm audit"],["Audit dependencies in all workspaces","yarn npm audit --all"],["Limit auditing to `dependencies` (excludes `devDependencies`)","yarn npm audit --environment production"],["Show audit report as valid JSON","yarn npm audit --json"],["Audit all direct and transitive dependencies","yarn npm audit --recursive"],["Output moderate (or more severe) vulnerabilities","yarn npm audit --severity moderate"],["Exclude certain packages","yarn npm audit --exclude package1 --exclude package2"],["Ignore specific advisories","yarn npm audit --ignore 1234567 --ignore 7654321"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s,workspace:a}=await Tt.find(r,this.context.cwd);if(!a)throw new ar(s.cwd,this.context.cwd);await s.restoreInstallState();let n=LK(s,a,{all:this.all,environment:this.environment}),c=MK(s,n,{recursive:this.recursive}),f=Array.from(new Set([...r.get("npmAuditExcludePackages"),...this.excludes])),p=Object.create(null);for(let[N,U]of c)f.some(W=>UK.default.isMatch(N,W))||(p[N]=[...U.keys()]);let h=hi.getAuditRegistry({configuration:r}),E,C=await lA.start({configuration:r,stdout:this.context.stdout},async()=>{let N=en.post("/-/npm/v1/security/advisories/bulk",p,{authType:en.AuthType.BEST_EFFORT,configuration:r,jsonResponse:!0,registry:h}),U=this.noDeprecations?[]:await Promise.all(Array.from(Object.entries(p),async([ee,ie])=>{let ue=await en.getPackageMetadata(G.parseIdent(ee),{project:s});return je.mapAndFilter(ie,le=>{let{deprecated:me}=ue.versions[le];return me?[ee,le,me]:je.mapAndFilter.skip})})),W=await N;for(let[ee,ie,ue]of U.flat(1))Object.hasOwn(W,ee)&&W[ee].some(le=>Fr.satisfiesWithPrereleases(ie,le.vulnerable_versions))||(W[ee]??=[],W[ee].push({id:`${ee} (deprecation)`,title:(typeof ue=="string"?ue:"").trim()||"This package has been deprecated.",severity:"moderate",vulnerable_versions:ie}));E=W});if(C.hasErrors())return C.exitCode();let S=NK(this.severity),P=Array.from(new Set([...r.get("npmAuditIgnoreAdvisories"),...this.ignores])),I=Object.create(null);for(let[N,U]of Object.entries(E)){let W=U.filter(ee=>!UK.default.isMatch(`${ee.id}`,P)&&S.has(ee.severity));W.length>0&&(I[N]=W.map(ee=>{let ie=c.get(N);if(typeof ie>"u")throw new Error("Assertion failed: Expected the registry to only return packages that were requested");let ue=[...ie.keys()].filter(me=>Fr.satisfiesWithPrereleases(me,ee.vulnerable_versions)),le=new Map;for(let me of ue)for(let pe of ie.get(me))le.set(pe.locatorHash,pe);return{...ee,versions:ue,dependents:[...le.values()]}}))}let R=Object.keys(I).length>0;return R?(xs.emitTree(OK(I),{configuration:r,json:this.json,stdout:this.context.stdout,separators:2}),1):(await Ot.start({configuration:r,includeFooter:!1,json:this.json,stdout:this.context.stdout},async N=>{N.reportInfo(1,"No audit suggestions")}),R?1:0)}};Ge();Ge();Dt();Yt();var _K=ut(Ai()),HK=Ie("util"),b1=class extends ft{constructor(){super(...arguments);this.fields=ge.String("-f,--fields",{description:"A comma-separated list of manifest fields that should be displayed"});this.json=ge.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.packages=ge.Rest()}static{this.paths=[["npm","info"]]}static{this.usage=ot.Usage({category:"Npm-related commands",description:"show information about a package",details:"\n This command fetches information about a package from the npm registry and prints it in a tree format.\n\n The package does not have to be installed locally, but needs to have been published (in particular, local changes will be ignored even for workspaces).\n\n Append `@<range>` to the package argument to provide information specific to the latest version that satisfies the range or to the corresponding tagged version. If the range is invalid or if there is no version satisfying the range, the command will print a warning and fall back to the latest version.\n\n If the `-f,--fields` option is set, it's a comma-separated list of fields which will be used to only display part of the package information.\n\n By default, this command won't return the `dist`, `readme`, and `users` fields, since they are often very long. To explicitly request those fields, explicitly list them with the `--fields` flag or request the output in JSON mode.\n ",examples:[["Show all available information about react (except the `dist`, `readme`, and `users` fields)","yarn npm info react"],["Show all available information about react as valid JSON (including the `dist`, `readme`, and `users` fields)","yarn npm info react --json"],["Show all available information about react@16.12.0","yarn npm info react@16.12.0"],["Show all available information about react@next","yarn npm info react@next"],["Show the description of react","yarn npm info react --fields description"],["Show all available versions of react","yarn npm info react Line truncated
`),this.context.stdout.write(`${(0,HK.inspect)(p,{depth:1/0,colors:!0,compact:!1})}
`);return f.exitCode()}};function jK(t){if(Array.isArray(t)){let e=[];for(let r of t)r=jK(r),r&&e.push(r);return e}else if(typeof t=="object"&&t!==null){let e={};for(let r of Object.keys(t)){if(r.startsWith("_"))continue;let s=jK(t[r]);s&&(e[r]=s)}return e}else return t||null}Ge();Ge();Yt();var GK=ut(Vv()),P1=class extends ft{constructor(){super(...arguments);this.scope=ge.String("-s,--scope",{description:"Login to the registry configured for a given scope"});this.publish=ge.Boolean("--publish",!1,{description:"Login to the publish registry"});this.alwaysAuth=ge.Boolean("--always-auth",{description:"Set the npmAlwaysAuth configuration"});this.webLogin=ge.Boolean("--web-login",{description:"Enable web login"})}static{this.paths=[["npm","login"]]}static{this.usage=ot.Usage({category:"Npm-related commands",description:"store new login info to access the npm registry",details:"\n This command will ask you for your username, password, and 2FA One-Time-Password (when it applies). It will then modify your local configuration (in your home folder, never in the project itself) to reference the new tokens thus generated.\n\n Adding the `-s,--scope` flag will cause the authentication to be done against whatever registry is configured for the associated scope (see also `npmScopes`).\n\n Adding the `--publish` flag will cause the authentication to be done against the registry used when publishing the package (see also `publishConfig.registry` and `npmPublishRegistry`).\n ",examples:[["Login to the default registry","yarn npm login"],["Login to the registry linked to the @my-scope registry","yarn npm login --scope my-scope"],["Login to the publish registry for the current package","yarn npm login --publish"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),s=await QL({configuration:r,cwd:this.context.cwd,publish:this.publish,scope:this.scope});return(await Ot.start({configuration:r,stdout:this.context.stdout,includeFooter:!1},async n=>{let c=await gbt({registry:s,configuration:r,report:n,webLogin:this.webLogin,stdin:this.context.stdin,stdout:this.context.stdout});return await mbt(s,c,{alwaysAuth:this.alwaysAuth,scope:this.scope}),n.reportInfo(0,"Successfully logged in")})).exitCode()}};async function QL({scope:t,publish:e,configuration:r,cwd:s}){return t&&e?hi.getScopeRegistry(t,{configuration:r,type:hi.RegistryType.PUBLISH_REGISTRY}):t?hi.getScopeRegistry(t,{configuration:r}):e?hi.getPublishRegistry((await eC(r,s)).manifest,{configuration:r}):hi.getDefaultRegistry({configuration:r})}async function fbt(t,e){let r;try{r=await en.post("/-/v1/login",null,{configuration:e,registry:t,authType:en.AuthType.NO_AUTH,jsonResponse:!0,headers:{"npm-auth-type":"web"}})}catch{return null}return r}async function Abt(t,e){let r=await nn.request(t,null,{configuration:e,jsonResponse:!0});if(r.statusCode===202){let s=r.headers["retry-after"]??"1";return{type:"waiting",sleep:parseInt(s,10)}}return r.statusCode===200?{type:"success",token:r.body.token}:null}async function pbt({registry:t,configuration:e,report:r}){let s=await fbt(t,e);if(!s)return null;if(Ui.openUrl){r.reportInfo(0,"Starting the web login process..."),r.reportSeparator();let{openNow:a}=await(0,GK.prompt)({type:"confirm",name:"openNow",message:"Do you want to try to open your browser now?",required:!0,initial:!0,onCancel:()=>process.exit(130)});r.reportSeparator(),(!a||!await Ui.openUrl(s.loginUrl))&&(r.reportWarning(0,"We failed to automatically open the url; you'll have to open it yourself in your browser of choice:"),r.reportWarning(0,he.pretty(e,s.loginUrl,he.Type.URL)),r.reportSeparator())}for(;;){let a=await Abt(s.doneUrl,e);if(a===null)return null;if(a.type==="waiting")await new Promise(n=>setTimeout(n,a.sleep*1e3));else return a.token}}var hbt=["https://registry.yarnpkg.com","https://registry.npmjs.org"];async function gbt(t){if(t.webLogin??hbt.includes(t.registry)){let e=await pbt(t);if(e!==null)return e}return await dbt(t)}async function dbt({registry:t,configuration:e,report:r,stdin:s,stdout:a}){let n=await ybt({configuration:e,registry:t,report:r,stdin:s,stdout:a}),c=`/-/user/org.couchdb.user:${encodeURIComponent(n.name)}`,f={_id:`org.couchdb.user:${n.name}`,name:n.name,password:n.password,type:"user",roles:[],date:new Date().toISOString()},p={attemptedAs:n.name,configuration:e,registry:t,jsonResponse:!0,authType:en.AuthType.NO_AUTH};try{return(await en.put(c,f,p)).token}catch(P){if(!(P.originalError?.name==="HTTPError"&&P.originalError?.response.statusCode===409))throw P}let h={...p,authType:en.AuthType.NO_AUTH,headers:{authorization:`Basic ${Buffer.from(`${n.name}:${n.password}`).toString("base64")}`}},E=await en.get(c,h);for(let[P,I]of Object.entries(E))(!f[P]||P==="roles")&&(f[P]=I);let C=`${c}/-rev/${f._rev}`;return(await en.put(C,f,h)).token}async function mbt(t,e,{alwaysAuth:r,scope:s}){let a=c=>f=>{let p=je.isIndexableObject(f)?f:{},h=p[c],E=je.isIndexableObject(h)?h:{};return{...p,[c]:{...E,...r!==void 0?{npLine truncated
This command will list all tags of a package from the npm registry.
If the package is not specified, Yarn will default to the current workspace.
`,examples:[["List all tags of package `my-pkg`","yarn npm tag list my-pkg"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s,workspace:a}=await Tt.find(r,this.context.cwd),n;if(typeof this.package<"u")n=G.parseIdent(this.package);else{if(!a)throw new ar(s.cwd,this.context.cwd);if(!a.manifest.name)throw new nt(`Missing 'name' field in ${fe.fromPortablePath(J.join(a.cwd,Er.manifest))}`);n=a.manifest.name}let c=await Xb(n,r),p={children:je.sortMap(Object.entries(c),([h])=>h).map(([h,E])=>({value:he.tuple(he.Type.RESOLUTION,{descriptor:G.makeDescriptor(n,h),locator:G.makeLocator(n,E)})}))};return xs.emitTree(p,{configuration:r,json:this.json,stdout:this.context.stdout})}};async function Xb(t,e){let r=`/-/package${en.getIdentUrl(t)}/dist-tags`;return en.get(r,{configuration:e,ident:t,jsonResponse:!0,customErrorMessage:en.customPackageError})}var R1=class extends ft{constructor(){super(...arguments);this.package=ge.String();this.tag=ge.String()}static{this.paths=[["npm","tag","add"]]}static{this.usage=ot.Usage({category:"Npm-related commands",description:"add a tag for a specific version of a package",details:`
This command will add a tag to the npm registry for a specific version of a package. If the tag already exists, it will be overwritten.
`,examples:[["Add a `beta` tag for version `2.3.4-beta.4` of package `my-pkg`","yarn npm tag add my-pkg@2.3.4-beta.4 beta"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s,workspace:a}=await Tt.find(r,this.context.cwd);if(!a)throw new ar(s.cwd,this.context.cwd);let n=G.parseDescriptor(this.package,!0),c=n.range;if(!Kxe.default.valid(c))throw new nt(`The range ${he.pretty(r,n.range,he.Type.RANGE)} must be a valid semver version`);let f=hi.getPublishRegistry(a.manifest,{configuration:r}),p=he.pretty(r,n,he.Type.IDENT),h=he.pretty(r,c,he.Type.RANGE),E=he.pretty(r,this.tag,he.Type.CODE);return(await Ot.start({configuration:r,stdout:this.context.stdout},async S=>{let P=await Xb(n,r);Object.hasOwn(P,this.tag)&&P[this.tag]===c&&S.reportWarning(0,`Tag ${E} is already set to version ${h}`);let I=`/-/package${en.getIdentUrl(n)}/dist-tags/${encodeURIComponent(this.tag)}`;await en.put(I,c,{configuration:r,registry:f,ident:n,jsonRequest:!0,jsonResponse:!0}),S.reportInfo(0,`Tag ${E} added to version ${h} of package ${p}`)})).exitCode()}};Ge();Yt();var F1=class extends ft{constructor(){super(...arguments);this.package=ge.String();this.tag=ge.String()}static{this.paths=[["npm","tag","remove"]]}static{this.usage=ot.Usage({category:"Npm-related commands",description:"remove a tag from a package",details:`
This command will remove a tag from a package from the npm registry.
`,examples:[["Remove the `beta` tag from package `my-pkg`","yarn npm tag remove my-pkg beta"]]})}async execute(){if(this.tag==="latest")throw new nt("The 'latest' tag cannot be removed.");let r=await ze.find(this.context.cwd,this.context.plugins),{project:s,workspace:a}=await Tt.find(r,this.context.cwd);if(!a)throw new ar(s.cwd,this.context.cwd);let n=G.parseIdent(this.package),c=hi.getPublishRegistry(a.manifest,{configuration:r}),f=he.pretty(r,this.tag,he.Type.CODE),p=he.pretty(r,n,he.Type.IDENT),h=await Xb(n,r);if(!Object.hasOwn(h,this.tag))throw new nt(`${f} is not a tag of package ${p}`);return(await Ot.start({configuration:r,stdout:this.context.stdout},async C=>{let S=`/-/package${en.getIdentUrl(n)}/dist-tags/${encodeURIComponent(this.tag)}`;await en.del(S,{configuration:r,registry:c,ident:n,jsonResponse:!0}),C.reportInfo(0,`Tag ${f} removed from package ${p}`)})).exitCode()}};Ge();Ge();Yt();var N1=class extends ft{constructor(){super(...arguments);this.scope=ge.String("-s,--scope",{description:"Print username for the registry configured for a given scope"});this.publish=ge.Boolean("--publish",!1,{description:"Print username for the publish registry"})}static{this.paths=[["npm","whoami"]]}static{this.usage=ot.Usage({category:"Npm-related commands",description:"display the name of the authenticated user",details:"\n Print the username associated with the current authentication settings to the standard output.\n\n When using `-s,--scope`, the username printed will be the one that matches the authentication settings of the registry associated with the given scope (those settings can be overriden using the `npmRegistries` map, and the registry associated with the scope is configured via the `npmScopes` map).\n\n When using `--publish`, the registry we'll select will by default be the one used when publishing packages (`publishConfig.registry` or `npmPublishRegistry` if available, otherwise we'll fallback to the regular `npmRegistryServer`).\n ",examples:[["Print username for the default registry","yarn npm whoami"],["Print username for the registry on a given scope","yarn npm whoami --scope company"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),s;return this.scope&&this.publish?s=hi.getScopeRegistry(this.scope,{configuration:r,type:hi.RegistryType.PUBLISH_REGISTRY}):this.scope?s=hi.getScopeRegistry(this.scope,{configuration:r}):this.publish?s=hi.getPublishRegistry((await eC(r,this.context.cwd)).manifest,{configuration:r}):s=hi.getDefaultRegistry({configuration:r}),(await Ot.start({configuration:r,stdout:this.context.stdout},async n=>{let c;try{c=await en.get("/-/whoami",{configuration:r,registry:s,authType:en.AuthType.ALWAYS_AUTH,jsonResponse:!0,ident:this.scope?G.makeIdent(this.scope,""):void 0})}catch(f){if(f.response?.statusCode===401||f.response?.statusCode===403){n.reportError(41,"Authentication failed - your credentials may have expired");return}else throw f}n.reportInfo(0,c.username)})).exitCode()}};var Cbt={configuration:{npmPublishAccess:{description:"Default access of the published packages",type:"STRING",default:null},npmPublishProvenance:{description:"Whether to generate provenance for the published packages",type:"BOOLEAN",default:!1},npmAuditExcludePackages:{description:"Array of glob patterns of packages to exclude from npm audit",type:"STRING",default:[],isArray:!0},npmAuditIgnoreAdvisories:{description:"Array of glob patterns of advisory IDs to exclude from npm audit",type:"STRING",default:[],isArray:!0}},commands:[D1,b1,P1,k1,Q1,R1,T1,F1,N1]},wbt=Cbt;var XK={};Vt(XK,{PatchCommand:()=>H1,PatchCommitCommand:()=>_1,PatchFetcher:()=>rP,PatchResolver:()=>nP,default:()=>_bt,patchUtils:()=>gy});Ge();Ge();Dt();eA();var gy={};Vt(gy,{applyPatchFile:()=>RL,diffFolders:()=>KK,ensureUnpatchedDescriptor:()=>WK,ensureUnpatchedLocator:()=>NL,extractPackageToDisk:()=>JK,extractPatchFlags:()=>rke,isParentRequired:()=>VK,isPatchDescriptor:()=>FL,isPatchLocator:()=>Rg,loadPatchFiles:()=>tP,makeDescriptor:()=>OL,makeLocator:()=>YK,makePatchHash:()=>zK,parseDescriptor:()=>$b,parseLocator:()=>eP,parsePatchFile:()=>Zb,unpatchDescriptor:()=>Lbt,unpatchLocator:()=>Mbt});Ge();Dt();Ge();Dt();var Bbt=/^@@ -(\d+)(,(\d+))? \+(\d+)(,(\d+))? @@.*/;function O1(t){return J.relative(vt.root,J.resolve(vt.root,fe.toPortablePath(t)))}function vbt(t){let e=t.trim().match(Bbt);if(!e)throw new Error(`Bad header line: '${t}'`);return{original:{start:Math.max(Number(e[1]),1),length:Number(e[3]||1)},patched:{start:Math.max(Number(e[4]),1),length:Number(e[6]||1)}}}var Sbt=420,Dbt=493;var zxe=()=>({semverExclusivity:null,diffLineFromPath:null,diffLineToPath:null,oldMode:null,newMode:null,deletedFileMode:null,newFileMode:null,renameFrom:null,renameTo:null,beforeHash:null,afterHash:null,fromPath:null,toPath:null,hunks:null}),bbt=t=>({header:vbt(t),parts:[]}),Pbt={"@":"header","-":"deletion","+":"insertion"," ":"context","\\":"pragma",undefined:"context"};function xbt(t){let e=[],r=Line truncated
`)+(a.hunk.parts[0].noNewlineAtEndOfFile?"":`
`):"";await e.mkdirpPromise(J.dirname(a.path),{chmod:493,utimes:[fi.SAFE_TIME,fi.SAFE_TIME]}),await e.writeFilePromise(a.path,n,{mode:a.mode}),await e.utimesPromise(a.path,fi.SAFE_TIME,fi.SAFE_TIME)}break;case"patch":await M1(e,a.path,async()=>{await Fbt(a,{baseFs:e,dryRun:r})});break;case"mode change":{let c=(await e.statPromise(a.path)).mode;if(Xxe(a.newMode)!==Xxe(c))continue;await M1(e,a.path,async()=>{await e.chmodPromise(a.path,a.newMode)})}break;default:je.assertNever(a);break}}function Xxe(t){return(t&64)>0}function Zxe(t){return t.replace(/\s+$/,"")}function Rbt(t,e){return Zxe(t)===Zxe(e)}async function Fbt({hunks:t,path:e},{baseFs:r,dryRun:s=!1}){let a=await r.statSync(e).mode,c=(await r.readFileSync(e,"utf8")).split(/\n/),f=[],p=0,h=0;for(let C of t){let S=Math.max(h,C.header.patched.start+p),P=Math.max(0,S-h),I=Math.max(0,c.length-S-C.header.original.length),R=Math.max(P,I),N=0,U=0,W=null;for(;N<=R;){if(N<=P&&(U=S-N,W=$xe(C,c,U),W!==null)){N=-N;break}if(N<=I&&(U=S+N,W=$xe(C,c,U),W!==null))break;N+=1}if(W===null)throw new L1(t.indexOf(C),C);f.push(W),p+=N,h=U+C.header.original.length}if(s)return;let E=0;for(let C of f)for(let S of C)switch(S.type){case"splice":{let P=S.index+E;c.splice(P,S.numToDelete,...S.linesToInsert),E+=S.linesToInsert.length-S.numToDelete}break;case"pop":c.pop();break;case"push":c.push(S.line);break;default:je.assertNever(S);break}await r.writeFilePromise(e,c.join(`
`),{mode:a})}function $xe(t,e,r){let s=[];for(let a of t.parts)switch(a.type){case"context":case"deletion":{for(let n of a.lines){let c=e[r];if(c==null||!Rbt(c,n))return null;r+=1}a.type==="deletion"&&(s.push({type:"splice",index:r-a.lines.length,numToDelete:a.lines.length,linesToInsert:[]}),a.noNewlineAtEndOfFile&&s.push({type:"push",line:""}))}break;case"insertion":s.push({type:"splice",index:r,numToDelete:0,linesToInsert:a.lines}),a.noNewlineAtEndOfFile&&s.push({type:"pop"});break;default:je.assertNever(a.type);break}return s}var Obt=/^builtin<([^>]+)>$/;function U1(t,e){let{protocol:r,source:s,selector:a,params:n}=G.parseRange(t);if(r!=="patch:")throw new Error("Invalid patch range");if(s===null)throw new Error("Patch locators must explicitly define their source");let c=a?a.split(/&/).map(E=>fe.toPortablePath(E)):[],f=n&&typeof n.locator=="string"?G.parseLocator(n.locator):null,p=n&&typeof n.version=="string"?n.version:null,h=e(s);return{parentLocator:f,sourceItem:h,patchPaths:c,sourceVersion:p}}function FL(t){return t.range.startsWith("patch:")}function Rg(t){return t.reference.startsWith("patch:")}function $b(t){let{sourceItem:e,...r}=U1(t.range,G.parseDescriptor);return{...r,sourceDescriptor:e}}function eP(t){let{sourceItem:e,...r}=U1(t.reference,G.parseLocator);return{...r,sourceLocator:e}}function Lbt(t){let{sourceItem:e}=U1(t.range,G.parseDescriptor);return e}function Mbt(t){let{sourceItem:e}=U1(t.reference,G.parseLocator);return e}function WK(t){if(!FL(t))return t;let{sourceItem:e}=U1(t.range,G.parseDescriptor);return e}function NL(t){if(!Rg(t))return t;let{sourceItem:e}=U1(t.reference,G.parseLocator);return e}function eke({parentLocator:t,sourceItem:e,patchPaths:r,sourceVersion:s,patchHash:a},n){let c=t!==null?{locator:G.stringifyLocator(t)}:{},f=typeof s<"u"?{version:s}:{},p=typeof a<"u"?{hash:a}:{};return G.makeRange({protocol:"patch:",source:n(e),selector:r.join("&"),params:{...f,...p,...c}})}function OL(t,{parentLocator:e,sourceDescriptor:r,patchPaths:s}){return G.makeDescriptor(t,eke({parentLocator:e,sourceItem:r,patchPaths:s},G.stringifyDescriptor))}function YK(t,{parentLocator:e,sourcePackage:r,patchPaths:s,patchHash:a}){return G.makeLocator(t,eke({parentLocator:e,sourceItem:r,sourceVersion:r.version,patchPaths:s,patchHash:a},G.stringifyLocator))}function tke({onAbsolute:t,onRelative:e,onProject:r,onBuiltin:s},a){let n=a.lastIndexOf("!");n!==-1&&(a=a.slice(n+1));let c=a.match(Obt);return c!==null?s(c[1]):a.startsWith("~/")?r(a.slice(2)):J.isAbsolute(a)?t(a):e(a)}function rke(t){let e=t.lastIndexOf("!");return{optional:(e!==-1?new Set(t.slice(0,e).split(/!/)):new Set).has("optional")}}function VK(t){return tke({onAbsolute:()=>!1,onRelative:()=>!0,onProject:()=>!1,onBuiltin:()=>!1},t)}async function tP(t,e,r){let s=t!==null?await r.fetcher.fetch(t,r):null,a=s&&s.localPath?{packageFs:new Sn(vt.root),prefixPath:J.relative(vt.root,s.localPath)}:s;s&&s!==a&&s.releaseFs&&s.releaseFs();let n=await je.releaseAfterUseAsync(async()=>await Promise.all(e.map(async c=>{let f=rke(c),p=await tke({onAbsolute:async h=>await ce.readFilePromise(h,"utf8"),onRelative:async h=>{if(a===null)throw new Error("Assertion failed: The parent locator should have been fetched");return await a.packageFs.readFilePromise(J.join(a.prefixPath,h),"utf8")},onProject:async h=>await ce.readFilePromise(J.join(r.project.cwd,h),"utf8"),onBuiltin:async h=>await r.project.configuration.firstHook(E=>E.getBuiltinPatch,r.project,h)},c);return{...f,source:p}})));for(let c of n)typeof c.source=="string"&&(c.source=c.source.replace(/\r\n?/g,`
`));return n}async function JK(t,{cache:e,project:r}){let s=r.storedPackages.get(t.locatorHash);if(typeof s>"u")throw new Error("Assertion failed: Expected the package to be registered");let a=NL(t),n=r.storedChecksums,c=new ki,f=await ce.mktempPromise(),p=J.join(f,"source"),h=J.join(f,"user"),E=J.join(f,".yarn-patch.json"),C=r.configuration.makeFetcher(),S=[];try{let P,I;if(t.locatorHash===a.locatorHash){let R=await C.fetch(t,{cache:e,project:r,fetcher:C,checksums:n,report:c});S.push(()=>R.releaseFs?.()),P=R,I=R}else P=await C.fetch(t,{cache:e,project:r,fetcher:C,checksums:n,report:c}),S.push(()=>P.releaseFs?.()),I=await C.fetch(t,{cache:e,project:r,fetcher:C,checksums:n,report:c}),S.push(()=>I.releaseFs?.());await Promise.all([ce.copyPromise(p,P.prefixPath,{baseFs:P.packageFs}),ce.copyPromise(h,I.prefixPath,{baseFs:I.packageFs}),ce.writeJsonPromise(E,{locator:G.stringifyLocator(t),version:s.version})])}finally{for(let P of S)P()}return ce.detachTemp(f),h}async function KK(t,e){let r=fe.fromPortablePath(t).replace(/\\/g,"/"),s=fe.fromPortablePath(e).replace(/\\/g,"/"),{stdout:a,stderr:n}=await qr.execvp("git",["-c","core.safecrlf=false","diff","--src-prefix=a/","--dst-prefix=b/","--ignore-cr-at-eol","--full-index","--no-index","--no-renames","--text",r,s],{cwd:fe.toPortablePath(process.cwd()),env:{...process.env,GIT_CONFIG_NOSYSTEM:"1",HOME:"",XDG_CONFIG_HOME:"",USERPROFILE:""}});if(n.length>0)throw new Error(`Unable to diff directories. Make sure you have a recent version of 'git' available in PATH.
The following error was reported by 'git':
${n}`);let c=r.startsWith("/")?f=>f.slice(1):f=>f;return a.replace(new RegExp(`(a|b)(${je.escapeRegExp(`/${c(r)}/`)})`,"g"),"$1/").replace(new RegExp(`(a|b)${je.escapeRegExp(`/${c(s)}/`)}`,"g"),"$1/").replace(new RegExp(je.escapeRegExp(`${r}/`),"g"),"").replace(new RegExp(je.escapeRegExp(`${s}/`),"g"),"")}function zK(t,e){let r=[];for(let{source:s}of t){if(s===null)continue;let a=Zb(s);for(let n of a){let{semverExclusivity:c,...f}=n;c!==null&&e!==null&&!Fr.satisfiesWithPrereleases(e,c)||r.push(JSON.stringify(f))}}return Nn.makeHash(`${3}`,...r).slice(0,6)}Ge();function nke(t,{configuration:e,report:r}){for(let s of t.parts)for(let a of s.lines)switch(s.type){case"context":r.reportInfo(null,` ${he.pretty(e,a,"grey")}`);break;case"deletion":r.reportError(28,`- ${he.pretty(e,a,he.Type.REMOVED)}`);break;case"insertion":r.reportError(28,`+ ${he.pretty(e,a,he.Type.ADDED)}`);break;default:je.assertNever(s.type)}}var rP=class{supports(e,r){return!!Rg(e)}getLocalPath(e,r){return null}async fetch(e,r){let s=r.checksums.get(e.locatorHash)||null,[a,n,c]=await r.cache.fetchPackageFromCache(e,s,{onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${G.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the disk`),loader:()=>this.patchPackage(e,r),...r.cacheOptions});return{packageFs:a,releaseFs:n,prefixPath:G.getIdentVendorPath(e),localPath:this.getLocalPath(e,r),checksum:c}}async patchPackage(e,r){let{parentLocator:s,sourceLocator:a,sourceVersion:n,patchPaths:c}=eP(e),f=await tP(s,c,r),p=await ce.mktempPromise(),h=J.join(p,"current.zip"),E=await r.fetcher.fetch(a,r),C=G.getIdentVendorPath(e),S=new As(h,{create:!0,level:r.project.configuration.get("compressionLevel")});await je.releaseAfterUseAsync(async()=>{await S.copyPromise(C,E.prefixPath,{baseFs:E.packageFs,stableSort:!0})},E.releaseFs),S.saveAndClose();for(let{source:P,optional:I}of f){if(P===null)continue;let R=new As(h,{level:r.project.configuration.get("compressionLevel")}),N=new Sn(J.resolve(vt.root,C),{baseFs:R});try{await RL(Zb(P),{baseFs:N,version:n})}catch(U){if(!(U instanceof L1))throw U;let W=r.project.configuration.get("enableInlineHunks"),ee=!W&&!I?" (set enableInlineHunks for details)":"",ie=`${G.prettyLocator(r.project.configuration,e)}: ${U.message}${ee}`,ue=le=>{W&&nke(U.hunk,{configuration:r.project.configuration,report:le})};if(R.discardAndClose(),I){r.report.reportWarningOnce(66,ie,{reportExtra:ue});continue}else throw new jt(66,ie,ue)}R.saveAndClose()}return new As(h,{level:r.project.configuration.get("compressionLevel")})}};Ge();var nP=class{supportsDescriptor(e,r){return!!FL(e)}supportsLocator(e,r){return!!Rg(e)}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,s){let{patchPaths:a}=$b(e);return a.every(n=>!VK(n))?e:G.bindDescriptor(e,{locator:G.stringifyLocator(r)})}getResolutionDependencies(e,r){let{sourceDescriptor:s}=$b(e);return{sourceDescriptor:r.project.configuration.normalizeDependency(s)}}async getCandidates(e,r,s){if(!s.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let{parentLocator:a,patchPaths:n}=$b(e),c=await tP(a,n,s.fetchOptions),f=r.sourceDescriptor;if(typeof f>"u")throw new Error("Assertion failed: The dependency should have been resolved");let p=zK(c,f.version);return[YK(e,{parentLocator:a,sourcePackage:f,patchPaths:n,patchHash:p})]}async getSatisfying(e,r,s,a){let[n]=await this.getCandidates(e,r,a);return{locators:s.filter(c=>c.locatorHash===n.locatorHash),sorted:!1}}async resolve(e,r){let{sourceLocator:s}=eP(e);return{...await r.resolver.resolve(s,r),...e}}};Ge();Dt();Yt();var _1=class extends ft{constructor(){super(...arguments);this.save=ge.Boolean("-s,--save",!1,{description:"Add the patch to your resolution entries"});this.patchFolder=ge.String()}static{this.paths=[["patch-commit"]]}static{this.usage=ot.Usage({description:"generate a patch out of a directory",details:"\n By default, this will print a patchfile on stdout based on the diff between the folder passed in and the original version of the package. Such file is suitable for consumption with the `patch:` protocol.\n\n With the `-s,--save` option set, the patchfile won't be printed on stdout anymore and will instead be stored within a local file (by default kept within `.yarn/patches`, but configurable via the `patchFolder` setting). A `resolutions` entry will also be added to your top-level manifest, referencing the patched package via the `patch:` protocol.\n\n Note that only folders generated by `yarn patch` are accepted as valid input for `yarn patch-commit`.\n "})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s,workspace:a}=await Tt.find(r,this.context.cwd);if(!a)throw new ar(s.cwd,this.context.cwd);await s.restoreInstallState();let n=J.resolve(this.context.cwd,fe.toPortablePath(this.patchFolder)),c=J.join(n,"../source"),f=J.join(n,"../.yarn-patch.json");if(!ce.existsSLine truncated
${f.map(p=>`
- ${G.prettyLocator(r,p)}`).join("")}`);c=f[0]}if(!s.storedPackages.has(c.locatorHash))throw new nt("No package found in the project for the given locator");await Ot.start({configuration:r,json:this.json,stdout:this.context.stdout},async f=>{let p=NL(c),h=await JK(c,{cache:n,project:s});f.reportJson({locator:G.stringifyLocator(p),path:fe.fromPortablePath(h)});let E=this.update?" along with its current modifications":"";f.reportInfo(0,`Package ${G.prettyLocator(r,p)} got extracted with success${E}!`),f.reportInfo(0,`You can now edit the following folder: ${he.pretty(r,fe.fromPortablePath(h),"magenta")}`),f.reportInfo(0,`Once you are done run ${he.pretty(r,`yarn patch-commit -s ${process.platform==="win32"?'"':""}${fe.fromPortablePath(h)}${process.platform==="win32"?'"':""}`,"cyan")} and Yarn will store a patchfile based on your changes.`)})}};var Ubt={configuration:{enableInlineHunks:{description:"If true, the installs will print unmatched patch hunks",type:"BOOLEAN",default:!1},patchFolder:{description:"Folder where the patch files must be written",type:"ABSOLUTE_PATH",default:"./.yarn/patches"}},commands:[_1,H1],fetchers:[rP],resolvers:[nP]},_bt=Ubt;var ez={};Vt(ez,{PnpmLinker:()=>iP,default:()=>Ybt});Ge();Dt();Yt();var iP=class{getCustomDataKey(){return JSON.stringify({name:"PnpmLinker",version:3})}supportsPackage(e,r){return this.isEnabled(r)}async findPackageLocation(e,r){if(!this.isEnabled(r))throw new Error("Assertion failed: Expected the pnpm linker to be enabled");let s=this.getCustomDataKey(),a=r.project.linkersCustomData.get(s);if(!a)throw new nt(`The project in ${he.pretty(r.project.configuration,`${r.project.cwd}/package.json`,he.Type.PATH)} doesn't seem to have been installed - running an install there might help`);let n=a.pathsByLocator.get(e.locatorHash);if(typeof n>"u")throw new nt(`Couldn't find ${G.prettyLocator(r.project.configuration,e)} in the currently installed pnpm map - running an install might help`);return n.packageLocation}async findPackageLocator(e,r){if(!this.isEnabled(r))return null;let s=this.getCustomDataKey(),a=r.project.linkersCustomData.get(s);if(!a)throw new nt(`The project in ${he.pretty(r.project.configuration,`${r.project.cwd}/package.json`,he.Type.PATH)} doesn't seem to have been installed - running an install there might help`);let n=e.match(/(^.*\/node_modules\/(@[^/]*\/)?[^/]+)(\/.*$)/);if(n){let p=a.locatorByPath.get(n[1]);if(p)return p}let c=e,f=e;do{f=c,c=J.dirname(f);let p=a.locatorByPath.get(f);if(p)return p}while(c!==f);return null}makeInstaller(e){return new ZK(e)}isEnabled(e){return e.project.configuration.get("nodeLinker")==="pnpm"}},ZK=class{constructor(e){this.opts=e;this.asyncActions=new je.AsyncActions(10);this.customData={pathsByLocator:new Map,locatorByPath:new Map};this.indexFolderPromise=$P(ce,{indexPath:J.join(e.project.configuration.get("globalFolder"),"index")})}attachCustomData(e){}async installPackage(e,r,s){switch(e.linkType){case"SOFT":return this.installPackageSoft(e,r,s);case"HARD":return this.installPackageHard(e,r,s)}throw new Error("Assertion failed: Unsupported package link type")}async installPackageSoft(e,r,s){let a=J.resolve(r.packageFs.getRealPath(),r.prefixPath),n=this.opts.project.tryWorkspaceByLocator(e)?J.join(a,Er.nodeModules):null;return this.customData.pathsByLocator.set(e.locatorHash,{packageLocation:a,dependenciesLocation:n}),{packageLocation:a,buildRequest:null}}async installPackageHard(e,r,s){let a=jbt(e,{project:this.opts.project}),n=a.packageLocation;this.customData.locatorByPath.set(n,G.stringifyLocator(e)),this.customData.pathsByLocator.set(e.locatorHash,a),s.holdFetchResult(this.asyncActions.set(e.locatorHash,async()=>{await ce.mkdirPromise(n,{recursive:!0}),await ce.copyPromise(n,r.prefixPath,{baseFs:r.packageFs,overwrite:!1,linkStrategy:{type:"HardlinkFromIndex",indexPath:await this.indexFolderPromise,autoRepair:!0}})}));let f=G.isVirtualLocator(e)?G.devirtualizeLocator(e):e,p={manifest:await Ut.tryFind(r.prefixPath,{baseFs:r.packageFs})??new Ut,misc:{hasBindingGyp:gA.hasBindingGyp(r)}},h=this.opts.project.getDependencyMeta(f,e.version),E=gA.extractBuildRequest(e,p,h,{configuration:this.opts.project.configuration});return{packageLocation:n,buildRequest:E}}async attachInternalDependencies(e,r){if(this.opts.project.configuration.get("nodeLinker")!=="pnpm"||!ike(e,{project:this.opts.project}))return;let s=this.customData.pathsByLocator.get(e.locatorHash);if(typeof s>"u")throw new Error(`Assertion failed: Expected the package to have been registered (${G.stringifyLocator(e)})`);let{dependenciesLocation:a}=s;a&&this.asyncActions.reduce(e.locatorHash,async n=>{await ce.mkdirPromise(a,{recursive:!0});let c=await Gbt(a),f=new Map(c),p=[n],h=(C,S)=>{let P=S;ike(S,{project:this.opts.project})||(this.opts.report.reportWarningOnce(0,"The pnpm linker doesn't support providing different versions to workspaces' peer dependencies"),P=G.devirtualizeLocator(S));let I=this.customData.pathsByLocator.get(P.locatorHash);if(typeof I>"Line truncated
${Jbt}
`,"--",...s],{cwd:t,strict:!0})},async makeReset(t,e){let r=e.map(s=>fe.fromPortablePath(s.path));await qr.execvp("git",["reset","HEAD","--",...r],{cwd:t,strict:!0})}};var $bt=[lke],j1=class extends ft{constructor(){super(...arguments);this.commit=ge.Boolean("-c,--commit",!1,{description:"Commit the staged files"});this.reset=ge.Boolean("-r,--reset",!1,{description:"Remove all files from the staging area"});this.dryRun=ge.Boolean("-n,--dry-run",!1,{description:"Print the commit message and the list of modified files without staging / committing"});this.update=ge.Boolean("-u,--update",!1,{hidden:!0})}static{this.paths=[["stage"]]}static{this.usage=ot.Usage({description:"add all yarn files to your vcs",details:"\n This command will add to your staging area the files belonging to Yarn (typically any modified `package.json` and `.yarnrc.yml` files, but also linker-generated files, cache data, etc). It will take your ignore list into account, so the cache files won't be added if the cache is ignored in a `.gitignore` file (assuming you use Git).\n\n Running `--reset` will instead remove them from the staging area (the changes will still be there, but won't be committed until you stage them back).\n\n Since the staging area is a non-existent concept in Mercurial, Yarn will always create a new commit when running this command on Mercurial repositories. You can get this behavior when using Git by using the `--commit` flag which will directly create a commit.\n ",examples:[["Adds all modified project files to the staging area","yarn stage"],["Creates a new commit containing all modified project files","yarn stage --commit"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s}=await Tt.find(r,this.context.cwd),{driver:a,root:n}=await ePt(s.cwd),c=[r.get("cacheFolder"),r.get("globalFolder"),r.get("virtualFolder"),r.get("yarnPath")];await r.triggerHook(C=>C.populateYarnPaths,s,C=>{c.push(C)});let f=new Set;for(let C of c)for(let S of tPt(n,C))f.add(S);let p=new Set([r.get("rcFilename"),Er.lockfile,Er.manifest]),h=await a.filterChanges(n,f,p),E=await a.genCommitMessage(n,h);if(this.dryRun)if(this.commit)this.context.stdout.write(`${E}
`);else for(let C of h)this.context.stdout.write(`${fe.fromPortablePath(C.path)}
`);else if(this.reset){let C=await a.filterChanges(n,f,p,{staged:!0});C.length===0?this.context.stdout.write("No staged changes found!"):await a.makeReset(n,C)}else h.length===0?this.context.stdout.write("No changes found!"):this.commit?await a.makeCommit(n,h,E):(await a.makeStage(n,h),this.context.stdout.write(E))}};async function ePt(t){let e=null,r=null;for(let s of $bt)if((r=await s.findRoot(t))!==null){e=s;break}if(e===null||r===null)throw new nt("No stage driver has been found for your current project");return{driver:e,root:r}}function tPt(t,e){let r=[];if(e===null)return r;for(;;){(e===t||e.startsWith(`${t}/`))&&r.push(e);let s;try{s=ce.statSync(e)}catch{break}if(s.isSymbolicLink())e=J.resolve(J.dirname(e),ce.readlinkSync(e));else break}return r}var rPt={commands:[j1]},nPt=rPt;var lz={};Vt(lz,{default:()=>fPt});Ge();Ge();Dt();var fke=ut(Ai());Ge();var cke=ut(g9()),iPt="e8e1bd300d860104bb8c58453ffa1eb4",sPt="OFCNCOG2CU",uke=async(t,e)=>{let r=G.stringifyIdent(t),a=oPt(e).initIndex("npm-search");try{return(await a.getObject(r,{attributesToRetrieve:["types"]})).types?.ts==="definitely-typed"}catch{return!1}},oPt=t=>(0,cke.default)(sPt,iPt,{requester:{async send(r){try{let s=await nn.request(r.url,r.data||null,{configuration:t,headers:r.headers});return{content:s.body,isTimedOut:!1,status:s.statusCode}}catch(s){return{content:s.response.body,isTimedOut:!1,status:s.response.statusCode}}}}});var Ake=t=>t.scope?`${t.scope}__${t.name}`:`${t.name}`,aPt=async(t,e,r,s)=>{if(r.scope==="types")return;let{project:a}=t,{configuration:n}=a;if(!(n.get("tsEnableAutoTypes")??(ce.existsSync(J.join(t.cwd,"tsconfig.json"))||ce.existsSync(J.join(a.cwd,"tsconfig.json")))))return;let f=n.makeResolver(),p={project:a,resolver:f,report:new ki};if(!await uke(r,n))return;let E=Ake(r),C=G.parseRange(r.range).selector;if(!Fr.validRange(C)){let N=n.normalizeDependency(r),U=await f.getCandidates(N,{},p);C=G.parseRange(U[0].reference).selector}let S=fke.default.coerce(C);if(S===null)return;let P=`${Xu.Modifier.CARET}${S.major}`,I=G.makeDescriptor(G.makeIdent("types",E),P),R=je.mapAndFind(a.workspaces,N=>{let U=N.manifest.dependencies.get(r.identHash)?.descriptorHash,W=N.manifest.devDependencies.get(r.identHash)?.descriptorHash;if(U!==r.descriptorHash&&W!==r.descriptorHash)return je.mapAndFind.skip;let ee=[];for(let ie of Ut.allDependencies){let ue=N.manifest[ie].get(I.identHash);typeof ue>"u"||ee.push([ie,ue])}return ee.length===0?je.mapAndFind.skip:ee});if(typeof R<"u")for(let[N,U]of R)t.manifest[N].set(U.identHash,U);else{try{let N=n.normalizeDependency(I);if((await f.getCandidates(N,{},p)).length===0)return}catch{return}t.manifest[Xu.Target.DEVELOPMENT].set(I.identHash,I)}},lPt=async(t,e,r)=>{if(r.scope==="types")return;let{project:s}=t,{configuration:a}=s;if(!(a.get("tsEnableAutoTypes")??(ce.existsSync(J.join(t.cwd,"tsconfig.json"))||ce.existsSync(J.join(s.cwd,"tsconfig.json")))))return;let c=Ake(r),f=G.makeIdent("types",c);for(let p of Ut.allDependencies)typeof t.manifest[p].get(f.identHash)>"u"||t.manifest[p].delete(f.identHash)},cPt=(t,e)=>{e.publishConfig&&e.publishConfig.typings&&(e.typings=e.publishConfig.typings),e.publishConfig&&e.publishConfig.types&&(e.types=e.publishConfig.types)},uPt={configuration:{tsEnableAutoTypes:{description:"Whether Yarn should auto-install @types/ dependencies on 'yarn add'",type:"BOOLEAN",isNullable:!0,default:null}},hooks:{afterWorkspaceDependencyAddition:aPt,afterWorkspaceDependencyRemoval:lPt,beforeWorkspacePacking:cPt}},fPt=uPt;var pz={};Vt(pz,{VersionApplyCommand:()=>Y1,VersionCheckCommand:()=>V1,VersionCommand:()=>J1,default:()=>dPt,versionUtils:()=>W1});Ge();Ge();Yt();var W1={};Vt(W1,{Decision:()=>G1,applyPrerelease:()=>pke,applyReleases:()=>Az,applyStrategy:()=>sP,clearVersionFiles:()=>cz,getUndecidedDependentWorkspaces:()=>aP,getUndecidedWorkspaces:()=>UL,openVersionFile:()=>q1,requireMoreDecisions:()=>pPt,resolveVersionFiles:()=>oP,suggestStrategy:()=>fz,updateVersionFiles:()=>uz,validateReleaseDecision:()=>dy});Ge();Dt();wc();Yt();ql();var kA=ut(Ai()),APt=/^(>=|[~^]|)(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(-(0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(\.(0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*)?(\+[0-9a-zA-Z-]+(\.[0-9a-zA-Z-]+)*)?$/,G1=(h=>(h.UNDECIDED="undecided",h.DECLINE="decline",h.MAJOR="major",h.MINOR="minor",h.PATCH="patch",h.PREMAJOR="premajor",h.PREMINOR="preminor",h.PREPATCH="prepatch",h.PRERELEASE="prerelease",h))(G1||{});function dy(t){let e=kA.default.valid(t);return e||je.validateEnum(O4(G1,"UNDECIDED"),t)}async function oP(t,{prerelease:e=null}={}){let r=new Map,s=t.configuration.get("deferredVersionFolder");if(!ce.existsSync(s))return r;let a=await ce.readdirPromise(s);for(let n of a){if(!n.endsWith(".yml"))continue;let c=J.join(s,n),f=await ce.readFilePromise(c,"utf8"),p=ls(f);for(let[h,E]of Object.entries(p.releases||{})){if(E==="decline")continue;let C=G.parseIdent(h),S=t.tryWorkspaceByIdent(C);if(S===null)throw new Error(`Assertion failed: Expected a release definitioLine truncated
- ${f.map(P=>fe.fromPortablePath(P)).join(`
- `)}`);let p=new Set(je.mapAndFilter(n,P=>{let I=t.tryWorkspaceByFilePath(P);return I===null?je.mapAndFilter.skip:I}));if(f.length===0&&p.size===0&&!e)return null;let h=f.length===1?f[0]:J.join(c,`${Nn.makeHash(Math.random().toString()).slice(0,8)}.yml`),E=ce.existsSync(h)?await ce.readFilePromise(h,"utf8"):"{}",C=ls(E),S=new Map;for(let P of C.declined||[]){let I=G.parseIdent(P),R=t.getWorkspaceByIdent(I);S.set(R,"decline")}for(let[P,I]of Object.entries(C.releases||{})){let R=G.parseIdent(P),N=t.getWorkspaceByIdent(R);S.set(N,dy(I))}return{project:t,root:s,baseHash:a!==null?a.hash:null,baseTitle:a!==null?a.title:null,changedFiles:new Set(n),changedWorkspaces:p,releaseRoots:new Set([...p].filter(P=>P.manifest.version!==null)),releases:S,async saveAll(){let P={},I=[],R=[];for(let N of t.workspaces){if(N.manifest.version===null)continue;let U=G.stringifyIdent(N.anchoredLocator),W=S.get(N);W==="decline"?I.push(U):typeof W<"u"?P[U]=dy(W):p.has(N)&&R.push(U)}await ce.mkdirPromise(J.dirname(h),{recursive:!0}),await ce.changeFilePromise(h,nl(new nl.PreserveOrdering({releases:Object.keys(P).length>0?P:void 0,declined:I.length>0?I:void 0,undecided:R.length>0?R:void 0})))}}}function pPt(t){return UL(t).size>0||aP(t).length>0}function UL(t){let e=new Set;for(let r of t.changedWorkspaces)r.manifest.version!==null&&(t.releases.has(r)||e.add(r));return e}function aP(t,{include:e=new Set}={}){let r=[],s=new Map(je.mapAndFilter([...t.releases],([n,c])=>c==="decline"?je.mapAndFilter.skip:[n.anchoredLocator.locatorHash,n])),a=new Map(je.mapAndFilter([...t.releases],([n,c])=>c!=="decline"?je.mapAndFilter.skip:[n.anchoredLocator.locatorHash,n]));for(let n of t.project.workspaces)if(!(!e.has(n)&&(a.has(n.anchoredLocator.locatorHash)||s.has(n.anchoredLocator.locatorHash)))&&n.manifest.version!==null)for(let c of Ut.hardDependencies)for(let f of n.manifest.getForScope(c).values()){let p=t.project.tryWorkspaceByDescriptor(f);p!==null&&s.has(p.anchoredLocator.locatorHash)&&r.push([n,p])}return r}function fz(t,e){let r=kA.default.clean(e);for(let s of Object.values(G1))if(s!=="undecided"&&s!=="decline"&&kA.default.inc(t,s)===r)return s;return null}function sP(t,e){if(kA.default.valid(e))return e;if(t===null)throw new nt(`Cannot apply the release strategy "${e}" unless the workspace already has a valid version`);if(!kA.default.valid(t))throw new nt(`Cannot apply the release strategy "${e}" on a non-semver version (${t})`);let r=kA.default.inc(t,e);if(r===null)throw new nt(`Cannot apply the release strategy "${e}" on the specified version (${t})`);return r}function Az(t,e,{report:r,exact:s}){let a=new Map;for(let n of t.workspaces)for(let c of Ut.allDependencies)for(let f of n.manifest[c].values()){let p=t.tryWorkspaceByDescriptor(f);if(p===null||!e.has(p))continue;je.getArrayWithDefault(a,p).push([n,c,f.identHash])}for(let[n,c]of e){let f=n.manifest.version;n.manifest.version=c,kA.default.prerelease(c)===null?delete n.manifest.raw.stableVersion:n.manifest.raw.stableVersion||(n.manifest.raw.stableVersion=f);let p=n.manifest.name!==null?G.stringifyIdent(n.manifest.name):null;r.reportInfo(0,`${G.prettyLocator(t.configuration,n.anchoredLocator)}: Bumped to ${c}`),r.reportJson({cwd:fe.fromPortablePath(n.cwd),ident:p,oldVersion:f,newVersion:c});let h=a.get(n);if(!(typeof h>"u"))for(let[E,C,S]of h){let P=E.manifest[C].get(S);if(typeof P>"u")throw new Error("Assertion failed: The dependency should have existed");let I=P.range,R=!1;if(I.startsWith(Ei.protocol)&&(I=I.slice(Ei.protocol.length),R=!0,I===n.relativeCwd))continue;let N=I.match(APt);if(!N){r.reportWarning(0,`Couldn't auto-upgrade range ${I} (in ${G.prettyLocator(t.configuration,E.anchoredLocator)})`);continue}let U=s?`${c}`:`${N[1]}${c}`;R&&(U=`${Ei.protocol}${U}`);let W=G.makeDescriptor(P,U);E.manifest[C].set(S,W)}}}var hPt=new Map([["%n",{extract:t=>t.length>=1?[t[0],t.slice(1)]:null,generate:(t=0)=>`${t+1}`}]]);function pke(t,{current:e,prerelease:r}){let s=new kA.default.SemVer(e),a=s.prerelease.slice(),n=[];s.prerelease=[],s.format()!==t&&(a.length=0);let c=!0,f=r.split(/\./g);for(let p of f){let h=hPt.get(p);if(typeof h>"u")n.push(p),a[0]===p?a.shift():c=!1;else{let E=c?h.extract(a):null;E!==null&&typeof E[0]=="number"?(n.push(h.generate(E[0])),a=E[1]):(n.push(h.generate()),c=!1)}}return s.prerelease&&(s.prerelease=[]),`${t}-${n.join(".")}`}var Y1=class extends ft{constructor(){super(...arguments);this.all=ge.Boolean("--all",!1,{description:"Apply the deferred version changes on all workspaces"});this.dryRun=ge.Boolean("--dry-run",!1,{description:"Print the versions without actually generating the package archive"});this.prerelease=ge.String("--prerelease",{description:"Add a prerelease identifier to new versions",tolerateBoolean:!0});this.exact=ge.Boolean("--exact",!1,{description:"Use the exact version of each package, removes any range. Useful for nightly releases where the range might match another version."});this.recursive=ge.Boolean("-R,--recursive",{description:"ReleLine truncated
This command will apply the deferred version changes and remove their definitions from the repository.
Note that if \`--prerelease\` is set, the given prerelease identifier (by default \`rc.%n\`) will be used on all new versions and the version definitions will be kept as-is.
By default only the current workspace will be bumped, but you can configure this behavior by using one of:
- \`--recursive\` to also apply the version bump on its dependencies
- \`--all\` to apply the version bump on all packages in the repository
Note that this command will also update the \`workspace:\` references across all your local workspaces, thus ensuring that they keep referring to the same workspaces even after the version bump.
`,examples:[["Apply the version change to the local workspace","yarn version apply"],["Apply the version change to all the workspaces in the local workspace","yarn version apply --all"]]})}async execute(){let r=await ze.find(this.context.cwd,this.context.plugins),{project:s,workspace:a}=await Tt.find(r,this.context.cwd),n=await Kr.find(r);if(!a)throw new ar(s.cwd,this.context.cwd);await s.restoreInstallState({restoreResolutions:!1});let c=await Ot.start({configuration:r,json:this.json,stdout:this.context.stdout},async f=>{let p=this.prerelease?typeof this.prerelease!="boolean"?this.prerelease:"rc.%n":null,h=await oP(s,{prerelease:p}),E=new Map;if(this.all)E=h;else{let C=this.recursive?a.getRecursiveWorkspaceDependencies():[a];for(let S of C){let P=h.get(S);typeof P<"u"&&E.set(S,P)}}if(E.size===0){let C=h.size>0?" Did you want to add --all?":"";f.reportWarning(0,`The current workspace doesn't seem to require a version bump.${C}`);return}Az(s,E,{report:f,exact:this.exact}),this.dryRun||(p||(this.all?await cz(s):await uz(s,[...E.keys()])),f.reportSeparator())});return this.dryRun||c.hasErrors()?c.exitCode():await s.installWithNewReport({json:this.json,stdout:this.context.stdout},{cache:n})}};Ge();Dt();Yt();var _L=ut(Ai());var V1=class extends ft{constructor(){super(...arguments);this.interactive=ge.Boolean("-i,--interactive",{description:"Open an interactive interface used to set version bumps"})}static{this.paths=[["version","check"]]}static{this.usage=ot.Usage({category:"Release-related commands",description:"check that all the relevant packages have been bumped",details:"\n **Warning:** This command currently requires Git.\n\n This command will check that all the packages covered by the files listed in argument have been properly bumped or declined to bump.\n\n In the case of a bump, the check will also cover transitive packages - meaning that should `Foo` be bumped, a package `Bar` depending on `Foo` will require a decision as to whether `Bar` will need to be bumped. This check doesn't cross packages that have declined to bump.\n\n In case no arguments are passed to the function, the list of modified files will be generated by comparing the HEAD against `master`.\n ",examples:[["Check whether the modified packages need a bump","yarn version check"]]})}async execute(){return this.interactive?await this.executeInteractive():await this.executeStandard()}async executeInteractive(){iw(this.context);let{Gem:r}=await Promise.resolve().then(()=>(WF(),LW)),{ScrollableItems:s}=await Promise.resolve().then(()=>(KF(),JF)),{FocusRequest:a}=await Promise.resolve().then(()=>(UW(),v2e)),{useListInput:n}=await Promise.resolve().then(()=>(VF(),S2e)),{renderForm:c}=await Promise.resolve().then(()=>($F(),ZF)),{Box:f,Text:p}=await Promise.resolve().then(()=>ut(Wc())),{default:h,useCallback:E,useState:C}=await Promise.resolve().then(()=>ut(hn())),S=await ze.find(this.context.cwd,this.context.plugins),{project:P,workspace:I}=await Tt.find(S,this.context.cwd);if(!I)throw new ar(P.cwd,this.context.cwd);await P.restoreInstallState();let R=await q1(P);if(R===null||R.releaseRoots.size===0)return 0;if(R.root===null)throw new nt("This command can only be run on Git repositories");let N=()=>h.createElement(f,{flexDirection:"row",paddingBottom:1},h.createElement(f,{flexDirection:"column",width:60},h.createElement(f,null,h.createElement(p,null,"Press ",h.createElement(p,{bold:!0,color:"cyanBright"},"<up>"),"/",h.createElement(p,{bold:!0,color:"cyanBright"},"<down>")," to select workspaces.")),h.createElement(f,null,h.createElement(p,null,"Press ",h.createElement(p,{bold:!0,color:"cyanBright"},"<left>"),"/",h.createElement(p,{bold:!0,color:"cyanBright"},"<right>")," to select release strategies."))),h.createElement(f,{flexDirection:"column"},h.createElement(f,{marginLeft:1},h.createElement(p,null,"Press ",h.createElement(p,{bold:!0,color:"cyanBright"},"<enter>")," to save.")),h.createElement(f,{marginLeft:1},h.createElement(p,null,"Press ",h.createElement(p,{bold:!0,color:"cyanBright"},"<ctrl+c>")," to abort.")))),U=({workspace:me,active:pe,decision:Be,setDecision:Ce})=>{let g=me.manifest.raw.stableVersion??me.manifest.version;if(g===null)throw new Error(`Assertion failed: The version should have been set (${G.prettyLocator(S,me.anchoredLocator)})`);if(_L.default.prerelease(g)!==null)throw new Error(`Assertion failed: Prerelease identifiers shouldn't be found (${g})`);let we=["undecided","decline","patch","minor","major"];n(Be,we,{active:pe,minus:"left",plus:"right",set:Ce});let ye=Be==="undecided"?h.createElement(p,{color:"yellow"},g):Be==="decline"?h.createElement(p,{color:"green"},g):h.createElement(p,null,h.createElement(p,{color:"magenta"},g)," \u2192 ",h.createElement(p,{color:"green"},_L.default.valid(Be)?Be:_L.default.inc(g,Be)));return h.createElement(f,{flexDirection:"column"},h.createElement(f,null,h.createElement(p,null,G.prettyLocator(S,me.anchoredLocator)," - ",ye)),h.createElement(f,null,we.map(AeLine truncated
`)},p=()=>{let Ce=this.from.map(g=>z1.default.matcher(g));return s.workspaces.filter(g=>{let we=G.stringifyIdent(g.anchoredLocator),ye=g.relativeCwd;return Ce.some(Ae=>Ae(we)||Ae(ye))})},h=[];if(this.since?(f("Option --since is set; selecting the changed workspaces as root for workspace selection"),h=Array.from(await ka.fetchChangedWorkspaces({ref:this.since,project:s}))):this.from?(f("Option --from is set; selecting the specified workspaces"),h=[...p()]):this.worktree?(f("Option --worktree is set; selecting the current workspace"),h=[a]):this.recursive?(f("Option --recursive is set; selecting the current workspace"),h=[a]):this.all&&(f("Option --all is set; selecting all workspaces"),h=[...s.workspaces]),this.dryRun&&!this.all){for(let Ce of h)f(`
- ${Ce.relativeCwd}
${G.prettyLocator(r,Ce.anchoredLocator)}`);h.length>0&&f("")}let E;if(this.recursive?this.since?(f("Option --recursive --since is set; recursively selecting all dependent workspaces"),E=new Set(h.map(Ce=>[...Ce.getRecursiveWorkspaceDependents()]).flat())):(f("Option --recursive is set; recursively selecting all transitive dependencies"),E=new Set(h.map(Ce=>[...Ce.getRecursiveWorkspaceDependencies()]).flat())):this.worktree?(f("Option --worktree is set; recursively selecting all nested workspaces"),E=new Set(h.map(Ce=>[...Ce.getRecursiveWorkspaceChildren()]).flat())):E=null,E!==null&&(h=[...new Set([...h,...E])],this.dryRun))for(let Ce of E)f(`
- ${Ce.relativeCwd}
${G.prettyLocator(r,Ce.anchoredLocator)}`);let C=[],S=!1;if(c?.includes(":")){for(let Ce of s.workspaces)if(Ce.manifest.scripts.has(c)&&(S=!S,S===!1))break}for(let Ce of h){if(c&&!Ce.manifest.scripts.has(c)&&!S&&!(await In.getWorkspaceAccessibleBinaries(Ce)).has(c)){f(`Excluding ${Ce.relativeCwd} because it doesn't have a "${c}" script`);continue}if(!(c===r.env.npm_lifecycle_event&&Ce.cwd===a.cwd)){if(this.include.length>0&&!z1.default.isMatch(G.stringifyIdent(Ce.anchoredLocator),this.include)&&!z1.default.isMatch(Ce.relativeCwd,this.include)){f(`Excluding ${Ce.relativeCwd} because it doesn't match the --include filter`);continue}if(this.exclude.length>0&&(z1.default.isMatch(G.stringifyIdent(Ce.anchoredLocator),this.exclude)||z1.default.isMatch(Ce.relativeCwd,this.exclude))){f(`Excluding ${Ce.relativeCwd} because it matches the --exclude filter`);continue}if(this.publicOnly&&Ce.manifest.private===!0){f(`Excluding ${Ce.relativeCwd} because it's a private workspace and --no-private was set`);continue}C.push(Ce)}}if(this.dryRun)return 0;let P=this.verbose??(this.context.stdout.isTTY?1/0:0),I=P>0,R=P>1,N=this.parallel?this.jobs==="unlimited"?1/0:Number(this.jobs)||Math.ceil(Ui.availableParallelism()/2):1,U=N===1?!1:this.parallel,W=U?this.interlaced:!0,ee=(0,gke.default)(N),ie=new Map,ue=new Set,le=0,me=null,pe=!1,Be=await Ot.start({configuration:r,stdout:this.context.stdout,includePrefix:!1},async Ce=>{let g=async(we,{commandIndex:ye})=>{if(pe)return-1;!U&&R&&ye>1&&Ce.reportSeparator();let Ae=mPt(we,{configuration:r,label:I,commandIndex:ye}),[se,Z]=hke(Ce,{prefix:Ae,interlaced:W}),[De,Re]=hke(Ce,{prefix:Ae,interlaced:W});try{R&&Ce.reportInfo(null,`${Ae?`${Ae} `:""}Process started`);let mt=Date.now(),j=await this.cli.run([this.commandName,...this.args],{cwd:we.cwd,stdout:se,stderr:De})||0;se.end(),De.end(),await Z,await Re;let rt=Date.now();if(R){let Fe=r.get("enableTimers")?`, completed in ${he.pretty(r,rt-mt,he.Type.DURATION)}`:"";Ce.reportInfo(null,`${Ae?`${Ae} `:""}Process exited (exit code ${j})${Fe}`)}return j===130&&(pe=!0,me=j),j}catch(mt){throw se.end(),De.end(),await Z,await Re,mt}};for(let we of C)ie.set(we.anchoredLocator.locatorHash,we);for(;ie.size>0&&!Ce.hasErrors();){let we=[];for(let[Z,De]of ie){if(ue.has(De.anchoredDescriptor.descriptorHash))continue;let Re=!0;if(this.topological||this.topologicalDev){let mt=this.topologicalDev?new Map([...De.manifest.dependencies,...De.manifest.devDependencies]):De.manifest.dependencies;for(let j of mt.values()){let rt=s.tryWorkspaceByDescriptor(j);if(Re=rt===null||!ie.has(rt.anchoredLocator.locatorHash),!Re)break}}if(Re&&(ue.add(De.anchoredDescriptor.descriptorHash),we.push(ee(async()=>{let mt=await g(De,{commandIndex:++le});return ie.delete(Z),ue.delete(De.anchoredDescriptor.descriptorHash),{workspace:De,exitCode:mt}})),!U))break}if(we.length===0){let Z=Array.from(ie.values()).map(De=>G.prettyLocator(r,De.anchoredLocator)).join(", ");Ce.reportError(3,`Dependency cycle detected (${Z})`);return}let ye=await Promise.all(we);ye.forEach(({workspace:Z,exitCode:De})=>{De!==0&&Ce.reportError(0,`The command failed in workspace ${G.prettyLocator(r,Z.anchoredLocator)} with exit code ${De}`)});let se=ye.map(Z=>Z.exitCode).find(Z=>Z!==0);(this.topological||this.topologicalDev)&&typeof se<"u"&&Ce.reportError(0,"The command failed for workspaces that are depended upon by other workspaces; can't satisfy the dependency graph")}});return me!==null?me:Be.exitCode()}};function hke(t,{prefix:e,interlaced:r}){let s=t.createStreamReporter(e),a=new je.DefaultStream;a.pipe(s,{end:!1}),a.on("finish",()=>{s.end()});let n=new Promise(f=>{s.on("finish",()=>{f(a.active)})});if(r)return[a,n];let c=new je.BufferStream;return c.pipe(a,{end:!1}),c.on("finish",()=>{a.end()}),[c,n]}function mPt(t,{configuration:e,commandIndex:r,label:s}){if(!s)return null;let n=`[${G.stringifyIdent(t.anchoredLocator)}]:`,c=["#2E86AB","#A23B72","#F18F01","#C73E1D","#CCE2A3"],f=c[r%c.length];return he.pretty(e,n,f)}var yPt={commands:[K1,X1]},EPt=yPt;var tC=()=>({modules:new Map([["@yarnpkg/cli",Gv],["@yarnpkg/core",jv],["@yarnpkg/fslib",_2],["@yarnpkg/libzip",fv],["@yarnpkg/parsers",J2],["@yarnpkg/shell",mv],["clipanion",oB],["semver",IPt],["typanion",Ea],["@yarnpkg/plugin-essentials",hq],["@yarnpkg/plugin-catalog",yq],["@yarnpkg/plugin-compat",Bq],["@yarnpkg/plugin-constraints",_q],["@yarnpkg/plugin-dlx",Hq],["@yarnpkg/plugin-exec",qq],["@yarnpkg/plugin-file",Yq],["@yarnpkg/plugin-git",pq],["@yarnpkg/plugin-github",Kq],["@yarnpkg/plugin-http",zq],["@yarnpkg/plugin-init",Xq],["@yarnpkg/plugin-interactive-tools",JW],["@yarnpkg/plugin-jsr",zW],["@yarnpkg/plugin-link",XW],["@yarnpkg/plugin-nm",FY],["@yarnpkg/plugin-npm",FK],["@yarnpkg/plugin-npm-cli",qK],["@yarnpkg/plugin-pack",bV],["@yarnpkg/plugin-patch",XK],["@yarnpkg/plugin-pnp",wY],["@yarnpkg/plugin-pnpm",ez],["@yarnpkg/plugin-stage",az],["@yarnpkg/plugin-typescript",lz],["@yarnpkg/plugin-version",pz],["@yarnpkg/plugin-workspace-tools",hz]]),plugins:new SetLine truncated
Please report this issue at https://github.com/yarnpkg/berry/issues.`)}process.once("beforeExit",n);try{process.exitCode=42,process.exitCode=await SPt(a,t,{selfPath:r,pluginConfiguration:s})}catch(c){Ca.defaultContext.stdout.write(a.error(c)),process.exitCode=1}finally{process.off("beforeExit",n),await ce.rmtempPromise()}}VR(process.argv.slice(2),{cwd:J.cwd(),selfPath:fe.toPortablePath(fe.resolve(process.argv[1])),pluginConfiguration:tC()});})();
/**
@license
Copyright (c) 2015, Rebecca Turner
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted, provided that the above
copyright notice and this permission notice appear in all copies.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.
*/
/**
@license
Copyright Node.js contributors. All rights reserved.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to
deal in the Software without restriction, including without limitation the
rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
sell copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
IN THE SOFTWARE.
*/
/**
@license
The MIT License (MIT)
Copyright (c) 2014 Blake Embrey (hello@blakeembrey.com)
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
/**
@license
Copyright Joyent, Inc. and other Node contributors.
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to permit
persons to whom the Software is furnished to do so, subject to the
following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
/*! Bundled license information:
is-number/index.js:
(*!
* is-number <https://github.com/jonschlinkert/is-number>
*
* Copyright (c) 2014-present, Jon Schlinkert.
* Released under the MIT License.
*)
to-regex-range/index.js:
(*!
* to-regex-range <https://github.com/micromatch/to-regex-range>
*
* Copyright (c) 2015-present, Jon Schlinkert.
* Released under the MIT License.
*)
fill-range/index.js:
(*!
* fill-range <https://github.com/jonschlinkert/fill-range>
*
* Copyright (c) 2014-present, Jon Schlinkert.
* Licensed under the MIT License.
*)
is-extglob/index.js:
(*!
* is-extglob <https://github.com/jonschlinkert/is-extglob>
*
* Copyright (c) 2014-2016, Jon Schlinkert.
* Licensed under the MIT License.
*)
is-glob/index.js:
(*!
* is-glob <https://github.com/jonschlinkert/is-glob>
*
* Copyright (c) 2014-2017, Jon Schlinkert.
* Released under the MIT License.
*)
queue-microtask/index.js:
(*! queue-microtask. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> *)
run-parallel/index.js:
(*! run-parallel. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> *)
git-url-parse/lib/index.js:
(*!
* buildToken
* Builds OAuth token prefix (helper function)
*
* @name buildToken
* @function
* @param {GitUrl} obj The parsed Git url object.
* @return {String} token prefix
*)
object-assign/index.js:
(*
object-assign
(c) Sindre Sorhus
@license MIT
*)
react/cjs/react.production.min.js:
(** @license React v17.0.2
* react.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*)
scheduler/cjs/scheduler.production.min.js:
(** @license React v0.20.2
* scheduler.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*)
react-reconciler/cjs/react-reconciler.production.min.js:
(** @license React v0.26.2
* react-reconciler.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*)
is-windows/index.js:
(*!
* is-windows <https://github.com/jonschlinkert/is-windows>
*
* Copyright © 2015-2018, Jon Schlinkert.
* Released under the MIT License.
*)
*/
+16 -4
View File
@@ -1,9 +1,21 @@
compressionLevel: mixed
enableGlobalCache: false
enableImmutableInstalls: false
nodeLinker: node-modules
plugins:
- path: .yarn/plugins/@yarnpkg/plugin-workspace-tools.cjs
spec: "@yarnpkg/plugin-workspace-tools"
npmScopes:
navikt:
npmAlwaysAuth: true
npmAuthToken: "${NPM_AUTH_TOKEN:-}"
npmRegistryServer: "https://npm.pkg.github.com"
yarnPath: .yarn/releases/yarn-3.2.1.cjs
enableScripts: false
defaultSemverRangePrefix: ""
npmMinimalAgeGate: "7d"
npmPreapprovedPackages: ["@navikt/*"]
enableTelemetry: false
yarnPath: .yarn/releases/yarn-4.12.0.cjs
+2 -1
View File
@@ -5,12 +5,13 @@ module.exports = {
ref: true,
icon: true,
titleProp: true,
jsxRuntime: "automatic",
svgProps: {
focusable: false,
role: "img",
},
replaceAttrValues: {
"#23262A": "currentColor",
"#202733": "currentColor",
},
template,
};
+492
View File
@@ -1,5 +1,497 @@
# @navikt/aksel-icons
## 8.10.2
## 8.10.1
## 8.10.0
## 8.9.1
## 8.9.0
## 8.8.0
## 8.7.0
## 8.6.0
## 8.5.2
## 8.5.1
## 8.5.0
## 8.4.1
## 8.4.0
## 8.3.0
## 8.2.2
## 8.2.1
## 8.2.0
## 8.1.0
## 8.0.1
## 8.0.0
## 7.40.0
### Minor Changes
- Icons: New icon MagnifyingGlassCheckmark ([#4489](https://github.com/navikt/aksel/pull/4489))
## 7.39.1
## 7.39.0
## 7.38.0
## 7.37.0
## 7.36.0
### Patch Changes
- Icons: Removed 'updated_at'-field from AkselIcon-type. ([#4399](https://github.com/navikt/aksel/pull/4399))
## 7.35.3
## 7.35.2
## 7.35.1
## 7.35.0
## 7.34.0
### Minor Changes
- Icons: :tada: New icons `PhoneSlash` and `BellSlash`. ([#4310](https://github.com/navikt/aksel/pull/4310))
## 7.33.5
## 7.33.4
## 7.33.3
## 7.33.2
## 7.33.1
## 7.33.0
## 7.32.5
## 7.32.4
## 7.32.3
### Patch Changes
- Icons: Modified 'Robot' type icons. ([#4200](https://github.com/navikt/aksel/pull/4200))
## 7.32.2
## 7.32.1
## 7.32.0
### Minor Changes
- Icons: Updated `SignLanguageTwoHands`-design. ([#4115](https://github.com/navikt/aksel/pull/4115))
- Icons: :tada: Added some new icons `ChairTable`, `Footprint`, `Lifebuoy`, `OpenBook`, `OpenMagazine` and `Slide`. ([#4115](https://github.com/navikt/aksel/pull/4115))
## 7.31.0
## 7.30.1
## 7.30.0
## 7.29.1
## 7.29.0
### Minor Changes
- Icons: :tada: New icons `CheckmarkHeavy` and `PageBreak`. ([#4038](https://github.com/navikt/aksel/pull/4038))
## 7.28.1
## 7.28.0
### Minor Changes
- Icons: :tada: New icons 'ArrowCirclepathReverse' and 'ArrowsAllDirections'. ([#3979](https://github.com/navikt/aksel/pull/3979))
## 7.27.1
## 7.27.0
### Patch Changes
- Icons: ChatAdd did not have 'currentColor' on parts of shape. ([#3963](https://github.com/navikt/aksel/pull/3963))
## 7.26.0
### Minor Changes
- Icons: New icons 'ChatAdd' and 'Theme'. ([#3958](https://github.com/navikt/aksel/pull/3958))
## 7.25.2
## 7.25.1
## 7.25.0
## 7.24.0
## 7.23.2
## 7.23.1
## 7.23.0
### Minor Changes
- Icons: :tada: Added new icons 'SquareGrid' and 'SquareGridFill'. ([#3851](https://github.com/navikt/aksel/pull/3851))
## 7.22.0
## 7.21.1
## 7.21.0
### Minor Changes
- Icons: New icon 'Cpu'. ([#3740](https://github.com/navikt/aksel/pull/3740))
## 7.20.0
## 7.19.1
## 7.19.0
## 7.18.0
## 7.17.4
## 7.17.3
## 7.17.2
## 7.17.1
## 7.17.0
## 7.16.1
## 7.16.0
## 7.15.0
## 7.14.3
## 7.14.2
## 7.14.1
## 7.14.0
### Minor Changes
- Icons: :tada: New icons `LineHeight`, `SpaceHorizontal` and `SpaceVertical`. ([#3587](https://github.com/navikt/aksel/pull/3587))
## 7.13.0
### Minor Changes
- Icons: :tada: New icons `ExpandVertical` and `QuestionmarkCircle` ([#3583](https://github.com/navikt/aksel/pull/3583))
## 7.12.2
## 7.12.1
## 7.12.0
## 7.11.0
### Minor Changes
- Icons: Added new icons 'SortUp' and 'SortDown' 🎉. ([#3528](https://github.com/navikt/aksel/pull/3528))
## 7.10.0
## 7.9.2
## 7.9.1
## 7.9.0
## 7.8.1
## 7.8.0
## 7.7.0
## 7.6.0
### Minor Changes
- Icons: Added new icons 'TruckPercent' and 'ShieldCheckmark' 🎉. ([#3416](https://github.com/navikt/aksel/pull/3416))
## 7.5.3
## 7.5.2
## 7.5.1
## 7.5.0
### Minor Changes
- Icons: 🎉 Added FileJpeg, FilePng and MedicalThermometer. ([#3332](https://github.com/navikt/aksel/pull/3332))
## 7.4.3
## 7.4.2
## 7.4.1
## 7.4.0
## 7.3.1
## 7.3.0
## 7.2.1
## 7.2.0
## 7.1.2
## 7.1.1
## 7.1.0
## 7.0.1
## 7.0.0
### Major Changes
- Icons: Removed renamed icons. [See migration guide for changes](https://aksel.nav.no/grunnleggende/kode/migrering#194b60833d9e). ([#3139](https://github.com/navikt/aksel/pull/3139))
## 6.17.0
### Minor Changes
- Icons: New 'face' icons for 'Engagement'-category. ([#3134](https://github.com/navikt/aksel/pull/3134))
## 6.16.3
### Patch Changes
- Icons: Updated Clipboard icons. ([#3113](https://github.com/navikt/aksel/pull/3113))
## 6.16.2
## 6.16.1
## 6.16.0
## 6.15.0
### Minor Changes
- Icons: New icon-series for 'SplitHorizontal' and 'SplitVertical' ([#3072](https://github.com/navikt/aksel/pull/3072))
## 6.14.0
## 6.13.0
## 6.12.0
### Minor Changes
- Icons: New icon ChildHairEyes ([#3020](https://github.com/navikt/aksel/pull/3020))
### Patch Changes
- Icons: FigureCombination icon adjusted ([#3031](https://github.com/navikt/aksel/pull/3031))
## 6.11.0
## 6.10.1
### Patch Changes
- Icons: Added back support for sourcemapping. ([#2978](https://github.com/navikt/aksel/pull/2978))
## 6.10.0
## 6.9.0
### Minor Changes
- Icons: New icons for geometric shapes ([#2927](https://github.com/navikt/aksel/pull/2927))
## 6.8.0
## 6.7.1
## 6.7.0
## 6.6.1
## 6.6.0
## 6.5.0
## 6.4.1
## 6.4.0
## 6.3.6
## 6.3.5
## 6.3.4
## 6.3.3
## 6.3.2
## 6.3.1
## 6.3.0
## 6.2.0
### Minor Changes
- Ikoner: Nytt ikon `archive` ([#2772](https://github.com/navikt/aksel/pull/2772))
- Ikoner: Nytt ikon `opensource` ([#2787](https://github.com/navikt/aksel/pull/2787))
## 6.1.1
## 6.1.0
## 6.0.0
### Major Changes
- ESM: ds-react og aksel-icons støtter nå native ESM 🎉 ([#2623](https://github.com/navikt/aksel/pull/2623))
### Minor Changes
- SSR: ds-react og aksel-icons støtter nå `use client` og kan brukes i nextjs app-router uten lokal re-eksportering. ([#2623](https://github.com/navikt/aksel/pull/2623))
## 5.18.3
## 5.18.2
## 5.18.1
## 5.18.0
## 5.17.5
## 5.17.4
## 5.17.3
## 5.17.2
## 5.17.1
## 5.17.0
## 5.16.0
### Patch Changes
- Ikoner: Nytt ikon `LocationPin` ✨ ([#2672](https://github.com/navikt/aksel/pull/2672))
## 5.15.1
## 5.15.0
### Minor Changes
- Ikoner: Synket ikoner med Figma. Lagt til nytt ikon `FigureChild` ([#2629](https://github.com/navikt/aksel/pull/2629))
## 5.14.0
## 5.13.0
## 5.12.5
## 5.12.4
## 5.12.3
## 5.12.2
## 5.12.1
## 5.12.0
### Minor Changes
- Ikoner: Oppdatert ikonpakke med diverse bugdfixes og oppdateringer av stroke ([#2538](https://github.com/navikt/aksel/pull/2538))
## 5.11.5
## 5.11.4
## 5.11.3
## 5.11.2
## 5.11.1
## 5.11.0
### Minor Changes
- Ikoner: Nytt ikon `PushPin` ([#2503](https://github.com/navikt/aksel/pull/2503))
## 5.10.4
## 5.10.3
## 5.10.2
## 5.10.1
## 5.10.0
## 5.9.2
## 5.9.1
## 5.9.0
## 5.8.0
## 5.7.6
## 5.7.5
## 5.7.4
## 5.7.3
## 5.7.2
## 5.7.1
## 5.7.0
+6 -40
View File
@@ -2,58 +2,24 @@
## Foreslå nye ikoner
Om du ikke finner et ikonet du leter etter kan du [åpne et issue på github](https://github.com/navikt/aksel/issues/new?labels=nytt+✨%2Cikoner+🖼%2Cforespørsel+🥰&template&template=new-icon.yaml&title=%5BNytt+ikon%5D%3A+).
Om du ikke finner ikonet du leter etter kan du [lage et issue på GitHub](https://github.com/navikt/aksel/issues/new?labels=nytt+✨%2Cikoner+🖼%2Cforespørsel+🥰&template=new-icon.yaml&title=%5BNytt+ikon%5D%3A+).
## Oppdatere ikon
Hvis du tenker et ikon fortjener en oppdatering eller er utdatert kan [du foreslå det her.](https://github.com/navikt/aksel/issues/new?labels=forespørsel+🥰&template=update-icon.yml&title=%5BInnspill+til+ikon%5D%3A+)
## Legge til nye ikoner selv
Hvis du selv ønsker å legge til nye ikoner kan du kopiere filenes fra `/template` og legge de inn i `/icons` med egen data. Alle ikonene har naming-format `PascalCase`. Alle ikonene har 1 SVG-fil og 1 tilhørende YML-fil.
### Svg
- Sizing, width og height må være 24x24: `width="24" height="24" `
- Viewbox: `viewBox="0 0 24 24"`
- Fill på path: `fill="#23262A"`
### Yml
```yml
name: Template # Samme som filnavn
category: Template category # Hovedkategori
sub_category: Sub category # Underkategori
keywords: # Samling med søkeord
- template1
- template2
- template3
variant: Stroke # Stroke eller Fill
updated_at: 02.01.2023 # Dato for siste oppdatering
created_at: 01.01.2023 # Dato for opprettelse
```
### Publisere oppdatering
Når du har lagt til nye ikoner kan du opprette en pull request. Denne vil bli automatisk testet og så gått gjennom av Aksel-teamet.
Legg gjerne til en `changeset` ved å kjøre `yarn changeset` i terminalen. Dette vil gi oss bedre oversikt over hva som er endret i endringslogger og automatisk bumpe pakke-versjonen ved merge.
#### Teste nytt ikon
Hvis du ønsker å teste om alt stemmer, både i `svg` og `yml` før du lager en PR kan du kjøre `yarn && cd navikt/aksel-icons && yarn test` i terminalen lokalt.
Hvis du tenker et ikon fortjener en oppdatering eller er utdatert kan [du foreslå det her](https://github.com/navikt/aksel/issues/new?labels=forespørsel+🥰&template=update-icon.yml&title=%5BInnspill+til+ikon%5D%3A+).
## Design av nye ikoner
### Generelt
- Designet følger Keyline-malen (under assets i figma-pakken).
- Alle lag og grupper skal bruke `#23262A` for stroke og fill.
- Alle lag og grupper skal bruke `#202733` for stroke og fill.
### Stroke (linje)
- Ikonet må bestå av kun linjer
- Linjene skal være 1.5px, center-aligned
- Ikonet må bestå av kun linjer.
- Linjene skal være 1.5px, center-aligned.
### Fill (fylt)
- Ikoner hvor shapes kan fylles, bør fylles
- Ikoner hvor shapes kan fylles, bør fylles.
+2 -2
View File
@@ -1,6 +1,6 @@
# Aksel icons
800+ open source icons made by Aksel, NAVs designsystem-team
800+ open source icons made by Aksel, Nav's design system team.
- Designed for 24x24px
- Available in React and SVG
@@ -30,7 +30,7 @@ Tip: Use the `title` prop for accessible icons.
### Sizing
Each icons `width` and `height` is default `1em`. This allows you to use the native `fontSize`-prop to adjust sizing. We recommend using at least 1.5rem/24px for best possible visual representation.
Each icon's `width` and `height` is default `1em`. This allows you to use the native `fontSize`-prop to adjust sizing. We recommend using at least 1.5rem/24px for the best possible visual representation.
```jsx
<StarIcon fontSize="1.5rem" />
@@ -0,0 +1,16 @@
import { describe, expect, test } from "vitest";
import { splitIntoParts } from "../config/figma/fetch-icons";
describe("splitIntoParts", () => {
test("should split array into parts correctly with odd count array", () => {
const arr = ["a", "b", "c", "d", "e"];
const result = splitIntoParts(arr, 4);
expect(result).toEqual(["a,b", "c,d", "e"]);
});
test("should split array into parts correctly with even count array", () => {
const arr = ["a", "b", "c", "d", "e", "f"];
const result = splitIntoParts(arr, 4);
expect(result).toEqual(["a,b", "c,d", "e,f"]);
});
});
@@ -1,34 +0,0 @@
const fastglob = require("fast-glob");
const path = require("path");
const jsYaml = require("js-yaml");
const fs = require("fs");
const basePath = path.resolve(__dirname, "../icons");
const ymlList = fastglob
.sync("*.yml", { cwd: basePath })
.map((fileN) => path.basename(fileN));
describe(`Each icons YML-config is valid`, () => {
ymlList.forEach((file) => {
it(`${file} has valid YML-config`, () => {
const ymlData = jsYaml.load(fs.readFileSync(`${basePath}/${file}`), {
schema: jsYaml.JSON_SCHEMA,
});
expect(ymlData.name).toBeTruthy();
expect(ymlData.category).toBeTruthy();
expect(ymlData.sub_category).toBeTruthy();
expect(ymlData.keywords).toBeTruthy();
expect(ymlData.variant).toBeTruthy();
expect(ymlData.keywords.length).toBeGreaterThan(0);
expect(ymlData.updated_at).toBeTruthy();
expect(isDate(ymlData.updated_at)).toBeTruthy();
expect(ymlData.created_at).toBeTruthy();
expect(isDate(ymlData.created_at)).toBeTruthy();
});
});
});
function isDate(dateStr) {
return !isNaN(new Date(dateStr.split(".").reverse().join(".")).getDate());
}
@@ -0,0 +1,37 @@
import fastglob from "fast-glob";
import { JSON_SCHEMA, load } from "js-yaml";
import fs from "node:fs";
import path from "node:path";
import { describe, expect, test } from "vitest";
import { IconYml } from "../config/figma/make-configs";
const basePath = path.resolve(__dirname, "../icons");
const ymlList = fastglob
.sync("*.yml", { cwd: basePath })
.map((fileN) => path.basename(fileN));
describe(`Each icons YML-config is valid`, () => {
ymlList.forEach((file) => {
test(`${file} has valid YML-config`, () => {
const ymlData = load(fs.readFileSync(`${basePath}/${file}`).toString(), {
schema: JSON_SCHEMA,
}) as IconYml;
expect(ymlData.name).toBeTruthy();
expect(ymlData.category).toBeTruthy();
expect(ymlData.sub_category).toBeTruthy();
expect(ymlData.keywords).toBeTruthy();
expect(ymlData.variant).toBeTruthy();
expect(ymlData.keywords.length).toBeGreaterThan(0);
expect(ymlData.created_at).toBeTruthy();
expect(isDate(ymlData.created_at)).toBeTruthy();
});
});
});
function isDate(dateStr: string) {
return !Number.isNaN(
new Date(dateStr.split(".").reverse().join(".")).getDate(),
);
}
@@ -1,32 +0,0 @@
const fastglob = require("fast-glob");
const path = require("path");
const basePath = path.resolve(__dirname, "../icons");
const svgList = fastglob
.sync("*.svg", { cwd: basePath })
.map((fileN) => path.basename(fileN));
const ymlList = fastglob
.sync("*.yml", { cwd: basePath })
.map((fileN) => path.basename(fileN));
describe(`Each SVG-file has a matching YML file`, () => {
it(`must have a corresponding YML file`, () => {
expect(
ymlList
.map((yml) => yml.replace(".yml", ".svg"))
.filter((file) => !svgList.includes(file))
).toStrictEqual([]);
});
});
describe(`Each YML-file has a matching SVG file`, () => {
it(`must have a corresponding SVG file`, () => {
expect(
svgList
.map((svg) => svg.replace(".svg", ".yml"))
.filter((file) => !ymlList.includes(file))
).toStrictEqual([]);
});
});
@@ -0,0 +1,33 @@
import fastglob from "fast-glob";
import path from "node:path";
import { describe, expect, test } from "vitest";
const basePath = path.resolve(__dirname, "../icons");
const svgList = fastglob
.sync("*.svg", { cwd: basePath })
.map((fileN) => path.basename(fileN));
const ymlList = fastglob
.sync("*.yml", { cwd: basePath })
.map((fileN) => path.basename(fileN));
describe(`Each SVG-file has a matching YML file`, () => {
test(`must have a corresponding YML file`, () => {
expect(
ymlList
.map((yml) => yml.replace(".yml", ".svg"))
.filter((file) => !svgList.includes(file)),
).toStrictEqual([]);
});
});
describe(`Each YML-file has a matching SVG file`, () => {
test(`must have a corresponding SVG file`, () => {
expect(
svgList
.map((svg) => svg.replace(".svg", ".yml"))
.filter((file) => !ymlList.includes(file)),
).toStrictEqual([]);
});
});
@@ -1,34 +0,0 @@
import { parseIcon } from "../config/parse-svg";
describe(`SVG should be correctly parsed`, () => {
const simpleSvg = `<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="#23262A"/>
</svg>
`;
const simpleSvgResult = `<svg width="1em" height="1em" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="currentColor"/>
</svg>
`;
const advancedSvg = `<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="#23262A"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="#23262A"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="#23262A"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="#23262A"/>
</svg>
`;
const advancedSvgResult = `<svg width="1em" height="1em" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="currentColor"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="currentColor"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="currentColor"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="currentColor"/>
</svg>
`;
it("a", () => {
expect(parseIcon(simpleSvg)).toEqual(simpleSvgResult);
expect(parseIcon(advancedSvg)).toEqual(advancedSvgResult);
});
});
@@ -0,0 +1,35 @@
import { describe, expect, test } from "vitest";
import { parseIcon } from "../config/parse-svg";
describe(`SVG should be correctly parsed`, () => {
const simpleSvg = `<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="#202733"/>
</svg>
`;
const simpleSvgResult = `<svg width="1em" height="1em" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="currentColor"/>
</svg>
`;
const advancedSvg = `<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="#202733"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="#202733"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="#202733"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="#202733"/>
</svg>
`;
const advancedSvgResult = `<svg width="1em" height="1em" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="currentColor"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="currentColor"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="currentColor"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="18.1559 9.81056 17.4392Z" fill="currentColor"/>
</svg>
`;
test("a", () => {
expect(parseIcon(simpleSvg)).toEqual(simpleSvgResult);
expect(parseIcon(advancedSvg)).toEqual(advancedSvgResult);
});
});
@@ -1,71 +0,0 @@
import { basename } from "path";
import { unified } from "unified";
import parse from "rehype-parse";
import fastglob from "fast-glob";
import { readFileSync } from "fs";
import { select, selectAll } from "hast-util-select";
const basePath = "./icons";
const svgList = fastglob
.sync("*.svg", { cwd: basePath })
.map((fileN) => basename(fileN));
describe(`Each icons has a valid code`, () => {
svgList.forEach((file) => {
describe(`${file} has valid code`, () => {
const iconAst = unified()
.use(parse, { fragment: true, space: "svg" })
.parse(readFileSync(`${basePath}/${file}`));
it(`has valid attributes on root-node`, () => {
const properties = Object.keys(
select(":root", iconAst).properties
).sort();
expect(properties).toStrictEqual(
["viewBox", "xmlns", "height", "width", "fill"].sort()
);
});
it(`has valid xml-attr`, () => {
const xmlns = select(":root", iconAst).properties.xmlns;
expect(xmlns).toBe("http://www.w3.org/2000/svg");
});
it(`has valid viewbox`, () => {
const viewbox = select(":root", iconAst).properties.viewBox;
expect(viewbox).toBe("0 0 24 24");
});
it(`root fill is none`, () => {
const fill = select(":root", iconAst).properties.fill;
expect(fill).toBe("none");
});
it(`has valid width and height`, () => {
const width = select(":root", iconAst).properties.width;
const height = select(":root", iconAst).properties.height;
expect(width).toBe("24");
expect(height).toBe("24");
});
it(`has valid stroke`, () => {
const nodes = selectAll("*", iconAst);
nodes.forEach((n) => {
n.properties?.stroke &&
expect(n.properties.stroke).toEqual("#23262A");
});
});
it(`has valid stroke-width`, () => {
const nodes = selectAll("*", iconAst);
nodes.forEach((n) => {
n.properties?.strokeWidth &&
expect(n.properties?.strokeWidth).toEqual("1.5");
});
});
});
});
});
@@ -0,0 +1,67 @@
import fastglob from "fast-glob";
import { select, selectAll } from "hast-util-select";
import { readFileSync } from "node:fs";
import { basename } from "node:path";
import parse from "rehype-parse";
import { unified } from "unified";
import { describe, expect, test } from "vitest";
const basePath = "./icons";
const svgList = fastglob
.sync("*.svg", { cwd: basePath })
.map((fileN) => basename(fileN));
describe("Each icons has a valid code", () => {
svgList.forEach((file) => {
describe(`${file} has valid code`, () => {
const iconAst = unified()
.use(parse, { fragment: true, space: "svg" })
.parse(readFileSync(`${basePath}/${file}`));
test("has valid attributes on root-node", () => {
const root = select(":root", iconAst);
const properties = Object.keys(root?.properties ?? []).sort();
expect(properties).toStrictEqual(
["viewBox", "xmlns", "height", "width", "fill"].sort(),
);
});
test("has valid xml-attr", () => {
const root = select(":root", iconAst);
expect(root?.properties.xmlns).toBe("http://www.w3.org/2000/svg");
});
test("has valid viewbox", () => {
const root = select(":root", iconAst);
expect(root?.properties.viewBox).toBe("0 0 24 24");
});
test("root fill is none", () => {
const root = select(":root", iconAst);
expect(root?.properties.fill).toBe("none");
});
test("has valid width and height", () => {
const root = select(":root", iconAst);
expect(root?.properties.width).toBe("24");
expect(root?.properties.height).toBe("24");
});
test("has valid fill", () => {
const nodes = selectAll("*", iconAst);
nodes.forEach((node) => {
expect(node.properties.fill).toBeOneOf(["none", "#202733"]);
});
});
test("has valid stroke-width", () => {
const nodes = selectAll("*", iconAst);
nodes.forEach((node) => {
expect(node.properties.strokeWidth).toBeOneOf([undefined, "1.5"]);
});
});
});
});
});
@@ -1,59 +0,0 @@
const file_key = "wEdyFjCQSBR3U7FvrMbPXa";
export const fetchIcons = async () => {
const data = await fetch(
`https://api.figma.com/v1/files/${file_key}/components`,
{
headers: {
"Content-type": "application/json",
"X-FIGMA-TOKEN": process.env.FIGMA_TOKEN,
},
}
)
.then((x) => x.json())
.catch((e) => {
throw e.message;
});
if (!data?.meta?.components || data?.meta?.components.length === 0) {
throw new Error("Fant ingen publiserte ikoner");
}
return data?.meta?.components;
};
export const fetchDownloadUrls = async (idArray) => {
const urls = { images: null };
for (let ids of idArray) {
await fetch(
`https://api.figma.com/v1/images/${file_key}/?ids=${ids}&format=svg`,
{
headers: {
"Content-type": "application/json",
"X-FIGMA-TOKEN": process.env.FIGMA_TOKEN,
},
}
)
.then((x) => x.json())
.then((x) => {
urls.images = {
...urls.images,
...x.images,
};
})
.catch((e) => {
throw e.message;
});
}
return urls;
};
export const fetchIcon = async (url) => {
return await fetch(url)
.then((x) => x.text())
.catch((e) => {
console.log("Error fetching icon: ", e.message);
throw e.message;
});
};
@@ -0,0 +1,114 @@
import {
BadRequestErrorResponseWithErrMessage,
ErrorResponsePayloadWithErrMessage,
GetFileComponentsResponse,
GetImagesResponse,
PublishedComponent,
} from "@figma/rest-api-spec";
/* https://www.figma.com/developers/api#library-items */
const FIGMA_FILE_KEY = "wEdyFjCQSBR3U7FvrMbPXa";
export const fetchIcons = async (): Promise<PublishedComponent[]> => {
console.group("Fetching list of published icons from Figma...");
const data:
| GetFileComponentsResponse
| BadRequestErrorResponseWithErrMessage = await fetch(
`https://api.figma.com/v1/files/${FIGMA_FILE_KEY}/components`,
{
headers: {
"Content-type": "application/json",
"X-FIGMA-TOKEN": process.env.FIGMA_TOKEN ?? "",
},
},
)
.then((x) => x.json())
.catch((e) => {
throw e.message;
});
if (data.status !== 200) {
throw new Error(data.err);
}
if (data.meta.components.length === 0) {
throw new Error("No published icons found");
}
/* Filtes out any 'random' icons not meant for the icon-library */
const validIcons = data.meta.components.filter((icon) => {
const validIcon =
!!icon.containing_frame?.pageName && !!icon.containing_frame?.name;
if (!validIcon) {
console.warn(`Ignoring icon '${icon.name}' as it is missing metadata`);
}
return validIcon;
});
console.info(
`Found ${validIcons.length} published icons in Figma. ${
data.meta.components.length - validIcons.length
} icons were ignored due to missing metadata.`,
);
console.groupEnd();
return validIcons;
};
export const fetchDownloadUrls = async (
nodeIds: string[],
): Promise<Record<string, string>> => {
/* Would just using Record be better here? Yes. But is a self-referencing return kinda cool? Also yes */
const idUrlPairs: Awaited<ReturnType<typeof fetchDownloadUrls>> = {};
/* Figma accepts a comma-separated list of ids: GET /v1/images/:key?ids=1:2,1:3,1:4 */
const paginatedNodeIds = splitIntoParts(nodeIds, 5);
for (const ids of paginatedNodeIds) {
const data: GetImagesResponse | ErrorResponsePayloadWithErrMessage =
await fetch(
`https://api.figma.com/v1/images/${FIGMA_FILE_KEY}/?ids=${ids}&format=svg`,
{
headers: {
"Content-type": "application/json",
"X-FIGMA-TOKEN": process.env.FIGMA_TOKEN ?? "",
},
},
)
.then((x) => x.json())
.catch((e) => {
throw e.message;
});
if (data.err !== null) {
throw new Error(data.err);
}
for (const [key, value] of Object.entries(data.images)) {
if (!value) {
console.warn(`No image found for ${key}`);
continue;
}
idUrlPairs[key] = value;
}
}
return idUrlPairs;
};
/**
* Splits an array of strings into parts where each part is a comma-separated string of all the strings for that part.
* @returns An array of comma-separated strings.
*/
export function splitIntoParts(arr: string[], parts: number): string[] {
const partSize = Math.ceil(arr.length / parts);
const blocks: string[] = [];
for (let i = 0; i < parts && i * partSize < arr.length; i++) {
const part = arr.slice(i * partSize, (i + 1) * partSize);
blocks.push(part.join(","));
}
return blocks;
}
@@ -1,15 +0,0 @@
import startCase from "lodash.startcase";
import camelCase from "lodash.camelCase";
export const resolveName = (icon) => {
const isVariant = icon.name.startsWith("Variant=");
if (isVariant) {
const variant = icon.name.replace("Variant=", "").replace("Stroke", "");
const actualName = icon["containing_frame"]?.["containingStateGroup"]?.name;
const name = `${actualName}${variant}`;
return `${startCase(camelCase(name)).replace(/ /g, "")}.svg`;
}
return `${startCase(camelCase(icon.name)).replace(/ /g, "")}.svg`;
};
@@ -0,0 +1,16 @@
import { PublishedComponent } from "@figma/rest-api-spec";
import { camelCase, startCase } from "lodash";
export const resolveName = (icon: PublishedComponent) => {
const isVariant = icon.name.startsWith("Variant=");
if (isVariant) {
const variant = icon.name.replace("Variant=", "").replace("Stroke", "");
const actualName = icon.containing_frame?.containingComponentSet?.name;
const name = `${actualName}${variant}`;
return `${startCase(camelCase(name)).replace(/ /g, "")}.svg`;
}
return `${startCase(camelCase(icon.name)).replace(/ /g, "")}.svg`;
};
@@ -1,64 +0,0 @@
import { config } from "dotenv";
import { fetchIcons, fetchDownloadUrls, fetchIcon } from "./fetch-icons.mjs";
import { makeConfig } from "./make-configs.mjs";
import { existsSync, writeFileSync, mkdirSync, rmSync, readdirSync } from "fs";
import { resolve } from "path";
import { resolveName } from "./icon-name.mjs";
import { paginate } from "./paginate.mjs";
config();
/* https://www.figma.com/file/wEdyFjCQSBR3U7FvrMbPXa/Core-Icons-Next?node-id=277%3A1221&t=mUJzFvnsceYYXNL5-0 */
const iconFolder = "./icons";
if (!process.env.FIGMA_TOKEN) {
throw new Error("FIGMA_TOKEN not set in .env");
}
async function main() {
let icons = await fetchIcons();
const totalIcons = icons.length;
const { images } = await fetchDownloadUrls(
paginate(
icons.map((x) => x.node_id),
400
).map((x) => x.join(","))
);
if (existsSync(iconFolder)) {
rmSync(iconFolder, { recursive: true, force: true });
}
mkdirSync(iconFolder);
console.log(`Laster ned ${Object.keys(images).length} ikoner`);
for (const [key, value] of Object.entries(images)) {
const icon = await fetchIcon(value).catch((e) => {
throw e;
});
await new Promise((r) => setTimeout(r, 20));
icon &&
writeFileSync(
resolve(iconFolder, resolveName(icons.find((x) => x.node_id === key))),
icon,
{
encoding: "utf8",
}
);
}
makeConfig(icons, iconFolder);
readdirSync(iconFolder, (_, files) => {
if (files.length * 2 !== totalIcons) {
throw new Error(`Ikoner mangler!`);
}
});
console.log(`Success! ${Object.keys(images).length} ikoner lastet ned`);
}
main();
+112
View File
@@ -0,0 +1,112 @@
import {
existsSync,
mkdirSync,
readdirSync,
rmSync,
writeFileSync,
} from "node:fs";
import { resolve } from "node:path";
import { fetchDownloadUrls, fetchIcons } from "./fetch-icons";
import { resolveName } from "./icon-name";
import { makeConfig } from "./make-configs";
/**
* https://www.figma.com/file/wEdyFjCQSBR3U7FvrMbPXa/Core-Icons-Next?node-id=277%3A1221&t=mUJzFvnsceYYXNL5-0
* This is the current source for all icons we are working with.
*/
const iconFolder = "./icons";
if (!process.env.FIGMA_TOKEN) {
throw new Error("FIGMA_TOKEN not set in .env");
}
main();
async function main() {
console.info("Started icon-update from Figma");
/* Icons are published as 'components' in Figma */
const publishedIconComponents = await fetchIcons();
/* When we have all the published icons, we can ask figma for URL's for downloading them as assets */
const imagesUrls = await fetchDownloadUrls(
publishedIconComponents.map((x) => x.node_id),
);
/* Lets do a clean install */
if (existsSync(iconFolder)) {
rmSync(iconFolder, { recursive: true, force: true });
}
mkdirSync(iconFolder);
console.group(`Processing ${Object.keys(imagesUrls).length} icons...`);
const fileNames = new Set<string>();
await Promise.all(
Object.entries(imagesUrls).map(async ([nodeId, iconUrl]) => {
/* Each icon is now a raw string for a complete SVG */
const iconSvg = await fetch(iconUrl)
.then((x) => x.text())
.catch((e) => {
throw e.message;
});
const matchingIcon = publishedIconComponents.find(
(x) => x.node_id === nodeId,
);
if (!matchingIcon) {
throw new Error(
`No matching icon found for ${nodeId}. It should not be possible to dowload icon without a matching icon in the list of icons fetched from Figma.`,
);
}
const fileName = resolveName(matchingIcon);
/*
* In some cases if multiple icons are published in Figma with the same name,
* we will end up overwriting the icon with the same name.
*/
if (fileNames.has(fileName)) {
console.warn(`Duplicate name detected: ${fileName}.`);
}
fileNames.add(fileName);
writeFileSync(resolve(iconFolder, resolveName(matchingIcon)), iconSvg, {
encoding: "utf8",
});
}),
);
if (fileNames.size !== publishedIconComponents.length) {
console.warn(
`Duplicate icon names from Figma leads to them being overwritten. This will cause the icon-library to be out of sync with Figma.`,
);
}
console.info(`Completed processing 🎉`);
console.groupEnd();
makeConfig(publishedIconComponents, iconFolder);
const filesInDir = readdirSync(iconFolder);
const svgFiles = filesInDir.filter((x) => x.endsWith(".svg"));
const ymlFiles = filesInDir.filter((x) => x.endsWith(".yml"));
if (
svgFiles.length !== publishedIconComponents.length ||
ymlFiles.length !== publishedIconComponents.length
) {
throw new Error(
`Icons (${svgFiles.length}) and configs (${ymlFiles.length}) written to directory does not match the expected amount of icons located in Figma (${publishedIconComponents.length}).\nThis is most likely caused by duplicate icon names from figma.`,
);
}
console.info(
`Success! A total of ${
Object.keys(imagesUrls).length
} were fetched and downloaded from Figma 🎉`,
);
}
@@ -1,36 +0,0 @@
import { writeFileSync } from "fs";
import jsYaml from "js-yaml";
import { resolve } from "path";
import { resolveName } from "./icon-name.mjs";
export const makeConfig = (icons, folder) => {
icons.forEach((icon) => {
const config = {
name: resolveName(icon).replace(".svg", ""),
category: icon.containing_frame.pageName,
sub_category: icon.containing_frame.name,
keywords: [...icon.description.split(",").map((x) => x.trim())],
variant: icon.name.includes("Variant=")
? icon.name.replace("Variant=", "")
: "Stroke",
updated_at: new Date(icon.updated_at)
.toISOString()
.split("T")[0]
.split("-")
.reverse()
.join("."),
created_at: new Date(icon.created_at)
.toISOString()
.split("T")[0]
.split("-")
.reverse()
.join("."),
};
const yml = jsYaml.dump(config, { noRefs: true, skipInvalid: false });
writeFileSync(resolve(folder, `${config.name}.yml`), yml, {
encoding: "utf8",
});
});
};
@@ -0,0 +1,66 @@
import { PublishedComponent } from "@figma/rest-api-spec";
import { dump } from "js-yaml";
import { writeFileSync } from "node:fs";
import { resolve } from "node:path";
import { resolveName } from "./icon-name";
export type IconYml = {
name: string;
category: string;
sub_category: string;
keywords: string[];
variant: string;
created_at: string;
};
export const makeConfig = (
icons: PublishedComponent[],
dirLocation: string,
) => {
console.group("Creating icon yml...");
let counter = 0;
for (const icon of icons) {
const name = resolveName(icon).replace(".svg", "");
const keywords = icon.description
.split(",")
.map((x) => x.trim())
.filter(Boolean);
if (!icon.containing_frame?.pageName || !icon.containing_frame?.name) {
throw new Error(
`Missing containing_frame.pageName or containing_frame.name for icon ${name}`,
);
}
const config: IconYml = {
name,
category: icon.containing_frame.pageName,
sub_category: icon.containing_frame.name,
keywords: keywords.length > 0 ? keywords : [name],
variant: icon.name.includes("Variant=")
? icon.name.replace("Variant=", "")
: "Stroke",
created_at: new Date(icon.created_at)
.toISOString()
.split("T")[0]
.split("-")
.reverse()
.join("."),
};
const yml = dump(config, {
noRefs: true,
skipInvalid: false,
quotingType: '"',
});
writeFileSync(resolve(dirLocation, `${config.name}.yml`), yml, {
encoding: "utf8",
});
counter++;
}
console.info(`Created ${counter} icon yml files`);
console.groupEnd();
};
@@ -1,9 +0,0 @@
export function paginate(arr, size) {
return arr.reduce((acc, val, i) => {
let idx = Math.floor(i / size);
let page = acc[idx] || (acc[idx] = []);
page.push(val);
return acc;
}, []);
}
+4 -1
View File
@@ -2,7 +2,10 @@ const path = require("path");
const defaultIndexTemplate = (paths) => {
const exportEntries = paths.map((filePath) => {
const basename = path.basename(filePath, path.extname(filePath));
const basename = path.basename(
filePath.originalPath,
path.extname(filePath.originalPath),
);
return `export { default as ${basename}Icon } from './${basename}'`;
});
+15 -5
View File
@@ -15,18 +15,25 @@ ymlList.forEach((file) => {
const ymlData = jsYaml.load(fs.readFileSync(`${basePath}/${file}`), {
schema: jsYaml.JSON_SCHEMA,
});
// biome-ignore lint/complexity/useOptionalChain: optional chain not supported in enviroment. Consider revriting to Typescript
if (ymlData.keywords && ymlData.keywords.includes("[ignore-docs]")) {
return;
}
const iconName = file.replace(".yml", "");
metadata[iconName] = { id: iconName, ...ymlData };
});
fs.writeFileSync(
path.resolve(__dirname, "../dist/metadata.js"),
`const metadata = ${JSON.stringify(metadata)};\n\n module.exports = metadata;`
`const metadata = ${JSON.stringify(
metadata,
)};\n\n module.exports = metadata;`,
);
fs.writeFileSync(
path.resolve(__dirname, "../dist/metadata.mjs"),
`const metadata = ${JSON.stringify(metadata)};\n\n export default metadata;`
`const metadata = ${JSON.stringify(metadata)};\n\n export default metadata;`,
);
fs.writeFileSync(
@@ -38,13 +45,16 @@ fs.writeFileSync(
sub_category: "Time",
keywords: string[];
variant: "stroke" | "fill";
updated_at: Date;
created_at: Date;
}
type AkselIconName = ${Object.keys(metadata)
.map((icon) => `"${icon}"`)
.join(" | ")};
declare const metadata: {
[iconId: string]: AkselIcon;
[key in AkselIconName]: AkselIcon;
};
export default metadata;`
export default metadata;`,
);
+1 -1
View File
@@ -34,7 +34,7 @@ function parseIcon(svgString) {
let icon = svgString;
icon = icon.replace(`width="24"`, `width="1em"`);
icon = icon.replace(`height="24"`, `height="1em"`);
icon = icon.replaceAll(`#23262A`, `currentColor`);
icon = icon.replaceAll(`#202733`, `currentColor`);
return icon;
}
+12 -2
View File
@@ -1,5 +1,13 @@
const template = (variables, { tpl }) => {
const imports = variables.imports;
/*
* Remove any react imports SVGR added
* This allows us to de-duplicate the react import.
*/
const imports = variables.imports.filter(
(imp) =>
!(imp.type === "ImportDeclaration" && imp.source.value === "react"),
);
imports.push({
type: "ImportDeclaration",
specifiers: [
@@ -18,13 +26,15 @@ const template = (variables, { tpl }) => {
});
variables.props[0].properties.find(
(prop) => prop.key.name === "titleId"
(prop) => prop.key.name === "titleId",
).value = {
type: "Identifier",
name: "_titleId",
};
return tpl`
"use client";
import React, { forwardRef, type Ref, type SVGProps } from "react";
${imports};
${variables.interfaces};
+6 -6
View File
@@ -33,18 +33,18 @@ async function generateFile() {
ymlData.category,
categories.get(ymlData.category)
? [...categories.get(ymlData.category), ymlData.name]
: [ymlData.name]
: [ymlData.name],
);
});
categories.forEach((value, key) => {
mkdirSync(`${iconFolder}/${key}`);
value.forEach((icon) =>
value.forEach((icon) => {
copyFileSync(
`${basePath}/${icon}.svg`,
`${iconFolder}/${key}/${icon}.svg`
)
);
`${iconFolder}/${key}/${icon}.svg`,
);
});
});
}
@@ -56,7 +56,7 @@ async function createZipArchive() {
zip.addLocalFolder("./core-icons");
zip.writeZip(outputFile);
console.log(`Created ${outputFile} successfully`);
console.info(`Created ${outputFile} successfully`);
}
createZipArchive();
+2 -2
View File
@@ -2,9 +2,9 @@
# Aksel Icons plugin
Pluginen gir deg mulighet til å se gjennom og hente ut alle ikonene i fra ikonpakken `@navikt/aksel-icons`. Du slipper da å hente nye oppdateringer fra Figma Community.
Pluginen gir deg mulighet til å se gjennom og hente ut alle ikonene fra ikonpakken `@navikt/aksel-icons`. Du slipper da å hente nye oppdateringer fra Figma Community.
Referer til [ikon-dokumentasjonen](https://aksel.nav.no/ikoner) for å se alle ikonene.
Gå til [ikon-dokumentasjonen](https://aksel.nav.no/ikoner) for å se alle ikonene.
Har du ønsker om nye ikoner, eller ønsker å bidra med å lage nye, lag et issue på [GitHub-repoet for designsystemet](https://github.com/navikt/aksel).
## Quickstart
@@ -6,5 +6,8 @@
"ui": "dist/index.html",
"capabilities": [],
"enableProposedApi": false,
"editorType": ["figma", "figjam"]
"editorType": ["figma", "figjam"],
"networkAccess": {
"allowedDomains": ["none"]
}
}
+13 -16
View File
@@ -13,23 +13,20 @@
"dependencies": {
"@navikt/ds-css": "*",
"@navikt/ds-react": "*",
"fuse.js": "^6.6.2",
"react": "^18.0.0",
"react-dom": "^18.0.0"
"fuse.js": "^7.0.0",
"react": "19.2.5",
"react-dom": "19.2.5"
},
"devDependencies": {
"@figma/plugin-typings": "^1.62.0",
"@svgr/core": "^6.5.1",
"@types/node": "^18.15.11",
"@types/postcss-url": "^10.0.0",
"@types/react": "^18.0.0",
"@types/react-dom": "^18.0.0",
"@vitejs/plugin-react": "^3.1.0",
"postcss": "^8.4.31",
"postcss-url": "^10.1.3",
"typescript": "^5.1.6",
"vite": "^4.2.0",
"vite-plugin-singlefile": "^0.13.3",
"vite-plugin-svgr": "^2.4.0"
"@figma/plugin-typings": "^1.100.2",
"@svgr/core": "^8.1.0",
"@types/node": "^24.10.9",
"@types/react": "19.2.14",
"@types/react-dom": "19.2.3",
"@vitejs/plugin-react": "^5.1.0",
"typescript": "6.0.2",
"vite": "^7.3.2",
"vite-plugin-singlefile": "^2.3.0",
"vite-plugin-svgr": "^4.2.0"
}
}
@@ -1,4 +1,4 @@
import fs from "fs";
import fs from "node:fs";
import { Plugin } from "vite";
function svgToDataURL(svgStr: string) {
@@ -1,6 +1,6 @@
import { createFilter, FilterPattern } from "@rollup/pluginutils";
import { FilterPattern, createFilter } from "@rollup/pluginutils";
import type { Config } from "@svgr/core";
import fs from "fs";
import fs from "node:fs";
import type { Plugin } from "vite";
import { transformWithEsbuild } from "vite";
@@ -22,12 +22,12 @@ export default function viteSvgr({
return {
name: "vite-svgr-component",
async transform(code, id) {
async transform(_, id) {
if (filter(id)) {
const { transform } = await import("@svgr/core");
const svgCode = await fs.promises.readFile(
id.replace(/\?.*$/, ""),
"utf8"
"utf8",
);
const componentCode = await transform(svgCode, svgrOptions, {
+13 -13
View File
@@ -1,7 +1,7 @@
/* eslint-disable react/react-in-jsx-scope */
import { Heading, Search, ToggleGroup } from "@navikt/ds-react";
import Fuse from "fuse.js";
import { useEffect, useMemo, useState } from "react";
import { Heading, Search, ToggleGroup } from "@navikt/ds-react";
import * as Icons from "../../../";
import meta from "../../../dist/metadata";
import "./app.css";
@@ -19,7 +19,7 @@ const fuseStroke = new Fuse(
{ name: "variant", weight: 1 },
],
shouldSort: false,
}
},
);
const fuseFill = new Fuse(getFillIcon(Object.values(meta)), {
@@ -39,7 +39,7 @@ const App = () => {
const [toggle, setToggle] = useState<"stroke" | "fill">("stroke");
const [strokeIcons] = useState(
Object.values(meta).filter((x) => x.variant.toLowerCase() === "stroke")
Object.values(meta).filter((x) => x.variant.toLowerCase() === "stroke"),
);
const [fillIcons] = useState(getFillIcon(Object.values(meta)));
@@ -49,13 +49,13 @@ const App = () => {
return categorizeIcons(
query
? fuseFill.search(query).map((result) => result.item as any)
: fillIcons
: fillIcons,
);
}
return categorizeIcons(
query
? fuseStroke.search(query).map((result) => result.item as any)
: strokeIcons
: strokeIcons,
);
}, [toggle, query, strokeIcons, fillIcons]);
@@ -71,7 +71,7 @@ const App = () => {
name,
},
},
"*"
"*",
);
};
@@ -95,7 +95,7 @@ const App = () => {
name: e.target.id,
},
},
"*"
"*",
);
};
@@ -109,7 +109,7 @@ const App = () => {
icon.removeEventListener("dragend", dragEvent);
}
};
}, [categories]);
}, []);
return (
<main tabIndex={-1} className="wrapper">
@@ -120,8 +120,8 @@ const App = () => {
onChange={(v) => setToggle(v as any)}
variant="neutral"
>
<ToggleGroup.Item value="stroke">Stroke</ToggleGroup.Item>
<ToggleGroup.Item value="fill">Fill</ToggleGroup.Item>
<ToggleGroup.Item value="stroke" label="Stroke" />
<ToggleGroup.Item value="fill" label="Fill" />
</ToggleGroup>
</div>
<div className="form-search">
@@ -154,9 +154,9 @@ const App = () => {
</Heading>
<div className="icons-wrapper">
{sub.icons.map((i) => {
const T = Icons[`${i.id}Icon`]; // eslint-disable-line import/namespace
// biome-ignore lint/performance/noDynamicNamespaceImportAccess: We do not know which icon will be rendered at build time
const T = Icons[`${i.id}Icon`];
if (T === undefined) {
console.log(i);
return null;
}
return (
@@ -170,7 +170,7 @@ const App = () => {
className="icon-classname icon-button"
>
<T
font-size="2rem"
fontSize="2rem"
title={i.id}
id={`icon-id-${i.id}`}
/>
@@ -1,11 +1,11 @@
@import "@navikt/ds-css";
.wrapper {
background-color: var(--a-bg-default);
background-color: var(--ax-bg-default);
}
.form {
border-bottom: 1px solid var(--a-border-subtle);
border-bottom: 1px solid var(--ax-border-neutral-subtle);
position: sticky;
top: 0;
z-index: 20;
@@ -16,7 +16,7 @@
gap: 1rem;
padding-block: 0.5rem;
padding-inline: 1rem;
background-color: var(--a-bg-default);
background-color: var(--ax-bg-default);
}
.form-togglegroup {
@@ -45,7 +45,7 @@
}
.sub-heading {
color: var(--a-text-subtle);
color: var(--ax-text-neutral-subtle);
margin-bottom: 0.25rem;
}
@@ -58,22 +58,23 @@
.icon-button {
min-height: 3rem;
min-width: 3rem;
border-radius: var(--a-border-radius-small);
border-radius: var(--ax-radius-2);
display: grid;
place-content: center;
background-color: var(--a-surface-default);
background-color: var(--ax-bg-neutral-softA);
cursor: pointer;
border: none;
}
.icon-button:hover {
background-color: var(--a-surface-hover);
background-color: var(--ax-bg-neutral-moderate-hoverA);
}
.icon-button:active {
background-color: var(--a-surface-neutral-subtle-hover);
background-color: var(--ax-bg-neutral-moderate-pressedA);
}
.icon-button:focus-visible {
outline: 2px solid var(--a-border-focus);
outline: 3px solid var(--ax-border-focus);
outline-offset: 2px;
}
Loaded 100 of 4707 files, more files were not shown because too many files have changed in this diff. Show more