This PR refactors the base templates by adding a new 'master' base template which combines common elements of the existing three base templates. This new base template also extends DSC's tool base template instead of the site one, with the required header changes. (Some site_base.html specific helper files were also removed as they are now unused).
The three existing templates are now extensions of this new master template.
I've also changed the existing base templates by removing the custom uu-content implementation. Instead, the cover and hero content blocks are now in the pre-messages-content content-block and the rest now uses content from the tool_base.html template. I think the custom uu-content implementation is a leftover from when DSC didn't have a solution for this content-ordering problem, so I thought it best to switch over now that it does exist.
As a bonus:
I removed the old HomeView, it wasn't used and confused me for a second
the landing page was cleaned up and a spacing issue in the 'steps' row was fixed.
I added some setup steps to the README, I hope you don't mind ;)
There are some things I noticed, which may require further changes:
base-no-sidebar.html may be redundant now. It only adds some CSS files to the new master template. The only reason I didn't straight up replace it is because those CSS files weren't loaded in base-form.html. However, I think they don't do harm there?
I think base.html should be renamed to base-sidebar.html. It's current name suggests it's a fairly generic template, but it is in fact a specialized template for pages with a sidebar. (base-no-sidebar.html is a better candidate for the name base.html, but again, I think that template is redundant now).
There's some in-html CSS in the base template. I moved them to the master template because it was duplicated in all three existing templates, but ideally they should be in a separate CSS file (probably procreg.css?)
I didn't change those yet, because you might have a good reason for doing it this way.
This PR refactors the base templates by adding a new 'master' base template which combines common elements of the existing three base templates. This new base template also extends DSC's tool base template instead of the site one, with the required header changes. (Some
site_base.html
specific helper files were also removed as they are now unused). The three existing templates are now extensions of this new master template.I've also changed the existing base templates by removing the custom
uu-content
implementation. Instead, thecover
andhero
content blocks are now in thepre-messages-content
content-block and the rest now usescontent
from thetool_base.html
template. I think the customuu-content
implementation is a leftover from when DSC didn't have a solution for this content-ordering problem, so I thought it best to switch over now that it does exist.As a bonus:
HomeView
, it wasn't used and confused me for a secondThere are some things I noticed, which may require further changes:
base-no-sidebar.html
may be redundant now. It only adds some CSS files to the new master template. The only reason I didn't straight up replace it is because those CSS files weren't loaded inbase-form.html
. However, I think they don't do harm there?base.html
should be renamed tobase-sidebar.html
. It's current name suggests it's a fairly generic template, but it is in fact a specialized template for pages with a sidebar. (base-no-sidebar.html
is a better candidate for the namebase.html
, but again, I think that template is redundant now).procreg.css
?)I didn't change those yet, because you might have a good reason for doing it this way.