Skip to content
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

Remove card mode to align elevation #2792

Merged
merged 51 commits into from
Jan 23, 2023

Conversation

RasmusKjeldgaard
Copy link
Collaborator

@RasmusKjeldgaard RasmusKjeldgaard commented Jan 20, 2023

Which issue does this PR close?

This PR closes #2668

What is the new behavior?

The UX group has requested a change to card elevation. This means that the 'highlighted' mode should no longer be an option, so all cards have equal elevation.

Card should use z-elevation 2 all round, and because z-elevation 4 was only used by card, I have chosen to remove it entirely, and instead make elevation 8 take its place, to not have an arbitrary gap between elevation 2 and 8 when 4 was removed. Components using elevation 8 has been changed to elevation 4 to preserve their existing look.

For this reason it no longer makes sense have a mode input with only one possible value, so I have made the option for making card appear flat as a boolean input instead, and updated the documentation accordingly.

NOTE: This PR: #2808 is a follow-up that properly remaps elevation 8 to elevation 4

Does this PR introduce a breaking change?

  • Yes
  • No

The cards 'mode' input is replaced with a boolean input 'flat' that can be set to true to remove the shadow around the card. This should never be used together with a clickable card or a card with a disclosure indicator.
The 'highlighted' look that could previously could be set on cards is no longer an option and all cards will have the same shadow.

Checklist:

The following tasks should be carried out in sequence in order to follow the process of contributing correctly.

Reminders

  • Make sure you have implemented tests following the guidelines in: "The good: Test".
  • Make sure you have updated the cookbook with examples and showcases (for bug fixes, enhancements & new components).

Review

  • Determine if your changes are a fix, feature or breaking-change, and add the matching label to your PR. If it is tooling, dependency updates or similar, add ignore-for-release.
  • Do a self-review.
  • Request that the changes are code-reviewed
  • Request that the changes are UX reviewed (only necessary if your PR introduces visual changes)

When the pull request has been approved it will be merged to develop by Team Kirby.

@github-actions github-actions bot temporarily deployed to pr-2668-align-card-elevation-2 January 20, 2023 08:22 Inactive
@RasmusKjeldgaard RasmusKjeldgaard added the breaking-change Add this PR to the changelog as a breaking change label Jan 20, 2023
@github-actions github-actions bot temporarily deployed to pr-2668-align-card-elevation-2 January 20, 2023 11:27 Inactive
@RasmusKjeldgaard RasmusKjeldgaard force-pushed the enhancement/improve-card-documentation-2 branch from 177a5aa to cd01db7 Compare January 23, 2023 09:06
@github-actions github-actions bot temporarily deployed to pr-2668-align-card-elevation-2 January 23, 2023 09:13 Inactive
Copy link
Contributor

@mark-drastrup mark-drastrup left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Beautiful! I know that is from another PR, but really nice update on the interactive parts of the card documentation! I have no comments for this PR.

Base automatically changed from enhancement/improve-card-documentation-2 to develop January 23, 2023 10:22
@RasmusKjeldgaard RasmusKjeldgaard enabled auto-merge (squash) January 23, 2023 10:24
@RasmusKjeldgaard RasmusKjeldgaard merged commit 7b0a08f into develop Jan 23, 2023
@RasmusKjeldgaard RasmusKjeldgaard deleted the enhancement/2668-align-card-elevation-2 branch January 23, 2023 10:28
@RasmusKjeldgaard RasmusKjeldgaard mentioned this pull request Jan 26, 2023
2 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking-change Add this PR to the changelog as a breaking change
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Enhancement] Align elevation on cards
2 participants