spotlibs-components 0.1.10 → 0.1.11

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.
Files changed (87) hide show
  1. package/dist/{chunk-OGJBPTUP.mjs → chunk-F6KSEYVB.mjs} +3 -3
  2. package/dist/{chunk-OGJBPTUP.mjs.map → chunk-F6KSEYVB.mjs.map} +1 -1
  3. package/dist/chunk-UFE7HFT2.mjs +60 -0
  4. package/dist/chunk-UFE7HFT2.mjs.map +1 -0
  5. package/dist/{chunk-NXFLMH2Q.mjs → chunk-YOSPWY5K.mjs} +3 -4
  6. package/dist/{chunk-NXFLMH2Q.mjs.map → chunk-YOSPWY5K.mjs.map} +1 -1
  7. package/dist/{atoms → components/atoms}/icons/index.mjs +2 -2
  8. package/dist/components/index.d.mts +449 -0
  9. package/dist/components/index.mjs +7241 -0
  10. package/dist/components/index.mjs.map +1 -0
  11. package/dist/{mui → components/mui}/index.mjs +1 -1
  12. package/dist/components/types.d.mts +4 -0
  13. package/dist/{types-B0iF5xX8.d.mts → types-BkrxwBFm.d.mts} +329 -178
  14. package/dist/utils/index.d.mts +186 -0
  15. package/dist/utils/index.mjs +477 -0
  16. package/dist/utils/index.mjs.map +1 -0
  17. package/package.json +12 -2
  18. package/src/utils/admin-kuota-nasional/constant.js +95 -0
  19. package/src/utils/asset.js +10 -0
  20. package/src/utils/booleanUtils.js +19 -0
  21. package/src/utils/briguna-digital/constant.js +12 -0
  22. package/src/utils/compress.js +24 -0
  23. package/src/utils/compressImage.js +20 -0
  24. package/src/utils/constants.js +20 -0
  25. package/src/utils/cookies.js +102 -0
  26. package/src/utils/crypto.js +104 -0
  27. package/src/utils/decodeString.js +17 -0
  28. package/src/utils/disableFormElements.js +19 -0
  29. package/src/utils/excelUtils.js +60 -0
  30. package/src/utils/exception.js +86 -0
  31. package/src/utils/formatString.js +151 -0
  32. package/src/utils/formatters/account.js +98 -0
  33. package/src/utils/formatters/currency.js +125 -0
  34. package/src/utils/formatters/date.js +219 -0
  35. package/src/utils/formatters/index.js +47 -0
  36. package/src/utils/formatters/string.js +114 -0
  37. package/src/utils/generateImportExcel.js +546 -0
  38. package/src/utils/generateTimestamp.js +4 -0
  39. package/src/utils/handleApiError.js +17 -0
  40. package/src/utils/index.js +92 -0
  41. package/src/utils/json.js +55 -0
  42. package/src/utils/localStorage.js +8 -0
  43. package/src/utils/logger.js +46 -0
  44. package/src/utils/schema/globalSchema.js +10 -0
  45. package/src/utils/signature.js +75 -0
  46. package/src/utils/specifics/korporasi/prakarsaKorporasiUtils.js +87 -0
  47. package/src/utils/specifics/mikro/validationMaintenanceAgunanUtils.js +214 -0
  48. package/src/utils/static-data/korporasi/prakarsa/analisa-risiko-kredit-nasabah/analisa-kinerja-keuangan/listStaticData.js +290 -0
  49. package/src/utils/static-data/korporasi/prakarsa/appendix/proyeksi-laporan-arus-kas/listStaticData.js +7 -0
  50. package/src/utils/static-data/korporasi/prakarsa/appendix/proyeksi-laporan-keuangan/listStaticData.js +75 -0
  51. package/src/utils/static-data/korporasi/prakarsa/appendix/total-exposure-group/listStaticData.js +7 -0
  52. package/src/utils/static-data/korporasi/prakarsa/create/listStaticData.js +21 -0
  53. package/src/utils/static-data/korporasi/prakarsa/generals/listExcelConfigData.js +11 -0
  54. package/src/utils/static-data/korporasi/prakarsa/pengajuan-fasilitas-kredit/fasilitas-kredit/listStaticData.js +69 -0
  55. package/src/utils/static-data/korporasi-internasional/eksternal/listStaticData.js +193 -0
  56. package/src/utils/static-data/korporasi-internasional/master/listStaticData.js +24 -0
  57. package/src/utils/static-data/korporasi-internasional/uji-kepatuhan/listStaticData.js +250 -0
  58. package/src/utils/status.js +160 -0
  59. package/src/utils/store/adminKuotaNasional.js +7 -0
  60. package/src/utils/store/authStore.js +13 -0
  61. package/src/utils/store/bankGaransiStore.js +10 -0
  62. package/src/utils/store/korporasi/approval/interface/interfaceStore.js +10 -0
  63. package/src/utils/store/korporasi/general/generalKorporasiStore.js +13 -0
  64. package/src/utils/store/korporasi/loan-disbursement/loanDisbursementStore.js +77 -0
  65. package/src/utils/store/korporasi/prakarsa/fasilitas-kredit/fasilitasKreditStore.js +141 -0
  66. package/src/utils/store/migrasi-mandiri/migrasiMandiriStore.js +53 -0
  67. package/src/utils/store/monitoring-konsumer/monitoring-leads-KPP/monitoring-leads-kpp-internal.js +34 -0
  68. package/src/utils/store/prakarsaBankGaransiStore.js +21 -0
  69. package/src/utils/store/prognosa-crr/settingPrognosaROStore.js +9 -0
  70. package/src/utils/store/prognosaRMStore.js +30 -0
  71. package/src/utils/store/restrukStore.js +26 -0
  72. package/src/utils/store/verificationAccessLink.js +11 -0
  73. package/src/utils/store/warkat-bg-wholesale/warkatBgWholesaleStore.js +22 -0
  74. package/src/utils/stringUtils.js +226 -0
  75. package/src/utils/tipeBank.js +14 -0
  76. package/dist/index.css +0 -32
  77. package/dist/index.css.map +0 -1
  78. package/dist/index.d.mts +0 -1726
  79. package/dist/index.mjs +0 -18560
  80. package/dist/index.mjs.map +0 -1
  81. package/dist/types.d.mts +0 -4
  82. /package/dist/{atoms → components/atoms}/icons/index.d.mts +0 -0
  83. /package/dist/{atoms → components/atoms}/icons/index.mjs.map +0 -0
  84. /package/dist/{mui → components/mui}/index.d.mts +0 -0
  85. /package/dist/{mui → components/mui}/index.mjs.map +0 -0
  86. /package/dist/{types.mjs → components/types.mjs} +0 -0
  87. /package/dist/{types.mjs.map → components/types.mjs.map} +0 -0
