@thx/controls 17.3.2-alpha.0 → 17.3.5

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 (143) hide show
  1. package/package.json +5 -5
  2. package/dist/esm/date/DatePicker/styles.css.js +0 -7
  3. package/dist/esm/date/DatePicker/styles.css.js.map +0 -1
  4. package/dist/esm/date/LocalDatePicker/LocalDatePicker.js +0 -151
  5. package/dist/esm/date/LocalDatePicker/LocalDatePicker.js.map +0 -1
  6. package/dist/esm/date/LocalDatePicker/MaskedDateInput.js +0 -22
  7. package/dist/esm/date/LocalDatePicker/MaskedDateInput.js.map +0 -1
  8. package/dist/esm/date/LocalMonthSelect/LocalMonthSelect.js +0 -43
  9. package/dist/esm/date/LocalMonthSelect/LocalMonthSelect.js.map +0 -1
  10. package/dist/esm/date/LocalTimePicker/LocalTimePicker.js +0 -96
  11. package/dist/esm/date/LocalTimePicker/LocalTimePicker.js.map +0 -1
  12. package/dist/esm/date/LocalTimePicker/MaskedTimeInput.js +0 -22
  13. package/dist/esm/date/LocalTimePicker/MaskedTimeInput.js.map +0 -1
  14. package/dist/esm/date/MonthDayPicker/MonthDayPicker.js +0 -86
  15. package/dist/esm/date/MonthDayPicker/MonthDayPicker.js.map +0 -1
  16. package/dist/esm/date/MonthYearPicker/MonthYearPicker.js +0 -73
  17. package/dist/esm/date/MonthYearPicker/MonthYearPicker.js.map +0 -1
  18. package/dist/esm/date/YearSelect/YearSelect.js +0 -62
  19. package/dist/esm/date/YearSelect/YearSelect.js.map +0 -1
  20. package/dist/esm/external/style-inject/dist/style-inject.es.js +0 -29
  21. package/dist/esm/external/style-inject/dist/style-inject.es.js.map +0 -1
  22. package/dist/esm/form/TForm/TForm.js +0 -29
  23. package/dist/esm/form/TForm/TForm.js.map +0 -1
  24. package/dist/esm/form/TForm/useTForm.js +0 -90
  25. package/dist/esm/form/TForm/useTForm.js.map +0 -1
  26. package/dist/esm/index.js +0 -34
  27. package/dist/esm/index.js.map +0 -1
  28. package/dist/esm/inputs/CreditCardInput/CreditCardInput.js +0 -71
  29. package/dist/esm/inputs/CreditCardInput/CreditCardInput.js.map +0 -1
  30. package/dist/esm/inputs/CreditCardInput/CreditCardNumberInput.js +0 -76
  31. package/dist/esm/inputs/CreditCardInput/CreditCardNumberInput.js.map +0 -1
  32. package/dist/esm/inputs/CreditCardInput/styles.css.js +0 -7
  33. package/dist/esm/inputs/CreditCardInput/styles.css.js.map +0 -1
  34. package/dist/esm/inputs/MaskedInput/MaskedInput.js +0 -26
  35. package/dist/esm/inputs/MaskedInput/MaskedInput.js.map +0 -1
  36. package/dist/esm/inputs/MaskedInput/useMaskedInput.js +0 -57
  37. package/dist/esm/inputs/MaskedInput/useMaskedInput.js.map +0 -1
  38. package/dist/esm/inputs/PhoneInput/PhoneInput.js +0 -59
  39. package/dist/esm/inputs/PhoneInput/PhoneInput.js.map +0 -1
  40. package/dist/esm/inputs/RadioGroup/RadioGroup.js +0 -25
  41. package/dist/esm/inputs/RadioGroup/RadioGroup.js.map +0 -1
  42. package/dist/esm/inputs/SinInput/SinInput.js +0 -54
  43. package/dist/esm/inputs/SinInput/SinInput.js.map +0 -1
  44. package/dist/esm/inputs/TableInput/CheckboxEditCell.js +0 -32
  45. package/dist/esm/inputs/TableInput/CheckboxEditCell.js.map +0 -1
  46. package/dist/esm/inputs/TableInput/DropdownCell.js +0 -26
  47. package/dist/esm/inputs/TableInput/DropdownCell.js.map +0 -1
  48. package/dist/esm/inputs/TableInput/HoverCell.js +0 -20
  49. package/dist/esm/inputs/TableInput/HoverCell.js.map +0 -1
  50. package/dist/esm/inputs/TableInput/LocalDateCell.js +0 -13
  51. package/dist/esm/inputs/TableInput/LocalDateCell.js.map +0 -1
  52. package/dist/esm/inputs/TableInput/LocalDateEditCell.js +0 -33
  53. package/dist/esm/inputs/TableInput/LocalDateEditCell.js.map +0 -1
  54. package/dist/esm/inputs/TableInput/LocalTimeEditCell.js +0 -31
  55. package/dist/esm/inputs/TableInput/LocalTimeEditCell.js.map +0 -1
  56. package/dist/esm/inputs/TableInput/MoneyCell.js +0 -13
  57. package/dist/esm/inputs/TableInput/MoneyCell.js.map +0 -1
  58. package/dist/esm/inputs/TableInput/MoneyEditCell.js +0 -37
  59. package/dist/esm/inputs/TableInput/MoneyEditCell.js.map +0 -1
  60. package/dist/esm/inputs/TableInput/MoneySumFooter.js +0 -20
  61. package/dist/esm/inputs/TableInput/MoneySumFooter.js.map +0 -1
  62. package/dist/esm/inputs/TableInput/NumberEditCell.js +0 -35
  63. package/dist/esm/inputs/TableInput/NumberEditCell.js.map +0 -1
  64. package/dist/esm/inputs/TableInput/StringEditCell.js +0 -34
  65. package/dist/esm/inputs/TableInput/StringEditCell.js.map +0 -1
  66. package/dist/esm/inputs/TableInput/TableInput.js +0 -79
  67. package/dist/esm/inputs/TableInput/TableInput.js.map +0 -1
  68. package/dist/esm/inputs/TableInput/addRowOnTab.js +0 -13
  69. package/dist/esm/inputs/TableInput/addRowOnTab.js.map +0 -1
  70. package/dist/esm/money/MoneyCurrencyInput/MoneyCurrencyInput.js +0 -51
  71. package/dist/esm/money/MoneyCurrencyInput/MoneyCurrencyInput.js.map +0 -1
  72. package/dist/esm/money/MoneyInput/MoneyInput.js +0 -31
  73. package/dist/esm/money/MoneyInput/MoneyInput.js.map +0 -1
  74. package/dist/esm/money/useMoneyInput.js +0 -75
  75. package/dist/esm/money/useMoneyInput.js.map +0 -1
  76. package/dist/esm/step/FormStep.js +0 -17
  77. package/dist/esm/step/FormStep.js.map +0 -1
  78. package/dist/esm/step/Step.js +0 -10
  79. package/dist/esm/step/Step.js.map +0 -1
  80. package/dist/esm/step/StepProvider.js +0 -95
  81. package/dist/esm/step/StepProvider.js.map +0 -1
  82. package/dist/esm/step/stepContext.js +0 -10
  83. package/dist/esm/step/stepContext.js.map +0 -1
  84. package/dist/esm/step/useStep.js +0 -10
  85. package/dist/esm/step/useStep.js.map +0 -1
  86. package/dist/stats.html +0 -2689
  87. package/dist/types/date/DatePicker/index.d.ts +0 -3
  88. package/dist/types/date/LocalDatePicker/LocalDatePicker.d.ts +0 -20
  89. package/dist/types/date/LocalDatePicker/MaskedDateInput.d.ts +0 -13
  90. package/dist/types/date/LocalDatePicker/index.d.ts +0 -2
  91. package/dist/types/date/LocalMonthSelect/LocalMonthSelect.d.ts +0 -11
  92. package/dist/types/date/LocalMonthSelect/index.d.ts +0 -2
  93. package/dist/types/date/LocalTimePicker/LocalTimePicker.d.ts +0 -13
  94. package/dist/types/date/LocalTimePicker/MaskedTimeInput.d.ts +0 -12
  95. package/dist/types/date/LocalTimePicker/index.d.ts +0 -2
  96. package/dist/types/date/MonthDayPicker/MonthDayPicker.d.ts +0 -13
  97. package/dist/types/date/MonthDayPicker/index.d.ts +0 -2
  98. package/dist/types/date/MonthYearPicker/MonthYearPicker.d.ts +0 -15
  99. package/dist/types/date/MonthYearPicker/index.d.ts +0 -2
  100. package/dist/types/date/YearSelect/YearSelect.d.ts +0 -10
  101. package/dist/types/date/YearSelect/index.d.ts +0 -2
  102. package/dist/types/form/TForm/TForm.d.ts +0 -3
  103. package/dist/types/form/TForm/index.d.ts +0 -3
  104. package/dist/types/form/TForm/types.d.ts +0 -32
  105. package/dist/types/form/TForm/useTForm.d.ts +0 -57
  106. package/dist/types/index.d.ts +0 -32
  107. package/dist/types/inputs/CreditCardInput/CreditCardInput.d.ts +0 -15
  108. package/dist/types/inputs/CreditCardInput/CreditCardNumberInput.d.ts +0 -7
  109. package/dist/types/inputs/CreditCardInput/index.d.ts +0 -2
  110. package/dist/types/inputs/MaskedInput/MaskedInput.d.ts +0 -11
  111. package/dist/types/inputs/MaskedInput/index.d.ts +0 -3
  112. package/dist/types/inputs/MaskedInput/useMaskedInput.d.ts +0 -7
  113. package/dist/types/inputs/PhoneInput/PhoneInput.d.ts +0 -6
  114. package/dist/types/inputs/PhoneInput/index.d.ts +0 -2
  115. package/dist/types/inputs/RadioGroup/RadioGroup.d.ts +0 -7
  116. package/dist/types/inputs/RadioGroup/index.d.ts +0 -2
  117. package/dist/types/inputs/SinInput/SinInput.d.ts +0 -6
  118. package/dist/types/inputs/SinInput/index.d.ts +0 -2
  119. package/dist/types/inputs/TableInput/CheckboxEditCell.d.ts +0 -11
  120. package/dist/types/inputs/TableInput/DropdownCell.d.ts +0 -3
  121. package/dist/types/inputs/TableInput/HoverCell.d.ts +0 -6
  122. package/dist/types/inputs/TableInput/LocalDateCell.d.ts +0 -10
  123. package/dist/types/inputs/TableInput/LocalDateEditCell.d.ts +0 -3
  124. package/dist/types/inputs/TableInput/LocalTimeEditCell.d.ts +0 -3
  125. package/dist/types/inputs/TableInput/MoneyCell.d.ts +0 -8
  126. package/dist/types/inputs/TableInput/MoneyEditCell.d.ts +0 -10
  127. package/dist/types/inputs/TableInput/MoneySumFooter.d.ts +0 -6
  128. package/dist/types/inputs/TableInput/NumberEditCell.d.ts +0 -11
  129. package/dist/types/inputs/TableInput/StringEditCell.d.ts +0 -11
  130. package/dist/types/inputs/TableInput/TableInput.d.ts +0 -32
  131. package/dist/types/inputs/TableInput/addRowOnTab.d.ts +0 -10
  132. package/dist/types/inputs/TableInput/index.d.ts +0 -14
  133. package/dist/types/money/MoneyCurrencyInput/MoneyCurrencyInput.d.ts +0 -10
  134. package/dist/types/money/MoneyCurrencyInput/index.d.ts +0 -2
  135. package/dist/types/money/MoneyInput/MoneyInput.d.ts +0 -14
  136. package/dist/types/money/MoneyInput/index.d.ts +0 -2
  137. package/dist/types/money/useMoneyInput.d.ts +0 -13
  138. package/dist/types/step/FormStep.d.ts +0 -8
  139. package/dist/types/step/Step.d.ts +0 -8
  140. package/dist/types/step/StepProvider.d.ts +0 -9
  141. package/dist/types/step/index.d.ts +0 -4
  142. package/dist/types/step/stepContext.d.ts +0 -4
  143. package/dist/types/step/useStep.d.ts +0 -1
