@fluentui/react-timepicker-compat 0.1.1 → 0.1.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 CHANGED
@@ -1,17 +1,29 @@
1
1
  # Change Log - @fluentui/react-timepicker-compat
2
2
 
3
- This log was last generated on Thu, 11 Jan 2024 09:02:16 GMT and should not be manually modified.
3
+ This log was last generated on Tue, 16 Jan 2024 13:07:05 GMT and should not be manually modified.
4
4
 
5
5
  <!-- Start content -->
6
6
 
7
+ ## [0.1.2](https://github.com/microsoft/fluentui/tree/@fluentui/react-timepicker-compat_v0.1.2)
8
+
9
+ Tue, 16 Jan 2024 13:07:05 GMT
10
+ [Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-timepicker-compat_v0.1.1..@fluentui/react-timepicker-compat_v0.1.2)
11
+
12
+ ### Patches
13
+
14
+ - fix: update types in styles to exclude "clearIcon" slot ([PR #30033](https://github.com/microsoft/fluentui/pull/30033) by olfedias@microsoft.com)
15
+ - Bump @fluentui/react-combobox to v9.6.0 ([PR #30299](https://github.com/microsoft/fluentui/pull/30299) by beachball)
16
+ - Bump @fluentui/react-field to v9.1.48 ([PR #30299](https://github.com/microsoft/fluentui/pull/30299) by beachball)
17
+ - Bump @fluentui/react-jsx-runtime to v9.0.25 ([PR #30299](https://github.com/microsoft/fluentui/pull/30299) by beachball)
18
+
7
19
  ## [0.1.1](https://github.com/microsoft/fluentui/tree/@fluentui/react-timepicker-compat_v0.1.1)
8
20
 
9
- Thu, 11 Jan 2024 09:02:16 GMT
21
+ Thu, 11 Jan 2024 09:04:29 GMT
10
22
  [Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-timepicker-compat_v0.1.0..@fluentui/react-timepicker-compat_v0.1.1)
11
23
 
12
24
  ### Patches
13
25
 
14
- - Bump @fluentui/react-combobox to v9.5.40 ([PR #30250](https://github.com/microsoft/fluentui/pull/30250) by beachball)
26
+ - Bump @fluentui/react-combobox to v9.5.40 ([PR #30259](https://github.com/microsoft/fluentui/pull/30259) by beachball)
15
27
 
16
28
  ## [0.1.0](https://github.com/microsoft/fluentui/tree/@fluentui/react-timepicker-compat_v0.1.0)
17
29
 
package/dist/index.d.ts CHANGED
@@ -94,7 +94,7 @@ export declare type TimePickerProps = Omit<ComponentProps<Partial<ComboboxSlots>
94
94
  parseTimeStringToDate?: (time: string | undefined) => TimeStringValidationResult;
95
95
  };
96
96
 
97
- export declare type TimePickerSlots = ComboboxSlots;
97
+ export declare type TimePickerSlots = Omit<ComboboxSlots, 'clearIcon'>;
98
98
 
99
99
  /**
100
100
  * State used in rendering TimePicker
@@ -1 +1 @@
1
- {"version":3,"sources":["TimePicker.types.ts"],"sourcesContent":["import * as React from 'react';\nimport type { ComboboxSlots, ComboboxState, ComboboxProps, SelectionEvents } from '@fluentui/react-combobox';\nimport type { ComponentProps } from '@fluentui/react-utilities';\n\nexport type Hour =\n | 0\n | 1\n | 2\n | 3\n | 4\n | 5\n | 6\n | 7\n | 8\n | 9\n | 10\n | 11\n | 12\n | 13\n | 14\n | 15\n | 16\n | 17\n | 18\n | 19\n | 20\n | 21\n | 22\n | 23\n | 24;\n\n/**\n * Data structure for rendering options in the TimePicker.\n */\nexport type TimePickerOption = {\n /**\n * The Date object associated with the option.\n */\n date: Date;\n\n /**\n * A unique identifier for the option.\n */\n key: string;\n\n /**\n * The display text for the option within the Combobox dropdown.\n */\n text: string;\n};\n\n/**\n * Error types returned by the `onValidationResult` callback.\n */\nexport type TimePickerErrorType = 'invalid-input' | 'out-of-bounds' | 'required-input';\n\nexport type TimeStringValidationResult = {\n date: Date | null;\n errorType?: TimePickerErrorType;\n};\n\nexport type TimePickerSlots = ComboboxSlots;\n\nexport type TimeSelectionEvents = SelectionEvents | React.FocusEvent<HTMLElement>;\nexport type TimeSelectionData = {\n /**\n * The Date object associated with the selected option. For freeform TimePicker it can also be the Date object parsed from the user input.\n */\n selectedTime: Date | null;\n /**\n * The display text for the selected option. For freeform TimePicker it can also be the value in user input.\n */\n selectedTimeText: string | undefined;\n /**\n * The error type for the selected option.\n */\n errorType: TimePickerErrorType | undefined;\n};\n\nexport type TimeFormatOptions = {\n /**\n * A string value indicating whether the 12-hour format (\"h11\", \"h12\") or the 24-hour format (\"h23\", \"h24\") should be used.\n * - 'h11' and 'h23' start with hour 0 and go up to 11 and 23 respectively.\n * - 'h12' and 'h24' start with hour 1 and go up to 12 and 24 respectively.\n * @default undefined\n */\n hourCycle?: 'h11' | 'h12' | 'h23' | 'h24' | undefined;\n\n /**\n * If true, show seconds in the dropdown options and consider seconds for default validation purposes.\n */\n showSeconds?: boolean;\n};\n\n/**\n * TimePicker Props\n */\nexport type TimePickerProps = Omit<ComponentProps<Partial<ComboboxSlots>, 'input'>, 'children' | 'size'> &\n Pick<\n ComboboxProps,\n | 'appearance'\n | 'defaultOpen'\n | 'defaultValue'\n | 'inlinePopup'\n | 'onOpenChange'\n | 'open'\n | 'placeholder'\n | 'positioning'\n | 'size'\n | 'value'\n | 'mountNode'\n | 'freeform'\n > &\n TimeFormatOptions & {\n /**\n * Start hour (inclusive) for the time range, 0-24.\n */\n startHour?: Hour;\n\n /**\n * End hour (exclusive) for the time range, 0-24.\n */\n endHour?: Hour;\n\n /**\n * Time increment, in minutes, of the options in the dropdown.\n */\n increment?: number;\n\n /**\n * The date in which all dropdown options are based off of.\n */\n dateAnchor?: Date;\n\n /**\n * Currently selected time in the TimePicker.\n */\n selectedTime?: Date | null;\n\n /**\n * Default selected time in the TimePicker, for uncontrolled scenarios.\n */\n defaultSelectedTime?: Date;\n\n /**\n * Callback for when a time selection is made.\n */\n onTimeChange?: (event: TimeSelectionEvents, data: TimeSelectionData) => void;\n\n /**\n * Customizes the formatting of date strings displayed in dropdown options.\n */\n formatDateToTimeString?: (date: Date) => string;\n\n /**\n * In the freeform TimePicker, customizes the parsing from the input time string into a Date and provides custom validation.\n */\n parseTimeStringToDate?: (time: string | undefined) => TimeStringValidationResult;\n };\n\n/**\n * State used in rendering TimePicker\n */\nexport type TimePickerState = ComboboxState &\n Required<Pick<TimePickerProps, 'freeform' | 'parseTimeStringToDate'>> & {\n /**\n * Submitted text from the input field. It is used to determine if the input value has changed when user submit a new value on Enter or blur from input.\n */\n submittedText: string | undefined;\n };\n"],"names":["React"],"mappings":"AAAA,YAAYA,WAAW,QAAQ"}
1
+ {"version":3,"sources":["TimePicker.types.ts"],"sourcesContent":["import * as React from 'react';\nimport type { ComboboxSlots, ComboboxState, ComboboxProps, SelectionEvents } from '@fluentui/react-combobox';\nimport type { ComponentProps } from '@fluentui/react-utilities';\n\nexport type Hour =\n | 0\n | 1\n | 2\n | 3\n | 4\n | 5\n | 6\n | 7\n | 8\n | 9\n | 10\n | 11\n | 12\n | 13\n | 14\n | 15\n | 16\n | 17\n | 18\n | 19\n | 20\n | 21\n | 22\n | 23\n | 24;\n\n/**\n * Data structure for rendering options in the TimePicker.\n */\nexport type TimePickerOption = {\n /**\n * The Date object associated with the option.\n */\n date: Date;\n\n /**\n * A unique identifier for the option.\n */\n key: string;\n\n /**\n * The display text for the option within the Combobox dropdown.\n */\n text: string;\n};\n\n/**\n * Error types returned by the `onValidationResult` callback.\n */\nexport type TimePickerErrorType = 'invalid-input' | 'out-of-bounds' | 'required-input';\n\nexport type TimeStringValidationResult = {\n date: Date | null;\n errorType?: TimePickerErrorType;\n};\n\nexport type TimePickerSlots = Omit<ComboboxSlots, 'clearIcon'>;\n\nexport type TimeSelectionEvents = SelectionEvents | React.FocusEvent<HTMLElement>;\nexport type TimeSelectionData = {\n /**\n * The Date object associated with the selected option. For freeform TimePicker it can also be the Date object parsed from the user input.\n */\n selectedTime: Date | null;\n /**\n * The display text for the selected option. For freeform TimePicker it can also be the value in user input.\n */\n selectedTimeText: string | undefined;\n /**\n * The error type for the selected option.\n */\n errorType: TimePickerErrorType | undefined;\n};\n\nexport type TimeFormatOptions = {\n /**\n * A string value indicating whether the 12-hour format (\"h11\", \"h12\") or the 24-hour format (\"h23\", \"h24\") should be used.\n * - 'h11' and 'h23' start with hour 0 and go up to 11 and 23 respectively.\n * - 'h12' and 'h24' start with hour 1 and go up to 12 and 24 respectively.\n * @default undefined\n */\n hourCycle?: 'h11' | 'h12' | 'h23' | 'h24' | undefined;\n\n /**\n * If true, show seconds in the dropdown options and consider seconds for default validation purposes.\n */\n showSeconds?: boolean;\n};\n\n/**\n * TimePicker Props\n */\nexport type TimePickerProps = Omit<ComponentProps<Partial<ComboboxSlots>, 'input'>, 'children' | 'size'> &\n Pick<\n ComboboxProps,\n | 'appearance'\n | 'defaultOpen'\n | 'defaultValue'\n | 'inlinePopup'\n | 'onOpenChange'\n | 'open'\n | 'placeholder'\n | 'positioning'\n | 'size'\n | 'value'\n | 'mountNode'\n | 'freeform'\n > &\n TimeFormatOptions & {\n /**\n * Start hour (inclusive) for the time range, 0-24.\n */\n startHour?: Hour;\n\n /**\n * End hour (exclusive) for the time range, 0-24.\n */\n endHour?: Hour;\n\n /**\n * Time increment, in minutes, of the options in the dropdown.\n */\n increment?: number;\n\n /**\n * The date in which all dropdown options are based off of.\n */\n dateAnchor?: Date;\n\n /**\n * Currently selected time in the TimePicker.\n */\n selectedTime?: Date | null;\n\n /**\n * Default selected time in the TimePicker, for uncontrolled scenarios.\n */\n defaultSelectedTime?: Date;\n\n /**\n * Callback for when a time selection is made.\n */\n onTimeChange?: (event: TimeSelectionEvents, data: TimeSelectionData) => void;\n\n /**\n * Customizes the formatting of date strings displayed in dropdown options.\n */\n formatDateToTimeString?: (date: Date) => string;\n\n /**\n * In the freeform TimePicker, customizes the parsing from the input time string into a Date and provides custom validation.\n */\n parseTimeStringToDate?: (time: string | undefined) => TimeStringValidationResult;\n };\n\n/**\n * State used in rendering TimePicker\n */\nexport type TimePickerState = ComboboxState &\n Required<Pick<TimePickerProps, 'freeform' | 'parseTimeStringToDate'>> & {\n /**\n * Submitted text from the input field. It is used to determine if the input value has changed when user submit a new value on Enter or blur from input.\n */\n submittedText: string | undefined;\n };\n"],"names":["React"],"mappings":"AAAA,YAAYA,WAAW,QAAQ"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fluentui/react-timepicker-compat",
3
- "version": "0.1.1",
3
+ "version": "0.1.2",
4
4
  "description": "Fluent UI TimePicker Compat Component",
5
5
  "main": "lib-commonjs/index.js",
6
6
  "module": "lib/index.js",
@@ -40,9 +40,9 @@
40
40
  },
41
41
  "dependencies": {
42
42
  "@fluentui/keyboard-keys": "^9.0.7",
43
- "@fluentui/react-combobox": "^9.5.40",
44
- "@fluentui/react-field": "^9.1.47",
45
- "@fluentui/react-jsx-runtime": "^9.0.24",
43
+ "@fluentui/react-combobox": "^9.6.0",
44
+ "@fluentui/react-field": "^9.1.48",
45
+ "@fluentui/react-jsx-runtime": "^9.0.25",
46
46
  "@fluentui/react-shared-contexts": "^9.13.2",
47
47
  "@fluentui/react-theme": "^9.1.16",
48
48
  "@fluentui/react-utilities": "^9.15.6",