Skip to content

Color: Mapping from codes (e.g. a400) to names (e.g. accent1) #987

Closed

Description

@phlippieb

It seems like material colors are usually named according to a code-based naming scheme (e.g. blue 500, orange a400). The material color library uses a different naming scheme (e.g. blue.base, orange.accent1). The alternative naming scheme is presumably chosen because blue.500 would be invalid syntax, and that's fine. But: how do these schemes map to one another? Is this documented somewhere that I missed?

Activity

  1. daniel-jonathan commented on Nov 29, 2017

    @daniel-jonathan
    Member

    Hey! Take a look at this site, http://materialcolor.com. It shows you the colors mapped with code, hex, and the swift label. If you need further help, please let me know. Thank you! I will be updating it to make it more clear. Basically, it starts from the base and goes up and down the darken and lighten scale.

  2. phlippieb commented on Nov 30, 2017

    @phlippieb
    ContributorAuthor

    Hi @DanielDahan! Thanks for the response. I have seen that site, and (unless I'm being an idiot) I don't see the swift labels there. I mean, there are colors (e.g. "Red"), but no "darken1", "lighten4", "accent3"-style text. I can see in the page's html that those values are used as tag classes etc, but I don't see it surfaced as human-readable text at all.

  3. phlippieb commented on Nov 30, 2017

    @phlippieb
    ContributorAuthor

    screen shot 2017-11-30 at 10 01 55 am
    @DanielDahan This is what the site looks like to me in chrome. There is no more content to the left or right.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions