StrapDown.js icon indicating copy to clipboard operation
StrapDown.js copied to clipboard

Update strapdown.js to support custom squirts and copyrights using the <squirt> and <copyright> tags in <head>.

Open ElnuDev opened this issue 4 years ago • 4 comments

Fixes #10. Minified file needs to be updated.

My apologies if I've done something wrong, this is my first pull request on GitHub!

ElnuDev avatar Jan 23 '21 18:01 ElnuDev

Oh, that's an interesting trick!

Can you please show a screenshot of how it looks on one of your page, with/without both and tags?

I'll try it myself, then merge your pull-request, and update the minified files.

I would also like to note that if HTML purists see your custom and tags, they won't be happy about them, but I don't care.

Naereen avatar Jan 23 '21 19:01 Naereen

Thanks for taking a look!

Here's my page with <squirt> and <copyright>: Screenshot from 2021-01-23 11-25-30

Here's my page without <squirt> and <copyright>: Screenshot from 2021-01-23 11-28-54

I'm not sure, perhaps it would be better just to have one tag (<subtitle>, perhaps?) that allows complete customizability and covers the whole section, instead of being forced to used <squirt> and <copyright>.

ElnuDev avatar Jan 23 '21 19:01 ElnuDev

I like your approach, as it allows to customize the location and content of the copyright notice.

I would also like to add an option, that works like the others currently supported by StrapDown.js : see this page for more details : https://naereen.github.io/StrapDown.js/example5.html

I'll do it myself, probably adding nosquirt=y and nocopyright=y. Except if you have a better suggestion? (I'll wait for a reply before merging this PR and adding my idea of these two tiny options)

Naereen avatar Jan 25 '21 11:01 Naereen

That sounds like a good idea! It's certainly cleaner than only being able to have empty <squirt> and <copyright> tags, which is the only way to remove the squirt and copyright in the system I set up.

ElnuDev avatar Jan 25 '21 18:01 ElnuDev