From 5bd22798b1a85fd3f1402f5fff7faac50f8935b3 Mon Sep 17 00:00:00 2001
From: Stefano Pigozzi
Date: Sat, 15 Oct 2022 00:51:30 +0200
Subject: [PATCH] Unify docs terminology (fixes #50)
---
LICENSE.txt | 2 +-
dist/_build.sh | 6 +-
dist/base.module.css | 25 +-
dist/base.module.less | 4 +-
dist/base.root.css | 64 ++--
dist/base.root.less | 4 +-
dist/classic.module.less | 4 +-
dist/classic.root.css | 2 +-
dist/classic.root.less | 4 +-
dist/colors-amber.module.less | 4 +-
dist/colors-amber.root.less | 4 +-
dist/colors-royalblue.module.less | 4 +-
dist/colors-royalblue.root.less | 4 +-
dist/fonts-fira-ghpages.module.less | 4 +-
dist/fonts-fira-ghpages.root.less | 4 +-
dist/fun.module.less | 4 +-
dist/fun.root.less | 4 +-
dist/glass.module.less | 4 +-
dist/glass.root.less | 4 +-
examples/index.html | 345 +++++++++++++-----
examples/index.js | 69 ----
src/{rules => rulesets}/base.less | 6 +-
src/{rules => rulesets}/classic.less | 0
.../colors/colors-amber.less | 0
.../colors/colors-royalblue.less | 0
.../fonts/fonts-fira-ghpages.less | 0
src/{rules => rulesets}/fun.less | 0
src/{rules => rulesets}/glass.less | 0
src/{selectors => selectorsets}/module.less | 0
src/{selectors => selectorsets}/root.less | 0
30 files changed, 337 insertions(+), 238 deletions(-)
delete mode 100644 examples/index.js
rename src/{rules => rulesets}/base.less (99%)
rename src/{rules => rulesets}/classic.less (100%)
rename src/{rules => rulesets}/colors/colors-amber.less (100%)
rename src/{rules => rulesets}/colors/colors-royalblue.less (100%)
rename src/{rules => rulesets}/fonts/fonts-fira-ghpages.less (100%)
rename src/{rules => rulesets}/fun.less (100%)
rename src/{rules => rulesets}/glass.less (100%)
rename src/{selectors => selectorsets}/module.less (100%)
rename src/{selectors => selectorsets}/root.less (100%)
diff --git a/LICENSE.txt b/LICENSE.txt
index 0ad25db..40a3d6a 100644
--- a/LICENSE.txt
+++ b/LICENSE.txt
@@ -319,7 +319,7 @@ requirement to continue to provide support service, warranty, or updates
for a work that has been modified or installed by the recipient, or for
the User Product in which it has been modified or installed. Access to a
network may be denied when the modification itself materially and
-adversely affects the operation of the network or violates the rules and
+adversely affects the operation of the network or violates the rulesets and
protocols for communication across the network.
Corresponding Source conveyed, and Installation Information provided,
diff --git a/dist/_build.sh b/dist/_build.sh
index 9de5459..b69aa29 100755
--- a/dist/_build.sh
+++ b/dist/_build.sh
@@ -7,14 +7,14 @@ echo "Mixins:"
echo "$mixins"
echo
-echo "Finding rules..."
-rules=$(ls ../src/rules/*.less ../src/rules/**/*.less)
+echo "Finding rulesets..."
+rules=$(ls ../src/rulesets/*.less ../src/rulesets/**/*.less)
echo "Rules:"
echo "$rules"
echo
echo "Finding selectors..."
-selectors=$(ls ../src/selectors/*.less ../src/selectors/**/*.less)
+selectors=$(ls ../src/selectorsets/*.less ../src/selectorsets/**/*.less)
echo "Selectors:"
echo "$selectors"
echo
diff --git a/dist/base.module.css b/dist/base.module.css
index 666b1d3..78f46f1 100644
--- a/dist/base.module.css
+++ b/dist/base.module.css
@@ -631,10 +631,11 @@
display: flex;
gap: 1ex;
}
-.bluelib .form-flex > .element-label > .element-span:first-child,
-.bluelib .form-flex > .element-label > .element-span:last-child {
+.bluelib .form-flex > .element-label > *:first-child,
+.bluelib .form-flex > .element-label > *:last-child {
margin: auto 0;
flex-basis: 15%;
+ flex-grow: 0;
font-style: var(--bfont-label-style);
font-variant: var(--bfont-label-variant);
font-weight: var(--bfont-label-weight);
@@ -645,14 +646,20 @@
--bhsl-current-saturation: var(--bhsl-primary-saturation);
--bhsl-current-lightness: var(--bhsl-primary-lightness);
}
-.bluelib .form-flex > .element-label > .element-span:first-child {
- text-align: right;
-}
-.bluelib .form-flex > .element-label > .element-span:last-child {
- text-align: left;
-}
-.bluelib .form-flex > .element-label > .input {
+.bluelib .form-flex > .element-label > * {
flex-grow: 1;
+ display: flex;
+ justify-content: start;
+ align-items: center;
+ gap: 4px;
+}
+.bluelib .form-flex > .element-label > *:first-child {
+ text-align: right;
+ display: block;
+}
+.bluelib .form-flex > .element-label > *:last-child {
+ text-align: left;
+ display: block;
}
.bluelib .text-anchor {
--bhsl-current-hue: var(--bhsl-link-hue);
diff --git a/dist/base.module.less b/dist/base.module.less
index 64850ba..43dede2 100644
--- a/dist/base.module.less
+++ b/dist/base.module.less
@@ -3,8 +3,8 @@
@import (less) "../src/mixins/hsl.less";
// Selector
-@import (less) "../src/selectors/module.less";
+@import (less) "../src/selectorsets/module.less";
// Rule
-@import (less) "../src/rules/base.less";
+@import (less) "../src/rulesets/base.less";
diff --git a/dist/base.root.css b/dist/base.root.css
index 6213b12..c9c98ce 100644
--- a/dist/base.root.css
+++ b/dist/base.root.css
@@ -103,27 +103,27 @@ body .panel {
background-color: hsl(var(--bhsl-background-hue) var(--bhsl-background-saturation) var(--bhsl-background-lightness));
}
body .panel.border-top,
-body .panel.panel-box {
+body .panel.box {
border-top-width: 2px;
padding-top: calc(0.5em - 2px);
}
body .panel.border-right,
-body .panel.panel-box {
+body .panel.box {
border-right-width: 2px;
padding-right: calc(0.5em - 2px);
}
body .panel.border-left,
-body .panel.panel-box,
-body .panel.panel-dialog {
+body .panel.box,
+body .panel.dialog {
border-left-width: 2px;
padding-left: calc(0.5em - 2px);
}
body .panel.border-bottom,
-body .panel.panel-box {
+body .panel.box {
border-bottom-width: 2px;
padding-bottom: calc(0.5em - 2px);
}
-body .panel.panel-parenthesis {
+body .panel.parenthesis {
font-size: smaller;
}
body .chapter-0,
@@ -321,39 +321,39 @@ body table.panel caption *:first-child {
body table.panel caption *:last-child {
margin-bottom: 0;
}
-body table.panel-box tr {
+body table.box tr {
border-width: 1px;
}
-body table.panel-box th,
-body table.panel-box td {
+body table.box th,
+body table.box td {
border-width: 1px;
padding: 7px;
}
-body table.panel-box caption {
+body table.box caption {
border-width: 2px;
padding: 6px;
}
-body table.panel-box caption.table-caption-top {
+body table.box caption.table-caption-top {
border-bottom-width: 0;
}
-body table.panel-box caption.table-caption-bottom {
+body table.box caption.table-caption-bottom {
border-top-width: 0;
}
-body table.panel-dialog thead > tr {
+body table.dialog thead > tr {
border-bottom-width: 1px;
}
-body table.panel-dialog tbody > tr {
+body table.dialog tbody > tr {
border-width: 0;
}
-body table.panel-dialog tfoot > tr {
+body table.dialog tfoot > tr {
border-top-width: 1px;
}
-body table.panel-dialog th,
-body table.panel-dialog td {
+body table.dialog th,
+body table.dialog td {
border-width: 0 0 0 1px;
padding: 8px 8px 8px 7px;
}
-body table.panel-dialog caption {
+body table.dialog caption {
border-width: 0 0 0 2px;
padding: 8px 8px 8px 6px;
}
@@ -675,10 +675,11 @@ body .form-flex > label {
display: flex;
gap: 1ex;
}
-body .form-flex > label > span:first-child,
-body .form-flex > label > span:last-child {
+body .form-flex > label > *:first-child,
+body .form-flex > label > *:last-child {
margin: auto 0;
flex-basis: 15%;
+ flex-grow: 0;
font-style: var(--bfont-label-style);
font-variant: var(--bfont-label-variant);
font-weight: var(--bfont-label-weight);
@@ -689,17 +690,20 @@ body .form-flex > label > span:last-child {
--bhsl-current-saturation: var(--bhsl-primary-saturation);
--bhsl-current-lightness: var(--bhsl-primary-lightness);
}
-body .form-flex > label > span:first-child {
- text-align: right;
-}
-body .form-flex > label > span:last-child {
- text-align: left;
-}
-body .form-flex > label > input,
-body .form-flex > label textarea,
-body .form-flex > label select,
-body .form-flex > label button {
+body .form-flex > label > * {
flex-grow: 1;
+ display: flex;
+ justify-content: start;
+ align-items: center;
+ gap: 4px;
+}
+body .form-flex > label > *:first-child {
+ text-align: right;
+ display: block;
+}
+body .form-flex > label > *:last-child {
+ text-align: left;
+ display: block;
}
body a {
--bhsl-current-hue: var(--bhsl-link-hue);
diff --git a/dist/base.root.less b/dist/base.root.less
index f76abbf..520aa51 100644
--- a/dist/base.root.less
+++ b/dist/base.root.less
@@ -3,8 +3,8 @@
@import (less) "../src/mixins/hsl.less";
// Selector
-@import (less) "../src/selectors/root.less";
+@import (less) "../src/selectorsets/root.less";
// Rule
-@import (less) "../src/rules/base.less";
+@import (less) "../src/rulesets/base.less";
diff --git a/dist/classic.module.less b/dist/classic.module.less
index f5cb986..d9958ea 100644
--- a/dist/classic.module.less
+++ b/dist/classic.module.less
@@ -3,8 +3,8 @@
@import (less) "../src/mixins/hsl.less";
// Selector
-@import (less) "../src/selectors/module.less";
+@import (less) "../src/selectorsets/module.less";
// Rule
-@import (less) "../src/rules/classic.less";
+@import (less) "../src/rulesets/classic.less";
diff --git a/dist/classic.root.css b/dist/classic.root.css
index db19528..47c80fc 100644
--- a/dist/classic.root.css
+++ b/dist/classic.root.css
@@ -98,7 +98,7 @@ body table.panel > caption {
border-radius: 0;
box-shadow: 0.0625em 0 0.25em hsl(var(--bhsl-background-hue) var(--bhsl-background-saturation) var(--bhsl-background-lightness));
}
-body table.panel-dialog > caption {
+body table.dialog > caption {
border-bottom-width: 2px;
}
body input,
diff --git a/dist/classic.root.less b/dist/classic.root.less
index cca53a0..4fc0cb2 100644
--- a/dist/classic.root.less
+++ b/dist/classic.root.less
@@ -3,8 +3,8 @@
@import (less) "../src/mixins/hsl.less";
// Selector
-@import (less) "../src/selectors/root.less";
+@import (less) "../src/selectorsets/root.less";
// Rule
-@import (less) "../src/rules/classic.less";
+@import (less) "../src/rulesets/classic.less";
diff --git a/dist/colors-amber.module.less b/dist/colors-amber.module.less
index 2cce788..e5ae6e7 100644
--- a/dist/colors-amber.module.less
+++ b/dist/colors-amber.module.less
@@ -3,8 +3,8 @@
@import (less) "../src/mixins/hsl.less";
// Selector
-@import (less) "../src/selectors/module.less";
+@import (less) "../src/selectorsets/module.less";
// Rule
-@import (less) "../src/rules/colors/colors-amber.less";
+@import (less) "../src/rulesets/colors/colors-amber.less";
diff --git a/dist/colors-amber.root.less b/dist/colors-amber.root.less
index eec105e..4efeba4 100644
--- a/dist/colors-amber.root.less
+++ b/dist/colors-amber.root.less
@@ -3,8 +3,8 @@
@import (less) "../src/mixins/hsl.less";
// Selector
-@import (less) "../src/selectors/root.less";
+@import (less) "../src/selectorsets/root.less";
// Rule
-@import (less) "../src/rules/colors/colors-amber.less";
+@import (less) "../src/rulesets/colors/colors-amber.less";
diff --git a/dist/colors-royalblue.module.less b/dist/colors-royalblue.module.less
index 7279a9b..2ffd485 100644
--- a/dist/colors-royalblue.module.less
+++ b/dist/colors-royalblue.module.less
@@ -3,8 +3,8 @@
@import (less) "../src/mixins/hsl.less";
// Selector
-@import (less) "../src/selectors/module.less";
+@import (less) "../src/selectorsets/module.less";
// Rule
-@import (less) "../src/rules/colors/colors-royalblue.less";
+@import (less) "../src/rulesets/colors/colors-royalblue.less";
diff --git a/dist/colors-royalblue.root.less b/dist/colors-royalblue.root.less
index 525a01c..f0cba50 100644
--- a/dist/colors-royalblue.root.less
+++ b/dist/colors-royalblue.root.less
@@ -3,8 +3,8 @@
@import (less) "../src/mixins/hsl.less";
// Selector
-@import (less) "../src/selectors/root.less";
+@import (less) "../src/selectorsets/root.less";
// Rule
-@import (less) "../src/rules/colors/colors-royalblue.less";
+@import (less) "../src/rulesets/colors/colors-royalblue.less";
diff --git a/dist/fonts-fira-ghpages.module.less b/dist/fonts-fira-ghpages.module.less
index 9982f86..441c689 100644
--- a/dist/fonts-fira-ghpages.module.less
+++ b/dist/fonts-fira-ghpages.module.less
@@ -3,8 +3,8 @@
@import (less) "../src/mixins/hsl.less";
// Selector
-@import (less) "../src/selectors/module.less";
+@import (less) "../src/selectorsets/module.less";
// Rule
-@import (less) "../src/rules/fonts/fonts-fira-ghpages.less";
+@import (less) "../src/rulesets/fonts/fonts-fira-ghpages.less";
diff --git a/dist/fonts-fira-ghpages.root.less b/dist/fonts-fira-ghpages.root.less
index 3fd7243..ec6b679 100644
--- a/dist/fonts-fira-ghpages.root.less
+++ b/dist/fonts-fira-ghpages.root.less
@@ -3,8 +3,8 @@
@import (less) "../src/mixins/hsl.less";
// Selector
-@import (less) "../src/selectors/root.less";
+@import (less) "../src/selectorsets/root.less";
// Rule
-@import (less) "../src/rules/fonts/fonts-fira-ghpages.less";
+@import (less) "../src/rulesets/fonts/fonts-fira-ghpages.less";
diff --git a/dist/fun.module.less b/dist/fun.module.less
index 7a661c7..07579a7 100644
--- a/dist/fun.module.less
+++ b/dist/fun.module.less
@@ -3,8 +3,8 @@
@import (less) "../src/mixins/hsl.less";
// Selector
-@import (less) "../src/selectors/module.less";
+@import (less) "../src/selectorsets/module.less";
// Rule
-@import (less) "../src/rules/fun.less";
+@import (less) "../src/rulesets/fun.less";
diff --git a/dist/fun.root.less b/dist/fun.root.less
index 428d98b..01bb3d6 100644
--- a/dist/fun.root.less
+++ b/dist/fun.root.less
@@ -3,8 +3,8 @@
@import (less) "../src/mixins/hsl.less";
// Selector
-@import (less) "../src/selectors/root.less";
+@import (less) "../src/selectorsets/root.less";
// Rule
-@import (less) "../src/rules/fun.less";
+@import (less) "../src/rulesets/fun.less";
diff --git a/dist/glass.module.less b/dist/glass.module.less
index fd7d168..48d01b7 100644
--- a/dist/glass.module.less
+++ b/dist/glass.module.less
@@ -3,8 +3,8 @@
@import (less) "../src/mixins/hsl.less";
// Selector
-@import (less) "../src/selectors/module.less";
+@import (less) "../src/selectorsets/module.less";
// Rule
-@import (less) "../src/rules/glass.less";
+@import (less) "../src/rulesets/glass.less";
diff --git a/dist/glass.root.less b/dist/glass.root.less
index 197f565..984fdd2 100644
--- a/dist/glass.root.less
+++ b/dist/glass.root.less
@@ -3,8 +3,8 @@
@import (less) "../src/mixins/hsl.less";
// Selector
-@import (less) "../src/selectors/root.less";
+@import (less) "../src/selectorsets/root.less";
// Rule
-@import (less) "../src/rules/glass.less";
+@import (less) "../src/rulesets/glass.less";
diff --git a/examples/index.html b/examples/index.html
index 0638c9d..a06f5f9 100644
--- a/examples/index.html
+++ b/examples/index.html
@@ -29,11 +29,11 @@
Bluelib
-
+
Welcome to Bluelib!
-
+
What is Bluelib?
@@ -48,66 +48,223 @@
- This page is also used for development, therefore it uses un-minified sources and imports many development scripts.
+ This page is also used for development, therefore it uses un-minified sources and imports some development scripts.
- Do not judge the library efficiency from this page, or perform any benchmarks on it, as they will probably be wrong!
+ Do not try to determine the performance of Bluelib from this page, as the development features are somewhat heavy on the browser!
-
+
-
+
+
+ Rulesets, selectorsets, targets
+
+
+
+ Targets
+
+
+ A Bluelib target is a CSS document where CSS rulesets of a certain type are grouped together.
+
+
+ It is composed by two parts: the ruleset, determining the CSS rules to use, and the selectorset, determining the elements to apply the CSS rules on.
+
+
+
+ Targets always have a predictable name, which is:
+
+
+
+ dist/RULESET.SELECTORSET.css
+
+
+
+ Be sure to choose the ones matching your needs!
+
+
+
+ By running dist/_build.sh
, new targets are generated and compiled from Less to CSS.
+
+
+ The cartesian product is applied between all rulesets in src/rulesets
and all selectorsets in src/selectorsets
, compiling a new target for each pair.
+
+
+
+
+
+
+
+ Installation and usage
+
+
+
+ Via UNPKG
+
+
+ The easiest way to use Bluelib on your website is by using UNPKG.
+
+
+ Simply link the stylesheets in the header of your project like this:
+
+
+ <link rel="stylesheet" href="https://unpkg.com/@steffo/bluelib@VERSION/dist/RULESET.SELECTORSET.css" type="text/css"/>
+
+
+
+
+ Coming soon
+
+
+ More installation methods coming soon!
+
+
+
+
Panels
@@ -302,7 +459,7 @@
To have a constant height, one has to be set manually.
-
+
Auto-sizing
@@ -346,7 +503,7 @@
-
+
Modifiers
@@ -373,7 +530,7 @@
-
- Text
+ Text elements
-
+
Anchors
@@ -640,7 +797,7 @@
-
+
Idiomatic expressions
@@ -653,7 +810,7 @@
-
+
Emphasis
@@ -666,7 +823,7 @@
-
+
Bring attention
@@ -679,7 +836,7 @@
-
+
Strong importance
@@ -692,7 +849,7 @@
-
+
Unarticulated annotations
@@ -705,7 +862,7 @@
-
+
Strike
@@ -718,12 +875,12 @@
-
+
Inserted and deleted text
- When comparing changes to a text, parts of it can be marked as inserted or removed.
+ When comparing changes to a text, parts of it can be marked as inserted or deleted.
@@ -735,7 +892,7 @@
-
+
Small comment
@@ -751,9 +908,9 @@
-
+
-
+
- Code snippets
+ Code
A code element denotes that its contents are some kind of code (probably belonging to a programming language).
@@ -790,7 +947,7 @@
</div>
-
+
Sample input and output
@@ -809,7 +966,7 @@
-
+
Variables
@@ -822,7 +979,7 @@
-
+
Quotes and citations
@@ -836,7 +993,7 @@
-
+
Definitions
@@ -849,7 +1006,7 @@
-
+
Abbreviations
@@ -865,12 +1022,12 @@
-
+
Ruby
- A ruby text element is text with small annotations above, commonly used in East Asian texts.
+ A ruby text element is text with small annotations above, commonly used in East Asian texts.
@@ -1133,7 +1290,7 @@
-