-
Notifications
You must be signed in to change notification settings - Fork 42
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
136 changed files
with
1,351 additions
and
1,660 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
--- | ||
"@navikt/ds-react": minor | ||
--- | ||
|
||
:recycle: Refaktorering og småfikser | ||
|
||
- Refaktorering som følge av nye ESLint-regler | ||
- AccordionItem/ToggleGroup: Støtte for 'id'-prop | ||
- MonthPicker: Mer presis type for 'onMonthSelect' prop |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
!.storybook |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,93 @@ | ||
// TODO: Convert to new format: https://eslint.org/docs/latest/use/configure/migration-guide | ||
module.exports = { | ||
env: { | ||
browser: true, | ||
es6: true, | ||
node: true, | ||
}, | ||
extends: [ | ||
"eslint:recommended", | ||
"plugin:react/recommended", | ||
//"plugin:react/jsx-runtime", // Not sure if this will cause problems for projects not using the new JSX transform | ||
"plugin:react-hooks/recommended", | ||
"plugin:jsx-a11y/recommended", | ||
"plugin:import/recommended", | ||
"plugin:import/typescript", | ||
"plugin:storybook/recommended", | ||
// TODO: Look into opinionated stylistic plugin | ||
// TODO: Replace @typescript-eslint/recommended with @typescript-eslint/recommended-type-checked | ||
], | ||
settings: { react: { version: "detect" } }, | ||
rules: { | ||
"import/no-unresolved": "off", | ||
"react/jsx-curly-brace-presence": [ | ||
"error", | ||
{ propElementValues: "always" }, | ||
], | ||
// TODO add: "object-shorthand": "error", | ||
// TODO: Consider adding the rule "id-length" | ||
// Temporary: | ||
"react/prop-types": "off", | ||
"react/display-name": "off", | ||
"import/no-named-as-default": "off", | ||
}, | ||
reportUnusedDisableDirectives: true, | ||
overrides: [ | ||
{ | ||
files: ["**/*.ts?(x)"], | ||
extends: ["plugin:@typescript-eslint/recommended"], | ||
rules: { | ||
"@typescript-eslint/no-explicit-any": "off", // Temporary | ||
}, | ||
}, | ||
{ | ||
files: ["**/*.test.*", "**/__tests__/*"], | ||
extends: ["plugin:jest/recommended", "plugin:testing-library/react"], | ||
}, | ||
{ | ||
files: ["aksel.nav.no/website/**"], | ||
env: { | ||
browser: true, | ||
es2021: true, | ||
}, | ||
extends: ["plugin:@next/next/recommended"], | ||
parser: "@typescript-eslint/parser", | ||
parserOptions: { | ||
ecmaFeatures: { | ||
jsx: true, | ||
}, | ||
ecmaVersion: 12, | ||
sourceType: "module", | ||
}, | ||
rules: { | ||
"react/no-unknown-property": [2, { ignore: ["jsx", "global"] }], | ||
"react/react-in-jsx-scope": "off", | ||
"@next/next/no-html-link-for-pages": [ | ||
"error", | ||
"aksel.nav.no/website/pages/", | ||
], | ||
"@typescript-eslint/ban-ts-comment": "off", // Temporary | ||
}, | ||
}, | ||
{ | ||
files: ["aksel.nav.no/website/pages/eksempler/**"], | ||
rules: { | ||
"jsx-a11y/anchor-is-valid": "off", | ||
}, | ||
}, | ||
], | ||
globals: { | ||
Locale: "readonly", | ||
JSX: "readonly", | ||
}, | ||
ignorePatterns: [ | ||
"node_modules", | ||
"lib", | ||
"public", | ||
"examples", | ||
"esm", | ||
"cjs", | ||
"dist", | ||
"**/codemod/**/*.js", | ||
], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
import React from "react"; | ||
import "@navikt/ds-css/index.css"; | ||
import "./layout.css"; | ||
|
||
|
1 change: 0 additions & 1 deletion
1
@navikt/aksel-icons/figma-plugin/scripts/vite/vite-inline-svg.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,3 @@ | ||
/* eslint-disable import/no-anonymous-default-export */ | ||
import fs from "fs"; | ||
import { Plugin } from "vite"; | ||
|
||
|
21 changes: 0 additions & 21 deletions
21
@navikt/aksel-icons/figma-plugin/src/common/network/init.ts
This file was deleted.
Oops, something went wrong.
21 changes: 0 additions & 21 deletions
21
@navikt/aksel-icons/figma-plugin/src/common/network/messages.ts
This file was deleted.
Oops, something went wrong.
42 changes: 0 additions & 42 deletions
42
@navikt/aksel-icons/figma-plugin/src/common/network/messages/CreateRectMessage.ts
This file was deleted.
Oops, something went wrong.
19 changes: 0 additions & 19 deletions
19
@navikt/aksel-icons/figma-plugin/src/common/network/messages/HelloMessage.ts
This file was deleted.
Oops, something went wrong.
17 changes: 0 additions & 17 deletions
17
@navikt/aksel-icons/figma-plugin/src/common/network/messages/PingMessage.ts
This file was deleted.
Oops, something went wrong.
24 changes: 0 additions & 24 deletions
24
@navikt/aksel-icons/figma-plugin/src/common/network/sides.ts
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.