@axiapps/axi-design 1.8.0 → 1.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md
CHANGED
|
@@ -83,6 +83,8 @@ not "what does the system look like". Everything else is
|
|
|
83
83
|
| `--axi-bars-gap` | gap between columns in `.axi-bars` | `6px` | `<div class="axi-bars" style="--axi-bars-gap: 2px">` |
|
|
84
84
|
| `--axi-plot-h` | height of a `.axi-plot` or `.axi-bars` | `180px` | `<div class="axi-plot" style="--axi-plot-h: 240px">` |
|
|
85
85
|
| `--axi-plot-rows` | how many horizontal rules a `.axi-plot` draws | `4` | `<div class="axi-plot" style="--axi-plot-rows: 6">` |
|
|
86
|
+
| `--axi-tick-w` / `--axi-tick-h` | size of one `.axi-ticks__tick` | `5px` / `15px` | `<div class="axi-ticks" style="--axi-tick-w: 7px">` |
|
|
87
|
+
| `--axi-ticks-gap` | gap between marks in `.axi-ticks` | `3px` | `<div class="axi-ticks" style="--axi-ticks-gap: 2px">` |
|
|
86
88
|
|
|
87
89
|
`--axi-page-pad: 0` is the one to know about: it is how a measure nested
|
|
88
90
|
inside another measure avoids paying the gutter twice.
|
package/dist/axi.css
CHANGED
|
@@ -1028,6 +1028,42 @@ a { color: inherit; }
|
|
|
1028
1028
|
background: var(--axi-series, var(--axi-accent));
|
|
1029
1029
|
}
|
|
1030
1030
|
|
|
1031
|
+
/* ---------- ticks ---------- */
|
|
1032
|
+
/* A run of yes/no along a timeline: attended or missed, passed or failed,
|
|
1033
|
+
shipped or skipped. This is rule 9 read the other way round - a bar has a
|
|
1034
|
+
length because a quantity has one, and "no" has no length at all. Drawn as
|
|
1035
|
+
a bar it has to be faked with a stub, and a stub reads as "a little bit",
|
|
1036
|
+
which is the same lie as a faded fill. So every event here is one mark of
|
|
1037
|
+
the same size, and what changes between them is only which ink it is drawn
|
|
1038
|
+
in: rule 10's two series, the accent for the fact and the neutral ramp for
|
|
1039
|
+
its absence.
|
|
1040
|
+
|
|
1041
|
+
Neither mark is outlined, which is the one place this departs from the
|
|
1042
|
+
filled/empty pair the language reaches for first. At the size a run of
|
|
1043
|
+
twenty sits in a table row the outline IS the mark - three pixels of edge
|
|
1044
|
+
around one pixel of middle - so the pair would differ in nothing the eye
|
|
1045
|
+
can resolve. A strip drawn large enough to outline is a bar chart, and
|
|
1046
|
+
.axi-bars already is one.
|
|
1047
|
+
|
|
1048
|
+
Marks are a fixed width and never flex: a run of fourteen and a run of
|
|
1049
|
+
three share a column in a table, and the short one has to read as a short
|
|
1050
|
+
run rather than as fourteen fatter events. */
|
|
1051
|
+
.axi-ticks {
|
|
1052
|
+
display: inline-flex;
|
|
1053
|
+
align-items: stretch;
|
|
1054
|
+
gap: var(--axi-ticks-gap, 3px);
|
|
1055
|
+
height: var(--axi-tick-h, 15px);
|
|
1056
|
+
}
|
|
1057
|
+
.axi-ticks__tick {
|
|
1058
|
+
flex: none;
|
|
1059
|
+
width: var(--axi-tick-w, 5px);
|
|
1060
|
+
background: var(--axi-rule);
|
|
1061
|
+
border-radius: var(--axi-radius-sm);
|
|
1062
|
+
}
|
|
1063
|
+
.axi-ticks__tick--on {
|
|
1064
|
+
background: var(--axi-series, var(--axi-accent));
|
|
1065
|
+
}
|
|
1066
|
+
|
|
1031
1067
|
/* ---------- plot ---------- */
|
|
1032
1068
|
/* A frame for a line or an area, with its horizontal rules drawn in. The
|
|
1033
1069
|
rules are hard stops in a repeating gradient, which is the select caret's
|
package/docs/RULES.md
CHANGED
|
@@ -247,6 +247,12 @@ is the one chart type that cannot be built without the thing rule 2 forbids, so
|
|
|
247
247
|
a distribution is drawn as bars, or as a table sorted by the value, or not at
|
|
248
248
|
all.
|
|
249
249
|
|
|
250
|
+
The other corollary is that a thing with no quantity gets no length. A run of
|
|
251
|
+
yes/no — attended or missed, passed or failed — is a sequence of facts, and a
|
|
252
|
+
fact has no magnitude to draw: rendering "no" as a short bar says "a little
|
|
253
|
+
bit" as loudly as a faded fill says "30%". That series is a row of marks of
|
|
254
|
+
one size, differing only in ink, which is `.axi-ticks`.
|
|
255
|
+
|
|
250
256
|
## 10. A chart's ink is the accent
|
|
251
257
|
|
|
252
258
|
One series is the accent. A second, for comparison, is the neutral ramp —
|