Compare commits

...
Author SHA1 Message Date
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
887 changed files with 56008 additions and 38506 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",
+39 -13
View File
@@ -1,4 +1,19 @@
// TODO: Convert to new format: https://eslint.org/docs/latest/use/configure/migration-guide
/**
* TODO:
* - Convert to new format (v9): https://eslint.org/docs/latest/use/configure/migration-guide
* - Look into opinionated stylistic plugin
* - Replace @typescript-eslint/recommended with @typescript-eslint/recommended-type-checked
* - We should add "plugin:react/jsx-runtime", but not sure if this will cause problems for projects not using the new JSX transform
* - Consider adding the rule "id-length"
*/
/**
* V9 migration WIP
* - eslint-plugin-storybook does not support v9 yet: https://github.com/storybookjs/eslint-plugin-storybook/issues/157
* - eslint-plugin-testing-library does not support v9 yet: https://github.com/testing-library/eslint-plugin-testing-library/issues?q=is%3Aissue+is%3Aopen+v9
* - @vitest/eslint-plugin supports v9, just need to replace @vitest/legacy-recommended: https://github.com/vitest-dev/eslint-plugin-vitest?tab=readme-ov-file#usage
* - Looks like @typescript-eslint/eslint-plugin and @typescript-eslint/parser can both be replaced by just typescript-eslint in v9: https://typescript-eslint.io/getting-started#step-2-configuration
*/
module.exports = {
env: {
browser: true,
@@ -8,15 +23,13 @@ module.exports = {
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
],
/* Allows eslint-plugin-react to detect installed react-version */
settings: { react: { version: "detect" } },
rules: {
"import/no-unresolved": "off",
@@ -26,12 +39,6 @@ module.exports = {
],
"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],
"no-else-return": "error",
"no-console": [
"warn",
@@ -53,7 +60,12 @@ module.exports = {
],
},
],
/* Temporarily turned off until code is updated */
"react/prop-types": "off",
"react/display-name": "off",
"import/no-named-as-default": "off",
},
/* https://eslint.org/docs/latest/use/configure/rules#report-unused-eslint-disable-comments */
reportUnusedDisableDirectives: true,
overrides: [
{
@@ -66,17 +78,27 @@ module.exports = {
files: ["**/*.ts?(x)"],
extends: ["plugin:@typescript-eslint/recommended"],
rules: {
"@typescript-eslint/no-shadow": ["error", { hoist: "all" }], // TODO: Consider { builtinGlobals: true }
/*
* TODO:
* - Consider { builtinGlobals: true }
*/
"@typescript-eslint/no-shadow": ["error", { hoist: "all" }],
"@typescript-eslint/no-explicit-any": "off", // Temporary
"@typescript-eslint/array-type": "error",
"@typescript-eslint/no-unused-expressions": [
"error",
/* https://eslint.org/docs/latest/rules/no-unused-expressions#allowshortcircuit-and-allowternary */
{ allowShortCircuit: true, allowTernary: true },
],
},
},
{
files: ["**/*.test.*", "**/__tests__/*"],
plugins: ["@vitest"],
extends: [
"plugin:@vitest/legacy-recommended",
"plugin:testing-library/react",
/* Needed to support v8 eslint config-syntax */
"plugin:@vitest/legacy-recommended",
],
},
@@ -121,7 +143,11 @@ module.exports = {
},
},
{
files: ["**/examples/__parts*/*.tsx"],
files: [
"**/examples/__parts*/*.tsx",
"**/pages/templates/**/*.tsx",
"**/pages/eksempler/**/*.tsx",
],
plugins: ["aksel-local"],
rules: {
"aksel-local/import-check": ["error"], // Only allow imports from @navikt and react
+1 -1
View File
@@ -6,7 +6,7 @@
- [ ] JSDoc
- [ ] Examples
- [ ] Documentation
- [ ] Documentation / Decision Records
- [ ] Storybook
- [ ] Style mappings (`@navikt/core/css/config/_mappings.js`)
- [ ] Component tokens (`@navikt/core/css/tokens.json`)
+56
View File
@@ -0,0 +1,56 @@
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
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: 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 }}
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@v4
with:
node-version: lts/*
cache: yarn
cache-dependency-path: "**/yarn.lock"
- name: Install dependencies
run: yarn
shell: bash
env:
NPM_AUTH_TOKEN: ${{ inputs.npm_auth_token }}
- name: Boot (build packages)
run: yarn boot
shell: bash
+20
View File
@@ -0,0 +1,20 @@
version: 2
registries:
npm-github:
type: npm-registry
url: https://npm.pkg.github.com
token: ${{ secrets.READER_TOKEN }}
updates:
- package-ecosystem: npm
directory: /
schedule:
interval: weekly
registries:
- npm-github
- package-ecosystem: github-actions
directory: "/"
schedule:
interval: weekly
registries:
- npm-github
+11 -33
View File
@@ -14,42 +14,20 @@ jobs:
contents: "read"
id-token: "write"
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
- name: Checkout code
uses: actions/checkout@v4
with:
node-version: lts/*
cache: yarn
- name: set-env for yarn install to @navikt scope
shell: bash
run: echo "NPM_AUTH_TOKEN=${{ secrets.READER_TOKEN }}" >> $GITHUB_ENV
fetch-depth: 1
- name: add tokens to .env
run: |
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: Install dependencies
run: yarn
- name: Build application
env:
SANITY_READ: ${{ secrets.SANITY_READ }}
SANITY_READ_NO_DRAFTS: ${{ secrets.SANITY_READ_NO_DRAFTS }}
run: |
yarn boot
yarn workspace aksel.nav.no build:next
- name: Upload static files to NAV CDN
uses: nais/deploy/actions/cdn-upload/v2@master
- name: Setup and build Next.js application
uses: ./.github/actions/build-website
with:
team: designsystem
source: ./aksel.nav.no/website/.next/static
destination: "/website/_next"
project_id: ${{ vars.NAIS_MANAGEMENT_PROJECT_ID }}
identity_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
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: Get complete tag
run: echo "TAG=DEV-$( date +%s )" >> $GITHUB_ENV
+16 -47
View File
@@ -16,21 +16,13 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
- name: Setup project
uses: ./.github/actions/setup
with:
node-version: lts/*
cache: yarn
- name: set-env for yarn install to @navikt scope
shell: bash
run: echo "NPM_AUTH_TOKEN=${{ secrets.READER_TOKEN }}" >> $GITHUB_ENV
npm_auth_token: ${{ secrets.READER_TOKEN }}
- name: Install dependencies
run: yarn
- name: Run docgen
run: |
yarn boot
yarn docgen
- name: Run ts-docgen
run: yarn docgen
- name: Update sanity sync
env:
@@ -45,43 +37,20 @@ jobs:
contents: "read"
id-token: "write"
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
- name: Checkout code
uses: actions/checkout@v4
with:
node-version: lts/*
cache: yarn
- name: set-env for yarn install to @navikt scope
shell: bash
run: echo "NPM_AUTH_TOKEN=${{ secrets.READER_TOKEN }}" >> $GITHUB_ENV
fetch-depth: 1
- name: add tokens to .env
run: |
echo "USE_CDN_ASSETS=true" >> aksel.nav.no/website/.env
- name: Install dependencies
run: yarn
- name: Build packages
run: yarn boot
- name: Tests
run: yarn workspace website test
- name: Build application
env:
SANITY_READ: ${{ secrets.SANITY_READ }}
SANITY_READ_NO_DRAFTS: ${{ secrets.SANITY_READ_NO_DRAFTS }}
run: yarn workspace aksel.nav.no build:next
- name: Upload static files to NAV CDN
uses: nais/deploy/actions/cdn-upload/v2@master
- name: Setup and build Next.js application
uses: ./.github/actions/build-website
with:
team: designsystem
source: ./aksel.nav.no/website/.next/static
destination: "/website/_next"
project_id: ${{ vars.NAIS_MANAGEMENT_PROJECT_ID }}
identity_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
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: Get complete tag
run: echo "TAG=PROD-$( date +%s )" >> $GITHUB_ENV
-42
View File
@@ -1,42 +0,0 @@
name: Redeploy image 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@v4
with:
node-version: lts/*
cache: yarn
- uses: actions/checkout@v4
- 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 }}
+5 -4
View File
@@ -16,17 +16,18 @@ jobs:
with:
node-version: lts/*
cache: yarn
- name: set-env for yarn install to @navikt scope
shell: bash
run: echo "NPM_AUTH_TOKEN=${{ secrets.READER_TOKEN }}" >> $GITHUB_ENV
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 }}
run: cd aksel.nav.no/website && yarn backup
- name: Upload GCP bucket
uses: "google-github-actions/auth@v2"
with:
+18 -47
View File
@@ -18,68 +18,49 @@ concurrency:
jobs:
chromatic:
if: ${{ !contains(github.event.pull_request.labels.*.name, 'ignore-chromatic') }}
runs-on: ubuntu-latest
permissions:
issues: write
pull-requests: write
contents: write
steps:
- uses: actions/checkout@v4
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-node@v4
- name: Setup project
uses: ./.github/actions/setup
with:
node-version: lts/*
cache: yarn
- name: set-env for yarn install to @navikt scope
shell: bash
run: echo "NPM_AUTH_TOKEN=${{ secrets.READER_TOKEN }}" >> $GITHUB_ENV
- name: Install dependencies
run: yarn
- name: Build packages
run: yarn boot
npm_auth_token: ${{ secrets.READER_TOKEN }}
- name: Chromatic
uses: chromaui/action@latest
id: chromatic_tests
continue-on-error: true
continue-on-error: false
with:
autoAcceptChanges: "main"
token: ${{ secrets.GITHUB_TOKEN }}
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
exitZeroOnChanges: false
exitZeroOnChanges: true
buildScriptName: "build:storybook-chromatic"
onlyChanged: true
untraced: "**/package.json|yarn.lock|**/*.md"
externals: \@navikt/core/css/**/*.css
externals: "**/core/css/*.css|**/core/css/baseline/*.css|**/core/css/form/*.css|**/core/css/primitives/*.css"
traceChanged: true
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'"
if: github.event_name != 'push' && !contains(github.event.head_commit.message, '[ci skip]')
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
if: github.event_name != 'push' && !contains(github.event.head_commit.message, '[ci skip]')
uses: peter-evans/find-comment@v3
id: fc
with:
issue-number: ${{ github.event.pull_request.number }}
@@ -87,27 +68,17 @@ jobs:
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
if: github.event_name != 'push' && !contains(github.event.head_commit.message, '[ci skip]')
uses: peter-evans/create-or-update-comment@v4
with:
comment-id: ${{ steps.fc.outputs.comment-id }}
issue-number: ${{ github.event.pull_request.number }}
body: |
## [Storybook demo](${{steps.storybook_url.outputs.replaced}})
## [Storybook demo](${{steps.chromatic_tests.outputs.storybookUrl}}) / [Chromatic](${{steps.chromatic_tests.outputs.url}})
[${{ 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
${{ 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) || '' }}
- 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
[${{ 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
+36 -19
View File
@@ -9,36 +9,53 @@ on:
workflow_dispatch:
jobs:
build:
name: "Validate build"
if: "!contains(github.event.head_commit.message, '[ci skip]')"
lint:
name: "Linter: eslint, stylelint"
runs-on: ubuntu-latest
permissions:
pull-requests: "write"
steps:
- uses: actions/checkout@v4
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
fetch-depth: 1
- uses: actions/setup-node@v4
- name: Setup project
uses: ./.github/actions/setup
with:
node-version: lts/*
cache: yarn
- name: set-env for yarn install to @navikt scope
shell: bash
run: echo "NPM_AUTH_TOKEN=${{ secrets.READER_TOKEN }}" >> $GITHUB_ENV
- name: Install dependencies
run: yarn
- name: Boot (build packages)
run: yarn boot
npm_auth_token: ${{ secrets.READER_TOKEN }}
- name: Lint
run: yarn lint
validate-examples:
name: "Validate Aksel.nav.no component examples"
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
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 tests"
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 1
- name: Setup project
uses: ./.github/actions/setup
with:
npm_auth_token: ${{ secrets.READER_TOKEN }}
- name: Test
run: yarn test
+39
View File
@@ -0,0 +1,39 @@
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.48.1-jammy
steps:
- name: Checkout code
uses: actions/checkout@v4
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: Run Playwright tests
env:
SANITY_READ: ${{ secrets.SANITY_READ }}
SANITY_READ_NO_DRAFTS: ${{ secrets.SANITY_READ_NO_DRAFTS }}
run: yarn workspace website e2e:ci-full
-50
View File
@@ -1,50 +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@v4
- uses: actions/setup-node@v4
with:
node-version: lts/*
cache: yarn
- name: set-env for yarn install to @navikt scope
shell: bash
run: echo "NPM_AUTH_TOKEN=${{ secrets.READER_TOKEN }}" >> $GITHUB_ENV
- name: Install dependencies
run: yarn
- name: Build packages
run: |
yarn boot
- name: Build application
env:
SANITY_READ: ${{ secrets.SANITY_READ }}
SANITY_READ_NO_DRAFTS: ${{ secrets.SANITY_READ_NO_DRAFTS }}
run: yarn workspace aksel.nav.no build:next
- name: Run Playwright tests
env:
SANITY_READ: ${{ secrets.SANITY_READ }}
SANITY_READ_NO_DRAFTS: ${{ secrets.SANITY_READ_NO_DRAFTS }}
run: yarn workspace website e2e:ci-full
- uses: actions/upload-artifact@v4
if: always()
with:
name: playwright-report
path: aksel.nav.no/website/playwright-report/
retention-days: 10
+3 -3
View File
@@ -25,12 +25,12 @@ jobs:
with:
node-version: lts/*
cache: yarn
- name: set-env for yarn install to @navikt scope
shell: bash
run: echo "NPM_AUTH_TOKEN=${{ secrets.READER_TOKEN }}" >> $GITHUB_ENV
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
@@ -15,16 +15,16 @@ jobs:
id-token: "write"
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
- name: Checkout code
uses: actions/checkout@v4
with:
node-version: lts/*
cache: yarn
fetch-depth: 1
- name: Setup project
uses: ./.github/actions/setup
with:
npm_auth_token: ${{ secrets.READER_TOKEN }}
- run: yarn install
env:
NPM_AUTH_TOKEN: ${{ secrets.READER_TOKEN }}
- run: yarn boot
- run: cd ./examples/referansesider && yarn && yarn build
- uses: nais/deploy/actions/spa-deploy/v2@master
with:
@@ -35,3 +35,4 @@ jobs:
environment: dev
project_id: ${{ vars.NAIS_MANAGEMENT_PROJECT_ID }}
identity_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
cache_invalidation: true
+5 -5
View File
@@ -30,9 +30,7 @@ jobs:
with:
node-version: lts/*
cache: yarn
- name: set-env for yarn install to @navikt scope
shell: bash
run: echo "NPM_AUTH_TOKEN=${{ secrets.READER_TOKEN }}" >> $GITHUB_ENV
cache-dependency-path: "**/yarn.lock"
- uses: denoland/setup-deno@v1
with:
@@ -40,6 +38,8 @@ jobs:
- name: Install dependencies
run: yarn
env:
NPM_AUTH_TOKEN: ${{ secrets.READER_TOKEN }}
- name: Create release Pull Request or publish to NPM
id: changesets
@@ -78,7 +78,7 @@ jobs:
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: nais/deploy/actions/cdn-upload/v2@master
with:
@@ -94,7 +94,7 @@ 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: nais/deploy/actions/cdn-upload/v2@master
with:
@@ -18,6 +18,7 @@ jobs:
dockerfile: scripts/article-views/Dockerfile.update-article-views
project_id: ${{ vars.NAIS_MANAGEMENT_PROJECT_ID }}
identity_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
- name: start naisjob prod-gcp
uses: nais/deploy/actions/deploy@master
env:
+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 lint-staged
yarn lint-staged && yarn tsx ./scripts/in-sync-versions.ts
+112
View File
@@ -0,0 +1,112 @@
import { Markdown, Meta } from "@storybook/blocks";
<Meta title="Docs/Become a Pilot team/3.Migration" />
# Migration
## Tokens
[See tokens docs here](https://main--66b4b3beb91603ed0ab5c45e.chromatic.com/?path=/docs/docs-become-a-pilot-team-4-tokens--docs).
## CSS
- Most of our CSS is re-written. This could potentially affect most custom overrides targeting `.navds`-classes.
- You will not be able to use the old CSS and the new CSS at the same time.
As we strongly recommend avoiding custom
overrides where possible, we would like to encourage opening an
issue if you find that you have to override our CSS to achieve
something! It's these cases we want to know about so that we can fix
them for everyone.
### Removed component-tokens
All component-spesific tokens are no longer supported. That means all tokens like these from `Button` are removed:
```css
--ac-button-primary-bg
--ac-button-primary-text
--ac-button-primary-hover-bg
--ac-button-primary-active-bg
```
All component-based tokens are prefixed with `--ac`, so a global search in your codebase should find all of them.
## Tailwind CSS
Since our Tailwind CSS config is tied to our tokens, most changes made to the tokens will affect the Tailwind CSS config.
We have decided to prefix all our classes with `ax-` in the new config, so it should be possible to use both packages at the same time. We will develop tooling to hopefuly make the migrations easier in the future.
### Removed classes
z-index, maxWidth and spacing classes are removed from the new config.
## React
We have made some updates to `@navikt/ds-react` that you should be aware of before testing.
### Accordion
#### Props
- `variant` is deprecated and will be removed in the future. We have not implemented it in the new system.
- `headingSize` is deprecated and will be removed in the future. Accordion-size medium now equals `small` heading, and size small equals `xsmall` heading.
#### Structural changes
`<Accordion.Content/>` now has an extra nested `div` to allow for better animations. Custom CSS might break.
### Datepicker
Weeknumber-button uses our own button-component, and no longer a
custom button.
### GuidePanel
Component got a complete overhaul. Custom overrides might break.
### Popover, HelpText
`arrow`-prop is removed. All of our floating dialog-elements except for `Tooltip` now comes without arrow.
If you have custom `offset`-values, you might have to update them to accommodate this.
### Pagination
Button now uses our own button-component and `variant="tertiary-neutral".
### Primitives
Given that these are closely tied to our tokens, you will most
likely have to update parts of them to test the new system.
All primitives using our current `spacing`-tokens now has
the new <code>space</code>-tokens. You can use the old tokens while
testing, but the full release will remove them from the prop-list
<Markdown>
{`
\`\`\`diff
- <HStack gap="4">
+ <HStack gap="space-16">
\`\`\`
`}
</Markdown>
#### Page
`background`-prop is removed. Now just uses `bg-default`-token.
#### Box
Since `<Box />` is directly tied to our tokens, we
now offer `<Box.New />` as a temporary altenative. This
component is based on our new tokens and can use the backgrounds,
borders, border-radius and shadows from the new system. When the full release comes, we will update `<Box />` to use the new system, and provide tooling to handle this migration.
**All instances of `<Box />` will break when using the new system if:**
- `background`-prop is used
- `shadow`-prop is used
- `borderColor`-prop is used
+128
View File
@@ -0,0 +1,128 @@
import { Markdown, Meta } from "@storybook/blocks";
<Meta title="Docs/Become a Pilot team/2.Setup" />
# Setup
## Clean project
For new projects, setup is just as easy as before, but now requires a `Theme`-component to be wrapped around your app.
The component acts as a local feature-flag for the new implementation, with the added benefit of being able to switch between light and dark mode for you.
Steps:
- 1. Import new CSS `@navikt/ds-css/darkside`
- 2. Import `Theme`-component from `@navikt/ds-react/Theme`
- 3. Wrap your app in the `Theme`-component. You do not have to set the theme, but it defaults to `light`.
```tsx
import "@navikt/ds-css/darkside";
import { Theme } from "@navikt/ds-react/Theme";
export const App = () => (
<Theme theme="light">
<YourApp />
</Theme>
);
```
### Only Tokens/CSS
If you are not using any of our React-components, you can still switch between themes by setting `class="light"` or `class="dark"` on your root-element.
## Theme switching
The `Theme`-component has a `theme`-prop that can be set to either `light` or `dark`. This only sets a `class` on the element of `light` or `dark` (in addition to a `navds-theme` class), and the rest is handled by the CSS.
You have the option of using `hasBackground` (defaults to true) to make `Theme` include a built on default background.
Since theme-switching often is framework-spesific, we have not included a theme-toggle component or advanced logic for cookies/localstorage.
You will have to implement this yourself using a custom setup, or use a library like [next-themes](https://github.com/pacocoursey/next-themes).
We will continue to work on the whole `Theme` ecosystem, and might include more features in the future to handle this built in.
### Theme-switch component
This is context-based for what fits your application, but there are some general patterns you can follow.
- **Light or Dark-mode**: Here you can use a simple Switch-component, or a Tertiary-button to toggle between them.
- **Light, Dark or System-mode**: Here you can use a ToggleGroup or Select-component.
```tsx
isLightMode ? (
<Button
variant="tertiary-neutral"
icon={<SunIcon title="Switch to dark theme" />}
/>
) : (
<Button
variant="tertiary-neutral"
icon={<MoonIcon title="Switch to light theme" />}
/>
);
```
## I just want to test the new tokens
Since you can use the new tokens alongside the old tokens, you can start by importing the new tokens as you would the old system.
```css
@import "@navikt/ds-tokens/darkside-css";
```
For SCSS, Less and JS they are also available under the paths
```
@navikt/ds-tokens/darkside-scss
@navikt/ds-tokens/darkside-less
@navikt/ds-tokens/darkside-js
```
**Note: To support theming, scss, less and js tokens are all now based on `css-variables`. This means you will have to import the css-version from `darkside-css` alongside them for everything to work.**
## I want to test the new React-changes
For the new system to work with our components, you will have to use the new `Theme`-component, and import the new CSS from `ds-css/darkside`
```tsx
import "@navikt/ds-css/darkside;";
import { Theme } from "@navikt/ds-react/Theme";
export const App = () => (
<Theme theme="light">
<YourApp />
</Theme>
);
```
You will not be able to use the old CSS and the new CSS at the same time.
You will have to check on all your custom overrides when making this switch.
## I have to make some custom changes in darkmode
Since our implementation is based on CSS, you can easily make custom adjustments where necessary.
```css
.my-component {
background-color: var(--ax-bg-raised);
color: var(--ax-text-neutral);
border: 1px solid var(--ax-border-neutral-subtleA);
}
// Makes hover-state more visible only for darkmode
.dark .my-component {
&:hover {
border-color: var(--ax-border-accent-default);
}
}
```
## Tailwind CSS
```
// Tailwind v3
module.exports = {
presets: [require("@navikt/ds-tailwind/darkside-tw3")],
}
```
+7
View File
@@ -0,0 +1,7 @@
import { Meta, Title } from "@storybook/blocks";
<Meta title="Docs/Become a Pilot team/5.Changelog" />
# Darkside changelog
Nothing to see here yet.
+95
View File
@@ -0,0 +1,95 @@
import { Meta, Title } from "@storybook/blocks";
<Meta title="Docs/Become a Pilot team/1.Intro" />
# Becoming a pilot team
We are looking for teams wanting to test our new theming implementation and darkmode before we go live with them later in 2025.
## What is a pilot team?
- A pilot team is a team that tests new implementations before they are released.
- The team will test the new implementation in a real-world scenario and provide us with feedback.
- The feedback will be used to improve the implementation before it replaces the old system.
As a pilot team, we want close communication to get
feedback on the changes. We want to know all the unclear and bad parts
of our implementations, so that we can fix them all up before the big release.
## Who are we mainly looking for?
We are focusing on applications meant for our internal systems and services for now. This line is often a little blurry,
but in short, all the public facing applications including those using "Dekoratøren" will not be considered internal.
Support for "Dekoratøren" is quite far down the road at the moment.
For teams wanting to test the new implementation, there are some key points to consider:
- You _probably_ want to be in the earlier stages of developing a new product or service (to more easily test something in isolation).
- You can test _any_ smaller subset of the new system as it's not an "all or nothing" ordeal. This could be: design tokens, darkmode, updated CSS or a combination of these.
- You have the capacity to test and provide feedback on the new implementation (You'll be saving Nav countless hours for every hour spent!).
Everyone is welcome to test the new implementation, but for some larger applications, it might be a bit early to adopt the new system. Keep in mind that there might be breaking changes as we go,
and we won't have all tooling ready for adoption yet so you might have to do some manual work.
## How to give feedback
We welcome all forms of feedback:
- **Issues**: [Open an issue on Github](https://github.com/navikt/aksel/issues)
- **Disussions**: [Start a discussion](https://github.com/navikt/aksel/discussions/categories/darkside).
- **Slack**: [Reach out to us on Slack #Aksel-designsystemet](https://nav-it.slack.com/archives/C7NE7A8UF)
## What's new?
- **Design tokens**: A complete re-write of our design tokens to allow for dark mode.
- **Dark mode**: A new dark mode implementation.
- **Updated CSS**: Now uses new tokens, built-in CSS-layers support and most components are re-written.
- **Updated Tailwind CSS config**: Now uses new tokens, now comes with built-in `ax`-prefix for easier separation between Aksel and your own config.
- **Updated components**: Components use the new tokens and CSS.
- **New Theme-component**: A new `<Theme/>`-component to handle the theming-switch locally.
- **Updated documentation**: Updated documentation for the new implementation.
## Documentation
As we go, we will add more documentation to help you get started with the new implementation.
- [Design i light og dark-mode](https://aksel.nav.no/god-praksis/artikler/design-i-dark-mode-og-light-mode)
### Demo page
We have a demo page to show off some of the new features and tokens. [You can find it here](https://aksel-referansesider.ansatt.dev.nav.no/aktivitetsplan/).
We recommend using "inspect-tool" in browser to get a feel for the new tokens and CSS.
## How testing could affect your application
All the changes are **opt in**, meaning you can choose to use nothing, some parts of the new implementation, or go all-in.
You will still be able to recieve updates to the old implementation while we are in the testing phase.
### Tokens
We have made a complete re-write of our design tokens to allow for dark mode.
This includes new backgrounds, text-colors, border-colors and updated spacing-tokens.
- All tokens have a new prefix `--ax` to avoid conflicts with old tokens.
- You will be able to use the new tokens at the same time as the old tokens.
- All background, text-colors and border-colors have new names and "concepts" to learn. Migration will not be a quick one to one with old system.
- New spacing tokens are now named `space` and based on `px` values (most devs think and deal in `px` values first, no more on-the-fly mental arithmetic! WYSIWYG).
### CSS
We have updated our CSS to be based on the new tokens for theming.
- Most of our CSS is re-written.
- All custom overrides targeting `.navds`-classes might have to be updated locally.
- You will not be able to use the old CSS and the new CSS at the same time.
- Component-based tokens are no longer avaliable.
### Tailwind CSS
We have made a new Tailwind CSS config based on the new tokens. Based on previous iterations, we have decided to try prefixing all our classes with `ax-`.
While this will be a little more verbose, it makes it easier to separate your own config from ours, and hopefully makes it easier to maintain.
### React components
We have made some prop-changes to some components to facilitate the new theming and updated CSS. You can read more about them under `migration` in the sidebar.
We have hidden the changes behind a "feature-flag", so you will have to use the new `<Theme/>`-component when testing the new CSS.
+193
View File
@@ -0,0 +1,193 @@
import { Meta } from "@storybook/blocks";
<Meta title="Docs/Become a Pilot team/4.Tokens" />
# Tokens
## Spacing scale
We have updated our spacing-scale to now be named `space` and for the values to reflect 1-1 the px-value.
To migrate old `--a-spacing-X`-tokens, you can just take the value and 4x it to get the new `--ax-space-X`-token.
```diff
// Old
--a-spacing-4: 1rem;
// New
--ax-space-16: 1rem;
```
```css
--ax-space-0: 0rem;
--ax-space-1: 0.0625rem;
--ax-space-2: 0.125rem;
--ax-space-4: 0.25rem;
--ax-space-6: 0.375rem;
--ax-space-8: 0.5rem;
--ax-space-12: 0.75rem;
--ax-space-16: 1rem;
--ax-space-20: 1.25rem;
--ax-space-24: 1.5rem;
--ax-space-28: 1.75rem;
--ax-space-32: 2rem;
--ax-space-36: 2.25rem;
--ax-space-40: 2.5rem;
--ax-space-44: 2.75rem;
--ax-space-48: 3rem;
--ax-space-56: 3.5rem;
--ax-space-64: 4rem;
--ax-space-72: 4.5rem;
--ax-space-80: 5rem;
--ax-space-96: 6rem;
--ax-space-128: 8rem;
```
## Global tokens
Our global colors are Neutral, Accent, Success, Info, Warning, Danger, Brand-magenta, Brand-beige, Brand-blue, Meta-purple and Meta-lime.
Beside `neutral` that has a `000`-token,
all other color-tokens are named after the following pattern:
```css
--ax-[role]-000 // Neutral only
--ax-[role]-100
--ax-[role]-100A
--ax-[role]-200
--ax-[role]-200A
--ax-[role]-300
--ax-[role]-300A
--ax-[role]-400
--ax-[role]-400A
--ax-[role]-500
--ax-[role]-600
--ax-[role]-700
--ax-[role]-800
--ax-[role]-900
--ax-[role]-1000
```
## Semantic tokens
We have two sets of semantic tokens, one for unique cases and one for all the roles.
```css
// Unique tokens
--ax-bg-default // Main page background.
--ax-bg-input // Background for input-fields.
--ax-bg-overlay // Background for overlays like Modal.
--ax-bg-sunken // Background for sunken sections to highlight ex. Cards.
--ax-bg-raised // Background for raised elements, like cards or dialogs.
--ax-text-logo // Nav-logo color.
--ax-border-focus // Outline-color for focus-states.
```
For the remaning tokens, they are equal between all the global roles. This means that if you know the token for one role, you know it for all the roles.
```css
// Backgrounds
// Soft is used for subtle backgrounds without state.
--ax-bg-[role]-soft
--ax-bg-[role]-softA
// Moderate is used for subtle elements, with the option for states.
// Should be used with a border in most cases to separate from the background.
// Think Secondary-buttons, Alerts
--ax-bg-[role]-moderate
--ax-bg-[role]-moderateA
--ax-bg-[role]-moderate-hover
--ax-bg-[role]-moderate-hoverA
--ax-bg-[role]-moderate-pressed
--ax-bg-[role]-moderate-pressedA
// Strong is used for elements that should stand out, with the option for states.
// Think Primary-buttons, Checkbox, Chips
// Text on strong should use contrast version of the color.
--ax-bg-[role]-strong
--ax-bg-[role]-strong-hover
--ax-bg-[role]-strong-pressed
// Text
--ax-text-[role]
--ax-text-[role]-subtle
--ax-text-[role]-icon
--ax-text-[role]-contrast
// Borders
--ax-border-[role]
--ax-border-[role]-subtle
--ax-border-[role]-subtleA
--ax-border-[role]-strong
```
### Example use
```css
.alert--success {
background-color: var(--ax-bg-success-moderate);
border: var(--ax-border-success);
}
.alert--info {
background-color: var(--ax-bg-info-moderate);
border: var(--ax-border-info);
}
```
## Shadows
We now have only one shadow-token:
```css
--ax-shadow-dialog
```
## Z-index
We have removed the `--a-z-index`-tokens.
## Font-tokens, breakpoints etc
The remaining tokens are kept the same as the old system, but now with updated prefix.
```css
--ax-font-weight-regular
--ax-font-weight-bold
--ax-font-size-small
--ax-font-size-medium
--ax-font-size-large
--ax-font-size-xlarge
--ax-font-size-heading-xsmall
--ax-font-size-heading-small
--ax-font-size-heading-medium
--ax-font-size-heading-large
--ax-font-size-heading-xlarge
--ax-font-size-heading-2xlarge
--ax-font-line-height-medium
--ax-font-line-height-large
--ax-font-line-height-xlarge
--ax-font-line-height-heading-xsmall
--ax-font-line-height-heading-small
--ax-font-line-height-heading-medium
--ax-font-line-height-heading-large
--ax-font-line-height-heading-xlarge
--ax-font-line-height-heading-2xlarge
--ax-font-family
--ax-breakpoint-2xl-down
--ax-breakpoint-2xl
--ax-breakpoint-xl-down
--ax-breakpoint-xl
--ax-breakpoint-lg-down
--ax-breakpoint-lg
--ax-breakpoint-md-down
--ax-breakpoint-md
--ax-breakpoint-sm-down
--ax-breakpoint-sm
--ax-breakpoint-xs
--ax-border-radius-full
--ax-border-radius-xlarge
--ax-border-radius-large
--ax-border-radius-medium
--ax-border-radius-small
```
File renamed without changes.
File renamed without changes.
@@ -4,14 +4,14 @@ import AkselThumbnail from "./assets/aksel-thumbnail.png";
import Components from "./assets/components.png";
import Setup from "./assets/setup.png";
<Meta title="Getting started" />
<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)
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>
@@ -30,7 +30,7 @@ import Setup from "./assets/setup.png";
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>
<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">
@@ -136,34 +136,34 @@ import Setup from "./assets/setup.png";
width: 100%;
display: grid;
grid-template-columns: repeat(3, 1fr);
grid-gap: var(--a-spacing-6);
grid-gap: 1.5rem;
}
.sb-link{
text-decoration: underline;
color: var(--a-text-default);
color: #111;
}
img {
object-fit: cover;
padding-bottom: var(--a-spacing-5);
padding-bottom: 1.25rem;
border-radius: 8px;
}
.sb-section-title {
margin-bottom: var(--a-spacing-8);
margin-bottom: 2rem;
}
.sb-section-item-heading {
padding-bottom: var(--a-spacing-1);
padding-bottom: 0.25rem
margin: 0 !important;
}
.sb-section-item-paragraph {
margin: 0;
padding-bottom: var(--a-spacing-3);
padding-bottom: 0.75rem;
}
@media screen and (max-width: 768px) {
+12
View File
@@ -19,3 +19,15 @@
.rowgap-wrap {
flex-wrap: wrap;
}
.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;
}
+8 -3
View File
@@ -46,13 +46,14 @@ export default {
staticDirs: ["./public"],
stories: () => [
"../@navikt/**/*.stories.@(js|jsx|ts|tsx|mdx)",
"./*.mdx",
"./docs/*.mdx",
"./docs/*.stories.tsx",
"../aksel.nav.no/website/pages/templates/**/*.tsx",
],
addons: [
"@storybook/addon-a11y",
"@whitespace/storybook-addon-html",
"@storybook/addon-interactions",
"@storybook/addon-themes",
{
name: "@storybook/addon-storysource",
options: {
@@ -70,7 +71,11 @@ export default {
},
},
},
"storybook-addon-pseudo-states",
/**
* https://github.com/chromaui/storybook-addon-pseudo-states/issues/101
* Currently disabled to avoid interference with darkmode update
*/
/* "storybook-addon-pseudo-states", */
],
framework: {
name: "@storybook/react-vite",
-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", "Controls"],
"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];
+127
View File
@@ -0,0 +1,127 @@
import { withThemeByClassName } from "@storybook/addon-themes";
import { Preview } from "@storybook/react";
import React, { useLayoutEffect } from "react";
// @ts-expect-error - Temporary
import darksideCss from "../@navikt/core/css/darkside/index.css?inline";
// @ts-expect-error - Temporary
import defaultCss from "../@navikt/core/css/index.css?inline";
import { Provider } from "../@navikt/core/react/src/provider";
import { Theme } from "../@navikt/core/react/src/theme";
import en from "../@navikt/core/react/src/util/i18n/locales/en";
import nb from "../@navikt/core/react/src/util/i18n/locales/nb";
import nn from "../@navikt/core/react/src/util/i18n/locales/nn";
import "./layout.css";
const ModeDecorator = ({ children, mode, theme }) => {
useLayoutEffect(() => {
const style = document.createElement("style");
style.innerHTML = mode === "darkside" ? darksideCss : defaultCss;
document.head.appendChild(style);
if (mode === "darkside") {
document.body.style.setProperty("background", "var(--ax-bg-default)");
}
return () => {
document.head.removeChild(style);
document.body.style.removeProperty("background");
};
}, [mode]);
return mode === "darkside" ? (
<Theme theme={theme || undefined} hasBackground={false}>
{children}
</Theme>
) : (
children
);
};
const translations = {
nb,
nn,
en,
};
const LanguageDecorator = ({ children, language }) => {
if (language) {
return (
<Provider translations={translations[language]}>{children}</Provider>
);
}
return children;
};
export default {
parameters: {
options: {
storySort: {
method: "alphabetical",
order: [
"Docs",
["Getting started"],
"ds-react",
["Primitives"],
["Default", "Controls"],
"Aksel-icons",
],
},
},
layout: "centered",
backgrounds: { disable: true },
},
globalTypes: {
mode: {
name: "Darkside",
toolbar: {
items: [
{
value: "default",
icon: "hourglass",
title: "Legacy theme",
},
{ value: "darkside", icon: "beaker", title: "Darkside theme" },
],
showName: true,
dynamicTitle: true,
},
},
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,
},
},
},
initialGlobals: {
mode: "default",
},
decorators: [
(StoryFn, context) => (
<ModeDecorator mode={context.globals.mode} theme={context.globals.theme}>
<StoryFn />
</ModeDecorator>
),
(StoryFn, context) => (
<LanguageDecorator language={context.globals.language}>
<StoryFn />
</LanguageDecorator>
),
withThemeByClassName({
themes: {
light: "light",
dark: "dark",
},
defaultTheme: "light",
}),
],
} satisfies Preview;
+4 -1
View File
@@ -1,5 +1,8 @@
{
"cssVariables.lookupFiles": ["@navikt/core/css/dist/index.css"],
"cssVariables.lookupFiles": [
"@navikt/core/tokens/dist/tokens.css",
"@navikt/core/tokens/dist/darkside/tokens.css"
],
"eslint.problems.shortenToSingleLine": true,
"editor.defaultFormatter": "esbenp.prettier-vscode",
"files.watcherExclude": {
+78
View File
@@ -1,5 +1,83 @@
# @navikt/aksel-icons
## 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
+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,9 +1,9 @@
/* eslint-disable import/no-named-as-default-member */
import fastglob from "fast-glob";
import fs from "fs";
import jsYaml from "js-yaml";
import { JSON_SCHEMA, load } from "js-yaml";
import path from "path";
import { describe, expect, test } from "vitest";
import { IconYml } from "../config/figma/make-configs";
const basePath = path.resolve(__dirname, "../icons");
@@ -14,9 +14,10 @@ const ymlList = fastglob
describe(`Each icons YML-config is valid`, () => {
ymlList.forEach((file) => {
test(`${file} has valid YML-config`, () => {
const ymlData = jsYaml.load(fs.readFileSync(`${basePath}/${file}`), {
schema: jsYaml.JSON_SCHEMA,
});
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();
@@ -31,7 +32,7 @@ describe(`Each icons YML-config is valid`, () => {
});
});
function isDate(dateStr) {
function isDate(dateStr: string) {
return !Number.isNaN(
new Date(dateStr.split(".").reverse().join(".")).getDate(),
);
@@ -21,8 +21,7 @@ describe(`Each icons has a valid code`, () => {
test(`has valid attributes on root-node`, () => {
const root = select(":root", iconAst);
const properties =
root && root.properties ? Object.keys(root.properties).sort() : [];
const properties = Object.keys(root?.properties ?? []).sort();
expect(properties).toStrictEqual(
["viewBox", "xmlns", "height", "width", "fill"].sort(),
@@ -31,45 +30,41 @@ describe(`Each icons has a valid code`, () => {
test(`has valid xml-attr`, () => {
const root = select(":root", iconAst);
const xmlns = root && root.properties ? root.properties.xmlns : null;
expect(xmlns).toBe("http://www.w3.org/2000/svg");
expect(root?.properties?.xmlns).toBe("http://www.w3.org/2000/svg");
});
test(`has valid viewbox`, () => {
const root = select(":root", iconAst);
const viewbox =
root && root.properties ? root.properties.viewBox : null;
expect(viewbox).toBe("0 0 24 24");
expect(root?.properties?.viewBox).toBe("0 0 24 24");
});
test(`root fill is none`, () => {
const root = select(":root", iconAst);
const fill = root && root.properties ? root.properties.fill : null;
expect(fill).toBe("none");
expect(root?.properties?.fill).toBe("none");
});
test(`has valid width and height`, () => {
const root = select(":root", iconAst);
const width = root && root.properties ? root.properties.width : null;
const height = root && root.properties ? root.properties.height : null;
expect(width).toBe("24");
expect(height).toBe("24");
expect(root?.properties?.width).toBe("24");
expect(root?.properties?.height).toBe("24");
});
test(`has valid stroke`, () => {
const nodes = selectAll("*", iconAst);
nodes.forEach((n) => {
n.properties?.stroke &&
if (n.properties?.stroke) {
expect(n.properties.stroke).toEqual("#23262A");
}
});
});
test(`has valid stroke-width`, () => {
const nodes = selectAll("*", iconAst);
nodes.forEach((n) => {
n.properties?.strokeWidth &&
if (n.properties?.strokeWidth) {
expect(n.properties?.strokeWidth).toEqual("1.5");
}
});
});
});
@@ -1,58 +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) => {
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 camelCase from "lodash.camelCase";
import startCase from "lodash.startcase";
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,17 @@
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", "");
/* @ts-expect-error Figma now includes the key:value pair `containingStateGroup: { name: string, nodeId: string }` */
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`;
};
@@ -1,65 +0,0 @@
import { config } from "dotenv";
import { existsSync, mkdirSync, readdirSync, rmSync, writeFileSync } from "fs";
import { resolve } from "path";
import { fetchDownloadUrls, fetchIcon, fetchIcons } from "./fetch-icons.mjs";
import { resolveName } from "./icon-name.mjs";
import { makeConfig } from "./make-configs.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.info(`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.info(`Success! ${Object.keys(images).length} ikoner lastet ned`);
}
main();
+106
View File
@@ -0,0 +1,106 @@
import { existsSync, mkdirSync, readdirSync, rmSync, writeFileSync } from "fs";
import { resolve } from "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,17 +1,40 @@
import { PublishedComponent } from "@figma/rest-api-spec";
import { writeFileSync } from "fs";
import jsYaml from "js-yaml";
import { dump } from "js-yaml";
import { resolve } from "path";
import { resolveName } from "./icon-name.mjs";
import { resolveName } from "./icon-name";
export const makeConfig = (icons, folder) => {
icons.forEach((icon) => {
export type IconYml = {
name: string;
category: string;
sub_category: string;
keywords: string[];
variant: string;
updated_at: 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);
const config = {
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,
@@ -33,14 +56,18 @@ export const makeConfig = (icons, folder) => {
.join("."),
};
const yml = jsYaml.dump(config, {
const yml = dump(config, {
noRefs: true,
skipInvalid: false,
quotingType: '"',
});
writeFileSync(resolve(folder, `${config.name}.yml`), yml, {
writeFileSync(resolve(dirLocation, `${config.name}.yml`), yml, {
encoding: "utf8",
});
});
counter++;
}
console.info(`Created ${counter} icon yml files`);
console.groupEnd();
};
@@ -1,12 +0,0 @@
export function paginate(arr, size) {
return arr.reduce((acc, val, i) => {
let idx = Math.floor(i / size);
if (!acc[idx]) {
acc[idx] = [];
}
let page = acc[idx];
page.push(val);
return acc;
}, []);
}
+1
View File
@@ -15,6 +15,7 @@ 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;
}
+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
@@ -22,13 +22,13 @@
"@svgr/core": "^8.1.0",
"@types/node": "^18.15.11",
"@types/postcss-url": "^10.0.4",
"@types/react": "^18.0.0",
"@types/react": "^18.3.11",
"@types/react-dom": "^18.0.0",
"@vitejs/plugin-react": "^4.2.1",
"postcss": "^8.4.31",
"postcss-url": "^10.1.3",
"typescript": "^5.1.6",
"vite": "^5.4.6",
"typescript": "5.5.4",
"vite": "^5.4.12",
"vite-plugin-singlefile": "^1.0.0",
"vite-plugin-svgr": "^4.2.0"
}
@@ -109,7 +109,7 @@ const App = () => {
icon.removeEventListener("dragend", dragEvent);
}
};
}, [categories]);
}, []);
return (
<main tabIndex={-1} className="wrapper">
+1 -1
View File
@@ -13,5 +13,5 @@ keywords:
- forward
- videresend
variant: Stroke
updated_at: 23.02.2024
updated_at: 05.09.2024
created_at: 07.03.2023
+1 -1
View File
@@ -15,5 +15,5 @@ keywords:
- risiko
- forsiktighet
variant: Stroke
updated_at: 05.01.2024
updated_at: 27.09.2024
created_at: 07.03.2023
+1 -1
View File
@@ -15,5 +15,5 @@ keywords:
- markup-språk
- kildekode
variant: Stroke
updated_at: 01.03.2024
updated_at: 18.09.2024
created_at: 07.03.2023
+1 -1
View File
@@ -12,5 +12,5 @@ keywords:
- struktur
- innhold
variant: Stroke
updated_at: 05.01.2024
updated_at: 10.02.2025
created_at: 07.03.2023
+1 -1
View File
@@ -6,5 +6,5 @@ keywords:
- sann
- resultat
variant: Stroke
updated_at: 05.01.2024
updated_at: 24.09.2024
created_at: 07.03.2023
+1 -1
View File
@@ -9,5 +9,5 @@ keywords:
- open
- åpne
variant: Stroke
updated_at: 24.01.2024
updated_at: 16.09.2024
created_at: 07.03.2023
@@ -0,0 +1,3 @@
<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="M12.5303 2.21967C12.2374 1.92678 11.7626 1.92678 11.4697 2.21967L7.46967 6.21967C7.17678 6.51256 7.17678 6.98744 7.46967 7.28033C7.76256 7.57322 8.23744 7.57322 8.53033 7.28033L11.25 4.56066L11.25 10C11.25 10.4142 11.5858 10.75 12 10.75C12.4142 10.75 12.75 10.4142 12.75 10L12.75 4.56066L15.4697 7.28033C15.7626 7.57322 16.2374 7.57322 16.5303 7.28033C16.8232 6.98744 16.8232 6.51256 16.5303 6.21967L12.5303 2.21967ZM11.4697 21.7803C11.7626 22.0732 12.2374 22.0732 12.5303 21.7803L16.5303 17.7803C16.8232 17.4874 16.8232 17.0126 16.5303 16.7197C16.2374 16.4268 15.7626 16.4268 15.4697 16.7197L12.75 19.4393L12.75 14C12.75 13.5858 12.4142 13.25 12 13.25C11.5858 13.25 11.25 13.5858 11.25 14L11.25 19.4393L8.53033 16.7197C8.23744 16.4268 7.76256 16.4268 7.46967 16.7197C7.17678 17.0126 7.17678 17.4874 7.46967 17.7803L11.4697 21.7803Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 1003 B

@@ -0,0 +1,13 @@
name: ExpandVertical
category: Arrows
sub_category: Arrow
keywords:
- arrows
- piler
- fullscreen
- fullskjerm
- open
- åpne
variant: Stroke
updated_at: 30.01.2025
created_at: 29.01.2025
+4
View File
@@ -0,0 +1,4 @@
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M9.20973 16.193H9.90274C10.1267 16.193 10.3041 16.1323 10.4347 16.011C10.5701 15.885 10.6377 15.7193 10.6377 15.514C10.6377 15.3087 10.5701 15.1453 10.4347 15.024C10.3041 14.898 10.1267 14.835 9.90274 14.835H9.20973V16.193Z" fill="#23262A"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M5.25 4.5C5.25 3.80964 5.80964 3.25 6.5 3.25H14C14.1989 3.25 14.3897 3.32902 14.5303 3.46967L18.5303 7.46967C18.671 7.61032 18.75 7.80109 18.75 8V12.25H21C21.4142 12.25 21.75 12.5858 21.75 13V20C21.75 20.4142 21.4142 20.75 21 20.75H3C2.58579 20.75 2.25 20.4142 2.25 20V13C2.25 12.5858 2.58579 12.25 3 12.25H5.25V4.5ZM6.75 12.25H17.25V8.75H14.5C13.8096 8.75 13.25 8.19036 13.25 7.5V4.75H6.75V12.25ZM14.75 5.81066L16.1893 7.25H14.75V5.81066ZM5.18047 19.077C4.6438 19.077 4.2168 18.9323 3.89947 18.643C3.5868 18.349 3.43047 17.9547 3.43047 17.46H4.48047C4.48047 17.6747 4.54347 17.8473 4.66947 17.978C4.79547 18.104 4.9658 18.167 5.18047 18.167C5.39514 18.167 5.56547 18.1063 5.69147 17.985C5.81747 17.859 5.88047 17.6887 5.88047 17.474V14.87H4.72547V13.89H6.93047V17.474C6.93047 17.9687 6.77414 18.3607 6.46147 18.65C6.1488 18.9347 5.7218 19.077 5.18047 19.077ZM8.15973 19V13.89H9.90274C10.2621 13.89 10.5747 13.9577 10.8407 14.093C11.1114 14.2283 11.3191 14.4173 11.4637 14.66C11.6131 14.9027 11.6877 15.1873 11.6877 15.514C11.6877 15.836 11.6131 16.1207 11.4637 16.368C11.3144 16.6107 11.1067 16.7997 10.8407 16.935C10.5747 17.0703 10.2621 17.138 9.90274 17.138H9.20973V19H8.15973ZM12.665 19V13.89H15.815V14.786H13.694V15.934H15.57V16.83H13.694V18.104H15.815V19H12.665ZM18.6403 19.07C18.2996 19.07 18.0009 19.007 17.7443 18.881C17.4876 18.7503 17.2869 18.5707 17.1423 18.342C17.0023 18.1087 16.9323 17.838 16.9323 17.53V15.36C16.9323 15.0473 17.0023 14.7767 17.1423 14.548C17.2869 14.3193 17.4876 14.142 17.7443 14.016C18.0009 13.8853 18.2996 13.82 18.6403 13.82C18.9856 13.82 19.2843 13.8853 19.5363 14.016C19.7929 14.142 19.9913 14.3193 20.1313 14.548C20.2759 14.7767 20.3483 15.0473 20.3483 15.36H19.2983C19.2983 15.1547 19.2399 14.9983 19.1233 14.891C19.0113 14.7837 18.8503 14.73 18.6403 14.73C18.4303 14.73 18.2669 14.7837 18.1503 14.891C18.0383 14.9983 17.9823 15.1547 17.9823 15.36V17.53C17.9823 17.7307 18.0383 17.887 18.1503 17.999C18.2669 18.1063 18.4303 18.16 18.6403 18.16C18.8503 18.16 19.0113 18.1063 19.1233 17.999C19.2399 17.887 19.2983 17.7307 19.2983 17.53V17.089H18.5423V16.2H20.3483V17.53C20.3483 17.838 20.2759 18.1087 20.1313 18.342C19.9913 18.5707 19.7929 18.7503 19.5363 18.881C19.2843 19.007 18.9856 19.07 18.6403 19.07Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 2.6 KiB

+13
View File
@@ -0,0 +1,13 @@
name: FileJpeg
category: Files and application
sub_category: Files
keywords:
- document
- dokument
- fil
- file
- jpg
- jpeg
variant: Stroke
updated_at: 06.11.2024
created_at: 06.11.2024
@@ -0,0 +1,5 @@
<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="M13 3.25C13.1381 3.25 13.25 3.36193 13.25 3.5V7.5C13.25 8.19036 13.8096 8.75 14.5 8.75H18.5C18.6381 8.75 18.75 8.86193 18.75 9V10.5C18.75 10.6381 18.6381 10.75 18.5 10.75H5.5C5.36193 10.75 5.25 10.6381 5.25 10.5V4.5C5.25 3.80964 5.80964 3.25 6.5 3.25H13ZM15.1768 4.11612C15.0193 3.95863 14.75 4.07017 14.75 4.29289V7C14.75 7.13807 14.8619 7.25 15 7.25H17.7071C17.9298 7.25 18.0414 6.98072 17.8839 6.82322L15.1768 4.11612Z" fill="#23262A"/>
<path d="M9.90274 16.193H9.20973V14.835H9.90274C10.1267 14.835 10.3041 14.898 10.4347 15.024C10.5701 15.1453 10.6377 15.3087 10.6377 15.514C10.6377 15.7193 10.5701 15.885 10.4347 16.011C10.3041 16.1323 10.1267 16.193 9.90274 16.193Z" fill="#23262A"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M3 12.25C2.58579 12.25 2.25 12.5858 2.25 13V20C2.25 20.4142 2.58579 20.75 3 20.75H21C21.4142 20.75 21.75 20.4142 21.75 20V13C21.75 12.5858 21.4142 12.25 21 12.25H3ZM3.89947 18.643C4.2168 18.9323 4.6438 19.077 5.18047 19.077C5.7218 19.077 6.1488 18.9347 6.46147 18.65C6.77414 18.3607 6.93047 17.9687 6.93047 17.474V13.89H4.72547V14.87H5.88047V17.474C5.88047 17.6887 5.81747 17.859 5.69147 17.985C5.56547 18.1063 5.39514 18.167 5.18047 18.167C4.9658 18.167 4.79547 18.104 4.66947 17.978C4.54347 17.8473 4.48047 17.6747 4.48047 17.46H3.43047C3.43047 17.9547 3.5868 18.349 3.89947 18.643ZM8.15973 13.89V19H9.20973V17.138H9.90274C10.2621 17.138 10.5747 17.0703 10.8407 16.935C11.1067 16.7997 11.3144 16.6107 11.4637 16.368C11.6131 16.1207 11.6877 15.836 11.6877 15.514C11.6877 15.1873 11.6131 14.9027 11.4637 14.66C11.3191 14.4173 11.1114 14.2283 10.8407 14.093C10.5747 13.9577 10.2621 13.89 9.90274 13.89H8.15973ZM12.665 13.89V19H15.815V18.104H13.694V16.83H15.57V15.934H13.694V14.786H15.815V13.89H12.665ZM17.7443 18.881C18.0009 19.007 18.2996 19.07 18.6403 19.07C18.9856 19.07 19.2843 19.007 19.5363 18.881C19.7929 18.7503 19.9913 18.5707 20.1313 18.342C20.2759 18.1087 20.3483 17.838 20.3483 17.53V16.2H18.5423V17.089H19.2983V17.53C19.2983 17.7307 19.2399 17.887 19.1233 17.999C19.0113 18.1063 18.8503 18.16 18.6403 18.16C18.4303 18.16 18.2669 18.1063 18.1503 17.999C18.0383 17.887 17.9823 17.7307 17.9823 17.53V15.36C17.9823 15.1547 18.0383 14.9983 18.1503 14.891C18.2669 14.7837 18.4303 14.73 18.6403 14.73C18.8503 14.73 19.0113 14.7837 19.1233 14.891C19.2399 14.9983 19.2983 15.1547 19.2983 15.36H20.3483C20.3483 15.0473 20.2759 14.7767 20.1313 14.548C19.9913 14.3193 19.7929 14.142 19.5363 14.016C19.2843 13.8853 18.9856 13.82 18.6403 13.82C18.2996 13.82 18.0009 13.8853 17.7443 14.016C17.4876 14.142 17.2869 14.3193 17.1423 14.548C17.0023 14.7767 16.9323 15.0473 16.9323 15.36V17.53C16.9323 17.838 17.0023 18.1087 17.1423 18.342C17.2869 18.5707 17.4876 18.7503 17.7443 18.881Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 2.8 KiB

@@ -0,0 +1,13 @@
name: FileJpegFill
category: Files and application
sub_category: Files
keywords:
- document
- dokument
- fil
- file
- jpg
- jpeg
variant: Fill
updated_at: 06.11.2024
created_at: 06.11.2024
+4
View File
@@ -0,0 +1,4 @@
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M7.0061 16.193H7.6991C7.9231 16.193 8.10043 16.1323 8.2311 16.011C8.36644 15.885 8.4341 15.7193 8.4341 15.514C8.4341 15.3087 8.36644 15.1453 8.2311 15.024C8.10043 14.898 7.9231 14.835 7.6991 14.835H7.0061V16.193Z" fill="#23262A"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M5.25 4.5C5.25 3.80964 5.80964 3.25 6.5 3.25H14C14.1989 3.25 14.3897 3.32902 14.5303 3.46967L18.5303 7.46967C18.671 7.61032 18.75 7.80109 18.75 8V12.25H21C21.4142 12.25 21.75 12.5858 21.75 13V20C21.75 20.4142 21.4142 20.75 21 20.75H3C2.58579 20.75 2.25 20.4142 2.25 20V13C2.25 12.5858 2.58579 12.25 3 12.25H5.25V4.5ZM6.75 12.25H17.25V8.75H14.5C13.8096 8.75 13.25 8.19036 13.25 7.5V4.75H6.75V12.25ZM14.75 5.81066L16.1893 7.25H14.75V5.81066ZM5.9561 19V13.89H7.6991C8.05843 13.89 8.3711 13.9577 8.6371 14.093C8.90777 14.2283 9.11544 14.4173 9.2601 14.66C9.40944 14.9027 9.4841 15.1873 9.4841 15.514C9.4841 15.836 9.40944 16.1207 9.2601 16.368C9.11077 16.6107 8.9031 16.7997 8.6371 16.935C8.3711 17.0703 8.05843 17.138 7.6991 17.138H7.0061V19H5.9561ZM10.3214 19V13.89H11.5464L12.8694 17.845C12.8554 17.6723 12.839 17.474 12.8204 17.25C12.8017 17.0213 12.7854 16.795 12.7714 16.571C12.762 16.3423 12.7574 16.1487 12.7574 15.99V13.89H13.6814V19H12.4564L11.1474 15.045C11.1614 15.1943 11.1754 15.3717 11.1894 15.577C11.2034 15.7823 11.215 15.99 11.2244 16.2C11.2384 16.41 11.2454 16.5967 11.2454 16.76V19H10.3214ZM16.4366 19.07C16.096 19.07 15.7973 19.007 15.5406 18.881C15.284 18.7503 15.0833 18.5707 14.9386 18.342C14.7986 18.1087 14.7286 17.838 14.7286 17.53V15.36C14.7286 15.0473 14.7986 14.7767 14.9386 14.548C15.0833 14.3193 15.284 14.142 15.5406 14.016C15.7973 13.8853 16.096 13.82 16.4366 13.82C16.782 13.82 17.0806 13.8853 17.3326 14.016C17.5893 14.142 17.7876 14.3193 17.9276 14.548C18.0723 14.7767 18.1446 15.0473 18.1446 15.36H17.0946C17.0946 15.1547 17.0363 14.9983 16.9196 14.891C16.8076 14.7837 16.6466 14.73 16.4366 14.73C16.2266 14.73 16.0633 14.7837 15.9466 14.891C15.8346 14.9983 15.7786 15.1547 15.7786 15.36V17.53C15.7786 17.7307 15.8346 17.887 15.9466 17.999C16.0633 18.1063 16.2266 18.16 16.4366 18.16C16.6466 18.16 16.8076 18.1063 16.9196 17.999C17.0363 17.887 17.0946 17.7307 17.0946 17.53V17.089H16.3386V16.2H18.1446V17.53C18.1446 17.838 18.0723 18.1087 17.9276 18.342C17.7876 18.5707 17.5893 18.7503 17.3326 18.881C17.0806 19.007 16.782 19.07 16.4366 19.07Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 2.4 KiB

+12
View File
@@ -0,0 +1,12 @@
name: FilePng
category: Files and application
sub_category: Files
keywords:
- document
- dokument
- fil
- file
- png
variant: Stroke
updated_at: 06.11.2024
created_at: 06.11.2024
@@ -0,0 +1,6 @@
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M13.25 3.5C13.25 3.36193 13.1381 3.25 13 3.25H6.5C5.80964 3.25 5.25 3.80964 5.25 4.5V10.5C5.25 10.6381 5.36193 10.75 5.5 10.75H18.5C18.6381 10.75 18.75 10.6381 18.75 10.5V9C18.75 8.86193 18.6381 8.75 18.5 8.75H14.5C13.8096 8.75 13.25 8.19036 13.25 7.5V3.5Z" fill="#23262A"/>
<path d="M14.75 4.29289C14.75 4.07017 15.0193 3.95863 15.1768 4.11612L17.8839 6.82322C18.0414 6.98072 17.9298 7.25 17.7071 7.25H15C14.8619 7.25 14.75 7.13807 14.75 7V4.29289Z" fill="#23262A"/>
<path d="M7.0061 16.193H7.6991C7.9231 16.193 8.10043 16.1323 8.2311 16.011C8.36644 15.885 8.4341 15.7193 8.4341 15.514C8.4341 15.3087 8.36644 15.1453 8.2311 15.024C8.10043 14.898 7.9231 14.835 7.6991 14.835H7.0061V16.193Z" fill="#23262A"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M2.25 13C2.25 12.5858 2.58579 12.25 3 12.25H21C21.4142 12.25 21.75 12.5858 21.75 13V20C21.75 20.4142 21.4142 20.75 21 20.75H3C2.58579 20.75 2.25 20.4142 2.25 20V13ZM5.9561 19V13.89H7.6991C8.05843 13.89 8.3711 13.9577 8.6371 14.093C8.90777 14.2283 9.11544 14.4173 9.2601 14.66C9.40944 14.9027 9.4841 15.1873 9.4841 15.514C9.4841 15.836 9.40944 16.1207 9.2601 16.368C9.11077 16.6107 8.9031 16.7997 8.6371 16.935C8.3711 17.0703 8.05843 17.138 7.6991 17.138H7.0061V19H5.9561ZM10.3214 19V13.89H11.5464L12.8694 17.845C12.8554 17.6723 12.839 17.474 12.8204 17.25C12.8017 17.0213 12.7854 16.795 12.7714 16.571C12.762 16.3423 12.7574 16.1487 12.7574 15.99V13.89H13.6814V19H12.4564L11.1474 15.045C11.1614 15.1943 11.1754 15.3717 11.1894 15.577C11.2034 15.7823 11.215 15.99 11.2244 16.2C11.2384 16.41 11.2454 16.5967 11.2454 16.76V19H10.3214ZM16.4366 19.07C16.096 19.07 15.7973 19.007 15.5406 18.881C15.284 18.7503 15.0833 18.5707 14.9386 18.342C14.7986 18.1087 14.7286 17.838 14.7286 17.53V15.36C14.7286 15.0473 14.7986 14.7767 14.9386 14.548C15.0833 14.3193 15.284 14.142 15.5406 14.016C15.7973 13.8853 16.096 13.82 16.4366 13.82C16.782 13.82 17.0806 13.8853 17.3326 14.016C17.5893 14.142 17.7876 14.3193 17.9276 14.548C18.0723 14.7767 18.1446 15.0473 18.1446 15.36H17.0946C17.0946 15.1547 17.0363 14.9983 16.9196 14.891C16.8076 14.7837 16.6466 14.73 16.4366 14.73C16.2266 14.73 16.0633 14.7837 15.9466 14.891C15.8346 14.9983 15.7786 15.1547 15.7786 15.36V17.53C15.7786 17.7307 15.8346 17.887 15.9466 17.999C16.0633 18.1063 16.2266 18.16 16.4366 18.16C16.6466 18.16 16.8076 18.1063 16.9196 17.999C17.0363 17.887 17.0946 17.7307 17.0946 17.53V17.089H16.3386V16.2H18.1446V17.53C18.1446 17.838 18.0723 18.1087 17.9276 18.342C17.7876 18.5707 17.5893 18.7503 17.3326 18.881C17.0806 19.007 16.782 19.07 16.4366 19.07Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 2.6 KiB

+12
View File
@@ -0,0 +1,12 @@
name: FilePngFill
category: Files and application
sub_category: Files
keywords:
- document
- dokument
- fil
- file
- png
variant: Fill
updated_at: 06.11.2024
created_at: 06.11.2024
+1 -1
View File
@@ -10,5 +10,5 @@ keywords:
- wardrobe
- kleshenger
variant: Stroke
updated_at: 04.12.2023
updated_at: 12.09.2024
created_at: 07.03.2023
+1 -1
View File
@@ -7,5 +7,5 @@ keywords:
- penger
- norske kroner
variant: Stroke
updated_at: 05.01.2024
updated_at: 03.09.2024
created_at: 07.03.2023
+1 -1
View File
@@ -15,5 +15,5 @@ keywords:
- avslutt
- avslutt
variant: Stroke
updated_at: 25.04.2024
updated_at: 06.09.2024
created_at: 07.03.2023
+3
View File
@@ -0,0 +1,3 @@
<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="M3.75 3.25C3.33579 3.25 3 3.58579 3 4C3 4.41421 3.33579 4.75 3.75 4.75H20.25C20.6642 4.75 21 4.41421 21 4C21 3.58579 20.6642 3.25 20.25 3.25H3.75ZM12.6855 6.9454C12.5652 6.67455 12.2966 6.5 12.0002 6.5C11.7038 6.5 11.4352 6.67455 11.3148 6.9454L7.31483 15.9454C7.1466 16.3239 7.31707 16.7671 7.69558 16.9354C8.0741 17.1036 8.51732 16.9331 8.68555 16.5546L9.5987 14.5H14.4017L15.3148 16.5546C15.4831 16.9331 15.9263 17.1036 16.3048 16.9354C16.6833 16.7671 16.8538 16.3239 16.6855 15.9454L12.6855 6.9454ZM13.735 13L12.0002 9.09666L10.2654 13H13.735ZM3 20C3 19.5858 3.33579 19.25 3.75 19.25H20.25C20.6642 19.25 21 19.5858 21 20C21 20.4142 20.6642 20.75 20.25 20.75H3.75C3.33579 20.75 3 20.4142 3 20Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 867 B

+9
View File
@@ -0,0 +1,9 @@
name: LineHeight
category: Interface
sub_category: Design
keywords:
- linjehøyde
- linjeavstand
variant: Stroke
updated_at: 14.02.2025
created_at: 14.02.2025
@@ -0,0 +1,3 @@
<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="M15.7626 3.17678C16.446 2.49336 17.554 2.49336 18.2374 3.17678L20.8232 5.76257C21.5066 6.44598 21.5066 7.55402 20.8232 8.23744L13.409 15.6517C12.7057 16.3549 11.7519 16.75 10.7574 16.75H8.31066L7.03033 18.0303C6.73744 18.3232 6.26256 18.3232 5.96967 18.0303C5.67678 17.7374 5.67678 17.2626 5.96967 16.9697L7.25 15.6893V13.2426C7.25 12.2481 7.64509 11.2943 8.34835 10.591L15.7626 3.17678ZM17.1768 4.23744C17.0791 4.13981 16.9209 4.13981 16.8232 4.23744L9.40901 11.6517C8.98705 12.0736 8.75 12.6459 8.75 13.2426V15.25H10.7574C11.3541 15.25 11.9264 15.0129 12.3483 14.591L19.7626 7.17678C19.8602 7.07915 19.8602 6.92086 19.7626 6.82323L17.1768 4.23744ZM17.0303 6.96967C17.3232 7.26256 17.3232 7.73744 17.0303 8.03033L14.0303 11.0303C13.7374 11.3232 13.2626 11.3232 12.9697 11.0303C12.6768 10.7374 12.6768 10.2626 12.9697 9.96967L15.9697 6.96967C16.2626 6.67678 16.7374 6.67678 17.0303 6.96967ZM5.03033 18.9697C5.32322 19.2626 5.32322 19.7374 5.03033 20.0303L4.03033 21.0303C3.73744 21.3232 3.26256 21.3232 2.96967 21.0303C2.67678 20.7374 2.67678 20.2626 2.96967 19.9697L3.96967 18.9697C4.26256 18.6768 4.73744 18.6768 5.03033 18.9697Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 1.3 KiB

@@ -0,0 +1,15 @@
name: MedicalThermometer
category: Wellness
sub_category: Equipment
keywords:
- termometer
- lege
- umiddelbar hjelp
- helse
- health
- help
- doctor
- patient
variant: Stroke
updated_at: 14.10.2024
created_at: 07.03.2023
@@ -0,0 +1,3 @@
<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="M18.2374 3.17687C17.554 2.49345 16.446 2.49345 15.7626 3.17687L8.34835 10.5911C7.64509 11.2943 7.25 12.2482 7.25 13.2427V15.6893L5.96967 16.9697C5.67678 17.2626 5.67678 17.7374 5.96967 18.0303C6.26256 18.3232 6.73744 18.3232 7.03033 18.0303L8.31057 16.7501H10.7574C11.7519 16.7501 12.7057 16.355 13.409 15.6517L20.8232 8.23753C21.5066 7.55411 21.5066 6.44608 20.8232 5.76266L18.2374 3.17687ZM17.0303 8.03033C17.3232 7.73744 17.3232 7.26256 17.0303 6.96967C16.7374 6.67678 16.2626 6.67678 15.9697 6.96967L12.9697 9.96967C12.6768 10.2626 12.6768 10.7374 12.9697 11.0303C13.2626 11.3232 13.7374 11.3232 14.0303 11.0303L17.0303 8.03033ZM5.03033 20.0303C5.32322 19.7374 5.32322 19.2626 5.03033 18.9697C4.73744 18.6768 4.26256 18.6768 3.96967 18.9697L2.96967 19.9697C2.67678 20.2626 2.67678 20.7374 2.96967 21.0303C3.26256 21.3232 3.73744 21.3232 4.03033 21.0303L5.03033 20.0303Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 1.0 KiB

@@ -0,0 +1,15 @@
name: MedicalThermometerFill
category: Wellness
sub_category: Equipment
keywords:
- termometer
- lege
- umiddelbar hjelp
- helse
- health
- help
- doctor
- patient
variant: Fill
updated_at: 14.10.2024
created_at: 07.03.2023
+1 -1
View File
@@ -20,5 +20,5 @@ keywords:
- ansvar
- paragraf
variant: Stroke
updated_at: 04.01.2024
updated_at: 18.09.2024
created_at: 07.03.2023
@@ -0,0 +1,3 @@
<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="M12 3.75C7.44365 3.75 3.75 7.44365 3.75 12C3.75 16.5563 7.44365 20.25 12 20.25C16.5563 20.25 20.25 16.5563 20.25 12C20.25 7.44365 16.5563 3.75 12 3.75ZM2.25 12C2.25 6.61522 6.61522 2.25 12 2.25C17.3848 2.25 21.75 6.61522 21.75 12C21.75 17.3848 17.3848 21.75 12 21.75C6.61522 21.75 2.25 17.3848 2.25 12ZM11.0498 16.9C11.0498 16.3753 11.4751 15.95 11.9998 15.95C12.5245 15.95 12.9498 16.3753 12.9498 16.9C12.9498 17.4247 12.5245 17.85 11.9998 17.85C11.4751 17.85 11.0498 17.4247 11.0498 16.9ZM10.25 9.5C10.25 8.5335 11.0335 7.75 12 7.75H12.1361C13.0274 7.75 13.75 8.47255 13.75 9.36387C13.75 9.85413 13.5271 10.3178 13.1443 10.6241L12.7028 10.9773C11.7845 11.7119 11.25 12.8241 11.25 14C11.25 14.4142 11.5858 14.75 12 14.75C12.4142 14.75 12.75 14.4142 12.75 14C12.75 13.2797 13.0774 12.5985 13.6398 12.1486L14.0814 11.7954C14.82 11.2045 15.25 10.3098 15.25 9.36387C15.25 7.64413 13.8559 6.25 12.1361 6.25H12C10.2051 6.25 8.75 7.70507 8.75 9.5C8.75 9.91421 9.08579 10.25 9.5 10.25C9.91421 10.25 10.25 9.91421 10.25 9.5Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 1.2 KiB

@@ -0,0 +1,17 @@
name: QuestionmarkCircle
category: Status
sub_category: Guidance
keywords:
- assistance
- support
- information
- guidance
- question mark
- hjelp
- støtte
- informasjon
- veiledning
- spørsmålstegn
variant: Stroke
updated_at: 29.01.2025
created_at: 29.01.2025
@@ -0,0 +1,3 @@
<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="M12 21.75C17.3848 21.75 21.75 17.3848 21.75 12C21.75 6.61522 17.3848 2.25 12 2.25C6.61522 2.25 2.25 6.61522 2.25 12C2.25 17.3848 6.61522 21.75 12 21.75ZM12 7.75C11.0335 7.75 10.25 8.5335 10.25 9.5C10.25 9.91421 9.91421 10.25 9.5 10.25C9.08579 10.25 8.75 9.91421 8.75 9.5C8.75 7.70507 10.2051 6.25 12 6.25H12.1361C13.8559 6.25 15.25 7.64413 15.25 9.36387C15.25 10.3098 14.82 11.2045 14.0814 11.7954L13.6398 12.1486C13.0774 12.5985 12.75 13.2797 12.75 14C12.75 14.4142 12.4142 14.75 12 14.75C11.5858 14.75 11.25 14.4142 11.25 14C11.25 12.8241 11.7845 11.7119 12.7028 10.9773L13.1443 10.6241C13.5271 10.3178 13.75 9.85413 13.75 9.36387C13.75 8.47255 13.0274 7.75 12.1361 7.75H12ZM11.0498 16.9C11.0498 16.3753 11.4751 15.95 11.9998 15.95C12.5245 15.95 12.9498 16.3753 12.9498 16.9C12.9498 17.4247 12.5245 17.85 11.9998 17.85C11.4751 17.85 11.0498 17.4247 11.0498 16.9Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 1.0 KiB

@@ -0,0 +1,17 @@
name: QuestionmarkCircleFill
category: Status
sub_category: Guidance
keywords:
- assistance
- support
- information
- guidance
- question mark
- hjelp
- støtte
- informasjon
- veiledning
- spørsmålstegn
variant: Fill
updated_at: 29.01.2025
created_at: 29.01.2025
+1 -1
View File
@@ -1,3 +1,3 @@
<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="M14.0091 3.05126C12.9222 1.88827 11.0778 1.88827 9.99089 3.05126L9.20244 3.89486C8.95602 4.15852 8.60767 4.30281 8.24698 4.29063L7.09295 4.25162C5.502 4.19786 4.19787 5.50199 4.25164 7.09294L4.29064 8.24697C4.30283 8.60766 4.15853 8.95601 3.89487 9.20243L3.05127 9.99087C1.88828 11.0778 1.88828 12.9221 3.05127 14.0091L3.89487 14.7975C4.15853 15.044 4.30283 15.3923 4.29064 15.753L4.25164 16.907C4.19787 18.498 5.502 19.8021 7.09295 19.7483L8.24698 19.7093C8.60767 19.6972 8.95602 19.8414 9.20244 20.1051L9.99089 20.9487C11.0778 22.1117 12.9222 22.1117 14.0091 20.9487L14.7976 20.1051C15.044 19.8414 15.3923 19.6972 15.753 19.7093L16.907 19.7483C18.498 19.8021 19.8021 18.498 19.7484 16.907L19.7094 15.753C19.6972 15.3923 19.8415 15.044 20.1051 14.7975L20.9487 14.0091C22.1117 12.9221 22.1117 11.0778 20.9487 9.99087L20.1051 9.20243C19.8415 8.95601 19.6972 8.60766 19.7094 8.24697L19.7484 7.09294C19.8021 5.50199 18.498 4.19786 16.907 4.25162L15.753 4.29063C15.3923 4.30281 15.044 4.15852 14.7976 3.89486L14.0091 3.05126ZM11.0868 4.07549C11.5808 3.54686 12.4192 3.54686 12.9132 4.07549L13.7017 4.91909C14.2438 5.49914 15.0102 5.81659 15.8037 5.78977L16.9577 5.75077C17.6809 5.72633 18.2737 6.31912 18.2492 7.04228L18.2102 8.19631C18.1834 8.98981 18.5008 9.75618 19.0809 10.2983L19.9245 11.0868C20.4531 11.5808 20.4531 12.4192 19.9245 12.9132L19.0809 13.7017C18.5008 14.2438 18.1834 15.0102 18.2102 15.8037L18.2492 16.9577C18.2737 17.6809 17.6809 18.2736 16.9577 18.2492L15.8037 18.2102C15.0102 18.1834 14.2438 18.5008 13.7017 19.0809L12.9132 19.9245C12.4192 20.4531 11.5808 20.4531 11.0868 19.9245L10.2983 19.0809C9.75619 18.5008 8.98982 18.1834 8.19632 18.2102L7.04229 18.2492C6.31913 18.2736 5.72634 17.6809 5.75078 16.9577L5.78978 15.8037C5.8166 15.0102 5.49916 14.2438 4.91911 13.7017L4.0755 12.9132C3.54687 12.4192 3.54687 11.5808 4.0755 11.0868L4.91911 10.2983C5.49916 9.75618 5.8166 8.98981 5.78978 8.19631L5.75078 7.04228C5.72634 6.31912 6.31913 5.72633 7.04229 5.75077L8.19632 5.78977C8.98982 5.81659 9.75619 5.49915 10.2983 4.91909L11.0868 4.07549ZM8.7195 8.71973C9.01239 8.42684 9.48727 8.42684 9.78016 8.71973L11.9998 10.9394L14.2195 8.71973C14.5124 8.42684 14.9873 8.42684 15.2802 8.71973C15.5731 9.01262 15.5731 9.4875 15.2802 9.78039L13.0605 12.0001L15.2802 14.2197C15.5731 14.5126 15.5731 14.9875 15.2802 15.2804C14.9873 15.5733 14.5124 15.5733 14.2195 15.2804L11.9998 13.0607L9.78016 15.2804C9.48727 15.5733 9.01239 15.5733 8.7195 15.2804C8.42661 14.9875 8.42661 14.5126 8.7195 14.2197L10.9392 12.0001L8.7195 9.78039C8.42661 9.4875 8.42661 9.01262 8.7195 8.71973Z" fill="#23262A"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M14.0091 3.05126C12.9222 1.88827 11.0778 1.88827 9.99089 3.05126L9.20244 3.89486C8.95602 4.15852 8.60767 4.30281 8.24699 4.29063L7.09295 4.25162C5.502 4.19786 4.19787 5.50199 4.25164 7.09294L4.29064 8.24697C4.30283 8.60766 4.15854 8.95601 3.89488 9.20243L3.05128 9.99087C1.88828 11.0778 1.88828 12.9221 3.05128 14.0091L3.89488 14.7975C4.15854 15.044 4.30283 15.3923 4.29064 15.753L4.25164 16.907C4.19787 18.498 5.502 19.8021 7.09296 19.7483L8.24699 19.7093C8.60767 19.6972 8.95602 19.8414 9.20244 20.1051L9.99089 20.9487C11.0778 22.1117 12.9222 22.1117 14.0091 20.9487L14.7976 20.1051C15.044 19.8414 15.3923 19.6972 15.753 19.7093L16.9071 19.7483C18.498 19.8021 19.8021 18.498 19.7484 16.907L19.7094 15.753C19.6972 15.3923 19.8415 15.044 20.1051 14.7975L20.9487 14.0091C22.1117 12.9221 22.1117 11.0778 20.9487 9.99087L20.1051 9.20243C19.8415 8.95601 19.6972 8.60766 19.7094 8.24697L19.7484 7.09294C19.8021 5.50199 18.498 4.19786 16.9071 4.25162L15.753 4.29063C15.3923 4.30281 15.044 4.15852 14.7976 3.89486L14.0091 3.05126ZM11.0868 4.07549C11.5808 3.54686 12.4192 3.54686 12.9132 4.07549L13.7017 4.91909C14.2438 5.49914 15.0102 5.81659 15.8037 5.78977L16.9577 5.75077C17.6809 5.72633 18.2737 6.31912 18.2492 7.04228L18.2102 8.19631C18.1834 8.98981 18.5008 9.75618 19.0809 10.2983L19.9245 11.0868C20.4531 11.5808 20.4531 12.4192 19.9245 12.9132L19.0809 13.7017C18.5008 14.2438 18.1834 15.0102 18.2102 15.8037L18.2492 16.9577C18.2737 17.6809 17.6809 18.2736 16.9577 18.2492L15.8037 18.2102C15.0102 18.1834 14.2438 18.5008 13.7017 19.0809L12.9132 19.9245C12.4192 20.4531 11.5808 20.4531 11.0868 19.9245L10.2983 19.0809C9.7562 18.5008 8.98983 18.1834 8.19632 18.2102L7.04229 18.2492C6.31913 18.2736 5.72634 17.6809 5.75078 16.9577L5.78978 15.8037C5.8166 15.0102 5.49916 14.2438 4.91911 13.7017L4.07551 12.9132C3.54687 12.4192 3.54687 11.5808 4.07551 11.0868L4.91911 10.2983C5.49916 9.75618 5.8166 8.98981 5.78978 8.19631L5.75078 7.04228C5.72634 6.31912 6.31913 5.72633 7.04229 5.75077L8.19632 5.78977C8.98982 5.81659 9.75619 5.49915 10.2983 4.91909L11.0868 4.07549ZM8.7195 8.71973C9.0124 8.42684 9.48727 8.42684 9.78016 8.71973L11.9998 10.9394L14.2195 8.71973C14.5124 8.42684 14.9873 8.42684 15.2802 8.71973C15.5731 9.01262 15.5731 9.4875 15.2802 9.78039L13.0605 12.0001L15.2802 14.2197C15.5731 14.5126 15.5731 14.9875 15.2802 15.2804C14.9873 15.5733 14.5124 15.5733 14.2195 15.2804L11.9998 13.0607L9.78016 15.2804C9.48727 15.5733 9.0124 15.5733 8.7195 15.2804C8.42661 14.9875 8.42661 14.5126 8.7195 14.2197L10.9392 12.0001L8.7195 9.78039C8.42661 9.4875 8.42661 9.01262 8.7195 8.71973Z" fill="#23262A"/>
</svg>

Before

Width:  |  Height:  |  Size: 2.7 KiB

After

Width:  |  Height:  |  Size: 2.7 KiB

@@ -0,0 +1,3 @@
<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="M19.75 4.01992C19.75 3.53224 19.3003 3.16875 18.8235 3.27093L18.4572 3.34943C14.2007 4.26153 9.79929 4.26153 5.54282 3.34943L5.17649 3.27093C4.69967 3.16875 4.25 3.53223 4.25 4.01992V13.0001C4.25 17.2803 7.71979 20.7501 12 20.7501C16.2802 20.7501 19.75 17.2803 19.75 13.0001V4.01992ZM5.75 4.92339C9.87693 5.73687 14.1231 5.73687 18.25 4.92339V13.0001C18.25 16.4519 15.4518 19.2501 12 19.2501C8.54822 19.2501 5.75 16.4519 5.75 13.0001V4.92339ZM15.7803 10.2803C16.0732 9.98744 16.0732 9.51256 15.7803 9.21967C15.4874 8.92678 15.0126 8.92678 14.7197 9.21967L11 12.9393L9.28033 11.2197C8.98744 10.9268 8.51256 10.9268 8.21967 11.2197C7.92678 11.5126 7.92678 11.9874 8.21967 12.2803L10.4697 14.5303C10.7626 14.8232 11.2374 14.8232 11.5303 14.5303L15.7803 10.2803Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 929 B

@@ -0,0 +1,14 @@
name: ShieldCheckmark
category: Law and security
sub_category: Security
keywords:
- sikkerhet
- security
- beskyttelse
- sikkert
- kryptert
- encrypted
- secured
variant: Stroke
updated_at: 29.11.2024
created_at: 18.11.2024
@@ -0,0 +1,3 @@
<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="M19.75 4.01971C19.75 3.53202 19.3003 3.16854 18.8235 3.27071L18.4572 3.34921C14.2007 4.26131 9.79929 4.26131 5.54282 3.34921L5.17649 3.27071C4.69967 3.16854 4.25 3.53202 4.25 4.01971V12.9999C4.25 17.2801 7.71979 20.7499 12 20.7499C16.2802 20.7499 19.75 17.2801 19.75 12.9999V4.01971ZM15.7803 10.2803C16.0732 9.98744 16.0732 9.51256 15.7803 9.21967C15.4874 8.92678 15.0126 8.92678 14.7197 9.21967L11 12.9393L9.28033 11.2197C8.98744 10.9268 8.51256 10.9268 8.21967 11.2197C7.92678 11.5126 7.92678 11.9874 8.21967 12.2803L10.4697 14.5303C10.7626 14.8232 11.2374 14.8232 11.5303 14.5303L15.7803 10.2803Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 770 B

@@ -0,0 +1,14 @@
name: ShieldCheckmarkFill
category: Law and security
sub_category: Security
keywords:
- sikkerhet
- security
- beskyttelse
- sikkert
- kryptert
- encrypted
- secured
variant: Fill
updated_at: 29.11.2024
created_at: 18.11.2024
+2 -1
View File
@@ -9,6 +9,7 @@ keywords:
- låst
- kryptert
- encrypted
- locked
variant: Stroke
updated_at: 04.12.2023
updated_at: 29.11.2024
created_at: 07.03.2023
+2 -1
View File
@@ -9,6 +9,7 @@ keywords:
- låst
- kryptert
- encrypted
- locked
variant: Fill
updated_at: 04.12.2023
updated_at: 29.11.2024
created_at: 07.03.2023
+1 -1
View File
@@ -6,5 +6,5 @@ keywords:
- crystal
- snø
variant: Stroke
updated_at: 05.01.2024
updated_at: 23.09.2024
created_at: 07.03.2023
+3
View File
@@ -0,0 +1,3 @@
<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="M18.0303 18.5303C17.8897 18.671 17.6989 18.75 17.5 18.75C17.3011 18.75 17.1103 18.671 16.9697 18.5303L13.4697 15.0303C13.1768 14.7374 13.1768 14.2626 13.4697 13.9697C13.7626 13.6768 14.2374 13.6768 14.5303 13.9697L16.75 16.1893V6C16.75 5.58579 17.0858 5.25 17.5 5.25C17.9142 5.25 18.25 5.58579 18.25 6V16.1893L20.4697 13.9697C20.7626 13.6768 21.2374 13.6768 21.5303 13.9697C21.8232 14.2626 21.8232 14.7374 21.5303 15.0303L18.0303 18.5303ZM2.75 6.25C2.33579 6.25 2 6.58579 2 7C2 7.41421 2.33579 7.75 2.75 7.75L12.25 7.75C12.6642 7.75 13 7.41421 13 7C13 6.58579 12.6642 6.25 12.25 6.25L2.75 6.25ZM2.75 11.25C2.33579 11.25 2 11.5858 2 12C2 12.4142 2.33579 12.75 2.75 12.75L10.25 12.75C10.6642 12.75 11 12.4142 11 12C11 11.5858 10.6642 11.25 10.25 11.25H2.75ZM2 17C2 16.5858 2.33579 16.25 2.75 16.25H8.25C8.66421 16.25 9 16.5858 9 17C9 17.4142 8.66421 17.75 8.25 17.75H2.75C2.33579 17.75 2 17.4142 2 17Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 1.0 KiB

+11
View File
@@ -0,0 +1,11 @@
name: SortDown
category: Interface
sub_category: Filtering and sorting
keywords:
- sort
- sortering
- synkende
- descending
variant: Stroke
updated_at: 27.01.2025
created_at: 27.01.2025
+3
View File
@@ -0,0 +1,3 @@
<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="M18.0303 5.46967C17.8897 5.32902 17.6989 5.25 17.5 5.25C17.3011 5.25 17.1103 5.32902 16.9697 5.46967L13.4697 8.96967C13.1768 9.26256 13.1768 9.73744 13.4697 10.0303C13.7626 10.3232 14.2374 10.3232 14.5303 10.0303L16.75 7.81066V18C16.75 18.4142 17.0858 18.75 17.5 18.75C17.9142 18.75 18.25 18.4142 18.25 18V7.81066L20.4697 10.0303C20.7626 10.3232 21.2374 10.3232 21.5303 10.0303C21.8232 9.73744 21.8232 9.26256 21.5303 8.96967L18.0303 5.46967ZM2.75 17.75C2.33579 17.75 2 17.4142 2 17C2 16.5858 2.33579 16.25 2.75 16.25L12.25 16.25C12.6642 16.25 13 16.5858 13 17C13 17.4142 12.6642 17.75 12.25 17.75L2.75 17.75ZM2.75 12.75C2.33579 12.75 2 12.4142 2 12C2 11.5858 2.33579 11.25 2.75 11.25L10.25 11.25C10.6642 11.25 11 11.5858 11 12C11 12.4142 10.6642 12.75 10.25 12.75H2.75ZM2 7C2 7.41421 2.33579 7.75 2.75 7.75H8.25C8.66421 7.75 9 7.41421 9 7C9 6.58579 8.66421 6.25 8.25 6.25H2.75C2.33579 6.25 2 6.58579 2 7Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 1.1 KiB

+11
View File
@@ -0,0 +1,11 @@
name: SortUp
category: Interface
sub_category: Filtering and sorting
keywords:
- sort
- sortering
- stigende
- ascending
variant: Stroke
updated_at: 27.01.2025
created_at: 27.01.2025
@@ -0,0 +1,3 @@
<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="M4 4C4.41421 4 4.75 4.33579 4.75 4.75V11.25H6.75C7.16421 11.25 7.5 11.5858 7.5 12C7.5 12.4142 7.16421 12.75 6.75 12.75H4.75V19.25C4.75 19.6642 4.41421 20 4 20C3.58579 20 3.25 19.6642 3.25 19.25V4.75C3.25 4.33579 3.58579 4 4 4ZM9.25 11.25C8.83579 11.25 8.5 11.5858 8.5 12C8.5 12.4142 8.83579 12.75 9.25 12.75H10.75C11.1642 12.75 11.5 12.4142 11.5 12C11.5 11.5858 11.1642 11.25 10.75 11.25H9.25ZM12.5 12C12.5 11.5858 12.8358 11.25 13.25 11.25H14.75C15.1642 11.25 15.5 11.5858 15.5 12C15.5 12.4142 15.1642 12.75 14.75 12.75H13.25C12.8358 12.75 12.5 12.4142 12.5 12ZM17.25 11.25C16.8358 11.25 16.5 11.5858 16.5 12C16.5 12.4142 16.8358 12.75 17.25 12.75H19.25V19.25C19.25 19.6642 19.5858 20 20 20C20.4142 20 20.75 19.6642 20.75 19.25V4.75C20.75 4.33579 20.4142 4 20 4C19.5858 4 19.25 4.33579 19.25 4.75V11.25H17.25Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 981 B

@@ -0,0 +1,12 @@
name: SpaceHorizontal
category: Interface
sub_category: Design
keywords:
- avstand
- padding
- margin
- horisontal
- luft
variant: Stroke
updated_at: 14.02.2025
created_at: 14.02.2025
@@ -0,0 +1,3 @@
<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="M4.75 3.25C4.33579 3.25 4 3.58579 4 4C4 4.41421 4.33579 4.75 4.75 4.75H11.25V6.75C11.25 7.16421 11.5858 7.5 12 7.5C12.4142 7.5 12.75 7.16421 12.75 6.75V4.75H19.25C19.6642 4.75 20 4.41421 20 4C20 3.58579 19.6642 3.25 19.25 3.25H4.75ZM12 11.5C11.5858 11.5 11.25 11.1642 11.25 10.75V9.25C11.25 8.83579 11.5858 8.5 12 8.5C12.4142 8.5 12.75 8.83579 12.75 9.25V10.75C12.75 11.1642 12.4142 11.5 12 11.5ZM11.25 14.75C11.25 15.1642 11.5858 15.5 12 15.5C12.4142 15.5 12.75 15.1642 12.75 14.75V13.25C12.75 12.8358 12.4142 12.5 12 12.5C11.5858 12.5 11.25 12.8358 11.25 13.25V14.75ZM4.75 19.25H11.25V17.25C11.25 16.8358 11.5858 16.5 12 16.5C12.4142 16.5 12.75 16.8358 12.75 17.25V19.25H19.25C19.6642 19.25 20 19.5858 20 20C20 20.4142 19.6642 20.75 19.25 20.75H4.75C4.33579 20.75 4 20.4142 4 20C4 19.5858 4.33579 19.25 4.75 19.25Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 987 B

@@ -0,0 +1,12 @@
name: SpaceVertical
category: Interface
sub_category: Design
keywords:
- avstand
- padding
- margin
- vertikal
- luft
variant: Stroke
updated_at: 14.02.2025
created_at: 14.02.2025
+1 -1
View File
@@ -6,5 +6,5 @@ keywords:
- europa
- europe
variant: Stroke
updated_at: 08.07.2024
updated_at: 23.09.2024
created_at: 07.03.2023
+1 -1
View File
@@ -12,5 +12,5 @@ keywords:
- diagram
- analyse
variant: Stroke
updated_at: 05.07.2024
updated_at: 18.09.2024
created_at: 07.03.2023
Loaded 100 of 887 files, more files were not shown because too many files have changed in this diff. Show more