@dimasbaguspm/versaur 0.0.47 → 0.0.49
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/assets/styles.css +14 -6
- package/dist/js/forms/index.js +12 -14
- package/dist/js/image-rectangle-K9jmTTED.js +2607 -0
- package/dist/js/index.js +66 -68
- package/dist/js/layouts/index.js +8 -9
- package/dist/js/navigation/index.js +1 -1
- package/dist/js/overlays/index.js +2 -2
- package/dist/js/primitive/index.js +21 -20
- package/dist/js/tabs-I4n6MLAv.js +210 -0
- package/dist/js/templates/index.js +1 -0
- package/dist/js/time-picker-input-jJBtyikv.js +1562 -0
- package/dist/js/{tooltip-D6fUigp2.js → tooltip-nZW9TUz3.js} +293 -297
- package/dist/js/{top-bar-Dx0JVXms.js → top-bar-BMw3gFYA.js} +292 -247
- package/dist/types/forms/checkbox-input/checkbox-input.d.ts +1 -1
- package/dist/types/forms/checkbox-input/types.d.ts +11 -14
- package/dist/types/forms/chip-multiple-input/chip-multiple-input.atoms.d.ts +2 -2
- package/dist/types/forms/chip-multiple-input/chip-multiple-input.d.ts +1 -1
- package/dist/types/forms/chip-multiple-input/types.d.ts +15 -14
- package/dist/types/forms/chip-single-input/chip-single-input.atoms.d.ts +1 -1
- package/dist/types/forms/chip-single-input/chip-single-input.d.ts +1 -1
- package/dist/types/forms/chip-single-input/types.d.ts +15 -14
- package/dist/types/forms/date-single-picker-input/types.d.ts +10 -0
- package/dist/types/forms/index.d.ts +0 -2
- package/dist/types/forms/pin-field/pin-field.d.ts +2 -2
- package/dist/types/forms/pin-field/types.d.ts +16 -28
- package/dist/types/forms/select-input/index.d.ts +1 -1
- package/dist/types/forms/select-input/select-input.atoms.d.ts +16 -0
- package/dist/types/forms/select-input/select-input.d.ts +4 -7
- package/dist/types/forms/select-input/types.d.ts +32 -9
- package/dist/types/forms/selectable-multiple-input/selectable-multiple-input.d.ts +1 -1
- package/dist/types/forms/selectable-multiple-input/types.d.ts +20 -3
- package/dist/types/forms/selectable-single-input/selectable-single-input.d.ts +1 -1
- package/dist/types/forms/selectable-single-input/types.d.ts +20 -3
- package/dist/types/forms/switch-input/switch-input.atoms.d.ts +7 -8
- package/dist/types/forms/switch-input/switch-input.d.ts +5 -1
- package/dist/types/forms/switch-input/types.d.ts +10 -33
- package/dist/types/forms/text-input/text-input.d.ts +2 -2
- package/dist/types/forms/text-input/types.d.ts +0 -7
- package/dist/types/forms/textarea-input/textarea-input.d.ts +3 -3
- package/dist/types/forms/textarea-input/types.d.ts +33 -18
- package/dist/types/layouts/index.d.ts +1 -2
- package/dist/types/layouts/page-content/index.d.ts +1 -1
- package/dist/types/layouts/page-content/page-content.d.ts +5 -11
- package/dist/types/layouts/page-content/types.d.ts +29 -9
- package/dist/types/layouts/page-header/types.d.ts +13 -0
- package/dist/types/navigation/tabs/tabs.atoms.d.ts +3 -2
- package/dist/types/navigation/tabs/types.d.ts +5 -13
- package/dist/types/navigation/tabs/use-tab-indicator.d.ts +8 -8
- package/dist/types/overlays/drawer/drawer.atoms.d.ts +18 -8
- package/dist/types/overlays/drawer/drawer.d.ts +5 -5
- package/dist/types/overlays/drawer/types.d.ts +11 -15
- package/dist/types/primitive/button/button.d.ts +5 -0
- package/dist/types/primitive/button/types.d.ts +24 -11
- package/dist/types/primitive/button-anchor/button-anchor.d.ts +9 -0
- package/dist/types/primitive/button-anchor/index.d.ts +2 -0
- package/dist/types/primitive/button-anchor/types.d.ts +35 -0
- package/dist/types/primitive/button-icon/button-icon.d.ts +6 -0
- package/dist/types/primitive/button-icon/types.d.ts +21 -10
- package/dist/types/primitive/filter-chip/types.d.ts +0 -10
- package/dist/types/primitive/index.d.ts +1 -0
- package/dist/types/templates/index.d.ts +1 -0
- package/dist/types/templates/pin-verifier-drawer/index.d.ts +2 -0
- package/dist/types/templates/pin-verifier-drawer/pin-verifier-drawer.atoms.d.ts +7 -0
- package/dist/types/templates/pin-verifier-drawer/pin-verifier-drawer.d.ts +10 -0
- package/dist/types/templates/pin-verifier-drawer/types.d.ts +97 -0
- package/dist/utils/enforce-subpath-import.js +2 -3
- package/package.json +5 -1
- package/dist/js/image-rectangle-B4nXH4Q5.js +0 -2581
- package/dist/js/tabs-BAzThVka.js +0 -291
- package/dist/js/time-picker-input-JBEgDV2V.js +0 -2049
- package/dist/types/forms/segment-multiple-input/index.d.ts +0 -2
- package/dist/types/forms/segment-multiple-input/segment-multiple-input.atoms.d.ts +0 -12
- package/dist/types/forms/segment-multiple-input/segment-multiple-input.d.ts +0 -7
- package/dist/types/forms/segment-multiple-input/types.d.ts +0 -55
- package/dist/types/forms/segment-single-input/index.d.ts +0 -2
- package/dist/types/forms/segment-single-input/segment-single-input.atoms.d.ts +0 -11
- package/dist/types/forms/segment-single-input/segment-single-input.d.ts +0 -7
- package/dist/types/forms/segment-single-input/types.d.ts +0 -55
- package/dist/types/layouts/page-layout/index.d.ts +0 -2
- package/dist/types/layouts/page-layout/page-layout.d.ts +0 -8
- package/dist/types/layouts/page-layout/types.d.ts +0 -20
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { NumericKeypadProps } from './types';
|
|
3
|
+
/**
|
|
4
|
+
* NumericKeypad - A 3x4 grid of numbers (1-9, 0) with delete button
|
|
5
|
+
* Provides touch-friendly input for PIN entry in drawer mode
|
|
6
|
+
*/
|
|
7
|
+
export declare const NumericKeypad: React.FC<NumericKeypadProps>;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { PinVerifierDrawerProps } from './types';
|
|
3
|
+
/**
|
|
4
|
+
* PinVerifierDrawer - A responsive PIN verification component
|
|
5
|
+
*
|
|
6
|
+
* Adapts between Modal (desktop) and Drawer (mobile) based on the `as` prop.
|
|
7
|
+
* For drawer mode, includes a numeric keypad for touch-friendly PIN entry.
|
|
8
|
+
* Provides complete PIN verification flow with proper accessibility and UX.
|
|
9
|
+
*/
|
|
10
|
+
export declare const PinVerifierDrawer: React.FC<PinVerifierDrawerProps>;
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { DrawerProps } from '../../overlays/drawer';
|
|
3
|
+
import { ModalRootProps } from '../../overlays/modal';
|
|
4
|
+
/**
|
|
5
|
+
* Pin verifier display mode
|
|
6
|
+
*/
|
|
7
|
+
export type PinVerifierAs = 'modal' | 'drawer';
|
|
8
|
+
/**
|
|
9
|
+
* Base props for PinVerifierDrawer component
|
|
10
|
+
*/
|
|
11
|
+
export interface PinVerifierDrawerProps {
|
|
12
|
+
/**
|
|
13
|
+
* Whether the PIN verifier is open
|
|
14
|
+
*/
|
|
15
|
+
isOpen: boolean;
|
|
16
|
+
/**
|
|
17
|
+
* Callback fired when the verifier should close
|
|
18
|
+
*/
|
|
19
|
+
onClose: () => void;
|
|
20
|
+
/**
|
|
21
|
+
* Title to display in the header
|
|
22
|
+
*/
|
|
23
|
+
title?: ReactNode;
|
|
24
|
+
/**
|
|
25
|
+
* Current PIN value (controlled)
|
|
26
|
+
*/
|
|
27
|
+
value?: string;
|
|
28
|
+
/**
|
|
29
|
+
* Default PIN value (uncontrolled)
|
|
30
|
+
*/
|
|
31
|
+
defaultValue?: string;
|
|
32
|
+
/**
|
|
33
|
+
* Callback fired when PIN value changes
|
|
34
|
+
*/
|
|
35
|
+
onChange?: (value: string) => void;
|
|
36
|
+
/**
|
|
37
|
+
* Callback fired when PIN is completed (6 digits entered)
|
|
38
|
+
*/
|
|
39
|
+
onComplete?: (value: string) => void;
|
|
40
|
+
/**
|
|
41
|
+
* Callback fired when verify button is clicked
|
|
42
|
+
*/
|
|
43
|
+
onVerify?: (value: string) => void;
|
|
44
|
+
/**
|
|
45
|
+
* Whether to show PIN as dots for security
|
|
46
|
+
*/
|
|
47
|
+
secure?: boolean;
|
|
48
|
+
/**
|
|
49
|
+
* Whether the component is in a loading state
|
|
50
|
+
*/
|
|
51
|
+
loading?: boolean;
|
|
52
|
+
/**
|
|
53
|
+
* Error message for invalid PIN
|
|
54
|
+
*/
|
|
55
|
+
error?: ReactNode;
|
|
56
|
+
/**
|
|
57
|
+
* Whether to show the numeric keypad (only shown for drawer mode)
|
|
58
|
+
*/
|
|
59
|
+
showKeypad?: boolean;
|
|
60
|
+
/**
|
|
61
|
+
* Display mode - 'modal' for desktop, 'drawer' for mobile
|
|
62
|
+
*/
|
|
63
|
+
as?: PinVerifierAs;
|
|
64
|
+
/**
|
|
65
|
+
* Custom verify button text
|
|
66
|
+
*/
|
|
67
|
+
verifyButtonText?: string;
|
|
68
|
+
/**
|
|
69
|
+
* Additional props passed to Modal (when as='modal')
|
|
70
|
+
*/
|
|
71
|
+
modalProps?: Partial<Omit<ModalRootProps, 'isOpen' | 'onClose' | 'children'>>;
|
|
72
|
+
/**
|
|
73
|
+
* Additional props passed to Drawer (when as='drawer')
|
|
74
|
+
*/
|
|
75
|
+
drawerProps?: Partial<Omit<DrawerProps, 'isOpen' | 'onClose' | 'children'>>;
|
|
76
|
+
}
|
|
77
|
+
/**
|
|
78
|
+
* Props for the numeric keypad
|
|
79
|
+
*/
|
|
80
|
+
export interface NumericKeypadProps {
|
|
81
|
+
/**
|
|
82
|
+
* Callback fired when a number is pressed
|
|
83
|
+
*/
|
|
84
|
+
onNumberPress: (digit: string) => void;
|
|
85
|
+
/**
|
|
86
|
+
* Callback fired when delete/backspace is pressed
|
|
87
|
+
*/
|
|
88
|
+
onDelete: () => void;
|
|
89
|
+
/**
|
|
90
|
+
* Whether the keypad is disabled
|
|
91
|
+
*/
|
|
92
|
+
disabled?: boolean;
|
|
93
|
+
/**
|
|
94
|
+
* Size of the keypad buttons
|
|
95
|
+
*/
|
|
96
|
+
size?: 'sm' | 'md' | 'lg';
|
|
97
|
+
}
|
|
@@ -16,8 +16,6 @@ const symbolToSubpath = {
|
|
|
16
16
|
"PriceInput": "forms",
|
|
17
17
|
"RadioInput": "forms",
|
|
18
18
|
"SearchInput": "forms",
|
|
19
|
-
"SegmentMultipleInput": "forms",
|
|
20
|
-
"SegmentSingleInput": "forms",
|
|
21
19
|
"SelectInput": "forms",
|
|
22
20
|
"SelectableMultipleInput": "forms",
|
|
23
21
|
"SelectableSingleInput": "forms",
|
|
@@ -33,7 +31,6 @@ const symbolToSubpath = {
|
|
|
33
31
|
"FormLayout": "layouts",
|
|
34
32
|
"PageContent": "layouts",
|
|
35
33
|
"PageHeader": "layouts",
|
|
36
|
-
"PageLayout": "layouts",
|
|
37
34
|
"PageLoader": "layouts",
|
|
38
35
|
"SideBar": "layouts",
|
|
39
36
|
"TopBar": "layouts",
|
|
@@ -54,6 +51,7 @@ const symbolToSubpath = {
|
|
|
54
51
|
"Badge": "primitive",
|
|
55
52
|
"Brand": "primitive",
|
|
56
53
|
"Button": "primitive",
|
|
54
|
+
"ButtonAnchor": "primitive",
|
|
57
55
|
"ButtonIcon": "primitive",
|
|
58
56
|
"ButtonMenu": "primitive",
|
|
59
57
|
"ButtonMenuIcon": "primitive",
|
|
@@ -73,6 +71,7 @@ const symbolToSubpath = {
|
|
|
73
71
|
"Tile": "primitive",
|
|
74
72
|
"SnackbarsProvider": "providers",
|
|
75
73
|
"useSnackbars": "providers",
|
|
74
|
+
"PinVerifierDrawer": "templates",
|
|
76
75
|
"cn": "utils",
|
|
77
76
|
"cva": "utils",
|
|
78
77
|
"createVariants": "utils",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dimasbaguspm/versaur",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.49",
|
|
4
4
|
"description": "React UI library with Tailwind CSS",
|
|
5
5
|
"author": "Dimas Bagus Prayogo Mukti<dimas.bagus.pm@gmail.com>",
|
|
6
6
|
"license": "MIT",
|
|
@@ -42,6 +42,10 @@
|
|
|
42
42
|
"import": "./dist/js/providers/index.js",
|
|
43
43
|
"types": "./dist/types/providers/index.d.ts"
|
|
44
44
|
},
|
|
45
|
+
"./templates": {
|
|
46
|
+
"import": "./dist/js/templates/index.js",
|
|
47
|
+
"types": "./dist/types/templates/index.d.ts"
|
|
48
|
+
},
|
|
45
49
|
"./styles.css": "./dist/assets/styles.css",
|
|
46
50
|
"./eslint-subpath-import": "./dist/utils/enforce-subpath-import.js"
|
|
47
51
|
},
|