Compare commits

...
Author SHA1 Message Date
github-actions[bot]andgithub-actions[bot] 09828a4223 Version Packages (#3043)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-08-07 11:52:24 +02:00
Halvor Haugan e776c7c560 Endre changeset 2024-08-07 11:45:17 +02:00
Halvor Haugan 2dd266f0c4 ⬆️ Upgrade dependencies (minor) (#3070) 2024-08-07 09:13:14 +02:00
Ken daee394a71 feat: Hide sandbox-pages from robots (#3069) 2024-08-06 07:31:39 +02:00
KenandHalvor Haugan 8fd183cc90 feat: Updated font support and definition (#3044)
* feat: Updated font definitions

* memo: Changeset

* stories adjustments

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2024-08-05 09:34:07 +02:00
Halvor Haugan 0b1ac4f82c [aksel.nav.no] Support relative markdown links (#3059) 2024-08-05 09:32:46 +02:00
KenandHalvor Haugan ec79e25060 feat: Added stale-issue handling (#3029)
* feat: Added stale-issue handling

* Update .github/workflows/stale.yml

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

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-08-05 08:57:44 +02:00
Vegard HaugstvedtandHalvor Haugan 18d20aaa8e Combobox: Pressing Escape in while focusing a Combobox inside a Modal will close the Modal (#3053)
* If pressing Escape while FilteredOptions is open, Combobox should swallow the keydown event, so it does not close a Modal

* Added changeset

* Update @navikt/core/react/src/form/combobox/Input/Input.tsx

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

* Prevent default Escape from bubbling out of Combobox also when we have a value (which will be cleared).
Also co-located all the Escape-handling in keyDown. This also better mimics Select's native behaviour.

* Add clearInput to dependency array

* Legg til et Storybook-eksempel på Combobox i Modal, for manuell testing. La inn en tekst for å forklare caset.

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-08-02 13:30:22 +02:00
Halvor Haugan 72c8f3112a Combobox: Fixed aria-describedby and some types (#3065) 2024-08-02 12:51:25 +02:00
Vegard HaugstvedtandHalvor Haugan 6e63069d6b Combobox: Fix NullPointer error in single-select with allowNewValues (#3054)
* Prevent NullPointer when selecting a new/custom value in Combobox single-select with Enter (without selecting it in FilteredOptions)

* Update .changeset/cyan-carrots-return.md

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

* Expect AddNewButton to be visible

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-08-02 12:47:37 +02:00
Halvor Haugan 825d87af43 Combobox: Entering an already selected option and pressing enter no longer removes it (#3061) 2024-08-02 12:43:34 +02:00
9181d2ce75 Combobox: Implement free text search (#2974)
* Implement fuzzy search in combobox

* bug: ArrowUp now works as intended, stopped onChange from running each arrow-press

* memo: Added comment

* refactor: Removed extra state-update for searchterm

* Update @navikt/core/react/src/form/combobox/FilteredOptions/filtered-options-util.ts

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

* bug: Missed function export after refactor

* Add test for filtering in search

* Fix comments to better reflect the new code

* Change type for onChange to take in only value, not the entire event. This simplifies calling onChange programatically.

* Added changesets to reflect the changes in this branch

* KeyboardEvent.currentTarget does not have selectionStart property

* Update example

* Update storybook examples

* bug: Fixed undefined value sent to toggleOption callback

* revert: Removed test for what was corret interaction

* Add generic to enhance the event type for handleKeyDown

* Updated JSDoc

* Changed method signatures for onChange earlier, but forgot these two tests

* Add test for triggering onChange on every typed character in Combobox with autocomplete.

Currently fails on the last character, as it does not actually change the word in the input field.

* Move onChangeHandler from triggering onChange to onInput, as the former does not trigger when typing the last character of an autocompleted word.
onInput seems to work more consistently, but will test multiple use cases.

* Update aksel.nav.no/website/pages/eksempler/combobox/multi-select-controlled.tsx

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

* Update @navikt/core/react/src/form/combobox/Input/Input.tsx

* Update .changeset/wild-owls-tan.md

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

* Update @navikt/core/react/src/form/combobox/Input/Input.tsx

* updateInputValue is no longer neccessary

* Update @navikt/core/react/src/form/combobox/Input/Input.tsx

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-08-02 11:04:50 +02:00
Ken 22016ec90f prettier-plugin-tailwindcss update (#3046)
* feat: Updated tailwind prettier plugin

* refactor: Used prettier-plugin to remove extra whitespace in className
2024-07-10 10:44:58 +02:00
Ken f7d4c43f98 Added support for markdown links in intro lists (#3045)
* feat: Added support for markdown-links in intro-list

* memo: Added comments
2024-07-10 10:40:22 +02:00
Ken c67fd8bcda feat: Increased amount of articles shown in masonary 2024-07-09 14:27:42 +02:00
Julian Nymark 5efa09d00e 🐛 bump playroom version + set white bg (#3042) 2024-07-08 15:35:46 +02:00
Ken 3afc568a04 refactor: Better naming for modifiers check in Tabs and Togglegroup 2024-07-08 08:44:36 +02:00
Ken 2fe2586ac6 Respect meta-keys when navigating in Tabs, ToggleGroup (#3041)
* bug: RovingFocus now respects alt-keys

* memo: changeset
2024-07-08 08:41:11 +02:00
Ken 420c5c30d8 Primitives CSS update (#3028)
* refactor: Updated stack to only add CSS when used as prop

* refactor: Updated hgrid to only add CSS when used as prop
2024-07-04 14:55:25 +02:00
Ken 6cf141a8c6 Font sync (#3032)
* refactor: Created namespaced location for SourceSans3 fonts

* testing: Added story/chromatic for fonts

* refactor: Rename to use - instead of underline

* refactor: Remove SourceSans3 prefix
2024-07-01 11:04:54 +02:00
dcba0fffad Chromatic stories consolidation (#2996)
* Guidepanel

* Bleed

* Move 'options' object out of 'control' object

* Hide & Show

* Page

* h2 instead of Heading in Chromatic FN

* 🎨 update stories

* 🐛 disable the forcedColors parameter, seems buggy?

- it seems to be a chromatic error, or at least I'm not sure what's
  happening when this parameter is enabled. Some stories seem to
  sporadically get the forcedColors applied.

* Stack

* Combobox: put 'Test' before every test-story for clarity

* Combobox & move combobox tests to tests-file

* made combobox stories testable with Chromatic snapshots

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

* Alert rewrite

* Bleed add chromatic disable false

* FileUpload

* FormSummary

* HelpText

* Tooltip

* yarn update chromatic to 11.5.4

* Show: move parameters into Chromatic object

* memo: Removed duplicate heading

* bug: Removed extra argTypes

---------

Co-authored-by: Julian Nymark <julian.nymark@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2024-07-01 10:58:33 +02:00
Halvor Haugan da0a66fb62 Fix type for default export in stories (#3038) 2024-07-01 09:47:02 +02:00
Halvor Haugan 3a52359169 Improved example of top aligned Modal (#3039) 2024-07-01 09:40:01 +02:00
1b8d553c05 <VirtualFocus /> component (#2894)
* 🚧 WIP on some dropdown prop API

* ♻️ rename dropdown -> autocomplete

* 🚧 WIP towards Autocomplete (inspiration from Menu)

* 🚧 WIP Autocomplete

* 🚧 wip Autocomplete

* 🚧 wip Autocomplete

* 🚧 working idea for context (get & set autocomplete)

const thinger = () => {

* 🚧 pick property on Item

* 🚧 enrich story/example of Autocomplete

show how easy it is to add icons / do something more complicated inside
the autocomplete suggestions list alongside a <Search>

* 🚧 wip

- fairly nicely working list of virtually focusable items
- API interface kept simple (moved pick to Anchor though, single "exit
  point")
- item has focus function now, which triggers when it gets virtual
  focus, the API should not distinguish between virtual and real focus
  was the thinking here, it's more an implementation detail.

* 🚧 WIP new story for Autocomplete

- showcase dropdown search autocomplete

* Update @navikt/core/react/src/form/autocomplete/Autocomplete.tsx

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

* Update @navikt/core/react/src/form/autocomplete/Autocomplete.tsx

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

* 🔥 refactor class -> attr, remove css, use user provided <style> in story

* 🔥 remove originial ideas for a prop on <Search>

* ♻️ refactor + use mouseMove over mouseOver

* 🐛 reset virtualfocus on input change (within Anchor)

* ✨ add prop 'loop' for Autocomplete

* 🚚 Autocomplete -> VirtualFocus

* 🚧 WIP on some dropdown prop API

* ♻️ rename dropdown -> autocomplete

* 🚧 WIP towards Autocomplete (inspiration from Menu)

* 🚧 WIP Autocomplete

* 🚧 wip Autocomplete

* 🚧 wip Autocomplete

* 🚧 working idea for context (get & set autocomplete)

const thinger = () => {

* 🚧 pick property on Item

* 🚧 enrich story/example of Autocomplete

show how easy it is to add icons / do something more complicated inside
the autocomplete suggestions list alongside a <Search>

* 🚧 wip

- fairly nicely working list of virtually focusable items
- API interface kept simple (moved pick to Anchor though, single "exit
  point")
- item has focus function now, which triggers when it gets virtual
  focus, the API should not distinguish between virtual and real focus
  was the thinking here, it's more an implementation detail.

* 🚧 WIP new story for Autocomplete

- showcase dropdown search autocomplete

* 🔥 refactor class -> attr, remove css, use user provided <style> in story

* Update @navikt/core/react/src/form/autocomplete/Autocomplete.tsx

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

* Update @navikt/core/react/src/form/autocomplete/Autocomplete.tsx

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

* 🔥 remove originial ideas for a prop on <Search>

* ♻️ refactor + use mouseMove over mouseOver

* 🐛 reset virtualfocus on input change (within Anchor)

* ✨ add prop 'loop' for Autocomplete

* 🚚 Autocomplete -> VirtualFocus

* 🚚 Autocomplete -> VirtualFocus

* 🔥 remove unused CSS

* 🚧 add onActive, delete unused code

* 🚧 rename CSS classes

* ♻️ simplify <VirtualFocus> impl

- use the descendants API > grabbing the DOM nodes...

* 🔥 remove the aria-activedescendant responsibility from VirtualFocus

* Update aksel.nav.no/website/sanity/config.ts

* 🔥 remove comments that no longer apply

* 🔥 remove biome.json changes from PR

* ♻️ various PR changes

- homogenize the API (so both anchor and item have the sameish props,
  onActive, pick...)
- use useId() so multiple <VirtualFocus> on the same page get unique ids

* 🚧 + ♻️ testing changes in VO

- it's not great, weird behaviour on readouts of Items... (FF completely
  broken, sometimes reads "rgla" from "hourglass", other times nothing,
  Chrome is a little better)
- is this a decent API at all? is it overcomplicated?

* 🏷️ type itemRole

* 🔥 remove empty file

* ♻️ pr comments

- renaming to better match the rest of DS
- remove itemRole (just use role)
- eslint ignore

* ⚡ do not go via descendant API if self

* 🎨 add forwardRef & ...rest to Content

* 🐛 fix lying prop doc comment, remove unused CSS class

* ♻️ use <Slot /> (hoistmerge child)

* 💄 fix broken CSS (class was removed)

* 📝 update jsdoc

* 🚚 move role to Anchor (from VirtualFocus wrapper)

* 🎨 remove filtering from broken example

* 🐛 Anchor should trigger virtualfocused.onSelect()

* 🐛 use react v17 shimmed useId()

* Update @navikt/core/react/src/form/virtualfocus/VirtualFocus.tsx

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

* 🚧 import

* 🎨 improve story

* 🐛 do not let consumer overwrite certain VirtualBox implementation

* 🎨 update story

* 🚚 move virtualfocus to utils

* 🎨 update to latest RovingFocus.tsx, tweaks to stories

* Update @navikt/core/react/src/util/virtualfocus/VirtualFocus.tsx

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

* 🎨 improve docs (jsdoc), add Simple story

* 🚚 split up monster component into /parts

* 🐛 pull out dependency to remove cyclic dependency

* 🔥 RovingFocus.tsx

* 🐛 do not ignore external prop

* 🎨 simplify function calls + reorder for consistency

* 🔥 remove unused code

* 🎨 disable chromatic for internal tool stories

* 🏷️ Omit<> props that will get ignored/overridden

* 🏷️ Omit<> props that will get ignored/overridden

* 🏷️ use satisfies

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-06-28 15:56:54 +02:00
github-actions[bot]andgithub-actions[bot] 1aea10573c Version Packages (#3037)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-06-28 12:42:02 +02:00
Halvor Haugan 7c644cd9b1 Modal: New prop for aligning modal to top (#3033) 2024-06-27 13:58:45 +02:00
Halvor Haugan fe93f6450b Adjust examples and JSDOC for Alert (#3035) 2024-06-27 13:54:46 +02:00
github-actions[bot]andgithub-actions[bot] 86e52df680 Version Packages (#3013)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-06-25 15:39:57 +02:00
Halvor Haugan ff8072e352 Icons: FigureCombination icon adjusted (#3031) 2024-06-25 12:32:37 +02:00
Julian Nymark 5b033ab218 ✨ start formatting with biome too (#2991) 2024-06-25 12:27:35 +02:00
Halvor Haugan 6276b676d6 [aksel.nav.no] Validate unique title in exampletext_block (#3024) 2024-06-25 09:52:07 +02:00
Halvor Haugan c2ffd466af Update link in form templates (#3022) 2024-06-24 15:03:36 +02:00
Andreas Nordahl d6d6fb06b1 start align link items (#3026) 2024-06-24 13:05:47 +02:00
Halvor Haugan e829753847 Example of Alert with buttons (#3019) 2024-06-24 13:01:27 +02:00
Ken f1d8e9c4d3 feat: New icon ChildHairEyes (#3020) 2024-06-24 11:56:18 +02:00
Halvor Haugan 4d0f8067b7 Adjust examples of Chips 2024-06-24 10:00:34 +02:00
Halvor Haugan 4afe90122b Add Chromatic modes on some templates (#3023) 2024-06-24 09:23:49 +02:00
Halvor HauganandKen 350dfd3477 Adjust buttons in form summary page template (#2999)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-06-20 14:00:18 +02:00
Ken 9a74fecbfb fire: Removed old testing-templates (#3011) 2024-06-20 13:57:33 +02:00
Ken 7ec73f2008 [ToggleGroup] Selecting already selected value avoids sending extra onChange (#3012)
* feat: Selecting already selected value avoids sending extra onChange-event

* Update @navikt/core/react/src/toggle-group/ToggleGroup.stories.tsx
2024-06-20 13:55:34 +02:00
Halvor Haugan 952655ed63 Refactor templates (#3017) 2024-06-20 13:51:15 +02:00
Halvor Haugan 6af8cc526f Adjust examples of Chips (#3016) 2024-06-20 13:49:18 +02:00
Halvor Haugan 23ea3232fa Alert: Misc. adjustments (#3007) 2024-06-20 13:43:09 +02:00
b38789b98d Implement BasePrimitive for Box, Stack and HGrid (#3003)
* feat: Implemented baseprimitive in box

* refactor: segmented box-features into classes

* feat: Implemented baseprimitive margin css

* refactor: Correctly allow box with no children when no asChild is used

* refactor: Implement BasePrimitive on Stack/HGrid, addef as-prop for hgrid

* typo: Rename constant to a more 'content' nameing convention

* bug: Fix slot-import

* 🚧 --__ac-r-m.*

* bug: Fixed nesting of className

* feat: BasePrimitive now supports auto

* memo: Changeset

* bug: Added margin auto support for marginBlock

* refactor: Redo naming of base props

* bug: Typo

* bug: Wrong css-token reference for pi and pb

* Update @navikt/core/react/src/layout/base/BasePrimitive.tsx

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

* Update @navikt/core/react/src/layout/base/BasePrimitive.tsx

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

* bug: Removed static padding representation

* Update @navikt/core/react/src/layout/base/BasePrimitive.tsx

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

* refactor: Renamed AsChildProps used in Primitives

* bug: Re-added fallback to padding/margin when using a subset of breakpoints for inline/block

* Update @navikt/core/react/src/layout/base/BasePrimitive.stories.tsx

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

* memo: JSDoc

* refactor: Removed undefined as-props from docgen

---------

Co-authored-by: Julian Nymark <julian.nymark@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-06-19 11:17:08 +02:00
Halvor Haugan cb304d0bb6 Add example of horizontal radios (#3009) 2024-06-19 09:33:14 +02:00
github-actions[bot]andgithub-actions[bot] 1dc3e43c6f Version Packages (#2981)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-06-19 09:16:54 +02:00
Halvor Haugan 50afa6f535 Adjust exampels of Tag (#3006) 2024-06-14 14:08:55 +02:00
Ken 5753acd5c1 refactor: Fixed no-double-equals biome (#3002) 2024-06-14 11:02:52 +02:00
KenandHalvor Haugan ff1e8b1140 refactor: Fixed no misleading character class biome (#3001)
* refactor: Fixed no misleading character class biome

* bug: Add lint ignore rule to support nextjs

* Update aksel.nav.no/website/sanity/schema/util.ts

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

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-06-14 10:49:05 +02:00
Ken 60ad18804a feat: Added version-tag to tokens (#2998)
* feat: Added version-tag to built tokens-lib

* feat: Avoid duplicate version-tags

* refactor: Changed --aksel -> -a when adding version-tag
2024-06-13 11:27:57 +02:00
Ken dda89c8a0d bug: BasePrimitive imported 'Slot' from wrong dir 2024-06-13 10:04:43 +02:00
Ken 623fbba362 🚚 Moved Slot into separate directory (#2959)
* refactor: Moved slot to single folder

* refactor: Updated use of Slot in system

* refactor: Rename SlotElement -> SlottedElement

* refactor: Removed slottedElement

Because of typing issues when using anything other than 'div', this added more complexity than needed at this stage
2024-06-13 09:54:33 +02:00
KenandHalvor Haugan 221f7c5d61 [Primitives] BasePrimitive (#2842)
* 🎉 Boilerplate for BasePrimitive

* feat: Lagt til height og width attrb

* test: Chromatic snapshot av height & width api

* feat: Position API

* feat: Overflow

* feat: Flex

* memo: Prop-comments

* refactor: children now React.ReactElement in BasePrimtive

* bug: removed comment strangler

* Update @navikt/core/react/src/layout/base/BasePrimitive.stories.tsx

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

* memo: Updated stories

* refactor: remove use of backtick

* Update @navikt/core/react/src/layout/base/BasePrimitive.tsx

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

* Update @navikt/core/react/src/layout/base/BasePrimitive.tsx

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

* Update @navikt/core/react/src/layout/base/BasePrimitive.tsx

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

* Update @navikt/core/react/src/layout/base/BasePrimitive.tsx

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

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-06-12 13:57:03 +02:00
Ken 82f9c30936 [Aksel.nav.no] Fixed clipping of focus-border in toc (#3000)
* bug: Fixed clipping of focus-border

* refactor: removed addition of padding-block in sidebar
2024-06-12 13:51:11 +02:00
Halvor HauganandKen e35ddd5282 [aksel.nav.no] Add possibility to import code in examples (#2970)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-06-11 12:47:00 +02:00
KenandHalvor Haugan 5b70a84674 feature: ToggleGroup icon and label-props replacing children. (#2929)
* refactor: ToggleGroup now supports label and icon-prop

* memo: changeset

* bug: Fixed render of default story

* Update @navikt/core/react/src/toggle-group/parts/ToggleItem.tsx

* Update @navikt/core/react/src/toggle-group/parts/ToggleItem.tsx

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

* Update .changeset/tiny-lions-stare.md

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

* doc: Added separate stories for group and item-labels in togglegroup

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-06-11 11:42:13 +02:00
KenandHalvor Haugan ce9da16147 update: Migrated to v9 of next-sanity (#2923)
* feat: API-routes for entering draftmode in nextjs

* feat: Grunlleggende now uses the new livequery-API

* feat: New preview for frontpage

* feat: New preview for standalone-pages

* feat: New preview for blogg

* feat: New preview for prinsipper

* feat: New preview for monster-maler

* feat: New preview for komponenter

* feat: New preview for god-praksis

* fire: Removed code from different PR

* refactor: default export syntax cleanup

* bug: Fixed colorScheme handling for studio

* bug: Added back global styling changes

* types: Better typed query-params for PagePreview

* refactor: typo with KomponentFrontpage in god-praksis

* refactor: Moved client definition out from livequeryprovider -> sanity client config

* Update aksel.nav.no/website/pages/komponenter/[...slug].tsx

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

* refactor: Removed select + valid from groq in prinsipp

* refactor: __props -> previewProps for more declarative naming

* refactor: Remove use of memo

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-06-11 11:41:12 +02:00
Halvor Haugan bed7db15c4 Fix error message when starting Storybook (#2994) 2024-06-11 09:36:29 +02:00
Halvor Haugan feff5ff5e4 [aksel.nav.no] Convert client.server.js to ts (#2993) 2024-06-11 09:15:48 +02:00
Halvor Haugan 8a338851b4 [aksel.nav.no] Fix React warning in Snippet (#2992) 2024-06-10 09:32:33 +02:00
Halvor Haugan a7bd3894ca Split BackgroundToken into BackgroundColorToken and SurfaceColorToken (#2990) 2024-06-07 15:11:14 +02:00
Ken 1b927d6396 feat: Synced button icon size with CopyButton (#2984)
* feat: Synced button icon size with copybutton

* bug: Added min-width to button small
2024-06-07 12:23:13 +02:00
Ken 96ed611e15 List spacing (#2979)
* WIP: List spacing

* test: Added spacing-story test for list

* feat: Updated List with new spacing and Typo-elemenet

* refactor: Changed to spacing-2

* refactor: Updated nest list spacing

* bug: Reverted change in gap between icon and text

* bug: Fixed marker height

* Update .changeset/strong-bulldogs-jam.md
2024-06-07 12:00:19 +02:00
KenandHalvor Haugan a23621d0b0 refactor: Fixed noShadowRestrictedNames lint-errors (#2982)
* refactor: Fixed noShadowRestrictedNames lint-errors

* bug: Fieldset error-story broke

* Update @navikt/core/react/src/form/confirmation-panel/confirmation-panel.stories.tsx

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

* Update @navikt/core/react/src/form/fieldset/fieldset.stories.tsx

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

* Update @navikt/core/react/src/form/fieldset/fieldset.stories.tsx

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

* Update @navikt/core/react/src/form/textfield/text-field.stories.tsx

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

* Update @navikt/core/react/src/form/select/select.stories.tsx

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

* refactor: synced new story-names

* refactor: Fixed noAssignInExpressions lint-errors (#2983)

* refactor: Fixed noAssignInExpressions lint-errors

* Update @navikt/core/react/src/util/i18n/get.ts

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

* refactor: added dialog-polyfill to biome ignorelist

---------

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

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-06-07 11:58:52 +02:00
Halvor HauganandKen 395eea108f Improved JSDOC for background and borderColor in Box and Page (#2988)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-06-07 11:32:18 +02:00
Ken 2e4351cced refactor: Removed surface-subtle from background-prop (#2987) 2024-06-07 11:27:53 +02:00
Ken f1707fe057 feat: Added prop for hidden heading to allow screen-readers to navigate to pagination (#2976)
* bug: Omit page-prop from PaginationItem and add data-attrb

* feat: Added prop for hidden heading to allow screen-readers to navigate to pagination

* refactor: Revert change of page-attrb removal since it could be breaking

* refactor: Fixed GH PR-comments

* refactor: Changed heading -> srHeading

* refactor: Modernized pagination-story

* refactor: Change to aria-labelledby, update stories
2024-06-07 11:26:21 +02:00
Ken ba76356178 Workflow update to node 20 (#2980)
* refactor: use github checkout v4

* refactor: use setup-node v4, default node 20

* workflow: Updated workflows to use node 20

* bug: removal of node-version in setup-node broke tests

* refactor: Revert removal of node-version in setup node for all workflows

* memo: Fixed typo in workflow-name
2024-06-06 09:37:21 +02:00
Ken 4c7de30732 memo: Edit broken docs-link in changelog 2024-06-05 14:39:18 +02:00
Ken 99ea2fa022 memo: Edit broken docs-link 2024-06-05 14:38:10 +02:00
Ken d5818a5e60 design: Copybutton-icon is now 20px for small og xsmall sizes (#2977)
* design: Copybutton-icon is now 20px for small og xsmall sizes

* bug: Replace aspect-ratio for min height/width with regular min-width and min-height attrb
2024-06-05 13:50:41 +02:00
KenandHalvor Haugan d0debc10ab feat: Added description-prop for fileupload item (#2975)
* feat: Added description-prop for fileupload item

* Update @navikt/core/react/src/form/file-upload/parts/item/Item.tsx

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

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-06-05 12:09:26 +02:00
KenandHalvor Haugan 5b011192f7 feat: Added option to use quotes in sanity editor (#2962)
* feat: Added option to use quotes i sanity editor

* Update aksel.nav.no/website/sanity/schema/objects/shared/riktekst.tsx

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

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-06-05 12:07:21 +02:00
github-actions[bot]andgithub-actions[bot] 754d151a7f Version Packages (#2972)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-06-05 11:32:10 +02:00
Ken 677170a767 update: Updated svgr cli to v8 (#2930) 2024-06-05 11:19:22 +02:00
Ken 2cd6b1a391 bug: Icon-package missed src-dir referenced in sourcemap (#2978) 2024-06-05 10:09:53 +02:00
Ken 5bcb870b16 bug: Etterlevelse-link in footer had wrong ingress 2024-06-04 11:29:49 +02:00
Halvor Haugan 704e4f6c77 Adjust examples of Pagination (#2973) 2024-06-04 09:57:27 +02:00
Halvor Haugan 334627061a 💄 Remove bottom margin on last item in Stepper and adjust FormProgress accordingly (#2971) 2024-06-03 14:32:05 +02:00
github-actions[bot]andgithub-actions[bot] c171a73d2f Version Packages (#2969)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-05-31 14:14:07 +02:00
Lars Eirik Korsgaard Hansen 1cab3698b1 Modal small (#2909) 2024-05-31 14:06:27 +02:00
Halvor Haugan b9fb86cc27 Real examples of form summary pages (#2967) 2024-05-31 12:20:46 +02:00
github-actions[bot]andgithub-actions[bot] ceaedc4505 Version Packages (#2933)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-05-31 08:43:12 +02:00
Vegard HaugstvedtandHalvor Haugan 394cc94db7 Fixed Combobox small sizing (#2801)
* Remove extra vertical padding and fixed height for combobox input, to make the small variant the same size as TextField and so on.

* no message

* More robust combobox styling - using tokens and proper padding instead of min-height for sizing

* More robust combobox styling using tokens

* Remove gap between options in FilteredOptions

* Update @navikt/core/css/form/combobox.css

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

* Combine selectors for svg sizes in combobox

Removed pointer-events: none, because I couldn't find a use-case for it. The reason vanished when we squashed commits.

* Fix visual regression, where the first option was partially overlapped by the "max selected" message

* Revert yarn lock to match main

* A general selector for combobox SVGs had an effect on chips as well, so we need a selector for each SVG we want to set size for.

* Properly align items in FilteredOptions. Fixes issue with out-of-alignment checkmarks.

* Fix incorrect class selector

* This doesn't seem to do anything

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-05-29 11:32:24 +02:00
Halvor Haugan af171a3ffc New template: form summary page (#2958) 2024-05-29 09:23:13 +02:00
Halvor Haugan 868170ef38 List: Adjusted examples and JSDOC (#2961) 2024-05-28 14:32:24 +02:00
Ken 01d2ee85d0 move: Moved dismissablelayer into overlays dir from overlay dir (#2960) 2024-05-28 14:14:53 +02:00
KenandHalvor Haugan 50d594787c Disallow use of implicit any type on variable declarations. (#2943)
* feat: Added biome again

* bug: Fixes Disallow use of implicit any type on variable declarations.

* refactor: Import as type

* refactor: Reverted change to typed for-loops in dialog-polyfill

* refactor: Reverted change to typed for-loops in dialog-polyfill

* Update @navikt/core/react/src/modal/dialog-polyfill.ts

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

* refactor: biome-ignored inline-typing for-loop

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-05-27 14:05:07 +02:00
Ken 8d0f7ae4b5 Use Array.isArray() instead of instanceof Array. (#2942)
* feat: Added biome again

* bug: Fixes Use Array.isArray() instead of instanceof Array.
2024-05-27 13:58:52 +02:00
Ken f23fd9aa83 Removed useless if/else (#2939)
* feat: Added biome again

* feat: Fixed noUselessElse

* feat: Added original eslint-rule
2024-05-27 13:54:39 +02:00
Ken 1a18bbedbb [Sanity] Fixed view for "Mine utkast" and creation of new undertema (#2957)
* bug: Mine utkast did not correctly handle letter casing for email

* bug: Declaring schemaType after initialTemplates removes initialTemplates
2024-05-27 13:29:28 +02:00
Halvor Haugan b7ddb9e557 [aksel.nav.no] Add ShowMore to ExampletextBlock (#2950) 2024-05-27 11:32:54 +02:00
Ken 1f3df8ad93 feat: New icons for geometric shapes (#2927) 2024-05-27 11:16:49 +02:00
Halvor Haugan 7c339c6dc6 🐛 Modal: Fix issue where polyfill-classname was not applied when using SSR (Next.js) (#2954) 2024-05-27 11:15:11 +02:00
Ken 61de6853e3 ⚡ Performance improvements when using spread in reduce (#2937)
* refactor: Fixed type-errors

* refactor: Optimized omit

* refactor: Optimize search-grouping on website

* refactor: Optimize option grouping in combobox

* refactor: Optimize reduce-functions in systems
2024-05-27 11:14:29 +02:00
Ken f05615d373 Use Number.isNaN instead of global isNaN. (#2941)
* feat: Added biome again

* bug: Fixes isNaN is unsafe. It attempts a type coercion. Use Number.isNaN instead.
2024-05-27 09:52:02 +02:00
Ken 34cdf015ff [Website] List-component in place of custom ul>li (#2928)
* feat: Uses List-component internally in website

* fire: Removed old CSS for list-styling

* fire: Undid change to example made under testing
2024-05-27 08:56:20 +02:00
Halvor Haugan f48178de22 Adjust docs for Chat and some primitives (#2948) 2024-05-24 11:12:51 +02:00
Halvor Haugan fcfbad9b90 Use <Link> instead of <a> in Accordion examples (#2952) 2024-05-24 11:07:45 +02:00
Ken dfef7f5c76 Use Number.isFinite instead of global isFinite. (#2940)
* feat: Added biome again

* bug: Fixed isFinite is unsafe. It attempts a type coercion. Use Number.isFinite instead
2024-05-23 09:43:19 +02:00
Vegard Haugstvedt 5a60ac9ae1 Form intropage adjustments (#2949)
* Remove sandbox from intropage templates. It doesn't work, because of the URI length.

* Remove form id from the concrete examples

* Rename default template from "Introside" to "Standard"

* VStack is no longer necessary when we remove the form id

* Merged the real examples into one folder, so they can be added as one block (using chips) instead of after each other
2024-05-22 16:09:43 +02:00
Halvor Haugan 2e233e6a3f ♻️ Refactor form intro template (#2946) 2024-05-22 15:48:43 +02:00
Halvor Haugan c2d010e81d Include templates in ds storybook (#2947) 2024-05-22 15:34:13 +02:00
Ken 70dc5f18d1 refactor: Optimized omit (#2936) 2024-05-22 14:57:32 +02:00
Ken 0b79be7db1 refactor: Updated 30% of examples to primitives (#2932) 2024-05-22 14:35:23 +02:00
62dd6a321c Feature/template intropage (#2876)
* Init intropage. Just with header and guidepanel in first commit. The rest will follow.

Needs to move icon in header outside main column.

* Add "what can i apply to here" content, as well as prepare the page for more of these sections.

* Add "this is how you apply"-section

* Add confirmation checkbox and "start application" button

* Add "extra information" accordion

* Add language selector and switch to simple decorator

* Correct icon and placement for "start application" button

* Proper pictogram in FormHeader and bleed outside of the main column.

* Make Intropage header responsive, moving pictogram to the right on mobile/on the left on desktop

* Add IntroPage story to regular Storybook, so it is exposed through Chromatic

* Temporarily add ApplicationPictogram in same folder as template to make it available for demo tomorrow. Needs to find another place.

* Simplify/extract code for decorator

* updated texts according to Figma

* Center align title and form id with pictogram, to better support not showing the ID

* Update intro page standard template

* Update Stack direction type to support reverse order

* Add examples for alert and alternative applications. Need to clean up some TS-error later.

* Update Aksel examples for intropage

* Rename folder for intropage examples

* Use BodyLong instead of BodyShort

* Add specific examples for intropage

* Style fixes: add gutters to content (like header) and make sure a longer title does not take space from pictogram

* Update aksel.nav.no/website/pages/templates/soknad-introside/intro-med-alternativ-soknad.tsx

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

* Hide pictogram on the smallest screens, and keep it on the right side up until "lg"  screens (compared to "md" before)

* Correct heading level

* All the content should be inside main

* Replace <Box> without any props with regular div's

* Replace "flex: 1" from heading-stack in every layout with flexShrink: 0 on only the pictogram

* Hide SVG's from screen readers

* Missing <Show>-element

* Keep pictogram on the right until the screen is at least of size "lg"

* Change the data-aksel-template attribute to allow proper tracking of intropage template use

* Changed texts after feedback from Sjur

* Legg til meta.json for changelog i form-introside-mappen

* Use standard padding between content and footer, but increase it to spacing-16 (4 rem) to reflect Figma and the documentation

* Remove template from Chromatic. May add templates to Chromatic-build later, but that should be done by watching templates on Aksel-webpage.

* Remove unused util for decorator

* Inline decorator-kode in all form intropage templates. Otherwise, they won't be included in the example code.

* Inline application pictogram in form intropage templates, so it can be copied. Maybe we should extract the form header as a component in Aksel?

* Remove spacing from BodyLong inside of Accordion

* Update aksel.nav.no/website/pages/templates/soknad-introside/intro-med-alternativ-soknad.tsx

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

* Removed duplicate word

* Added changeset for ds-react and ds-css changes

* Update aksel.nav.no/website/pages/templates/soknad-introside-alderspensjon/soknad-introside-alderspensjon.tsx

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

* Fix alignment and placement in form header

* Move template tracking id further into the code, so it is not excluded by accident

* Title and other props are unnecessary on ApplicationPictogram, since it has aria-hidden set

* Remove title from single examples (only in folder), since it is not used, and use 0-index on all form intropage examples

* Align pictogram to the top of the title

* Reduce gap between sections from 3rem to 2rem

* Align pictogram to the top of the title for the rest of the templates

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-05-21 16:02:13 +02:00
Ken 88c26d2c70 bug: Fixed All exports are only types and should thus use export type 2024-05-16 18:29:50 +02:00
Ken 201fd75c0c bug: Fixed void is not valid as a constituent in a union type 2024-05-16 18:28:09 +02:00
Ken cbc512832c bug: ExampletextBlock used wrong bg-color 2024-05-16 12:54:13 +02:00
Ken 9d815adab2 bug: ExampletextBlock had no background on God-praksis pages 2024-05-16 12:40:41 +02:00
Ken 1800b2b34d feat: GodPraksis can now use ExampletextBlock on all articles 2024-05-16 09:37:47 +02:00
Ken 93623ce355 bug: DismissableLayer broke when disabling disableOutsidePointerEvents (#2925)
* bug: DismissableLayer broke when disabling outsidePointerEvents

* refactor: removed old code

* bug: New useEffect implementation ignored enabled-flag

* feat: Removed unsafe_index prop used in stepper and replaced it with context

* memo: Added changeset

* Revert "memo: Added changeset"

This reverts commit 03d7dc6bb8.

* Revert "feat: Removed unsafe_index prop used in stepper and replaced it with context"

This reverts commit 14c316f4a3.

* bug: Pointer-state were not corretly updated

* test: Demo setup in storybook

* bug: Fixed body-styles handling and pointerEvents on element

* refactor: Simplified expression for pointerEvents

* refactor: Removed extra state for pointer-state
2024-05-15 17:35:44 +02:00
Ken aed321728f feat: Removed unsafe_index prop used in stepper.step (#2926)
* feat: Removed unsafe_index prop used in stepper and replaced it with context

* memo: Better errormessaging

* refactor: Resolves PR-comments
2024-05-15 16:31:13 +02:00
Ken 8003fd2222 bug: templatesKategorier used wrong value for soknadsdialog 2024-05-15 15:40:31 +02:00
Ken 32c8bab6f9 update: Updated categories for new template-structure (#2931) 2024-05-15 15:30:18 +02:00
KenandHalvor Haugan 7527cbe07f sanity: removed scheduling (#2924)
* feat: Removed scheduled publishing from sanity, fixed type-errors

* bug: Wrong type for devOnly callback

* bug: removed sideeffect added when developing

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

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

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-05-15 11:33:32 +02:00
Ken 57a6a18dbe feat: API-routes for entering draftmode in nextjs (#2922) 2024-05-15 09:37:13 +02:00
github-actions[bot]andgithub-actions[bot] 7b691b6cd0 Version Packages (#2916)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-05-14 15:29:55 +02:00
Ken 1b048ba5c3 refactor: removed unsplash plugin from sanity media input (#2921) 2024-05-14 11:31:45 +02:00
Ken e92c897c01 update: New sanity versions (#2918)
* update: New sanity versions

* update: Bump canary-release of devDeps for nextjs

* sync: yarn lock
2024-05-14 10:15:52 +02:00
Halvor Haugan a1041d13cd Stepper.Step: Set aria-current to "step" instead of true (#2920) 2024-05-14 10:14:35 +02:00
Ken 241dd79ecb Block to show template/standard-texts on template-pages (#2913)
* feat: Standard highlighting komponent

* feat: Immplementert StandardHighlight i CMS

* refactor: Rename StandardHighlight -> ExampletextBlock

* memo: Riktigere initialValue
2024-05-14 09:40:59 +02:00
Halvor Haugan 6aaf56bc10 Adjust examples FormProgress 2024-05-13 15:54:23 +02:00
Ken 7becf3e4cf Simplified HGrid CSS-nesting (#2917)
* test: Setup testing env for HGrid bug

* refactor: Forenklet HGrid-css

* memo: Changeset
2024-05-13 14:39:41 +02:00
Ken a358d222b5 refactor: Removed extra w-fit left after refactor 2024-05-13 13:53:13 +02:00
Ken 24d4d48c87 Link to GH-discussions from template-pages (#2914)
* feat: New gh-discussions field for template-articles

* feat: Link to gh-discussions on template-pages

* refactor: removed extra display grid in wrapper

* feat: Added story for GHPages suggeestionBlock
2024-05-13 12:27:49 +02:00
Ken 2d0c2c6567 deps: Updated Nextjs and logging depdendencies (#2915) 2024-05-13 11:36:32 +02:00
Halvor Haugan bd482c5d3e Ny komponent FormProgress (#2855) 2024-05-13 10:30:28 +02:00
github-actions[bot]andgithub-actions[bot] c8c3fc4ec5 Version Packages (#2896)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-05-10 14:37:43 +02:00
Andreas Nordahl 834ba0cbae Decouple read-more icon hover offset and rotation style (#2912) 2024-05-10 13:53:03 +02:00
KenandHalvor Haugan be653cc67a [Aksel.nav.no] Mindre justeringer på Søk (#2899)
* refactor: Fjernet tags fra søk

* design: Oppdatert padding for søk og la tilbake border på focus

* refactor: Fjernet lenketags fra komponent-artikler

* design: Oppdatert fokusmarkering og hover for search-hit

* bug: Mobiltilpasset søk-headings

* bug: e2e-tester fant ikke søkefelt

* bug: Seksjoner i søk har nå riktig heading-level h2

* Update aksel.nav.no/website/components/website-modules/search/parts/Hit.tsx

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

* refactor: Quotes i søk får samme farge

* Update aksel.nav.no/website/components/website-modules/search/parts/Results.tsx

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

* refactor: Unødvendig filtrering basert på dokumenttype er fjernet

* bug: Bruker section-element for gruppering av søkeresultater

* refactor: Unødvendig filtrering basert på dokumenttype er fjernet

* bug: Border forsvant ved pointerdown

* refactor: Hides image-frame from serch-hit

* Revert "refactor: Hides image-frame from serch-hit"

This reverts commit 764c82ebdb.

* refactor: Truncate title

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-05-08 10:08:57 +02:00
Halvor Haugan 054835d1dd 🆙 Oppgradert deps (#2908) 2024-05-08 09:53:14 +02:00
Ken 7f99d407c0 Combobox refactor: Flyttet Input controls ut i egen komponent (#2900)
* refactor: Flyttet Input controls ut i egen komponent

* refactor: Inlinet clearbutton implementasjon, fikset typer

* 🚚 Flyttet ToggleListButton til input-mappe

* Combobox refactor: Bruker intern `createContext` for context-creation i Combobox (#2902)

* refactor: Bruker egen creactContext for selectedOptionsContext

* refactor: Bruker egen creactContext for filteredOptionsContext

* refactor: Bruker egen creactContext for InputContext

* refactor: Bruker egen creactContext for selectedOptionsContext

* refactor: Rename InputContext hook

* 🚚 Flyttet testfiler inn i egen mappe (#2905)
2024-05-08 09:05:02 +02:00
Ken 1202e0a6f7 bug: InitialValues for god-praksis struktur i admin ga ikke riktige tilganger 2024-05-07 18:22:56 +02:00
0c06fa12d0 Progressbar tweaks (etter docs-møtet) (#2892)
Co-authored-by: Julian Nymark <julian.nymark@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-05-07 14:36:11 +02:00
Lars Eirik Korsgaard Hansen 4797ccae9d Combobox: Remove 'Ingen søketreff' when custom options allowed (#2895) 2024-05-07 11:41:01 +02:00
Ken ac06d882a7 refactor: Forenklet mergeRefs i floating-util 2024-05-07 09:57:20 +02:00
Ken 8f5c956bad Floating utility (#2872)
* ✨ Initial Popper wrapper

* ✨ Floating popper element

* 🏷️ Rename popper -> floating

* 🐛 Fikset imports

* ♻️ FLoating-fil splittet opp i moduler

* 🎨 Satt opp exports og story

* 🎨 Arrow er nå del av content

* 🐛 display block på arrow

* 🎉 Egen Portal-komponent

* 🎨 Portal og Overlay exportert i root

* ♻️ Tooltip bruker egen Portal

* 📝 Changeset

* 🔀 Merge Portal

* 📝 Story with portal

* 📝 Props story

* 🚚 Temp rename

* 🚚 Temp rename

* 🎨 La til Slot på Floating.Anchor

* ✨ Fungerende nesting av dismissable items

* ✨ Fungerende outsidepointerclick handler

* 🚚 Ryddet opp i struktur

* ✨ bedre event-handling

* 🎉 Popover bruker dismissableLayer

* 🔥 Fjernet console.logs

* ♻️ Extender nå ikke htmldivelement

* 📝 Commented on dimsissablelayer

* 📝 Kommentarer

* 🎨 Disable pointer-events on body

* 🎨 Setup content

* 🎨 Fungerende popover med story

* 🎨 useDescendant-API kan bruke uten context-error på nesting

* 🐛 Fikset tilfeller der oppdatering av descendant-options ikke ble reflektert i descendants-map

* 🐛 Satte enabled til optional

* bug: import av Portal brakk stories for Popover og Floating

* bug: DescenadantContext er nå riktig typet som undefined

* label: scopet navn for bruk av descendant-provider i dismissablelayer

* memo: Bedre kommentarer

* feat: Sender ikke callbacks hvis layer er disabled

* memo: Formatering og kommentarer

* memo: Kommentarer

* feat: Støtter forwardRef

* merge: Merge branch with main

* 🔥 Fjernet ny popover implementasjon

* 🔥 Fjernet mergeconflict fra main i tabs

* 🔥 Fjernet mergeconflict fra main i tabs

* refactor: Cleaniup codestructure

* refactor: Fjernet unødvendige props

* refactor: Synket dependencies og changeset
2024-05-07 09:56:06 +02:00
Ken 6b40a0ddd8 refactor: Oppdatert stories til chromatic format
refactor: Oppdatert HGrid stories til chromatic format

refactor: Oppdatert InternalHeader stories til chromatic format

refactor: Oppdatert skeleton stories til chromatic format

refactor: Oppdatert box stories til chromatic format

refactor: Oppdatert loader stories til chromatic format

refactor: Oppdatert list stories til chromatic format

refactor: Oppdatert tag stories til chromatic format
2024-05-06 16:28:12 +02:00
Halvor Haugan 60a6cba329 Justering av stories på Chat (#2903) 2024-05-06 14:24:23 +02:00
Ken 7fd62f3b79 logging: Fjernet logging av query i søk (#2897) 2024-05-06 11:50:02 +02:00
Ken 0944bbc256 DismissableLayer-API (#2814)
* ✨ Fungerende nesting av dismissable items

* ✨ Fungerende outsidepointerclick handler

* 🚚 Ryddet opp i struktur

* ✨ bedre event-handling

* 🎉 Popover bruker dismissableLayer

* 🔥 Fjernet console.logs

* ♻️ Extender nå ikke htmldivelement

* 📝 Commented on dimsissablelayer

* 📝 Kommentarer

* 🎨 Disable pointer-events on body

* 🎨 useDescendant-API kan bruke uten context-error på nesting

* 🐛 Fikset tilfeller der oppdatering av descendant-options ikke ble reflektert i descendants-map

* 🐛 Satte enabled til optional

* bug: DescenadantContext er nå riktig typet som undefined

* label: scopet navn for bruk av descendant-provider i dismissablelayer

* memo: Bedre kommentarer

* feat: Sender ikke callbacks hvis layer er disabled

* memo: Formatering og kommentarer

* memo: Kommentarer

* feat: Støtter forwardRef

* ♻️ Ryddet i DismissableLayer filer

* ♻️ Fikset edgecase der 'disabled'-noder kunne stoppe pointer-events

* refactor: Cleanup PR før release

* bug: useDismissableDescendantsContext ikke required
2024-05-04 15:15:15 +02:00
Ken 16087a458a refactor: DescendantContext er nå scopet (#2890)
* refactor: DescendantContext er nå scopet

* ♻️ Fjernet unødvendig wrapping
2024-05-04 13:34:34 +02:00
KenandHalvor Haugan c47c372d0f [Datepicker|MonthPicker] Flippet visning av år. (#2882)
* feat: DropdownCaption viser år i motsatt rekkefølge for select

* feat: Year-select for MonthPicker er viser nyeste år først

* memo: Changeset

* Update .changeset/thick-poems-design.md

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

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-05-04 13:33:59 +02:00
Ken 0c479831df bug: Nettsidebygg feilet ved bruk av fjernet prop 2024-05-02 13:27:50 +02:00
github-actions[bot]andgithub-actions[bot] 41e9fbd2a5 Version Packages (#2878)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-05-02 12:35:49 +02:00
Ken 7b25f30e60 🏷️ Fjernet referanse til duration i Progressbar for pre-release 2024-05-02 12:32:31 +02:00
Ken db9c858153 refactor: Radio og Checkbox bruker :focus for bedre synlighet når de blir lenket til fra ErrorSummary (#2893) 2024-05-02 12:18:49 +02:00
Julian Nymark b21015bf54 💄 fix for broken pin style (#2889)
* 💄 fix for broken pin style

As content (Rows) grows, the pin would get pushed down (and under) the content.

* changeset

* 💄 make css for timeline pin even more compact
2024-04-29 19:13:57 +02:00
Lars Eirik Korsgaard Hansen bac48d9057 Progressbar aria hidden (#2888) 2024-04-29 14:47:29 +02:00
Lars Eirik Korsgaard Hansen e1a85dfbeb Progressbar demo-fixes (#2887) 2024-04-29 12:40:09 +02:00
Lars Eirik Korsgaard Hansen 3f65eee9e9 Progressbar demos (#2885) 2024-04-29 10:53:02 +02:00
Halvor Haugan cd77198f1c [aksel.nav.no] Fiks anker i søketreff-lenker (#2884) 2024-04-29 09:02:58 +02:00
Halvor Haugan 82827ec712 Justering av eksempler på Label, Detail og ErrorMessage (#2883) 2024-04-29 09:02:34 +02:00
Ken 710ed83661 [Aksel.nav.no] Ny Meny for sidebar og TOC (#2873)
* 🎉 WIP for ny sidebar og TOC meny

* 💫 Animert farger

* 🎨 Støtte for nested menuitems

* 🎨 Støtter nå sidebar og toc-variant for farger

* ♻️ Migrert TOC til å bruke ny meny

* ♻️ Migrert Sidebar til å bruke ny meny

* 🐛 Fikset story

* ♿ Klikkhøyde nå minst 32px

* 💄 Justert bakgrunnsanimasjon fra 200ms -> 100ms

* Types: variant bruker semantiske navn

* bug: MenuLink ble brukt utenfor MenuLi
2024-04-26 07:58:47 +02:00
Ken 3b44a97725 design: Fallback/Alle tema piktogram er nå Aksel-logo (#2877) 2024-04-25 11:55:46 +02:00
Ken edcbd6e198 bug: Error-handling for oppretting av nye brukerprofiler i sanity (#2881) 2024-04-25 11:54:08 +02:00
Halvor Haugan bd3f9355eb storybook:aksel viser og sorterer nå på index på kodeeksempler (#2880) 2024-04-25 10:49:04 +02:00
Halvor Haugan f11bce1f8c Oppdater JSDOC og eksempler på Heading, BodyLong og BodyShort (#2879) 2024-04-25 10:16:00 +02:00
Lars Eirik Korsgaard HansenandHalvor Haugan 277525f39f ✨ Ny komponent: ProgressBar (#2845)
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-04-24 14:18:55 +02:00
Ken 210496c2cc bug: Validering av SEO-felt i sanity brakk ved undefined asset 2024-04-24 08:03:27 +02:00
github-actions[bot]andgithub-actions[bot] 8f317878fc Version Packages (#2875)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-04-22 15:48:59 +02:00
KenandHalvor Haugan c3064a01f7 🎨 Spacer er nå span (tidligere div) (#2874)
* 🎨 Spacer er nå span (tidligere div)

* 📝 Changeset

* Update .changeset/thick-humans-smile.md

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

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-04-22 15:32:57 +02:00
Ken 02f0a911b0 🔥 Fjernet gammel kode for god praksis og sanity (#2866)
* 🔥 Fjernet filtrering av aksel_tema

* 🔥 Fjernet gamle migreringer

* ⚰️ Fjernet aksel_tema og gammelt feedback-dokument

* ⚰️ Fjernet gammelt god praksis card

* ♻️ Gjenbruker nytt gp-card for relaterte artikler

* ♻️ Fjernet gamle typer

* 🔥 Fjernet referanser til gammelt feedback-dokument
2024-04-22 15:12:56 +02:00
Ken ee8524229f 🎨 Temakontakter får slack-melding gjennom tilbakemeldinger (#2869) 2024-04-19 13:36:16 +02:00
Ken d9932e203a [Sanity] Temakontakter visning (#2868)
* 🎨 Lagt til Temakontakter-felt i for gp.tema

* 🔥 Fjernet requirement for temakontakter

* 🎨 Visning for temakontakter
2024-04-19 12:58:14 +02:00
KenandHalvor Haugan b14fc23ecb [react] Collapsible component utility (#2859)
* ✨ Boilerplate for collapsible-component

* 🎨 Collapsible wrapper interface

* 🎨 Collapsible trigger interface

* 🎨 Collapsible content interface

* 🧪 Stories

* ♻️ Satt opp storybook for chromatic

* 📝 Satt opp exports

* 🧪 Open/defaultOpen tester for chromatic

* 📝 Kommentert props

* ♻️ Definerer data-state verdi på root

* 📝 JSDOC

* 📝 Disabled-demo

* ♻️ aria-controls blir bare satt når open

* ♿ Content controls button

* Update @navikt/core/react/src/collapsible/Collapsible.types.ts

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

* ♻️ props -> rest

* ♻️ props -> rest

* ♻️ Omit unreachable props

* 📝 _id rename

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-04-19 12:27:55 +02:00
Ken c16f75d6f8 [Sanity] Temakontakter (#2867)
* 🎨 Lagt til Temakontakter-felt i for gp.tema

* 🔥 Fjernet requirement for temakontakter
2024-04-19 08:42:22 +02:00
Halvor Haugan a01be91608 Rekkefølge på eksempler på FormSummary 2024-04-18 13:05:21 +02:00
github-actions[bot]andgithub-actions[bot] 8826a79021 Version Packages (#2850)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-04-18 11:59:36 +02:00
Vegard HaugstvedtandKen c2f3da84cc Bugfix/prevent submit on enter in combobox (#2861)
* Prevent "Enter" key in Combobox to...

* Added test for Enter not submitting form

* Added changeset

* Add test for un-selecting a selected option using "enter" on a Chip not submitting the form

* Do not prevent enter from submitting form if it should not perform another action (like selecting an option)

* Do not submit when the input field has a value

* Replace lots of sleep-calls with awaiting userEvents

* Create util function for looking up an option

* Fix bug where we couldn't un-select a custom option using "enter"

* Update test to account for the dropdown list closing when focus moves to the chips in the previous step

* Add possibility to slow down tests for debugging

* Fix issue with onFocus -> onToggleSelected(false), where clicking the open/close button didn't work

* Fix test

* Closing the FilteredOptionsList when focusing a Chip caused too many side effects, but we need to remove virtual focus at least. That way we won't double-click on enter.

* When no longer closing FilteredOptions on focusing a chip, we don't need to click the toggleIsOpen button to check that the option is un-selected

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

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

---------

Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-04-18 10:00:16 +02:00
Ken 2c1476022d 🐛 Descendant-provider feilet ved bruk av cloneElement (#2832)
* 🐛 Når Descendant-provider ble brukt med react cloneElement feilet child-re-render

* ⚡ Synker options for allerede registrert node

* ⚡ Unngår flere map-lookups for samme funksjon
2024-04-18 09:55:34 +02:00
Halvor Haugan dacf648c47 FormSummary: Link til dokumentasjonen i JSDOC (#2865) 2024-04-18 09:06:29 +02:00
Ken 5ec986771b [God praksis] Nye sider erstatter gamle (#2858)
* 🚚 Byttet ut gamle god-praksis sider med nye

* ♻️ Sitemap bruker ny gp-struktur

* ♻️ Lister med tema tittler bruker nå nye tema

* ♻️ Flyttet gammel godpraksiscardsimple

* ⚰️ Markert gamle tema-felt i sanity som deprecated

* ♻️ Bedre håndtering av editor/profil visning

* ♻️ Velger nå ikke en default tab for sanity visning

* 🔒 ErrorBoundary på alle gp-cards

* 🧪 Storybook for frontpage-cards

* 🐛 Dialog var ikke riktig lablet

* 🐛 Chips-liste wrappet ikke button i li, cube-illustrasjon var ikke gjemt for skjermleser

* 🎉 Viser publiserings og oppdateringsdatoer i toppen av artikkel

* 📝 Bidragsytere -> Medvirkende

* 🐛 Playwright testet gamle god praksis sider

* 🐛 Preview brakk på forside og god-praksis

* 💄 HeroCards har større illustrasjon

* ♻️ Forenklet size på herocard

* ♻️ Innhold i herocard er alltid sentrert

* 🔍 Artikler har nå riktig fallback OG-image

* Update aksel.nav.no/website/e2e/test-urls.json

* 🏷️ bruker SanityImageSource for piktogram

* 🏷️ Tagget title i staticprops som deprecated

* 🔥 Fjernet testkode

* Update aksel.nav.no/website/sanity/plugins/structure/god-praksis.ts

* 📝 Skrivefeil i structure

* 💄 Oppdatert gap mellom tagger i cards
2024-04-18 07:28:08 +02:00
ca6af8a5f7 index & process templates -> stories (#2856)
* index & process templates -> stories

* ✨ add duplication of templates to component storybook

* 🎨 fix story

* ♻️ refactor indexers for storybook

* ♻️ layout fullscreen for templates

* 🔥 Fjernet meta.json filer

* ♻️ Trukket dekorator-kode ut av alle templates

* 🐛 Fjerner storybook stories fra npm output

* 🔥 Fjernet templates fra core/react

* 🔥 Fjernet console.log

---------

Co-authored-by: Ken <ken.aleksander@gmail.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-04-17 13:46:58 +02:00
Ken 9410840f74 🐛 Fikset lenke i sanity (#2863) 2024-04-17 13:22:42 +02:00
Ken d88884f785 🔥 Fjernet content-container.css og grid.css fra _mappings (#2860)
* 🔥 Fjernet content-container og grid css fra _mappings

* Update .changeset/wet-books-end.md
2024-04-17 09:46:27 +02:00
Ken 0c8239ee00 🐛 EditorPreview knapp Sanity admin 2024-04-16 12:48:06 +02:00
Halvor Haugan 987118fd47 FormSummary.Heading: Fjern overridable, level oblig. og css-justeringer på <sm (#2857) 2024-04-16 10:34:27 +02:00
8d13f11689 Summary component (docs tweaks) (#2853)
* 🚧 wip on Summary

* ✨ new HR component

* 👔 fancy utility function to inject components into children

This is to be used in 2 places where we iterate over children and add <hr /> components between them all.

It also wraps the children in a <Box>, which is used here and not really reflected in the name of the function 🤔

* 🎨 improved version of Summary component

* Remove (some) magic

* Fix children type in injectHRBetween

* css

* header gap and bg

* responsive story + example with long texts

* 🚚 Summary -> FormSummary

* 🎨 update stories

* 🎨 update story + tweak CSS for EditButton

* 📝 add JSDoc

* export FormSummary in core/react/src/index.ts

* FormSummaryValue bruker BodyLong

* 📝 update JSDoc

* 📝 add demo

* 📝 update README.md for eksempler

* forwardRef på Answers

* forwardRef på Header

* forwardRef på Label og Value

* forwardRef på Heading og Edit

* Answer export

* spread props

* 🔥 remove HR component

* 📝 update JSDoc

* 🎨 export more FormSummary

* 🔥 duplicate dependency of _mapping (same as main)

* 📝 update JSDoc for FormSummary

* changeset

* 🔖 changeset

* 🔥 duplicate changeset

* Rename EditButton -> Edit

* oops

* Link er vel valgfritt

* 🐛 add correct CSS dependency for FormSummary

* 💄 FormSummary

* 💄 FormSummary

* className navds-form-summary

* className navds-form-summary__answers

* className navds-form-summary__header

* Update @navikt/core/css/form/form-summary.css

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

* Update @navikt/core/react/src/form-summary/FormSummaryLabel.tsx

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

* Update @navikt/core/react/src/form-summary/FormSummaryValue.tsx

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

* Header wrapper på små skjermer

* Rekkefølgen på selectors samme som DOM

* 🎨 structure consistency (ref, then ...rest, then className, then other things)

- also convert a props -> {not_the_rest, ...rest}

* update mappings

* Flytt border slik at du kan ha flere dd etter hverandre

* 🎨 update stories

* 🎨 update stories (more empty values)

* 🚚 story ComplexData -> RealisticUsage

* Mindre padding på små skjermer

* 🎨 update stories

* Answer forwardRef

* 🎨 update stories

* Eksempel på linjeskift i value i story

* 🎨 update story

* 🎨 update story

* 🚚 FormSummary -> Form/FormSummary

* 🎨 update Demo and story

* 🏷️ make href required for FormSummaryEdit

* 🏷️ + 🚧 typing woes

* 💄 tweak CSS to make it look just right

* 🏷️ correct typing using Exclude > Omit

* 🎨 use div over section without label

* 💄 FormSummary, last-child padding removal

* Fjernet kommentar

* typo i readme

* 🚚 FormSummary.Edit -> FormSummary.EditLink

* 🏷️ make href for EditLink optional

* 🚚 rename FormSummaryEdit -> FormSummaryEditLink

* FormSummaryEdit -> FormSummaryEditLink

* ✨ add example to FormSummary

* 🎨 update examples

* 🎨 update examples

* 💄 FormSummary

* 🎨 types + jsdoc tweaks (FormSummary)

* 🔥 remove aria-label example

* 🎨 separate example for grouped data

* 🎨 update desc for example

* 🔥 unused example code

* 🚚 rename examples

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-04-15 13:54:08 +02:00
Ken 158e18454e 🚚 gp-sider lenker nå til god-praksis (#2852) 2024-04-15 13:53:40 +02:00
Ken be26bf22c9 🔥 Fjernet redirect (#2851) 2024-04-15 13:35:36 +02:00
Ken c2968a0e6d 🎨 Artikler med contributors får automatisk editor (#2849)
* 🎨 Artikler med contributors får automatisk editor lagt til ved creation

* 🔒 Lager bare profil automatisk for SSO-inlogging
2024-04-15 11:16:27 +02:00
KenandHalvor Haugan 3f92773273 [Sanity] Oppdatert deskStructure (#2844)
* 🚚 Flyttet bloggvisning til egen fil

* 🚚 Flyttet grunnleggende visning

* 🎨 Sorterer 'trenger oppdatering' etter eldst først

* 🎨 Sorterer 'trenger oppdatering' etter eldst først i god-praksis

* 🚚 Flyttet komponenter visning

* 🚚 Flyttet admin visning

* 💄 Endret ikon for utdaterte artikler. Dynamisk treshold for utdatert

* 📝 Skrivefeil

* 🐛 Skrivehjelp-tittel hadde for lav kontrast på darkmode i sanity

* 🔥 Fjernet unødvendig currenUser check

* ♻️ Fikset PR-kommentarer

* Update aksel.nav.no/website/sanity/plugins/structure/structure.util.ts

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

* 🐛 Sjekker mail for lowercase

* 🐛 email kan være undefined

* Update aksel.nav.no/website/sanity/plugins/structure/structure.util.ts

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

* ♻️ Bruker innebygd showIcon-funksjon

* 📝 Bedre gruppenavn for seksjoner i sanity

* 💄 Ikoner på landigssider

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-04-15 11:15:17 +02:00
Ken 0c3ab1d0e7 [Sanity] Oppdatert utdatertvarsel (#2846)
* 🎨 innholdstype og undertema er nå required

* ♻️ Bruker eget panel for utdatert-warning i sanity

* ⚡ Bruker sanity useCurrentUser for å vise tilganger til bruker på profilside

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

* 🔥 Fjernet rest-spread
2024-04-15 11:12:32 +02:00
3a73a029f6 ✨ new FormSummary component (#2802)
* 🚧 wip on Summary

* ✨ new HR component

* 👔 fancy utility function to inject components into children

This is to be used in 2 places where we iterate over children and add <hr /> components between them all.

It also wraps the children in a <Box>, which is used here and not really reflected in the name of the function 🤔

* 🎨 improved version of Summary component

* Remove (some) magic

* Fix children type in injectHRBetween

* css

* header gap and bg

* responsive story + example with long texts

* 🚚 Summary -> FormSummary

* 🎨 update stories

* 🎨 update story + tweak CSS for EditButton

* 📝 add JSDoc

* export FormSummary in core/react/src/index.ts

* FormSummaryValue bruker BodyLong

* 📝 update JSDoc

* 📝 add demo

* 📝 update README.md for eksempler

* forwardRef på Answers

* forwardRef på Header

* forwardRef på Label og Value

* forwardRef på Heading og Edit

* Answer export

* spread props

* 🔥 remove HR component

* 📝 update JSDoc

* 🎨 export more FormSummary

* 🔥 duplicate dependency of _mapping (same as main)

* 📝 update JSDoc for FormSummary

* changeset

* 🔖 changeset

* 🔥 duplicate changeset

* Rename EditButton -> Edit

* oops

* Link er vel valgfritt

* 🐛 add correct CSS dependency for FormSummary

* 💄 FormSummary

* 💄 FormSummary

* className navds-form-summary

* className navds-form-summary__answers

* className navds-form-summary__header

* Update @navikt/core/css/form/form-summary.css

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

* Update @navikt/core/react/src/form-summary/FormSummaryLabel.tsx

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

* Update @navikt/core/react/src/form-summary/FormSummaryValue.tsx

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

* Header wrapper på små skjermer

* Rekkefølgen på selectors samme som DOM

* 🎨 structure consistency (ref, then ...rest, then className, then other things)

- also convert a props -> {not_the_rest, ...rest}

* update mappings

* Flytt border slik at du kan ha flere dd etter hverandre

* 🎨 update stories

* 🎨 update stories (more empty values)

* 🚚 story ComplexData -> RealisticUsage

* Mindre padding på små skjermer

* 🎨 update stories

* Answer forwardRef

* 🎨 update stories

* Eksempel på linjeskift i value i story

* 🎨 update story

* 🎨 update story

* 🚚 FormSummary -> Form/FormSummary

* 🎨 update Demo and story

* 🏷️ make href required for FormSummaryEdit

* 🏷️ + 🚧 typing woes

* 💄 tweak CSS to make it look just right

* 🏷️ correct typing using Exclude > Omit

* 🎨 use div over section without label

* 💄 FormSummary, last-child padding removal

* Fjernet kommentar

* typo i readme

* 🚚 FormSummary.Edit -> FormSummary.EditLink

* 🏷️ make href for EditLink optional

* 🚚 rename FormSummaryEdit -> FormSummaryEditLink

* FormSummaryEdit -> FormSummaryEditLink

* ✨ add example to FormSummary

* 🎨 update examples

* 🎨 update examples

* 💄 FormSummary

* 🎨 types + jsdoc tweaks (FormSummary)

---------

Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-04-15 09:53:42 +02:00
Halvor Haugan 6fd0f501f5 Story med forced-colors på Button (#2847) 2024-04-15 09:24:07 +02:00
Ken a11b8ddf4e 🐛 Dokumentert bruk av full og overflow-x av bleed 2024-04-12 14:51:45 +02:00
Ken 171db6a813 [Sanity] Flyttet dev-område for ny god-praksis inn i "prod" (#2843)
* 🚚 Flyttet gp-taxonomy over til prod

* 🎉 Satt opp ny sanity-struktur for god-praksis

* 🔥 Fjernet gammel editor-visning

* 🎉 Oppdatert templates for ny sanity-visning av gp

* 🔥 Fjernet god-praksis-taxonomy struktur

Struktur er nå flyttet inn i main
2024-04-12 08:25:00 +02:00
github-actions[bot]andgithub-actions[bot] 085cc532ee Version Packages (#2839)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-04-11 12:21:05 +02:00
KenandHalvor Haugan deae4ecba5 Datepicker/MonthPicker required bugs (#2838)
* 🐛 Required-prop på monthpicker stoppet ikke de-select av valg

* 🧪 Tester required for datepicker

* 🔥 Fjernet console.logs

* 📝 Changeset

* Update .changeset/fifty-hairs-fix.md

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

* Update @navikt/core/react/src/date/datepicker/datepicker.stories.tsx

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

* 🔥 Disabled-attrb er ikke nødvendig i required demo

* 🐛 Satt defaultSelected-dato til statisk dato

* ♻️ Fjernet unødvendig required-sjekk

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-04-11 11:55:27 +02:00
KenandHalvor Haugan cd2adcb655 Erstattet Radix togglegroup med intern implementasjon (#2620)
* 🎉 Ny hook og API 'descendants'

* 📝 Bedre storiers

* 🎨 implementert togglegroup med descendants

* 🎨 Implemented togglegroup.item

* 🎨 Fjernet gammel togglegroup

* 🐛 Fikset keydown

* 🔥 Fjernet comment

* 🎉 RowingFocus resetter nå ved focus-exit

* 🔥 Fjernet radix toggleroup fra dependencies

* 📝 Changeset

* [V6] Deprecated Grid og ContentContainer (#2622)

* 🔥 Fjernet grid css

* 🔥 Fjernet grid tsx

* 🔥 Fjernet content-container fra systemet

* 🐛 la til deprecatePrefix-tag for stylelint

* 📝 Changeset

* Textarea: Fjern wrapper (#2635)

* [V6] Chat-props deprecation (#2631)

* 🎨 Satt opp codemod boilerplate for chat deprecation

* 🐛 v5 -> v6 i codemod

* 🧪 Tester for alias-import av chat

* 🧪 idempotent codemod-test

* 🔥 Fjernet deprecated props fra Chat

* 📝 Changeset

* 📝 Bedre advarsel i chat-codemod

* 📝 v6-migration update

* 🧪 Tester vanlig import av Chat

* 📝 Oppdatert tekster i codemod

* 🔥 Fjernet return fra removeProps

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

* [V6] 1440px breakpoint (#2632)

* ✨ La til nytt brekkpunkt 1440px

* 🎉 Bleed støtter 2xl breakpoint

* 🎉 Bleed box 2xl breakpoint

* 🎉 hgrid 2xl breakpoint

* 🎉 resterende primitives støtter 1440px

* 📝 tailwind migreringsdocs

* 🔥 Fjernet navno-mal fra chromatic snapshot

* 📝 Changeset

* 🐛 2xl hgrid css brakk

* 📝 Oppdatert changset med tailwind-ref

* Update @navikt/core/react/src/layout/bleed/Bleed.tsx

* Update @navikt/core/react/src/layout/bleed/Bleed.tsx

* 📝 Mer konsekvent story for breakpoints i box

* 🐛 JSDOC for Bleed matcher nå syntax

* [V6] Fjernet z-index-modal token  (#2637)

* 🔥 Fjernet zindex-modal token

* 📝 Oppdatert docs

* 📝 Changeset

* [V6] ErrorSummary magic (#2642)

* ♻️ Flyttet li-tag fra ErrorSummary-parent til child

* 🏷️ Bedre typer

* 🔒 Heading er nå required i ErrorSummary

* 🎨 Egen prop for ErrorSummary fokus

* 📝 Changeset

* 🎨 Bedre fokushåndtering i ErrorSummary

* ♻️ focusTarget -> focusTargetRef

* 📝 Fikset jsdoc

* 📝 Migreringstekst

* 📝 changeset

* 📝 Migration-text

* 📝 JSDoc-staving

* 📝 Oppdatert migreringsguide for z-index + tailwind

* 🐛 Fikset bruk av z-modal i tailwind

* 🔥 Fjernet descendants-filer

* 📝 Rename context og types til namespace

* 🔥 Fjernet openOnFocus-prop fra date

* [V6] Modal: strengere prop-typer (#2718)

* 🎨 SortState i Table har nå none tilgjengelig (#2726)

* [V6] Oppdatert bruk av action-farger (#2717)

* 💄 Button secondary hover

* 💄 Radio/Checkbox action-farger

* :WIP: combobox action-farger

* 🐛 Tilpasset hover-farge på checkbox i confirmationpanel

* 💄 copybutton hover-text action

* 💄 dropdown, helptext hover-text

* 💄 link og linkpanel actionsfarger

* 💄 Search action-farger

* 💄 select action-farger

* 💄 Stepper action

* 💄 Textarea action

* 💄 Textarea og textfield colors

* 🐛 Riktig hover-bakgrunn på combobox selected option

* 📝 Changeset

* 📝 changeset tokens

* 📝 Dokumentert nye tokens

* [V6] Native ESM-støtte 🎉  (#2677)

* 🎨 Fungerende cjs/esm bundle med use-client

* 🎨 Oppdatert dir-output i for esm

* ⬆️ Bump date-fns og react-day-picker

* 🎨 oppdatert date-fns imports

* 🐛 Endret bruk av reat-day-picker i monthpicker

* 🐛 Fikset rendring av button i Datepicker-row

* ♻️ Bruker date-fns imports ssom støtter v2 og v3

* ⬆️ Synced date-fns versions

* ✨ Astro testmiljø

* 📝 Changeset

* 🎨 Skriver packagejson med type for esm

* 🔥 Fjernet .yarn/* fra astro

* 🎨 La til .yarn i gitignore for astro

* ⏪ Bruker riktig ds-react versjon

* ⬆️ Lik tsconfig som ds-react i aksel-icons

* 🐛 La tilbake provernance

* 🐛 Undo Day/Row fix fra main

* 🔥 Fjernet mulighet til å laste date-fns v2

* 🔥 Fjernet fs-extra dependency

* 🐛 Fikset feil versjon på core/react

* [V6] React-pakker støtter nå native SSR ved å bruke `use-client` 🎉  (#2707)

* 🎉 use-client blir lagt til på export av ds-react og aksel-icons

* 🎉 La til nextjs med appdir for testing

* ⚡ Tom yarn.lock med i git

* 📝 changeset

* 📝 Oppdatert migration-guide

* Update @navikt/aksel-icons/config/index-template.js

* 🎉 ToggleGroup-prop fill

* 🐛 Async-lasting av date-fns er nå v3 esm compliant

v3 av date-fns støtter ikke default export/import, noe som brakk async-lasting da vi brukte .default

* 🧪 Forbedret ToggleGroup-tester

* ⬆️ yarn sync

* 🐛 Fikset import av parts

* 🔥 Fjernet duplikate changesets

* ⬇️ Reversert duplikate endringer som kom fra v6

* 📝 rowing -> roving

* 📝 Bedre test-navn

* 📝 Bedre navngivning for tester

* ⚡ Fjernet useEffect for state update

* 📝 Oppdatert changeset og jsdoc

* ♻️ Inlinet aria-desribedby

* 📝 Demo for fill-prop på aksel.nav.no

* 🐛 Togglegroup krever onChange-prop

* 📝 ToggleGroup story for chromatic

* ⬆️ yarn lock

* 🎉 Bedre visning av eksempel på aksel.nav.no

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-04-11 11:29:33 +02:00
Ken 0d4385a545 🐛 Fill-eksempel på Tabs viste ikke funksjon riktig 2024-04-11 11:25:54 +02:00
Ken 6f1b9751f3 🛂 La til feedback på nye gp-sider (#2840) 2024-04-11 07:21:44 +02:00
Ken 7fb97808f0 🚚 Flyttet data-aksel-template attr dypere i dom-treet (#2841) 2024-04-11 07:21:29 +02:00
KenandHalvor Haugan d8ac958de2 Erstattet Radix tabs med intern implementasjon (#2621)
* 🎉 Ny hook og API 'descendants'

* 📝 Bedre storiers

* 🎉 Setup for ny tabs

* 🎨 Setup context

* 🎨 useTabs-hook

* 🎨 Tablist hook

* 🚚 Flyttet tablist i egen mappe

* 🎨 TabList

* 🐛 Fikset import av tabList

* 🎨 Tabs.Tab implementert

* 🎨 Tabs.TabPanel implementert

* 🐛 Fikset import av tabpanel

* 🐛 onOnClick -> onClick

* 🐛 Fikset keydown-håndtering i tablist

* 🐛 Fikset plassering av scrollbuttons i overflow

* ♿ Scrollbutton er nå

* ✨ Fitted variant

* 🐛 Fikset imports

* 🔥 Fjernet radix-tabs import

* 🎨 Panel-children rendres bare hvis selected

* 🎨 lazy-prop for å bare rendre children i panel hvis selected

* 🎨 Tabs.Tab håndterer nå tab-key og tabindex riktig

* 📝 Changeset

* 📝 Changeset

* [V6] Deprecated Grid og ContentContainer (#2622)

* 🔥 Fjernet grid css

* 🔥 Fjernet grid tsx

* 🔥 Fjernet content-container fra systemet

* 🐛 la til deprecatePrefix-tag for stylelint

* 📝 Changeset

* Textarea: Fjern wrapper (#2635)

* [V6] Chat-props deprecation (#2631)

* 🎨 Satt opp codemod boilerplate for chat deprecation

* 🐛 v5 -> v6 i codemod

* 🧪 Tester for alias-import av chat

* 🧪 idempotent codemod-test

* 🔥 Fjernet deprecated props fra Chat

* 📝 Changeset

* 📝 Bedre advarsel i chat-codemod

* 📝 v6-migration update

* 🧪 Tester vanlig import av Chat

* 📝 Oppdatert tekster i codemod

* 🔥 Fjernet return fra removeProps

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

* [V6] 1440px breakpoint (#2632)

* ✨ La til nytt brekkpunkt 1440px

* 🎉 Bleed støtter 2xl breakpoint

* 🎉 Bleed box 2xl breakpoint

* 🎉 hgrid 2xl breakpoint

* 🎉 resterende primitives støtter 1440px

* 📝 tailwind migreringsdocs

* 🔥 Fjernet navno-mal fra chromatic snapshot

* 📝 Changeset

* 🐛 2xl hgrid css brakk

* 📝 Oppdatert changset med tailwind-ref

* Update @navikt/core/react/src/layout/bleed/Bleed.tsx

* Update @navikt/core/react/src/layout/bleed/Bleed.tsx

* 📝 Mer konsekvent story for breakpoints i box

* 🐛 JSDOC for Bleed matcher nå syntax

* [V6] Fjernet z-index-modal token  (#2637)

* 🔥 Fjernet zindex-modal token

* 📝 Oppdatert docs

* 📝 Changeset

* [V6] ErrorSummary magic (#2642)

* ♻️ Flyttet li-tag fra ErrorSummary-parent til child

* 🏷️ Bedre typer

* 🔒 Heading er nå required i ErrorSummary

* 🎨 Egen prop for ErrorSummary fokus

* 📝 Changeset

* 🎨 Bedre fokushåndtering i ErrorSummary

* ♻️ focusTarget -> focusTargetRef

* 📝 Fikset jsdoc

* 📝 Migreringstekst

* 📝 changeset

* 📝 Migration-text

* 📝 JSDoc-staving

* 📝 Oppdatert migreringsguide for z-index + tailwind

* 🐛 Fikset bruk av z-modal i tailwind

* 🔥 Fjernet descendants-filer

* 📝 Rename context og types til namespace

* 🔥 Fjernet openOnFocus-prop fra date

* [V6] Modal: strengere prop-typer (#2718)

* 🎨 SortState i Table har nå none tilgjengelig (#2726)

* [V6] Oppdatert bruk av action-farger (#2717)

* 💄 Button secondary hover

* 💄 Radio/Checkbox action-farger

* :WIP: combobox action-farger

* 🐛 Tilpasset hover-farge på checkbox i confirmationpanel

* 💄 copybutton hover-text action

* 💄 dropdown, helptext hover-text

* 💄 link og linkpanel actionsfarger

* 💄 Search action-farger

* 💄 select action-farger

* 💄 Stepper action

* 💄 Textarea action

* 💄 Textarea og textfield colors

* 🐛 Riktig hover-bakgrunn på combobox selected option

* 📝 Changeset

* 📝 changeset tokens

* 📝 Dokumentert nye tokens

* [V6] Native ESM-støtte 🎉  (#2677)

* 🎨 Fungerende cjs/esm bundle med use-client

* 🎨 Oppdatert dir-output i for esm

* ⬆️ Bump date-fns og react-day-picker

* 🎨 oppdatert date-fns imports

* 🐛 Endret bruk av reat-day-picker i monthpicker

* 🐛 Fikset rendring av button i Datepicker-row

* ♻️ Bruker date-fns imports ssom støtter v2 og v3

* ⬆️ Synced date-fns versions

* ✨ Astro testmiljø

* 📝 Changeset

* 🎨 Skriver packagejson med type for esm

* 🔥 Fjernet .yarn/* fra astro

* 🎨 La til .yarn i gitignore for astro

* ⏪ Bruker riktig ds-react versjon

* ⬆️ Lik tsconfig som ds-react i aksel-icons

* 🐛 La tilbake provernance

* 🐛 Undo Day/Row fix fra main

* 🔥 Fjernet mulighet til å laste date-fns v2

* 🔥 Fjernet fs-extra dependency

* 🐛 Fikset feil versjon på core/react

* [V6] React-pakker støtter nå native SSR ved å bruke `use-client` 🎉  (#2707)

* 🎉 use-client blir lagt til på export av ds-react og aksel-icons

* 🎉 La til nextjs med appdir for testing

* ⚡ Tom yarn.lock med i git

* 📝 changeset

* 📝 Oppdatert migration-guide

* Update @navikt/aksel-icons/config/index-template.js

* 🚚 rename fitted -> fill in tabs

* 🐛 Async-lasting av date-fns er nå v3 esm compliant

v3 av date-fns støtter ikke default export/import, noe som brakk async-lasting da vi brukte .default

* 🧪 Forbedret Tabs-tester

Lagt til flere test-caser, men implementert testing av keyboard-nav og tabbing

* ⬆️ yarn sync

* ⬆️ Yarn lock

* ⬇️ Reversert duplikate endringer som kom fra v6

* 🎨 Aria-hidden blir nå satt på ikon hvis label allerede er satt på tab

* Update @navikt/core/react/src/tabs/Tabs.types.ts

* 📝 Testnavn for tabs

* ⚡ Skipper unødvendig memo for tab-context, punktum etter all jsdoc

* 🔥 Fjernet TabsContextProps

* 📝 Fjernet comma på changeset

* 📝 Fill-demo for aksel.nav.no

* 📝 Changeset for lazy-prop

* Update @navikt/core/react/src/tabs/parts/tabpanel/TabPanel.tsx

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

* 🐛 Beholder  attr fra radix med i ny implementasjon

* ⚡ Flyttet fokus-state update ut av useeffect, fjernet unødvendig klasse for hidden

* ⚡ Unngår unødvendig sjekk for disabled i onFocus for useTab2

* ♻️ tab og tabpanel støtter nå egne id-er

* Update @navikt/core/react/src/tabs/useTabs.ts

* 🐛 I none tilfeller førte setFocusedValue utenfor useEffect til infinite re-renders

* Update @navikt/core/react/src/tabs/parts/tab/Tab.tsx

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

* 🐛 bruker-id var satt på feil attrb

* 📝 Dokumentert custom-ids for tabs

* ⚡ Chroamtic-format for tabs-stories

* ♻️ Omskrevet tabs-stories for ny syntax

* 📝 Bruker bold markdown istedenfor note syntax

* 📝 Flyttet warning til newline

* 📝 Bruker bare ett linjeskift for jsdoc

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-04-10 13:36:11 +02:00
dependabot[bot]andKen b417c74374 ⬆️ Bump vite from 5.1.6 to 5.1.7 (#2836)
* ⬆️ Bump vite from 5.1.6 to 5.1.7

Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 5.1.6 to 5.1.7.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v5.1.7/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.1.7/packages/vite)

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

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

* ⬆️ bumpet vite til 5.1.7 i shadow-dom demo

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ken <ken.aleksander@gmail.com>
2024-04-10 12:24:54 +02:00
Halvor Haugan ff1d3534a6 🆙 Oppgrader Chromatic (#2837) 2024-04-10 12:13:48 +02:00
KenandHalvor Haugan 57d015209d [aksel.nav.no] Oppdatert ny GP-struktur og frontend (#2778)
* 🎉 Animert hero-select for nye gp-sider

* 🎨 Implementert keyboard-handler for tema-hero

* ♿ Gjemmer elementer ikke synlige ved hero-select

* 🎉 Ny hero for gp-side

* 🎨 Oppdatet gp-forside

* 🧪 Stories for nye komponenter

* 🐛 tabindex -> tabIndex

* ♻️ Oppdatert queriy definition

* 💄 Justert for mobilvisning

* 🎨 Bruker prictogram-data fra sanity i cards

* 🎉 Bruker faktiske innholdstyper og undertema nå

* 🔥 Fjernet TODO

* 🎨 Oppdatert go-forside til å støtte riktekst description

* 🐛 stories var ikke oppdatert

* 🎉 Bruker hero-cards i tema-hero

* 🐛 stories var ikke oppdatert

* 🐛 Manglet image i response-type

* ♻️ Omstrukturert modalvariant av dialog

* 🎉 Dynamisk hero for gp-sider

* 💫 Dynamisk skalering er nå animert

* 💫 Justert exit-animasjon

* 🔥 Fjernet gammel inline style

* ♻️ Forenklet Static hero callbacks

* 🔥 Fjernet hasRefs sjekk etter query for gp-artikler

* 🎉 Oppdatert serverside interface for gp-tema

* 🎉 Visninger for filtervalg på gp-tema

* 🐛 Valgt element ble ikke fokusert ved hero-åpning

* 🎉 Oppdatert artikkelkort for nye gp-sider

* 💄 Justert spacing for heading/desc seksjoner

* 🎉 Fikset lasting av data og chips

* 🎉 Fungerende chip-navigering

* ⚰️ Fjernet gammel kode

* 🚚 rename tema-hero filer

* 📝 Dokumentert count articles funksjoner

* 🧪 tester for count-articles

* 🚚 Flyttet cardgrid ut til egen fil

* 🔍 lagt til seo for tema

* ⬇️ reversert til prod-dataset

* 🎉 Artikler på gp-forside er sortert etter mest populære

* 🎨 satt description på undertema til required

* 🎉 Panel for forhåndsvisning av undertema/innholdstype på artikkelside

* 🎉 Lagt til forklarings-felt i ny god-praksis struktur

* 🐛 Fjernet chiplist for lister uten noe data

* 🎉 Tilpasset temaheader for kontrast

* 💄 normal -> semibold for statichero title

* ♿ Wrappet lister i ul > li

* 🎉 Oppdatert til ul > li på artikkel-lister

* 🐛 Cards strakk seg ikke til høyde etter wrapping i li

* 🐛 Manglet main-element og skip-link støtte

* 🔍 Bedre meta-description

* 🔥 Fjernet kommentar

* 🎨 Gjort klar sitemap for ny god-praksis

* ♿ Bedre semantikk for temasider

* 🎨 Justert tema header

* 🎨 Oppdatert akselchevron

* 💫 Justert page-animasjon

* 🎨 La til artikkel-chips

* ♻️ Link chip -> temalink

* 🎨 Tema-tagging på gp-artikler

* 💄 Gradient og illustrasjon på tema-hero

* 💄 La til bildestøtte i hero-tittel

* 🐛 stories brakk

* 💄 Satt god praksis heading til text- default for bedre kontrast

* 💄 z-index problem på intro hero

* 💄 Småjusteringer design

* 🐛 z-index stacking av cube-illustrasjon nå bak tekst

* 📝 Lagt til kommentar

* 🚚 Flyttet over støtte for wc definering i react

* 🐛 Brukte feil temahenter i sitemap som brakk playwright

* ♿ uu-oppdateringer etter review

* ♻️ Explanation -> description for undertema og tema

* 💄 Oppdatert Hero for teamsider

* 💄 Blur-bg på tekst i hero, no underline på hover for komponentsforside

* ♻️ Fokus beholdet på select-knapp ved åpning av tema-dialog

* 📝 Commentarer på escapeKeyDown hook

* 💄 Gjennbruker gradient for alle hero-headers

* 📝 Skrivefeil

* 📝 Kommentert useGpViews

* 📝 Kommentert endringer

* ⬆️ Bumpet sanity til v3.36

* ♻️ Fjernet Modal variant av tema hero.

Bruker samme dialog på mobil og desktop

* 🎨 aria headings -> h3 for gp-forside lenke

* 📝 Lowercase i html for artikkelcards

* Update aksel.nav.no/website/pages/gp/index.tsx

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

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

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

* Update aksel.nav.no/website/components/layout/god-praksis-page/cards/GpArticleCard.tsx

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

* Update aksel.nav.no/website/components/layout/god-praksis-page/hero/tema-hero/parts/HeroCardList.tsx

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

* 🚚 ArticleView -> ArticleSections

* 🚚 bosheight -> dialogheight

* 🐛 Import feilet av GpCardGrid etter navneendring

* 🐛 hero navigasjon var ikke sortert etter temanavn

* 🔥 Fjernet explanation-felt for innholdstyper

* ♻️ Ryddet opp i kommentarer fra github

* ♻️ Bruker SanityImageSource for Image-type

* 💄 Selected-variant av herocard. Inverted-pictogram i sanity

* 📝 view -> queryView

* ♻️ Skrevet om ArticleSections for å unngå repetert kode

* ⬆️ yarn lock

* ♻️ Fjernet unødvendig react-fragment

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-04-10 10:15:56 +02:00
Ken 5969859024 🐛 Unngå at global Escape-event lukker ikon-sidebar
Dette gjelder ved escape i Søk(modal) og søkefelt på ikonside
2024-04-10 09:05:51 +02:00
github-actions[bot]andgithub-actions[bot] 9bbc3e6813 Version Packages (#2835)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-04-09 15:25:38 +02:00
Ken 5250b47ca4 💄 Border-radius på FileUpload.Item er nå rund (#2834) 2024-04-09 15:20:40 +02:00
Ken fc7709ae2a 🐛 Søk filtrerte ut beste treff fra 'nyeste artikler' 2024-04-09 09:40:20 +02:00
github-actions[bot]andgithub-actions[bot] 2364e689ed Version Packages (#2831)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-04-09 09:12:06 +02:00
Halvor Haugan d57c0b2c2c Justering av eksempler på Checkbox (#2833) 2024-04-09 09:06:58 +02:00
Ken 868bb543a5 🐛 Preview brakk for god-praksis
Siden 'userState' ikke hentes fra Sanity, blir den undefined ved lasting av previewdata
2024-04-09 07:33:16 +02:00
Torkjel SkjetneandHalvor Haugan 8f9ed7a404 FileUpload.Item: 💥 Endret API og støtte for å sette ID på knappen (#2824)
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2024-04-08 09:16:53 +02:00
Halvor HauganandKen 5ea6255f6d Justeringer av eksempler på Radio og Checkbox med mer (#2830)
Co-authored-by: Ken <26967723+KenAJoh@users.noreply.github.com>
2024-04-04 20:54:12 +02:00
github-actions[bot]andgithub-actions[bot] 491fccbe80 Version Packages (#2828)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-04-03 11:56:35 +02:00
Ken cca2a8263f 💄 Fjernet Illustrasjon fra bloggsider (#2827) 2024-04-03 11:50:12 +02:00
Ken 3140ec2765 🔥 Fjernet role=gridcell fra datoknapper (#2826)
Siden knappene allerede er i en table og da også td er det unødvendig med gricell
2024-04-03 11:37:05 +02:00
Halvor Haugan d8fce83ae3 Oppgrader til Storybook 8 (#2825) 2024-04-03 10:03:44 +02:00
github-actions[bot]andgithub-actions[bot] f88b00daf6 Version Packages (#2821)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-04-03 09:45:19 +02:00
Ken 6d0baea5c1 👽 Oppdatert om Aksel lenke i footer
Side er flyttet fra god-praksis til standalone-side url
Er opprettet automatisk redirect slik at eldre lenker ikke brekker
2024-04-03 09:25:54 +02:00
Ken 880e77b9c2 ♻️ Fjernet max-krav for antall tegn i Relaterte lenker-module
Siden lenketeksten ofte refererer til en sidetittel skaper det utfordringer da de ofte er litt lengre
2024-04-03 09:03:57 +02:00
Ken 6d16373f85 👽 Oppdatert skriv for aksel lenke i footer
Side er flyttet fra god-praksis til standalone-side url
Er opprettet automatisk redirect slik at eldre lenker ikke brekker
2024-04-03 08:42:08 +02:00
Halvor Haugan ae078254dc Modal: Fjern tomt element (#2819) 2024-04-02 10:20:00 +02:00
github-actions[bot]andgithub-actions[bot] 638e8260b4 Version Packages (#2811)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-04-02 08:45:10 +02:00
Halvor Haugan d991011690 FileUpload.Dropzone: id prop settes på button (#2817) 2024-03-22 11:03:05 +01:00
KenandHalvor Haugan b6086f7b1f 📝 Oppdatert radio-error dokumentasjon (#2800)
* 📝 Oppdatert radio-error dokumentasjon

* Update aksel.nav.no/website/pages/eksempler/radio/error.tsx

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

* Update aksel.nav.no/website/pages/eksempler/radio/error.tsx

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

* Update aksel.nav.no/website/pages/eksempler/radio/error.tsx

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

---------

Co-authored-by: Halvor Haugan <83693529+HalvorHaugan@users.noreply.github.com>
2024-03-22 10:42:38 +01:00
Ken 05462081aa useControllableState i Expansioncard og Switch state-bug (#2810)
* ♻️ Bruker controllableState i ExpansionCard

* 🐛 Fikset tilfelle der checked switch var visuelt unchecked

* 📝 Changeset

* 🔥 Fjernet utkommentert kode
2024-03-22 10:24:35 +01:00
Ken 63e42de3ee 🆙 Oppdatert Playroom (#2815) 2024-03-22 09:31:00 +01:00
Halvor Haugan 2e85178166 yarn.lock sync 2024-03-21 16:36:11 +01:00
Ken 456d4e2e07 🐛 Slack var ikke i outbound accessPolicy for feedback 2024-03-21 11:52:48 +01:00
Ken b5a0cb8cdf Oppdatert logging for Aksel.nav.no + bumpet feedback pagination page-size (#2812)
* 🆙 Oppgradert logging

* 🎨 Bedre loggeoutput

* 🎨 Bruker childlogger

* 🧪 Custome error-logg

* ⚡ Større paginering-page for slackusers

* 📝 error -> info
2024-03-21 11:36:43 +01:00
Ken a2af9bcc37 Lagt til mer padding-right på ReadMore (#2806)
* 💄 Oppdatert padding-right på readmore

* 📝 Changeset

* 🐛 Manglet chromatic-disable på readmore story
2024-03-21 10:16:14 +01:00
bd45754adb [aksel.nav.no] Slackbot for feedback (#2785)
* 🎉 Satt opp boilerplate for auth på Aksel

* 🎉 Auth boilerplate

* 🎨 Demo-setup for å teste auth i dev

* 🚚 Flyttet auth til getserversideprops

* 🔥 Fjernet authprovider fra _app

* 🐛 revalidate er ikke valid key for getserversideprops i nextjs

* 🚚 rename auth-dir

* 🔥 Fjernet auth types

* 🎉 Auth for api

* 🎨 Oppdatert workflows med token

* 🔥 Fjernet testing av auth på god-praksis sider

* 🎨 La til sidecar på prod-deploy

* 🐛 only return boolean in Promise<boolean>

* ✨ feedback form

* 🎨 showcase all states of new FeedBackForm

* 🔥 remove prop name (will use auth api)

* 🎨 use getAuthUser()

* 🎨 use useAuth() for login/logout

* 🎉 Slack feedback-api

* 🐛 handle case where token is null

* 🎨 scroll to anchor on login redirect

* ⚡ Utility-funksjoner for slack-api

* 🧪 Tests for slack-utilities

* 🎨 Ryddet opp i henting av slack memebers

* 🚚 Flyttet caching inn i funkson

* 📱 make FeedbackForm responsive

* 🎉 Strengere typet slack-utilities

* 🎨 Fikset typefeil i feedback-api

* ⬆️ Migrert til @navikt/oasis

* 🏷️ Satt typer til strict for å kjøre tester

* 🎨 Slackbot-API with protected auth and actual user

* 🏷️ strengere typer

* ⚡ Implementert paginering av slacbot

* 🎨 Lagt til slackbot-token i workflows

* 🏷️ strict tsconfig

* 🏷️ Typer for slackbot input

* 🔥 Fjernet demo-body

* 🎨 oppdatert medvirkende tekst

* ⬆️ Yarn lock

* 🎨 move state handling down to Feedback

* 🏷️ typing fixes

* 🚧 API usage

* 🏷️ fix type error

* 👷 update AccessPolicy

* 🦺 add validation to feedback form

* 💄 justify-items-stretch on TextArea needed 🤔

* ♻️ avoid prop drilling, use sanity data hook for document id

* 🔧 add auth to webpack config for storybook

* ♻️ Feedback form  (also add error state handling)

* 👷 add stories for Feedback form

* 🔊 log feedback results metadata

* ♻️ remove refs, use formData and event.currentTarget

* 🧪 retry flaky test

* ⚗️ test promises for dynamic import in test

* 🧪 flaky test config

* ⬆️ yarn lock sync

* ⬆️ yarn lock sync

* ♻️ Bruker nå egen userState-type for fortelle komponenter om bruker er logget inn eller ikke

* 🔥 remove unused CSS

* 📝 lagt til todods

* 🔥 remove anonymous feedback submission

* 🔥 remove CSS

* :goals_net: catch fetch clientside, feedback

* ✨ send feedback to private slack channel as well

notify everyone if there are 0 editors

* 💄 + ♿ aria-hiddens and better styling, Feedback

* ♻️ refactor + add more feedback (loading state + alert)

* ⚗️ test encoding uri for anchor (redirect)

* ⚗️ more testing URL redirect

* ⚗️ more testing

* ⚗️ testing

* ✅ stories for Feedback

* 🔒 sanitize user objects (then cache)

* 🏷️ type SanitizeUser in find-user

* 🐛 optionally render the message about zero editors

* ⚗️ more testing for URL redirect / fragment issue

* ⚗️ log the redirect URL

* ⚗️ more testing

* ♻️ Gjennbruker error-return for feedback-api

* 🧪 Tester alternativ løsning for scroll etter login

* 🐛 Query update slapte loop i useEffect

* 🧪 Tester alternativ løsning for scroll etter login

* 🚚 Flyttet autofocus inn i headingseksjon

* 🐛 Wonderwall fjerner & fra query

* 🐛 encodeUrl as defined in wonderwall docs

* 🧪 Reversert til anchor-løsning

* 🧪 Reversert til anchor-løsning med encoding

* 🐛 Fikset edgecase der asPath med allerede eksisterende hash brakk login-redirect

* 🔥 Cleanup etter anchor-testing

* ⬆️ yarn lock sync

* 🎨 Oppdatert til navikt channelid

* 📝 Endret på error-tekst i feedback

* Fjernet ts-expect-error

* ⬆️ yarn lock sync

* 🔥 Fjernet filterering på godkjent mail

* 📝 Oppdatert slackbot-block

---------

Co-authored-by: Julian Nymark <julian.nymark@nav.no>
Co-authored-by: Halvor Haugan <halvor.haugan@nav.no>
2024-03-20 15:48:49 +01:00
github-actions[bot]andgithub-actions[bot] a882a8a389 Version Packages (#2807)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-03-20 13:26:51 +01:00
Ken d1606d358a 🐛 useDatepicker håndterer isInvalid validation riktig (#2809)
* 🐛 useDatepicker håndterer isInvalid validation riktig nå

* Update @navikt/core/react/src/date/hooks/useDatepicker.tsx

* Update @navikt/core/react/src/date/hooks/useDatepicker.tsx
2024-03-20 13:21:05 +01:00
Ken bb87837632 🧪 Bump timeout and retry of dateStr testing 2024-03-20 12:33:56 +01:00
Halvor Haugan 9c8b2301ed FileUpload.Dropzone: Fiks feil med duplisert id (#2805) 2024-03-20 12:31:08 +01:00
Ken 54ba483d2d ✅ Oppdatert Chromatic-tester
✅ Oppdatert dropdown-tester

🐛 satt dropdown-story til open

✅ Oppdatert errorsummary-tester

✅ Oppdatert fieldset-tester
2024-03-20 11:51:46 +01:00
870 changed files with 29778 additions and 19477 deletions

No files matched your search

+22 -1
View File
@@ -32,6 +32,7 @@ module.exports = {
"react/display-name": "off",
"import/no-named-as-default": "off",
// "import/no-cycle": [1],
"no-else-return": "error",
},
reportUnusedDisableDirectives: true,
overrides: [
@@ -90,6 +91,27 @@ module.exports = {
"aksel-local/comment-check": ["error"],
},
},
{
files: ["**/examples/__parts*/*.tsx"],
plugins: ["aksel-local"],
rules: {
"aksel-local/import-check": ["error"], // Only allow imports from @navikt and react
},
},
{
files: ["**/examples/__parts-inline/*.tsx"],
rules: {
"arrow-body-style": ["error", "never"],
"func-style": ["error", "expression"],
"import/no-named-export": "error",
},
},
{
files: ["examples/**"],
rules: {
"react/react-in-jsx-scope": "off",
},
},
],
globals: {
Locale: "readonly",
@@ -99,7 +121,6 @@ module.exports = {
"node_modules",
"lib",
"public",
"examples",
"esm",
"cjs",
"dist",
+1
View File
@@ -19,6 +19,7 @@ add links to project-tasks, slack discussions etc here
- Check that styling is correctly exported from `@navikt/core/css/index.css`
- Check that correct tokens for component is documented in `@navikt/core/css/tokens.json`
- Check that only needed components and types are exported from `@navikt/core/react/src/index.ts`
- Check that component is exported from `@navikt/core/react/package.json`
- Add JSDoc to component (see other components for reference)
- Create storybook-stories for relevant component variations and compositions. Stories are used for [visual regression testing](https://www.chromatic.com/docs/), so make sure they are complete.
- Is the component sufficiently complex to warrant tests? Add some unit-tests for vitest.
+4 -3
View File
@@ -14,10 +14,10 @@ jobs:
contents: "read"
id-token: "write"
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "20"
node-version: lts/*
cache: yarn
- name: set-env for yarn install to @navikt scope
shell: bash
@@ -25,6 +25,7 @@ jobs:
- name: add tokens to .env
run: |
echo "SLACK_BOT_TOKEN=${{ secrets.SLACK_BOT_TOKEN }}" >> aksel.nav.no/website/.env
echo "SANITY_WRITE_KEY=${{ secrets.SANITY_FEEDBACK_WRITE_KEY }}" >> aksel.nav.no/website/.env
echo "SANITY_PREVIEW_TOKEN=${{ secrets.SANITY_PREVIEW_TOKEN }}" >> aksel.nav.no/website/.env
echo "SANITY_PRIVATE_NO_DRAFTS=${{ secrets.SANITY_PRIVATE_NO_DRAFTS }}" >> aksel.nav.no/website/.env
+7 -6
View File
@@ -14,11 +14,11 @@ jobs:
name: Update component data
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
with:
node-version: "20"
node-version: lts/*
cache: yarn
- name: set-env for yarn install to @navikt scope
shell: bash
@@ -47,11 +47,11 @@ jobs:
contents: "read"
id-token: "write"
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
with:
node-version: "20"
node-version: lts/*
cache: yarn
- name: set-env for yarn install to @navikt scope
shell: bash
@@ -59,6 +59,7 @@ jobs:
- name: add tokens to .env
run: |
echo "SLACK_BOT_TOKEN=${{ secrets.SLACK_BOT_TOKEN }}" >> aksel.nav.no/website/.env
echo "SANITY_WRITE_KEY=${{ secrets.SANITY_FEEDBACK_WRITE_KEY }}" >> aksel.nav.no/website/.env
echo "SANITY_PREVIEW_TOKEN=${{ secrets.SANITY_PREVIEW_TOKEN }}" >> aksel.nav.no/website/.env
echo "SANITY_PRIVATE_NO_DRAFTS=${{ secrets.SANITY_PRIVATE_NO_DRAFTS }}" >> aksel.nav.no/website/.env
+5 -4
View File
@@ -1,4 +1,4 @@
name: Redeploy image to for aksel.nav.no
name: Redeploy image for aksel.nav.no
on:
workflow_dispatch:
inputs:
@@ -19,10 +19,11 @@ jobs:
name: Redeploy image
runs-on: ubuntu-20.04
steps:
- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
with:
node-version: "20"
- uses: actions/checkout@v3
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:
+5 -5
View File
@@ -8,13 +8,13 @@ jobs:
execute:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Required to retrieve git history
- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
with:
node-version: "20"
node-version: lts/*
cache: yarn
- name: set-env for yarn install to @navikt scope
shell: bash
@@ -26,10 +26,10 @@ jobs:
- name: Export dataset
run: cd aksel.nav.no/website && SANITY_PREVIEW_TOKEN=${{secrets.SANITY_DATASET_EDITOR_TOKEN}} yarn backup
- name: Upload GCP bucket
uses: "google-github-actions/auth@v0"
uses: "google-github-actions/auth@v2"
with:
credentials_json: "${{ secrets.gcp_credentials_prod }}"
- uses: "google-github-actions/upload-cloud-storage@v0"
- uses: "google-github-actions/upload-cloud-storage@v2"
with:
path: ./aksel.nav.no/website
destination: "aksel-website-prod/backups"
+7 -15
View File
@@ -10,38 +10,30 @@ on:
branches: [main, next]
paths:
- "@navikt/**"
- "aksel.nav.no/website/pages/templates/**"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
visual_regression_test:
chromatic:
if: ${{ !contains(github.event.pull_request.labels.*.name, 'ignore-chromatic') }}
name: "visual regression test (chromatic)"
runs-on: ubuntu-latest
permissions:
issues: write
pull-requests: write
contents: write
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
with:
node-version: "20"
node-version: lts/*
cache: yarn
- name: Restore cache
uses: actions/cache@v3
with:
path: "**/node_modules"
key: ${{ runner.os }}-visual-regression-test-${{ github.sha }}
restore-keys: |
${{ runner.os }}-visual-regression-test-
- name: Install dependencies
run: yarn
@@ -49,7 +41,7 @@ jobs:
run: yarn boot
- name: Chromatic
uses: chromaui/action@v1
uses: chromaui/action@latest
id: chromatic_tests
continue-on-error: true
with:
@@ -57,7 +49,7 @@ jobs:
token: ${{ secrets.GITHUB_TOKEN }}
projectToken: x3xqdfgkujg
exitZeroOnChanges: false
buildScriptName: "build:storybook"
buildScriptName: "build:storybook-chromatic"
onlyChanged: true
untraced: "**/package.json|yarn.lock|**/*.md"
externals: \@navikt/core/css/**/*.css
+6 -3
View File
@@ -16,13 +16,13 @@ jobs:
permissions:
pull-requests: "write"
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
with:
node-version: "20"
node-version: lts/*
cache: yarn
- name: set-env for yarn install to @navikt scope
shell: bash
@@ -37,5 +37,8 @@ jobs:
- name: Lint
run: yarn lint
- name: Validate example code
run: yarn validate:eksempler
- name: Test
run: yarn test
+4 -4
View File
@@ -15,10 +15,10 @@ jobs:
container:
image: mcr.microsoft.com/playwright:v1.35.1-jammy
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "20"
node-version: lts/*
cache: yarn
- name: set-env for yarn install to @navikt scope
shell: bash
@@ -42,7 +42,7 @@ jobs:
- name: Run Playwright tests
run: yarn workspace website e2e:ci-full
- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
if: always()
with:
name: playwright-report
+1 -1
View File
@@ -17,7 +17,7 @@ jobs:
id-token: "write"
steps:
- uses: "actions/checkout@v3"
- uses: "actions/checkout@v4"
- id: upload
uses: nais/deploy/actions/cdn-upload/v2@master
+3 -3
View File
@@ -22,13 +22,13 @@ jobs:
packages: "write"
pull-requests: "write"
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
with:
node-version: "20"
node-version: lts/*
cache: yarn
- name: set-env for yarn install to @navikt scope
shell: bash
+29
View File
@@ -0,0 +1,29 @@
# https://github.com/actions/stale
name: Mark stale issues
on:
schedule:
- cron: "31 3 * * *"
workflow_dispatch:
jobs:
stale:
runs-on: ubuntu-latest
permissions:
issues: write
steps:
- uses: actions/stale@v9
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
days-before-issue-stale: 120
days-before-pr-stale: -1
days-before-close: 30
any-of-labels: "Besvart"
stale-issue-message: |-
Hei! Det ser ut som det ikke har vært aktivitet her på en stund. Etter 30 dager vil saken bli lukket automatisk.
Om saken fortsatt er relevant eller du har oppdateringer, vil en kommentar hindre at den lukkes. Du kan alltids åpne den igjen hvis det skulle være nødvendig!
stale-issue-label: "no-issue-activity"
ascending: true
operations-per-run: 200
+2 -2
View File
@@ -9,14 +9,14 @@ jobs:
contents: "read"
id-token: "write"
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 1
- uses: denoland/setup-deno@v1
with:
deno-version: v1.x
- name: Restore cache
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: "**/node_modules"
key: ${{ runner.os }}-build-${{ github.sha }}
+56 -7
View File
@@ -1,13 +1,57 @@
import { mergeConfig } from "vite";
import { loadCsf } from "@storybook/csf-tools";
import { StorybookConfig } from "@storybook/react-vite";
import { readFileSync } from "fs";
import turbosnap from "vite-plugin-turbosnap";
import TsconfigPathsPlugin from "vite-tsconfig-paths";
const indexRegex = /export const args = {\s+index: (\d+),/;
export default {
staticDirs: ["./public"],
experimental_indexers: (indexers) => {
// Changes here might need to be reflected in aksel.nav.no/website/.storybook/main.ts
const customIndexer = async (fileName: string, opts) => {
let code = readFileSync(fileName, "utf-8").toString();
stories: () => ["../@navikt/**/*.stories.@(js|jsx|ts|tsx|mdx)", "./*.mdx"],
const matches = indexRegex.exec(code);
const prefix = matches ? `${matches[1]} | ` : "";
code = code.split(
/\/\/ EXAMPLES DO NOT INCLUDE CONTENT BELOW THIS LINE/,
)[0];
const [templateName, name] = fileName
.split(`pages/templates/`)[1]
.replace(".tsx", "")
.split("/");
const storyName = process.env.CHROMATIC
? `${templateName} | ${prefix}${name}` // Chromatic does not support folders
: `${prefix}${name}`;
code += `
export default { title: "Templates/${templateName}/${storyName}" };
export const Demo = { render: Example };
Demo.storyName = "${storyName}";`;
return loadCsf(code, { ...opts, fileName }).parse().indexInputs;
};
return [
...(indexers || []),
{
test: /pages\/templates\/.+?.tsx$/,
createIndex: customIndexer,
},
];
},
staticDirs: ["./public"],
stories: () => [
"../@navikt/**/*.stories.@(js|jsx|ts|tsx|mdx)",
"./*.mdx",
"../aksel.nav.no/website/pages/templates/**/*.tsx",
],
addons: [
"@storybook/addon-a11y",
"@xfinx/storybook-addon-html",
"@whitespace/storybook-addon-html",
"@storybook/addon-interactions",
{
name: "@storybook/addon-storysource",
@@ -37,20 +81,25 @@ export default {
},
typescript: {
check: false,
checkOptions: {},
reactDocgen: false,
},
async viteFinal(config, { configType }) {
const { mergeConfig } = await import("vite");
// The TsconfigPathsPlugin is only used to silence errors when importing nextjs components, but the imports does not acutally work.
const tsConfigPathsPluginOpts = { root: "aksel.nav.no/website/" };
return mergeConfig(config, {
plugins:
configType === "PRODUCTION"
? [
TsconfigPathsPlugin(tsConfigPathsPluginOpts),
turbosnap({
rootDir: config.root ?? process.cwd(),
}),
]
: [],
: [TsconfigPathsPlugin(tsConfigPathsPluginOpts)],
});
},
};
} satisfies StorybookConfig;
-2
View File
@@ -1,9 +1,7 @@
{
"cssVariables.lookupFiles": ["@navikt/core/css/dist/index.css"],
"eslint.problems.shortenToSingleLine": true,
"deno.enablePaths": ["scripts/article-views", "scripts/changelog"],
"editor.defaultFormatter": "esbenp.prettier-vscode",
"deno.lint": true,
"files.watcherExclude": {
"**/.yarn/**": true,
"**/dist": true,
+54
View File
@@ -1,5 +1,59 @@
# @navikt/aksel-icons
## 6.14.0
## 6.13.0
## 6.12.0
### Minor Changes
- Icons: New icon ChildHairEyes ([#3020](https://github.com/navikt/aksel/pull/3020))
### Patch Changes
- Icons: FigureCombination icon adjusted ([#3031](https://github.com/navikt/aksel/pull/3031))
## 6.11.0
## 6.10.1
### Patch Changes
- Icons: Added back support for sourcemapping. ([#2978](https://github.com/navikt/aksel/pull/2978))
## 6.10.0
## 6.9.0
### Minor Changes
- Icons: New icons for geometric shapes ([#2927](https://github.com/navikt/aksel/pull/2927))
## 6.8.0
## 6.7.1
## 6.7.0
## 6.6.1
## 6.6.0
## 6.5.0
## 6.4.1
## 6.4.0
## 6.3.6
## 6.3.5
## 6.3.4
## 6.3.3
## 6.3.2
## 6.3.1
@@ -31,5 +31,7 @@ describe(`Each icons YML-config is valid`, () => {
});
function isDate(dateStr) {
return !isNaN(new Date(dateStr.split(".").reverse().join(".")).getDate());
return !Number.isNaN(
new Date(dateStr.split(".").reverse().join(".")).getDate(),
);
}
@@ -5,11 +5,17 @@ import { resolveName } from "./icon-name.mjs";
export const makeConfig = (icons, folder) => {
icons.forEach((icon) => {
const name = resolveName(icon).replace(".svg", "");
const keywords = icon.description
.split(",")
.map((x) => x.trim())
.filter(Boolean);
const config = {
name: resolveName(icon).replace(".svg", ""),
name,
category: icon.containing_frame.pageName,
sub_category: icon.containing_frame.name,
keywords: [...icon.description.split(",").map((x) => x.trim())],
keywords: keywords.length > 0 ? keywords : [name],
variant: icon.name.includes("Variant=")
? icon.name.replace("Variant=", "")
: "Stroke",
@@ -27,7 +33,11 @@ export const makeConfig = (icons, folder) => {
.join("."),
};
const yml = jsYaml.dump(config, { noRefs: true, skipInvalid: false });
const yml = jsYaml.dump(config, {
noRefs: true,
skipInvalid: false,
quotingType: '"',
});
writeFileSync(resolve(folder, `${config.name}.yml`), yml, {
encoding: "utf8",
@@ -1,7 +1,10 @@
export function paginate(arr, size) {
return arr.reduce((acc, val, i) => {
let idx = Math.floor(i / size);
let page = acc[idx] || (acc[idx] = []);
if (!acc[idx]) {
acc[idx] = [];
}
let page = acc[idx];
page.push(val);
return acc;
+4 -1
View File
@@ -2,7 +2,10 @@ const path = require("path");
const defaultIndexTemplate = (paths) => {
const exportEntries = paths.map((filePath) => {
const basename = path.basename(filePath, path.extname(filePath));
const basename = path.basename(
filePath.originalPath,
path.extname(filePath.originalPath),
);
return `export { default as ${basename}Icon } from './${basename}'`;
});
@@ -28,7 +28,7 @@
"postcss": "^8.4.31",
"postcss-url": "^10.1.3",
"typescript": "^5.1.6",
"vite": "^5.0.12",
"vite": "^5.1.7",
"vite-plugin-singlefile": "^1.0.0",
"vite-plugin-svgr": "^4.2.0"
}
@@ -120,8 +120,8 @@ const App = () => {
onChange={(v) => setToggle(v as any)}
variant="neutral"
>
<ToggleGroup.Item value="stroke">Stroke</ToggleGroup.Item>
<ToggleGroup.Item value="fill">Fill</ToggleGroup.Item>
<ToggleGroup.Item value="stroke" label="Stroke" />
<ToggleGroup.Item value="fill" label="Fill" />
</ToggleGroup>
</div>
<div className="form-search">
+5 -4
View File
@@ -3,12 +3,13 @@ import React from "react";
import * as AkselIcons from "@navikt/aksel-icons";
import { StarFillIcon } from "@navikt/aksel-icons";
const meta = {
const meta: Meta<typeof StarFillIcon> = {
title: "aksel-icons/Icons",
} satisfies Meta<typeof StarFillIcon>;
parameters: { html: { disable: true } },
};
export default meta;
type Story = StoryObj<typeof meta>;
type Story = StoryObj<typeof StarFillIcon>;
export const Icons: Story = {
render: () => {
+1 -1
View File
@@ -11,5 +11,5 @@ keywords:
- åpnet
- opened
variant: Stroke
updated_at: 07.01.2024
updated_at: 02.05.2024
created_at: 07.03.2023
+1 -1
View File
@@ -9,5 +9,5 @@ keywords:
- nivå
- innrykk
variant: Stroke
updated_at: 16.01.2024
updated_at: 02.05.2024
created_at: 04.12.2023
+1 -1
View File
@@ -8,5 +8,5 @@ keywords:
- back
- tilbake
variant: Stroke
updated_at: 04.01.2024
updated_at: 31.05.2024
created_at: 07.03.2023
+1 -1
View File
@@ -9,5 +9,5 @@ keywords:
- frem
- fram
variant: Stroke
updated_at: 03.01.2024
updated_at: 10.06.2024
created_at: 07.03.2023
+1 -1
View File
@@ -12,5 +12,5 @@ keywords:
- ombestemt
- back
variant: Stroke
updated_at: 10.01.2024
updated_at: 11.06.2024
created_at: 07.03.2023
+1 -1
View File
@@ -10,5 +10,5 @@ keywords:
- close
- lukke
variant: Stroke
updated_at: 03.01.2024
updated_at: 06.06.2024
created_at: 07.03.2023
@@ -13,5 +13,5 @@ keywords:
- oppfrisking
- oppdatering
variant: Stroke
updated_at: 29.02.2024
updated_at: 17.04.2024
created_at: 07.03.2023
@@ -14,5 +14,5 @@ keywords:
- opptak
- gjenopptak
variant: Stroke
updated_at: 04.12.2023
updated_at: 31.05.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="M8 4.75C7.86193 4.75 7.75 4.86193 7.75 5V6.875C7.75 7.28921 7.41421 7.625 7 7.625C6.58579 7.625 6.25 7.28921 6.25 6.875V5C6.25 4.0335 7.0335 3.25 8 3.25H10C10.4142 3.25 10.75 3.58579 10.75 4C10.75 4.41421 10.4142 4.75 10 4.75H8ZM13.25 4C13.25 3.58579 13.5858 3.25 14 3.25H16C16.9665 3.25 17.75 4.0335 17.75 5V6.875C17.75 7.28921 17.4142 7.625 17 7.625C16.5858 7.625 16.25 7.28921 16.25 6.875V5C16.25 4.86193 16.1381 4.75 16 4.75H14C13.5858 4.75 13.25 4.41421 13.25 4ZM7 9.875C7.41421 9.875 7.75 10.2108 7.75 10.625V14.375C7.75 14.7892 7.41421 15.125 7 15.125C6.58579 15.125 6.25 14.7892 6.25 14.375V10.625C6.25 10.2108 6.58579 9.875 7 9.875ZM17 9.875C17.4142 9.875 17.75 10.2108 17.75 10.625V14.375C17.75 14.7892 17.4142 15.125 17 15.125C16.5858 15.125 16.25 14.7892 16.25 14.375V10.625C16.25 10.2108 16.5858 9.875 17 9.875ZM11.4697 14.4697C11.7626 14.1768 12.2374 14.1768 12.5303 14.4697L13.7803 15.7197C14.0732 16.0126 14.0732 16.4874 13.7803 16.7803C13.4874 17.0732 13.0126 17.0732 12.7197 16.7803L12 16.0607L11.2803 16.7803C10.9874 17.0732 10.5126 17.0732 10.2197 16.7803C9.92678 16.4874 9.92678 16.0126 10.2197 15.7197L11.4697 14.4697ZM7 17.375C7.41421 17.375 7.75 17.7108 7.75 18.125V18.191C8.04448 17.9271 8.49734 17.9367 8.78033 18.2197C9.07322 18.5126 9.07322 18.9874 8.78033 19.2803L7.53033 20.5303C7.31583 20.7448 6.99324 20.809 6.71299 20.6929C6.43273 20.5768 6.25 20.3033 6.25 20V18.125C6.25 17.7108 6.58579 17.375 7 17.375ZM17 17.375C17.4142 17.375 17.75 17.7108 17.75 18.125V20C17.75 20.3033 17.5673 20.5768 17.287 20.6929C17.0068 20.809 16.6842 20.7448 16.4697 20.5303L15.2197 19.2803C14.9268 18.9874 14.9268 18.5126 15.2197 18.2197C15.5027 17.9367 15.9555 17.9271 16.25 18.191V18.125C16.25 17.7108 16.5858 17.375 17 17.375Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 1.9 KiB

@@ -0,0 +1,14 @@
name: BookmarkDash
category: Interface
sub_category: Filtering and sorting
keywords:
- save
- bokmerke
- collection
- collect
- samling
- empty
- tom
variant: Stroke
updated_at: 15.05.2024
created_at: 15.05.2024
+1 -1
View File
@@ -2,7 +2,7 @@ name: Bug
category: Nature and animals
sub_category: Nature
keywords:
- ""
- Bug
variant: Stroke
updated_at: 04.12.2023
created_at: 27.02.2023
+1 -1
View File
@@ -2,7 +2,7 @@ name: BugFill
category: Nature and animals
sub_category: Nature
keywords:
- ""
- BugFill
variant: Fill
updated_at: 04.12.2023
created_at: 27.02.2023
+1 -1
View File
@@ -7,5 +7,5 @@ keywords:
- order
- punktliste
variant: Stroke
updated_at: 05.01.2024
updated_at: 19.04.2024
created_at: 07.03.2023
+1 -1
View File
@@ -15,5 +15,5 @@ keywords:
- fullføring
- validering
variant: Stroke
updated_at: 05.01.2024
updated_at: 10.06.2024
created_at: 07.03.2023
@@ -15,5 +15,5 @@ keywords:
- fullføring
- validering
variant: Stroke
updated_at: 04.12.2023
updated_at: 21.05.2024
created_at: 07.03.2023
@@ -15,5 +15,5 @@ keywords:
- fullføring
- validering
variant: Fill
updated_at: 04.12.2023
updated_at: 21.05.2024
created_at: 07.03.2023
+1 -1
View File
@@ -10,5 +10,5 @@ keywords:
- åpner
- mer
variant: Stroke
updated_at: 05.01.2024
updated_at: 19.06.2024
created_at: 07.03.2023
+1 -1
View File
@@ -6,5 +6,5 @@ keywords:
- venstre
- side
variant: Stroke
updated_at: 05.01.2024
updated_at: 29.05.2024
created_at: 07.03.2023
+1 -1
View File
@@ -6,5 +6,5 @@ keywords:
- høyre
- side
variant: Stroke
updated_at: 04.01.2024
updated_at: 10.06.2024
created_at: 07.03.2023
+1 -1
View File
@@ -10,5 +10,5 @@ keywords:
- lukk
- lukke
variant: Stroke
updated_at: 05.01.2024
updated_at: 16.04.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="M10.651 3.94427C8.68476 4.52559 7.25 6.34524 7.25 8.5C7.25 11.1234 9.37665 13.25 12 13.25C14.6234 13.25 16.75 11.1234 16.75 8.5C16.75 6.98351 16.0393 5.63301 14.9329 4.76335C14.9538 5.10864 14.9022 5.44954 14.7891 5.75643C14.1895 7.38197 12.1053 7.74555 10.677 6.5063C10.3641 6.23484 10.3305 5.76115 10.602 5.44829C10.8734 5.13543 11.3471 5.10186 11.66 5.37331C12.4681 6.07443 13.2206 5.67424 13.3817 5.23739C13.5006 4.91494 13.4405 4.49643 13.124 4.20959C12.8111 3.92606 12.1541 3.61035 10.651 3.94427ZM12 2.25C8.54822 2.25 5.75 5.04822 5.75 8.5C5.75 11.9518 8.54822 14.75 12 14.75C15.4518 14.75 18.25 11.9518 18.25 8.5C18.25 5.04822 15.4518 2.25 12 2.25ZM10.5 8.75C10.0858 8.75 9.75 9.08579 9.75 9.5C9.75 9.91421 10.0858 10.25 10.5 10.25H10.51C10.9242 10.25 11.26 9.91421 11.26 9.5C11.26 9.08579 10.9242 8.75 10.51 8.75H10.5ZM12.75 9.5C12.75 9.08579 13.0858 8.75 13.5 8.75H13.51C13.9242 8.75 14.26 9.08579 14.26 9.5C14.26 9.91421 13.9242 10.25 13.51 10.25H13.5C13.0858 10.25 12.75 9.91421 12.75 9.5ZM9.34835 18.3484C10.0516 17.6451 11.0054 17.25 12 17.25C12.9946 17.25 13.9484 17.6451 14.6516 18.3483C15.3549 19.0516 15.75 20.0054 15.75 21C15.75 21.4142 16.0858 21.75 16.5 21.75C16.9142 21.75 17.25 21.4142 17.25 21C17.25 19.6076 16.6969 18.2723 15.7123 17.2877C14.7277 16.3031 13.3924 15.75 12 15.75C10.6076 15.75 9.27226 16.3031 8.28769 17.2877C7.30312 18.2723 6.75 19.6076 6.75 21C6.75 21.4142 7.08579 21.75 7.5 21.75C7.91421 21.75 8.25 21.4142 8.25 21C8.25 20.0054 8.64509 19.0516 9.34835 18.3484Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 1.6 KiB

@@ -0,0 +1,12 @@
name: ChildHairEyes
category: People
sub_category: Children
keywords:
- human
- menneske
- øyne
- barn
- baby
variant: Stroke
updated_at: 20.06.2024
created_at: 20.06.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="M14.7365 4.51074C14.9187 4.01666 14.9409 3.43431 14.7577 2.88768C16.8265 3.90652 18.25 6.036 18.25 8.49796C18.25 11.9497 15.4518 14.748 12 14.748C8.54822 14.748 5.75 11.9497 5.75 8.49796C5.75 5.62729 7.68536 3.20864 10.3225 2.47564L10.3228 2.4771C11.98 2.10394 12.8426 2.42231 13.2398 2.78233C13.6388 3.14395 13.7136 3.67177 13.5637 4.07821C13.3388 4.68809 12.3735 5.11262 11.4336 4.29706C11.1728 4.07085 10.7781 4.09882 10.5519 4.35954C10.3257 4.62027 10.3537 5.015 10.6144 5.24122C12.0712 6.50522 14.1463 6.11119 14.7365 4.51074ZM10.5 8.74796C10.0858 8.74796 9.75 9.08374 9.75 9.49796C9.75 9.91217 10.0858 10.248 10.5 10.248H10.51C10.9242 10.248 11.26 9.91217 11.26 9.49796C11.26 9.08374 10.9242 8.74796 10.51 8.74796H10.5ZM12.75 9.49796C12.75 9.08374 13.0858 8.74796 13.5 8.74796H13.51C13.9242 8.74796 14.26 9.08374 14.26 9.49796C14.26 9.91217 13.9242 10.248 13.51 10.248H13.5C13.0858 10.248 12.75 9.91217 12.75 9.49796ZM12 15.748C10.6076 15.748 9.27226 16.3011 8.28769 17.2856C7.30312 18.2702 6.75 19.6056 6.75 20.998C6.75 21.1969 6.82902 21.3876 6.96967 21.5283C7.11032 21.6689 7.30109 21.748 7.5 21.748L16.5 21.748C16.6989 21.748 16.8897 21.6689 17.0303 21.5283C17.171 21.3876 17.25 21.1969 17.25 20.998C17.25 19.6056 16.6969 18.2702 15.7123 17.2856C14.7277 16.3011 13.3924 15.748 12 15.748Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 1.4 KiB

@@ -0,0 +1,12 @@
name: ChildHairEyesFill
category: People
sub_category: Children
keywords:
- human
- menneske
- øyne
- barn
- baby
variant: Fill
updated_at: 20.06.2024
created_at: 20.06.2024
+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="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 12Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 473 B

+8
View File
@@ -0,0 +1,8 @@
name: Circle
category: Status
sub_category: Shapes
keywords:
- Sirkel
variant: Stroke
updated_at: 15.05.2024
created_at: 15.05.2024
+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="M1.5 12C1.5 6.20101 6.20101 1.5 12 1.5C17.799 1.5 22.5 6.20101 22.5 12C22.5 17.799 17.799 22.5 12 22.5C6.20101 22.5 1.5 17.799 1.5 12Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 305 B

+8
View File
@@ -0,0 +1,8 @@
name: CircleFill
category: Status
sub_category: Shapes
keywords:
- Sirkel
variant: Fill
updated_at: 15.05.2024
created_at: 15.05.2024
+1 -1
View File
@@ -8,5 +8,5 @@ keywords:
- historikk
- visited
variant: Stroke
updated_at: 09.01.2024
updated_at: 17.04.2024
created_at: 07.03.2023
@@ -11,5 +11,5 @@ keywords:
- handel
- økonomi
variant: Stroke
updated_at: 05.01.2024
updated_at: 07.05.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="M11.4698 1.57026C11.7626 1.27736 12.2375 1.27736 12.5304 1.57026L22.4299 11.4698C22.7228 11.7626 22.7228 12.2375 22.4299 12.5304L12.5304 22.4299C12.2375 22.7228 11.7626 22.7228 11.4698 22.4299L1.57026 12.5304C1.27736 12.2375 1.27736 11.7626 1.57026 11.4698L11.4698 1.57026ZM3.16125 12.0001L12.0001 20.8389L20.8389 12.0001L12.0001 3.16125L3.16125 12.0001Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 525 B

+8
View File
@@ -0,0 +1,8 @@
name: Diamond
category: Status
sub_category: Shapes
keywords:
- diamant
variant: Stroke
updated_at: 15.05.2024
created_at: 15.05.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="M1.57026 12.5303C1.27736 12.2374 1.27736 11.7625 1.57026 11.4696L11.4698 1.57013C11.7626 1.27724 12.2375 1.27724 12.5304 1.57013L22.4299 11.4696C22.7228 11.7625 22.7228 12.2374 22.4299 12.5303L12.5304 22.4298C12.2375 22.7227 11.7626 22.7227 11.4698 22.4298L1.57026 12.5303Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 444 B

@@ -0,0 +1,8 @@
name: DiamondFill
category: Status
sub_category: Shapes
keywords:
- diamant
variant: Fill
updated_at: 15.05.2024
created_at: 15.05.2024
+1 -1
View File
@@ -5,5 +5,5 @@ keywords:
- dele
- division
variant: Stroke
updated_at: 05.01.2024
updated_at: 12.04.2024
created_at: 07.03.2023
+1 -1
View File
@@ -13,5 +13,5 @@ keywords:
- dra og slippe
- skifte
variant: Stroke
updated_at: 05.01.2024
updated_at: 23.04.2024
created_at: 07.03.2023
+1 -1
View File
@@ -14,5 +14,5 @@ keywords:
- pålogging
- adgang
variant: Stroke
updated_at: 05.01.2024
updated_at: 23.04.2024
created_at: 07.03.2023
@@ -13,5 +13,5 @@ keywords:
- oppmerksomhet
- viktig
variant: Stroke
updated_at: 05.01.2024
updated_at: 16.04.2024
created_at: 07.03.2023
+1 -1
View File
@@ -7,5 +7,5 @@ keywords:
- lukket
- hidden
variant: Stroke
updated_at: 05.01.2024
updated_at: 15.04.2024
created_at: 07.03.2023
+1 -1
View File
@@ -8,5 +8,5 @@ keywords:
- gutt
- barn
variant: Stroke
updated_at: 16.01.2024
updated_at: 20.06.2024
created_at: 16.01.2024
@@ -8,5 +8,5 @@ keywords:
- gutt
- barn
variant: Fill
updated_at: 16.01.2024
updated_at: 20.06.2024
created_at: 16.01.2024
@@ -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="M12 3.75C11.3096 3.75 10.75 4.30964 10.75 5C10.75 5.69036 11.3096 6.25 12 6.25C12.6904 6.25 13.25 5.69036 13.25 5C13.25 4.30964 12.6904 3.75 12 3.75ZM9.25 5C9.25 3.48122 10.4812 2.25 12 2.25C13.5188 2.25 14.75 3.48122 14.75 5C14.75 6.51878 13.5188 7.75 12 7.75C10.4812 7.75 9.25 6.51878 9.25 5ZM12.75 9C12.75 8.58579 13.0858 8.25 13.5 8.25H14.847C15.912 8.25 16.73 9.19323 16.5794 10.2475L15.7425 16.1061C15.6897 16.4756 15.3732 16.75 15 16.75H14.25V21C14.25 21.4142 13.9142 21.75 13.5 21.75C13.0858 21.75 12.75 21.4142 12.75 21V16C12.75 15.5858 13.0858 15.25 13.5 15.25H14.3495L15.0945 10.0354C15.116 9.88475 14.9991 9.75 14.847 9.75H13.5C13.0858 9.75 12.75 9.41421 12.75 9ZM9.96929 9.91592C10.0048 9.81642 10.0991 9.75 10.2047 9.75H10.5C10.9142 9.75 11.25 9.41421 11.25 9C11.25 8.58579 10.9142 8.25 10.5 8.25H10.2047C9.46515 8.25 8.80542 8.71492 8.55668 9.41141L6.2937 15.7477C6.21167 15.9774 6.24645 16.2327 6.38694 16.432C6.52744 16.6314 6.75611 16.75 7 16.75H9.75V21C9.75 21.4142 10.0858 21.75 10.5 21.75C10.9142 21.75 11.25 21.4142 11.25 21V16C11.25 15.5858 10.9142 15.25 10.5 15.25H8.06426L9.96929 9.91592Z" fill="#23262A"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M12.55 3.75C11.8596 3.75 11.3 4.30964 11.3 5C11.3 5.69036 11.8596 6.25 12.55 6.25C13.2404 6.25 13.8 5.69036 13.8 5C13.8 4.30964 13.2404 3.75 12.55 3.75ZM9.8 5C9.8 3.48122 11.0312 2.25 12.55 2.25C14.0688 2.25 15.3 3.48122 15.3 5C15.3 6.51878 14.0688 7.75 12.55 7.75C11.0312 7.75 9.8 6.51878 9.8 5ZM13.3 9C13.3 8.58579 13.6358 8.25 14.05 8.25H16.05C16.4642 8.25 16.8 8.58579 16.8 9V16.1061C16.8 16.5203 16.4642 16.8561 16.05 16.8561H14.8V21C14.8 21.4142 14.4642 21.75 14.05 21.75C13.6358 21.75 13.3 21.4142 13.3 21V16.1061C13.3 15.6919 13.6358 15.3561 14.05 15.3561H15.3V9.75H14.05C13.6358 9.75 13.3 9.41421 13.3 9ZM10.5193 9.91592C10.5548 9.81642 10.6491 9.75 10.7547 9.75H11.05C11.4642 9.75 11.8 9.41421 11.8 9C11.8 8.58579 11.4642 8.25 11.05 8.25H10.7547C10.0152 8.25 9.35542 8.71492 9.10668 9.41141L6.8437 15.7477C6.76167 15.9774 6.79645 16.2327 6.93695 16.432C7.07744 16.6314 7.30611 16.75 7.55001 16.75H10.3V21C10.3 21.4142 10.6358 21.75 11.05 21.75C11.4642 21.75 11.8 21.4142 11.8 21V16C11.8 15.5858 11.4642 15.25 11.05 15.25H8.61426L10.5193 9.91592Z" fill="#23262A"/>
</svg>

Before

Width:  |  Height:  |  Size: 1.3 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

@@ -7,6 +7,7 @@ keywords:
- trans
- intetkjønn
- hen
- person
variant: Stroke
updated_at: 04.12.2023
updated_at: 25.06.2024
created_at: 07.03.2023
@@ -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="M9.25 5C9.25 3.48122 10.4812 2.25 12 2.25C13.5188 2.25 14.75 3.48122 14.75 5C14.75 6.51878 13.5188 7.75 12 7.75C10.4812 7.75 9.25 6.51878 9.25 5ZM13.5 8.25C13.3011 8.25 13.1103 8.32902 12.9697 8.46967C12.829 8.61032 12.75 8.80109 12.75 9V21C12.75 21.4142 13.0858 21.75 13.5 21.75C13.9142 21.75 14.25 21.4142 14.25 21V16.75H15C15.3732 16.75 15.6897 16.4756 15.7425 16.1061L16.5794 10.2475C16.73 9.19323 15.912 8.25 14.847 8.25H13.5ZM8.55668 9.41141C8.80542 8.71492 9.46515 8.25 10.2047 8.25H10.5C10.9142 8.25 11.25 8.58579 11.25 9L11.25 21C11.25 21.4142 10.9142 21.75 10.5 21.75C10.0858 21.75 9.75 21.4142 9.75 21V16.75H7C6.75611 16.75 6.52744 16.6314 6.38694 16.432C6.24645 16.2327 6.21167 15.9774 6.2937 15.7477L8.55668 9.41141Z" fill="#23262A"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M9.8 5C9.8 3.48122 11.0312 2.25 12.55 2.25C14.0688 2.25 15.3 3.48122 15.3 5C15.3 6.51878 14.0688 7.75 12.55 7.75C11.0312 7.75 9.8 6.51878 9.8 5ZM13.3 9C13.3 8.58579 13.6358 8.25 14.05 8.25H16.05C16.4642 8.25 16.8 8.58579 16.8 9V16C16.8 16.4142 16.4642 16.75 16.05 16.75H14.8V21C14.8 21.4142 14.4642 21.75 14.05 21.75C13.6358 21.75 13.3 21.4142 13.3 21V9ZM9.10668 9.41141C9.35542 8.71492 10.0152 8.25 10.7547 8.25H11.05C11.4642 8.25 11.8 8.58579 11.8 9L11.8 21C11.8 21.4142 11.4642 21.75 11.05 21.75C10.6358 21.75 10.3 21.4142 10.3 21V16.75H7.55001C7.30611 16.75 7.07744 16.6314 6.93695 16.432C6.79645 16.2327 6.76167 15.9774 6.8437 15.7477L9.10668 9.41141Z" fill="#23262A"/>
</svg>

Before

Width:  |  Height:  |  Size: 900 B

After

Width:  |  Height:  |  Size: 827 B

@@ -7,6 +7,7 @@ keywords:
- trans
- intetkjønn
- hen
- person
variant: Fill
updated_at: 04.12.2023
updated_at: 25.06.2024
created_at: 07.03.2023
+1 -1
View File
@@ -9,5 +9,5 @@ keywords:
- herre
- han
variant: Stroke
updated_at: 04.12.2023
updated_at: 20.06.2024
created_at: 07.03.2023
@@ -9,5 +9,5 @@ keywords:
- herre
- han
variant: Fill
updated_at: 04.12.2023
updated_at: 20.06.2024
created_at: 07.03.2023
+1 -1
View File
@@ -8,5 +8,5 @@ keywords:
- female
- hun
variant: Stroke
updated_at: 04.12.2023
updated_at: 20.06.2024
created_at: 07.03.2023
@@ -8,5 +8,5 @@ keywords:
- female
- hun
variant: Fill
updated_at: 04.12.2023
updated_at: 20.06.2024
created_at: 07.03.2023
@@ -8,7 +8,6 @@ keywords:
- file
- laster
- loading
- ""
variant: Stroke
updated_at: 04.12.2023
created_at: 07.03.2023
@@ -8,7 +8,6 @@ keywords:
- file
- laster
- loading
- ""
variant: Fill
updated_at: 04.12.2023
created_at: 07.03.2023
+1 -1
View File
@@ -7,5 +7,5 @@ keywords:
- data
- tabell
variant: Stroke
updated_at: 05.01.2024
updated_at: 17.04.2024
created_at: 07.03.2023
+1 -1
View File
@@ -13,5 +13,5 @@ keywords:
- organisering
- sosiale medier
variant: Stroke
updated_at: 05.01.2024
updated_at: 05.06.2024
created_at: 07.03.2023
+1 -1
View File
@@ -15,5 +15,5 @@ keywords:
- beskrivelse
- forklaring
variant: Stroke
updated_at: 04.01.2024
updated_at: 16.04.2024
created_at: 07.03.2023
+1 -1
View File
@@ -15,5 +15,5 @@ keywords:
- avslutt
- avslutt
variant: Stroke
updated_at: 05.01.2024
updated_at: 25.04.2024
created_at: 07.03.2023
+1 -1
View File
@@ -13,5 +13,5 @@ keywords:
- graf
- analyse
variant: Stroke
updated_at: 05.01.2024
updated_at: 25.04.2024
created_at: 07.03.2023
@@ -13,5 +13,5 @@ keywords:
- graf
- analyse
variant: Stroke
updated_at: 05.01.2024
updated_at: 25.04.2024
created_at: 07.03.2023
+1 -1
View File
@@ -6,5 +6,5 @@ keywords:
- chain
- kobling
variant: Stroke
updated_at: 05.01.2024
updated_at: 21.05.2024
created_at: 07.03.2023
@@ -12,5 +12,5 @@ keywords:
- nedtrekksvalg
- ellipse
variant: Stroke
updated_at: 05.01.2024
updated_at: 17.04.2024
created_at: 07.03.2023
+1 -1
View File
@@ -6,5 +6,5 @@ keywords:
- meny
- hamburger
variant: Stroke
updated_at: 05.01.2024
updated_at: 25.04.2024
created_at: 07.03.2023
+1 -1
View File
@@ -7,5 +7,5 @@ keywords:
- delete
- slett
variant: Stroke
updated_at: 05.01.2024
updated_at: 12.04.2024
created_at: 07.03.2023
+1 -1
View File
@@ -5,5 +5,5 @@ keywords:
- gange
- multiplisere
variant: Stroke
updated_at: 05.01.2024
updated_at: 12.04.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="M16.9697 2.96968C18.091 1.84836 19.909 1.84836 21.0303 2.96968C22.1517 4.091 22.1517 5.90902 21.0303 7.03034L19.5303 8.53033L15.1973 12.8634C15.0052 13.0555 14.771 13.2003 14.5132 13.2862L10.2372 14.7115C9.96767 14.8014 9.67055 14.7312 9.46968 14.5303C9.2688 14.3295 9.19866 14.0323 9.28849 13.7628L10.7138 9.48679C10.7998 9.22906 10.9445 8.99486 11.1366 8.80276L15.4666 4.47277C15.4676 4.47174 15.4686 4.4707 15.4697 4.46967C15.4707 4.46864 15.4717 4.46761 15.4728 4.46658L16.9697 2.96968ZM16 6.06067L12.1973 9.86342C12.1698 9.89086 12.1491 9.92432 12.1369 9.96114L11.1859 12.8142L14.0389 11.8632C14.0757 11.8509 14.1092 11.8302 14.1366 11.8028L17.9393 8.00001L16 6.06067ZM19 6.93935L17.0607 5.00001L18.0303 4.03034C18.5659 3.49481 19.4341 3.49481 19.9697 4.03034C20.5052 4.56588 20.5052 5.43415 19.9697 5.96968L19 6.93935ZM3.25 5C3.25 4.0335 4.0335 3.25 5 3.25H12C12.4142 3.25 12.75 3.58579 12.75 4C12.75 4.41421 12.4142 4.75 12 4.75H5C4.86193 4.75 4.75 4.86193 4.75 5V19C4.75 19.1381 4.86193 19.25 5 19.25H19C19.1381 19.25 19.25 19.1381 19.25 19V12C19.25 11.5858 19.5858 11.25 20 11.25C20.4142 11.25 20.75 11.5858 20.75 12V19C20.75 19.9665 19.9665 20.75 19 20.75H5C4.0335 20.75 3.25 19.9665 3.25 19V5Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 1.3 KiB

+13
View File
@@ -0,0 +1,13 @@
name: NotePencil
category: Interface
sub_category: Editing
keywords:
- note
- notat
- edit
- editing
- manage file
- redigere
variant: Stroke
updated_at: 15.05.2024
created_at: 15.05.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="M16.9697 2.96968C18.091 1.84836 19.909 1.84836 21.0303 2.96968C22.1517 4.091 22.1517 5.90902 21.0303 7.03034L19.5303 8.53033L15.0303 13.0303C14.948 13.1127 14.8476 13.1747 14.7372 13.2115L10.2372 14.7115C9.96767 14.8014 9.67055 14.7312 9.46968 14.5303C9.2688 14.3295 9.19866 14.0323 9.28849 13.7628L10.7885 9.26284C10.8253 9.15238 10.8873 9.05201 10.9697 8.96968L15.4666 4.47277C15.4676 4.47173 15.4686 4.4707 15.4697 4.46967C15.4707 4.46864 15.4717 4.46761 15.4728 4.46659L16.9697 2.96968ZM16 6.06067L12.1555 9.90515L11.1859 12.8142L14.0949 11.8445L17.9393 8.00001L16 6.06067ZM19 6.93935L17.0607 5.00001L18.0303 4.03034C18.5659 3.49481 19.4341 3.49481 19.9697 4.03034C20.5052 4.56588 20.5052 5.43415 19.9697 5.96968L19 6.93935ZM3.25 5C3.25 4.0335 4.0335 3.25 5 3.25H6.75C7.16421 3.25 7.5 3.58579 7.5 4C7.5 4.41421 7.16421 4.75 6.75 4.75H5C4.86193 4.75 4.75 4.86193 4.75 5V6.75C4.75 7.16421 4.41421 7.5 4 7.5C3.58579 7.5 3.25 7.16421 3.25 6.75V5ZM9.5 4C9.5 3.58579 9.83579 3.25 10.25 3.25H12C12.4142 3.25 12.75 3.58579 12.75 4C12.75 4.41421 12.4142 4.75 12 4.75H10.25C9.83579 4.75 9.5 4.41421 9.5 4ZM4 9.5C4.41421 9.5 4.75 9.83579 4.75 10.25V13.75C4.75 14.1642 4.41421 14.5 4 14.5C3.58579 14.5 3.25 14.1642 3.25 13.75V10.25C3.25 9.83579 3.58579 9.5 4 9.5ZM20 11.25C20.4142 11.25 20.75 11.5858 20.75 12V13.75C20.75 14.1642 20.4142 14.5 20 14.5C19.5858 14.5 19.25 14.1642 19.25 13.75V12C19.25 11.5858 19.5858 11.25 20 11.25ZM4 16.5C4.41421 16.5 4.75 16.8358 4.75 17.25V19C4.75 19.1381 4.86193 19.25 5 19.25H6.75C7.16421 19.25 7.5 19.5858 7.5 20C7.5 20.4142 7.16421 20.75 6.75 20.75H5C4.0335 20.75 3.25 19.9665 3.25 19V17.25C3.25 16.8358 3.58579 16.5 4 16.5ZM20 16.5C20.4142 16.5 20.75 16.8358 20.75 17.25V19C20.75 19.9665 19.9665 20.75 19 20.75H17.25C16.8358 20.75 16.5 20.4142 16.5 20C16.5 19.5858 16.8358 19.25 17.25 19.25H19C19.1381 19.25 19.25 19.1381 19.25 19V17.25C19.25 16.8358 19.5858 16.5 20 16.5ZM9.5 20C9.5 19.5858 9.83579 19.25 10.25 19.25H13.75C14.1642 19.25 14.5 19.5858 14.5 20C14.5 20.4142 14.1642 20.75 13.75 20.75H10.25C9.83579 20.75 9.5 20.4142 9.5 20Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 2.2 KiB

@@ -0,0 +1,15 @@
name: NotePencilDash
category: Interface
sub_category: Editing
keywords:
- note
- notat
- edit
- editing
- manage file
- redigere
- empty
- tom
variant: Stroke
updated_at: 15.05.2024
created_at: 15.05.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="M18.2929 8.70711C18.3905 8.60948 18.3905 8.45118 18.2929 8.35355L15.6465 5.70711C15.5488 5.60948 15.3905 5.60948 15.2929 5.70711L11.6669 9.33309C11.5571 9.44286 11.4744 9.57669 11.4253 9.72397L10.1581 13.5257C10.093 13.7211 10.2789 13.907 10.4743 13.8419L14.276 12.5747C14.4233 12.5256 14.5571 12.4429 14.6669 12.3331L18.2929 8.70711ZM19.3536 7.29289C19.4512 7.39052 19.6095 7.39053 19.7071 7.2929L20.5 6.50001C21.3284 5.67159 21.3284 4.32844 20.5 3.50001C19.6716 2.67159 18.3284 2.67159 17.5 3.50001L16.7071 4.2929C16.6095 4.39053 16.6095 4.54882 16.7071 4.64645L19.3536 7.29289ZM15.2019 3.67678C15.3594 3.51929 15.2479 3.25 15.0251 3.25H5C4.0335 3.25 3.25 4.0335 3.25 5V19C3.25 19.9665 4.0335 20.75 5 20.75H19C19.9665 20.75 20.75 19.9665 20.75 19V8.97488C20.75 8.75216 20.4807 8.64062 20.3232 8.79811L15.7276 13.3937C15.4531 13.6682 15.1186 13.875 14.7504 13.9977L10.9487 15.2649C9.5806 15.721 8.27906 14.4194 8.73509 13.0513L10.0023 9.24962C10.1251 8.88143 10.3318 8.54686 10.6063 8.27243L15.2019 3.67678Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 1.2 KiB

@@ -0,0 +1,13 @@
name: NotePencilFill
category: Interface
sub_category: Editing
keywords:
- note
- notat
- edit
- editing
- manage file
- redigere
variant: Fill
updated_at: 15.05.2024
created_at: 15.05.2024
+1 -1
View File
@@ -7,5 +7,5 @@ keywords:
- order
- nummerliste
variant: Stroke
updated_at: 05.01.2024
updated_at: 19.04.2024
created_at: 28.04.2023
+1 -1
View File
@@ -13,5 +13,5 @@ keywords:
- papir
- kontorrekvisita
variant: Stroke
updated_at: 04.01.2024
updated_at: 12.06.2024
created_at: 07.03.2023
+1 -1
View File
@@ -2,7 +2,7 @@ name: Pause
category: Media
sub_category: Control
keywords:
- ""
- Pause
variant: Stroke
updated_at: 04.12.2023
created_at: 07.03.2023
+1 -1
View File
@@ -2,7 +2,7 @@ name: PauseFill
category: Media
sub_category: Control
keywords:
- ""
- PauseFill
variant: Fill
updated_at: 04.12.2023
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="M11.5609 1.89199C11.823 1.70267 12.177 1.70267 12.4391 1.89199L21.4391 8.39199C21.7049 8.58392 21.8152 8.92619 21.7115 9.23717L18.2115 19.7372C18.1094 20.0434 17.8228 20.25 17.5 20.25H6.49999C6.17717 20.25 5.89057 20.0434 5.78848 19.7372L2.28848 9.23717C2.18482 8.92619 2.29513 8.58392 2.56087 8.39199L11.5609 1.89199ZM3.88572 9.28546L7.04056 18.75H16.9594L20.1143 9.28546L12 3.42515L3.88572 9.28546Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 571 B

+8
View File
@@ -0,0 +1,8 @@
name: Pentagon
category: Status
sub_category: Shapes
keywords:
- femkant
variant: Stroke
updated_at: 15.05.2024
created_at: 15.05.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="M11.5609 1.89199C11.823 1.70267 12.177 1.70267 12.4391 1.89199L21.4391 8.39199C21.7049 8.58392 21.8152 8.92619 21.7115 9.23717L18.2115 19.7372C18.1094 20.0434 17.8228 20.25 17.5 20.25H6.49999C6.17717 20.25 5.89057 20.0434 5.78848 19.7372L2.28848 9.23717C2.18482 8.92619 2.29513 8.58392 2.56087 8.39199L11.5609 1.89199Z" fill="#23262A"/>
</svg>

After

Width:  |  Height:  |  Size: 489 B

@@ -0,0 +1,8 @@
name: PentagonFill
category: Status
sub_category: Shapes
keywords:
- femkant
variant: Fill
updated_at: 15.05.2024
created_at: 15.05.2024
+1 -1
View File
@@ -6,5 +6,5 @@ keywords:
- legg til
- more
variant: Stroke
updated_at: 03.01.2024
updated_at: 12.04.2024
created_at: 07.03.2023
Loaded 100 of 870 files, more files were not shown because too many files have changed in this diff. Show more