@fluentui/react-overflow 9.0.12 → 9.0.14
Sign up to get free protection for your applications and to get access to all the features.
package/CHANGELOG.json
CHANGED
@@ -2,7 +2,55 @@
|
|
2
2
|
"name": "@fluentui/react-overflow",
|
3
3
|
"entries": [
|
4
4
|
{
|
5
|
-
"date": "
|
5
|
+
"date": "Wed, 12 Apr 2023 09:28:17 GMT",
|
6
|
+
"tag": "@fluentui/react-overflow_v9.0.14",
|
7
|
+
"version": "9.0.14",
|
8
|
+
"comments": {
|
9
|
+
"patch": [
|
10
|
+
{
|
11
|
+
"author": "beachball",
|
12
|
+
"package": "@fluentui/react-overflow",
|
13
|
+
"comment": "Bump @fluentui/react-context-selector to v9.1.17",
|
14
|
+
"commit": "b48890859f5ce28fe12fd40f6bda26ed486c5e47"
|
15
|
+
},
|
16
|
+
{
|
17
|
+
"author": "beachball",
|
18
|
+
"package": "@fluentui/react-overflow",
|
19
|
+
"comment": "Bump @fluentui/react-utilities to v9.7.4",
|
20
|
+
"commit": "b48890859f5ce28fe12fd40f6bda26ed486c5e47"
|
21
|
+
}
|
22
|
+
]
|
23
|
+
}
|
24
|
+
},
|
25
|
+
{
|
26
|
+
"date": "Tue, 04 Apr 2023 18:44:49 GMT",
|
27
|
+
"tag": "@fluentui/react-overflow_v9.0.13",
|
28
|
+
"version": "9.0.13",
|
29
|
+
"comments": {
|
30
|
+
"patch": [
|
31
|
+
{
|
32
|
+
"author": "vkozlova@microsoft.com",
|
33
|
+
"package": "@fluentui/react-overflow",
|
34
|
+
"commit": "34124853ca638421e5b90d6c3b1ad2611b78b4f7",
|
35
|
+
"comment": "fix: overflow item style should be applied when overflow items are nested in wrapper elements"
|
36
|
+
},
|
37
|
+
{
|
38
|
+
"author": "beachball",
|
39
|
+
"package": "@fluentui/react-overflow",
|
40
|
+
"comment": "Bump @fluentui/react-context-selector to v9.1.16",
|
41
|
+
"commit": "6778d76bbbad7e1975c151c797f28c2708cde2ce"
|
42
|
+
},
|
43
|
+
{
|
44
|
+
"author": "beachball",
|
45
|
+
"package": "@fluentui/react-overflow",
|
46
|
+
"comment": "Bump @fluentui/react-utilities to v9.7.3",
|
47
|
+
"commit": "6778d76bbbad7e1975c151c797f28c2708cde2ce"
|
48
|
+
}
|
49
|
+
]
|
50
|
+
}
|
51
|
+
},
|
52
|
+
{
|
53
|
+
"date": "Tue, 21 Mar 2023 21:23:41 GMT",
|
6
54
|
"tag": "@fluentui/react-overflow_v9.0.12",
|
7
55
|
"version": "9.0.12",
|
8
56
|
"comments": {
|
package/CHANGELOG.md
CHANGED
@@ -1,12 +1,33 @@
|
|
1
1
|
# Change Log - @fluentui/react-overflow
|
2
2
|
|
3
|
-
This log was last generated on
|
3
|
+
This log was last generated on Wed, 12 Apr 2023 09:28:17 GMT and should not be manually modified.
|
4
4
|
|
5
5
|
<!-- Start content -->
|
6
6
|
|
7
|
+
## [9.0.14](https://github.com/microsoft/fluentui/tree/@fluentui/react-overflow_v9.0.14)
|
8
|
+
|
9
|
+
Wed, 12 Apr 2023 09:28:17 GMT
|
10
|
+
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-overflow_v9.0.13..@fluentui/react-overflow_v9.0.14)
|
11
|
+
|
12
|
+
### Patches
|
13
|
+
|
14
|
+
- Bump @fluentui/react-context-selector to v9.1.17 ([commit](https://github.com/microsoft/fluentui/commit/b48890859f5ce28fe12fd40f6bda26ed486c5e47) by beachball)
|
15
|
+
- Bump @fluentui/react-utilities to v9.7.4 ([commit](https://github.com/microsoft/fluentui/commit/b48890859f5ce28fe12fd40f6bda26ed486c5e47) by beachball)
|
16
|
+
|
17
|
+
## [9.0.13](https://github.com/microsoft/fluentui/tree/@fluentui/react-overflow_v9.0.13)
|
18
|
+
|
19
|
+
Tue, 04 Apr 2023 18:44:49 GMT
|
20
|
+
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-overflow_v9.0.12..@fluentui/react-overflow_v9.0.13)
|
21
|
+
|
22
|
+
### Patches
|
23
|
+
|
24
|
+
- fix: overflow item style should be applied when overflow items are nested in wrapper elements ([PR #27402](https://github.com/microsoft/fluentui/pull/27402) by vkozlova@microsoft.com)
|
25
|
+
- Bump @fluentui/react-context-selector to v9.1.16 ([PR #27434](https://github.com/microsoft/fluentui/pull/27434) by beachball)
|
26
|
+
- Bump @fluentui/react-utilities to v9.7.3 ([PR #27434](https://github.com/microsoft/fluentui/pull/27434) by beachball)
|
27
|
+
|
7
28
|
## [9.0.12](https://github.com/microsoft/fluentui/tree/@fluentui/react-overflow_v9.0.12)
|
8
29
|
|
9
|
-
Tue, 21 Mar 2023 21:
|
30
|
+
Tue, 21 Mar 2023 21:23:41 GMT
|
10
31
|
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-overflow_v9.0.11..@fluentui/react-overflow_v9.0.12)
|
11
32
|
|
12
33
|
### Patches
|
@@ -9,10 +9,10 @@ const useStyles = /*#__PURE__*/__styles({
|
|
9
9
|
Brvla84: "fyfkpbf"
|
10
10
|
},
|
11
11
|
overflowingItems: {
|
12
|
-
|
12
|
+
zb22lx: "f10570jf"
|
13
13
|
}
|
14
14
|
}, {
|
15
|
-
d: [".fyfkpbf [data-overflow-menu]{-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;}", ".
|
15
|
+
d: [".fyfkpbf [data-overflow-menu]{-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;}", ".f10570jf [data-overflowing]{display:none;}"]
|
16
16
|
});
|
17
17
|
/**
|
18
18
|
* Provides an OverflowContext for OverflowItem descendants.
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["React","__styles","mergeClasses","applyTriggerPropsToChildren","useMergedRefs","OverflowContext","updateVisibilityAttribute","useOverflowContainer","DATA_OVERFLOWING","DATA_OVERFLOW_MENU","useStyles","overflowMenu","Brvla84","overflowingItems","
|
1
|
+
{"version":3,"names":["React","__styles","mergeClasses","applyTriggerPropsToChildren","useMergedRefs","OverflowContext","updateVisibilityAttribute","useOverflowContainer","DATA_OVERFLOWING","DATA_OVERFLOW_MENU","useStyles","overflowMenu","Brvla84","overflowingItems","zb22lx","d","Overflow","forwardRef","props","ref","styles","children","minimumVisible","overflowAxis","overflowDirection","padding","hasOverflow","setHasOverflow","useState","itemVisibility","setItemVisibility","groupVisibility","setGroupVisibility","update","data","invisibleItems","length","newState","visibleItems","forEach","x","id","containerRef","registerItem","updateOverflow","registerOverflowMenu","onUpdateItemVisibility","clonedChild","className","createElement","Provider","value"],"sources":["../../src/components/Overflow.tsx"],"sourcesContent":["import * as React from 'react';\nimport { makeStyles, mergeClasses } from '@griffel/react';\nimport type { OnUpdateOverflow, OverflowGroupState, ObserveOptions } from '@fluentui/priority-overflow';\nimport { applyTriggerPropsToChildren, useMergedRefs } from '@fluentui/react-utilities';\n\nimport { OverflowContext } from '../overflowContext';\nimport { updateVisibilityAttribute, useOverflowContainer } from '../useOverflowContainer';\nimport { DATA_OVERFLOWING, DATA_OVERFLOW_MENU } from '../constants';\n\nconst useStyles = makeStyles({\n overflowMenu: {\n [`& [${DATA_OVERFLOW_MENU}]`]: {\n flexShrink: 0,\n },\n },\n\n overflowingItems: {\n [`& [${DATA_OVERFLOWING}]`]: {\n display: 'none',\n },\n },\n});\n\n/**\n * Overflow Props\n */\nexport type OverflowProps = Partial<\n Pick<ObserveOptions, 'overflowAxis' | 'overflowDirection' | 'padding' | 'minimumVisible'>\n> & {\n children: React.ReactElement;\n};\n\n/**\n * Provides an OverflowContext for OverflowItem descendants.\n */\nexport const Overflow = React.forwardRef((props: OverflowProps, ref) => {\n const styles = useStyles();\n\n const { children, minimumVisible, overflowAxis = 'horizontal', overflowDirection, padding } = props;\n\n const [hasOverflow, setHasOverflow] = React.useState(false);\n const [itemVisibility, setItemVisibility] = React.useState<Record<string, boolean>>({});\n const [groupVisibility, setGroupVisibility] = React.useState<Record<string, OverflowGroupState>>({});\n\n // useOverflowContainer wraps this method in a useEventCallback.\n // TODO: Do we need a useEventCallback here too?\n const update: OnUpdateOverflow = data => {\n setHasOverflow(() => data.invisibleItems.length > 0);\n setItemVisibility(() => {\n const newState: Record<string, boolean> = {};\n data.visibleItems.forEach(x => (newState[x.id] = true));\n data.invisibleItems.forEach(x => (newState[x.id] = false));\n return newState;\n });\n setGroupVisibility(data.groupVisibility);\n };\n\n const { containerRef, registerItem, updateOverflow, registerOverflowMenu } = useOverflowContainer(update, {\n overflowDirection,\n overflowAxis,\n padding,\n minimumVisible,\n onUpdateItemVisibility: updateVisibilityAttribute,\n });\n\n const clonedChild = applyTriggerPropsToChildren(children, {\n ref: useMergedRefs(containerRef, ref),\n className: mergeClasses(styles.overflowMenu, styles.overflowingItems, children.props.className),\n });\n\n return (\n <OverflowContext.Provider\n value={{\n itemVisibility,\n groupVisibility,\n hasOverflow,\n registerItem,\n updateOverflow,\n registerOverflowMenu,\n }}\n >\n {clonedChild}\n </OverflowContext.Provider>\n );\n});\n"],"mappings":"AAAA,YAAYA,KAAA,MAAW;AACvB,SAAAC,QAAA,EAAqBC,YAAY,QAAQ;AAEzC,SAASC,2BAA2B,EAAEC,aAAa,QAAQ;AAE3D,SAASC,eAAe,QAAQ;AAChC,SAASC,yBAAyB,EAAEC,oBAAoB,QAAQ;AAChE,SAASC,gBAAgB,EAAEC,kBAAkB,QAAQ;AAErD,MAAMC,SAAA,gBAAYT,QAAA;EAAAU,YAAA;IAAAC,OAAA;EAAA;EAAAC,gBAAA;IAAAC,MAAA;EAAA;AAAA;EAAAC,CAAA;AAAA,EAYlB;AAWA;;;AAGA,OAAO,MAAMC,QAAA,gBAAWhB,KAAA,CAAMiB,UAAU,CAAC,CAACC,KAAA,EAAsBC,GAAA,KAAQ;EACtE,MAAMC,MAAA,GAASV,SAAA;EAEf,MAAM;IAAEW,QAAA;IAAUC,cAAA;IAAgBC,YAAA,GAAe;IAAcC,iBAAA;IAAmBC;EAAO,CAAE,GAAGP,KAAA;EAE9F,MAAM,CAACQ,WAAA,EAAaC,cAAA,CAAe,GAAG3B,KAAA,CAAM4B,QAAQ,CAAC,KAAK;EAC1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IACF;KAECE,WAAA;AAGP"}
|
@@ -17,12 +17,12 @@ const useStyles = /*#__PURE__*/ (0, _react1["__styles"])({
|
|
17
17
|
Brvla84: "fyfkpbf"
|
18
18
|
},
|
19
19
|
overflowingItems: {
|
20
|
-
|
20
|
+
zb22lx: "f10570jf"
|
21
21
|
}
|
22
22
|
}, {
|
23
23
|
d: [
|
24
24
|
".fyfkpbf [data-overflow-menu]{-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;}",
|
25
|
-
".
|
25
|
+
".f10570jf [data-overflowing]{display:none;}"
|
26
26
|
]
|
27
27
|
});
|
28
28
|
const Overflow = /*#__PURE__*/ _react.forwardRef((props, ref)=>{
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../../lib/components/Overflow.js"],"sourcesContent":["import * as React from 'react';\nimport { __styles, mergeClasses } from '@griffel/react';\nimport { applyTriggerPropsToChildren, useMergedRefs } from '@fluentui/react-utilities';\nimport { OverflowContext } from '../overflowContext';\nimport { updateVisibilityAttribute, useOverflowContainer } from '../useOverflowContainer';\nimport { DATA_OVERFLOWING, DATA_OVERFLOW_MENU } from '../constants';\nconst useStyles = /*#__PURE__*/__styles({\n overflowMenu: {\n Brvla84: \"fyfkpbf\"\n },\n overflowingItems: {\n
|
1
|
+
{"version":3,"sources":["../../lib/components/Overflow.js"],"sourcesContent":["import * as React from 'react';\nimport { __styles, mergeClasses } from '@griffel/react';\nimport { applyTriggerPropsToChildren, useMergedRefs } from '@fluentui/react-utilities';\nimport { OverflowContext } from '../overflowContext';\nimport { updateVisibilityAttribute, useOverflowContainer } from '../useOverflowContainer';\nimport { DATA_OVERFLOWING, DATA_OVERFLOW_MENU } from '../constants';\nconst useStyles = /*#__PURE__*/__styles({\n overflowMenu: {\n Brvla84: \"fyfkpbf\"\n },\n overflowingItems: {\n zb22lx: \"f10570jf\"\n }\n}, {\n d: [\".fyfkpbf [data-overflow-menu]{-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;}\", \".f10570jf [data-overflowing]{display:none;}\"]\n});\n/**\n * Provides an OverflowContext for OverflowItem descendants.\n */\nexport const Overflow = /*#__PURE__*/React.forwardRef((props, ref) => {\n const styles = useStyles();\n const {\n children,\n minimumVisible,\n overflowAxis = 'horizontal',\n overflowDirection,\n padding\n } = props;\n const [hasOverflow, setHasOverflow] = React.useState(false);\n const [itemVisibility, setItemVisibility] = React.useState({});\n const [groupVisibility, setGroupVisibility] = React.useState({});\n // useOverflowContainer wraps this method in a useEventCallback.\n // TODO: Do we need a useEventCallback here too?\n const update = data => {\n setHasOverflow(() => data.invisibleItems.length > 0);\n setItemVisibility(() => {\n const newState = {};\n data.visibleItems.forEach(x => newState[x.id] = true);\n data.invisibleItems.forEach(x => newState[x.id] = false);\n return newState;\n });\n setGroupVisibility(data.groupVisibility);\n };\n const {\n containerRef,\n registerItem,\n updateOverflow,\n registerOverflowMenu\n } = useOverflowContainer(update, {\n overflowDirection,\n overflowAxis,\n padding,\n minimumVisible,\n onUpdateItemVisibility: updateVisibilityAttribute\n });\n const clonedChild = applyTriggerPropsToChildren(children, {\n ref: useMergedRefs(containerRef, ref),\n className: mergeClasses(styles.overflowMenu, styles.overflowingItems, children.props.className)\n });\n return /*#__PURE__*/React.createElement(OverflowContext.Provider, {\n value: {\n itemVisibility,\n groupVisibility,\n hasOverflow,\n registerItem,\n updateOverflow,\n registerOverflowMenu\n }\n }, clonedChild);\n});\n//# sourceMappingURL=Overflow.js.map"],"names":["Overflow","useStyles","__styles","overflowMenu","Brvla84","overflowingItems","zb22lx","d","React","forwardRef","props","ref","styles","children","minimumVisible","overflowAxis","overflowDirection","padding","hasOverflow","setHasOverflow","useState","itemVisibility","setItemVisibility","groupVisibility","setGroupVisibility","update","data","invisibleItems","length","newState","visibleItems","forEach","x","id","containerRef","registerItem","updateOverflow","registerOverflowMenu","useOverflowContainer","onUpdateItemVisibility","updateVisibilityAttribute","clonedChild","applyTriggerPropsToChildren","useMergedRefs","className","mergeClasses","createElement","Over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AMC,cAAcC,IAAAA,2CAA2B,EAAC7B,UAAU;QACxDF,KAAKgC,IAAAA,6BAAa,EAACT,cAAcvB;QACjCiC,WAAWC,IAAAA,oBAAY,EAACjC,OAAOT,YAAY,EAAES,OAAOP,gBAAgB,EAAEQ,SAASH,KAAK,CAACkC,SAAS;IAChG;IACA,OAAO,WAAW,GAAEpC,OAAMsC,aAAa,CAACC,gCAAe,CAACC,QAAQ,EAAE;QAChEC,OAAO;YACL5B;YACAE;YACAL;YACAiB;YACAC;YACAC;QACF;IACF,GAAGI;AACL,IACA,oCAAoC"}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@fluentui/react-overflow",
|
3
|
-
"version": "9.0.
|
3
|
+
"version": "9.0.14",
|
4
4
|
"description": "React bindings for @fluentui/priority-overflow",
|
5
5
|
"main": "lib-commonjs/index.js",
|
6
6
|
"module": "lib/index.js",
|
@@ -34,9 +34,9 @@
|
|
34
34
|
},
|
35
35
|
"dependencies": {
|
36
36
|
"@fluentui/priority-overflow": "^9.0.2",
|
37
|
-
"@fluentui/react-context-selector": "^9.1.
|
37
|
+
"@fluentui/react-context-selector": "^9.1.17",
|
38
38
|
"@fluentui/react-theme": "^9.1.7",
|
39
|
-
"@fluentui/react-utilities": "^9.7.
|
39
|
+
"@fluentui/react-utilities": "^9.7.4",
|
40
40
|
"@griffel/react": "^1.5.2",
|
41
41
|
"@swc/helpers": "^0.4.14"
|
42
42
|
},
|