@bifrostui/react 1.4.2-beta.0 → 1.4.2-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -70,6 +70,7 @@ const Popover = /* @__PURE__ */ import_react.default.forwardRef((props, ref) =>
70
70
  title,
71
71
  content,
72
72
  defaultOpen,
73
+ offsetSpacing = 0,
73
74
  placement = "top",
74
75
  trigger = "click",
75
76
  onOpenChange,
@@ -82,6 +83,7 @@ const Popover = /* @__PURE__ */ import_react.default.forwardRef((props, ref) =>
82
83
  "title",
83
84
  "content",
84
85
  "defaultOpen",
86
+ "offsetSpacing",
85
87
  "placement",
86
88
  "trigger",
87
89
  "onOpenChange",
@@ -136,6 +138,7 @@ const Popover = /* @__PURE__ */ import_react.default.forwardRef((props, ref) =>
136
138
  childrenRef,
137
139
  arrowDirection,
138
140
  arrowLocation,
141
+ offsetSpacing,
139
142
  selector: `[data-id="tt_${ttId}"]`
140
143
  });
141
144
  if (!result)
@@ -25,6 +25,10 @@ export type PopoverProps<D extends React.ElementType = 'div', P = {}> = Override
25
25
  * @default false
26
26
  */
27
27
  hideArrow?: boolean;
28
+ /**
29
+ * 用于控制浮层和目标元素偏移量
30
+ */
31
+ offsetSpacing?: number;
28
32
  /**
29
33
  * 气泡框位置
30
34
  * @default 'top'
@@ -69,6 +69,7 @@ const Tooltip = /* @__PURE__ */ import_react.default.forwardRef((props, ref) =>
69
69
  children,
70
70
  title,
71
71
  defaultOpen,
72
+ offsetSpacing = 0,
72
73
  placement = "top",
73
74
  trigger = "click",
74
75
  onOpenChange,
@@ -79,6 +80,7 @@ const Tooltip = /* @__PURE__ */ import_react.default.forwardRef((props, ref) =>
79
80
  "children",
80
81
  "title",
81
82
  "defaultOpen",
83
+ "offsetSpacing",
82
84
  "placement",
83
85
  "trigger",
84
86
  "onOpenChange",
@@ -132,6 +134,7 @@ const Tooltip = /* @__PURE__ */ import_react.default.forwardRef((props, ref) =>
132
134
  childrenRef,
133
135
  arrowDirection,
134
136
  arrowLocation,
137
+ offsetSpacing,
135
138
  selector: `[data-id="tt_${ttId}"]`
136
139
  });
137
140
  if (!result)
@@ -16,6 +16,10 @@ export type TooltipProps<D extends React.ElementType = 'div', P = {}> = Override
16
16
  * 用于手动控制气泡浮层显隐
17
17
  */
18
18
  open?: boolean;
19
+ /**
20
+ * 用于控制气泡浮层和目标元素偏移量
21
+ */
22
+ offsetSpacing?: number;
19
23
  /**
20
24
  * 气泡框位置
21
25
  * @default 'top'
@@ -12,5 +12,5 @@ declare const Modal: React.ForwardRefExoticComponent<Omit<ViewProps & {
12
12
  keepMounted?: boolean;
13
13
  } & import("@bifrostui/types").ICommonProps & Omit<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
14
14
  ref?: React.Ref<HTMLDivElement>;
15
- }, "open" | keyof import("@bifrostui/types").ICommonProps | "container" | "disablePortal" | "hideBackdrop" | "BackdropProps" | "onClose" | "disableScrollLock" | "keepMounted">, "ref"> & React.RefAttributes<HTMLDivElement>>;
15
+ }, keyof import("@bifrostui/types").ICommonProps | "open" | "container" | "disablePortal" | "hideBackdrop" | "BackdropProps" | "onClose" | "disableScrollLock" | "keepMounted">, "ref"> & React.RefAttributes<HTMLDivElement>>;
16
16
  export default Modal;
@@ -45,6 +45,7 @@ const Popover = /* @__PURE__ */ React.forwardRef((props, ref) => {
45
45
  title,
46
46
  content,
47
47
  defaultOpen,
48
+ offsetSpacing = 0,
48
49
  placement = "top",
49
50
  trigger = "click",
50
51
  onOpenChange,
@@ -57,6 +58,7 @@ const Popover = /* @__PURE__ */ React.forwardRef((props, ref) => {
57
58
  "title",
58
59
  "content",
59
60
  "defaultOpen",
61
+ "offsetSpacing",
60
62
  "placement",
61
63
  "trigger",
62
64
  "onOpenChange",
@@ -111,6 +113,7 @@ const Popover = /* @__PURE__ */ React.forwardRef((props, ref) => {
111
113
  childrenRef,
112
114
  arrowDirection,
113
115
  arrowLocation,
116
+ offsetSpacing,
114
117
  selector: `[data-id="tt_${ttId}"]`
115
118
  });
116
119
  if (!result)
@@ -25,6 +25,10 @@ export type PopoverProps<D extends React.ElementType = 'div', P = {}> = Override
25
25
  * @default false
26
26
  */
27
27
  hideArrow?: boolean;
28
+ /**
29
+ * 用于控制浮层和目标元素偏移量
30
+ */
31
+ offsetSpacing?: number;
28
32
  /**
29
33
  * 气泡框位置
30
34
  * @default 'top'
@@ -44,6 +44,7 @@ const Tooltip = /* @__PURE__ */ React.forwardRef((props, ref) => {
44
44
  children,
45
45
  title,
46
46
  defaultOpen,
47
+ offsetSpacing = 0,
47
48
  placement = "top",
48
49
  trigger = "click",
49
50
  onOpenChange,
@@ -54,6 +55,7 @@ const Tooltip = /* @__PURE__ */ React.forwardRef((props, ref) => {
54
55
  "children",
55
56
  "title",
56
57
  "defaultOpen",
58
+ "offsetSpacing",
57
59
  "placement",
58
60
  "trigger",
59
61
  "onOpenChange",
@@ -107,6 +109,7 @@ const Tooltip = /* @__PURE__ */ React.forwardRef((props, ref) => {
107
109
  childrenRef,
108
110
  arrowDirection,
109
111
  arrowLocation,
112
+ offsetSpacing,
110
113
  selector: `[data-id="tt_${ttId}"]`
111
114
  });
112
115
  if (!result)
@@ -16,6 +16,10 @@ export type TooltipProps<D extends React.ElementType = 'div', P = {}> = Override
16
16
  * 用于手动控制气泡浮层显隐
17
17
  */
18
18
  open?: boolean;
19
+ /**
20
+ * 用于控制气泡浮层和目标元素偏移量
21
+ */
22
+ offsetSpacing?: number;
19
23
  /**
20
24
  * 气泡框位置
21
25
  * @default 'top'
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bifrostui/react",
3
- "version": "1.4.2-beta.0",
3
+ "version": "1.4.2-beta.1",
4
4
  "description": "React components for building mobile application",
5
5
  "homepage": "http://bui.taopiaopiao.com",
6
6
  "license": "MIT",
@@ -33,10 +33,10 @@
33
33
  "clsx": "^1.2.1",
34
34
  "dayjs": "^1.11.7",
35
35
  "swiper": "^8.1.5",
36
- "@bifrostui/icons": "1.4.2-beta.0",
37
- "@bifrostui/styles": "1.4.2-beta.0",
38
- "@bifrostui/types": "1.4.2-beta.0",
39
- "@bifrostui/utils": "1.4.2-beta.0"
36
+ "@bifrostui/icons": "1.4.2-beta.1",
37
+ "@bifrostui/styles": "1.4.2-beta.1",
38
+ "@bifrostui/types": "1.4.2-beta.1",
39
+ "@bifrostui/utils": "1.4.2-beta.1"
40
40
  },
41
41
  "peerDependencies": {
42
42
  "@tarojs/components": "^3.0.0",