@diagrammo/dgmo-standalone 0.64.1 → 0.65.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/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Diagrammo LLC
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -65,6 +65,27 @@ Themes and palettes are attributes — `palette="slate"`, `theme="dark"`. Maps
65
65
  fetch their basemaps on demand from `@diagrammo/dgmo` on the same CDN, so a page
66
66
  with no map downloads no map data.
67
67
 
68
+ ## Watching a diagram somebody showed you
69
+
70
+ If someone published a diagram at Diagrammo — *showed it on the web* — you can
71
+ watch it from any page, and every reader gets the version its author has now:
72
+
73
+ ```html
74
+ <script src="https://cdn.jsdelivr.net/npm/@diagrammo/dgmo-standalone/dist/element.js"></script>
75
+
76
+ <dgmo-diagram watch="https://online.diagrammo.app/d/dgm_7f2a91"></dgmo-diagram>
77
+ ```
78
+
79
+ Paste the share link you were sent, or just the id at the end of it. The
80
+ diagram is fetched when the page loads — there is no polling, so a page left
81
+ open shows what it fetched on arrival until it is reloaded.
82
+
83
+ If your page sends a `Content-Security-Policy` header, it needs
84
+ `connect-src https://api.diagrammo.app` or the browser will block the request.
85
+ That case is not silent: the element draws a card naming the diagram and says
86
+ what went wrong, as it does when a diagram is missing or its author has stopped
87
+ showing it.
88
+
68
89
  ## When you want a different package
69
90
 
70
91
  This one exists for the no-build case. Reach for a sibling instead when:
@@ -79,4 +100,6 @@ This one exists for the no-build case. Reach for a sibling instead when:
79
100
  - **Try it in the browser** — <https://online.diagrammo.app>
80
101
  - **Issues** — <https://github.com/diagrammo/dgmo/issues>
81
102
 
82
- MIT licensed. Bundles [Inter](https://rsms.me/inter/) (SIL Open Font License).
103
+ MIT licensed the full text is in `LICENSE`, in this package. Labels are drawn
104
+ in [Inter](https://rsms.me/inter/) when your page already provides it, falling
105
+ back to the system interface font; no font files are bundled.
package/dist/auto.css CHANGED
@@ -26,6 +26,17 @@ pre.dgmo, code.language-dgmo, pre > code.language-dgmo,
26
26
  font-family: ui-monospace, monospace;
27
27
  }
28
28
 
29
+ /* A watched diagram that could not be drawn: the reference card, then this
30
+ sentence. Deliberately not styled as an error — a publisher who stopped
31
+ showing a diagram did something on purpose, and a red box would tell the
32
+ reader the page is broken. */
33
+ .dgmo--live-state .dgmo-live-note {
34
+ margin: 0.5em 0 0;
35
+ font-size: 13px;
36
+ line-height: 1.5;
37
+ opacity: 0.8;
38
+ }
39
+
29
40
  /* @diagrammo/dgmo block — standard embed chrome.
30
41
  * Override the [data-theme="dark"] selectors if your site uses .dark or
31
42
  * another color-mode convention. */