Page 1 of 1

Additional Content - request to add a class to horizontal rules

Posted: Wed May 18, 2022 3:39 pm
by c0mp0ser
I'm making a request that in the next version of the Additional Content plugin, a class be added to <HR> - horizontal rules, separating individual content blocks. They cannot be hidden or styled using CSS without touching all other, additional horizontal rules on the page. Or maybe I'm not smart enough to get around this problem. 😆 This is the code generated by the plugin:

Code: Select all

<div id="content">...</div>
   <hr>
<div id="addition_content_1>...</div>
BTW, IMO the "style.css" in this plugin should be renamed to "additional-content.css" and also the "script.js" to "additional-content.js". If only for order when reviewing code.

Thank you. 😉

Re: Additional Content - request to add a class to horizontal rules

Posted: Fri May 20, 2022 10:18 am
by c0mp0ser
I have already created such a version of this plugin. It's called "Additional Contents Lite"
- jQuery call removed
- name "style.css" changed to "additional-contents-lite.css"
- name "script.js" changed to "additional-contents-lite.js".
- horizontal rules has CSS class "content-separator".

Now you can easy style those horizontal rules or even hide them in your theme.
If the currently activated theme calls jQuery, you can use this plugin. Works fine.
Anyone interested ...? 😉

Re: Additional Content - request to add a class to horizontal rules

Posted: Sun May 22, 2022 8:48 am
by OneManLaptop
This is fantastic stuff, yeah, show us what you've got. :) The less dependencies across WCMS the better I think.

Re: Additional Content - request to add a class to horizontal rules

Posted: Mon May 23, 2022 5:19 am
by c0mp0ser
OneManLaptop wrote: ↑Sun May 22, 2022 8:48 am This is fantastic stuff, yeah, show us what you've got. :) The less dependencies across WCMS the better I think.
Thank you for your kind words. I activated the "Paper P" theme on a trial basis which calls jQuery 1.12.4. It seems to be working. On my prepared Materialize Dark theme that calls jQuery 3.4.1, it also works.

https://github.com/pawell0/additional-contents-lite

More "lite" plugins to come ...