josenanodev-react-components-library 1.10.4 → 1.11.0

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 (35) hide show
  1. package/README.md +212 -4
  2. package/dist/cjs/index.js +1 -1
  3. package/dist/cjs/types/components/AlertModal/AlertModal.d.ts +14 -0
  4. package/dist/cjs/types/components/AlertModal/index.d.ts +1 -0
  5. package/dist/cjs/types/components/BubbleMenu/BubbleMenu.d.ts +6 -0
  6. package/dist/cjs/types/components/CalendarDatePicker/CalendarDatePicker.d.ts +13 -0
  7. package/dist/cjs/types/components/InputBoxWithConfirmation/InputBoxWithConfirmation.d.ts +12 -0
  8. package/dist/cjs/types/components/IntegerControl/IntegerControl.d.ts +5 -0
  9. package/dist/cjs/types/components/LabeledInput/LabeledInput.d.ts +11 -0
  10. package/dist/cjs/types/components/Modal/Modal.d.ts +6 -0
  11. package/dist/cjs/types/components/Multicalendar/types.d.ts +27 -1
  12. package/dist/cjs/types/components/ScreenSteps/ScreenSteps.d.ts +8 -0
  13. package/dist/cjs/types/components/ScrollSnapGallery/ScrollSnapGallery.d.ts +11 -0
  14. package/dist/cjs/types/components/StackedCards/StackedCards.d.ts +9 -0
  15. package/dist/cjs/types/components/index.d.ts +1 -0
  16. package/dist/cjs/types/index.d.ts +1 -0
  17. package/dist/esm/index.js +1 -1
  18. package/dist/esm/types/components/AlertModal/AlertModal.d.ts +14 -0
  19. package/dist/esm/types/components/AlertModal/index.d.ts +1 -0
  20. package/dist/esm/types/components/BubbleMenu/BubbleMenu.d.ts +6 -0
  21. package/dist/esm/types/components/CalendarDatePicker/CalendarDatePicker.d.ts +13 -0
  22. package/dist/esm/types/components/InputBoxWithConfirmation/InputBoxWithConfirmation.d.ts +12 -0
  23. package/dist/esm/types/components/IntegerControl/IntegerControl.d.ts +5 -0
  24. package/dist/esm/types/components/LabeledInput/LabeledInput.d.ts +11 -0
  25. package/dist/esm/types/components/Modal/Modal.d.ts +6 -0
  26. package/dist/esm/types/components/Multicalendar/types.d.ts +27 -1
  27. package/dist/esm/types/components/ScreenSteps/ScreenSteps.d.ts +8 -0
  28. package/dist/esm/types/components/ScrollSnapGallery/ScrollSnapGallery.d.ts +11 -0
  29. package/dist/esm/types/components/StackedCards/StackedCards.d.ts +9 -0
  30. package/dist/esm/types/components/index.d.ts +1 -0
  31. package/dist/esm/types/index.d.ts +1 -0
  32. package/dist/index.d.ts +141 -2
  33. package/package.json +2 -3
  34. package/dist/cjs/types/stories/CalendarDatePickerMask.d.ts +0 -4
  35. package/dist/esm/types/stories/CalendarDatePickerMask.d.ts +0 -4
