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

Compound: add BigIcon, BigCheckmark and PageTitle components #2574

Merged
merged 5 commits into from
Mar 21, 2024

Conversation

jmartinesp
Copy link
Member

@jmartinesp jmartinesp commented Mar 20, 2024

Type of change

  • Feature
  • Bugfix
  • Technical
  • Other : add compound components

Content

Adds 3 new Compound components that will be needed for future development:

  • BigIcon.
  • BigCheckmark.
  • PageTitle.

Motivation and context

These components will be used in new designs and will replace older ones we were using.

Screenshots / GIFs

Being recorded.

Tests

Nothing, but you can check the screenshots look like the designs in Figma.

Tested devices

  • Physical
  • Emulator
  • OS version(s):

Checklist

@jmartinesp jmartinesp requested a review from a team as a code owner March 20, 2024 16:56
@jmartinesp jmartinesp requested review from bmarty and removed request for a team March 20, 2024 16:56
Copy link
Contributor

github-actions bot commented Mar 20, 2024

📱 Scan the QR code below to install the build (arm64 only) for this PR.
QR code
If you can't scan the QR code you can install the build via this link: https://i.diawi.com/U4Fsqj

Copy link

codecov bot commented Mar 20, 2024

Codecov Report

Attention: Patch coverage is 83.14607% with 15 lines in your changes are missing coverage. Please review.

Project coverage is 73.19%. Comparing base (6aa84d6) to head (a53a0a8).
Report is 3 commits behind head on develop.

Files Patch % Lines
...oid/libraries/designsystem/components/PageTitle.kt 72.97% 5 Missing and 5 partials ⚠️
.../libraries/designsystem/components/BigCheckmark.kt 62.50% 0 Missing and 3 partials ⚠️
...droid/libraries/designsystem/components/BigIcon.kt 95.23% 0 Missing and 2 partials ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #2574      +/-   ##
===========================================
+ Coverage    73.16%   73.19%   +0.02%     
===========================================
  Files         1410     1413       +3     
  Lines        34202    34291      +89     
  Branches      6638     6670      +32     
===========================================
+ Hits         25024    25098      +74     
- Misses        5713     5718       +5     
- Partials      3465     3475      +10     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@bmarty bmarty left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

) {
val backgroundColor = when (style) {
is Style.Default -> ElementTheme.colors.bigIconDefaultBackgroundColor
Style.AlertSolid, Style.SuccessSolid -> ElementTheme.colors.bgCanvasDefault
Copy link
Member

Choose a reason for hiding this comment

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

I am wondering if using a transparent color should be preferable in this case. I let you decide.

Copy link
Member Author

Choose a reason for hiding this comment

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

Transparent is probably better, although it kind of contradicts its name. I'm asking in the Compound room to clarify this.

Copy link
Member Author

Choose a reason for hiding this comment

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

I just confirmed it with them, it's the other way around: the solid ones should have a solid background (duh), the others should be transparent. I'll change those.

internal class BigIconStylePreviewProvider : PreviewParameterProvider<BigIcon.Style> {
override val values: Sequence<BigIcon.Style>
get() = sequenceOf(
BigIcon.Style.Default(Icons.Filled.CatchingPokemon),
Copy link
Member

Choose a reason for hiding this comment

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

:)

Make the non-solid ones use a transparent one.
@jmartinesp jmartinesp added the Record-Screenshots Runs the 'Record Screenshots' CI job and adds a commit with any new screenshots found. label Mar 21, 2024
@github-actions github-actions bot removed the Record-Screenshots Runs the 'Record Screenshots' CI job and adds a commit with any new screenshots found. label Mar 21, 2024
Copy link

sonarcloud bot commented Mar 21, 2024

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarCloud

@jmartinesp jmartinesp merged commit 998eb7d into develop Mar 21, 2024
16 checks passed
@jmartinesp jmartinesp deleted the misc/jme/add-compound-big-icon-and-title branch March 21, 2024 10:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants