Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6e9b0e9b1c | ||
|
|
ad0375e918 | ||
|
|
0cb04db261 | ||
|
|
50113b4501 | ||
|
|
b745daa35c | ||
|
|
1d41f0d8f5 | ||
|
|
85eeb68f20 | ||
|
|
9f958c1242 | ||
|
|
489ac3a426 | ||
|
|
68b61de895 | ||
|
|
528d4afa98 | ||
|
|
3d3e26a555 | ||
|
|
adaee5e002 | ||
|
|
e826eb7bc6 | ||
|
|
edd64c4bcd | ||
|
|
4eba5a929c | ||
|
|
a560bce1d2 | ||
|
|
1d3abd7a68 | ||
|
|
8f3913c437 | ||
|
|
56971a105d | ||
|
|
31ec44dd62 | ||
|
|
e769eed269 | ||
|
|
b374aaa03e | ||
|
|
a6ab5335e0 | ||
|
|
9f37b3805e | ||
|
|
c6ccfe53bc | ||
|
|
0279b19579 | ||
|
|
80f12069e1 | ||
|
|
7915b7e47b | ||
|
|
3c646465b4 | ||
|
|
d37d03f05c | ||
|
|
c1b2944321 | ||
|
|
c0078f1199 | ||
|
|
e7f42ab02e | ||
|
|
abd5de2304 | ||
|
|
7f895df4a9 | ||
|
|
ffd7e818e3 | ||
|
|
7894bbb510 | ||
|
|
9f4535e6bb |
No files matched your search
@@ -179,6 +179,8 @@ module.exports = {
|
||||
"esm",
|
||||
"cjs",
|
||||
"dist",
|
||||
"@navikt/aksel/**/*.input.*",
|
||||
"@navikt/aksel/**/*.output.*",
|
||||
"**/codemod/**/*.js",
|
||||
"!.storybook",
|
||||
"**/playwright-report/**",
|
||||
|
||||
@@ -32,7 +32,7 @@ jobs:
|
||||
cache: yarn
|
||||
cache-dependency-path: "**/yarn.lock"
|
||||
|
||||
- uses: denoland/setup-deno@v1
|
||||
- uses: denoland/setup-deno@v2
|
||||
with:
|
||||
deno-version: v1.x
|
||||
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
**/nais*.yaml
|
||||
**/nais*.yml
|
||||
**/codemod/**/tests/**/*.js
|
||||
**/@navikt/aksel/**/*.input.*
|
||||
**/@navikt/aksel/**/*.output.*
|
||||
node_modules
|
||||
.next
|
||||
dist
|
||||
|
||||
@@ -1,5 +1,15 @@
|
||||
# @navikt/aksel-icons
|
||||
|
||||
## 7.17.4
|
||||
|
||||
## 7.17.3
|
||||
|
||||
## 7.17.2
|
||||
|
||||
## 7.17.1
|
||||
|
||||
## 7.17.0
|
||||
|
||||
## 7.16.1
|
||||
|
||||
## 7.16.0
|
||||
|
||||
@@ -13,5 +13,5 @@ keywords:
|
||||
- reload
|
||||
- oppdater
|
||||
variant: Stroke
|
||||
updated_at: 29.07.2024
|
||||
updated_at: 05.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -11,5 +11,5 @@ keywords:
|
||||
- åpnet
|
||||
- opened
|
||||
variant: Stroke
|
||||
updated_at: 15.08.2024
|
||||
updated_at: 12.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -9,5 +9,5 @@ keywords:
|
||||
- nivå
|
||||
- innrykk
|
||||
variant: Stroke
|
||||
updated_at: 06.08.2024
|
||||
updated_at: 12.03.2025
|
||||
created_at: 04.12.2023
|
||||
@@ -8,5 +8,5 @@ keywords:
|
||||
- back
|
||||
- tilbake
|
||||
variant: Stroke
|
||||
updated_at: 25.07.2024
|
||||
updated_at: 03.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -13,5 +13,5 @@ keywords:
|
||||
- forward
|
||||
- videresend
|
||||
variant: Stroke
|
||||
updated_at: 05.09.2024
|
||||
updated_at: 07.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -9,5 +9,5 @@ keywords:
|
||||
- frem
|
||||
- fram
|
||||
variant: Stroke
|
||||
updated_at: 02.08.2024
|
||||
updated_at: 04.03.2025
|
||||
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="M16.4699 2.96959C16.7627 2.67669 17.2376 2.67669 17.5305 2.96959L21.0305 6.46959C21.3234 6.76248 21.3234 7.23735 21.0305 7.53025L17.5305 11.0302C17.2376 11.3231 16.7627 11.3231 16.4699 11.0302C16.177 10.7374 16.177 10.2625 16.4699 9.96959L18.6895 7.74992L9.50018 7.74992C9.08597 7.74992 8.75018 7.41413 8.75018 6.99992C8.75018 6.5857 9.08597 6.24992 9.50018 6.24992L18.6895 6.24992L16.4699 4.03025C16.177 3.73735 16.177 3.26248 16.4699 2.96959ZM7.53051 12.9696C7.82341 13.2625 7.82341 13.7374 7.53051 14.0302L5.31084 16.2499L14.5002 16.2499C14.9144 16.2499 15.2502 16.5857 15.2502 16.9999C15.2502 17.4141 14.9144 17.7499 14.5002 17.7499L5.31084 17.7499L7.53051 19.9696C7.82341 20.2625 7.82341 20.7374 7.53051 21.0302C7.23762 21.3231 6.76275 21.3231 6.46985 21.0302L2.96985 17.5302C2.8292 17.3896 2.75018 17.1988 2.75018 16.9999C2.75018 16.801 2.8292 16.6102 2.96985 16.4696L6.46985 12.9696C6.76275 12.6767 7.23762 12.6767 7.53051 12.9696Z" fill="#23262A"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M7.53015 21.0304C7.23725 21.3233 6.76238 21.3233 6.46949 21.0304L2.96949 17.5304C2.67659 17.2375 2.67659 16.7627 2.96949 16.4698L6.46949 12.9698C6.76238 12.6769 7.23725 12.6769 7.53015 12.9698C7.82304 13.2627 7.82304 13.7375 7.53015 14.0304L5.31048 16.2501L14.4998 16.2501C14.914 16.2501 15.2498 16.5859 15.2498 17.0001C15.2498 17.4143 14.914 17.7501 14.4998 17.7501L5.31048 17.7501L7.53015 19.9698C7.82304 20.2627 7.82304 20.7375 7.53015 21.0304ZM16.4695 11.0304C16.1766 10.7375 16.1766 10.2627 16.4695 9.96976L18.6892 7.75009L9.49982 7.75009C9.0856 7.75009 8.74982 7.4143 8.74982 7.00009C8.74982 6.58588 9.0856 6.25009 9.49982 6.25009L18.6892 6.25009L16.4695 4.03042C16.1766 3.73753 16.1766 3.26266 16.4695 2.96976C16.7624 2.67687 17.2373 2.67687 17.5301 2.96976L21.0301 6.46976C21.1708 6.61041 21.2498 6.80118 21.2498 7.00009C21.2498 7.19901 21.1708 7.38977 21.0301 7.53042L17.5301 11.0304C17.2373 11.3233 16.7624 11.3233 16.4695 11.0304Z" fill="#23262A"/>
|
||||
</svg>
|
||||
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
@@ -11,5 +11,5 @@ keywords:
|
||||
- overføring
|
||||
- overgang
|
||||
variant: Stroke
|
||||
updated_at: 13.08.2024
|
||||
updated_at: 18.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -12,5 +12,5 @@ keywords:
|
||||
- ombestemt
|
||||
- back
|
||||
variant: Stroke
|
||||
updated_at: 07.08.2024
|
||||
updated_at: 13.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -10,5 +10,5 @@ keywords:
|
||||
- close
|
||||
- lukke
|
||||
variant: Stroke
|
||||
updated_at: 25.07.2024
|
||||
updated_at: 06.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -13,5 +13,5 @@ keywords:
|
||||
- oppfrisking
|
||||
- oppdatering
|
||||
variant: Stroke
|
||||
updated_at: 26.07.2024
|
||||
updated_at: 04.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -14,5 +14,5 @@ keywords:
|
||||
- opptak
|
||||
- gjenopptak
|
||||
variant: Stroke
|
||||
updated_at: 14.08.2024
|
||||
updated_at: 13.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -15,5 +15,5 @@ keywords:
|
||||
- Sammenføye
|
||||
- Kildekontroll
|
||||
variant: Stroke
|
||||
updated_at: 29.07.2024
|
||||
updated_at: 10.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -15,5 +15,5 @@ keywords:
|
||||
- fullføring
|
||||
- validering
|
||||
variant: Stroke
|
||||
updated_at: 17.07.2024
|
||||
updated_at: 03.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -10,5 +10,5 @@ keywords:
|
||||
- åpner
|
||||
- mer
|
||||
variant: Stroke
|
||||
updated_at: 18.07.2024
|
||||
updated_at: 02.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -8,5 +8,5 @@ keywords:
|
||||
- Utvide/skjule
|
||||
- vise/skjule
|
||||
variant: Stroke
|
||||
updated_at: 04.12.2023
|
||||
updated_at: 18.03.2025
|
||||
created_at: 04.12.2023
|
||||
@@ -6,5 +6,5 @@ keywords:
|
||||
- venstre
|
||||
- side
|
||||
variant: Stroke
|
||||
updated_at: 22.07.2024
|
||||
updated_at: 04.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -6,5 +6,5 @@ keywords:
|
||||
- høyre
|
||||
- side
|
||||
variant: Stroke
|
||||
updated_at: 23.07.2024
|
||||
updated_at: 03.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -6,5 +6,5 @@ keywords:
|
||||
- høyre
|
||||
- side
|
||||
variant: Stroke
|
||||
updated_at: 04.01.2024
|
||||
updated_at: 11.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -10,5 +10,5 @@ keywords:
|
||||
- lukk
|
||||
- lukke
|
||||
variant: Stroke
|
||||
updated_at: 01.08.2024
|
||||
updated_at: 03.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -8,5 +8,5 @@ keywords:
|
||||
- Utvide/skjule
|
||||
- vise/skjule
|
||||
variant: Stroke
|
||||
updated_at: 30.07.2024
|
||||
updated_at: 18.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -10,5 +10,5 @@ keywords:
|
||||
- nettverk
|
||||
- network
|
||||
variant: Stroke
|
||||
updated_at: 29.07.2024
|
||||
updated_at: 17.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -8,5 +8,5 @@ keywords:
|
||||
- historikk
|
||||
- visited
|
||||
variant: Stroke
|
||||
updated_at: 17.07.2024
|
||||
updated_at: 07.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -15,5 +15,5 @@ keywords:
|
||||
- markup-språk
|
||||
- kildekode
|
||||
variant: Stroke
|
||||
updated_at: 18.09.2024
|
||||
updated_at: 18.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -11,5 +11,5 @@ keywords:
|
||||
- handel
|
||||
- økonomi
|
||||
variant: Stroke
|
||||
updated_at: 07.05.2024
|
||||
updated_at: 07.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -7,5 +7,5 @@ keywords:
|
||||
- downloading
|
||||
- last ned
|
||||
variant: Stroke
|
||||
updated_at: 31.07.2024
|
||||
updated_at: 11.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -13,5 +13,5 @@ keywords:
|
||||
- oppmerksomhet
|
||||
- viktig
|
||||
variant: Stroke
|
||||
updated_at: 09.08.2024
|
||||
updated_at: 13.03.2025
|
||||
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="M12.75 4.5C12.75 4.08579 13.0857 3.75 13.5 3.75L19.5 3.75C19.6989 3.75 19.8896 3.82902 20.0303 3.96967C20.171 4.11032 20.25 4.30109 20.25 4.5L20.25 10.5C20.25 10.9142 19.9142 11.25 19.5 11.25C19.0858 11.25 18.75 10.9142 18.75 10.5L18.75 6.31065L14.0303 11.0303C13.7374 11.3232 13.2625 11.3232 12.9696 11.0303C12.6767 10.7374 12.6767 10.2626 12.9696 9.96967L17.6893 5.25L13.5 5.25C13.0857 5.25 12.75 4.91421 12.75 4.5ZM4.49997 12.75C4.91418 12.75 5.24997 13.0858 5.24997 13.5L5.24997 17.6893L9.96962 12.9697C10.2625 12.6768 10.7374 12.6768 11.0303 12.9697C11.3232 13.2626 11.3232 13.7374 11.0303 14.0303L6.31062 18.75L10.5 18.75C10.9142 18.75 11.25 19.0858 11.25 19.5C11.25 19.9142 10.9142 20.25 10.5 20.25L4.49997 20.25C4.30106 20.25 4.11029 20.171 3.96964 20.0303C3.82899 19.8897 3.74997 19.6989 3.74997 19.5L3.74997 13.5C3.74997 13.0858 4.08576 12.75 4.49997 12.75Z" fill="#23262A"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M11.25 19.5C11.25 19.9142 10.9143 20.25 10.5 20.25H4.50003C4.30112 20.25 4.11035 20.171 3.9697 20.0303C3.82905 19.8897 3.75003 19.6989 3.75003 19.5L3.75003 13.5C3.75003 13.0858 4.08582 12.75 4.50003 12.75C4.91424 12.75 5.25003 13.0858 5.25003 13.5L5.25003 17.6894L9.96971 12.9697C10.2626 12.6768 10.7375 12.6768 11.0304 12.9697C11.3233 13.2626 11.3233 13.7374 11.0304 14.0303L6.3107 18.75L10.5 18.75C10.9143 18.75 11.25 19.0858 11.25 19.5ZM19.5 11.25C19.0858 11.25 18.75 10.9142 18.75 10.5L18.75 6.31066L14.0304 11.0303C13.7375 11.3232 13.2626 11.3232 12.9697 11.0303C12.6768 10.7374 12.6768 10.2626 12.9697 9.96967L17.6894 5.24998L13.5 5.24998C13.0858 5.24998 12.75 4.9142 12.75 4.49998C12.75 4.08577 13.0858 3.74998 13.5 3.74998L19.5 3.74998C19.6989 3.74998 19.8897 3.829 20.0304 3.96965C20.171 4.11031 20.25 4.30107 20.25 4.49998L20.25 10.5C20.25 10.9142 19.9142 11.25 19.5 11.25Z" fill="#23262A"/>
|
||||
</svg>
|
||||
|
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 1.0 KiB |
@@ -9,5 +9,5 @@ keywords:
|
||||
- open
|
||||
- åpne
|
||||
variant: Stroke
|
||||
updated_at: 16.09.2024
|
||||
updated_at: 18.03.2025
|
||||
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="M12.5303 2.21967C12.2374 1.92678 11.7626 1.92678 11.4697 2.21967L7.46967 6.21967C7.17678 6.51256 7.17678 6.98744 7.46967 7.28033C7.76256 7.57322 8.23744 7.57322 8.53033 7.28033L11.25 4.56066L11.25 10C11.25 10.4142 11.5858 10.75 12 10.75C12.4142 10.75 12.75 10.4142 12.75 10L12.75 4.56066L15.4697 7.28033C15.7626 7.57322 16.2374 7.57322 16.5303 7.28033C16.8232 6.98744 16.8232 6.51256 16.5303 6.21967L12.5303 2.21967ZM11.4697 21.7803C11.7626 22.0732 12.2374 22.0732 12.5303 21.7803L16.5303 17.7803C16.8232 17.4874 16.8232 17.0126 16.5303 16.7197C16.2374 16.4268 15.7626 16.4268 15.4697 16.7197L12.75 19.4393L12.75 14C12.75 13.5858 12.4142 13.25 12 13.25C11.5858 13.25 11.25 13.5858 11.25 14L11.25 19.4393L8.53033 16.7197C8.23744 16.4268 7.76256 16.4268 7.46967 16.7197C7.17678 17.0126 7.17678 17.4874 7.46967 17.7803L11.4697 21.7803Z" fill="#23262A"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M11.4697 21.7803C11.7626 22.0732 12.2374 22.0732 12.5303 21.7803L16.5303 17.7803C16.8232 17.4874 16.8232 17.0126 16.5303 16.7197C16.2374 16.4268 15.7626 16.4268 15.4697 16.7197L12.75 19.4393L12.75 14C12.75 13.5858 12.4142 13.25 12 13.25C11.5858 13.25 11.25 13.5858 11.25 14L11.25 19.4393L8.53033 16.7197C8.23744 16.4268 7.76256 16.4268 7.46967 16.7197C7.17678 17.0126 7.17678 17.4874 7.46967 17.7803L11.4697 21.7803ZM12.5303 2.21967C12.2374 1.92678 11.7626 1.92678 11.4697 2.21967L7.46967 6.21967C7.17678 6.51256 7.17678 6.98744 7.46967 7.28033C7.76256 7.57322 8.23744 7.57322 8.53033 7.28033L11.25 4.56066L11.25 10C11.25 10.4142 11.5858 10.75 12 10.75C12.4142 10.75 12.75 10.4142 12.75 10L12.75 4.56066L15.4697 7.28033C15.7626 7.57323 16.2374 7.57323 16.5303 7.28033C16.8232 6.98744 16.8232 6.51256 16.5303 6.21967L12.5303 2.21967Z" fill="#23262A"/>
|
||||
</svg>
|
||||
|
Before Width: | Height: | Size: 1003 B After Width: | Height: | Size: 1003 B |
@@ -9,5 +9,5 @@ keywords:
|
||||
- open
|
||||
- åpne
|
||||
variant: Stroke
|
||||
updated_at: 30.01.2025
|
||||
updated_at: 18.03.2025
|
||||
created_at: 29.01.2025
|
||||
@@ -5,9 +5,8 @@ keywords:
|
||||
- lenke
|
||||
- kobling
|
||||
- videresending
|
||||
- new tab
|
||||
- ekstern side
|
||||
- eksternt
|
||||
variant: Stroke
|
||||
updated_at: 04.12.2023
|
||||
updated_at: 19.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -5,9 +5,8 @@ keywords:
|
||||
- lenke
|
||||
- kobling
|
||||
- videresending
|
||||
- new tab
|
||||
- ekstern side
|
||||
- eksternt
|
||||
variant: Fill
|
||||
updated_at: 04.12.2023
|
||||
updated_at: 19.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -7,5 +7,5 @@ keywords:
|
||||
- lukket
|
||||
- hidden
|
||||
variant: Stroke
|
||||
updated_at: 01.08.2024
|
||||
updated_at: 12.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -7,5 +7,5 @@ keywords:
|
||||
- data
|
||||
- tabell
|
||||
variant: Stroke
|
||||
updated_at: 26.07.2024
|
||||
updated_at: 03.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -13,5 +13,5 @@ keywords:
|
||||
- fremdrift
|
||||
- nedtelling
|
||||
variant: Stroke
|
||||
updated_at: 21.08.2024
|
||||
updated_at: 06.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -13,5 +13,5 @@ keywords:
|
||||
- fremdrift
|
||||
- nedtelling
|
||||
variant: Stroke
|
||||
updated_at: 14.08.2024
|
||||
updated_at: 04.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -13,5 +13,5 @@ keywords:
|
||||
- fremdrift
|
||||
- nedtelling
|
||||
variant: Stroke
|
||||
updated_at: 06.08.2024
|
||||
updated_at: 11.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -15,5 +15,5 @@ keywords:
|
||||
- beskrivelse
|
||||
- forklaring
|
||||
variant: Stroke
|
||||
updated_at: 30.07.2024
|
||||
updated_at: 04.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -15,5 +15,5 @@ keywords:
|
||||
- avslutt
|
||||
- avslutt
|
||||
variant: Stroke
|
||||
updated_at: 06.09.2024
|
||||
updated_at: 12.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -6,5 +6,5 @@ keywords:
|
||||
- chain
|
||||
- kobling
|
||||
variant: Stroke
|
||||
updated_at: 24.07.2024
|
||||
updated_at: 12.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -12,5 +12,5 @@ keywords:
|
||||
- nedtrekksvalg
|
||||
- ellipse
|
||||
variant: Stroke
|
||||
updated_at: 01.08.2024
|
||||
updated_at: 03.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -12,5 +12,5 @@ keywords:
|
||||
- nedtrekksvalg
|
||||
- ellipse
|
||||
variant: Stroke
|
||||
updated_at: 01.08.2024
|
||||
updated_at: 03.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -7,5 +7,5 @@ keywords:
|
||||
- grid
|
||||
- rutenett
|
||||
variant: Stroke
|
||||
updated_at: 29.07.2024
|
||||
updated_at: 04.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -6,5 +6,5 @@ keywords:
|
||||
- meny
|
||||
- hamburger
|
||||
variant: Stroke
|
||||
updated_at: 24.07.2024
|
||||
updated_at: 04.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -20,5 +20,5 @@ keywords:
|
||||
- ansvar
|
||||
- paragraf
|
||||
variant: Stroke
|
||||
updated_at: 18.09.2024
|
||||
updated_at: 03.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -6,5 +6,5 @@ keywords:
|
||||
- legg til
|
||||
- more
|
||||
variant: Stroke
|
||||
updated_at: 18.07.2024
|
||||
updated_at: 04.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -6,5 +6,5 @@ keywords:
|
||||
- math
|
||||
- plus minus
|
||||
variant: Stroke
|
||||
updated_at: 05.01.2024
|
||||
updated_at: 13.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -0,0 +1,15 @@
|
||||
<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="M5 17V7C5 5.89543 5.89543 5 7 5H17C18.1046 5 19 5.89543 19 7V17C19 18.1046 18.1046 19 17 19H7C5.89543 19 5 18.1046 5 17ZM8 7.25C7.58579 7.25 7.25 7.58579 7.25 8V16C7.25 16.4142 7.58579 16.75 8 16.75H16C16.4142 16.75 16.75 16.4142 16.75 16V8C16.75 7.58579 16.4142 7.25 16 7.25H8ZM8.75 15.25V8.75H15.25V15.25H8.75Z" fill="#23262A"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M12 1.25C12.4142 1.25 12.75 1.58579 12.75 2V5C12.75 5.41421 12.4142 5.75 12 5.75C11.5858 5.75 11.25 5.41421 11.25 5V2C11.25 1.58579 11.5858 1.25 12 1.25Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M12 18.25C12.4142 18.25 12.75 18.5858 12.75 19V22C12.75 22.4142 12.4142 22.75 12 22.75C11.5858 22.75 11.25 22.4142 11.25 22V19C11.25 18.5858 11.5858 18.25 12 18.25Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M22.75 12C22.75 12.4142 22.4142 12.75 22 12.75L19 12.75C18.5858 12.75 18.25 12.4142 18.25 12C18.25 11.5858 18.5858 11.25 19 11.25L22 11.25C22.4142 11.25 22.75 11.5858 22.75 12Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M5.75 12C5.75 12.4142 5.41421 12.75 5 12.75L2 12.75C1.58579 12.75 1.25 12.4142 1.25 12C1.25 11.5858 1.58579 11.25 2 11.25L5 11.25C5.41421 11.25 5.75 11.5858 5.75 12Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M15 1.25C15.4142 1.25 15.75 1.58579 15.75 2V5C15.75 5.41421 15.4142 5.75 15 5.75C14.5858 5.75 14.25 5.41421 14.25 5V2C14.25 1.58579 14.5858 1.25 15 1.25Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M15 18.25C15.4142 18.25 15.75 18.5858 15.75 19V22C15.75 22.4142 15.4142 22.75 15 22.75C14.5858 22.75 14.25 22.4142 14.25 22V19C14.25 18.5858 14.5858 18.25 15 18.25Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M22.75 15C22.75 15.4142 22.4142 15.75 22 15.75L19 15.75C18.5858 15.75 18.25 15.4142 18.25 15C18.25 14.5858 18.5858 14.25 19 14.25L22 14.25C22.4142 14.25 22.75 14.5858 22.75 15Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M5.75 15C5.75 15.4142 5.41421 15.75 5 15.75L2 15.75C1.58579 15.75 1.25 15.4142 1.25 15C1.25 14.5858 1.58579 14.25 2 14.25L5 14.25C5.41421 14.25 5.75 14.5858 5.75 15Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M9 1.25C9.41421 1.25 9.75 1.58579 9.75 2V5C9.75 5.41421 9.41421 5.75 9 5.75C8.58579 5.75 8.25 5.41421 8.25 5V2C8.25 1.58579 8.58579 1.25 9 1.25Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M9 18.25C9.41421 18.25 9.75 18.5858 9.75 19V22C9.75 22.4142 9.41421 22.75 9 22.75C8.58579 22.75 8.25 22.4142 8.25 22V19C8.25 18.5858 8.58579 18.25 9 18.25Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M22.75 9C22.75 9.41421 22.4142 9.75 22 9.75L19 9.75C18.5858 9.75 18.25 9.41421 18.25 9C18.25 8.58579 18.5858 8.25 19 8.25L22 8.25C22.4142 8.25 22.75 8.58579 22.75 9Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M5.75 9C5.75 9.41421 5.41421 9.75 5 9.75L2 9.75C1.58579 9.75 1.25 9.41421 1.25 9C1.25 8.58579 1.58579 8.25 2 8.25L5 8.25C5.41421 8.25 5.75 8.58579 5.75 9Z" fill="#262626"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 3.2 KiB |
@@ -0,0 +1,12 @@
|
||||
name: Property1Fill
|
||||
category: Interface
|
||||
sub_category: Devices
|
||||
keywords:
|
||||
- print
|
||||
- skrive ut
|
||||
- skriver
|
||||
- printing room
|
||||
- skriverom
|
||||
variant: Stroke
|
||||
updated_at: 19.02.2025
|
||||
created_at: 19.02.2025
|
||||
@@ -0,0 +1,16 @@
|
||||
<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="M7 5.75C6.30964 5.75 5.75 6.30964 5.75 7V17C5.75 17.6904 6.30964 18.25 7 18.25H17C17.6904 18.25 18.25 17.6904 18.25 17V7C18.25 6.30964 17.6904 5.75 17 5.75H7ZM4.25 7C4.25 5.48122 5.48122 4.25 7 4.25H17C18.5188 4.25 19.75 5.48122 19.75 7V17C19.75 18.5188 18.5188 19.75 17 19.75H7C5.48122 19.75 4.25 18.5188 4.25 17V7Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M7.25 8C7.25 7.58579 7.58579 7.25 8 7.25H16C16.4142 7.25 16.75 7.58579 16.75 8V16C16.75 16.4142 16.4142 16.75 16 16.75H8C7.58579 16.75 7.25 16.4142 7.25 16V8ZM8.75 8.75V15.25H15.25V8.75H8.75Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M12 1.25C12.4142 1.25 12.75 1.58579 12.75 2V5C12.75 5.41421 12.4142 5.75 12 5.75C11.5858 5.75 11.25 5.41421 11.25 5V2C11.25 1.58579 11.5858 1.25 12 1.25Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M12 18.25C12.4142 18.25 12.75 18.5858 12.75 19V22C12.75 22.4142 12.4142 22.75 12 22.75C11.5858 22.75 11.25 22.4142 11.25 22V19C11.25 18.5858 11.5858 18.25 12 18.25Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M22.75 12C22.75 12.4142 22.4142 12.75 22 12.75L19 12.75C18.5858 12.75 18.25 12.4142 18.25 12C18.25 11.5858 18.5858 11.25 19 11.25L22 11.25C22.4142 11.25 22.75 11.5858 22.75 12Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M5.75 12C5.75 12.4142 5.41421 12.75 5 12.75L2 12.75C1.58579 12.75 1.25 12.4142 1.25 12C1.25 11.5858 1.58579 11.25 2 11.25L5 11.25C5.41421 11.25 5.75 11.5858 5.75 12Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M15 1.25C15.4142 1.25 15.75 1.58579 15.75 2V5C15.75 5.41421 15.4142 5.75 15 5.75C14.5858 5.75 14.25 5.41421 14.25 5V2C14.25 1.58579 14.5858 1.25 15 1.25Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M15 18.25C15.4142 18.25 15.75 18.5858 15.75 19V22C15.75 22.4142 15.4142 22.75 15 22.75C14.5858 22.75 14.25 22.4142 14.25 22V19C14.25 18.5858 14.5858 18.25 15 18.25Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M22.75 15C22.75 15.4142 22.4142 15.75 22 15.75L19 15.75C18.5858 15.75 18.25 15.4142 18.25 15C18.25 14.5858 18.5858 14.25 19 14.25L22 14.25C22.4142 14.25 22.75 14.5858 22.75 15Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M5.75 15C5.75 15.4142 5.41421 15.75 5 15.75L2 15.75C1.58579 15.75 1.25 15.4142 1.25 15C1.25 14.5858 1.58579 14.25 2 14.25L5 14.25C5.41421 14.25 5.75 14.5858 5.75 15Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M9 1.25C9.41421 1.25 9.75 1.58579 9.75 2V5C9.75 5.41421 9.41421 5.75 9 5.75C8.58579 5.75 8.25 5.41421 8.25 5V2C8.25 1.58579 8.58579 1.25 9 1.25Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M9 18.25C9.41421 18.25 9.75 18.5858 9.75 19V22C9.75 22.4142 9.41421 22.75 9 22.75C8.58579 22.75 8.25 22.4142 8.25 22V19C8.25 18.5858 8.58579 18.25 9 18.25Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M22.75 9C22.75 9.41421 22.4142 9.75 22 9.75L19 9.75C18.5858 9.75 18.25 9.41421 18.25 9C18.25 8.58579 18.5858 8.25 19 8.25L22 8.25C22.4142 8.25 22.75 8.58579 22.75 9Z" fill="#262626"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M5.75 9C5.75 9.41421 5.41421 9.75 5 9.75L2 9.75C1.58579 9.75 1.25 9.41421 1.25 9C1.25 8.58579 1.58579 8.25 2 8.25L5 8.25C5.41421 8.25 5.75 8.58579 5.75 9Z" fill="#262626"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 3.4 KiB |
@@ -0,0 +1,12 @@
|
||||
name: Property1Stroke
|
||||
category: Interface
|
||||
sub_category: Devices
|
||||
keywords:
|
||||
- print
|
||||
- skrive ut
|
||||
- skriver
|
||||
- printing room
|
||||
- skriverom
|
||||
variant: Stroke
|
||||
updated_at: 19.02.2025
|
||||
created_at: 19.02.2025
|
||||
@@ -13,5 +13,5 @@ keywords:
|
||||
- veiledning
|
||||
- spørsmålstegn
|
||||
variant: Stroke
|
||||
updated_at: 30.07.2024
|
||||
updated_at: 07.03.2025
|
||||
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="M13.5 3.75C13.9142 3.75 14.25 4.08579 14.25 4.5L14.25 8.68933L18.9697 3.96967C19.2625 3.67678 19.7374 3.67678 20.0303 3.96967C20.3232 4.26256 20.3232 4.73744 20.0303 5.03033L15.3106 9.75002L19.5 9.75002C19.9142 9.75002 20.25 10.0858 20.25 10.5C20.25 10.9142 19.9142 11.25 19.5 11.25L13.5 11.25C13.3011 11.25 13.1103 11.171 12.9697 11.0303C12.829 10.8897 12.75 10.6989 12.75 10.5L12.75 4.5C12.75 4.08579 13.0858 3.75 13.5 3.75ZM3.74999 13.5C3.74999 13.0858 4.08577 12.75 4.49999 12.75L10.5 12.75C10.9142 12.75 11.25 13.0858 11.25 13.5L11.25 19.5C11.25 19.9142 10.9142 20.25 10.5 20.25C10.0858 20.25 9.75 19.9142 9.75 19.5L9.75 15.3106L5.03031 20.0303C4.73742 20.3232 4.26255 20.3232 3.96966 20.0303C3.67676 19.7374 3.67676 19.2626 3.96966 18.9697L8.68931 14.25L4.49999 14.25C4.08577 14.25 3.74999 13.9142 3.74999 13.5Z" fill="#23262A"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M10.5 20.25C10.0858 20.25 9.74998 19.9142 9.74998 19.5L9.74999 15.3107L5.03035 20.0303C4.73745 20.3232 4.26258 20.3232 3.96969 20.0303C3.67679 19.7374 3.67679 19.2626 3.96968 18.9697L8.68935 14.25L4.5 14.25C4.08579 14.25 3.75 13.9142 3.75 13.5C3.75 13.0858 4.08579 12.75 4.5 12.75L10.5 12.75C10.6989 12.75 10.8897 12.829 11.0303 12.9697C11.171 13.1103 11.25 13.3011 11.25 13.5L11.25 19.5C11.25 19.9142 10.9142 20.25 10.5 20.25ZM20.25 10.5C20.25 10.9142 19.9142 11.25 19.5 11.25H13.5C13.0858 11.25 12.75 10.9142 12.75 10.5V4.5C12.75 4.08579 13.0858 3.75 13.5 3.75C13.9142 3.75 14.25 4.08579 14.25 4.5V8.68935L18.9697 3.96967C19.2626 3.67678 19.7375 3.67678 20.0303 3.96967C20.3232 4.26256 20.3232 4.73744 20.0303 5.03033L15.3107 9.74999H19.5C19.9142 9.74999 20.25 10.0858 20.25 10.5Z" fill="#23262A"/>
|
||||
</svg>
|
||||
|
Before Width: | Height: | Size: 988 B After Width: | Height: | Size: 953 B |
@@ -9,5 +9,5 @@ keywords:
|
||||
- lukk
|
||||
- close
|
||||
variant: Stroke
|
||||
updated_at: 08.01.2024
|
||||
updated_at: 18.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -11,5 +11,5 @@ keywords:
|
||||
- hand
|
||||
- hånd
|
||||
variant: Stroke
|
||||
updated_at: 04.12.2023
|
||||
updated_at: 13.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -11,5 +11,5 @@ keywords:
|
||||
- hand
|
||||
- hånd
|
||||
variant: Fill
|
||||
updated_at: 04.12.2023
|
||||
updated_at: 13.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -6,5 +6,5 @@ keywords:
|
||||
- crystal
|
||||
- snø
|
||||
variant: Stroke
|
||||
updated_at: 23.09.2024
|
||||
updated_at: 18.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -8,5 +8,5 @@ keywords:
|
||||
- loading
|
||||
- laster
|
||||
variant: Stroke
|
||||
updated_at: 18.07.2024
|
||||
updated_at: 10.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -8,5 +8,5 @@ keywords:
|
||||
- loading
|
||||
- laster
|
||||
variant: Stroke
|
||||
updated_at: 18.07.2024
|
||||
updated_at: 10.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -7,5 +7,5 @@ keywords:
|
||||
- stairs
|
||||
- floors
|
||||
variant: Stroke
|
||||
updated_at: 19.04.2024
|
||||
updated_at: 18.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -6,5 +6,5 @@ keywords:
|
||||
- europa
|
||||
- europe
|
||||
variant: Stroke
|
||||
updated_at: 23.09.2024
|
||||
updated_at: 03.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -11,5 +11,5 @@ keywords:
|
||||
- doctor
|
||||
- patient
|
||||
variant: Stroke
|
||||
updated_at: 31.07.2024
|
||||
updated_at: 04.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -5,6 +5,7 @@ keywords:
|
||||
- legg til
|
||||
- tabs
|
||||
- tab
|
||||
- new tab
|
||||
variant: Stroke
|
||||
updated_at: 04.12.2023
|
||||
updated_at: 19.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -5,6 +5,7 @@ keywords:
|
||||
- legg til
|
||||
- tabs
|
||||
- tab
|
||||
- new tab
|
||||
variant: Fill
|
||||
updated_at: 04.12.2023
|
||||
updated_at: 19.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -15,5 +15,5 @@ keywords:
|
||||
- avvis
|
||||
- avslå
|
||||
variant: Stroke
|
||||
updated_at: 25.07.2024
|
||||
updated_at: 03.03.2025
|
||||
created_at: 07.03.2023
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@navikt/aksel-icons",
|
||||
"version": "7.16.1",
|
||||
"version": "7.17.4",
|
||||
"author": "Aksel | Nav",
|
||||
"homepage": "https://aksel.nav.no/ikoner",
|
||||
"repository": {
|
||||
|
||||
@@ -1,5 +1,15 @@
|
||||
# @navikt/aksel-stylelint
|
||||
|
||||
## 7.17.4
|
||||
|
||||
## 7.17.3
|
||||
|
||||
## 7.17.2
|
||||
|
||||
## 7.17.1
|
||||
|
||||
## 7.17.0
|
||||
|
||||
## 7.16.1
|
||||
|
||||
## 7.16.0
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@navikt/aksel-stylelint",
|
||||
"version": "7.16.1",
|
||||
"version": "7.17.4",
|
||||
"author": "Aksel | Nav",
|
||||
"homepage": "https://aksel.nav.no/grunnleggende/kode/stylelint",
|
||||
"repository": {
|
||||
@@ -35,8 +35,8 @@
|
||||
"dev": "yarn watch:lint"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@navikt/ds-css": "^7.16.1",
|
||||
"@navikt/ds-tokens": "^7.16.1",
|
||||
"@navikt/ds-css": "^7.17.4",
|
||||
"@navikt/ds-tokens": "^7.17.4",
|
||||
"concurrently": "9.0.1",
|
||||
"postcss-selector-parser": "^6.0.13",
|
||||
"postcss-value-parser": "^4.2.0",
|
||||
|
||||
@@ -1,5 +1,41 @@
|
||||
# @navikt/aksel
|
||||
|
||||
## 7.17.4
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- Updated dependencies [[`0cb04db`](https://github.com/navikt/aksel/commit/0cb04db2617a3597f1aeb27887977ed75db65731)]:
|
||||
- @navikt/ds-css@7.17.4
|
||||
- @navikt/ds-tokens@7.17.4
|
||||
|
||||
## 7.17.3
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- Updated dependencies [[`56971a1`](https://github.com/navikt/aksel/commit/56971a105d95b08b3e9a31d79f012eb9cd150cc0)]:
|
||||
- @navikt/ds-css@7.17.3
|
||||
|
||||
## 7.17.2
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- Updated dependencies [[`e769eed`](https://github.com/navikt/aksel/commit/e769eed269d327403b89935502f8fe431eca8cc9)]:
|
||||
- @navikt/ds-css@7.17.2
|
||||
|
||||
## 7.17.1
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- Updated dependencies [[`c1b2944`](https://github.com/navikt/aksel/commit/c1b294432195985309f33cef8e1bfc3119bb087b)]:
|
||||
- @navikt/ds-css@7.17.1
|
||||
|
||||
## 7.17.0
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- Updated dependencies []:
|
||||
- @navikt/ds-css@7.17.0
|
||||
|
||||
## 7.16.1
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@navikt/aksel",
|
||||
"version": "7.16.1",
|
||||
"version": "7.17.4",
|
||||
"description": "Aksel command line interface. Handles css-imports, codemods and more",
|
||||
"author": "Aksel | Nav designsystem team",
|
||||
"license": "MIT",
|
||||
@@ -29,9 +29,11 @@
|
||||
},
|
||||
"homepage": "https://aksel.nav.no/grunnleggende/kode/kommandolinje",
|
||||
"dependencies": {
|
||||
"@navikt/ds-css": "^7.16.1",
|
||||
"axios": "1.7.4",
|
||||
"@navikt/ds-css": "^7.17.4",
|
||||
"@navikt/ds-tokens": "^7.17.4",
|
||||
"axios": "1.8.2",
|
||||
"chalk": "4.1.0",
|
||||
"cli-progress": "^3.12.0",
|
||||
"clipboardy": "^2.3.0",
|
||||
"commander": "10.0.1",
|
||||
"enquirer": "^2.3.6",
|
||||
@@ -44,6 +46,7 @@
|
||||
"react-scanner": "^1.1.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/cli-progress": "3.11.6",
|
||||
"rimraf": "6.0.1",
|
||||
"typescript": "5.5.4",
|
||||
"vitest": "^2.1.8"
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
const GLOB_IGNORE_PATTERNS = [
|
||||
"**/node_modules/**",
|
||||
"**/dist/**",
|
||||
"**/build/**",
|
||||
"**/lib/**",
|
||||
"**/.next/**",
|
||||
"**/__snapshots__/**",
|
||||
];
|
||||
|
||||
/**
|
||||
* Utility function to generate the default glob pattern
|
||||
*/
|
||||
function getDefaultGlob(ext: string): string {
|
||||
const defaultExt = "js,ts,jsx,tsx,css,scss,less";
|
||||
return `**/*.{${cleanExtensions(ext ?? defaultExt).join(",")}}`;
|
||||
}
|
||||
|
||||
/**
|
||||
* Utility function to clean file extensions
|
||||
*/
|
||||
function cleanExtensions(ext: string): string[] {
|
||||
return ext
|
||||
.split(",")
|
||||
.map((e) => e.trim())
|
||||
.map((e) => e.replace(".", ""));
|
||||
}
|
||||
|
||||
export { GLOB_IGNORE_PATTERNS, getDefaultGlob, cleanExtensions };
|
||||
@@ -97,35 +97,31 @@ export const migrations: {
|
||||
"Remember to update use of `variant`-prop to match previous use of colors. If needed the component exposes css-variables for custom overrides",
|
||||
},
|
||||
],
|
||||
darkside: [
|
||||
spacing: [
|
||||
{
|
||||
description:
|
||||
"Updates all Primitives to use new `space`-tokens. (Works with old and new system)",
|
||||
value: "primitive-spacing",
|
||||
path: "darkside/primitives-spacing/spacing",
|
||||
path: "spacing/primitives-spacing/spacing",
|
||||
},
|
||||
{
|
||||
description:
|
||||
"Updates css, scss and less-variables to use new `space`-tokens. (Works with old and new system)",
|
||||
value: "token-spacing",
|
||||
path: "darkside/token-spacing/spacing",
|
||||
path: "spacing/token-spacing/spacing",
|
||||
},
|
||||
{
|
||||
description:
|
||||
"Updates js-tokens to use new `space`-tokens. (Works with old and new system)",
|
||||
value: "token-spacing-js",
|
||||
path: "darkside/token-spacing-js/spacing",
|
||||
path: "spacing/token-spacing-js/spacing",
|
||||
},
|
||||
],
|
||||
darkside: [
|
||||
{
|
||||
description:
|
||||
"Updates css, scss and less-variables to use new token-prefix",
|
||||
value: "token-update",
|
||||
path: "darkside/token-update/token-update",
|
||||
},
|
||||
{
|
||||
description: "Updates js tokens to use new token-prefix and names",
|
||||
value: "token-update-js",
|
||||
path: "darkside/token-update-js/token-update-js",
|
||||
description: "marks deprecated prop usage with comments.",
|
||||
value: "prop-deprecate",
|
||||
path: "darkside/prop-deprecate/prop-deprecate",
|
||||
},
|
||||
],
|
||||
};
|
||||
|
||||
@@ -3,6 +3,7 @@ import { Command } from "commander";
|
||||
import fg from "fast-glob";
|
||||
import * as jscodeshift from "jscodeshift/src/Runner";
|
||||
import path from "path";
|
||||
import { GLOB_IGNORE_PATTERNS, getDefaultGlob } from "./codeshift.utils";
|
||||
import { getMigrationPath, getWarning } from "./migrations";
|
||||
|
||||
const ignoreNodeModules = [
|
||||
@@ -13,14 +14,6 @@ const ignoreNodeModules = [
|
||||
"**/.next/**",
|
||||
];
|
||||
|
||||
export const messages = new Map<
|
||||
string,
|
||||
{
|
||||
format: (input: any) => void;
|
||||
data: any;
|
||||
}
|
||||
>();
|
||||
|
||||
export async function runCodeshift(
|
||||
input: string,
|
||||
options: any,
|
||||
@@ -33,7 +26,7 @@ export async function runCodeshift(
|
||||
|
||||
const filepaths = fg.sync([options.glob ?? getDefaultGlob(options?.ext)], {
|
||||
cwd: process.cwd(),
|
||||
ignore: ignoreNodeModules,
|
||||
ignore: GLOB_IGNORE_PATTERNS,
|
||||
});
|
||||
|
||||
console.info("\nRunning migration:", chalk.green("input"));
|
||||
@@ -58,23 +51,7 @@ export async function runCodeshift(
|
||||
});
|
||||
|
||||
warning && console.info(`\n${chalk.yellow(warning)}\n`);
|
||||
|
||||
messages.forEach((value) => {
|
||||
value.format(value.data);
|
||||
});
|
||||
} catch (error) {
|
||||
program.error(chalk.red("Error:", error.message));
|
||||
}
|
||||
}
|
||||
|
||||
function getDefaultGlob(ext: string): string {
|
||||
const defaultExt = "js,ts,jsx,tsx,css,scss,less";
|
||||
return `**/*.{${cleanExtensions(ext ?? defaultExt).join(",")}}`;
|
||||
}
|
||||
|
||||
function cleanExtensions(ext: string): string[] {
|
||||
return ext
|
||||
.split(",")
|
||||
.map((e) => e.trim())
|
||||
.map((e) => e.replace(".", ""));
|
||||
}
|
||||
@@ -1,23 +0,0 @@
|
||||
import { describe, expect, test } from "vitest";
|
||||
import { newTokens, updatedTokens } from "./darkside.tokens";
|
||||
|
||||
describe("Darkside codemods", () => {
|
||||
test("Token migration references exists", () => {
|
||||
Object.entries(updatedTokens).forEach(([oldToken, config]) => {
|
||||
if (config.replacement.length > 1) {
|
||||
expect(
|
||||
newTokens,
|
||||
`${oldToken} has valid replacement: ${config.replacement}`,
|
||||
).toContain(config.replacement);
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
test("Has raw value if no reference is set", () => {
|
||||
Object.values(updatedTokens).forEach((config) => {
|
||||
if (config.replacement.length === 0) {
|
||||
expect(config.raw.length > 0).toBeTruthy();
|
||||
}
|
||||
});
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,34 @@
|
||||
import type { API, FileInfo } from "jscodeshift";
|
||||
import { findComponentImport } from "../../../utils/ast";
|
||||
import { getLineTerminator } from "../../../utils/lineterminator";
|
||||
import removePropsFromComponent from "../../../utils/removeProps";
|
||||
|
||||
const deprecationMap = {
|
||||
Accordion: ["headingSize", "variant"],
|
||||
Popover: ["arrow"],
|
||||
Page: ["background"],
|
||||
};
|
||||
|
||||
export default function transformer(file: FileInfo, api: API) {
|
||||
const j = api.jscodeshift;
|
||||
const root = j(file.source);
|
||||
|
||||
const toSourceOptions = getLineTerminator(file.source);
|
||||
|
||||
for (const [component, props] of Object.entries(deprecationMap)) {
|
||||
const sourceName = findComponentImport({
|
||||
file,
|
||||
j,
|
||||
name: component,
|
||||
packageType: "react",
|
||||
});
|
||||
|
||||
if (!sourceName) {
|
||||
continue;
|
||||
}
|
||||
|
||||
removePropsFromComponent(j, root, sourceName, props);
|
||||
}
|
||||
|
||||
return root.toSource(toSourceOptions);
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
import { Accordion, Alert, Box, Page, Popover } from "@navikt/ds-react";
|
||||
|
||||
export const Demo = () => (
|
||||
<Page background="bg-subtle">
|
||||
<Alert
|
||||
variant="error" // should remain untouched
|
||||
background="#ff0000" // should remain untouched
|
||||
>
|
||||
dette er en feilmelding
|
||||
</Alert>
|
||||
<Accordion headingSize="large" hidden variant="neutral">
|
||||
<Accordion.Item>
|
||||
<Accordion.Header>Section 1</Accordion.Header>
|
||||
<Accordion.Content>Content 1</Accordion.Content>
|
||||
</Accordion.Item>
|
||||
<Accordion.Item>
|
||||
<Accordion.Header>Section 2</Accordion.Header>
|
||||
<Accordion.Content>Content 2</Accordion.Content>
|
||||
</Accordion.Item>
|
||||
</Accordion>
|
||||
<Button ref={buttonRef} onClick={() => setOpenState(true)}>
|
||||
Åpne popover
|
||||
</Button>
|
||||
<Popover
|
||||
open={openState}
|
||||
onClose={() => setOpenState(false)}
|
||||
anchorEl={buttonRef.current}
|
||||
arrow
|
||||
>
|
||||
<Popover.Content>Innhold her!</Popover.Content>
|
||||
</Popover>
|
||||
<Page.Block></Page.Block>
|
||||
<Box background="surface-danger">should remain untouched</Box>
|
||||
</Page>
|
||||
);
|
||||
@@ -0,0 +1,34 @@
|
||||
import { Accordion, Alert, Box, Page, Popover } from "@navikt/ds-react";
|
||||
|
||||
export const Demo = () => (
|
||||
<Page>
|
||||
<Alert
|
||||
variant="error" // should remain untouched
|
||||
background="#ff0000" // should remain untouched
|
||||
>
|
||||
dette er en feilmelding
|
||||
</Alert>
|
||||
<Accordion hidden>
|
||||
<Accordion.Item>
|
||||
<Accordion.Header>Section 1</Accordion.Header>
|
||||
<Accordion.Content>Content 1</Accordion.Content>
|
||||
</Accordion.Item>
|
||||
<Accordion.Item>
|
||||
<Accordion.Header>Section 2</Accordion.Header>
|
||||
<Accordion.Content>Content 2</Accordion.Content>
|
||||
</Accordion.Item>
|
||||
</Accordion>
|
||||
<Button ref={buttonRef} onClick={() => setOpenState(true)}>
|
||||
Åpne popover
|
||||
</Button>
|
||||
<Popover
|
||||
open={openState}
|
||||
onClose={() => setOpenState(false)}
|
||||
anchorEl={buttonRef.current}
|
||||
>
|
||||
<Popover.Content>Innhold her!</Popover.Content>
|
||||
</Popover>
|
||||
<Page.Block></Page.Block>
|
||||
<Box background="surface-danger">should remain untouched</Box>
|
||||
</Page>
|
||||
);
|
||||
@@ -1,7 +1,7 @@
|
||||
import { check } from "../../../../utils/check";
|
||||
|
||||
const migration = "token-update-js";
|
||||
const fixtures = ["replace-all", "replace-some"];
|
||||
const migration = "prop-deprecate";
|
||||
const fixtures = ["import"];
|
||||
|
||||
for (const fixture of fixtures) {
|
||||
check(__dirname, {
|
||||
@@ -1,154 +0,0 @@
|
||||
import chalk from "chalk";
|
||||
import type { API, FileInfo } from "jscodeshift";
|
||||
import { messages } from "../../../run-codeshift";
|
||||
import { getImportSpecifier } from "../../../utils/imports";
|
||||
import { getLineTerminator } from "../../../utils/lineterminator";
|
||||
import moveAndRenameImport from "../../../utils/moveAndRenameImport";
|
||||
import { translateToken } from "../../../utils/translate-token";
|
||||
import { updatedTokens } from "../darkside.tokens";
|
||||
|
||||
/**
|
||||
* Updates old tokens to new names.
|
||||
* Replaces global and semantic tokens with avalaible replacement.
|
||||
*/
|
||||
export default function transformer(file: FileInfo, api: API) {
|
||||
initMessageSetup();
|
||||
|
||||
let src = file.source;
|
||||
|
||||
const j = api.jscodeshift;
|
||||
|
||||
let root = j(file.source);
|
||||
|
||||
const jsImport = root.find(j.ImportDeclaration).filter((x) => {
|
||||
return ["@navikt/ds-tokens/dist/tokens"].includes(
|
||||
x.node.source.value as string,
|
||||
);
|
||||
});
|
||||
|
||||
if (!jsImport) {
|
||||
return src;
|
||||
}
|
||||
|
||||
for (const [oldToken, config] of Object.entries(updatedTokens)) {
|
||||
const oldCSSVar = `--a-${oldToken}`;
|
||||
const oldJsVar = translateToken(oldCSSVar, "js");
|
||||
|
||||
let foundName: string | null = null;
|
||||
|
||||
getImportSpecifier(
|
||||
j,
|
||||
root,
|
||||
oldJsVar,
|
||||
"@navikt/ds-tokens/dist/tokens",
|
||||
).forEach((x) => {
|
||||
foundName = x.node.imported.name;
|
||||
});
|
||||
|
||||
if (!foundName) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (config.replacement.length > 0) {
|
||||
/* We remove the prefix */
|
||||
const jsToken = translateToken(`--ax-${config.replacement}`, "js").slice(
|
||||
2,
|
||||
);
|
||||
|
||||
const localName = moveAndRenameImport(j, root, {
|
||||
fromImport: "@navikt/ds-tokens/dist/tokens",
|
||||
toImport: "@navikt/ds-tokens/darkside-js",
|
||||
fromName: foundName,
|
||||
toName: jsToken,
|
||||
ignoreAlias: true,
|
||||
});
|
||||
|
||||
let code = root.toSource(getLineTerminator(src));
|
||||
|
||||
const rgx = new RegExp("(" + localName + ")", "gm");
|
||||
code = code.replace(rgx, jsToken);
|
||||
src = code;
|
||||
|
||||
root = j(code);
|
||||
continue;
|
||||
}
|
||||
|
||||
documentLegacyReferences({
|
||||
src,
|
||||
oldToken: oldCSSVar,
|
||||
comment: config.comment,
|
||||
});
|
||||
}
|
||||
|
||||
return root.toSource(getLineTerminator(src));
|
||||
}
|
||||
|
||||
/**
|
||||
* Replaces old token with new token reference.
|
||||
*/
|
||||
function documentLegacyReferences({
|
||||
src,
|
||||
oldToken,
|
||||
comment,
|
||||
}: {
|
||||
src: string;
|
||||
oldToken: string;
|
||||
comment?: string;
|
||||
}) {
|
||||
const JSRgx = new RegExp("(" + translateToken(oldToken, "js") + ")", "gm");
|
||||
|
||||
JSRgx.test(src) && addMessage({ token: oldToken, comment, type: "js" });
|
||||
}
|
||||
|
||||
type UpdateMessageData = {
|
||||
js: string[];
|
||||
};
|
||||
|
||||
function initMessageSetup() {
|
||||
if (!messages.has("Token update")) {
|
||||
messages.set("Token update", {
|
||||
format: formatMessage,
|
||||
data: {
|
||||
js: [],
|
||||
} satisfies UpdateMessageData,
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
function addMessage({
|
||||
token,
|
||||
comment,
|
||||
type,
|
||||
}: {
|
||||
token: string;
|
||||
comment?: string;
|
||||
type: keyof UpdateMessageData;
|
||||
}) {
|
||||
messages
|
||||
.get("Token update")
|
||||
?.data[type].push(`${token}${comment ? ` (${comment})` : ""}`);
|
||||
}
|
||||
|
||||
function formatMessage(input: UpdateMessageData) {
|
||||
const js = [...new Set(input.js)];
|
||||
|
||||
const total = js.length;
|
||||
|
||||
if (total === 0) {
|
||||
console.info(
|
||||
chalk.green(
|
||||
`Found no legacy-tokens 🎉, you have now migrated over to the darkside.`,
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
console.info(chalk.green(`\nToken update`));
|
||||
console.info(
|
||||
chalk.green(
|
||||
`Found use of ${total} tokens no longer supported. Until these are updated, you will need to keep old tokens imported in your code.`,
|
||||
),
|
||||
);
|
||||
|
||||
js.length > 0 &&
|
||||
console.info(`\nJS:${js.map((token) => `\n${token}`).join("")}`);
|
||||
}
|
||||
@@ -1,25 +0,0 @@
|
||||
.test {
|
||||
margin: var(--a-spacing-4);
|
||||
padding: var(--a-spacing-0);
|
||||
padding: var(--a-spacing-1-alt);
|
||||
padding: var(--a-spacing-05);
|
||||
/* Has replacement */
|
||||
background-color: var(--a-surface-subtle);
|
||||
/* Has no replacement */
|
||||
background-color: var(--a-surface-transparent);
|
||||
|
||||
/* Is tagged as legacy */
|
||||
--a-surface-neutral: red;
|
||||
--a-surface-subtle: orange;
|
||||
}
|
||||
|
||||
.test-scss {
|
||||
margin: @a-spacing-4;
|
||||
padding: @a-spacing-0;
|
||||
padding: @a-spacing-1-alt;
|
||||
padding: @a-spacing-05;
|
||||
/* Has replacement */
|
||||
background-color: @a-surface-subtle;
|
||||
/* Has no replacement */
|
||||
background-color: @a-surface-transparent;
|
||||
}
|
||||
@@ -1,25 +0,0 @@
|
||||
.test {
|
||||
margin: var(--a-spacing-4);
|
||||
padding: var(--a-spacing-0);
|
||||
padding: var(--a-spacing-1-alt);
|
||||
padding: var(--a-spacing-05);
|
||||
/* Has replacement */
|
||||
background-color: var(--a-surface-subtle);
|
||||
/* Has no replacement */
|
||||
background-color: var(--a-surface-transparent);
|
||||
|
||||
/* Is tagged as legacy */
|
||||
--a-surface-neutral: red;
|
||||
--a-surface-subtle: orange;
|
||||
}
|
||||
|
||||
.test-scss {
|
||||
margin: $a-spacing-4;
|
||||
padding: $a-spacing-0;
|
||||
padding: $a-spacing-1-alt;
|
||||
padding: $a-spacing-05;
|
||||
/* Has replacement */
|
||||
background-color: $a-surface-subtle;
|
||||
/* Has no replacement */
|
||||
background-color: $a-surface-transparent;
|
||||
}
|
||||
@@ -1,25 +0,0 @@
|
||||
.test {
|
||||
margin: var(--ax-space-16);
|
||||
padding: var(--ax-space-0);
|
||||
padding: var(--ax-space-6);
|
||||
padding: var(--ax-space-2);
|
||||
/* Has replacement */
|
||||
background-color: var(--ax-bg-neutral-soft);
|
||||
/* Has no replacement */
|
||||
background-color: var(--a-surface-transparent);
|
||||
|
||||
/* Is tagged as legacy */
|
||||
--aksel-legacy__a-surface-neutral: red;
|
||||
--aksel-legacy__a-surface-subtle: orange;
|
||||
}
|
||||
|
||||
.test-scss {
|
||||
margin: @ax-space-16;
|
||||
padding: @ax-space-0;
|
||||
padding: @ax-space-6;
|
||||
padding: @ax-space-2;
|
||||
/* Has replacement */
|
||||
background-color: @ax-bg-neutral-soft;
|
||||
/* Has no replacement */
|
||||
background-color: @a-surface-transparent;
|
||||
}
|
||||
@@ -1,25 +0,0 @@
|
||||
.test {
|
||||
margin: var(--ax-space-16);
|
||||
padding: var(--ax-space-0);
|
||||
padding: var(--ax-space-6);
|
||||
padding: var(--ax-space-2);
|
||||
/* Has replacement */
|
||||
background-color: var(--ax-bg-neutral-soft);
|
||||
/* Has no replacement */
|
||||
background-color: var(--a-surface-transparent);
|
||||
|
||||
/* Is tagged as legacy */
|
||||
--aksel-legacy__a-surface-neutral: red;
|
||||
--aksel-legacy__a-surface-subtle: orange;
|
||||
}
|
||||
|
||||
.test-scss {
|
||||
margin: $ax-space-16;
|
||||
padding: $ax-space-0;
|
||||
padding: $ax-space-6;
|
||||
padding: $ax-space-2;
|
||||
/* Has replacement */
|
||||
background-color: $ax-bg-neutral-soft;
|
||||
/* Has no replacement */
|
||||
background-color: $a-surface-transparent;
|
||||
}
|
||||
@@ -1,30 +0,0 @@
|
||||
import { check } from "../../../../utils/check";
|
||||
|
||||
const migration = "token-update";
|
||||
const fixtures = ["complete"];
|
||||
|
||||
for (const fixture of fixtures) {
|
||||
check(__dirname, {
|
||||
fixture,
|
||||
migration,
|
||||
extension: "css",
|
||||
});
|
||||
|
||||
check(__dirname, {
|
||||
fixture,
|
||||
migration,
|
||||
extension: "scss",
|
||||
});
|
||||
|
||||
check(__dirname, {
|
||||
fixture,
|
||||
migration,
|
||||
extension: "less",
|
||||
});
|
||||
|
||||
check(__dirname, {
|
||||
fixture,
|
||||
migration,
|
||||
extension: "js",
|
||||
});
|
||||
}
|
||||
@@ -1,185 +0,0 @@
|
||||
import chalk from "chalk";
|
||||
import type { FileInfo } from "jscodeshift";
|
||||
import { messages } from "../../../run-codeshift";
|
||||
import { translateToken } from "../../../utils/translate-token";
|
||||
import { updatedTokens } from "../darkside.tokens";
|
||||
|
||||
/**
|
||||
* Updates old tokens to new names.
|
||||
* Replaces global and semantic tokens with avalaible replacement.
|
||||
*/
|
||||
export default function transformer(file: FileInfo) {
|
||||
initMessageSetup();
|
||||
|
||||
let src = file.source;
|
||||
|
||||
for (const [oldToken, config] of Object.entries(updatedTokens)) {
|
||||
const oldCSSVar = `--a-${oldToken}`;
|
||||
|
||||
/* We update all re-definitions of a token to a "legacy" version */
|
||||
const replaceRegex = new RegExp("(" + `${oldCSSVar}:` + ")", "gm");
|
||||
|
||||
src = src.replace(
|
||||
replaceRegex,
|
||||
`--aksel-legacy${oldCSSVar.replace("--", "__")}:`,
|
||||
);
|
||||
|
||||
if (config.replacement.length > 0) {
|
||||
src = replaceTokenWithReference({
|
||||
src,
|
||||
newToken: `--ax-${config.replacement}`,
|
||||
oldToken: oldCSSVar,
|
||||
});
|
||||
continue;
|
||||
}
|
||||
|
||||
documentLegacyReferences({
|
||||
src,
|
||||
oldToken: oldCSSVar,
|
||||
comment: config.comment,
|
||||
});
|
||||
}
|
||||
|
||||
return src;
|
||||
}
|
||||
|
||||
/**
|
||||
* Replaces old token with new token reference.
|
||||
*/
|
||||
function replaceTokenWithReference({
|
||||
src,
|
||||
newToken,
|
||||
oldToken,
|
||||
}: {
|
||||
src: string;
|
||||
newToken: string;
|
||||
oldToken: string;
|
||||
}) {
|
||||
const CSSRgx = new RegExp("(" + oldToken + ")", "gm");
|
||||
const SCSSRgx = new RegExp(
|
||||
"(\\" + translateToken(oldToken, "scss") + ")",
|
||||
"gm",
|
||||
);
|
||||
const LESSRgx = new RegExp(
|
||||
"(" + translateToken(oldToken, "less") + ")",
|
||||
"gm",
|
||||
);
|
||||
|
||||
let fileSrc = src;
|
||||
|
||||
fileSrc = fileSrc.replace(CSSRgx, newToken);
|
||||
fileSrc = fileSrc.replace(SCSSRgx, translateToken(newToken, "scss"));
|
||||
fileSrc = fileSrc.replace(LESSRgx, translateToken(newToken, "less"));
|
||||
|
||||
return fileSrc;
|
||||
}
|
||||
|
||||
/**
|
||||
* Replaces old token with new token reference.
|
||||
*/
|
||||
function documentLegacyReferences({
|
||||
src,
|
||||
oldToken,
|
||||
comment,
|
||||
}: {
|
||||
src: string;
|
||||
oldToken: string;
|
||||
comment?: string;
|
||||
}) {
|
||||
const CSSRgx = new RegExp("(" + oldToken + ")", "gm");
|
||||
const SCSSRgx = new RegExp(
|
||||
"(\\" + translateToken(oldToken, "scss") + ")",
|
||||
"gm",
|
||||
);
|
||||
const LESSRgx = new RegExp(
|
||||
"(" + translateToken(oldToken, "less") + ")",
|
||||
"gm",
|
||||
);
|
||||
|
||||
if (CSSRgx.test(src)) {
|
||||
addMessage({ token: oldToken, comment, type: "css" });
|
||||
} else if (SCSSRgx.test(src)) {
|
||||
addMessage({
|
||||
token: translateToken(oldToken, "scss"),
|
||||
comment,
|
||||
type: "scss",
|
||||
});
|
||||
} else if (LESSRgx.test(src)) {
|
||||
addMessage({
|
||||
token: translateToken(oldToken, "less"),
|
||||
comment,
|
||||
type: "less",
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
type UpdateMessageData = {
|
||||
scss: string[];
|
||||
less: string[];
|
||||
css: string[];
|
||||
};
|
||||
|
||||
function initMessageSetup() {
|
||||
if (!messages.has("Token update")) {
|
||||
messages.set("Token update", {
|
||||
format: formatMessage,
|
||||
data: {
|
||||
scss: [],
|
||||
less: [],
|
||||
css: [],
|
||||
} satisfies UpdateMessageData,
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
function addMessage({
|
||||
token,
|
||||
comment,
|
||||
type,
|
||||
}: {
|
||||
token: string;
|
||||
comment?: string;
|
||||
type: keyof UpdateMessageData;
|
||||
}) {
|
||||
messages
|
||||
.get("Token update")
|
||||
?.data[type].push(`${token}${comment ? ` (${comment})` : ""}`);
|
||||
}
|
||||
|
||||
function formatMessage(input: UpdateMessageData) {
|
||||
const css = [...new Set(input.css)];
|
||||
const scss = [...new Set(input.scss)];
|
||||
const less = [...new Set(input.less)];
|
||||
|
||||
const total = css.length + scss.length + less.length;
|
||||
|
||||
if (total === 0) {
|
||||
console.info(
|
||||
chalk.green(
|
||||
`Found no legacy-tokens 🎉, you have now migrated over to the darkside.`,
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
console.info(chalk.green(`\nToken update`));
|
||||
console.info(
|
||||
chalk.green(
|
||||
`Found ${total} legacy tokens that are no longer supported. Until these are updated, you will need to keep the old tokens package imported in your code.`,
|
||||
),
|
||||
);
|
||||
|
||||
css.length > 0 &&
|
||||
console.info(
|
||||
`\nCSS tokens found:${css.map((token) => `\n${token}`).join("")}`,
|
||||
);
|
||||
|
||||
scss.length > 1 &&
|
||||
console.info(
|
||||
`\nSCSS tokens found:${scss.map((token) => `\n${token}`).join("")}`,
|
||||
);
|
||||
|
||||
less.length > 1 &&
|
||||
console.info(
|
||||
`\nLESS tokens found:${less.map((token) => `\n${token}`).join("")}`,
|
||||
);
|
||||
}
|
||||
@@ -1,11 +1,11 @@
|
||||
import type { API, FileInfo } from "jscodeshift";
|
||||
import { getLineTerminator } from "../../../utils/lineterminator";
|
||||
import {
|
||||
findComponentImport,
|
||||
findJSXElement,
|
||||
findProp,
|
||||
legacySpacingTokenMap,
|
||||
} from "../darkside.utils";
|
||||
} from "../../../utils/ast";
|
||||
import { getLineTerminator } from "../../../utils/lineterminator";
|
||||
import { legacySpacingTokenMap } from "../spacing.utils";
|
||||
|
||||
export default function transformer(file: FileInfo, api: API) {
|
||||
const j = api.jscodeshift;
|
||||