-
Notifications
You must be signed in to change notification settings - Fork 31
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
Datepicker 0 #132
Datepicker 0 #132
Conversation
affects: @fremtind/jkl-datepicker-react, @fremtind/jkl-text-input-react
affects: @fremtind/jkl-datepicker-react, @fremtind/jkl-datepicker
affects: @fremtind/jkl-datepicker-react
I'm having some issues writing tests that actually change the date. getBytText() seems to create an eternal loop that crashes the js-runtime. |
I think there are some issues with testing web components out of the box with jest/testing library. @Saegrov probably knows more about this, though. |
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.
Nice implementation! The comments below about double-imprted styles is something we should look at in all packages.
@import "~@fremtind/jkl-core/build/scss/variables/colors.scss"; | ||
@import "~@fremtind/jkl-core/build/scss/typography/paragraphs.scss"; | ||
@import "~@fremtind/jkl-core/build/scss/functions.scss"; | ||
@import "~@fremtind/jkl-text-input/text-input.scss"; |
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.
We should avoid importing other stylesheets directly, as this will duplicate the rules (presuming text-input
is used elsewhere).
} | ||
|
||
caption { | ||
@extend .jkl-p; |
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.
As above. This will include the style rules for paragraphs in duplicate for this component (since we import paragraph.scss
). Optimally we would just give the element the .jkl-p
class, but I guess that is not an option here. I still think we should try to get rid of the duplicate. Maybe make a paragraph @mixin
instead?
📥 Proposed changes
Add initial package and design for datepicker
☑️ Submission checklist
yarn build
works locally with my changes💬 Further comments
Notes:
closes: #46