Skip to content

Commit 3a6d283

Browse files
committed
Read roles from json, align wrapped labels
1 parent 537f3db commit 3a6d283

File tree

8 files changed

+510
-169
lines changed

8 files changed

+510
-169
lines changed

gulp.d/tasks/rollup.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ const rollupPluginNodeResolve = require('@rollup/plugin-node-resolve').nodeResol
55
const rollupPluginCommonJS = require('@rollup/plugin-commonjs')
66
const rollupPluginBabel = require('@rollup/plugin-babel').babel
77
const rollupPluginTerser = require('rollup-plugin-terser').terser
8+
const rollupPluginJSON = require('@rollup/plugin-json')
89

910
const toCamel = (s) => {
1011
return s.replace(/([-_][a-z])/ig, ($1) => {
@@ -35,6 +36,7 @@ async function bundle (vinylFile) {
3536
babelHelpers: 'bundled',
3637
}),
3738
rollupPluginTerser(),
39+
rollupPluginJSON(),
3840
],
3941
onwarn: (warning) => {
4042
if (warning.code === 'CIRCULAR_DEPENDENCY' && ignoredCircular.some((d) => warning.importer.includes(d))) {

package-lock.json

Lines changed: 121 additions & 14 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
"@gram-data/gram-d3": "^0.1.2",
1919
"@rollup/plugin-babel": "^5.2.3",
2020
"@rollup/plugin-commonjs": "^17.1.0",
21+
"@rollup/plugin-json": "^6.1.0",
2122
"@rollup/plugin-node-resolve": "^11.1.1",
2223
"asciidoctor.js": "1.5.9",
2324
"auth0-js": "^9.14.0",

preview-src/docs-roles.adoc

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
= Docs `code test` flags
1+
= Docs roles with a long title
22
:page-role: not-on-aura new-5.17
33
:page-theme: docs
44
// :page-labels: fabric enterprise-edition alpha test
@@ -8,19 +8,34 @@
88
Flags sections as Not Available on Aura, Aura DB Enterprise, Enterprise Edition, Fabric, and Deprecated
99
--
1010

11+
1112
[role="label--new-5.17 label--enterprise-edition"]
1213
== Relationship property type constraints
1314

1415
Blocks with the appropriate roles have labels added.
1516

17+
18+
[role=label--aura-db-enterprise label--not-on-aura]
19+
=== H3 AuraDB Enterprise AND Not on Aura
20+
21+
Lorem ipsum dolor sit
22+
23+
Open blocks can be used to mark multiple paragraphs within a section.
24+
1625
[role=label--new-5.17]
26+
--
1727
Lorem ipsum dolor sit amet, consectetur adipiscing elit.
1828
Mauris eget leo nunc, nec tempus mi? Curabitur id nisl mi, ut vulputate urna.
29+
1930
Quisque porta facilisis tortor, vitae bibendum velit fringilla vitae! Lorem ipsum dolor sit amet, consectetur adipiscing elit.
31+
--
32+
2033

2134
This is a normal paragraph.
2235

23-
[role=label--deprecated-5.17]
36+
The next paragraph has a label, but it's not one we support.
37+
38+
[role=label--invented-label]
2439
Lorem ipsum dolor sit amet, consectetur adipiscing elit.
2540

2641
[role=label--enterprise-edition]

src/css/doc.css

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ body {
6868
.doc h4 code,
6969
.doc h5 code,
7070
.doc h6 code {
71-
padding: 0.125em 0.25em;
71+
padding: 0 0.25em;
7272
background: var(--code-background);
7373
}
7474

@@ -664,6 +664,10 @@ body {
664664
text-align: left;
665665
}
666666

667+
.doc .tableblock caption {
668+
display: table-caption;
669+
}
670+
667671
.hide-table-captions .doc .tableblock caption {
668672
position: absolute;
669673
left: -10000px;

0 commit comments

Comments
 (0)