This repository has been archived by the owner on Apr 18, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 320
feat: LEAP-336: Collapsible cards in Ranker #1612
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
First try with just collapsible items, no design, via react context.
Codecov ReportAttention:
📢 Thoughts on this report? Let us know! |
} | ||
|
||
button span::after { | ||
content: '△'; |
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.
this functions just fine but it may look better if we use icons instead - can Design provide icons? or do you want to pull in React icons much like we have in DM2 and LSP
yyassi-heartex
approved these changes
Nov 7, 2023
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.
approved but i have a optional suggestion to use icons like react-icons or icons provided by design for better visuals
This will allow to disable collapsible items if they are not a good fit for any reason. Fix styles to be applied only when it's true.
hlomzik
force-pushed
the
fb-leap-336/collapsible-card
branch
from
November 10, 2023 00:45
4aa886d
to
7f9d6ad
Compare
Gondragos
approved these changes
Nov 10, 2023
MasherJames
pushed a commit
to HelloPareto/label-studio-frontend
that referenced
this pull request
Feb 29, 2024
* feat: LEAP-336: Make Ranker cards collapsible First try with just collapsible items, no design, via react context. * Move styling and hiding to styles * Collapse/Expand All in column titles * Add param `collapsible` default to true This will allow to disable collapsible items if they are not a good fit for any reason. Fix styles to be applied only when it's true. * Change default styles; better to be more universal by default
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Allow to collapse and expand cards for easy interactions. With collapsed cards user can see lot of items together with makes rearrangement easier.
Collapsed/expanded states are indicated by ASCII triangles (△/▽ and ▲/▼ for hovered state) used in css to change only class names, not the content and to keep indicators in one place.
Collapse is desirable action so column is treated as expanded when at least one item is expanded. This allows to collapse all items in any state by one click.
New hidden parameter added to
Ranker
:collapsible
with default true to allow to disable this functionality if it's not needed for any reason.PR fulfills these requirements
What libraries were added/updated?
none
Does this change affect performance?
nope
Does this change affect security?
nope
What alternative approaches were there?
Cards can be made hidden with animation to not change the content inside, but this will require calculations of their height.
What feature flags were used to cover this change?
none yet
Does this PR introduce a breaking change?
What level of testing was included in the change?
(check all that apply)
Which logical domain(s) does this change affect?
Ranker