@tmlmobilidade/ui 20250820.2306.45 → 20250820.2314.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import * as React$1 from 'react';
|
|
3
|
-
import React__default, { PropsWithChildren, ReactNode } from 'react';
|
|
3
|
+
import React__default, { PropsWithChildren, ReactNode, RefObject } from 'react';
|
|
4
4
|
import { ButtonProps as ButtonProps$1, BadgeProps as BadgeProps$1, ComboboxProps, MenuProps as MenuProps$1, MenuTargetProps as MenuTargetProps$1, MenuDropdownProps as MenuDropdownProps$1, MenuItemProps as MenuItemProps$1, MenuDividerProps as MenuDividerProps$1, MenuLabelProps as MenuLabelProps$1, SegmentedControlProps as SegmentedControlProps$1, TooltipProps as TooltipProps$1, CheckboxProps as CheckboxProps$1, CheckboxGroupProps as CheckboxGroupProps$1, PopoverProps as PopoverProps$1, PopoverTargetProps as PopoverTargetProps$1, PopoverDropdownProps as PopoverDropdownProps$1, SliderProps as SliderProps$1, SwitchProps as SwitchProps$1, TextProps as TextProps$1, NumberInputProps as NumberInputProps$1, PasswordInputProps, PillsInputProps as PillsInputProps$1, TextareaProps as TextareaProps$1, TextInputProps as TextInputProps$1 } from '@mantine/core';
|
|
5
5
|
export { RenderTreeNodePayload, Tree, TreeNodeData, getTreeExpandedState, useTree } from '@mantine/core';
|
|
6
6
|
import { DatePickerInputProps, DateTimePickerProps as DateTimePickerProps$1 } from '@mantine/dates';
|
|
7
7
|
import { StyleSpecification } from 'maplibre-gl';
|
|
8
8
|
import { Stop, Permission, User } from '@tmlmobilidade/types';
|
|
9
|
-
import { MapLayerMouseEvent, ViewStateChangeEvent } from '@vis.gl/react-maplibre';
|
|
9
|
+
import { MapLayerMouseEvent, ViewStateChangeEvent, MapRef } from '@vis.gl/react-maplibre';
|
|
10
10
|
import { HttpException } from '@tmlmobilidade/lib';
|
|
11
11
|
import { HasPermissionResourceArgs } from '@tmlmobilidade/utils';
|
|
12
12
|
import { NotificationData } from '@mantine/notifications';
|
|
@@ -597,6 +597,18 @@ interface MapViewProps {
|
|
|
597
597
|
}
|
|
598
598
|
declare function MapView({ children, id, interactiveLayerIds, onClick, onDrag, onDragEnd, onDragStart, onMouseDrag, onMouseEnter, onMouseLeave, onMouseOut, onMouseOver }: PropsWithChildren<MapViewProps>): react_jsx_runtime.JSX.Element;
|
|
599
599
|
|
|
600
|
+
interface MapViewContextState {
|
|
601
|
+
actions: {
|
|
602
|
+
centerMapOnFeatures: () => void;
|
|
603
|
+
registerSourceId: (id: string) => void;
|
|
604
|
+
};
|
|
605
|
+
ref: {
|
|
606
|
+
map: RefObject<MapRef | null>;
|
|
607
|
+
};
|
|
608
|
+
}
|
|
609
|
+
declare function useMapViewContext(): MapViewContextState;
|
|
610
|
+
declare const MapViewContextProvider: ({ children }: PropsWithChildren) => react_jsx_runtime.JSX.Element;
|
|
611
|
+
|
|
600
612
|
interface PaneProps {
|
|
601
613
|
/**
|
|
602
614
|
* A set of or a single React component to be rendered inside
|
|
@@ -916,5 +928,5 @@ declare const getBaseGeoJsonFeatureLineString: () => GeoJSON.Feature<GeoJSON.Lin
|
|
|
916
928
|
*/
|
|
917
929
|
declare const getBaseGeoJsonFeatureCollection: () => GeoJSON.FeatureCollection<GeoJSON.LineString | GeoJSON.Point, GeoJSON.GeoJsonProperties>;
|
|
918
930
|
|
|
919
|
-
export { AVAILABLE_THEMES, AlertCard, AlertMessage, AppProvider, AppWrapper, BackButton, Badge, Button, CMIcon, CMLogo, Checkbox, Collapsible, ComboboxComponent as Combobox, ComponentWrapper, CoordinatesInput, DataTable, DatePicker, DateTimePicker, DeleteButton, Description, Divider, ErrorDisplay, FileButton, FileUpload, FilterMenu, FilterMenuTarget, FiltersBar, Grid, HasPermission, Indicator, Label, Loader, LoadingOverlay, LockButton, MAP_STYLES, MAP_VIEWPORT, MapContextProvider, MapOverlayMultipleStops, MapOverlayMultipleStopsInteractiveLayerIds, MapOverlayMultipleStopsPrimaryLayerId, MapView, MeContextProvider, Menu, MultiSelect, NoDataLabel, NumberInput, Pane, PanesManager, PasswordInput, PillsInput, Popover, SearchInput, Section, SegmentedControl, Sidebar, SidebarContextProvider, SidebarItem, SidebarSubItem, Slider, Spacer, Surface, Switch, TMLogo, TMLogoDark, TMLogoLight, Tag, TagGroup, Text, TextInput, Textarea, ThemeContextProvider, ThemeDark, ThemeLight, ThemeSwitcher, Themer, Tooltip, ValueDisplay, accessorSearch, centerMap, getBaseGeoJsonFeatureCollection, getBaseGeoJsonFeatureLineString, moveMap, plainSearch, sidebarApps, useCssVariable, useIsActiveDomain, useIsActivePage, useMapContext, useMeContext, useScreenSize, useSearch, useSidebarContext, useThemeContext, useToast };
|
|
931
|
+
export { AVAILABLE_THEMES, AlertCard, AlertMessage, AppProvider, AppWrapper, BackButton, Badge, Button, CMIcon, CMLogo, Checkbox, Collapsible, ComboboxComponent as Combobox, ComponentWrapper, CoordinatesInput, DataTable, DatePicker, DateTimePicker, DeleteButton, Description, Divider, ErrorDisplay, FileButton, FileUpload, FilterMenu, FilterMenuTarget, FiltersBar, Grid, HasPermission, Indicator, Label, Loader, LoadingOverlay, LockButton, MAP_STYLES, MAP_VIEWPORT, MapContextProvider, MapOverlayMultipleStops, MapOverlayMultipleStopsInteractiveLayerIds, MapOverlayMultipleStopsPrimaryLayerId, MapView, MapViewContextProvider, MeContextProvider, Menu, MultiSelect, NoDataLabel, NumberInput, Pane, PanesManager, PasswordInput, PillsInput, Popover, SearchInput, Section, SegmentedControl, Sidebar, SidebarContextProvider, SidebarItem, SidebarSubItem, Slider, Spacer, Surface, Switch, TMLogo, TMLogoDark, TMLogoLight, Tag, TagGroup, Text, TextInput, Textarea, ThemeContextProvider, ThemeDark, ThemeLight, ThemeSwitcher, Themer, Tooltip, ValueDisplay, accessorSearch, centerMap, getBaseGeoJsonFeatureCollection, getBaseGeoJsonFeatureLineString, moveMap, plainSearch, sidebarApps, useCssVariable, useIsActiveDomain, useIsActivePage, useMapContext, useMapViewContext, useMeContext, useScreenSize, useSearch, useSidebarContext, useThemeContext, useToast };
|
|
920
932
|
export type { ButtonProps, CheckboxGroupProps, CheckboxProps, DataItem$1 as DataItem, DataTableColumn, DataTableProps, FileButtonProps, LabelProps, LoaderProps, MapStyle, NoDataLabelProps, NumberInputProps, PillsInputProps, PopoverDropdownProps, PopoverProps, PopoverTargetProps, SearchInputProps, SidebarItemProps, SidebarSubItemProps, SurfaceProps, TagGroupProps, TagProps, TextInputProps, TextProps, TextareaProps, ThemeType, ToastPromiseParams, ToastProps };
|
package/dist/index.js
CHANGED
|
@@ -54,6 +54,7 @@ export { MAP_STYLES } from './src/components/map/configs/styles.js';
|
|
|
54
54
|
export { MAP_VIEWPORT } from './src/components/map/configs/viewport.js';
|
|
55
55
|
export { MapOverlayMultipleStops, MapOverlayMultipleStopsInteractiveLayerIds, MapOverlayMultipleStopsPrimaryLayerId } from './src/components/map/overlays/MapOverlayMultipleStops/index.js';
|
|
56
56
|
export { MapView } from './src/components/map/view/MapView/index.js';
|
|
57
|
+
export { MapViewContextProvider, useMapViewContext } from './src/components/map/view/MapViewContext/index.js';
|
|
57
58
|
export { Pane } from './src/components/panes/Pane/index.js';
|
|
58
59
|
export { PanesManager } from './src/components/panes/PanesManager/index.js';
|
|
59
60
|
export { Sidebar, sidebarApps } from './src/components/sidebar/Sidebar/index.js';
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
import { j as jsxRuntimeExports } from '../../../../../_virtual/jsx-runtime.js';
|
|
3
3
|
import { centerMapView } from '../../utils/center-map-view.js';
|
|
4
|
-
import { createContext,
|
|
4
|
+
import { createContext, useContext, useRef } from 'react';
|
|
5
5
|
|
|
6
6
|
/* * */
|
|
7
7
|
const MapViewContext = createContext(undefined);
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tmlmobilidade/ui",
|
|
3
3
|
"description": "UI components for Transportes Metropolitanos de Lisboa (TML) web applications.",
|
|
4
|
-
"version": "20250820.
|
|
4
|
+
"version": "20250820.2314.30",
|
|
5
5
|
"author": "João de Vasconcelos & Jusi Monteiro",
|
|
6
6
|
"license": "AGPL-3.0-or-later",
|
|
7
7
|
"publishConfig": {
|