@tamagui/create-context 2.0.0-rc.3 → 2.0.0-rc.30

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/dist/cjs/index.js CHANGED
@@ -3,13 +3,16 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
3
  var __getOwnPropNames = Object.getOwnPropertyNames;
4
4
  var __hasOwnProp = Object.prototype.hasOwnProperty;
5
5
  var __copyProps = (to, from, except, desc) => {
6
- if (from && typeof from == "object" || typeof from == "function")
7
- for (let key of __getOwnPropNames(from))
8
- !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
9
- return to;
10
- }, __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
11
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
6
+ if (from && typeof from == "object" || typeof from == "function") for (let key of __getOwnPropNames(from)) !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, {
7
+ get: () => from[key],
8
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
9
+ });
10
+ return to;
11
+ },
12
+ __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
13
+ var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
14
+ value: !0
15
+ }), mod);
12
16
  var index_exports = {};
13
17
  module.exports = __toCommonJS(index_exports);
14
- __reExport(index_exports, require("./create-context"), module.exports);
15
- //# sourceMappingURL=index.js.map
18
+ __reExport(index_exports, require("./create-context.cjs"), module.exports);
package/dist/esm/index.js CHANGED
@@ -1,2 +1,2 @@
1
- export * from "./create-context";
1
+ export * from "./create-context.mjs";
2
2
  //# sourceMappingURL=index.js.map
@@ -1,6 +1 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../src/index.ts"],
4
- "mappings": "AAAA,cAAc;",
5
- "names": []
6
- }
1
+ {"version":3,"names":[],"sources":["../../src/index.ts"],"sourcesContent":[null],"mappings":"AAAA,cAAc","ignoreList":[]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tamagui/create-context",
3
- "version": "2.0.0-rc.3",
3
+ "version": "2.0.0-rc.30",
4
4
  "gitHead": "a49cc7ea6b93ba384e77a4880ae48ac4a5635c14",
5
5
  "source": "src/index.ts",
6
6
  "files": [
@@ -17,15 +17,12 @@
17
17
  "./package.json": "./package.json",
18
18
  ".": {
19
19
  "types": "./types/index.d.ts",
20
- "react-native": {
21
- "module": "./dist/esm/index.native.js",
22
- "import": "./dist/esm/index.native.js",
23
- "require": "./dist/cjs/index.native.js"
24
- },
20
+ "react-native": "./dist/esm/index.native.js",
21
+ "browser": "./dist/esm/index.mjs",
25
22
  "module": "./dist/esm/index.mjs",
26
23
  "import": "./dist/esm/index.mjs",
27
24
  "require": "./dist/cjs/index.cjs",
28
- "default": "./dist/cjs/index.native.js"
25
+ "default": "./dist/esm/index.mjs"
29
26
  }
30
27
  },
31
28
  "publishConfig": {
@@ -38,7 +35,7 @@
38
35
  "clean:build": "tamagui-build clean:build"
39
36
  },
40
37
  "devDependencies": {
41
- "@tamagui/build": "2.0.0-rc.3",
38
+ "@tamagui/build": "2.0.0-rc.30",
42
39
  "react": ">=19"
43
40
  },
44
41
  "peerDependencies": {
@@ -4,8 +4,8 @@
4
4
  "sources": [
5
5
  "src/create-context.tsx"
6
6
  ],
7
+ "version": 3,
7
8
  "sourcesContent": [
8
9
  "// from radix\n// https://github.com/radix-ui/primitives/blob/main/packages/react/context/src/createContext.tsx\n\nimport * as React from 'react'\n\nexport type ScopedProps<P, K extends string> = P & { [Key in `__scope${K}`]?: Scope }\n\nexport function createContext<ContextValueType extends object | null>(\n rootComponentName: string,\n defaultContext?: ContextValueType\n): readonly [\n (props: ContextValueType & { children: React.ReactNode }) => React.JSX.Element,\n (consumerName: string) => Exclude<ContextValueType | undefined, undefined>,\n] {\n const Context = React.createContext<ContextValueType | undefined>(defaultContext)\n\n function Provider(props: ContextValueType & { children: React.ReactNode }) {\n const { children, ...context } = props\n // Only re-memoize when prop values change\n\n const value = React.useMemo(() => context, Object.values(context)) as ContextValueType\n return <Context.Provider value={value}>{children}</Context.Provider>\n }\n\n function useContext(consumerName: string): Exclude<typeof context, undefined> {\n const context = React.useContext(Context)\n if (context) return context as any\n if (defaultContext !== undefined) return defaultContext as any\n // if a defaultContext wasn't specified, it's a required context.\n throw new Error(`\\`${consumerName}\\` must be used within \\`${rootComponentName}\\``)\n }\n\n return [Provider, useContext] as const\n}\n\n/* -------------------------------------------------------------------------------------------------\n * createContextScope\n * -----------------------------------------------------------------------------------------------*/\n\ntype ScopeHook = (scope: Scope) => { [__scopeProp: string]: Scope }\n\nexport type Scope<C = any> = { [scopeName: string]: React.Context<C>[] } | undefined\n\nexport interface CreateScope {\n scopeName: string\n (): ScopeHook\n}\n\nexport function createContextScope(\n scopeName: string,\n createContextScopeDeps: CreateScope[] = []\n): readonly [\n <ContextValueType extends object | null>(\n rootComponentName: string,\n defaultContext?: ContextValueType\n ) => readonly [\n (\n props: ContextValueType & {\n scope: Scope<ContextValueType>\n children: React.ReactNode\n }\n ) => import('react/jsx-runtime').JSX.Element,\n (\n consumerName: string,\n scope: Scope<ContextValueType | undefined>,\n options?: {\n warn?: boolean\n fallback?: Partial<ContextValueType>\n }\n ) => ContextValueType,\n ],\n CreateScope,\n] {\n let defaultContexts: any[] = []\n\n /* -----------------------------------------------------------------------------------------------\n * createContext\n * ---------------------------------------------------------------------------------------------*/\n\n function createContext<ContextValueType extends object | null>(\n rootComponentName: string,\n defaultContext?: ContextValueType\n ) {\n const BaseContext = React.createContext<ContextValueType | undefined>(defaultContext)\n const index = defaultContexts.length\n defaultContexts = [...defaultContexts, defaultContext]\n\n function Provider(\n props: ContextValueType & {\n scope: Scope<ContextValueType>\n children: React.ReactNode\n }\n ) {\n const { scope, children, ...context } = props\n const Context = scope?.[scopeName]?.[index] || BaseContext\n // Only re-memoize when prop values change\n\n const value = React.useMemo(\n () => context,\n Object.values(context)\n ) as ContextValueType\n return <Context.Provider value={value}>{children}</Context.Provider>\n }\n\n function useContext(\n consumerName: string,\n scope: Scope<ContextValueType | undefined>,\n options?: {\n warn?: boolean\n fallback?: Partial<ContextValueType>\n }\n ) {\n const Context = scope?.[scopeName]?.[index] || BaseContext\n const context = React.useContext(Context)\n if (context) return context\n // if a defaultContext wasn't specified, it's a required context.\n if (defaultContext !== undefined) return defaultContext\n const missingContextMessage = `\\`${consumerName}\\` must be used within \\`${rootComponentName}\\``\n // fallback can be given per-hook as well\n if (options?.fallback) {\n if (options?.warn !== false) {\n console.warn(missingContextMessage)\n }\n return options.fallback as ContextValueType\n }\n throw new Error(missingContextMessage)\n }\n\n return [Provider, useContext] as const\n }\n\n /* -----------------------------------------------------------------------------------------------\n * createScope\n * ---------------------------------------------------------------------------------------------*/\n\n const createScope: CreateScope = () => {\n const scopeContexts = defaultContexts.map((defaultContext) => {\n return React.createContext(defaultContext)\n })\n return function useScope(scope: Scope) {\n const contexts = scope?.[scopeName] || scopeContexts\n return React.useMemo(\n () => ({ [`__scope${scopeName}`]: { ...scope, [scopeName]: contexts } }),\n [scope, contexts]\n )\n }\n }\n\n createScope.scopeName = scopeName\n\n return [\n createContext,\n composeContextScopes(createScope, ...createContextScopeDeps),\n ] as const\n}\n\n/* -------------------------------------------------------------------------------------------------\n * composeContextScopes\n * -----------------------------------------------------------------------------------------------*/\n\nfunction composeContextScopes(...scopes: CreateScope[]) {\n const baseScope = scopes[0]\n if (scopes.length === 1) return baseScope\n\n const createScope: CreateScope = () => {\n const scopeHooks = scopes.map((createScope) => ({\n useScope: createScope(),\n scopeName: createScope.scopeName,\n }))\n\n return function useComposedScopes(overrideScopes) {\n const nextScopes = scopeHooks.reduce((nextScopes, { useScope, scopeName }) => {\n // We are calling a hook inside a callback which React warns against to avoid inconsistent\n // renders, however, scoping doesn't have render side effects so we ignore the rule.\n\n const scopeProps = useScope(overrideScopes)\n const currentScope = scopeProps[`__scope${scopeName}`]\n return { ...nextScopes, ...currentScope }\n }, {})\n\n return React.useMemo(\n () => ({ [`__scope${baseScope.scopeName}`]: nextScopes }),\n [nextScopes]\n )\n }\n }\n\n createScope.scopeName = baseScope.scopeName\n return createScope\n}\n\n/* -----------------------------------------------------------------------------------------------*/\n"
9
- ],
10
- "version": 3
10
+ ]
11
11
  }
