Move pug pattern files to .pp, check tab order
This commit is contained in:
16
src/pg/patterns/core/header/_header.pp
Normal file
16
src/pg/patterns/core/header/_header.pp
Normal file
@@ -0,0 +1,16 @@
|
||||
//- DS2 core (c) 2024 Alexander McIlwraith
|
||||
//- Licensed under CC BY-SA 4.0
|
||||
|
||||
//- required variables
|
||||
//- site - the site name that goes in the site title
|
||||
//- root - the path to the root of the site
|
||||
|
||||
header
|
||||
// The headline banner area
|
||||
svg(height='5.5rem' width='100%' xmlns='http://www.w3.org/2000/svg' aria-hidden='true')
|
||||
text= site
|
||||
div
|
||||
div.header-title
|
||||
h1
|
||||
a(href="./")= site
|
||||
// Other sections can go here, such as search and directory
|
@@ -22,7 +22,11 @@ block content
|
||||
- site= tmpsite
|
||||
- root= tmproot
|
||||
|
||||
pre.language-sass(data-tab="scss")
|
||||
include _header.scss
|
||||
pre.language-html(data-tab="html")
|
||||
include _header.pug
|
||||
pre.language-pug(data-tab="pug")
|
||||
include _header.pp
|
||||
pre.language-css(data-tab="css")
|
||||
include header.css
|
||||
include header.css
|
||||
pre.language-sass(data-tab="scss")
|
||||
include _header.scss
|
2
src/pg/patterns/core/sticky-note/_sticky-note.pp
Normal file
2
src/pg/patterns/core/sticky-note/_sticky-note.pp
Normal file
@@ -0,0 +1,2 @@
|
||||
sticky-note(float="right").blue This #[strong is] a sample sticky.
|
||||
| You can drag it out of the way if you need to see the content under it.
|
2
src/pg/patterns/core/sticky-note/_sticky-note.pug
Normal file
2
src/pg/patterns/core/sticky-note/_sticky-note.pug
Normal file
@@ -0,0 +1,2 @@
|
||||
sticky-note(float="right").blue This #[strong is] a sample sticky.
|
||||
| You can drag it out of the way if you need to see the content under it.
|
@@ -18,11 +18,9 @@ block content
|
||||
|
||||
tabset#sticky-note
|
||||
pre.language-html(tab="html")
|
||||
sticky-note(float="right").blue This #[strong is] a sample sticky.
|
||||
| You can drag it out of the way if you need to see the content under it.
|
||||
pre.language-pug(tab="pug").
|
||||
sticky-note(float="right").blue This #[strong is] a sample sticky.
|
||||
| You can drag it out of the way if you need to see the content under it.
|
||||
include _sticky-note.pug
|
||||
pre.language-pug(tab="pug")
|
||||
include _sticky-note.pp
|
||||
pre.language-css(data-tab="css")
|
||||
include sticky-note.css
|
||||
pre.language-css(data-tab="scss")
|
||||
|
1
src/pg/patterns/core/switch/_switch.pp
Normal file
1
src/pg/patterns/core/switch/_switch.pp
Normal file
@@ -0,0 +1 @@
|
||||
span#example-id(role="switch")
|
@@ -1,2 +0,0 @@
|
||||
.
|
||||
span#example-id(role="switch")
|
4
src/pg/patterns/core/tabs/_tabs.pp
Normal file
4
src/pg/patterns/core/tabs/_tabs.pp
Normal file
@@ -0,0 +1,4 @@
|
||||
div#uniqueID.tab-group
|
||||
div(data-tab="[tab title]")
|
||||
div(data-tab="[tab title]")
|
||||
|
@@ -27,16 +27,12 @@ block content
|
||||
tabset#tabs
|
||||
pre.language-html(tab="html")
|
||||
include _tabs.pug
|
||||
|
||||
//- pre.language-pug(tab="pug").
|
||||
include _tabs.pug
|
||||
|
||||
pre.language-pug(tab="pug")
|
||||
include _tabs.pp
|
||||
pre.language-css(tab="css")
|
||||
include tabs.css
|
||||
|
||||
pre.language-css(tab="scss")
|
||||
include _tabs.scss
|
||||
|
||||
pre.language-css(tab="js")
|
||||
include _tabs.js
|
||||
|
||||
|
5
src/pg/patterns/core/tooltip/_tooltip.pp
Normal file
5
src/pg/patterns/core/tooltip/_tooltip.pp
Normal file
@@ -0,0 +1,5 @@
|
||||
a(href="#") Link with a tool tip
|
||||
div(role="tooltip" inert tip-position="bottom") Tool tip content
|
||||
|
||||
a(href="#") Link with a tool tip
|
||||
tool-tip(role="tooltip" inert tip-position="bottom") Tool tip content
|
@@ -5,14 +5,13 @@ extends ../../../core/_master-pattern
|
||||
block content
|
||||
|
||||
+h(0)
|
||||
|
||||
+h(1)
|
||||
|
||||
+h(2)
|
||||
|
||||
p Either form works. Place this inside another element for the tooltip to be "linked to that element."
|
||||
|
||||
|
||||
|
||||
|
||||
p Tool tip positions are:
|
||||
ul
|
||||
li top / block-start
|
||||
@@ -25,7 +24,7 @@ block content
|
||||
pre.language-html(data-tab="html")
|
||||
include _tooltip.pug
|
||||
pre.language-pug(data-tab="pug")
|
||||
include tooltip.pug
|
||||
include _tooltip.pp
|
||||
pre.language-css(data-tab="css")
|
||||
include tooltip.css
|
||||
pre.language-css(data-tab="scss")
|
||||
|
@@ -1,6 +0,0 @@
|
||||
.
|
||||
a(href="#") Link with a tool tip
|
||||
div(role="tooltip" inert tip-position="bottom") Tool tip content
|
||||
|
||||
a(href="#") Link with a tool tip
|
||||
tool-tip(role="tooltip" inert tip-position="bottom") Tool tip content
|
Reference in New Issue
Block a user