@xhsreds/reds-rn-next 0.9.1-beta202510291556 → 0.9.1-test.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.
Files changed (67) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/coverage/.tmp/coverage-0.json +1 -1
  3. package/coverage/.tmp/coverage-1.json +1 -1
  4. package/coverage/.tmp/coverage-10.json +1 -1
  5. package/coverage/.tmp/coverage-11.json +1 -1
  6. package/coverage/.tmp/coverage-12.json +1 -1
  7. package/coverage/.tmp/coverage-13.json +1 -1
  8. package/coverage/.tmp/coverage-14.json +1 -1
  9. package/coverage/.tmp/coverage-15.json +1 -1
  10. package/coverage/.tmp/coverage-16.json +1 -1
  11. package/coverage/.tmp/coverage-17.json +1 -1
  12. package/coverage/.tmp/coverage-18.json +1 -1
  13. package/coverage/.tmp/coverage-19.json +1 -1
  14. package/coverage/.tmp/coverage-2.json +1 -1
  15. package/coverage/.tmp/coverage-20.json +1 -1
  16. package/coverage/.tmp/coverage-23.json +1 -1
  17. package/coverage/.tmp/coverage-24.json +1 -1
  18. package/coverage/.tmp/coverage-29.json +1 -1
  19. package/coverage/.tmp/coverage-3.json +1 -1
  20. package/coverage/.tmp/coverage-30.json +1 -1
  21. package/coverage/.tmp/coverage-31.json +1 -1
  22. package/coverage/.tmp/coverage-33.json +1 -1
  23. package/coverage/.tmp/coverage-34.json +1 -1
  24. package/coverage/.tmp/coverage-35.json +1 -1
  25. package/coverage/.tmp/coverage-36.json +1 -1
  26. package/coverage/.tmp/coverage-37.json +1 -1
  27. package/coverage/.tmp/coverage-38.json +1 -1
  28. package/coverage/.tmp/coverage-39.json +1 -1
  29. package/coverage/.tmp/coverage-40.json +1 -1
  30. package/coverage/.tmp/coverage-42.json +1 -1
  31. package/coverage/.tmp/coverage-43.json +1 -1
  32. package/coverage/.tmp/coverage-5.json +1 -1
  33. package/coverage/.tmp/coverage-7.json +1 -1
  34. package/coverage/.tmp/coverage-8.json +1 -1
  35. package/coverage/.tmp/coverage-9.json +1 -1
  36. package/lib/cjs/_chunks/CwkpVXDI.js.map +1 -1
  37. package/lib/cjs/components/Carousel/Carousel.js +2 -9
  38. package/lib/cjs/components/Carousel/Carousel.js.map +1 -1
  39. package/lib/cjs/components/Popover/Popover.js +3 -4
  40. package/lib/cjs/components/Popover/Popover.js.map +1 -1
  41. package/lib/cjs/components/Radio/Radio.js.map +1 -1
  42. package/lib/cjs/components/Sheets/styles.js +2 -2
  43. package/lib/cjs/components/Sheets/styles.js.map +1 -1
  44. package/lib/cjs/pvCount/pvData.js +1 -1
  45. package/lib/esm/_chunks/Da9cW8JG.js.map +1 -1
  46. package/lib/esm/components/Carousel/Carousel.js +2 -9
  47. package/lib/esm/components/Carousel/Carousel.js.map +1 -1
  48. package/lib/esm/components/Popover/Popover.js +3 -4
  49. package/lib/esm/components/Popover/Popover.js.map +1 -1
  50. package/lib/esm/components/Radio/Radio.js.map +1 -1
  51. package/lib/esm/components/Sheets/styles.js +2 -2
  52. package/lib/esm/components/Sheets/styles.js.map +1 -1
  53. package/lib/esm/pvCount/pvData.js +1 -1
  54. package/lib/src/components/Popover/Popover.d.ts +1 -1
  55. package/lib/src/components/Popover/interface/index.d.ts +0 -1
  56. package/lib/types/components/Popover/Popover.d.ts +1 -1
  57. package/lib/types/components/Popover/interface/index.d.ts +0 -1
  58. package/package.json +2 -2
  59. package/src/components/Carousel/Carousel.tsx +3 -15
  60. package/src/components/Carousel/demo/index.tsx +2 -14
  61. package/src/components/Popover/Popover.tsx +3 -4
  62. package/src/components/Popover/doc/index.mdx +21 -22
  63. package/src/components/Popover/interface/index.ts +0 -1
  64. package/src/components/Sheets/styles.ts +2 -2
  65. package/src/i18n/@types/resources.d.ts +27 -27
  66. package/src/i18n/index.json +31 -31
  67. package/src/index.ts +1 -0
