Skip to content
This repository has been archived by the owner on Mar 4, 2024. It is now read-only.

Add css file with design tokens #12

Draft
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

ffigiel
Copy link

@ffigiel ffigiel commented Feb 11, 2024

Context

All core gleam websites such as generated docs, packages site, etc. have their own independent CSS files, which makes them somewhat difficult to maintain while staying consistent with the styles of other sites.

While working on gleam-lang/packages#28 (comment), I suggested an idea to provide a shared collection of colors, sizes, etc. that will be reused across the websites for better consistency.
We discussed this on discord and chose to use the branding repo as the "source of truth", and to copy-and-paste the file around

Process

I decided it will be best/easiest to start with colors.
I downloaded the stylesheets from https://gleam.run/, https://packages.gleam.run/, https://tour.gleam.run/ and https://hexdocs.pm/gleam_stdlib/
Then I wrote a small python stript to find the most common colors between them.

To avoid bikeshedding color names, I'm using the names from https://www.color-name.com/, except for faff-pink because it's already being called this way in the community.

update: It was suggested to use basic hue names and colors (similar to what Tailwind does). I assigned the intensity numbers by comparing the colors to the ones at https://tailwindcss.com/docs/background-color

I will be extending this stylesheet as I update the projects to use it

@ffigiel ffigiel marked this pull request as draft February 11, 2024 17:13
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant