chronograf/ui/src/style
Andrew Watkins 4fafd851d6
Merge branch 'master' into ifql/filter
2018-05-10 16:40:05 -07:00
..
components Merge branch 'master' into ifql/filter 2018-05-10 16:40:05 -07:00
external Changes from review feedback 2018-03-01 13:40:16 -08:00
fonts Remove function icons, add "Collapse" icon 2018-05-07 09:36:41 -07:00
layout Animate overlays in and out 2018-04-24 14:50:58 -07:00
modules Introduce text color utilities from bootstrap theme 2018-02-28 00:00:42 -08:00
pages Limit max-width to TICKScript editor 2018-05-10 16:46:05 +02:00
theme Introduce styles for alerts 2018-04-09 14:41:36 -07:00
README.md Bring over enterprise ui and configuration 2016-09-19 13:45:05 -07:00
chronograf.scss Organize time machine styles 2018-05-04 10:09:12 -07:00
unsorted.scss Add space between timeFormat dropdown and input 2018-04-11 13:08:23 -07:00

README.md

Sass Organization

After spending some time with it, the general idea is that there are A LOT of opinions on how to structure sass files. This seemed like a reasonable option. Straightforward, lean, but with enough separation of concerns to make it worth the trouble in the first place.

  • /components -- this is where most of our code will go. Generally I think we'll have two types of components:
  1. more generic components like _button.scss and _form-input.scss, and 2) partials that map to React components, e.g. _Explorer.scss and _QueryEditor.scss. Most of the styles we'll end up writing will go in /components. We've toyed around with the idea of putting React component styles directly next to the component itself, so that's something to try out potentially as well.
  • /base -- global styles like resets/typography and things you'd depend on in the rest of the codebase like mixins, variables, colors, etc.

  • /layout -- larger page-level styles

  • /themes -- anything that might need to override styles, like a light/dark theme

Keep in mind this is a work in progress, and it will take some time trying things out to find a good balance.