-
Notifications
You must be signed in to change notification settings - Fork 22
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(clock): small analogue clock face #54
Conversation
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'd like to do another review after comments have been addressed.
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 size=small
should not be added if it's not analog clock.
Would you please change it and write test for this change?
Regarding to the test, I suggest you breakdown test case to be smaller test. When test is failed, it's easier to understand what is going wrong e.g.
Shows small size clock when width is less than 130px
- test if [part=digital] is rendered if width >= 130px
- set width < 130px
- test if [part=digital] is not rendered
- test if [part="segment am-pm"] is rendered (ps. I wouldn't bother to check if it needs to be inside [part="hands"] but it's fine if you want the test is a little bit strict
Small size clock show AM/PM if it has attribute am-pm
- Use el = await fixture('');
- Set width <= 130px
- Test if am-pm part is rendered
Attribute size=small
shouldn't show if it's not analog clock
- el = await fixture('');
- Set width < 130px
- Test if
size=small
is not present - Set width >= 130px
- Test if
size=small
is not present
…nitiv-ui into simple-clock-face
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.
Please squash commit when merge.
Description
A new feature on the clock. When the width is less than 130px, the face of the clock will change to a smaller face that is easy to read.
Update UI of digital and analog clock to match with current spec from UX.
Type of change
Checklist