@instructure/ui-date-input 9.5.2-snapshot-1 → 9.5.2
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/CHANGELOG.md +5 -2
- package/es/DateInput2/index.js +22 -17
- package/lib/DateInput2/index.js +22 -17
- package/package.json +20 -20
- package/src/DateInput2/index.tsx +35 -41
- package/src/DateInput2/props.ts +10 -4
- package/src/index.ts +1 -0
- package/tsconfig.build.tsbuildinfo +1 -1
- package/types/DateInput2/index.d.ts +38 -1
- package/types/DateInput2/index.d.ts.map +1 -1
- package/types/DateInput2/props.d.ts +5 -4
- package/types/DateInput2/props.d.ts.map +1 -1
- package/types/index.d.ts +1 -0
- package/types/index.d.ts.map +1 -1
@@ -1,5 +1,7 @@
|
|
1
|
+
import type { SyntheticEvent } from 'react';
|
1
2
|
import { jsx } from '@instructure/emotion';
|
2
3
|
import type { DateInput2Props } from './props';
|
4
|
+
import type { FormMessage } from '@instructure/ui-form-field';
|
3
5
|
/**
|
4
6
|
---
|
5
7
|
category: components
|
@@ -7,7 +9,42 @@ category: components
|
|
7
9
|
**/
|
8
10
|
declare const DateInput2: {
|
9
11
|
({ renderLabel, screenReaderLabels, isRequired, interaction, size, isInline, value, messages, width, onChange, onBlur, withYearPicker, onRequestValidateDate, invalidDateErrorMessage, locale, timezone, placeholder, ...rest }: DateInput2Props): jsx.JSX.Element;
|
10
|
-
propTypes: import("@instructure/shared-types").PropValidators<keyof
|
12
|
+
propTypes: import("@instructure/shared-types").PropValidators<keyof {
|
13
|
+
renderLabel: import("@instructure/shared-types").Renderable;
|
14
|
+
screenReaderLabels: {
|
15
|
+
calendarIcon: string;
|
16
|
+
prevMonthButton: string;
|
17
|
+
nextMonthButton: string;
|
18
|
+
};
|
19
|
+
value?: string;
|
20
|
+
size?: "small" | "medium" | "large";
|
21
|
+
placeholder?: string;
|
22
|
+
onChange?: (event:
|
23
|
+
/**
|
24
|
+
---
|
25
|
+
category: components
|
26
|
+
---
|
27
|
+
**/
|
28
|
+
React.SyntheticEvent, value: string) => void;
|
29
|
+
onBlur?: (event: React.SyntheticEvent) => void;
|
30
|
+
interaction?: "enabled" | "disabled" | "readonly";
|
31
|
+
isRequired?: boolean;
|
32
|
+
isInline?: boolean;
|
33
|
+
width?: string;
|
34
|
+
messages?: FormMessage[];
|
35
|
+
onRequestShowCalendar?: (event: SyntheticEvent) => void;
|
36
|
+
onRequestHideCalendar?: (event: SyntheticEvent) => void;
|
37
|
+
onRequestValidateDate?: (value?: string, internalValidationPassed?: boolean) => void | FormMessage[];
|
38
|
+
invalidDateErrorMessage?: string;
|
39
|
+
locale?: string;
|
40
|
+
timezone?: string;
|
41
|
+
withYearPicker?: {
|
42
|
+
screenReaderLabel: string;
|
43
|
+
onRequestYearChange?: (e: SyntheticEvent, requestedYear: number) => void;
|
44
|
+
startYear: number;
|
45
|
+
endYear: number;
|
46
|
+
};
|
47
|
+
}>;
|
11
48
|
};
|
12
49
|
export default DateInput2;
|
13
50
|
export { DateInput2 };
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/DateInput2/index.tsx"],"names":[],"mappings":"
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/DateInput2/index.tsx"],"names":[],"mappings":"AA0BA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAA;AAa3C,OAAO,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAA;AAG1C,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,SAAS,CAAA;AAC9C,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,4BAA4B,CAAA;AAS7D;;;;GAIG;AACH,QAAA,MAAM,UAAU;qOAmBb,eAAe;;;;;;;;;;;;QAxBlB;;;;WAIG;QACH,MAJC,cACU;yBAOG,MAAO,cACb;;;;;;;;sCAyDU,CAAC,kCAAsC,CAAC;;;;;;+BA0EpD,CAAF;;;;;CAsDH,CAAA;AAID,eAAe,UAAU,CAAA;AACzB,OAAO,EAAE,UAAU,EAAE,CAAA"}
|
@@ -1,7 +1,7 @@
|
|
1
|
-
import type { SyntheticEvent } from 'react';
|
1
|
+
import type { SyntheticEvent, InputHTMLAttributes } from 'react';
|
2
2
|
import type { FormMessage } from '@instructure/ui-form-field';
|
3
|
-
import type { Renderable, PropValidators } from '@instructure/shared-types';
|
4
|
-
type
|
3
|
+
import type { OtherHTMLAttributes, Renderable, PropValidators } from '@instructure/shared-types';
|
4
|
+
type DateInput2OwnProps = {
|
5
5
|
/**
|
6
6
|
* Specifies the input label.
|
7
7
|
*/
|
@@ -125,7 +125,8 @@ type DateInput2Props = {
|
|
125
125
|
endYear: number;
|
126
126
|
};
|
127
127
|
};
|
128
|
-
type PropKeys = keyof
|
128
|
+
type PropKeys = keyof DateInput2OwnProps;
|
129
|
+
type DateInput2Props = DateInput2OwnProps & OtherHTMLAttributes<DateInput2OwnProps, InputHTMLAttributes<DateInput2OwnProps & Element>>;
|
129
130
|
declare const propTypes: PropValidators<PropKeys>;
|
130
131
|
export type { DateInput2Props };
|
131
132
|
export { propTypes };
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"props.d.ts","sourceRoot":"","sources":["../../src/DateInput2/props.ts"],"names":[],"mappings":"AAyBA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAA;
|
1
|
+
{"version":3,"file":"props.d.ts","sourceRoot":"","sources":["../../src/DateInput2/props.ts"],"names":[],"mappings":"AAyBA,OAAO,KAAK,EAAE,cAAc,EAAE,mBAAmB,EAAE,MAAM,OAAO,CAAA;AAIhE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,4BAA4B,CAAA;AAC7D,OAAO,KAAK,EAAE,mBAAmB,EAAE,UAAU,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAA;AAEhG,KAAK,kBAAkB,GAAG;IACxB;;OAEG;IACH,WAAW,EAAE,UAAU,CAAA;IACvB,kBAAkB,EAAE;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AAA;IAEjB;;;;;;;;;;OAUG;IACH,cAAc,CAAC,EAAE;QACf,iBAAiB,EAAE,MAAM,CAAA;QACzB,mBAAmB,CAAC,EAAE,CAAC,CAAC,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,KAAK,IAAI,CAAA;QACxE,SAAS,EAAE,MAAM,CAAA;QACjB,OAAO,EAAE,MAAM,CAAA;KAChB,CAAA;CACF,CAAA;AAED,KAAK,QAAQ,GAAG,MAAM,kBAAkB,CAAA;AAExC,KAAK,eAAe,GAAG,kBAAkB,GACvC,mBAAmB,CACjB,kBAAkB,EAClB,mBAAmB,CAAC,kBAAkB,GAAG,OAAO,CAAC,CAClD,CAAA;AAEH,QAAA,MAAM,SAAS,EAAE,cAAc,CAAC,QAAQ,CAuBvC,CAAA;AAED,YAAY,EAAE,eAAe,EAAE,CAAA;AAC/B,OAAO,EAAE,SAAS,EAAE,CAAA"}
|
package/types/index.d.ts
CHANGED
package/types/index.d.ts.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAwBA,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAA;AACvC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AACzC,YAAY,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAA"}
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAwBA,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAA;AACvC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AACzC,YAAY,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAA;AACvD,YAAY,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAA"}
|