first commit

This commit is contained in:
Stefan Hacker
2026-04-03 09:38:48 +02:00
commit 37ad745546
47450 changed files with 3120798 additions and 0 deletions
File diff suppressed because it is too large Load Diff
+481
View File
@@ -0,0 +1,481 @@
# Change Log - @fluentui/react-window-provider
This log was last generated on Wed, 10 Dec 2025 06:25:38 GMT and should not be manually modified.
<!-- Start content -->
## [2.3.2](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.3.2)
Wed, 10 Dec 2025 06:25:38 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.3.1..@fluentui/react-window-provider_v2.3.2)
### Patches
- chore: remove unused eslint-disable directives ([PR #35518](https://github.com/microsoft/fluentui/pull/35518) by vgenaev@gmail.com)
## [2.3.0](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.3.0)
Thu, 23 Oct 2025 10:23:21 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.29..@fluentui/react-window-provider_v2.3.0)
### Minor changes
- feat: bump react range to support React 19 ([PR #35362](https://github.com/microsoft/fluentui/pull/35362) by martinhochel@microsoft.com)
## [2.2.29](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.29)
Fri, 21 Feb 2025 07:22:41 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.28..@fluentui/react-window-provider_v2.2.29)
### Patches
- Bump @fluentui/set-version to v8.2.24 ([PR #33879](https://github.com/microsoft/fluentui/pull/33879) by beachball)
## [2.2.28](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.28)
Thu, 01 Aug 2024 07:24:47 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.27..@fluentui/react-window-provider_v2.2.28)
### Patches
- fix: revert incorectly set npm versions in all packages ([PR #31937](https://github.com/microsoft/fluentui/pull/31937) by martinhochel@microsoft.com)
## [2.2.27](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.27)
Mon, 24 Jun 2024 07:33:22 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.26..@fluentui/react-window-provider_v2.2.27)
### Patches
- Bump @fluentui/set-version to v8.2.23 ([commit](https://github.com/microsoft/fluentui/commit/444d2ef497b5be5b4252f4af86ded3d2db7a0850) by beachball)
## [2.2.26](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.26)
Thu, 06 Jun 2024 07:26:46 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.25..@fluentui/react-window-provider_v2.2.26)
### Patches
- Bump @fluentui/set-version to v8.2.22 ([commit](https://github.com/microsoft/fluentui/commit/e5e806f46bd00bc7baffbfe7514a617600ba2d47) by beachball)
## [2.2.25](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.25)
Tue, 28 May 2024 07:28:20 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.24..@fluentui/react-window-provider_v2.2.25)
### Patches
- Bump @fluentui/set-version to v8.2.21 ([PR #31324](https://github.com/microsoft/fluentui/pull/31324) by beachball)
## [2.2.24](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.24)
Fri, 24 May 2024 07:28:17 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.23..@fluentui/react-window-provider_v2.2.24)
### Patches
- Bump @fluentui/set-version to v8.2.20 ([commit](https://github.com/microsoft/fluentui/commit/e5b614623b9aa1ae3f1f86f3e753b934943a4601) by beachball)
## [2.2.23](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.23)
Thu, 23 May 2024 07:28:51 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.22..@fluentui/react-window-provider_v2.2.23)
### Patches
- Bump @fluentui/set-version to v8.2.19 ([commit](https://github.com/microsoft/fluentui/commit/10e6758b203de79c53ce31ba264e137f83f50ff4) by beachball)
## [2.2.22](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.22)
Mon, 20 May 2024 07:29:20 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.21..@fluentui/react-window-provider_v2.2.22)
### Patches
- Bump @fluentui/set-version to v8.2.18 ([commit](https://github.com/microsoft/fluentui/commit/eadc00f974b3199e6c34d2e9d16015add154ec3b) by beachball)
## [2.2.21](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.21)
Wed, 24 Apr 2024 07:27:48 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.20..@fluentui/react-window-provider_v2.2.21)
### Patches
- Bump @fluentui/set-version to v8.2.17 ([PR #31130](https://github.com/microsoft/fluentui/pull/31130) by beachball)
## [2.2.20](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.20)
Fri, 12 Apr 2024 07:29:11 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.19..@fluentui/react-window-provider_v2.2.20)
### Patches
- Bump @fluentui/set-version to v8.2.16 ([PR #31022](https://github.com/microsoft/fluentui/pull/31022) by beachball)
## [2.2.19](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.19)
Wed, 03 Apr 2024 07:29:31 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.18..@fluentui/react-window-provider_v2.2.19)
### Patches
- Bump @fluentui/set-version to v8.2.15 ([PR #30943](https://github.com/microsoft/fluentui/pull/30943) by beachball)
## [2.2.18](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.18)
Wed, 10 Jan 2024 07:28:49 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.17..@fluentui/react-window-provider_v2.2.18)
### Patches
- chore: clean up exports ([PR #30063](https://github.com/microsoft/fluentui/pull/30063) by seanmonahan@microsoft.com)
- Bump @fluentui/set-version to v8.2.14 ([PR #30063](https://github.com/microsoft/fluentui/pull/30063) by beachball)
## [2.2.17](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.17)
Thu, 14 Dec 2023 07:30:10 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.16..@fluentui/react-window-provider_v2.2.17)
### Patches
- chore: disallow `window` and `document` access ([PR #29962](https://github.com/microsoft/fluentui/pull/29962) by seanmonahan@microsoft.com)
- Bump @fluentui/set-version to v8.2.13 ([PR #30061](https://github.com/microsoft/fluentui/pull/30061) by beachball)
## [2.2.16](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.16)
Sat, 28 Oct 2023 00:29:16 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.15..@fluentui/react-window-provider_v2.2.16)
### Patches
- Bump @fluentui/set-version to v8.2.12 ([commit](https://github.com/microsoft/fluentui/commit/70d0762fd12eb211f7c1dbe31a23b2fbb73a67c4) by beachball)
## [2.2.15](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.15)
Wed, 31 May 2023 07:38:40 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.14..@fluentui/react-window-provider_v2.2.15)
### Patches
- Bump @fluentui/set-version to v8.2.11 ([commit](https://github.com/microsoft/fluentui/commit/dd8c30d9b97f68eb332366fc0e69775a88775319) by beachball)
- Bump @fluentui/test-utilities to v8.3.6 ([commit](https://github.com/microsoft/fluentui/commit/dd8c30d9b97f68eb332366fc0e69775a88775319) by beachball)
## [2.2.14](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.14)
Tue, 30 May 2023 07:36:09 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.13..@fluentui/react-window-provider_v2.2.14)
### Patches
- Bump @fluentui/set-version to v8.2.10 ([PR #27685](https://github.com/microsoft/fluentui/pull/27685) by beachball)
- Bump @fluentui/test-utilities to v8.3.5 ([PR #27685](https://github.com/microsoft/fluentui/pull/27685) by beachball)
## [2.2.13](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.13)
Fri, 05 May 2023 18:13:59 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.12..@fluentui/react-window-provider_v2.2.13)
### Patches
- fix: explicitly ship dist/ folder. ([PR #27769](https://github.com/microsoft/fluentui/pull/27769) by tristan.watanabe@gmail.com)
- Bump @fluentui/set-version to v8.2.9 ([PR #27769](https://github.com/microsoft/fluentui/pull/27769) by beachball)
- Bump @fluentui/test-utilities to v8.3.4 ([PR #27769](https://github.com/microsoft/fluentui/pull/27769) by beachball)
## [2.2.12](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.12)
Tue, 02 May 2023 22:20:25 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.11..@fluentui/react-window-provider_v2.2.12)
### Patches
- Bump @fluentui/test-utilities to v8.3.3 ([PR #27745](https://github.com/microsoft/fluentui/pull/27745) by beachball)
## [2.2.11](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.11)
Tue, 02 May 2023 00:58:17 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.10..@fluentui/react-window-provider_v2.2.11)
### Patches
- fix: esm, cjs, and amd folders should all be published correctly. ([PR #27736](https://github.com/microsoft/fluentui/pull/27736) by tristan.watanabe@gmail.com)
- Bump @fluentui/set-version to v8.2.8 ([PR #27736](https://github.com/microsoft/fluentui/pull/27736) by beachball)
## [2.2.10](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.10)
Mon, 01 May 2023 07:39:54 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.9..@fluentui/react-window-provider_v2.2.10)
### Patches
- Bump @fluentui/set-version to v8.2.7 ([PR #27724](https://github.com/microsoft/fluentui/pull/27724) by beachball)
- Bump @fluentui/test-utilities to v8.3.2 ([PR #27724](https://github.com/microsoft/fluentui/pull/27724) by beachball)
## [2.2.9](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.9)
Fri, 17 Mar 2023 08:15:56 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.8..@fluentui/react-window-provider_v2.2.9)
### Patches
- Bump @fluentui/set-version to v8.2.6 ([PR #27210](https://github.com/microsoft/fluentui/pull/27210) by beachball)
- Bump @fluentui/test-utilities to v8.3.1 ([PR #27210](https://github.com/microsoft/fluentui/pull/27210) by beachball)
## [2.2.8](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.8)
Fri, 10 Mar 2023 07:38:25 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.7..@fluentui/react-window-provider_v2.2.8)
### Patches
- fix: add explicit children to window provider to ensure react 18 type compat ([PR #27117](https://github.com/microsoft/fluentui/pull/27117) by mgodbolt@microsoft.com)
## [2.2.7](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.7)
Wed, 01 Mar 2023 07:45:41 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.6..@fluentui/react-window-provider_v2.2.7)
### Patches
- Bump @fluentui/test-utilities to v8.3.0 ([PR #26980](https://github.com/microsoft/fluentui/pull/26980) by beachball)
## [2.2.6](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.6)
Fri, 03 Feb 2023 07:50:06 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.5..@fluentui/react-window-provider_v2.2.6)
### Patches
- Bump @fluentui/set-version to v8.2.5 ([PR #26569](https://github.com/microsoft/fluentui/pull/26569) by beachball)
- Bump @fluentui/test-utilities to v8.2.6 ([PR #26569](https://github.com/microsoft/fluentui/pull/26569) by beachball)
## [2.2.5](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.5)
Tue, 10 Jan 2023 07:50:15 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.4..@fluentui/react-window-provider_v2.2.5)
### Patches
- Bump @fluentui/set-version to v8.2.4 ([PR #26260](https://github.com/microsoft/fluentui/pull/26260) by beachball)
- Bump @fluentui/test-utilities to v8.2.5 ([PR #26260](https://github.com/microsoft/fluentui/pull/26260) by beachball)
## [2.2.4](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.4)
Wed, 09 Nov 2022 07:48:12 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.3..@fluentui/react-window-provider_v2.2.4)
### Patches
- Bump @fluentui/set-version to v8.2.3 ([PR #25564](https://github.com/microsoft/fluentui/pull/25564) by beachball)
- Bump @fluentui/test-utilities to v8.2.4 ([PR #25564](https://github.com/microsoft/fluentui/pull/25564) by beachball)
## [2.2.3](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.3)
Thu, 20 Oct 2022 07:43:12 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.2..@fluentui/react-window-provider_v2.2.3)
### Patches
- chore: Bump react peer dependency to react 18. ([PR #25278](https://github.com/microsoft/fluentui/pull/25278) by mgodbolt@microsoft.com)
- Bump @fluentui/test-utilities to v8.2.3 ([PR #25294](https://github.com/microsoft/fluentui/pull/25294) by beachball)
## [2.2.2](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.2)
Mon, 08 Aug 2022 07:39:33 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.1..@fluentui/react-window-provider_v2.2.2)
### Patches
- Bump @fluentui/set-version to v8.2.2 ([PR #24212](https://github.com/microsoft/fluentui/pull/24212) by beachball)
- Bump @fluentui/test-utilities to v8.2.2 ([PR #24212](https://github.com/microsoft/fluentui/pull/24212) by beachball)
## [2.2.1](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.1)
Fri, 13 May 2022 07:45:35 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.2.0..@fluentui/react-window-provider_v2.2.1)
### Patches
- Bump @fluentui/set-version to v8.2.1 ([PR #22966](https://github.com/microsoft/fluentui/pull/22966) by beachball)
- Bump @fluentui/test-utilities to v8.2.1 ([PR #22966](https://github.com/microsoft/fluentui/pull/22966) by beachball)
## [2.2.0](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.2.0)
Thu, 03 Mar 2022 07:24:24 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.1.6..@fluentui/react-window-provider_v2.2.0)
### Minor changes
- Adding explicit export maps on all consumer packages for FUIR 8 and 9. ([PR #21508](https://github.com/microsoft/fluentui/pull/21508) by dzearing@microsoft.com)
- Bump @fluentui/set-version to v8.2.0 ([PR #21919](https://github.com/microsoft/fluentui/pull/21919) by beachball)
## [2.1.6](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.1.6)
Wed, 15 Dec 2021 07:31:29 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.1.5..@fluentui/react-window-provider_v2.1.6)
### Patches
- Bump @fluentui/test-utilities to v8.1.0 ([PR #20716](https://github.com/microsoft/fluentui/pull/20716) by beachball)
## [2.1.5](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.1.5)
Thu, 25 Nov 2021 14:54:16 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.1.4..@fluentui/react-window-provider_v2.1.5)
### Patches
- Bump @fluentui/set-version to v8.1.5 ([PR #20784](https://github.com/microsoft/fluentui/pull/20784) by beachball)
- Bump @fluentui/test-utilities to v8.0.9 ([PR #20784](https://github.com/microsoft/fluentui/pull/20784) by beachball)
## [2.1.4](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.1.4)
Tue, 03 Aug 2021 07:39:30 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.1.3..@fluentui/react-window-provider_v2.1.4)
### Patches
- Bump @fluentui/eslint-plugin to v1.3.3 ([PR #19169](https://github.com/microsoft/fluentui/pull/19169) by behowell@microsoft.com)
## [2.1.3](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.1.3)
Fri, 09 Jul 2021 07:39:31 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.1.2..@fluentui/react-window-provider_v2.1.3)
### Patches
- Bump @fluentui/eslint-plugin to v1.3.2 ([PR #18808](https://github.com/microsoft/fluentui/pull/18808) by martinhochel@microsoft.com)
## [2.1.2](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.1.2)
Mon, 07 Jun 2021 07:38:15 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.1.1..@fluentui/react-window-provider_v2.1.2)
### Patches
- Bump @fluentui/eslint-plugin to v1.3.1 ([PR #18437](https://github.com/microsoft/fluentui/pull/18437) by martinhochel@microsoft.com)
## [2.1.1](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.1.1)
Thu, 20 May 2021 07:41:54 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.1.0..@fluentui/react-window-provider_v2.1.1)
### Patches
- Bump @fluentui/eslint-plugin to v1.3.0 ([PR #18024](https://github.com/microsoft/fluentui/pull/18024) by elcraig@microsoft.com)
## [2.1.0](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.1.0)
Fri, 30 Apr 2021 07:42:23 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.0.3..@fluentui/react-window-provider_v2.1.0)
### Minor changes
- Upgrade to ts 4.0 ([PR #17932](https://github.com/microsoft/fluentui/pull/17932) by joschect@microsoft.com)
### Patches
- Bump @fluentui/eslint-plugin to v1.2.0 ([PR #17932](https://github.com/microsoft/fluentui/pull/17932) by joschect@microsoft.com)
- Bump @fluentui/set-version to v8.1.0 ([PR #17932](https://github.com/microsoft/fluentui/pull/17932) by joschect@microsoft.com)
- Bump @fluentui/test-utilities to v8.0.4 ([PR #17932](https://github.com/microsoft/fluentui/pull/17932) by joschect@microsoft.com)
- Bump @fluentui/scripts to v1.0.0 ([PR #17932](https://github.com/microsoft/fluentui/pull/17932) by joschect@microsoft.com)
## [2.0.3](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.0.3)
Fri, 23 Apr 2021 07:37:10 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.0.2..@fluentui/react-window-provider_v2.0.3)
### Patches
- Bump @fluentui/eslint-plugin to v1.1.1 ([PR #17894](https://github.com/microsoft/fluentui/pull/17894) by olfedias@microsoft.com)
## [2.0.2](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.0.2)
Wed, 31 Mar 2021 00:53:43 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.0.1..@fluentui/react-window-provider_v2.0.2)
### Patches
- Bump @fluentui/eslint-plugin to v1.1.0 ([PR #17568](https://github.com/microsoft/fluentui/pull/17568) by elcraig@microsoft.com)
## [2.0.1](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.0.1)
Fri, 26 Feb 2021 01:16:27 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.0.0-beta.9..@fluentui/react-window-provider_v2.0.1)
### Patches
- Release major version ([PR #17169](https://github.com/microsoft/fluentui/pull/17169) by elcraig@microsoft.com)
## [2.0.0-beta.9](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.0.0-beta.9)
Mon, 22 Feb 2021 12:26:22 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.0.0-beta.8..@fluentui/react-window-provider_v2.0.0-beta.9)
### Changes
- Bump @fluentui/test-utilities to v8.0.0-beta.9 ([PR #17061](https://github.com/microsoft/fluentui/pull/17061) by elcraig@microsoft.com)
## [2.0.0-beta.8](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.0.0-beta.8)
Thu, 18 Feb 2021 19:38:50 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.0.0-beta.7..@fluentui/react-window-provider_v2.0.0-beta.8)
### Changes
- Allow React 17 in peerDependencies. The library has not yet been fully validated with React 17, so please report any issues you find. ([PR #17048](https://github.com/microsoft/fluentui/pull/17048) by elcraig@microsoft.com)
## [2.0.0-beta.7](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.0.0-beta.7)
Thu, 18 Feb 2021 12:27:34 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.0.0-beta.6..@fluentui/react-window-provider_v2.0.0-beta.7)
### Changes
- Bump @fluentui/test-utilities to v8.0.0-beta.7 ([PR #16975](https://github.com/microsoft/fluentui/pull/16975) by elcraig@microsoft.com)
## [2.0.0-beta.6](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.0.0-beta.6)
Mon, 15 Feb 2021 12:22:00 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.0.0-beta.5..@fluentui/react-window-provider_v2.0.0-beta.6)
### Changes
- Bump @fluentui/test-utilities to v8.0.0-beta.6 ([PR #16880](https://github.com/microsoft/fluentui/pull/16880) by xgao@microsoft.com)
## [2.0.0-beta.5](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.0.0-beta.5)
Thu, 28 Jan 2021 12:25:56 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.0.0-beta.4..@fluentui/react-window-provider_v2.0.0-beta.5)
### Changes
- Updating to webpack 5, latest typings, latest loaders and plugins. ([PR #16447](https://github.com/microsoft/fluentui/pull/16447) by dzearing@microsoft.com)
## [2.0.0-beta.4](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.0.0-beta.4)
Thu, 21 Jan 2021 12:36:12 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v2.0.0-beta.0..@fluentui/react-window-provider_v2.0.0-beta.4)
### Changes
- Updating dev dependencies. ([PR #16548](https://github.com/microsoft/fluentui/pull/16548) by dzearing@microsoft.com)
## [2.0.0-beta.0](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v2.0.0-beta.0)
Fri, 23 Oct 2020 03:26:15 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-window-provider_v0.3.2..@fluentui/react-window-provider_v2.0.0-beta.0)
### Changes
- Add missing version.ts; Remove unneeded package dependencies. ([PR #15456](https://github.com/microsoft/fluentui/pull/15456) by xgao@microsoft.com)
- Fix version.ts to have correct package name. ([PR #15532](https://github.com/microsoft/fluentui/pull/15532) by xgao@microsoft.com)
- Rename @uifabric/set-version to @fluentui/set-version ([PR #15616](https://github.com/microsoft/fluentui/pull/15616) by ololubek@microsoft.com)
- Remove react-dom from peerDependencies ([PR #15634](https://github.com/microsoft/fluentui/pull/15634) by elcraig@microsoft.com)
## [0.2.0](https://github.com/microsoft/fluentui/tree/@fluentui/react-window-provider_v0.2.0)
Wed, 19 Aug 2020 12:44:33 GMT
### Patches
- Introducing react-window-provider package. ([PR #14599](https://github.com/microsoft/fluentui/pull/14599) by dzearing@hotmail.com)
+15
View File
@@ -0,0 +1,15 @@
@fluentui/react-window-provider
Copyright (c) Microsoft Corporation
All rights reserved.
MIT License
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the ""Software""), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Note: Usage of the fonts and icons referenced in Fluent UI React is subject to the terms listed at https://aka.ms/fluentui-assets-license
+34
View File
@@ -0,0 +1,34 @@
# @fluentui/react-window-provider
A set of utilities for providing and consuming the `window` and `document` references in a contextual scope.
## Why is this needed?
When rendering on the main browser window, many components need access to `window` or `document` for applying styling, listening for events, or measuring things. However it is possible to render to child windows and elements hosted in `iframe` elements.
In these cases, the target element is hosted in a different context, and thus have a different `window` reference. To aid in providing components with the correct instances of `window` or `document`, React context can be used to provide the tree of React components with the correct instance.
## Usage
To consume the window or document object, call `useWindow` or `useDocument` respectively:
```jsx
const Foo = () => {
const win = useWindow();
const doc = useDocument();
return </>
}
```
To provide a new window other than the default, wrap your app in the `WindowProvider` to override the defaults contextually:
```jsx
import { createRoot } from 'react-dom/client';
createRoot(childWindowElement).render(
<WindowProvider window={childWindow}>
<...>
</WindowProvider>,
);
```
@@ -0,0 +1,3 @@
{
"extends": "@fluentui/scripts-api-extractor/api-extractor.common.json"
}
+1
View File
@@ -0,0 +1 @@
/** Jest test setup file. */
@@ -0,0 +1,36 @@
import * as React_2 from 'react';
/**
* Hook to access the document object. This can be overridden contextually using the `WindowProvider`.
*/
export declare const useDocument: () => Document | undefined;
/**
* Hook to access the window object. This can be overridden contextually using the `WindowProvider`.
*/
export declare const useWindow: () => Window | undefined;
/**
* Context for providing the window.
*/
export declare const WindowContext: React_2.Context<WindowProviderProps>;
/**
* Component to provide the window object contextually. This is useful when rendering content to an element
* contained within a child window or iframe element, where event handlers and styling must be projected
* to an alternative window or document.
*/
export declare const WindowProvider: React_2.FunctionComponent<WindowProviderProps>;
/**
* Props for the WindowProvider component.
*/
export declare type WindowProviderProps = {
/**
* Provide the active window.
*/
window: Window | undefined;
children?: React_2.ReactNode;
};
export { }
@@ -0,0 +1,29 @@
## API Report File for "@fluentui/react-window-provider"
> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
```ts
import * as React_2 from 'react';
// @public
export const useDocument: () => Document | undefined;
// @public
export const useWindow: () => Window | undefined;
// @public
export const WindowContext: React_2.Context<WindowProviderProps>;
// @public
export const WindowProvider: React_2.FunctionComponent<WindowProviderProps>;
// @public
export type WindowProviderProps = {
window: Window | undefined;
children?: React_2.ReactNode;
};
// (No @packageDocumentation comment for this package)
```
+3
View File
@@ -0,0 +1,3 @@
import { preset } from '@fluentui/scripts-tasks';
preset();
@@ -0,0 +1,29 @@
import * as React from 'react';
/**
* Props for the WindowProvider component.
*/
export type WindowProviderProps = {
/**
* Provide the active window.
*/
window: Window | undefined;
children?: React.ReactNode;
};
/**
* Context for providing the window.
*/
export declare const WindowContext: React.Context<WindowProviderProps>;
/**
* Hook to access the window object. This can be overridden contextually using the `WindowProvider`.
*/
export declare const useWindow: () => Window | undefined;
/**
* Hook to access the document object. This can be overridden contextually using the `WindowProvider`.
*/
export declare const useDocument: () => Document | undefined;
/**
* Component to provide the window object contextually. This is useful when rendering content to an element
* contained within a child window or iframe element, where event handlers and styling must be projected
* to an alternative window or document.
*/
export declare const WindowProvider: React.FunctionComponent<WindowProviderProps>;
+32
View File
@@ -0,0 +1,32 @@
define(["require", "exports", "react"], function (require, exports, React) {
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.WindowProvider = exports.useDocument = exports.useWindow = exports.WindowContext = void 0;
/**
* Context for providing the window.
*/
exports.WindowContext = React.createContext({
// eslint-disable-next-line no-restricted-globals
window: typeof window === 'object' ? window : undefined,
});
/**
* Hook to access the window object. This can be overridden contextually using the `WindowProvider`.
*/
var useWindow = function () { return React.useContext(exports.WindowContext).window; };
exports.useWindow = useWindow;
/**
* Hook to access the document object. This can be overridden contextually using the `WindowProvider`.
*/
var useDocument = function () { var _a; return (_a = React.useContext(exports.WindowContext).window) === null || _a === void 0 ? void 0 : _a.document; };
exports.useDocument = useDocument;
/**
* Component to provide the window object contextually. This is useful when rendering content to an element
* contained within a child window or iframe element, where event handlers and styling must be projected
* to an alternative window or document.
*/
var WindowProvider = function (props) {
return React.createElement(exports.WindowContext.Provider, { value: props }, props.children);
};
exports.WindowProvider = WindowProvider;
});
//# sourceMappingURL=WindowProvider.js.map
@@ -0,0 +1 @@
{"version":3,"file":"WindowProvider.js","sourceRoot":"../src/","sources":["WindowProvider.tsx"],"names":[],"mappings":";;;;IAaA;;OAEG;IACU,QAAA,aAAa,GAAG,KAAK,CAAC,aAAa,CAAsB;QACpE,iDAAiD;QACjD,MAAM,EAAE,OAAO,MAAM,KAAK,QAAQ,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,SAAS;KACxD,CAAC,CAAC;IAEH;;OAEG;IACI,IAAM,SAAS,GAAG,cAA0B,OAAA,KAAK,CAAC,UAAU,CAAC,qBAAa,CAAC,CAAC,MAAM,EAAtC,CAAsC,CAAC;IAA7E,QAAA,SAAS,aAAoE;IAE1F;;OAEG;IACI,IAAM,WAAW,GAAG,sBAA4B,OAAA,MAAA,KAAK,CAAC,UAAU,CAAC,qBAAa,CAAC,CAAC,MAAM,0CAAE,QAAQ,CAAA,EAAA,CAAC;IAA3F,QAAA,WAAW,eAAgF;IAExG;;;;OAIG;IACI,IAAM,cAAc,GAAiD,UAAA,KAAK;QAC/E,OAAO,oBAAC,qBAAa,CAAC,QAAQ,IAAC,KAAK,EAAE,KAAK,IAAG,KAAK,CAAC,QAAQ,CAA0B,CAAC;IACzF,CAAC,CAAC;IAFW,QAAA,cAAc,kBAEzB","sourcesContent":["import * as React from 'react';\n\n/**\n * Props for the WindowProvider component.\n */\nexport type WindowProviderProps = {\n /**\n * Provide the active window.\n */\n window: Window | undefined;\n children?: React.ReactNode;\n};\n\n/**\n * Context for providing the window.\n */\nexport const WindowContext = React.createContext<WindowProviderProps>({\n // eslint-disable-next-line no-restricted-globals\n window: typeof window === 'object' ? window : undefined,\n});\n\n/**\n * Hook to access the window object. This can be overridden contextually using the `WindowProvider`.\n */\nexport const useWindow = (): Window | undefined => React.useContext(WindowContext).window;\n\n/**\n * Hook to access the document object. This can be overridden contextually using the `WindowProvider`.\n */\nexport const useDocument = (): Document | undefined => React.useContext(WindowContext).window?.document;\n\n/**\n * Component to provide the window object contextually. This is useful when rendering content to an element\n * contained within a child window or iframe element, where event handlers and styling must be projected\n * to an alternative window or document.\n */\nexport const WindowProvider: React.FunctionComponent<WindowProviderProps> = props => {\n return <WindowContext.Provider value={props}>{props.children}</WindowContext.Provider>;\n};\n"]}
+3
View File
@@ -0,0 +1,3 @@
export { WindowContext, useWindow, useDocument, WindowProvider } from './WindowProvider';
export type { WindowProviderProps } from './WindowProvider';
import './version';
+10
View File
@@ -0,0 +1,10 @@
define(["require", "exports", "./WindowProvider", "./version"], function (require, exports, WindowProvider_1) {
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.WindowProvider = exports.useDocument = exports.useWindow = exports.WindowContext = void 0;
Object.defineProperty(exports, "WindowContext", { enumerable: true, get: function () { return WindowProvider_1.WindowContext; } });
Object.defineProperty(exports, "useWindow", { enumerable: true, get: function () { return WindowProvider_1.useWindow; } });
Object.defineProperty(exports, "useDocument", { enumerable: true, get: function () { return WindowProvider_1.useDocument; } });
Object.defineProperty(exports, "WindowProvider", { enumerable: true, get: function () { return WindowProvider_1.WindowProvider; } });
});
//# sourceMappingURL=index.js.map
+1
View File
@@ -0,0 +1 @@
{"version":3,"file":"index.js","sourceRoot":"../src/","sources":["index.ts"],"names":[],"mappings":";;;;IAAS,+GAAA,aAAa,OAAA;IAAE,2GAAA,SAAS,OAAA;IAAE,6GAAA,WAAW,OAAA;IAAE,gHAAA,cAAc,OAAA","sourcesContent":["export { WindowContext, useWindow, useDocument, WindowProvider } from './WindowProvider';\nexport type { WindowProviderProps } from './WindowProvider';\n\nimport './version';\n"]}
+1
View File
@@ -0,0 +1 @@
export {};
+6
View File
@@ -0,0 +1,6 @@
define(["require", "exports", "@fluentui/set-version"], function (require, exports, set_version_1) {
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
(0, set_version_1.setVersion)('@fluentui/react-window-provider', '2.3.2');
});
//# sourceMappingURL=version.js.map
+1
View File
@@ -0,0 +1 @@
{"version":3,"file":"version.js","sourceRoot":"../src/","sources":["version.ts"],"names":[],"mappings":";;;IAGA,IAAA,wBAAU,EAAC,iCAAiC,EAAE,OAAO,CAAC,CAAC","sourcesContent":["// Do not modify this file; it is generated as part of publish.\n// The checked in version is a placeholder only and will not be updated.\nimport { setVersion } from '@fluentui/set-version';\nsetVersion('@fluentui/react-window-provider', '2.3.2');"]}
@@ -0,0 +1,29 @@
import * as React from 'react';
/**
* Props for the WindowProvider component.
*/
export type WindowProviderProps = {
/**
* Provide the active window.
*/
window: Window | undefined;
children?: React.ReactNode;
};
/**
* Context for providing the window.
*/
export declare const WindowContext: React.Context<WindowProviderProps>;
/**
* Hook to access the window object. This can be overridden contextually using the `WindowProvider`.
*/
export declare const useWindow: () => Window | undefined;
/**
* Hook to access the document object. This can be overridden contextually using the `WindowProvider`.
*/
export declare const useDocument: () => Document | undefined;
/**
* Component to provide the window object contextually. This is useful when rendering content to an element
* contained within a child window or iframe element, where event handlers and styling must be projected
* to an alternative window or document.
*/
export declare const WindowProvider: React.FunctionComponent<WindowProviderProps>;
@@ -0,0 +1,31 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.WindowProvider = exports.useDocument = exports.useWindow = exports.WindowContext = void 0;
var React = require("react");
/**
* Context for providing the window.
*/
exports.WindowContext = React.createContext({
// eslint-disable-next-line no-restricted-globals
window: typeof window === 'object' ? window : undefined,
});
/**
* Hook to access the window object. This can be overridden contextually using the `WindowProvider`.
*/
var useWindow = function () { return React.useContext(exports.WindowContext).window; };
exports.useWindow = useWindow;
/**
* Hook to access the document object. This can be overridden contextually using the `WindowProvider`.
*/
var useDocument = function () { var _a; return (_a = React.useContext(exports.WindowContext).window) === null || _a === void 0 ? void 0 : _a.document; };
exports.useDocument = useDocument;
/**
* Component to provide the window object contextually. This is useful when rendering content to an element
* contained within a child window or iframe element, where event handlers and styling must be projected
* to an alternative window or document.
*/
var WindowProvider = function (props) {
return React.createElement(exports.WindowContext.Provider, { value: props }, props.children);
};
exports.WindowProvider = WindowProvider;
//# sourceMappingURL=WindowProvider.js.map
@@ -0,0 +1 @@
{"version":3,"file":"WindowProvider.js","sourceRoot":"../src/","sources":["WindowProvider.tsx"],"names":[],"mappings":";;;AAAA,6BAA+B;AAa/B;;GAEG;AACU,QAAA,aAAa,GAAG,KAAK,CAAC,aAAa,CAAsB;IACpE,iDAAiD;IACjD,MAAM,EAAE,OAAO,MAAM,KAAK,QAAQ,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,SAAS;CACxD,CAAC,CAAC;AAEH;;GAEG;AACI,IAAM,SAAS,GAAG,cAA0B,OAAA,KAAK,CAAC,UAAU,CAAC,qBAAa,CAAC,CAAC,MAAM,EAAtC,CAAsC,CAAC;AAA7E,QAAA,SAAS,aAAoE;AAE1F;;GAEG;AACI,IAAM,WAAW,GAAG,sBAA4B,OAAA,MAAA,KAAK,CAAC,UAAU,CAAC,qBAAa,CAAC,CAAC,MAAM,0CAAE,QAAQ,CAAA,EAAA,CAAC;AAA3F,QAAA,WAAW,eAAgF;AAExG;;;;GAIG;AACI,IAAM,cAAc,GAAiD,UAAA,KAAK;IAC/E,OAAO,oBAAC,qBAAa,CAAC,QAAQ,IAAC,KAAK,EAAE,KAAK,IAAG,KAAK,CAAC,QAAQ,CAA0B,CAAC;AACzF,CAAC,CAAC;AAFW,QAAA,cAAc,kBAEzB","sourcesContent":["import * as React from 'react';\n\n/**\n * Props for the WindowProvider component.\n */\nexport type WindowProviderProps = {\n /**\n * Provide the active window.\n */\n window: Window | undefined;\n children?: React.ReactNode;\n};\n\n/**\n * Context for providing the window.\n */\nexport const WindowContext = React.createContext<WindowProviderProps>({\n // eslint-disable-next-line no-restricted-globals\n window: typeof window === 'object' ? window : undefined,\n});\n\n/**\n * Hook to access the window object. This can be overridden contextually using the `WindowProvider`.\n */\nexport const useWindow = (): Window | undefined => React.useContext(WindowContext).window;\n\n/**\n * Hook to access the document object. This can be overridden contextually using the `WindowProvider`.\n */\nexport const useDocument = (): Document | undefined => React.useContext(WindowContext).window?.document;\n\n/**\n * Component to provide the window object contextually. This is useful when rendering content to an element\n * contained within a child window or iframe element, where event handlers and styling must be projected\n * to an alternative window or document.\n */\nexport const WindowProvider: React.FunctionComponent<WindowProviderProps> = props => {\n return <WindowContext.Provider value={props}>{props.children}</WindowContext.Provider>;\n};\n"]}
+3
View File
@@ -0,0 +1,3 @@
export { WindowContext, useWindow, useDocument, WindowProvider } from './WindowProvider';
export type { WindowProviderProps } from './WindowProvider';
import './version';
+10
View File
@@ -0,0 +1,10 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.WindowProvider = exports.useDocument = exports.useWindow = exports.WindowContext = void 0;
var WindowProvider_1 = require("./WindowProvider");
Object.defineProperty(exports, "WindowContext", { enumerable: true, get: function () { return WindowProvider_1.WindowContext; } });
Object.defineProperty(exports, "useWindow", { enumerable: true, get: function () { return WindowProvider_1.useWindow; } });
Object.defineProperty(exports, "useDocument", { enumerable: true, get: function () { return WindowProvider_1.useDocument; } });
Object.defineProperty(exports, "WindowProvider", { enumerable: true, get: function () { return WindowProvider_1.WindowProvider; } });
require("./version");
//# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
{"version":3,"file":"index.js","sourceRoot":"../src/","sources":["index.ts"],"names":[],"mappings":";;;AAAA,mDAAyF;AAAhF,+GAAA,aAAa,OAAA;AAAE,2GAAA,SAAS,OAAA;AAAE,6GAAA,WAAW,OAAA;AAAE,gHAAA,cAAc,OAAA;AAG9D,qBAAmB","sourcesContent":["export { WindowContext, useWindow, useDocument, WindowProvider } from './WindowProvider';\nexport type { WindowProviderProps } from './WindowProvider';\n\nimport './version';\n"]}
@@ -0,0 +1 @@
export {};
+7
View File
@@ -0,0 +1,7 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
// Do not modify this file; it is generated as part of publish.
// The checked in version is a placeholder only and will not be updated.
var set_version_1 = require("@fluentui/set-version");
(0, set_version_1.setVersion)('@fluentui/react-window-provider', '2.3.2');
//# sourceMappingURL=version.js.map
@@ -0,0 +1 @@
{"version":3,"file":"version.js","sourceRoot":"../src/","sources":["version.ts"],"names":[],"mappings":";;AAAA,+DAA+D;AAC/D,wEAAwE;AACxE,qDAAmD;AACnD,IAAA,wBAAU,EAAC,iCAAiC,EAAE,OAAO,CAAC,CAAC","sourcesContent":["// Do not modify this file; it is generated as part of publish.\n// The checked in version is a placeholder only and will not be updated.\nimport { setVersion } from '@fluentui/set-version';\nsetVersion('@fluentui/react-window-provider', '2.3.2');"]}
+29
View File
@@ -0,0 +1,29 @@
import * as React from 'react';
/**
* Props for the WindowProvider component.
*/
export type WindowProviderProps = {
/**
* Provide the active window.
*/
window: Window | undefined;
children?: React.ReactNode;
};
/**
* Context for providing the window.
*/
export declare const WindowContext: React.Context<WindowProviderProps>;
/**
* Hook to access the window object. This can be overridden contextually using the `WindowProvider`.
*/
export declare const useWindow: () => Window | undefined;
/**
* Hook to access the document object. This can be overridden contextually using the `WindowProvider`.
*/
export declare const useDocument: () => Document | undefined;
/**
* Component to provide the window object contextually. This is useful when rendering content to an element
* contained within a child window or iframe element, where event handlers and styling must be projected
* to an alternative window or document.
*/
export declare const WindowProvider: React.FunctionComponent<WindowProviderProps>;
+25
View File
@@ -0,0 +1,25 @@
import * as React from 'react';
/**
* Context for providing the window.
*/
export var WindowContext = React.createContext({
// eslint-disable-next-line no-restricted-globals
window: typeof window === 'object' ? window : undefined,
});
/**
* Hook to access the window object. This can be overridden contextually using the `WindowProvider`.
*/
export var useWindow = function () { return React.useContext(WindowContext).window; };
/**
* Hook to access the document object. This can be overridden contextually using the `WindowProvider`.
*/
export var useDocument = function () { var _a; return (_a = React.useContext(WindowContext).window) === null || _a === void 0 ? void 0 : _a.document; };
/**
* Component to provide the window object contextually. This is useful when rendering content to an element
* contained within a child window or iframe element, where event handlers and styling must be projected
* to an alternative window or document.
*/
export var WindowProvider = function (props) {
return React.createElement(WindowContext.Provider, { value: props }, props.children);
};
//# sourceMappingURL=WindowProvider.js.map
@@ -0,0 +1 @@
{"version":3,"file":"WindowProvider.js","sourceRoot":"../src/","sources":["WindowProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAa/B;;GAEG;AACH,MAAM,CAAC,IAAM,aAAa,GAAG,KAAK,CAAC,aAAa,CAAsB;IACpE,iDAAiD;IACjD,MAAM,EAAE,OAAO,MAAM,KAAK,QAAQ,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,SAAS;CACxD,CAAC,CAAC;AAEH;;GAEG;AACH,MAAM,CAAC,IAAM,SAAS,GAAG,cAA0B,OAAA,KAAK,CAAC,UAAU,CAAC,aAAa,CAAC,CAAC,MAAM,EAAtC,CAAsC,CAAC;AAE1F;;GAEG;AACH,MAAM,CAAC,IAAM,WAAW,GAAG,sBAA4B,OAAA,MAAA,KAAK,CAAC,UAAU,CAAC,aAAa,CAAC,CAAC,MAAM,0CAAE,QAAQ,CAAA,EAAA,CAAC;AAExG;;;;GAIG;AACH,MAAM,CAAC,IAAM,cAAc,GAAiD,UAAA,KAAK;IAC/E,OAAO,oBAAC,aAAa,CAAC,QAAQ,IAAC,KAAK,EAAE,KAAK,IAAG,KAAK,CAAC,QAAQ,CAA0B,CAAC;AACzF,CAAC,CAAC","sourcesContent":["import * as React from 'react';\n\n/**\n * Props for the WindowProvider component.\n */\nexport type WindowProviderProps = {\n /**\n * Provide the active window.\n */\n window: Window | undefined;\n children?: React.ReactNode;\n};\n\n/**\n * Context for providing the window.\n */\nexport const WindowContext = React.createContext<WindowProviderProps>({\n // eslint-disable-next-line no-restricted-globals\n window: typeof window === 'object' ? window : undefined,\n});\n\n/**\n * Hook to access the window object. This can be overridden contextually using the `WindowProvider`.\n */\nexport const useWindow = (): Window | undefined => React.useContext(WindowContext).window;\n\n/**\n * Hook to access the document object. This can be overridden contextually using the `WindowProvider`.\n */\nexport const useDocument = (): Document | undefined => React.useContext(WindowContext).window?.document;\n\n/**\n * Component to provide the window object contextually. This is useful when rendering content to an element\n * contained within a child window or iframe element, where event handlers and styling must be projected\n * to an alternative window or document.\n */\nexport const WindowProvider: React.FunctionComponent<WindowProviderProps> = props => {\n return <WindowContext.Provider value={props}>{props.children}</WindowContext.Provider>;\n};\n"]}
+3
View File
@@ -0,0 +1,3 @@
export { WindowContext, useWindow, useDocument, WindowProvider } from './WindowProvider';
export type { WindowProviderProps } from './WindowProvider';
import './version';
+3
View File
@@ -0,0 +1,3 @@
export { WindowContext, useWindow, useDocument, WindowProvider } from './WindowProvider';
import './version';
//# sourceMappingURL=index.js.map
+1
View File
@@ -0,0 +1 @@
{"version":3,"file":"index.js","sourceRoot":"../src/","sources":["index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,SAAS,EAAE,WAAW,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAGzF,OAAO,WAAW,CAAC","sourcesContent":["export { WindowContext, useWindow, useDocument, WindowProvider } from './WindowProvider';\nexport type { WindowProviderProps } from './WindowProvider';\n\nimport './version';\n"]}
+1
View File
@@ -0,0 +1 @@
export {};
+5
View File
@@ -0,0 +1,5 @@
// Do not modify this file; it is generated as part of publish.
// The checked in version is a placeholder only and will not be updated.
import { setVersion } from '@fluentui/set-version';
setVersion('@fluentui/react-window-provider', '2.3.2');
//# sourceMappingURL=version.js.map
+1
View File
@@ -0,0 +1 @@
{"version":3,"file":"version.js","sourceRoot":"../src/","sources":["version.ts"],"names":[],"mappings":"AAAA,+DAA+D;AAC/D,wEAAwE;AACxE,OAAO,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AACnD,UAAU,CAAC,iCAAiC,EAAE,OAAO,CAAC,CAAC","sourcesContent":["// Do not modify this file; it is generated as part of publish.\n// The checked in version is a placeholder only and will not be updated.\nimport { setVersion } from '@fluentui/set-version';\nsetVersion('@fluentui/react-window-provider', '2.3.2');"]}
+42
View File
@@ -0,0 +1,42 @@
{
"name": "@fluentui/react-window-provider",
"version": "2.3.2",
"description": "Utilities for providing and consuming the window/document objects even across portal/iframe/child-window boundaries.",
"main": "lib-commonjs/index.js",
"module": "lib/index.js",
"typings": "lib/index.d.ts",
"sideEffects": [
"lib/version.js"
],
"repository": {
"type": "git",
"url": "https://github.com/microsoft/fluentui"
},
"license": "MIT",
"scripts": {
"build": "just-scripts build",
"clean": "just-scripts clean"
},
"devDependencies": {
"@fluentui/eslint-plugin": "*",
"@fluentui/test-utilities": "*",
"@fluentui/scripts-api-extractor": "*",
"@fluentui/scripts-jest": "*",
"@fluentui/scripts-tasks": "*"
},
"dependencies": {
"@fluentui/set-version": "^8.2.24",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@types/react": ">=16.8.0 <20.0.0",
"react": ">=16.8.0 <20.0.0"
},
"exports": {
".": {
"types": "./lib/index.d.ts",
"import": "./lib/index.js",
"require": "./lib-commonjs/index.js"
}
}
}
+7
View File
@@ -0,0 +1,7 @@
{
"name": "react-window-provider",
"$schema": "../../node_modules/nx/schemas/project-schema.json",
"projectType": "library",
"tags": ["v8"],
"implicitDependencies": []
}