diff --git a/themes/V3/5ePHB/snippets.js b/themes/V3/5ePHB/snippets.js index bea2a1da3..afdbf1e49 100644 --- a/themes/V3/5ePHB/snippets.js +++ b/themes/V3/5ePHB/snippets.js @@ -5,6 +5,7 @@ const ClassTableGen = require('./snippets/classtable.gen.js'); const MonsterBlockGen = require('./snippets/monsterblock.gen.js'); const ClassFeatureGen = require('./snippets/classfeature.gen.js'); const CoverPageGen = require('./snippets/coverpage.gen.js'); +const PartCoverPageGen = require('./snippets/partcoverpage.gen.js'); const TableOfContentsGen = require('./snippets/tableOfContents.gen.js'); const dedent = require('dedent-tabs').default; @@ -173,6 +174,11 @@ module.exports = [ icon : 'fas fa-file-word', gen : CoverPageGen, }, + { + name : 'Part Cover Page', + icon : 'fas fa-file-alt', + gen : PartCoverPageGen, + }, { name : 'Magic Item', icon : 'fas fa-hat-wizard', diff --git a/themes/V3/5ePHB/snippets/partcoverpage.gen.js b/themes/V3/5ePHB/snippets/partcoverpage.gen.js new file mode 100644 index 000000000..f4720d219 --- /dev/null +++ b/themes/V3/5ePHB/snippets/partcoverpage.gen.js @@ -0,0 +1,53 @@ +const _ = require('lodash'); + +var titles = [ + 'Introduction to the World of DnD', + 'Creating Your Character', + 'The Rules of the Game', + 'Combat and Combat Strategies', + 'Magic and Spellcasting', + 'Adventuring and Exploration', + 'Dungeon Delving', + 'Campaign Building and World Building', + 'DM Techniques and Tips', + 'Appendix: Reference Material', + 'Monsters and Creatures', + 'Equipment and Treasure', + 'Non-Player Characters (NPCs)', + 'Experience and Leveling', + 'Races and Classes', + 'Skills and Abilities', + 'Alignment and Moral Choices', + 'Player-vs-Player Conflict', + 'Game Mastering 101', + 'Running a Successful Campaign', + 'Worldbuilding and Lore', + 'Designing Encounters and Adventures', + 'Managing Players and their Expectations', + 'Factions and Political Intrigue', + 'Adventure Hooks and Plot Ideas', + 'Building a Campaign Setting', + 'Handling Rules Disputes', + 'Running Large-Scale Battles', + 'Designing Unique Magic Systems', + 'Developing and Using NPCs', + 'Crafting Memorable Quests', + 'Improvising When Things Don\'t Go as Planned', + 'Managing Session Flow and Pacing', + 'Building a World That Feels Alive' +]; + +module.exports = ()=>{ + return ` +{{partCover +# PART X +## ${_.sample(titles)} + +![Background](https://i.imgur.com/dpg5qPT.png) +}} + +{{pageNumber,auto}} +{{footnote PART X | SECTION NAME}} + +\\page`; +}; \ No newline at end of file diff --git a/themes/V3/5ePHB/style.less b/themes/V3/5ePHB/style.less index 85dc566f4..16451e32c 100644 --- a/themes/V3/5ePHB/style.less +++ b/themes/V3/5ePHB/style.less @@ -795,4 +795,44 @@ .page h1 + *{ margin-top : 0; } + //***************************** + // * PART COVER + // *****************************/ + .page .partCover { + background-image: @partCoverHeader; + background-repeat: no-repeat; + position: absolute; + background-size: 100%; + inset: 0; + img { + position: absolute; + inset: 0; + height:100%; + mask-image: @partCoverMask; + mask-size: 816px; + -webkit-mask-image: @partCoverMask; + -webkit-mask-size: 816px; + } + h1 { + text-align: center; + text-transform: uppercase; + font-size: 80px; + font-family: NodestoCapsCondensed; + font-variant: small-caps; + max-width: 7ch; + text-overflow: clip; + white-space: nowrap; + overflow: hidden; + margin-inline: auto; + } + h2 { + text-align: center; + font-family: MartelSansBlack; + font-size: 18px; + position: relative; + max-width: 18ch; + margin-inline: auto; + margin-top: -5px; + } + } } diff --git a/themes/assets/assets.less b/themes/assets/assets.less index 7df5db0f6..3442b8c49 100644 --- a/themes/assets/assets.less +++ b/themes/assets/assets.less @@ -10,6 +10,8 @@ @monsterBorderImage : url('/assets/monsterBorderFancy.png'); @codeBorderImage : url('/assets/codeBorder.png'); @classTableDecoration : url('/assets/classTableDecoration.png'); +@partCoverHeader : url('/assets/partCoverHeader.png'); +@partCoverMask : url('/assets/partCoverMask.png'); // Watercolor Images @watercolor1 : url('/assets/watercolor/watercolor1.png'); diff --git a/themes/assets/partCoverHeader.png b/themes/assets/partCoverHeader.png new file mode 100644 index 000000000..f359668ba Binary files /dev/null and b/themes/assets/partCoverHeader.png differ diff --git a/themes/assets/partCoverMask.png b/themes/assets/partCoverMask.png new file mode 100644 index 000000000..c0da1ab3a Binary files /dev/null and b/themes/assets/partCoverMask.png differ diff --git a/themes/fonts/5e/Martel Sans Black.woff2 b/themes/fonts/5e/Martel Sans Black.woff2 new file mode 100644 index 000000000..44580467d Binary files /dev/null and b/themes/fonts/5e/Martel Sans Black.woff2 differ diff --git a/themes/fonts/5e/fonts.less b/themes/fonts/5e/fonts.less index f5118a7cc..e7450a21c 100644 --- a/themes/fonts/5e/fonts.less +++ b/themes/fonts/5e/fonts.less @@ -106,3 +106,10 @@ font-weight: bold; font-style: italic; } + +@font-face { + font-family: MartelSansBlack; + src: url('../../../fonts/5e/Martel Sans Black.woff2'); + font-weight: bold; + font-style: normal; +}