@element-editor/ui 0.0.0-stage → 0.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.
Files changed (244) hide show
  1. package/AGENTS.md +65 -0
  2. package/LICENSE +21 -0
  3. package/README.md +46 -2
  4. package/dist/BooleanOperations-BRO7NHUY.js +111 -0
  5. package/dist/BooleanOperations-C2uOHRu3.cjs +1 -0
  6. package/dist/DataTable-B-2VjBEz.cjs +2 -0
  7. package/dist/DataTable-CS-3dIqY.js +510 -0
  8. package/dist/DataTablePanel-58LwzXQR.cjs +1 -0
  9. package/dist/DataTablePanel-DDFUmMaM.js +208 -0
  10. package/dist/EditToolbarBtn-Ch9HCLHq.cjs +3 -0
  11. package/dist/EditToolbarBtn-SR4xHd8G.js +378 -0
  12. package/dist/FeatureEditModal-Cc8N6vei.cjs +1 -0
  13. package/dist/FeatureEditModal-Dr10p3nE.js +77 -0
  14. package/dist/FeatureList-Bo9w9nre.js +520 -0
  15. package/dist/FeatureList-VRYesXCq.cjs +1 -0
  16. package/dist/FeatureRowContextMenu-CtBqdC1j.cjs +1 -0
  17. package/dist/FeatureRowContextMenu-DCUIiDwc.js +130 -0
  18. package/dist/GeoJSONModal-BV9Tamf4.js +886 -0
  19. package/dist/GeoJSONModal-Dd-nBufy.cjs +9 -0
  20. package/dist/SchemaEditor-B4L17K1e.cjs +1 -0
  21. package/dist/SchemaEditor-ryoTgaLb.js +293 -0
  22. package/dist/SchemaModal-DvMbWskS.js +95 -0
  23. package/dist/SchemaModal-gAuDkd-L.cjs +1 -0
  24. package/dist/SettingsModal-BScVTjpn.js +237 -0
  25. package/dist/SettingsModal-CqaSFxxR.cjs +1 -0
  26. package/dist/ShortcutsModal-D1Y2bGT8.cjs +1 -0
  27. package/dist/ShortcutsModal-ozuS2Ysb.js +299 -0
  28. package/dist/components/ActiveDrawingToolbar.d.cts +1 -0
  29. package/dist/components/ActiveDrawingToolbar.d.ts +1 -0
  30. package/dist/components/BasemapPicker.d.cts +26 -0
  31. package/dist/components/BasemapPicker.d.ts +26 -0
  32. package/dist/components/BooleanOperations.d.cts +1 -0
  33. package/dist/components/BooleanOperations.d.ts +1 -0
  34. package/dist/components/BufferPanel.d.cts +1 -0
  35. package/dist/components/BufferPanel.d.ts +1 -0
  36. package/dist/components/DataTable.d.cts +9 -0
  37. package/dist/components/DataTable.d.ts +9 -0
  38. package/dist/components/DataTablePanel.d.cts +10 -0
  39. package/dist/components/DataTablePanel.d.ts +10 -0
  40. package/dist/components/EditingToolbar.d.cts +1 -0
  41. package/dist/components/EditingToolbar.d.ts +1 -0
  42. package/dist/components/ElementEditorErrorBoundary.d.cts +28 -0
  43. package/dist/components/ElementEditorErrorBoundary.d.ts +28 -0
  44. package/dist/components/ElementEditorUIProvider.d.cts +50 -0
  45. package/dist/components/ElementEditorUIProvider.d.ts +50 -0
  46. package/dist/components/FeatureMapContextMenu.d.cts +23 -0
  47. package/dist/components/FeatureMapContextMenu.d.ts +23 -0
  48. package/dist/components/FitBoundsButton.d.cts +6 -0
  49. package/dist/components/FitBoundsButton.d.ts +6 -0
  50. package/dist/components/FloatingToolbar.d.cts +3 -0
  51. package/dist/components/FloatingToolbar.d.ts +3 -0
  52. package/dist/components/LocateButton.d.cts +11 -0
  53. package/dist/components/LocateButton.d.ts +11 -0
  54. package/dist/components/ReadonlyBanner.d.cts +1 -0
  55. package/dist/components/ReadonlyBanner.d.ts +1 -0
  56. package/dist/components/ShortcutsModal.d.cts +1 -0
  57. package/dist/components/ShortcutsModal.d.ts +1 -0
  58. package/dist/components/SimplifyPanel.d.cts +1 -0
  59. package/dist/components/SimplifyPanel.d.ts +1 -0
  60. package/dist/components/SmoothPanel.d.cts +1 -0
  61. package/dist/components/SmoothPanel.d.ts +1 -0
  62. package/dist/components/UndoRedoToolbar.d.cts +20 -0
  63. package/dist/components/UndoRedoToolbar.d.ts +20 -0
  64. package/dist/components/VertexSelectionBar.d.cts +12 -0
  65. package/dist/components/VertexSelectionBar.d.ts +12 -0
  66. package/dist/components/ZoomIndicator.d.cts +15 -0
  67. package/dist/components/ZoomIndicator.d.ts +15 -0
  68. package/dist/components/dialogs/DynamicFieldRenderer.d.cts +11 -0
  69. package/dist/components/dialogs/DynamicFieldRenderer.d.ts +11 -0
  70. package/dist/components/dialogs/SettingsModal.d.cts +1 -0
  71. package/dist/components/dialogs/SettingsModal.d.ts +1 -0
  72. package/dist/components/lazyParts.d.cts +12 -0
  73. package/dist/components/lazyParts.d.ts +12 -0
  74. package/dist/components/sidebar/FeatureEditModal.d.cts +6 -0
  75. package/dist/components/sidebar/FeatureEditModal.d.ts +6 -0
  76. package/dist/components/sidebar/FeatureList.d.cts +4 -0
  77. package/dist/components/sidebar/FeatureList.d.ts +4 -0
  78. package/dist/components/sidebar/FeatureRow.d.cts +38 -0
  79. package/dist/components/sidebar/FeatureRow.d.ts +38 -0
  80. package/dist/components/sidebar/FeatureRowContextMenu.d.cts +12 -0
  81. package/dist/components/sidebar/FeatureRowContextMenu.d.ts +12 -0
  82. package/dist/components/sidebar/FeatureSidePanel.d.cts +8 -0
  83. package/dist/components/sidebar/FeatureSidePanel.d.ts +8 -0
  84. package/dist/components/sidebar/GeoJSONModal.d.cts +5 -0
  85. package/dist/components/sidebar/GeoJSONModal.d.ts +5 -0
  86. package/dist/components/sidebar/GroupRow.d.cts +21 -0
  87. package/dist/components/sidebar/GroupRow.d.ts +21 -0
  88. package/dist/components/sidebar/HideLayersToggle.d.cts +2 -0
  89. package/dist/components/sidebar/HideLayersToggle.d.ts +2 -0
  90. package/dist/components/sidebar/LayersPanel.d.cts +5 -0
  91. package/dist/components/sidebar/LayersPanel.d.ts +5 -0
  92. package/dist/components/sidebar/PartSubRow.d.cts +9 -0
  93. package/dist/components/sidebar/PartSubRow.d.ts +9 -0
  94. package/dist/components/sidebar/SchemaEditor.d.cts +4 -0
  95. package/dist/components/sidebar/SchemaEditor.d.ts +4 -0
  96. package/dist/components/sidebar/SchemaModal.d.cts +5 -0
  97. package/dist/components/sidebar/SchemaModal.d.ts +5 -0
  98. package/dist/components/sidebar/codeDock.d.cts +21 -0
  99. package/dist/components/sidebar/codeDock.d.ts +21 -0
  100. package/dist/components/ui/Button.d.cts +9 -0
  101. package/dist/components/ui/Button.d.ts +9 -0
  102. package/dist/components/ui/CloseButton.d.cts +6 -0
  103. package/dist/components/ui/CloseButton.d.ts +6 -0
  104. package/dist/components/ui/ContextMenu.d.cts +28 -0
  105. package/dist/components/ui/ContextMenu.d.ts +28 -0
  106. package/dist/components/ui/EditToolbarBtn.d.cts +13 -0
  107. package/dist/components/ui/EditToolbarBtn.d.ts +13 -0
  108. package/dist/components/ui/ElementToaster.d.cts +3 -0
  109. package/dist/components/ui/ElementToaster.d.ts +3 -0
  110. package/dist/components/ui/GeometryTypeIcon.d.cts +7 -0
  111. package/dist/components/ui/GeometryTypeIcon.d.ts +7 -0
  112. package/dist/components/ui/IconButton.d.cts +28 -0
  113. package/dist/components/ui/IconButton.d.ts +28 -0
  114. package/dist/components/ui/Input.d.cts +14 -0
  115. package/dist/components/ui/Input.d.ts +14 -0
  116. package/dist/components/ui/JsonCode.d.cts +4 -0
  117. package/dist/components/ui/JsonCode.d.ts +4 -0
  118. package/dist/components/ui/Kbd.d.cts +16 -0
  119. package/dist/components/ui/Kbd.d.ts +16 -0
  120. package/dist/components/ui/NoFeaturesEmptyState.d.cts +1 -0
  121. package/dist/components/ui/NoFeaturesEmptyState.d.ts +1 -0
  122. package/dist/components/ui/SearchDropdown.d.cts +28 -0
  123. package/dist/components/ui/SearchDropdown.d.ts +28 -0
  124. package/dist/components/ui/ToolButton.d.cts +19 -0
  125. package/dist/components/ui/ToolButton.d.ts +19 -0
  126. package/dist/components/ui/Tooltip.d.cts +12 -0
  127. package/dist/components/ui/Tooltip.d.ts +12 -0
  128. package/dist/components/ui/panelHeader.d.cts +2 -0
  129. package/dist/components/ui/panelHeader.d.ts +2 -0
  130. package/dist/components/ui/resizeEdge.d.cts +4 -0
  131. package/dist/components/ui/resizeEdge.d.ts +4 -0
  132. package/dist/contexts/ElementEditorConfigContext.d.cts +351 -0
  133. package/dist/contexts/ElementEditorConfigContext.d.ts +351 -0
  134. package/dist/contexts/EventContext.d.cts +69 -0
  135. package/dist/contexts/EventContext.d.ts +69 -0
  136. package/dist/contexts/MapControllerContext.d.cts +24 -0
  137. package/dist/contexts/MapControllerContext.d.ts +24 -0
  138. package/dist/contexts/ShortcutConfigContext.d.cts +16 -0
  139. package/dist/contexts/ShortcutConfigContext.d.ts +16 -0
  140. package/dist/contexts/ThemeContext.d.cts +12 -0
  141. package/dist/contexts/ThemeContext.d.ts +12 -0
  142. package/dist/element-editor-ui.cjs +1 -0
  143. package/dist/element-editor-ui.es.js +102 -0
  144. package/dist/geometryWorker-CCwg4tNC.cjs +1 -0
  145. package/dist/geometryWorker-DgQCFSmD.js +25 -0
  146. package/dist/hooks/dragShield.d.cts +7 -0
  147. package/dist/hooks/dragShield.d.ts +7 -0
  148. package/dist/hooks/themeInputs.d.cts +14 -0
  149. package/dist/hooks/themeInputs.d.ts +14 -0
  150. package/dist/hooks/useAccentPalette.d.cts +15 -0
  151. package/dist/hooks/useAccentPalette.d.ts +15 -0
  152. package/dist/hooks/useAccentStyle.d.cts +39 -0
  153. package/dist/hooks/useAccentStyle.d.ts +39 -0
  154. package/dist/hooks/useAdapterControls.d.cts +280 -0
  155. package/dist/hooks/useAdapterControls.d.ts +280 -0
  156. package/dist/hooks/useBalancedWrap.d.cts +8 -0
  157. package/dist/hooks/useBalancedWrap.d.ts +8 -0
  158. package/dist/hooks/useContextMenu.d.cts +11 -0
  159. package/dist/hooks/useContextMenu.d.ts +11 -0
  160. package/dist/hooks/useDataChangeSubscription.d.cts +9 -0
  161. package/dist/hooks/useDataChangeSubscription.d.ts +9 -0
  162. package/dist/hooks/useDragWindow.d.cts +9 -0
  163. package/dist/hooks/useDragWindow.d.ts +9 -0
  164. package/dist/hooks/useFocusTrap.d.cts +7 -0
  165. package/dist/hooks/useFocusTrap.d.ts +7 -0
  166. package/dist/hooks/useGeoJSONDrop.d.cts +40 -0
  167. package/dist/hooks/useGeoJSONDrop.d.ts +40 -0
  168. package/dist/hooks/useGeoJSONExport.d.cts +69 -0
  169. package/dist/hooks/useGeoJSONExport.d.ts +69 -0
  170. package/dist/hooks/useGeoJSONFileImport.d.cts +24 -0
  171. package/dist/hooks/useGeoJSONFileImport.d.ts +24 -0
  172. package/dist/hooks/useInlineRename.d.cts +26 -0
  173. package/dist/hooks/useInlineRename.d.ts +26 -0
  174. package/dist/hooks/useJumpToFeature.d.cts +3 -0
  175. package/dist/hooks/useJumpToFeature.d.ts +3 -0
  176. package/dist/hooks/useKeyboardShortcuts.d.cts +9 -0
  177. package/dist/hooks/useKeyboardShortcuts.d.ts +9 -0
  178. package/dist/hooks/useNominatim.d.cts +24 -0
  179. package/dist/hooks/useNominatim.d.ts +24 -0
  180. package/dist/hooks/usePanelOffset.d.cts +14 -0
  181. package/dist/hooks/usePanelOffset.d.ts +14 -0
  182. package/dist/hooks/useResizablePanel.d.cts +4 -0
  183. package/dist/hooks/useResizablePanel.d.ts +4 -0
  184. package/dist/hooks/useRootTokens.d.cts +27 -0
  185. package/dist/hooks/useRootTokens.d.ts +27 -0
  186. package/dist/hooks/useSearchState.d.cts +23 -0
  187. package/dist/hooks/useSearchState.d.ts +23 -0
  188. package/dist/hooks/useServiceAttribution.d.cts +13 -0
  189. package/dist/hooks/useServiceAttribution.d.ts +13 -0
  190. package/dist/hooks/useWindowEscape.d.cts +25 -0
  191. package/dist/hooks/useWindowEscape.d.ts +25 -0
  192. package/dist/hooks/useWindowFocus.d.cts +4 -0
  193. package/dist/hooks/useWindowFocus.d.ts +4 -0
  194. package/dist/hooks/useWorkerGeometryPreview.d.cts +22 -0
  195. package/dist/hooks/useWorkerGeometryPreview.d.ts +22 -0
  196. package/dist/index-CILw1Du5.js +3165 -0
  197. package/dist/index-DG4wEjGj.cjs +1 -0
  198. package/dist/index.d.cts +89 -0
  199. package/dist/index.d.ts +89 -0
  200. package/dist/internal.cjs +1 -0
  201. package/dist/internal.d.cts +16 -0
  202. package/dist/internal.d.ts +16 -0
  203. package/dist/internal.es.js +42 -0
  204. package/dist/primitives.cjs +1 -0
  205. package/dist/primitives.d.cts +19 -0
  206. package/dist/primitives.d.ts +19 -0
  207. package/dist/primitives.es.js +17 -0
  208. package/dist/store/StoreContext.d.cts +17 -0
  209. package/dist/store/StoreContext.d.ts +17 -0
  210. package/dist/types/events.d.cts +95 -0
  211. package/dist/types/events.d.ts +95 -0
  212. package/dist/useAccentStyle-CPo2XqAn.js +412 -0
  213. package/dist/useAccentStyle-hsGvyHZc.cjs +1 -0
  214. package/dist/useAdapterControls-BBObhzVX.cjs +1 -0
  215. package/dist/useAdapterControls-DVjkwRZ_.js +691 -0
  216. package/dist/useContextMenu-DJ2Cti85.js +10 -0
  217. package/dist/useContextMenu-DbxMvb1s.cjs +1 -0
  218. package/dist/useFocusTrap-BBjPCfDR.cjs +1 -0
  219. package/dist/useFocusTrap-CKxKT8De.js +25 -0
  220. package/dist/useJumpToFeature-Bdz2hqOC.js +16 -0
  221. package/dist/useJumpToFeature-LwjxGzfy.cjs +1 -0
  222. package/dist/useWindowFocus-DuQVjnHE.js +80 -0
  223. package/dist/useWindowFocus-EemgNOuz.cjs +1 -0
  224. package/dist/utils/booleanValue.d.cts +4 -0
  225. package/dist/utils/booleanValue.d.ts +4 -0
  226. package/dist/utils/clipboardError.d.cts +3 -0
  227. package/dist/utils/clipboardError.d.ts +3 -0
  228. package/dist/utils/download.d.cts +42 -0
  229. package/dist/utils/download.d.ts +42 -0
  230. package/dist/utils/geojsonDocument.d.cts +168 -0
  231. package/dist/utils/geojsonDocument.d.ts +168 -0
  232. package/dist/utils/geometryWorkerClient.d.cts +6 -0
  233. package/dist/utils/geometryWorkerClient.d.ts +6 -0
  234. package/dist/utils/layerOrder.d.cts +9 -0
  235. package/dist/utils/layerOrder.d.ts +9 -0
  236. package/dist/utils/lazyWithPreload.d.cts +24 -0
  237. package/dist/utils/lazyWithPreload.d.ts +24 -0
  238. package/dist/utils/lineSmooth.d.cts +7 -0
  239. package/dist/utils/lineSmooth.d.ts +7 -0
  240. package/dist/utils/platform.d.cts +2 -0
  241. package/dist/utils/platform.d.ts +2 -0
  242. package/dist/workers/geometryWorker.d.cts +1 -0
  243. package/dist/workers/geometryWorker.d.ts +1 -0
  244. package/package.json +133 -3
