flowchart-sequence-designer 1.0.0 → 1.0.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/CHANGELOG.md +13 -0
- package/dist/ui/index.cjs +1418 -1183
- package/dist/ui/index.cjs.map +1 -1
- package/dist/ui/index.js +1354 -1119
- package/dist/ui/index.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -74,6 +74,19 @@ Versioning: [Semantic Versioning](https://semver.org/).
|
|
|
74
74
|
viewport tracking) — and added a `nodeDims(node, variant)` helper to
|
|
75
75
|
`layout.ts` that collapses the repeated `variant === 'question' ? ... : ...`
|
|
76
76
|
width/height ternary. `DiagramEditor.tsx` is now ~990 lines.
|
|
77
|
+
- Extracted `useEditorKeyboard` hook from both `DiagramEditor` and
|
|
78
|
+
`SequenceEditor` — declarative `KeyCommand[]` pattern replaces monolithic
|
|
79
|
+
`useEffect` keyboard handlers. Each command is independently testable.
|
|
80
|
+
- Moved `arrowColor()` and `shadowColor()` derivation into `theme.ts` as
|
|
81
|
+
reusable functions; both editors import them instead of inline-deriving hex
|
|
82
|
+
values from the dark-mode flag.
|
|
83
|
+
- Hoisted static inline `style={{}}` objects out of SVG `.map()` render hot
|
|
84
|
+
paths in both editors. Static styles are now module-level constants; dynamic
|
|
85
|
+
ones remain per-render but no longer allocate inside the loop.
|
|
86
|
+
- Extracted `DiagramCanvas` (346 LOC) and `SequenceCanvas` (234 LOC) from
|
|
87
|
+
their parent editors. Each editor is now an orchestrator (state + handlers)
|
|
88
|
+
while the canvas component owns all SVG rendering. `DiagramEditor.tsx` is
|
|
89
|
+
now ~836 lines; `SequenceEditor.tsx` is ~476 lines.
|
|
77
90
|
|
|
78
91
|
### Fixed
|
|
79
92
|
- Sequence diagram new-message ID collision. `addMessage()` minted IDs from
|