@gamecp/ui 0.1.30 → 0.1.33
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 +38 -6
- package/dist/index.d.ts +38 -6
- package/dist/index.js +190 -67
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +187 -69
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -202,8 +202,37 @@ interface InfoBoxProps {
|
|
|
202
202
|
children: React__default.ReactNode;
|
|
203
203
|
variant?: 'default' | 'warning' | 'info' | 'success' | 'danger';
|
|
204
204
|
className?: string;
|
|
205
|
+
/** Compact mode for inline usage */
|
|
206
|
+
compact?: boolean;
|
|
205
207
|
}
|
|
206
|
-
|
|
208
|
+
/**
|
|
209
|
+
* @deprecated Use Notice component instead. InfoBox is now a wrapper around Notice.
|
|
210
|
+
*/
|
|
211
|
+
declare function InfoBox({ title, children, variant, className, compact, }: InfoBoxProps): react_jsx_runtime.JSX.Element;
|
|
212
|
+
|
|
213
|
+
interface NoticeProps {
|
|
214
|
+
/** Main content of the notice */
|
|
215
|
+
children: React__default.ReactNode;
|
|
216
|
+
/** Variant type of the notice */
|
|
217
|
+
variant?: 'info' | 'warning' | 'success' | 'danger' | 'default';
|
|
218
|
+
/** Icon to display. If not provided, uses default for variant */
|
|
219
|
+
icon?: React__default.ReactNode;
|
|
220
|
+
/** Optional title */
|
|
221
|
+
title?: string | React__default.ReactNode;
|
|
222
|
+
/** Additional CSS classes */
|
|
223
|
+
className?: string;
|
|
224
|
+
/** Whether to show the icon */
|
|
225
|
+
showIcon?: boolean;
|
|
226
|
+
/** Custom content to the right (e.g., a toggle button) */
|
|
227
|
+
action?: React__default.ReactNode;
|
|
228
|
+
/** Compact mode for inline usage (less padding, smaller text) */
|
|
229
|
+
compact?: boolean;
|
|
230
|
+
}
|
|
231
|
+
declare function Notice({ children, variant, icon, title, className, showIcon, action, compact, }: NoticeProps): react_jsx_runtime.JSX.Element;
|
|
232
|
+
declare function InfoNotice(props: Omit<NoticeProps, 'variant'>): react_jsx_runtime.JSX.Element;
|
|
233
|
+
declare function WarningNotice(props: Omit<NoticeProps, 'variant'>): react_jsx_runtime.JSX.Element;
|
|
234
|
+
declare function SuccessNotice(props: Omit<NoticeProps, 'variant'>): react_jsx_runtime.JSX.Element;
|
|
235
|
+
declare function DangerNotice(props: Omit<NoticeProps, 'variant'>): react_jsx_runtime.JSX.Element;
|
|
207
236
|
|
|
208
237
|
interface LinkProps extends AnchorHTMLAttributes<HTMLAnchorElement> {
|
|
209
238
|
href: string;
|
|
@@ -302,11 +331,12 @@ declare function SmartDropdown({ isOpen, onClose, trigger, children, className,
|
|
|
302
331
|
interface Option {
|
|
303
332
|
value: string;
|
|
304
333
|
label: string;
|
|
305
|
-
description?:
|
|
334
|
+
description?: React.ReactNode;
|
|
306
335
|
icon?: React.ReactNode;
|
|
307
336
|
metadata?: {
|
|
308
337
|
isDefault?: boolean;
|
|
309
338
|
args?: string[];
|
|
339
|
+
commandType?: 'command' | 'bash' | 'sh' | 'powershell';
|
|
310
340
|
};
|
|
311
341
|
}
|
|
312
342
|
interface SmartSelectProps {
|
|
@@ -315,19 +345,21 @@ interface SmartSelectProps {
|
|
|
315
345
|
onChange: (value: string | string[]) => void;
|
|
316
346
|
placeholder?: string;
|
|
317
347
|
className?: string;
|
|
318
|
-
description?:
|
|
348
|
+
description?: React.ReactNode;
|
|
319
349
|
disabled?: boolean;
|
|
320
350
|
multiple?: boolean;
|
|
321
|
-
width?: number;
|
|
351
|
+
width?: number | 'auto' | 'fit-content';
|
|
322
352
|
searchable?: boolean;
|
|
323
353
|
keepOpen?: boolean;
|
|
324
354
|
clearable?: boolean;
|
|
355
|
+
variant?: 'default' | 'compact';
|
|
356
|
+
renderSelected?: (option: Option) => React.ReactNode;
|
|
325
357
|
onOpen?: () => void;
|
|
326
358
|
onClose?: () => void;
|
|
327
359
|
onSearch?: (search: string) => void;
|
|
328
360
|
isLoading?: boolean;
|
|
329
361
|
}
|
|
330
|
-
declare function SmartSelect({ options, value, onChange, placeholder, className, description, disabled, multiple, width, searchable, keepOpen, clearable, onOpen, onClose, onSearch, isLoading, }: SmartSelectProps): react_jsx_runtime.JSX.Element;
|
|
362
|
+
declare function SmartSelect({ options, value, onChange, placeholder, className, description, disabled, multiple, width, searchable, keepOpen, clearable, variant, renderSelected, onOpen, onClose, onSearch, isLoading, }: SmartSelectProps): react_jsx_runtime.JSX.Element;
|
|
331
363
|
|
|
332
364
|
interface SkeletonProps {
|
|
333
365
|
className?: string;
|
|
@@ -649,4 +681,4 @@ declare function IconButtonWithCount({ icon, label, count, onClick, onClear, sho
|
|
|
649
681
|
|
|
650
682
|
declare const VERSION = "0.1.3";
|
|
651
683
|
|
|
652
|
-
export { ActionButton, Badge, type BadgeSize, type BadgeVariant, Button, type ButtonProps, type ButtonSize, type ButtonVariant, Card, ConfirmDialog, type ConfirmDialogOptions, Container, DataTable, DataTableActions, DataTableBody, DataTableCell, DataTableEmptyState, DataTableHeader, DataTableHeaderCell, DataTableLoadingState, DataTableRow, EmptyState, FilterSelect, FilterToggleButton, FormInput, FormSection, Grid, IconButtonWithCount, InfoBox, Link, type LinkProps, LoadingSpinner, MobileSearchLayout, Modal, PageHeader, RefreshButton, SearchCard, SearchCardContent, SearchCardHeader, SearchInput, SharedTooltip, SidebarNavItem, type SidebarNavItemProps, Skeleton, SkeletonCard, SkeletonEnvironmentsList, SkeletonForm, SkeletonGameCard, SkeletonGameServerCard, SkeletonGameServerCards, SkeletonGameServerTable, SkeletonGamesTable, SkeletonItem, SkeletonList, SkeletonNodeCard, SkeletonNodeCards, SkeletonNodeTable, SkeletonRecentActivity, SkeletonSearchCard, SkeletonStats, SkeletonTable, SkeletonTenantCard, SkeletonUserCard, SmartDropdown, SmartSelect, Spinner, StatusBadge, StickyActionsColumn, Switch, type SwitchVariant, Typography, VERSION, ViewToggle, useConfirmDialog };
|
|
684
|
+
export { ActionButton, Badge, type BadgeSize, type BadgeVariant, Button, type ButtonProps, type ButtonSize, type ButtonVariant, Card, ConfirmDialog, type ConfirmDialogOptions, Container, DangerNotice, DataTable, DataTableActions, DataTableBody, DataTableCell, DataTableEmptyState, DataTableHeader, DataTableHeaderCell, DataTableLoadingState, DataTableRow, EmptyState, FilterSelect, FilterToggleButton, FormInput, FormSection, Grid, IconButtonWithCount, InfoBox, InfoNotice, Link, type LinkProps, LoadingSpinner, MobileSearchLayout, Modal, Notice, PageHeader, RefreshButton, SearchCard, SearchCardContent, SearchCardHeader, SearchInput, SharedTooltip, SidebarNavItem, type SidebarNavItemProps, Skeleton, SkeletonCard, SkeletonEnvironmentsList, SkeletonForm, SkeletonGameCard, SkeletonGameServerCard, SkeletonGameServerCards, SkeletonGameServerTable, SkeletonGamesTable, SkeletonItem, SkeletonList, SkeletonNodeCard, SkeletonNodeCards, SkeletonNodeTable, SkeletonRecentActivity, SkeletonSearchCard, SkeletonStats, SkeletonTable, SkeletonTenantCard, SkeletonUserCard, SmartDropdown, SmartSelect, Spinner, StatusBadge, StickyActionsColumn, SuccessNotice, Switch, type SwitchVariant, Typography, VERSION, ViewToggle, WarningNotice, useConfirmDialog };
|
package/dist/index.d.ts
CHANGED
|
@@ -202,8 +202,37 @@ interface InfoBoxProps {
|
|
|
202
202
|
children: React__default.ReactNode;
|
|
203
203
|
variant?: 'default' | 'warning' | 'info' | 'success' | 'danger';
|
|
204
204
|
className?: string;
|
|
205
|
+
/** Compact mode for inline usage */
|
|
206
|
+
compact?: boolean;
|
|
205
207
|
}
|
|
206
|
-
|
|
208
|
+
/**
|
|
209
|
+
* @deprecated Use Notice component instead. InfoBox is now a wrapper around Notice.
|
|
210
|
+
*/
|
|
211
|
+
declare function InfoBox({ title, children, variant, className, compact, }: InfoBoxProps): react_jsx_runtime.JSX.Element;
|
|
212
|
+
|
|
213
|
+
interface NoticeProps {
|
|
214
|
+
/** Main content of the notice */
|
|
215
|
+
children: React__default.ReactNode;
|
|
216
|
+
/** Variant type of the notice */
|
|
217
|
+
variant?: 'info' | 'warning' | 'success' | 'danger' | 'default';
|
|
218
|
+
/** Icon to display. If not provided, uses default for variant */
|
|
219
|
+
icon?: React__default.ReactNode;
|
|
220
|
+
/** Optional title */
|
|
221
|
+
title?: string | React__default.ReactNode;
|
|
222
|
+
/** Additional CSS classes */
|
|
223
|
+
className?: string;
|
|
224
|
+
/** Whether to show the icon */
|
|
225
|
+
showIcon?: boolean;
|
|
226
|
+
/** Custom content to the right (e.g., a toggle button) */
|
|
227
|
+
action?: React__default.ReactNode;
|
|
228
|
+
/** Compact mode for inline usage (less padding, smaller text) */
|
|
229
|
+
compact?: boolean;
|
|
230
|
+
}
|
|
231
|
+
declare function Notice({ children, variant, icon, title, className, showIcon, action, compact, }: NoticeProps): react_jsx_runtime.JSX.Element;
|
|
232
|
+
declare function InfoNotice(props: Omit<NoticeProps, 'variant'>): react_jsx_runtime.JSX.Element;
|
|
233
|
+
declare function WarningNotice(props: Omit<NoticeProps, 'variant'>): react_jsx_runtime.JSX.Element;
|
|
234
|
+
declare function SuccessNotice(props: Omit<NoticeProps, 'variant'>): react_jsx_runtime.JSX.Element;
|
|
235
|
+
declare function DangerNotice(props: Omit<NoticeProps, 'variant'>): react_jsx_runtime.JSX.Element;
|
|
207
236
|
|
|
208
237
|
interface LinkProps extends AnchorHTMLAttributes<HTMLAnchorElement> {
|
|
209
238
|
href: string;
|
|
@@ -302,11 +331,12 @@ declare function SmartDropdown({ isOpen, onClose, trigger, children, className,
|
|
|
302
331
|
interface Option {
|
|
303
332
|
value: string;
|
|
304
333
|
label: string;
|
|
305
|
-
description?:
|
|
334
|
+
description?: React.ReactNode;
|
|
306
335
|
icon?: React.ReactNode;
|
|
307
336
|
metadata?: {
|
|
308
337
|
isDefault?: boolean;
|
|
309
338
|
args?: string[];
|
|
339
|
+
commandType?: 'command' | 'bash' | 'sh' | 'powershell';
|
|
310
340
|
};
|
|
311
341
|
}
|
|
312
342
|
interface SmartSelectProps {
|
|
@@ -315,19 +345,21 @@ interface SmartSelectProps {
|
|
|
315
345
|
onChange: (value: string | string[]) => void;
|
|
316
346
|
placeholder?: string;
|
|
317
347
|
className?: string;
|
|
318
|
-
description?:
|
|
348
|
+
description?: React.ReactNode;
|
|
319
349
|
disabled?: boolean;
|
|
320
350
|
multiple?: boolean;
|
|
321
|
-
width?: number;
|
|
351
|
+
width?: number | 'auto' | 'fit-content';
|
|
322
352
|
searchable?: boolean;
|
|
323
353
|
keepOpen?: boolean;
|
|
324
354
|
clearable?: boolean;
|
|
355
|
+
variant?: 'default' | 'compact';
|
|
356
|
+
renderSelected?: (option: Option) => React.ReactNode;
|
|
325
357
|
onOpen?: () => void;
|
|
326
358
|
onClose?: () => void;
|
|
327
359
|
onSearch?: (search: string) => void;
|
|
328
360
|
isLoading?: boolean;
|
|
329
361
|
}
|
|
330
|
-
declare function SmartSelect({ options, value, onChange, placeholder, className, description, disabled, multiple, width, searchable, keepOpen, clearable, onOpen, onClose, onSearch, isLoading, }: SmartSelectProps): react_jsx_runtime.JSX.Element;
|
|
362
|
+
declare function SmartSelect({ options, value, onChange, placeholder, className, description, disabled, multiple, width, searchable, keepOpen, clearable, variant, renderSelected, onOpen, onClose, onSearch, isLoading, }: SmartSelectProps): react_jsx_runtime.JSX.Element;
|
|
331
363
|
|
|
332
364
|
interface SkeletonProps {
|
|
333
365
|
className?: string;
|
|
@@ -649,4 +681,4 @@ declare function IconButtonWithCount({ icon, label, count, onClick, onClear, sho
|
|
|
649
681
|
|
|
650
682
|
declare const VERSION = "0.1.3";
|
|
651
683
|
|
|
652
|
-
export { ActionButton, Badge, type BadgeSize, type BadgeVariant, Button, type ButtonProps, type ButtonSize, type ButtonVariant, Card, ConfirmDialog, type ConfirmDialogOptions, Container, DataTable, DataTableActions, DataTableBody, DataTableCell, DataTableEmptyState, DataTableHeader, DataTableHeaderCell, DataTableLoadingState, DataTableRow, EmptyState, FilterSelect, FilterToggleButton, FormInput, FormSection, Grid, IconButtonWithCount, InfoBox, Link, type LinkProps, LoadingSpinner, MobileSearchLayout, Modal, PageHeader, RefreshButton, SearchCard, SearchCardContent, SearchCardHeader, SearchInput, SharedTooltip, SidebarNavItem, type SidebarNavItemProps, Skeleton, SkeletonCard, SkeletonEnvironmentsList, SkeletonForm, SkeletonGameCard, SkeletonGameServerCard, SkeletonGameServerCards, SkeletonGameServerTable, SkeletonGamesTable, SkeletonItem, SkeletonList, SkeletonNodeCard, SkeletonNodeCards, SkeletonNodeTable, SkeletonRecentActivity, SkeletonSearchCard, SkeletonStats, SkeletonTable, SkeletonTenantCard, SkeletonUserCard, SmartDropdown, SmartSelect, Spinner, StatusBadge, StickyActionsColumn, Switch, type SwitchVariant, Typography, VERSION, ViewToggle, useConfirmDialog };
|
|
684
|
+
export { ActionButton, Badge, type BadgeSize, type BadgeVariant, Button, type ButtonProps, type ButtonSize, type ButtonVariant, Card, ConfirmDialog, type ConfirmDialogOptions, Container, DangerNotice, DataTable, DataTableActions, DataTableBody, DataTableCell, DataTableEmptyState, DataTableHeader, DataTableHeaderCell, DataTableLoadingState, DataTableRow, EmptyState, FilterSelect, FilterToggleButton, FormInput, FormSection, Grid, IconButtonWithCount, InfoBox, InfoNotice, Link, type LinkProps, LoadingSpinner, MobileSearchLayout, Modal, Notice, PageHeader, RefreshButton, SearchCard, SearchCardContent, SearchCardHeader, SearchInput, SharedTooltip, SidebarNavItem, type SidebarNavItemProps, Skeleton, SkeletonCard, SkeletonEnvironmentsList, SkeletonForm, SkeletonGameCard, SkeletonGameServerCard, SkeletonGameServerCards, SkeletonGameServerTable, SkeletonGamesTable, SkeletonItem, SkeletonList, SkeletonNodeCard, SkeletonNodeCards, SkeletonNodeTable, SkeletonRecentActivity, SkeletonSearchCard, SkeletonStats, SkeletonTable, SkeletonTenantCard, SkeletonUserCard, SmartDropdown, SmartSelect, Spinner, StatusBadge, StickyActionsColumn, SuccessNotice, Switch, type SwitchVariant, Typography, VERSION, ViewToggle, WarningNotice, useConfirmDialog };
|