@progress/kendo-react-inputs 5.6.0-next.202208310638 → 5.6.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 (60) hide show
  1. package/LICENSE.md +2 -2
  2. package/README.md +4 -4
  3. package/about.md +1 -1
  4. package/dist/cdn/js/kendo-react-inputs.js +1 -1
  5. package/dist/es/colors/ColorPalette.d.ts +1 -1
  6. package/dist/es/main.d.ts +2 -0
  7. package/dist/es/main.js +2 -0
  8. package/dist/es/maskedtextbox/MaskedTextBox.d.ts +1 -1
  9. package/dist/es/messages/index.d.ts +15 -0
  10. package/dist/es/messages/index.js +15 -0
  11. package/dist/es/package-metadata.js +1 -1
  12. package/dist/es/signature/Signature.d.ts +14 -0
  13. package/dist/es/signature/Signature.js +346 -0
  14. package/dist/es/signature/interfaces/SignatureBlurEvent.d.ts +7 -0
  15. package/dist/es/signature/interfaces/SignatureBlurEvent.js +1 -0
  16. package/dist/es/signature/interfaces/SignatureChangeEvent.d.ts +11 -0
  17. package/dist/es/signature/interfaces/SignatureChangeEvent.js +1 -0
  18. package/dist/es/signature/interfaces/SignatureCloseEvent.d.ts +7 -0
  19. package/dist/es/signature/interfaces/SignatureCloseEvent.js +1 -0
  20. package/dist/es/signature/interfaces/SignatureFocusEvent.d.ts +7 -0
  21. package/dist/es/signature/interfaces/SignatureFocusEvent.js +1 -0
  22. package/dist/es/signature/interfaces/SignatureHandle.d.ts +34 -0
  23. package/dist/es/signature/interfaces/SignatureHandle.js +1 -0
  24. package/dist/es/signature/interfaces/SignatureOpenEvent.d.ts +7 -0
  25. package/dist/es/signature/interfaces/SignatureOpenEvent.js +1 -0
  26. package/dist/es/signature/interfaces/SignatureProps.d.ts +196 -0
  27. package/dist/es/signature/interfaces/SignatureProps.js +1 -0
  28. package/dist/es/signature/interfaces/index.d.ts +7 -0
  29. package/dist/es/signature/interfaces/index.js +1 -0
  30. package/dist/es/signature/utils/index.d.ts +4 -0
  31. package/dist/es/signature/utils/index.js +10 -0
  32. package/dist/npm/colors/ColorPalette.d.ts +1 -1
  33. package/dist/npm/main.d.ts +2 -0
  34. package/dist/npm/main.js +2 -0
  35. package/dist/npm/maskedtextbox/MaskedTextBox.d.ts +1 -1
  36. package/dist/npm/messages/index.d.ts +15 -0
  37. package/dist/npm/messages/index.js +16 -1
  38. package/dist/npm/package-metadata.js +1 -1
  39. package/dist/npm/signature/Signature.d.ts +14 -0
  40. package/dist/npm/signature/Signature.js +349 -0
  41. package/dist/npm/signature/interfaces/SignatureBlurEvent.d.ts +7 -0
  42. package/dist/npm/signature/interfaces/SignatureBlurEvent.js +2 -0
  43. package/dist/npm/signature/interfaces/SignatureChangeEvent.d.ts +11 -0
  44. package/dist/npm/signature/interfaces/SignatureChangeEvent.js +2 -0
  45. package/dist/npm/signature/interfaces/SignatureCloseEvent.d.ts +7 -0
  46. package/dist/npm/signature/interfaces/SignatureCloseEvent.js +2 -0
  47. package/dist/npm/signature/interfaces/SignatureFocusEvent.d.ts +7 -0
  48. package/dist/npm/signature/interfaces/SignatureFocusEvent.js +2 -0
  49. package/dist/npm/signature/interfaces/SignatureHandle.d.ts +34 -0
  50. package/dist/npm/signature/interfaces/SignatureHandle.js +2 -0
  51. package/dist/npm/signature/interfaces/SignatureOpenEvent.d.ts +7 -0
  52. package/dist/npm/signature/interfaces/SignatureOpenEvent.js +2 -0
  53. package/dist/npm/signature/interfaces/SignatureProps.d.ts +196 -0
  54. package/dist/npm/signature/interfaces/SignatureProps.js +2 -0
  55. package/dist/npm/signature/interfaces/index.d.ts +7 -0
  56. package/dist/npm/signature/interfaces/index.js +2 -0
  57. package/dist/npm/signature/utils/index.d.ts +4 -0
  58. package/dist/npm/signature/utils/index.js +14 -0
  59. package/dist/systemjs/kendo-react-inputs.js +1 -1
  60. package/package.json +20 -16