@@ -1,27 +1,51 @@
1
1
  export interface MulticalendarProps {
2
+ /** Stable DOM and sessionStorage id. Use a unique value per calendar instance. */
2
3
  multicalendarId: string;
4
+ /** Component rendered inside every visible date/resource grid cell. */
3
5
  ReactCellChildren: ReactCellChildren;
6
+ /** Component rendered for each visible row in the left resource axis. */
4
7
  ReactListElementChildren: ReactListElementChildren;
8
+ /** Resource ids displayed as rows in the calendar. */
5
9
  listElementsIdsArray: string[] | number[];
10
+ /** Language used by toolbar controls and date labels. */
6
11
  language?: "es_ES" | "en_EN";
12
+ /** Whether dates before today are available in the horizontal range. */
7
13
  pastDatesVisible?: boolean;
14
+ /** Width in pixels for each date cell. */
8
15
  cellsWidth?: number;
16
+ /** Height in pixels for each resource row. */
9
17
  cellsHeight?: number;
18
+ /** Width in pixels of the left resource axis. */
10
19
  verticalAxisWidth?: number;
20
+ /** Reserved height setting for the top date axis. */
11
21
  horizontalAxisHeight?: number;
22
+ /** Initial number of past days rendered in the scrollable range. */
12
23
  pastDaysInitialQuantity?: number;
24
+ /** Initial number of future days rendered in the scrollable range. */
13
25
  futureDaysInitialQuantity?: number;
26
+ /** Extra horizontal cells rendered outside the viewport to reduce blank space while scrolling. */
14
27
  chunkRenderX?: number;
28
+ /** Extra vertical rows rendered outside the viewport to reduce blank space while scrolling. */
15
29
  chunkRenderY?: number;
30
+ /** Auto-scrolls while dragging near grid edges. */
16
31
  authomaticScrollOnDraggingOverEdges?: boolean;
32
+ /** Extends the date range when users scroll near the horizontal boundaries. */
17
33
  dynamicDaysQuantity?: boolean;
34
+ /** Debounce time in milliseconds before callsOnScrollingStops runs. */
18
35
  waitTimeForCalls?: number;
36
+ /** Called once after the initial visible ids and dates are available. */
19
37
  callsOnInitialView?: (visibleIds: string[] | number[], visibleDates: Date[]) => void;
38
+ /** Called after scrolling settles with currently visible ids and dates. */
20
39
  callsOnScrollingStops?: (visibleIds: string[] | number[], visibleDates: Date[]) => void;
40
+ /** Extra controls rendered in the toolbar beside date navigation. */
21
41
  aditionalControlsComponents?: React.ReactNode | React.ReactNode[];
42
+ /** Custom content rendered in the upper-left corner above the resource axis. */
22
43
  upperLeftComponent?: React.ReactNode;
44
+ /** Persists scroll position in sessionStorage using multicalendarId. */
23
45
  autoSavePosition?: boolean;
46
+ /** Called whenever the vertical scroll position changes. */
24
47
  onScrollTopChanges?: (scrollTop: number) => void;
48
+ /** Called whenever the horizontal scroll position changes. */
25
49
  onScrollLeftChanges?: (scrollLeft: number) => void;
26
50
  }
