@dongsuo/react-native-uitextview 1.0.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 (102) hide show
  1. package/LICENSE +20 -0
  2. package/README.md +225 -0
  3. package/android/generated/jni/CMakeLists.txt +36 -0
  4. package/android/generated/jni/RNUITextViewSpec-generated.cpp +22 -0
  5. package/android/generated/jni/RNUITextViewSpec.h +24 -0
  6. package/android/generated/jni/react/renderer/components/RNUITextViewSpec/ComponentDescriptors.cpp +23 -0
  7. package/android/generated/jni/react/renderer/components/RNUITextViewSpec/ComponentDescriptors.h +25 -0
  8. package/android/generated/jni/react/renderer/components/RNUITextViewSpec/EventEmitters.cpp +61 -0
  9. package/android/generated/jni/react/renderer/components/RNUITextViewSpec/EventEmitters.h +49 -0
  10. package/android/generated/jni/react/renderer/components/RNUITextViewSpec/Props.cpp +47 -0
  11. package/android/generated/jni/react/renderer/components/RNUITextViewSpec/Props.h +182 -0
  12. package/android/generated/jni/react/renderer/components/RNUITextViewSpec/RNUITextViewSpecJSI-generated.cpp +17 -0
  13. package/android/generated/jni/react/renderer/components/RNUITextViewSpec/RNUITextViewSpecJSI.h +19 -0
  14. package/android/generated/jni/react/renderer/components/RNUITextViewSpec/ShadowNodes.cpp +18 -0
  15. package/android/generated/jni/react/renderer/components/RNUITextViewSpec/ShadowNodes.h +43 -0
  16. package/android/generated/jni/react/renderer/components/RNUITextViewSpec/States.cpp +16 -0
  17. package/android/generated/jni/react/renderer/components/RNUITextViewSpec/States.h +41 -0
  18. package/ios/RNUITextView.h +23 -0
  19. package/ios/RNUITextView.mm +474 -0
  20. package/ios/RNUITextViewChild.h +24 -0
  21. package/ios/RNUITextViewChild.mm +76 -0
  22. package/ios/RNUITextViewChildComponentDescriptor.h +13 -0
  23. package/ios/RNUITextViewChildShadowNode.cpp +6 -0
  24. package/ios/RNUITextViewChildShadowNode.h +16 -0
  25. package/ios/RNUITextViewComponentDescriptor.h +13 -0
  26. package/ios/RNUITextViewEventEmitter.h +26 -0
  27. package/ios/RNUITextViewManager.mm +36 -0
  28. package/ios/RNUITextViewShadowNode.cpp +127 -0
  29. package/ios/RNUITextViewShadowNode.h +48 -0
  30. package/ios/RNUITextViewSpecJSI-generated.cpp +17 -0
  31. package/ios/RNUITextViewSpecJSI.h +19 -0
  32. package/ios/generated/RNUITextViewSpec/ComponentDescriptors.cpp +23 -0
  33. package/ios/generated/RNUITextViewSpec/ComponentDescriptors.h +25 -0
  34. package/ios/generated/RNUITextViewSpec/EventEmitters.cpp +61 -0
  35. package/ios/generated/RNUITextViewSpec/EventEmitters.h +49 -0
  36. package/ios/generated/RNUITextViewSpec/Props.cpp +47 -0
  37. package/ios/generated/RNUITextViewSpec/Props.h +182 -0
  38. package/ios/generated/RNUITextViewSpec/RCTComponentViewHelpers.h +24 -0
  39. package/ios/generated/RNUITextViewSpec/RNUITextViewSpec-generated.mm +16 -0
  40. package/ios/generated/RNUITextViewSpec/RNUITextViewSpec.h +38 -0
  41. package/ios/generated/RNUITextViewSpec/ShadowNodes.cpp +18 -0
  42. package/ios/generated/RNUITextViewSpec/ShadowNodes.h +43 -0
  43. package/ios/generated/RNUITextViewSpec/States.cpp +16 -0
  44. package/ios/generated/RNUITextViewSpec/States.h +41 -0
  45. package/ios/generated/RNUITextViewSpecJSI-generated.cpp +17 -0
  46. package/ios/generated/RNUITextViewSpecJSI.h +19 -0
  47. package/lib/commonjs/RNUITextViewChildNativeComponent.ts +48 -0
  48. package/lib/commonjs/RNUITextViewNativeComponent.ts +47 -0
  49. package/lib/commonjs/Text.js +140 -0
  50. package/lib/commonjs/Text.js.map +1 -0
  51. package/lib/commonjs/index.js +17 -0
  52. package/lib/commonjs/index.js.map +1 -0
  53. package/lib/commonjs/package.json +1 -0
  54. package/lib/commonjs/util.js +64 -0
  55. package/lib/commonjs/util.js.map +1 -0
  56. package/lib/module/RNUITextViewChildNativeComponent.ts +48 -0
  57. package/lib/module/RNUITextViewNativeComponent.ts +47 -0
  58. package/lib/module/Text.js +136 -0
  59. package/lib/module/Text.js.map +1 -0
  60. package/lib/module/index.js +4 -0
  61. package/lib/module/index.js.map +1 -0
  62. package/lib/module/package.json +1 -0
  63. package/lib/module/util.js +60 -0
  64. package/lib/module/util.js.map +1 -0
  65. package/lib/typescript/commonjs/example/src/App.d.ts +2 -0
  66. package/lib/typescript/commonjs/example/src/App.d.ts.map +1 -0
  67. package/lib/typescript/commonjs/example/src/CustomMenuExample.d.ts +3 -0
  68. package/lib/typescript/commonjs/example/src/CustomMenuExample.d.ts.map +1 -0
  69. package/lib/typescript/commonjs/package.json +1 -0
  70. package/lib/typescript/commonjs/src/RNUITextViewChildNativeComponent.d.ts +28 -0
  71. package/lib/typescript/commonjs/src/RNUITextViewChildNativeComponent.d.ts.map +1 -0
  72. package/lib/typescript/commonjs/src/RNUITextViewNativeComponent.d.ts +29 -0
  73. package/lib/typescript/commonjs/src/RNUITextViewNativeComponent.d.ts.map +1 -0
  74. package/lib/typescript/commonjs/src/Text.d.ts +17 -0
  75. package/lib/typescript/commonjs/src/Text.d.ts.map +1 -0
  76. package/lib/typescript/commonjs/src/index.d.ts +2 -0
  77. package/lib/typescript/commonjs/src/index.d.ts.map +1 -0
  78. package/lib/typescript/commonjs/src/util.d.ts +160 -0
  79. package/lib/typescript/commonjs/src/util.d.ts.map +1 -0
  80. package/lib/typescript/module/example/src/App.d.ts +2 -0
  81. package/lib/typescript/module/example/src/App.d.ts.map +1 -0
  82. package/lib/typescript/module/example/src/CustomMenuExample.d.ts +3 -0
  83. package/lib/typescript/module/example/src/CustomMenuExample.d.ts.map +1 -0
  84. package/lib/typescript/module/package.json +1 -0
  85. package/lib/typescript/module/src/RNUITextViewChildNativeComponent.d.ts +28 -0
  86. package/lib/typescript/module/src/RNUITextViewChildNativeComponent.d.ts.map +1 -0
  87. package/lib/typescript/module/src/RNUITextViewNativeComponent.d.ts +29 -0
  88. package/lib/typescript/module/src/RNUITextViewNativeComponent.d.ts.map +1 -0
  89. package/lib/typescript/module/src/Text.d.ts +17 -0
  90. package/lib/typescript/module/src/Text.d.ts.map +1 -0
  91. package/lib/typescript/module/src/index.d.ts +2 -0
  92. package/lib/typescript/module/src/index.d.ts.map +1 -0
  93. package/lib/typescript/module/src/util.d.ts +160 -0
  94. package/lib/typescript/module/src/util.d.ts.map +1 -0
  95. package/package.json +187 -0
  96. package/react-native-uitextview.podspec +21 -0
  97. package/react-native.config.js +28 -0
  98. package/src/RNUITextViewChildNativeComponent.ts +48 -0
  99. package/src/RNUITextViewNativeComponent.ts +47 -0
  100. package/src/Text.tsx +148 -0
  101. package/src/index.tsx +1 -0
  102. package/src/util.ts +65 -0
