sldeditor 0.10.4 → 0.11.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/dist/OneLineEditor.d.ts +8 -1
- package/dist/OneLineEditor.d.ts.map +1 -1
- package/dist/canvas/CanvasSvg.d.ts.map +1 -1
- package/dist/canvas/tools/PanTool.d.ts.map +1 -1
- package/dist/canvas/useKeyboardShortcuts.d.ts.map +1 -1
- package/dist/canvas/useTools.d.ts.map +1 -1
- package/dist/components/EditorShell.d.ts.map +1 -1
- package/dist/components/ViewToolbar.d.ts.map +1 -1
- package/dist/i18n/messages.d.ts +4 -4
- package/dist/sldeditor.cjs +41 -41
- package/dist/sldeditor.cjs.map +1 -1
- package/dist/sldeditor.js +3586 -3557
- package/dist/sldeditor.js.map +1 -1
- package/dist/store/store.d.ts +5 -0
- package/dist/store/store.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/OneLineEditor.d.ts
CHANGED
|
@@ -5,6 +5,13 @@ export interface OneLineEditorProps {
|
|
|
5
5
|
className?: string;
|
|
6
6
|
/** Initial DiagramFile to render. Re-renders when this reference changes. */
|
|
7
7
|
diagram?: DiagramFile;
|
|
8
|
+
/**
|
|
9
|
+
* Render as a view-only viewer: full pan/zoom/touch gestures and
|
|
10
|
+
* fit-to-content on load are preserved, but every editing interaction and
|
|
11
|
+
* all editing chrome are disabled. In this mode the passed `diagram` always
|
|
12
|
+
* wins over any persisted document, and nothing is written to storage.
|
|
13
|
+
*/
|
|
14
|
+
readOnly?: boolean;
|
|
8
15
|
/**
|
|
9
16
|
* Force the editor's UI language. When omitted, falls back to the user's
|
|
10
17
|
* previous choice (localStorage) or the browser's locale. When set, the
|
|
@@ -20,5 +27,5 @@ export interface OneLineEditorProps {
|
|
|
20
27
|
*/
|
|
21
28
|
theme?: Theme;
|
|
22
29
|
}
|
|
23
|
-
export declare function OneLineEditor({ className, diagram, locale, theme }: OneLineEditorProps): import("react/jsx-runtime").JSX.Element;
|
|
30
|
+
export declare function OneLineEditor({ className, diagram, readOnly, locale, theme }: OneLineEditorProps): import("react/jsx-runtime").JSX.Element;
|
|
24
31
|
//# sourceMappingURL=OneLineEditor.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"OneLineEditor.d.ts","sourceRoot":"","sources":["../src/OneLineEditor.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAE3C,OAAO,EAAa,KAAK,MAAM,EAAE,MAAM,QAAQ,CAAC;AAChD,OAAO,EAAc,KAAK,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAE3D,MAAM,WAAW,kBAAkB;IACjC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,6EAA6E;IAC7E,OAAO,CAAC,EAAE,WAAW,CAAC;IACtB;;;;;OAKG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;;;;OAKG;IACH,KAAK,CAAC,EAAE,KAAK,CAAC;CACf;AAED,wBAAgB,aAAa,CAAC,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,kBAAkB,
|
|
1
|
+
{"version":3,"file":"OneLineEditor.d.ts","sourceRoot":"","sources":["../src/OneLineEditor.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAE3C,OAAO,EAAa,KAAK,MAAM,EAAE,MAAM,QAAQ,CAAC;AAChD,OAAO,EAAc,KAAK,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAE3D,MAAM,WAAW,kBAAkB;IACjC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,6EAA6E;IAC7E,OAAO,CAAC,EAAE,WAAW,CAAC;IACtB;;;;;OAKG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB;;;;;OAKG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;;;;OAKG;IACH,KAAK,CAAC,EAAE,KAAK,CAAC;CACf;AAED,wBAAgB,aAAa,CAAC,EAAE,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,kBAAkB,2CAkDhG"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CanvasSvg.d.ts","sourceRoot":"","sources":["../../src/canvas/CanvasSvg.tsx"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AA2DH,wBAAgB,SAAS,
|
|
1
|
+
{"version":3,"file":"CanvasSvg.d.ts","sourceRoot":"","sources":["../../src/canvas/CanvasSvg.tsx"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AA2DH,wBAAgB,SAAS,4CAoRxB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PanTool.d.ts","sourceRoot":"","sources":["../../../src/canvas/tools/PanTool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAQH,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,SAAS,CAAC;AAyBpC,eAAO,MAAM,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"PanTool.d.ts","sourceRoot":"","sources":["../../../src/canvas/tools/PanTool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAQH,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,SAAS,CAAC;AAyBpC,eAAO,MAAM,OAAO,EAAE,IA2JrB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useKeyboardShortcuts.d.ts","sourceRoot":"","sources":["../../src/canvas/useKeyboardShortcuts.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAgBH;;;;;GAKG;AACH,wBAAgB,gBAAgB,IAAI,IAAI,CAiCvC;AAGD,wBAAgB,oBAAoB,IAAI,IAAI,
|
|
1
|
+
{"version":3,"file":"useKeyboardShortcuts.d.ts","sourceRoot":"","sources":["../../src/canvas/useKeyboardShortcuts.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAgBH;;;;;GAKG;AACH,wBAAgB,gBAAgB,IAAI,IAAI,CAiCvC;AAGD,wBAAgB,oBAAoB,IAAI,IAAI,CA2H3C"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useTools.d.ts","sourceRoot":"","sources":["../../src/canvas/useTools.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAa,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAIlD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAEjD,wBAAgB,QAAQ,CACtB,OAAO,EAAE,SAAS,CAAC,cAAc,GAAG,IAAI,CAAC,EACzC,QAAQ,EAAE,WAAW,GACpB,IAAI,
|
|
1
|
+
{"version":3,"file":"useTools.d.ts","sourceRoot":"","sources":["../../src/canvas/useTools.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAa,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAIlD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAEjD,wBAAgB,QAAQ,CACtB,OAAO,EAAE,SAAS,CAAC,cAAc,GAAG,IAAI,CAAC,EACzC,QAAQ,EAAE,WAAW,GACpB,IAAI,CA6CN"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EditorShell.d.ts","sourceRoot":"","sources":["../../src/components/EditorShell.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"EditorShell.d.ts","sourceRoot":"","sources":["../../src/components/EditorShell.tsx"],"names":[],"mappings":"AAuEA,wBAAgB,WAAW,4CAuC1B"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ViewToolbar.d.ts","sourceRoot":"","sources":["../../src/components/ViewToolbar.tsx"],"names":[],"mappings":"AA8TA;;;;;;;GAOG;AACH,wBAAgB,cAAc,CAAC,EAAE,OAAO,EAAE,GAAE;IAAE,OAAO,CAAC,EAAE,OAAO,CAAA;CAAO,2CA8DrE;AAED;;;;;GAKG;AACH,wBAAgB,WAAW,
|
|
1
|
+
{"version":3,"file":"ViewToolbar.d.ts","sourceRoot":"","sources":["../../src/components/ViewToolbar.tsx"],"names":[],"mappings":"AA8TA;;;;;;;GAOG;AACH,wBAAgB,cAAc,CAAC,EAAE,OAAO,EAAE,GAAE;IAAE,OAAO,CAAC,EAAE,OAAO,CAAA;CAAO,2CA8DrE;AAED;;;;;GAKG;AACH,wBAAgB,WAAW,mDAQ1B"}
|
package/dist/i18n/messages.d.ts
CHANGED
|
@@ -177,8 +177,8 @@ export declare const messages: {
|
|
|
177
177
|
readonly 'onboard.step1.body': "切到 元件 工具(P),从左侧元件库选一种拖到画布";
|
|
178
178
|
readonly 'onboard.step2.title': "拉线连接";
|
|
179
179
|
readonly 'onboard.step2.body': "用 连线 工具(W)从一个引脚拖到另一个引脚;拖到空白处会自动新建接线柱";
|
|
180
|
-
readonly 'onboard.step3.title': "
|
|
181
|
-
readonly 'onboard.step3.body': "
|
|
180
|
+
readonly 'onboard.step3.title': "母线是共用排,不是连线";
|
|
181
|
+
readonly 'onboard.step3.body': "几条回路共用一排时才用 母线 工具(B)。别拿母线连两个器件——点对点直接拉线(W)就行。";
|
|
182
182
|
readonly 'onboard.dismiss': "知道了";
|
|
183
183
|
};
|
|
184
184
|
readonly en: {
|
|
@@ -352,8 +352,8 @@ export declare const messages: {
|
|
|
352
352
|
readonly 'onboard.step1.body': "Pick the Place tool (P) and drag a kind from the library onto the canvas";
|
|
353
353
|
readonly 'onboard.step2.title': "Wire it up";
|
|
354
354
|
readonly 'onboard.step2.body': "Use the Wire tool (W): drag from one pin to another — drag into empty space to drop a junction";
|
|
355
|
-
readonly 'onboard.step3.title': "
|
|
356
|
-
readonly 'onboard.step3.body': "
|
|
355
|
+
readonly 'onboard.step3.title': "A busbar is a shared rail, not a wire";
|
|
356
|
+
readonly 'onboard.step3.body': "Use the Busbar tool (B) only when several circuits share one rail. Don't use a bus to join two devices — just wire the pins (W).";
|
|
357
357
|
readonly 'onboard.dismiss': "Got it";
|
|
358
358
|
};
|
|
359
359
|
};
|