@cyber-harbour/ui 1.0.30 → 1.0.32
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.mts +18 -4
- package/dist/index.d.ts +18 -4
- package/dist/index.js +131 -109
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +131 -109
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/Core/EmptyData/EmptyData.tsx +44 -0
- package/src/Core/EmptyData/index.ts +1 -0
- package/src/Core/Input/Input.tsx +34 -35
- package/src/Core/index.ts +1 -0
- package/src/Theme/theme.ts +42 -0
- package/src/Theme/types.ts +3 -2
- package/src/Theme/utils.ts +16 -17
package/dist/index.d.mts
CHANGED
|
@@ -18,9 +18,9 @@ type ButtonVariant = 'fill' | 'outlined' | 'empty';
|
|
|
18
18
|
type ButtonColor = 'default' | 'primary' | 'secondary' | 'error';
|
|
19
19
|
type ButtonState = 'default' | 'hover' | 'active' | 'disabled';
|
|
20
20
|
type ButtonSize = 'small' | 'medium';
|
|
21
|
-
type InputVariant = 'outlined';
|
|
21
|
+
type InputVariant = 'outlined' | 'empty';
|
|
22
22
|
type InputState = 'default' | 'focus' | 'error' | 'disabled';
|
|
23
|
-
type InputSize = 'small' | 'medium';
|
|
23
|
+
type InputSize = 'empty' | 'small' | 'medium';
|
|
24
24
|
type Breakpoint = 'xs' | 's' | 'm' | 'l' | 'xl';
|
|
25
25
|
type ButtonElementStyle = {
|
|
26
26
|
background: string;
|
|
@@ -195,6 +195,7 @@ type Theme = {
|
|
|
195
195
|
input: {
|
|
196
196
|
sizes: Record<InputSize, InputSizeStyle>;
|
|
197
197
|
outlined: Record<InputState, InputElementStyle>;
|
|
198
|
+
empty: Record<InputState, InputElementStyle>;
|
|
198
199
|
};
|
|
199
200
|
box: {
|
|
200
201
|
padding: number | string;
|
|
@@ -243,6 +244,10 @@ declare const convertPaletteToRem: (obj: Record<string, any>, baseSize?: number,
|
|
|
243
244
|
*/
|
|
244
245
|
declare const getButtonStyles: <V extends ButtonVariant>(theme: DefaultTheme, variant: ButtonVariant, color: ButtonColor, state: ButtonState) => ButtonElementStyle;
|
|
245
246
|
declare const getButtonSizeStyles: (theme: DefaultTheme, size: ButtonSize) => ButtonSizeStyle;
|
|
247
|
+
/**
|
|
248
|
+
* Функція для отримання стилів інпута за варіантом та станом
|
|
249
|
+
*/
|
|
250
|
+
declare const getInputStyles: (theme: DefaultTheme, variant: InputVariant, state: InputState) => InputElementStyle;
|
|
246
251
|
/**
|
|
247
252
|
* Функція для отримання типографічних стилів
|
|
248
253
|
*/
|
|
@@ -721,8 +726,9 @@ type InputProps = Omit<InputHTMLAttributes<HTMLInputElement>, 'size'> & {
|
|
|
721
726
|
append?: any;
|
|
722
727
|
prepend?: any;
|
|
723
728
|
size?: InputSize;
|
|
729
|
+
variant?: InputVariant;
|
|
724
730
|
};
|
|
725
|
-
declare const Input:
|
|
731
|
+
declare const Input: any;
|
|
726
732
|
|
|
727
733
|
type FlexDirection = 'row' | 'column' | 'row-reverse' | 'column-reverse';
|
|
728
734
|
type FlexWrap = 'nowrap' | 'wrap' | 'wrap-reverse';
|
|
@@ -801,6 +807,14 @@ type LineProps = FabricComponent<{
|
|
|
801
807
|
} & Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, 'children'>>;
|
|
802
808
|
declare const Line: ({ direction, ...props }: LineProps) => react_jsx_runtime.JSX.Element;
|
|
803
809
|
|
|
810
|
+
interface EmptyDataProps {
|
|
811
|
+
children?: any;
|
|
812
|
+
title?: string;
|
|
813
|
+
note?: string;
|
|
814
|
+
className?: string;
|
|
815
|
+
}
|
|
816
|
+
declare const EmptyData: ({ children, title, note, className }: EmptyDataProps) => react_jsx_runtime.JSX.Element;
|
|
817
|
+
|
|
804
818
|
interface PageLayoutProps {
|
|
805
819
|
header?: any;
|
|
806
820
|
sidebar?: any;
|
|
@@ -847,4 +861,4 @@ interface FullscreenCardProps {
|
|
|
847
861
|
}
|
|
848
862
|
declare const FullscreenCard: ({ isActive, position, ...props }: FullscreenCardProps) => react_jsx_runtime.JSX.Element;
|
|
849
863
|
|
|
850
|
-
export { type Action, AlertIcon, ApiIcon, ArrowCircleTopRightIcon, ArrowRightIcon, BallsMenu, Box, type Breakpoint, BugReportIcon, Button, type ButtonColor, type ButtonElementStyle, type ButtonProps, type ButtonSize, type ButtonSizeStyle, type ButtonState, type ButtonVariant, CalendarIcon, CheckIcon, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon, ChevronUpIcon, ClosedLockIcon, type ColorVariant, type ColumnTable, Container, ContextMenu, ContextMenuDelimiter, CrossIcon, DataSetsIcon, DeepSearchIcon, DisabledVisibleIcon, DocsIcon, DownloadIcon, EditUserIcon, EnableVisibleIcon, EnterArrowLeftIcon, type FabricComponent, FiltersIcon, FlexContainer, FlexItem, FullscreenCard, GlobalStyle, Graph2D, type Graph2DProps, Header, HeaderDelimeter, HeaderSection, HomepageIcon, InfoCircleFilledIcon, InfoCircleIcon, Input, type InputElementStyle, type InputSize, type InputSizeStyle, type InputState, type InputVariant, Line, ListMenu, ListMenuItem, type ListMenuItemAnchorProps, type ListMenuItemBase, type ListMenuItemButtonProps, type ListMenuItemProps, type ListMenuProps, ListMenuSection, type ListMenuSectionProps, MapRadarIcon, MaximizeIcon, MoonIcon, type NestedColorPaths, OpenLockIcon, OrganizationIcon, PageLayout, Pagination, type PaginationProps, PasswordFinderIcon, PhonebookIcon, PlusIcon, PrintIcon, Profiler2Icon, ProfilerIcon, type RenderCellProps, type RenderHeaderCellProps, RowActionsMenu, SandBoxIcon, SearchIcon, Select, Sidebar, SidebarContext, SidebarDelimeter, SidebarItem, type SidebarItemProps, type SidebarProps, SidebarSection, type SidebarSectionProps, StatisticIcon, StyledContainer, SunIcon, Table, type Theme, ThemeProvider, Typography, type TypographyVariant, UnfoldIcon, UpRightArrowCircleIcon, UsersIcon, VectorIcon, convertPaletteToRem, createComponent, darkTheme, getBreakpoint, getButtonSizeStyles, getButtonStyles, getTypographyStyles, lightTheme, lightThemePx, pxToRem, resolveThemeColor, useContextMenuControl };
|
|
864
|
+
export { type Action, AlertIcon, ApiIcon, ArrowCircleTopRightIcon, ArrowRightIcon, BallsMenu, Box, type Breakpoint, BugReportIcon, Button, type ButtonColor, type ButtonElementStyle, type ButtonProps, type ButtonSize, type ButtonSizeStyle, type ButtonState, type ButtonVariant, CalendarIcon, CheckIcon, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon, ChevronUpIcon, ClosedLockIcon, type ColorVariant, type ColumnTable, Container, ContextMenu, ContextMenuDelimiter, CrossIcon, DataSetsIcon, DeepSearchIcon, DisabledVisibleIcon, DocsIcon, DownloadIcon, EditUserIcon, EmptyData, type EmptyDataProps, EnableVisibleIcon, EnterArrowLeftIcon, type FabricComponent, FiltersIcon, FlexContainer, FlexItem, FullscreenCard, GlobalStyle, Graph2D, type Graph2DProps, Header, HeaderDelimeter, HeaderSection, HomepageIcon, InfoCircleFilledIcon, InfoCircleIcon, Input, type InputElementStyle, type InputProps, type InputSize, type InputSizeStyle, type InputState, type InputVariant, Line, ListMenu, ListMenuItem, type ListMenuItemAnchorProps, type ListMenuItemBase, type ListMenuItemButtonProps, type ListMenuItemProps, type ListMenuProps, ListMenuSection, type ListMenuSectionProps, MapRadarIcon, MaximizeIcon, MoonIcon, type NestedColorPaths, OpenLockIcon, OrganizationIcon, PageLayout, Pagination, type PaginationProps, PasswordFinderIcon, PhonebookIcon, PlusIcon, PrintIcon, Profiler2Icon, ProfilerIcon, type RenderCellProps, type RenderHeaderCellProps, RowActionsMenu, SandBoxIcon, SearchIcon, Select, Sidebar, SidebarContext, SidebarDelimeter, SidebarItem, type SidebarItemProps, type SidebarProps, SidebarSection, type SidebarSectionProps, StatisticIcon, StyledContainer, SunIcon, Table, type Theme, ThemeProvider, Typography, type TypographyVariant, UnfoldIcon, UpRightArrowCircleIcon, UsersIcon, VectorIcon, convertPaletteToRem, createComponent, darkTheme, getBreakpoint, getButtonSizeStyles, getButtonStyles, getInputStyles, getTypographyStyles, lightTheme, lightThemePx, pxToRem, resolveThemeColor, useContextMenuControl };
|
package/dist/index.d.ts
CHANGED
|
@@ -18,9 +18,9 @@ type ButtonVariant = 'fill' | 'outlined' | 'empty';
|
|
|
18
18
|
type ButtonColor = 'default' | 'primary' | 'secondary' | 'error';
|
|
19
19
|
type ButtonState = 'default' | 'hover' | 'active' | 'disabled';
|
|
20
20
|
type ButtonSize = 'small' | 'medium';
|
|
21
|
-
type InputVariant = 'outlined';
|
|
21
|
+
type InputVariant = 'outlined' | 'empty';
|
|
22
22
|
type InputState = 'default' | 'focus' | 'error' | 'disabled';
|
|
23
|
-
type InputSize = 'small' | 'medium';
|
|
23
|
+
type InputSize = 'empty' | 'small' | 'medium';
|
|
24
24
|
type Breakpoint = 'xs' | 's' | 'm' | 'l' | 'xl';
|
|
25
25
|
type ButtonElementStyle = {
|
|
26
26
|
background: string;
|
|
@@ -195,6 +195,7 @@ type Theme = {
|
|
|
195
195
|
input: {
|
|
196
196
|
sizes: Record<InputSize, InputSizeStyle>;
|
|
197
197
|
outlined: Record<InputState, InputElementStyle>;
|
|
198
|
+
empty: Record<InputState, InputElementStyle>;
|
|
198
199
|
};
|
|
199
200
|
box: {
|
|
200
201
|
padding: number | string;
|
|
@@ -243,6 +244,10 @@ declare const convertPaletteToRem: (obj: Record<string, any>, baseSize?: number,
|
|
|
243
244
|
*/
|
|
244
245
|
declare const getButtonStyles: <V extends ButtonVariant>(theme: DefaultTheme, variant: ButtonVariant, color: ButtonColor, state: ButtonState) => ButtonElementStyle;
|
|
245
246
|
declare const getButtonSizeStyles: (theme: DefaultTheme, size: ButtonSize) => ButtonSizeStyle;
|
|
247
|
+
/**
|
|
248
|
+
* Функція для отримання стилів інпута за варіантом та станом
|
|
249
|
+
*/
|
|
250
|
+
declare const getInputStyles: (theme: DefaultTheme, variant: InputVariant, state: InputState) => InputElementStyle;
|
|
246
251
|
/**
|
|
247
252
|
* Функція для отримання типографічних стилів
|
|
248
253
|
*/
|
|
@@ -721,8 +726,9 @@ type InputProps = Omit<InputHTMLAttributes<HTMLInputElement>, 'size'> & {
|
|
|
721
726
|
append?: any;
|
|
722
727
|
prepend?: any;
|
|
723
728
|
size?: InputSize;
|
|
729
|
+
variant?: InputVariant;
|
|
724
730
|
};
|
|
725
|
-
declare const Input:
|
|
731
|
+
declare const Input: any;
|
|
726
732
|
|
|
727
733
|
type FlexDirection = 'row' | 'column' | 'row-reverse' | 'column-reverse';
|
|
728
734
|
type FlexWrap = 'nowrap' | 'wrap' | 'wrap-reverse';
|
|
@@ -801,6 +807,14 @@ type LineProps = FabricComponent<{
|
|
|
801
807
|
} & Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, 'children'>>;
|
|
802
808
|
declare const Line: ({ direction, ...props }: LineProps) => react_jsx_runtime.JSX.Element;
|
|
803
809
|
|
|
810
|
+
interface EmptyDataProps {
|
|
811
|
+
children?: any;
|
|
812
|
+
title?: string;
|
|
813
|
+
note?: string;
|
|
814
|
+
className?: string;
|
|
815
|
+
}
|
|
816
|
+
declare const EmptyData: ({ children, title, note, className }: EmptyDataProps) => react_jsx_runtime.JSX.Element;
|
|
817
|
+
|
|
804
818
|
interface PageLayoutProps {
|
|
805
819
|
header?: any;
|
|
806
820
|
sidebar?: any;
|
|
@@ -847,4 +861,4 @@ interface FullscreenCardProps {
|
|
|
847
861
|
}
|
|
848
862
|
declare const FullscreenCard: ({ isActive, position, ...props }: FullscreenCardProps) => react_jsx_runtime.JSX.Element;
|
|
849
863
|
|
|
850
|
-
export { type Action, AlertIcon, ApiIcon, ArrowCircleTopRightIcon, ArrowRightIcon, BallsMenu, Box, type Breakpoint, BugReportIcon, Button, type ButtonColor, type ButtonElementStyle, type ButtonProps, type ButtonSize, type ButtonSizeStyle, type ButtonState, type ButtonVariant, CalendarIcon, CheckIcon, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon, ChevronUpIcon, ClosedLockIcon, type ColorVariant, type ColumnTable, Container, ContextMenu, ContextMenuDelimiter, CrossIcon, DataSetsIcon, DeepSearchIcon, DisabledVisibleIcon, DocsIcon, DownloadIcon, EditUserIcon, EnableVisibleIcon, EnterArrowLeftIcon, type FabricComponent, FiltersIcon, FlexContainer, FlexItem, FullscreenCard, GlobalStyle, Graph2D, type Graph2DProps, Header, HeaderDelimeter, HeaderSection, HomepageIcon, InfoCircleFilledIcon, InfoCircleIcon, Input, type InputElementStyle, type InputSize, type InputSizeStyle, type InputState, type InputVariant, Line, ListMenu, ListMenuItem, type ListMenuItemAnchorProps, type ListMenuItemBase, type ListMenuItemButtonProps, type ListMenuItemProps, type ListMenuProps, ListMenuSection, type ListMenuSectionProps, MapRadarIcon, MaximizeIcon, MoonIcon, type NestedColorPaths, OpenLockIcon, OrganizationIcon, PageLayout, Pagination, type PaginationProps, PasswordFinderIcon, PhonebookIcon, PlusIcon, PrintIcon, Profiler2Icon, ProfilerIcon, type RenderCellProps, type RenderHeaderCellProps, RowActionsMenu, SandBoxIcon, SearchIcon, Select, Sidebar, SidebarContext, SidebarDelimeter, SidebarItem, type SidebarItemProps, type SidebarProps, SidebarSection, type SidebarSectionProps, StatisticIcon, StyledContainer, SunIcon, Table, type Theme, ThemeProvider, Typography, type TypographyVariant, UnfoldIcon, UpRightArrowCircleIcon, UsersIcon, VectorIcon, convertPaletteToRem, createComponent, darkTheme, getBreakpoint, getButtonSizeStyles, getButtonStyles, getTypographyStyles, lightTheme, lightThemePx, pxToRem, resolveThemeColor, useContextMenuControl };
|
|
864
|
+
export { type Action, AlertIcon, ApiIcon, ArrowCircleTopRightIcon, ArrowRightIcon, BallsMenu, Box, type Breakpoint, BugReportIcon, Button, type ButtonColor, type ButtonElementStyle, type ButtonProps, type ButtonSize, type ButtonSizeStyle, type ButtonState, type ButtonVariant, CalendarIcon, CheckIcon, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon, ChevronUpIcon, ClosedLockIcon, type ColorVariant, type ColumnTable, Container, ContextMenu, ContextMenuDelimiter, CrossIcon, DataSetsIcon, DeepSearchIcon, DisabledVisibleIcon, DocsIcon, DownloadIcon, EditUserIcon, EmptyData, type EmptyDataProps, EnableVisibleIcon, EnterArrowLeftIcon, type FabricComponent, FiltersIcon, FlexContainer, FlexItem, FullscreenCard, GlobalStyle, Graph2D, type Graph2DProps, Header, HeaderDelimeter, HeaderSection, HomepageIcon, InfoCircleFilledIcon, InfoCircleIcon, Input, type InputElementStyle, type InputProps, type InputSize, type InputSizeStyle, type InputState, type InputVariant, Line, ListMenu, ListMenuItem, type ListMenuItemAnchorProps, type ListMenuItemBase, type ListMenuItemButtonProps, type ListMenuItemProps, type ListMenuProps, ListMenuSection, type ListMenuSectionProps, MapRadarIcon, MaximizeIcon, MoonIcon, type NestedColorPaths, OpenLockIcon, OrganizationIcon, PageLayout, Pagination, type PaginationProps, PasswordFinderIcon, PhonebookIcon, PlusIcon, PrintIcon, Profiler2Icon, ProfilerIcon, type RenderCellProps, type RenderHeaderCellProps, RowActionsMenu, SandBoxIcon, SearchIcon, Select, Sidebar, SidebarContext, SidebarDelimeter, SidebarItem, type SidebarItemProps, type SidebarProps, SidebarSection, type SidebarSectionProps, StatisticIcon, StyledContainer, SunIcon, Table, type Theme, ThemeProvider, Typography, type TypographyVariant, UnfoldIcon, UpRightArrowCircleIcon, UsersIcon, VectorIcon, convertPaletteToRem, createComponent, darkTheme, getBreakpoint, getButtonSizeStyles, getButtonStyles, getInputStyles, getTypographyStyles, lightTheme, lightThemePx, pxToRem, resolveThemeColor, useContextMenuControl };
|