Skip to content

Instantly share code, notes, and snippets.

@jasonlemay
Created May 14, 2015 14:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jasonlemay/0c17056185ec53cee7e8 to your computer and use it in GitHub Desktop.
Save jasonlemay/0c17056185ec53cee7e8 to your computer and use it in GitHub Desktop.
Managing your CSS (GSS) files with variables and a theme
// src/main/resources/com/company/project/client/resources/css/theme.gss
@provide 'theme';
/**
* Colors
*/
@def C_PRIMARY eval("com.company.project.client.resources.theme.Colors.C_PRIMARY");
@def C_PRIMARY_BACKGROUND eval("com.company.project.client.resources.theme.Colors.C_BACKGROUND");
@def C_TEXT eval("com.company.project.client.resources.theme.Colors.C_TEXT");
/* ... */
/**
* Fonts
*/
@def F_PRIMARY eval("com.company.project.client.resources.theme.Fonts.F_PRIMARY");
@def F_PRIMARY_BOLD eval("com.company.project.client.resources.theme.Fonts.F_PRIMARY_BOLD");
/* ... */
/**
* Sizes
*/
@def S_LINE_HEIGHT eval("com.company.project.client.resources.theme.Sizes.S_LINE_HEIGHT");
@def S_SECTION_PADDING eval("com.company.project.client.resources.theme.Sizes.S_SECTION_PADDING");
/* ... */
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment