@fluentui/react-portal-compat-context 9.0.0 → 9.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.json +72 -1
- package/CHANGELOG.md +20 -2
- package/lib/PortalCompatContext.js +11 -5
- package/lib/PortalCompatContext.js.map +1 -1
- package/lib-amd/PortalCompatContext.js +14 -0
- package/lib-amd/PortalCompatContext.js.map +1 -0
- package/lib-amd/index.js +8 -0
- package/lib-amd/index.js.map +1 -0
- package/lib-amd/types.js +5 -0
- package/lib-amd/types.js.map +1 -0
- package/lib-commonjs/PortalCompatContext.js +11 -5
- package/lib-commonjs/PortalCompatContext.js.map +1 -1
- package/package.json +6 -7
- package/dist/tsdoc-metadata.json +0 -11
package/CHANGELOG.json
CHANGED
@@ -2,7 +2,78 @@
|
|
2
2
|
"name": "@fluentui/react-portal-compat-context",
|
3
3
|
"entries": [
|
4
4
|
{
|
5
|
-
"date": "
|
5
|
+
"date": "Thu, 15 Sep 2022 09:44:37 GMT",
|
6
|
+
"tag": "@fluentui/react-portal-compat-context_v9.0.2",
|
7
|
+
"version": "9.0.2",
|
8
|
+
"comments": {
|
9
|
+
"none": [
|
10
|
+
{
|
11
|
+
"author": "martinhochel@microsoft.com",
|
12
|
+
"package": "@fluentui/react-portal-compat-context",
|
13
|
+
"commit": "e6cf183695d6d67a24e038c49a876224e5ed35e5",
|
14
|
+
"comment": "chore: update package scaffold"
|
15
|
+
}
|
16
|
+
],
|
17
|
+
"patch": [
|
18
|
+
{
|
19
|
+
"author": "lingfangao@hotmail.com",
|
20
|
+
"package": "@fluentui/react-portal-compat-context",
|
21
|
+
"commit": "a0cfab0e5f74e3a3bfa9c269fff574295042d7f2",
|
22
|
+
"comment": "chore: fix no-context-default-value lint violations"
|
23
|
+
}
|
24
|
+
]
|
25
|
+
}
|
26
|
+
},
|
27
|
+
{
|
28
|
+
"date": "Wed, 03 Aug 2022 16:03:55 GMT",
|
29
|
+
"tag": "@fluentui/react-portal-compat-context_v9.0.1",
|
30
|
+
"version": "9.0.1",
|
31
|
+
"comments": {
|
32
|
+
"none": [
|
33
|
+
{
|
34
|
+
"author": "bernardo.sunderhus@gmail.com",
|
35
|
+
"package": "@fluentui/react-portal-compat-context",
|
36
|
+
"commit": "d966ea3d9169f2e8d69f0d2a4daf86fe4ca328d6",
|
37
|
+
"comment": "disables eslint rule @fluentui/no-context-default-value for local component context"
|
38
|
+
},
|
39
|
+
{
|
40
|
+
"author": "lingfangao@hotmail.com",
|
41
|
+
"package": "@fluentui/react-portal-compat-context",
|
42
|
+
"commit": "99cc385631d04a76ee10ebc143cb9fecd99640b6",
|
43
|
+
"comment": "chore: Add `prerelease` as disallowed changetype for 9.0.0 packages"
|
44
|
+
},
|
45
|
+
{
|
46
|
+
"author": "martinhochel@microsoft.com",
|
47
|
+
"package": "@fluentui/react-portal-compat-context",
|
48
|
+
"commit": "30737a497e7787fe8b4efddeadb4a261ba19933f",
|
49
|
+
"comment": "refactor(scripts): replace isCompatibilityPackage with new --module build flag"
|
50
|
+
},
|
51
|
+
{
|
52
|
+
"author": "lingfangao@hotmail.com",
|
53
|
+
"package": "@fluentui/react-portal-compat-context",
|
54
|
+
"commit": "6731ada047afe1d79d2765d1464cfa9acb90bee8",
|
55
|
+
"comment": "chore: Explicitly enable AMD lint-imports rule"
|
56
|
+
}
|
57
|
+
]
|
58
|
+
}
|
59
|
+
},
|
60
|
+
{
|
61
|
+
"date": "Fri, 15 Jul 2022 18:27:27 GMT",
|
62
|
+
"tag": "@fluentui/react-portal-compat-context_v9.0.1",
|
63
|
+
"version": "9.0.1",
|
64
|
+
"comments": {
|
65
|
+
"patch": [
|
66
|
+
{
|
67
|
+
"author": "gcox@microsoft.com",
|
68
|
+
"package": "@fluentui/react-portal-compat-context",
|
69
|
+
"commit": "9252601953bb2462fec25d22748149665868fb89",
|
70
|
+
"comment": "Added mechanism for marking fluent-compatibility packages"
|
71
|
+
}
|
72
|
+
]
|
73
|
+
}
|
74
|
+
},
|
75
|
+
{
|
76
|
+
"date": "Tue, 28 Jun 2022 15:13:50 GMT",
|
6
77
|
"tag": "@fluentui/react-portal-compat-context_v9.0.0",
|
7
78
|
"version": "9.0.0",
|
8
79
|
"comments": {
|
package/CHANGELOG.md
CHANGED
@@ -1,12 +1,30 @@
|
|
1
1
|
# Change Log - @fluentui/react-portal-compat-context
|
2
2
|
|
3
|
-
This log was last generated on
|
3
|
+
This log was last generated on Thu, 15 Sep 2022 09:44:37 GMT and should not be manually modified.
|
4
4
|
|
5
5
|
<!-- Start content -->
|
6
6
|
|
7
|
+
## [9.0.2](https://github.com/microsoft/fluentui/tree/@fluentui/react-portal-compat-context_v9.0.2)
|
8
|
+
|
9
|
+
Thu, 15 Sep 2022 09:44:37 GMT
|
10
|
+
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-portal-compat-context_v9.0.1..@fluentui/react-portal-compat-context_v9.0.2)
|
11
|
+
|
12
|
+
### Patches
|
13
|
+
|
14
|
+
- chore: fix no-context-default-value lint violations ([PR #24276](https://github.com/microsoft/fluentui/pull/24276) by lingfangao@hotmail.com)
|
15
|
+
|
16
|
+
## [9.0.1](https://github.com/microsoft/fluentui/tree/@fluentui/react-portal-compat-context_v9.0.1)
|
17
|
+
|
18
|
+
Fri, 15 Jul 2022 18:27:27 GMT
|
19
|
+
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-portal-compat-context_v9.0.0..@fluentui/react-portal-compat-context_v9.0.1)
|
20
|
+
|
21
|
+
### Patches
|
22
|
+
|
23
|
+
- Added mechanism for marking fluent-compatibility packages ([PR #23923](https://github.com/microsoft/fluentui/pull/23923) by gcox@microsoft.com)
|
24
|
+
|
7
25
|
## [9.0.0](https://github.com/microsoft/fluentui/tree/@fluentui/react-portal-compat-context_v9.0.0)
|
8
26
|
|
9
|
-
Tue, 28 Jun 2022 15:
|
27
|
+
Tue, 28 Jun 2022 15:13:50 GMT
|
10
28
|
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-portal-compat-context_v9.0.0-rc.2..@fluentui/react-portal-compat-context_v9.0.0)
|
11
29
|
|
12
30
|
### Patches
|
@@ -1,10 +1,16 @@
|
|
1
1
|
import * as React from 'react';
|
2
|
-
var PortalCompatContext = /*#__PURE__*/React.createContext(
|
3
|
-
|
4
|
-
|
5
|
-
|
2
|
+
var PortalCompatContext = /*#__PURE__*/React.createContext(undefined);
|
3
|
+
|
4
|
+
var portalCompatContextDefaultValue = function () {
|
5
|
+
return function () {
|
6
|
+
return undefined;
|
7
|
+
};
|
8
|
+
};
|
9
|
+
|
6
10
|
export var PortalCompatContextProvider = PortalCompatContext.Provider;
|
7
11
|
export function usePortalCompat() {
|
8
|
-
|
12
|
+
var _a;
|
13
|
+
|
14
|
+
return (_a = React.useContext(PortalCompatContext)) !== null && _a !== void 0 ? _a : portalCompatContextDefaultValue;
|
9
15
|
}
|
10
16
|
//# sourceMappingURL=PortalCompatContext.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["PortalCompatContext.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAZ,MAAuB,OAAvB;AAGA,IAAM,mBAAmB,gBAAG,KAAK,CAAC,aAAN,
|
1
|
+
{"version":3,"sources":["PortalCompatContext.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAZ,MAAuB,OAAvB;AAGA,IAAM,mBAAmB,gBAAG,KAAK,CAAC,aAAN,CAC1B,SAD0B,CAA5B;;AAIA,IAAM,+BAA+B,GAAG,YAAA;EAAM,OAAA,YAAA;IAAM,OAAA,SAAA;EAAN,CAAA;AAAe,CAA7D;;AAEA,OAAO,IAAM,2BAA2B,GAAG,mBAAmB,CAAC,QAAxD;AAEP,OAAM,SAAU,eAAV,GAAyB;;;EAC7B,OAAO,CAAA,EAAA,GAAA,KAAK,CAAC,UAAN,CAAiB,mBAAjB,CAAA,MAAqC,IAArC,IAAqC,EAAA,KAAA,KAAA,CAArC,GAAqC,EAArC,GAAyC,+BAAhD;AACD","sourcesContent":["import * as React from 'react';\nimport type { RegisterPortalFn } from './types';\n\nconst PortalCompatContext = React.createContext<RegisterPortalFn | undefined>(\n undefined,\n) as React.Context<RegisterPortalFn>;\n\nconst portalCompatContextDefaultValue = () => () => undefined;\n\nexport const PortalCompatContextProvider = PortalCompatContext.Provider;\n\nexport function usePortalCompat() {\n return React.useContext(PortalCompatContext) ?? portalCompatContextDefaultValue;\n}\n"],"sourceRoot":"../src/"}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
define(["require", "exports", "react"], function (require, exports, React) {
|
2
|
+
"use strict";
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
4
|
+
exports.usePortalCompat = exports.PortalCompatContextProvider = void 0;
|
5
|
+
var PortalCompatContext = React.createContext(undefined);
|
6
|
+
var portalCompatContextDefaultValue = function () { return function () { return undefined; }; };
|
7
|
+
exports.PortalCompatContextProvider = PortalCompatContext.Provider;
|
8
|
+
function usePortalCompat() {
|
9
|
+
var _a;
|
10
|
+
return (_a = React.useContext(PortalCompatContext)) !== null && _a !== void 0 ? _a : portalCompatContextDefaultValue;
|
11
|
+
}
|
12
|
+
exports.usePortalCompat = usePortalCompat;
|
13
|
+
});
|
14
|
+
//# sourceMappingURL=PortalCompatContext.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"PortalCompatContext.js","sourceRoot":"../src/","sources":["PortalCompatContext.ts"],"names":[],"mappings":";;;;IAGA,IAAM,mBAAmB,GAAG,KAAK,CAAC,aAAa,CAC7C,SAAS,CACyB,CAAC;IAErC,IAAM,+BAA+B,GAAG,cAAM,OAAA,cAAM,OAAA,SAAS,EAAT,CAAS,EAAf,CAAe,CAAC;IAEjD,QAAA,2BAA2B,GAAG,mBAAmB,CAAC,QAAQ,CAAC;IAExE,SAAgB,eAAe;;QAC7B,OAAO,MAAA,KAAK,CAAC,UAAU,CAAC,mBAAmB,CAAC,mCAAI,+BAA+B,CAAC;IAClF,CAAC;IAFD,0CAEC","sourcesContent":["import * as React from 'react';\nimport type { RegisterPortalFn } from './types';\n\nconst PortalCompatContext = React.createContext<RegisterPortalFn | undefined>(\n undefined,\n) as React.Context<RegisterPortalFn>;\n\nconst portalCompatContextDefaultValue = () => () => undefined;\n\nexport const PortalCompatContextProvider = PortalCompatContext.Provider;\n\nexport function usePortalCompat() {\n return React.useContext(PortalCompatContext) ?? portalCompatContextDefaultValue;\n}\n"]}
|
package/lib-amd/index.js
ADDED
@@ -0,0 +1,8 @@
|
|
1
|
+
define(["require", "exports", "./PortalCompatContext"], function (require, exports, PortalCompatContext_1) {
|
2
|
+
"use strict";
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
4
|
+
exports.usePortalCompat = exports.PortalCompatContextProvider = void 0;
|
5
|
+
Object.defineProperty(exports, "PortalCompatContextProvider", { enumerable: true, get: function () { return PortalCompatContext_1.PortalCompatContextProvider; } });
|
6
|
+
Object.defineProperty(exports, "usePortalCompat", { enumerable: true, get: function () { return PortalCompatContext_1.usePortalCompat; } });
|
7
|
+
});
|
8
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"../src/","sources":["index.ts"],"names":[],"mappings":";;;;IAAS,kIAAA,2BAA2B,OAAA;IAAE,sHAAA,eAAe,OAAA","sourcesContent":["export { PortalCompatContextProvider, usePortalCompat } from './PortalCompatContext';\nexport type { RegisterPortalFn } from './types';\n"]}
|
package/lib-amd/types.js
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"../src/","sources":["types.ts"],"names":[],"mappings":"","sourcesContent":["export type RegisterPortalFn = (el: HTMLElement) => () => void;\n"]}
|
@@ -7,14 +7,20 @@ exports.usePortalCompat = exports.PortalCompatContextProvider = void 0;
|
|
7
7
|
|
8
8
|
var React = /*#__PURE__*/require("react");
|
9
9
|
|
10
|
-
var PortalCompatContext = /*#__PURE__*/React.createContext(
|
11
|
-
|
12
|
-
|
13
|
-
|
10
|
+
var PortalCompatContext = /*#__PURE__*/React.createContext(undefined);
|
11
|
+
|
12
|
+
var portalCompatContextDefaultValue = function () {
|
13
|
+
return function () {
|
14
|
+
return undefined;
|
15
|
+
};
|
16
|
+
};
|
17
|
+
|
14
18
|
exports.PortalCompatContextProvider = PortalCompatContext.Provider;
|
15
19
|
|
16
20
|
function usePortalCompat() {
|
17
|
-
|
21
|
+
var _a;
|
22
|
+
|
23
|
+
return (_a = React.useContext(PortalCompatContext)) !== null && _a !== void 0 ? _a : portalCompatContextDefaultValue;
|
18
24
|
}
|
19
25
|
|
20
26
|
exports.usePortalCompat = usePortalCompat;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["PortalCompatContext.ts"],"names":[],"mappings":";;;;;;;AAAA,IAAA,KAAA,gBAAA,OAAA,CAAA,OAAA,CAAA;;AAGA,IAAM,mBAAmB,gBAAG,KAAK,CAAC,aAAN,
|
1
|
+
{"version":3,"sources":["PortalCompatContext.ts"],"names":[],"mappings":";;;;;;;AAAA,IAAA,KAAA,gBAAA,OAAA,CAAA,OAAA,CAAA;;AAGA,IAAM,mBAAmB,gBAAG,KAAK,CAAC,aAAN,CAC1B,SAD0B,CAA5B;;AAIA,IAAM,+BAA+B,GAAG,YAAA;EAAM,OAAA,YAAA;IAAM,OAAA,SAAA;EAAN,CAAA;AAAe,CAA7D;;AAEa,OAAA,CAAA,2BAAA,GAA8B,mBAAmB,CAAC,QAAlD;;AAEb,SAAgB,eAAhB,GAA+B;;;EAC7B,OAAO,CAAA,EAAA,GAAA,KAAK,CAAC,UAAN,CAAiB,mBAAjB,CAAA,MAAqC,IAArC,IAAqC,EAAA,KAAA,KAAA,CAArC,GAAqC,EAArC,GAAyC,+BAAhD;AACD;;AAFD,OAAA,CAAA,eAAA,GAAA,eAAA","sourcesContent":["import * as React from 'react';\nimport type { RegisterPortalFn } from './types';\n\nconst PortalCompatContext = React.createContext<RegisterPortalFn | undefined>(\n undefined,\n) as React.Context<RegisterPortalFn>;\n\nconst portalCompatContextDefaultValue = () => () => undefined;\n\nexport const PortalCompatContextProvider = PortalCompatContext.Provider;\n\nexport function usePortalCompat() {\n return React.useContext(PortalCompatContext) ?? portalCompatContextDefaultValue;\n}\n"],"sourceRoot":"../src/"}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@fluentui/react-portal-compat-context",
|
3
|
-
"version": "9.0.
|
3
|
+
"version": "9.0.2",
|
4
4
|
"description": "A package that holds React context for compatibility of React Contexts",
|
5
5
|
"main": "lib-commonjs/index.js",
|
6
6
|
"module": "lib/index.js",
|
@@ -12,16 +12,14 @@
|
|
12
12
|
},
|
13
13
|
"license": "MIT",
|
14
14
|
"scripts": {
|
15
|
-
"build": "just-scripts build",
|
15
|
+
"build": "just-scripts build --module esm,cjs,amd",
|
16
16
|
"clean": "just-scripts clean",
|
17
17
|
"code-style": "just-scripts code-style",
|
18
18
|
"just": "just-scripts",
|
19
|
-
"lint": "just-scripts lint",
|
20
|
-
"start": "yarn storybook",
|
19
|
+
"lint": "just-scripts lint && just-scripts lint-imports",
|
21
20
|
"test": "jest --passWithNoTests",
|
22
21
|
"docs": "api-extractor run --config=config/api-extractor.local.json --local",
|
23
|
-
"build:local": "tsc -p ./tsconfig.lib.json --module esnext --emitDeclarationOnly && node ../../../scripts/typescript/normalize-import --output ./dist/packages/react-components/react-portal-compat-context/src && yarn docs",
|
24
|
-
"storybook": "node ../../../scripts/storybook/runner",
|
22
|
+
"build:local": "tsc -p ./tsconfig.lib.json --module esnext --emitDeclarationOnly && node ../../../scripts/typescript/normalize-import --output ./dist/types/packages/react-components/react-portal-compat-context/src && yarn docs",
|
25
23
|
"type-check": "tsc -b tsconfig.json"
|
26
24
|
},
|
27
25
|
"devDependencies": {
|
@@ -37,7 +35,8 @@
|
|
37
35
|
},
|
38
36
|
"beachball": {
|
39
37
|
"disallowedChangeTypes": [
|
40
|
-
"major"
|
38
|
+
"major",
|
39
|
+
"prerelease"
|
41
40
|
]
|
42
41
|
}
|
43
42
|
}
|
package/dist/tsdoc-metadata.json
DELETED
@@ -1,11 +0,0 @@
|
|
1
|
-
// This file is read by tools that parse documentation comments conforming to the TSDoc standard.
|
2
|
-
// It should be published with your NPM package. It should not be tracked by Git.
|
3
|
-
{
|
4
|
-
"tsdocVersion": "0.12",
|
5
|
-
"toolPackages": [
|
6
|
-
{
|
7
|
-
"packageName": "@microsoft/api-extractor",
|
8
|
-
"packageVersion": "7.18.1"
|
9
|
-
}
|
10
|
-
]
|
11
|
-
}
|