@@ -0,0 +1,136 @@
1
+ "use strict";
2
+
3
+ import React from 'react';
4
+ import { Platform, StyleSheet, Text as RNText } from 'react-native';
5
+
6
+ // 自定义菜单项接口
7
+
8
+ // 自定义菜单事件接口
9
+
10
+ import RNUITextViewChildNativeComponent from './RNUITextViewChildNativeComponent';
11
+ import RNUITextViewNativeComponent from './RNUITextViewNativeComponent';
12
+ import { flattenStyles } from "./util.js";
13
+ import { jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
14
+ const TextAncestorContext = /*#__PURE__*/React.createContext([false, StyleSheet.create({})]);
15
+ const textDefaults = {
16
+ allowFontScaling: true,
17
+ selectable: true
18
+ };
19
+ const useTextAncestorContext = () => React.useContext(TextAncestorContext);
20
+
21
+ // 扩展 TextProps 类型添加自定义菜单相关属性
22
+
23
+ function UITextViewChild({
24
+ style,
25
+ children,
26
+ customMenuItems,
27
+ onCustomMenuAction,
28
+ ...rest
29
+ }) {
30
+ const [isAncestor, rootStyle] = useTextAncestorContext();
31
+
32
+ // Flatten the styles, and apply the root styles when needed
33
+ const flattenedStyle = React.useMemo(() => flattenStyles(rootStyle, style), [rootStyle, style]);
34
+ console.log('customMenuItems', customMenuItems);
35
+ if (!isAncestor) {
36
+ return /*#__PURE__*/_jsx(TextAncestorContext.Provider, {
37
+ value: [true, flattenedStyle],
38
+ children: /*#__PURE__*/_jsx(RNUITextViewNativeComponent, {
39
+ ...textDefaults,
40
+ ...rest,
41
+ // ellipsizeMode={rest.ellipsizeMode ?? rest.lineBreakMode ?? 'tail'}
42
+ style: [flattenedStyle]
43
+ // 自定义菜单相关属性
44
+ ,
45
+ customMenuItems: customMenuItems,
46
+ onCustomMenuAction: event => {
47
+ onCustomMenuAction && onCustomMenuAction({
48
+ actionId: event.nativeEvent.actionId,
49
+ selectedText: event.nativeEvent.selectedText
50
+ });
51
+ }
52
+ // @ts-expect-error Weirdness
53
+ ,
54
+ onPress: undefined,
55
+ onLongPress: undefined,
56
+ children: React.Children.toArray(children).map((c, index) => {
57
+ if (/*#__PURE__*/React.isValidElement(c)) {
58
+ return c;
59
+ } else if (typeof c === 'string' || typeof c === 'number') {
60
+ return (
61
+ /*#__PURE__*/
62
+ // @ts-expect-error @TODO fix this type
63
+ _jsx(RNUITextViewChildNativeComponent, {
64
+ style: flattenedStyle,
65
+ text: c.toString(),
66
+ ...rest
67
+ }, index)
68
+ );
69
+ }
70
+ return null;
71
+ })
72
+ })
73
+ });
74
+ } else {
75
+ return /*#__PURE__*/_jsx(_Fragment, {
76
+ children: React.Children.toArray(children).map((c, index) => {
77
+ if (/*#__PURE__*/React.isValidElement(c)) {
78
+ return c;
79
+ } else if (typeof c === 'string' || typeof c === 'number') {
80
+ return (
81
+ /*#__PURE__*/
82
+ // @ts-expect-error @TODO fix this type
83
+ _jsx(RNUITextViewChildNativeComponent, {
84
+ style: flattenedStyle,
85
+ text: c.toString(),
86
+ ...rest
87
+ }, index)
88
+ );
89
+ }
90
+ return null;
91
+ })
92
+ });
93
+ }
94
+ }
95
+ function UITextViewInner(props) {
96
+ const [isAncestor] = useTextAncestorContext();
97
+
98
+ // Even if the uiTextView prop is set, we can still default to using
99
+ // normal selection (i.e. base RN text) if the text doesn't need to be
100
+ // selectable
101
+ if ((!props.selectable || !props.uiTextView) && !isAncestor) {
102
+ // 当使用原生 RNText 时,自定义菜单功能不可用
103
+ // Using _ prefix to indicate these are intentionally unused
104
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
105
+ const {
106
+ customMenuItems: _,
107
+ onCustomMenuAction: __,
108
+ ...restProps
109
+ } = props;
110
+ return /*#__PURE__*/_jsx(RNText, {
111
+ ...restProps
112
+ });
113
+ }
114
+ return /*#__PURE__*/_jsx(UITextViewChild, {
115
+ ...props
116
+ });
117
+ }
118
+ export function UITextView(props) {
119
+ if (Platform.OS !== 'ios') {
120
+ // 当不是 iOS 平台时,自定义菜单功能不可用
121
+ // Using _ prefix to indicate these are intentionally unused
122
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
123
+ const {
124
+ customMenuItems: _,
125
+ onCustomMenuAction: __,
126
+ ...restProps
127
+ } = props;
128
+ return /*#__PURE__*/_jsx(RNText, {
129
+ ...restProps
130
+ });
131
+ }
132
+ return /*#__PURE__*/_jsx(UITextViewInner, {
133
+ ...props
134
+ });
135
+ }
136
+ //# sourceMappingURL=Text.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["React","Platform","StyleSheet","Text","RNText","RNUITextViewChildNativeComponent","RNUITextViewNativeComponent","flattenStyles","jsx","_jsx","Fragment","_Fragment","TextAncestorContext","createContext","create","textDefaults","allowFontScaling","selectable","useTextAncestorContext","useContext","UITextViewChild","style","children","customMenuItems","onCustomMenuAction","rest","isAncestor","rootStyle","flattenedStyle","useMemo","console","log","Provider","value","event","actionId","nativeEvent","selectedText","onPress","undefined","onLongPress","Children","toArray","map","c","index","isValidElement","text","toString","UITextViewInner","props","uiTextView","_","__","restProps","UITextView","OS"],"sourceRoot":"../../src","sources":["Text.tsx"],"mappings":";;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SACEC,QAAQ,EACRC,UAAU,EACVC,IAAI,IAAIC,MAAM,QAGT,cAAc;;AAErB;;AAMA;;AAKA,OAAOC,gCAAgC,MAAM,oCAAoC;AACjF,OAAOC,2BAA2B,MAAM,+BAA+B;AACvE,SAA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,CAACxB,UAAU,CAAC,GAAGR,sBAAsB,CAAC,CAAC;;EAE7C;EACA;EACA;EACA,IAAI,CAAC,CAACgC,KAAK,CAACjC,UAAU,IAAI,CAACiC,KAAK,CAACC,UAAU,KAAK,CAACzB,UAAU,EAAE;IAC3D;IACA;IACA;IACA,MAAM;MAACH,eAAe,EAAE6B,CAAC;MAAE5B,kBAAkB,EAAE6B,EAAE;MAAE,GAAGC;IAAS,CAAC,GAAGJ,KAAK;IACxE,oBAAOzC,IAAA,CAACL,MAAM;MAAA,GAAKkD;IAAS,CAAG,CAAC;EAClC;EACA,oBAAO7C,IAAA,CAACW,eAAe;IAAA,GAAK8B;EAAK,CAAG,CAAC;AACvC;AAEA,OAAO,SAASK,UAAUA,CAACL,KAAwB,EAAE;EACnD,IAAIjD,QAAQ,CAACuD,EAAE,KAAK,KAAK,EAAE;IACzB;IACA;IACA;IACA,MAAM;MAACjC,eAAe,EAAE6B,CAAC;MAAE5B,kBAAkB,EAAE6B,EAAE;MAAE,GAAGC;IAAS,CAAC,GAAGJ,KAAK;IACxE,oBAAOzC,IAAA,CAACL,MAAM;MAAA,GAAKkD;IAAS,CAAG,CAAC;EAClC;EACA,oBAAO7C,IAAA,CAACwC,eAAe;IAAA,GAAKC;EAAK,CAAG,CAAC;AACvC","ignoreList":[]}
@@ -0,0 +1,4 @@
1
+ "use strict";
2
+
3
+ export * from "./Text.js";
4
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":[],"sourceRoot":"../../src","sources":["index.tsx"],"mappings":";;AAAA,cAAc,WAAQ","ignoreList":[]}
@@ -0,0 +1 @@
1
+ {"type":"module"}
@@ -0,0 +1,60 @@
1
+ "use strict";
2
+
3
+ import { StyleSheet } from 'react-native';
4
+ export function flattenStyles(rootStyle, style) {
5
+ const flattenedStyle = StyleSheet.flatten([rootStyle, style]);
6
+ return {
7
+ ...flattenedStyle,
8
+ fontWeight: fontWeightToNativeProp(flattenedStyle.fontWeight ?? 'normal'),
9
+ backgroundColor: flattenedStyle.backgroundColor ? flattenedStyle.backgroundColor : 'transparent',
10
+ shadowOffset: flattenedStyle.shadowOffset ? flattenedStyle.shadowOffset : {
11
+ width: 0,
12
+ height: 0
13
+ }
14
+ };
15
+ }
16
+
17
+ // Codegen doesn't like using integer values for enums (c++ L) so we'll conver them to the proper native prop
18
+ // value before returning flattened styles.
19
+ function fontWeightToNativeProp(fontWeight) {
20
+ switch (fontWeight) {
21
+ case 'normal':
22
+ return 'normal';
23
+ case 'bold':
24
+ return 'bold';
25
+ case 100:
26
+ case '100':
27
+ case 'ultralight':
28
+ return 'ultraLight';
29
+ case 200:
30
+ case '200':
31
+ return 'ultraLight';
32
+ case 300:
33
+ case '300':
34
+ case 'light':
35
+ return 'light';
36
+ case 400:
37
+ case '400':
38
+ case 'regular':
39
+ return 'normal';
40
+ case 500:
41
+ return 'medium';
42
+ case 600:
43
+ case '600':
44
+ case 'semibold':
45
+ return 'semibold';
46
+ case 700:
47
+ case '700':
48
+ return 'semibold';
49
+ case 800:
50
+ case '800':
51
+ return 'bold';
52
+ case 900:
53
+ case '900':
54
+ case 'heavy':
55
+ return 'heavy';
56
+ default:
57
+ return 'normal';
58
+ }
59
+ }
60
+ //# sourceMappingURL=util.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["StyleSheet","flattenStyles","rootStyle","style","flattenedStyle","flatten","fontWeight","fontWeightToNativeProp","backgroundColor","shadowOffset","width","height"],"sourceRoot":"../../src","sources":["util.ts"],"mappings":";;AAAA,SAAwBA,UAAU,QAAuB,cAAc;AAGvE,OAAO,SAASC,aAAaA,CAC3BC,SAAoB,EACpBC,KAA2B,EAC3B;EACA,MAAMC,cAAc,GAAGJ,UAAU,CAACK,OAAO,CAAC,CAACH,SAAS,EAAEC,KAAK,CAAC,CAAc;EAC1E,OAAO;IACL,GAAGC,cAAc;IACjBE,UAAU,EAAEC,sBAAsB,CAACH,cAAc,CAACE,UAAU,IAAI,QAAQ,CAAC;IACzEE,eAAe,EAAEJ,cAAc,CAACI,eAAe,GAC3CJ,cAAc,CAACI,eAAe,GAC9B,aAAa;IACjBC,YAAY,EAAEL,cAAc,CAACK,YAAY,GACrCL,cAAc,CAACK,YAAY,GAC3B;MAACC,KAAK,EAAE,CAAC;MAAEC,MAAM,EAAE;IAAC;EAC1B,CAAC;AACH;;AAEA;AACA;AACA,SAASJ,sBAAsBA,CAC7BD,UAAmC,EACjB;EAClB,QAAQA,UAAU;IAChB,KAAK,QAAQ;MACX,OAAO,QAAQ;IACjB,KAAK,MAAM;MACT,OAAO,MAAM;IACf,KAAK,GAAG;IACR,KAAK,KAAK;IACV,KAAK,YAAY;MACf,OAAO,YAAY;IACrB,KAAK,GAAG;IACR,KAAK,KAAK;MACR,OAAO,YAAY;IACrB,KAAK,GAAG;IACR,KAAK,KAAK;IACV,KAAK,OAAO;MACV,OAAO,OAAO;IAChB,KAAK,GAAG;IACR,KAAK,KAAK;IACV,KAAK,SAAS;MACZ,OAAO,QAAQ;IACjB,KAAK,GAAG;MACN,OAAO,QAAQ;IACjB,KAAK,GAAG;IACR,KAAK,KAAK;IACV,KAAK,UAAU;MACb,OAAO,UAAU;IACnB,KAAK,GAAG;IACR,KAAK,KAAK;MACR,OAAO,UAAU;IACnB,KAAK,GAAG;IACR,KAAK,KAAK;MACR,OAAO,MAAM;IACf,KAAK,GAAG;IACR,KAAK,KAAK;IACV,KAAK,OAAO;MACV,OAAO,OAAO;IAChB;MACE,OAAO,QAAQ;EACnB;AACF","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ export default function App(): import("react/jsx-runtime").JSX.Element;
2
+ //# sourceMappingURL=App.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"App.d.ts","sourceRoot":"","sources":["../../../../../example/src/App.tsx"],"names":[],"mappings":"AAaA,MAAM,CAAC,OAAO,UAAU,GAAG,4CA6jB1B"}
@@ -0,0 +1,3 @@
1
+ declare const CustomMenuExample: () => import("react/jsx-runtime").JSX.Element;
2
+ export default CustomMenuExample;
3
+ //# sourceMappingURL=CustomMenuExample.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CustomMenuExample.d.ts","sourceRoot":"","sources":["../../../../../example/src/CustomMenuExample.tsx"],"names":[],"mappings":"AAIA,QAAA,MAAM,iBAAiB,+CA4CtB,CAAA;AAgBD,eAAe,iBAAiB,CAAA"}
@@ -0,0 +1 @@
1
+ {"type":"commonjs"}
@@ -0,0 +1,28 @@
1
+ import type { ColorValue, ViewProps } from 'react-native';
2
+ import type { BubblingEventHandler, Float, Int32, WithDefault } from 'react-native/Libraries/Types/CodegenTypes';
3
+ interface TargetedEvent {
4
+ target: Int32;
5
+ }
6
+ type TextDecorationLine = 'none' | 'underline' | 'line-through';
7
+ type TextDecorationStyle = 'solid' | 'double' | 'dotted' | 'dashed';
8
+ export type NativeFontWeight = 'normal' | 'bold' | 'ultraLight' | 'light' | 'medium' | 'semibold' | 'heavy';
9
+ type FontStyle = 'normal' | 'italic';
10
+ interface NativeProps extends ViewProps {
11
+ text: string;
12
+ color?: ColorValue;
13
+ fontSize?: Float;
14
+ fontStyle?: WithDefault<FontStyle, 'normal'>;
15
+ fontWeight?: WithDefault<NativeFontWeight, 'normal'>;
16
+ fontFamily?: string;
17
+ letterSpacing?: Float;
18
+ lineHeight?: Float;
19
+ textDecorationLine?: WithDefault<TextDecorationLine, 'none'>;
20
+ textDecorationStyle?: WithDefault<TextDecorationStyle, 'solid'>;
21
+ textDecorationColor?: ColorValue;
22
+ shadowRadius?: WithDefault<Float, 0>;
23
+ onPress?: BubblingEventHandler<TargetedEvent>;
24
+ onLongPress?: BubblingEventHandler<TargetedEvent>;
25
+ }
26
+ declare const _default: import("react-native/Libraries/Utilities/codegenNativeComponent").NativeComponentType<NativeProps>;
27
+ export default _default;
28
+ //# sourceMappingURL=RNUITextViewChildNativeComponent.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RNUITextViewChildNativeComponent.d.ts","sourceRoot":"","sources":["../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a,CAAC,CAAA;IAC7C,WAAW,CAAC,EAAE,oBAAoB,CAAC,aAAa,CAAC,CAAA;CAClD;;AAED,wBAEE"}
@@ -0,0 +1,29 @@
1
+ import type { ViewProps } from 'react-native';
2
+ import type { BubblingEventHandler, Int32, WithDefault, DirectEventHandler } from 'react-native/Libraries/Types/CodegenTypes';
3
+ interface TargetedEvent {
4
+ target: Int32;
5
+ }
6
+ interface TextLayoutEvent extends TargetedEvent {
7
+ lines: string[];
8
+ }
9
+ interface CustomMenuItem {
10
+ title: string;
11
+ actionId: string;
12
+ }
13
+ interface CustomMenuActionEvent extends TargetedEvent {
14
+ actionId: string;
15
+ selectedText: string;
16
+ }
17
+ type EllipsizeMode = 'head' | 'middle' | 'tail' | 'clip';
18
+ interface NativeProps extends ViewProps {
19
+ numberOfLines?: Int32;
20
+ allowsFontScaling?: boolean;
21
+ ellipsizeMode?: WithDefault<EllipsizeMode, 'tail'>;
22
+ selectable?: boolean;
23
+ onTextLayout?: BubblingEventHandler<TextLayoutEvent>;
24
+ customMenuItems?: ReadonlyArray<CustomMenuItem>;
25
+ onCustomMenuAction?: DirectEventHandler<CustomMenuActionEvent>;
26
+ }
27
+ declare const _default: import("react-native/Libraries/Utilities/codegenNativeComponent").NativeComponentType<NativeProps>;
28
+ export default _default;
29
+ //# sourceMappingURL=RNUITextViewNativeComponent.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RNUITextViewNativeComponent.d.ts","sourceRoot":"","sources":["../../../../src/RNUITextViewNativeComponent.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAC,SAAS,EAAC,MAAM,cAAc,CAAA;AAC3C,OAAO,KAAK,EACV,oBAAoB,EACpB,KAAK,EACL,WAAW,EACX,kBAAkB,EACnB,MAAM,2CAA2C,CAAA;AAElD,UAAU,aAAa;IACrB,MAAM,EAAE,KAAK,CAAA;CACd;AAED,UAAU,eAAgB,SAAQ,aAAa;IAC7C,KAAK,EAAE,MAAM,EAAE,CAAA;CAChB;AAGD,UAAU,cAAc;IACtB,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,EAAE,MAAM,CAAA;CACjB;AAGD,UAAU,qBAAsB,SAAQ,aAAa;IACnD,QAAQ,EAAE,MAAM,CAAA;IAChB,YAAY,EAAE,MAAM,CAAA;CACrB;AAED,KAAK,aAAa,GAAG,MAAM,GAAG,QAAQ,GAAG,MAAM,GAAG,MAAM,CAAA;AAExD,UAAU,WAAY,SAAQ,SAAS;IAErC,aAAa,CAAC,EAAE,KAAK,CAAA;IACrB,iBAAiB,CAAC,EAAE,OAAO,CAAA;IAC3B,aAAa,CAAC,EAAE,WAAW,CAAC,aAAa,EAAE,MAAM,CAAC,CAAA;IAClD,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,YAAY,CAAC,EAAE,oBAAoB,CAAC,eAAe,CAAC,CAAA;IAGpD,eAAe,CAAC,EAAE,aAAa,CAAC,cAAc,CAAC,CAAA;IAC/C,kBAAkB,CAAC,EAAE,kBAAkB,CAAC,qBAAqB,CAAC,CAAA;CAC/D;;AAED,wBAEE"}
@@ -0,0 +1,17 @@
1
+ import { type TextProps } from 'react-native';
2
+ interface CustomMenuItem {
3
+ title: string;
4
+ actionId: string;
5
+ }
6
+ interface CustomMenuActionEvent {
7
+ actionId: string;
8
+ selectedText: string;
9
+ }
10
+ type ExtendedTextProps = TextProps & {
11
+ uiTextView?: boolean;
12
+ customMenuItems?: CustomMenuItem[];
13
+ onCustomMenuAction?: (event: CustomMenuActionEvent) => void;
14
+ };
15
+ export declare function UITextView(props: ExtendedTextProps): import("react/jsx-runtime").JSX.Element;
16
+ export {};
17
+ //# sourceMappingURL=Text.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Text.d.ts","sourceRoot":"","sources":["../../../../src/Text.tsx"],"names":[],"mappings":"AACA,OAAO,EAIL,KAAK,SAAS,EAEf,MAAM,cAAc,CAAA;AAGrB,UAAU,cAAc;IACtB,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,EAAE,MAAM,CAAA;CACjB;AAGD,UAAU,qBAAqB;IAC7B,QAAQ,EAAE,MAAM,CAAA;IAChB,YAAY,EAAE,MAAM,CAAA;CACrB;AAkBD,KAAK,iBAAiB,GAAG,SAAS,GAAG;IACnC,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,eAAe,CAAC,EAAE,cAAc,EAAE,CAAA;IAClC,kBAAkB,CAAC,EAAE,CAAC,KAAK,EAAE,qBAAqB,KAAK,IAAI,CAAA;CAC5D,CAAA;AAiGD,wBAAgB,UAAU,CAAC,KAAK,EAAE,iBAAiB,2CASlD"}
@@ -0,0 +1,2 @@
1
+ export * from './Text';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/index.tsx"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAA"}
@@ -0,0 +1,160 @@
1
+ import { type StyleProp, type TextStyle } from 'react-native';
2
+ import type { NativeFontWeight } from './RNUITextViewChildNativeComponent';
3
+ export declare function flattenStyles(rootStyle: TextStyle, style: StyleProp<TextStyle>): {
4
+ fontWeight: NativeFontWeight;
5
+ backgroundColor: import("react-native").ColorValue;
6
+ shadowOffset: Readonly<{
7
+ width: number;
8
+ height: number;
9
+ }>;
10
+ color?: import("react-native").ColorValue | undefined;
11
+ fontFamily?: string | undefined;
12
+ fontSize?: number | undefined;
13
+ fontStyle?: "normal" | "italic" | undefined;
14
+ letterSpacing?: number | undefined;
15
+ lineHeight?: number | undefined;
16
+ textAlign?: "auto" | "left" | "right" | "center" | "justify" | undefined;
17
+ textDecorationLine?: "none" | "underline" | "line-through" | "underline line-through" | undefined;
18
+ textDecorationStyle?: "solid" | "double" | "dotted" | "dashed" | undefined;
19
+ textDecorationColor?: import("react-native").ColorValue | undefined;
20
+ textShadowColor?: import("react-native").ColorValue | undefined;
21
+ textShadowOffset?: {
22
+ width: number;
23
+ height: number;
24
+ } | undefined;
25
+ textShadowRadius?: number | undefined;
26
+ textTransform?: "none" | "capitalize" | "uppercase" | "lowercase" | undefined;
27
+ userSelect?: "auto" | "none" | "text" | "contain" | "all" | undefined;
28
+ fontVariant?: import("react-native").FontVariant[] | undefined;
29
+ writingDirection?: "auto" | "ltr" | "rtl" | undefined;
30
+ backfaceVisibility?: "visible" | "hidden" | undefined;
31
+ borderBlockColor?: import("react-native").ColorValue | undefined;
32
+ borderBlockEndColor?: import("react-native").ColorValue | undefined;
33
+ borderBlockStartColor?: import("react-native").ColorValue | undefined;
34
+ borderBottomColor?: import("react-native").ColorValue | undefined;
35
+ borderBottomEndRadius?: import("react-native").AnimatableNumericValue | string | undefined;
36
+ borderBottomLeftRadius?: import("react-native").AnimatableNumericValue | string | undefined;
37
+ borderBottomRightRadius?: import("react-native").AnimatableNumericValue | string | undefined;
38
+ borderBottomStartRadius?: import("react-native").AnimatableNumericValue | string | undefined;
39
+ borderColor?: import("react-native").ColorValue | undefined;
40
+ borderCurve?: "circular" | "continuous" | undefined;
41
+ borderEndColor?: import("react-native").ColorValue | undefined;
42
+ borderEndEndRadius?: import("react-native").AnimatableNumericValue | string | undefined;
43
+ borderEndStartRadius?: import("react-native").AnimatableNumericValue | string | undefined;
44
+ borderLeftColor?: import("react-native").ColorValue | undefined;
45
+ borderRadius?: import("react-native").AnimatableNumericValue | string | undefined;
46
+ borderRightColor?: import("react-native").ColorValue | undefined;
47
+ borderStartColor?: import("react-native").ColorValue | undefined;
48
+ borderStartEndRadius?: import("react-native").AnimatableNumericValue | string | undefined;
49
+ borderStartStartRadius?: import("react-native").AnimatableNumericValue | string | undefined;
50
+ borderStyle?: "solid" | "dotted" | "dashed" | undefined;
51
+ borderTopColor?: import("react-native").ColorValue | undefined;
52
+ borderTopEndRadius?: import("react-native").AnimatableNumericValue | string | undefined;
53
+ borderTopLeftRadius?: import("react-native").AnimatableNumericValue | string | undefined;
54
+ borderTopRightRadius?: import("react-native").AnimatableNumericValue | string | undefined;
55
+ borderTopStartRadius?: import("react-native").AnimatableNumericValue | string | undefined;
56
+ outlineColor?: import("react-native").ColorValue | undefined;
57
+ outlineOffset?: import("react-native").AnimatableNumericValue | undefined;
58
+ outlineStyle?: "solid" | "dotted" | "dashed" | undefined;
59
+ outlineWidth?: import("react-native").AnimatableNumericValue | undefined;
60
+ opacity?: import("react-native").AnimatableNumericValue | undefined;
61
+ elevation?: number | undefined;
62
+ pointerEvents?: "box-none" | "none" | "box-only" | "auto" | undefined;
63
+ isolation?: "auto" | "isolate" | undefined;
64
+ cursor?: import("react-native").CursorValue | undefined;
65
+ boxShadow?: ReadonlyArray<import("react-native").BoxShadowValue> | string | undefined;
66
+ filter?: ReadonlyArray<import("react-native").FilterFunction> | string | undefined;
67
+ mixBlendMode?: import("react-native").BlendMode | undefined;
68
+ experimental_backgroundImage?: ReadonlyArray<import("react-native").GradientValue> | string | undefined;
69
+ alignContent?: "flex-start" | "flex-end" | "center" | "stretch" | "space-between" | "space-around" | "space-evenly" | undefined;
70
+ alignItems?: import("react-native").FlexAlignType | undefined;
71
+ alignSelf?: "auto" | import("react-native").FlexAlignType | undefined;
72
+ aspectRatio?: number | string | undefined;
73
+ borderBottomWidth?: number | undefined;
74
+ borderEndWidth?: number | undefined;
75
+ borderLeftWidth?: number | undefined;
76
+ borderRightWidth?: number | undefined;
77
+ borderStartWidth?: number | undefined;
78
+ borderTopWidth?: number | undefined;
79
+ borderWidth?: number | undefined;
80
+ bottom?: import("react-native").DimensionValue | undefined;
81
+ boxSizing?: "border-box" | "content-box" | undefined;
82
+ display?: "none" | "flex" | "contents" | undefined;
83
+ end?: import("react-native").DimensionValue | undefined;
84
+ flex?: number | undefined;
85
+ flexBasis?: import("react-native").DimensionValue | undefined;
86
+ flexDirection?: "row" | "column" | "row-reverse" | "column-reverse" | undefined;
87
+ rowGap?: number | string | undefined;
88
+ gap?: number | string | undefined;
89
+ columnGap?: number | string | undefined;
90
+ flexGrow?: number | undefined;
91
+ flexShrink?: number | undefined;
92
+ flexWrap?: "wrap" | "nowrap" | "wrap-reverse" | undefined;
93
+ height?: import("react-native").DimensionValue | undefined;
94
+ justifyContent?: "flex-start" | "flex-end" | "center" | "space-between" | "space-around" | "space-evenly" | undefined;
95
+ left?: import("react-native").DimensionValue | undefined;
96
+ margin?: import("react-native").DimensionValue | undefined;
97
+ marginBottom?: import("react-native").DimensionValue | undefined;
98
+ marginEnd?: import("react-native").DimensionValue | undefined;
99
+ marginHorizontal?: import("react-native").DimensionValue | undefined;
100
+ marginLeft?: import("react-native").DimensionValue | undefined;
101
+ marginRight?: import("react-native").DimensionValue | undefined;
102
+ marginStart?: import("react-native").DimensionValue | undefined;
103
+ marginTop?: import("react-native").DimensionValue | undefined;
104
+ marginVertical?: import("react-native").DimensionValue | undefined;
105
+ maxHeight?: import("react-native").DimensionValue | undefined;
106
+ maxWidth?: import("react-native").DimensionValue | undefined;
107
+ minHeight?: import("react-native").DimensionValue | undefined;
108
+ minWidth?: import("react-native").DimensionValue | undefined;
109
+ overflow?: "visible" | "hidden" | "scroll" | undefined;
110
+ padding?: import("react-native").DimensionValue | undefined;
111
+ paddingBottom?: import("react-native").DimensionValue | undefined;
112
+ paddingEnd?: import("react-native").DimensionValue | undefined;
113
+ paddingHorizontal?: import("react-native").DimensionValue | undefined;
114
+ paddingLeft?: import("react-native").DimensionValue | undefined;
115
+ paddingRight?: import("react-native").DimensionValue | undefined;
116
+ paddingStart?: import("react-native").DimensionValue | undefined;
117
+ paddingTop?: import("react-native").DimensionValue | undefined;
118
+ paddingVertical?: import("react-native").DimensionValue | undefined;
119
+ position?: "absolute" | "relative" | "static" | undefined;
120
+ right?: import("react-native").DimensionValue | undefined;
121
+ start?: import("react-native").DimensionValue | undefined;
122
+ top?: import("react-native").DimensionValue | undefined;
123
+ width?: import("react-native").DimensionValue | undefined;
124
+ zIndex?: number | undefined;
125
+ direction?: "inherit" | "ltr" | "rtl" | undefined;
126
+ inset?: import("react-native").DimensionValue | undefined;
127
+ insetBlock?: import("react-native").DimensionValue | undefined;
128
+ insetBlockEnd?: import("react-native").DimensionValue | undefined;
129
+ insetBlockStart?: import("react-native").DimensionValue | undefined;
130
+ insetInline?: import("react-native").DimensionValue | undefined;
131
+ insetInlineEnd?: import("react-native").DimensionValue | undefined;
132
+ insetInlineStart?: import("react-native").DimensionValue | undefined;
133
+ marginBlock?: import("react-native").DimensionValue | undefined;
134
+ marginBlockEnd?: import("react-native").DimensionValue | undefined;
135
+ marginBlockStart?: import("react-native").DimensionValue | undefined;
136
+ marginInline?: import("react-native").DimensionValue | undefined;
137
+ marginInlineEnd?: import("react-native").DimensionValue | undefined;
138
+ marginInlineStart?: import("react-native").DimensionValue | undefined;
139
+ paddingBlock?: import("react-native").DimensionValue | undefined;
140
+ paddingBlockEnd?: import("react-native").DimensionValue | undefined;
141
+ paddingBlockStart?: import("react-native").DimensionValue | undefined;
142
+ paddingInline?: import("react-native").DimensionValue | undefined;
143
+ paddingInlineEnd?: import("react-native").DimensionValue | undefined;
144
+ paddingInlineStart?: import("react-native").DimensionValue | undefined;
145
+ shadowColor?: import("react-native").ColorValue | undefined;
146
+ shadowOpacity?: import("react-native").AnimatableNumericValue | undefined;
147
+ shadowRadius?: number | undefined;
148
+ transform?: Readonly<import("react-native").MaximumOneOf<import("react-native").PerspectiveTransform & import("react-native").RotateTransform & import("react-native").RotateXTransform & import("react-native").RotateYTransform & import("react-native").RotateZTransform & import("react-native").ScaleTransform & import("react-native").ScaleXTransform & import("react-native").ScaleYTransform & import("react-native").TranslateXTransform & import("react-native").TranslateYTransform & import("react-native").SkewXTransform & import("react-native").SkewYTransform & import("react-native").MatrixTransform>[]> | string | undefined;
149
+ transformOrigin?: Array<string | number> | string | undefined;
150
+ transformMatrix?: Array<number> | undefined;
151
+ rotation?: import("react-native").AnimatableNumericValue | undefined;
152
+ scaleX?: import("react-native").AnimatableNumericValue | undefined;
153
+ scaleY?: import("react-native").AnimatableNumericValue | undefined;
154
+ translateX?: import("react-native").AnimatableNumericValue | undefined;
155
+ translateY?: import("react-native").AnimatableNumericValue | undefined;
156
+ textAlignVertical?: "auto" | "top" | "bottom" | "center" | undefined;
157
+ verticalAlign?: "auto" | "top" | "bottom" | "middle" | undefined;
158
+ includeFontPadding?: boolean | undefined;
159
+ };
160
+ //# sourceMappingURL=util.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../../../../src/util.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,KAAK,SAAS,EAAc,KAAK,SAAS,EAAC,MAAM,cAAc,CAAA;AACvE,OAAO,KAAK,EAAC,gBAAgB,EAAC,MAAM,oCAAoC,CAAA;AAExE,wBAAgB,aAAa,CAC3B,SAAS,EAAE,SAAS,EACpB,KAAK,EAAE,SAAS,CAAC,SAAS,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAa5B"}
@@ -0,0 +1,2 @@
1
+ export default function App(): import("react/jsx-runtime").JSX.Element;
2
+ //# sourceMappingURL=App.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"App.d.ts","sourceRoot":"","sources":["../../../../../example/src/App.tsx"],"names":[],"mappings":"AAaA,MAAM,CAAC,OAAO,UAAU,GAAG,4CA6jB1B"}
@@ -0,0 +1,3 @@
1
+ declare const CustomMenuExample: () => import("react/jsx-runtime").JSX.Element;
2
+ export default CustomMenuExample;
3
+ //# sourceMappingURL=CustomMenuExample.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CustomMenuExample.d.ts","sourceRoot":"","sources":["../../../../../example/src/CustomMenuExample.tsx"],"names":[],"mappings":"AAIA,QAAA,MAAM,iBAAiB,+CA4CtB,CAAA;AAgBD,eAAe,iBAAiB,CAAA"}
@@ -0,0 +1 @@
1
+ {"type":"module"}
@@ -0,0 +1,28 @@
1
+ import type { ColorValue, ViewProps } from 'react-native';
2
+ import type { BubblingEventHandler, Float, Int32, WithDefault } from 'react-native/Libraries/Types/CodegenTypes';
3
+ interface TargetedEvent {
4
+ target: Int32;
5
+ }
6
+ type TextDecorationLine = 'none' | 'underline' | 'line-through';
7
+ type TextDecorationStyle = 'solid' | 'double' | 'dotted' | 'dashed';
8
+ export type NativeFontWeight = 'normal' | 'bold' | 'ultraLight' | 'light' | 'medium' | 'semibold' | 'heavy';
9
+ type FontStyle = 'normal' | 'italic';
10
+ interface NativeProps extends ViewProps {
11
+ text: string;
12
+ color?: ColorValue;
13
+ fontSize?: Float;
14
+ fontStyle?: WithDefault<FontStyle, 'normal'>;
15
+ fontWeight?: WithDefault<NativeFontWeight, 'normal'>;
16
+ fontFamily?: string;
17
+ letterSpacing?: Float;
18
+ lineHeight?: Float;
19
+ textDecorationLine?: WithDefault<TextDecorationLine, 'none'>;
20
+ textDecorationStyle?: WithDefault<TextDecorationStyle, 'solid'>;
21
+ textDecorationColor?: ColorValue;
22
+ shadowRadius?: WithDefault<Float, 0>;
23
+ onPress?: BubblingEventHandler<TargetedEvent>;
24
+ onLongPress?: BubblingEventHandler<TargetedEvent>;
25
+ }
26
+ declare const _default: import("react-native/Libraries/Utilities/codegenNativeComponent").NativeComponentType<NativeProps>;
27
+ export default _default;
28
+ //# sourceMappingURL=RNUITextViewChildNativeComponent.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RNUITextViewChildNativeComponent.d.ts","sourceRoot":"","sources":["../../../../src/RNUITextViewChildNativeComponent.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAC,UAAU,EAAE,SAAS,EAAC,MAAM,cAAc,CAAA;AACvD,OAAO,KAAK,EACV,oBAAoB,EACpB,KAAK,EACL,KAAK,EACL,WAAW,EACZ,MAAM,2CAA2C,CAAA;AAElD,UAAU,aAAa;IACrB,MAAM,EAAE,KAAK,CAAA;CACd;AAED,KAAK,kBAAkB,GAAG,MAAM,GAAG,WAAW,GAAG,cAAc,CAAA;AAE/D,KAAK,mBAAmB,GAAG,OAAO,GAAG,QAAQ,GAAG,QAAQ,GAAG,QAAQ,CAAA;AAEnE,MAAM,MAAM,gBAAgB,GACxB,QAAQ,GACR,MAAM,GACN,YAAY,GACZ,OAAO,GACP,QAAQ,GACR,UAAU,GACV,OAAO,CAAA;AAEX,KAAK,SAAS,GAAG,QAAQ,GAAG,QAAQ,CAAA;AAEpC,UAAU,WAAY,SAAQ,SAAS;IACrC,IAAI,EAAE,MAAM,CAAA;IACZ,KAAK,CAAC,EAAE,UAAU,CAAA;IAClB,QAAQ,CAAC,EAAE,KAAK,CAAA;IAChB,SAAS,CAAC,EAAE,WAAW,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAA;IAC5C,UAAU,CAAC,EAAE,WAAW,CAAC,gBAAgB,EAAE,QAAQ,CAAC,CAAA;IACpD,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,aAAa,CAAC,EAAE,KAAK,CAAA;IACrB,UAAU,CAAC,EAAE,KAAK,CAAA;IAClB,kBAAkB,CAAC,EAAE,WAAW,CAAC,kBAAkB,EAAE,MAAM,CAAC,CAAA;IAC5D,mBAAmB,CAAC,EAAE,WAAW,CAAC,mBAAmB,EAAE,OAAO,CAAC,CAAA;IAC/D,mBAAmB,CAAC,EAAE,UAAU,CAAA;IAChC,YAAY,CAAC,EAAE,WAAW,CAAC,KAAK,EAAE,CAAC,CAAC,CAAA;IACpC,OAAO,CAAC,EAAE,oBAAoB,CAAC,aAAa,CAAC,CAAA;IAC7C,WAAW,CAAC,EAAE,oBAAoB,CAAC,aAAa,CAAC,CAAA;CAClD;;AAED,wBAEE"}
@@ -0,0 +1,29 @@
1
+ import type { ViewProps } from 'react-native';
2
+ import type { BubblingEventHandler, Int32, WithDefault, DirectEventHandler } from 'react-native/Libraries/Types/CodegenTypes';
3
+ interface TargetedEvent {
4
+ target: Int32;
5
+ }
6
+ interface TextLayoutEvent extends TargetedEvent {
7
+ lines: string[];
8
+ }
9
+ interface CustomMenuItem {
10
+ title: string;
11
+ actionId: string;
12
+ }
13
+ interface CustomMenuActionEvent extends TargetedEvent {
14
+ actionId: string;
15
+ selectedText: string;
16
+ }
17
+ type EllipsizeMode = 'head' | 'middle' | 'tail' | 'clip';
18
+ interface NativeProps extends ViewProps {
19
+ numberOfLines?: Int32;
20
+ allowsFontScaling?: boolean;
21
+ ellipsizeMode?: WithDefault<EllipsizeMode, 'tail'>;
22
+ selectable?: boolean;
23
+ onTextLayout?: BubblingEventHandler<TextLayoutEvent>;
24
+ customMenuItems?: ReadonlyArray<CustomMenuItem>;
25
+ onCustomMenuAction?: DirectEventHandler<CustomMenuActionEvent>;
26
+ }
27
+ declare const _default: import("react-native/Libraries/Utilities/codegenNativeComponent").NativeComponentType<NativeProps>;
28
+ export default _default;
29
+ //# sourceMappingURL=RNUITextViewNativeComponent.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RNUITextViewNativeComponent.d.ts","sourceRoot":"","sources":["../../../../src/RNUITextViewNativeComponent.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAC,SAAS,EAAC,MAAM,cAAc,CAAA;AAC3C,OAAO,KAAK,EACV,oBAAoB,EACpB,KAAK,EACL,WAAW,EACX,kBAAkB,EACnB,MAAM,2CAA2C,CAAA;AAElD,UAAU,aAAa;IACrB,MAAM,EAAE,KAAK,CAAA;CACd;AAED,UAAU,eAAgB,SAAQ,aAAa;IAC7C,KAAK,EAAE,MAAM,EAAE,CAAA;CAChB;AAGD,UAAU,cAAc;IACtB,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,EAAE,MAAM,CAAA;CACjB;AAGD,UAAU,qBAAsB,SAAQ,aAAa;IACnD,QAAQ,EAAE,MAAM,CAAA;IAChB,YAAY,EAAE,MAAM,CAAA;CACrB;AAED,KAAK,aAAa,GAAG,MAAM,GAAG,QAAQ,GAAG,MAAM,GAAG,MAAM,CAAA;AAExD,UAAU,WAAY,SAAQ,SAAS;IAErC,aAAa,CAAC,EAAE,KAAK,CAAA;IACrB,iBAAiB,CAAC,EAAE,OAAO,CAAA;IAC3B,aAAa,CAAC,EAAE,WAAW,CAAC,aAAa,EAAE,MAAM,CAAC,CAAA;IAClD,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,YAAY,CAAC,EAAE,oBAAoB,CAAC,eAAe,CAAC,CAAA;IAGpD,eAAe,CAAC,EAAE,aAAa,CAAC,cAAc,CAAC,CAAA;IAC/C,kBAAkB,CAAC,EAAE,kBAAkB,CAAC,qBAAqB,CAAC,CAAA;CAC/D;;AAED,wBAEE"}
@@ -0,0 +1,17 @@
1
+ import { type TextProps } from 'react-native';
2
+ interface CustomMenuItem {
3
+ title: string;
4
+ actionId: string;
5
+ }
6
+ interface CustomMenuActionEvent {
7
+ actionId: string;
8
+ selectedText: string;
9
+ }
10
+ type ExtendedTextProps = TextProps & {
11
+ uiTextView?: boolean;
12
+ customMenuItems?: CustomMenuItem[];
13
+ onCustomMenuAction?: (event: CustomMenuActionEvent) => void;
14
+ };
15
+ export declare function UITextView(props: ExtendedTextProps): import("react/jsx-runtime").JSX.Element;
16
+ export {};
17
+ //# sourceMappingURL=Text.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Text.d.ts","sourceRoot":"","sources":["../../../../src/Text.tsx"],"names":[],"mappings":"AACA,OAAO,EAIL,KAAK,SAAS,EAEf,MAAM,cAAc,CAAA;AAGrB,UAAU,cAAc;IACtB,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,EAAE,MAAM,CAAA;CACjB;AAGD,UAAU,qBAAqB;IAC7B,QAAQ,EAAE,MAAM,CAAA;IAChB,YAAY,EAAE,MAAM,CAAA;CACrB;AAkBD,KAAK,iBAAiB,GAAG,SAAS,GAAG;IACnC,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,eAAe,CAAC,EAAE,cAAc,EAAE,CAAA;IAClC,kBAAkB,CAAC,EAAE,CAAC,KAAK,EAAE,qBAAqB,KAAK,IAAI,CAAA;CAC5D,CAAA;AAiGD,wBAAgB,UAAU,CAAC,KAAK,EAAE,iBAAiB,2CASlD"}
@@ -0,0 +1,2 @@
1
+ export * from './Text';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/index.tsx"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAA"}