pillardash-ui-react 0.1.28 → 0.1.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +72 -2
- package/dist/index.js +3 -3
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -174,6 +174,26 @@ declare const alert: {
|
|
|
174
174
|
show: (props: Omit<AlertProps, "onClose">) => void;
|
|
175
175
|
};
|
|
176
176
|
|
|
177
|
+
type ConfirmationType = "default" | "danger" | "warning" | "success" | "info";
|
|
178
|
+
interface ConfirmationPopupProps {
|
|
179
|
+
isOpen: boolean;
|
|
180
|
+
onConfirm: () => void;
|
|
181
|
+
onCancel: () => void;
|
|
182
|
+
title?: string;
|
|
183
|
+
message?: string;
|
|
184
|
+
confirmText?: string;
|
|
185
|
+
cancelText?: string;
|
|
186
|
+
type?: ConfirmationType;
|
|
187
|
+
showIcon?: boolean;
|
|
188
|
+
showCloseButton?: boolean;
|
|
189
|
+
closeOnOverlayClick?: boolean;
|
|
190
|
+
closeOnEscape?: boolean;
|
|
191
|
+
isLoading?: boolean;
|
|
192
|
+
className?: string;
|
|
193
|
+
overlayClassName?: string;
|
|
194
|
+
maxWidth?: "sm" | "md" | "lg";
|
|
195
|
+
}
|
|
196
|
+
|
|
177
197
|
type ModalSize = 'xs' | 'sm' | 'md' | 'lg' | 'xl' | '2xl' | 'full';
|
|
178
198
|
type ModalPosition = 'left' | 'right' | 'center';
|
|
179
199
|
interface ModalProps {
|
|
@@ -198,5 +218,55 @@ declare const Modal: React$1.FC<ModalProps>;
|
|
|
198
218
|
|
|
199
219
|
declare const ModalExample: React$1.FC;
|
|
200
220
|
|
|
201
|
-
|
|
202
|
-
|
|
221
|
+
interface TableProps<T> {
|
|
222
|
+
data: T[];
|
|
223
|
+
columns: Column<T>[];
|
|
224
|
+
title?: string;
|
|
225
|
+
subtitle?: string;
|
|
226
|
+
itemsPerPage?: number;
|
|
227
|
+
currentView?: string;
|
|
228
|
+
onViewChange?: (view: string) => void;
|
|
229
|
+
totalItems?: number;
|
|
230
|
+
currentPage?: number;
|
|
231
|
+
onPageChange?: (page: number) => void;
|
|
232
|
+
loading?: boolean;
|
|
233
|
+
showPagination?: boolean;
|
|
234
|
+
}
|
|
235
|
+
interface Column<T> {
|
|
236
|
+
title: string;
|
|
237
|
+
value: keyof T | ((data: T) => React$1.ReactNode);
|
|
238
|
+
width?: string;
|
|
239
|
+
}
|
|
240
|
+
interface PaginationProps {
|
|
241
|
+
currentPage: number;
|
|
242
|
+
totalPages: number;
|
|
243
|
+
totalItems: number;
|
|
244
|
+
itemsPerPage: number;
|
|
245
|
+
onPageChange?: (page: number) => void;
|
|
246
|
+
onViewChange?: (itemsPerPage: string) => void;
|
|
247
|
+
loading?: boolean;
|
|
248
|
+
}
|
|
249
|
+
type TableDropdownProps = {
|
|
250
|
+
actions: {
|
|
251
|
+
label: string;
|
|
252
|
+
onClick: () => void;
|
|
253
|
+
icon?: React$1.ReactNode;
|
|
254
|
+
disabled?: boolean;
|
|
255
|
+
variant?: "default" | "danger";
|
|
256
|
+
}[];
|
|
257
|
+
trigger?: React$1.ReactNode;
|
|
258
|
+
className?: string;
|
|
259
|
+
dropdownClassName?: string;
|
|
260
|
+
};
|
|
261
|
+
|
|
262
|
+
declare function Table<T>({ data, columns, itemsPerPage, onViewChange, totalItems, currentPage, onPageChange, loading, showPagination, }: TableProps<T>): react_jsx_runtime.JSX.Element;
|
|
263
|
+
|
|
264
|
+
declare function Pagination({ currentPage, totalPages, totalItems, itemsPerPage, onPageChange, onViewChange, loading, }: PaginationProps): react_jsx_runtime.JSX.Element;
|
|
265
|
+
|
|
266
|
+
declare function TableSkeleton({ columns, rows }: {
|
|
267
|
+
columns: number;
|
|
268
|
+
rows: number;
|
|
269
|
+
}): react_jsx_runtime.JSX.Element;
|
|
270
|
+
|
|
271
|
+
export { AlertContext, AlertProvider, Button, Card, CheckBox, EmptyStateCard, ExportButton, ExportFormatEnum, FileUpload, Input, Modal, ModalExample, Pagination, Search, Select, SelectButton, Table, TableSkeleton, TextEditor, alert, useAlert };
|
|
272
|
+
export type { AlertContextProps, AlertItem, AlertProps, AlertType, ButtonProps, CheckBoxProps, Column, ConfirmationPopupProps, ConfirmationType, EmptyStateProps, FileUploadProps, InputProps, ModalProps, PaginationProps, SearchProps, SelectButtonOption, SelectButtonProps, SelectOption, SelectProps, TableDropdownProps, TableProps, TextEditorProps };
|