@@ -4,21 +4,28 @@ import { SxProps } from '@mui/material/styles';
4
4
  import { Control, RegisterOptions } from 'react-hook-form';
5
5
 
6
6
  interface BaseAlertProps {
7
- variant?: string;
8
- type?: string;
9
- title?: React.ReactNode;
7
+ /** Alert color variant */
8
+ variant?: "default" | "error" | "info" | "success" | "warning";
9
+ /** MUI Alert variant type */
10
+ type?: "standard" | "filled" | "outlined";
11
+ /** Alert title */
12
+ title?: string;
13
+ /** Alert content */
10
14
  children?: React.ReactNode;
11
- icon?: React.ReactNode;
15
+ /** Icon element or component. If not provided, no icon is shown. */
16
+ icon?: React.ReactNode | React.ComponentType<any>;
17
+ /** Custom background color override */
12
18
  color?: string;
13
- sx?: any;
19
+ /** MUI sx overrides */
20
+ sx?: SxProps;
21
+ /** Close handler. If provided, close button is shown. */
14
22
  onClose?: () => void;
15
- childrenStyle?: React.CSSProperties;
23
+ /** sx overrides for children wrapper */
24
+ childrenSx?: SxProps;
16
25
  [key: string]: any;
17
26
  }
18
27
 
19
- declare function BaseAlert(
20
- props: BaseAlertProps,
21
- ): React.ReactElement | null;
28
+ declare function BaseAlert(props: BaseAlertProps): React.ReactElement;
22
29
 
