prometeo-design-system 3.1.3 → 3.1.4
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/Avatar.es.js +42 -36
- package/dist/Button.es.js +27 -27
- package/dist/{CardProfile-BVO6fKr9.js → CardProfile-y9Knsg26.js} +23 -23
- package/dist/CardProfile.es.js +1 -1
- package/dist/CheckBox.es.js +1 -1
- package/dist/DatePicker-CehTiXGa.js +3631 -0
- package/dist/DatePicker.es.js +1 -1
- package/dist/DialogModal.es.js +1 -1
- package/dist/DrawerDesktop.es.js +78 -72
- package/dist/DrawerMobile.es.js +1 -1
- package/dist/DropZone.es.js +1 -1
- package/dist/FAButton.es.js +1 -1
- package/dist/Header.es.js +4 -4
- package/dist/{HelperComponent-DhGU_ug-.js → HelperComponent-ljsn0xD6.js} +1 -1
- package/dist/Icons/AccountCircle.es.js +1 -1
- package/dist/Icons/Add.es.js +1 -1
- package/dist/Icons/ArrowLeft.es.js +1 -1
- package/dist/Icons/ArrowUpDown.es.js +1 -1
- package/dist/Icons/AttachFile.es.js +1 -1
- package/dist/Icons/Boards.es.js +1 -1
- package/dist/Icons/Calendar.es.js +1 -1
- package/dist/Icons/Cancel.es.js +1 -1
- package/dist/Icons/Check.es.js +1 -1
- package/dist/Icons/CheckCircle.es.js +1 -1
- package/dist/Icons/CheckList.es.js +1 -1
- package/dist/Icons/ChevronDown.es.js +1 -1
- package/dist/Icons/Clock.es.js +1 -1
- package/dist/Icons/Close.es.js +1 -1
- package/dist/Icons/CloseNavBarDesktop.es.js +1 -1
- package/dist/Icons/Collapse.es.js +1 -1
- package/dist/Icons/Company.es.js +1 -1
- package/dist/Icons/Copy.es.js +1 -1
- package/dist/Icons/CrevronLeft.es.js +1 -1
- package/dist/Icons/CrevronRight.es.js +1 -1
- package/dist/Icons/DocumentFill.es.js +1 -1
- package/dist/Icons/Download.es.js +1 -1
- package/dist/Icons/Edit.es.js +1 -1
- package/dist/Icons/EditFill.es.js +1 -1
- package/dist/Icons/Email.es.js +1 -1
- package/dist/Icons/Error.es.js +1 -1
- package/dist/Icons/EyeVisibility.es.js +1 -1
- package/dist/Icons/EyeVisibilityOff.es.js +1 -1
- package/dist/Icons/FaLock.es.js +1 -1
- package/dist/Icons/FastForward.es.js +1 -1
- package/dist/Icons/File.es.js +1 -1
- package/dist/Icons/Filter.es.js +1 -1
- package/dist/Icons/FormatColorText.es.js +1 -1
- package/dist/Icons/Help.es.js +1 -1
- package/dist/Icons/HistoryActivity.es.js +1 -1
- package/dist/Icons/Home.es.js +1 -1
- package/dist/Icons/Image.es.js +1 -1
- package/dist/Icons/Info.es.js +1 -1
- package/dist/Icons/Logout.es.js +1 -1
- package/dist/Icons/MessageSquare.es.js +1 -1
- package/dist/Icons/MessageSquareFill.es.js +1 -1
- package/dist/Icons/MoreVert.es.js +1 -1
- package/dist/Icons/Notifications.es.js +1 -1
- package/dist/Icons/Pause.es.js +1 -1
- package/dist/Icons/Reload.es.js +1 -1
- package/dist/Icons/Search.es.js +1 -1
- package/dist/Icons/Settings.es.js +1 -1
- package/dist/Icons/Shared.es.js +1 -1
- package/dist/Icons/Sort.es.js +1 -1
- package/dist/Icons/Stars.es.js +1 -1
- package/dist/Icons/Ticket.es.js +1 -1
- package/dist/Icons/TicketFilled.es.js +1 -1
- package/dist/Icons/Trash.es.js +1 -1
- package/dist/Icons/TrashFill.es.js +1 -1
- package/dist/Icons/Upload.es.js +1 -1
- package/dist/Icons/UploadCloud.es.js +1 -1
- package/dist/Icons/UserAdd.es.js +1 -1
- package/dist/Icons/UserAddFill.es.js +1 -1
- package/dist/Icons/UserPerson.es.js +1 -1
- package/dist/Icons/WhatsApp.es.js +1 -1
- package/dist/Image.es.js +1 -1
- package/dist/{ImageGallery-4DdXqwRy.js → ImageGallery-DG9ovlQ-.js} +1 -1
- package/dist/ImageGallery.es.js +1 -1
- package/dist/Input.es.js +218 -2
- package/dist/InputMultiple.es.js +1 -1
- package/dist/{LayoutGeneric-CbaoatQB.js → LayoutGeneric-CfWhV1ov.js} +6 -6
- package/dist/LayoutGeneric.es.js +1 -1
- package/dist/Logo.es.js +1 -1
- package/dist/Menu.es.js +1 -1
- package/dist/OtpInput.es.js +1 -1
- package/dist/Pagination.es.js +1 -1
- package/dist/ProfilePictureUpload.es.js +1 -1
- package/dist/ProgressBar.es.js +1 -1
- package/dist/RadioButton.es.js +2 -2
- package/dist/RecurrentDatePicker.es.js +7 -7
- package/dist/RecurrentDatePickerRRule.es.js +2 -4
- package/dist/Scrollable.d.ts +2 -0
- package/dist/Scrollable.es.js +260 -0
- package/dist/SegmentedButton.es.js +1 -1
- package/dist/{Select-Bq1fVlwM.js → Select-BdxmkrjB.js} +12 -11
- package/dist/Select.es.js +1 -1
- package/dist/SelectSearch.es.js +2 -2
- package/dist/Skeleton.es.js +1 -1
- package/dist/Spinner.es.js +1 -1
- package/dist/Steps.es.js +1 -1
- package/dist/SwipeContainer.es.js +1 -1
- package/dist/Switch.es.js +7 -7
- package/dist/TabLinks.es.js +9 -9
- package/dist/Table.es.js +1 -1
- package/dist/TextArea.es.js +1 -1
- package/dist/Toast.es.js +1 -1
- package/dist/ToastProvider.es.js +1 -1
- package/dist/Tooltip.es.js +1 -1
- package/dist/components/Avatar/Avatar.d.ts +1 -1
- package/dist/components/Drawer/DrawerDesktop.d.ts +1 -0
- package/dist/components/NavigationDrawer/NavigationDrawer.d.ts +18 -2
- package/dist/components/NavigationDrawer/NavigationDrawerActionItem.d.ts +3 -1
- package/dist/components/NavigationDrawer/NavigationDrawerItemBase.d.ts +1 -0
- package/dist/components/NavigationDrawer/NavigationDrawerLinkItem.d.ts +1 -0
- package/dist/components/NotificationCard/NotificationCard.d.ts +25 -0
- package/dist/components/PyrionNavigationDrawer/PyrionHelpSection.d.ts +8 -0
- package/dist/components/PyrionNavigationDrawer/PyrionNavigationDrawer.d.ts +90 -11
- package/dist/components/PyrionNavigationDrawer/PyrionNavigationDrawerMobileAppSwitcher.d.ts +10 -0
- package/dist/components/PyrionNavigationDrawer/PyrionNavigationDrawerSystemLogo.d.ts +7 -0
- package/dist/components/PyrionNavigationDrawer/PyrionNotificationsList.d.ts +8 -0
- package/dist/components/PyrionNavigationDrawer/SidebarContent.d.ts +13 -0
- package/dist/components/PyrionNavigationDrawer/SystemSessions.d.ts +12 -0
- package/dist/components/Scrollable/Scrollable.d.ts +9 -3
- package/dist/components/Sidebar/components/badge.d.ts +2 -1
- package/dist/components/TicketCard/TicketCard.d.ts +32 -0
- package/dist/components/UserCard/UserCard.d.ts +12 -0
- package/dist/exports/Scrollable.d.ts +2 -0
- package/dist/hooks/useLabelBackground.d.ts +1 -0
- package/dist/{jsx-runtime-DKDX3adD.js → jsx-runtime-GkKLlHH4.js} +2 -20
- package/dist/lib/utils.d.ts +2 -2
- package/dist/prometeo-design-system.es.js +54 -51
- package/dist/styles.css +1 -1
- package/dist/useLabelBackground-BDIHUdND.js +26 -0
- package/package.json +9 -5
- package/src/styles/base.css +25 -0
- package/src/styles/palette.css +3 -0
- package/dist/DatePicker-D1EwMGIN.js +0 -3568
- package/dist/Input-EkMrxcNX.js +0 -241
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { NavigationDrawerSidebarProps } from '../NavigationDrawer/NavigationDrawer';
|
|
3
3
|
import { NavigationDrawerActionItemProps } from '../NavigationDrawer/NavigationDrawerActionItem';
|
|
4
|
+
import { NavigationDrawerLinkItemProps } from '../NavigationDrawer/NavigationDrawerLinkItem';
|
|
5
|
+
import { NotificationCardProps } from '../NotificationCard/NotificationCard';
|
|
6
|
+
import { AllOptionAccessor } from '../Shared/types';
|
|
4
7
|
import { TabSwitchElement } from '../TabSwitch/TabSwitch';
|
|
8
|
+
import { subImageUrlAccessor } from './SystemSessions';
|
|
5
9
|
type TProduct = {
|
|
6
10
|
name: string;
|
|
7
11
|
domain: string;
|
|
@@ -14,38 +18,113 @@ type TCompany = {
|
|
|
14
18
|
products?: TProduct[];
|
|
15
19
|
icon?: string;
|
|
16
20
|
};
|
|
17
|
-
type TSystem = {
|
|
18
|
-
name: string;
|
|
19
|
-
url: string;
|
|
20
|
-
coverImage?: string;
|
|
21
|
-
thumbnail?: string;
|
|
22
|
-
};
|
|
23
21
|
type TUser = {
|
|
22
|
+
auth_id: string;
|
|
24
23
|
name: string;
|
|
25
24
|
surname?: string;
|
|
26
25
|
email?: string;
|
|
27
26
|
profile_picture?: string;
|
|
28
|
-
area?: string;
|
|
29
27
|
};
|
|
28
|
+
export type TSystem = {
|
|
29
|
+
name: string;
|
|
30
|
+
url: string;
|
|
31
|
+
coverImage?: string;
|
|
32
|
+
thumbnail?: string;
|
|
33
|
+
system_id: string;
|
|
34
|
+
};
|
|
35
|
+
type TSystemSession<TSystemMetadata> = TSystem & {
|
|
36
|
+
metadata?: TSystemMetadata;
|
|
37
|
+
};
|
|
38
|
+
export interface AuthSession<TSystemMetadata> {
|
|
39
|
+
token: string;
|
|
40
|
+
expires_at: string;
|
|
41
|
+
logoutDate?: string;
|
|
42
|
+
userHub: TUser;
|
|
43
|
+
systems: TSystemSession<TSystemMetadata>[];
|
|
44
|
+
}
|
|
30
45
|
export interface NavigationDrawerTabsProps {
|
|
31
46
|
currentTabName?: string;
|
|
32
47
|
customTabs?: TabSwitchElement[];
|
|
33
48
|
onTabClick?: (name: string) => void;
|
|
34
49
|
}
|
|
35
|
-
|
|
50
|
+
type AvailableData<TSystemMetadata> = {
|
|
51
|
+
company: TCompany;
|
|
52
|
+
user: TUser;
|
|
53
|
+
system?: TSystem;
|
|
54
|
+
metadata?: TSystemMetadata;
|
|
55
|
+
};
|
|
56
|
+
type SessionAvailableData<TSystemMetadata> = {
|
|
57
|
+
company: TCompany;
|
|
58
|
+
user: TUser;
|
|
59
|
+
system?: TSystemSession<TSystemMetadata>;
|
|
60
|
+
metadata?: TSystemMetadata;
|
|
61
|
+
};
|
|
62
|
+
type UserCardAccesors<TSystemMetadata> = AllOptionAccessor<AvailableData<TSystemMetadata>, string>;
|
|
63
|
+
type SessionCardAccesors<TSystemMetadata> = AllOptionAccessor<SessionAvailableData<TSystemMetadata>, string>;
|
|
64
|
+
interface UserCardOptions<TSystemMetadata> {
|
|
65
|
+
secondarySlot: UserCardAccesors<TSystemMetadata> | [UserCardAccesors<TSystemMetadata>, UserCardAccesors<TSystemMetadata>] | ((data: AvailableData<TSystemMetadata>) => React.ReactNode);
|
|
66
|
+
}
|
|
67
|
+
interface SessionCardOptions<TSystemMetadata> {
|
|
68
|
+
secondarySlot: SessionCardAccesors<TSystemMetadata> | [SessionCardAccesors<TSystemMetadata>, SessionCardAccesors<TSystemMetadata>] | ((data: SessionAvailableData<TSystemMetadata>) => React.ReactNode);
|
|
69
|
+
subImageUrlAccessor?: subImageUrlAccessor<TSystemMetadata>;
|
|
70
|
+
}
|
|
71
|
+
export interface NotificationsDrawerOptions {
|
|
72
|
+
hide?: boolean;
|
|
73
|
+
hideActionButton?: boolean;
|
|
74
|
+
onMarkAllAsRead?: () => void;
|
|
75
|
+
}
|
|
76
|
+
export interface HelpSectionDrawerOptions {
|
|
77
|
+
hide?: boolean;
|
|
78
|
+
hideActionButton?: boolean;
|
|
79
|
+
}
|
|
80
|
+
export interface ConfigurationActionOptions {
|
|
81
|
+
hideActionButton?: boolean;
|
|
82
|
+
onClick: VoidFunction;
|
|
83
|
+
}
|
|
84
|
+
export interface PyrionNavigationDrawerOptions<TSystemMetadata> {
|
|
85
|
+
userCardOptions?: UserCardOptions<TSystemMetadata>;
|
|
86
|
+
sessionCardOptions?: SessionCardOptions<TSystemMetadata>;
|
|
87
|
+
notificationsDrawerOptions?: NotificationsDrawerOptions;
|
|
88
|
+
helpSectionDrawerOptions?: HelpSectionDrawerOptions;
|
|
89
|
+
configurationActionOptions?: ConfigurationActionOptions;
|
|
90
|
+
sidebarOptions: Pick<NavigationDrawerSidebarProps, 'modal' | 'closeOnOverlayClick'>;
|
|
91
|
+
}
|
|
92
|
+
export interface PyrionNavigationDrawerProps<TSystemMetadata, NotificationMetadata = unknown> {
|
|
36
93
|
links?: NavigationDrawerLinkItemProps[];
|
|
37
94
|
actions?: NavigationDrawerActionItemProps[];
|
|
38
95
|
tabsProps?: NavigationDrawerTabsProps;
|
|
39
96
|
activeActionId?: string;
|
|
40
|
-
|
|
97
|
+
currentSystemId: string;
|
|
98
|
+
helpSection?: ReactNode | (() => ReactNode);
|
|
41
99
|
children?: ReactNode;
|
|
42
100
|
state: {
|
|
43
101
|
company: TCompany;
|
|
44
102
|
enabled_systems: TSystem[];
|
|
45
103
|
user: TUser;
|
|
104
|
+
sessions?: AuthSession<TSystemMetadata>[];
|
|
105
|
+
metadata?: TSystemMetadata;
|
|
106
|
+
notifications?: NotificationCardProps<NotificationMetadata>[];
|
|
46
107
|
};
|
|
108
|
+
options?: PyrionNavigationDrawerOptions<TSystemMetadata>;
|
|
109
|
+
onActionClick?: (id: string) => void;
|
|
47
110
|
onLinkClick?: (path: string) => void;
|
|
111
|
+
onSessionClick?: (session: AuthSession<TSystemMetadata>) => void;
|
|
48
112
|
onNavigate?: (from: string, to: string) => void;
|
|
113
|
+
onSystemLogoClick?: (collapsed?: boolean) => void;
|
|
114
|
+
onLogoutClick?: () => void;
|
|
49
115
|
}
|
|
50
|
-
|
|
116
|
+
type PyrionNavigationControls = {
|
|
117
|
+
toggleCollapse?: () => void;
|
|
118
|
+
getIsCollapsed?: () => boolean;
|
|
119
|
+
subscribeToCollapse?: (listener: (collapsed: boolean) => void) => () => void;
|
|
120
|
+
openSidebar?: () => void;
|
|
121
|
+
closeSidebar?: () => void;
|
|
122
|
+
toggleSidebar?: () => void;
|
|
123
|
+
getIsSidebarOpen?: () => boolean;
|
|
124
|
+
subscribeToSidebarOpen?: (listener: (open: boolean) => void) => () => void;
|
|
125
|
+
openNotifications?: () => void;
|
|
126
|
+
openHelp?: () => void;
|
|
127
|
+
};
|
|
128
|
+
export declare const usePyrionNavigation: () => PyrionNavigationControls;
|
|
129
|
+
declare const PyrionNavigationDrawer: <TAppMetadata = unknown, NotificationMetadata = unknown>({ children, helpSection, state, links: navlinks, onLinkClick, onNavigate, onLogoutClick, actions, activeActionId, onActionClick, tabsProps, currentSystemId, onSessionClick, options, onSystemLogoClick }: PyrionNavigationDrawerProps<TAppMetadata, NotificationMetadata>) => import("react/jsx-runtime").JSX.Element;
|
|
51
130
|
export default PyrionNavigationDrawer;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { TabSwitchElement } from '../TabSwitch/TabSwitch';
|
|
3
|
+
import { TicketCardHandlerProps } from '../TicketCard/TicketCard';
|
|
4
|
+
export interface PyrionNavigationDrawerMobileAppSwitcherProps {
|
|
5
|
+
tabs: TabSwitchElement[];
|
|
6
|
+
content: React.ReactNode | (() => React.ReactNode);
|
|
7
|
+
controls?: React.RefObject<TicketCardHandlerProps | null>;
|
|
8
|
+
}
|
|
9
|
+
declare const PyrionNavigationDrawerMobileAppSwitcher: ({ tabs, content, controls }: PyrionNavigationDrawerMobileAppSwitcherProps) => import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
export default PyrionNavigationDrawerMobileAppSwitcher;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { TSystem } from './PyrionNavigationDrawer';
|
|
2
|
+
declare const SystemLogo: import('react').MemoExoticComponent<({ enabled_systems, onClick, currentSystemId }: {
|
|
3
|
+
enabled_systems?: TSystem[];
|
|
4
|
+
onClick?: () => void;
|
|
5
|
+
currentSystemId?: string;
|
|
6
|
+
}) => import("react/jsx-runtime").JSX.Element>;
|
|
7
|
+
export default SystemLogo;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { NotificationCardProps } from '../NotificationCard/NotificationCard';
|
|
2
|
+
interface PyrionNotificationsDrawerProps<NotificationMetadata> {
|
|
3
|
+
onCloseClick?: VoidFunction;
|
|
4
|
+
onMarkAllAsRead?: () => void;
|
|
5
|
+
notifications?: NotificationCardProps<NotificationMetadata>[];
|
|
6
|
+
}
|
|
7
|
+
declare const PyrionNotificationsList: <NotificationMetadata = unknown>({ onCloseClick, onMarkAllAsRead, notifications }: PyrionNotificationsDrawerProps<NotificationMetadata>) => import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export default PyrionNotificationsList;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { PyrionNavigationDrawerOptions, PyrionNavigationDrawerProps } from './PyrionNavigationDrawer';
|
|
3
|
+
export type SidebarContentHandle = {
|
|
4
|
+
setActiveSection: (section: 'notifications' | 'help') => void;
|
|
5
|
+
};
|
|
6
|
+
declare const SidebarContent: import('react').ForwardRefExoticComponent<{
|
|
7
|
+
closeSidebar: () => void;
|
|
8
|
+
options?: PyrionNavigationDrawerOptions<any>;
|
|
9
|
+
state: PyrionNavigationDrawerProps<any, any>["state"];
|
|
10
|
+
helpSection?: ReactNode | (() => ReactNode);
|
|
11
|
+
initialSection?: "notifications" | "help";
|
|
12
|
+
} & import('react').RefAttributes<SidebarContentHandle>>;
|
|
13
|
+
export default SidebarContent;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { AllOptionAccessor } from '../Shared/types';
|
|
2
|
+
import { AuthSession } from './PyrionNavigationDrawer';
|
|
3
|
+
export interface SystemSessionsProps<TSystemMetadata> {
|
|
4
|
+
sessions?: AuthSession<TSystemMetadata>[];
|
|
5
|
+
onSessionClick?: (session: AuthSession<TSystemMetadata>) => void;
|
|
6
|
+
secondarySlot?: React.ReactNode | string | ((session: AuthSession<TSystemMetadata>) => React.ReactNode | string | null) | null;
|
|
7
|
+
subImageUrlAccessor?: subImageUrlAccessor<TSystemMetadata>;
|
|
8
|
+
currentSystemId: string;
|
|
9
|
+
}
|
|
10
|
+
export type subImageUrlAccessor<TSystemMetadata> = AllOptionAccessor<TSystemMetadata, string>;
|
|
11
|
+
declare const SystemSessions: <TSystemMetadata = unknown>(props: SystemSessionsProps<TSystemMetadata>) => import("react/jsx-runtime").JSX.Element | null;
|
|
12
|
+
export default SystemSessions;
|
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
import { IconComponent } from '../../Icons';
|
|
2
1
|
import { default as React } from 'react';
|
|
3
2
|
type IndicatorType = 'icon' | 'shadow';
|
|
4
3
|
type IndicatorProps = {
|
|
5
4
|
show?: boolean;
|
|
6
|
-
icon?: IconComponent;
|
|
7
5
|
className?: string;
|
|
8
6
|
type?: IndicatorType;
|
|
7
|
+
behavior?: 'scroll-on-click' | 'scroll-on-hover' | 'none';
|
|
9
8
|
};
|
|
10
9
|
interface IndicatorsProps {
|
|
11
10
|
top?: IndicatorProps;
|
|
@@ -14,12 +13,19 @@ interface IndicatorsProps {
|
|
|
14
13
|
right?: IndicatorProps;
|
|
15
14
|
}
|
|
16
15
|
type scrollableAxis = "x" | "y" | "both";
|
|
17
|
-
|
|
16
|
+
type ScrollbarProps = {
|
|
17
|
+
hide?: boolean;
|
|
18
|
+
size?: "small" | 'medium';
|
|
19
|
+
};
|
|
20
|
+
export interface ScrollableProps {
|
|
18
21
|
debugMode?: boolean;
|
|
19
22
|
className?: string;
|
|
20
23
|
indicators?: IndicatorsProps;
|
|
21
24
|
axis?: scrollableAxis;
|
|
22
25
|
children?: React.ReactNode;
|
|
26
|
+
scrollbarProps?: ScrollbarProps;
|
|
27
|
+
disableMouseScroll?: boolean;
|
|
28
|
+
defaultBehavior?: 'scroll-on-click' | 'scroll-on-hover' | 'none';
|
|
23
29
|
}
|
|
24
30
|
declare const Scrollable: (props: ScrollableProps) => import("react/jsx-runtime").JSX.Element;
|
|
25
31
|
export default Scrollable;
|
|
@@ -5,5 +5,6 @@ export type BadgeProps = {
|
|
|
5
5
|
size?: 'small' | 'medium' | 'large';
|
|
6
6
|
variant?: 'primary' | 'secondary' | 'success' | 'warning' | 'danger';
|
|
7
7
|
showZero?: boolean;
|
|
8
|
+
disabled?: boolean;
|
|
8
9
|
};
|
|
9
|
-
export declare const Badge: ({ count, maxCount, className, size, variant, showZero }: BadgeProps) => import("react/jsx-runtime").JSX.Element | null;
|
|
10
|
+
export declare const Badge: ({ count, maxCount, className, size, variant, showZero, disabled }: BadgeProps) => import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { ReactNode, RefObject } from 'react';
|
|
2
|
+
type TicketCardSlotChildren = ReactNode | ((context: TicketCardRenderContext) => ReactNode);
|
|
3
|
+
type SlotBaseProps = {
|
|
4
|
+
children?: TicketCardSlotChildren;
|
|
5
|
+
className?: string;
|
|
6
|
+
context?: TicketCardRenderContext;
|
|
7
|
+
};
|
|
8
|
+
export type TicketCardHandlerProps = {
|
|
9
|
+
open: () => void;
|
|
10
|
+
close: () => void;
|
|
11
|
+
toggle: () => void;
|
|
12
|
+
};
|
|
13
|
+
type TicketCardRenderContext = {
|
|
14
|
+
isCollapsed: boolean;
|
|
15
|
+
toggle: () => void;
|
|
16
|
+
};
|
|
17
|
+
export interface TicketCardProps {
|
|
18
|
+
children?: TicketCardSlotChildren;
|
|
19
|
+
className?: string;
|
|
20
|
+
controls?: RefObject<TicketCardHandlerProps | null>;
|
|
21
|
+
}
|
|
22
|
+
type ContentSlotProps = SlotBaseProps & {
|
|
23
|
+
onClick?: () => void;
|
|
24
|
+
};
|
|
25
|
+
declare const TicketCard: import('react').NamedExoticComponent<TicketCardProps> & {
|
|
26
|
+
readonly type: (props: TicketCardProps) => import("react/jsx-runtime").JSX.Element;
|
|
27
|
+
} & {
|
|
28
|
+
Root: import('react').MemoExoticComponent<(props: TicketCardProps) => import("react/jsx-runtime").JSX.Element>;
|
|
29
|
+
Content: (props: ContentSlotProps) => import("react/jsx-runtime").JSX.Element;
|
|
30
|
+
Options: (props: SlotBaseProps) => import("react/jsx-runtime").JSX.Element;
|
|
31
|
+
};
|
|
32
|
+
export default TicketCard;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { SizeVariant } from '../Avatar/Avatar';
|
|
2
|
+
export interface UserCardProps {
|
|
3
|
+
name: string;
|
|
4
|
+
mainSlot?: string | React.ReactNode | (() => React.ReactNode);
|
|
5
|
+
secondarySlot?: string | React.ReactNode | (() => React.ReactNode) | null;
|
|
6
|
+
imageUrl?: string;
|
|
7
|
+
subImageUrl?: string;
|
|
8
|
+
avatarSize?: SizeVariant;
|
|
9
|
+
className?: string;
|
|
10
|
+
}
|
|
11
|
+
declare const UserCard: import('react').MemoExoticComponent<({ name, imageUrl, avatarSize, subImageUrl, className, mainSlot, secondarySlot }: UserCardProps) => import("react/jsx-runtime").JSX.Element>;
|
|
12
|
+
export default UserCard;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
interface UseLabelBackgroundResult<T extends HTMLElement> {
|
|
2
2
|
ref: React.RefObject<T | null>;
|
|
3
3
|
}
|
|
4
|
+
export declare const getActualBackgroundColor: (element: HTMLElement) => string;
|
|
4
5
|
export declare function useLabelBackground<T extends HTMLElement = HTMLElement>(): UseLabelBackgroundResult<T>;
|
|
5
6
|
export {};
|
|
@@ -1,19 +1,10 @@
|
|
|
1
1
|
import K from "react";
|
|
2
2
|
var v = { exports: {} }, m = {};
|
|
3
|
-
/**
|
|
4
|
-
* @license React
|
|
5
|
-
* react-jsx-runtime.production.js
|
|
6
|
-
*
|
|
7
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
8
|
-
*
|
|
9
|
-
* This source code is licensed under the MIT license found in the
|
|
10
|
-
* LICENSE file in the root directory of this source tree.
|
|
11
|
-
*/
|
|
12
3
|
var I;
|
|
13
4
|
function ee() {
|
|
14
5
|
if (I) return m;
|
|
15
6
|
I = 1;
|
|
16
|
-
var l = Symbol.for("react.transitional.element"), b = Symbol.for("react.fragment");
|
|
7
|
+
var l = /* @__PURE__ */ Symbol.for("react.transitional.element"), b = /* @__PURE__ */ Symbol.for("react.fragment");
|
|
17
8
|
function c(i, o, s) {
|
|
18
9
|
var f = null;
|
|
19
10
|
if (s !== void 0 && (f = "" + s), o.key !== void 0 && (f = "" + o.key), "key" in o) {
|
|
@@ -32,15 +23,6 @@ function ee() {
|
|
|
32
23
|
return m.Fragment = b, m.jsx = c, m.jsxs = c, m;
|
|
33
24
|
}
|
|
34
25
|
var _ = {};
|
|
35
|
-
/**
|
|
36
|
-
* @license React
|
|
37
|
-
* react-jsx-runtime.development.js
|
|
38
|
-
*
|
|
39
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
40
|
-
*
|
|
41
|
-
* This source code is licensed under the MIT license found in the
|
|
42
|
-
* LICENSE file in the root directory of this source tree.
|
|
43
|
-
*/
|
|
44
26
|
var $;
|
|
45
27
|
function re() {
|
|
46
28
|
return $ || ($ = 1, process.env.NODE_ENV !== "production" && (function() {
|
|
@@ -236,7 +218,7 @@ React keys must be passed directly to JSX without using spread:
|
|
|
236
218
|
function y(e) {
|
|
237
219
|
return typeof e == "object" && e !== null && e.$$typeof === j;
|
|
238
220
|
}
|
|
239
|
-
var E = K, j = Symbol.for("react.transitional.element"), M = Symbol.for("react.portal"), p = Symbol.for("react.fragment"), W = Symbol.for("react.strict_mode"), U = Symbol.for("react.profiler"), J = Symbol.for("react.consumer"), V = Symbol.for("react.context"), q = Symbol.for("react.forward_ref"), z = Symbol.for("react.suspense"), G = Symbol.for("react.suspense_list"), X = Symbol.for("react.memo"), T = Symbol.for("react.lazy"), B = Symbol.for("react.activity"), H = Symbol.for("react.client.reference"), k = E.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, x = Object.prototype.hasOwnProperty, Z = Array.isArray, O = console.createTask ? console.createTask : function() {
|
|
221
|
+
var E = K, j = /* @__PURE__ */ Symbol.for("react.transitional.element"), M = /* @__PURE__ */ Symbol.for("react.portal"), p = /* @__PURE__ */ Symbol.for("react.fragment"), W = /* @__PURE__ */ Symbol.for("react.strict_mode"), U = /* @__PURE__ */ Symbol.for("react.profiler"), J = /* @__PURE__ */ Symbol.for("react.consumer"), V = /* @__PURE__ */ Symbol.for("react.context"), q = /* @__PURE__ */ Symbol.for("react.forward_ref"), z = /* @__PURE__ */ Symbol.for("react.suspense"), G = /* @__PURE__ */ Symbol.for("react.suspense_list"), X = /* @__PURE__ */ Symbol.for("react.memo"), T = /* @__PURE__ */ Symbol.for("react.lazy"), B = /* @__PURE__ */ Symbol.for("react.activity"), H = /* @__PURE__ */ Symbol.for("react.client.reference"), k = E.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, x = Object.prototype.hasOwnProperty, Z = Array.isArray, O = console.createTask ? console.createTask : function() {
|
|
240
222
|
return null;
|
|
241
223
|
};
|
|
242
224
|
E = {
|
package/dist/lib/utils.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { OptionAccessor } from '../components/Shared/types';
|
|
2
|
-
export declare function getAccessorValue<T, R>(option: T, accessor: OptionAccessor<T, R>): R;
|
|
1
|
+
import { AllOptionAccessor, OptionAccessor } from '../components/Shared/types';
|
|
2
|
+
export declare function getAccessorValue<T, R>(option: T, accessor: (AllOptionAccessor<T, R> | OptionAccessor<T, R>)): R;
|
|
3
3
|
export declare const hasCoincidences: (option: string, inputValue: string) => boolean;
|