@fluentui/react-combobox 9.2.8 → 9.2.9
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.json
CHANGED
|
@@ -2,7 +2,52 @@
|
|
|
2
2
|
"name": "@fluentui/react-combobox",
|
|
3
3
|
"entries": [
|
|
4
4
|
{
|
|
5
|
-
"date": "
|
|
5
|
+
"date": "Wed, 12 Apr 2023 09:28:15 GMT",
|
|
6
|
+
"tag": "@fluentui/react-combobox_v9.2.9",
|
|
7
|
+
"version": "9.2.9",
|
|
8
|
+
"comments": {
|
|
9
|
+
"patch": [
|
|
10
|
+
{
|
|
11
|
+
"author": "sarah.higley@microsoft.com",
|
|
12
|
+
"package": "@fluentui/react-combobox",
|
|
13
|
+
"commit": "7b241289e260b97db8cd1fc4347d521a694b06d7",
|
|
14
|
+
"comment": "fix: popup now defines fallbackPositions to use when it doesn't fit the screen"
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
"author": "beachball",
|
|
18
|
+
"package": "@fluentui/react-combobox",
|
|
19
|
+
"comment": "Bump @fluentui/react-context-selector to v9.1.17",
|
|
20
|
+
"commit": "b48890859f5ce28fe12fd40f6bda26ed486c5e47"
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
"author": "beachball",
|
|
24
|
+
"package": "@fluentui/react-combobox",
|
|
25
|
+
"comment": "Bump @fluentui/react-field to v9.0.0-beta.2",
|
|
26
|
+
"commit": "b48890859f5ce28fe12fd40f6bda26ed486c5e47"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"author": "beachball",
|
|
30
|
+
"package": "@fluentui/react-combobox",
|
|
31
|
+
"comment": "Bump @fluentui/react-portal to v9.2.5",
|
|
32
|
+
"commit": "b48890859f5ce28fe12fd40f6bda26ed486c5e47"
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"author": "beachball",
|
|
36
|
+
"package": "@fluentui/react-combobox",
|
|
37
|
+
"comment": "Bump @fluentui/react-positioning to v9.5.9",
|
|
38
|
+
"commit": "b48890859f5ce28fe12fd40f6bda26ed486c5e47"
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
"author": "beachball",
|
|
42
|
+
"package": "@fluentui/react-combobox",
|
|
43
|
+
"comment": "Bump @fluentui/react-utilities to v9.7.4",
|
|
44
|
+
"commit": "b48890859f5ce28fe12fd40f6bda26ed486c5e47"
|
|
45
|
+
}
|
|
46
|
+
]
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
"date": "Fri, 07 Apr 2023 00:01:37 GMT",
|
|
6
51
|
"tag": "@fluentui/react-combobox_v9.2.8",
|
|
7
52
|
"version": "9.2.8",
|
|
8
53
|
"comments": {
|
package/CHANGELOG.md
CHANGED
|
@@ -1,12 +1,26 @@
|
|
|
1
1
|
# Change Log - @fluentui/react-combobox
|
|
2
2
|
|
|
3
|
-
This log was last generated on
|
|
3
|
+
This log was last generated on Wed, 12 Apr 2023 09:28:15 GMT and should not be manually modified.
|
|
4
4
|
|
|
5
5
|
<!-- Start content -->
|
|
6
6
|
|
|
7
|
+
## [9.2.9](https://github.com/microsoft/fluentui/tree/@fluentui/react-combobox_v9.2.9)
|
|
8
|
+
|
|
9
|
+
Wed, 12 Apr 2023 09:28:15 GMT
|
|
10
|
+
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-combobox_v9.2.8..@fluentui/react-combobox_v9.2.9)
|
|
11
|
+
|
|
12
|
+
### Patches
|
|
13
|
+
|
|
14
|
+
- fix: popup now defines fallbackPositions to use when it doesn't fit the screen ([PR #27521](https://github.com/microsoft/fluentui/pull/27521) by sarah.higley@microsoft.com)
|
|
15
|
+
- Bump @fluentui/react-context-selector to v9.1.17 ([commit](https://github.com/microsoft/fluentui/commit/b48890859f5ce28fe12fd40f6bda26ed486c5e47) by beachball)
|
|
16
|
+
- Bump @fluentui/react-field to v9.0.0-beta.2 ([commit](https://github.com/microsoft/fluentui/commit/b48890859f5ce28fe12fd40f6bda26ed486c5e47) by beachball)
|
|
17
|
+
- Bump @fluentui/react-portal to v9.2.5 ([commit](https://github.com/microsoft/fluentui/commit/b48890859f5ce28fe12fd40f6bda26ed486c5e47) by beachball)
|
|
18
|
+
- Bump @fluentui/react-positioning to v9.5.9 ([commit](https://github.com/microsoft/fluentui/commit/b48890859f5ce28fe12fd40f6bda26ed486c5e47) by beachball)
|
|
19
|
+
- Bump @fluentui/react-utilities to v9.7.4 ([commit](https://github.com/microsoft/fluentui/commit/b48890859f5ce28fe12fd40f6bda26ed486c5e47) by beachball)
|
|
20
|
+
|
|
7
21
|
## [9.2.8](https://github.com/microsoft/fluentui/tree/@fluentui/react-combobox_v9.2.8)
|
|
8
22
|
|
|
9
|
-
|
|
23
|
+
Fri, 07 Apr 2023 00:01:37 GMT
|
|
10
24
|
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-combobox_v9.2.7..@fluentui/react-combobox_v9.2.8)
|
|
11
25
|
|
|
12
26
|
### Patches
|
|
@@ -4,6 +4,8 @@ export function useComboboxPopup(props, triggerShorthand, listboxShorthand) {
|
|
|
4
4
|
const {
|
|
5
5
|
positioning
|
|
6
6
|
} = props;
|
|
7
|
+
// Set a default set of fallback positions to try if the dropdown does not fit on screen
|
|
8
|
+
const fallbackPositions = ['above', 'after', 'after-top', 'before', 'before-top'];
|
|
7
9
|
// popper options
|
|
8
10
|
const popperOptions = {
|
|
9
11
|
position: 'below',
|
|
@@ -12,6 +14,7 @@ export function useComboboxPopup(props, triggerShorthand, listboxShorthand) {
|
|
|
12
14
|
crossAxis: 0,
|
|
13
15
|
mainAxis: 2
|
|
14
16
|
},
|
|
17
|
+
fallbackPositions,
|
|
15
18
|
...resolvePositioningShorthand(positioning)
|
|
16
19
|
};
|
|
17
20
|
const {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["resolvePositioningShorthand","usePositioning","useMergedRefs","useComboboxPopup","props","triggerShorthand","listboxShorthand","positioning","popperOptions","position","align","offset","crossAxis","mainAxis","targetRef","containerRef","listboxRef","ref","listbox"],"sources":["../../src/utils/useComboboxPopup.ts"],"sourcesContent":["import { resolvePositioningShorthand, usePositioning } from '@fluentui/react-positioning';\nimport { ExtractSlotProps, Slot, useMergedRefs } from '@fluentui/react-utilities';\nimport type { ComboboxBaseProps } from './ComboboxBase.types';\nimport { Listbox } from '../components/Listbox/Listbox';\n\nexport function useComboboxPopup(\n props: ComboboxBaseProps,\n triggerShorthand?: ExtractSlotProps<Slot<'button'>>,\n listboxShorthand?: ExtractSlotProps<Slot<typeof Listbox>>,\n): [trigger: ExtractSlotProps<Slot<'button'>>, listbox?: ExtractSlotProps<Slot<typeof Listbox>>];\nexport function useComboboxPopup(\n props: ComboboxBaseProps,\n triggerShorthand?: ExtractSlotProps<Slot<'input'>>,\n listboxShorthand?: ExtractSlotProps<Slot<typeof Listbox>>,\n): [trigger: ExtractSlotProps<Slot<'input'>>, listbox?: ExtractSlotProps<Slot<typeof Listbox>>];\n\nexport function useComboboxPopup(\n props: ComboboxBaseProps,\n triggerShorthand?: ExtractSlotProps<Slot<'input'>> | ExtractSlotProps<Slot<'button'>>,\n listboxShorthand?: ExtractSlotProps<Slot<typeof Listbox>>,\n): [\n trigger: ExtractSlotProps<Slot<'input'>> | ExtractSlotProps<Slot<'button'>>,\n listbox?: ExtractSlotProps<Slot<typeof Listbox>>,\n] {\n const { positioning } = props;\n\n // popper options\n const popperOptions = {\n position: 'below' as const,\n align: 'start' as const,\n offset: { crossAxis: 0, mainAxis: 2 },\n ...resolvePositioningShorthand(positioning),\n };\n\n const { targetRef, containerRef } = usePositioning(popperOptions);\n\n const listboxRef = useMergedRefs(listboxShorthand?.ref, containerRef);\n const listbox = listboxShorthand && { ...listboxShorthand, ref: listboxRef };\n\n return [{ ...triggerShorthand, ref: useMergedRefs(triggerShorthand?.ref, targetRef) }, listbox];\n}\n"],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"names":["resolvePositioningShorthand","usePositioning","useMergedRefs","useComboboxPopup","props","triggerShorthand","listboxShorthand","positioning","fallbackPositions","popperOptions","position","align","offset","crossAxis","mainAxis","targetRef","containerRef","listboxRef","ref","listbox"],"sources":["../../src/utils/useComboboxPopup.ts"],"sourcesContent":["import { PositioningShorthandValue, resolvePositioningShorthand, usePositioning } from '@fluentui/react-positioning';\nimport { ExtractSlotProps, Slot, useMergedRefs } from '@fluentui/react-utilities';\nimport type { ComboboxBaseProps } from './ComboboxBase.types';\nimport { Listbox } from '../components/Listbox/Listbox';\n\nexport function useComboboxPopup(\n props: ComboboxBaseProps,\n triggerShorthand?: ExtractSlotProps<Slot<'button'>>,\n listboxShorthand?: ExtractSlotProps<Slot<typeof Listbox>>,\n): [trigger: ExtractSlotProps<Slot<'button'>>, listbox?: ExtractSlotProps<Slot<typeof Listbox>>];\nexport function useComboboxPopup(\n props: ComboboxBaseProps,\n triggerShorthand?: ExtractSlotProps<Slot<'input'>>,\n listboxShorthand?: ExtractSlotProps<Slot<typeof Listbox>>,\n): [trigger: ExtractSlotProps<Slot<'input'>>, listbox?: ExtractSlotProps<Slot<typeof Listbox>>];\n\nexport function useComboboxPopup(\n props: ComboboxBaseProps,\n triggerShorthand?: ExtractSlotProps<Slot<'input'>> | ExtractSlotProps<Slot<'button'>>,\n listboxShorthand?: ExtractSlotProps<Slot<typeof Listbox>>,\n): [\n trigger: ExtractSlotProps<Slot<'input'>> | ExtractSlotProps<Slot<'button'>>,\n listbox?: ExtractSlotProps<Slot<typeof Listbox>>,\n] {\n const { positioning } = props;\n\n // Set a default set of fallback positions to try if the dropdown does not fit on screen\n const fallbackPositions: PositioningShorthandValue[] = ['above', 'after', 'after-top', 'before', 'before-top'];\n\n // popper options\n const popperOptions = {\n position: 'below' as const,\n align: 'start' as const,\n offset: { crossAxis: 0, mainAxis: 2 },\n fallbackPositions,\n ...resolvePositioningShorthand(positioning),\n };\n\n const { targetRef, containerRef } = usePositioning(popperOptions);\n\n const listboxRef = useMergedRefs(listboxShorthand?.ref, containerRef);\n const listbox = listboxShorthand && { ...listboxShorthand, ref: listboxRef };\n\n return [{ ...triggerShorthand, ref: useMergedRefs(triggerShorthand?.ref, targetRef) }, listbox];\n}\n"],"mappings":"AAAA,SAAoCA,2BAA2B,EAAEC,cAAc,QAAQ;AACvF,SAAiCC,aAAa,QAAQ;AAetD,OAAO,SAASC,iBACdC,KAAwB,EACxBC,gBAAqF,EACrFC,gBAAyD,EAIzD;EACA,MAAM;IAAEC;EAAW,CAAE,GAAGH,KAAA;EAExB;EACA,MAAMI,iBAAA,GAAiD,CAAC,SAAS,SAAS,aAAa,UAAU,aAAa;EAE9G;EACA,MAAMC,aAAA,GAAgB;IACpBC,QAAA,EAAU;IACVC,KAAA,EAAO;IACPC,MAAA,EAAQ;MAAEC,SAAA,EAAW;MAAGC,QAAA,EAAU;IAAE;IACpCN,iBAAA;IACA,GAAGR,2BAAA,CAA4BO,WAAA;EACjC;EAEA,MAAM;IAAEQ,SAAA;IAAWC;EAAY,CAAE,GAAGf,cAAA,CAAeQ,aAAA;EAEnD,MAAMQ,UAAA,GAAaf,aAAA,CAAcI,gBAAA,aAAAA,gBAAA,uBAAAA,gBAAA,CAAkBY,GAAG,EAAEF,YAAA;EACxD,MAAMG,OAAA,GAAUb,gBAAA,IAAoB;IAAE,GAAGA,gBAAgB;IAAEY,GAAA,EAAKD;EAAW;EAE3E,OAAO,CAAC;IAAE,GAAGZ,gBAAgB;IAAEa,GAAA,EAAKhB,aAAA,CAAcG,gBAAA,aAAAA,gBAAA,uBAAAA,gBAAA,CAAkBa,GAAG,EAAEH,SAAA;EAAW,GAAGI,OAAA,CAAQ;AACjG"}
|
|
@@ -10,6 +10,14 @@ const _reactPositioning = require("@fluentui/react-positioning");
|
|
|
10
10
|
const _reactUtilities = require("@fluentui/react-utilities");
|
|
11
11
|
function useComboboxPopup(props, triggerShorthand, listboxShorthand) {
|
|
12
12
|
const { positioning } = props;
|
|
13
|
+
// Set a default set of fallback positions to try if the dropdown does not fit on screen
|
|
14
|
+
const fallbackPositions = [
|
|
15
|
+
'above',
|
|
16
|
+
'after',
|
|
17
|
+
'after-top',
|
|
18
|
+
'before',
|
|
19
|
+
'before-top'
|
|
20
|
+
];
|
|
13
21
|
// popper options
|
|
14
22
|
const popperOptions = {
|
|
15
23
|
position: 'below',
|
|
@@ -18,6 +26,7 @@ function useComboboxPopup(props, triggerShorthand, listboxShorthand) {
|
|
|
18
26
|
crossAxis: 0,
|
|
19
27
|
mainAxis: 2
|
|
20
28
|
},
|
|
29
|
+
fallbackPositions,
|
|
21
30
|
...(0, _reactPositioning.resolvePositioningShorthand)(positioning)
|
|
22
31
|
};
|
|
23
32
|
const { targetRef , containerRef } = (0, _reactPositioning.usePositioning)(popperOptions);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../lib/utils/useComboboxPopup.js"],"sourcesContent":["import { resolvePositioningShorthand, usePositioning } from '@fluentui/react-positioning';\nimport { useMergedRefs } from '@fluentui/react-utilities';\nexport function useComboboxPopup(props, triggerShorthand, listboxShorthand) {\n const {\n positioning\n } = props;\n // popper options\n const popperOptions = {\n position: 'below',\n align: 'start',\n offset: {\n crossAxis: 0,\n mainAxis: 2\n },\n ...resolvePositioningShorthand(positioning)\n };\n const {\n targetRef,\n containerRef\n } = usePositioning(popperOptions);\n const listboxRef = useMergedRefs(listboxShorthand === null || listboxShorthand === void 0 ? void 0 : listboxShorthand.ref, containerRef);\n const listbox = listboxShorthand && {\n ...listboxShorthand,\n ref: listboxRef\n };\n return [{\n ...triggerShorthand,\n ref: useMergedRefs(triggerShorthand === null || triggerShorthand === void 0 ? void 0 : triggerShorthand.ref, targetRef)\n }, listbox];\n}\n//# sourceMappingURL=useComboboxPopup.js.map"],"names":["useComboboxPopup","props","triggerShorthand","listboxShorthand","positioning","popperOptions","position","align","offset","crossAxis","mainAxis","resolvePositioningShorthand","targetRef","containerRef","usePositioning","listboxRef","useMergedRefs","ref","listbox"],"mappings":";;;;+BAEgBA;;aAAAA;;kCAF4C;gCAC9B;AACvB,SAASA,iBAAiBC,KAAK,EAAEC,gBAAgB,EAAEC,gBAAgB,EAAE;IAC1E,MAAM,EACJC,YAAW,EACZ,GAAGH;IACJ,iBAAiB;IACjB,
|
|
1
|
+
{"version":3,"sources":["../../lib/utils/useComboboxPopup.js"],"sourcesContent":["import { resolvePositioningShorthand, usePositioning } from '@fluentui/react-positioning';\nimport { useMergedRefs } from '@fluentui/react-utilities';\nexport function useComboboxPopup(props, triggerShorthand, listboxShorthand) {\n const {\n positioning\n } = props;\n // Set a default set of fallback positions to try if the dropdown does not fit on screen\n const fallbackPositions = ['above', 'after', 'after-top', 'before', 'before-top'];\n // popper options\n const popperOptions = {\n position: 'below',\n align: 'start',\n offset: {\n crossAxis: 0,\n mainAxis: 2\n },\n fallbackPositions,\n ...resolvePositioningShorthand(positioning)\n };\n const {\n targetRef,\n containerRef\n } = usePositioning(popperOptions);\n const listboxRef = useMergedRefs(listboxShorthand === null || listboxShorthand === void 0 ? void 0 : listboxShorthand.ref, containerRef);\n const listbox = listboxShorthand && {\n ...listboxShorthand,\n ref: listboxRef\n };\n return [{\n ...triggerShorthand,\n ref: useMergedRefs(triggerShorthand === null || triggerShorthand === void 0 ? void 0 : triggerShorthand.ref, targetRef)\n }, listbox];\n}\n//# sourceMappingURL=useComboboxPopup.js.map"],"names":["useComboboxPopup","props","triggerShorthand","listboxShorthand","positioning","fallbackPositions","popperOptions","position","align","offset","crossAxis","mainAxis","resolvePositioningShorthand","targetRef","containerRef","usePositioning","listboxRef","useMergedRefs","ref","listbox"],"mappings":";;;;+BAEgBA;;aAAAA;;kCAF4C;gCAC9B;AACvB,SAASA,iBAAiBC,KAAK,EAAEC,gBAAgB,EAAEC,gBAAgB,EAAE;IAC1E,MAAM,EACJC,YAAW,EACZ,GAAGH;IACJ,wFAAwF;IACxF,MAAMI,oBAAoB;QAAC;QAAS;QAAS;QAAa;QAAU;KAAa;IACjF,iBAAiB;IACjB,MAAMC,gBAAgB;QACpBC,UAAU;QACVC,OAAO;QACPC,QAAQ;YACNC,WAAW;YACXC,UAAU;QACZ;QACAN;QACA,GAAGO,IAAAA,6CAA2B,EAACR,YAAY;IAC7C;IACA,MAAM,EACJS,UAAS,EACTC,aAAY,EACb,GAAGC,IAAAA,gCAAc,EAACT;IACnB,MAAMU,aAAaC,IAAAA,6BAAa,EAACd,qBAAqB,IAAI,IAAIA,qBAAqB,KAAK,IAAI,KAAK,IAAIA,iBAAiBe,GAAG,EAAEJ;IAC3H,MAAMK,UAAUhB,oBAAoB;QAClC,GAAGA,gBAAgB;QACnBe,KAAKF;IACP;IACA,OAAO;QAAC;YACN,GAAGd,gBAAgB;YACnBgB,KAAKD,IAAAA,6BAAa,EAACf,qBAAqB,IAAI,IAAIA,qBAAqB,KAAK,IAAI,KAAK,IAAIA,iBAAiBgB,GAAG,EAAEL;QAC/G;QAAGM;KAAQ;AACb,EACA,4CAA4C"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluentui/react-combobox",
|
|
3
|
-
"version": "9.2.
|
|
3
|
+
"version": "9.2.9",
|
|
4
4
|
"description": "Fluent UI React Combobox component",
|
|
5
5
|
"main": "lib-commonjs/index.js",
|
|
6
6
|
"module": "lib/index.js",
|
|
@@ -33,14 +33,14 @@
|
|
|
33
33
|
},
|
|
34
34
|
"dependencies": {
|
|
35
35
|
"@fluentui/keyboard-keys": "^9.0.2",
|
|
36
|
-
"@fluentui/react-context-selector": "^9.1.
|
|
37
|
-
"@fluentui/react-field": "9.0.0-beta.
|
|
36
|
+
"@fluentui/react-context-selector": "^9.1.17",
|
|
37
|
+
"@fluentui/react-field": "9.0.0-beta.2",
|
|
38
38
|
"@fluentui/react-icons": "^2.0.196",
|
|
39
|
-
"@fluentui/react-portal": "^9.2.
|
|
40
|
-
"@fluentui/react-positioning": "^9.5.
|
|
39
|
+
"@fluentui/react-portal": "^9.2.5",
|
|
40
|
+
"@fluentui/react-positioning": "^9.5.9",
|
|
41
41
|
"@fluentui/react-shared-contexts": "^9.3.3",
|
|
42
42
|
"@fluentui/react-theme": "^9.1.7",
|
|
43
|
-
"@fluentui/react-utilities": "^9.7.
|
|
43
|
+
"@fluentui/react-utilities": "^9.7.4",
|
|
44
44
|
"@griffel/react": "^1.5.2",
|
|
45
45
|
"@swc/helpers": "^0.4.14"
|
|
46
46
|
},
|