@progress/kendo-vue-dateinputs 11.0.0 → 11.1.0-develop.1

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 (38) hide show
  1. package/calendar/components/Calendar.d.ts +13 -1
  2. package/calendar/components/Calendar.mjs +3 -0
  3. package/calendar/components/CalendarCell.d.ts +16 -2
  4. package/calendar/components/CalendarCell.mjs +1 -1
  5. package/calendar/components/CalendarHeaderTitle.d.ts +19 -2
  6. package/calendar/components/CalendarHeaderTitle.mjs +1 -1
  7. package/calendar/components/CalendarWeekCell.d.ts +10 -1
  8. package/calendar/components/CalendarWeekCell.mjs +1 -1
  9. package/calendar/components/interfaces/CalendarProps.d.ts +15 -9
  10. package/calendar/models/CalendarSettings.d.ts +40 -19
  11. package/calendar/models/CellContext.d.ts +45 -0
  12. package/common/PickerWrap.d.ts +1 -1
  13. package/dateinput/DateInput.d.ts +10 -1
  14. package/dateinput/DateInput.mjs +3 -0
  15. package/dateinput/interfaces/DateInputEventArguments.d.ts +12 -0
  16. package/dateinput/interfaces/DateInputProps.d.ts +6 -6
  17. package/dateinput/models/DateInputSettings.d.ts +58 -24
  18. package/datepicker/DatePicker.d.ts +11 -1
  19. package/datepicker/DatePicker.mjs +3 -0
  20. package/datepicker/interfaces/DatePickerEventArguments.d.ts +21 -0
  21. package/datepicker/interfaces/DatePickerProps.d.ts +15 -9
  22. package/datepicker/models/DatePickerSettings.d.ts +50 -32
  23. package/daterangepicker/DateRangePicker.d.ts +39 -9
  24. package/daterangepicker/DateRangePicker.mjs +3 -0
  25. package/daterangepicker/models/DateRangePickerCalendarSettings.d.ts +1 -1
  26. package/daterangepicker/models/DateRangePickerDateInputSettings.d.ts +1 -1
  27. package/daterangepicker/models/DateRangePickerPopupSettings.d.ts +1 -1
  28. package/daterangepicker/models/DateRangePickerSettings.d.ts +53 -32
  29. package/datetimepicker/DateTimePicker.d.ts +37 -8
  30. package/datetimepicker/DateTimePicker.mjs +3 -0
  31. package/datetimepicker/models/DateTimePickerSettings.d.ts +82 -44
  32. package/dist/cdn/js/kendo-vue-dateinputs.js +1 -1
  33. package/package-metadata.js +1 -1
  34. package/package-metadata.mjs +2 -2
  35. package/package.json +9 -9
  36. package/timepicker/TimePicker.d.ts +36 -7
  37. package/timepicker/TimePicker.mjs +3 -0
  38. package/timepicker/models/TimePickerSettings.d.ts +69 -36
@@ -12,7 +12,16 @@ import { NavigationEventArguments, CalendarChangeEvent } from './interfaces/Cale
12
12
  import { ViewWeekCellEventArguments, ViewWeekNameEventArguments } from './View';
13
13
  import { PropType } from 'vue';
14
14
  /**
15
- * @hidden
15
+ * Represents the [Kendo UI for Vue Calendar component](slug:overview_calendar).
16
+ * Use the Calendar to show dates in a month, year, decade, or century view and to let the user select a date.
17
+ *
18
+ * @example
19
+ * ```vue
20
+ * <Calendar :value="selectedDate" :min="minDate" :max="maxDate" :week-number="true" />
21
+ * ```
22
+ *
23
+ * @remarks
24
+ * Supported children components are: {@link CalendarCell}, {@link CalendarHeaderTitle}.
16
25
  */
17
26
  declare const Calendar: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
