loogart / impact-canada

Canadian Government's Privy Council's Office Impact Canada website.
https://loogart.github.io/impact-canada/
0 stars 0 forks source link

Custom css overrides #26

Closed loogart closed 5 years ago

loogart commented 5 years ago
  1. Can there be a place where we can add global css that will override the theme's css?
  2. Is there also a possibility to add css override PER challenge? i.e. if a specific challenge has a specific style, can this more specific css be only applicable to the challenge-related pages?
djsutter commented 5 years ago

Will give this consideration. Ideally, you would be able to edit the theme directly and commit changes to github but there are process issues we would need to address. Such as how to get it to the server.

loogart commented 5 years ago

totally agree with you if that is the ideal. As far as css overrides per challenge, maybe we can simply keep the css inline for sake of simplicity (as it is right now), unless you can create challenge-specific css stylesheets.

djsutter commented 5 years ago

I have consolidated all the scss that has been accumulating during development, it's all in style.scss now. It is possible that there are regressions, so don't be surprised if something that was fixed gets broken again. Also I will leave a file called override.css (currently empty) for override that does not require scss compile. We can probably (hoepfully) address per-challenge css in the theme, but if not maybe we can figure out how to get it into the Drupal back-end editing.

loogart commented 5 years ago

@djsutter we will need guidance on how to implement (1) custom css overrides from the GUI and (2) push new styling that affects the overall templates.

djsutter commented 5 years ago

Thinking this through... we will need a process. Best option is if you can commit css changes to github and we pull them on the server. Also it allows us to test changes on the dev server and propagate them to production. For short term, immediate fixes, we can always go back to how you did it before using a block to hold global css overrides. I don't really prefer that, but it's an option.

djsutter commented 5 years ago

Would you be ok if you just email me when you need css pulled on the dev server? Or is it way better if you can pull them yourself. It is an option.

loogart commented 5 years ago

@djsutter I agree. I guess we will do the following:

  1. For any temporary styling e.g. special events, xmas colours, Halloween, etc, we will use blocks with css.
  2. When we will develop new features which will require new css, we will use blocks with css. Upon completion of the feature, we will then ask you to pull css on the dev server.
  3. For any css fixes or bugs, we will ask you to pull css on the dev server.

Does this make sense?

djsutter commented 5 years ago

Ok, yes this does make sense. The block still exists and just needs to be enabled and cleared of the previous CSS which is now obsolete. We cab also look at the ability to collaborate on the theme in github. Will need to work out a convention or process so that things work smoothly (e.g. always pull latest before you make changes).