From fdb81be0a04d43acd602dd76a27b352741149084 Mon Sep 17 00:00:00 2001 From: "Ashley Engelund (weedySeaDragon @ github)" Date: Sun, 2 Oct 2022 13:51:25 -0700 Subject: [PATCH 01/11] update demo diagrams to have lang, hr tags, src = mermaid.js where needed. --- demos/c4context.html | 8 ++- demos/classchart.html | 11 +++- demos/dataflowchart.html | 8 +-- demos/er.html | 8 ++- demos/flowchart.html | 109 +++++++++++++++++++++++++-------------- demos/gantt.html | 17 +++++- demos/git.html | 3 +- demos/index.html | 100 ++++------------------------------- demos/journey.html | 3 +- demos/pie.html | 6 ++- demos/requirements.html | 3 +- demos/sequence.html | 10 +++- demos/state.html | 3 +- 13 files changed, 143 insertions(+), 146 deletions(-) diff --git a/demos/c4context.html b/demos/c4context.html index 1485d42d8..ec7197b98 100644 --- a/demos/c4context.html +++ b/demos/c4context.html @@ -1,5 +1,5 @@ - + @@ -14,6 +14,7 @@ +

C4 context diagram demos

     C4Context
       accTitle: C4 context demo
@@ -62,6 +63,7 @@
       
       UpdateLayoutConfig($c4ShapeInRow="3", $c4BoundaryInRow="1")
     
+
     C4Container
@@ -101,6 +103,7 @@
     Rel(backend_api, banking_system, "Uses", "sync/async, XML/HTTPS")
     UpdateRelStyle(backend_api, banking_system, $offsetY="-50", $offsetX="-140")
     
+
     C4Component
@@ -140,6 +143,7 @@
         UpdateRelStyle(security, db, $offsetY="-40")
         UpdateRelStyle(mbsfacade, mbs, $offsetY="-40")
     
+
     C4Dynamic
@@ -159,6 +163,7 @@
     UpdateRelStyle(c2, c3, $textColor="red", $offsetX="-40", $offsetY="60")
     UpdateRelStyle(c3, c4, $textColor="red", $offsetY="-40", $offsetX="10")
     
+
     C4Deployment
@@ -210,7 +215,6 @@
     UpdateRelStyle(api, db2, $offsetX="-40", $offsetY="-20")
     UpdateRelStyle(db, db2, $offsetY="-10")
      
-
diff --git a/demos/classchart.html b/demos/classchart.html index e15495b95..5979152d6 100644 --- a/demos/classchart.html +++ b/demos/classchart.html @@ -1,5 +1,5 @@ - + @@ -14,6 +14,8 @@ +

Class diagram demos

+
 		classDiagram
       accTitle: Demo Class Diagram
@@ -42,8 +44,8 @@
       }
 
     
-
+
     classDiagram
     Class01 <|-- AveryLongClass : Cool
@@ -68,6 +70,7 @@
       }
     

+
     classDiagram
     class Class01~T~
@@ -81,6 +84,7 @@
     }
     

+
     classDiagram
     Class01~T~ <|-- AveryLongClass : Cool
@@ -104,11 +108,13 @@
         }
     

+
     classDiagram
     Interface1 ()-- Interface1Impl
     

+
     classDiagram
     direction LR
@@ -117,6 +123,7 @@
     Dog : species()
     

+
     classDiagram
     direction RL
diff --git a/demos/dataflowchart.html b/demos/dataflowchart.html
index 34011b5fe..dc7fe05af 100644
--- a/demos/dataflowchart.html
+++ b/demos/dataflowchart.html
@@ -1,9 +1,9 @@
 
-
+
   
     
     
-    Mermaid Quick Test Page
+    Data Flow Mermaid Quick Test Page
     
     
   
   
-    

Data Flow Diagram Example

+

Data Flow Diagram demos

     flowchart LR
       accTitle: A simple linear flowchart.
@@ -21,6 +21,8 @@
       DataStore[|borders:tb|Database] -->|input| Process((System)) -->|output| Entity[Customer];
     
+
+

Borders Example

     flowchart TD
diff --git a/demos/er.html b/demos/er.html
index 68aaf18a2..4c1a72c20 100644
--- a/demos/er.html
+++ b/demos/er.html
@@ -1,5 +1,5 @@
 
-
+
   
     
     
@@ -10,6 +10,10 @@
         /* font-family: 'trebuchet ms', verdana, arial; */
         font-family: 'Courier New', Courier, monospace !important;
       }
+      .diagram-title {
+        fill: red;
+        font-size: 24pt;
+      }
     
   
 
