@diagrammo/dgmo 0.50.1 → 0.50.2
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/dist/advanced.d.ts +6578 -0
- package/dist/advanced.js +6 -6
- package/dist/auto.d.ts +54 -0
- package/dist/auto.js +103 -103
- package/dist/auto.mjs +99 -8
- package/dist/block.d.ts +130 -0
- package/dist/block.js +13 -7
- package/dist/{charts-d3-LR6D3D7A.js → charts-d3-MUW3LTML.js} +3 -3
- package/dist/{chunk-7PQYTZMA.js → chunk-5WFIYXQ6.js} +5 -5
- package/dist/{chunk-YIA4LEX4.js → chunk-DN66GPY5.js} +74 -3
- package/dist/{chunk-VVZRV54S.js → chunk-KQ57MHRO.js} +2 -2
- package/dist/{chunk-4S52SK6G.js → chunk-QJJZSROI.js} +10 -3
- package/dist/{chunk-ZAD4HV2G.js → chunk-SVTI362O.js} +9 -9
- package/dist/{chunk-Y4RNXEAO.js → chunk-T5SHNNGP.js} +81 -1
- package/dist/{chunk-XDXNDSKO.js → chunk-XEGTMVYY.js} +4 -1
- package/dist/cli.cjs +124 -124
- package/dist/{dgmo-router-YTU3ENAX.js → dgmo-router-CE2G67FV.js} +3 -3
- package/dist/element.d.ts +62 -0
- package/dist/element.js +100 -100
- package/dist/element.mjs +99 -8
- package/dist/index.d.ts +185 -0
- package/dist/index.js +7 -5
- package/dist/{renderer-72LGR2YF.js → renderer-5KVCNMOJ.js} +2 -2
- package/dist/{renderer-PJM35LJN.js → renderer-P5ROYQGU.js} +2 -2
- package/dist/themes-PdPR1-hC.d.ts +916 -0
- package/docs/language-reference.md +5 -0
- package/gallery/fixtures/countdown-far.dgmo +2 -0
- package/package.json +1 -1
package/dist/advanced.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
renderCountdown,
|
|
3
3
|
renderCountdownForExport
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-T5SHNNGP.js";
|
|
5
5
|
import {
|
|
6
6
|
formatTime,
|
|
7
7
|
handAngles,
|
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
sunLine,
|
|
11
11
|
workStatus,
|
|
12
12
|
zoneParts
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-5WFIYXQ6.js";
|
|
14
14
|
import {
|
|
15
15
|
layoutBracket,
|
|
16
16
|
renderBracket,
|
|
@@ -321,7 +321,7 @@ import {
|
|
|
321
321
|
renderSlopeChart,
|
|
322
322
|
renderVenn,
|
|
323
323
|
renderWordCloud
|
|
324
|
-
} from "./chunk-
|
|
324
|
+
} from "./chunk-SVTI362O.js";
|
|
325
325
|
import {
|
|
326
326
|
formatDateLabel,
|
|
327
327
|
renderTimeline
|
|
@@ -346,7 +346,7 @@ import {
|
|
|
346
346
|
parseDgmo,
|
|
347
347
|
parseDgmoChartType,
|
|
348
348
|
parseVisualization
|
|
349
|
-
} from "./chunk-
|
|
349
|
+
} from "./chunk-KQ57MHRO.js";
|
|
350
350
|
import {
|
|
351
351
|
parseGoal
|
|
352
352
|
} from "./chunk-Q4V4XQWV.js";
|
|
@@ -385,7 +385,7 @@ import "./chunk-BDXC7MDK.js";
|
|
|
385
385
|
import {
|
|
386
386
|
renderLegendSvg,
|
|
387
387
|
renderLegendSvgFromConfig
|
|
388
|
-
} from "./chunk-
|
|
388
|
+
} from "./chunk-QJJZSROI.js";
|
|
389
389
|
import "./chunk-HGN652MU.js";
|
|
390
390
|
import "./chunk-U6EQI3U6.js";
|
|
391
391
|
import {
|
|
@@ -406,7 +406,7 @@ import {
|
|
|
406
406
|
parseChart,
|
|
407
407
|
parseDataRowValues,
|
|
408
408
|
parseExtendedChart
|
|
409
|
-
} from "./chunk-
|
|
409
|
+
} from "./chunk-XEGTMVYY.js";
|
|
410
410
|
import {
|
|
411
411
|
parseWireframe
|
|
412
412
|
} from "./chunk-I2WKW7C7.js";
|
package/dist/auto.d.ts
ADDED
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Shared browser-embed helpers for the `@diagrammo/dgmo` client-side
|
|
3
|
+
* drop-ins (`./auto` script-tag renderer and `./element` custom element).
|
|
4
|
+
*
|
|
5
|
+
* These are the SVG sanitizer, theme resolver, the standard-block DOM
|
|
6
|
+
* assembler (canonical chrome from `src/embed` — BL-114), the error card,
|
|
7
|
+
* aria-label derivation, style injection, and share-URL builder — factored
|
|
8
|
+
* out of `auto/index.ts` so the two entries share one implementation rather
|
|
9
|
+
* than diverging copies. The `auto` entry's public `window.dgmo` surface is
|
|
10
|
+
* unaffected; it imports from here.
|
|
11
|
+
*/
|
|
12
|
+
declare const VERSION: string;
|
|
13
|
+
|
|
14
|
+
type ThemePreference = 'auto' | 'light' | 'dark' | 'transparent';
|
|
15
|
+
declare function resolveTheme(theme: ThemePreference | undefined): 'light' | 'dark' | 'transparent';
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* `@diagrammo/dgmo/auto` — IIFE-distributed auto-renderer for static HTML.
|
|
19
|
+
*
|
|
20
|
+
* Drop a `<script src="…/auto.js">` on any page; on `DOMContentLoaded`
|
|
21
|
+
* this module scans for `.dgmo, .language-dgmo`, runs `render()`, and
|
|
22
|
+
* replaces each match with the standard DGMO embed block (BL-114,
|
|
23
|
+
* `figure.dgmo.dgmo-rendered`) — the diagram plus a hover-reveal icon
|
|
24
|
+
* toolbar with view-source, Copy, and "Open in editor" actions.
|
|
25
|
+
*
|
|
26
|
+
* Public API: frozen `window.dgmo` and alias `window.diagrammo` with
|
|
27
|
+
* `{ initialize, run, version }`. Configuration is read from the
|
|
28
|
+
* bundle's own `<script data-config='{…}'>` (JSON with strict
|
|
29
|
+
* allowlist) or via `dgmo.initialize(opts)` for `data-auto="false"`
|
|
30
|
+
* embedders.
|
|
31
|
+
*/
|
|
32
|
+
|
|
33
|
+
interface AutoConfig {
|
|
34
|
+
theme?: 'auto' | 'light' | 'dark' | 'transparent';
|
|
35
|
+
palette?: string;
|
|
36
|
+
showSource?: boolean;
|
|
37
|
+
showEditorLink?: boolean;
|
|
38
|
+
}
|
|
39
|
+
interface RunOptions {
|
|
40
|
+
nodes?: Element[] | NodeListOf<Element>;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
declare function findScriptTag(): HTMLScriptElement | null;
|
|
44
|
+
declare function parseConfig(raw: string | null | undefined): Partial<AutoConfig>;
|
|
45
|
+
declare function selectTargets(root?: ParentNode): Element[];
|
|
46
|
+
declare function initialize(opts?: AutoConfig): void;
|
|
47
|
+
declare function run(opts?: RunOptions): Promise<void>;
|
|
48
|
+
declare const api: Readonly<{
|
|
49
|
+
initialize: typeof initialize;
|
|
50
|
+
run: typeof run;
|
|
51
|
+
version: string;
|
|
52
|
+
}>;
|
|
53
|
+
|
|
54
|
+
export { type AutoConfig, type RunOptions, VERSION, api as default, findScriptTag, initialize, parseConfig, resolveTheme, run, selectTargets };
|