27
51
  export interface RenderCoordinates {
@@ -33,12 +57,14 @@ export type ReactListElementChildren = React.ElementType<ListElementChildrenProp
33
57
  export type CellChildrenProps = {
34
58
  [key: string]: any;
35
59
  } & {
36
- /**Date in SQL format, i.e. 1993-03-29 */
60
+ /** Date in SQL format, for example 1993-03-29. */
37
61
  date: string;
62
+ /** Row/resource id for the cell being rendered. */
38
63
  listElementId: string | number;
39
64
  };
40
65
  export type ListElementChildrenProps = {
41
66
  [key: string]: any;
42
67
  } & {
68
+ /** Row/resource id for the list element being rendered. */
43
69
  listElementId: string | number;
44
70
  };
@@ -1,14 +1,22 @@
1
1
  import React from "react";
2
2
  type Step = {
3
+ /** React panel rendered for this step. */
3
4
  component: React.ReactNode;
5
+ /** Text rendered inside the step navigation marker. */
4
6
  innerText: string;
7
+ /** Optional descriptive text rendered above the active step panel. */
5
8
  outterText?: string;
6
9
  };
7
10
  type ScreenStepsProps = {
11
+ /** Ordered list of steps in the flow. */
8
12
  steps: Step[];
13
+ /** Initial active step index. */
9
14
  defaultStep?: number;
15
+ /** Called when the active step changes through user navigation. */
10
16
  onStepChange?: (step: number) => void;
17
+ /** Allows users to click step markers to navigate. */
11
18
  canNavigate?: boolean;
19
+ /** Controlled active step index from the parent. */
12
20
  overrideStep?: number;
13
21
  };
14
22
  declare const ScreenSteps: ({ steps, defaultStep, onStepChange, canNavigate, overrideStep, }: ScreenStepsProps) => React.JSX.Element;
@@ -1,16 +1,27 @@
1
1
  import React from "react";
2
2
  import { IconType } from "react-icons/lib";
3
3
  type ScrollSnapGalleryProps = {
4
+ /** Image URLs rendered as slides. */
4
5
  urls: string[];
6
+ /** Optional alt text array matched by slide index. */
5
7
  alts?: string[];
8
+ /** CSS width applied to the scroll frame. */
6
9
  width?: string;
10
+ /** CSS height applied to the scroll frame. */
7
11
  height?: string;
12
+ /** Icon component used for position indicators. */
8
13
  IndicatorIcon?: IconType;
14
+ /** Number of indicator icons emphasized at one time. */
9
15
  positionIndicatorSize?: number;
16
+ /** Indicator icon size in pixels. */
10
17
  iconSize?: number;
18
+ /** Shows previous and next arrow controls. */
11
19
  showArrows?: boolean;
20
+ /** Inline styles applied to the image frame. */
12
21
  frameStyle?: React.CSSProperties;
22
+ /** Called with the active slide index after scrolling. */
13
23
  onSlideChange?: (index: number) => void;
24
+ /** Automatically advances the gallery every 3 seconds. */
14
25
  autoChange?: boolean;
15
26
  };
16
27
  declare const ScrollSnapGallery: ({ urls, alts, width, height, IndicatorIcon, positionIndicatorSize, iconSize, showArrows, frameStyle, onSlideChange, autoChange, }: ScrollSnapGalleryProps) => React.JSX.Element;
@@ -1,15 +1,24 @@
1
1
  import React from "react";
2
2
  type Card = {
3
+ /** Header content rendered at the top of the card. */
3
4
  title: React.ReactNode;
5
+ /** Main content rendered inside the card body. */
4
6
  content: React.ReactNode;
5
7
  };
6
8
  type StackedCardsProps = {
9
+ /** Cards available in the stack. */
7
10
  cards: Card[];
11
+ /** Initial selected card index. */
8
12
  initialCard: number;
13
+ /** Called when the user selects a different card. */
9
14
  onCardChangeByUser?: (cardIndex: number) => void;
15
+ /** Controlled selected card index from the parent. */
10
16
  overrideSelectedCard?: number;
17
+ /** Stack spread direction in degrees. */
11
18
  stackingOrientation?: number;
19
+ /** Height in pixels for each card. */
12
20
  cardHeight?: number;
21
+ /** Width in pixels for each card. */
13
22
  cardWidth?: number;
14
23
  };
15
24
  declare const StackedCards: ({ cards, initialCard, onCardChangeByUser, overrideSelectedCard, stackingOrientation, cardWidth, cardHeight, }: StackedCardsProps) => React.JSX.Element;
@@ -1,3 +1,4 @@
1
+ export { default as AlertModal } from "./AlertModal";
1
2
  export { default as BubbleMenu } from "./BubbleMenu";
2
3
  export { default as CalendarDatePicker } from "./CalendarDatePicker";
3
4
  export { default as InputBoxWithConfirmation } from "./InputBoxWithConfirmation";
@@ -1,2 +1,3 @@
1
+ import './index.css';
1
2
  export * from './components';
2
3
  export * from './hooks';
package/dist/index.d.ts CHANGED
@@ -1,110 +1,219 @@
1
1
  import React$1, { RefObject } from 'react';
2
2
  import { IconType } from 'react-icons/lib';
3
3
 
4
+ type AlertModalProps = {
5
+ /** Visual intent used to select the default status icon and color. */
6
+ type?: "success" | "error" | "warning" | "info" | "question";
7
+ /** Optional heading displayed above the modal message. */
8
+ title?: string;
9
+ /** Short body copy displayed below the title. */
10
+ message?: string;
11
+ /** Custom content rendered between the message and action buttons. */
12
+ customChildren?: React$1.ReactNode;
13
+ /** Text rendered in the confirm action button. */
14
+ confirmText?: string;
15
+ /** Text rendered in the cancel action button. */
16
+ cancelText?: string;
17
+ /** Shows or hides the confirm action button. */
18
+ confirmButton?: boolean;
19
+ /** Shows or hides the cancel action button. */
20
+ cancelButton?: boolean;
21
+ /** Controlled open state. Set to true to display the modal. */
22
+ overrideOpenState?: boolean;
23
+ /** Prevents closing the modal by clicking the backdrop. */
24
+ forced?: boolean;
25
+ /** Icon size in pixels. */
26
+ iconSize?: number;
27
+ /** Overrides the default icon color for the selected type. */
28
+ iconColor?: string;
29
+ /** Called after the confirm button is clicked. */
30
+ onConfirm?: () => void;
31
+ /** Called after the cancel button is clicked. */
32
+ onCancel?: () => void;
33
+ };
34
+ declare const AlertModal: ({ type, title, message, customChildren, confirmText, cancelText, confirmButton, cancelButton, overrideOpenState, forced, iconSize, iconColor, onConfirm, onCancel, }: AlertModalProps) => React$1.JSX.Element;
35
+
4
36
  type BubbleMenuProps = {
37
+ /** Menu actions displayed when the floating menu is open. */
5
38
  options: {
39
+ /** Icon rendered above the option text. */
6
40
  icon: React$1.ReactNode;
41
+ /** Label rendered inside the circular option button. */
7
42
  text: string;
43
+ /** Controls whether this option is shown. */
8
44
  visible: boolean;
45
+ /** Called after the menu close animation delay. */
9
46
  optionCallback: () => void;
10
47
  }[];
48
+ /** Language used for the floating menu toggle label. */
11
49
  language?: "en" | "es";
12
50
  };
13
51
  declare const BubbleMenu: ({ options, language }: BubbleMenuProps) => React$1.JSX.Element;
14
52
 
15
53
  type CalendarDatePickerProps = {
54
+ /** Selection model used by the calendar. */
16
55
  mode: "single" | "multiple" | "range" | "booking";
56
+ /** Emits the current selection any time selected dates change. */
17
57
  onSelectedDatesChange: (dates: Date[]) => void;
58
+ /** Language used for month, weekday, and Today labels. */
18
59
  language?: "es" | "en";
60
+ /** Custom date rules used to color, disable, cross out, or handle specific days. */
19
61
  customDates?: {
62
+ /** Background color applied to matching dates. */
20
63
  color: string;
64
+ /** Dates affected by this rule. */
21
65
  dates: Date[];
66
+ /** Whether matching dates can be selected. */
22
67
  selectable: boolean;
68
+ /** Renders a diagonal crossed visual treatment on matching dates. */
23
69
  crossed?: boolean;
70
+ /** Clears the current selection when a matching date is clicked. */
24
71
  clearSelectionIfClicked?: boolean;
72
+ /** Optional side effect triggered when a matching date is clicked. */
25
73
  clickSideEffect?: (date: Date) => void;
26
74
  }[];
75
+ /** Earliest date/month the user can navigate to. */
27
76
  minimumDate?: Date;
77
+ /** Latest date/month the user can navigate to. */
28
78
  maximumDate?: Date;
79
+ /** Inline style applied to the calendar root element. */
29
80
  customStyle?: React$1.CSSProperties;
30
81
  };
31
82
  declare const CalendarDatePicker: ({ mode, onSelectedDatesChange, language, customDates, minimumDate, maximumDate, customStyle, }: CalendarDatePickerProps) => React$1.JSX.Element;
32
83
 
33
84
  type InputBoxWithConfirmationPropsType = {
85
+ /** Called with the committed value after confirmation, Enter, or blur. */
34
86
  onConfirmAction: (inputCurrentValue: string) => void;
87
+ /** Native input type used by the inner input. */
35
88
  inputType?: "text" | "number";
89
+ /** Minimum value passed to the native input and enforced for number inputs. */
36
90
  minimumValue?: HTMLInputElement["min"];
91
+ /** Maximum value passed to the native input and enforced for number inputs. */
37
92
  maximumValue?: HTMLInputElement["max"];
93
+ /** Maximum number of accepted characters. */
38
94
  maxLength?: HTMLInputElement["maxLength"];
95
+ /** Placeholder shown while the input is empty. */
39
96
  placeholder?: HTMLInputElement["placeholder"];
97
+ /** Inline styles applied to the outer clickable wrapper. */
40
98
  divWrapperCustomStyle?: React$1.CSSProperties;
99
+ /** Inline styles applied to the inner input element. */
41
100
  inputBoxCustomStyle?: React$1.CSSProperties;
101
+ /** Initial value shown before the user edits. */
42
102
  defaultValue?: string | number;
103
+ /** Controlled value override. Pass null to clear the input. */
43
104
  overrideCurrentValue?: string | number | null;
105
+ /** Shows explicit edit/confirm buttons instead of confirming directly on blur. */
44
106
  showConfirmationButton?: boolean;
107
+ /** Disables editing and hides the confirmation controls. */
45
108
  disabled?: boolean;
46
109
  };
47
110
  declare const InputBoxWithConfirmation: ({ onConfirmAction, inputType, minimumValue, maximumValue, maxLength, placeholder, divWrapperCustomStyle, inputBoxCustomStyle, defaultValue, overrideCurrentValue, showConfirmationButton, disabled, }: InputBoxWithConfirmationPropsType) => React$1.JSX.Element;
48
111
 
49
112
  type IntegerControlProps = {
113
+ /** Called with the clamped value after the user changes it. */
50
114
  onChange: (value: number) => void;
115
+ /** Initial value and visual baseline for the default state. */
51
116
  defaultValue?: number;
117
+ /** Lowest value the control can emit. */
52
118
  minimumValue?: number;
119
+ /** Highest value the control can emit. */
53
120
  maximumValue?: number;
121
+ /** Inline style applied to the root control. */
54
122
  customStyle?: React$1.CSSProperties;
55
123
  };
56
124
  declare const IntegerControl: ({ onChange, defaultValue, minimumValue, maximumValue, customStyle, }: IntegerControlProps) => React$1.JSX.Element;
57
125
 
58
126
  type SpecialType = "credit-card-number" | "expiration-date" | "cvv" | "phone";
59
127
  type LabeledInputProps = {
128
+ /** Floating label displayed over the input. */
60
129
  label: string;
130
+ /** Initial uncontrolled input value. */
61
131
  defaultValue?: string;
132
+ /** Called with the current formatted value whenever the user types. */
62
133
  onChange?: (value: string) => void;
134
+ /** CSS width applied to the root wrapper. */
63
135
  width?: string;
136
+ /** CSS height applied to the root wrapper. */
64
137
  height?: string;
138
+ /** Background color applied to the wrapper and label gap. */
65
139
  backgroundColor?: string;
140
+ /** Text alignment for the native input. */
66
141
  textAlign?: "left" | "center" | "right";
142
+ /** Enables the error border and label color. */
67
143
  highlightError?: boolean;
144
+ /** Error text displayed below the input when highlightError is true. */
68
145
  errorMessage?: string;
146
+ /** Additional props forwarded to the native input element. */
69
147
  inputProps?: React$1.ComponentProps<"input">;
148
+ /** Optional built-in formatter applied while typing. */
70
149
  specialType?: SpecialType;
71
150
  };
72
151
  declare const LabeledInput: ({ label, defaultValue, onChange, width, height, backgroundColor, textAlign, highlightError, errorMessage, inputProps, specialType, }: LabeledInputProps) => React$1.JSX.Element;
73
152
 
74
153
  type ModalProps = {
154
+ /** Content rendered inside the modal panel. */
75
155
  children: React$1.ReactNode;
156
+ /** Controlled open state. Set to true to display the modal. */
76
157
  overrideOpenState?: boolean;
158
+ /** Prevents backdrop clicks from closing the modal. */
77
159
  forced?: boolean;
160
+ /** Called when overrideOpenState opens the modal. */
78
161
  onOpen?: Function;
162
+ /** Called when the modal closes. */
79
163
  onClose?: Function;
164
+ /** Reserved transition duration prop. Current timing is controlled by CSS. */
80
165
  transitionTime?: number;
81
166
  };
82
167
  declare const Modal: ({ children, overrideOpenState, forced, onOpen, onClose, }: ModalProps) => React$1.JSX.Element;
83
168
 
84
169
  interface MulticalendarProps {
170
+ /** Stable DOM and sessionStorage id. Use a unique value per calendar instance. */
85
171
  multicalendarId: string;
172
+ /** Component rendered inside every visible date/resource grid cell. */
86
173
  ReactCellChildren: ReactCellChildren;
174
+ /** Component rendered for each visible row in the left resource axis. */
87
175
  ReactListElementChildren: ReactListElementChildren;
176
+ /** Resource ids displayed as rows in the calendar. */
88
177
  listElementsIdsArray: string[] | number[];
178
+ /** Language used by toolbar controls and date labels. */
89
179
  language?: "es_ES" | "en_EN";
180
+ /** Whether dates before today are available in the horizontal range. */
90
181
  pastDatesVisible?: boolean;
182
+ /** Width in pixels for each date cell. */
91
183
  cellsWidth?: number;
184
+ /** Height in pixels for each resource row. */
92
185
  cellsHeight?: number;
186
+ /** Width in pixels of the left resource axis. */
93
187
  verticalAxisWidth?: number;
188
+ /** Reserved height setting for the top date axis. */
94
189
  horizontalAxisHeight?: number;
190
+ /** Initial number of past days rendered in the scrollable range. */
95
191
  pastDaysInitialQuantity?: number;
192
+ /** Initial number of future days rendered in the scrollable range. */
96
193
  futureDaysInitialQuantity?: number;
194
+ /** Extra horizontal cells rendered outside the viewport to reduce blank space while scrolling. */
97
195
  chunkRenderX?: number;
196
+ /** Extra vertical rows rendered outside the viewport to reduce blank space while scrolling. */
98
197
  chunkRenderY?: number;
198
+ /** Auto-scrolls while dragging near grid edges. */
99
199
  authomaticScrollOnDraggingOverEdges?: boolean;
200
+ /** Extends the date range when users scroll near the horizontal boundaries. */
100
201
  dynamicDaysQuantity?: boolean;
202
+ /** Debounce time in milliseconds before callsOnScrollingStops runs. */
101
203
  waitTimeForCalls?: number;
204
+ /** Called once after the initial visible ids and dates are available. */
102
205
  callsOnInitialView?: (visibleIds: string[] | number[], visibleDates: Date[]) => void;
206
+ /** Called after scrolling settles with currently visible ids and dates. */
103
207
  callsOnScrollingStops?: (visibleIds: string[] | number[], visibleDates: Date[]) => void;
208
+ /** Extra controls rendered in the toolbar beside date navigation. */
104
209
  aditionalControlsComponents?: React.ReactNode | React.ReactNode[];
210
+ /** Custom content rendered in the upper-left corner above the resource axis. */
105
211
  upperLeftComponent?: React.ReactNode;
212
+ /** Persists scroll position in sessionStorage using multicalendarId. */
106
213
  autoSavePosition?: boolean;
214
+ /** Called whenever the vertical scroll position changes. */
107
215
  onScrollTopChanges?: (scrollTop: number) => void;
216
+ /** Called whenever the horizontal scroll position changes. */
108
217
  onScrollLeftChanges?: (scrollLeft: number) => void;
109
218
  }
110
219
  type ReactCellChildren = React.ElementType<CellChildrenProps>;
@@ -112,58 +221,88 @@ type ReactListElementChildren = React.ElementType<ListElementChildrenProps>;
112
221
  type CellChildrenProps = {
113
222
  [key: string]: any;
114
223
  } & {
115
- /**Date in SQL format, i.e. 1993-03-29 */
224
+ /** Date in SQL format, for example 1993-03-29. */
116
225
  date: string;
226
+ /** Row/resource id for the cell being rendered. */
117
227
  listElementId: string | number;
118
228
  };
119
229
  type ListElementChildrenProps = {
120
230
  [key: string]: any;
121
231
  } & {
232
+ /** Row/resource id for the list element being rendered. */
122
233
  listElementId: string | number;
123
234
  };
124
235
 
125
236
  declare const Multicalendar: ({ multicalendarId, ReactCellChildren, ReactListElementChildren, listElementsIdsArray, language, pastDatesVisible, cellsWidth, cellsHeight, verticalAxisWidth, pastDaysInitialQuantity, futureDaysInitialQuantity, chunkRenderX, chunkRenderY, dynamicDaysQuantity, authomaticScrollOnDraggingOverEdges, waitTimeForCalls, callsOnInitialView, callsOnScrollingStops, aditionalControlsComponents, upperLeftComponent, autoSavePosition, onScrollTopChanges, onScrollLeftChanges, }: MulticalendarProps) => React$1.JSX.Element;
126
237
 
127
238
  type Step = {
239
+ /** React panel rendered for this step. */
128
240
  component: React$1.ReactNode;
241
+ /** Text rendered inside the step navigation marker. */
129
242
  innerText: string;
243
+ /** Optional descriptive text rendered above the active step panel. */
130
244
  outterText?: string;
131
245
  };
132
246
  type ScreenStepsProps = {
247
+ /** Ordered list of steps in the flow. */
133
248
  steps: Step[];
249
+ /** Initial active step index. */
134
250
  defaultStep?: number;
251
+ /** Called when the active step changes through user navigation. */
135
252
  onStepChange?: (step: number) => void;
253
+ /** Allows users to click step markers to navigate. */
136
254
  canNavigate?: boolean;
255
+ /** Controlled active step index from the parent. */
137
256
  overrideStep?: number;
138
257
  };
139
258
  declare const ScreenSteps: ({ steps, defaultStep, onStepChange, canNavigate, overrideStep, }: ScreenStepsProps) => React$1.JSX.Element;
140
259
 
141
260
  type ScrollSnapGalleryProps = {
261
+ /** Image URLs rendered as slides. */
142
262
  urls: string[];
263
+ /** Optional alt text array matched by slide index. */
143
264
  alts?: string[];
265
+ /** CSS width applied to the scroll frame. */
144
266
  width?: string;
267
+ /** CSS height applied to the scroll frame. */
145
268
  height?: string;
269
+ /** Icon component used for position indicators. */
146
270
  IndicatorIcon?: IconType;
271
+ /** Number of indicator icons emphasized at one time. */
147
272
  positionIndicatorSize?: number;
273
+ /** Indicator icon size in pixels. */
148
274
  iconSize?: number;
275
+ /** Shows previous and next arrow controls. */
149
276
  showArrows?: boolean;
277
+ /** Inline styles applied to the image frame. */
150
278
  frameStyle?: React$1.CSSProperties;
279
+ /** Called with the active slide index after scrolling. */
151
280
  onSlideChange?: (index: number) => void;
281
+ /** Automatically advances the gallery every 3 seconds. */
152
282
  autoChange?: boolean;
153
283
  };
154
284
  declare const ScrollSnapGallery: ({ urls, alts, width, height, IndicatorIcon, positionIndicatorSize, iconSize, showArrows, frameStyle, onSlideChange, autoChange, }: ScrollSnapGalleryProps) => React$1.JSX.Element;
155
285
 
156
286
  type Card = {
287
+ /** Header content rendered at the top of the card. */
157
288
  title: React$1.ReactNode;
289
+ /** Main content rendered inside the card body. */
158
290
  content: React$1.ReactNode;
159
291
  };
160
292
  type StackedCardsProps = {
293
+ /** Cards available in the stack. */
161
294
  cards: Card[];
295
+ /** Initial selected card index. */
162
296
  initialCard: number;
297
+ /** Called when the user selects a different card. */
163
298
  onCardChangeByUser?: (cardIndex: number) => void;
299
+ /** Controlled selected card index from the parent. */
164
300
  overrideSelectedCard?: number;
301
+ /** Stack spread direction in degrees. */
165
302
  stackingOrientation?: number;
303
+ /** Height in pixels for each card. */
166
304
  cardHeight?: number;
305
+ /** Width in pixels for each card. */
167
306
  cardWidth?: number;
168
307
  };
169
308
  declare const StackedCards: ({ cards, initialCard, onCardChangeByUser, overrideSelectedCard, stackingOrientation, cardWidth, cardHeight, }: StackedCardsProps) => React$1.JSX.Element;
@@ -199,4 +338,4 @@ declare function useResizeObserver(elementRef: React$1.MutableRefObject<HTMLElem
199
338
  */
200
339
  declare function useWindowSize(): [number, number];
201
340
 
202
- export { BubbleMenu, CalendarDatePicker, InputBoxWithConfirmation, IntegerControl, LabeledInput, Modal, Multicalendar, ScreenSteps, ScrollSnapGallery, StackedCards, useIntersectionObserver, useOutsideClick, useResizeObserver, useWindowSize as useWindowsSize };
341
+ export { AlertModal, BubbleMenu, CalendarDatePicker, InputBoxWithConfirmation, IntegerControl, LabeledInput, Modal, Multicalendar, ScreenSteps, ScrollSnapGallery, StackedCards, useIntersectionObserver, useOutsideClick, useResizeObserver, useWindowSize as useWindowsSize };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "josenanodev-react-components-library",
3
- "version": "1.10.4",
3
+ "version": "1.11.0",
4
4
  "author": {
5
5
  "name": "Jose Carlos Cardenas Martinez"
6
6
  },
@@ -62,7 +62,7 @@
62
62
  "react-icons": "^5.0.0"
63
63
  },
64
64
  "scripts": {
65
- "rollup-build-lib": "rollup -c",
65
+ "rollup-build-lib": "node -e \"require('fs').rmSync('dist', { recursive: true, force: true })\" && rollup -c",
66
66
  "tsc": "tsc",
67
67
  "storybook": "storybook dev -p 6006",
68
68
  "build-storybook": "storybook build"
@@ -87,7 +87,6 @@
87
87
  "bugs": {
88
88
  "url": "https://github.com/Josenanodev/josenanodev-react-components-library/issues"
89
89
  },
90
- "readme": "ERROR: No README data found!",
91
90
  "homepage": "https://github.com/Josenanodev/josenanodev-react-components-library#readme",
92
91
  "dependencies": {
93
92
  "xlsx-js-style": "^1.2.0"
@@ -1,4 +0,0 @@
1
- import React from "react";
2
- import { CalendarDatePickerProps } from "../components/CalendarDatePicker/CalendarDatePicker";
3
- declare const CalendarDatePickerMask: (props: CalendarDatePickerProps) => React.JSX.Element;
4
- export default CalendarDatePickerMask;
@@ -1,4 +0,0 @@
1
- import React from "react";
2
- import { CalendarDatePickerProps } from "../components/CalendarDatePicker/CalendarDatePicker";
3
- declare const CalendarDatePickerMask: (props: CalendarDatePickerProps) => React.JSX.Element;
4
- export default CalendarDatePickerMask;