@@ -4,8 +4,8 @@
4
4
  "sources": [
5
5
  "src/index.ts"
6
6
  ],
7
+ "version": 3,
7
8
  "sourcesContent": [
8
9
  "export * from './create-context'\n"
9
- ],
10
- "version": 3
10
+ ]
11
11
  }
@@ -1,103 +0,0 @@
1
- var __create = Object.create;
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __getProtoOf = Object.getPrototypeOf, __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __export = (target, all) => {
7
- for (var name in all)
8
- __defProp(target, name, { get: all[name], enumerable: !0 });
9
- }, __copyProps = (to, from, except, desc) => {
10
- if (from && typeof from == "object" || typeof from == "function")
11
- for (let key of __getOwnPropNames(from))
12
- !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
13
- return to;
14
- };
15
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
16
- // If the importer is in node compatibility mode or this is not an ESM
17
- // file that has been converted to a CommonJS file using a Babel-
18
- // compatible transform (i.e. "__esModule" has not been set), then set
19
- // "default" to the CommonJS "module.exports" for node compatibility.
20
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: !0 }) : target,
21
- mod
22
- )), __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
23
- var create_context_exports = {};
24
- __export(create_context_exports, {
25
- createContext: () => createContext,
26
- createContextScope: () => createContextScope
27
- });
28
- module.exports = __toCommonJS(create_context_exports);
29
- var React = __toESM(require("react"), 1), import_jsx_runtime = require("react/jsx-runtime");
30
- function createContext(rootComponentName, defaultContext) {
31
- const Context = React.createContext(defaultContext);
32
- function Provider(props) {
33
- const { children, ...context } = props, value = React.useMemo(() => context, Object.values(context));
34
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Context.Provider, { value, children });
35
- }
36
- function useContext(consumerName) {
37
- const context = React.useContext(Context);
38
- if (context) return context;
39
- if (defaultContext !== void 0) return defaultContext;
40
- throw new Error(`\`${consumerName}\` must be used within \`${rootComponentName}\``);
41
- }
42
- return [Provider, useContext];
43
- }
44
- function createContextScope(scopeName, createContextScopeDeps = []) {
45
- let defaultContexts = [];
46
- function createContext2(rootComponentName, defaultContext) {
47
- const BaseContext = React.createContext(defaultContext), index = defaultContexts.length;
48
- defaultContexts = [...defaultContexts, defaultContext];
49
- function Provider(props) {
50
- const { scope, children, ...context } = props, Context = scope?.[scopeName]?.[index] || BaseContext, value = React.useMemo(
51
- () => context,
52
- Object.values(context)
53
- );
54
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Context.Provider, { value, children });
55
- }
56
- function useContext(consumerName, scope, options) {
57
- const Context = scope?.[scopeName]?.[index] || BaseContext, context = React.useContext(Context);
58
- if (context) return context;
59
- if (defaultContext !== void 0) return defaultContext;
60
- const missingContextMessage = `\`${consumerName}\` must be used within \`${rootComponentName}\``;
61
- if (options?.fallback)
62
- return options?.warn !== !1 && console.warn(missingContextMessage), options.fallback;
63
- throw new Error(missingContextMessage);
64
- }
65
- return [Provider, useContext];
66
- }
67
- const createScope = () => {
68
- const scopeContexts = defaultContexts.map((defaultContext) => React.createContext(defaultContext));
69
- return function(scope) {
70
- const contexts = scope?.[scopeName] || scopeContexts;
71
- return React.useMemo(
72
- () => ({ [`__scope${scopeName}`]: { ...scope, [scopeName]: contexts } }),
73
- [scope, contexts]
74
- );
75
- };
76
- };
77
- return createScope.scopeName = scopeName, [
78
- createContext2,
79
- composeContextScopes(createScope, ...createContextScopeDeps)
80
- ];
81
- }
82
- function composeContextScopes(...scopes) {
83
- const baseScope = scopes[0];
84
- if (scopes.length === 1) return baseScope;
85
- const createScope = () => {
86
- const scopeHooks = scopes.map((createScope2) => ({
87
- useScope: createScope2(),
88
- scopeName: createScope2.scopeName
89
- }));
90
- return function(overrideScopes) {
91
- const nextScopes = scopeHooks.reduce((nextScopes2, { useScope, scopeName }) => {
92
- const currentScope = useScope(overrideScopes)[`__scope${scopeName}`];
93
- return { ...nextScopes2, ...currentScope };
94
- }, {});
95
- return React.useMemo(
96
- () => ({ [`__scope${baseScope.scopeName}`]: nextScopes }),
97
- [nextScopes]
98
- );
99
- };
100
- };
101
- return createScope.scopeName = baseScope.scopeName, createScope;
102
- }
103
- //# sourceMappingURL=create-context.js.map
@@ -1,6 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../src/create-context.tsx"],
4
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAGA,YAAuB,8BAkBZ;AAdJ,SAAS,cACd,mBACA,gBAIA;AACA,QAAM,UAAU,MAAM,cAA4C,cAAc;AAEhF,WAAS,SAAS,OAAyD;AACzE,UAAM,EAAE,UAAU,GAAG,QAAQ,IAAI,OAG3B,QAAQ,MAAM,QAAQ,MAAM,SAAS,OAAO,OAAO,OAAO,CAAC;AACjE,WAAO,4CAAC,QAAQ,UAAR,EAAiB,OAAe,UAAS;AAAA,EACnD;AAEA,WAAS,WAAW,cAA0D;AAC5E,UAAM,UAAU,MAAM,WAAW,OAAO;AACxC,QAAI,QAAS,QAAO;AACpB,QAAI,mBAAmB,OAAW,QAAO;AAEzC,UAAM,IAAI,MAAM,KAAK,YAAY,4BAA4B,iBAAiB,IAAI;AAAA,EACpF;AAEA,SAAO,CAAC,UAAU,UAAU;AA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ACLA;AAAA,IACA,qBAAqB,aAAa,GAAG,sBAAsB;AAAA,EAC7D;AACF;AAMA,SAAS,wBAAwB,QAAuB;AACtD,QAAM,YAAY,OAAO,CAAC;AAC1B,MAAI,OAAO,WAAW,EAAG,QAAO;AAEhC,QAAM,cAA2B,MAAM;AACrC,UAAM,aAAa,OAAO,IAAI,CAACC,kBAAiB;AAAA,MAC9C,UAAUA,aAAY;AAAA,MACtB,WAAWA,aAAY;AAAA,IACzB,EAAE;AAEF,WAAO,SAA2B,gBAAgB;AAChD,YAAM,aAAa,WAAW,OAAO,CAACC,aAAY,EAAE,UAAU,UAAU,MAAM;AAK5E,cAAM,eADa,SAAS,cAAc,EACV,UAAU,SAAS,EAAE;AACrD,eAAO,EAAE,GAAGA,aAAY,GAAG,aAAa;AAAA,MAC1C,GAAG,CAAC,CAAC;AAEL,aAAO,MAAM;AAAA,QACX,OAAO,EAAE,CAAC,UAAU,UAAU,SAAS,EAAE,GAAG,WAAW;AAAA,QACvD,CAAC,UAAU;AAAA,MACb;AAAA,IACF;AAAA,EACF;AAEA,qBAAY,YAAY,UAAU,WAC3B;AACT;",
5
- "names": ["createContext", "createScope", "nextScopes"]
6
- }
@@ -1,80 +0,0 @@
1
- import * as React from "react";
2
- import { jsx } from "react/jsx-runtime";
3
- function createContext(rootComponentName, defaultContext) {
4
- const Context = React.createContext(defaultContext);
5
- function Provider(props) {
6
- const { children, ...context } = props, value = React.useMemo(() => context, Object.values(context));
7
- return /* @__PURE__ */ jsx(Context.Provider, { value, children });
8
- }
9
- function useContext(consumerName) {
10
- const context = React.useContext(Context);
11
- if (context) return context;
12
- if (defaultContext !== void 0) return defaultContext;
13
- throw new Error(`\`${consumerName}\` must be used within \`${rootComponentName}\``);
14
- }
15
- return [Provider, useContext];
16
- }
17
- function createContextScope(scopeName, createContextScopeDeps = []) {
18
- let defaultContexts = [];
19
- function createContext2(rootComponentName, defaultContext) {
20
- const BaseContext = React.createContext(defaultContext), index = defaultContexts.length;
21
- defaultContexts = [...defaultContexts, defaultContext];
22
- function Provider(props) {
23
- const { scope, children, ...context } = props, Context = scope?.[scopeName]?.[index] || BaseContext, value = React.useMemo(
24
- () => context,
25
- Object.values(context)
26
- );
27
- return /* @__PURE__ */ jsx(Context.Provider, { value, children });
28
- }
29
- function useContext(consumerName, scope, options) {
30
- const Context = scope?.[scopeName]?.[index] || BaseContext, context = React.useContext(Context);
31
- if (context) return context;
32
- if (defaultContext !== void 0) return defaultContext;
33
- const missingContextMessage = `\`${consumerName}\` must be used within \`${rootComponentName}\``;
34
- if (options?.fallback)
35
- return options?.warn !== !1 && console.warn(missingContextMessage), options.fallback;
36
- throw new Error(missingContextMessage);
37
- }
38
- return [Provider, useContext];
39
- }
40
- const createScope = () => {
41
- const scopeContexts = defaultContexts.map((defaultContext) => React.createContext(defaultContext));
42
- return function(scope) {
43
- const contexts = scope?.[scopeName] || scopeContexts;
44
- return React.useMemo(
45
- () => ({ [`__scope${scopeName}`]: { ...scope, [scopeName]: contexts } }),
46
- [scope, contexts]
47
- );
48
- };
49
- };
50
- return createScope.scopeName = scopeName, [
51
- createContext2,
52
- composeContextScopes(createScope, ...createContextScopeDeps)
53
- ];
54
- }
55
- function composeContextScopes(...scopes) {
56
- const baseScope = scopes[0];
57
- if (scopes.length === 1) return baseScope;
58
- const createScope = () => {
59
- const scopeHooks = scopes.map((createScope2) => ({
60
- useScope: createScope2(),
61
- scopeName: createScope2.scopeName
62
- }));
63
- return function(overrideScopes) {
64
- const nextScopes = scopeHooks.reduce((nextScopes2, { useScope, scopeName }) => {
65
- const currentScope = useScope(overrideScopes)[`__scope${scopeName}`];
66
- return { ...nextScopes2, ...currentScope };
67
- }, {});
68
- return React.useMemo(
69
- () => ({ [`__scope${baseScope.scopeName}`]: nextScopes }),
70
- [nextScopes]
71
- );
72
- };
73
- };
74
- return createScope.scopeName = baseScope.scopeName, createScope;
75
- }
76
- export {
77
- createContext,
78
- createContextScope
79
- };
80
- //# sourceMappingURL=create-context.js.map
@@ -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