@eyeon/map 2.0.3 → 2.0.4
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/assets/MapViewer.css +1 -1
- package/dist/assets/index.css +1 -1
- package/dist/chunks/MapViewer.js +2557 -1432
- package/dist/chunks/MapViewer.js.map +1 -1
- package/dist/chunks/stacking.js +1263 -745
- package/dist/chunks/stacking.js.map +1 -1
- package/dist/chunks/wheelZoom.js +259 -0
- package/dist/chunks/wheelZoom.js.map +1 -0
- package/dist/core/assignment.d.ts +97 -0
- package/dist/core/assignment.d.ts.map +1 -0
- package/dist/core/color.d.ts +5 -0
- package/dist/core/color.d.ts.map +1 -0
- package/dist/core/entranceIcon.d.ts +12 -0
- package/dist/core/entranceIcon.d.ts.map +1 -0
- package/dist/core/hostChrome.d.ts +2 -4
- package/dist/core/hostChrome.d.ts.map +1 -1
- package/dist/core/index.d.ts +6 -0
- package/dist/core/index.d.ts.map +1 -1
- package/dist/core/index.js +161 -89
- package/dist/core/labelAlign.d.ts +7 -0
- package/dist/core/labelAlign.d.ts.map +1 -0
- package/dist/core/layerStyles.d.ts +40 -7
- package/dist/core/layerStyles.d.ts.map +1 -1
- package/dist/core/outdoorDecoration.d.ts +1 -1
- package/dist/core/outdoorDecoration.d.ts.map +1 -1
- package/dist/core/publish/index.d.ts +6 -4
- package/dist/core/publish/index.d.ts.map +1 -1
- package/dist/core/stacking.d.ts +50 -3
- package/dist/core/stacking.d.ts.map +1 -1
- package/dist/core/types.d.ts +29 -1
- package/dist/core/types.d.ts.map +1 -1
- package/dist/core/voids.d.ts +41 -0
- package/dist/core/voids.d.ts.map +1 -0
- package/dist/core/wheelZoom.d.ts +30 -0
- package/dist/core/wheelZoom.d.ts.map +1 -0
- package/dist/editor/FieldResetButton.d.ts +7 -0
- package/dist/editor/FieldResetButton.d.ts.map +1 -0
- package/dist/editor/MapEditor.d.ts +12 -2
- package/dist/editor/MapEditor.d.ts.map +1 -1
- package/dist/editor/canvas/EditorCanvas.d.ts +6 -2
- package/dist/editor/canvas/EditorCanvas.d.ts.map +1 -1
- package/dist/editor/canvas/OutdoorSvgUnderlay.d.ts +2 -1
- package/dist/editor/canvas/OutdoorSvgUnderlay.d.ts.map +1 -1
- package/dist/editor/canvas/coords.d.ts +26 -3
- package/dist/editor/canvas/coords.d.ts.map +1 -1
- package/dist/editor/canvas/editorFill.d.ts +3 -1
- package/dist/editor/canvas/editorFill.d.ts.map +1 -1
- package/dist/editor/canvas/editorHover.d.ts +4 -0
- package/dist/editor/canvas/editorHover.d.ts.map +1 -1
- package/dist/editor/canvas/underlayHint.d.ts +8 -0
- package/dist/editor/canvas/underlayHint.d.ts.map +1 -1
- package/dist/editor/connectorAssignments.d.ts +61 -0
- package/dist/editor/connectorAssignments.d.ts.map +1 -1
- package/dist/editor/draftOps.d.ts +8 -0
- package/dist/editor/draftOps.d.ts.map +1 -1
- package/dist/editor/editorSectionReturn.d.ts.map +1 -1
- package/dist/editor/ellipseDraw.d.ts +12 -0
- package/dist/editor/ellipseDraw.d.ts.map +1 -0
- package/dist/editor/entranceIcon.d.ts +15 -0
- package/dist/editor/entranceIcon.d.ts.map +1 -0
- package/dist/editor/hexColor.d.ts +2 -0
- package/dist/editor/hexColor.d.ts.map +1 -1
- package/dist/editor/index.css +824 -72
- package/dist/editor/index.d.ts +2 -0
- package/dist/editor/index.d.ts.map +1 -1
- package/dist/editor/index.js +6700 -4160
- package/dist/editor/index.js.map +1 -1
- package/dist/editor/labelText.d.ts +12 -2
- package/dist/editor/labelText.d.ts.map +1 -1
- package/dist/editor/labels.d.ts +8 -0
- package/dist/editor/labels.d.ts.map +1 -1
- package/dist/editor/panels/AssignForm.d.ts +17 -0
- package/dist/editor/panels/AssignForm.d.ts.map +1 -0
- package/dist/editor/panels/AssignmentStyleFields.d.ts +14 -0
- package/dist/editor/panels/AssignmentStyleFields.d.ts.map +1 -0
- package/dist/editor/panels/BulkAssignForm.d.ts +11 -0
- package/dist/editor/panels/BulkAssignForm.d.ts.map +1 -0
- package/dist/editor/panels/CatalogKioskForm.d.ts +18 -0
- package/dist/editor/panels/CatalogKioskForm.d.ts.map +1 -0
- package/dist/editor/panels/ConnectorAssign.d.ts +6 -2
- package/dist/editor/panels/ConnectorAssign.d.ts.map +1 -1
- package/dist/editor/panels/CopyToLevelButton.d.ts +10 -0
- package/dist/editor/panels/CopyToLevelButton.d.ts.map +1 -0
- package/dist/editor/panels/EntranceIconForm.d.ts +11 -0
- package/dist/editor/panels/EntranceIconForm.d.ts.map +1 -0
- package/dist/editor/panels/Inspector.d.ts +24 -3
- package/dist/editor/panels/Inspector.d.ts.map +1 -1
- package/dist/editor/panels/LeftRail.d.ts +17 -6
- package/dist/editor/panels/LeftRail.d.ts.map +1 -1
- package/dist/editor/panels/PreviewOverlay.d.ts +9 -3
- package/dist/editor/panels/PreviewOverlay.d.ts.map +1 -1
- package/dist/editor/panels/TextLabelForm.d.ts +11 -0
- package/dist/editor/panels/TextLabelForm.d.ts.map +1 -0
- package/dist/editor/panels/formRows.d.ts +41 -0
- package/dist/editor/panels/formRows.d.ts.map +1 -0
- package/dist/editor/portalSurface.d.ts +10 -2
- package/dist/editor/portalSurface.d.ts.map +1 -1
- package/dist/editor/previewDocument.d.ts +2 -1
- package/dist/editor/previewDocument.d.ts.map +1 -1
- package/dist/editor/railAssignments.d.ts +9 -2
- package/dist/editor/railAssignments.d.ts.map +1 -1
- package/dist/editor/railKiosks.d.ts +27 -0
- package/dist/editor/railKiosks.d.ts.map +1 -0
- package/dist/editor/railListCopy.d.ts +31 -0
- package/dist/editor/railListCopy.d.ts.map +1 -0
- package/dist/editor/routeStubs.d.ts +1 -1
- package/dist/editor/routeStubs.d.ts.map +1 -1
- package/dist/editor/shapeCopy.d.ts +40 -0
- package/dist/editor/shapeCopy.d.ts.map +1 -0
- package/dist/editor/shapeSelection.d.ts +6 -0
- package/dist/editor/shapeSelection.d.ts.map +1 -0
- package/dist/editor/tools.d.ts +12 -2
- package/dist/editor/tools.d.ts.map +1 -1
- package/dist/fonts/assets.d.ts +4 -0
- package/dist/fonts/mapFont.d.ts +5 -0
- package/dist/fonts/mapFont.d.ts.map +1 -0
- package/dist/fonts/mapFontUrl.d.ts +8 -0
- package/dist/fonts/mapFontUrl.d.ts.map +1 -0
- package/dist/specialIcons.d.ts +39 -0
- package/dist/specialIcons.d.ts.map +1 -0
- package/dist/ui/ModernSelect.d.ts.map +1 -1
- package/dist/ui/selectSearch.d.ts +3 -0
- package/dist/ui/selectSearch.d.ts.map +1 -1
- package/dist/viewer/MapViewer.d.ts +14 -1
- package/dist/viewer/MapViewer.d.ts.map +1 -1
- package/dist/viewer/camera.d.ts +82 -1
- package/dist/viewer/camera.d.ts.map +1 -1
- package/dist/viewer/components/CameraRig.d.ts +18 -1
- package/dist/viewer/components/CameraRig.d.ts.map +1 -1
- package/dist/viewer/components/LevelMeshes.d.ts +15 -4
- package/dist/viewer/components/LevelMeshes.d.ts.map +1 -1
- package/dist/viewer/components/MapScene.d.ts +10 -4
- package/dist/viewer/components/MapScene.d.ts.map +1 -1
- package/dist/viewer/components/OpeningWell.d.ts +7 -0
- package/dist/viewer/components/OpeningWell.d.ts.map +1 -0
- package/dist/viewer/components/RouteLine.d.ts.map +1 -1
- package/dist/viewer/components/SvgVectorLayer.d.ts +3 -1
- package/dist/viewer/components/SvgVectorLayer.d.ts.map +1 -1
- package/dist/viewer/components/openingGeometry.d.ts +7 -0
- package/dist/viewer/components/openingGeometry.d.ts.map +1 -0
- package/dist/viewer/index.css +151 -19
- package/dist/viewer/index.js +3 -3
- package/dist/viewer/pointer.d.ts +26 -0
- package/dist/viewer/pointer.d.ts.map +1 -0
- package/dist/viewer/ui/MapControls.d.ts.map +1 -1
- package/dist/viewer/ui/RuntimeChrome.d.ts.map +1 -1
- package/package.json +4 -2
- package/dist/chunks/graph-tools.js +0 -246
- package/dist/chunks/graph-tools.js.map +0 -1
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { ShapeKind, Vec2 } from './types';
|
|
2
|
+
/** Large fills that would otherwise cover an atrium. */
|
|
3
|
+
export declare const SLAB_SHAPE_KINDS: ShapeKind[];
|
|
4
|
+
export declare function isVoidKind(kind: string): boolean;
|
|
5
|
+
export declare function isSlabShapeKind(kind: string): boolean;
|
|
6
|
+
type VoidishShape = {
|
|
7
|
+
kind: string;
|
|
8
|
+
orphanedAt?: string | null;
|
|
9
|
+
geometry?: {
|
|
10
|
+
polygons?: Vec2[][];
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
export declare function isActiveVoidShape(shape: VoidishShape): boolean;
|
|
14
|
+
export declare function levelHasVoids(level: {
|
|
15
|
+
shapes?: VoidishShape[] | null;
|
|
16
|
+
}): boolean;
|
|
17
|
+
/** Cached polygons for every opening on a level. */
|
|
18
|
+
export declare function voidPolygonsOnLevel(level: {
|
|
19
|
+
shapes?: VoidishShape[] | null;
|
|
20
|
+
}): Vec2[][];
|
|
21
|
+
export declare function polygonSignedArea(points: Vec2[]): number;
|
|
22
|
+
/** Opposite winding so Three.js / SVG treat the ring as a hole. */
|
|
23
|
+
export declare function reversedRing(points: Vec2[]): Vec2[];
|
|
24
|
+
export declare function holeRingForOuter(outer: Vec2[], hole: Vec2[]): Vec2[];
|
|
25
|
+
export declare function polygonBBox(points: Vec2[]): {
|
|
26
|
+
minX: number;
|
|
27
|
+
minY: number;
|
|
28
|
+
maxX: number;
|
|
29
|
+
maxY: number;
|
|
30
|
+
};
|
|
31
|
+
export declare function polygonsOverlap(a: Vec2[], b: Vec2[]): boolean;
|
|
32
|
+
export declare function holesOverlappingOuter(outer: Vec2[], holes: Vec2[][]): Vec2[][];
|
|
33
|
+
/**
|
|
34
|
+
* Default / public map: dashed outline and an X through the void —
|
|
35
|
+
* the usual open-to-below mark. Edit Map is unchanged.
|
|
36
|
+
*/
|
|
37
|
+
export declare const OPENING_VOID_FILL = "#e8eef4";
|
|
38
|
+
export declare const OPENING_VOID_STROKE = "#64748b";
|
|
39
|
+
export declare const OPENING_VOID_MARK = "#475569";
|
|
40
|
+
export {};
|
|
41
|
+
//# sourceMappingURL=voids.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"voids.d.ts","sourceRoot":"","sources":["../../src/core/voids.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,IAAI,EAAE,MAAM,SAAS,CAAC;AAE/C,wDAAwD;AACxD,eAAO,MAAM,gBAAgB,EAAE,SAAS,EAQvC,CAAC;AAEF,wBAAgB,UAAU,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAEhD;AAED,wBAAgB,eAAe,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAErD;AAED,KAAK,YAAY,GAAG;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,QAAQ,CAAC,EAAE;QAAE,QAAQ,CAAC,EAAE,IAAI,EAAE,EAAE,CAAA;KAAE,CAAC;CACpC,CAAC;AAEF,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,YAAY,GAAG,OAAO,CAE9D;AAED,wBAAgB,aAAa,CAAC,KAAK,EAAE;IAAE,MAAM,CAAC,EAAE,YAAY,EAAE,GAAG,IAAI,CAAA;CAAE,GAAG,OAAO,CAEhF;AAED,oDAAoD;AACpD,wBAAgB,mBAAmB,CAAC,KAAK,EAAE;IACzC,MAAM,CAAC,EAAE,YAAY,EAAE,GAAG,IAAI,CAAC;CAChC,GAAG,IAAI,EAAE,EAAE,CASX;AAED,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,MAAM,CAMxD;AAED,mEAAmE;AACnE,wBAAgB,YAAY,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,IAAI,EAAE,CAEnD;AAED,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,IAAI,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,GAAG,IAAI,EAAE,CAKpE;AAED,wBAAgB,WAAW,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG;IAC3C,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;CACd,CAYA;AAED,wBAAgB,eAAe,CAAC,CAAC,EAAE,IAAI,EAAE,EAAE,CAAC,EAAE,IAAI,EAAE,GAAG,OAAO,CAI7D;AAED,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,IAAI,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,EAAE,GAAG,IAAI,EAAE,EAAE,CAI9E;AAED;;;GAGG;AACH,eAAO,MAAM,iBAAiB,YAAY,CAAC;AAC3C,eAAO,MAAM,mBAAmB,YAAY,CAAC;AAC7C,eAAO,MAAM,iBAAiB,YAAY,CAAC"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Wheel / trackpad zoom curve for every map surface.
|
|
3
|
+
*
|
|
4
|
+
* PORTAL default MapViewer uses drei → three-stdlib OrbitControls, whose
|
|
5
|
+
* `getZoomScale()` is `Math.pow(0.95, zoomSpeed)` **per wheel event** (not
|
|
6
|
+
* scaled by `deltaY`). Edit Map / Wayfinding must use the same step or they
|
|
7
|
+
* feel slower than the assign map.
|
|
8
|
+
*
|
|
9
|
+
* Scroll up zooms in; the caller keeps the pointer over the same map point
|
|
10
|
+
* (`panAfterZoom` on the SVG canvas, `zoomToCursor` on OrbitControls).
|
|
11
|
+
*/
|
|
12
|
+
/** three-stdlib OrbitControls `Math.pow(0.95, zoomSpeed)` base. */
|
|
13
|
+
export declare const WHEEL_ZOOM_BASE = 0.95;
|
|
14
|
+
/** drei / three-stdlib default `zoomSpeed`. */
|
|
15
|
+
export declare const WHEEL_ZOOM_SPEED = 1;
|
|
16
|
+
/**
|
|
17
|
+
* OrbitControls dolly scale for one wheel event: `0.95 ** zoomSpeed`.
|
|
18
|
+
* Sign of `deltaY` is ignored here; `nextZoomFromWheel` applies in vs out.
|
|
19
|
+
*/
|
|
20
|
+
export declare function wheelDollyScale(zoomSpeed?: number): number;
|
|
21
|
+
/**
|
|
22
|
+
* Next SVG / orthographic zoom from a wheel event.
|
|
23
|
+
* `deltaY < 0` zooms in. Pan separately so the cursor stays on the same point.
|
|
24
|
+
*/
|
|
25
|
+
export declare function nextZoomFromWheel(currentZoom: number, deltaY: number, options?: {
|
|
26
|
+
zoomSpeed?: number;
|
|
27
|
+
min?: number;
|
|
28
|
+
max?: number;
|
|
29
|
+
}): number;
|
|
30
|
+
//# sourceMappingURL=wheelZoom.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"wheelZoom.d.ts","sourceRoot":"","sources":["../../src/core/wheelZoom.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,mEAAmE;AACnE,eAAO,MAAM,eAAe,OAAO,CAAC;AACpC,+CAA+C;AAC/C,eAAO,MAAM,gBAAgB,IAAI,CAAC;AAElC;;;GAGG;AACH,wBAAgB,eAAe,CAAC,SAAS,SAAmB,GAAG,MAAM,CAEpE;AAED;;;GAGG;AACH,wBAAgB,iBAAiB,CAC/B,WAAW,EAAE,MAAM,EACnB,MAAM,EAAE,MAAM,EACd,OAAO,CAAC,EAAE;IACR,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,GAAG,CAAC,EAAE,MAAM,CAAC;CACd,GACA,MAAM,CAOR"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"FieldResetButton.d.ts","sourceRoot":"","sources":["../../src/editor/FieldResetButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAsB1B,wBAAgB,gBAAgB,CAAC,EAC/B,KAAK,EACL,OAAO,EACP,QAAQ,GACT,EAAE;IACD,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,qBAaA"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { default as React, ReactNode } from 'react';
|
|
2
|
-
import { BatchOp, MapEditorHost, PublishedDocument } from '../core';
|
|
2
|
+
import { BatchOp, MapAssignKiosk, MapAssignRetailer, MapEditorHost, PublishedDocument } from '../core';
|
|
3
3
|
import { EditorDraftState } from './draftOps';
|
|
4
4
|
import { CreateLevelInput, UpdateLevelInput } from './panels/FloorsPanel';
|
|
5
5
|
export type { EditorDraftState } from './draftOps';
|
|
@@ -21,6 +21,8 @@ export interface MapEditorProps {
|
|
|
21
21
|
canSettings?: boolean;
|
|
22
22
|
onBatch?: (ops: BatchOp[]) => Promise<void>;
|
|
23
23
|
onPublish?: () => Promise<void>;
|
|
24
|
+
/** Reload the draft from the database after discarding local edits. */
|
|
25
|
+
onDiscard?: () => Promise<void> | void;
|
|
24
26
|
onImportSvg?: (levelId: number, file: File) => Promise<void>;
|
|
25
27
|
onCreateLevel?: (input: CreateLevelInput) => Promise<number | void>;
|
|
26
28
|
onUpdateLevel?: (input: UpdateLevelInput) => Promise<void>;
|
|
@@ -28,6 +30,12 @@ export interface MapEditorProps {
|
|
|
28
30
|
onReorderLevels?: (orderedIds: number[]) => Promise<void>;
|
|
29
31
|
onAutoroute?: (levelId: number) => Promise<void>;
|
|
30
32
|
previewDocument?: PublishedDocument | null;
|
|
33
|
+
/**
|
|
34
|
+
* Center retailers for the default-map assign form (v1 retailer dropdown).
|
|
35
|
+
*/
|
|
36
|
+
retailers?: MapAssignRetailer[];
|
|
37
|
+
/** Center kiosks for leftover ID-only assignments; new kiosks are named in Assign. */
|
|
38
|
+
kiosks?: MapAssignKiosk[];
|
|
31
39
|
/**
|
|
32
40
|
* Media proxy base, same contract as v1 `IMAGE_PROXY_URL` (base + encoded
|
|
33
41
|
* URL). Required whenever the outdoor SVG is served from a origin that does
|
|
@@ -37,7 +45,9 @@ export interface MapEditorProps {
|
|
|
37
45
|
className?: string;
|
|
38
46
|
/** Quiet extra actions under the left rail (e.g. developer Classic Map). */
|
|
39
47
|
sidebarFooter?: ReactNode;
|
|
48
|
+
/** PORTAL host: pin "Use Classic Map" at the bottom of the left rail. */
|
|
49
|
+
onUseClassicMap?: () => void;
|
|
40
50
|
}
|
|
41
|
-
export declare function MapEditor({ host, draft, canEdit, canFloors, canSettings, onBatch, onPublish, onImportSvg, onCreateLevel, onUpdateLevel, onDeleteLevel, onReorderLevels, onAutoroute, previewDocument, imageProxyUrl, className, sidebarFooter, }: MapEditorProps): React.JSX.Element;
|
|
51
|
+
export declare function MapEditor({ host, draft, canEdit, canFloors, canSettings, onBatch, onPublish, onDiscard, onImportSvg, onCreateLevel, onUpdateLevel, onDeleteLevel, onReorderLevels, onAutoroute, previewDocument, retailers, kiosks, imageProxyUrl, className, sidebarFooter, onUseClassicMap, }: MapEditorProps): React.JSX.Element;
|
|
42
52
|
export default MapEditor;
|
|
43
53
|
//# sourceMappingURL=MapEditor.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MapEditor.d.ts","sourceRoot":"","sources":["../../src/editor/MapEditor.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAMZ,KAAK,SAAS,EACf,MAAM,OAAO,CAAC;AACf,OAAO,KAAK,EACV,OAAO,
|
|
1
|
+
{"version":3,"file":"MapEditor.d.ts","sourceRoot":"","sources":["../../src/editor/MapEditor.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAMZ,KAAK,SAAS,EACf,MAAM,OAAO,CAAC;AACf,OAAO,KAAK,EACV,OAAO,EAEP,cAAc,EACd,iBAAiB,EACjB,aAAa,EACb,iBAAiB,EAElB,MAAM,SAAS,CAAC;AAmBjB,OAAO,EAKL,KAAK,gBAAgB,EACtB,MAAM,YAAY,CAAC;AAGpB,OAAO,KAAK,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC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,CAAC,EAAE,iBAAiB,GAAG,IAAI,CAAC;IAC3C;;OAEG;IACH,SAAS,CAAC,EAAE,iBAAiB,EAAE,CAAC;IAChC,sFAAsF;IACtF,MAAM,CAAC,EAAE,cAAc,EAAE,CAAC;IAC1B;;;;OAIG;IACH,aAAa,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC9B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,4EAA4E;IAC5E,aAAa,CAAC,EAAE,SAAS,CAAC;IAC1B,yEAAyE;IACzE,eAAe,CAAC,EAAE,MAAM,IAAI,CAAC;CAC9B;AAED,wBAAgB,SAAS,CAAC,EACxB,IAAe,EACf,KAAK,EACL,OAAc,EACd,SAAgB,EAChB,WAAkB,EAClB,OAAO,EACP,SAAS,EACT,SAAS,EACT,WAAW,EACX,aAAa,EACb,aAAa,EACb,aAAa,EACb,eAAe,EACf,WAAW,EACX,eAAe,EACf,SAAc,EACd,MAAW,EACX,aAAa,EACb,SAAS,EACT,aAAa,EACb,eAAe,GAChB,EAAE,cAAc,qBA+vChB;AAED,eAAe,SAAS,CAAC"}
|
|
@@ -16,8 +16,8 @@ export interface EditorCanvasProps {
|
|
|
16
16
|
baseSvgUrl: string | null;
|
|
17
17
|
baseViewbox?: ViewBox | null;
|
|
18
18
|
/**
|
|
19
|
-
* Live outdoor SVG. Drawn on every Edit Map floor (and
|
|
20
|
-
* green areas, parking lanes, and icons match the assign view.
|
|
19
|
+
* Live outdoor SVG. Drawn on every Edit Map and Wayfinding floor (and
|
|
20
|
+
* Outdoor) so green areas, parking lanes, and icons match the assign view.
|
|
21
21
|
*/
|
|
22
22
|
outdoorSvgUrl?: string | null;
|
|
23
23
|
/** Same proxy as MapViewer — required when the SVG is cross-origin. */
|
|
@@ -26,6 +26,8 @@ export interface EditorCanvasProps {
|
|
|
26
26
|
levelSvgUrl?: string | null;
|
|
27
27
|
/** Outdoor/base shapes drawn behind the active building floor (non-interactive). */
|
|
28
28
|
underlayShapes?: CmShape[];
|
|
29
|
+
/** Floor below, clipped to openings so Edit Map previews the atrium. */
|
|
30
|
+
openingUnderlayShapes?: CmShape[];
|
|
29
31
|
/** When true (outdoor), only interactive shapes are editable. */
|
|
30
32
|
interactiveOnly?: boolean;
|
|
31
33
|
/** Graph-paper grid. PORTAL only mounts this canvas after Edit Map. */
|
|
@@ -61,6 +63,8 @@ export interface EditorCanvasProps {
|
|
|
61
63
|
onBatchShapeEdits?: (edits: ShapeBatchEdit[]) => void;
|
|
62
64
|
/** End a live drag so the next edit starts a new undo step. */
|
|
63
65
|
onHistoryGestureEnd?: () => void;
|
|
66
|
+
/** Shown when no floor or Outdoor is selected. */
|
|
67
|
+
emptyMessage?: string;
|
|
64
68
|
}
|
|
65
69
|
export interface EditorCanvasHandle {
|
|
66
70
|
consumeRouteUndo: () => 'clear-only' | 'clear-and-undo';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EditorCanvas.d.ts","sourceRoot":"","sources":["../../../src/editor/canvas/EditorCanvas.tsx"],"names":[],"mappings":"AAAA,OAAO,KAON,MAAM,OAAO,CAAC;AACf,OAAO,KAAK,EACV,QAAQ,EACR,OAAO,EACP,WAAW,EACX,OAAO,EACP,iBAAiB,EACjB,aAAa,EACb,SAAS,EACT,UAAU,EACV,aAAa,EACb,IAAI,EACJ,OAAO,EACR,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"EditorCanvas.d.ts","sourceRoot":"","sources":["../../../src/editor/canvas/EditorCanvas.tsx"],"names":[],"mappings":"AAAA,OAAO,KAON,MAAM,OAAO,CAAC;AACf,OAAO,KAAK,EACV,QAAQ,EACR,OAAO,EACP,WAAW,EACX,OAAO,EACP,iBAAiB,EACjB,aAAa,EACb,SAAS,EACT,UAAU,EACV,aAAa,EACb,IAAI,EACJ,OAAO,EACR,MAAM,YAAY,CAAC;AAWpB,OAAO,EAaL,KAAK,UAAU,EAChB,MAAM,UAAU,CAAC;AAClB,OAAO,EAWL,KAAK,cAAc,EA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,aAAa,EACvB,IAAI,CAAC,EAAE;QAAE,IAAI,CAAC,EAAE,OAAO,CAAA;KAAE,KACtB,IAAI,CAAC;IACV,iBAAiB,CAAC,EAAE,CAAC,KAAK,EAAE,cAAc,EAAE,KAAK,IAAI,CAAC;IACtD,+DAA+D;IAC/D,mBAAmB,CAAC,EAAE,MAAM,IAAI,CAAC;IACjC,kDAAkD;IAClD,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,WAAW,kBAAkB;IACjC,gBAAgB,EAAE,MAAM,YAAY,GAAG,gBAAgB,CAAC;IACxD,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,SAAS,EAAE,MAAM,IAAI,CAAC;CACvB;AAqBD,eAAO,MAAM,YAAY,8FA+rFvB,CAAC"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
-
export declare function OutdoorSvgUnderlay({ url, imageProxyUrl, suppressIds, }: {
|
|
2
|
+
export declare function OutdoorSvgUnderlay({ url, imageProxyUrl, suppressIds, theme, }: {
|
|
3
3
|
url: string;
|
|
4
4
|
imageProxyUrl?: string | null;
|
|
5
5
|
suppressIds?: ReadonlySet<string>;
|
|
6
|
+
theme?: Partial<Record<string, string>> | null;
|
|
6
7
|
}): React.JSX.Element | null;
|
|
7
8
|
//# sourceMappingURL=OutdoorSvgUnderlay.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"OutdoorSvgUnderlay.d.ts","sourceRoot":"","sources":["../../../src/editor/canvas/OutdoorSvgUnderlay.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAuC,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"OutdoorSvgUnderlay.d.ts","sourceRoot":"","sources":["../../../src/editor/canvas/OutdoorSvgUnderlay.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAuC,MAAM,OAAO,CAAC;AAG5D,wBAAgB,kBAAkB,CAAC,EACjC,GAAG,EACH,aAAa,EACb,WAAW,EACX,KAAK,GACN,EAAE;IACD,GAAG,EAAE,MAAM,CAAC;IACZ,aAAa,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC9B,WAAW,CAAC,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IAClC,KAAK,CAAC,EAAE,OAAO,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,GAAG,IAAI,CAAC;CAChD,4BA4DA"}
|
|
@@ -8,20 +8,43 @@ export interface Affine2 {
|
|
|
8
8
|
e: number;
|
|
9
9
|
f: number;
|
|
10
10
|
}
|
|
11
|
+
export interface ViewBoxRect {
|
|
12
|
+
x: number;
|
|
13
|
+
y: number;
|
|
14
|
+
width: number;
|
|
15
|
+
height: number;
|
|
16
|
+
}
|
|
17
|
+
export interface ClientRectLike {
|
|
18
|
+
left: number;
|
|
19
|
+
top: number;
|
|
20
|
+
width: number;
|
|
21
|
+
height: number;
|
|
22
|
+
}
|
|
11
23
|
/**
|
|
12
24
|
* Map a client (CSS pixel) point through the inverse of an SVG screen CTM.
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
* canvas CSS box (or letterboxed by preserveAspectRatio).
|
|
25
|
+
* Prefer {@link clientRectToViewBox} for pointer mapping — `getScreenCTM()` on
|
|
26
|
+
* the root `<svg>` is wrong inside transformed admin-portal layout.
|
|
16
27
|
*/
|
|
17
28
|
export declare function clientToUser(ctm: Affine2, clientX: number, clientY: number): Vec2;
|
|
29
|
+
/**
|
|
30
|
+
* Viewport point → SVG viewBox user space, same method OrbitControls uses
|
|
31
|
+
* (`getBoundingClientRect` + letterboxed viewBox). Default map zoom-to-cursor
|
|
32
|
+
* works in admin-portal because of this; Edit Map must not use `getScreenCTM()`.
|
|
33
|
+
*
|
|
34
|
+
* Assumes `preserveAspectRatio="xMidYMid meet"` (editor canvas default).
|
|
35
|
+
*/
|
|
36
|
+
export declare function clientRectToViewBox(rect: ClientRectLike, viewBox: ViewBoxRect, clientX: number, clientY: number): Vec2;
|
|
37
|
+
export declare function pxPerUserFromViewBox(rect: ClientRectLike, viewBox: ViewBoxRect): number;
|
|
18
38
|
export declare function clientToSvgUser(svg: SVGSVGElement, clientX: number, clientY: number): Vec2;
|
|
39
|
+
export declare function pxPerUserFromSvg(svg: SVGSVGElement): number;
|
|
19
40
|
/** Invert `translate(pan) scale(zoom)` so a user-space point becomes world geometry. */
|
|
20
41
|
export declare function userToWorld(user: Vec2, pan: Vec2, zoom: number): Vec2;
|
|
21
42
|
export declare const EDITOR_MIN_ZOOM = 0.2;
|
|
22
43
|
/** High enough that designers can park on a single storefront or route node. */
|
|
23
44
|
export declare const EDITOR_MAX_ZOOM = 128;
|
|
24
45
|
export declare function clampEditorZoom(zoom: number): number;
|
|
46
|
+
/** Same per-event step as PORTAL default MapViewer (three-stdlib OrbitControls). */
|
|
47
|
+
export declare function nextEditorZoomFromWheel(currentZoom: number, event: Pick<WheelEvent, 'deltaY'>): number;
|
|
25
48
|
/** CSS pixels per SVG user unit from a screen CTM (ignores translation). */
|
|
26
49
|
export declare function pxPerUserFromCtm(ctm: Affine2): number;
|
|
27
50
|
/** World-space length that draws as `px` CSS pixels after `scale(zoom)`. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coords.d.ts","sourceRoot":"","sources":["../../../src/editor/canvas/coords.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"coords.d.ts","sourceRoot":"","sources":["../../../src/editor/canvas/coords.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;AAGvC,wEAAwE;AACxE,MAAM,WAAW,OAAO;IACtB,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;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AAE,MAAM,YAAY,CAAC;AAG3D,+EAA+E;AAC/E,wBAAgB,sBAAsB,CAAC,IAAI,EAAE,SAAS,GAAG,MAAM,
|
|
1
|
+
{"version":3,"file":"editorFill.d.ts","sourceRoot":"","sources":["../../../src/editor/canvas/editorFill.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAG3D,+EAA+E;AAC/E,wBAAgB,sBAAsB,CAAC,IAAI,EAAE,SAAS,GAAG,MAAM,CAK9D;AAED,wBAAgB,eAAe,CAC7B,KAAK,EAAE;IAAE,IAAI,EAAE,SAAS,CAAC;IAAC,KAAK,CAAC,EAAE;QAAE,IAAI,CAAC,EAAE,MAAM,CAAA;KAAE,CAAA;CAAE,EACrD,KAAK,EAAE,aAAa,EACpB,UAAU,CAAC,EAAE;IAAE,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;CAAE,GAAG,IAAI,GAC9C,MAAM,CAOR"}
|
|
@@ -9,6 +9,10 @@ export declare function editorSelectCursor(args: {
|
|
|
9
9
|
dragging?: boolean;
|
|
10
10
|
/** Wayfinding: + cursor — click places an orange store destination. */
|
|
11
11
|
wayfinding?: boolean;
|
|
12
|
+
/** Map text placed with the Text tool. */
|
|
13
|
+
textLabel?: boolean;
|
|
14
|
+
/** Entrance stamp placed with the Entrance tool. */
|
|
15
|
+
entranceIcon?: boolean;
|
|
12
16
|
}): 'pointer' | 'grab' | 'grabbing' | 'cell' | undefined;
|
|
13
17
|
export declare function editorHoverFillOpacity(kind: ShapeKind, base: number, hovered: boolean): number;
|
|
14
18
|
//# sourceMappingURL=editorHover.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"editorHover.d.ts","sourceRoot":"","sources":["../../../src/editor/canvas/editorHover.ts"],"names":[],"mappings":"AAAA,OAAO,EAA2B,KAAK,SAAS,EAAE,MAAM,YAAY,CAAC;AACrE,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"editorHover.d.ts","sourceRoot":"","sources":["../../../src/editor/canvas/editorHover.ts"],"names":[],"mappings":"AAAA,OAAO,EAA2B,KAAK,SAAS,EAAE,MAAM,YAAY,CAAC;AACrE,OAAO,EAAoC,KAAK,UAAU,EAAE,MAAM,UAAU,CAAC;AAE7E,iFAAiF;AACjF,wBAAgB,qBAAqB,CAAC,IAAI,EAAE,SAAS,GAAG,OAAO,CAE9D;AAED,wBAAgB,kBAAkB,CAAC,IAAI,EAAE;IACvC,IAAI,EAAE,UAAU,CAAC;IACjB,QAAQ,EAAE,OAAO,CAAC;IAClB,aAAa,EAAE,OAAO,CAAC;IACvB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,uEAAuE;IACvE,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,0CAA0C;IAC1C,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,oDAAoD;IACpD,YAAY,CAAC,EAAE,OAAO,CAAC;CACxB,GAAG,SAAS,GAAG,MAAM,GAAG,UAAU,GAAG,MAAM,GAAG,SAAS,CAgBvD;AAED,wBAAgB,sBAAsB,CACpC,IAAI,EAAE,SAAS,EACf,IAAI,EAAE,MAAM,EACZ,OAAO,EAAE,OAAO,GACf,MAAM,CAGR"}
|
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
import { ShapeKind } from '../../core';
|
|
2
2
|
/** Outdoor underlay items that look clickable on a floor. */
|
|
3
3
|
export declare function isUnderlayHintShape(kind: ShapeKind): boolean;
|
|
4
|
+
/** Text and entrance hit-boxes stay on Outdoor — do not ghost them onto building floors. */
|
|
5
|
+
export declare function isUnderlayDrawnShape(shape: {
|
|
6
|
+
kind: string;
|
|
7
|
+
label?: {
|
|
8
|
+
text?: string;
|
|
9
|
+
imageKey?: string | null;
|
|
10
|
+
} | null;
|
|
11
|
+
}): boolean;
|
|
4
12
|
export declare function underlaySwitchHint(kind: ShapeKind): string;
|
|
5
13
|
//# sourceMappingURL=underlayHint.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"underlayHint.d.ts","sourceRoot":"","sources":["../../../src/editor/canvas/underlayHint.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"underlayHint.d.ts","sourceRoot":"","sources":["../../../src/editor/canvas/underlayHint.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAI5C,6DAA6D;AAC7D,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,SAAS,GAAG,OAAO,CAE5D;AAED,4FAA4F;AAC5F,wBAAgB,oBAAoB,CAAC,KAAK,EAAE;IAC1C,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE;QAAE,IAAI,CAAC,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;KAAE,GAAG,IAAI,CAAC;CAC5D,GAAG,OAAO,CAEV;AAED,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,SAAS,GAAG,MAAM,CAW1D"}
|
|
@@ -37,6 +37,67 @@ export declare function defaultConnectorName(kind: VerticalRailKind, shapes: Arr
|
|
|
37
37
|
}>): string;
|
|
38
38
|
export declare function nearestWalkAnchor(anchors: CmAnchor[], levelId: number, point: Vec2, excludeIds?: ReadonlySet<number>): CmAnchor | null;
|
|
39
39
|
export declare function memberShapeIds(connectorId: number, anchors: Array<Pick<CmAnchor, 'shapeId' | 'connectorId'>>): number[];
|
|
40
|
+
export type ConnectorEdgeLike = Pick<CmRouteEdge, 'kind' | 'directed' | 'fromAnchorId' | 'toAnchorId'>;
|
|
41
|
+
export type ConnectorAnchorLike = Pick<CmAnchor, 'id' | 'shapeId' | 'connectorId'>;
|
|
42
|
+
export declare function partnerShapesForConnector<T extends {
|
|
43
|
+
id: number;
|
|
44
|
+
}>(shapeId: number, anchors: ConnectorAnchorLike[], connectors: CmConnector[], shapes: T[]): T[];
|
|
45
|
+
export declare function levelsWithLandings<T extends {
|
|
46
|
+
levelId: number;
|
|
47
|
+
}>(landings: T[], levels: CmLevel[]): CmLevel[];
|
|
48
|
+
export declare function escalatorDirectedEnds<T extends {
|
|
49
|
+
id: number;
|
|
50
|
+
}>(connectorId: number, anchors: ConnectorAnchorLike[], edges: ConnectorEdgeLike[], shapes: T[]): {
|
|
51
|
+
from: T;
|
|
52
|
+
to: T;
|
|
53
|
+
} | null;
|
|
54
|
+
export type EscalatorRideEnds<T extends {
|
|
55
|
+
id: number;
|
|
56
|
+
key: string;
|
|
57
|
+
levelId: number;
|
|
58
|
+
}> = {
|
|
59
|
+
connectorId: number;
|
|
60
|
+
from: T;
|
|
61
|
+
to: T;
|
|
62
|
+
};
|
|
63
|
+
export type EscalatorRideLandingLine = {
|
|
64
|
+
shapeId: number;
|
|
65
|
+
key: string;
|
|
66
|
+
levelName: string;
|
|
67
|
+
};
|
|
68
|
+
/**
|
|
69
|
+
* One sidebar row per linked ride. Boarding is `from`, exit is `to`.
|
|
70
|
+
* Unlinked landings are omitted — they stay in the Unassigned list.
|
|
71
|
+
*/
|
|
72
|
+
export declare function groupEscalatorRides<T extends {
|
|
73
|
+
id: number;
|
|
74
|
+
key: string;
|
|
75
|
+
levelId: number;
|
|
76
|
+
}>(connectors: Array<Pick<CmConnector, 'id' | 'kind'>>, anchors: ConnectorAnchorLike[], edges: ConnectorEdgeLike[], shapes: T[]): EscalatorRideEnds<T>[];
|
|
77
|
+
/** Boarding on top, exit below — each with its floor name. */
|
|
78
|
+
export declare function escalatorRideLandingLines<T extends {
|
|
79
|
+
id: number;
|
|
80
|
+
key: string;
|
|
81
|
+
levelId: number;
|
|
82
|
+
}>(ride: EscalatorRideEnds<T>, levels: Array<{
|
|
83
|
+
id: number;
|
|
84
|
+
name: string;
|
|
85
|
+
}>): [EscalatorRideLandingLine, EscalatorRideLandingLine];
|
|
86
|
+
/** Assigned-list title: boarding → exit (escalator) or floor landings ↔ (elevator). */
|
|
87
|
+
export declare function connectorRideLabel(shape: {
|
|
88
|
+
id: number;
|
|
89
|
+
key: string;
|
|
90
|
+
levelId: number;
|
|
91
|
+
}, anchors: ConnectorAnchorLike[], edges: ConnectorEdgeLike[], connectors: CmConnector[], shapes: Array<{
|
|
92
|
+
id: number;
|
|
93
|
+
key: string;
|
|
94
|
+
levelId: number;
|
|
95
|
+
}>, levels?: Array<{
|
|
96
|
+
id: number;
|
|
97
|
+
name: string;
|
|
98
|
+
ordering?: number;
|
|
99
|
+
levelIndex?: number;
|
|
100
|
+
}>): string | null;
|
|
40
101
|
export interface ConnectorPlanContext {
|
|
41
102
|
mapId: number;
|
|
42
103
|
levels: CmLevel[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"connectorAssignments.d.ts","sourceRoot":"","sources":["../../src/editor/connectorAssignments.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,OAAO,EACP,QAAQ,EACR,WAAW,EACX,OAAO,EACP,WAAW,EACX,OAAO,EACP,kBAAkB,EAClB,aAAa,EACb,IAAI,EACL,MAAM,SAAS,CAAC;AAGjB,MAAM,MAAM,gBAAgB,GAAG,WAAW,GAAG,UAAU,CAAC;AAExD,MAAM,WAAW,qBAAqB;IACpC,MAAM,EAAE,aAAa,CAAC;IACtB,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,CAAC,EAAE,IAAI,GAAG,MAAM,CAAC;IAC1B,IAAI,CAAC,EAAE,OAAO,GAAG,KAAK,CAAC;CACxB;AAcD,gEAAgE;AAChE,wBAAgB,sBAAsB,CACpC,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,GAC/B,qBAAqB,GAAG,IAAI,CAuB9B;AAED,wBAAgB,kBAAkB,CAAC,KAAK,EAAE;IACxC,IAAI,EAAE,MAAM,CAAC;IACb,GAAG,EAAE,MAAM,CAAC;IACZ,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CAC7B,GAAG,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EAChB,OAAO,CAAC,EAAE;IAAE,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,SAAS,CAAC,EAAE,IAAI,GAAG,MAAM,CAAA;CAAE,GACrD,OAAO,EAAE,CA0DX;AAED,wBAAgB,qBAAqB,CACnC,GAAG,EAAE,oBAAoB,EACzB,YAAY,EAAE,OAAO,EAAE,EACvB,OAAO,CAAC,EAAE;IAAE,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,UAAU,CAAC,EAAE,OAAO,CAAC;IAAC,WAAW,CAAC,EAAE,MAAM,CAAA;CAAE,GACtE,OAAO,EAAE,CAkEX;AAED,wBAAgB,qBAAqB,CACnC,MAAM,EAAE,OAAO,EAAE,EACjB,MAAM,EAAE,OAAO,EAAE,EACjB,OAAO,EAAE,KAAK,CAAC,IAAI,CAAC,QAAQ,EAAE,SAAS,GAAG,aAAa,CAAC,CAAC,GACxD,KAAK,CAAC;IAAE,WAAW,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC,CAkClE"}
|
|
1
|
+
{"version":3,"file":"connectorAssignments.d.ts","sourceRoot":"","sources":["../../src/editor/connectorAssignments.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,OAAO,EACP,QAAQ,EACR,WAAW,EACX,OAAO,EACP,WAAW,EACX,OAAO,EACP,kBAAkB,EAClB,aAAa,EACb,IAAI,EACL,MAAM,SAAS,CAAC;AAGjB,MAAM,MAAM,gBAAgB,GAAG,WAAW,GAAG,UAAU,CAAC;AAExD,MAAM,WAAW,qBAAqB;IACpC,MAAM,EAAE,aAAa,CAAC;IACtB,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,CAAC,EAAE,IAAI,GAAG,MAAM,CAAC;IAC1B,IAAI,CAAC,EAAE,OAAO,GAAG,KAAK,CAAC;CACxB;AAcD,gEAAgE;AAChE,wBAAgB,sBAAsB,CACpC,KAAK,EAAE,MAAM,GAAG,IAAI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E,CAAC;IACpB,KAAK,EAAE,WAAW,EAAE,CAAC;IACrB,UAAU,EAAE,WAAW,EAAE,CAAC;IAC1B,OAAO,EAAE,MAAM,MAAM,CAAC;CACvB;AA+FD,wBAAgB,uBAAuB,CACrC,GAAG,EAAE,oBAAoB,EACzB,WAAW,EAAE,MAAM,GAClB,OAAO,EAAE,CAEX;AAED,wBAAgB,qBAAqB,CACnC,GAAG,EAAE,oBAAoB,EACzB,SAAS,EAAE,OAAO,EAClB,OAAO,EAAE,OAAO,EAChB,OAAO,CAAC,EAAE;IAAE,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,SAAS,CAAC,EAAE,IAAI,GAAG,MAAM,CAAA;CAAE,GACrD,OAAO,EAAE,CA0DX;AAED,wBAAgB,qBAAqB,CACnC,GAAG,EAAE,oBAAoB,EACzB,YAAY,EAAE,OAAO,EAAE,EACvB,OAAO,CAAC,EAAE;IAAE,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,UAAU,CAAC,EAAE,OAAO,CAAC;IAAC,WAAW,CAAC,EAAE,MAAM,CAAA;CAAE,GACtE,OAAO,EAAE,CAkEX;AAED,wBAAgB,qBAAqB,CACnC,MAAM,EAAE,OAAO,EAAE,EACjB,MAAM,EAAE,OAAO,EAAE,EACjB,OAAO,EAAE,KAAK,CAAC,IAAI,CAAC,QAAQ,EAAE,SAAS,GAAG,aAAa,CAAC,CAAC,GACxD,KAAK,CAAC;IAAE,WAAW,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC,CAkClE"}
|
|
@@ -13,10 +13,18 @@ export interface EditorDraftState {
|
|
|
13
13
|
amenities: CmAmenityCatalogItem[];
|
|
14
14
|
baseSvgUrl?: string | null;
|
|
15
15
|
}
|
|
16
|
+
/** True when another live shape already uses this ID on the floor. */
|
|
17
|
+
export declare function shapeKeyTakenOnLevel(shapes: Array<{
|
|
18
|
+
id: number;
|
|
19
|
+
levelId: number;
|
|
20
|
+
key: string;
|
|
21
|
+
orphanedAt?: string | null;
|
|
22
|
+
}>, shapeId: number, levelId: number, key: string): boolean;
|
|
16
23
|
export declare function applyDraftOp(draft: EditorDraftState, op: BatchOp): EditorDraftState;
|
|
17
24
|
/** Drop a floor/outdoor level and every draft row that lived on it. */
|
|
18
25
|
export declare function omitLevelFromDraft(draft: EditorDraftState, levelId: number): EditorDraftState;
|
|
19
26
|
export declare function applyDraftOps(draft: EditorDraftState, ops: BatchOp[]): EditorDraftState;
|
|
20
27
|
/** Collapse repeated updates to the same entity so Save Changes sends one op each. */
|
|
21
28
|
export declare function coalesceDraftOp(ops: BatchOp[], op: BatchOp): BatchOp[];
|
|
29
|
+
export declare function orderBatchOpsForPersist(ops: BatchOp[]): BatchOp[];
|
|
22
30
|
//# sourceMappingURL=draftOps.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"draftOps.d.ts","sourceRoot":"","sources":["../../src/editor/draftOps.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,OAAO,EAEP,oBAAoB,EACpB,QAAQ,EACR,UAAU,EACV,WAAW,EACX,OAAO,EACP,WAAW,EACX,OAAO,EACP,iBAAiB,EAEjB,aAAa,EACd,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"draftOps.d.ts","sourceRoot":"","sources":["../../src/editor/draftOps.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,OAAO,EAEP,oBAAoB,EACpB,QAAQ,EACR,UAAU,EACV,WAAW,EACX,OAAO,EACP,WAAW,EACX,OAAO,EACP,iBAAiB,EAEjB,aAAa,EACd,MAAM,SAAS,CAAC;AAQjB,MAAM,WAAW,gBAAgB;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,OAAO,CAAC,aAAa,CAAC,CAAC;IAC9B,SAAS,EAAE,UAAU,EAAE,CAAC;IACxB,MAAM,EAAE,OAAO,EAAE,CAAC;IAClB,MAAM,EAAE,OAAO,EAAE,CAAC;IAClB,WAAW,EAAE,iBAAiB,EAAE,CAAC;IACjC,OAAO,EAAE,QAAQ,EAAE,CAAC;IACpB,KAAK,EAAE,WAAW,EAAE,CAAC;IACrB,UAAU,EAAE,WAAW,EAAE,CAAC;IAC1B,SAAS,EAAE,oBAAoB,EAAE,CAAC;IAClC,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CAC5B;AAOD,sEAAsE;AACtE,wBAAgB,oBAAoB,CAClC,MAAM,EAAE,KAAK,CAAC;IACZ,EAAE,EAAE,MAAM,CAAC;IACX,OAAO,EAAE,MAAM,CAAC;IAChB,GAAG,EAAE,MAAM,CAAC;IACZ,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CAC5B,CAAC,EACF,OAAO,EAAE,MAAM,EACf,OAAO,EAAE,MAAM,EACf,GAAG,EAAE,MAAM,GACV,OAAO,CAQT;AAaD,wBAAgB,YAAY,CAC1B,KAAK,EAAE,gBAAgB,EACvB,EAAE,EAAE,OAAO,GACV,gBAAgB,CAoJlB;AAED,uEAAuE;AACvE,wBAAgB,kBAAkB,CAChC,KAAK,EAAE,gBAAgB,EACvB,OAAO,EAAE,MAAM,GACd,gBAAgB,CA0BlB;AAED,wBAAgB,aAAa,CAC3B,KAAK,EAAE,gBAAgB,EACvB,GAAG,EAAE,OAAO,EAAE,GACb,gBAAgB,CAMlB;AAiBD,sFAAsF;AACtF,wBAAgB,eAAe,CAAC,GAAG,EAAE,OAAO,EAAE,EAAE,EAAE,EAAE,OAAO,GAAG,OAAO,EAAE,CAmEtE;AA0BD,wBAAgB,uBAAuB,CAAC,GAAG,EAAE,OAAO,EAAE,GAAG,OAAO,EAAE,CAQjE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"editorSectionReturn.d.ts","sourceRoot":"","sources":["../../src/editor/editorSectionReturn.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"editorSectionReturn.d.ts","sourceRoot":"","sources":["../../src/editor/editorSectionReturn.ts"],"names":[],"mappings":"AAGA,MAAM,MAAM,qBAAqB,GAAG;IAClC,OAAO,EAAE,UAAU,GAAG,YAAY,CAAC;IACnC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;CACxB,CAAC;AAYF;;;GAGG;AACH,wBAAgB,iBAAiB,CAC/B,KAAK,EAAE,MAAM,EACb,QAAQ,EAAE,qBAAqB,GAC9B,IAAI,CAQN;AAED,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,MAAM,GAAG,qBAAqB,GAAG,IAAI,CAG7E;AAED,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAGtD"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ShapeGeometry, Vec2 } from '../core';
|
|
2
|
+
export interface EllipseBounds {
|
|
3
|
+
cx: number;
|
|
4
|
+
cy: number;
|
|
5
|
+
rx: number;
|
|
6
|
+
ry: number;
|
|
7
|
+
}
|
|
8
|
+
/** Drag from corner `from` to `to`. Shift / lockCircle keeps rx === ry. */
|
|
9
|
+
export declare function ellipseBoundsFromDrag(from: Vec2, to: Vec2, lockCircle?: boolean): EllipseBounds;
|
|
10
|
+
export declare function ellipsePathD(bounds: EllipseBounds): string;
|
|
11
|
+
export declare function ellipseGeometry(from: Vec2, to: Vec2, lockCircle?: boolean): ShapeGeometry;
|
|
12
|
+
//# sourceMappingURL=ellipseDraw.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ellipseDraw.d.ts","sourceRoot":"","sources":["../../src/editor/ellipseDraw.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,IAAI,EAAE,MAAM,SAAS,CAAC;AAGnD,MAAM,WAAW,aAAa;IAC5B,EAAE,EAAE,MAAM,CAAC;IACX,EAAE,EAAE,MAAM,CAAC;IACX,EAAE,EAAE,MAAM,CAAC;IACX,EAAE,EAAE,MAAM,CAAC;CACZ;AAED,2EAA2E;AAC3E,wBAAgB,qBAAqB,CACnC,IAAI,EAAE,IAAI,EACV,EAAE,EAAE,IAAI,EACR,UAAU,UAAQ,GACjB,aAAa,CAoBf;AAED,wBAAgB,YAAY,CAAC,MAAM,EAAE,aAAa,GAAG,MAAM,CAK1D;AAED,wBAAgB,eAAe,CAC7B,IAAI,EAAE,IAAI,EACV,EAAE,EAAE,IAAI,EACR,UAAU,UAAQ,GACjB,aAAa,CAIf"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { ShapeGeometry, ShapeLabel, Vec2, DEFAULT_ENTRANCE_SIZE, ENTRANCE_ICON_ID, clampEntranceSize, isEntranceIcon } from '../core';
|
|
2
|
+
export { DEFAULT_ENTRANCE_SIZE, ENTRANCE_ICON_ID, clampEntranceSize, isEntranceIcon, };
|
|
3
|
+
export declare function isStampShape(shape: {
|
|
4
|
+
kind: string;
|
|
5
|
+
label?: {
|
|
6
|
+
text?: string;
|
|
7
|
+
imageKey?: string | null;
|
|
8
|
+
} | null;
|
|
9
|
+
}): boolean;
|
|
10
|
+
export declare function defaultEntranceLabel(size: number, color?: string): ShapeLabel;
|
|
11
|
+
export declare function entranceIconPolygon(center: Vec2, size: number): Vec2[];
|
|
12
|
+
export declare function entranceIconGeometry(center: Vec2, size: number): ShapeGeometry;
|
|
13
|
+
/** Keep the icon centred when Size changes. */
|
|
14
|
+
export declare function geometryForEntranceIcon(geometry: ShapeGeometry, size: number): ShapeGeometry;
|
|
15
|
+
//# sourceMappingURL=entranceIcon.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"entranceIcon.d.ts","sourceRoot":"","sources":["../../src/editor/entranceIcon.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,UAAU,EAAE,IAAI,EAAE,MAAM,SAAS,CAAC;AAC/D,OAAO,EACL,qBAAqB,EACrB,gBAAgB,EAChB,iBAAiB,EAEjB,cAAc,EACf,MAAM,SAAS,CAAC;AAIjB,OAAO,EACL,qBAAqB,EACrB,gBAAgB,EAChB,iBAAiB,EACjB,cAAc,GACf,CAAC;AAEF,wBAAgB,YAAY,CAAC,KAAK,EAAE;IAClC,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE;QAAE,IAAI,CAAC,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;KAAE,GAAG,IAAI,CAAC;CAC5D,GAAG,OAAO,CAEV;AAED,wBAAgB,oBAAoB,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,MAAM,GAAG,UAAU,CAO7E;AAED,wBAAgB,mBAAmB,CAAC,MAAM,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,GAAG,IAAI,EAAE,CAQtE;AAED,wBAAgB,oBAAoB,CAAC,MAAM,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,GAAG,aAAa,CAE9E;AAED,+CAA+C;AAC/C,wBAAgB,uBAAuB,CACrC,QAAQ,EAAE,aAAa,EACvB,IAAI,EAAE,MAAM,GACX,aAAa,CAEf"}
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
+
export { isTransparentColor, TRANSPARENT_COLOR } from '../core/color';
|
|
1
2
|
/** Normalize `#rgb` / `#rrggbb` (with or without `#`) for `<input type="color">`. */
|
|
2
3
|
export declare function normalizeHexColor(value: string): string | null;
|
|
3
4
|
export declare function hexColorInputValue(value: string): string;
|
|
5
|
+
export declare function sameHexColor(a: string, b: string): boolean;
|
|
4
6
|
//# sourceMappingURL=hexColor.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"hexColor.d.ts","sourceRoot":"","sources":["../../src/editor/hexColor.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"hexColor.d.ts","sourceRoot":"","sources":["../../src/editor/hexColor.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,kBAAkB,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAEtE,qFAAqF;AACrF,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAW9D;AAED,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAExD;AAED,wBAAgB,YAAY,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,GAAG,OAAO,CAO1D"}
|