@@ -49,11 +49,11 @@ var styles = StyleSheet.create({
49
49
  borderTopRightRadius: 12
50
50
  },
51
51
  cancel: {
52
- fontSize: typography.B2LooseSwitchFontSize,
52
+ fontSize: typography.B1LooseFontSize,
53
53
  fontWeight: typography.B1LooseFontWeight
54
54
  },
55
55
  confirm: {
56
- fontSize: typography.B2LooseSwitchFontSize,
56
+ fontSize: typography.B1LooseFontSize,
57
57
  fontWeight: typography.T3FontWeight
58
58
  },
59
59
  label: {
@@ -1 +1 @@
1
- {"version":3,"file":"styles.js","sources":["../../../../src/components/Sheets/styles.ts"],"sourcesContent":["import { StyleSheet } from \"react-native\";\nimport { typography } from \"@xhsreds/reds-token-next\";\n\nconst styles = StyleSheet.create({\n wrapper: {\n position: \"absolute\",\n bottom: 0,\n left: 0,\n right: 0,\n top: 0,\n },\n mask: {\n width: \"100%\",\n height: \"100%\",\n position: \"absolute\",\n bottom: 0,\n left: 0,\n right: 0,\n top: 0,\n },\n picker: {\n borderTopLeftRadius: 12,\n borderTopRightRadius: 12,\n position: \"absolute\",\n bottom: 0,\n left: 0,\n right: 0,\n },\n labelContainer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n flexDirection: \"row\",\n height: 44,\n paddingLeft: 16,\n paddingRight: 16,\n borderTopLeftRadius: 12,\n borderTopRightRadius: 12,\n },\n leftLabelContainer: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n flexDirection: \"row\",\n height: 44,\n paddingLeft: 16,\n paddingRight: 16,\n borderTopLeftRadius: 12,\n borderTopRightRadius: 12,\n },\n cancel: {\n fontSize: typography.B2LooseSwitchFontSize,\n fontWeight: typography.B1LooseFontWeight,\n },\n confirm: {\n fontSize: typography.B2LooseSwitchFontSize,\n fontWeight: typography.T3FontWeight,\n },\n label: {\n fontSize: typography.B1LooseFontSize,\n fontWeight: typography.T3FontWeight,\n },\n iconBg: {\n width: 28,\n height: 28,\n borderRadius: 28,\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n },\n dragableContainer: {\n width: \"100%\",\n height: 20,\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n },\n dragable: {\n width: 33,\n height: 4,\n borderRadius: 10,\n },\n block: {\n width: 28,\n height: 28,\n },\n actionContainer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n flexDirection: \"row\",\n width: \"100%\",\n paddingHorizontal: 56,\n },\n action: {\n flex: 1,\n marginHorizontal: 12,\n },\n});\n\nexport default styles;\n"],"names":["styles","StyleSheet","create","wrapper","position","bottom","left","right","top","mask","width","height","picker","borderTopLeftRadius","borderTopRightRadius","labelContainer","display","justifyContent","alignItems","flexDirection","paddingLeft","paddingRight","leftLabelContainer","cancel","fontSize","typography","B2LooseSwitchFontSize","fontWeight","B1LooseFontWeight","confirm","T3FontWeight","label","B1LooseFontSize","iconBg","borderRadius","dragableContainer","dragable","block","actionContainer","paddingHorizontal","action","flex","marginHorizontal"],"mappings":";;;AAGA,IAAMA,MAAA,GAASC,WAAWC,MAAO,CAAA;AAC/BC,EAAAA,OAAS,EAAA;AACPC,IAAAA,QAAU,EAAA,UAAA;AACVC,IAAAA,MAAQ,EAAA,CAAA;AACRC,IAAAA,IAAM,EAAA,CAAA;AACNC,IAAAA,KAAO,EAAA,CAAA;AACPC,IAAAA,GAAK,EAAA,CAAA;GACP;AACAC,EAAAA,IAAM,EAAA;AACJC,IAAAA,KAAO,EAAA,MAAA;AACPC,IAAAA,MAAQ,EAAA,MAAA;AACRP,IAAAA,QAAU,EAAA,UAAA;AACVC,IAAAA,MAAQ,EAAA,CAAA;AACRC,IAAAA,IAAM,EAAA,CAAA;AACNC,IAAAA,KAAO,EAAA,CAAA;AACPC,IAAAA,GAAK,EAAA,CAAA;GACP;AACAI,EAAAA,MAAQ,EAAA;AACNC,IAAAA,mBAAqB,EAAA,EAAA;AACrBC,IAAAA,oBAAsB,EAAA,EAAA;AACtBV,IAAAA,QAAU,EAAA,UAAA;AACVC,IAAAA,MAAQ,EAAA,CAAA;AACRC,IAAAA,IAAM,EAAA,CAAA;AACNC,IAAAA,KAAO,EAAA,CAAA;GACT;AACA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MAAA;AACPC,IAAAA,MAAQ,EAAA,EAAA;AACRK,IAAAA,OAAS,EAAA,MAAA;AACTC,IAAAA,cAAgB,EAAA,QAAA;AAChBC,IAAAA,UAAY,EAAA,QAAA;GACd;AACAkB,EAAAA,QAAU,EAAA;AACR1B,IAAAA,KAAO,EAAA,EAAA;AACPC,IAAAA,MAAQ,EAAA,CAAA;AACRuB,IAAAA,YAAc,EAAA,EAAA;GAChB;AACAG,EAAAA,KAAO,EAAA;AACL3B,IAAAA,KAAO,EAAA,EAAA;AACPC,IAAAA,MAAQ,EAAA,EAAA;GACV;AACA2B,EAAAA,eAAiB,EAAA;AACftB,IAAAA,OAAS,EAAA,MAAA;AACTC,IAAAA,cAAgB,EAAA,eAAA;AAChBC,IAAAA,UAAY,EAAA,QAAA;AACZC,IAAAA,aAAe,EAAA,KAAA;AACfT,IAAAA,KAAO,EAAA,MAAA;AACP6B,IAAAA,iBAAmB,EAAA,EAAA;GACrB;AACAC,EAAAA,MAAQ,EAAA;AACNC,IAAAA,IAAM,EAAA,CAAA;AACNC,IAAAA,gBAAkB,EAAA,EAAA;AACpB,GAAA;AACF,CAAC;;;;"}
1
+ {"version":3,"file":"styles.js","sources":["../../../../src/components/Sheets/styles.ts"],"sourcesContent":["import { StyleSheet } from \"react-native\";\nimport { typography } from \"@xhsreds/reds-token-next\";\n\nconst styles = StyleSheet.create({\n wrapper: {\n position: \"absolute\",\n bottom: 0,\n left: 0,\n right: 0,\n top: 0,\n },\n mask: {\n width: \"100%\",\n height: \"100%\",\n position: \"absolute\",\n bottom: 0,\n left: 0,\n right: 0,\n top: 0,\n },\n picker: {\n borderTopLeftRadius: 12,\n borderTopRightRadius: 12,\n position: \"absolute\",\n bottom: 0,\n left: 0,\n right: 0,\n },\n labelContainer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n flexDirection: \"row\",\n height: 44,\n paddingLeft: 16,\n paddingRight: 16,\n borderTopLeftRadius: 12,\n borderTopRightRadius: 12,\n },\n leftLabelContainer: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n flexDirection: \"row\",\n height: 44,\n paddingLeft: 16,\n paddingRight: 16,\n borderTopLeftRadius: 12,\n borderTopRightRadius: 12,\n },\n cancel: {\n fontSize: typography.B1LooseFontSize,\n fontWeight: typography.B1LooseFontWeight,\n },\n confirm: {\n fontSize: typography.B1LooseFontSize,\n fontWeight: typography.T3FontWeight,\n },\n label: {\n fontSize: typography.B1LooseFontSize,\n fontWeight: typography.T3FontWeight,\n },\n iconBg: {\n width: 28,\n height: 28,\n borderRadius: 28,\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n },\n dragableContainer: {\n width: \"100%\",\n height: 20,\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n },\n dragable: {\n width: 33,\n height: 4,\n borderRadius: 10,\n },\n block: {\n width: 28,\n height: 28,\n },\n actionContainer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n flexDirection: \"row\",\n width: \"100%\",\n paddingHorizontal: 56,\n },\n action: {\n flex: 1,\n marginHorizontal: 12,\n },\n});\n\nexport default styles;\n"],"names":["styles","StyleSheet","create","wrapper","position","bottom","left","right","top","mask","width","height","picker","borderTopLeftRadius","borderTopRightRadius","labelContainer","display","justifyContent","alignItems","flexDirection","paddingLeft","paddingRight","leftLabelContainer","cancel","fontSize","typography","B1LooseFontSize","fontWeight","B1LooseFontWeight","confirm","T3FontWeight","label","iconBg","borderRadius","dragableContainer","dragable","block","actionContainer","paddingHorizontal","action","flex","marginHorizontal"],"mappings":";;;AAGA,IAAMA,MAAA,GAASC,WAAWC,MAAO,CAAA;AAC/BC,EAAAA,OAAS,EAAA;AACPC,IAAAA,QAAU,EAAA,UAAA;AACVC,IAAAA,MAAQ,EAAA,CAAA;AACRC,IAAAA,IAAM,EAAA,CAAA;AACNC,IAAAA,KAAO,EAAA,CAAA;AACPC,IAAAA,GAAK,EAAA,CAAA;GACP;AACA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Callback } from '@xhs/reds-apm/src/index.native';
2
2
 
3
3
  var name = "@xhs/reds-rn-next";
4
- var version = "0.9.0";
4
+ var version = "0.9.1-test.0";
5
5
  var author = "贾斌(呀哈) <jiabin@xiaohongshu.com>";
6
6
  var license = "ISC";
7
7
  var dependencies = {
@@ -1,4 +1,4 @@
1
1
  import React from "react";
2
2
  import { RedsPopover } from "./interface/index";
3
- declare const _default: ({ mode, opacity, content, children, isControl, placement, closeOnClickAgain, trigger, zIndex, visible, onVisibleChange, onClickMask: _onClickMask, popContainerStyle, arrowStyles: propsArrowStyles, offset, duration, animation_duration, hostName, maxWidth, arrowOffset, }: RedsPopover) => React.JSX.Element;
3
+ declare const _default: ({ mode, opacity, content, children, isControl, placement, closeOnClickAgain, trigger, zIndex, visible, onVisibleChange, onClickMask: _onClickMask, popContainerStyle, arrowStyles: propsArrowStyles, offset, duration, hostName, maxWidth, arrowOffset, }: RedsPopover) => React.JSX.Element;
4
4
  export default _default;
@@ -12,7 +12,6 @@ export interface RedsPopover {
12
12
  mode?: "light" | "dark" | "alwaysLight" | "alwaysDark";
13
13
  trigger?: "click" | "touch";
14
14
  duration?: number;
15
- animation_duration?: number;
16
15
  zIndex?: number;
17
16
  popContainerStyle?: ViewStyle;
18
17
  closeOnClickAgain?: boolean;
@@ -1,4 +1,4 @@
1
1
  import React from "react";
2
2
  import { RedsPopover } from "./interface/index";
3
- declare const _default: ({ mode, opacity, content, children, isControl, placement, closeOnClickAgain, trigger, zIndex, visible, onVisibleChange, onClickMask: _onClickMask, popContainerStyle, arrowStyles: propsArrowStyles, offset, duration, animation_duration, hostName, maxWidth, arrowOffset, }: RedsPopover) => React.JSX.Element;
3
+ declare const _default: ({ mode, opacity, content, children, isControl, placement, closeOnClickAgain, trigger, zIndex, visible, onVisibleChange, onClickMask: _onClickMask, popContainerStyle, arrowStyles: propsArrowStyles, offset, duration, hostName, maxWidth, arrowOffset, }: RedsPopover) => React.JSX.Element;
4
4
  export default _default;
@@ -12,7 +12,6 @@ export interface RedsPopover {
12
12
  mode?: "light" | "dark" | "alwaysLight" | "alwaysDark";
13
13
  trigger?: "click" | "touch";
14
14
  duration?: number;
15
- animation_duration?: number;
16
15
  zIndex?: number;
17
16
  popContainerStyle?: ViewStyle;
18
17
  closeOnClickAgain?: boolean;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xhsreds/reds-rn-next",
3
- "version": "0.9.1-beta202510291556",
3
+ "version": "0.9.1-test.0",
4
4
  "author": "贾斌(呀哈) <jiabin@xiaohongshu.com>",
5
5
  "license": "ISC",
6
6
  "dependencies": {
@@ -26,7 +26,7 @@
26
26
  "react-native-fs": "2.20.0",
27
27
  "react-native-svg": "13.14.0",
28
28
  "@xhs/react-native-harmony": "*",
29
- "@xhsreds/reds-token-next": "0.9.1-beta202510291556"
29
+ "@xhsreds/reds-token-next": "0.9.0"
30
30
  },
31
31
  "peerDependenciesMeta": {
32
32
  "ozone-schema-web": {
@@ -238,8 +238,8 @@ export const Carousel: React.FC<RedsCarousel> = (props) => {
238
238
 
239
239
  requestAnimationFrame(() => {
240
240
  let scrollOffset = index * offsetPerItem;
241
- // 修复:只有在无限循环模式下才需要减去containerPadding
242
- if (props.playingMode !== "normal" && props.infinite) {
241
+
242
+ if (props.playingMode !== "normal") {
243
243
  scrollOffset -= containerPadding;
244
244
  }
245
245
 
@@ -287,18 +287,10 @@ export const Carousel: React.FC<RedsCarousel> = (props) => {
287
287
  props.direction === "horizontal" ? event.nativeEvent.contentOffset.x : event.nativeEvent.contentOffset.y;
288
288
 
289
289
  let index: number;
290
- // 修复:对于非无限循环的compact模式,需要调整偏移量计算
291
290
  if (props.playingMode === "normal") {
292
291
  index = Math.round(offset / offsetPerItem);
293
292
  } else {
294
- // 对于compact和card模式
295
- if (!props.infinite) {
296
- // 非无限循环模式:不需要加containerPadding,因为滚动时已经考虑了padding
297
- index = Math.round(offset / offsetPerItem);
298
- } else {
299
- // 无限循环模式:需要加containerPadding
300
- index = Math.round((offset + containerPadding) / offsetPerItem);
301
- }
293
+ index = Math.round((offset + containerPadding) / offsetPerItem);
302
294
  }
303
295
 
304
296
  index = Math.max(0, Math.min(index, extendedData.length - 1));
@@ -320,10 +312,6 @@ export const Carousel: React.FC<RedsCarousel> = (props) => {
320
312
  const clampedIndex = Math.max(0, Math.min(index, length - 1));
321
313
  setCurrentIndex(clampedIndex);
322
314
  setRealIndex(clampedIndex);
323
- // 修复:确保滚动到正确位置
324
- if (props.playingMode !== "normal") {
325
- scrollToIndex(clampedIndex, true);
326
- }
327
315
  }
328
316
 
329
317
  setIsScrolling(false);
@@ -1,6 +1,6 @@
1
1
  import React, { useState } from "react";
2
2
  import { View, Text, StyleSheet, ScrollView, Image as RNImage } from "react-native";
3
- import { Carousel, CarouselType } from "@xhs/reds-rn-next";
3
+ import { Carousel } from "@xhs/reds-rn-next";
4
4
  const styles = StyleSheet.create({
5
5
  container: {
6
6
  paddingBottom: 100,
@@ -54,18 +54,6 @@ export default function App() {
54
54
  handlable={false}
55
55
  />
56
56
  <Carousel
57
- data={images}
58
- autoPlay={false}
59
- currentIndex={3}
60
- onChange={handleChange}
61
- onClick={handleClick}
62
- displayNumbers={true}
63
- // duration={3000}
64
- playingMode={CarouselType.PLAYINGMODE.COMPACT}
65
- handlable={true}
66
- infinite={false}
67
- />
68
- {/* <Carousel
69
57
  autoPlay={true}
70
58
  currentIndex={3}
71
59
  onChange={handleChange}
@@ -94,7 +82,7 @@ export default function App() {
94
82
  {images.map((item, idx) => (
95
83
  <RNImage style={{ width: 300, height: 200 }} source={{ uri: item }} />
96
84
  ))}
97
- </Carousel> */}
85
+ </Carousel>
98
86
  {/* <Desc>自动播放(默认轮播间隔1000ms)</Desc>
99
87
  <Carousel data={images} duration={3000} />
100
88
 
@@ -24,7 +24,6 @@ export default ({
24
24
  arrowStyles: propsArrowStyles,
25
25
  offset,
26
26
  duration,
27
- animation_duration,
28
27
  hostName,
29
28
  maxWidth,
30
29
  arrowOffset,
@@ -122,18 +121,18 @@ export default ({
122
121
  if (layout.x !== defaultValue) {
123
122
  Animated.timing(progress, {
124
123
  toValue: 1,
125
- duration: animation_duration ?? 400,
124
+ duration: duration ?? 400,
126
125
  useNativeDriver: false,
127
126
  }).start();
128
127
  }
129
128
  } else {
130
129
  Animated.timing(progress, {
131
130
  toValue: 0,
132
- duration: animation_duration ?? 400,
131
+ duration: duration ?? 400,
133
132
  useNativeDriver: false,
134
133
  }).start();
135
134
  }
136
- }, [_visible, layout, animation_duration]);
135
+ }, [_visible, layout]);
137
136
 
138
137
  const onMaskChange = (event: GestureResponderEvent, value: boolean) => {
139
138
  if (isControl) return;
@@ -8,28 +8,27 @@ import BaseDemo from "!!raw-loader!../demo/index.tsx";
8
8
 
9
9
  ### Props
10
10
 
11
- | 属性 | 描述 | 类型 | 默认值 |
12
- | ------------------ | --------------------------------- | --------------------------------------------------------------------------------------------------- | --------------- |
13
- | visible | 是否显示气泡 | boolean | undefined |
14
- | placement | 气泡方向 | "top-start" &#124; "top" &#124; "top-end" &#124; "bottom-start" &#124; "bottom" &#124; "bottom-end" | top |
15
- | content | 弹出内容 | ReactNode &#124; (() => ReactNode) | |
16
- | opacity | 遮罩透明度 | number | 0 |
17
- | mode | 主题色 | "light" &#124; "dark" &#124; "alwaysLight" &#124; "alwaysDark" | light |
18
- | trigger | 触发方式 | "click" &#124; "touch" | click |
19
- | duration | 固定时间后popover消失 | number | |
20
- | animation_duration | animation_duration 动画时间 | number | |
21
- | zIndex | 层级 | number | 1000 |
22
- | popContainerStyle | 气泡框的样式 | ViewStyle | `{}` |
23
- | closeOnClickAgain | 再次点击关闭 | boolean | true |
24
- | children | popover 作用的目标节点 | ReactNode | |
25
- | floatingStyles | floating style | ViewStyle | `{}` |
26
- | arrowStyles | arrow style | ImageStyle | `{}` |
27
- | isControl | 是否受控 | boolean | false |
28
- | offset | 气泡偏移位置 用于特殊场景适配 | Offset | `{"x":0,"y":0}` |
29
- | arrowOffset | 气泡箭头偏移位置 用于特殊场景适配 | Offset | `{"x":0,"y":0}` |
30
- | hostName | hostName | string | root |
31
- | maxWidth | popover最大宽度 | number | 280 |
32
- | layoutChange | 布局是否变化 | any | `{}` |
11
+ | 属性 | 描述 | 类型 | 默认值 |
12
+ | ----------------- | --------------------------------- | --------------------------------------------------------------------------------------------------- | --------------- |
13
+ | visible | 是否显示气泡 | boolean | undefined |
14
+ | placement | 气泡方向 | "top-start" &#124; "top" &#124; "top-end" &#124; "bottom-start" &#124; "bottom" &#124; "bottom-end" | top |
15
+ | content | 弹出内容 | ReactNode &#124; (() => ReactNode) | |
16
+ | opacity | 遮罩透明度 | number | 0 |
17
+ | mode | 主题色 | "light" &#124; "dark" &#124; "alwaysLight" &#124; "alwaysDark" | light |
18
+ | trigger | 触发方式 | "click" &#124; "touch" | click |
19
+ | duration | 固定时间后popover消失 | number | |
20
+ | zIndex | 层级 | number | 1000 |
21
+ | popContainerStyle | 气泡框的样式 | ViewStyle | `{}` |
22
+ | closeOnClickAgain | 再次点击关闭 | boolean | true |
23
+ | children | popover 作用的目标节点 | ReactNode | |
24
+ | floatingStyles | floating style | ViewStyle | `{}` |
25
+ | arrowStyles | arrow style | ImageStyle | `{}` |
26
+ | isControl | 是否受控 | boolean | false |
27
+ | offset | 气泡偏移位置 用于特殊场景适配 | Offset | `{"x":0,"y":0}` |
28
+ | arrowOffset | 气泡箭头偏移位置 用于特殊场景适配 | Offset | `{"x":0,"y":0}` |
29
+ | hostName | hostName | string | root |
30
+ | maxWidth | popover最大宽度 | number | 280 |
31
+ | layoutChange | 布局是否变化 | any | `{}` |
33
32
 
34
33
  ### Events
35
34
 
@@ -12,7 +12,6 @@ export interface RedsPopover {
12
12
  mode?: "light" | "dark" | "alwaysLight" | "alwaysDark";
13
13
  trigger?: "click" | "touch";
14
14
  duration?: number;
15
- animation_duration?: number;
16
15
  zIndex?: number;
17
16
  popContainerStyle?: ViewStyle;
18
17
  closeOnClickAgain?: boolean;
@@ -49,11 +49,11 @@ const styles = StyleSheet.create({
49
49
  borderTopRightRadius: 12,
50
50
  },
51
51
  cancel: {
52
- fontSize: typography.B2LooseSwitchFontSize,
52
+ fontSize: typography.B1LooseFontSize,
53
53
  fontWeight: typography.B1LooseFontWeight,
54
54
  },
55
55
  confirm: {
56
- fontSize: typography.B2LooseSwitchFontSize,
56
+ fontSize: typography.B1LooseFontSize,
57
57
  fontWeight: typography.T3FontWeight,
58
58
  },
59
59
  label: {
@@ -1,32 +1,32 @@
1
1
  interface Resources {
2
2
  componentKey: {
3
- sureKey: "確定";
4
- satisfyKey: "滿意";
5
- confirmKey: "確認";
6
- uploadingKey: "上傳中";
7
- resetKey: "重置";
8
- NoDataKey: "暫無數據";
9
- liveStreamingKey: "直播";
10
- generallyKey: "一般";
11
- uploadFailedKey: "上傳失敗";
12
- submitKey: "提交";
13
- requestSuccessfulKey: "請求成功";
14
- cancelKey: "取消";
15
- PullDownToRefreshKey: "下拉重繪";
16
- selectAllKey: "全選";
17
- requestDataKey: "請求數據中";
18
- closeKey: "收起";
19
- veryBadKey: "極差";
20
- searchKey: "蒐索";
21
- expandKey: "展開";
22
- IDCardPhotoKey: "身份證人像面";
23
- finishKey: "完成";
24
- surpriseKey: "驚喜";
25
- releaseRefreshKey: "鬆開重繪";
26
- nationalEmblemSideOfIDCardKey: "身份证国徽面";
27
- buttonKey: "按鈕";
28
- jumpKey: "跳轉";
29
- disappointmentKey: "失望";
3
+ sureKey: "Confirm";
4
+ satisfyKey: "Satisfy";
5
+ confirmKey: "Confirm";
6
+ uploadingKey: "Uploading";
7
+ resetKey: "Reset";
8
+ NoDataKey: "No data available at the moment";
9
+ liveStreamingKey: "live";
10
+ generallyKey: "Generally";
11
+ uploadFailedKey: "Upload failed";
12
+ submitKey: "Submit";
13
+ requestSuccessfulKey: "Request successful";
14
+ cancelKey: "Cancel";
15
+ PullDownToRefreshKey: "Pull down to refresh";
16
+ selectAllKey: "SelectAll";
17
+ requestDataKey: "Request data";
18
+ closeKey: "Close";
19
+ veryBadKey: "Very bad";
20
+ searchKey: "Search";
21
+ expandKey: "Expand";
22
+ IDCardPhotoKey: "ID card photo";
23
+ finishKey: "Finish";
24
+ surpriseKey: "Surprise";
25
+ releaseRefreshKey: "Release refresh";
26
+ nationalEmblemSideOfIDCardKey: "National emblem side of ID card";
27
+ buttonKey: "Button";
28
+ jumpKey: "Jump";
29
+ disappointmentKey: "Disappointment";
30
30
  };
31
31
  }
32
32
  export default Resources;
@@ -1,35 +1,4 @@
1
1
  {
2
- "zh_tw": {
3
- "componentKey": {
4
- "sureKey": "確定",
5
- "satisfyKey": "滿意",
6
- "confirmKey": "確認",
7
- "uploadingKey": "上傳中",
8
- "resetKey": "重置",
9
- "NoDataKey": "暫無數據",
10
- "liveStreamingKey": "直播",
11
- "generallyKey": "一般",
12
- "uploadFailedKey": "上傳失敗",
13
- "submitKey": "提交",
14
- "requestSuccessfulKey": "請求成功",
15
- "cancelKey": "取消",
16
- "PullDownToRefreshKey": "下拉重繪",
17
- "selectAllKey": "全選",
18
- "requestDataKey": "請求數據中",
19
- "closeKey": "收起",
20
- "veryBadKey": "極差",
21
- "searchKey": "蒐索",
22
- "expandKey": "展開",
23
- "IDCardPhotoKey": "身份證人像面",
24
- "finishKey": "完成",
25
- "surpriseKey": "驚喜",
26
- "releaseRefreshKey": "鬆開重繪",
27
- "nationalEmblemSideOfIDCardKey": "身份证国徽面",
28
- "buttonKey": "按鈕",
29
- "jumpKey": "跳轉",
30
- "disappointmentKey": "失望"
31
- }
32
- },
33
2
  "en_us": {
34
3
  "componentKey": {
35
4
  "sureKey": "Confirm",
@@ -91,5 +60,36 @@
91
60
  "jumpKey": "跳转",
92
61
  "disappointmentKey": "失望"
93
62
  }
63
+ },
64
+ "zh_tw": {
65
+ "componentKey": {
66
+ "sureKey": "確定",
67
+ "satisfyKey": "滿意",
68
+ "confirmKey": "確認",
69
+ "uploadingKey": "上傳中",
70
+ "resetKey": "重置",
71
+ "NoDataKey": "暫無數據",
72
+ "liveStreamingKey": "直播",
73
+ "generallyKey": "一般",
74
+ "uploadFailedKey": "上傳失敗",
75
+ "submitKey": "提交",
76
+ "requestSuccessfulKey": "請求成功",
77
+ "cancelKey": "取消",
78
+ "PullDownToRefreshKey": "下拉重繪",
79
+ "selectAllKey": "全選",
80
+ "requestDataKey": "請求數據中",
81
+ "closeKey": "收起",
82
+ "veryBadKey": "極差",
83
+ "searchKey": "蒐索",
84
+ "expandKey": "展開",
85
+ "IDCardPhotoKey": "身份證人像面",
86
+ "finishKey": "完成",
87
+ "surpriseKey": "驚喜",
88
+ "releaseRefreshKey": "鬆開重繪",
89
+ "nationalEmblemSideOfIDCardKey": "身份证国徽面",
90
+ "buttonKey": "按鈕",
91
+ "jumpKey": "跳轉",
92
+ "disappointmentKey": "失望"
93
+ }
94
94
  }
95
95
  }
package/src/index.ts CHANGED
@@ -1,3 +1,4 @@
1
+ // "test"
1
2
  export * from "./components/SegmentedControl";
2
3
  export * from "./components/LanguageProvider";
3
4
  export * from "./components/NoticeBar";