-
Notifications
You must be signed in to change notification settings - Fork 217
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
(feat): Enhancements to the OpenmrsDatePicker #1062
Conversation
On hindsight, instead of making separate styles for the asterisk only, there's probably a carbon className I could use. |
Size Change: -364 kB (-8.97%) ✅ Total Size: 3.7 MB
ℹ️ View Unchanged
|
packages/framework/esm-styleguide/src/datepicker/datepicker.module.scss
Outdated
Show resolved
Hide resolved
color: #da1e28 !important; | ||
margin-left: 0.25rem; |
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.
I think you could also get the color right by applying the .cds--form-requirement
class.
color: #da1e28 !important; | |
margin-left: 0.25rem; | |
color: theme.$text-error !important; | |
margin-left: spacing.$spacing-02; |
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.
I tried cds--form-requirement
as the className, but it didn't work. I tried looking in Carbon's playground but I couldn't find any required styling for the inputs, so I updated the styles, as suggested.
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.
Just saw that by default cds--form-requirement
has a display: none
that gets overriden by some selectors based on if the input is disabled and so on.
packages/framework/esm-styleguide/src/datepicker/datepicker.module.scss
Outdated
Show resolved
Hide resolved
Any reason this is still marked as draft? |
@ibacher Yeah I want to fix the |
@ibacher Wherever we've used Carbon inputs in form engine, we have passed in a custom component for |
Yes, we should keep things consistent, I think. |
da6521a
to
c296e16
Compare
That is the first time I've seen Turbo cause a build failure... |
Co-authored-by: Ian <[email protected]>
Requirements
feat
,fix
, orchore
, among others). See existing PR titles for inspiration.For changes to apps
If applicable
Summary
Screenshots
This PR adds styling enhancements to the Date Picker.
<Label>
component with the classNamecds-label
.After fix:
invalidText
. Renders the text passed in to the propinvalidText
if the conditionisInvalid
is true, with the carbon styling for an error message applied.invalid
toisInvalid
.Related Issue
Other