@opengeoweb/shared 14.0.1 → 14.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.
- package/index.esm.js +608 -494
- package/package.json +2 -2
- package/src/index.d.ts +1 -1
- package/src/lib/components/AlertBanner/AlertBanner.d.ts +2 -2
- package/src/lib/components/AlertBanner/AlertBanner.stories.d.ts +1 -1
- package/src/lib/components/AlertIcon/AlertIcon.d.ts +2 -2
- package/src/lib/components/AppHeader/AppHeader.stories.d.ts +1 -1
- package/src/lib/components/AppLayout/AppLayout.stories.d.ts +1 -1
- package/src/lib/components/Avatar/Avatar.d.ts +1 -1
- package/src/lib/components/CanvasComponent/CanvasComponent.stories.d.ts +1 -1
- package/src/lib/components/ConfirmationDialog/ConfirmationButtons.d.ts +2 -2
- package/src/lib/components/ConfirmationDialog/ConfirmationDialog.d.ts +3 -3
- package/src/lib/components/ConfirmationDialog/ConfirmationDialog.stories.d.ts +1 -1
- package/src/lib/components/ConfirmationDialog/ConfirmationService.d.ts +2 -2
- package/src/lib/components/CustomAccordion/CustomAccordion.d.ts +2 -2
- package/src/lib/components/CustomDialog/CustomDialog.d.ts +5 -5
- package/src/lib/components/CustomDialog/CustomDialog.stories.d.ts +1 -1
- package/src/lib/components/CustomDialog/CustomDialogHeader.d.ts +4 -4
- package/src/lib/components/CustomIconButton/CustomIconButton.d.ts +2 -2
- package/src/lib/components/CustomSlider/CustomSlider.d.ts +2 -2
- package/src/lib/components/CustomToggleButton/CustomToggleButton.d.ts +3 -3
- package/src/lib/components/CustomTooltip/CustomTooltip.d.ts +2 -2
- package/src/lib/components/DraggableResizable/Draggable.d.ts +2 -2
- package/src/lib/components/DraggableResizable/Resizable.d.ts +1 -1
- package/src/lib/components/DraggableResizable/index.d.ts +1 -1
- package/src/lib/components/DraggableResizable/types.d.ts +2 -2
- package/src/lib/components/ErrorBoundary/ErrorBoundary.d.ts +1 -1
- package/src/lib/components/Filter/Filter.d.ts +3 -3
- package/src/lib/components/Filter/FilterChip.d.ts +2 -2
- package/src/lib/components/Filter/FilterList.d.ts +1 -1
- package/src/lib/components/Filter/FilterOption.d.ts +3 -2
- package/src/lib/components/Filter/SearchField.d.ts +1 -1
- package/src/lib/components/LastUpdateTime/LastUpdateTime.d.ts +1 -1
- package/src/lib/components/Providers/Providers.d.ts +1 -1
- package/src/lib/components/SearchField/SearchField.d.ts +1 -1
- package/src/lib/components/StatusTag/StatusTag.d.ts +2 -2
- package/src/lib/components/StatusTag/StatusTag.stories.d.ts +1 -1
- package/src/lib/components/Storybook/StorybookDocsWrapper.d.ts +1 -1
- package/src/lib/components/SwitchButton/SwitchButton.d.ts +2 -2
- package/src/lib/components/ToggleMenu/ToggleMenu.d.ts +3 -3
- package/src/lib/components/ToolContainer/ToolContainer.d.ts +1 -1
- package/src/lib/components/ToolContainer/ToolContainer.stories.d.ts +1 -1
- package/src/lib/components/ToolContainer/ToolContainerDraggable.d.ts +4 -4
- package/src/lib/components/ToolContainer/ToolHeader.d.ts +1 -1
- package/src/lib/components/ToolContainer/index.d.ts +1 -1
- package/src/lib/components/ToolContainer/types.d.ts +1 -1
- package/src/lib/components/ToolContainer/useHandleSizeFromOutsideComponent.d.ts +1 -1
- package/src/lib/components/TooltipSelect/TooltipSelect.d.ts +2 -2
- package/src/lib/hooks/index.d.ts +1 -0
- package/src/lib/hooks/useIsMounted/useIsMounted.d.ts +1 -1
- package/src/lib/hooks/useMakeSureContainerStaysInsideWindow/useMakeSureContainerStaysInsideWindow.d.ts +1 -1
- package/src/lib/hooks/usePoller/usePoller.d.ts +1 -1
- package/src/lib/hooks/usePrevious/usePrevious.stories.d.ts +1 -1
- package/src/lib/hooks/useResizeObserver/useResizeObserver.d.ts +2 -0
- package/src/lib/hooks/useResizeObserver/useResizeObserver.spec.d.ts +1 -0
- package/src/lib/types/edr-coverage-types.d.ts +31 -6
- package/src/lib/types/index.d.ts +1 -1
- package/src/lib/types/types.d.ts +19 -1
- package/src/lib/utils/axiosErrorUtils/axiosErrorUtils.d.ts +1 -1
- package/src/lib/utils/dateUtils/dateFormats.d.ts +1 -0
- package/src/lib/utils/dateUtils/dateUtils.d.ts +3 -2
- package/src/lib/utils/i18n.d.ts +1 -1
- package/src/lib/utils/index.d.ts +1 -1
- package/src/lib/utils/sessionStorage.d.ts +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@opengeoweb/shared",
|
|
3
|
-
"version": "14.
|
|
3
|
+
"version": "14.2.1",
|
|
4
4
|
"description": "GeoWeb shared library with shared components and utils for the opengeoweb project",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"repository": {
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"url": "git@gitlab.com:opengeoweb/opengeoweb.git"
|
|
9
9
|
},
|
|
10
10
|
"dependencies": {
|
|
11
|
-
"@opengeoweb/theme": "14.
|
|
11
|
+
"@opengeoweb/theme": "14.2.1",
|
|
12
12
|
"react-draggable": "^4.4.6",
|
|
13
13
|
"re-resizable": "^6.9.11",
|
|
14
14
|
"lodash": "^4.17.21",
|
package/src/index.d.ts
CHANGED
|
@@ -3,5 +3,5 @@ export * from './lib/components';
|
|
|
3
3
|
export * from './lib/hooks';
|
|
4
4
|
export * from './lib/utils';
|
|
5
5
|
export * from './lib/types';
|
|
6
|
-
export {
|
|
6
|
+
export { loadAllTranslations, safelyInitI18nForTestsAndStories, SHARED_NAMESPACE, } from './lib/utils/i18n';
|
|
7
7
|
export { sharedTranslations };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { DialogAction } from '../CustomDialog/types';
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { DialogAction } from '../CustomDialog/types';
|
|
3
3
|
export type ConfirmationAction = 'CANCELLED' | DialogAction;
|
|
4
4
|
export interface ConfirmationButtonsProps {
|
|
5
5
|
confirmLabel?: string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import { DialogAction } from '../CustomDialog/types';
|
|
1
|
+
import type { ModalProps, SxProps, Theme } from '@mui/material';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import type { DialogAction } from '../CustomDialog/types';
|
|
4
4
|
export interface ConfirmationOptions {
|
|
5
5
|
title?: string;
|
|
6
6
|
description?: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { ConfirmationAction, ConfirmationOptions } from './ConfirmationDialog';
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { ConfirmationAction, ConfirmationOptions } from './ConfirmationDialog';
|
|
3
3
|
type ConfirmationContext = (options: ConfirmationOptions) => Promise<void>;
|
|
4
4
|
export declare const useConfirmationDialog: () => ConfirmationContext;
|
|
5
5
|
export declare const useDialogActions: (awaitingPromiseRef: React.MutableRefObject<{
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
1
|
+
import type { AccordionProps, SxProps, Theme } from '@mui/material';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
export interface CustomAccordionProps extends Omit<AccordionProps, 'title'> {
|
|
4
4
|
title?: string | React.ReactNode;
|
|
5
5
|
title2?: string;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import { Size } from '../DraggableResizable';
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
1
|
+
import type { DialogProps } from '@mui/material';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import type { Size } from '../DraggableResizable';
|
|
4
|
+
import type { HeaderAction } from './CustomDialogHeader';
|
|
5
|
+
import type { DialogAction } from './types';
|
|
6
6
|
export interface CustomDialogProps extends DialogProps {
|
|
7
7
|
description?: string;
|
|
8
8
|
actions?: React.ReactNode;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { ButtonVariant } from '@opengeoweb/theme';
|
|
3
|
-
import { DialogAction } from './types';
|
|
4
|
-
import { MenuItemType } from '../ToggleMenu';
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { ButtonVariant } from '@opengeoweb/theme';
|
|
3
|
+
import type { DialogAction } from './types';
|
|
4
|
+
import type { MenuItemType } from '../ToggleMenu';
|
|
5
5
|
export type HeaderAction = MenuItemType & {
|
|
6
6
|
variant?: ButtonVariant;
|
|
7
7
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
1
|
+
import type { IconButtonProps, TooltipProps as MuiTooltipProps } from '@mui/material';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
export type Variant = 'flat' | 'tool' | 'boxed';
|
|
4
4
|
type TooltipProps = Omit<MuiTooltipProps, 'children'>;
|
|
5
5
|
export interface CustomIconProps extends IconButtonProps {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import { ButtonVariant } from '@opengeoweb/theme';
|
|
1
|
+
import type { ToggleButtonProps } from '@mui/material';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import type { ButtonVariant } from '@opengeoweb/theme';
|
|
4
4
|
export interface CustomToggleButtonProps extends Omit<ToggleButtonProps, 'value'> {
|
|
5
5
|
variant?: ButtonVariant;
|
|
6
6
|
value?: any;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
1
|
+
import type { TooltipProps } from '@mui/material';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
export declare const defaultDelay = 1000;
|
|
4
4
|
export declare const useControlledTooltip: () => [boolean, React.Dispatch<React.SetStateAction<boolean>>];
|
|
5
5
|
export declare const CustomTooltip: React.FC<TooltipProps>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { DraggableEvent } from 'react-draggable';
|
|
3
|
-
import { DraggablePosition } from './types';
|
|
2
|
+
import type { DraggableEvent } from 'react-draggable';
|
|
3
|
+
import type { DraggablePosition } from './types';
|
|
4
4
|
export interface DraggableComponentProps {
|
|
5
5
|
nodeRef?: React.RefObject<HTMLElement>;
|
|
6
6
|
children?: React.ReactNode;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { BoxProps } from '@mui/material';
|
|
2
|
-
import
|
|
3
|
-
import { ListFilter } from './FilterList';
|
|
1
|
+
import type { BoxProps } from '@mui/material';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import type { ListFilter } from './FilterList';
|
|
4
4
|
export declare const DEFAULT_FILTER_HEIGHT = 85;
|
|
5
5
|
interface FilterProps extends BoxProps {
|
|
6
6
|
filters: ListFilter[];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import
|
|
1
|
+
import React from 'react';
|
|
2
2
|
export interface FilterChipProps {
|
|
3
3
|
id: string;
|
|
4
|
-
label:
|
|
4
|
+
label: React.ReactNode;
|
|
5
5
|
isSelected?: boolean;
|
|
6
6
|
isDisabled?: boolean;
|
|
7
7
|
handleClick?: (label: string, isSelected?: boolean) => void;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { SxProps, Theme } from '@mui/material';
|
|
2
|
-
import React
|
|
1
|
+
import type { SxProps, Theme } from '@mui/material';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import type { ReactNode } from 'react';
|
|
3
4
|
interface Props {
|
|
4
5
|
optionId: string;
|
|
5
6
|
checked: boolean;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import { Variant } from '../CustomIconButton';
|
|
1
|
+
import type { PopoverOrigin, SxProps, Theme } from '@mui/material';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import type { Variant } from '../CustomIconButton';
|
|
4
4
|
type MenuPosition = 'left' | 'right' | 'bottom';
|
|
5
5
|
export declare const getPosition: (menuPosition: MenuPosition) => {
|
|
6
6
|
anchorOrigin: PopoverOrigin;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
+
import type { SxProps } from '@mui/material';
|
|
2
|
+
import type { NumberSize } from 're-resizable';
|
|
1
3
|
import React from 'react';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import { DraggableSize, DraggablePosition, Position, ResizableComponentProps, Size } from '../DraggableResizable/types';
|
|
5
|
-
import { HeaderSize } from './types';
|
|
4
|
+
import type { HeaderSize } from './types';
|
|
5
|
+
import type { DraggablePosition, DraggableSize, Position, ResizableComponentProps, Size } from '../DraggableResizable/types';
|
|
6
6
|
export declare const calculateDialogSizeAndPosition: () => {
|
|
7
7
|
width: number;
|
|
8
8
|
height: number;
|
|
@@ -4,4 +4,4 @@ export type { Source } from './ToolContainerDraggable';
|
|
|
4
4
|
export { calculateDialogSizeAndPosition, calculateStartSize, } from './ToolContainerDraggable';
|
|
5
5
|
export { default as ToolHeader } from './ToolHeader';
|
|
6
6
|
export { default as ToolFooter } from './ToolFooter';
|
|
7
|
-
export * from './types';
|
|
7
|
+
export type * from './types';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { DraggablePosition, Position, Size } from '../DraggableResizable/types';
|
|
2
|
+
import type { DraggablePosition, Position, Size } from '../DraggableResizable/types';
|
|
3
3
|
export declare const getNewPositionSize: (element: Element, boundsNode: Element, isRightAligned: boolean, position: DraggablePosition, newSize?: Size) => {
|
|
4
4
|
position: Position;
|
|
5
5
|
size: Size;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
1
|
+
import type { BaseSelectProps, SelectVariants, SxProps, Theme } from '@mui/material';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
interface ListElement {
|
|
4
4
|
value: string;
|
|
5
5
|
}
|
package/src/lib/hooks/index.d.ts
CHANGED
|
@@ -6,3 +6,4 @@ export * from './useMakeSureContainerStaysInsideWindow/useMakeSureContainerStays
|
|
|
6
6
|
export * from './useDebounce/useDebounce';
|
|
7
7
|
export * from './useWheelStopPropagation/useWheelStopPropagation';
|
|
8
8
|
export * from './useScrollingInIsolation/useScrollingInIsolation';
|
|
9
|
+
export * from './useResizeObserver/useResizeObserver';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { DraggablePosition } from '../../components/DraggableResizable/types';
|
|
2
|
+
import type { DraggablePosition } from '../../components/DraggableResizable/types';
|
|
3
3
|
export declare const adjustPosition: (bbox: DOMRect, containingView: DOMRect, position: DraggablePosition, setPosition: (position: DraggablePosition) => void) => void;
|
|
4
4
|
export declare const useMakeSureContainerStaysInsideWindow: (nodeRef: React.RefObject<HTMLDivElement>, position: DraggablePosition, setPosition: (position: DraggablePosition) => void) => void;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Referencing } from './crss-types';
|
|
1
|
+
import type { Referencing } from './crss-types';
|
|
2
2
|
interface AxisValues {
|
|
3
3
|
values: number[] | string[];
|
|
4
4
|
}
|
|
@@ -8,6 +8,30 @@ interface SingleValueAxis {
|
|
|
8
8
|
interface SingleTimeValueAxis {
|
|
9
9
|
values: [string];
|
|
10
10
|
}
|
|
11
|
+
interface PointSeriesAxes {
|
|
12
|
+
x: SingleValueAxis;
|
|
13
|
+
y: SingleValueAxis;
|
|
14
|
+
z?: SingleTimeValueAxis;
|
|
15
|
+
t: AxisValues;
|
|
16
|
+
}
|
|
17
|
+
export interface PointSeriesDomain {
|
|
18
|
+
type: 'Domain';
|
|
19
|
+
domainType: 'PointSeries';
|
|
20
|
+
axes: PointSeriesAxes;
|
|
21
|
+
referencing?: Referencing[];
|
|
22
|
+
}
|
|
23
|
+
interface PointAxes {
|
|
24
|
+
x: SingleValueAxis;
|
|
25
|
+
y: SingleValueAxis;
|
|
26
|
+
z?: SingleValueAxis;
|
|
27
|
+
t?: SingleTimeValueAxis;
|
|
28
|
+
}
|
|
29
|
+
export interface PointDomain {
|
|
30
|
+
type: 'Domain';
|
|
31
|
+
domainType: 'Point';
|
|
32
|
+
axes: PointAxes;
|
|
33
|
+
referencing?: Referencing[];
|
|
34
|
+
}
|
|
11
35
|
interface VerticalProfileAxes {
|
|
12
36
|
x: SingleValueAxis;
|
|
13
37
|
y: SingleValueAxis;
|
|
@@ -20,6 +44,7 @@ export interface VerticalProfileDomain {
|
|
|
20
44
|
axes: VerticalProfileAxes;
|
|
21
45
|
referencing?: Referencing[];
|
|
22
46
|
}
|
|
47
|
+
export type CoverageDomain = VerticalProfileDomain | PointDomain | PointSeriesDomain;
|
|
23
48
|
interface NdArray {
|
|
24
49
|
type: 'NdArray';
|
|
25
50
|
dataType: 'float' | 'integer' | 'string';
|
|
@@ -45,17 +70,17 @@ interface Parameter {
|
|
|
45
70
|
description?: Description;
|
|
46
71
|
};
|
|
47
72
|
}
|
|
48
|
-
export interface Coverage {
|
|
73
|
+
export interface Coverage<T extends CoverageDomain> {
|
|
49
74
|
type: 'Coverage';
|
|
50
|
-
domain:
|
|
75
|
+
domain: T;
|
|
51
76
|
ranges: Ranges;
|
|
52
77
|
}
|
|
53
|
-
export interface CoverageCollection {
|
|
78
|
+
export interface CoverageCollection<T extends CoverageDomain> {
|
|
54
79
|
type: 'CoverageCollection';
|
|
55
|
-
domainType:
|
|
80
|
+
domainType: string;
|
|
56
81
|
parameters: Record<string, Parameter>;
|
|
57
82
|
ranges: Record<string, NdArray>;
|
|
58
|
-
coverages: Coverage[];
|
|
83
|
+
coverages: Coverage<T>[];
|
|
59
84
|
referencing: Referencing[];
|
|
60
85
|
}
|
|
61
86
|
export {};
|
package/src/lib/types/index.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export * from './types';
|
|
2
|
-
export * from './edr-coverage-types';
|
|
2
|
+
export type * from './edr-coverage-types';
|
package/src/lib/types/types.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ThemeTypes } from '@opengeoweb/theme';
|
|
1
|
+
import type { ThemeTypes } from '@opengeoweb/theme';
|
|
2
2
|
export interface ConfigType {
|
|
3
3
|
GW_AUTH_LOGIN_URL?: string;
|
|
4
4
|
GW_AUTH_LOGOUT_URL?: string;
|
|
@@ -21,6 +21,7 @@ export interface ConfigType {
|
|
|
21
21
|
GW_DRAWINGS_BASE_URL?: string;
|
|
22
22
|
GW_WARNINGS_WORKSPACE_ID?: string;
|
|
23
23
|
GW_SPACE_WEATHER_WORKSPACE_ID?: string;
|
|
24
|
+
GW_TRAJKS_WORKSPACE_ID?: string;
|
|
24
25
|
GW_TECHNICAL_RELEASE_NOTES_URL?: string;
|
|
25
26
|
GW_VERSION_PROGRESS_NOTES_URL?: string;
|
|
26
27
|
GW_BE_RELEASE_URL?: string;
|
|
@@ -136,6 +137,20 @@ export interface EDRInstance {
|
|
|
136
137
|
};
|
|
137
138
|
};
|
|
138
139
|
};
|
|
140
|
+
area?: {
|
|
141
|
+
link: {
|
|
142
|
+
variables: {
|
|
143
|
+
output_formats: string[];
|
|
144
|
+
};
|
|
145
|
+
};
|
|
146
|
+
};
|
|
147
|
+
cube?: {
|
|
148
|
+
link: {
|
|
149
|
+
variables: {
|
|
150
|
+
output_formats: string[];
|
|
151
|
+
};
|
|
152
|
+
};
|
|
153
|
+
};
|
|
139
154
|
instances?: {
|
|
140
155
|
link: string;
|
|
141
156
|
};
|
|
@@ -156,4 +171,7 @@ export interface EDRInstance {
|
|
|
156
171
|
values: string[];
|
|
157
172
|
};
|
|
158
173
|
};
|
|
174
|
+
parameter_names?: object;
|
|
175
|
+
title?: string;
|
|
176
|
+
description?: string;
|
|
159
177
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { AxiosError } from 'axios';
|
|
1
|
+
import type { AxiosError } from 'axios';
|
|
2
2
|
export declare const DEFAULT_ERROR_MESSAGE = "An error has occurred";
|
|
3
3
|
export declare const isAxiosError: (error: AxiosError | Error) => error is AxiosError;
|
|
4
4
|
export declare const isAxiosAuthError: (error: AxiosError | Error) => boolean;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
export declare const DATE_FORMAT_DATEPICKER = "dd/MM/yyyy HH:mm";
|
|
2
|
+
export declare const DATE_FORMAT_DATEPICKER_NO_YEAR = "dd/MM HH:mm";
|
|
2
3
|
export declare const DATE_FORMAT_UTC = "yyyy-MM-dd'T'HH:mm:ss'Z'";
|
|
3
4
|
export declare const DATE_FORMAT_YEAR = "yyyy-MM-dd";
|
|
4
5
|
export declare const DATE_FORMAT_HOURS = "HH:mm";
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import type { Duration, NearestMinutes, Locale } from 'date-fns';
|
|
2
|
+
import { parseISO, isEqual, startOfDay, isWithinInterval, getDayOfYear, getDay, getMonth, getYear, getWeek } from 'date-fns';
|
|
2
3
|
export interface DateValues {
|
|
3
4
|
year?: number;
|
|
4
5
|
month?: number;
|
|
@@ -238,7 +239,7 @@ export declare const isAfter: (date: Date | number, dateToCompare: Date | number
|
|
|
238
239
|
* @param dateStr - string containing date
|
|
239
240
|
* @returns {Date} - Date in UTC, or current date when something invalid is passed.
|
|
240
241
|
*/
|
|
241
|
-
export declare const utc: (dateStr?: string
|
|
242
|
+
export declare const utc: (dateStr?: string) => Date;
|
|
242
243
|
/**
|
|
243
244
|
* Parsing string to a date. Stricter check, will return undefined when dateString is invalid.
|
|
244
245
|
* @param dateStr - string containing date
|