@uigraph/sdk 1.2.0 → 1.2.1
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/index.cjs +22 -21
- package/dist/index.mjs +22 -21
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -2023,7 +2023,7 @@ function _asyncToGenerator(n) {
|
|
|
2023
2023
|
}
|
|
2024
2024
|
mermaid.default.initialize({
|
|
2025
2025
|
startOnLoad: false,
|
|
2026
|
-
theme: "
|
|
2026
|
+
theme: "dark",
|
|
2027
2027
|
flowchart: {
|
|
2028
2028
|
htmlLabels: false,
|
|
2029
2029
|
curve: "linear"
|
|
@@ -3089,12 +3089,12 @@ function createReactFlowElements(nodes, edges, subgraphs, subgraphLayouts, subgr
|
|
|
3089
3089
|
debugLog("Creating React Flow elements");
|
|
3090
3090
|
function getNodeColors(shape) {
|
|
3091
3091
|
const colors = {
|
|
3092
|
-
rect: ["#
|
|
3093
|
-
diamond: ["#
|
|
3094
|
-
circle: ["#
|
|
3095
|
-
stadium: ["#
|
|
3096
|
-
round: ["#
|
|
3097
|
-
}[shape] || ["#
|
|
3092
|
+
rect: ["#1C2336", "#3D5EA8"],
|
|
3093
|
+
diamond: ["#1C2336", "#3D5EA8"],
|
|
3094
|
+
circle: ["#1C2336", "#3D5EA8"],
|
|
3095
|
+
stadium: ["#1C2336", "#3D5EA8"],
|
|
3096
|
+
round: ["#1C2336", "#3D5EA8"]
|
|
3097
|
+
}[shape] || ["#1C2336", "#3D5EA8"];
|
|
3098
3098
|
return {
|
|
3099
3099
|
backgroundColor: colors[0],
|
|
3100
3100
|
borderColor: colors[1]
|
|
@@ -3103,24 +3103,24 @@ function createReactFlowElements(nodes, edges, subgraphs, subgraphLayouts, subgr
|
|
|
3103
3103
|
function getSubgraphColors(index) {
|
|
3104
3104
|
const subgraphColors = [
|
|
3105
3105
|
{
|
|
3106
|
-
bg: "rgba(
|
|
3107
|
-
border: "#
|
|
3106
|
+
bg: "rgba(100, 181, 246, 0.08)",
|
|
3107
|
+
border: "#64B5F6"
|
|
3108
3108
|
},
|
|
3109
3109
|
{
|
|
3110
|
-
bg: "rgba(
|
|
3111
|
-
border: "#
|
|
3110
|
+
bg: "rgba(129, 199, 132, 0.08)",
|
|
3111
|
+
border: "#81C784"
|
|
3112
3112
|
},
|
|
3113
3113
|
{
|
|
3114
|
-
bg: "rgba(
|
|
3115
|
-
border: "#
|
|
3114
|
+
bg: "rgba(186, 104, 200, 0.08)",
|
|
3115
|
+
border: "#BA68C8"
|
|
3116
3116
|
},
|
|
3117
3117
|
{
|
|
3118
|
-
bg: "rgba(255,
|
|
3119
|
-
border: "#
|
|
3118
|
+
bg: "rgba(255, 183, 77, 0.08)",
|
|
3119
|
+
border: "#FFB74D"
|
|
3120
3120
|
},
|
|
3121
3121
|
{
|
|
3122
|
-
bg: "rgba(
|
|
3123
|
-
border: "#
|
|
3122
|
+
bg: "rgba(240, 98, 146, 0.08)",
|
|
3123
|
+
border: "#F06292"
|
|
3124
3124
|
}
|
|
3125
3125
|
];
|
|
3126
3126
|
return subgraphColors[index % subgraphColors.length];
|
|
@@ -3353,7 +3353,8 @@ function createReactFlowElements(nodes, edges, subgraphs, subgraphLayouts, subgr
|
|
|
3353
3353
|
labelStyle: {
|
|
3354
3354
|
fontSize: "12px",
|
|
3355
3355
|
fontWeight: "500",
|
|
3356
|
-
|
|
3356
|
+
color: "#E2E8F0",
|
|
3357
|
+
backgroundColor: "#1E293B",
|
|
3357
3358
|
padding: "2px 6px"
|
|
3358
3359
|
},
|
|
3359
3360
|
markerEnd: {
|
|
@@ -3412,7 +3413,7 @@ function _convertSequenceDiagramToReactFlow() {
|
|
|
3412
3413
|
componentFields: [generateComponentFieldNameInput(p.name), generateComponentFieldInput({
|
|
3413
3414
|
componentFieldId: "color",
|
|
3414
3415
|
label: "Color",
|
|
3415
|
-
data: "#
|
|
3416
|
+
data: "#E2E8F0",
|
|
3416
3417
|
type: require_component_type.ComponentInputType.ColorPicker
|
|
3417
3418
|
})]
|
|
3418
3419
|
}
|
|
@@ -3437,8 +3438,8 @@ function _convertSequenceDiagramToReactFlow() {
|
|
|
3437
3438
|
data: {
|
|
3438
3439
|
source: "mermaid",
|
|
3439
3440
|
shape: "rectangle",
|
|
3440
|
-
fill: "#
|
|
3441
|
-
stroke: "#
|
|
3441
|
+
fill: "#1E293B",
|
|
3442
|
+
stroke: "#475569",
|
|
3442
3443
|
strokeWidth: 1,
|
|
3443
3444
|
componentFields: [generateComponentFieldNameInput(m.label)]
|
|
3444
3445
|
},
|
package/dist/index.mjs
CHANGED
|
@@ -2016,7 +2016,7 @@ function _asyncToGenerator(n) {
|
|
|
2016
2016
|
}
|
|
2017
2017
|
mermaid.initialize({
|
|
2018
2018
|
startOnLoad: false,
|
|
2019
|
-
theme: "
|
|
2019
|
+
theme: "dark",
|
|
2020
2020
|
flowchart: {
|
|
2021
2021
|
htmlLabels: false,
|
|
2022
2022
|
curve: "linear"
|
|
@@ -3082,12 +3082,12 @@ function createReactFlowElements(nodes, edges, subgraphs, subgraphLayouts, subgr
|
|
|
3082
3082
|
debugLog("Creating React Flow elements");
|
|
3083
3083
|
function getNodeColors(shape) {
|
|
3084
3084
|
const colors = {
|
|
3085
|
-
rect: ["#
|
|
3086
|
-
diamond: ["#
|
|
3087
|
-
circle: ["#
|
|
3088
|
-
stadium: ["#
|
|
3089
|
-
round: ["#
|
|
3090
|
-
}[shape] || ["#
|
|
3085
|
+
rect: ["#1C2336", "#3D5EA8"],
|
|
3086
|
+
diamond: ["#1C2336", "#3D5EA8"],
|
|
3087
|
+
circle: ["#1C2336", "#3D5EA8"],
|
|
3088
|
+
stadium: ["#1C2336", "#3D5EA8"],
|
|
3089
|
+
round: ["#1C2336", "#3D5EA8"]
|
|
3090
|
+
}[shape] || ["#1C2336", "#3D5EA8"];
|
|
3091
3091
|
return {
|
|
3092
3092
|
backgroundColor: colors[0],
|
|
3093
3093
|
borderColor: colors[1]
|
|
@@ -3096,24 +3096,24 @@ function createReactFlowElements(nodes, edges, subgraphs, subgraphLayouts, subgr
|
|
|
3096
3096
|
function getSubgraphColors(index) {
|
|
3097
3097
|
const subgraphColors = [
|
|
3098
3098
|
{
|
|
3099
|
-
bg: "rgba(
|
|
3100
|
-
border: "#
|
|
3099
|
+
bg: "rgba(100, 181, 246, 0.08)",
|
|
3100
|
+
border: "#64B5F6"
|
|
3101
3101
|
},
|
|
3102
3102
|
{
|
|
3103
|
-
bg: "rgba(
|
|
3104
|
-
border: "#
|
|
3103
|
+
bg: "rgba(129, 199, 132, 0.08)",
|
|
3104
|
+
border: "#81C784"
|
|
3105
3105
|
},
|
|
3106
3106
|
{
|
|
3107
|
-
bg: "rgba(
|
|
3108
|
-
border: "#
|
|
3107
|
+
bg: "rgba(186, 104, 200, 0.08)",
|
|
3108
|
+
border: "#BA68C8"
|
|
3109
3109
|
},
|
|
3110
3110
|
{
|
|
3111
|
-
bg: "rgba(255,
|
|
3112
|
-
border: "#
|
|
3111
|
+
bg: "rgba(255, 183, 77, 0.08)",
|
|
3112
|
+
border: "#FFB74D"
|
|
3113
3113
|
},
|
|
3114
3114
|
{
|
|
3115
|
-
bg: "rgba(
|
|
3116
|
-
border: "#
|
|
3115
|
+
bg: "rgba(240, 98, 146, 0.08)",
|
|
3116
|
+
border: "#F06292"
|
|
3117
3117
|
}
|
|
3118
3118
|
];
|
|
3119
3119
|
return subgraphColors[index % subgraphColors.length];
|
|
@@ -3346,7 +3346,8 @@ function createReactFlowElements(nodes, edges, subgraphs, subgraphLayouts, subgr
|
|
|
3346
3346
|
labelStyle: {
|
|
3347
3347
|
fontSize: "12px",
|
|
3348
3348
|
fontWeight: "500",
|
|
3349
|
-
|
|
3349
|
+
color: "#E2E8F0",
|
|
3350
|
+
backgroundColor: "#1E293B",
|
|
3350
3351
|
padding: "2px 6px"
|
|
3351
3352
|
},
|
|
3352
3353
|
markerEnd: {
|
|
@@ -3405,7 +3406,7 @@ function _convertSequenceDiagramToReactFlow() {
|
|
|
3405
3406
|
componentFields: [generateComponentFieldNameInput(p.name), generateComponentFieldInput({
|
|
3406
3407
|
componentFieldId: "color",
|
|
3407
3408
|
label: "Color",
|
|
3408
|
-
data: "#
|
|
3409
|
+
data: "#E2E8F0",
|
|
3409
3410
|
type: ComponentInputType.ColorPicker
|
|
3410
3411
|
})]
|
|
3411
3412
|
}
|
|
@@ -3430,8 +3431,8 @@ function _convertSequenceDiagramToReactFlow() {
|
|
|
3430
3431
|
data: {
|
|
3431
3432
|
source: "mermaid",
|
|
3432
3433
|
shape: "rectangle",
|
|
3433
|
-
fill: "#
|
|
3434
|
-
stroke: "#
|
|
3434
|
+
fill: "#1E293B",
|
|
3435
|
+
stroke: "#475569",
|
|
3435
3436
|
strokeWidth: 1,
|
|
3436
3437
|
componentFields: [generateComponentFieldNameInput(m.label)]
|
|
3437
3438
|
},
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uigraph/sdk",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.1",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"license": "BUSL-1.1",
|
|
6
6
|
"repository": {
|
|
@@ -117,7 +117,7 @@
|
|
|
117
117
|
"tc": "tsc --noEmit --watch",
|
|
118
118
|
"exports": "tsx ./write-exports.ts",
|
|
119
119
|
"build": "tsdown --config ./tsdown.config.ts",
|
|
120
|
-
"dev": "concurrently --names \"R,T
|
|
120
|
+
"dev": "concurrently --names \"R,T\" --prefix-colors \"blue.dim,magenta.dim\" \"tsdown --config ./tsdown.config.ts --watch\" \"tsc --noEmit --watch\"",
|
|
121
121
|
"start": "bun run --watch ./src/__lab__/index.ts"
|
|
122
122
|
}
|
|
123
123
|
}
|