@12-apps/ui 6.84.0 → 6.86.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/NATIVE.md +1 -1
- package/components-catalog.md +7 -0
- package/dist/_internal/components/data-display/Alert/Alert.js +2 -2
- package/dist/_internal/components/data-display/AsyncStateContainer/AsyncStateContainer.js +4 -4
- package/dist/_internal/components/data-display/Badge/Badge.js +3 -3
- package/dist/_internal/components/data-display/Badge/Badge.styles.js +3 -3
- package/dist/_internal/components/data-display/Badge/BadgeContent.js +3 -3
- package/dist/_internal/components/data-display/CardKit/CardKebab.js +5 -5
- package/dist/_internal/components/data-display/CardKit/card-actions-context.js +3 -3
- package/dist/_internal/components/data-display/CardKit/use-remove-confirm.js +9 -9
- package/dist/_internal/components/data-display/CardKit/use-row-confirm.js +5 -5
- package/dist/_internal/components/data-display/Carousel/Carousel.chrome.js +7 -7
- package/dist/_internal/components/data-display/Carousel/Carousel.js +10 -10
- package/dist/_internal/components/data-display/Carousel/Carousel.parts.js +6 -6
- package/dist/_internal/components/data-display/Carousel/Carousel.styles.js +3 -3
- package/dist/_internal/components/data-display/Chart/Chart.js +3 -3
- package/dist/_internal/components/data-display/Chart/SpecChart.js +6 -6
- package/dist/_internal/components/data-display/Chart/chart-context.js +3 -3
- package/dist/_internal/components/data-display/Chart/chart-internals.js +3 -3
- package/dist/_internal/components/data-display/Chart/chart-renderers.js +3 -3
- package/dist/_internal/components/data-display/DataGrid/DataGrid.js +1 -1
- package/dist/_internal/components/data-display/DataViews/DataViewsGrid.js +64 -64
- package/dist/_internal/components/data-display/DataViews/DataViewsTableBase.js +78 -78
- package/dist/_internal/components/data-display/DataViews/DeleteViewDialog.js +5 -5
- package/dist/_internal/components/data-display/DataViews/ManageViewsDialog.js +6 -6
- package/dist/_internal/components/data-display/DataViews/SaveViewModal.js +8 -8
- package/dist/_internal/components/data-display/DataViews/base-card.js +3 -3
- package/dist/_internal/components/data-display/DataViews/base-list-card-gutters.js +3 -3
- package/dist/_internal/components/data-display/DataViews/base-list-card.js +5 -5
- package/dist/_internal/components/data-display/DataViews/data-views-bar-controls.js +3 -3
- package/dist/_internal/components/data-display/DataViews/data-views-card-body.js +6 -6
- package/dist/_internal/components/data-display/DataViews/data-views-category-pill.js +19 -19
- package/dist/_internal/components/data-display/DataViews/data-views-columns.js +6 -6
- package/dist/_internal/components/data-display/DataViews/data-views-day-input.js +3 -3
- package/dist/_internal/components/data-display/DataViews/data-views-display-panel.js +6 -6
- package/dist/_internal/components/data-display/DataViews/data-views-empty.js +5 -5
- package/dist/_internal/components/data-display/DataViews/data-views-export.js +5 -5
- package/dist/_internal/components/data-display/DataViews/data-views-filter-panel.js +31 -31
- package/dist/_internal/components/data-display/DataViews/data-views-grid-bodies.js +9 -9
- package/dist/_internal/components/data-display/DataViews/data-views-grid-helpers.js +5 -5
- package/dist/_internal/components/data-display/DataViews/data-views-grid-parts.js +61 -61
- package/dist/_internal/components/data-display/DataViews/data-views-inline-bar.js +34 -34
- package/dist/_internal/components/data-display/DataViews/data-views-more-fields.js +28 -28
- package/dist/_internal/components/data-display/DataViews/data-views-more-filters.js +31 -31
- package/dist/_internal/components/data-display/DataViews/data-views-number-input.js +3 -3
- package/dist/_internal/components/data-display/DataViews/data-views-pagination.js +5 -5
- package/dist/_internal/components/data-display/DataViews/data-views-quick-chip.js +3 -3
- package/dist/_internal/components/data-display/DataViews/data-views-range-pill.js +7 -7
- package/dist/_internal/components/data-display/DataViews/data-views-search.js +3 -3
- package/dist/_internal/components/data-display/DataViews/data-views-select-all-strip.js +5 -5
- package/dist/_internal/components/data-display/DataViews/data-views-shell-toolbar.js +17 -17
- package/dist/_internal/components/data-display/DataViews/data-views-table-parts.js +20 -20
- package/dist/_internal/components/data-display/DataViews/data-views-toolbar.js +16 -16
- package/dist/_internal/components/data-display/DataViews/data-views-view-nav.js +5 -5
- package/dist/_internal/components/data-display/DataViews/use-data-views-state.js +7 -7
- package/dist/_internal/components/data-display/FleetMap/FleetBody.js +22 -22
- package/dist/_internal/components/data-display/FleetMap/FleetCanvas.js +17 -17
- package/dist/_internal/components/data-display/FleetMap/FleetMap.fixtures.js +2 -2
- package/dist/_internal/components/data-display/FleetMap/FleetMap.js +24 -24
- package/dist/_internal/components/data-display/FleetMap/FleetRoster.js +4 -4
- package/dist/_internal/components/data-display/LazyImage/LazyImage.js +5 -5
- package/dist/_internal/components/data-display/Lightbox/Lightbox.js +6 -6
- package/dist/_internal/components/data-display/Lightbox/LightboxControls.js +2 -2
- package/dist/_internal/components/data-display/Lightbox/LightboxOverlay.js +3 -3
- package/dist/_internal/components/data-display/Lightbox/LightboxThumbnails.js +2 -2
- package/dist/_internal/components/data-display/LoadingState/LoadingState.js +3 -3
- package/dist/_internal/components/data-display/MapPreview/MapControlBar.js +4 -4
- package/dist/_internal/components/data-display/MapPreview/MapDecorations.js +2 -2
- package/dist/_internal/components/data-display/MapPreview/MapLayers.js +8 -8
- package/dist/_internal/components/data-display/MapPreview/MapMarkers.js +4 -4
- package/dist/_internal/components/data-display/MapPreview/MapPreview.helpers.js +3 -3
- package/dist/_internal/components/data-display/MapPreview/MapPreview.hooks.js +2 -2
- package/dist/_internal/components/data-display/MapPreview/MapPreview.js +16 -16
- package/dist/_internal/components/data-display/MapPreview/MapSearchBar.js +3 -3
- package/dist/_internal/components/data-display/MapPreview/MapTiles.js +2 -2
- package/dist/_internal/components/data-display/MapPreview/StaticMapView.js +4 -4
- package/dist/_internal/components/data-display/MapPreview/useMapPreview.js +3 -3
- package/dist/_internal/components/data-display/Progress/Progress.js +2 -2
- package/dist/_internal/components/data-display/RegionMap/RegionMap.fixtures.js +51 -0
- package/dist/_internal/components/data-display/RegionMap/RegionMap.fixtures.js.map +1 -0
- package/dist/_internal/components/data-display/RegionMap/RegionMap.helpers.js +38 -0
- package/dist/_internal/components/data-display/RegionMap/RegionMap.hooks.js +9 -0
- package/dist/_internal/components/data-display/RegionMap/RegionMap.hooks.js.map +1 -0
- package/dist/_internal/components/data-display/RegionMap/RegionMap.js +37 -0
- package/dist/_internal/components/data-display/RegionMap/RegionMap.js.map +1 -0
- package/dist/_internal/components/data-display/RegionMap/RegionMap.types.js +1 -0
- package/dist/_internal/components/data-display/RegionMap/RegionMap.types.js.map +1 -0
- package/dist/_internal/components/data-display/RegionMap/RegionMapDrawing.js +10 -0
- package/dist/_internal/components/data-display/RegionMap/RegionMapDrawing.js.map +1 -0
- package/dist/_internal/components/data-display/RegionMap/RegionMapLegend.js +9 -0
- package/dist/_internal/components/data-display/RegionMap/RegionMapLegend.js.map +1 -0
- package/dist/_internal/components/data-display/RegionMap/RegionMapList.js +34 -0
- package/dist/_internal/components/data-display/RegionMap/RegionMapList.js.map +1 -0
- package/dist/_internal/components/data-display/Sheet/Sheet.body.js +3 -3
- package/dist/_internal/components/data-display/Sheet/Sheet.js +6 -6
- package/dist/_internal/components/data-display/Sheet/Sheet.styles.js +3 -3
- package/dist/_internal/components/data-display/StatCard/StatCard.js +3 -3
- package/dist/_internal/components/data-display/Table/Table.js +2 -2
- package/dist/_internal/components/data-display/index.js +91 -74
- package/dist/_internal/components/feedback/ConfirmAction/ConfirmButton.js +5 -5
- package/dist/_internal/components/feedback/Modal/Modal.js +2 -2
- package/dist/_internal/components/feedback/NotificationStatusNotice/NotificationStatusNotice.js +7 -7
- package/dist/_internal/components/feedback/SequenceResolver/SequenceResolver.js +10 -10
- package/dist/_internal/components/feedback/SequenceResolver/SequenceResolver.parts.js +9 -9
- package/dist/_internal/components/feedback/index.js +21 -21
- package/dist/_internal/components/form/AddressAutocomplete/AddressAutocomplete.js +8 -8
- package/dist/_internal/components/form/AddressAutocomplete/AddressAutocompleteField.js +6 -6
- package/dist/_internal/components/form/AddressAutocomplete/AddressFallbackField.js +4 -4
- package/dist/_internal/components/form/AddressAutocomplete/AddressInputField.js +4 -4
- package/dist/_internal/components/form/AddressAutocomplete/AddressTextField.js +3 -3
- package/dist/_internal/components/form/Autocomplete/Autocomplete.js +4 -4
- package/dist/_internal/components/form/Autocomplete/Autocomplete.parts.js +3 -3
- package/dist/_internal/components/form/Button/Button.js +4 -4
- package/dist/_internal/components/form/Button/Button.styles.js +3 -3
- package/dist/_internal/components/form/Calendar/Calendar.js +5 -5
- package/dist/_internal/components/form/Calendar/CalendarSelectorsMonth.js +3 -3
- package/dist/_internal/components/form/CategorySelect/CategoryPanel.js +8 -8
- package/dist/_internal/components/form/CategorySelect/CategoryPanelFoot.js +4 -4
- package/dist/_internal/components/form/CategorySelect/CategoryPanelHead.js +4 -4
- package/dist/_internal/components/form/CategorySelect/CategoryPanelList.js +5 -5
- package/dist/_internal/components/form/CategorySelect/CategoryRows.js +4 -4
- package/dist/_internal/components/form/CategorySelect/CategorySelect.js +11 -11
- package/dist/_internal/components/form/CategorySelect/CategorySelect.styles.js +3 -3
- package/dist/_internal/components/form/CategorySelect/CategoryTrigger.js +4 -4
- package/dist/_internal/components/form/CepField/CepField.js +6 -6
- package/dist/_internal/components/form/Checkbox/Checkbox.js +2 -2
- package/dist/_internal/components/form/CodeEditor/CodeEditor.js +3 -3
- package/dist/_internal/components/form/Command/Command.js +3 -3
- package/dist/_internal/components/form/Command/Command.styles.js +3 -3
- package/dist/_internal/components/form/CreatableSelect/CreatableSelect.js +3 -3
- package/dist/_internal/components/form/DateRangePicker/DateRangePicker.hooks.js +5 -5
- package/dist/_internal/components/form/DateRangePicker/DateRangePicker.js +12 -12
- package/dist/_internal/components/form/DateRangePicker/DateRangePicker.range.js +4 -4
- package/dist/_internal/components/form/DateRangePicker/DateRangePickerFields.js +5 -5
- package/dist/_internal/components/form/Input/Input.factory.js +4 -4
- package/dist/_internal/components/form/Input/Input.js +5 -5
- package/dist/_internal/components/form/Input/Input.styles.js +3 -3
- package/dist/_internal/components/form/InputOTP/InputOTP.js +4 -4
- package/dist/_internal/components/form/InputOTP/InputOTP.styles.js +3 -3
- package/dist/_internal/components/form/Label/Label.js +3 -3
- package/dist/_internal/components/form/Label/Label.styles.js +3 -3
- package/dist/_internal/components/form/Menubar/Menubar.item.js +3 -3
- package/dist/_internal/components/form/Menubar/Menubar.js +7 -7
- package/dist/_internal/components/form/Menubar/Menubar.styles.js +3 -3
- package/dist/_internal/components/form/Menubar/Menubar.toolbar.js +5 -5
- package/dist/_internal/components/form/NumberField/NumberField.js +6 -6
- package/dist/_internal/components/form/PhoneInput/PhoneInput.hooks.js +2 -2
- package/dist/_internal/components/form/PhoneInput/PhoneInput.js +5 -5
- package/dist/_internal/components/form/PickerSheet/PickerSheet.js +6 -6
- package/dist/_internal/components/form/PickerSheet/PickerSheet.parts.js +4 -4
- package/dist/_internal/components/form/PickerSheet/PickerSheet.styles.js +3 -3
- package/dist/_internal/components/form/RadioGroup/RadioGroup.js +5 -5
- package/dist/_internal/components/form/RadioGroup/RadioGroup.styles.js +3 -3
- package/dist/_internal/components/form/RadioGroup/RadioGroup.variants.js +4 -4
- package/dist/_internal/components/form/RichTextEditor/RichTextEditor.js +2 -2
- package/dist/_internal/components/form/Select/Select.js +6 -6
- package/dist/_internal/components/form/Select/Select.menu.js +4 -4
- package/dist/_internal/components/form/Select/Select.searchable.js +4 -4
- package/dist/_internal/components/form/Select/Select.styles.js +3 -3
- package/dist/_internal/components/form/Textarea/Textarea.js +3 -3
- package/dist/_internal/components/form/Textarea/TextareaRichEditor.js +4 -4
- package/dist/_internal/components/form/Toggle/Toggle.js +4 -4
- package/dist/_internal/components/form/Toggle/Toggle.styles.js +3 -3
- package/dist/_internal/components/form/ToggleGroup/ToggleGroup.js +3 -3
- package/dist/_internal/components/form/index.js +59 -59
- package/dist/_internal/components/form/total-form/Fields/CategoryField.js +12 -12
- package/dist/_internal/components/form/total-form/Fields/CepField.js +7 -7
- package/dist/_internal/components/form/total-form/Fields/SelectField.js +7 -7
- package/dist/_internal/components/form/total-form/Fields/TextField.js +6 -6
- package/dist/_internal/components/form/total-form/Fields/ToggleField.js +4 -4
- package/dist/_internal/components/form/total-form/Fields/index.js +31 -31
- package/dist/_internal/components/form/total-form/SubmitButton.js +5 -5
- package/dist/_internal/components/index.js +222 -205
- package/dist/_internal/components/layout/Box/Box.js +6 -6
- package/dist/_internal/components/layout/ContentToolbar/ColumnsMenu.js +3 -3
- package/dist/_internal/components/layout/ContentToolbar/FilterTrigger.js +3 -3
- package/dist/_internal/components/layout/ContentToolbar/MultiSelectDropdown.js +4 -4
- package/dist/_internal/components/layout/ContentToolbar/MultiSelectTriggers.js +3 -3
- package/dist/_internal/components/layout/ContentToolbar/SavedViewsMenu.js +3 -3
- package/dist/_internal/components/layout/ContentToolbar/SortByDropdown.js +3 -3
- package/dist/_internal/components/layout/ContentToolbar/ViewSelector.js +3 -3
- package/dist/_internal/components/layout/Screen/Screen.js +7 -7
- package/dist/_internal/components/layout/SettingCard/SettingCard.js +11 -11
- package/dist/_internal/components/layout/SettingCard/SettingCard.parts.js +9 -9
- package/dist/_internal/components/layout/SettingCard/SettingCard.summary.js +10 -10
- package/dist/_internal/components/layout/SettingCard/SettingGrid.js +10 -10
- package/dist/_internal/components/layout/SettingCard/SettingGroup.js +12 -12
- package/dist/_internal/components/layout/SettingCard/SettingSwitch.js +11 -11
- package/dist/_internal/components/layout/SettingCard/SettingToggle.js +12 -12
- package/dist/_internal/components/layout/SettingsLayout/SettingsLayout.js +2 -2
- package/dist/_internal/components/layout/Skeleton/Skeleton.js +2 -2
- package/dist/_internal/components/layout/Stack/Stack.js +7 -7
- package/dist/_internal/components/layout/TableFilter/TableFilter.js +3 -3
- package/dist/_internal/components/layout/index.js +34 -34
- package/dist/_internal/components/navigation/AppHeader/AppHeader.details.js +9 -9
- package/dist/_internal/components/navigation/AppHeader/AppHeader.identity.js +3 -3
- package/dist/_internal/components/navigation/CommandPalette/CommandPalette.js +2 -2
- package/dist/_internal/components/navigation/Pagination/Pagination.js +4 -4
- package/dist/_internal/components/navigation/Pagination/PaginationParts.js +3 -3
- package/dist/_internal/components/navigation/SectionNav/SectionNav.bar.js +3 -3
- package/dist/_internal/components/navigation/SectionNav/SectionNav.js +4 -4
- package/dist/_internal/components/navigation/SectionNav/SectionNav.parts.js +3 -3
- package/dist/_internal/components/navigation/SectionNav/SectionNav.primary.js +3 -3
- package/dist/_internal/components/navigation/SectionNav/SectionNav.rail.js +3 -3
- package/dist/_internal/components/navigation/SectionNav/SectionNav.railCreate.js +3 -3
- package/dist/_internal/components/navigation/SectionNav/SectionNav.sheet.js +3 -3
- package/dist/_internal/components/navigation/SectionNav/__stories__/fixtures.js +3 -3
- package/dist/_internal/components/navigation/Tabs/Tabs.js +2 -2
- package/dist/_internal/components/navigation/Tabs/Tabs.styles.js +2 -2
- package/dist/_internal/components/navigation/index.js +18 -18
- package/dist/_internal/components/utility/WorkflowStep/WorkflowStep.helpers.js +3 -3
- package/dist/_internal/components/utility/WorkflowStep/WorkflowStep.js +3 -3
- package/dist/_internal/components/utility/WorkflowStep/WorkflowStep.parts.js +3 -3
- package/dist/_internal/components/utility/WorkflowStep/WorkflowStepRow.js +3 -3
- package/dist/_internal/components/utility/index.js +16 -16
- package/dist/_internal/en-US.data-display.js +2 -2
- package/dist/_internal/icons/Icon.js +6 -6
- package/dist/_internal/provider/UiProvider.js +5 -5
- package/dist/_internal/provider/mui-bridge.js +4 -4
- package/dist/_internal/provider/use-ui-theme.js +5 -5
- package/dist/_internal/pt-BR.data-display.js +2 -2
- package/dist/_internal/social-login-button/social-login-button.js +5 -5
- package/dist/_internal/tokens/density.js +3 -3
- package/dist/_internal/tokens/field-height.js +2 -2
- package/dist/_internal/user-avatar/user-avatar.js +5 -5
- package/dist/charts.js +14 -14
- package/dist/{chunk-3RHU2Y2N.js → chunk-2DDCRHJE.js} +2 -2
- package/dist/{chunk-6ONQTXFM.js → chunk-2GDPZ53K.js} +2 -2
- package/dist/{chunk-X3EB67O2.js → chunk-2VRJ577J.js} +4 -4
- package/dist/{chunk-QSRZOXQI.js → chunk-2WVHZIWP.js} +2 -2
- package/dist/{chunk-6OYB3MRF.js → chunk-33AVAYCR.js} +3 -3
- package/dist/{chunk-62SXUU5U.js → chunk-3DPPDGOF.js} +5 -5
- package/dist/{chunk-RXKFPXVH.js → chunk-3IX2TP4I.js} +2 -2
- package/dist/chunk-3OL2TSEJ.js +80 -0
- package/dist/chunk-3OL2TSEJ.js.map +1 -0
- package/dist/{chunk-BTGXHQX3.js → chunk-4JNC5AEF.js} +2 -2
- package/dist/{chunk-6MOJK2QT.js → chunk-4SQ2WCZA.js} +2 -2
- package/dist/{chunk-QHFAKEZZ.js → chunk-4V37DAMA.js} +3 -3
- package/dist/{chunk-PWXDMP7G.js → chunk-52RHAAIH.js} +10 -10
- package/dist/{chunk-E3E4L7MH.js → chunk-56GWNA5V.js} +5 -5
- package/dist/{chunk-I54LHHZS.js → chunk-5CP5Z3YU.js} +2 -2
- package/dist/{chunk-L6UTYEUS.js → chunk-5S5K73I6.js} +3 -3
- package/dist/{chunk-RBW5QQXW.js → chunk-5XTPEA3O.js} +2 -2
- package/dist/{chunk-LOGSJH2Q.js → chunk-5ZC7CNU4.js} +2 -2
- package/dist/{chunk-V4JMZZGH.js → chunk-6A4PTK5Q.js} +5 -5
- package/dist/{chunk-2P5ZBBTL.js → chunk-6GICMRDX.js} +5 -5
- package/dist/{chunk-QOTMQLMW.js → chunk-6OISIUZM.js} +3 -3
- package/dist/{chunk-34FX3NRZ.js → chunk-6PTP5NID.js} +2 -2
- package/dist/{chunk-3XZZSHE5.js → chunk-6VTOGR36.js} +5 -5
- package/dist/{chunk-RLDTV5I2.js → chunk-6WHIJPEF.js} +2 -2
- package/dist/{chunk-6LMYQJZP.js → chunk-6YSGP2WS.js} +3 -2
- package/dist/{chunk-6LMYQJZP.js.map → chunk-6YSGP2WS.js.map} +1 -1
- package/dist/{chunk-D7SOXI2K.js → chunk-72HOUWAW.js} +2 -2
- package/dist/{chunk-2D4WKET2.js → chunk-75FHDUJW.js} +5 -5
- package/dist/{chunk-AAREDFH6.js → chunk-7TKQIZ3K.js} +2 -2
- package/dist/{chunk-WPFVQVQC.js → chunk-7VUXSNVZ.js} +5 -5
- package/dist/chunk-A63WU4UZ.js +226 -0
- package/dist/chunk-A63WU4UZ.js.map +1 -0
- package/dist/chunk-ABRUOINB.js +1 -0
- package/dist/chunk-ABRUOINB.js.map +1 -0
- package/dist/{chunk-UERGWYGY.js → chunk-ABRVOPC2.js} +3 -3
- package/dist/{chunk-M74YHHJE.js → chunk-ACBHZG3Z.js} +5 -5
- package/dist/chunk-ACFKPE2T.js +1 -0
- package/dist/chunk-ACFKPE2T.js.map +1 -0
- package/dist/{chunk-GPTNZ57P.js → chunk-ARMKSYEQ.js} +3 -3
- package/dist/{chunk-MHFXJRLD.js → chunk-AT6UKTH4.js} +2 -2
- package/dist/{chunk-O4G7QKDU.js → chunk-AWUFS2ZC.js} +7 -7
- package/dist/{chunk-66QQ7YQN.js → chunk-AYJGRQT4.js} +3 -2
- package/dist/{chunk-66QQ7YQN.js.map → chunk-AYJGRQT4.js.map} +1 -1
- package/dist/{chunk-YWJCMGTE.js → chunk-BECKKDYG.js} +2 -2
- package/dist/{chunk-64UNVW6D.js → chunk-BP3ZKIPE.js} +4 -4
- package/dist/{chunk-ENRB6PIN.js → chunk-BRHRK7BK.js} +2 -2
- package/dist/chunk-BRZKOUEL.js +115 -0
- package/dist/chunk-BRZKOUEL.js.map +1 -0
- package/dist/{chunk-Z47SYKRX.js → chunk-C74PDNTF.js} +3 -3
- package/dist/{chunk-KEBYZ2MO.js → chunk-CARUHKZW.js} +11 -11
- package/dist/{chunk-3HSLEUVW.js → chunk-CBO46LJH.js} +5 -5
- package/dist/{chunk-EMSMJRP3.js → chunk-CESGZRVQ.js} +4 -4
- package/dist/{chunk-LODYTVOO.js → chunk-CFDWKQZT.js} +2 -2
- package/dist/chunk-COOSJKZL.js +197 -0
- package/dist/chunk-COOSJKZL.js.map +1 -0
- package/dist/{chunk-TPAMLIN7.js → chunk-CPZGFIFH.js} +2 -2
- package/dist/{chunk-UIWVSZ6I.js → chunk-CSGBHYW6.js} +2 -2
- package/dist/{chunk-JW7MN4DG.js → chunk-D34PZJH3.js} +2 -2
- package/dist/{chunk-WT7VZDTI.js → chunk-DDNUPFPE.js} +5 -5
- package/dist/{chunk-LZ5PGB7U.js → chunk-DYRZRY2T.js} +5 -5
- package/dist/{chunk-73BMQ3VC.js → chunk-ENJOBJPK.js} +2 -2
- package/dist/{chunk-U36BXXQ7.js → chunk-EP3DRILI.js} +2 -2
- package/dist/{chunk-W2JYXZC2.js → chunk-FCLON3MO.js} +3 -3
- package/dist/{chunk-I5NTADBO.js → chunk-FEKWKWGK.js} +4 -4
- package/dist/{chunk-33MMQHYU.js → chunk-FJ3UZ4RC.js} +2 -2
- package/dist/{chunk-LNIK7FJO.js → chunk-FORQEHRQ.js} +2 -2
- package/dist/{chunk-N3W6FZOC.js → chunk-FQGPYP2M.js} +4 -4
- package/dist/{chunk-MAHY7PK3.js → chunk-FQMLTCXT.js} +4 -4
- package/dist/{chunk-BDJIP4HG.js → chunk-FRUDRDJX.js} +4 -4
- package/dist/{chunk-MO4FFK62.js → chunk-FXECKKPW.js} +3 -3
- package/dist/{chunk-UWVVKUCG.js → chunk-FZEDQNUN.js} +3 -3
- package/dist/{chunk-YASSCBWN.js → chunk-GHP5JLL3.js} +2 -2
- package/dist/{chunk-3S352ZSG.js → chunk-GLR5MSU3.js} +2 -2
- package/dist/chunk-GMRQPNG3.js +80 -0
- package/dist/chunk-GMRQPNG3.js.map +1 -0
- package/dist/{chunk-ATJTGQYE.js → chunk-GOQOVKUZ.js} +3 -3
- package/dist/{chunk-REMODSVN.js → chunk-HDTFLW42.js} +2 -2
- package/dist/{chunk-SFVHZAGE.js → chunk-HG2YLNGJ.js} +2 -2
- package/dist/{chunk-OKDAHCYE.js → chunk-HJJR2WGL.js} +2 -2
- package/dist/{chunk-J34VGMA5.js → chunk-HNEZWVDR.js} +2 -2
- package/dist/{chunk-MGFTHOPG.js → chunk-HUXAIQC5.js} +2 -2
- package/dist/{chunk-OUI5IPS6.js → chunk-HWPQKHN2.js} +6 -6
- package/dist/{chunk-PGVGCDPD.js → chunk-I7JUAHUO.js} +3 -3
- package/dist/{chunk-LC6ND4ET.js → chunk-IBOFASAZ.js} +2 -2
- package/dist/{chunk-TNDTEI6D.js → chunk-IDRVQVDL.js} +2 -2
- package/dist/{chunk-4PUCT3RX.js → chunk-IEAPXS57.js} +2 -2
- package/dist/{chunk-NQCTANF3.js → chunk-IF5UY3CT.js} +4 -4
- package/dist/{chunk-OQ554425.js → chunk-IFX5KP65.js} +4 -4
- package/dist/{chunk-VQBY73QH.js → chunk-IMCSY2SI.js} +6 -6
- package/dist/{chunk-BARTUKJU.js → chunk-IU2WSJ4F.js} +2 -2
- package/dist/{chunk-GVSRBFP3.js → chunk-IYDXKLCE.js} +7 -7
- package/dist/{chunk-5NT2M2JI.js → chunk-JKIKHWD2.js} +4 -4
- package/dist/{chunk-IKXCAYFH.js → chunk-JVTZ7FWR.js} +2 -2
- package/dist/{chunk-DPHSJLMN.js → chunk-JZQYVGPV.js} +2 -2
- package/dist/{chunk-3W2B7IZG.js → chunk-K6WY2CHG.js} +2 -2
- package/dist/{chunk-RWCQ6TEM.js → chunk-KR4TN3OF.js} +2 -2
- package/dist/{chunk-SUCVFEPT.js → chunk-KRPDBVUB.js} +5 -5
- package/dist/{chunk-LRIPJ2D5.js → chunk-KRYOT3KB.js} +2 -2
- package/dist/{chunk-3V3Z4EML.js → chunk-L4FWEI2P.js} +5 -5
- package/dist/{chunk-I3OKAQ5L.js → chunk-L7HNQRFS.js} +7 -7
- package/dist/{chunk-J7C7FPVO.js → chunk-LABIUXDM.js} +2 -2
- package/dist/{chunk-GM7BG3SD.js → chunk-LLPPIO3K.js} +3 -3
- package/dist/{chunk-RCTHCXS6.js → chunk-LRQT4MQO.js} +2 -2
- package/dist/{chunk-LTSVYILY.js → chunk-LXMFHD7M.js} +4 -4
- package/dist/{chunk-72OG3AGH.js → chunk-LYB6YYTG.js} +2 -2
- package/dist/{chunk-DRJL3JHR.js → chunk-LZJHHMOF.js} +2 -2
- package/dist/{chunk-Y4KR4LT2.js → chunk-MIUPTZS6.js} +2 -2
- package/dist/{chunk-XXUTD74L.js → chunk-MK6UXAWY.js} +3 -3
- package/dist/{chunk-BIUT3K6A.js → chunk-MKNW4FRR.js} +6 -6
- package/dist/{chunk-NZDIO5UG.js → chunk-MVNFUIJS.js} +5 -5
- package/dist/{chunk-APBIQH4G.js → chunk-N5OEDOJT.js} +7 -7
- package/dist/{chunk-UAOE3ZPC.js → chunk-NEYZV6V5.js} +6 -6
- package/dist/{chunk-ZXHODKHH.js → chunk-NKHNUTTY.js} +3 -3
- package/dist/{chunk-JL4I7OQE.js → chunk-NOF2FF4K.js} +2 -2
- package/dist/{chunk-WOSUYOAU.js → chunk-NQYC7V5N.js} +5 -5
- package/dist/{chunk-2XI4R6UO.js → chunk-NTRWUDP6.js} +2 -2
- package/dist/{chunk-ZCCKIWZU.js → chunk-NYA26GV2.js} +2 -2
- package/dist/{chunk-N3LW5ER5.js → chunk-NZBEE2PR.js} +3 -3
- package/dist/{chunk-RUQNKOSP.js → chunk-OPY2AGAU.js} +4 -4
- package/dist/{chunk-FYJDI5BW.js → chunk-OQN2FHEL.js} +3 -3
- package/dist/{chunk-WNIL2KTB.js → chunk-OQW4OERS.js} +3 -3
- package/dist/{chunk-KG7OTJ26.js → chunk-OZYUE2BI.js} +2 -2
- package/dist/{chunk-Y3TD7HOY.js → chunk-P4Q7JK4L.js} +2 -2
- package/dist/{chunk-W676GY42.js → chunk-P772HCHI.js} +4 -4
- package/dist/chunk-PBRCKHN3.js +75 -0
- package/dist/chunk-PBRCKHN3.js.map +1 -0
- package/dist/{chunk-4AJY7HMH.js → chunk-PD7MKJCM.js} +5 -5
- package/dist/{chunk-ICKR3QTG.js → chunk-PGHSNG33.js} +4 -4
- package/dist/{chunk-ZNJGEDCE.js → chunk-PGYYDSNX.js} +2 -2
- package/dist/{chunk-KXTNTDRD.js → chunk-PPEHBI5O.js} +2 -2
- package/dist/{chunk-5RPT32EL.js → chunk-PVIQDBUN.js} +2 -2
- package/dist/{chunk-N3ZOZWP5.js → chunk-Q3HYEAVQ.js} +2 -2
- package/dist/{chunk-HKQQ2NED.js → chunk-Q4GAPZDA.js} +2 -2
- package/dist/{chunk-VUBFCHXL.js → chunk-Q7XLTN2D.js} +3 -3
- package/dist/{chunk-YQIT3ET7.js → chunk-QAH3XILB.js} +3 -3
- package/dist/{chunk-YH7G44WL.js → chunk-QLJU7UUI.js} +2 -2
- package/dist/{chunk-TVMSXL3R.js → chunk-QO7UJXXO.js} +2 -2
- package/dist/{chunk-EXTES7LP.js → chunk-QZOQVJ5L.js} +4 -4
- package/dist/{chunk-QQHZBJMU.js → chunk-RGVNXES5.js} +4 -4
- package/dist/{chunk-MWPD2BXO.js → chunk-RHVJ3L4U.js} +2 -2
- package/dist/{chunk-YV4O7KDR.js → chunk-S6HIZQIG.js} +5 -5
- package/dist/{chunk-MQVIYTH5.js → chunk-SAKSIN7E.js} +2 -2
- package/dist/{chunk-4HBCWKIX.js → chunk-SGFRSRAL.js} +2 -2
- package/dist/{chunk-WLLUARTC.js → chunk-T2G4LDU5.js} +2 -2
- package/dist/{chunk-37G7M2GJ.js → chunk-T6QVM5Q5.js} +5 -5
- package/dist/{chunk-BLNFOP2O.js → chunk-T6YTDEY4.js} +4 -4
- package/dist/{chunk-QTLM2YY2.js → chunk-TI4FGQYV.js} +2 -2
- package/dist/{chunk-6HMDUUVJ.js → chunk-TRYR424I.js} +4 -4
- package/dist/{chunk-V2UJEICC.js → chunk-TVDHA7BT.js} +8 -8
- package/dist/{chunk-74KCGLOU.js → chunk-U2ILXZDG.js} +2 -2
- package/dist/{chunk-TR7ZA67L.js → chunk-U2QV4TTZ.js} +2 -2
- package/dist/{chunk-GNDIVKWF.js → chunk-U3HGQHEO.js} +3 -3
- package/dist/{chunk-3YFDGFEK.js → chunk-U4WAAZXJ.js} +2 -2
- package/dist/{chunk-UQUN2NGE.js → chunk-UAFSEZ2E.js} +2 -2
- package/dist/{chunk-D5Y4PNC5.js → chunk-ULAZDF6D.js} +2 -2
- package/dist/{chunk-3OWFUFZL.js → chunk-UMI3GYWI.js} +6 -6
- package/dist/{chunk-Q7QQXNL7.js → chunk-UT545JBQ.js} +3 -3
- package/dist/{chunk-JXK53XJW.js → chunk-UTUYXH72.js} +5 -5
- package/dist/{chunk-E72INDBL.js → chunk-UXOFA3ZP.js} +4 -4
- package/dist/{chunk-PDSZN26U.js → chunk-V6KQ5R4T.js} +11 -11
- package/dist/{chunk-FLJ3RIRP.js → chunk-VEKTKCSB.js} +5 -5
- package/dist/{chunk-UJACXYC2.js → chunk-VHGHF537.js} +3 -3
- package/dist/{chunk-OFXCSLGX.js → chunk-VLH3IMJG.js} +2 -2
- package/dist/{chunk-AKBL7S7A.js → chunk-VPGDYI63.js} +5 -5
- package/dist/{chunk-6DGNMASB.js → chunk-VPH3TENY.js} +2 -2
- package/dist/{chunk-45AON4CS.js → chunk-VYQZ5U3N.js} +2 -2
- package/dist/{chunk-GXSHLMT4.js → chunk-WDSJ6SVY.js} +2 -2
- package/dist/{chunk-JMDT3GQ3.js → chunk-WMAS6DZR.js} +3 -3
- package/dist/{chunk-XE7QBHXN.js → chunk-WTOA52EQ.js} +2 -2
- package/dist/{chunk-ILNAPS44.js → chunk-XMWTVDQN.js} +20 -20
- package/dist/{chunk-JIAIPOEV.js → chunk-XNMU32XC.js} +2 -2
- package/dist/{chunk-PEMXXFXL.js → chunk-XQJPR57I.js} +2 -2
- package/dist/{chunk-54F7QIV2.js → chunk-XW44IFYE.js} +5 -5
- package/dist/{chunk-I2KAN3YB.js → chunk-Y3LK6ZQG.js} +2 -2
- package/dist/{chunk-7AC2UGTU.js → chunk-Y46R26TE.js} +3 -3
- package/dist/{chunk-GQ2T44BC.js → chunk-YEKPQAOW.js} +2 -2
- package/dist/{chunk-YC2QYRNE.js → chunk-YGWLMTPB.js} +2 -2
- package/dist/{chunk-H56CRMCM.js → chunk-YHPSPFU5.js} +9 -9
- package/dist/{chunk-F6LZHF4O.js → chunk-YTDUIU7X.js} +2 -2
- package/dist/{chunk-CO7GH3W7.js → chunk-YWXCLPCX.js} +2 -2
- package/dist/{chunk-RIPG3QIN.js → chunk-Z445LLFN.js} +4 -4
- package/dist/{chunk-M7HYNXCU.js → chunk-ZAPP32GD.js} +2 -2
- package/dist/{chunk-C2OX3C7L.js → chunk-ZLVRCQPG.js} +7 -7
- package/dist/{chunk-SGAHME6W.js → chunk-ZVZTQF7E.js} +4 -4
- package/dist/data-display/Alert.js +2 -2
- package/dist/data-display/AsyncStateContainer.js +4 -4
- package/dist/data-display/Badge.js +3 -3
- package/dist/data-display/CardKit.js +10 -10
- package/dist/data-display/Carousel.js +10 -10
- package/dist/data-display/Chart.js +14 -14
- package/dist/data-display/DataGrid.js +1 -1
- package/dist/data-display/DataViews.js +88 -88
- package/dist/data-display/FleetMap.js +24 -24
- package/dist/data-display/LazyImage.js +5 -5
- package/dist/data-display/Lightbox.js +6 -6
- package/dist/data-display/LoadingState.js +3 -3
- package/dist/data-display/MapPreview.js +16 -16
- package/dist/data-display/Progress.js +2 -2
- package/dist/data-display/RegionMap.js +45 -0
- package/dist/data-display/RegionMap.js.map +1 -0
- package/dist/data-display/Sheet.js +6 -6
- package/dist/data-display/StatCard.js +3 -3
- package/dist/data-display/Table.js +2 -2
- package/dist/en-US.js +6 -6
- package/dist/feedback/ConfirmAction.js +5 -5
- package/dist/feedback/Modal.js +2 -2
- package/dist/feedback/NotificationStatusNotice.js +7 -7
- package/dist/feedback/SequenceResolver.js +10 -10
- package/dist/form/AddressAutocomplete.js +8 -8
- package/dist/form/Autocomplete.js +4 -4
- package/dist/form/Button.js +4 -4
- package/dist/form/Calendar.js +5 -5
- package/dist/form/CategorySelect.js +11 -11
- package/dist/form/CepField.js +6 -6
- package/dist/form/Checkbox.js +2 -2
- package/dist/form/CodeEditor.js +3 -3
- package/dist/form/Command.js +3 -3
- package/dist/form/CreatableSelect.js +3 -3
- package/dist/form/DateRangePicker.js +12 -12
- package/dist/form/Input/outlined.js +5 -5
- package/dist/form/Input.js +5 -5
- package/dist/form/InputOTP.js +4 -4
- package/dist/form/Label.js +3 -3
- package/dist/form/MenuSelect.js +4 -4
- package/dist/form/Menubar.js +7 -7
- package/dist/form/NumberField.js +6 -6
- package/dist/form/PhoneInput.js +5 -5
- package/dist/form/PickerSheet.js +6 -6
- package/dist/form/RadioGroup.js +5 -5
- package/dist/form/RichTextEditor.js +2 -2
- package/dist/form/Select.js +6 -6
- package/dist/form/Textarea.js +3 -3
- package/dist/form/Toggle.js +4 -4
- package/dist/form/ToggleGroup.js +3 -3
- package/dist/form/total-form.js +34 -34
- package/dist/icons.js +6 -6
- package/dist/layout/Box.js +6 -6
- package/dist/layout/ContentToolbar.js +12 -12
- package/dist/layout/Screen.js +7 -7
- package/dist/layout/SettingCard.js +15 -15
- package/dist/layout/SettingsLayout.js +2 -2
- package/dist/layout/Skeleton.js +2 -2
- package/dist/layout/Stack.js +7 -7
- package/dist/layout/TableFilter.js +3 -3
- package/dist/locales.js +14 -14
- package/dist/navigation/AppHeader.js +9 -9
- package/dist/navigation/CommandPalette.js +2 -2
- package/dist/navigation/Pagination.js +4 -4
- package/dist/navigation/SectionNav.js +4 -4
- package/dist/navigation/Tabs.js +2 -2
- package/dist/provider.js +6 -6
- package/dist/pt-BR.js +8 -8
- package/dist/social-login-button.js +5 -5
- package/dist/tokens.js +4 -4
- package/dist/types/components/data-display/RegionMap/RegionMap.d.ts +25 -0
- package/dist/types/components/data-display/RegionMap/RegionMap.d.ts.map +1 -0
- package/dist/types/components/data-display/RegionMap/RegionMap.fixtures.d.ts +27 -0
- package/dist/types/components/data-display/RegionMap/RegionMap.fixtures.d.ts.map +1 -0
- package/dist/types/components/data-display/RegionMap/RegionMap.helpers.d.ts +110 -0
- package/dist/types/components/data-display/RegionMap/RegionMap.helpers.d.ts.map +1 -0
- package/dist/types/components/data-display/RegionMap/RegionMap.hooks.d.ts +28 -0
- package/dist/types/components/data-display/RegionMap/RegionMap.hooks.d.ts.map +1 -0
- package/dist/types/components/data-display/RegionMap/RegionMap.types.d.ts +116 -0
- package/dist/types/components/data-display/RegionMap/RegionMap.types.d.ts.map +1 -0
- package/dist/types/components/data-display/RegionMap/RegionMapDrawing.d.ts +28 -0
- package/dist/types/components/data-display/RegionMap/RegionMapDrawing.d.ts.map +1 -0
- package/dist/types/components/data-display/RegionMap/RegionMapLegend.d.ts +12 -0
- package/dist/types/components/data-display/RegionMap/RegionMapLegend.d.ts.map +1 -0
- package/dist/types/components/data-display/RegionMap/RegionMapList.d.ts +20 -0
- package/dist/types/components/data-display/RegionMap/RegionMapList.d.ts.map +1 -0
- package/dist/types/components/data-display/RegionMap/index.d.ts +5 -0
- package/dist/types/components/data-display/RegionMap/index.d.ts.map +1 -0
- package/dist/types/components/data-display/index.d.ts +1 -0
- package/dist/types/components/data-display/index.d.ts.map +1 -1
- package/dist/types/components/form/total-form/Fields/SelectField.d.ts.map +1 -1
- package/dist/types/components/form/total-form/Fields/ToggleField.d.ts.map +1 -1
- package/dist/user-avatar.js +5 -5
- package/dist/utility/WorkflowStep.js +3 -3
- package/package.json +5 -1
- package/src/components/data-display/RegionMap/RegionMap.fixtures.ts +67 -0
- package/src/components/data-display/RegionMap/RegionMap.helpers.ts +338 -0
- package/src/components/data-display/RegionMap/RegionMap.hooks.ts +125 -0
- package/src/components/data-display/RegionMap/RegionMap.md +144 -0
- package/src/components/data-display/RegionMap/RegionMap.tsx +88 -0
- package/src/components/data-display/RegionMap/RegionMap.types.ts +117 -0
- package/src/components/data-display/RegionMap/RegionMapDrawing.tsx +299 -0
- package/src/components/data-display/RegionMap/RegionMapLegend.tsx +81 -0
- package/src/components/data-display/RegionMap/RegionMapList.tsx +167 -0
- package/src/components/data-display/RegionMap/index.ts +13 -0
- package/src/components/data-display/RegionMap/tests.md +22 -0
- package/src/components/data-display/RegionMap/track.md +13 -0
- package/src/components/data-display/index.ts +1 -0
- package/src/components/form/total-form/Fields/SelectField.tsx +4 -0
- package/src/components/form/total-form/Fields/ToggleField.tsx +3 -0
- package/dist/chunk-CDCTLPMD.js +0 -1
- /package/dist/{chunk-CDCTLPMD.js.map → _internal/components/data-display/RegionMap/RegionMap.helpers.js.map} +0 -0
- /package/dist/{chunk-3RHU2Y2N.js.map → chunk-2DDCRHJE.js.map} +0 -0
- /package/dist/{chunk-6ONQTXFM.js.map → chunk-2GDPZ53K.js.map} +0 -0
- /package/dist/{chunk-X3EB67O2.js.map → chunk-2VRJ577J.js.map} +0 -0
- /package/dist/{chunk-QSRZOXQI.js.map → chunk-2WVHZIWP.js.map} +0 -0
- /package/dist/{chunk-6OYB3MRF.js.map → chunk-33AVAYCR.js.map} +0 -0
- /package/dist/{chunk-62SXUU5U.js.map → chunk-3DPPDGOF.js.map} +0 -0
- /package/dist/{chunk-RXKFPXVH.js.map → chunk-3IX2TP4I.js.map} +0 -0
- /package/dist/{chunk-BTGXHQX3.js.map → chunk-4JNC5AEF.js.map} +0 -0
- /package/dist/{chunk-6MOJK2QT.js.map → chunk-4SQ2WCZA.js.map} +0 -0
- /package/dist/{chunk-QHFAKEZZ.js.map → chunk-4V37DAMA.js.map} +0 -0
- /package/dist/{chunk-PWXDMP7G.js.map → chunk-52RHAAIH.js.map} +0 -0
- /package/dist/{chunk-E3E4L7MH.js.map → chunk-56GWNA5V.js.map} +0 -0
- /package/dist/{chunk-I54LHHZS.js.map → chunk-5CP5Z3YU.js.map} +0 -0
- /package/dist/{chunk-L6UTYEUS.js.map → chunk-5S5K73I6.js.map} +0 -0
- /package/dist/{chunk-RBW5QQXW.js.map → chunk-5XTPEA3O.js.map} +0 -0
- /package/dist/{chunk-LOGSJH2Q.js.map → chunk-5ZC7CNU4.js.map} +0 -0
- /package/dist/{chunk-V4JMZZGH.js.map → chunk-6A4PTK5Q.js.map} +0 -0
- /package/dist/{chunk-2P5ZBBTL.js.map → chunk-6GICMRDX.js.map} +0 -0
- /package/dist/{chunk-QOTMQLMW.js.map → chunk-6OISIUZM.js.map} +0 -0
- /package/dist/{chunk-34FX3NRZ.js.map → chunk-6PTP5NID.js.map} +0 -0
- /package/dist/{chunk-3XZZSHE5.js.map → chunk-6VTOGR36.js.map} +0 -0
- /package/dist/{chunk-RLDTV5I2.js.map → chunk-6WHIJPEF.js.map} +0 -0
- /package/dist/{chunk-D7SOXI2K.js.map → chunk-72HOUWAW.js.map} +0 -0
- /package/dist/{chunk-2D4WKET2.js.map → chunk-75FHDUJW.js.map} +0 -0
- /package/dist/{chunk-AAREDFH6.js.map → chunk-7TKQIZ3K.js.map} +0 -0
- /package/dist/{chunk-WPFVQVQC.js.map → chunk-7VUXSNVZ.js.map} +0 -0
- /package/dist/{chunk-UERGWYGY.js.map → chunk-ABRVOPC2.js.map} +0 -0
- /package/dist/{chunk-M74YHHJE.js.map → chunk-ACBHZG3Z.js.map} +0 -0
- /package/dist/{chunk-GPTNZ57P.js.map → chunk-ARMKSYEQ.js.map} +0 -0
- /package/dist/{chunk-MHFXJRLD.js.map → chunk-AT6UKTH4.js.map} +0 -0
- /package/dist/{chunk-O4G7QKDU.js.map → chunk-AWUFS2ZC.js.map} +0 -0
- /package/dist/{chunk-YWJCMGTE.js.map → chunk-BECKKDYG.js.map} +0 -0
- /package/dist/{chunk-64UNVW6D.js.map → chunk-BP3ZKIPE.js.map} +0 -0
- /package/dist/{chunk-ENRB6PIN.js.map → chunk-BRHRK7BK.js.map} +0 -0
- /package/dist/{chunk-Z47SYKRX.js.map → chunk-C74PDNTF.js.map} +0 -0
- /package/dist/{chunk-KEBYZ2MO.js.map → chunk-CARUHKZW.js.map} +0 -0
- /package/dist/{chunk-3HSLEUVW.js.map → chunk-CBO46LJH.js.map} +0 -0
- /package/dist/{chunk-EMSMJRP3.js.map → chunk-CESGZRVQ.js.map} +0 -0
- /package/dist/{chunk-LODYTVOO.js.map → chunk-CFDWKQZT.js.map} +0 -0
- /package/dist/{chunk-TPAMLIN7.js.map → chunk-CPZGFIFH.js.map} +0 -0
- /package/dist/{chunk-UIWVSZ6I.js.map → chunk-CSGBHYW6.js.map} +0 -0
- /package/dist/{chunk-JW7MN4DG.js.map → chunk-D34PZJH3.js.map} +0 -0
- /package/dist/{chunk-WT7VZDTI.js.map → chunk-DDNUPFPE.js.map} +0 -0
- /package/dist/{chunk-LZ5PGB7U.js.map → chunk-DYRZRY2T.js.map} +0 -0
- /package/dist/{chunk-73BMQ3VC.js.map → chunk-ENJOBJPK.js.map} +0 -0
- /package/dist/{chunk-U36BXXQ7.js.map → chunk-EP3DRILI.js.map} +0 -0
- /package/dist/{chunk-W2JYXZC2.js.map → chunk-FCLON3MO.js.map} +0 -0
- /package/dist/{chunk-I5NTADBO.js.map → chunk-FEKWKWGK.js.map} +0 -0
- /package/dist/{chunk-33MMQHYU.js.map → chunk-FJ3UZ4RC.js.map} +0 -0
- /package/dist/{chunk-LNIK7FJO.js.map → chunk-FORQEHRQ.js.map} +0 -0
- /package/dist/{chunk-N3W6FZOC.js.map → chunk-FQGPYP2M.js.map} +0 -0
- /package/dist/{chunk-MAHY7PK3.js.map → chunk-FQMLTCXT.js.map} +0 -0
- /package/dist/{chunk-BDJIP4HG.js.map → chunk-FRUDRDJX.js.map} +0 -0
- /package/dist/{chunk-MO4FFK62.js.map → chunk-FXECKKPW.js.map} +0 -0
- /package/dist/{chunk-UWVVKUCG.js.map → chunk-FZEDQNUN.js.map} +0 -0
- /package/dist/{chunk-YASSCBWN.js.map → chunk-GHP5JLL3.js.map} +0 -0
- /package/dist/{chunk-3S352ZSG.js.map → chunk-GLR5MSU3.js.map} +0 -0
- /package/dist/{chunk-ATJTGQYE.js.map → chunk-GOQOVKUZ.js.map} +0 -0
- /package/dist/{chunk-REMODSVN.js.map → chunk-HDTFLW42.js.map} +0 -0
- /package/dist/{chunk-SFVHZAGE.js.map → chunk-HG2YLNGJ.js.map} +0 -0
- /package/dist/{chunk-OKDAHCYE.js.map → chunk-HJJR2WGL.js.map} +0 -0
- /package/dist/{chunk-J34VGMA5.js.map → chunk-HNEZWVDR.js.map} +0 -0
- /package/dist/{chunk-MGFTHOPG.js.map → chunk-HUXAIQC5.js.map} +0 -0
- /package/dist/{chunk-OUI5IPS6.js.map → chunk-HWPQKHN2.js.map} +0 -0
- /package/dist/{chunk-PGVGCDPD.js.map → chunk-I7JUAHUO.js.map} +0 -0
- /package/dist/{chunk-LC6ND4ET.js.map → chunk-IBOFASAZ.js.map} +0 -0
- /package/dist/{chunk-TNDTEI6D.js.map → chunk-IDRVQVDL.js.map} +0 -0
- /package/dist/{chunk-4PUCT3RX.js.map → chunk-IEAPXS57.js.map} +0 -0
- /package/dist/{chunk-NQCTANF3.js.map → chunk-IF5UY3CT.js.map} +0 -0
- /package/dist/{chunk-OQ554425.js.map → chunk-IFX5KP65.js.map} +0 -0
- /package/dist/{chunk-VQBY73QH.js.map → chunk-IMCSY2SI.js.map} +0 -0
- /package/dist/{chunk-BARTUKJU.js.map → chunk-IU2WSJ4F.js.map} +0 -0
- /package/dist/{chunk-GVSRBFP3.js.map → chunk-IYDXKLCE.js.map} +0 -0
- /package/dist/{chunk-5NT2M2JI.js.map → chunk-JKIKHWD2.js.map} +0 -0
- /package/dist/{chunk-IKXCAYFH.js.map → chunk-JVTZ7FWR.js.map} +0 -0
- /package/dist/{chunk-DPHSJLMN.js.map → chunk-JZQYVGPV.js.map} +0 -0
- /package/dist/{chunk-3W2B7IZG.js.map → chunk-K6WY2CHG.js.map} +0 -0
- /package/dist/{chunk-RWCQ6TEM.js.map → chunk-KR4TN3OF.js.map} +0 -0
- /package/dist/{chunk-SUCVFEPT.js.map → chunk-KRPDBVUB.js.map} +0 -0
- /package/dist/{chunk-LRIPJ2D5.js.map → chunk-KRYOT3KB.js.map} +0 -0
- /package/dist/{chunk-3V3Z4EML.js.map → chunk-L4FWEI2P.js.map} +0 -0
- /package/dist/{chunk-I3OKAQ5L.js.map → chunk-L7HNQRFS.js.map} +0 -0
- /package/dist/{chunk-J7C7FPVO.js.map → chunk-LABIUXDM.js.map} +0 -0
- /package/dist/{chunk-GM7BG3SD.js.map → chunk-LLPPIO3K.js.map} +0 -0
- /package/dist/{chunk-RCTHCXS6.js.map → chunk-LRQT4MQO.js.map} +0 -0
- /package/dist/{chunk-LTSVYILY.js.map → chunk-LXMFHD7M.js.map} +0 -0
- /package/dist/{chunk-72OG3AGH.js.map → chunk-LYB6YYTG.js.map} +0 -0
- /package/dist/{chunk-DRJL3JHR.js.map → chunk-LZJHHMOF.js.map} +0 -0
- /package/dist/{chunk-Y4KR4LT2.js.map → chunk-MIUPTZS6.js.map} +0 -0
- /package/dist/{chunk-XXUTD74L.js.map → chunk-MK6UXAWY.js.map} +0 -0
- /package/dist/{chunk-BIUT3K6A.js.map → chunk-MKNW4FRR.js.map} +0 -0
- /package/dist/{chunk-NZDIO5UG.js.map → chunk-MVNFUIJS.js.map} +0 -0
- /package/dist/{chunk-APBIQH4G.js.map → chunk-N5OEDOJT.js.map} +0 -0
- /package/dist/{chunk-UAOE3ZPC.js.map → chunk-NEYZV6V5.js.map} +0 -0
- /package/dist/{chunk-ZXHODKHH.js.map → chunk-NKHNUTTY.js.map} +0 -0
- /package/dist/{chunk-JL4I7OQE.js.map → chunk-NOF2FF4K.js.map} +0 -0
- /package/dist/{chunk-WOSUYOAU.js.map → chunk-NQYC7V5N.js.map} +0 -0
- /package/dist/{chunk-2XI4R6UO.js.map → chunk-NTRWUDP6.js.map} +0 -0
- /package/dist/{chunk-ZCCKIWZU.js.map → chunk-NYA26GV2.js.map} +0 -0
- /package/dist/{chunk-N3LW5ER5.js.map → chunk-NZBEE2PR.js.map} +0 -0
- /package/dist/{chunk-RUQNKOSP.js.map → chunk-OPY2AGAU.js.map} +0 -0
- /package/dist/{chunk-FYJDI5BW.js.map → chunk-OQN2FHEL.js.map} +0 -0
- /package/dist/{chunk-WNIL2KTB.js.map → chunk-OQW4OERS.js.map} +0 -0
- /package/dist/{chunk-KG7OTJ26.js.map → chunk-OZYUE2BI.js.map} +0 -0
- /package/dist/{chunk-Y3TD7HOY.js.map → chunk-P4Q7JK4L.js.map} +0 -0
- /package/dist/{chunk-W676GY42.js.map → chunk-P772HCHI.js.map} +0 -0
- /package/dist/{chunk-4AJY7HMH.js.map → chunk-PD7MKJCM.js.map} +0 -0
- /package/dist/{chunk-ICKR3QTG.js.map → chunk-PGHSNG33.js.map} +0 -0
- /package/dist/{chunk-ZNJGEDCE.js.map → chunk-PGYYDSNX.js.map} +0 -0
- /package/dist/{chunk-KXTNTDRD.js.map → chunk-PPEHBI5O.js.map} +0 -0
- /package/dist/{chunk-5RPT32EL.js.map → chunk-PVIQDBUN.js.map} +0 -0
- /package/dist/{chunk-N3ZOZWP5.js.map → chunk-Q3HYEAVQ.js.map} +0 -0
- /package/dist/{chunk-HKQQ2NED.js.map → chunk-Q4GAPZDA.js.map} +0 -0
- /package/dist/{chunk-VUBFCHXL.js.map → chunk-Q7XLTN2D.js.map} +0 -0
- /package/dist/{chunk-YQIT3ET7.js.map → chunk-QAH3XILB.js.map} +0 -0
- /package/dist/{chunk-YH7G44WL.js.map → chunk-QLJU7UUI.js.map} +0 -0
- /package/dist/{chunk-TVMSXL3R.js.map → chunk-QO7UJXXO.js.map} +0 -0
- /package/dist/{chunk-EXTES7LP.js.map → chunk-QZOQVJ5L.js.map} +0 -0
- /package/dist/{chunk-QQHZBJMU.js.map → chunk-RGVNXES5.js.map} +0 -0
- /package/dist/{chunk-MWPD2BXO.js.map → chunk-RHVJ3L4U.js.map} +0 -0
- /package/dist/{chunk-YV4O7KDR.js.map → chunk-S6HIZQIG.js.map} +0 -0
- /package/dist/{chunk-MQVIYTH5.js.map → chunk-SAKSIN7E.js.map} +0 -0
- /package/dist/{chunk-4HBCWKIX.js.map → chunk-SGFRSRAL.js.map} +0 -0
- /package/dist/{chunk-WLLUARTC.js.map → chunk-T2G4LDU5.js.map} +0 -0
- /package/dist/{chunk-37G7M2GJ.js.map → chunk-T6QVM5Q5.js.map} +0 -0
- /package/dist/{chunk-BLNFOP2O.js.map → chunk-T6YTDEY4.js.map} +0 -0
- /package/dist/{chunk-QTLM2YY2.js.map → chunk-TI4FGQYV.js.map} +0 -0
- /package/dist/{chunk-6HMDUUVJ.js.map → chunk-TRYR424I.js.map} +0 -0
- /package/dist/{chunk-V2UJEICC.js.map → chunk-TVDHA7BT.js.map} +0 -0
- /package/dist/{chunk-74KCGLOU.js.map → chunk-U2ILXZDG.js.map} +0 -0
- /package/dist/{chunk-TR7ZA67L.js.map → chunk-U2QV4TTZ.js.map} +0 -0
- /package/dist/{chunk-GNDIVKWF.js.map → chunk-U3HGQHEO.js.map} +0 -0
- /package/dist/{chunk-3YFDGFEK.js.map → chunk-U4WAAZXJ.js.map} +0 -0
- /package/dist/{chunk-UQUN2NGE.js.map → chunk-UAFSEZ2E.js.map} +0 -0
- /package/dist/{chunk-D5Y4PNC5.js.map → chunk-ULAZDF6D.js.map} +0 -0
- /package/dist/{chunk-3OWFUFZL.js.map → chunk-UMI3GYWI.js.map} +0 -0
- /package/dist/{chunk-Q7QQXNL7.js.map → chunk-UT545JBQ.js.map} +0 -0
- /package/dist/{chunk-JXK53XJW.js.map → chunk-UTUYXH72.js.map} +0 -0
- /package/dist/{chunk-E72INDBL.js.map → chunk-UXOFA3ZP.js.map} +0 -0
- /package/dist/{chunk-PDSZN26U.js.map → chunk-V6KQ5R4T.js.map} +0 -0
- /package/dist/{chunk-FLJ3RIRP.js.map → chunk-VEKTKCSB.js.map} +0 -0
- /package/dist/{chunk-UJACXYC2.js.map → chunk-VHGHF537.js.map} +0 -0
- /package/dist/{chunk-OFXCSLGX.js.map → chunk-VLH3IMJG.js.map} +0 -0
- /package/dist/{chunk-AKBL7S7A.js.map → chunk-VPGDYI63.js.map} +0 -0
- /package/dist/{chunk-6DGNMASB.js.map → chunk-VPH3TENY.js.map} +0 -0
- /package/dist/{chunk-45AON4CS.js.map → chunk-VYQZ5U3N.js.map} +0 -0
- /package/dist/{chunk-GXSHLMT4.js.map → chunk-WDSJ6SVY.js.map} +0 -0
- /package/dist/{chunk-JMDT3GQ3.js.map → chunk-WMAS6DZR.js.map} +0 -0
- /package/dist/{chunk-XE7QBHXN.js.map → chunk-WTOA52EQ.js.map} +0 -0
- /package/dist/{chunk-ILNAPS44.js.map → chunk-XMWTVDQN.js.map} +0 -0
- /package/dist/{chunk-JIAIPOEV.js.map → chunk-XNMU32XC.js.map} +0 -0
- /package/dist/{chunk-PEMXXFXL.js.map → chunk-XQJPR57I.js.map} +0 -0
- /package/dist/{chunk-54F7QIV2.js.map → chunk-XW44IFYE.js.map} +0 -0
- /package/dist/{chunk-I2KAN3YB.js.map → chunk-Y3LK6ZQG.js.map} +0 -0
- /package/dist/{chunk-7AC2UGTU.js.map → chunk-Y46R26TE.js.map} +0 -0
- /package/dist/{chunk-GQ2T44BC.js.map → chunk-YEKPQAOW.js.map} +0 -0
- /package/dist/{chunk-YC2QYRNE.js.map → chunk-YGWLMTPB.js.map} +0 -0
- /package/dist/{chunk-H56CRMCM.js.map → chunk-YHPSPFU5.js.map} +0 -0
- /package/dist/{chunk-F6LZHF4O.js.map → chunk-YTDUIU7X.js.map} +0 -0
- /package/dist/{chunk-CO7GH3W7.js.map → chunk-YWXCLPCX.js.map} +0 -0
- /package/dist/{chunk-RIPG3QIN.js.map → chunk-Z445LLFN.js.map} +0 -0
- /package/dist/{chunk-M7HYNXCU.js.map → chunk-ZAPP32GD.js.map} +0 -0
- /package/dist/{chunk-C2OX3C7L.js.map → chunk-ZLVRCQPG.js.map} +0 -0
- /package/dist/{chunk-SGAHME6W.js.map → chunk-ZVZTQF7E.js.map} +0 -0
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
|
|
3
|
+
import {
|
|
4
|
+
drawOrder,
|
|
5
|
+
extent,
|
|
6
|
+
geometryCache,
|
|
7
|
+
hitRegion,
|
|
8
|
+
projectionAt,
|
|
9
|
+
viewBoxFor,
|
|
10
|
+
type DrawnRegion,
|
|
11
|
+
type PlaneBox,
|
|
12
|
+
} from './RegionMap.helpers';
|
|
13
|
+
import type { RegionMapProps, RegionMapRegion } from './RegionMap.types';
|
|
14
|
+
|
|
15
|
+
/** What the drawing needs, derived from the props. */
|
|
16
|
+
export interface RegionMapModel {
|
|
17
|
+
/** The square shown, or null when there is nothing to centre on. */
|
|
18
|
+
view: PlaneBox | null;
|
|
19
|
+
drawn: DrawnRegion[];
|
|
20
|
+
/** Radii drawn, in metres; empty without circles. */
|
|
21
|
+
radii: number[];
|
|
22
|
+
outermostMetres: number | null;
|
|
23
|
+
/** The tap handlers for the drawing's `<svg>`. */
|
|
24
|
+
onPointerDown: (event: React.PointerEvent<SVGSVGElement>) => void;
|
|
25
|
+
onClick: (event: React.MouseEvent<SVGSVGElement>) => void;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
/** A tap reaches an area this close: a share of the view (~8 px on a phone). */
|
|
29
|
+
const TOLERANCE_SHARE = 1 / 45;
|
|
30
|
+
|
|
31
|
+
/** The middle of every area, for a map with no centre of its own. */
|
|
32
|
+
function centreOf(regions: readonly RegionMapRegion[]): { latitude: number; longitude: number } | null {
|
|
33
|
+
const points = regions.flatMap((r) => r.rings.flat());
|
|
34
|
+
const lats = extent(points.map(([lat]) => lat));
|
|
35
|
+
const lngs = extent(points.map(([, lng]) => lng));
|
|
36
|
+
if (lats === null || lngs === null) return null;
|
|
37
|
+
return { latitude: (lats.min + lats.max) / 2, longitude: (lngs.min + lngs.max) / 2 };
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
/** The click, in the drawing's own coordinates — or null where it cannot be read. */
|
|
41
|
+
function svgPoint(event: React.MouseEvent<SVGSVGElement>): { x: number; y: number } | null {
|
|
42
|
+
const svg = event.currentTarget;
|
|
43
|
+
const matrix = typeof svg.getScreenCTM === 'function' ? svg.getScreenCTM() : null;
|
|
44
|
+
if (!matrix || typeof DOMPoint === 'undefined') return null;
|
|
45
|
+
const point = new DOMPoint(event.clientX, event.clientY).matrixTransform(matrix.inverse());
|
|
46
|
+
return { x: point.x, y: point.y };
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
/** The view: the outermost circle when there is one, else every area's box. */
|
|
50
|
+
function viewOf(outermostMetres: number | null, drawable: () => (PlaneBox | null)[]): PlaneBox | null {
|
|
51
|
+
if (outermostMetres !== null) return viewBoxFor(outermostMetres, null);
|
|
52
|
+
const boxes = drawable().filter((box): box is PlaneBox => box !== null);
|
|
53
|
+
const xs = extent(boxes.flatMap((b) => [b.minX, b.minX + b.spanX]));
|
|
54
|
+
const ys = extent(boxes.flatMap((b) => [b.minY, b.minY + b.spanY]));
|
|
55
|
+
if (xs === null || ys === null) return null;
|
|
56
|
+
return viewBoxFor(null, { minX: xs.min, minY: ys.min, spanX: xs.max - xs.min, spanY: ys.max - ys.min });
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
/** Which area a click or tap means — see `useRegionMap`. */
|
|
60
|
+
function tappedRegion(
|
|
61
|
+
event: React.MouseEvent<SVGSVGElement>,
|
|
62
|
+
pointer: string,
|
|
63
|
+
drawn: readonly DrawnRegion[],
|
|
64
|
+
view: PlaneBox,
|
|
65
|
+
): string | null {
|
|
66
|
+
const targetId = (event.target as Element).getAttribute('data-region-id');
|
|
67
|
+
if (pointer === 'mouse' && targetId) return targetId;
|
|
68
|
+
const point = svgPoint(event);
|
|
69
|
+
if (point === null) return targetId;
|
|
70
|
+
return hitRegion(
|
|
71
|
+
drawn.map((d) => ({ id: d.id, geometry: d.geometry })),
|
|
72
|
+
point,
|
|
73
|
+
view.spanX * TOLERANCE_SHARE,
|
|
74
|
+
);
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
/** The geometry cache for a centre, or null without one. */
|
|
78
|
+
function useGeometry(
|
|
79
|
+
origin: { latitude: number; longitude: number } | null,
|
|
80
|
+
): ReturnType<typeof geometryCache> | null {
|
|
81
|
+
const lat = origin?.latitude ?? null;
|
|
82
|
+
const lng = origin?.longitude ?? null;
|
|
83
|
+
return React.useMemo(
|
|
84
|
+
() => (lat === null || lng === null ? null : geometryCache(projectionAt({ latitude: lat, longitude: lng }))),
|
|
85
|
+
[lat, lng],
|
|
86
|
+
);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
/**
|
|
90
|
+
* The projection, the view, the areas in draw order and the tap handlers.
|
|
91
|
+
*
|
|
92
|
+
* Geometry is projected once per `rings` identity and centre
|
|
93
|
+
* (`geometryCache`), so a toggle — which changes `excluded`, not `rings` —
|
|
94
|
+
* re-projects nothing.
|
|
95
|
+
*
|
|
96
|
+
* A MOUSE click on a path is that path's area: a pointer is precise. Any
|
|
97
|
+
* other tap — a finger, a pen — goes to `hitRegion`: the smallest area within
|
|
98
|
+
* a few pixels, so a sliver beside a big area is reachable from the map.
|
|
99
|
+
*/
|
|
100
|
+
export function useRegionMap({
|
|
101
|
+
regions,
|
|
102
|
+
center,
|
|
103
|
+
circles = [],
|
|
104
|
+
onToggle,
|
|
105
|
+
}: Pick<RegionMapProps, 'regions' | 'center' | 'circles' | 'onToggle'>): RegionMapModel {
|
|
106
|
+
const geometryOf = useGeometry(center ?? centreOf(regions));
|
|
107
|
+
const radii = circles.map((c) => c.radiusMetres);
|
|
108
|
+
const outermostMetres = extent(radii)?.max ?? null;
|
|
109
|
+
const view =
|
|
110
|
+
geometryOf === null ? null : viewOf(outermostMetres, () => regions.map((r) => geometryOf(r.rings).bounds));
|
|
111
|
+
const drawn = geometryOf && view ? drawOrder(regions, geometryOf, view) : [];
|
|
112
|
+
const pointerType = React.useRef<string>('mouse');
|
|
113
|
+
|
|
114
|
+
const onPointerDown = (event: React.PointerEvent<SVGSVGElement>): void => {
|
|
115
|
+
pointerType.current = event.pointerType || 'mouse';
|
|
116
|
+
};
|
|
117
|
+
|
|
118
|
+
const onClick = (event: React.MouseEvent<SVGSVGElement>): void => {
|
|
119
|
+
if (!onToggle || view === null) return;
|
|
120
|
+
const hit = tappedRegion(event, pointerType.current, drawn, view);
|
|
121
|
+
if (hit) onToggle(hit);
|
|
122
|
+
};
|
|
123
|
+
|
|
124
|
+
return { view, drawn, radii, outermostMetres, onPointerDown, onClick };
|
|
125
|
+
}
|
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
# RegionMap
|
|
2
|
+
|
|
3
|
+
A hand-drawn map of named **areas** around a centre — polygons with holes,
|
|
4
|
+
drawn as inline SVG — where a tap toggles an area's `excluded` state.
|
|
5
|
+
|
|
6
|
+
Product-free. An area is a bairro, a delivery zone, a sales territory or a
|
|
7
|
+
parking sector alike; coordinates are plain latitude/longitude, and every word
|
|
8
|
+
arrives through `copy`. Built for a delivery host's "which neighbourhoods does this store not
|
|
9
|
+
deliver to", and deliberately not named after it.
|
|
10
|
+
|
|
11
|
+
## Use cases
|
|
12
|
+
|
|
13
|
+
- Picking which neighbourhoods inside a delivery radius are left out.
|
|
14
|
+
- Marking territories, zones or sectors on/off around a point.
|
|
15
|
+
- Showing a read-only picture of which areas are in and out (omit `onToggle`).
|
|
16
|
+
|
|
17
|
+
## Decisions that shape the API
|
|
18
|
+
|
|
19
|
+
### No tiles, no key, nothing fetched
|
|
20
|
+
|
|
21
|
+
The question is "which of THESE areas", not "what is this street called", so
|
|
22
|
+
the drawing is the areas themselves over a plain background. That keeps it
|
|
23
|
+
free of a tile provider, an API key and a network request, and it renders the
|
|
24
|
+
same in a test as on a phone. `MapPreview` is the component for a real map.
|
|
25
|
+
|
|
26
|
+
### The list is the accessible way in
|
|
27
|
+
|
|
28
|
+
The drawing is ONE `role="img"` with `copy.mapLabel`; its areas are not tab
|
|
29
|
+
stops. Real areas are many and some are far too small to tap on a phone (IBGE
|
|
30
|
+
outlines 11 of the 48 bairros inside a 3 km ring in one Belo Horizonte
|
|
31
|
+
neighbourhood at under 0.1 km²). Every area is also a toggle button in the list
|
|
32
|
+
beneath (`aria-pressed`, plus its state in words from `copy.rowState`), which
|
|
33
|
+
is what a keyboard and a screen reader use, and what reaches a sliver no finger
|
|
34
|
+
can. `listMode` decides how it is offered:
|
|
35
|
+
`shown` (a computer), `collapsed` behind one button that names the count (a
|
|
36
|
+
phone), or `none` for a host that renders its own.
|
|
37
|
+
|
|
38
|
+
The list holds only the areas in reach: an `outside` area is drawn faded on the
|
|
39
|
+
map for context but has no row unless `listed: true`, and the count matches the
|
|
40
|
+
rows. `listSort: 'name'` orders it by name; `detail` carries a distance or a
|
|
41
|
+
size tag ("tiny") for an area too small to tap.
|
|
42
|
+
|
|
43
|
+
### Excluded is hatched AND named, never only coloured
|
|
44
|
+
|
|
45
|
+
An excluded area gets a hatch, a darker edge and its name on the map, and a
|
|
46
|
+
pressed, filled row with a check in the list, whose inverted colours hold under
|
|
47
|
+
hover and keyboard focus, with a focus ring. Colour is never the only signal,
|
|
48
|
+
and the error colour is never used: leaving an area out is a choice, not a
|
|
49
|
+
failure. The highlighted areas (`highlightedIds`, e.g. a search's hits — several
|
|
50
|
+
at once) use the primary colour and are named too.
|
|
51
|
+
|
|
52
|
+
### Our hit test, not only the browser's
|
|
53
|
+
|
|
54
|
+
A MOUSE click on an area's path is that area: the browser hit-tests the
|
|
55
|
+
even-odd fill, and areas are drawn largest first, so an area in another's hole
|
|
56
|
+
is on top. A finger's (or pen's) tap goes to `hitRegion`: the SMALLEST area
|
|
57
|
+
within ~2% of the view (about 8 px on a phone), the ones holding the tap
|
|
58
|
+
included — so a strip a few metres wide beside a big area can be hit from the
|
|
59
|
+
map, and the big one stays easy to hit everywhere else. A tap on empty map
|
|
60
|
+
toggles nothing. An area too thin even for that is on the list.
|
|
61
|
+
|
|
62
|
+
### A toggle is cheap
|
|
63
|
+
|
|
64
|
+
Geometry is projected once per `rings` array identity and centre, so a host
|
|
65
|
+
that rebuilds its region objects on every toggle (`{ ...area, excluded }`) but
|
|
66
|
+
keeps their `rings` re-projects nothing. The base areas are a memoised layer: a
|
|
67
|
+
toggle re-renders only the hatch, highlight and label layers. Measured on 102
|
|
68
|
+
areas of 300 vertices each at 4× CPU throttle: 18–46 ms from tap to commit.
|
|
69
|
+
|
|
70
|
+
### Strokes and type stay their size at every width
|
|
71
|
+
|
|
72
|
+
Strokes use `vector-effect: non-scaling-stroke`, and labels are HTML laid over
|
|
73
|
+
the drawing at theme sizes, moved in by their measured width so none is
|
|
74
|
+
clipped at an edge — the map reads the same at 320 px and at 1600 px. The
|
|
75
|
+
drawing is square; `maxHeight` caps it on a wide screen, and where it sits in a
|
|
76
|
+
wider box is the host's call.
|
|
77
|
+
|
|
78
|
+
## Props
|
|
79
|
+
|
|
80
|
+
| prop | type | default | what it does |
|
|
81
|
+
|---|---|---|---|
|
|
82
|
+
| `regions` | `readonly RegionMapRegion[]` | — | the areas; drawn when any part is in view |
|
|
83
|
+
| `center` | `{ latitude, longitude } \| null` | — | centre, dot and circles; `null` centres on the areas, no dot |
|
|
84
|
+
| `circles` | `readonly { radiusMetres }[]` | `[]` | dashed circles; the view fits the largest |
|
|
85
|
+
| `onToggle` | `(id: string) => void` | — | a tap or a list press; omit for read-only |
|
|
86
|
+
| `highlightedIds` | `readonly string[]` | `[]` | areas to point at (a search's hits), outlined and named |
|
|
87
|
+
| `copy` | `RegionMapCopy` | — | every word |
|
|
88
|
+
| `listMode` | `'shown' \| 'collapsed' \| 'none'` | `'collapsed'` | how the list is offered |
|
|
89
|
+
| `listSort` | `'given' \| 'name'` | `'given'` | the list's order |
|
|
90
|
+
| `maxHeight` | `string` | — | the drawing's largest height, any CSS length |
|
|
91
|
+
| `className` | `string` | — | on the root |
|
|
92
|
+
| `dataTestId` | `string` | `'region-map'` | every child test id derives from it |
|
|
93
|
+
|
|
94
|
+
### `RegionMapRegion`
|
|
95
|
+
|
|
96
|
+
```ts
|
|
97
|
+
{
|
|
98
|
+
id: string;
|
|
99
|
+
name: string;
|
|
100
|
+
rings: readonly (readonly [latitude, longitude])[][]; // even-odd: holes are rings
|
|
101
|
+
excluded?: boolean;
|
|
102
|
+
outside?: boolean; // drawn faded (context beyond the circles); still tappable
|
|
103
|
+
listed?: boolean; // has a list row; defaults to !outside
|
|
104
|
+
detail?: string; // pre-formatted, on the list row: "2.7 km away", "tiny"
|
|
105
|
+
}
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
### `RegionMapCopy`
|
|
109
|
+
|
|
110
|
+
`mapLabel`, `legendExcluded`, `legendCircle(radiusMetres)`, `legendCenter`,
|
|
111
|
+
`listLabel`, `showList(count)` (the count of LISTED areas), `hideList`, and
|
|
112
|
+
`rowState: { excluded, outside }` — a row's state in words, for a screen reader.
|
|
113
|
+
|
|
114
|
+
## Helpers
|
|
115
|
+
|
|
116
|
+
- `decodePolyline(encoded, precision = 1e5)` — Google's encoded polyline into
|
|
117
|
+
`[latitude, longitude]` points; outlines usually travel this way.
|
|
118
|
+
- `hitRegion(regions, point, tolerance)` and `projectionAt(center)` — the hit
|
|
119
|
+
test and projection the component uses, for a host that draws its own layer.
|
|
120
|
+
|
|
121
|
+
## Example
|
|
122
|
+
|
|
123
|
+
```tsx
|
|
124
|
+
<RegionMap
|
|
125
|
+
regions={bairros.map((b) => ({
|
|
126
|
+
id: b.code,
|
|
127
|
+
name: b.name,
|
|
128
|
+
rings: b.outline.split(';').flatMap((p) => p.split(',')).map((r) => decodePolyline(r)),
|
|
129
|
+
excluded: excluded.has(b.code),
|
|
130
|
+
detail: b.distanceLabel,
|
|
131
|
+
}))}
|
|
132
|
+
center={store}
|
|
133
|
+
circles={rings.map((r) => ({ radiusMetres: r.maxDistanceMetres }))}
|
|
134
|
+
onToggle={toggle}
|
|
135
|
+
highlightedIds={searchHits}
|
|
136
|
+
copy={copy}
|
|
137
|
+
listMode={isPhone ? 'collapsed' : 'shown'}
|
|
138
|
+
/>
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
## Not here (yet)
|
|
142
|
+
|
|
143
|
+
- Zoom and pan. The list covers the areas too small to tap.
|
|
144
|
+
- A React Native build.
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
import Box from '@mui/material/Box/index.js';
|
|
2
|
+
import { useTheme } from '@mui/material/styles/index.js';
|
|
3
|
+
import React from 'react';
|
|
4
|
+
|
|
5
|
+
import { useRegionMap } from './RegionMap.hooks';
|
|
6
|
+
import type { RegionMapProps } from './RegionMap.types';
|
|
7
|
+
import { RegionMapDrawing } from './RegionMapDrawing';
|
|
8
|
+
import { RegionMapLegend } from './RegionMapLegend';
|
|
9
|
+
import { RegionMapList } from './RegionMapList';
|
|
10
|
+
|
|
11
|
+
/** One empty list, so the default does not change identity per render. */
|
|
12
|
+
const NO_IDS: readonly string[] = [];
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* A hand-drawn map of named areas around a centre; a tap toggles an area.
|
|
16
|
+
*
|
|
17
|
+
* Drawn as inline SVG over a plain background — no tile server, no API key,
|
|
18
|
+
* nothing fetched — because the question it answers is "which of THESE areas",
|
|
19
|
+
* not "what is the street called". Four choices shape it:
|
|
20
|
+
*
|
|
21
|
+
* - **The list is the accessible way in.** The drawing is one `role="img"`
|
|
22
|
+
* with a name; its areas are not tab stops (dozens of them, many too small to
|
|
23
|
+
* tap on a phone). Every area is also a toggle button in the list beneath,
|
|
24
|
+
* with `aria-pressed`, which is what a keyboard and a screen reader use —
|
|
25
|
+
* and what reaches a sliver no finger can.
|
|
26
|
+
* - **Excluded is hatched AND named, never only coloured,** and never in the
|
|
27
|
+
* error colour: leaving an area out is a choice, not a failure.
|
|
28
|
+
* - **The hit test is ours, not only the browser's.** A mouse click on a path
|
|
29
|
+
* is that path. A finger's tap takes the SMALLEST area within a few pixels'
|
|
30
|
+
* worth of metres (`hitRegion`), so a sliver beside a big area can be hit
|
|
31
|
+
* from the map; one too thin even for that is still on the list.
|
|
32
|
+
* - **A toggle is cheap.** Geometry is projected once per `rings` identity,
|
|
33
|
+
* and the base layer is memoised, so a tap re-renders the hatch and labels.
|
|
34
|
+
*/
|
|
35
|
+
export function RegionMap({
|
|
36
|
+
regions,
|
|
37
|
+
center,
|
|
38
|
+
circles,
|
|
39
|
+
onToggle,
|
|
40
|
+
highlightedIds = NO_IDS,
|
|
41
|
+
copy,
|
|
42
|
+
listMode = 'collapsed',
|
|
43
|
+
listSort = 'given',
|
|
44
|
+
maxHeight,
|
|
45
|
+
className,
|
|
46
|
+
dataTestId = 'region-map',
|
|
47
|
+
}: RegionMapProps): React.JSX.Element | null {
|
|
48
|
+
const theme = useTheme();
|
|
49
|
+
const model = useRegionMap({ regions, center, circles, onToggle });
|
|
50
|
+
const { view } = model;
|
|
51
|
+
if (view === null && regions.length === 0) return null;
|
|
52
|
+
return (
|
|
53
|
+
<Box className={className} data-testid={dataTestId}>
|
|
54
|
+
{view && (
|
|
55
|
+
<>
|
|
56
|
+
<RegionMapDrawing
|
|
57
|
+
model={{ ...model, view }}
|
|
58
|
+
showCenter={center !== null}
|
|
59
|
+
highlightedIds={highlightedIds}
|
|
60
|
+
maxHeight={maxHeight}
|
|
61
|
+
label={copy.mapLabel}
|
|
62
|
+
tappable={onToggle !== undefined}
|
|
63
|
+
testId={dataTestId}
|
|
64
|
+
theme={theme}
|
|
65
|
+
/>
|
|
66
|
+
<RegionMapLegend
|
|
67
|
+
copy={copy}
|
|
68
|
+
outermostMetres={model.outermostMetres}
|
|
69
|
+
showCenter={center !== null}
|
|
70
|
+
theme={theme}
|
|
71
|
+
testId={dataTestId}
|
|
72
|
+
/>
|
|
73
|
+
</>
|
|
74
|
+
)}
|
|
75
|
+
{listMode !== 'none' && (
|
|
76
|
+
<RegionMapList
|
|
77
|
+
regions={regions}
|
|
78
|
+
copy={copy}
|
|
79
|
+
mode={listMode}
|
|
80
|
+
sort={listSort}
|
|
81
|
+
onToggle={onToggle}
|
|
82
|
+
testId={dataTestId}
|
|
83
|
+
theme={theme}
|
|
84
|
+
/>
|
|
85
|
+
)}
|
|
86
|
+
</Box>
|
|
87
|
+
);
|
|
88
|
+
}
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The contract of `RegionMap` — a hand-drawn map of named areas (polygons with
|
|
3
|
+
* holes) around a centre, where a tap toggles an area's `excluded` state.
|
|
4
|
+
*
|
|
5
|
+
* Product-free: an area is a bairro, a delivery zone, a sales territory or a
|
|
6
|
+
* parking sector alike. Coordinates are plain WGS 84 latitude/longitude, and
|
|
7
|
+
* every word arrives through `copy`.
|
|
8
|
+
*/
|
|
9
|
+
|
|
10
|
+
/** A latitude/longitude pair, in that order. */
|
|
11
|
+
export type RegionMapPoint = readonly [latitude: number, longitude: number];
|
|
12
|
+
|
|
13
|
+
/** One closed ring: the first point repeated last is allowed, not required. */
|
|
14
|
+
export type RegionMapRing = readonly RegionMapPoint[];
|
|
15
|
+
|
|
16
|
+
/** One named area. */
|
|
17
|
+
export interface RegionMapRegion {
|
|
18
|
+
/** Stable id — what `onToggle` reports. */
|
|
19
|
+
id: string;
|
|
20
|
+
/** The area's name: its label on the map and its row in the list. */
|
|
21
|
+
name: string;
|
|
22
|
+
/**
|
|
23
|
+
* Every ring of every polygon of the area, holes included. Inside is decided
|
|
24
|
+
* by the EVEN-ODD rule over all of them, so a hole is just a ring inside its
|
|
25
|
+
* polygon, and a multi-part area is several outer rings.
|
|
26
|
+
*/
|
|
27
|
+
rings: readonly RegionMapRing[];
|
|
28
|
+
/** Drawn hatched, labelled, and pressed in the list. */
|
|
29
|
+
excluded?: boolean;
|
|
30
|
+
/**
|
|
31
|
+
* Drawn faded, for an area shown for context beyond the circles (a ring may
|
|
32
|
+
* grow). Still tappable on the map; left off the list unless `listed`.
|
|
33
|
+
*/
|
|
34
|
+
outside?: boolean;
|
|
35
|
+
/**
|
|
36
|
+
* Whether the area has a row in the list. Defaults to `!outside`, so the
|
|
37
|
+
* list — and its count — covers the areas inside the circles while the map
|
|
38
|
+
* still draws the faded context around them.
|
|
39
|
+
*/
|
|
40
|
+
listed?: boolean;
|
|
41
|
+
/**
|
|
42
|
+
* Pre-formatted secondary text on the list row, e.g. "2.7 km away", or a
|
|
43
|
+
* size tag such as "tiny" for an area too small to tap.
|
|
44
|
+
*/
|
|
45
|
+
detail?: string;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
/** A circle drawn around the centre, e.g. a delivery ring. */
|
|
49
|
+
export interface RegionMapCircle {
|
|
50
|
+
radiusMetres: number;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
/** Every word the map prints or announces. */
|
|
54
|
+
export interface RegionMapCopy {
|
|
55
|
+
/** The drawing's accessible name (`role="img"`). */
|
|
56
|
+
mapLabel: string;
|
|
57
|
+
/** The legend entry for a hatched (excluded) area. */
|
|
58
|
+
legendExcluded: string;
|
|
59
|
+
/** The legend entry for the outermost circle, given its radius in metres. */
|
|
60
|
+
legendCircle: (radiusMetres: number) => string;
|
|
61
|
+
/** The legend entry for the centre's dot. */
|
|
62
|
+
legendCenter: string;
|
|
63
|
+
/** The list's accessible name and its heading when shown. */
|
|
64
|
+
listLabel: string;
|
|
65
|
+
/** The button that reveals the list, given how many areas it holds. */
|
|
66
|
+
showList: (count: number) => string;
|
|
67
|
+
/** The button that hides it again. */
|
|
68
|
+
hideList: string;
|
|
69
|
+
/**
|
|
70
|
+
* A list row's state, read after its name by a screen reader: "excluded"
|
|
71
|
+
* for an excluded area (pressed, filled, checked), "outside" for a listed
|
|
72
|
+
* `outside` one (faded). Neither is shown; the row's look carries it.
|
|
73
|
+
*/
|
|
74
|
+
rowState: { excluded: string; outside: string };
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
/** The order of the list: as given (e.g. nearest first), or by name. */
|
|
78
|
+
export type RegionMapListSort = 'given' | 'name';
|
|
79
|
+
|
|
80
|
+
/**
|
|
81
|
+
* How the accessible list of areas — one toggle button each — is offered.
|
|
82
|
+
*
|
|
83
|
+
* - `shown`: always under the map (a computer, where there is room);
|
|
84
|
+
* - `collapsed`: behind one button (a phone) — still a keyboard's way in;
|
|
85
|
+
* - `none`: not rendered. Only for a host that offers its own list.
|
|
86
|
+
*/
|
|
87
|
+
export type RegionMapListMode = 'shown' | 'collapsed' | 'none';
|
|
88
|
+
|
|
89
|
+
export interface RegionMapProps {
|
|
90
|
+
regions: readonly RegionMapRegion[];
|
|
91
|
+
/**
|
|
92
|
+
* Where the map is centred, and where the dot and the circles are drawn.
|
|
93
|
+
* `null` with no regions renders NOTHING rather than a map of `0, 0`.
|
|
94
|
+
*/
|
|
95
|
+
center: { latitude: number; longitude: number } | null;
|
|
96
|
+
/** Circles around the centre; the view fits the largest. */
|
|
97
|
+
circles?: readonly RegionMapCircle[];
|
|
98
|
+
/**
|
|
99
|
+
* A tap on an area, or a press of its list button. Omit it and the map is
|
|
100
|
+
* read-only: nothing is tappable and the list rows are not buttons.
|
|
101
|
+
*/
|
|
102
|
+
onToggle?: (id: string) => void;
|
|
103
|
+
/**
|
|
104
|
+
* Areas to point at — e.g. a search's results — outlined and labelled. More
|
|
105
|
+
* than one at once: a search lists several hits.
|
|
106
|
+
*/
|
|
107
|
+
highlightedIds?: readonly string[];
|
|
108
|
+
copy: RegionMapCopy;
|
|
109
|
+
listMode?: RegionMapListMode;
|
|
110
|
+
/** The list's order; `'given'` keeps the order of `regions`. */
|
|
111
|
+
listSort?: RegionMapListSort;
|
|
112
|
+
/** The drawing's largest height, any CSS length; it stays square inside it. */
|
|
113
|
+
maxHeight?: string;
|
|
114
|
+
className?: string;
|
|
115
|
+
/** Every child TEST id derives from it. */
|
|
116
|
+
dataTestId?: string;
|
|
117
|
+
}
|