18
27
  activeRangeEnd: {
@@ -99,6 +108,9 @@ declare const Calendar: import('vue').DefineComponent<import('vue').ExtractPropT
99
108
  }, {
100
109
  element(): any;
101
110
  computedValue(): Date | null;
111
+ /**
112
+ * Moves the focus to the Calendar.
113
+ */
102
114
  focus(): void;
103
115
  handleBlur(): void;
104
116
  handleFocus(): void;
@@ -159,6 +159,9 @@ const ue = /* @__PURE__ */ S({
159
159
  computedValue() {
160
160
  return this.$data.valueDuringOnChange !== void 0 ? this.$data.valueDuringOnChange : this.$props.value !== void 0 ? this.$props.value : this.$props.modelValue !== void 0 ? this.$props.modelValue : this.$data.currentValue;
161
161
  },
162
+ /**
163
+ * Moves the focus to the Calendar.
164
+ */
162
165
  focus() {
163
166
  this.calendarViewList && this.calendarViewList.$el.firstElementChild.focus();
164
167
  },
@@ -8,14 +8,28 @@
8
8
  import { PropType } from 'vue';
9
9
  import { CellContext } from '../models/main';
10
10
  /**
11
- * The props which will be received by the custom cell of the [Calendar]({% slug api_dateinputs_calendarprops %}#toc-cell).
11
+ * Represents the props that the custom cell of the [Calendar](slug:api_dateinputs_calendarprops#toc-cell) receives.
12
12
  */
13
13
  export interface CalendarCellProps extends CellContext {
14
+ /**
15
+ * When `true`, the cell is disabled.
16
+ */
14
17
  isDisabled?: boolean;
18
+ /**
19
+ * The current view of the Calendar. The value is a `CalendarViewEnum` member.
20
+ */
15
21
  view?: number;
16
22
  }
17
23
  /**
18
- * @hidden
24
+ * Represents the [Kendo UI for Vue CalendarCell component](slug:custom_rendering_calendar#toc-cells-inside-the-view).
25
+ * Use the CalendarCell inside a custom `cell` template of the Calendar to keep the default cell markup and styles.
26
+ *
27
+ * @example
28
+ * ```vue
29
+ * <CalendarCell :value="cellProps.value" :is-selected="cellProps.isSelected" :is-today="cellProps.isToday" @click="handleClick">
30
+ * {{ cellProps.formattedValue }}
31
+ * </CalendarCell>
32
+ * ```
19
33
  */
20
34
  declare const CalendarCell: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
21
35
  isDisabled: PropType<boolean>;
@@ -45,7 +45,7 @@ const M = /* @__PURE__ */ k({
45
45
  // tslint:disable:max-line-length
46
46
  /**
47
47
  * @return
48
- * Returns a `<td />` element with a `<span class="k-link" />` inside to apply the styles. The text inside is the [`formattedValue`]({% slug api_dateinputs_calendarcellprops %}#toc-formattedvalue) of the `cell`.
48
+ * Returns a `<td />` element with a `<span class="k-link" />` inside that applies the styles. The text inside is the [`formattedValue`](slug:api_dateinputs_calendarcellprops#toc-formattedvalue) of the `cell`.
49
49
  */
50
50
  render() {
51
51
  const e = m(this), {
@@ -7,15 +7,32 @@
7
7
  */
8
8
  import { PropType } from 'vue';
9
9
  /**
10
- * The props which will be received by the custom header title of the [Calendar]({% slug api_dateinputs_calendarprops %}#toc-headertitle).
10
+ * Represents the props that the custom header title of the [Calendar](slug:api_dateinputs_calendarprops#toc-headertitle) receives.
11
11
  */
12
12
  export interface CalendarHeaderTitleProps {
13
+ /**
14
+ * The text of the header title.
15
+ */
13
16
  value?: string;
17
+ /**
18
+ * The `id` of the header title element.
19
+ */
14
20
  id?: string;
21
+ /**
22
+ * The current view of the Calendar. The value is a `CalendarViewEnum` member.
23
+ */
15
24
  view?: number;
16
25
  }
17
26
  /**
18
- * @hidden
27
+ * Represents the [Kendo UI for Vue CalendarHeaderTitle component](slug:custom_rendering_calendar#toc-titles-of-current-views).
28
+ * Use the CalendarHeaderTitle inside a custom `headerTitle` template of the Calendar to keep the default title button.
29
+ *
30
+ * @example
31
+ * ```vue
32
+ * <CalendarHeaderTitle :id="id" :value="value" :view="view" @click="handleClick">
33
+ * {{ value }}
34
+ * </CalendarHeaderTitle>
35
+ * ```
19
36
  */
20
37
  declare const CalendarHeaderTitle: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
21
38
  id: PropType<string>;
@@ -28,7 +28,7 @@ const m = /* @__PURE__ */ e({
28
28
  },
29
29
  /**
30
30
  * @return
31
- * Returns a `<button />` element with the [`value`]({% slug api_dateinputs_calendarheadertitleprops %}#toc-value) of the title as a child.
31
+ * Returns a `<button />` element with the [`value`](slug:api_dateinputs_calendarheadertitleprops#toc-value) of the title as a child.
32
32
  */
33
33
  render() {
34
34
  const t = r(this);
@@ -7,11 +7,20 @@
7
7
  */
8
8
  import { PropType } from 'vue';
9
9
  /**
10
- * The props which will be received by the custom week cell of the [Calendar]({% slug api_dateinputs_calendarprops %}#toc-weekcell).
10
+ * The props which will be received by the custom week cell of the [Calendar](slug:api_dateinputs_calendarprops#toc-weekcell).
11
11
  */
12
12
  export interface CalendarWeekCellProps {
13
+ /**
14
+ * The unique identifier of the week cell element.
15
+ */
13
16
  id?: string;
17
+ /**
18
+ * The week number value. `null` when not available.
19
+ */
14
20
  value?: number | null;
21
+ /**
22
+ * The CSS class name for styling the week cell.
23
+ */
15
24
  className?: string;
16
25
  }
17
26
  /**
@@ -18,7 +18,7 @@ const n = /* @__PURE__ */ i({
18
18
  },
19
19
  /**
20
20
  * @return
21
- * Returns a `<td />` element with the [`value`]({% slug api_dateinputs_calendarweekcellprops %}#toc-value) as a child.
21
+ * Returns a `<td />` element with the [`value`](slug:api_dateinputs_calendarweekcellprops#toc-value) as a child.
22
22
  */
23
23
  render() {
24
24
  const e = r(this);
@@ -9,17 +9,19 @@ import { CalendarSettings, SelectionRangeEnd, SelectionRange, CalendarMode } fro
9
9
  import { CalendarChangeEvent, CalendarWeekCellClickEvent } from '../../..';
10
10
  import { CalendarWeekNameClickEvent } from './CalendarEventArguments';
11
11
  /**
12
- * Represents the props of the [Kendo UI for Vue Calendar component]({% slug overview_calendar %}). The generic argument is passed to the `change` property and is used as a target in the [`CalendarChangeEvent`]({% slug api_dateinputs_calendarchangeevent %}) interface.
12
+ * Represents the props of the [Kendo UI for Vue Calendar component](slug:overview_calendar). The `change` event passes a [`CalendarChangeEvent`](slug:api_dateinputs_calendarchangeevent) object to its handler.
13
13
  */
14
14
  export interface CalendarProps extends CalendarSettings {
15
15
  /**
16
- * Specifies which end of the defined selection range will be marked as active.
16
+ * Sets which end of the selection range the Calendar marks as active.
17
17
  *
18
- * > If the selection range is undefined, the value is ignored.
18
+ * > If you do not set a selection range, the Calendar ignores this value.
19
19
  */
20
20
  activeRangeEnd?: SelectionRangeEnd;
21
21
  /**
22
- * If set to `true`, the component skips the validation of whether the `from` value is after the `to` value.
22
+ * When you set it to `true`, the Calendar skips the check that the `from` value comes before the `to` value.
23
+ *
24
+ * @default false
23
25
  */
24
26
  allowReverse?: boolean;
25
27
  /**
@@ -27,19 +29,21 @@ export interface CalendarProps extends CalendarSettings {
27
29
  */
28
30
  modelValue?: Date | Date[] | SelectionRange | null;
29
31
  /**
30
- * Sets the default value of the Calendar.
32
+ * Sets the initial value of the Calendar when you do not set `value`.
33
+ *
34
+ * @default null
31
35
  */
32
36
  defaultValue?: Date | Date[] | SelectionRange | null;
33
37
  /**
34
- * An event that is called after the value of the Calendar has changed.
38
+ * Fires after the value of the Calendar changes. The event name is `change`.
35
39
  */
36
40
  onChange?: (event: CalendarChangeEvent) => void;
37
41
  /**
38
- * An event called when the week number cell is clicked.
42
+ * Fires when the user clicks a week number cell. The event name is `weekcellclick`.
39
43
  */
40
44
  onWeekcellclick?: (event: CalendarWeekCellClickEvent) => void;
41
45
  /**
42
- * An event called when the week name cell is clicked.
46
+ * Fires when the user clicks a week name cell. The event name is `weeknameclick`.
43
47
  */
44
48
  onWeeknameclick?: (event: CalendarWeekNameClickEvent) => void;
45
49
  /**
@@ -47,7 +51,9 @@ export interface CalendarProps extends CalendarSettings {
47
51
  */
48
52
  value?: Date | Date[] | SelectionRange | null;
49
53
  /**
50
- * Sets the value of the Calendar.
54
+ * Sets the number of views that the Calendar shows side by side.
55
+ *
56
+ * @default 1
51
57
  */
52
58
  views: number;
53
59
  /**
@@ -10,24 +10,30 @@
10
10
  */
11
11
  export interface CalendarSettings {
12
12
  /**
13
- * Defines the bottommost view to which the user can navigate.
13
+ * Sets the lowest view to which the user can navigate.
14
+ *
15
+ * @default 'month'
14
16
  */
15
17
  bottomView?: string;
16
18
  /**
17
- * Sets the `className` of the Calendar.
19
+ * Sets a CSS class on the Calendar.
18
20
  */
19
21
  className?: string;
20
22
  /**
21
- * Sets the default active view of the Calendar.
22
- * If not set, the Calendar will display the month view.
23
+ * Sets the view that the Calendar shows first.
24
+ * If you do not set it, the Calendar shows the month view.
25
+ *
26
+ * @default 'month'
23
27
  */
24
28
  defaultActiveView?: string;
25
29
  /**
26
- * Determines whether the Calendar is disabled.
30
+ * When you set it to `true`, the Calendar is disabled.
31
+ *
32
+ * @default false
27
33
  */
28
34
  disabled?: boolean;
29
35
  /**
30
- * Sets the initial focused date of the Calendar.
36
+ * Sets the date that the Calendar focuses first.
31
37
  */
32
38
  focusedDate?: Date;
33
39
  /**
@@ -35,50 +41,65 @@ export interface CalendarSettings {
35
41
  */
36
42
  id?: string;
37
43
  /**
38
- * Sets the maximum allowed date of the Calendar. Defaults to `2099-12-31`.
44
+ * Sets the latest date that the user can select in the Calendar. Defaults to `2099-12-31`.
39
45
  */
40
46
  max?: Date;
41
47
  /**
42
- * Sets the minimum allowed date of the Calendar. Defaults to `1900-1-1`.
48
+ * Sets the earliest date that the user can select in the Calendar. Defaults to `1900-1-1`.
43
49
  */
44
50
  min?: Date;
45
51
  /**
46
- * Determines if the navigation sidebar will be displayed.
52
+ * When you set it to `true`, the Calendar shows the navigation sidebar.
53
+ *
54
+ * @default true
47
55
  */
48
56
  navigation?: boolean;
49
57
  /**
50
- * Fires each time the Calendar is blurred.
58
+ * Fires each time the Calendar loses focus. The event name is `blur`.
51
59
  */
52
60
  onBlur?: (event: any) => void;
53
61
  /**
54
- * Fires each time the Calendar is focused.
62
+ * Fires each time the Calendar receives focus. The event name is `focus`.
55
63
  */
56
64
  onFocus?: (event: any) => void;
57
65
  /**
58
66
  * Sets the `tabIndex` property of the Calendar.
67
+ *
68
+ * @remarks
69
+ * This property is related to accessibility.
59
70
  */
60
71
  tabIndex?: number;
61
72
  /**
62
- * Defines the topmost view to which the user can navigate.
73
+ * Sets the highest view to which the user can navigate.
74
+ *
75
+ * @default 'century'
63
76
  */
64
77
  topView?: string;
65
78
  /**
66
- * Determines if the week number column will be displayed.
79
+ * When you set it to `true`, the Calendar shows a week number column.
67
80
  */
68
81
  weekNumber?: boolean;
69
82
  /**
70
- * Enables the customization or the override of the default Calendar cell
71
- * ([see example]({% slug custom_rendering_calendar %}#toc-cells-inside-the-view)).
83
+ * Sets a custom template for the Calendar cells.
84
+ * The template receives the `CalendarCellProps` of each cell
85
+ * ([see example](slug:custom_rendering_calendar#toc-cells-inside-the-view)).
86
+ *
87
+ * @remarks
88
+ * Slot props: {@link CalendarCellProps}.
72
89
  */
73
90
  cell?: any;
74
91
  /**
75
- * Enables the customization or the override of the default week-column cell in the Calendar
76
- * ([see example]({% slug custom_rendering_calendar %}#toc-cells-inside-the-week-column)).
92
+ * Sets a custom template for the week-column cells of the Calendar
93
+ * ([see example](slug:custom_rendering_calendar#toc-cells-inside-the-week-column)).
77
94
  */
78
95
  weekCell?: any;
79
96
  /**
80
- * Enables the customization or the override of the default header title in the Calendar
81
- * ([see example]({% slug custom_rendering_calendar %}#toc-titles-of-current-views)).
97
+ * Sets a custom template for the header title of the Calendar.
98
+ * The template receives the `CalendarHeaderTitleProps` of the title
99
+ * ([see example](slug:custom_rendering_calendar#toc-titles-of-current-views)).
100
+ *
101
+ * @remarks
102
+ * Slot props: {@link CalendarHeaderTitleProps}.
82
103
  */
83
104
  headerTitle?: any;
84
105
  }
@@ -9,18 +9,63 @@
9
9
  * @hidden
10
10
  */
11
11
  export interface CellContext {
12
+ /**
13
+ * The formatted text of the cell.
14
+ */
12
15
  formattedValue: string;
16
+ /**
17
+ * The `id` of the cell. The Calendar uses it as the `aria-activedescendant` value when the cell is focused.
18
+ *
19
+ * @remarks
20
+ * This property is related to accessibility.
21
+ */
13
22
  id: string;
23
+ /**
24
+ * When `true`, the cell date is a Saturday or a Sunday.
25
+ */
14
26
  isWeekend: boolean;
27
+ /**
28
+ * When `true`, the cell is focused.
29
+ */
15
30
  isFocused: boolean;
31
+ /**
32
+ * When `true`, the cell is selected.
33
+ */
16
34
  isSelected: boolean;
35
+ /**
36
+ * When `true`, the cell is inside the selected range.
37
+ */
17
38
  isInRange: boolean;
39
+ /**
40
+ * When `true`, the cell is the start of the selected range.
41
+ */
18
42
  isRangeStart: boolean;
43
+ /**
44
+ * When `true`, the cell is the end of the selected range.
45
+ */
19
46
  isRangeEnd: boolean;
47
+ /**
48
+ * When `true`, the cell is between the start and the end of the selected range.
49
+ */
20
50
  isRangeMid: boolean;
51
+ /**
52
+ * When `true`, the cell is the last date of the view and the selected range continues into the next view.
53
+ */
21
54
  isRangeSplitEnd?: boolean;
55
+ /**
56
+ * When `true`, the cell is the first date of the view and the selected range continues from the previous view.
57
+ */
22
58
  isRangeSplitStart?: boolean;
59
+ /**
60
+ * When `true`, the cell date is today.
61
+ */
23
62
  isToday: boolean;
63
+ /**
64
+ * The `title` attribute of the cell.
65
+ */
24
66
  title?: string;
67
+ /**
68
+ * The date of the cell.
69
+ */
25
70
  value: Date;
26
71
  }
@@ -7,7 +7,7 @@
7
7
  */
8
8
  /**
9
9
  * Represents the props of the Kendo UI for
10
- * Vue [PickerWrap]({% slug api_dateinputs_pickerwrapprops %}) component.
10
+ * Vue [PickerWrap](slug:api_dateinputs_pickerwrapprops) component.
11
11
  */
12
12
  export interface PickerWrapProps {
13
13
  id?: string;
@@ -13,7 +13,13 @@ import { DateInputFocusEvent } from './interfaces/DateInputFocusEvent';
13
13
  import { DateInputBlurEvent } from './interfaces/DateInputBlurEvent';
14
14
  import { PropType } from 'vue';
15
15
  /**
16
- * @hidden
16
+ * Represents the [Kendo UI for Vue DateInput component](slug:overview_dateinput).
17
+ * Use the DateInput to let the user type a date and edit each part of it with the keyboard.
18
+ *
19
+ * @example
20
+ * ```vue
21
+ * <DateInput :value="orderDate" :format="'MM/dd/yyyy'" :min="minDate" :max="maxDate" @change="handleChange" />
22
+ * ```
17
23
  */
18
24
  declare const DateInput: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
19
25
  modelValue: PropType<Date>;
@@ -122,6 +128,9 @@ declare const DateInput: import('vue').DefineComponent<import('vue').ExtractProp
122
128
  }, {
123
129
  selection(): Selection;
124
130
  element(): HTMLInputElement | null;
131
+ /**
132
+ * Moves the focus to the input element of the DateInput.
133
+ */
125
134
  focus(e: any): void;
126
135
  handleFocus(e: FocusEvent): void;
127
136
  handleBlur(e: FocusEvent): void;
@@ -209,6 +209,9 @@ const se = "Please enter a valid value!", ve = /* @__PURE__ */ M({
209
209
  element() {
210
210
  return this._element;
211
211
  },
212
+ /**
213
+ * Moves the focus to the input element of the DateInput.
214
+ */
212
215
  focus(e) {
213
216
  this._element && this._element.focus(e);
214
217
  },
@@ -10,8 +10,20 @@
10
10
  * The generic argument sets the target type of the event. Defaults to `DateInput`.
11
11
  */
12
12
  export interface DateInputChangeEvent {
13
+ /**
14
+ * The original event that triggered the change.
15
+ */
13
16
  event?: any;
17
+ /**
18
+ * The new `value`.
19
+ */
14
20
  value: Date | null;
21
+ /**
22
+ * The component instance that fired the event.
23
+ */
15
24
  component: any;
25
+ /**
26
+ * The component instance that fired the event.
27
+ */
16
28
  target: any;
17
29
  }
@@ -8,11 +8,11 @@
8
8
  import { FormComponentProps } from '@progress/kendo-vue-common';
9
9
  import { DateInputSettings } from '../models/main';
10
10
  /**
11
- * Represents the props of the [Kendo UI for Vue DateInput component]({% slug overview_dateinput %}). The generic argument is passed to the `change` property and is used as a target in the [`DateInputChangeEvent`]({% slug api_dateinputs_dateinputchangeevent %}) interface.
11
+ * Represents the props of the [Kendo UI for Vue DateInput component](slug:overview_dateinput). The `change` event passes a [`DateInputChangeEvent`](slug:api_dateinputs_dateinputchangeevent) object to its handler.
12
12
  */
13
13
  export interface DateInputProps extends FormComponentProps, DateInputSettings {
14
14
  /**
15
- * Specifies the value of the placeholder.
15
+ * Sets the placeholder text of the DateInput.
16
16
  */
17
17
  placeholder?: string;
18
18
  /**
@@ -20,19 +20,19 @@ export interface DateInputProps extends FormComponentProps, DateInputSettings {
20
20
  */
21
21
  modelValue?: Date | null;
22
22
  /**
23
- * Specifies the value of the DateInput.
23
+ * Sets the value of the DateInput.
24
24
  */
25
25
  value?: Date | null;
26
26
  /**
27
- * Specifies the validate of the DateInput.
27
+ * Sets whether the DateInput validates its value.
28
28
  */
29
29
  validate?: boolean;
30
30
  /**
31
- * Specifies the default value of the DateInput. If `value` is not set, this value will correspond to the initial value.
31
+ * Sets the initial value of the DateInput when you do not set `value`.
32
32
  */
33
33
  defaultValue?: Date | null;
34
34
  /**
35
- * Determines the event handler that will be fired when the user edits the value ([see example]({% slug dateranges_dateinput %}).
35
+ * Fires when the user edits the value. The event name is `change` ([see example](slug:dateranges_dateinput)).
36
36
  */
37
37
  onChange?: (event: any) => void;
38
38
  }