@@ -0,0 +1,38 @@
1
+ import { GeoJSONFeature } from '@element-editor/core';
2
+ /** A feature's display name: its `name`, else its geometry type in plain words (Point, Line, Area, …). */
3
+ export declare function featureLabel(feature: GeoJSONFeature): string;
4
+ interface FeatureRowProps {
5
+ feature: GeoJSONFeature;
6
+ isSelected: boolean;
7
+ onRowClick: (id: string) => void;
8
+ /** Selection without the map move — used to keep multi/range-select chains
9
+ * responsive when a name-click defers the row's pan/fit. */
10
+ onRowSelectOnly?: (id: string) => void;
11
+ /** Just the pan/fit — invoked by the name-click's deferred timer so a
12
+ * follow-up dblclick (rename) can cancel it. */
13
+ onRowJump?: (id: string) => void;
14
+ onEdit: (id: string) => void;
15
+ onToggleHidden: (id: string) => void;
16
+ containerProps?: Record<string, unknown>;
17
+ dragHandleProps?: Record<string, unknown>;
18
+ isDragging?: boolean;
19
+ innerRef?: (node: HTMLElement | null) => void;
20
+ isMultiSelected?: boolean;
21
+ onMultiSelectToggle?: (id: string) => void;
22
+ onRangeSelect?: (id: string) => void;
23
+ isContextMenuActive?: boolean;
24
+ /** When dragging multiple selected items, shows a count badge on the drag preview */
25
+ dragCountBadge?: number;
26
+ /** Dims the row when it's being dragged along as part of a multi-drag */
27
+ isGhosted?: boolean;
28
+ onRename?: (id: string, name: string) => void;
29
+ /** Parent-controlled rename activation (drives Tab / Shift+Tab navigation between rows). */
30
+ renameActive?: boolean;
31
+ onRenameEnd?: () => void;
32
+ onRenameTab?: (direction: 'next' | 'prev') => void;
33
+ /** Square off the top / bottom corners (selected neighbour joins this row). */
34
+ joinTop?: boolean;
35
+ joinBottom?: boolean;
36
+ }
37
+ declare const FeatureRow: import('react').NamedExoticComponent<FeatureRowProps>;
38
+ export default FeatureRow;
@@ -0,0 +1,12 @@
1
+ import { GeoJSONFeature } from '@element-editor/core';
2
+ interface Props {
3
+ x: number;
4
+ y: number;
5
+ feature: GeoJSONFeature;
6
+ onClose: () => void;
7
+ /** Group / Ungroup items — layer-list organisation, meaningless in the data table. */
8
+ showGrouping?: boolean;
9
+ }
10
+ /** Right-click menu for a feature row — shared by the layers list and the data table. */
11
+ export declare function FeatureRowContextMenu({ x, y, feature, onClose, showGrouping }: Props): import("react/jsx-runtime").JSX.Element;
12
+ export {};
@@ -0,0 +1,12 @@
1
+ import { GeoJSONFeature } from '@element-editor/core';
2
+ interface Props {
3
+ x: number;
4
+ y: number;
5
+ feature: GeoJSONFeature;
6
+ onClose: () => void;
7
+ /** Group / Ungroup items — layer-list organisation, meaningless in the data table. */
8
+ showGrouping?: boolean;
9
+ }
10
+ /** Right-click menu for a feature row — shared by the layers list and the data table. */
11
+ export declare function FeatureRowContextMenu({ x, y, feature, onClose, showGrouping }: Props): import("react/jsx-runtime").JSX.Element;
12
+ export {};
@@ -0,0 +1,8 @@
1
+ import { DialogState } from '@element-editor/core';
2
+ /** `collapsible`: show the hide-layers toggle in the header (set when the form replaces the layers list, not in the modal). */
3
+ export default function FeatureSidePanel({ dialogState, collapsible }: {
4
+ dialogState: Exclude<DialogState, {
5
+ type: 'closed';
6
+ }>;
7
+ collapsible?: boolean;
8
+ }): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,8 @@
1
+ import { DialogState } from '@element-editor/core';
2
+ /** `collapsible`: show the hide-layers toggle in the header (set when the form replaces the layers list, not in the modal). */
3
+ export default function FeatureSidePanel({ dialogState, collapsible }: {
4
+ dialogState: Exclude<DialogState, {
5
+ type: 'closed';
6
+ }>;
7
+ collapsible?: boolean;
8
+ }): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,5 @@
1
+ interface GeoJSONModalProps {
2
+ onClose: () => void;
3
+ }
4
+ export default function GeoJSONModal({ onClose }: GeoJSONModalProps): import("react/jsx-runtime").JSX.Element;
5
+ export {};
@@ -0,0 +1,5 @@
1
+ interface GeoJSONModalProps {
2
+ onClose: () => void;
3
+ }
4
+ export default function GeoJSONModal({ onClose }: GeoJSONModalProps): import("react/jsx-runtime").JSX.Element;
5
+ export {};
@@ -0,0 +1,21 @@
1
+ import { Group } from '@element-editor/core';
2
+ interface GroupRowProps {
3
+ group: Group;
4
+ featureCount: number;
5
+ autoFocus?: boolean;
6
+ /** True when every feature in this group is currently selected — drives the
7
+ * highlighted row appearance after a name-click selects the group. */
8
+ isSelected?: boolean;
9
+ onToggleCollapse: () => void;
10
+ onToggleHidden: () => void;
11
+ onRename: (name: string) => void;
12
+ onDelete: (mode: 'ungroup' | 'delete-features') => void;
13
+ /** Selects every feature in the group and fits the map to their combined bbox. */
14
+ onSelect?: () => void;
15
+ innerRef?: (node: HTMLElement | null) => void;
16
+ dragHandleProps?: Record<string, unknown>;
17
+ containerProps?: Record<string, unknown>;
18
+ isDragging?: boolean;
19
+ }
20
+ export default function GroupRow({ group, featureCount, autoFocus, isSelected, onToggleCollapse, onToggleHidden, onRename, onDelete, onSelect, innerRef, dragHandleProps, containerProps, isDragging }: GroupRowProps): import("react/jsx-runtime").JSX.Element;
21
+ export {};
@@ -0,0 +1,21 @@
1
+ import { Group } from '@element-editor/core';
2
+ interface GroupRowProps {
3
+ group: Group;
4
+ featureCount: number;
5
+ autoFocus?: boolean;
6
+ /** True when every feature in this group is currently selected — drives the
7
+ * highlighted row appearance after a name-click selects the group. */
8
+ isSelected?: boolean;
9
+ onToggleCollapse: () => void;
10
+ onToggleHidden: () => void;
11
+ onRename: (name: string) => void;
12
+ onDelete: (mode: 'ungroup' | 'delete-features') => void;
13
+ /** Selects every feature in the group and fits the map to their combined bbox. */
14
+ onSelect?: () => void;
15
+ innerRef?: (node: HTMLElement | null) => void;
16
+ dragHandleProps?: Record<string, unknown>;
17
+ containerProps?: Record<string, unknown>;
18
+ isDragging?: boolean;
19
+ }
20
+ export default function GroupRow({ group, featureCount, autoFocus, isSelected, onToggleCollapse, onToggleHidden, onRename, onDelete, onSelect, innerRef, dragHandleProps, containerProps, isDragging }: GroupRowProps): import("react/jsx-runtime").JSX.Element;
21
+ export {};
@@ -0,0 +1,2 @@
1
+ /** Bare "hide layers panel" toggle for panel headers. Hidden in split layout (panel can't collapse). */
2
+ export declare function HideLayersToggle(): import("react/jsx-runtime").JSX.Element | null;
@@ -0,0 +1,2 @@
1
+ /** Bare "hide layers panel" toggle for panel headers. Hidden in split layout (panel can't collapse). */
2
+ export declare function HideLayersToggle(): import("react/jsx-runtime").JSX.Element | null;
@@ -0,0 +1,5 @@
1
+ import { ReactNode } from 'react';
2
+ declare const _default: import('react').NamedExoticComponent<{
3
+ footer?: ReactNode;
4
+ }>;
5
+ export default _default;
@@ -0,0 +1,5 @@
1
+ import { ReactNode } from 'react';
2
+ declare const _default: import('react').NamedExoticComponent<{
3
+ footer?: ReactNode;
4
+ }>;
5
+ export default _default;
@@ -0,0 +1,9 @@
1
+ import { Geometry } from '@element-editor/core';
2
+ interface PartSubRowProps {
3
+ geometry: Geometry;
4
+ partIndex: number;
5
+ isSelected: boolean;
6
+ onClick: () => void;
7
+ }
8
+ export default function PartSubRow({ geometry, partIndex, isSelected, onClick }: PartSubRowProps): import("react/jsx-runtime").JSX.Element;
9
+ export {};
@@ -0,0 +1,9 @@
1
+ import { Geometry } from '@element-editor/core';
2
+ interface PartSubRowProps {
3
+ geometry: Geometry;
4
+ partIndex: number;
5
+ isSelected: boolean;
6
+ onClick: () => void;
7
+ }
8
+ export default function PartSubRow({ geometry, partIndex, isSelected, onClick }: PartSubRowProps): import("react/jsx-runtime").JSX.Element;
9
+ export {};
@@ -0,0 +1,4 @@
1
+ import { RefObject } from 'react';
2
+ export default function SchemaEditor({ containerRef }: {
3
+ containerRef?: RefObject<HTMLDivElement | null>;
4
+ }): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,4 @@
1
+ import { RefObject } from 'react';
2
+ export default function SchemaEditor({ containerRef }: {
3
+ containerRef?: RefObject<HTMLDivElement | null>;
4
+ }): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,5 @@
1
+ interface SchemaModalProps {
2
+ onClose: () => void;
3
+ }
4
+ export default function SchemaModal({ onClose }: SchemaModalProps): import('react').ReactPortal;
5
+ export {};
@@ -0,0 +1,5 @@
1
+ interface SchemaModalProps {
2
+ onClose: () => void;
3
+ }
4
+ export default function SchemaModal({ onClose }: SchemaModalProps): import('react').ReactPortal;
5
+ export {};
@@ -0,0 +1,21 @@
1
+ export declare const CODE_DOCKED_KEY = "elm_code_docked";
2
+ /** The user's saved Dock/Undock choice wins; without one, the inspector opens docked. */
3
+ export declare function useInitialCodeDocked(): boolean;
4
+ /**
5
+ * Docked: the frame's width (resizable, saved) and position, published as
6
+ * `codeDockWidth` so map slots, the toolbar and the data table clear it.
7
+ * Layout effect + no transitions: they move in the same frame the dock
8
+ * appears / disappears, not after a paint and then a 200 ms slide.
9
+ */
10
+ export declare function useCodeDock(docked: boolean): {
11
+ className: string;
12
+ style: React.CSSProperties;
13
+ width: number;
14
+ onHandleMouseDown: (e: React.MouseEvent) => void;
15
+ };
16
+ /**
17
+ * Suspense fallback for the inspector: an empty dock frame while its chunk
18
+ * loads (nothing when it opens floating), so the controls clear the dock at
19
+ * once instead of jumping when the inspector lands.
20
+ */
21
+ export declare function GeoJSONDockPlaceholder(): import("react/jsx-runtime").JSX.Element | null;
@@ -0,0 +1,21 @@
1
+ export declare const CODE_DOCKED_KEY = "elm_code_docked";
2
+ /** The user's saved Dock/Undock choice wins; without one, the inspector opens docked. */
3
+ export declare function useInitialCodeDocked(): boolean;
4
+ /**
5
+ * Docked: the frame's width (resizable, saved) and position, published as
6
+ * `codeDockWidth` so map slots, the toolbar and the data table clear it.
7
+ * Layout effect + no transitions: they move in the same frame the dock
8
+ * appears / disappears, not after a paint and then a 200 ms slide.
9
+ */
10
+ export declare function useCodeDock(docked: boolean): {
11
+ className: string;
12
+ style: React.CSSProperties;
13
+ width: number;
14
+ onHandleMouseDown: (e: React.MouseEvent) => void;
15
+ };
16
+ /**
17
+ * Suspense fallback for the inspector: an empty dock frame while its chunk
18
+ * loads (nothing when it opens floating), so the controls clear the dock at
19
+ * once instead of jumping when the inspector lands.
20
+ */
21
+ export declare function GeoJSONDockPlaceholder(): import("react/jsx-runtime").JSX.Element | null;
@@ -0,0 +1,9 @@
1
+ import { ButtonHTMLAttributes } from 'react';
2
+ export type ButtonVariant = 'primary' | 'secondary' | 'ghost' | 'success' | 'emerald' | 'warning' | 'dashed';
3
+ export type ButtonSize = 'sm' | 'md' | 'icon' | 'icon-sm';
4
+ interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
5
+ variant?: ButtonVariant;
6
+ size?: ButtonSize;
7
+ }
8
+ export declare const Button: import('react').ForwardRefExoticComponent<ButtonProps & import('react').RefAttributes<HTMLButtonElement>>;
9
+ export {};
@@ -0,0 +1,9 @@
1
+ import { ButtonHTMLAttributes } from 'react';
2
+ export type ButtonVariant = 'primary' | 'secondary' | 'ghost' | 'success' | 'emerald' | 'warning' | 'dashed';
3
+ export type ButtonSize = 'sm' | 'md' | 'icon' | 'icon-sm';
4
+ interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
5
+ variant?: ButtonVariant;
6
+ size?: ButtonSize;
7
+ }
8
+ export declare const Button: import('react').ForwardRefExoticComponent<ButtonProps & import('react').RefAttributes<HTMLButtonElement>>;
9
+ export {};
@@ -0,0 +1,6 @@
1
+ interface CloseButtonProps {
2
+ onClick: () => void;
3
+ label?: string;
4
+ }
5
+ export declare function CloseButton({ onClick, label }: CloseButtonProps): import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ interface CloseButtonProps {
2
+ onClick: () => void;
3
+ label?: string;
4
+ }
5
+ export declare function CloseButton({ onClick, label }: CloseButtonProps): import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,28 @@
1
+ export interface ContextMenuAction {
2
+ label: string;
3
+ icon?: React.ReactNode;
4
+ /** Optional shortcut hint shown right-aligned (e.g. a <KbdDark> element). */
5
+ shortcut?: React.ReactNode;
6
+ onClick: () => void;
7
+ disabled?: boolean;
8
+ }
9
+ export type ContextMenuItem = ContextMenuAction | {
10
+ separator: true;
11
+ };
12
+ /**
13
+ * Marker attribute set on every open <ContextMenu>. Other capture-phase ESC
14
+ * handlers registered earlier than the menu's own listener won't see the
15
+ * stopImmediatePropagation from ContextMenu (capture order = registration
16
+ * order). Those handlers check for this attribute to yield the keypress.
17
+ */
18
+ export declare const CONTEXT_MENU_MARKER_ATTR = "data-elm-context-menu";
19
+ /** True if any <ContextMenu> is currently mounted. Pair with capture-phase ESC handlers. */
20
+ export declare function isContextMenuOpen(): boolean;
21
+ interface ContextMenuProps {
22
+ x: number;
23
+ y: number;
24
+ items: ContextMenuItem[];
25
+ onClose: () => void;
26
+ }
27
+ export declare function ContextMenu({ x, y, items, onClose }: ContextMenuProps): import("react/jsx-runtime").JSX.Element;
28
+ export {};
@@ -0,0 +1,28 @@
1
+ export interface ContextMenuAction {
2
+ label: string;
3
+ icon?: React.ReactNode;
4
+ /** Optional shortcut hint shown right-aligned (e.g. a <KbdDark> element). */
5
+ shortcut?: React.ReactNode;
6
+ onClick: () => void;
7
+ disabled?: boolean;
8
+ }
9
+ export type ContextMenuItem = ContextMenuAction | {
10
+ separator: true;
11
+ };
12
+ /**
13
+ * Marker attribute set on every open <ContextMenu>. Other capture-phase ESC
14
+ * handlers registered earlier than the menu's own listener won't see the
15
+ * stopImmediatePropagation from ContextMenu (capture order = registration
16
+ * order). Those handlers check for this attribute to yield the keypress.
17
+ */
18
+ export declare const CONTEXT_MENU_MARKER_ATTR = "data-elm-context-menu";
19
+ /** True if any <ContextMenu> is currently mounted. Pair with capture-phase ESC handlers. */
20
+ export declare function isContextMenuOpen(): boolean;
21
+ interface ContextMenuProps {
22
+ x: number;
23
+ y: number;
24
+ items: ContextMenuItem[];
25
+ onClose: () => void;
26
+ }
27
+ export declare function ContextMenu({ x, y, items, onClose }: ContextMenuProps): import("react/jsx-runtime").JSX.Element;
28
+ export {};
@@ -0,0 +1,13 @@
1
+ import { TooltipSide } from './Tooltip.cjs';
2
+ export declare function EditToolbarBtn({ label, shortcut, shortcutId, onClick, active, disabled, tooltipSide, children, }: {
3
+ label: string;
4
+ shortcut?: React.ReactNode;
5
+ /** Shortcut id (`data-elm-shortcut`): the key flashes this button pressed. */
6
+ shortcutId?: string;
7
+ onClick: () => void;
8
+ active?: boolean;
9
+ disabled?: boolean;
10
+ tooltipSide?: TooltipSide;
11
+ children: React.ReactNode;
12
+ }): import("react/jsx-runtime").JSX.Element;
13
+ export declare function ToolbarDivider(): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,13 @@
1
+ import { TooltipSide } from './Tooltip.js';
2
+ export declare function EditToolbarBtn({ label, shortcut, shortcutId, onClick, active, disabled, tooltipSide, children, }: {
3
+ label: string;
4
+ shortcut?: React.ReactNode;
5
+ /** Shortcut id (`data-elm-shortcut`): the key flashes this button pressed. */
6
+ shortcutId?: string;
7
+ onClick: () => void;
8
+ active?: boolean;
9
+ disabled?: boolean;
10
+ tooltipSide?: TooltipSide;
11
+ children: React.ReactNode;
12
+ }): import("react/jsx-runtime").JSX.Element;
13
+ export declare function ToolbarDivider(): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,3 @@
1
+ import { ToasterProps } from 'sonner';
2
+ /** sonner `<Toaster>` styled like Element: follows the editor's resolved theme (dark toast on a dark editor), panel surface, no icons. */
3
+ export declare function ElementToaster(props: ToasterProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,3 @@
1
+ import { ToasterProps } from 'sonner';
2
+ /** sonner `<Toaster>` styled like Element: follows the editor's resolved theme (dark toast on a dark editor), panel surface, no icons. */
3
+ export declare function ElementToaster(props: ToasterProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,7 @@
1
+ /** A geometry type's icon, as in the layers list (sized by the caller, coloured by currentColor). */
2
+ export declare function GeometryTypeIcon({ type, size }: {
3
+ type: string;
4
+ size?: number;
5
+ }): import("react/jsx-runtime").JSX.Element;
6
+ /** A geometry type in plain words: Point, Line, Area (plural for Multi*), Mixed. */
7
+ export declare function geometryTypeLabel(type: string): string;
@@ -0,0 +1,7 @@
1
+ /** A geometry type's icon, as in the layers list (sized by the caller, coloured by currentColor). */
2
+ export declare function GeometryTypeIcon({ type, size }: {
3
+ type: string;
4
+ size?: number;
5
+ }): import("react/jsx-runtime").JSX.Element;
6
+ /** A geometry type in plain words: Point, Line, Area (plural for Multi*), Mixed. */
7
+ export declare function geometryTypeLabel(type: string): string;
@@ -0,0 +1,28 @@
1
+ import { ReactNode } from 'react';
2
+ import { TooltipSide } from './Tooltip.cjs';
3
+ interface IconButtonProps {
4
+ label: string;
5
+ tooltipContent?: ReactNode;
6
+ shortcut?: ReactNode;
7
+ /** Shortcut id (`data-elm-shortcut`): the key flashes this button pressed. */
8
+ shortcutId?: string;
9
+ tooltipSide?: TooltipSide;
10
+ onClick: () => void;
11
+ active?: boolean;
12
+ /**
13
+ * Set for a button that opens a popover: announces `aria-expanded` (and
14
+ * `aria-controls` = `controls`) instead of `aria-pressed`.
15
+ */
16
+ expanded?: boolean;
17
+ controls?: string;
18
+ disabled?: boolean;
19
+ /**
20
+ * `'sm'`: flat 24px button with a 16px icon, for the status bar. `'group'`:
21
+ * flat 32px button inside a joined pill (`ControlGroup`). Default `'md'`.
22
+ */
23
+ size?: IconButtonSize;
24
+ children: ReactNode;
25
+ }
26
+ export type IconButtonSize = 'md' | 'sm' | 'group';
27
+ export declare function IconButton({ label, tooltipContent, shortcut, shortcutId, tooltipSide, onClick, active, expanded, controls, disabled, size, children, }: IconButtonProps): import("react/jsx-runtime").JSX.Element;
28
+ export {};
@@ -0,0 +1,28 @@
1
+ import { ReactNode } from 'react';
2
+ import { TooltipSide } from './Tooltip.js';
3
+ interface IconButtonProps {
4
+ label: string;
5
+ tooltipContent?: ReactNode;
6
+ shortcut?: ReactNode;
7
+ /** Shortcut id (`data-elm-shortcut`): the key flashes this button pressed. */
8
+ shortcutId?: string;
9
+ tooltipSide?: TooltipSide;
10
+ onClick: () => void;
11
+ active?: boolean;
12
+ /**
13
+ * Set for a button that opens a popover: announces `aria-expanded` (and
14
+ * `aria-controls` = `controls`) instead of `aria-pressed`.
15
+ */
16
+ expanded?: boolean;
17
+ controls?: string;
18
+ disabled?: boolean;
19
+ /**
20
+ * `'sm'`: flat 24px button with a 16px icon, for the status bar. `'group'`:
21
+ * flat 32px button inside a joined pill (`ControlGroup`). Default `'md'`.
22
+ */
23
+ size?: IconButtonSize;
24
+ children: ReactNode;
25
+ }
26
+ export type IconButtonSize = 'md' | 'sm' | 'group';
27
+ export declare function IconButton({ label, tooltipContent, shortcut, shortcutId, tooltipSide, onClick, active, expanded, controls, disabled, size, children, }: IconButtonProps): import("react/jsx-runtime").JSX.Element;
28
+ export {};
@@ -0,0 +1,14 @@
1
+ import { InputHTMLAttributes, TextareaHTMLAttributes, SelectHTMLAttributes } from 'react';
2
+ interface InputProps extends InputHTMLAttributes<HTMLInputElement> {
3
+ error?: boolean;
4
+ }
5
+ export declare function Input({ error, className, ...props }: InputProps): import("react/jsx-runtime").JSX.Element;
6
+ interface TextareaProps extends TextareaHTMLAttributes<HTMLTextAreaElement> {
7
+ error?: boolean;
8
+ }
9
+ export declare function Textarea({ error, className, ...props }: TextareaProps): import("react/jsx-runtime").JSX.Element;
10
+ interface SelectInputProps extends SelectHTMLAttributes<HTMLSelectElement> {
11
+ error?: boolean;
12
+ }
13
+ export declare function SelectInput({ error, className, children, ...props }: SelectInputProps): import("react/jsx-runtime").JSX.Element;
14
+ export {};
@@ -0,0 +1,14 @@
1
+ import { InputHTMLAttributes, TextareaHTMLAttributes, SelectHTMLAttributes } from 'react';
2
+ interface InputProps extends InputHTMLAttributes<HTMLInputElement> {
3
+ error?: boolean;
4
+ }
5
+ export declare function Input({ error, className, ...props }: InputProps): import("react/jsx-runtime").JSX.Element;
6
+ interface TextareaProps extends TextareaHTMLAttributes<HTMLTextAreaElement> {
7
+ error?: boolean;
8
+ }
9
+ export declare function Textarea({ error, className, ...props }: TextareaProps): import("react/jsx-runtime").JSX.Element;
10
+ interface SelectInputProps extends SelectHTMLAttributes<HTMLSelectElement> {
11
+ error?: boolean;
12
+ }
13
+ export declare function SelectInput({ error, className, children, ...props }: SelectInputProps): import("react/jsx-runtime").JSX.Element;
14
+ export {};
@@ -0,0 +1,4 @@
1
+ export declare function JsonCode({ json, className }: {
2
+ json: string;
3
+ className?: string;
4
+ }): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,4 @@
1
+ export declare function JsonCode({ json, className }: {
2
+ json: string;
3
+ className?: string;
4
+ }): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,16 @@
1
+ export declare function Kbd({ children }: {
2
+ children: React.ReactNode;
3
+ }): import("react/jsx-runtime").JSX.Element;
4
+ /**
5
+ * Kbd variant for tooltips and context menus. Neutral greys by default; once the
6
+ * integrator sets the design tokens of its container (tooltip: --elm-tooltip +
7
+ * --elm-tooltip-text, menu: --elm-surface + --elm-text) it is mixed from them
8
+ * (`--_elm-kbd-*`, shared.css).
9
+ */
10
+ export declare function KbdDark({ children }: {
11
+ children: React.ReactNode;
12
+ }): import("react/jsx-runtime").JSX.Element;
13
+ /** Kbd variant for use on colored backgrounds (e.g. inside a primary button). */
14
+ export declare function KbdInvert({ children }: {
15
+ children: React.ReactNode;
16
+ }): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,16 @@
1
+ export declare function Kbd({ children }: {
2
+ children: React.ReactNode;
3
+ }): import("react/jsx-runtime").JSX.Element;
4
+ /**
5
+ * Kbd variant for tooltips and context menus. Neutral greys by default; once the
6
+ * integrator sets the design tokens of its container (tooltip: --elm-tooltip +
7
+ * --elm-tooltip-text, menu: --elm-surface + --elm-text) it is mixed from them
8
+ * (`--_elm-kbd-*`, shared.css).
9
+ */
10
+ export declare function KbdDark({ children }: {
11
+ children: React.ReactNode;
12
+ }): import("react/jsx-runtime").JSX.Element;
13
+ /** Kbd variant for use on colored backgrounds (e.g. inside a primary button). */
14
+ export declare function KbdInvert({ children }: {
15
+ children: React.ReactNode;
16
+ }): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1 @@
1
+ export declare function NoFeaturesEmptyState(): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1 @@
1
+ export declare function NoFeaturesEmptyState(): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,28 @@
1
+ import { NominatimResult } from '../../hooks/useNominatim.cjs';
2
+ interface Props {
3
+ results: NominatimResult[];
4
+ loading: boolean;
5
+ error: string | null;
6
+ onGo: (r: NominatimResult) => void;
7
+ /** Omitted (readonly editor): no Add / Shape buttons. */
8
+ onAdd?: (r: NominatimResult) => void;
9
+ onAddShape?: (r: NominatimResult) => void;
10
+ activeIndex?: number;
11
+ onHoverIndex?: (i: number) => void;
12
+ onNavigate?: (delta: 1 | -1, fromIndex: number) => void;
13
+ className?: string;
14
+ /**
15
+ * `stack` — name on top, action buttons on a second row. Used in the
16
+ * vertical-toolbar side popup (~320px wide) where the single-row layout
17
+ * would truncate names to single characters.
18
+ * `row` — single horizontal row, action buttons on the right. Used when
19
+ * the toolbar is horizontal and the dropdown inherits the full toolbar
20
+ * width, so there's room for both on one line.
21
+ */
22
+ layout?: 'stack' | 'row';
23
+ }
24
+ export interface SearchDropdownHandle {
25
+ focusAdd: (index: number) => void;
26
+ }
27
+ export declare const SearchDropdown: import('react').ForwardRefExoticComponent<Props & import('react').RefAttributes<SearchDropdownHandle>>;
28
+ export {};
@@ -0,0 +1,28 @@
1
+ import { NominatimResult } from '../../hooks/useNominatim.js';
2
+ interface Props {
3
+ results: NominatimResult[];
4
+ loading: boolean;
5
+ error: string | null;
6
+ onGo: (r: NominatimResult) => void;
7
+ /** Omitted (readonly editor): no Add / Shape buttons. */
8
+ onAdd?: (r: NominatimResult) => void;
9
+ onAddShape?: (r: NominatimResult) => void;
10
+ activeIndex?: number;
11
+ onHoverIndex?: (i: number) => void;
12
+ onNavigate?: (delta: 1 | -1, fromIndex: number) => void;
13
+ className?: string;
14
+ /**
15
+ * `stack` — name on top, action buttons on a second row. Used in the
16
+ * vertical-toolbar side popup (~320px wide) where the single-row layout
17
+ * would truncate names to single characters.
18
+ * `row` — single horizontal row, action buttons on the right. Used when
19
+ * the toolbar is horizontal and the dropdown inherits the full toolbar
20
+ * width, so there's room for both on one line.
21
+ */
22
+ layout?: 'stack' | 'row';
23
+ }
24
+ export interface SearchDropdownHandle {
25
+ focusAdd: (index: number) => void;
26
+ }
27
+ export declare const SearchDropdown: import('react').ForwardRefExoticComponent<Props & import('react').RefAttributes<SearchDropdownHandle>>;
28
+ export {};