@@ -51,8 +55,8 @@ erDiagram
       }
     
+ + - - - diff --git a/demos/journey.html b/demos/journey.html index dc1c379d3..c5c6c25e8 100644 --- a/demos/journey.html +++ b/demos/journey.html @@ -1,5 +1,5 @@ - + @@ -14,6 +14,7 @@ +

Journey diagram demo

          journey
     title My working day
diff --git a/demos/pie.html b/demos/pie.html
index 3232d2534..333ef9491 100644
--- a/demos/pie.html
+++ b/demos/pie.html
@@ -1,5 +1,5 @@
 
-
+
   
     
     
@@ -14,6 +14,7 @@
   
 
   
+    

Pie chart demos

       pie title Pets adopted by volunteers
       accTitle: simple pie char demo
@@ -23,6 +24,7 @@
     "Rats" : 15
     
+
     pie
       title Key elements in Product X
@@ -35,7 +37,7 @@
     
From 803ea863fdd98bd5018ea5c740c80ba9f87419f1 Mon Sep 17 00:00:00 2001 From: Sidharth Vinod Date: Thu, 6 Oct 2022 22:58:54 +0800 Subject: [PATCH 11/11] fix: pnpm not found --- package.json | 9 +++++---- pnpm-lock.yaml | 8 ++++++++ 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index 67f546d97..c1c33920f 100644 --- a/package.json +++ b/package.json @@ -7,7 +7,7 @@ "module": "dist/mermaid.core.mjs", "types": "dist/mermaid.d.ts", "type": "module", - "packageManager": "pnpm@7.12.2", + "packageManager": "pnpm@7.13.2", "exports": { ".": { "require": "./dist/mermaid.min.js", @@ -71,8 +71,8 @@ }, "dependencies": { "@braintree/sanitize-url": "^6.0.0", - "@types/uuid": "^8.3.4", "@types/node": "^18.8.1", + "@types/uuid": "^8.3.4", "d3": "^7.0.0", "dagre": "^0.8.5", "dagre-d3": "^0.6.4", @@ -107,8 +107,8 @@ "coveralls": "^3.1.1", "cypress": "^10.0.0", "cypress-image-snapshot": "^4.0.1", - "esbuild": "^0.15.10", "documentation": "13.2.0", + "esbuild": "^0.15.10", "eslint": "^8.24.0", "eslint-config-prettier": "^8.5.0", "eslint-plugin-cypress": "^2.12.1", @@ -128,6 +128,7 @@ "markdown-it": "^13.0.1", "moment": "^2.23.0", "path-browserify": "^1.0.1", + "pnpm": "^7.13.2", "prettier": "^2.7.1", "prettier-plugin-jsdoc": "^0.4.2", "remark": "^14.0.2", @@ -136,10 +137,10 @@ "ts-node": "^10.9.1", "typescript": "^4.8.4", "unist-util-flatmap": "^1.0.0", + "vite": "^3.1.4", "vitepress": "^1.0.0-alpha.19", "vitepress-plugin-mermaid": "^2.0.8", "vitepress-plugin-search": "^1.0.4-alpha.11", - "vite": "^3.1.4", "vitest": "^0.23.4" }, "resolutions": { diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 80e619de0..9cb8306ea 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -60,6 +60,7 @@ importers: moment-mini: ^2.24.0 non-layered-tidy-tree-layout: ^2.0.2 path-browserify: ^1.0.1 + pnpm: ^7.13.2 prettier: ^2.7.1 prettier-plugin-jsdoc: ^0.4.2 remark: ^14.0.2 @@ -134,6 +135,7 @@ importers: markdown-it: 13.0.1 moment: 2.29.4 path-browserify: 1.0.1 + pnpm: 7.13.2 prettier: 2.7.1 prettier-plugin-jsdoc: 0.4.2_prettier@2.7.1 remark: 14.0.2 @@ -10729,6 +10731,12 @@ packages: engines: {node: '>=12.13.0'} dev: true + /pnpm/7.13.2: + resolution: {integrity: sha512-lOQRBcCWycLK1PB9KptqTd6iyiH7m4GRuS4G2j4b74yDx/XvRXtP/weYz8e0/ia7HX1pMF1vJCF48ssklq0TJQ==} + engines: {node: '>=14.6'} + hasBin: true + dev: true + /posix-character-classes/0.1.1: resolution: {integrity: sha512-xTgYBc3fuo7Yt7JbiuFxSYGToMoz8fLoE6TC9Wx1P/u+LfeThMOAqmuyECnlBaaJb+u1m9hHiXUEtwW4OzfUJg==} engines: {node: '>=0.10.0'}