@js-empire/emperor-ui 1.2.5 → 1.2.7
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/package.json +5 -2
- package/src/components/atoms/color-picker/color-picker.tsx +0 -1
- package/src/components/atoms/color-picker/free-color-picker.tsx +8 -10
- package/src/components/atoms/color-picker/preset-color-picker.tsx +5 -3
- package/src/components/atoms/color-picker/stories/color-picker.stories.tsx +25 -11
- package/src/components/atoms/field/field.tsx +75 -5
- package/src/components/atoms/field/index.ts +2 -0
- package/src/components/atoms/field/units/autocomplete-field.tsx +49 -0
- package/src/components/atoms/field/units/checkbox-field.tsx +35 -0
- package/src/components/atoms/field/units/index.ts +7 -0
- package/src/components/atoms/field/units/input-field.tsx +35 -0
- package/src/components/atoms/field/units/radio-field.tsx +43 -0
- package/src/components/atoms/field/units/select-field.tsx +50 -0
- package/src/components/atoms/field/units/switch-field.tsx +35 -0
- package/src/components/atoms/field/units/textarea-field.tsx +37 -0
- package/src/components/atoms/filter/filter.tsx +2 -1
- package/src/components/atoms/filter/stories/filter.stories.tsx +148 -7
- package/src/components/atoms/filter/units/autocomplete-filter.tsx +38 -11
- package/src/components/atoms/filter/units/checkbox-filter.tsx +16 -6
- package/src/components/atoms/filter/units/checkbox-group-filter.tsx +40 -9
- package/src/components/atoms/filter/units/date-filter.tsx +18 -22
- package/src/components/atoms/filter/units/numeric-filter.tsx +12 -7
- package/src/components/atoms/filter/units/range-filter.tsx +42 -13
- package/src/components/atoms/filter/units/search-filter.tsx +8 -7
- package/src/components/atoms/filter/units/select-filter.tsx +17 -9
- package/src/components/atoms/filter/units/switch-filter.tsx +6 -4
- package/src/components/atoms/uploader/{avatar-label.tsx → components/avatar-label.tsx} +17 -5
- package/src/components/atoms/uploader/components/index.ts +8 -0
- package/src/components/atoms/uploader/components/upload-file-error-box.tsx +40 -0
- package/src/components/atoms/uploader/{upload-file-label.tsx → components/upload-file-label.tsx} +18 -11
- package/src/components/atoms/uploader/index.ts +1 -8
- package/src/components/atoms/uploader/stories/uploader.stories.tsx +17 -10
- package/src/components/molecules/item-card/index.ts +2 -0
- package/src/components/molecules/item-card/item-actions-buttons.tsx +43 -0
- package/src/components/molecules/item-card/item-actions-overlay.tsx +41 -0
- package/src/components/molecules/item-card/item-card-body.tsx +8 -2
- package/src/components/molecules/item-card/item-card-footer.tsx +22 -1
- package/src/components/molecules/item-card/item-card-header.tsx +8 -2
- package/src/components/molecules/item-card/item-card.tsx +39 -1
- package/src/components/molecules/item-card/stories/item-card.stories.tsx +36 -0
- package/src/components/organisms/deletion-confirmor/deletion-confirmor.tsx +114 -0
- package/src/components/organisms/deletion-confirmor/index.ts +3 -0
- package/src/components/organisms/deletion-confirmor/stories/components.tsx +22 -0
- package/src/components/organisms/deletion-confirmor/stories/deletion-confirmor.stories.tsx +78 -0
- package/src/components/organisms/deletion-confirmor/styles/classes.ts +28 -0
- package/src/components/organisms/{filters → deletion-confirmor}/styles/index.ts +1 -0
- package/src/components/organisms/deletion-confirmor/styles/styles.ts +4 -0
- package/src/components/organisms/form-builder/form-builder.stories.tsx +144 -0
- package/src/components/organisms/form-builder/form-builder.tsx +75 -0
- package/src/components/organisms/form-builder/index.ts +1 -0
- package/src/components/organisms/index.ts +2 -1
- package/src/constants/card.tsx +5 -2
- package/src/constants/defaults.ts +40 -0
- package/src/context/form-builder-context.tsx +8 -0
- package/src/context/index.ts +1 -0
- package/src/hooks/index.ts +1 -0
- package/src/hooks/use-filters.ts +2 -2
- package/src/hooks/use-form-builder-context.ts +16 -0
- package/src/hooks/use-uploader.tsx +21 -9
- package/src/i18n/locales/atoms/ar.ts +1 -1
- package/src/i18n/locales/atoms/en.ts +1 -1
- package/src/i18n/locales/organisms/ar.ts +4 -0
- package/src/i18n/locales/organisms/en.ts +4 -0
- package/src/mocks/deletion-confirmor.ts +16 -0
- package/src/mocks/index.ts +2 -0
- package/src/mocks/locales/index.ts +1 -0
- package/src/mocks/locales/uploader.ts +33 -0
- package/src/providers/config-provider.tsx +8 -0
- package/src/providers/form-builder-provider-context.tsx +18 -0
- package/src/providers/index.ts +1 -0
- package/src/styles/globals.css +26 -1
- package/src/styles/hero.ts +1 -0
- package/src/styles/index.css +0 -5
- package/src/types/components/atoms/color-picker/color-picker.ts +10 -1
- package/src/types/components/atoms/field/field.ts +53 -1
- package/src/types/components/atoms/filter/filter.ts +26 -17
- package/src/types/components/atoms/uploader.ts +4 -0
- package/src/types/components/molecules/item-card/item-card.ts +14 -4
- package/src/types/components/organisms/deletion-confirmor/deletion-confirmor.ts +22 -0
- package/src/types/components/organisms/deletion-confirmor/index.ts +1 -0
- package/src/types/components/organisms/form-builder/context.ts +6 -0
- package/src/types/components/organisms/form-builder/form-builder.ts +39 -0
- package/src/types/components/organisms/form-builder/index.ts +2 -0
- package/src/types/components/organisms/index.ts +2 -0
- package/src/types/context/config.ts +2 -0
- package/src/types/context/index.ts +1 -0
- package/src/types/context/theme.ts +33 -0
- package/src/utils/uploader.ts +25 -7
- package/dist/emperor-ui.js +0 -123
- package/dist/emperor-ui.umd.cjs +0 -63
- package/dist/globals.css +0 -1
- package/dist/icons/emperor-ui-logo.ico +0 -0
- package/dist/images/avatar-female.jpg +0 -0
- package/dist/images/avatar-male.jpg +0 -0
- package/dist/images/emperor-ui-logo.png +0 -0
- package/dist/index-BXtdEByK.js +0 -5
- package/dist/index-CDB93OLO.js +0 -55965
- package/dist/index-CYORMghp.js +0 -290
- package/dist/index.d.ts +0 -1090
- package/dist/src-UW24ZMRV-C1Pn8-w8.js +0 -5
- package/src/components/atoms/color-picker/styles/color-picker.css +0 -23
- package/src/components/atoms/field/field.stories.tsx +0 -27
- package/src/components/atoms/uploader/upload-file-error-box.tsx +0 -29
- package/src/components/organisms/filters/filters.stories.tsx +0 -32
- package/src/components/organisms/filters/filters.tsx +0 -36
- package/src/components/organisms/filters/index.ts +0 -1
- package/src/components/organisms/filters/styles/classes.ts +0 -9
- /package/src/components/atoms/uploader/{upload-file-input.tsx → components/upload-file-input.tsx} +0 -0
- /package/src/components/atoms/uploader/{upload-file-listing.tsx → components/upload-file-listing.tsx} +0 -0
- /package/src/components/atoms/uploader/{uploader-title.tsx → components/uploader-title.tsx} +0 -0
- /package/src/components/atoms/uploader/{uploader.tsx → components/uploader.tsx} +0 -0
- /package/src/components/atoms/uploader/{view-image-modal.tsx → components/view-image-modal.tsx} +0 -0
package/dist/index.d.ts
DELETED
|
@@ -1,1090 +0,0 @@
|
|
|
1
|
-
import { AutocompleteProps } from '@heroui/autocomplete';
|
|
2
|
-
import { ButtonProps } from '@heroui/button';
|
|
3
|
-
import { CheckboxGroupProps } from '@heroui/checkbox';
|
|
4
|
-
import { CheckboxProps } from '@heroui/checkbox';
|
|
5
|
-
import { ChipProps } from '@heroui/chip';
|
|
6
|
-
import { ClassAttributes } from 'react';
|
|
7
|
-
import { ClassProp } from 'class-variance-authority/types';
|
|
8
|
-
import { ClassValue } from 'clsx';
|
|
9
|
-
import { ComponentProps } from 'react';
|
|
10
|
-
import { Context } from 'react';
|
|
11
|
-
import { CSSProperties } from 'react';
|
|
12
|
-
import { DatePickerProps } from '@heroui/date-picker';
|
|
13
|
-
import { Dispatch } from 'react';
|
|
14
|
-
import { DropdownItemProps } from '@heroui/dropdown';
|
|
15
|
-
import { ElementType } from 'react';
|
|
16
|
-
import { ForwardRefExoticComponent } from 'react';
|
|
17
|
-
import { HTMLAttributes } from 'react';
|
|
18
|
-
import { InputProps } from '@heroui/input';
|
|
19
|
-
import { JSX } from 'react/jsx-runtime';
|
|
20
|
-
import { LiHTMLAttributes } from 'react';
|
|
21
|
-
import { ModalProps } from '@heroui/modal';
|
|
22
|
-
import { MotionProps } from 'framer-motion';
|
|
23
|
-
import { RadioProps } from '@heroui/radio';
|
|
24
|
-
import { ReactNode } from 'react';
|
|
25
|
-
import { ReactPortal } from 'react';
|
|
26
|
-
import { RefAttributes } from 'react';
|
|
27
|
-
import { SelectProps } from '@heroui/select';
|
|
28
|
-
import { SetStateAction } from 'react';
|
|
29
|
-
import { SliderProps } from '@heroui/slider';
|
|
30
|
-
import { SwitchProps } from '@heroui/switch';
|
|
31
|
-
import { ToastProps } from '@heroui/toast';
|
|
32
|
-
import { VariantProps } from 'class-variance-authority';
|
|
33
|
-
import { Variants } from 'framer-motion';
|
|
34
|
-
|
|
35
|
-
export declare type Address = {
|
|
36
|
-
country?: string;
|
|
37
|
-
street?: string;
|
|
38
|
-
city?: string;
|
|
39
|
-
state?: string;
|
|
40
|
-
zip?: string;
|
|
41
|
-
};
|
|
42
|
-
|
|
43
|
-
export declare const ALLOWED_DOC_TYPES: string[];
|
|
44
|
-
|
|
45
|
-
export declare const ALLOWED_IMAGES_TYPES: string[];
|
|
46
|
-
|
|
47
|
-
export declare const ALLOWED_PDF_TYPES: string[];
|
|
48
|
-
|
|
49
|
-
export declare type AppDirection = "ltr" | "rtl";
|
|
50
|
-
|
|
51
|
-
declare const ar: {
|
|
52
|
-
common: {};
|
|
53
|
-
toasts: {};
|
|
54
|
-
atoms: {
|
|
55
|
-
colorPicker: {
|
|
56
|
-
invalidColorFormat: string;
|
|
57
|
-
};
|
|
58
|
-
uploader: {
|
|
59
|
-
dropHere: string;
|
|
60
|
-
selectFile: string;
|
|
61
|
-
selectionTypes: string;
|
|
62
|
-
selectBtn: string;
|
|
63
|
-
errorUploadingFile: string;
|
|
64
|
-
maxNumImages: string;
|
|
65
|
-
errorUploadedTypes: string;
|
|
66
|
-
maxSizeExceededError: string;
|
|
67
|
-
duplicatesDenied: string;
|
|
68
|
-
};
|
|
69
|
-
};
|
|
70
|
-
molecules: {};
|
|
71
|
-
organisms: {
|
|
72
|
-
listings: {
|
|
73
|
-
emptyTitle: string;
|
|
74
|
-
emptyDescription: string;
|
|
75
|
-
};
|
|
76
|
-
};
|
|
77
|
-
templates: {};
|
|
78
|
-
};
|
|
79
|
-
|
|
80
|
-
export declare function AutocompleteFilter({ classNames, autocompleteProps, paramKey, ...props }: Pick<FilterProps, "classNames" | "autocompleteProps" | "paramKey">): JSX.Element;
|
|
81
|
-
|
|
82
|
-
export declare function AvatarLabel(): JSX.Element | null;
|
|
83
|
-
|
|
84
|
-
export declare const Brand: ForwardRefExoticComponent<Omit<ClassAttributes<HTMLDivElement> & HTMLAttributes<HTMLDivElement> & VariantProps<(props?: ({
|
|
85
|
-
variant?: null | undefined;
|
|
86
|
-
} & ClassProp) | undefined) => string> & SharedComponentProps & {
|
|
87
|
-
src?: string;
|
|
88
|
-
alt?: string;
|
|
89
|
-
name?: string;
|
|
90
|
-
isIconOnly?: boolean;
|
|
91
|
-
classNames?: {
|
|
92
|
-
base?: string;
|
|
93
|
-
logo?: string;
|
|
94
|
-
name?: string;
|
|
95
|
-
};
|
|
96
|
-
}, "ref"> & RefAttributes<HTMLElement>>;
|
|
97
|
-
|
|
98
|
-
export declare type BrandProps = SharedComponentProps & {
|
|
99
|
-
src?: string;
|
|
100
|
-
alt?: string;
|
|
101
|
-
name?: string;
|
|
102
|
-
isIconOnly?: boolean;
|
|
103
|
-
classNames?: {
|
|
104
|
-
base?: string;
|
|
105
|
-
logo?: string;
|
|
106
|
-
name?: string;
|
|
107
|
-
};
|
|
108
|
-
};
|
|
109
|
-
|
|
110
|
-
export declare function CheckboxFilter({ classNames, checkboxProps, paramKey, ...props }: Pick<FilterProps, "classNames" | "checkboxProps" | "paramKey">): JSX.Element;
|
|
111
|
-
|
|
112
|
-
export declare function CheckboxGroupFilter({ classNames, checkboxGroupProps, paramKey, ...props }: Pick<FilterProps, "classNames" | "checkboxGroupProps" | "paramKey">): JSX.Element;
|
|
113
|
-
|
|
114
|
-
export declare function cn(...classes: ClassValue[]): string;
|
|
115
|
-
|
|
116
|
-
export declare function ColorPicker({ ...props }: ColorPickerProps): JSX.Element;
|
|
117
|
-
|
|
118
|
-
export declare type ColorPickerInputType = "free" | "preset";
|
|
119
|
-
|
|
120
|
-
export declare type ColorPickerProps = Omit<InputProps & SelectProps, "onChange" | "children"> & {
|
|
121
|
-
inputType: ColorPickerInputType;
|
|
122
|
-
presets?: string[];
|
|
123
|
-
};
|
|
124
|
-
|
|
125
|
-
export declare const Column: ForwardRefExoticComponent<Omit<ClassAttributes<HTMLElement> & HTMLAttributes<HTMLElement> & VariantProps<(props?: ({} & ClassProp) | undefined) => string> & SharedComponentProps, "ref"> & RefAttributes<HTMLElement>>;
|
|
126
|
-
|
|
127
|
-
export declare type ColumnProps = SharedComponentProps & {};
|
|
128
|
-
|
|
129
|
-
export declare type CompactSideBarProps = SideBarProps & {};
|
|
130
|
-
|
|
131
|
-
export declare type ComponentRadius = "none" | "sm" | "md" | "lg" | "full";
|
|
132
|
-
|
|
133
|
-
export declare type ComponentSize = "xs" | "sm" | "base" | "md" | "lg" | "xl";
|
|
134
|
-
|
|
135
|
-
export declare function compressImage(fileObject: FileObject, maxSizeMB?: number): Promise<FileObject | null>;
|
|
136
|
-
|
|
137
|
-
export declare type ConfigContextState = {
|
|
138
|
-
config: EmperorUIConfig;
|
|
139
|
-
};
|
|
140
|
-
|
|
141
|
-
export declare function ConfigProvider({ children, config, }: ConfigProviderProps): JSX.Element;
|
|
142
|
-
|
|
143
|
-
export declare type ConfigProviderProps = {
|
|
144
|
-
children: ReactNode;
|
|
145
|
-
config?: EmperorUIConfig;
|
|
146
|
-
};
|
|
147
|
-
|
|
148
|
-
export declare type Contacts = {
|
|
149
|
-
mobile?: string;
|
|
150
|
-
email?: string;
|
|
151
|
-
addresses?: Address[];
|
|
152
|
-
website?: string;
|
|
153
|
-
workingHours?: string;
|
|
154
|
-
};
|
|
155
|
-
|
|
156
|
-
export declare const contacts: Contacts;
|
|
157
|
-
|
|
158
|
-
export declare const Container: ForwardRefExoticComponent<Omit<ClassAttributes<HTMLElement> & HTMLAttributes<HTMLElement> & VariantProps<(props?: ({} & ClassProp) | undefined) => string> & SharedComponentProps, "ref"> & RefAttributes<HTMLElement>>;
|
|
159
|
-
|
|
160
|
-
export declare type ContainerProps = SharedComponentProps & {};
|
|
161
|
-
|
|
162
|
-
export declare function CopyButton({ value }: {
|
|
163
|
-
value: string;
|
|
164
|
-
}): JSX.Element;
|
|
165
|
-
|
|
166
|
-
export declare type CopyRights = {
|
|
167
|
-
year: number;
|
|
168
|
-
text: string;
|
|
169
|
-
};
|
|
170
|
-
|
|
171
|
-
export declare const copyRights: CopyRights;
|
|
172
|
-
|
|
173
|
-
export declare function CopyRightsBox({ copyRights, classNames }: FooterProps): JSX.Element;
|
|
174
|
-
|
|
175
|
-
export declare function DateFilter({ classNames, dateProps, paramKey, ...props }: Pick<FilterProps, "classNames" | "dateProps" | "paramKey">): JSX.Element;
|
|
176
|
-
|
|
177
|
-
export declare const defaultEmperorUIConfig: EmperorUIConfig;
|
|
178
|
-
|
|
179
|
-
export declare type EmperorUIConfig = {
|
|
180
|
-
layout?: Partial<EmperorUILayout>;
|
|
181
|
-
interLocalization?: Partial<EmperorUIInterLocalization>;
|
|
182
|
-
toast?: ToastProps;
|
|
183
|
-
};
|
|
184
|
-
|
|
185
|
-
export declare const EmperorUIContext: Context<ConfigContextState | undefined>;
|
|
186
|
-
|
|
187
|
-
export declare type EmperorUIInterLocalization = {
|
|
188
|
-
lang?: EmperorUILang;
|
|
189
|
-
languages?: EmperorUILang[];
|
|
190
|
-
defaultLanguage?: EmperorUILang;
|
|
191
|
-
isMultiLingual?: boolean;
|
|
192
|
-
dir?: AppDirection;
|
|
193
|
-
locales?: EmperorUILocales;
|
|
194
|
-
};
|
|
195
|
-
|
|
196
|
-
export declare type EmperorUILang = "en" | "ar";
|
|
197
|
-
|
|
198
|
-
export declare type EmperorUILayout = {
|
|
199
|
-
withScaffold: boolean;
|
|
200
|
-
};
|
|
201
|
-
|
|
202
|
-
export declare type EmperorUILocales = Record<EmperorUILang, Partial<{
|
|
203
|
-
atoms?: {
|
|
204
|
-
uploader?: Partial<Locale["atoms"]["uploader"]>;
|
|
205
|
-
colorPicker?: Partial<Locale["atoms"]["colorPicker"]>;
|
|
206
|
-
};
|
|
207
|
-
}>>;
|
|
208
|
-
|
|
209
|
-
export declare function EmperorUIProvider({ children, ...props }: EmperorUIProviderProps): JSX.Element;
|
|
210
|
-
|
|
211
|
-
declare type EmperorUIProviderProps = ConfigProviderProps & {};
|
|
212
|
-
|
|
213
|
-
export declare function EmptyListings({ className, classNames, }: {
|
|
214
|
-
className?: string;
|
|
215
|
-
classNames?: {
|
|
216
|
-
wrapper?: string;
|
|
217
|
-
iconWrapper?: string;
|
|
218
|
-
title?: string;
|
|
219
|
-
description?: string;
|
|
220
|
-
};
|
|
221
|
-
}): JSX.Element;
|
|
222
|
-
|
|
223
|
-
export declare const emptyListingsClasses: (props?: ({} & ClassProp) | undefined) => string;
|
|
224
|
-
|
|
225
|
-
declare const en: {
|
|
226
|
-
common: {};
|
|
227
|
-
toasts: {};
|
|
228
|
-
atoms: {
|
|
229
|
-
colorPicker: {
|
|
230
|
-
invalidColorFormat: string;
|
|
231
|
-
};
|
|
232
|
-
uploader: {
|
|
233
|
-
dropHere: string;
|
|
234
|
-
selectFile: string;
|
|
235
|
-
selectionTypes: string;
|
|
236
|
-
selectBtn: string;
|
|
237
|
-
errorUploadingFile: string;
|
|
238
|
-
maxNumImages: string;
|
|
239
|
-
errorUploadedTypes: string;
|
|
240
|
-
maxSizeExceededError: string;
|
|
241
|
-
duplicatesDenied: string;
|
|
242
|
-
};
|
|
243
|
-
};
|
|
244
|
-
molecules: {};
|
|
245
|
-
organisms: {
|
|
246
|
-
listings: {
|
|
247
|
-
emptyTitle: string;
|
|
248
|
-
emptyDescription: string;
|
|
249
|
-
};
|
|
250
|
-
};
|
|
251
|
-
templates: {};
|
|
252
|
-
};
|
|
253
|
-
|
|
254
|
-
export declare const FAKE_PARAGRAPH = "Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor. Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem. Nulla consequat massa quis enim. Donec pede justo, fringilla vel, aliquet nec, vulputate eget, arcu. In enim justo, rhoncus ut, imperdiet a, venenatis vitae, justo. Nullam dictum felis eu pede mollis pretium. Integer tincidunt. Cras dapibus. Vivamus elementum semper nisi. Aenean vulputate eleifend tellus. Aenean leo ligula, porttitor eu, consequat vitae, eleifend ac, enim. Aliquam lorem ante, dapibus in, viverra quis, feugiat a, tellus. Phasellus viverra nulla ut metus varius laoreet. Quisque rutrum. Aenean imperdiet. Etiam ultricies nisi vel augue. Curabitur ullamcorper ultricies nisi. Nam eget dui. Etiam rhoncus. Maecenas tempus, tellus eget condimentum rhoncus, sem quam semper libero, sit amet adipiscing sem neque sed ipsum. Nam quam nunc, blandit vel, luctus pulvinar, hendrerit id, lorem. Maecenas nec odio et ante tincidunt tempus. Donec vitae sapien ut libero venenatis faucibus. Nullam quis ante. Etiam sit amet orci eget eros faucibus tincidunt. Duis leo. Sed fringilla mauris sit amet nibh. Donec sodales sagittis magna. Sed consequat, leo eget bibendum sodales, augue velit cursus nunc,";
|
|
255
|
-
|
|
256
|
-
export declare const FAKE_SENTENCE = "Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor.";
|
|
257
|
-
|
|
258
|
-
export declare function Field({ className, classNames, ...props }: FieldProps): JSX.Element;
|
|
259
|
-
|
|
260
|
-
export declare type FieldClassnames = {
|
|
261
|
-
base?: string;
|
|
262
|
-
};
|
|
263
|
-
|
|
264
|
-
export declare type FieldProps = SharedComponentProps & {
|
|
265
|
-
classNames?: FieldClassnames;
|
|
266
|
-
};
|
|
267
|
-
|
|
268
|
-
export declare type FileObject = {
|
|
269
|
-
view?: string;
|
|
270
|
-
type?: FileType;
|
|
271
|
-
file?: File;
|
|
272
|
-
url?: string;
|
|
273
|
-
};
|
|
274
|
-
|
|
275
|
-
export declare type FileType = "image" | "doc" | "pdf" | "video" | "sheet";
|
|
276
|
-
|
|
277
|
-
export declare const fileTypesMapping: {
|
|
278
|
-
[key: string]: string[];
|
|
279
|
-
};
|
|
280
|
-
|
|
281
|
-
export declare function Filter({ className, type, searchProps, selectProps, autocompleteProps, dateProps, numericProps, checkboxProps, checkboxGroupProps, radioProps, switchProps, rangeProps, paramKey, options, ...props }: FilterProps): JSX.Element;
|
|
282
|
-
|
|
283
|
-
export declare const filterClasses: (props?: ({
|
|
284
|
-
type?: "search" | "select" | "switch" | "checkbox" | "radio" | "date" | "autocomplete" | "numeric" | "checkboxGroup" | "range" | null | undefined;
|
|
285
|
-
} & ClassProp) | undefined) => string;
|
|
286
|
-
|
|
287
|
-
export declare type FilterClassnames = {
|
|
288
|
-
base?: string;
|
|
289
|
-
field?: string;
|
|
290
|
-
};
|
|
291
|
-
|
|
292
|
-
export declare type FilterProps = SharedComponentProps & SelectFilterProps & {
|
|
293
|
-
classNames?: FilterClassnames;
|
|
294
|
-
type: FilterType;
|
|
295
|
-
paramKey: string;
|
|
296
|
-
searchProps?: InputProps;
|
|
297
|
-
selectProps?: Omit<SelectProps, "children">;
|
|
298
|
-
autocompleteProps?: AutocompleteProps;
|
|
299
|
-
dateProps?: DatePickerProps;
|
|
300
|
-
numericProps?: InputProps;
|
|
301
|
-
checkboxProps?: CheckboxProps;
|
|
302
|
-
checkboxGroupProps?: CheckboxGroupProps;
|
|
303
|
-
radioProps?: RadioProps;
|
|
304
|
-
switchProps?: SwitchProps;
|
|
305
|
-
rangeProps?: SliderProps;
|
|
306
|
-
};
|
|
307
|
-
|
|
308
|
-
export declare function Filters({ className, classNames, children, ...props }: FiltersProps): JSX.Element;
|
|
309
|
-
|
|
310
|
-
export declare type FiltersClassnames = {
|
|
311
|
-
base?: string;
|
|
312
|
-
};
|
|
313
|
-
|
|
314
|
-
export declare type FiltersProps = Omit<SharedComponentProps, "children"> & {
|
|
315
|
-
classNames?: FiltersClassnames;
|
|
316
|
-
children: ReactNode;
|
|
317
|
-
};
|
|
318
|
-
|
|
319
|
-
export declare type FilterType = "search" | "select" | "autocomplete" | "date" | "numeric" | "checkbox" | "checkboxGroup" | "switch" | "range";
|
|
320
|
-
|
|
321
|
-
export declare const Footer: ForwardRefExoticComponent<Omit<ClassAttributes<HTMLElement> & HTMLAttributes<HTMLElement> & VariantProps<(props?: ({
|
|
322
|
-
variant?: "default" | null | undefined;
|
|
323
|
-
} & ClassProp) | undefined) => string> & SharedComponentProps & {
|
|
324
|
-
classNames?: FooterClassnames;
|
|
325
|
-
policies?: QuickLink[];
|
|
326
|
-
quickLinks?: QuickLinkCollection[];
|
|
327
|
-
socialLinks?: SocialLink[];
|
|
328
|
-
copyRights?: CopyRights;
|
|
329
|
-
contacts?: Contacts;
|
|
330
|
-
}, "ref"> & RefAttributes<HTMLElement>>;
|
|
331
|
-
|
|
332
|
-
export declare type FooterClassnames = {
|
|
333
|
-
base?: string;
|
|
334
|
-
content?: string;
|
|
335
|
-
policiesWrapper?: string;
|
|
336
|
-
policy?: string;
|
|
337
|
-
quickLinksWrapper?: string;
|
|
338
|
-
quickLinksTitle?: string;
|
|
339
|
-
quickLinksList?: string;
|
|
340
|
-
quickLinksItem?: string;
|
|
341
|
-
quickLinksLink?: string;
|
|
342
|
-
socialLinksWrapper?: string;
|
|
343
|
-
socialLink?: string;
|
|
344
|
-
copyRightsWrapper?: string;
|
|
345
|
-
copyRightsText?: string;
|
|
346
|
-
contactsWrapper?: string;
|
|
347
|
-
contact?: string;
|
|
348
|
-
};
|
|
349
|
-
|
|
350
|
-
export declare type FooterProps = SharedComponentProps & {
|
|
351
|
-
classNames?: FooterClassnames;
|
|
352
|
-
policies?: QuickLink[];
|
|
353
|
-
quickLinks?: QuickLinkCollection[];
|
|
354
|
-
socialLinks?: SocialLink[];
|
|
355
|
-
copyRights?: CopyRights;
|
|
356
|
-
contacts?: Contacts;
|
|
357
|
-
};
|
|
358
|
-
|
|
359
|
-
export declare function FreeColorPicker({ className, classNames, value, onValueChange, inputType, ...props }: ColorPickerProps): JSX.Element;
|
|
360
|
-
|
|
361
|
-
export declare const getAllowedTypes: (fileTypes: FileType[]) => string[];
|
|
362
|
-
|
|
363
|
-
export declare const getCardMotion: ({}: {
|
|
364
|
-
hoverEffect: ItemCardHoverEffect;
|
|
365
|
-
}) => MotionProps;
|
|
366
|
-
|
|
367
|
-
export declare const getListing: () => Promise<{
|
|
368
|
-
item?: MockItemType | null | undefined;
|
|
369
|
-
}>;
|
|
370
|
-
|
|
371
|
-
export declare const getListings: ({ page, pageSize, }: {
|
|
372
|
-
page?: number;
|
|
373
|
-
pageSize?: number;
|
|
374
|
-
}) => Promise<{
|
|
375
|
-
items: MockItemType[];
|
|
376
|
-
}>;
|
|
377
|
-
|
|
378
|
-
export declare const getStorybookDecorators: ({ config, }: {
|
|
379
|
-
config?: EmperorUIConfig;
|
|
380
|
-
}) => ((Story: any) => JSX.Element)[];
|
|
381
|
-
|
|
382
|
-
export declare const Header: ForwardRefExoticComponent<Omit<ClassAttributes<HTMLElement> & HTMLAttributes<HTMLElement> & VariantProps<(props?: ({
|
|
383
|
-
variant?: "default" | "floating" | "light" | "segmented-floating" | null | undefined;
|
|
384
|
-
} & ClassProp) | undefined) => string> & SharedComponentProps & {
|
|
385
|
-
variant?: HeaderVariant;
|
|
386
|
-
classNames?: HeaderClassnames;
|
|
387
|
-
glassEffect?: HeaderGlassEffect;
|
|
388
|
-
}, "ref"> & RefAttributes<HTMLElement>>;
|
|
389
|
-
|
|
390
|
-
export declare type HeaderActivations = {
|
|
391
|
-
hideLog?: boolean;
|
|
392
|
-
hideNavbar?: boolean;
|
|
393
|
-
hideUserDropdown?: boolean;
|
|
394
|
-
hideSideMenu?: boolean;
|
|
395
|
-
};
|
|
396
|
-
|
|
397
|
-
export declare type HeaderClassnames = {
|
|
398
|
-
base?: string;
|
|
399
|
-
logo?: string;
|
|
400
|
-
navbar?: string;
|
|
401
|
-
userDropdown?: string;
|
|
402
|
-
sideMenu?: string;
|
|
403
|
-
};
|
|
404
|
-
|
|
405
|
-
export declare type HeaderDropdownProps = SharedComponentProps & {};
|
|
406
|
-
|
|
407
|
-
export declare type HeaderGlassEffect = {
|
|
408
|
-
enabled?: boolean;
|
|
409
|
-
blur?: number;
|
|
410
|
-
backgroundColor?: string;
|
|
411
|
-
foregroundColor?: string;
|
|
412
|
-
opacity?: number;
|
|
413
|
-
};
|
|
414
|
-
|
|
415
|
-
export declare type HeaderProps = SharedComponentProps & {
|
|
416
|
-
variant?: HeaderVariant;
|
|
417
|
-
classNames?: HeaderClassnames;
|
|
418
|
-
glassEffect?: HeaderGlassEffect;
|
|
419
|
-
};
|
|
420
|
-
|
|
421
|
-
export declare type HeaderStylesProps = {
|
|
422
|
-
primaryColor?: string;
|
|
423
|
-
foregroundColor?: string;
|
|
424
|
-
variant?: HeaderVariant;
|
|
425
|
-
glassEffect?: HeaderGlassEffect;
|
|
426
|
-
};
|
|
427
|
-
|
|
428
|
-
export declare type HeaderVariant = "default" | "floating" | "light" | "segmented-floating";
|
|
429
|
-
|
|
430
|
-
export declare const isFileDuplicated: ({ files, fileName, }: {
|
|
431
|
-
files: FileObject[];
|
|
432
|
-
fileName: string;
|
|
433
|
-
}) => boolean;
|
|
434
|
-
|
|
435
|
-
export declare const isMaxFileSizeExceeded: ({ fileSize, maxFileSize, }: {
|
|
436
|
-
fileSize: number;
|
|
437
|
-
maxFileSize: number;
|
|
438
|
-
}) => boolean;
|
|
439
|
-
|
|
440
|
-
export declare const ITEM_CARD_ACTIONS: ItemCardAction[];
|
|
441
|
-
|
|
442
|
-
export declare function ItemActionsDropdown({ actions, classNames, onActionClick, }: Pick<ItemCardProps, "actions" | "classNames" | "onActionClick">): JSX.Element | null;
|
|
443
|
-
|
|
444
|
-
export declare function ItemBanner({ item, orientation, classNames, }: Pick<ItemCardProps, "item" | "orientation" | "classNames">): JSX.Element | null;
|
|
445
|
-
|
|
446
|
-
export declare function ItemCard({ variants, isLoading, className, classNames, item, actions, hoverEffect, onActionClick, orientation: defaultOrientation, }: ItemCardProps): JSX.Element;
|
|
447
|
-
|
|
448
|
-
export declare type ItemCardAction = DropdownItemProps & {
|
|
449
|
-
key: string;
|
|
450
|
-
label: string;
|
|
451
|
-
};
|
|
452
|
-
|
|
453
|
-
export declare function ItemCardBody({ item, orientation, classNames, actions, onActionClick, }: Pick<ItemCardProps, "item" | "orientation" | "classNames" | "actions" | "onActionClick">): JSX.Element;
|
|
454
|
-
|
|
455
|
-
export declare type ItemCardClassnames = {
|
|
456
|
-
base?: string;
|
|
457
|
-
image?: string;
|
|
458
|
-
header?: string;
|
|
459
|
-
footer?: string;
|
|
460
|
-
imageWrapper?: string;
|
|
461
|
-
mainWrapper?: string;
|
|
462
|
-
banner?: string;
|
|
463
|
-
dropdown?: string;
|
|
464
|
-
body?: string;
|
|
465
|
-
title?: string;
|
|
466
|
-
price?: string;
|
|
467
|
-
description?: string;
|
|
468
|
-
chips?: string;
|
|
469
|
-
chip?: string;
|
|
470
|
-
};
|
|
471
|
-
|
|
472
|
-
export declare function ItemCardFooter({ item, orientation, classNames, }: Pick<ItemCardProps, "item" | "orientation" | "classNames">): JSX.Element;
|
|
473
|
-
|
|
474
|
-
export declare function ItemCardHeader({ item, orientation, classNames, actions, onActionClick, }: Pick<ItemCardProps, "item" | "orientation" | "classNames" | "actions" | "onActionClick">): JSX.Element;
|
|
475
|
-
|
|
476
|
-
export declare type ItemCardHoverEffect = "none" | "zoom" | "rotate";
|
|
477
|
-
|
|
478
|
-
export declare type ItemCardOrientation = "horizontal" | "vertical";
|
|
479
|
-
|
|
480
|
-
export declare type ItemCardProps = SharedComponentProps & {
|
|
481
|
-
variants?: Variants;
|
|
482
|
-
isLoading?: boolean;
|
|
483
|
-
hoverEffect?: ItemCardHoverEffect;
|
|
484
|
-
classNames?: ItemCardClassnames;
|
|
485
|
-
item: ItemProps;
|
|
486
|
-
actions?: ItemCardAction[];
|
|
487
|
-
onActionClick?: (key: string) => void;
|
|
488
|
-
orientation?: ItemCardOrientation;
|
|
489
|
-
};
|
|
490
|
-
|
|
491
|
-
export declare type ItemChipProps = ChipProps & {
|
|
492
|
-
label: string;
|
|
493
|
-
};
|
|
494
|
-
|
|
495
|
-
export declare function ItemDetails({ className }: ItemDetailsProps): JSX.Element;
|
|
496
|
-
|
|
497
|
-
export declare type ItemDetailsClassnames = {
|
|
498
|
-
base?: string;
|
|
499
|
-
};
|
|
500
|
-
|
|
501
|
-
export declare type ItemDetailsProps = SharedComponentProps & {
|
|
502
|
-
classNames?: ItemDetailsClassnames;
|
|
503
|
-
};
|
|
504
|
-
|
|
505
|
-
export declare type ItemProps = {
|
|
506
|
-
key: string;
|
|
507
|
-
title?: ReactNode;
|
|
508
|
-
description?: ReactNode;
|
|
509
|
-
image?: {
|
|
510
|
-
src: string;
|
|
511
|
-
alt: string;
|
|
512
|
-
};
|
|
513
|
-
chips?: ItemChipProps[];
|
|
514
|
-
banner?: ReactNode;
|
|
515
|
-
price?: ReactNode;
|
|
516
|
-
};
|
|
517
|
-
|
|
518
|
-
/**
|
|
519
|
-
* This component is not for general use nor it is reusable, it is intended to be used as a demo page.
|
|
520
|
-
*/
|
|
521
|
-
export declare const LandingPage: ForwardRefExoticComponent<Omit<ClassAttributes<HTMLElement> & HTMLAttributes<HTMLElement> & VariantProps<(props?: ({
|
|
522
|
-
variant?: "default" | null | undefined;
|
|
523
|
-
} & ClassProp) | undefined) => string> & SharedComponentProps & {
|
|
524
|
-
classNames?: LandingPageClassnames;
|
|
525
|
-
variant?: "default";
|
|
526
|
-
}, "ref"> & RefAttributes<HTMLDivElement>>;
|
|
527
|
-
|
|
528
|
-
export declare type LandingPageClassnames = {
|
|
529
|
-
base?: string;
|
|
530
|
-
};
|
|
531
|
-
|
|
532
|
-
export declare type LandingPageProps = SharedComponentProps & {
|
|
533
|
-
classNames?: LandingPageClassnames;
|
|
534
|
-
variant?: "default";
|
|
535
|
-
};
|
|
536
|
-
|
|
537
|
-
export declare function Listings({ items, isLoading, className, classNames, layout, actions, onActionClick, pagination, }: ListingsProps): JSX.Element;
|
|
538
|
-
|
|
539
|
-
export declare const listingsClasses: (props?: ({
|
|
540
|
-
layout?: "grid" | "list" | "carousel" | null | undefined;
|
|
541
|
-
} & ClassProp) | undefined) => string;
|
|
542
|
-
|
|
543
|
-
export declare type ListingsClassnames = {
|
|
544
|
-
base?: string;
|
|
545
|
-
item?: string;
|
|
546
|
-
pagination?: string;
|
|
547
|
-
};
|
|
548
|
-
|
|
549
|
-
export declare const listingsItemClasses: (props?: ({
|
|
550
|
-
layout?: "grid" | "list" | "carousel" | null | undefined;
|
|
551
|
-
} & ClassProp) | undefined) => string;
|
|
552
|
-
|
|
553
|
-
export declare type ListingsLayout = "grid" | "list" | "carousel";
|
|
554
|
-
|
|
555
|
-
export declare const listingsPaginationClasses: (props?: ({
|
|
556
|
-
layout?: "grid" | "list" | "carousel" | null | undefined;
|
|
557
|
-
} & ClassProp) | undefined) => string;
|
|
558
|
-
|
|
559
|
-
export declare type ListingsProps = SharedComponentProps & {
|
|
560
|
-
classNames?: ListingsClassnames;
|
|
561
|
-
layout?: ListingsLayout;
|
|
562
|
-
items: ItemCardProps[];
|
|
563
|
-
isLoading?: boolean;
|
|
564
|
-
actions?: ItemCardAction[];
|
|
565
|
-
onActionClick?: (key: string) => void;
|
|
566
|
-
pagination?: {
|
|
567
|
-
page: number;
|
|
568
|
-
setPage: (page: number) => void;
|
|
569
|
-
pageSize: number;
|
|
570
|
-
totalItemsCount: number;
|
|
571
|
-
pagesCount: number;
|
|
572
|
-
};
|
|
573
|
-
};
|
|
574
|
-
|
|
575
|
-
export declare const listingsStyles: ({}: {}) => CSSProperties;
|
|
576
|
-
|
|
577
|
-
export declare function LoadingItem({ className, classNames, hoverEffect, orientation, }: Pick<ItemCardProps, "className" | "classNames" | "hoverEffect" | "orientation">): JSX.Element;
|
|
578
|
-
|
|
579
|
-
declare type Locale = typeof ar | typeof en;
|
|
580
|
-
|
|
581
|
-
export declare const mapFileType: (fileType: string) => FileType | null;
|
|
582
|
-
|
|
583
|
-
/**
|
|
584
|
-
* Deep-merges config locales into default locales. Default values are used as base,
|
|
585
|
-
* and config values override only the keys they provide. Nested objects are merged
|
|
586
|
-
* recursively so unrelated keys at any level remain unchanged.
|
|
587
|
-
*/
|
|
588
|
-
export declare const mergeLocales: ({ defaultLocales, configLocales, }: {
|
|
589
|
-
defaultLocales: Locale;
|
|
590
|
-
configLocales?: Partial<Locale>;
|
|
591
|
-
}) => Locale;
|
|
592
|
-
|
|
593
|
-
export declare const MOCK_BASE_DATE: Date;
|
|
594
|
-
|
|
595
|
-
export declare const MOCK_COLORS: MockColor[];
|
|
596
|
-
|
|
597
|
-
export declare const MOCK_HEADER_ACTIONS: SideBarAction[];
|
|
598
|
-
|
|
599
|
-
export declare const MOCK_HEADER_ITEMS: NavigationItem[];
|
|
600
|
-
|
|
601
|
-
export declare const MOCK_HEADER_ITEMS_WITH_SUB_ITEMS: NavigationItem[];
|
|
602
|
-
|
|
603
|
-
export declare const MOCK_HEADER_SUB_ITEMS: NavigationItem[];
|
|
604
|
-
|
|
605
|
-
export declare const MOCK_ITEM_BRANDS: MockItemBrand[];
|
|
606
|
-
|
|
607
|
-
export declare const MOCK_ITEM_CATEGORIES: MockItemCategory[];
|
|
608
|
-
|
|
609
|
-
export declare const MOCK_ITEM_REVIEWS_1: MockReview[];
|
|
610
|
-
|
|
611
|
-
export declare const MOCK_ITEM_REVIEWS_2: MockReview[];
|
|
612
|
-
|
|
613
|
-
export declare const MOCK_ITEM_REVIEWS_3: MockReview[];
|
|
614
|
-
|
|
615
|
-
export declare const MOCK_LISTING_DESCRIPTIONS: string[];
|
|
616
|
-
|
|
617
|
-
export declare const MOCK_LISTING_IMAGES: string[];
|
|
618
|
-
|
|
619
|
-
export declare const MOCK_LISTING_TITLES: string[];
|
|
620
|
-
|
|
621
|
-
export declare const MOCK_LISTINGS: MockItemType[];
|
|
622
|
-
|
|
623
|
-
export declare const MOCK_REVIEW_AUTHORS: string[];
|
|
624
|
-
|
|
625
|
-
export declare const MOCK_REVIEW_COMMENTS: readonly string[];
|
|
626
|
-
|
|
627
|
-
export declare type MockColor = "red" | "blue" | "green" | "yellow" | "purple" | "orange" | "pink" | "brown" | "gray" | "black" | "white";
|
|
628
|
-
|
|
629
|
-
export declare type MockItemBrand = "Apple" | "Dell" | "HP" | "Lenovo" | "Asus" | "Acer" | "MSI" | "Razer" | "Samsung" | "Microsoft";
|
|
630
|
-
|
|
631
|
-
export declare type MockItemCategory = "laptops" | "desktops" | "monitors" | "keyboards" | "mice" | "headsets" | "printers" | "storage" | "components" | "networking";
|
|
632
|
-
|
|
633
|
-
export declare type MockItemType = {
|
|
634
|
-
id: number;
|
|
635
|
-
title: string;
|
|
636
|
-
description: string;
|
|
637
|
-
image: string;
|
|
638
|
-
price: number;
|
|
639
|
-
categories: ItemChipProps[];
|
|
640
|
-
isAvailable: boolean;
|
|
641
|
-
isBestSeller: boolean;
|
|
642
|
-
averageRating: number;
|
|
643
|
-
reviews: MockReview[];
|
|
644
|
-
brand: MockItemBrand;
|
|
645
|
-
color: MockColor;
|
|
646
|
-
createdAt: Date;
|
|
647
|
-
updatedAt: Date;
|
|
648
|
-
};
|
|
649
|
-
|
|
650
|
-
export declare type MockReview = {
|
|
651
|
-
id: number;
|
|
652
|
-
rating: number;
|
|
653
|
-
comment: string;
|
|
654
|
-
author: string;
|
|
655
|
-
createdAt: Date;
|
|
656
|
-
updatedAt: Date;
|
|
657
|
-
};
|
|
658
|
-
|
|
659
|
-
export declare const NavBar: ForwardRefExoticComponent<Omit<ClassAttributes<HTMLElement> & HTMLAttributes<HTMLElement> & VariantProps<(props?: ({
|
|
660
|
-
hoverEffect?: "default" | "underline" | "solid" | "ghost" | "bordered" | "none" | null | undefined;
|
|
661
|
-
variant?: "default" | "solid" | "bordered" | null | undefined;
|
|
662
|
-
} & ClassProp) | undefined) => string> & SharedComponentProps & {
|
|
663
|
-
items: NavigationItem[];
|
|
664
|
-
classNames?: NavBarClassnames;
|
|
665
|
-
hoverEffect?: NavBarHoverEffect;
|
|
666
|
-
radius?: ComponentRadius;
|
|
667
|
-
size?: ComponentSize;
|
|
668
|
-
variant?: NavBarVariant;
|
|
669
|
-
subItemsColumns?: number;
|
|
670
|
-
}, "ref"> & RefAttributes<HTMLDivElement>>;
|
|
671
|
-
|
|
672
|
-
export declare type NavBarClassnames = {
|
|
673
|
-
base?: string;
|
|
674
|
-
};
|
|
675
|
-
|
|
676
|
-
export declare type NavBarHoverEffect = "default" | "underline" | "solid" | "ghost" | "bordered" | "none";
|
|
677
|
-
|
|
678
|
-
export declare const NavBarItem: ForwardRefExoticComponent<Omit<ClassAttributes<HTMLLIElement> & LiHTMLAttributes<HTMLLIElement> & VariantProps<(props?: ({
|
|
679
|
-
hoverEffect?: "default" | "underline" | "solid" | "ghost" | "bordered" | "none" | null | undefined;
|
|
680
|
-
variant?: "default" | "solid" | "bordered" | null | undefined;
|
|
681
|
-
} & ClassProp) | undefined) => string> & NavBarItemProps, "ref"> & RefAttributes<HTMLLIElement>>;
|
|
682
|
-
|
|
683
|
-
export declare type NavBarItemProps = {
|
|
684
|
-
item: NavigationItem;
|
|
685
|
-
variant: NavBarVariant;
|
|
686
|
-
hoverEffect: NavBarHoverEffect;
|
|
687
|
-
};
|
|
688
|
-
|
|
689
|
-
export declare type NavBarItemStylesProps = {
|
|
690
|
-
foregroundColor?: string;
|
|
691
|
-
primaryColor?: string;
|
|
692
|
-
hoverEffect: NavBarHoverEffect;
|
|
693
|
-
isHovered?: boolean;
|
|
694
|
-
variant?: NavBarVariant;
|
|
695
|
-
};
|
|
696
|
-
|
|
697
|
-
export declare type NavBarMenuStylesProps = {};
|
|
698
|
-
|
|
699
|
-
export declare type NavBarProps = SharedComponentProps & {
|
|
700
|
-
items: NavigationItem[];
|
|
701
|
-
classNames?: NavBarClassnames;
|
|
702
|
-
hoverEffect?: NavBarHoverEffect;
|
|
703
|
-
radius?: ComponentRadius;
|
|
704
|
-
size?: ComponentSize;
|
|
705
|
-
variant?: NavBarVariant;
|
|
706
|
-
subItemsColumns?: number;
|
|
707
|
-
};
|
|
708
|
-
|
|
709
|
-
export declare type NavBarStylesProps = {
|
|
710
|
-
primaryColor?: string;
|
|
711
|
-
foregroundColor?: string;
|
|
712
|
-
variant?: NavBarVariant;
|
|
713
|
-
};
|
|
714
|
-
|
|
715
|
-
export declare type NavBarVariant = "default" | "solid" | "bordered";
|
|
716
|
-
|
|
717
|
-
export declare const NavigationContext: Context<NavigationContextState | undefined>;
|
|
718
|
-
|
|
719
|
-
export declare type NavigationContextState = {
|
|
720
|
-
hoveredItemId: string | null;
|
|
721
|
-
subItems: NavigationItem[];
|
|
722
|
-
isSubItemsBoxOpen: boolean;
|
|
723
|
-
subItemsBoxIsHovered: boolean;
|
|
724
|
-
setHoveredItemId: (id: string | null) => void;
|
|
725
|
-
setSubItems: (items: NavigationItem[]) => void;
|
|
726
|
-
setIsSubItemsBoxOpen: (isOpen: boolean) => void;
|
|
727
|
-
setSubItemsBoxIsHovered: (isHovered: boolean) => void;
|
|
728
|
-
};
|
|
729
|
-
|
|
730
|
-
export declare type NavigationItem = {
|
|
731
|
-
id: string;
|
|
732
|
-
label?: string;
|
|
733
|
-
href?: string;
|
|
734
|
-
subItems?: NavigationItem[];
|
|
735
|
-
onClick?: () => void;
|
|
736
|
-
Icon?: ElementType;
|
|
737
|
-
};
|
|
738
|
-
|
|
739
|
-
export declare function NavigationProvider({ children }: NavigationProviderProps): JSX.Element;
|
|
740
|
-
|
|
741
|
-
export declare type NavigationProviderProps = {
|
|
742
|
-
children: ReactNode;
|
|
743
|
-
};
|
|
744
|
-
|
|
745
|
-
export declare function NumericFilter({ classNames, numericProps, paramKey, ...props }: Pick<FilterProps, "classNames" | "numericProps" | "paramKey">): JSX.Element;
|
|
746
|
-
|
|
747
|
-
export declare const ONE_MEGABYTE = 1024;
|
|
748
|
-
|
|
749
|
-
export declare enum Placeholders {
|
|
750
|
-
PLACEHOLDER_MALE_AVATAR = "/images/placeholder-male-avatar.png",
|
|
751
|
-
PLACEHOLDER_FEMALE_AVATAR = "/images/placeholder-female-avatar.png"
|
|
752
|
-
}
|
|
753
|
-
|
|
754
|
-
export declare const policies: QuickLink[];
|
|
755
|
-
|
|
756
|
-
export declare function PoliciesBox({ policies, classNames }: FooterProps): JSX.Element;
|
|
757
|
-
|
|
758
|
-
export declare function Portal({ children, containerId, isVisible, }: PortalProps): ReactPortal | null;
|
|
759
|
-
|
|
760
|
-
export declare type PortalProps = SharedComponentProps & {
|
|
761
|
-
containerId: string;
|
|
762
|
-
isVisible?: boolean;
|
|
763
|
-
};
|
|
764
|
-
|
|
765
|
-
export declare enum PreservedKeys {
|
|
766
|
-
COMPACT_SIDEBAR_ID = "emperor-compact-sidebar"
|
|
767
|
-
}
|
|
768
|
-
|
|
769
|
-
export declare function PresetColorPicker({ className, classNames, value, onSelectionChange, inputType, presets, ...props }: ColorPickerProps): JSX.Element;
|
|
770
|
-
|
|
771
|
-
export declare type QuickLink = {
|
|
772
|
-
label: string;
|
|
773
|
-
href: string;
|
|
774
|
-
isExternal?: boolean;
|
|
775
|
-
};
|
|
776
|
-
|
|
777
|
-
export declare type QuickLinkCollection = {
|
|
778
|
-
title?: string;
|
|
779
|
-
links: QuickLink[];
|
|
780
|
-
};
|
|
781
|
-
|
|
782
|
-
export declare const quickLinks: QuickLinkCollection[];
|
|
783
|
-
|
|
784
|
-
export declare function QuickLinksBox({ quickLinks, classNames }: FooterProps): JSX.Element;
|
|
785
|
-
|
|
786
|
-
export declare function RangeFilter({ classNames, rangeProps, paramKey, ...props }: Pick<FilterProps, "classNames" | "rangeProps" | "paramKey">): JSX.Element;
|
|
787
|
-
|
|
788
|
-
export declare function refineUploadedFiles({ uploadedFiles, locale, allowedTypes, isMulti, setFiles, }: {
|
|
789
|
-
uploadedFiles: (File | undefined)[];
|
|
790
|
-
locale?: Locale;
|
|
791
|
-
allowedTypes: string[];
|
|
792
|
-
isMulti: boolean;
|
|
793
|
-
setFiles: Dispatch<SetStateAction<FileObject[]>>;
|
|
794
|
-
}): Promise<void[]>;
|
|
795
|
-
|
|
796
|
-
export declare const Row: ForwardRefExoticComponent<Omit<ClassAttributes<HTMLElement> & HTMLAttributes<HTMLElement> & VariantProps<(props?: ({} & ClassProp) | undefined) => string> & SharedComponentProps, "ref"> & RefAttributes<HTMLElement>>;
|
|
797
|
-
|
|
798
|
-
export declare type RowProps = SharedComponentProps & {};
|
|
799
|
-
|
|
800
|
-
export declare const Scaffold: ForwardRefExoticComponent<SharedComponentProps & {
|
|
801
|
-
classNames?: ScaffoldClassnames;
|
|
802
|
-
} & RefAttributes<HTMLDivElement>>;
|
|
803
|
-
|
|
804
|
-
export declare const scaffoldClasses: (props?: ({} & ClassProp) | undefined) => string;
|
|
805
|
-
|
|
806
|
-
export declare type ScaffoldClassnames = {
|
|
807
|
-
base?: string;
|
|
808
|
-
};
|
|
809
|
-
|
|
810
|
-
export declare type ScaffoldProps = SharedComponentProps & {
|
|
811
|
-
classNames?: ScaffoldClassnames;
|
|
812
|
-
};
|
|
813
|
-
|
|
814
|
-
export declare function SearchFilter({ classNames, searchProps, paramKey, ...props }: Pick<FilterProps, "classNames" | "searchProps" | "paramKey">): JSX.Element;
|
|
815
|
-
|
|
816
|
-
export declare type SegmentedHeaderContentProps = SharedComponentProps & {
|
|
817
|
-
glassEffect?: HeaderGlassEffect;
|
|
818
|
-
};
|
|
819
|
-
|
|
820
|
-
export declare function SelectFilter({ classNames, selectProps, paramKey, options, ...props }: Pick<FilterProps, "classNames" | "selectProps" | "paramKey" | "options">): JSX.Element;
|
|
821
|
-
|
|
822
|
-
export declare type SelectFilterProps = {
|
|
823
|
-
options?: SelectOption[];
|
|
824
|
-
};
|
|
825
|
-
|
|
826
|
-
export declare type SelectOption = {
|
|
827
|
-
key: string;
|
|
828
|
-
label: string;
|
|
829
|
-
};
|
|
830
|
-
|
|
831
|
-
export declare type SharedComponentProps = {
|
|
832
|
-
className?: string;
|
|
833
|
-
classNames?: {
|
|
834
|
-
base?: string;
|
|
835
|
-
};
|
|
836
|
-
children?: ReactNode;
|
|
837
|
-
};
|
|
838
|
-
|
|
839
|
-
export declare type SharedFilesType = FileObject[];
|
|
840
|
-
|
|
841
|
-
export declare type SharedLabelIdType = string;
|
|
842
|
-
|
|
843
|
-
export declare type SharedOnInputChangeType = (event: React.ChangeEvent<HTMLInputElement> & React.DragEvent<HTMLLabelElement>) => Promise<void | string | null>;
|
|
844
|
-
|
|
845
|
-
export declare const SideBar: ForwardRefExoticComponent<Omit<ClassAttributes<HTMLDivElement> & HTMLAttributes<HTMLDivElement> & VariantProps<(props?: ({
|
|
846
|
-
variant?: "default" | "compact" | null | undefined;
|
|
847
|
-
} & ClassProp) | undefined) => string> & SharedComponentProps & {
|
|
848
|
-
classNames?: SideBarClassnames;
|
|
849
|
-
variant?: SideBarVariant;
|
|
850
|
-
items: NavigationItem[];
|
|
851
|
-
actions?: SideBarAction[];
|
|
852
|
-
triggerProps?: Omit<ButtonProps, "content"> & {
|
|
853
|
-
content?: ReactNode;
|
|
854
|
-
};
|
|
855
|
-
isOpen?: boolean;
|
|
856
|
-
onOpenChange?: (isOpen: boolean) => void;
|
|
857
|
-
header?: ReactNode;
|
|
858
|
-
}, "ref"> & RefAttributes<HTMLDivElement>>;
|
|
859
|
-
|
|
860
|
-
export declare type SideBarAction = ButtonProps & {
|
|
861
|
-
key: string;
|
|
862
|
-
label?: string;
|
|
863
|
-
};
|
|
864
|
-
|
|
865
|
-
export declare type SideBarClassnames = {
|
|
866
|
-
base?: string;
|
|
867
|
-
trigger?: string;
|
|
868
|
-
title?: string;
|
|
869
|
-
menu?: string;
|
|
870
|
-
menuItem?: string;
|
|
871
|
-
actionsWrapper?: string;
|
|
872
|
-
actionItem?: string;
|
|
873
|
-
};
|
|
874
|
-
|
|
875
|
-
export declare type SideBarItemStylesProps = {
|
|
876
|
-
foregroundColor?: string;
|
|
877
|
-
primaryColor?: string;
|
|
878
|
-
isHovered?: boolean;
|
|
879
|
-
variant?: SideBarVariant;
|
|
880
|
-
};
|
|
881
|
-
|
|
882
|
-
export declare type SideBarProps = SharedComponentProps & {
|
|
883
|
-
classNames?: SideBarClassnames;
|
|
884
|
-
variant?: SideBarVariant;
|
|
885
|
-
items: NavigationItem[];
|
|
886
|
-
actions?: SideBarAction[];
|
|
887
|
-
triggerProps?: Omit<ButtonProps, "content"> & {
|
|
888
|
-
content?: ReactNode;
|
|
889
|
-
};
|
|
890
|
-
isOpen?: boolean;
|
|
891
|
-
onOpenChange?: (isOpen: boolean) => void;
|
|
892
|
-
header?: ReactNode;
|
|
893
|
-
};
|
|
894
|
-
|
|
895
|
-
export declare type SideBarVariant = "default" | "compact";
|
|
896
|
-
|
|
897
|
-
export declare type SocialLink = {
|
|
898
|
-
label?: string;
|
|
899
|
-
href: string;
|
|
900
|
-
icon?: ReactNode;
|
|
901
|
-
isExternal?: boolean;
|
|
902
|
-
};
|
|
903
|
-
|
|
904
|
-
export declare const socialLinks: SocialLink[];
|
|
905
|
-
|
|
906
|
-
export declare function SocialLinksBox({ socialLinks, classNames }: FooterProps): JSX.Element;
|
|
907
|
-
|
|
908
|
-
export declare const SubItemsBox: ({ subItemsColumns }: SubItemsBoxProps) => JSX.Element;
|
|
909
|
-
|
|
910
|
-
export declare type SubItemsBoxProps = {
|
|
911
|
-
subItemsColumns?: number;
|
|
912
|
-
};
|
|
913
|
-
|
|
914
|
-
export declare function SwitchFilter({ classNames, switchProps, paramKey, ...props }: Pick<FilterProps, "classNames" | "switchProps" | "paramKey">): JSX.Element;
|
|
915
|
-
|
|
916
|
-
export declare function ThemeProvider({ children }: ThemeProviderProps): JSX.Element;
|
|
917
|
-
|
|
918
|
-
export declare type ThemeProviderProps = {
|
|
919
|
-
children: ReactNode;
|
|
920
|
-
};
|
|
921
|
-
|
|
922
|
-
export declare function ThemeSwitch({ className, classNames, ...props }: ThemeSwitchProps): JSX.Element;
|
|
923
|
-
|
|
924
|
-
export declare type ThemeSwitchClassnames = {
|
|
925
|
-
base?: string;
|
|
926
|
-
};
|
|
927
|
-
|
|
928
|
-
export declare type ThemeSwitchProps = SharedComponentProps & {
|
|
929
|
-
classNames?: ThemeSwitchClassnames;
|
|
930
|
-
};
|
|
931
|
-
|
|
932
|
-
/**
|
|
933
|
-
* @usage
|
|
934
|
-
* ```
|
|
935
|
-
* const uploadProps = useUpload({
|
|
936
|
-
labelId: "uploaded-file",
|
|
937
|
-
fileTypes: ["image", "pdf"],
|
|
938
|
-
isRequired: true,
|
|
939
|
-
isMulti: true,
|
|
940
|
-
});
|
|
941
|
-
|
|
942
|
-
<Uploader {...uploadProps} />
|
|
943
|
-
* ```
|
|
944
|
-
*/
|
|
945
|
-
export declare const Uploader: ForwardRefExoticComponent<Omit<ClassAttributes<HTMLDivElement> & HTMLAttributes<HTMLDivElement> & VariantProps<(props?: ({} & ClassProp) | undefined) => string> & SharedComponentProps & UploaderContextState & {
|
|
946
|
-
className?: string;
|
|
947
|
-
hideListing?: boolean;
|
|
948
|
-
isAvatar?: boolean;
|
|
949
|
-
}, "ref"> & RefAttributes<HTMLDivElement>>;
|
|
950
|
-
|
|
951
|
-
export declare const UploaderContext: Context<UploaderContextState | undefined>;
|
|
952
|
-
|
|
953
|
-
export declare type UploaderContextState = {
|
|
954
|
-
selectedFile?: FileObject | null;
|
|
955
|
-
setSelectedFile?: (file: FileObject | null) => void;
|
|
956
|
-
labelId: SharedLabelIdType;
|
|
957
|
-
labelContent?: ReactNode;
|
|
958
|
-
avatarLabelContent?: ReactNode;
|
|
959
|
-
title?: ReactNode;
|
|
960
|
-
errorMessage?: ReactNode;
|
|
961
|
-
isFileViewable?: boolean;
|
|
962
|
-
isRequired?: boolean;
|
|
963
|
-
isDraggable?: boolean;
|
|
964
|
-
isLoading: boolean;
|
|
965
|
-
hideErrorMessage?: boolean;
|
|
966
|
-
isMulti: boolean;
|
|
967
|
-
placeholderImage?: string;
|
|
968
|
-
files: SharedFilesType;
|
|
969
|
-
fileTypes: FileType[];
|
|
970
|
-
onInputChange: SharedOnInputChangeType;
|
|
971
|
-
handleClearFile: (fileName?: string) => void;
|
|
972
|
-
modal?: Omit<ModalProps, "children"> & {
|
|
973
|
-
onOpen?: () => void;
|
|
974
|
-
};
|
|
975
|
-
classNames?: {
|
|
976
|
-
label?: string;
|
|
977
|
-
avatar?: string;
|
|
978
|
-
listing?: string;
|
|
979
|
-
listingItem?: string;
|
|
980
|
-
error?: string;
|
|
981
|
-
input?: string;
|
|
982
|
-
title?: string;
|
|
983
|
-
};
|
|
984
|
-
};
|
|
985
|
-
|
|
986
|
-
export declare type UploaderProps = SharedComponentProps & UploaderContextState & {
|
|
987
|
-
className?: string;
|
|
988
|
-
hideListing?: boolean;
|
|
989
|
-
isAvatar?: boolean;
|
|
990
|
-
};
|
|
991
|
-
|
|
992
|
-
export declare function UploaderProvider({ children, ...props }: UploaderProviderProps): JSX.Element;
|
|
993
|
-
|
|
994
|
-
export declare type UploaderProviderProps = UploaderContextState & {
|
|
995
|
-
children: ReactNode;
|
|
996
|
-
};
|
|
997
|
-
|
|
998
|
-
export declare function UploaderTitle({ ...props }: ComponentProps<"h3">): JSX.Element | null;
|
|
999
|
-
|
|
1000
|
-
export declare function UploadFileErrorBox(): JSX.Element | null;
|
|
1001
|
-
|
|
1002
|
-
export declare function UploadFileInput(): JSX.Element;
|
|
1003
|
-
|
|
1004
|
-
export declare function UploadFileLabel(): JSX.Element | null;
|
|
1005
|
-
|
|
1006
|
-
export declare function UploadFileListing(): JSX.Element;
|
|
1007
|
-
|
|
1008
|
-
export declare function useEmperorUI(): ConfigContextState;
|
|
1009
|
-
|
|
1010
|
-
export declare function useFilters<FiltersType extends Record<string, string | number | boolean>>(): {
|
|
1011
|
-
filters: FiltersType | null;
|
|
1012
|
-
};
|
|
1013
|
-
|
|
1014
|
-
export declare function useNavigation(): NavigationContextState;
|
|
1015
|
-
|
|
1016
|
-
export declare type UserDropdownProps = SharedComponentProps & {};
|
|
1017
|
-
|
|
1018
|
-
export declare function useSearchParamsHandler(): {
|
|
1019
|
-
getParam: (name: string) => string | null;
|
|
1020
|
-
allParams: Record<string, string>;
|
|
1021
|
-
setParams: ({ params, options, }: {
|
|
1022
|
-
params: Record<string, string | number | boolean | undefined | null>;
|
|
1023
|
-
options?: {
|
|
1024
|
-
replace?: boolean;
|
|
1025
|
-
};
|
|
1026
|
-
}) => void;
|
|
1027
|
-
deleteParam: ({ key }: {
|
|
1028
|
-
key: string;
|
|
1029
|
-
}) => void;
|
|
1030
|
-
deleteParams: ({ keys }: {
|
|
1031
|
-
keys: string[];
|
|
1032
|
-
}) => void;
|
|
1033
|
-
clearParams: () => void;
|
|
1034
|
-
};
|
|
1035
|
-
|
|
1036
|
-
export declare const useUploader: ({ labelContent, labelId, fileTypes, isRequired, isDraggable, isMulti, preventDuplicates, maxCount, maxFileSize, compressFiles, onChange, }: UseUploadFileProps) => UseUploadFileReturn;
|
|
1037
|
-
|
|
1038
|
-
export declare function useUploaderContext(): UploaderContextState;
|
|
1039
|
-
|
|
1040
|
-
export declare type UseUploadFileProps = {
|
|
1041
|
-
labelId: string;
|
|
1042
|
-
fileTypes: FileType[];
|
|
1043
|
-
labelContent?: ReactNode;
|
|
1044
|
-
isRequired?: boolean;
|
|
1045
|
-
isMulti?: boolean;
|
|
1046
|
-
isDraggable?: boolean;
|
|
1047
|
-
maxCount?: number;
|
|
1048
|
-
maxFileSize?: number;
|
|
1049
|
-
compressFiles?: boolean;
|
|
1050
|
-
preventDuplicates?: boolean;
|
|
1051
|
-
onChange?: () => void;
|
|
1052
|
-
};
|
|
1053
|
-
|
|
1054
|
-
export declare type UseUploadFileReturn = {
|
|
1055
|
-
files: FileObject[];
|
|
1056
|
-
fileTypes: FileType[];
|
|
1057
|
-
labelId: string;
|
|
1058
|
-
isRequired: boolean;
|
|
1059
|
-
labelContent: ReactNode;
|
|
1060
|
-
isDraggable: boolean;
|
|
1061
|
-
isMulti: boolean;
|
|
1062
|
-
isLoading: boolean;
|
|
1063
|
-
setFiles: Dispatch<SetStateAction<FileObject[]>>;
|
|
1064
|
-
handleClearFile: (fileName?: string) => void;
|
|
1065
|
-
onInputChange: SharedOnInputChangeType;
|
|
1066
|
-
};
|
|
1067
|
-
|
|
1068
|
-
export declare const useWindowSize: () => {
|
|
1069
|
-
viewportWidth: number;
|
|
1070
|
-
viewportHeight: number;
|
|
1071
|
-
currentScreen: "base" | "sm" | "md" | "lg" | "xl" | "2xl";
|
|
1072
|
-
isSmallDevice: boolean;
|
|
1073
|
-
isExtraSmallDevice: boolean;
|
|
1074
|
-
};
|
|
1075
|
-
|
|
1076
|
-
export declare function validateUploadedFiles({ uploadedFiles, maxFileSize, compressFiles, locale, preventDuplicates, files, }: {
|
|
1077
|
-
uploadedFiles: File[];
|
|
1078
|
-
maxFileSize?: number;
|
|
1079
|
-
compressFiles?: boolean;
|
|
1080
|
-
locale?: Locale;
|
|
1081
|
-
preventDuplicates?: boolean;
|
|
1082
|
-
files: FileObject[];
|
|
1083
|
-
}): Promise<{
|
|
1084
|
-
compressedFiles: (File | undefined)[];
|
|
1085
|
-
isInValid: boolean;
|
|
1086
|
-
}>;
|
|
1087
|
-
|
|
1088
|
-
export declare function ViewImageModal(): JSX.Element | null;
|
|
1089
|
-
|
|
1090
|
-
export { }
|