-
-
Notifications
You must be signed in to change notification settings - Fork 55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Wrap blog templates with an ablog CSS selector #143
Comments
I would just need to add a custom div like that for each html file in https://github.com/sunpy/ablog/tree/main/ablog/templates ? |
Yeah I think so - you could just do a pattern like: <div class="ablog-item ablog__{{ TEMPLATE-FILENAME }}">
{{ whatever is in there now }}
</div> cc @pradyunsg in case he has any thoughts there |
Similarly, for the HTML elements that at put onto a page, like the <div class="section">
<span style="float: left">
Previous:
<a href="post2.html">
Post 2
</a>
</span>
<span> </span>
<span style="float: right">
</span>
</div> could instead be: <div class="section ablog__prev-next">
<span style="float: left">
Previous:
<a href="post2.html">
Post 2
</a>
</span>
<span> </span>
<span style="float: right">
</span>
</div> |
Thanks, I will see about getting this in ablog within this week. |
Describe the feature
Currently, this extension has no way of knowing whether an inserted template is related to
ABlog
. For example:from https://github.com/sunpy/ablog/blob/main/ablog/templates/authors.html :
This makes it harder to create CSS rules that make ABlog behave in certain ways (e.g. as a part of themes)
Proposed solution
An easy path forward would be to wrap all of those
ablog
templates with a CSS selector that was unique to the template. For example:References
I think this is related to:
The text was updated successfully, but these errors were encountered: