greymatter-io / gm-ui-components

A library of reusable Grey Matter UI components.
MIT License
15 stars 6 forks source link

Audit Theme Style Variables #445

Closed shanberg closed 5 years ago

shanberg commented 5 years ago

Goals:

Define roadmap for any variable name changes, considering any change will impact downstream applications.

shanberg commented 5 years ago

Proposed new theme constants

Scheme: PROPERTY_ROLE_VARIANT

Notable changes

//// COLOR

COLOR_BRAND_PRIMARY
COLOR_BRAND_SECONDARY

COLOR_BACKGROUND_DEFAULT
COLOR_BACKGROUND_TWO
COLOR_BACKGROUND_THREE

COLOR_CONTENT_DEFAULT
COLOR_CONTENT_CONTRAST
COLOR_CONTENT_MUTED
COLOR_CONTENT_NONESSENTIAL

COLOR_INTENT_HIGHLIGHT
COLOR_INTENT_SUCCESS
COLOR_INTENT_WARNING
COLOR_INTENT_DANGER
COLOR_INTENT_INFO

COLOR_KEYLINE_DEFAULT
COLOR_KEYLINE_FLAT

//// LAYOUT

OPACITY_FULL
OPACITY_LIGHT
OPACITY_LIGHTER
OPACITY_LIGHTEST

RADIUS_SHARP
RADIUS_INPUT
RADIUS_CARD_LG
RADIUS_CARD_DEFAULT
RADIUS_CARD_SM
RADIUS_MAX

SPACING_BASE

ZINDEX_ABYSS
ZINDEX_FLOOR
ZINDEX_DROPDOWN
ZINDEX_STICKY
ZINDEX_FIXED
ZINDEX_SCRIM
ZINDEX_MODAL
ZINDEX_POPOVER
ZINDEX_TOOLTIP

//// TYPOGRAPHY

FONT_STACK_BRAND
FONT_STACK_DEFAULT
FONT_STACK_CODE

FONT_SIZE_PAGE_TITLE

FONT_SIZE_HEADING_LG
FONT_SIZE_HEADING_DEFAULT
FONT_SIZE_HEADING_SM

FONT_SIZE_SUBHEADING_LG
FONT_SIZE_SUBHEADING_DEFAULT
FONT_SIZE_SUBHEADING_SM

FONT_SIZE_ITEM_TITLE_LG
FONT_SIZE_ITEM_TITLE_DEFAULT
FONT_SIZE_ITEM_TITLE_SM

FONT_SIZE_TEXT_XL
FONT_SIZE_TEXT_LG
FONT_SIZE_TEXT_DEFAULT
FONT_SIZE_TEXT_SM
FONT_SIZE_TEXT_XS

LINE_HEIGHT_LOOSE
LINE_HEIGHT_DEFAULT
LINE_HEIGHT_TIGHT

FONT_WEIGHT_DEFAULT
FONT_WEIGHT_MEDIUM
FONT_WEIGHT_SEMIBOLD
FONT_WEIGHT_BOLD
tilleryd commented 5 years ago

@shanberg Perhaps opacity should also use a variant?

OPACITY_DEFAULT
OPACITY_DIFFUSED_STRONG
OPACITY_DIFFUSED_LIGHT
OPACITY_TRANSLUCENT
shanberg commented 5 years ago

Exploring the options...

OPACITY_FULL
OPACITY_MOSTLY
OPACITY_HALF
OPACITY_BARELY

OPACITY_FULL
OPACITY_MOSTLY_THERE
OPACITY_HALF_THERE
OPACITY_BARELY_THERE

OPACITY_FULL
OPACITY_MOST
OPACITY_HALF
OPACITY_SLIGHT
shanberg commented 5 years ago

I'm wondering if we can do better than DIFFUSED... along the axis of learnability. It’s not immediately clear without testing that DIFFUSED_STRONG is a higher opacity value than DIFFUSED_LIGHT. Is DIFFUSED_STRONG strongly diffused, or strong but diffused?

I think we could do better than this with

OPACITY_FULL
OPACITY_LIGHT
OPACITY_LIGHTER
OPACITY_LIGHTEST
shanberg commented 5 years ago

@kaitmore @tilleryd

COLOR_BRAND_PRIMARY
COLOR_BRAND_SECONDARY
COLOR_BACKGROUND_DEFAULT
COLOR_BACKGROUND_TWO
COLOR_BACKGROUND_THREE
OPACITY_FULL
OPACITY_LIGHT
OPACITY_LIGHTER
OPACITY_LIGHTEST
tilleryd commented 5 years ago

@shanberg I'm cool with the opacity variants you came up with.

OPACITY_FULL
OPACITY_LIGHT
OPACITY_LIGHTER
OPACITY_LIGHTEST
shanberg commented 5 years ago

Closed by #490