Skip to content
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

Add snippet for box-less monster statblocks #914

Closed
calculuschild opened this issue Mar 16, 2020 · 4 comments
Closed

Add snippet for box-less monster statblocks #914

calculuschild opened this issue Mar 16, 2020 · 4 comments
Labels
feature phb-style sub-epic Sub-task of an Epic tweak Small, non-breaking change

Comments

@calculuschild
Copy link
Member

See #909 .

@calculuschild calculuschild added the sub-epic Sub-task of an Epic label Nov 11, 2020
@ericscheid ericscheid added the tweak Small, non-breaking change label Nov 13, 2020
@Gazook89
Copy link
Collaborator

How about this for the snippet? It uses !important which isn't great, but it works. Added the #p1 so it can targeted at least to a page...further targeting can be done but don't want to over complicate it.

<style>
  .phb#p1 hr + blockquote {
  	background:none !important;
  	border:none !important;
  	box-shadow:none !important;
  }
</style>

@calculuschild
Copy link
Member Author

@Gazook89 Thanks for looking into this!

You may be interested in looking at #1093, which is going to involve a total re-build of the current rendering and styling system to make room for more of these missing snippets and getting rid of a lot of the cluttery CSS. Until that happens, adding new snippets is on pause. When that happens, we are likely going to move away from the hacky Markdown tricks to render different blocks (lots of hrs in odd places, things inside and outside of blockquote combinations, etc.) and just use simple div s for simplicity and extendability. As it is now, we kind of ran out of good combinations of Markdown and now we have a weird mix of div and ___ > **Title** weirdness, which just makes things confusing to users. So in this case, your code above will likely translate to something like:

.statBlock .noBox {
  background: none;
  ...
  ...
}

Once we get #1093 further along, we would love to have you and others help us dig through the CSS and clean it up, and we can probably add in some of the other cool things you've been putting together on Reddit.

@Gazook89
Copy link
Collaborator

Gazook89 commented Dec 13, 2020

Just messing around with div-based snippets that skip using <hr> and <blockquote> elements for complex css selections. Started with Monster Stat Blocks. This result also separates out the frame/border/background component into it's own css class, so it's easy to toggle that one or off.

I know this is 'future' stuff until the new renderer is in place, and perhaps it's not useful to have it done piecemeal in homebrewery documents like this, but I also didn't want to just sit on it if I've got it:

Share Link is here: Revised Monster Stat Block. I can comment in the code if needed.

And because I'm not sure where to put it, I'll mention here that I also did the same for Class Features.

@calculuschild
Copy link
Member Author

Added to the V3 changelog finally. Closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature phb-style sub-epic Sub-task of an Epic tweak Small, non-breaking change
Projects
None yet
Development

No branches or pull requests

3 participants