@tamagui/popper 1.12.1 → 1.13.0
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/floating.js +19 -0
- package/dist/cjs/floating.js.map +7 -0
- package/dist/cjs/floating.native.js +19 -0
- package/dist/cjs/floating.native.js.map +7 -0
- package/dist/cjs/useFloating.js +48 -0
- package/dist/cjs/useFloating.js.map +7 -0
- package/dist/esm/floating.js +2 -0
- package/dist/esm/floating.js.map +7 -0
- package/dist/esm/floating.mjs +2 -0
- package/dist/esm/floating.mjs.map +7 -0
- package/dist/esm/floating.native.js +2 -0
- package/dist/esm/floating.native.js.map +7 -0
- package/dist/esm/floating.native.mjs +2 -0
- package/dist/esm/floating.native.mjs.map +7 -0
- package/dist/esm/useFloating.js +13 -0
- package/dist/esm/useFloating.js.map +7 -0
- package/dist/esm/useFloating.mjs +13 -0
- package/dist/esm/useFloating.mjs.map +7 -0
- package/dist/jsx/floating.js +2 -0
- package/dist/jsx/floating.js.map +7 -0
- package/dist/jsx/floating.mjs +2 -0
- package/dist/jsx/floating.mjs.map +7 -0
- package/dist/jsx/floating.native.js +2 -0
- package/dist/jsx/floating.native.js.map +7 -0
- package/dist/jsx/floating.native.mjs +2 -0
- package/dist/jsx/floating.native.mjs.map +7 -0
- package/dist/jsx/useFloating.js +12 -0
- package/dist/jsx/useFloating.js.map +7 -0
- package/dist/jsx/useFloating.mjs +12 -0
- package/dist/jsx/useFloating.mjs.map +7 -0
- package/package.json +9 -9
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __copyProps = (to, from, except, desc) => {
|
|
7
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
8
|
+
for (let key of __getOwnPropNames(from))
|
|
9
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
10
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
11
|
+
}
|
|
12
|
+
return to;
|
|
13
|
+
};
|
|
14
|
+
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
15
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
16
|
+
var floating_exports = {};
|
|
17
|
+
module.exports = __toCommonJS(floating_exports);
|
|
18
|
+
__reExport(floating_exports, require("@floating-ui/react-dom"), module.exports);
|
|
19
|
+
//# sourceMappingURL=floating.js.map
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __copyProps = (to, from, except, desc) => {
|
|
7
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
8
|
+
for (let key of __getOwnPropNames(from))
|
|
9
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
10
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
11
|
+
}
|
|
12
|
+
return to;
|
|
13
|
+
};
|
|
14
|
+
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
15
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
16
|
+
var floating_native_exports = {};
|
|
17
|
+
module.exports = __toCommonJS(floating_native_exports);
|
|
18
|
+
__reExport(floating_native_exports, require("@floating-ui/react-native"), module.exports);
|
|
19
|
+
//# sourceMappingURL=floating.native.js.map
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var useFloating_exports = {};
|
|
30
|
+
__export(useFloating_exports, {
|
|
31
|
+
FloatingOverrideContext: () => FloatingOverrideContext,
|
|
32
|
+
useFloating: () => useFloating
|
|
33
|
+
});
|
|
34
|
+
module.exports = __toCommonJS(useFloating_exports);
|
|
35
|
+
var import_react = require("react");
|
|
36
|
+
var Floating = __toESM(require("./floating"));
|
|
37
|
+
const FloatingOverrideContext = (0, import_react.createContext)(null);
|
|
38
|
+
const useFloating = (props) => {
|
|
39
|
+
var _a;
|
|
40
|
+
const context = (0, import_react.useContext)(FloatingOverrideContext);
|
|
41
|
+
return (_a = context || Floating.useFloating) == null ? void 0 : _a(props);
|
|
42
|
+
};
|
|
43
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
44
|
+
0 && (module.exports = {
|
|
45
|
+
FloatingOverrideContext,
|
|
46
|
+
useFloating
|
|
47
|
+
});
|
|
48
|
+
//# sourceMappingURL=useFloating.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/useFloating.tsx"],
|
|
4
|
+
"sourcesContent": ["import { createContext, useContext } from 'react'\n\nimport * as Floating from './floating'\n\nexport type UseFloatingFn = typeof Floating.useFloating\n\ntype UseFloatingProps = UseFloatingFn extends (props: infer Props) => any\n ? Props\n : never\n\nexport type UseFloatingReturn = Floating.UseFloatingReturn & {\n context?: any\n getFloatingProps?: (props: { ref: any; [key: string]: any }) => any\n getReferenceProps?: (props: { ref: any; [key: string]: any }) => any\n}\n\nexport const FloatingOverrideContext = createContext<UseFloatingFn | null>(null)\n\nexport const useFloating = (props: UseFloatingProps): UseFloatingReturn => {\n const context = useContext(FloatingOverrideContext)\n return (context || Floating.useFloating)?.(props)\n}\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBAA0C;AAE1C,eAA0B;AAcnB,MAAM,8BAA0B,4BAAoC,IAAI;AAExE,MAAM,cAAc,CAAC,UAA+C;AAlB3E;AAmBE,QAAM,cAAU,yBAAW,uBAAuB;AAClD,UAAQ,gBAAW,SAAS,gBAApB,mBAAmC;AAC7C;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { createContext, useContext } from "react";
|
|
2
|
+
import * as Floating from "./floating";
|
|
3
|
+
const FloatingOverrideContext = createContext(null);
|
|
4
|
+
const useFloating = (props) => {
|
|
5
|
+
var _a;
|
|
6
|
+
const context = useContext(FloatingOverrideContext);
|
|
7
|
+
return (_a = context || Floating.useFloating) == null ? void 0 : _a(props);
|
|
8
|
+
};
|
|
9
|
+
export {
|
|
10
|
+
FloatingOverrideContext,
|
|
11
|
+
useFloating
|
|
12
|
+
};
|
|
13
|
+
//# sourceMappingURL=useFloating.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/useFloating.tsx"],
|
|
4
|
+
"sourcesContent": ["import { createContext, useContext } from 'react'\n\nimport * as Floating from './floating'\n\nexport type UseFloatingFn = typeof Floating.useFloating\n\ntype UseFloatingProps = UseFloatingFn extends (props: infer Props) => any\n ? Props\n : never\n\nexport type UseFloatingReturn = Floating.UseFloatingReturn & {\n context?: any\n getFloatingProps?: (props: { ref: any; [key: string]: any }) => any\n getReferenceProps?: (props: { ref: any; [key: string]: any }) => any\n}\n\nexport const FloatingOverrideContext = createContext<UseFloatingFn | null>(null)\n\nexport const useFloating = (props: UseFloatingProps): UseFloatingReturn => {\n const context = useContext(FloatingOverrideContext)\n return (context || Floating.useFloating)?.(props)\n}\n"],
|
|
5
|
+
"mappings": "AAAA,SAAS,eAAe,kBAAkB;AAE1C,YAAY,cAAc;AAcnB,MAAM,0BAA0B,cAAoC,IAAI;AAExE,MAAM,cAAc,CAAC,UAA+C;AAlB3E;AAmBE,QAAM,UAAU,WAAW,uBAAuB;AAClD,UAAQ,gBAAW,SAAS,gBAApB,mBAAmC;AAC7C;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { createContext, useContext } from "react";
|
|
2
|
+
import * as Floating from "./floating";
|
|
3
|
+
const FloatingOverrideContext = createContext(null);
|
|
4
|
+
const useFloating = (props) => {
|
|
5
|
+
var _a;
|
|
6
|
+
const context = useContext(FloatingOverrideContext);
|
|
7
|
+
return (_a = context || Floating.useFloating) == null ? void 0 : _a(props);
|
|
8
|
+
};
|
|
9
|
+
export {
|
|
10
|
+
FloatingOverrideContext,
|
|
11
|
+
useFloating
|
|
12
|
+
};
|
|
13
|
+
//# sourceMappingURL=useFloating.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/useFloating.tsx"],
|
|
4
|
+
"sourcesContent": ["import { createContext, useContext } from 'react'\n\nimport * as Floating from './floating'\n\nexport type UseFloatingFn = typeof Floating.useFloating\n\ntype UseFloatingProps = UseFloatingFn extends (props: infer Props) => any\n ? Props\n : never\n\nexport type UseFloatingReturn = Floating.UseFloatingReturn & {\n context?: any\n getFloatingProps?: (props: { ref: any; [key: string]: any }) => any\n getReferenceProps?: (props: { ref: any; [key: string]: any }) => any\n}\n\nexport const FloatingOverrideContext = createContext<UseFloatingFn | null>(null)\n\nexport const useFloating = (props: UseFloatingProps): UseFloatingReturn => {\n const context = useContext(FloatingOverrideContext)\n return (context || Floating.useFloating)?.(props)\n}\n"],
|
|
5
|
+
"mappings": "AAAA,SAAS,eAAe,kBAAkB;AAE1C,YAAY,cAAc;AAcnB,MAAM,0BAA0B,cAAoC,IAAI;AAExE,MAAM,cAAc,CAAC,UAA+C;AAlB3E;AAmBE,QAAM,UAAU,WAAW,uBAAuB;AAClD,UAAQ,gBAAW,SAAS,gBAApB,mBAAmC;AAC7C;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { createContext, useContext } from "react";
|
|
2
|
+
import * as Floating from "./floating";
|
|
3
|
+
const FloatingOverrideContext = createContext(null);
|
|
4
|
+
const useFloating = (props) => {
|
|
5
|
+
const context = useContext(FloatingOverrideContext);
|
|
6
|
+
return (context || Floating.useFloating)?.(props);
|
|
7
|
+
};
|
|
8
|
+
export {
|
|
9
|
+
FloatingOverrideContext,
|
|
10
|
+
useFloating
|
|
11
|
+
};
|
|
12
|
+
//# sourceMappingURL=useFloating.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/useFloating.tsx"],
|
|
4
|
+
"sourcesContent": ["import { createContext, useContext } from 'react'\n\nimport * as Floating from './floating'\n\nexport type UseFloatingFn = typeof Floating.useFloating\n\ntype UseFloatingProps = UseFloatingFn extends (props: infer Props) => any\n ? Props\n : never\n\nexport type UseFloatingReturn = Floating.UseFloatingReturn & {\n context?: any\n getFloatingProps?: (props: { ref: any; [key: string]: any }) => any\n getReferenceProps?: (props: { ref: any; [key: string]: any }) => any\n}\n\nexport const FloatingOverrideContext = createContext<UseFloatingFn | null>(null)\n\nexport const useFloating = (props: UseFloatingProps): UseFloatingReturn => {\n const context = useContext(FloatingOverrideContext)\n return (context || Floating.useFloating)?.(props)\n}\n"],
|
|
5
|
+
"mappings": "AAAA,SAAS,eAAe,kBAAkB;AAE1C,YAAY,cAAc;AAcnB,MAAM,0BAA0B,cAAoC,IAAI;AAExE,MAAM,cAAc,CAAC,UAA+C;AACzE,QAAM,UAAU,WAAW,uBAAuB;AAClD,UAAQ,WAAW,SAAS,eAAe,KAAK;AAClD;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { createContext, useContext } from "react";
|
|
2
|
+
import * as Floating from "./floating";
|
|
3
|
+
const FloatingOverrideContext = createContext(null);
|
|
4
|
+
const useFloating = (props) => {
|
|
5
|
+
const context = useContext(FloatingOverrideContext);
|
|
6
|
+
return (context || Floating.useFloating)?.(props);
|
|
7
|
+
};
|
|
8
|
+
export {
|
|
9
|
+
FloatingOverrideContext,
|
|
10
|
+
useFloating
|
|
11
|
+
};
|
|
12
|
+
//# sourceMappingURL=useFloating.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/useFloating.tsx"],
|
|
4
|
+
"sourcesContent": ["import { createContext, useContext } from 'react'\n\nimport * as Floating from './floating'\n\nexport type UseFloatingFn = typeof Floating.useFloating\n\ntype UseFloatingProps = UseFloatingFn extends (props: infer Props) => any\n ? Props\n : never\n\nexport type UseFloatingReturn = Floating.UseFloatingReturn & {\n context?: any\n getFloatingProps?: (props: { ref: any; [key: string]: any }) => any\n getReferenceProps?: (props: { ref: any; [key: string]: any }) => any\n}\n\nexport const FloatingOverrideContext = createContext<UseFloatingFn | null>(null)\n\nexport const useFloating = (props: UseFloatingProps): UseFloatingReturn => {\n const context = useContext(FloatingOverrideContext)\n return (context || Floating.useFloating)?.(props)\n}\n"],
|
|
5
|
+
"mappings": "AAAA,SAAS,eAAe,kBAAkB;AAE1C,YAAY,cAAc;AAcnB,MAAM,0BAA0B,cAAoC,IAAI;AAExE,MAAM,cAAc,CAAC,UAA+C;AACzE,QAAM,UAAU,WAAW,uBAAuB;AAClD,UAAQ,WAAW,SAAS,eAAe,KAAK;AAClD;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tamagui/popper",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.13.0",
|
|
4
4
|
"sideEffects": [
|
|
5
5
|
"*.css"
|
|
6
6
|
],
|
|
@@ -33,13 +33,13 @@
|
|
|
33
33
|
"dependencies": {
|
|
34
34
|
"@floating-ui/react-dom": "^1.2.2",
|
|
35
35
|
"@floating-ui/react-native": "^0.9.0",
|
|
36
|
-
"@tamagui/compose-refs": "1.
|
|
37
|
-
"@tamagui/core": "1.
|
|
38
|
-
"@tamagui/create-context": "1.
|
|
39
|
-
"@tamagui/floating": "1.
|
|
40
|
-
"@tamagui/get-size": "1.
|
|
41
|
-
"@tamagui/stacks": "1.
|
|
42
|
-
"@tamagui/use-controllable-state": "1.
|
|
36
|
+
"@tamagui/compose-refs": "1.13.0",
|
|
37
|
+
"@tamagui/core": "1.13.0",
|
|
38
|
+
"@tamagui/create-context": "1.13.0",
|
|
39
|
+
"@tamagui/floating": "1.13.0",
|
|
40
|
+
"@tamagui/get-size": "1.13.0",
|
|
41
|
+
"@tamagui/stacks": "1.13.0",
|
|
42
|
+
"@tamagui/use-controllable-state": "1.13.0"
|
|
43
43
|
},
|
|
44
44
|
"peerDependencies": {
|
|
45
45
|
"react": "*",
|
|
@@ -47,7 +47,7 @@
|
|
|
47
47
|
"react-native": "*"
|
|
48
48
|
},
|
|
49
49
|
"devDependencies": {
|
|
50
|
-
"@tamagui/build": "1.
|
|
50
|
+
"@tamagui/build": "1.13.0",
|
|
51
51
|
"react": "^18.2.0",
|
|
52
52
|
"react-dom": "^18.2.0",
|
|
53
53
|
"react-native": "^0.71.4"
|