calcite-design-system icon indicating copy to clipboard operation
calcite-design-system copied to clipboard

Enhancement: update component shadows per latest Figma designs

Open bstifle opened this issue 4 years ago • 18 comments

In order to keep 1:1 change between light and dark theme, these changes have been vetted by design group:

image

  • Change border radius to 4px --calcite-border-radius: 4px
  • Add border-3 to light theme level 2 components
  • Add border-3-dark to dark theme level 2 components
  • Use foreground-1-dark on dark theme level 2 components instead of foreground-3

This applies to dropdown, alert, modal, date picker, tooltip, action pad, tip manager, popover, combobox dropdown, color picker (when it's a dropdown)

bstifle avatar Dec 28 '20 23:12 bstifle

@bstifle does this one still apply?

caripizza avatar May 21 '21 00:05 caripizza

Yes i believe so!

bstifle avatar May 21 '21 17:05 bstifle

checking in on this one again

julio8a avatar Jul 16 '21 05:07 julio8a

@julio8a @bstifle isn't this already covered in our refactors based on the Figma designs?

caripizza avatar Jul 16 '21 16:07 caripizza

Yes, closing.

julio8a avatar Jul 16 '21 17:07 julio8a

Hmm. Not seeing these shadows in our components on master @caripizza @julio8a

bstifle avatar Jul 19 '21 15:07 bstifle

@bstifle do the shadows appear in the Figma designs that we're using for the refactors?

caripizza avatar Jul 19 '21 15:07 caripizza

@caripizza yep! i wonder if this is just a shadows utility class we need to fix? other than the shadows, the other design criteria seem to be met in the issue

bstifle avatar Jul 19 '21 16:07 bstifle

Re-opened after clarifying the remaining work needed in this issue with Bryan (@bstifle please correct or add anything I missed from our chat).

Based on first glance, it looks like:

  1. _popper.scss global styles - currently using $shadow-2 sass var - needs to instead use @apply shadow-2:
  2. Additionally, the %shadow-vars sass placeholder we have here: src/assets/styles/_shadow.scss Don't seem to be used right now. We don't want these as global CSS Vars as far as I know, so let's remove them. As long as we have what we need in TW config under boxShadow object, we can refer to those moving forward. (But why do we have duplicate 0 and 1 values?)

@julio We should also use this issue to update the shadows content in our readme to make sure it corresponds with (or points to) the content we add in dev docs: https://github.com/ArcGIS/afd-calcite-documentation/issues/57

caripizza avatar Jul 22 '21 23:07 caripizza

Can we update the description to a) articulate which components are Level 0, 1, or 2 (I don't know), and b) so we can style their shadows based on their level?

caripizza avatar Jul 22 '21 23:07 caripizza

@caripizza this issue is for specific components (listed in the description at the bottom) and wont apply to all components with shadows

bstifle avatar Jul 27 '21 18:07 bstifle

here are the depth values and which components use them:

Depth Light Depth Dark

bstifle avatar Jul 27 '21 18:07 bstifle

This issue needs another design review (Figma) before moving into code.

julio8a avatar Sep 03 '21 19:09 julio8a

Should the updated box-shadows correspond to the output of this calcite-base mixin?

https://github.com/Esri/calcite-base/blob/master/dist/_shadow.scss

(Currently only referenced in calcite-slider.)

caripizza avatar Sep 23 '21 21:09 caripizza

This one was moved to the Oct 11 sprint. @macandcheese will need to give this another design review.

julio8a avatar Sep 24 '21 19:09 julio8a

Moving this issue to the Freezer after discussion with @macandcheese.

caripizza avatar Oct 13 '21 15:10 caripizza

The proposed shadows are shown in this codepen.

It appears that the most used shadows are shadow-1 and shadow-2. The other shadows are only used in these cases:

  • shadow-1-sm
    • Card's active state. Card shouldn't have an active state since it's not clickable.
  • shadow-1-lg
    • Card's hover state. Card shouldn't have an active state since it's not clickable.
  • shadow-2-sm
    • Fab's active state
    • Modal
  • shadow-2-lg
    • Fab's hover state

Also, it seems that shadow-0 and shadow-1 in the tailwind confige are the same?

Propose removing the rarely use shadows and updating those components as such:

  • Card active and hover states would not exist.
  • Fab's states would be handled with color states that match Button
  • Modal could use 1.

asangma avatar May 17 '22 23:05 asangma

Agree w @asangma assessment - these could be greatly simplified. Let's also consider other theming options for shadow so even if the "default Calcite" theme doesn't have a shadow in the design, an overriding theme may.

macandcheese avatar Jun 17 '22 18:06 macandcheese

Prioritization will be made after the 1.0 release next month.

geospatialem avatar Dec 01 '22 22:12 geospatialem

Related issue https://github.com/Esri/calcite-components/issues/3122

geospatialem avatar Mar 03 '23 20:03 geospatialem

@ashetland @SkyeSeitz proposing we close this one and address in an updated issue if this is still needed, but this seems a bit outdated at this point compared to current Figma.

macandcheese avatar Aug 18 '23 13:08 macandcheese

Agreed. Would be dealt with in #3122.

ashetland avatar Aug 18 '23 16:08 ashetland

Agreed. Would be dealt with in #3122.

+1

SkyeSeitz avatar Aug 18 '23 16:08 SkyeSeitz