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

Improve naming of logo.with and color.with #18

Open
gadenbuie opened this issue Sep 10, 2024 · 1 comment
Open

Improve naming of logo.with and color.with #18

gadenbuie opened this issue Sep 10, 2024 · 1 comment

Comments

@gadenbuie
Copy link
Collaborator

gadenbuie commented Sep 10, 2024

We introduced the with abstraction when we realized there was a common pattern across logo (logo files), color (color palette) and typography (fonts). Upon implementing the spec, @cscheid and I realized that fonts are sufficiently different from files and the color palette that they don't fit the with abstraction (see #3).

With only two fields supporting with, it's worth reconsidering. While I like the abstraction, I think color.palette is significantly easier to explain and understand than color.with and I think this is a strong reason to consider switching back to palette instead of with.

That leaves logo.with as a singleton, which could be renamed images without changing the implementation (in theory).

logo:
  images:
    primary: full-color.png
    reverse: full-color-reverse.png
    icon: favicon.png
    both:
      light: primary
      dark: reverse
  small: icon
  medium: both

color:
  palette:
    white: "#FFFFFF"
    black: "#151515"
    blue: "#447099"
  foreground: black
  background: white
  primary: blue

typography:
  fonts:
    - source: google
      family: Open Sans
  base:
    family: "Open Sans"
    line-height: 1.25
    size: 1rem
@gadenbuie
Copy link
Collaborator Author

Renamed to brand.color.palette and brand.logo.images in brand_yaml for Python.

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

No branches or pull requests

1 participant