@diagrammo/dgmo 0.8.12 → 0.8.13

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.
Files changed (45) hide show
  1. package/dist/cli.cjs +115 -719
  2. package/dist/index.cjs +11 -5
  3. package/dist/index.cjs.map +1 -1
  4. package/dist/index.js +9 -6
  5. package/dist/index.js.map +1 -1
  6. package/docs/guide/chart-arc.md +71 -0
  7. package/docs/guide/chart-area.md +73 -0
  8. package/docs/guide/chart-bar-stacked.md +61 -0
  9. package/docs/guide/chart-bar.md +62 -0
  10. package/docs/guide/chart-boxes-and-lines.md +243 -0
  11. package/docs/guide/chart-c4.md +300 -0
  12. package/docs/guide/chart-chord.md +43 -0
  13. package/docs/guide/chart-class.md +204 -0
  14. package/docs/guide/chart-doughnut.md +38 -0
  15. package/docs/guide/chart-er.md +218 -0
  16. package/docs/guide/chart-flowchart.md +102 -0
  17. package/docs/guide/chart-function.md +56 -0
  18. package/docs/guide/chart-funnel.md +38 -0
  19. package/docs/guide/chart-gantt.md +368 -0
  20. package/docs/guide/chart-heatmap.md +41 -0
  21. package/docs/guide/chart-infra.md +694 -0
  22. package/docs/guide/chart-kanban.md +156 -0
  23. package/docs/guide/chart-line.md +79 -0
  24. package/docs/guide/chart-multi-line.md +84 -0
  25. package/docs/guide/chart-org.md +209 -0
  26. package/docs/guide/chart-pie.md +39 -0
  27. package/docs/guide/chart-polar-area.md +38 -0
  28. package/docs/guide/chart-quadrant.md +69 -0
  29. package/docs/guide/chart-radar.md +38 -0
  30. package/docs/guide/chart-sankey.md +103 -0
  31. package/docs/guide/chart-scatter.md +94 -0
  32. package/docs/guide/chart-sequence.md +332 -0
  33. package/docs/guide/chart-sitemap.md +248 -0
  34. package/docs/guide/chart-slope.md +56 -0
  35. package/docs/guide/chart-state.md +171 -0
  36. package/docs/guide/chart-timeline.md +229 -0
  37. package/docs/guide/chart-venn.md +81 -0
  38. package/docs/guide/chart-wordcloud.md +66 -0
  39. package/docs/guide/colors.md +283 -0
  40. package/docs/guide/index.md +55 -0
  41. package/docs/guide/keyboard-shortcuts.md +49 -0
  42. package/docs/guide/registry.json +51 -0
  43. package/gallery/fixtures/boxes-and-lines.dgmo +4 -6
  44. package/package.json +1 -1
  45. package/src/sharing.ts +3 -4
package/dist/index.js CHANGED
@@ -31238,10 +31238,8 @@ init_colors();
31238
31238
  init_palettes();
31239
31239
 
31240
31240
  // src/sharing.ts
31241
- import {
31242
- compressToEncodedURIComponent,
31243
- decompressFromEncodedURIComponent
31244
- } from "lz-string";
31241
+ import lzString from "lz-string";
31242
+ var { compressToEncodedURIComponent, decompressFromEncodedURIComponent } = lzString;
31245
31243
  var DEFAULT_BASE_URL = "https://online.diagrammo.app";
31246
31244
  var COMPRESSED_SIZE_LIMIT = 8192;
31247
31245
  function encodeDiagramUrl(dsl, options) {
@@ -31249,7 +31247,11 @@ function encodeDiagramUrl(dsl, options) {
31249
31247
  const compressed = compressToEncodedURIComponent(dsl);
31250
31248
  const byteSize = new TextEncoder().encode(compressed).byteLength;
31251
31249
  if (byteSize > COMPRESSED_SIZE_LIMIT) {
31252
- return { error: "too-large", compressedSize: byteSize, limit: COMPRESSED_SIZE_LIMIT };
31250
+ return {
31251
+ error: "too-large",
31252
+ compressedSize: byteSize,
31253
+ limit: COMPRESSED_SIZE_LIMIT
31254
+ };
31253
31255
  }
31254
31256
  let hash = `dgmo=${compressed}`;
31255
31257
  if (options?.viewState?.activeTagGroup) {
@@ -31300,7 +31302,8 @@ function decodeDiagramUrl(hash) {
31300
31302
  viewState.collapsedLanes = val.split(",").filter(Boolean);
31301
31303
  }
31302
31304
  if (key === "pal" && val) viewState.palette = val;
31303
- if (key === "th" && (val === "light" || val === "dark")) viewState.theme = val;
31305
+ if (key === "th" && (val === "light" || val === "dark"))
31306
+ viewState.theme = val;
31304
31307
  }
31305
31308
  if (payload.startsWith("dgmo=")) {
31306
31309
  payload = payload.slice(5);