@@ -1,3 +0,0 @@
1
- import DatePicker from 'react-datepicker';
2
- import './styles.css';
3
- export { DatePicker };
@@ -1,20 +0,0 @@
1
- import type { LocalDate } from '@js-joda/core';
2
- import type { ReactDatePickerProps } from 'react-datepicker';
3
- import { type InputProps } from 'semantic-ui-react';
4
- import '../DatePicker/styles.css';
5
- interface ILocalDatePicker {
6
- value?: LocalDate | number | null;
7
- onChange?: (value: LocalDate | null) => void;
8
- onChangeRaw?: () => void;
9
- minDate?: LocalDate;
10
- maxDate?: LocalDate;
11
- icon?: boolean;
12
- openOnFocus?: boolean;
13
- startFocused?: boolean;
14
- startSelected?: boolean;
15
- }
16
- type InputPropsOmitted = Omit<InputProps, 'onChange'>;
17
- type ReactDatePickerPropsOmitted = Omit<Omit<ReactDatePickerProps, 'value'>, 'onChange' | 'minDate' | 'maxDate' | 'icon'>;
18
- export type LocalDatePickerProps = ILocalDatePicker & InputPropsOmitted & ReactDatePickerPropsOmitted;
19
- export declare function LocalDatePicker(props: LocalDatePickerProps): JSX.Element;
20
- export {};
@@ -1,13 +0,0 @@
1
- import { type MaskedInputProps } from '../../inputs/MaskedInput';
2
- import type { MaskedInputRef } from '../../inputs/MaskedInput/MaskedInput';
3
- export type MaskedDateInputRef = MaskedInputRef;
4
- export interface MaskedDateInputValue {
5
- target: {
6
- value: string;
7
- };
8
- }
9
- export interface MaskedDateInputProps {
10
- name?: string;
11
- onChange?: (value: MaskedDateInputValue) => void;
12
- }
13
- export declare const MaskedDateInput: import("react").ForwardRefExoticComponent<Pick<MaskedDateInputProps & Omit<MaskedInputProps, "onChange">, string | number> & import("react").RefAttributes<MaskedInputRef>>;
@@ -1,2 +0,0 @@
1
- export { LocalDatePicker } from './LocalDatePicker';
2
- export type { LocalDatePickerProps } from './LocalDatePicker';
@@ -1,11 +0,0 @@
1
- import { LocalDate } from '@js-joda/core';
2
- import { type SelectProps } from 'semantic-ui-react';
3
- interface ILocalMonthSelectProps {
4
- onChange?: (value: LocalDate | null) => void;
5
- value?: LocalDate | null;
6
- year?: number;
7
- handleBlur?: (event: any) => void;
8
- }
9
- export type LocalMonthSelectProps = ILocalMonthSelectProps & Omit<SelectProps, 'options'>;
10
- export declare function LocalMonthSelect(props: LocalMonthSelectProps): JSX.Element;
11
- export {};
@@ -1,2 +0,0 @@
1
- export { LocalMonthSelect } from './LocalMonthSelect';
2
- export type { LocalMonthSelectProps } from './LocalMonthSelect';
@@ -1,13 +0,0 @@
1
- import { LocalTime } from '@js-joda/core';
2
- import type { ReactDatePickerProps } from 'react-datepicker';
3
- import { type InputProps } from 'semantic-ui-react';
4
- interface ILocalTimePicker {
5
- value?: LocalTime | number | null;
6
- onChange?: (value: LocalTime | null) => void;
7
- onChangeRaw?: () => void;
8
- }
9
- type InputPropsOmitted = Omit<InputProps, 'onChange'>;
10
- type ReactDatePickerPropsOmitted = Omit<Omit<ReactDatePickerProps, 'value'>, 'onChange'>;
11
- export type LocalTimePickerProps = ILocalTimePicker & InputPropsOmitted & ReactDatePickerPropsOmitted;
12
- export declare function LocalTimePicker(props: LocalTimePickerProps): JSX.Element;
13
- export {};
@@ -1,12 +0,0 @@
1
- import { type MaskedInputProps } from '../../inputs/MaskedInput';
2
- import type { MaskedInputRef } from '../../inputs/MaskedInput/MaskedInput';
3
- export type MaskedTimeInputRef = MaskedInputRef;
4
- export interface MaskedTimeInputValue {
5
- target: {
6
- value: string;
7
- };
8
- }
9
- export interface MaskedTimeInputProps {
10
- onChange?: (value: MaskedTimeInputValue) => void;
11
- }
12
- export declare const MaskedTimeInput: import("react").ForwardRefExoticComponent<Pick<MaskedTimeInputProps & Omit<MaskedInputProps, "onChange">, string | number> & import("react").RefAttributes<MaskedInputRef>>;
@@ -1,2 +0,0 @@
1
- export { LocalTimePicker } from './LocalTimePicker';
2
- export type { LocalTimePickerProps } from './LocalTimePicker';
@@ -1,13 +0,0 @@
1
- import type { LocalDate } from '@js-joda/core';
2
- import type { ReactDatePickerProps } from 'react-datepicker';
3
- import { type InputProps } from 'semantic-ui-react';
4
- interface IMonthDayPickerProps {
5
- value?: LocalDate | number | null;
6
- onChange?: (value: LocalDate | null) => void;
7
- onChangeRaw?: () => void;
8
- }
9
- type InputPropsOmitted = Omit<InputProps, 'onChange'>;
10
- type ReactDatePickerPropsOmitted = Omit<Omit<ReactDatePickerProps, 'value'>, 'onChange'>;
11
- export type MonthDayPickerProps = IMonthDayPickerProps & InputPropsOmitted & ReactDatePickerPropsOmitted;
12
- export declare function MonthDayPicker(props: MonthDayPickerProps): JSX.Element;
13
- export {};
@@ -1,2 +0,0 @@
1
- export { MonthDayPicker } from './MonthDayPicker';
2
- export type { MonthDayPickerProps } from './MonthDayPicker';
@@ -1,15 +0,0 @@
1
- import { LocalDate } from '@js-joda/core';
2
- import type { ReactDatePickerProps } from 'react-datepicker';
3
- import { type InputProps } from 'semantic-ui-react';
4
- interface IMonthYearPickerProps {
5
- value?: LocalDate | number | undefined;
6
- onChange?: (value: LocalDate | undefined) => void;
7
- onChangeRaw?: () => void;
8
- minDate?: LocalDate | undefined;
9
- maxDate?: LocalDate | undefined;
10
- }
11
- type InputPropsOmitted = Omit<InputProps, 'onChange'>;
12
- type ReactDatePickerPropsOmitted = Omit<Omit<ReactDatePickerProps, 'value' | 'minDate' | 'maxDate'>, 'onChange'>;
13
- export type MonthYearPickerProps = IMonthYearPickerProps & InputPropsOmitted & ReactDatePickerPropsOmitted;
14
- export declare function MonthYearPicker(props: MonthYearPickerProps): JSX.Element;
15
- export {};
@@ -1,2 +0,0 @@
1
- export { MonthYearPicker } from './MonthYearPicker';
2
- export type { MonthYearPickerProps } from './MonthYearPicker';
@@ -1,10 +0,0 @@
1
- import { type SegmentProps } from 'semantic-ui-react';
2
- export interface YearSelectProps {
3
- onChange?: (value: number) => void;
4
- onBlur?: (ev: any) => void;
5
- value: number;
6
- minYear?: number;
7
- maxYear?: number;
8
- error?: boolean;
9
- }
10
- export declare function YearSelect(props: YearSelectProps & Omit<SegmentProps, 'onChange'>): JSX.Element;
@@ -1,2 +0,0 @@
1
- export { YearSelect } from './YearSelect';
2
- export type { YearSelectProps } from './YearSelect';
@@ -1,3 +0,0 @@
1
- import { type FormikValues } from 'formik';
2
- import type { TFormConfig } from './types';
3
- export declare function TForm<Values extends FormikValues = FormikValues>(props: TFormConfig<Values>): JSX.Element;
@@ -1,3 +0,0 @@
1
- export { TForm } from './TForm';
2
- export { useTForm } from './useTForm';
3
- export type { TFormProps } from './types';
@@ -1,32 +0,0 @@
1
- import type { FormikConfig, FormikProps } from 'formik';
2
- import type React from 'react';
3
- export interface TFormProps<Values> extends FormikProps<Values> {
4
- hasErrors: boolean;
5
- hasWarnings: boolean;
6
- isValid: boolean;
7
- loading: boolean;
8
- submitDisabled: boolean;
9
- errorMarkedCleared: boolean;
10
- formError: boolean;
11
- renderWarnings: () => JSX.Element | null;
12
- fieldError: (fieldName: keyof Values | string | number) => boolean;
13
- handleSubmit: (e?: React.FormEvent<HTMLFormElement>) => void;
14
- }
15
- interface ApolloError {
16
- message?: string;
17
- graphQLErrors?: {
18
- message?: string;
19
- }[];
20
- }
21
- export interface TFormConfig<Values, InitialValues = any> extends Omit<FormikConfig<Values>, 'component' | 'render' | 'children' | 'initialValues'> {
22
- component?: React.ComponentType<TFormProps<Values>> | React.ReactNode;
23
- render?: (props: TFormProps<Values>) => React.ReactNode;
24
- children?: ((props: TFormProps<Values>) => React.ReactNode) | React.ReactNode;
25
- initialValues: InitialValues;
26
- loading?: boolean;
27
- error?: ApolloError;
28
- onValidate?: (isValid: boolean) => void;
29
- getSubmitFn?: (submitFormFn: () => Promise<void> | Promise<any>) => void;
30
- onChange?: (values: Values) => void;
31
- }
32
- export {};
@@ -1,57 +0,0 @@
1
- import { type FormikValues, type FormikErrors, type FormikTouched } from 'formik';
2
- import { type FormEvent } from 'react';
3
- import type { TFormConfig } from './types';
4
- export declare function useTForm<Values extends FormikValues = FormikValues, InitialValues = any>(config: TFormConfig<Values, InitialValues>): {
5
- hasErrors: boolean;
6
- hasWarnings: boolean;
7
- isValid: boolean;
8
- loading: boolean;
9
- submitDisabled: boolean;
10
- errorMarkedCleared: boolean;
11
- formError: boolean;
12
- renderWarnings: () => JSX.Element | null;
13
- fieldError: (fieldName: keyof Values | string | number) => boolean;
14
- handleSubmit: (e?: FormEvent<HTMLFormElement>) => void;
15
- initialValues: Values;
16
- initialErrors: FormikErrors<unknown>;
17
- initialTouched: FormikTouched<unknown>;
18
- initialStatus: any;
19
- handleBlur: {
20
- (e: React.FocusEvent<any>): void;
21
- <T = any>(fieldOrEvent: T): T extends string ? (e: any) => void : void;
22
- };
23
- handleChange: {
24
- (e: React.ChangeEvent<any>): void;
25
- <T_1 = string | React.ChangeEvent<any>>(field: T_1): T_1 extends React.ChangeEvent<any> ? void : (e: string | React.ChangeEvent<any>) => void;
26
- };
27
- handleReset: (e: any) => void;
28
- resetForm: (nextState?: Partial<import("formik").FormikState<Values>> | undefined) => void;
29
- setErrors: (errors: FormikErrors<Values>) => void;
30
- setFormikState: (stateOrCb: import("formik").FormikState<Values> | ((state: import("formik").FormikState<Values>) => import("formik").FormikState<Values>)) => void;
31
- setFieldTouched: (field: string, touched?: boolean, shouldValidate?: boolean | undefined) => Promise<void> | Promise<FormikErrors<Values>>;
32
- setFieldValue: (field: string, value: any, shouldValidate?: boolean | undefined) => Promise<void> | Promise<FormikErrors<Values>>;
33
- setFieldError: (field: string, value: string | undefined) => void;
34
- setStatus: (status: any) => void;
35
- setSubmitting: (isSubmitting: boolean) => void;
36
- setTouched: (touched: FormikTouched<Values>, shouldValidate?: boolean | undefined) => Promise<void> | Promise<FormikErrors<Values>>;
37
- setValues: (values: import("react").SetStateAction<Values>, shouldValidate?: boolean | undefined) => Promise<void> | Promise<FormikErrors<Values>>;
38
- submitForm: () => Promise<any>;
39
- validateForm: (values?: Values | undefined) => Promise<FormikErrors<Values>>;
40
- validateField: (name: string) => Promise<void> | Promise<string | undefined>;
41
- dirty: boolean;
42
- unregisterField: (name: string) => void;
43
- registerField: (name: string, { validate }: any) => void;
44
- getFieldProps: (nameOrOptions: any) => import("formik").FieldInputProps<any>;
45
- getFieldMeta: (name: string) => import("formik").FieldMetaProps<any>;
46
- getFieldHelpers: (name: string) => import("formik").FieldHelperProps<any>;
47
- validateOnBlur: boolean;
48
- validateOnChange: boolean;
49
- validateOnMount: boolean;
50
- values: Values;
51
- errors: FormikErrors<Values>;
52
- touched: FormikTouched<Values>;
53
- isSubmitting: boolean;
54
- isValidating: boolean;
55
- status?: any;
56
- submitCount: number;
57
- };
@@ -1,32 +0,0 @@
1
- export type { DatePicker } from './date/DatePicker';
2
- export { LocalDatePicker } from './date/LocalDatePicker';
3
- export type { LocalDatePickerProps } from './date/LocalDatePicker';
4
- export { LocalMonthSelect } from './date/LocalMonthSelect';
5
- export type { LocalMonthSelectProps } from './date/LocalMonthSelect';
6
- export { LocalTimePicker } from './date/LocalTimePicker';
7
- export type { LocalTimePickerProps } from './date/LocalTimePicker';
8
- export { MonthDayPicker } from './date/MonthDayPicker';
9
- export type { MonthDayPickerProps } from './date/MonthDayPicker';
10
- export { MonthYearPicker } from './date/MonthYearPicker';
11
- export type { MonthYearPickerProps } from './date/MonthYearPicker';
12
- export { YearSelect } from './date/YearSelect';
13
- export type { YearSelectProps } from './date/YearSelect';
14
- export { useTForm, TForm } from './form/TForm';
15
- export type { TFormProps } from './form/TForm';
16
- export { MaskedInput } from './inputs/MaskedInput';
17
- export type { MaskedInputProps } from './inputs/MaskedInput';
18
- export { RadioGroup } from './inputs/RadioGroup';
19
- export type { RadioGroupProps } from './inputs/RadioGroup';
20
- export { PhoneInput } from './inputs/PhoneInput';
21
- export type { PhoneInputProps } from './inputs/PhoneInput';
22
- export { CreditCardInput } from './inputs/CreditCardInput';
23
- export type { CreditCardInputProps } from './inputs/CreditCardInput';
24
- export { SinInput } from './inputs/SinInput';
25
- export type { SinInputProps } from './inputs/SinInput';
26
- export { TableInput, MoneyCell, MoneyEditCell, CheckboxEditCell, LocalDateCell, LocalDateEditCell, LocalTimeEditCell, MoneySumFooter, NumberEditCell, StringEditCell, DropdownCell, HoverCell, addRowOnTab, } from './inputs/TableInput';
27
- export type { AddRowOnTabIf } from './inputs/TableInput';
28
- export { MoneyInput } from './money/MoneyInput';
29
- export type { MoneyInputProps } from './money/MoneyInput';
30
- export { MoneyCurrencyInput } from './money/MoneyCurrencyInput';
31
- export type { MoneyCurrencyInputProps } from './money/MoneyCurrencyInput';
32
- export { FormStep, StepProvider, useStep, Step } from './step';
@@ -1,15 +0,0 @@
1
- import type { LocalDate } from '@js-joda/core';
2
- import 'react-credit-cards/es/styles-compiled.css';
3
- import { type InputProps } from 'semantic-ui-react';
4
- import './styles.css';
5
- export interface CreditCardData {
6
- number?: string;
7
- name?: string;
8
- cvc?: string;
9
- expiry?: LocalDate;
10
- }
11
- export type CreditCardInputProps = {
12
- value?: CreditCardData;
13
- onChange?: (data: CreditCardData) => void;
14
- } & Pick<InputProps, 'disabled' | 'onBlur'>;
15
- export declare function CreditCardInput(props: CreditCardInputProps): JSX.Element;
@@ -1,7 +0,0 @@
1
- import { type InputProps } from 'semantic-ui-react';
2
- interface CreditCardNumberInputProps {
3
- onChange?: (value: string | undefined) => void;
4
- value?: string;
5
- }
6
- export declare function CreditCardNumberInput(props: CreditCardNumberInputProps & Omit<InputProps, 'onChange'>): JSX.Element;
7
- export {};
@@ -1,2 +0,0 @@
1
- export { CreditCardInput } from './CreditCardInput';
2
- export type { CreditCardInputProps } from './CreditCardInput';
@@ -1,11 +0,0 @@
1
- import type { InputProps } from 'semantic-ui-react';
2
- import { type UseMaskedInputProps } from './useMaskedInput';
3
- export interface MaskedInputRef {
4
- focus: () => void;
5
- select: () => void;
6
- }
7
- export type MaskedInputProps = {
8
- name?: string;
9
- onBlur?: (event: any) => void;
10
- } & UseMaskedInputProps & Omit<InputProps, 'onChange'>;
11
- export declare const MaskedInput: import("react").ForwardRefExoticComponent<Pick<MaskedInputProps, string | number> & import("react").RefAttributes<MaskedInputRef>>;
@@ -1,3 +0,0 @@
1
- export { MaskedInput } from './MaskedInput';
2
- export { useMaskedInput } from './useMaskedInput';
3
- export type { MaskedInputProps } from './MaskedInput';
@@ -1,7 +0,0 @@
1
- export interface UseMaskedInputProps {
2
- value?: string;
3
- onChange?: (value?: string) => void;
4
- mask?: Inputmask.Options;
5
- onSet?: (value?: string) => void;
6
- }
7
- export declare function useMaskedInput(props: UseMaskedInputProps): import("react").MutableRefObject<HTMLInputElement | null>;
@@ -1,6 +0,0 @@
1
- import { type MaskedInputProps } from '../MaskedInput';
2
- export interface PhoneInputProps {
3
- extension?: boolean;
4
- onChange?: (value?: string) => void;
5
- }
6
- export declare function PhoneInput(props: PhoneInputProps & Omit<MaskedInputProps, 'mask' | 'onChange'>): JSX.Element;
@@ -1,2 +0,0 @@
1
- export { PhoneInput } from './PhoneInput';
2
- export type { PhoneInputProps } from './PhoneInput';
@@ -1,7 +0,0 @@
1
- import { type FormGroupProps } from 'semantic-ui-react';
2
- export interface RadioGroupProps {
3
- children?: JSX.Element[] | JSX.Element;
4
- onChange?: (value?: string | number) => void;
5
- value?: string | number;
6
- }
7
- export declare function RadioGroup(props: RadioGroupProps & Omit<FormGroupProps, 'children'>): JSX.Element;
@@ -1,2 +0,0 @@
1
- export { RadioGroup } from './RadioGroup';
2
- export type { RadioGroupProps } from './RadioGroup';
@@ -1,6 +0,0 @@
1
- import type { MaskedInputProps } from '../MaskedInput';
2
- export interface SinInputProps extends Omit<MaskedInputProps, 'mask'> {
3
- value?: string;
4
- onChange(value?: string): void;
5
- }
6
- export declare function SinInput(props: SinInputProps): JSX.Element;
@@ -1,2 +0,0 @@
1
- export { SinInput } from './SinInput';
2
- export type { SinInputProps } from './SinInput';
@@ -1,11 +0,0 @@
1
- import { type CheckboxProps } from 'semantic-ui-react';
2
- import type { TableCellProps } from './TableInput';
3
- import type { AddRowOnTabIf } from './addRowOnTab';
4
- interface CheckboxEditCellOptions<D extends Record<string, unknown>> {
5
- /** Override SemanticUI Input props */
6
- inputProps?: CheckboxProps;
7
- /** If function is present, and returns true, will add a new row if tab is pressed on the last row */
8
- addRowOnTabIf?: AddRowOnTabIf<D, boolean>;
9
- }
10
- export declare function CheckboxEditCell<D extends Record<string, unknown>>(options?: CheckboxEditCellOptions<D>): (props: TableCellProps<D, boolean>) => JSX.Element;
11
- export {};
@@ -1,3 +0,0 @@
1
- import type { DropdownProps } from 'semantic-ui-react';
2
- import type { TableCellProps } from './TableInput';
3
- export declare function DropdownCell<D extends Record<string, unknown>>(dropdownProps: DropdownProps): (props: TableCellProps<D>) => JSX.Element;
@@ -1,6 +0,0 @@
1
- import type { CellProps, Renderer } from 'react-table';
2
- interface HoverCellOptions<D extends Record<string, unknown>> {
3
- Action: Renderer<CellProps<D>>;
4
- }
5
- export declare function HoverCell<D extends Record<string, unknown>>(options: HoverCellOptions<D>): (props: CellProps<D>) => JSX.Element | null;
6
- export {};
@@ -1,10 +0,0 @@
1
- import type { LocalDate } from '@js-joda/core';
2
- import { type FormatDateParams } from '@thx/date';
3
- import type { CellProps } from 'react-table';
4
- interface LocalDateCellOptions<D extends Record<string, unknown>> {
5
- /** If provided, this function will override the LocalDate value displayed */
6
- overrideValue?: (props: CellProps<D, LocalDate>) => LocalDate;
7
- dateFormat?: FormatDateParams;
8
- }
9
- export declare function LocalDateCell<D extends Record<string, unknown>>(options?: LocalDateCellOptions<D>): (props: CellProps<D, LocalDate>) => JSX.Element;
10
- export {};
@@ -1,3 +0,0 @@
1
- import type { LocalDate } from '@js-joda/core';
2
- import type { TableCellProps } from './TableInput';
3
- export declare function LocalDateEditCell<D extends Record<string, unknown>>(): (props: TableCellProps<D, LocalDate | null>) => JSX.Element;
@@ -1,3 +0,0 @@
1
- import type { LocalTime } from '@js-joda/core';
2
- import type { TableCellProps } from './TableInput';
3
- export declare function LocalTimeEditCell<D extends Record<string, unknown>>(): (props: TableCellProps<D, LocalTime | null>) => JSX.Element;
@@ -1,8 +0,0 @@
1
- import type Money from 'js-money';
2
- import type { CellProps } from 'react-table';
3
- interface MoneyCellOptions<D extends Record<string, unknown>> {
4
- /** If provided, this function will override the Money value displayed */
5
- overrideValue?: (props: CellProps<D, Money>) => Money;
6
- }
7
- export declare function MoneyCell<D extends Record<string, unknown>>(options?: MoneyCellOptions<D>): (props: CellProps<D, Money>) => JSX.Element;
8
- export {};
@@ -1,10 +0,0 @@
1
- import type Money from 'js-money';
2
- import type { TableCellProps } from './TableInput';
3
- import type { AddRowOnTabIf } from './addRowOnTab';
4
- interface MoneyEditCellOptions<D extends Record<string, unknown>> {
5
- /** If function is present, and returns true, will add a new row if tab is pressed on the last row */
6
- addRowOnTabIf?: AddRowOnTabIf<D, Money | undefined>;
7
- tabIndex?: number;
8
- }
9
- export declare function MoneyEditCell<D extends Record<string, unknown>>(moneyEditCellProps?: MoneyEditCellOptions<D>): (props: TableCellProps<D, Money | undefined>) => JSX.Element;
10
- export {};
@@ -1,6 +0,0 @@
1
- import type { IdType, TableInstance } from 'react-table';
2
- interface MoneySumFooterOptions<A extends Record<string, unknown>> {
3
- id: IdType<A>;
4
- }
5
- export declare function MoneySumFooter<A extends Record<string, unknown>>(options: MoneySumFooterOptions<A>): (info: TableInstance<A>) => JSX.Element;
6
- export {};
@@ -1,11 +0,0 @@
1
- import { type InputProps } from 'semantic-ui-react';
2
- import type { TableCellProps } from './TableInput';
3
- import type { AddRowOnTabIf } from './addRowOnTab';
4
- interface NumberEditCellOptions<D extends Record<number, unknown>> {
5
- /** Override SemanticUI Input props */
6
- inputProps?: InputProps;
7
- /** If function is present, and returns true, will add a new row if tab is pressed on the last row */
8
- addRowOnTabIf?: AddRowOnTabIf<D, number>;
9
- }
10
- export declare function NumberEditCell<D extends Record<number, unknown>>(options?: NumberEditCellOptions<D>): (props: TableCellProps<D, number>) => JSX.Element;
11
- export {};
@@ -1,11 +0,0 @@
1
- import { type InputProps } from 'semantic-ui-react';
2
- import type { TableCellProps } from './TableInput';
3
- import type { AddRowOnTabIf } from './addRowOnTab';
4
- interface StringEditCellOptions<D extends Record<string, unknown>> {
5
- /** Override SemanticUI Input props */
6
- inputProps?: InputProps;
7
- /** If function is present, and returns true, will add a new row if tab is pressed on the last row */
8
- addRowOnTabIf?: AddRowOnTabIf<D, string>;
9
- }
10
- export declare function StringEditCell<D extends Record<string, unknown>>(options?: StringEditCellOptions<D>): (props: TableCellProps<D, string>) => JSX.Element;
11
- export {};
@@ -1,32 +0,0 @@
1
- import { type FieldArrayRenderProps } from 'formik';
2
- import { type CellPropGetter, type CellProps, type Column, type FooterGroupPropGetter, type FooterPropGetter, type HeaderGroupPropGetter, type HeaderPropGetter, type RowPropGetter, type TableBodyPropGetter } from 'react-table';
3
- import { type TableProps } from 'semantic-ui-react';
4
- type DefaultTableType = Record<string, unknown>;
5
- interface TableInputProps<A extends DefaultTableType> {
6
- name: string;
7
- values: A[];
8
- columns: Column<A>[];
9
- setFieldValue: (field: string, value: any, shouldValidate?: boolean | undefined) => void;
10
- createRow?: () => A;
11
- tableProps?: TableProps;
12
- headerRowProps?: HeaderGroupPropGetter<A>;
13
- headerCellProps?: HeaderPropGetter<A>;
14
- footerRowProps?: FooterGroupPropGetter<A>;
15
- footerCellProps?: FooterPropGetter<A>;
16
- bodyProps?: TableBodyPropGetter<A>;
17
- rowProps?: RowPropGetter<A>;
18
- cellProps?: CellPropGetter<A>;
19
- }
20
- export interface TableCellProps<D extends DefaultTableType, V = any> extends CellProps<D, V> {
21
- arrayHelpers: FieldArrayRenderProps;
22
- addRow: () => void;
23
- updateData: (index: number, id: string, value: V) => void;
24
- hoverRow: string | number;
25
- }
26
- /**
27
- * Can be used in a TForm as a Table Input.
28
- * @param props
29
- * @constructor
30
- */
31
- export declare function TableInput<A extends DefaultTableType>(props: TableInputProps<A>): JSX.Element;
32
- export {};
@@ -1,10 +0,0 @@
1
- import type { TableCellProps } from './TableInput';
2
- export type AddRowOnTabIf<D extends Record<string, unknown>, V = any> = (props: TableCellProps<D, V>, newValue: V) => boolean;
3
- /**
4
- * Use as an onKeyDown event handler to add a new row when tab is pressed, depending on certain criteria.
5
- * @param event
6
- * @param value
7
- * @param props
8
- * @param addRowOnTabIf
9
- */
10
- export declare function addRowOnTab<D extends Record<string, unknown>, V = any>(event: KeyboardEvent, value: V, props: TableCellProps<D, V>, addRowOnTabIf?: AddRowOnTabIf<D, V>): void;
@@ -1,14 +0,0 @@
1
- export { TableInput } from './TableInput';
2
- export { MoneyCell } from './MoneyCell';
3
- export { MoneyEditCell } from './MoneyEditCell';
4
- export { LocalDateCell } from './LocalDateCell';
5
- export { CheckboxEditCell } from './CheckboxEditCell';
6
- export { LocalDateEditCell } from './LocalDateEditCell';
7
- export { LocalTimeEditCell } from './LocalTimeEditCell';
8
- export { MoneySumFooter } from './MoneySumFooter';
9
- export { NumberEditCell } from './NumberEditCell';
10
- export { StringEditCell } from './StringEditCell';
11
- export { DropdownCell } from './DropdownCell';
12
- export { HoverCell } from './HoverCell';
13
- export { addRowOnTab } from './addRowOnTab';
14
- export type { AddRowOnTabIf } from './addRowOnTab';
@@ -1,10 +0,0 @@
1
- import { type InputProps } from 'semantic-ui-react';
2
- import type { MoneyInputProps } from '../MoneyInput';
3
- export interface MoneyCurrencyInputProps extends MoneyInputProps {
4
- currencies?: {
5
- key: string;
6
- value: string;
7
- text: string;
8
- }[];
9
- }
10
- export declare function MoneyCurrencyInput(props: MoneyCurrencyInputProps & Omit<InputProps, 'onChange'>): JSX.Element;
@@ -1,2 +0,0 @@
1
- export { MoneyCurrencyInput } from './MoneyCurrencyInput';
2
- export type { MoneyCurrencyInputProps } from './MoneyCurrencyInput';
@@ -1,14 +0,0 @@
1
- import Money, { type Currency, type MoneyObject } from 'js-money';
2
- import { type InputProps } from 'semantic-ui-react';
3
- export interface MoneyInputProps {
4
- name?: string;
5
- onChange?: (value: Money) => void;
6
- value?: Money | MoneyObject;
7
- defaultCurrency?: Currency;
8
- onBlur?: (ev: any) => void;
9
- prefix?: string;
10
- showPrefix?: boolean;
11
- locked?: boolean;
12
- wholeNumber?: boolean;
13
- }
14
- export declare function MoneyInput(props: MoneyInputProps & Omit<InputProps, 'onChange'>): JSX.Element;
@@ -1,2 +0,0 @@
1
- export { MoneyInput } from './MoneyInput';
2
- export type { MoneyInputProps } from './MoneyInput';
@@ -1,13 +0,0 @@
1
- import Money from 'js-money';
2
- import { type MutableRefObject } from 'react';
3
- interface UseMoneyInputProps {
4
- value?: Money;
5
- onChange?: (value?: Money) => void;
6
- onSet?: (value?: Money) => void;
7
- prefix?: string;
8
- showPrefix?: boolean;
9
- wholeNumber?: boolean;
10
- }
11
- type SetValueFn = (value?: Money) => void;
12
- export declare function useMoneyInput(props: UseMoneyInputProps): [MutableRefObject<HTMLInputElement | null>, SetValueFn];
13
- export {};
@@ -1,8 +0,0 @@
1
- interface FormStepProps {
2
- children: JSX.Element;
3
- title?: string;
4
- stepKey: string;
5
- hidden?: boolean | ((state: any, step: number) => boolean);
6
- }
7
- export declare function FormStep(props: FormStepProps): JSX.Element;
8
- export {};
@@ -1,8 +0,0 @@
1
- interface StepProps {
2
- children?: JSX.Element | JSX.Element[];
3
- title?: string;
4
- step?: number;
5
- hidden?: boolean | ((state: any, step: number) => boolean);
6
- }
7
- export declare function Step(props: StepProps): JSX.Element;
8
- export {};