-
Notifications
You must be signed in to change notification settings - Fork 42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Migration]: box -> boxNew #3669
base: main
Are you sure you want to change the base?
Conversation
|
Storybook demo / Chromatic24124919d | 91 components | 135 stories |
it's currently missing a change to using |
@navikt/aksel/src/codemod/transforms/darkside/box-to-boxnew/box-to-boxnew.ts
Show resolved
Hide resolved
@navikt/aksel/src/codemod/transforms/darkside/box-to-boxnew/box-to-boxnew.ts
Outdated
Show resolved
Hide resolved
Think it should work, token-name keys should match the names used for the props 🤞 But wouldn't hurt to skim over them to make sure. |
@navikt/aksel/src/codemod/transforms/darkside/box-to-boxnew/box-to-boxnew.ts
Outdated
Show resolved
Hide resolved
Decided to not be as cool and preserve existing localName, if you get the new box, it will always become
There really doesn't seem to be a winning way of doing all the work for developers, we have to use two different names because there's no going around having multiple Box types during migration 😢. The more I think about it, the more I think i like |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code errors on build now, so cant test
[@navikt/aksel]: src/codemod/transforms/darkside/box-to-boxnew/box-to-boxnew.ts(68,43): error TS2339: Property 'name' does not exist on type 'JSXIdentifier | JSXNamespacedName | JSXMemberExpression'.
[@navikt/aksel]: Property 'name' does not exist on type 'JSXMemberExpression'.
[@navikt/aksel]: src/codemod/transforms/darkside/box-to-boxnew/box-to-boxnew.ts(69,43): error TS2339: Property 'name' does not exist on type 'JSXIdentifier | JSXNamespacedName | JSXMemberExpression'.
[@navikt/aksel]: Property 'name' does not exist on type 'JSXMemberExpression'.
[@navikt/aksel]: src/codemod/transforms/spacing/primitives-spacing/spacing.ts(5,3): error TS2724: '"../../../utils/ast"' has no exported member named 'findProp'. Did you mean 'findProps'?
[@navikt/aksel]: Process exited (exit code 2), completed in 1s 992ms
@KenAJoh nice idempotency tests! (i forgot about those completely) |
Description
Component Checklist 📝
@navikt/core/css/config/_mappings.js
)@navikt/core/css/tokens.json
)@navikt/aksel-stylelint/src/deprecations.ts
)@navikt/core/react/src/index.ts
and@navikt/core/react/package.json
)@navikt/core/css/index.css
)<Component>: <gitmoji?> <Text>.
E.g. "Button: ✨ Add feature xyz.")