23
30
  interface PrimitiveColorType {
24
31
  color_overlay: string;
@@ -118,14 +125,23 @@ interface DerivedColorType {
118
125
  color_bg_surface: string;
119
126
  color_bg_inverse: string;
120
127
  color_bg_disabled: string;
128
+
129
+ color_bg_brand_primary_strong: string;
121
130
  color_bg_brand_primary: string;
122
131
  color_bg_brand_primary_subtle: string;
132
+ color_bg_brand_secondary_strong: string;
123
133
  color_bg_brand_secondary: string;
124
134
  color_bg_brand_secondary_subtle: string;
135
+
136
+ color_bg_success_strong: string;
125
137
  color_bg_success: string;
126
138
  color_bg_success_subtle: string;
139
+
140
+ color_bg_danger_strong: string;
127
141
  color_bg_danger: string;
128
142
  color_bg_danger_subtle: string;
143
+
144
+ color_bg_warning_strong: string;
129
145
  color_bg_warning: string;
130
146
  color_bg_warning_subtle: string;
131
147
 
@@ -165,30 +181,53 @@ interface DerivedColorType {
165
181
 
166
182
  declare const DerivedColor: DerivedColorType;
167
183
 
168
- interface TypographyColorToken {
169
- value: string;
170
- token: string;
171
- alias: string;
184
+ type TypographyVariant =
185
+ | "h1"
186
+ | "h2"
187
+ | "h3"
188
+ | "h4"
189
+ | "h5"
190
+ | "h6"
191
+ | "header1_regular"
192
+ | "header1_semibold"
193
+ | "header1_bold"
194
+ | "header2_regular"
195
+ | "header2_semibold"
196
+ | "header2_bold"
197
+ | "body1_regular"
198
+ | "body2_regular"
199
+ | "caption_regular";
200
+
201
+ type TypographyColor =
202
+ | "default"
203
+ | "subtle"
204
+ | "disabled"
205
+ | "placeholder"
206
+ | "inverse"
207
+ | "primary"
208
+ | "secondary"
209
+ | "success"
210
+ | "danger"
211
+ | "warning";
212
+
213
+ interface VariantStyleEntry {
214
+ fontSize: string;
215
+ fontWeight: number;
172
216
  }
173
217
 
174
- declare const VariantStyles: Record<
175
- string,
176
- {
177
- fontSize: string;
178
- fontWeight: number;
179
- }
180
- >;
218
+ declare const VariantStyles: Record<TypographyVariant, VariantStyleEntry>;
181
219
 
182
220
  interface TypographyProps {
183
- variant?: string;
221
+ /** Format: "variant.color" e.g. "body1_regular.default" */
222
+ variant?: `${TypographyVariant}.${TypographyColor}` | TypographyVariant;
223
+ /** Content */
184
224
  children?: React.ReactNode;
185
- sx?: React.CSSProperties & Record<string, unknown>;
225
+ /** MUI sx overrides */
226
+ sx?: SxProps;
186
227
  [key: string]: any;
187
228
  }
188
229
 
189
- declare function Typography(
190
- props: TypographyProps,
191
- ): React.ReactElement | null;
230
+ declare function BaseTypography(props: TypographyProps): React.ReactElement | null;
192
231
 
193
232
  declare const SpacingToken: {
194
233
  spacing0: string;
@@ -279,12 +318,10 @@ type ShadowLevel = keyof ShadowMap;
279
318
  interface ShadowTokenProps {
280
319
  /** Elevation level */
281
320
  level?: ShadowLevel;
282
- /** HTML element or component to render */
283
- as?: React.ElementType;
284
- /** Inline style overrides */
285
- style?: React.CSSProperties;
286
321
  /** Content */
287
322
  children?: React.ReactNode;
323
+ /** MUI sx overrides */
324
+ sx?: SxProps;
288
325
  [key: string]: any;
289
326
  }
290
327
 
@@ -301,17 +338,15 @@ interface RadiusMap {
301
338
 
302
339
  declare const Radius: RadiusMap;
303
340
 
304
- type RadiusKey = keyof RadiusMap;
341
+ type RadiusLevel = keyof RadiusMap;
305
342
 
306
343
  interface RadiusTokenProps {
307
- /** Radius token key */
308
- radius?: RadiusKey;
309
- /** HTML element or component to render */
310
- as?: React.ElementType;
311
- /** Inline style overrides */
312
- style?: React.CSSProperties;
344
+ /** Radius level */
345
+ radius?: RadiusLevel;
313
346
  /** Content */
314
347
  children?: React.ReactNode;
348
+ /** MUI sx overrides */
349
+ sx?: SxProps;
315
350
  [key: string]: any;
316
351
  }
317
352
 
@@ -324,14 +359,20 @@ interface BaseButtonProps {
324
359
  children?: React.ReactNode;
325
360
  /** Visual style variant */
326
361
  variant?: "fill" | "outline" | "text" | "fab" | "ellipse-fill" | "ellipse-outline";
327
- /** Color key from PrimitiveColor or a raw CSS color string */
328
- color?: string;
362
+ /** Semantic color preset */
363
+ color?: "primary" | "secondary" | "success" | "warning" | "danger";
364
+ /** Custom color key from PrimitiveColor. Overrides `color` prop when set. */
365
+ customColor?: keyof typeof PrimitiveColor | null;
329
366
  /** Button size */
330
367
  size?: "large" | "small";
331
368
  /** Disabled state */
332
369
  disabled?: boolean;
333
370
  /** Icon element rendered before children */
334
- icon?: React.ReactNode;
371
+ startIcon?: React.ReactNode;
372
+ /** Icon element rendered after children */
373
+ endIcon?: React.ReactNode;
374
+ /** Button width */
375
+ width?: string;
335
376
  /** MUI sx overrides */
336
377
  sx?: SxProps;
337
378
  [key: string]: any;
@@ -339,62 +380,36 @@ interface BaseButtonProps {
339
380
 
340
381
  declare function BaseButton(props: BaseButtonProps): React.ReactElement;
341
382
 
342
- interface BaseCardDataItem {
343
- icon?: React.ReactNode;
344
- count?: number | string;
345
- title?: string;
346
- update?: string;
347
- }
348
-
349
- interface BaseCardProps {
350
- /** Card layout type */
351
- type?: "default" | "notification" | "with-header" | "summary";
352
- /** Card body content */
353
- children?: React.ReactNode;
383
+ interface BaseSkeletonProps {
384
+ /**
385
+ * Skeleton shape variant.
386
+ * - `text` — single line of text placeholder
387
+ * - `rectangular` — rectangle block placeholder
388
+ * - `rounded` — rectangle with border-radius
389
+ * - `circular` — circle placeholder (avatar, icon)
390
+ */
391
+ variant?: "text" | "rectangular" | "rounded" | "circular";
392
+ /**
393
+ * Animation type.
394
+ * - `pulse` — fading animation (default)
395
+ * - `wave` — wave sweep animation
396
+ * - `none` — no animation (static)
397
+ */
398
+ animation?: "pulse" | "wave" | "none";
399
+ /** Width of the skeleton. Accepts number (px) or string (e.g. "100%", "200px") */
400
+ width?: number | string;
401
+ /** Height of the skeleton. Accepts number (px) or string (e.g. "40px", "1.2em") */
402
+ height?: number | string;
403
+ /** Number of skeleton lines to render. If > 1, renders stacked skeletons. */
404
+ count?: number;
405
+ /** Gap between stacked skeletons when count > 1. Default is SpacingToken.spacing2 */
406
+ gap?: string | number;
354
407
  /** MUI sx overrides */
355
408
  sx?: SxProps;
356
- /** Icon displayed in the card */
357
- icon?: React.ReactNode;
358
- /** Label text */
359
- label?: string;
360
- /** Title text */
361
- title?: string;
362
- /** Subtitle text */
363
- subtitle?: string;
364
- /** Data items for summary card type */
365
- dataList?: BaseCardDataItem[];
366
- /** Last update date string */
367
- updateDate?: string;
368
- /** Bold the count icon */
369
- boldCountIcon?: boolean;
370
- /** Bold the count value */
371
- boldCount?: boolean;
372
- /** Bold the title */
373
- boldTitle?: boolean;
374
- /** Bold the update text */
375
- boldUpdate?: boolean;
376
- /** Custom icon element for the header */
377
- iconHeader?: React.ReactElement;
378
- /** Card background color */
379
- backgroundColor?: string;
380
- /** Title color */
381
- colorTitlte?: string;
382
- /** Nominal/count color */
383
- colorNominal?: string;
384
- /** Show/hide icon */
385
- displayIcon?: boolean;
386
- /** Number format type */
387
- formatNumber?: "currency" | "nominal" | string;
388
- /** Count text color */
389
- colorCount?: string;
390
- /** Header background color */
391
- headerBackgroundColor?: string;
392
- /** Enable collapse toggle */
393
- isCollapsible?: boolean;
394
409
  [key: string]: any;
395
410
  }
396
411
 
397
- declare function BaseCard(props: BaseCardProps): React.ReactElement;
412
+ declare function BaseSkeleton(props: BaseSkeletonProps): React.ReactElement;
398
413
 
399
414
  interface BaseSwitchProps {
400
415
  /** Current switch state */
@@ -411,32 +426,112 @@ interface BaseSwitchProps {
411
426
 
412
427
  declare function BaseSwitch(props: BaseSwitchProps): React.ReactElement;
413
428
 
429
+ interface BaseCardProps {
430
+ /** Card variant type */
431
+ variant?: "default" | "with-header" | "with-header-footer";
432
+ /** Card body content */
433
+ children?: React.ReactNode;
434
+ /** Header background color preset */
435
+ color?: "primary" | "secondary" | "success" | "warning" | "danger";
436
+ /** Header title text */
437
+ title?: string;
438
+ /** Header subtitle text */
439
+ subtitle?: string;
440
+ /** Bold the title */
441
+ boldTitle?: boolean;
442
+ /** Bold the subtitle */
443
+ boldSubtitle?: boolean;
444
+ /** Show/hide subtitle */
445
+ showSubtitle?: boolean;
446
+ /** Enable collapse/expand on header click */
447
+ isCollapsible?: boolean;
448
+ /** Icon element before title in header */
449
+ startIcon?: React.ReactNode;
450
+ /** Icon element after title in header */
451
+ endIcon?: React.ReactNode;
452
+ /** Show/hide startIcon */
453
+ showStartIcon?: boolean;
454
+ /** Show/hide endIcon */
455
+ showEndIcon?: boolean;
456
+ /** Footer content (only for with-header-footer variant) */
457
+ footer?: React.ReactNode;
458
+ /** Enable watermark overlay on content area */
459
+ isWatermark?: boolean;
460
+ /** Watermark text (e.g. "000000 / Nama Lengkap") */
461
+ watermarkText?: string;
462
+ /** MUI sx overrides */
463
+ sx?: SxProps;
464
+ [key: string]: any;
465
+ }
466
+
467
+ declare function BaseCard(props: BaseCardProps): React.ReactElement;
468
+
469
+ interface BaseSnackbarPosition {
470
+ vertical: "top" | "bottom";
471
+ horizontal: "left" | "center" | "right";
472
+ }
473
+
474
+ interface BaseSnackbarProps {
475
+ /** Whether the snackbar is open */
476
+ open?: boolean;
477
+ /** Close handler */
478
+ onClose?: (event?: React.SyntheticEvent | Event, reason?: string) => void;
479
+ /** Snackbar message content */
480
+ message?: string;
481
+ /** Color variant */
482
+ variant?: "success" | "error" | "info" | "warning" | "default";
483
+ /** Auto hide duration in milliseconds */
484
+ duration?: number;
485
+ /** Anchor origin position */
486
+ position?: BaseSnackbarPosition;
487
+ /** Icon element or component. If not provided, no icon is shown. */
488
+ icon?: React.ReactNode | React.ComponentType<any>;
489
+ /** MUI sx overrides */
490
+ sx?: SxProps;
491
+ [key: string]: any;
492
+ }
493
+
494
+ declare function BaseSnackbar(props: BaseSnackbarProps): React.ReactElement;
495
+
414
496
  interface BaseCheckboxOption {
497
+ /** Label yang ditampilkan */
415
498
  label: React.ReactNode;
499
+ /** Nilai opsi */
416
500
  value: string;
501
+ /** Nonaktifkan opsi ini */
417
502
  disabled?: boolean;
418
503
  [key: string]: any;
419
504
  }
420
505
 
421
506
  interface BaseCheckboxSharedProps {
507
+ /** Daftar opsi checkbox (untuk mode group) */
422
508
  options: BaseCheckboxOption[];
509
+ /** Label untuk mode single checkbox */
423
510
  label?: React.ReactNode;
511
+ /** Nonaktifkan semua checkbox */
424
512
  disabled?: boolean;
513
+ /** Posisi label relatif terhadap checkbox */
425
514
  labelPlacement?: "top" | "bottom" | "start" | "end";
515
+ /** Tampilkan checkbox secara horizontal */
426
516
  isHorizontal?: boolean;
427
- sx?: any;
517
+ /** Custom styles via MUI sx prop */
518
+ sx?: SxProps;
428
519
  [key: string]: any;
429
520
  }
430
521
 
431
522
  interface BaseCheckboxSingleProps extends Omit<BaseCheckboxSharedProps, "options"> {
432
523
  options?: undefined;
524
+ /** Nilai checked untuk single checkbox */
433
525
  checked?: boolean;
526
+ /** Callback ketika nilai berubah (single mode) */
434
527
  onChange?: (checked: boolean, event?: React.ChangeEvent<HTMLInputElement>) => void;
435
528
  }
436
529
 
437
530
  interface BaseCheckboxGroupProps extends BaseCheckboxSharedProps {
438
531
  options: BaseCheckboxOption[];
532
+ /** Array nilai yang dipilih (group mode) */
439
533
  checked?: string[];
534
+ /** Callback ketika nilai berubah (group mode) */
440
535
  onChange?: (newValue: string[]) => void;
441
536
  }
442
537
 
@@ -608,33 +703,38 @@ declare function BaseDatatable<T = Record<string, any>>(
608
703
  ): ReactNode;
609
704
 
610
705
  interface BaseDatePickerProps {
611
- type?: string;
612
-
613
- name?: string;
614
- control?: any;
615
-
706
+ /** Picker mode */
707
+ type?: "single" | "day" | "datetime" | "range" | "month" | "year" | "time";
708
+ /** Field name for React Hook Form */
709
+ name: string;
710
+ /** Control object from react-hook-form */
711
+ control: any;
712
+ /** Default selected value */
616
713
  defaultValue?: any;
617
-
618
- title?: React.ReactNode;
619
- subtitle?: React.ReactNode;
620
-
621
- className?: string;
622
- titleClassName?: string;
623
- subtitleClassName?: string;
624
-
714
+ /** Label title above input */
715
+ title?: string;
716
+ /** Optional subtitle */
717
+ subtitle?: string;
718
+ /** Input placeholder text */
625
719
  placeholder?: string;
626
-
627
- minDate?: any;
628
- maxDate?: any;
629
-
720
+ /** Minimum selectable date */
721
+ minDate?: Date | string;
722
+ /** Maximum selectable date */
723
+ maxDate?: Date | string;
724
+ /** Disable picker interaction */
630
725
  isDisabled?: boolean;
726
+ /** Allow user to clear selected value */
631
727
  clearable?: boolean;
728
+ /** Allow manual input editing (range only) */
632
729
  editableDateInputs?: boolean;
633
-
730
+ /** Display format for value */
634
731
  format?: string;
635
-
636
- onChange?: (date: any) => void;
637
-
732
+ /** How the calendar popup is triggered */
733
+ openBy?: "field" | "icon" | "both";
734
+ /** MUI sx overrides for the wrapper */
735
+ sx?: SxProps;
736
+ /** Custom onChange handler */
737
+ onChange?: (value: any) => void;
638
738
  [key: string]: any;
639
739
  }
640
740
 
@@ -642,26 +742,50 @@ declare function BaseDatePicker(
642
742
  props: BaseDatePickerProps,
643
743
  ): React.ReactElement | null;
644
744
 
745
+ interface DropdownOption {
746
+ label: string;
747
+ value: string;
748
+ disabled?: boolean;
749
+ [key: string]: any;
750
+ }
751
+
645
752
  interface BaseDropdownProps {
646
- name?: string;
647
- control?: any;
648
- options?: any[];
649
- loadOptions?: any;
753
+ /** Field name for react-hook-form */
754
+ name: string;
755
+ /** Control object from react-hook-form */
756
+ control: any;
757
+ /** Static options list */
758
+ options?: DropdownOption[];
759
+ /** Async options loader function */
760
+ loadOptions?: (inputValue: string) => Promise<DropdownOption[]>;
761
+ /** Enable multi select mode */
650
762
  isMulti?: boolean;
763
+ /** Enable search input */
651
764
  isSearchable?: boolean;
765
+ /** Show selected values as chips (multi only) */
652
766
  showChip?: boolean;
767
+ /** Show Select All checkbox (multi only) */
653
768
  showSelectAll?: boolean;
654
- title?: React.ReactNode;
655
- subtitle?: React.ReactNode;
656
- className?: string;
657
- titleClassName?: string;
658
- subtitleClassName?: string;
769
+ /** Label title */
770
+ title?: string;
771
+ /** Subtitle text */
772
+ subtitle?: string;
773
+ /** Default selected value */
659
774
  defaultValue?: any;
775
+ /** Disable dropdown */
660
776
  isDisabled?: boolean;
777
+ /** Allow clearing value */
661
778
  isClearable?: boolean;
779
+ /** Limit max height with scroll */
662
780
  preventOverflow?: boolean;
781
+ /** Colors for multi-value tags */
663
782
  optionColors?: string[];
783
+ /** Dropdown variant */
664
784
  variant?: "select" | "checkbox";
785
+ /** MUI sx overrides for wrapper */
786
+ sx?: SxProps;
787
+ /** Custom onChange handler */
788
+ onChange?: (value: any) => void;
665
789
  [key: string]: any;
666
790
  }
667
791
 
@@ -670,33 +794,46 @@ declare function BaseDropdown(
670
794
  ): React.ReactElement;
671
795
 
672
796
  interface BaseDropzoneSettings {
673
- allowedExtensions?: Record<string, any>;
797
+ /** Ekstensi file yang diizinkan (format react-dropzone accept) */
798
+ allowedExtensions?: Record<string, string[]>;
799
+ /** Ukuran maksimal file dalam MB */
674
800
  maxSize?: number;
801
+ /** Jumlah maksimal file yang dapat diupload */
675
802
  maxFiles?: number;
803
+ /** Tampilkan preview gambar */
676
804
  isImagePreview?: boolean;
805
+ /** Tipe tampilan preview */
677
806
  previewType?: "grid" | "list";
678
807
  }
679
808
 
680
809
  interface BaseDropzoneLabels {
810
+ /** Label judul di atas dropzone */
681
811
  title?: React.ReactNode;
812
+ /** Teks utama di dalam area dropzone */
682
813
  dropzoneTitle?: string;
814
+ /** Label pada tombol pilih file */
683
815
  titleButton?: string;
816
+ /** Teks keterangan format file yang diizinkan */
684
817
  allowedFileLabel?: string;
685
818
  }
686
819
 
687
820
  interface BaseDropzoneCallbacks {
688
- uploadFile?: (file: File) => void | Promise<any>;
689
- removeFile?: (file: File) => void;
690
- customError?: (error: unknown) => void;
821
+ /** Callback ketika file berhasil diupload */
822
+ uploadFile?: (files: Array<{ source: string; originName: string; type: string; size: number }>) => void;
823
+ /** Callback ketika file dihapus */
824
+ removeFile?: (fileName: string) => void;
825
+ /** Pesan error kustom dari luar komponen */
826
+ customError?: string | null;
691
827
  }
692
828
 
693
829
  interface BaseDropzoneProps {
830
+ /** Upload otomatis setelah file dipilih */
694
831
  autoUpload?: boolean;
695
-
832
+ /** Pengaturan dropzone */
696
833
  settings?: BaseDropzoneSettings;
697
-
834
+ /** Label-label yang ditampilkan */
698
835
  labels?: BaseDropzoneLabels;
699
-
836
+ /** Callback functions */
700
837
  callbacks?: BaseDropzoneCallbacks;
701
838
  }
702
839
 
@@ -707,38 +844,35 @@ declare function BaseDropzone(
707
844
  interface BaseRadioOption {
708
845
  label: React.ReactNode;
709
846
  value: any;
710
- disabled?: boolean;
847
+ isDisabled?: boolean;
711
848
  [key: string]: any;
712
849
  }
713
850
 
714
851
  interface BaseRadioButtonProps {
852
+ /** Nama field untuk react-hook-form */
715
853
  name?: string;
854
+ /** Control dari useForm() */
716
855
  control?: any;
856
+ /** Nilai awal yang dipilih */
717
857
  defaultValue?: any;
718
-
858
+ /** Label di atas radio group */
719
859
  label?: React.ReactNode;
860
+ /** Daftar opsi radio */
720
861
  options?: BaseRadioOption[];
721
-
722
- /* ================= TYPOGRAPHY ================= */
862
+ /** Variant typography untuk label */
723
863
  labelVariant?: string;
864
+ /** Variant typography untuk pesan error */
724
865
  errorVariant?: string;
725
-
726
- /* ================= LAYOUT ================= */
866
+ /** Orientasi layout radio group */
727
867
  orientation?: "vertical" | "horizontal";
728
-
729
- /* ================= COLOR TOKEN ================= */
868
+ /** Token warna untuk radio yang dipilih */
730
869
  radioColorToken?: string;
731
-
732
- /* ================= STATE ================= */
870
+ /** Nonaktifkan semua opsi */
733
871
  isDisabled?: boolean;
734
-
735
- /* ================= CLASS ================= */
736
- className?: string;
737
- titleClassName?: string;
738
- fieldClassName?: string;
739
-
740
- /* ================= ERROR ================= */
872
+ /** Gunakan error state helper untuk nested field names */
741
873
  useErrorStateHelper?: boolean;
874
+ /** Custom styles via MUI sx prop */
875
+ sx?: SxProps;
742
876
 
743
877
  [key: string]: any;
744
878
  }
@@ -774,42 +908,59 @@ interface BaseStepperProps {
774
908
  orientation?: "horizontal" | "vertical";
775
909
  /** Stepper visual variant */
776
910
  variant?: "simple" | "dashboard";
911
+ /** MUI sx overrides for wrapper */
912
+ sx?: SxProps;
777
913
  }
778
914
 
779
915
  declare function BaseStepper(props: BaseStepperProps): React.ReactElement;
780
916
 
781
917
  interface BaseTextFieldProps {
782
- name?: string;
783
- control?: any;
784
-
918
+ /** Field name for react-hook-form binding */
919
+ name: string;
920
+ /** Control object from react-hook-form */
921
+ control: any;
922
+ /** Default value for the field */
785
923
  defaultValue?: any;
786
- className?: string;
787
- titleClassName?: string;
788
-
924
+ /** Label title displayed above the input */
925
+ title?: string;
926
+ /** Maximum character length */
789
927
  maxLength?: number;
928
+ /** Show "Maksimal X Karakter" helper text */
790
929
  showLength?: boolean;
791
-
930
+ /** Show character counter (e.g. 5/20) */
931
+ showCountHelper?: boolean;
932
+ /** Only allow numeric input (0-9) */
792
933
  isNumericOnly?: boolean;
934
+ /** Only allow alphanumeric input (a-z, A-Z, 0-9) */
793
935
  isAlphaNumericOnly?: boolean;
936
+ /** Only allow alphabetic input (a-z, A-Z) */
794
937
  isAlphaOnly?: boolean;
795
-
938
+ /** Additional special characters to allow */
796
939
  allowedSpecialCharacters?: string;
940
+ /** Special characters to disallow */
797
941
  dontAllowedSpecialCharacters?: string;
798
-
799
- isAlphaNumericWithUnderscore?: boolean;
800
-
942
+ /** Disable the input */
801
943
  isDisabled?: boolean;
944
+ /** Prevent paste action */
802
945
  isCantPaste?: boolean;
803
-
804
- result?: any;
946
+ /** Result text shown below the input */
947
+ result?: React.ReactNode;
948
+ /** Color for the result text */
805
949
  resultColor?: string;
806
-
950
+ /** Disallow spaces */
807
951
  noSpaceAllowed?: boolean;
808
-
809
- showCountHelper?: boolean;
810
-
952
+ /** Input mask pattern (use 'x' for editable slots, e.g. "0xxx-xxxx-xxxx") */
811
953
  textMask?: string;
812
-
954
+ /** MUI InputProps (startAdornment, endAdornment, sx, etc.) */
955
+ InputProps?: Record<string, any>;
956
+ /** Native input props (min, max, step, etc.) */
957
+ inputProps?: Record<string, any>;
958
+ /** MUI sx overrides for the wrapper Box */
959
+ sx?: SxProps;
960
+ /** Input placeholder text */
961
+ placeholder?: string;
962
+ /** Input type (text, password, email, etc.) */
963
+ type?: string;
813
964
  [key: string]: any;
814
965
  }
815
966
 
@@ -818,26 +969,28 @@ declare function BaseTextField(
818
969
  ): React.ReactElement | null;
819
970
 
820
971
  interface TextFieldUploadProps {
972
+ /** Nama field untuk react-hook-form */
821
973
  name?: string;
974
+ /** Control dari useForm() */
822
975
  control?: any;
823
-
976
+ /** Nilai awal field */
824
977
  defaultValue?: string;
825
-
978
+ /** Label di atas field */
826
979
  title?: React.ReactNode;
827
-
980
+ /** Ekstensi file yang diterima (contoh: ".pdf,.jpg") */
828
981
  accept?: string;
982
+ /** Ukuran maksimal file dalam MB */
829
983
  maxSize?: number;
830
-
984
+ /** Nonaktifkan field */
831
985
  isDisabled?: boolean;
832
-
986
+ /** Label pada tombol upload */
833
987
  buttonLabel?: string;
988
+ /** Posisi tombol upload relatif terhadap input */
834
989
  buttonPosition?: "start" | "end";
835
-
990
+ /** Callback ketika file dipilih */
991
+ uploadFile?: (fileName: string, file: File | null) => void;
992
+ /** Posisi ikon pada tombol upload */
836
993
  iconPosition?: "start" | "end";
837
-
838
- uploadFile?: (file: File) => void | Promise<any>;
839
-
840
- [key: string]: any;
841
994
  }
842
995
 
843
996
  declare function TextFieldUpload(
@@ -867,12 +1020,8 @@ interface BaseTextAreaProps {
867
1020
  exactLength?: number;
868
1021
  /** Batas maksimal karakter */
869
1022
  maxLength?: number;
870
- /** CSS class untuk wrapper */
871
- className?: string;
872
1023
  /** Label di atas field */
873
1024
  title?: string;
874
- /** CSS class untuk title */
875
- titleClassName?: string;
876
1025
  /** Nonaktifkan field */
877
1026
  isDisabled?: boolean;
878
1027
  /** Aktifkan TinyMCE rich-text editor (default: plain MUI textarea) */
@@ -885,6 +1034,8 @@ interface BaseTextAreaProps {
885
1034
  value: string,
886
1035
  meta: Record<string, string>,
887
1036
  ) => void;
1037
+ /** Custom styles via MUI sx prop */
1038
+ sx?: SxProps;
888
1039
 
889
1040
  [key: string]: any;
890
1041
  }
@@ -992,4 +1143,4 @@ declare function BaseModalOTP(
992
1143
  props: BaseModalOTPProps,
993
1144
  ): React.ReactElement | null;
994
1145
 
995
- export { type BaseStepperDashboardStep as $, type BaseCheckboxProps as A, BaseAlert as B, CONTENT_SPACING_TOKENS as C, DerivedColor as D, type BaseDatatableAlign as E, type BaseDatatableColumn as F, type BaseDatatableFeatures as G, type BaseDatatableHeaderCell as H, type BaseDatatableLayout as I, type BaseDatatablePagination as J, type BaseDatatableProps as K, type BaseDatatableSelection as L, type BaseDatatableSortPayload as M, type BaseDatatableSortState as N, type BaseDatePickerProps as O, PrimitiveColor as P, type BaseDropdownProps as Q, Radius as R, Shadow as S, TextFieldUpload as T, type BaseDropzoneProps as U, VariantStyles as V, type BaseModalOTPProps as W, type BaseModalProps as X, type BaseModalStepperProps as Y, type BaseModalStepperStep as Z, type BaseRadioButtonProps as _, BaseButton as a, type BaseStepperProps as a0, type BaseStepperSimpleStep as a1, type BaseSwitchProps as a2, type BaseTextAreaProps as a3, type BaseTextFieldProps as a4, type ContentSpacingProps as a5, type DerivedColorType as a6, type PrimitiveColorType as a7, type RadiusKey as a8, type RadiusMap as a9, type RadiusTokenProps as aa, type ShadowElevation as ab, type ShadowLevel as ac, type ShadowMap as ad, type ShadowTokenProps as ae, type SpacingProps as af, type TextFieldUploadProps as ag, type TypographyColorToken as ah, type TypographyProps as ai, BaseCard as b, BaseCheckbox as c, BaseDatatable as d, BaseDatePicker as e, BaseDropdown as f, BaseDropzone as g, BaseModal as h, BaseModalOTP as i, BaseModalStepper as j, BaseRadioButton as k, BaseStepper as l, BaseSwitch as m, BaseTextArea as n, BaseTextField as o, ContentSpacing as p, RadiusToken as q, ShadowToken as r, Spacing as s, SpacingToken as t, Typography as u, type BaseAlertProps as v, type BaseButtonProps as w, type BaseCardDataItem as x, type BaseCardProps as y, type BaseCheckboxOption as z };
1146
+ export { type BaseRadioButtonProps as $, type BaseCheckboxOption as A, BaseAlert as B, CONTENT_SPACING_TOKENS as C, DerivedColor as D, type BaseCheckboxProps as E, type BaseDatatableAlign as F, type BaseDatatableColumn as G, type BaseDatatableFeatures as H, type BaseDatatableHeaderCell as I, type BaseDatatableLayout as J, type BaseDatatablePagination as K, type BaseDatatableProps as L, type BaseDatatableSelection as M, type BaseDatatableSortPayload as N, type BaseDatatableSortState as O, PrimitiveColor as P, type BaseDatePickerProps as Q, Radius as R, Shadow as S, TextFieldUpload as T, type BaseDropdownProps as U, VariantStyles as V, type BaseDropzoneProps as W, type BaseModalOTPProps as X, type BaseModalProps as Y, type BaseModalStepperProps as Z, type BaseModalStepperStep as _, BaseButton as a, type BaseSkeletonProps as a0, type BaseSnackbarPosition as a1, type BaseSnackbarProps as a2, type BaseStepperDashboardStep as a3, type BaseStepperProps as a4, type BaseStepperSimpleStep as a5, type BaseSwitchProps as a6, type BaseTextAreaProps as a7, type BaseTextFieldProps as a8, type ContentSpacingProps as a9, type DerivedColorType as aa, type PrimitiveColorType as ab, type RadiusLevel as ac, type RadiusMap as ad, type RadiusTokenProps as ae, type ShadowElevation as af, type ShadowLevel as ag, type ShadowMap as ah, type ShadowTokenProps as ai, type SpacingProps as aj, type TextFieldUploadProps as ak, type TypographyColor as al, type TypographyProps as am, type TypographyVariant as an, BaseCard as b, BaseCheckbox as c, BaseDatatable as d, BaseDatePicker as e, BaseDropdown as f, BaseDropzone as g, BaseModal as h, BaseModalOTP as i, BaseModalStepper as j, BaseRadioButton as k, BaseSkeleton as l, BaseSnackbar as m, BaseStepper as n, BaseSwitch as o, BaseTextArea as p, BaseTextField as q, BaseTypography as r, ContentSpacing as s, RadiusToken as t, ShadowToken as u, Spacing as v, SpacingToken as w, type BaseAlertProps as x, type BaseButtonProps as y, type BaseCardProps as z };