@fluentui/react-positioning 0.0.0-nightly-20230725-0413.1 → 0.0.0-nightly-20230726-0415.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.
package/CHANGELOG.json
CHANGED
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
"name": "@fluentui/react-positioning",
|
|
3
3
|
"entries": [
|
|
4
4
|
{
|
|
5
|
-
"date": "
|
|
6
|
-
"tag": "@fluentui/react-positioning_v0.0.0-nightly-
|
|
7
|
-
"version": "0.0.0-nightly-
|
|
5
|
+
"date": "Wed, 26 Jul 2023 04:22:03 GMT",
|
|
6
|
+
"tag": "@fluentui/react-positioning_v0.0.0-nightly-20230726-0415.1",
|
|
7
|
+
"version": "0.0.0-nightly-20230726-0415.1",
|
|
8
8
|
"comments": {
|
|
9
9
|
"prerelease": [
|
|
10
10
|
{
|
|
@@ -16,20 +16,20 @@
|
|
|
16
16
|
{
|
|
17
17
|
"author": "beachball",
|
|
18
18
|
"package": "@fluentui/react-positioning",
|
|
19
|
-
"comment": "Bump @fluentui/react-shared-contexts to v0.0.0-nightly-
|
|
20
|
-
"commit": "
|
|
19
|
+
"comment": "Bump @fluentui/react-shared-contexts to v0.0.0-nightly-20230726-0415.1",
|
|
20
|
+
"commit": "e38637401bb1ed42fefca7e7d8edc2fa0727f765"
|
|
21
21
|
},
|
|
22
22
|
{
|
|
23
23
|
"author": "beachball",
|
|
24
24
|
"package": "@fluentui/react-positioning",
|
|
25
|
-
"comment": "Bump @fluentui/react-theme to v0.0.0-nightly-
|
|
26
|
-
"commit": "
|
|
25
|
+
"comment": "Bump @fluentui/react-theme to v0.0.0-nightly-20230726-0415.1",
|
|
26
|
+
"commit": "e38637401bb1ed42fefca7e7d8edc2fa0727f765"
|
|
27
27
|
},
|
|
28
28
|
{
|
|
29
29
|
"author": "beachball",
|
|
30
30
|
"package": "@fluentui/react-positioning",
|
|
31
|
-
"comment": "Bump @fluentui/react-utilities to v0.0.0-nightly-
|
|
32
|
-
"commit": "
|
|
31
|
+
"comment": "Bump @fluentui/react-utilities to v0.0.0-nightly-20230726-0415.1",
|
|
32
|
+
"commit": "e38637401bb1ed42fefca7e7d8edc2fa0727f765"
|
|
33
33
|
}
|
|
34
34
|
]
|
|
35
35
|
}
|
package/CHANGELOG.md
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
# Change Log - @fluentui/react-positioning
|
|
2
2
|
|
|
3
|
-
This log was last generated on
|
|
3
|
+
This log was last generated on Wed, 26 Jul 2023 04:22:03 GMT and should not be manually modified.
|
|
4
4
|
|
|
5
5
|
<!-- Start content -->
|
|
6
6
|
|
|
7
|
-
## [0.0.0-nightly-
|
|
7
|
+
## [0.0.0-nightly-20230726-0415.1](https://github.com/microsoft/fluentui/tree/@fluentui/react-positioning_v0.0.0-nightly-20230726-0415.1)
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-positioning_v9.8.0..@fluentui/react-positioning_v0.0.0-nightly-
|
|
9
|
+
Wed, 26 Jul 2023 04:22:03 GMT
|
|
10
|
+
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-positioning_v9.8.0..@fluentui/react-positioning_v0.0.0-nightly-20230726-0415.1)
|
|
11
11
|
|
|
12
12
|
### Changes
|
|
13
13
|
|
|
14
14
|
- Release nightly v9 ([commit](https://github.com/microsoft/fluentui/commit/not available) by fluentui-internal@service.microsoft.com)
|
|
15
|
-
- Bump @fluentui/react-shared-contexts to v0.0.0-nightly-
|
|
16
|
-
- Bump @fluentui/react-theme to v0.0.0-nightly-
|
|
17
|
-
- Bump @fluentui/react-utilities to v0.0.0-nightly-
|
|
15
|
+
- Bump @fluentui/react-shared-contexts to v0.0.0-nightly-20230726-0415.1 ([commit](https://github.com/microsoft/fluentui/commit/e38637401bb1ed42fefca7e7d8edc2fa0727f765) by beachball)
|
|
16
|
+
- Bump @fluentui/react-theme to v0.0.0-nightly-20230726-0415.1 ([commit](https://github.com/microsoft/fluentui/commit/e38637401bb1ed42fefca7e7d8edc2fa0727f765) by beachball)
|
|
17
|
+
- Bump @fluentui/react-utilities to v0.0.0-nightly-20230726-0415.1 ([commit](https://github.com/microsoft/fluentui/commit/e38637401bb1ed42fefca7e7d8edc2fa0727f765) by beachball)
|
|
18
18
|
|
|
19
19
|
## [9.8.0](https://github.com/microsoft/fluentui/tree/@fluentui/react-positioning_v9.8.0)
|
|
20
20
|
|
|
@@ -8,21 +8,26 @@ export function maxSize(autoSize, options) {
|
|
|
8
8
|
boundary: getBoundary(container, overflowBoundary)
|
|
9
9
|
},
|
|
10
10
|
apply ({ availableHeight , availableWidth , elements , rects }) {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
if (applyMaxHeight) {
|
|
14
|
-
Object.assign(elements.floating.style, {
|
|
15
|
-
maxHeight: `${availableHeight}px`,
|
|
16
|
-
boxSizing: 'border-box',
|
|
17
|
-
overflowY: 'auto'
|
|
18
|
-
});
|
|
11
|
+
if (autoSize) {
|
|
12
|
+
elements.floating.style.setProperty('box-sizing', 'border-box');
|
|
19
13
|
}
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
});
|
|
14
|
+
const applyMaxWidth = autoSize === 'always' || autoSize === 'width-always';
|
|
15
|
+
const widthOverflow = rects.floating.width > availableWidth && (autoSize === true || autoSize === 'width');
|
|
16
|
+
const applyMaxHeight = autoSize === 'always' || autoSize === 'height-always';
|
|
17
|
+
const heightOverflow = rects.floating.height > availableHeight && (autoSize === true || autoSize === 'height');
|
|
18
|
+
if (applyMaxHeight || heightOverflow) {
|
|
19
|
+
elements.floating.style.setProperty('max-height', `${availableHeight}px`);
|
|
20
|
+
}
|
|
21
|
+
if (heightOverflow) {
|
|
22
|
+
elements.floating.style.setProperty('height', `${availableHeight}px`);
|
|
23
|
+
elements.floating.style.setProperty('overflow-y', 'auto');
|
|
24
|
+
}
|
|
25
|
+
if (applyMaxWidth || widthOverflow) {
|
|
26
|
+
elements.floating.style.setProperty('max-width', `${availableWidth}px`);
|
|
27
|
+
}
|
|
28
|
+
if (widthOverflow) {
|
|
29
|
+
elements.floating.style.setProperty('width', `${availableWidth}px`);
|
|
30
|
+
elements.floating.style.setProperty('overflow-x', 'auto');
|
|
26
31
|
}
|
|
27
32
|
}
|
|
28
33
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["maxSize.ts"],"sourcesContent":["import { size } from '@floating-ui/dom';\nimport type { Middleware } from '@floating-ui/dom';\nimport type { PositioningOptions } from '../types';\nimport { getBoundary } from '../utils/getBoundary';\nexport interface MaxSizeMiddlewareOptions extends Pick<PositioningOptions, 'overflowBoundary'> {\n container: HTMLElement | null;\n}\n\nexport function maxSize(autoSize: PositioningOptions['autoSize'], options: MaxSizeMiddlewareOptions): Middleware {\n const { container, overflowBoundary } = options;\n return size({\n ...(overflowBoundary && { altBoundary: true, boundary: getBoundary(container, overflowBoundary) }),\n apply({ availableHeight, availableWidth, elements, rects }) {\n const applyMaxWidth
|
|
1
|
+
{"version":3,"sources":["maxSize.ts"],"sourcesContent":["import { size } from '@floating-ui/dom';\nimport type { Middleware } from '@floating-ui/dom';\nimport type { PositioningOptions } from '../types';\nimport { getBoundary } from '../utils/getBoundary';\nexport interface MaxSizeMiddlewareOptions extends Pick<PositioningOptions, 'overflowBoundary'> {\n container: HTMLElement | null;\n}\n\nexport function maxSize(autoSize: PositioningOptions['autoSize'], options: MaxSizeMiddlewareOptions): Middleware {\n const { container, overflowBoundary } = options;\n return size({\n ...(overflowBoundary && { altBoundary: true, boundary: getBoundary(container, overflowBoundary) }),\n apply({ availableHeight, availableWidth, elements, rects }) {\n if (autoSize) {\n elements.floating.style.setProperty('box-sizing', 'border-box');\n }\n\n const applyMaxWidth = autoSize === 'always' || autoSize === 'width-always';\n const widthOverflow = rects.floating.width > availableWidth && (autoSize === true || autoSize === 'width');\n\n const applyMaxHeight = autoSize === 'always' || autoSize === 'height-always';\n const heightOverflow = rects.floating.height > availableHeight && (autoSize === true || autoSize === 'height');\n\n if (applyMaxHeight || heightOverflow) {\n elements.floating.style.setProperty('max-height', `${availableHeight}px`);\n }\n if (heightOverflow) {\n elements.floating.style.setProperty('height', `${availableHeight}px`);\n elements.floating.style.setProperty('overflow-y', 'auto');\n }\n\n if (applyMaxWidth || widthOverflow) {\n elements.floating.style.setProperty('max-width', `${availableWidth}px`);\n }\n if (widthOverflow) {\n elements.floating.style.setProperty('width', `${availableWidth}px`);\n elements.floating.style.setProperty('overflow-x', 'auto');\n }\n },\n });\n}\n"],"names":["size","getBoundary","maxSize","autoSize","options","container","overflowBoundary","altBoundary","boundary","apply","availableHeight","availableWidth","elements","rects","floating","style","setProperty","applyMaxWidth","widthOverflow","width","applyMaxHeight","heightOverflow","height"],"mappings":"AAAA,SAASA,IAAI,QAAQ,mBAAmB;AAGxC,SAASC,WAAW,QAAQ,uBAAuB;AAKnD,OAAO,SAASC,QAAQC,QAAwC,EAAEC,OAAiC,EAAc;IAC/G,MAAM,EAAEC,UAAS,EAAEC,iBAAgB,EAAE,GAAGF;IACxC,OAAOJ,KAAK;QACV,GAAIM,oBAAoB;YAAEC,aAAa,IAAI;YAAEC,UAAUP,YAAYI,WAAWC;QAAkB,CAAC;QACjGG,OAAM,EAAEC,gBAAe,EAAEC,eAAc,EAAEC,SAAQ,EAAEC,MAAK,EAAE,EAAE;YAC1D,IAAIV,UAAU;gBACZS,SAASE,QAAQ,CAACC,KAAK,CAACC,WAAW,CAAC,cAAc;YACpD,CAAC;YAED,MAAMC,gBAAgBd,aAAa,YAAYA,aAAa;YAC5D,MAAMe,gBAAgBL,MAAMC,QAAQ,CAACK,KAAK,GAAGR,kBAAmBR,CAAAA,aAAa,IAAI,IAAIA,aAAa,OAAM;YAExG,MAAMiB,iBAAiBjB,aAAa,YAAYA,aAAa;YAC7D,MAAMkB,iBAAiBR,MAAMC,QAAQ,CAACQ,MAAM,GAAGZ,mBAAoBP,CAAAA,aAAa,IAAI,IAAIA,aAAa,QAAO;YAE5G,IAAIiB,kBAAkBC,gBAAgB;gBACpCT,SAASE,QAAQ,CAACC,KAAK,CAACC,WAAW,CAAC,cAAc,CAAC,EAAEN,gBAAgB,EAAE,CAAC;YAC1E,CAAC;YACD,IAAIW,gBAAgB;gBAClBT,SAASE,QAAQ,CAACC,KAAK,CAACC,WAAW,CAAC,UAAU,CAAC,EAAEN,gBAAgB,EAAE,CAAC;gBACpEE,SAASE,QAAQ,CAACC,KAAK,CAACC,WAAW,CAAC,cAAc;YACpD,CAAC;YAED,IAAIC,iBAAiBC,eAAe;gBAClCN,SAASE,QAAQ,CAACC,KAAK,CAACC,WAAW,CAAC,aAAa,CAAC,EAAEL,eAAe,EAAE,CAAC;YACxE,CAAC;YACD,IAAIO,eAAe;gBACjBN,SAASE,QAAQ,CAACC,KAAK,CAACC,WAAW,CAAC,SAAS,CAAC,EAAEL,eAAe,EAAE,CAAC;gBAClEC,SAASE,QAAQ,CAACC,KAAK,CAACC,WAAW,CAAC,cAAc;YACpD,CAAC;QACH;IACF;AACF,CAAC"}
|
|
@@ -16,21 +16,26 @@ function maxSize(autoSize, options) {
|
|
|
16
16
|
boundary: (0, _getBoundary.getBoundary)(container, overflowBoundary)
|
|
17
17
|
},
|
|
18
18
|
apply ({ availableHeight , availableWidth , elements , rects }) {
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
if (applyMaxHeight) {
|
|
22
|
-
Object.assign(elements.floating.style, {
|
|
23
|
-
maxHeight: `${availableHeight}px`,
|
|
24
|
-
boxSizing: 'border-box',
|
|
25
|
-
overflowY: 'auto'
|
|
26
|
-
});
|
|
19
|
+
if (autoSize) {
|
|
20
|
+
elements.floating.style.setProperty('box-sizing', 'border-box');
|
|
27
21
|
}
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
});
|
|
22
|
+
const applyMaxWidth = autoSize === 'always' || autoSize === 'width-always';
|
|
23
|
+
const widthOverflow = rects.floating.width > availableWidth && (autoSize === true || autoSize === 'width');
|
|
24
|
+
const applyMaxHeight = autoSize === 'always' || autoSize === 'height-always';
|
|
25
|
+
const heightOverflow = rects.floating.height > availableHeight && (autoSize === true || autoSize === 'height');
|
|
26
|
+
if (applyMaxHeight || heightOverflow) {
|
|
27
|
+
elements.floating.style.setProperty('max-height', `${availableHeight}px`);
|
|
28
|
+
}
|
|
29
|
+
if (heightOverflow) {
|
|
30
|
+
elements.floating.style.setProperty('height', `${availableHeight}px`);
|
|
31
|
+
elements.floating.style.setProperty('overflow-y', 'auto');
|
|
32
|
+
}
|
|
33
|
+
if (applyMaxWidth || widthOverflow) {
|
|
34
|
+
elements.floating.style.setProperty('max-width', `${availableWidth}px`);
|
|
35
|
+
}
|
|
36
|
+
if (widthOverflow) {
|
|
37
|
+
elements.floating.style.setProperty('width', `${availableWidth}px`);
|
|
38
|
+
elements.floating.style.setProperty('overflow-x', 'auto');
|
|
34
39
|
}
|
|
35
40
|
}
|
|
36
41
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["maxSize.js"],"sourcesContent":["import { size } from '@floating-ui/dom';\nimport { getBoundary } from '../utils/getBoundary';\nexport function maxSize(autoSize, options) {\n const { container , overflowBoundary } = options;\n return size({\n ...overflowBoundary && {\n altBoundary: true,\n boundary: getBoundary(container, overflowBoundary)\n },\n apply ({ availableHeight , availableWidth , elements , rects }) {\n const applyMaxWidth = autoSize === 'always' || autoSize === 'width-always'
|
|
1
|
+
{"version":3,"sources":["maxSize.js"],"sourcesContent":["import { size } from '@floating-ui/dom';\nimport { getBoundary } from '../utils/getBoundary';\nexport function maxSize(autoSize, options) {\n const { container , overflowBoundary } = options;\n return size({\n ...overflowBoundary && {\n altBoundary: true,\n boundary: getBoundary(container, overflowBoundary)\n },\n apply ({ availableHeight , availableWidth , elements , rects }) {\n if (autoSize) {\n elements.floating.style.setProperty('box-sizing', 'border-box');\n }\n const applyMaxWidth = autoSize === 'always' || autoSize === 'width-always';\n const widthOverflow = rects.floating.width > availableWidth && (autoSize === true || autoSize === 'width');\n const applyMaxHeight = autoSize === 'always' || autoSize === 'height-always';\n const heightOverflow = rects.floating.height > availableHeight && (autoSize === true || autoSize === 'height');\n if (applyMaxHeight || heightOverflow) {\n elements.floating.style.setProperty('max-height', `${availableHeight}px`);\n }\n if (heightOverflow) {\n elements.floating.style.setProperty('height', `${availableHeight}px`);\n elements.floating.style.setProperty('overflow-y', 'auto');\n }\n if (applyMaxWidth || widthOverflow) {\n elements.floating.style.setProperty('max-width', `${availableWidth}px`);\n }\n if (widthOverflow) {\n elements.floating.style.setProperty('width', `${availableWidth}px`);\n elements.floating.style.setProperty('overflow-x', 'auto');\n }\n }\n });\n}\n"],"names":["maxSize","autoSize","options","container","overflowBoundary","size","altBoundary","boundary","getBoundary","apply","availableHeight","availableWidth","elements","rects","floating","style","setProperty","applyMaxWidth","widthOverflow","width","applyMaxHeight","heightOverflow","height"],"mappings":";;;;+BAEgBA;;aAAAA;;qBAFK;6BACO;AACrB,SAASA,QAAQC,QAAQ,EAAEC,OAAO,EAAE;IACvC,MAAM,EAAEC,UAAS,EAAGC,iBAAgB,EAAG,GAAGF;IAC1C,OAAOG,IAAAA,SAAI,EAAC;QACR,GAAGD,oBAAoB;YACnBE,aAAa,IAAI;YACjBC,UAAUC,IAAAA,wBAAW,EAACL,WAAWC;QACrC,CAAC;QACDK,OAAO,EAAEC,gBAAe,EAAGC,eAAc,EAAGC,SAAQ,EAAGC,MAAK,EAAG,EAAE;YAC7D,IAAIZ,UAAU;gBACVW,SAASE,QAAQ,CAACC,KAAK,CAACC,WAAW,CAAC,cAAc;YACtD,CAAC;YACD,MAAMC,gBAAgBhB,aAAa,YAAYA,aAAa;YAC5D,MAAMiB,gBAAgBL,MAAMC,QAAQ,CAACK,KAAK,GAAGR,kBAAmBV,CAAAA,aAAa,IAAI,IAAIA,aAAa,OAAM;YACxG,MAAMmB,iBAAiBnB,aAAa,YAAYA,aAAa;YAC7D,MAAMoB,iBAAiBR,MAAMC,QAAQ,CAACQ,MAAM,GAAGZ,mBAAoBT,CAAAA,aAAa,IAAI,IAAIA,aAAa,QAAO;YAC5G,IAAImB,kBAAkBC,gBAAgB;gBAClCT,SAASE,QAAQ,CAACC,KAAK,CAACC,WAAW,CAAC,cAAc,CAAC,EAAEN,gBAAgB,EAAE,CAAC;YAC5E,CAAC;YACD,IAAIW,gBAAgB;gBAChBT,SAASE,QAAQ,CAACC,KAAK,CAACC,WAAW,CAAC,UAAU,CAAC,EAAEN,gBAAgB,EAAE,CAAC;gBACpEE,SAASE,QAAQ,CAACC,KAAK,CAACC,WAAW,CAAC,cAAc;YACtD,CAAC;YACD,IAAIC,iBAAiBC,eAAe;gBAChCN,SAASE,QAAQ,CAACC,KAAK,CAACC,WAAW,CAAC,aAAa,CAAC,EAAEL,eAAe,EAAE,CAAC;YAC1E,CAAC;YACD,IAAIO,eAAe;gBACfN,SAASE,QAAQ,CAACC,KAAK,CAACC,WAAW,CAAC,SAAS,CAAC,EAAEL,eAAe,EAAE,CAAC;gBAClEC,SAASE,QAAQ,CAACC,KAAK,CAACC,WAAW,CAAC,cAAc;YACtD,CAAC;QACL;IACJ;AACJ"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluentui/react-positioning",
|
|
3
|
-
"version": "0.0.0-nightly-
|
|
3
|
+
"version": "0.0.0-nightly-20230726-0415.1",
|
|
4
4
|
"description": "A react wrapper around Popper.js for Fluent UI",
|
|
5
5
|
"main": "lib-commonjs/index.js",
|
|
6
6
|
"module": "lib/index.js",
|
|
@@ -30,9 +30,9 @@
|
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
32
|
"@floating-ui/dom": "^1.2.0",
|
|
33
|
-
"@fluentui/react-shared-contexts": "0.0.0-nightly-
|
|
34
|
-
"@fluentui/react-theme": "0.0.0-nightly-
|
|
35
|
-
"@fluentui/react-utilities": "0.0.0-nightly-
|
|
33
|
+
"@fluentui/react-shared-contexts": "0.0.0-nightly-20230726-0415.1",
|
|
34
|
+
"@fluentui/react-theme": "0.0.0-nightly-20230726-0415.1",
|
|
35
|
+
"@fluentui/react-utilities": "0.0.0-nightly-20230726-0415.1",
|
|
36
36
|
"@griffel/react": "^1.5.7",
|
|
37
37
|
"@swc/helpers": "^0.4.14"
|
|
38
38
|
},
|