-
Notifications
You must be signed in to change notification settings - Fork 60
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: introduce Quick View component #1898
Conversation
✔️ Deploy preview for fundamental-styles ready! 🔨 Explore the source changes: bb2ac13 🔍 Inspect the deploy logs: https://app.netlify.com/sites/fundamental-styles/deploys/5feb28e0eda0f100079766ae 😎 Browse the preview: https://deploy-preview-1898--fundamental-styles.netlify.app |
It would be great to add an example in RTL mode |
HI @EvilAlexei Expected: Actual implemented: |
</div> | ||
|
||
<div class="fd-quick-view__group"> | ||
<div class="fd-quick-view__group__title"> |
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.
it should be -title
instead of __title
This element is a content holder inside flex layout, also there is a fix for flex width :) |
If it's just a container to follow a flex layout we should name it properly cause |
Hi Oleksii, |
It's a name based on semantic content, and it's a common name for such content. In my opinion semantic name better than styling naming. It's higher chances that styles will be changed, but the type of content has fewer chances to be changed. |
From provided |
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.
Hello @EvilAlexei I added some comments, that will drastically change component structure. This should be more composition of components, not standalone component. I can't see any specification for quick view. PM me, if you willl have any questions
src/quick-view.scss
Outdated
min-width: 20rem; | ||
max-width: 30rem; |
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.
Where are those limits from?
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 wasn't able to find any info about those limits in the design docs,
but this component has already pre-defined content and I think those limits are necessary for the view perception.
For min-width
I used a width value from [examples], (https://sapui5.hana.ondemand.com/#/entity/sap.m.QuickView/sample/sap.m.sample.QuickView) They all have 320px
width.
I wasn't able to use max-width as well from those examples because it is dynamic there,
so 30rem
is my assumption
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.
Could you then put it as a hardcoded value into examples? You can use inline-styling or check how it's done with dialog
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.
Hello @EvilAlexei Great job with refactoring this component. You are almost there, I added some code related comments
src/quick-view.scss
Outdated
min-width: 20rem; | ||
max-width: 30rem; |
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.
Could you then put it as a hardcoded value into examples? You can use inline-styling or check how it's done with dialog
</div> | ||
`; | ||
|
||
RTLMode.storyName = 'RTL mode'; |
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.
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.
changed
Hello @JKMarkowski, thank you for your comments! About About min-width: About max-width: |
Hello @EvilAlexei, thanks for complex response, I totally agree with you that those limitations will be a little handy for users, but it's same situation as with dialogs, or card. We provide such a limits on docs level, because specification doesn't specify them. Let's keep it same with this component. Everything else looks great for me. Good job! |
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.
LGTM
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.
Looks good!
Related Issue
No related issue
Description
This PR introduces the Quick View component
Please check whether the PR fulfills the following requirements
rem
fd-*
class is used in the filefd-rtl
,fd-ellipsis
,fd-flex
,fd-selected
,fd-focus
, ect.)fd-reset()
mixin is applied to all elementsnormalize
optionunnormalize
option