@@ -0,0 +1,196 @@
1
+ /// <reference types="react" />
2
+ import { FormComponentProps } from '@progress/kendo-react-common';
3
+ import { SignatureChangeEvent } from './SignatureChangeEvent';
4
+ import { SignatureFocusEvent } from './SignatureFocusEvent';
5
+ import { SignatureBlurEvent } from './SignatureBlurEvent';
6
+ import { SignatureOpenEvent } from './SignatureOpenEvent';
7
+ import { SignatureCloseEvent } from './SignatureCloseEvent';
8
+ /**
9
+ * Represents the props of the [KendoReact Signature component]({% slug overview_signature %}).
10
+ */
11
+ export interface SignatureProps extends FormComponentProps {
12
+ /**
13
+ * Sets a class of the Signature DOM element.
14
+ */
15
+ className?: string;
16
+ /**
17
+ * Specifies the value of the Signature.
18
+ *
19
+ * The value is an image encoded as a [Data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URLs).
20
+ */
21
+ value?: string;
22
+ /**
23
+ * Specifies the width of the Signature in pixels.
24
+ */
25
+ width?: number;
26
+ /**
27
+ * Specifies the height of the Signature in pixels.
28
+ */
29
+ height?: number;
30
+ /**
31
+ * Sets the `tabIndex` property of the Signature.
32
+ */
33
+ tabIndex?: number;
34
+ /**
35
+ * Sets the `id` of the Signature DOM element.
36
+ */
37
+ id?: string;
38
+ /**
39
+ * Represents the `dir` HTML attribute.
40
+ */
41
+ dir?: string;
42
+ /**
43
+ * Specifies the name of the Signature input.
44
+ */
45
+ name?: string;
46
+ /**
47
+ * Identifies the element(s) which will describe the component, similar to [HTML aria-describedby attribute](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Techniques/Using_the_aria-describedby_attribute).
48
+ * For example these elements could contain error or hint message.
49
+ */
50
+ ariaDescribedBy?: string;
51
+ /**
52
+ * Identifies the element(s) which will label the component.
53
+ */
54
+ ariaLabelledBy?: string;
55
+ /**
56
+ * The accessible label of the component.
57
+ */
58
+ ariaLabel?: string;
59
+ /**
60
+ * Determines whether the Signature is in its read-only state.
61
+ */
62
+ readOnly?: boolean;
63
+ /**
64
+ * Determines whether the Signature is in its disabled state.
65
+ */
66
+ disabled?: boolean;
67
+ /**
68
+ * Configures the `size` of the Signature.
69
+ *
70
+ * The available options are:
71
+ * - small
72
+ * - medium
73
+ * - large
74
+ * - null&mdash;Does not set a size `className`.
75
+ *
76
+ * @default `medium`
77
+ */
78
+ size?: null | 'small' | 'medium' | 'large';
79
+ /**
80
+ * Configures the `roundness` of the Signature.
81
+ *
82
+ * The available options are:
83
+ * - small
84
+ * - medium
85
+ * - large
86
+ * - full
87
+ * - null&mdash;Does not set a rounded `className`.
88
+ *
89
+ * @default `medium`
90
+ */
91
+ rounded?: null | 'small' | 'medium' | 'large' | 'full';
92
+ /**
93
+ * Configures the `fillMode` of the Signature.
94
+ *
95
+ * The available options are:
96
+ * - solid
97
+ * - outline
98
+ * - flat
99
+ * - null&mdash;Does not set a fillMode `className`.
100
+ *
101
+ * @default `solid`
102
+ */
103
+ fillMode?: null | 'solid' | 'flat' | 'outline';
104
+ /**
105
+ * The stroke color of the signature.
106
+ *
107
+ * Accepts CSS color names and hex values.
108
+ *
109
+ * @default '#000000'
110
+ */
111
+ color?: string;
112
+ /**
113
+ * The background color of the signature.
114
+ *
115
+ * Accepts CSS color names and hex values.
116
+ *
117
+ * @default '#ffffff'
118
+ */
119
+ backgroundColor?: string;
120
+ /**
121
+ * The stroke width of the signature.
122
+ *
123
+ * @default 1
124
+ */
125
+ strokeWidth?: number;
126
+ /**
127
+ * A flag indicating whether to smooth out signature lines.
128
+ *
129
+ * @default false
130
+ */
131
+ smooth?: boolean;
132
+ /**
133
+ * A flag indicating if the signature can be maximized.
134
+ *
135
+ * @default true
136
+ */
137
+ maximizable?: boolean;
138
+ /**
139
+ * Sets the open and close state of the Signature.
140
+ */
141
+ open?: boolean;
142
+ /**
143
+ * The scale factor for the popup.
144
+ *
145
+ * The Signature width and height will be multiplied by the scale when showing the popup.
146
+ *
147
+ * @default 3
148
+ */
149
+ popupScale?: number;
150
+ /**
151
+ * The scale factor for the exported image.
152
+ *
153
+ * The Signature width and height will be multiplied by the scale when converting the signature to an image.
154
+ *
155
+ * @default 2
156
+ */
157
+ exportScale?: number;
158
+ /**
159
+ * A flag indicating whether the dotted line should be displayed in the background.
160
+ *
161
+ * @default false
162
+ */
163
+ hideLine?: boolean;
164
+ /**
165
+ * Represents the `style` HTML attribute.
166
+ */
167
+ style?: React.CSSProperties;
168
+ /**
169
+ * Represents the input element `style` HTML attribute.
170
+ */
171
+ inputStyle?: React.CSSProperties;
172
+ /**
173
+ * Determines the event handler that will be fired when the user edits the value.
174
+ */
175
+ onChange?: (event: SignatureChangeEvent) => void;
176
+ /**
177
+ * The event handler that will be fired when Signature is focused.
178
+ */
179
+ onFocus?: (event: SignatureFocusEvent) => void;
180
+ /**
181
+ * The event handler that will be fired when Signature is blurred.
182
+ */
183
+ onBlur?: (event: SignatureBlurEvent) => void;
184
+ /**
185
+ * The event handler that will be fired when Signature popup is open.
186
+ */
187
+ onOpen?: (event: SignatureOpenEvent) => void;
188
+ /**
189
+ * The event handler that will be fired when Signature popup is closed.
190
+ */
191
+ onClose?: (event: SignatureCloseEvent) => void;
192
+ /** @hidden */
193
+ children?: React.ReactNode;
194
+ /** @hidden */
195
+ maximized?: boolean;
196
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,7 @@
1
+ export { SignatureBlurEvent } from './SignatureBlurEvent';
2
+ export { SignatureChangeEvent } from './SignatureChangeEvent';
3
+ export { SignatureCloseEvent } from './SignatureCloseEvent';
4
+ export { SignatureFocusEvent } from './SignatureFocusEvent';
5
+ export { SignatureHandle } from './SignatureHandle';
6
+ export { SignatureOpenEvent } from './SignatureOpenEvent';
7
+ export { SignatureProps } from './SignatureProps';
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,4 @@
1
+ /**
2
+ * @hidden
3
+ */
4
+ export declare function hasParent(element: any, parent: any): boolean;
@@ -0,0 +1,10 @@
1
+ /**
2
+ * @hidden
3
+ */
4
+ export function hasParent(element, parent) {
5
+ var current = element;
6
+ while (current && current !== parent) {
7
+ current = current.parentNode;
8
+ }
9
+ return current ? true : false;
10
+ }
@@ -28,7 +28,7 @@ export declare class ColorPaletteWithoutContext extends React.Component<ColorPal
28
28
  * @hidden
29
29
  */
30
30
  static propTypes: {
31
- palette: PropTypes.Requireable<string | string[]>;
31
+ palette: PropTypes.Requireable<NonNullable<string | string[] | null | undefined>>;
32
32
  columns: PropTypes.Requireable<number>;
33
33
  tileSize: PropTypes.Requireable<any>;
34
34
  defaultValue: PropTypes.Requireable<string>;
@@ -50,6 +50,8 @@ export * from './textarea/interfaces/TextAreaFocusEvent';
50
50
  export * from './rating/Rating';
51
51
  export * from './rating/RatingItem';
52
52
  export * from './rating/models/index';
53
+ export * from './signature/Signature';
54
+ export * from './signature/interfaces';
53
55
  export { TextBox, TextBoxProps, TextBoxHandle, TextBoxChangeEvent } from './textbox/Textbox';
54
56
  export { InputClearValue, InputClearValueProps, InputClearValueHandle } from './input/InputClearValue';
55
57
  export { InputPrefix, InputPrefixProps, InputPrefixHandle } from './input/InputPrefix';
package/dist/npm/main.js CHANGED
@@ -75,6 +75,8 @@ __exportStar(require("./textarea/interfaces/TextAreaFocusEvent"), exports);
75
75
  __exportStar(require("./rating/Rating"), exports);
76
76
  __exportStar(require("./rating/RatingItem"), exports);
77
77
  __exportStar(require("./rating/models/index"), exports);
78
+ __exportStar(require("./signature/Signature"), exports);
79
+ __exportStar(require("./signature/interfaces"), exports);
78
80
  var Textbox_1 = require("./textbox/Textbox");
79
81
  Object.defineProperty(exports, "TextBox", { enumerable: true, get: function () { return Textbox_1.TextBox; } });
80
82
  var InputClearValue_1 = require("./input/InputClearValue");
@@ -26,7 +26,7 @@ export declare class MaskedTextBoxWithoutContext extends React.Component<MaskedT
26
26
  className: PropTypes.Requireable<string>;
27
27
  ariaLabelledBy: PropTypes.Requireable<string>;
28
28
  ariaDescribedBy: PropTypes.Requireable<string>;
29
- width: PropTypes.Requireable<string | number>;
29
+ width: PropTypes.Requireable<NonNullable<string | number | null | undefined>>;
30
30
  tabIndex: PropTypes.Requireable<number>;
31
31
  accessKey: PropTypes.Requireable<string>;
32
32
  disabled: PropTypes.Requireable<boolean>;
@@ -102,6 +102,18 @@ export declare const colorPickerDropdownButtonAriaLabel = "colorPicker.dropdownB
102
102
  * @hidden
103
103
  */
104
104
  export declare const ratingAriaLabel = "rating.ariaLabel";
105
+ /**
106
+ * @hidden
107
+ */
108
+ export declare const signatureClear = "signature.clear";
109
+ /**
110
+ * @hidden
111
+ */
112
+ export declare const signatureMaximize = "signature.maximize";
113
+ /**
114
+ * @hidden
115
+ */
116
+ export declare const signatureMinimize = "signature.minimize";
105
117
  /**
106
118
  * @hidden
107
119
  */
@@ -132,4 +144,7 @@ export declare const messages: {
132
144
  "switch.validation": string;
133
145
  "colorPicker.dropdownButtonAriaLabel": string;
134
146
  "rating.ariaLabel": string;
147
+ "signature.clear": string;
148
+ "signature.maximize": string;
149
+ "signature.minimize": string;
135
150
  };
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  var _a;
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
- exports.messages = exports.ratingAriaLabel = exports.colorPickerDropdownButtonAriaLabel = exports.switchValidation = exports.radioButtonValidation = exports.checkboxOptionalText = exports.checkboxValidation = exports.flatColorPickerApplyBtn = exports.flatColorPickerCancelBtn = exports.colorGradientToggleInputsButton = exports.colorGradientAlphaSliderLabel = exports.colorGradientHueSliderLabel = exports.colorGradientFail = exports.colorGradientPass = exports.colorGradientAAALevel = exports.colorGradientAALevel = exports.colorGradientContrastRatio = exports.colorGradientHex = exports.colorGradientA = exports.colorGradientB = exports.colorGradientG = exports.colorGradientR = exports.sliderDragTitle = exports.sliderDecreaseValue = exports.sliderIncreaseValue = exports.numericDecreaseValue = exports.numericIncreaseValue = void 0;
4
+ exports.messages = exports.signatureMinimize = exports.signatureMaximize = exports.signatureClear = exports.ratingAriaLabel = exports.colorPickerDropdownButtonAriaLabel = exports.switchValidation = exports.radioButtonValidation = exports.checkboxOptionalText = exports.checkboxValidation = exports.flatColorPickerApplyBtn = exports.flatColorPickerCancelBtn = exports.colorGradientToggleInputsButton = exports.colorGradientAlphaSliderLabel = exports.colorGradientHueSliderLabel = exports.colorGradientFail = exports.colorGradientPass = exports.colorGradientAAALevel = exports.colorGradientAALevel = exports.colorGradientContrastRatio = exports.colorGradientHex = exports.colorGradientA = exports.colorGradientB = exports.colorGradientG = exports.colorGradientR = exports.sliderDragTitle = exports.sliderDecreaseValue = exports.sliderIncreaseValue = exports.numericDecreaseValue = exports.numericIncreaseValue = void 0;
5
5
  /**
6
6
  * @hidden
7
7
  */
@@ -106,6 +106,18 @@ exports.colorPickerDropdownButtonAriaLabel = 'colorPicker.dropdownButtonAriaLabe
106
106
  * @hidden
107
107
  */
108
108
  exports.ratingAriaLabel = 'rating.ariaLabel';
109
+ /**
110
+ * @hidden
111
+ */
112
+ exports.signatureClear = 'signature.clear';
113
+ /**
114
+ * @hidden
115
+ */
116
+ exports.signatureMaximize = 'signature.maximize';
117
+ /**
118
+ * @hidden
119
+ */
120
+ exports.signatureMinimize = 'signature.minimize';
109
121
  /**
110
122
  * @hidden
111
123
  */
@@ -136,4 +148,7 @@ exports.messages = (_a = {},
136
148
  _a[exports.switchValidation] = 'Please turn on if you want to proceed!',
137
149
  _a[exports.colorPickerDropdownButtonAriaLabel] = 'Select',
138
150
  _a[exports.ratingAriaLabel] = 'Rating',
151
+ _a[exports.signatureClear] = 'Clear',
152
+ _a[exports.signatureMaximize] = 'Maximize',
153
+ _a[exports.signatureMinimize] = 'Minimize',
139
154
  _a);
@@ -8,7 +8,7 @@ exports.packageMetadata = {
8
8
  name: '@progress/kendo-react-inputs',
9
9
  productName: 'KendoReact',
10
10
  productCodes: ['KENDOUIREACT', 'KENDOUICOMPLETE'],
11
- publishDate: 1661926871,
11
+ publishDate: 1662550544,
12
12
  version: '',
13
13
  licensingDocsUrl: 'https://www.telerik.com/kendo-react-ui/my-license/?utm_medium=product&utm_source=kendoreact&utm_campaign=kendo-ui-react-purchase-license-keys-warning'
14
14
  };
@@ -0,0 +1,14 @@
1
+ import * as React from 'react';
2
+ import { SignatureHandle } from './interfaces/SignatureHandle';
3
+ import { SignatureProps } from './interfaces/SignatureProps';
4
+ /**
5
+ * Represents the PropsContext of the `Signature` component.
6
+ * Used for global configuration of all `Signature` instances.
7
+ *
8
+ * For more information, refer to the [Inputs Props Context]({% slug props-context_inputs %}) article.
9
+ */
10
+ export declare const SignaturePropsContext: React.Context<(p: SignatureProps) => SignatureProps>;
11
+ /**
12
+ * Represents the [KendoReact Signature component]({% slug overview_signature %}).
13
+ */
14
+ export declare const Signature: React.ForwardRefExoticComponent<SignatureProps & React.RefAttributes<SignatureHandle | null>>;