react-native-advanced-text 0.1.15 → 0.1.17
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/android/src/main/java/com/advancedtext/AdvancedTextView.kt +303 -296
- package/android/src/main/java/com/advancedtext/AdvancedTextViewManager.kt +95 -101
- package/lib/module/AdvancedText.js +2 -6
- package/lib/module/AdvancedText.js.map +1 -1
- package/lib/module/AdvancedTextViewNativeComponent.ts +4 -6
- package/lib/typescript/src/AdvancedText.d.ts +0 -2
- package/lib/typescript/src/AdvancedText.d.ts.map +1 -1
- package/lib/typescript/src/AdvancedTextViewNativeComponent.d.ts +2 -5
- package/lib/typescript/src/AdvancedTextViewNativeComponent.d.ts.map +1 -1
- package/package.json +175 -175
- package/src/AdvancedText.tsx +1 -6
- package/src/AdvancedTextViewNativeComponent.ts +4 -6
|
@@ -1,101 +1,95 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
import
|
|
6
|
-
import com.facebook.react.
|
|
7
|
-
import com.facebook.react.
|
|
8
|
-
import com.facebook.react.uimanager.
|
|
9
|
-
import com.facebook.react.uimanager.
|
|
10
|
-
import com.facebook.react.
|
|
11
|
-
import com.facebook.react.
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
companion object {
|
|
99
|
-
const val NAME = "AdvancedTextView"
|
|
100
|
-
}
|
|
101
|
-
}
|
|
1
|
+
// File: AdvancedTextViewManager.kt
|
|
2
|
+
// This should be the ONLY content in this file
|
|
3
|
+
package com.advancedtext
|
|
4
|
+
|
|
5
|
+
import android.view.ViewGroup
|
|
6
|
+
import com.facebook.react.bridge.ReadableArray
|
|
7
|
+
import com.facebook.react.module.annotations.ReactModule
|
|
8
|
+
import com.facebook.react.uimanager.SimpleViewManager
|
|
9
|
+
import com.facebook.react.uimanager.ThemedReactContext
|
|
10
|
+
import com.facebook.react.uimanager.ViewManagerDelegate
|
|
11
|
+
import com.facebook.react.uimanager.annotations.ReactProp
|
|
12
|
+
import com.facebook.react.viewmanagers.AdvancedTextViewManagerInterface
|
|
13
|
+
import com.facebook.react.viewmanagers.AdvancedTextViewManagerDelegate
|
|
14
|
+
|
|
15
|
+
@ReactModule(name = AdvancedTextViewManager.NAME)
|
|
16
|
+
class AdvancedTextViewManager : SimpleViewManager<AdvancedTextView>(),
|
|
17
|
+
AdvancedTextViewManagerInterface<AdvancedTextView> {
|
|
18
|
+
private val mDelegate: ViewManagerDelegate<AdvancedTextView>
|
|
19
|
+
|
|
20
|
+
init {
|
|
21
|
+
mDelegate = AdvancedTextViewManagerDelegate(this)
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
override fun getDelegate(): ViewManagerDelegate<AdvancedTextView>? {
|
|
25
|
+
return mDelegate
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
override fun getName(): String {
|
|
29
|
+
return NAME
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
public override fun createViewInstance(context: ThemedReactContext): AdvancedTextView {
|
|
33
|
+
val view = AdvancedTextView(context)
|
|
34
|
+
// Set default layout params to ensure the view is visible
|
|
35
|
+
view.layoutParams = ViewGroup.LayoutParams(
|
|
36
|
+
ViewGroup.LayoutParams.MATCH_PARENT,
|
|
37
|
+
ViewGroup.LayoutParams.WRAP_CONTENT
|
|
38
|
+
)
|
|
39
|
+
return view
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
@ReactProp(name = "text")
|
|
43
|
+
override fun setText(view: AdvancedTextView?, text: String?) {
|
|
44
|
+
view?.setAdvancedText(text ?: "")
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
@ReactProp(name = "highlightedWords")
|
|
48
|
+
override fun setHighlightedWords(view: AdvancedTextView?, highlightedWords: ReadableArray?) {
|
|
49
|
+
val words = mutableListOf<HighlightedWord>()
|
|
50
|
+
highlightedWords?.let {
|
|
51
|
+
for (i in 0 until it.size()) {
|
|
52
|
+
val map = it.getMap(i)
|
|
53
|
+
map?.let { wordMap ->
|
|
54
|
+
words.add(
|
|
55
|
+
HighlightedWord(
|
|
56
|
+
index = wordMap.getInt("index"),
|
|
57
|
+
highlightColor = wordMap.getString("highlightColor") ?: "#FFFF00"
|
|
58
|
+
)
|
|
59
|
+
)
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
view?.setHighlightedWords(words)
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
@ReactProp(name = "menuOptions")
|
|
67
|
+
override fun setMenuOptions(view: AdvancedTextView?, menuOptions: ReadableArray?) {
|
|
68
|
+
val options = mutableListOf<String>()
|
|
69
|
+
menuOptions?.let {
|
|
70
|
+
for (i in 0 until it.size()) {
|
|
71
|
+
it.getString(i)?.let { option ->
|
|
72
|
+
options.add(option)
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
view?.setMenuOptions(options)
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
@ReactProp(name = "indicatorWordIndex")
|
|
80
|
+
override fun setIndicatorWordIndex(view: AdvancedTextView?, index: Int) {
|
|
81
|
+
view?.setIndicatorWordIndex(index)
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
// Add this method to register custom events
|
|
85
|
+
override fun getExportedCustomDirectEventTypeConstants(): Map<String, Any> {
|
|
86
|
+
return mapOf(
|
|
87
|
+
"onWordPress" to mapOf("registrationName" to "onWordPress"),
|
|
88
|
+
"onSelection" to mapOf("registrationName" to "onSelection")
|
|
89
|
+
)
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
companion object {
|
|
93
|
+
const val NAME = "AdvancedTextView"
|
|
94
|
+
}
|
|
95
|
+
}
|
|
@@ -8,9 +8,7 @@ export const AdvancedText = ({
|
|
|
8
8
|
menuOptions,
|
|
9
9
|
onWordPress,
|
|
10
10
|
onSelection,
|
|
11
|
-
indicatorWordIndex
|
|
12
|
-
fontSize,
|
|
13
|
-
color
|
|
11
|
+
indicatorWordIndex
|
|
14
12
|
}) => {
|
|
15
13
|
return /*#__PURE__*/_jsx(AdvancedTextViewNativeComponent, {
|
|
16
14
|
text: text,
|
|
@@ -18,9 +16,7 @@ export const AdvancedText = ({
|
|
|
18
16
|
menuOptions: menuOptions,
|
|
19
17
|
onWordPress: onWordPress,
|
|
20
18
|
onSelection: onSelection,
|
|
21
|
-
indicatorWordIndex: indicatorWordIndex
|
|
22
|
-
fontSize: fontSize,
|
|
23
|
-
color: color
|
|
19
|
+
indicatorWordIndex: indicatorWordIndex
|
|
24
20
|
});
|
|
25
21
|
};
|
|
26
22
|
//# sourceMappingURL=AdvancedText.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["AdvancedTextViewNativeComponent","jsx","_jsx","AdvancedText","text","highlightedWords","menuOptions","onWordPress","onSelection","indicatorWordIndex"
|
|
1
|
+
{"version":3,"names":["AdvancedTextViewNativeComponent","jsx","_jsx","AdvancedText","text","highlightedWords","menuOptions","onWordPress","onSelection","indicatorWordIndex"],"sourceRoot":"..\\..\\src","sources":["AdvancedText.tsx"],"mappings":";;AACA,OAAOA,+BAA+B,MAAM,mCAAmC;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAqBhF,OAAO,MAAMC,YAAmC,GAAGA,CAAC;EAClDC,IAAI;EACJC,gBAAgB;EAChBC,WAAW;EACXC,WAAW;EACXC,WAAW;EACXC;AACF,CAAC,KAAK;EACJ,oBACEP,IAAA,CAACF,+BAA+B;IAC9BI,IAAI,EAAEA,IAAK;IACXC,gBAAgB,EAAEA,gBAAiB;IACnCC,WAAW,EAAEA,WAAY;IACzBC,WAAW,EAAEA,WAAY;IACzBC,WAAW,EAAEA,WAAY;IACzBC,kBAAkB,EAAEA;EAAmB,CACxC,CAAC;AAEN,CAAC","ignoreList":[]}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { codegenNativeComponent } from 'react-native';
|
|
2
1
|
import type { ViewProps } from 'react-native';
|
|
2
|
+
import { codegenNativeComponent } from 'react-native';
|
|
3
3
|
// @ts-ignore
|
|
4
4
|
// eslint-disable-next-line prettier/prettier
|
|
5
|
-
import type { DirectEventHandler, Int32
|
|
5
|
+
import type { DirectEventHandler, Int32 } from 'react-native/Libraries/Types/CodegenTypes';
|
|
6
6
|
|
|
7
7
|
interface HighlightedWord {
|
|
8
8
|
index: Int32;
|
|
@@ -11,12 +11,10 @@ interface HighlightedWord {
|
|
|
11
11
|
|
|
12
12
|
interface NativeProps extends ViewProps {
|
|
13
13
|
text: string;
|
|
14
|
-
fontSize?: Float;
|
|
15
|
-
color?: string;
|
|
16
14
|
highlightedWords?: ReadonlyArray<HighlightedWord>;
|
|
17
15
|
menuOptions?: ReadonlyArray<string>;
|
|
18
|
-
onWordPress?: DirectEventHandler<{ word: string
|
|
19
|
-
onSelection?: DirectEventHandler<{ selectedText: string;
|
|
16
|
+
onWordPress?: DirectEventHandler<{ word: string }>;
|
|
17
|
+
onSelection?: DirectEventHandler<{ selectedText: string; eventType: string }>;
|
|
20
18
|
indicatorWordIndex?: Int32;
|
|
21
19
|
}
|
|
22
20
|
|
|
@@ -6,8 +6,6 @@ interface HighlightedWord {
|
|
|
6
6
|
interface NativeProps extends ViewProps {
|
|
7
7
|
text: string;
|
|
8
8
|
highlightedWords?: ReadonlyArray<HighlightedWord>;
|
|
9
|
-
fontSize?: number;
|
|
10
|
-
color?: string;
|
|
11
9
|
menuOptions?: ReadonlyArray<string>;
|
|
12
10
|
onWordPress?: (event: NativeSyntheticEvent<{
|
|
13
11
|
word: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AdvancedText.d.ts","sourceRoot":"","sources":["../../../src/AdvancedText.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,oBAAoB,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAGpE,UAAU,eAAe;IACvB,KAAK,EAAE,MAAM,CAAC;IACd,cAAc,EAAE,MAAM,CAAC;CACxB;AAED,UAAU,WAAY,SAAQ,SAAS;IACrC,IAAI,EAAE,MAAM,CAAC;IACb,gBAAgB,CAAC,EAAE,aAAa,CAAC,eAAe,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"AdvancedText.d.ts","sourceRoot":"","sources":["../../../src/AdvancedText.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,oBAAoB,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAGpE,UAAU,eAAe;IACvB,KAAK,EAAE,MAAM,CAAC;IACd,cAAc,EAAE,MAAM,CAAC;CACxB;AAED,UAAU,WAAY,SAAQ,SAAS;IACrC,IAAI,EAAE,MAAM,CAAC;IACb,gBAAgB,CAAC,EAAE,aAAa,CAAC,eAAe,CAAC,CAAC;IAElD,WAAW,CAAC,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;IACpC,WAAW,CAAC,EAAE,CACZ,KAAK,EAAE,oBAAoB,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC,KACzD,IAAI,CAAC;IACV,WAAW,CAAC,EAAE,CACZ,KAAK,EAAE,oBAAoB,CAAC;QAAE,YAAY,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC,KACjE,IAAI,CAAC;IACV,kBAAkB,CAAC,EAAE,MAAM,CAAC;CAC7B;AAED,eAAO,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC,WAAW,CAkB9C,CAAC"}
|
|
@@ -1,22 +1,19 @@
|
|
|
1
1
|
import type { ViewProps } from 'react-native';
|
|
2
|
-
import type { DirectEventHandler, Int32
|
|
2
|
+
import type { DirectEventHandler, Int32 } from 'react-native/Libraries/Types/CodegenTypes';
|
|
3
3
|
interface HighlightedWord {
|
|
4
4
|
index: Int32;
|
|
5
5
|
highlightColor: string;
|
|
6
6
|
}
|
|
7
7
|
interface NativeProps extends ViewProps {
|
|
8
8
|
text: string;
|
|
9
|
-
fontSize?: Float;
|
|
10
|
-
color?: string;
|
|
11
9
|
highlightedWords?: ReadonlyArray<HighlightedWord>;
|
|
12
10
|
menuOptions?: ReadonlyArray<string>;
|
|
13
11
|
onWordPress?: DirectEventHandler<{
|
|
14
12
|
word: string;
|
|
15
|
-
index: Int32;
|
|
16
13
|
}>;
|
|
17
14
|
onSelection?: DirectEventHandler<{
|
|
18
15
|
selectedText: string;
|
|
19
|
-
|
|
16
|
+
eventType: string;
|
|
20
17
|
}>;
|
|
21
18
|
indicatorWordIndex?: Int32;
|
|
22
19
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AdvancedTextViewNativeComponent.d.ts","sourceRoot":"","sources":["../../../src/AdvancedTextViewNativeComponent.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"AdvancedTextViewNativeComponent.d.ts","sourceRoot":"","sources":["../../../src/AdvancedTextViewNativeComponent.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAI9C,OAAO,KAAK,EAAE,kBAAkB,EAAE,KAAK,EAAE,MAAM,2CAA2C,CAAC;AAE3F,UAAU,eAAe;IACvB,KAAK,EAAE,KAAK,CAAC;IACb,cAAc,EAAE,MAAM,CAAC;CACxB;AAED,UAAU,WAAY,SAAQ,SAAS;IACrC,IAAI,EAAE,MAAM,CAAC;IACb,gBAAgB,CAAC,EAAE,aAAa,CAAC,eAAe,CAAC,CAAC;IAClD,WAAW,CAAC,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;IACpC,WAAW,CAAC,EAAE,kBAAkB,CAAC;QAAE,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;IACnD,WAAW,CAAC,EAAE,kBAAkB,CAAC;QAAE,YAAY,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;IAC9E,kBAAkB,CAAC,EAAE,KAAK,CAAC;CAC5B;;AAED,wBAAuE"}
|
package/package.json
CHANGED
|
@@ -1,175 +1,175 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "react-native-advanced-text",
|
|
3
|
-
"version": "0.1.
|
|
4
|
-
"description": " Advanced text component for React Native with custom select options.",
|
|
5
|
-
"main": "./lib/module/index.js",
|
|
6
|
-
"types": "./lib/typescript/src/index.d.ts",
|
|
7
|
-
"exports": {
|
|
8
|
-
".": {
|
|
9
|
-
"source": "./src/index.tsx",
|
|
10
|
-
"types": "./lib/typescript/src/index.d.ts",
|
|
11
|
-
"default": "./lib/module/index.js"
|
|
12
|
-
},
|
|
13
|
-
"./package.json": "./package.json"
|
|
14
|
-
},
|
|
15
|
-
"files": [
|
|
16
|
-
"src",
|
|
17
|
-
"lib",
|
|
18
|
-
"android",
|
|
19
|
-
"ios",
|
|
20
|
-
"cpp",
|
|
21
|
-
"*.podspec",
|
|
22
|
-
"react-native.config.js",
|
|
23
|
-
"!ios/build",
|
|
24
|
-
"!android/build",
|
|
25
|
-
"!android/gradle",
|
|
26
|
-
"!android/gradlew",
|
|
27
|
-
"!android/gradlew.bat",
|
|
28
|
-
"!android/local.properties",
|
|
29
|
-
"!**/__tests__",
|
|
30
|
-
"!**/__fixtures__",
|
|
31
|
-
"!**/__mocks__",
|
|
32
|
-
"!**/.*"
|
|
33
|
-
],
|
|
34
|
-
"scripts": {
|
|
35
|
-
"example": "yarn workspace react-native-advanced-text-example",
|
|
36
|
-
"clean": "del-cli android/build example/android/build example/android/app/build example/ios/build lib",
|
|
37
|
-
"prepare": "bob build",
|
|
38
|
-
"typecheck": "tsc",
|
|
39
|
-
"lint": "eslint \"**/*.{js,ts,tsx}\"",
|
|
40
|
-
"release": "release-it --only-version",
|
|
41
|
-
"test": "jest"
|
|
42
|
-
},
|
|
43
|
-
"keywords": [
|
|
44
|
-
"react-native",
|
|
45
|
-
"ios",
|
|
46
|
-
"android"
|
|
47
|
-
],
|
|
48
|
-
"repository": {
|
|
49
|
-
"type": "git",
|
|
50
|
-
"url": "git+https://github.com/AminAllahham/react-native-advanced-text.git"
|
|
51
|
-
},
|
|
52
|
-
"author": "Amin Al-lahham <amin.allahham9@gmail.com> (https://github.com/AminAllahham)",
|
|
53
|
-
"license": "MIT",
|
|
54
|
-
"bugs": {
|
|
55
|
-
"url": "https://github.com/AminAllahham/react-native-advanced-text/issues"
|
|
56
|
-
},
|
|
57
|
-
"homepage": "https://github.com/AminAllahham/react-native-advanced-text#readme",
|
|
58
|
-
"publishConfig": {
|
|
59
|
-
"registry": "https://registry.npmjs.org/"
|
|
60
|
-
},
|
|
61
|
-
"devDependencies": {
|
|
62
|
-
"@commitlint/config-conventional": "^19.8.1",
|
|
63
|
-
"@eslint/compat": "^1.3.2",
|
|
64
|
-
"@eslint/eslintrc": "^3.3.1",
|
|
65
|
-
"@eslint/js": "^9.35.0",
|
|
66
|
-
"@react-native-community/cli": "20.0.1",
|
|
67
|
-
"@react-native/babel-preset": "0.81.1",
|
|
68
|
-
"@react-native/eslint-config": "^0.81.1",
|
|
69
|
-
"@release-it/conventional-changelog": "^10.0.1",
|
|
70
|
-
"@types/jest": "^29.5.14",
|
|
71
|
-
"@types/react": "^19.1.0",
|
|
72
|
-
"commitlint": "^19.8.1",
|
|
73
|
-
"del-cli": "^6.0.0",
|
|
74
|
-
"eslint": "^9.35.0",
|
|
75
|
-
"eslint-config-prettier": "^10.1.8",
|
|
76
|
-
"eslint-plugin-prettier": "^5.5.4",
|
|
77
|
-
"jest": "^29.7.0",
|
|
78
|
-
"lefthook": "^2.0.3",
|
|
79
|
-
"prettier": "^2.8.8",
|
|
80
|
-
"react": "19.1.0",
|
|
81
|
-
"react-native": "0.81.1",
|
|
82
|
-
"react-native-builder-bob": "^0.40.16",
|
|
83
|
-
"release-it": "^19.0.4",
|
|
84
|
-
"turbo": "^2.5.6",
|
|
85
|
-
"typescript": "^5.9.2"
|
|
86
|
-
},
|
|
87
|
-
"peerDependencies": {
|
|
88
|
-
"react": "*",
|
|
89
|
-
"react-native": "*"
|
|
90
|
-
},
|
|
91
|
-
"workspaces": [
|
|
92
|
-
"example"
|
|
93
|
-
],
|
|
94
|
-
"packageManager": "yarn@4.11.0",
|
|
95
|
-
"react-native-builder-bob": {
|
|
96
|
-
"source": "src",
|
|
97
|
-
"output": "lib",
|
|
98
|
-
"targets": [
|
|
99
|
-
[
|
|
100
|
-
"module",
|
|
101
|
-
{
|
|
102
|
-
"esm": true
|
|
103
|
-
}
|
|
104
|
-
],
|
|
105
|
-
[
|
|
106
|
-
"typescript",
|
|
107
|
-
{
|
|
108
|
-
"project": "tsconfig.build.json"
|
|
109
|
-
}
|
|
110
|
-
]
|
|
111
|
-
]
|
|
112
|
-
},
|
|
113
|
-
"codegenConfig": {
|
|
114
|
-
"name": "AdvancedTextViewSpec",
|
|
115
|
-
"type": "all",
|
|
116
|
-
"jsSrcsDir": "src",
|
|
117
|
-
"android": {
|
|
118
|
-
"javaPackageName": "com.advancedtext"
|
|
119
|
-
},
|
|
120
|
-
"ios": {
|
|
121
|
-
"componentProvider": {
|
|
122
|
-
"AdvancedTextView": "AdvancedTextView"
|
|
123
|
-
}
|
|
124
|
-
}
|
|
125
|
-
},
|
|
126
|
-
"prettier": {
|
|
127
|
-
"quoteProps": "consistent",
|
|
128
|
-
"singleQuote": true,
|
|
129
|
-
"tabWidth": 2,
|
|
130
|
-
"trailingComma": "es5",
|
|
131
|
-
"useTabs": false
|
|
132
|
-
},
|
|
133
|
-
"commitlint": {
|
|
134
|
-
"extends": [
|
|
135
|
-
"@commitlint/config-conventional"
|
|
136
|
-
]
|
|
137
|
-
},
|
|
138
|
-
"release-it": {
|
|
139
|
-
"git": {
|
|
140
|
-
"commitMessage": "chore: release ${version}",
|
|
141
|
-
"tagName": "v${version}"
|
|
142
|
-
},
|
|
143
|
-
"npm": {
|
|
144
|
-
"publish": true
|
|
145
|
-
},
|
|
146
|
-
"github": {
|
|
147
|
-
"release": true
|
|
148
|
-
},
|
|
149
|
-
"plugins": {
|
|
150
|
-
"@release-it/conventional-changelog": {
|
|
151
|
-
"preset": {
|
|
152
|
-
"name": "angular"
|
|
153
|
-
}
|
|
154
|
-
}
|
|
155
|
-
}
|
|
156
|
-
},
|
|
157
|
-
"jest": {
|
|
158
|
-
"preset": "react-native",
|
|
159
|
-
"modulePathIgnorePatterns": [
|
|
160
|
-
"<rootDir>/example/node_modules",
|
|
161
|
-
"<rootDir>/lib/"
|
|
162
|
-
]
|
|
163
|
-
},
|
|
164
|
-
"create-react-native-library": {
|
|
165
|
-
"languages": "kotlin-objc",
|
|
166
|
-
"type": "fabric-view",
|
|
167
|
-
"tools": [
|
|
168
|
-
"eslint",
|
|
169
|
-
"lefthook",
|
|
170
|
-
"release-it",
|
|
171
|
-
"jest"
|
|
172
|
-
],
|
|
173
|
-
"version": "0.55.1"
|
|
174
|
-
}
|
|
175
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "react-native-advanced-text",
|
|
3
|
+
"version": "0.1.17",
|
|
4
|
+
"description": " Advanced text component for React Native with custom select options.",
|
|
5
|
+
"main": "./lib/module/index.js",
|
|
6
|
+
"types": "./lib/typescript/src/index.d.ts",
|
|
7
|
+
"exports": {
|
|
8
|
+
".": {
|
|
9
|
+
"source": "./src/index.tsx",
|
|
10
|
+
"types": "./lib/typescript/src/index.d.ts",
|
|
11
|
+
"default": "./lib/module/index.js"
|
|
12
|
+
},
|
|
13
|
+
"./package.json": "./package.json"
|
|
14
|
+
},
|
|
15
|
+
"files": [
|
|
16
|
+
"src",
|
|
17
|
+
"lib",
|
|
18
|
+
"android",
|
|
19
|
+
"ios",
|
|
20
|
+
"cpp",
|
|
21
|
+
"*.podspec",
|
|
22
|
+
"react-native.config.js",
|
|
23
|
+
"!ios/build",
|
|
24
|
+
"!android/build",
|
|
25
|
+
"!android/gradle",
|
|
26
|
+
"!android/gradlew",
|
|
27
|
+
"!android/gradlew.bat",
|
|
28
|
+
"!android/local.properties",
|
|
29
|
+
"!**/__tests__",
|
|
30
|
+
"!**/__fixtures__",
|
|
31
|
+
"!**/__mocks__",
|
|
32
|
+
"!**/.*"
|
|
33
|
+
],
|
|
34
|
+
"scripts": {
|
|
35
|
+
"example": "yarn workspace react-native-advanced-text-example",
|
|
36
|
+
"clean": "del-cli android/build example/android/build example/android/app/build example/ios/build lib",
|
|
37
|
+
"prepare": "bob build",
|
|
38
|
+
"typecheck": "tsc",
|
|
39
|
+
"lint": "eslint \"**/*.{js,ts,tsx}\"",
|
|
40
|
+
"release": "release-it --only-version",
|
|
41
|
+
"test": "jest"
|
|
42
|
+
},
|
|
43
|
+
"keywords": [
|
|
44
|
+
"react-native",
|
|
45
|
+
"ios",
|
|
46
|
+
"android"
|
|
47
|
+
],
|
|
48
|
+
"repository": {
|
|
49
|
+
"type": "git",
|
|
50
|
+
"url": "git+https://github.com/AminAllahham/react-native-advanced-text.git"
|
|
51
|
+
},
|
|
52
|
+
"author": "Amin Al-lahham <amin.allahham9@gmail.com> (https://github.com/AminAllahham)",
|
|
53
|
+
"license": "MIT",
|
|
54
|
+
"bugs": {
|
|
55
|
+
"url": "https://github.com/AminAllahham/react-native-advanced-text/issues"
|
|
56
|
+
},
|
|
57
|
+
"homepage": "https://github.com/AminAllahham/react-native-advanced-text#readme",
|
|
58
|
+
"publishConfig": {
|
|
59
|
+
"registry": "https://registry.npmjs.org/"
|
|
60
|
+
},
|
|
61
|
+
"devDependencies": {
|
|
62
|
+
"@commitlint/config-conventional": "^19.8.1",
|
|
63
|
+
"@eslint/compat": "^1.3.2",
|
|
64
|
+
"@eslint/eslintrc": "^3.3.1",
|
|
65
|
+
"@eslint/js": "^9.35.0",
|
|
66
|
+
"@react-native-community/cli": "20.0.1",
|
|
67
|
+
"@react-native/babel-preset": "0.81.1",
|
|
68
|
+
"@react-native/eslint-config": "^0.81.1",
|
|
69
|
+
"@release-it/conventional-changelog": "^10.0.1",
|
|
70
|
+
"@types/jest": "^29.5.14",
|
|
71
|
+
"@types/react": "^19.1.0",
|
|
72
|
+
"commitlint": "^19.8.1",
|
|
73
|
+
"del-cli": "^6.0.0",
|
|
74
|
+
"eslint": "^9.35.0",
|
|
75
|
+
"eslint-config-prettier": "^10.1.8",
|
|
76
|
+
"eslint-plugin-prettier": "^5.5.4",
|
|
77
|
+
"jest": "^29.7.0",
|
|
78
|
+
"lefthook": "^2.0.3",
|
|
79
|
+
"prettier": "^2.8.8",
|
|
80
|
+
"react": "19.1.0",
|
|
81
|
+
"react-native": "0.81.1",
|
|
82
|
+
"react-native-builder-bob": "^0.40.16",
|
|
83
|
+
"release-it": "^19.0.4",
|
|
84
|
+
"turbo": "^2.5.6",
|
|
85
|
+
"typescript": "^5.9.2"
|
|
86
|
+
},
|
|
87
|
+
"peerDependencies": {
|
|
88
|
+
"react": "*",
|
|
89
|
+
"react-native": "*"
|
|
90
|
+
},
|
|
91
|
+
"workspaces": [
|
|
92
|
+
"example"
|
|
93
|
+
],
|
|
94
|
+
"packageManager": "yarn@4.11.0",
|
|
95
|
+
"react-native-builder-bob": {
|
|
96
|
+
"source": "src",
|
|
97
|
+
"output": "lib",
|
|
98
|
+
"targets": [
|
|
99
|
+
[
|
|
100
|
+
"module",
|
|
101
|
+
{
|
|
102
|
+
"esm": true
|
|
103
|
+
}
|
|
104
|
+
],
|
|
105
|
+
[
|
|
106
|
+
"typescript",
|
|
107
|
+
{
|
|
108
|
+
"project": "tsconfig.build.json"
|
|
109
|
+
}
|
|
110
|
+
]
|
|
111
|
+
]
|
|
112
|
+
},
|
|
113
|
+
"codegenConfig": {
|
|
114
|
+
"name": "AdvancedTextViewSpec",
|
|
115
|
+
"type": "all",
|
|
116
|
+
"jsSrcsDir": "src",
|
|
117
|
+
"android": {
|
|
118
|
+
"javaPackageName": "com.advancedtext"
|
|
119
|
+
},
|
|
120
|
+
"ios": {
|
|
121
|
+
"componentProvider": {
|
|
122
|
+
"AdvancedTextView": "AdvancedTextView"
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
},
|
|
126
|
+
"prettier": {
|
|
127
|
+
"quoteProps": "consistent",
|
|
128
|
+
"singleQuote": true,
|
|
129
|
+
"tabWidth": 2,
|
|
130
|
+
"trailingComma": "es5",
|
|
131
|
+
"useTabs": false
|
|
132
|
+
},
|
|
133
|
+
"commitlint": {
|
|
134
|
+
"extends": [
|
|
135
|
+
"@commitlint/config-conventional"
|
|
136
|
+
]
|
|
137
|
+
},
|
|
138
|
+
"release-it": {
|
|
139
|
+
"git": {
|
|
140
|
+
"commitMessage": "chore: release ${version}",
|
|
141
|
+
"tagName": "v${version}"
|
|
142
|
+
},
|
|
143
|
+
"npm": {
|
|
144
|
+
"publish": true
|
|
145
|
+
},
|
|
146
|
+
"github": {
|
|
147
|
+
"release": true
|
|
148
|
+
},
|
|
149
|
+
"plugins": {
|
|
150
|
+
"@release-it/conventional-changelog": {
|
|
151
|
+
"preset": {
|
|
152
|
+
"name": "angular"
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
},
|
|
157
|
+
"jest": {
|
|
158
|
+
"preset": "react-native",
|
|
159
|
+
"modulePathIgnorePatterns": [
|
|
160
|
+
"<rootDir>/example/node_modules",
|
|
161
|
+
"<rootDir>/lib/"
|
|
162
|
+
]
|
|
163
|
+
},
|
|
164
|
+
"create-react-native-library": {
|
|
165
|
+
"languages": "kotlin-objc",
|
|
166
|
+
"type": "fabric-view",
|
|
167
|
+
"tools": [
|
|
168
|
+
"eslint",
|
|
169
|
+
"lefthook",
|
|
170
|
+
"release-it",
|
|
171
|
+
"jest"
|
|
172
|
+
],
|
|
173
|
+
"version": "0.55.1"
|
|
174
|
+
}
|
|
175
|
+
}
|