@leapdevuk/component-toolbox 0.0.118 → 0.0.119

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/CHANGELOG.md CHANGED
@@ -57,3 +57,13 @@
57
57
  ### Bug Fixes
58
58
 
59
59
  - Updated DatePicker to not show calendar icon when disabled
60
+
61
+ ## 0.0.119 (2025-05-29)
62
+
63
+ ### Bug Fixes
64
+
65
+ - Fixed Calendar reverting to the original year instead of the selected one
66
+
67
+ ### Features
68
+
69
+ - Updated DatePicker to use sdk alerts for validation
@@ -1,5 +1,6 @@
1
1
  import { FC } from 'react';
2
2
  import { Locale } from 'date-fns';
3
+ import { Api } from '@leapdev/leap-host';
3
4
  interface IValidationError {
4
5
  keepButton: boolean;
5
6
  message: string;
@@ -28,6 +29,7 @@ interface IDatePickerProps {
28
29
  validate?: (value?: any | null) => IValidationError | null;
29
30
  value: string | null;
30
31
  locale?: Locale;
32
+ sdk?: Api;
31
33
  }
32
34
  declare const LCTDatePicker: FC<IDatePickerProps>;
33
35
  export default LCTDatePicker;
@@ -1,4 +1,4 @@
1
- import { LeapContext } from '@leapdev/leap-host';
1
+ import { Api, LeapContext } from '@leapdev/leap-host';
2
2
  import { Locale } from 'date-fns';
3
3
  export declare const defaultDateFormat = "dd/MM/yyyy";
4
4
  export declare const defaultDateTimeFormat = "yyyy-MM-dd HH:mm:ss";
@@ -22,3 +22,9 @@ export declare const lctFormatDateTime: (value?: string | Date, locale?: Locale,
22
22
  export declare const getDateTimeWithOffset: (date: string) => Date;
23
23
  export declare const isStringNullOrUndefined: (value?: string | null) => boolean;
24
24
  export declare const formatAsDBDate: (date: Date) => string;
25
+ export declare enum DialogButtonType {
26
+ Confirm = 1,
27
+ Refuse = 2,
28
+ Cancel = 3
29
+ }
30
+ export declare const show3buttonAlert: (message: string, confirmButtonText: string, confirmCallback: () => void, refuseButtonText?: string, refuseCallback?: () => void, cancelButtonText?: string, sdkApi?: Api) => Promise<void> | undefined;