@expensify/react-native-live-markdown 0.1.302 → 0.1.304

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/README.md CHANGED
@@ -173,7 +173,7 @@ function parser(input: string) {
173
173
 
174
174
  ## Markdown flavors support
175
175
 
176
- Currently, `react-native-live-markdown` supports only [ExpensiMark](https://github.com/Expensify/expensify-common/blob/main/lib/ExpensiMark.ts) flavor. We are working on CommonMark support as well as possibility to use other Markdown parsers.
176
+ Currently, `react-native-live-markdown` supports only [ExpensiMark](https://github.com/Expensify/expensify-common/blob/main/lib/ExpensiMark.ts) flavor out-of-the-box. You can customize the behavior by passing a custom parser worklet function via the `parser` prop, as detailed in the [Parsing logic](#parsing-logic) section.
177
177
 
178
178
  ## API reference
179
179
 
@@ -128,8 +128,10 @@ android {
128
128
  ]
129
129
 
130
130
  // TextLayoutManager
131
- if (REACT_NATIVE_MINOR_VERSION <= 79 ) {
131
+ if (REACT_NATIVE_MINOR_VERSION <= 79) {
132
132
  java.srcDirs += "src/reactNativeVersionPatch/CustomMountingManager/79"
133
+ } else if (REACT_NATIVE_MINOR_VERSION == 80) {
134
+ java.srcDirs += "src/reactNativeVersionPatch/CustomMountingManager/80"
133
135
  } else {
134
136
  java.srcDirs += "src/reactNativeVersionPatch/CustomMountingManager/latest"
135
137
  }
@@ -43,14 +43,23 @@ target_link_libraries(
43
43
  ReactAndroid::reactnative
44
44
  )
45
45
 
46
+ if (ReactAndroid_VERSION_MINOR LESS_EQUAL 80)
47
+ target_compile_options(
48
+ ${LIB_TARGET_NAME}
49
+ PRIVATE
50
+ -DLOG_TAG=\"ReactNative\"
51
+ -fexceptions
52
+ -frtti
53
+ -Wall
54
+ -std=c++20
55
+ )
56
+ else()
57
+ target_compile_reactnative_options(${LIB_TARGET_NAME} PRIVATE)
58
+ endif()
59
+
46
60
  target_compile_options(
47
61
  ${LIB_TARGET_NAME}
48
62
  PRIVATE
49
- -DLOG_TAG=\"ReactNative\"
50
- -fexceptions
51
- -frtti
52
- -Wall
53
- -std=c++20
54
63
  -DREACT_NATIVE_MINOR_VERSION=${ReactAndroid_VERSION_MINOR}
55
64
  )
56
65
 
@@ -144,14 +144,14 @@ void MarkdownTextInputDecoratorShadowNode::overwriteTextLayoutManager() {
144
144
  }
145
145
 
146
146
  void MarkdownTextInputDecoratorShadowNode::appendChild(
147
- const ShadowNode::Shared &child) {
147
+ const std::shared_ptr<const ShadowNode> &child) {
148
148
  YogaLayoutableShadowNode::appendChild(child);
149
149
 
150
150
  overwriteTextLayoutManager();
151
151
  }
152
152
 
153
153
  void MarkdownTextInputDecoratorShadowNode::replaceChild(
154
- const ShadowNode &oldChild, const ShadowNode::Shared &newChild,
154
+ const ShadowNode &oldChild, const std::shared_ptr<const ShadowNode> &newChild,
155
155
  size_t suggestedIndex) {
156
156
  YogaLayoutableShadowNode::replaceChild(oldChild, newChild, suggestedIndex);
157
157
 
@@ -26,10 +26,10 @@ public:
26
26
  MarkdownTextInputDecoratorShadowNode(ShadowNode const &sourceShadowNode,
27
27
  ShadowNodeFragment const &fragment);
28
28
 
29
- void appendChild(const ShadowNode::Shared &child) override;
29
+ void appendChild(const std::shared_ptr<const ShadowNode> &child) override;
30
30
 
31
31
  void replaceChild(const ShadowNode &oldChild,
32
- const ShadowNode::Shared &newChild,
32
+ const std::shared_ptr<const ShadowNode> &newChild,
33
33
  size_t suggestedIndex = SIZE_MAX) override;
34
34
 
35
35
  void layout(LayoutContext layoutContext) override;
@@ -0,0 +1,47 @@
1
+ package com.expensify.livemarkdown;
2
+
3
+ import com.facebook.react.bridge.ReactApplicationContext;
4
+ import com.facebook.react.bridge.ReadableMap;
5
+ import com.facebook.react.fabric.FabricUIManager;
6
+ import com.facebook.react.fabric.mounting.MountingManager;
7
+ import com.facebook.react.uimanager.ViewManagerRegistry;
8
+ import com.facebook.react.uimanager.events.BatchEventDispatchedListener;
9
+
10
+ import java.lang.reflect.Field;
11
+
12
+ public class CustomFabricUIManager {
13
+
14
+ public static FabricUIManager create(FabricUIManager source, ReadableMap markdownProps, int parserId) {
15
+ Class<? extends FabricUIManager> uiManagerClass = source.getClass();
16
+
17
+ try {
18
+ Field mountingManagerField = uiManagerClass.getDeclaredField("mMountingManager");
19
+ mountingManagerField.setAccessible(true);
20
+
21
+ MountingManager sourceMountingManager = readPrivateField(source, "mMountingManager");
22
+ ReactApplicationContext reactContext = readPrivateField(source, "mReactApplicationContext");
23
+ ViewManagerRegistry viewManagerRegistry = readPrivateField(source, "mViewManagerRegistry");
24
+ BatchEventDispatchedListener batchEventDispatchedListener = readPrivateField(source, "mBatchEventDispatchedListener");
25
+ MountingManager.MountItemExecutor mountItemExecutor = readPrivateField(source, "mMountItemExecutor");
26
+
27
+ FabricUIManager customFabricUIManager = new FabricUIManager(reactContext, viewManagerRegistry, batchEventDispatchedListener);
28
+
29
+ mountingManagerField.set(customFabricUIManager, new CustomMountingManager(sourceMountingManager, viewManagerRegistry, mountItemExecutor, reactContext, markdownProps, parserId));
30
+
31
+ return customFabricUIManager;
32
+ } catch (NoSuchFieldException | IllegalAccessException e) {
33
+ throw new RuntimeException("[LiveMarkdown] Cannot read data from FabricUIManager");
34
+ }
35
+ }
36
+
37
+ @SuppressWarnings("unchecked")
38
+ private static <T> T readPrivateField(Object obj, String name) throws NoSuchFieldException, IllegalAccessException {
39
+ Class<?> clazz = obj.getClass();
40
+
41
+ Field field = clazz.getDeclaredField(name);
42
+ field.setAccessible(true);
43
+ T value = (T) field.get(obj);
44
+
45
+ return value;
46
+ }
47
+ }
@@ -1,15 +1,89 @@
1
1
  package com.expensify.livemarkdown;
2
2
 
3
+ import static com.facebook.react.fabric.mounting.LayoutMetricsConversions.getYogaMeasureMode;
4
+ import static com.facebook.react.fabric.mounting.LayoutMetricsConversions.getYogaSize;
5
+
6
+ import android.text.SpannableStringBuilder;
7
+
8
+ import androidx.annotation.Nullable;
9
+
10
+ import com.facebook.infer.annotation.Assertions;
11
+ import com.facebook.jni.annotations.DoNotStrip;
3
12
  import com.facebook.react.bridge.ReactApplicationContext;
13
+ import com.facebook.react.bridge.ReactContext;
4
14
  import com.facebook.react.bridge.ReadableMap;
15
+ import com.facebook.react.common.mapbuffer.ReadableMapBuffer;
5
16
  import com.facebook.react.fabric.FabricUIManager;
6
17
  import com.facebook.react.fabric.mounting.MountingManager;
18
+ import com.facebook.react.fabric.mounting.SurfaceMountingManager;
7
19
  import com.facebook.react.uimanager.ViewManagerRegistry;
8
20
  import com.facebook.react.uimanager.events.BatchEventDispatchedListener;
21
+ import com.facebook.react.views.text.TextLayoutManager;
9
22
 
10
23
  import java.lang.reflect.Field;
11
24
 
12
- public class CustomFabricUIManager {
25
+ @DoNotStrip
26
+ public class CustomFabricUIManager extends FabricUIManager {
27
+
28
+ private final ReactApplicationContext mReactApplicationContext;
29
+ private final MountingManager mMountingManager;
30
+ private final MarkdownUtils mMarkdownUtils;
31
+
32
+ public CustomFabricUIManager(
33
+ ReactApplicationContext reactContext,
34
+ ViewManagerRegistry viewManagerRegistry,
35
+ BatchEventDispatchedListener batchEventDispatchedListener,
36
+ MountingManager mountingManager,
37
+ ReadableMap markdownProps,
38
+ int parserId
39
+ ) {
40
+ super(reactContext, viewManagerRegistry, batchEventDispatchedListener);
41
+
42
+ this.mReactApplicationContext = reactContext;
43
+ this.mMountingManager = mountingManager;
44
+
45
+ this.mMarkdownUtils = new MarkdownUtils(reactContext);
46
+ this.mMarkdownUtils.setMarkdownStyle(new MarkdownStyle(markdownProps, reactContext));
47
+ this.mMarkdownUtils.setParserId(parserId);
48
+ }
49
+
50
+ public long measureText(
51
+ int surfaceId,
52
+ ReadableMapBuffer attributedString,
53
+ ReadableMapBuffer paragraphAttributes,
54
+ float minWidth,
55
+ float maxWidth,
56
+ float minHeight,
57
+ float maxHeight,
58
+ @Nullable float[] attachmentsPositions) {
59
+
60
+ ReactContext context;
61
+ if (surfaceId > 0) {
62
+ SurfaceMountingManager surfaceMountingManager =
63
+ mMountingManager.getSurfaceManagerEnforced(surfaceId, "measureText");
64
+ if (surfaceMountingManager.isStopped()) {
65
+ return 0;
66
+ }
67
+ context = surfaceMountingManager.getContext();
68
+ Assertions.assertNotNull(
69
+ context, "Context in SurfaceMountingManager is null. surfaceId: " + surfaceId);
70
+ } else {
71
+ context = mReactApplicationContext;
72
+ }
73
+
74
+ return TextLayoutManager.measureText(
75
+ context,
76
+ attributedString,
77
+ paragraphAttributes,
78
+ getYogaSize(minWidth, maxWidth),
79
+ getYogaMeasureMode(minWidth, maxWidth),
80
+ getYogaSize(minHeight, maxHeight),
81
+ getYogaMeasureMode(minHeight, maxHeight),
82
+ spannable -> {
83
+ mMarkdownUtils.applyMarkdownFormatting((SpannableStringBuilder)spannable);
84
+ },
85
+ attachmentsPositions);
86
+ }
13
87
 
14
88
  public static FabricUIManager create(FabricUIManager source, ReadableMap markdownProps, int parserId) {
15
89
  Class<? extends FabricUIManager> uiManagerClass = source.getClass();
@@ -22,11 +96,15 @@ public class CustomFabricUIManager {
22
96
  ReactApplicationContext reactContext = readPrivateField(source, "mReactApplicationContext");
23
97
  ViewManagerRegistry viewManagerRegistry = readPrivateField(source, "mViewManagerRegistry");
24
98
  BatchEventDispatchedListener batchEventDispatchedListener = readPrivateField(source, "mBatchEventDispatchedListener");
25
- MountingManager.MountItemExecutor mountItemExecutor = readPrivateField(source, "mMountItemExecutor");
26
-
27
- FabricUIManager customFabricUIManager = new FabricUIManager(reactContext, viewManagerRegistry, batchEventDispatchedListener);
28
99
 
29
- mountingManagerField.set(customFabricUIManager, new CustomMountingManager(sourceMountingManager, viewManagerRegistry, mountItemExecutor, reactContext, markdownProps, parserId));
100
+ FabricUIManager customFabricUIManager = new CustomFabricUIManager(
101
+ reactContext,
102
+ viewManagerRegistry,
103
+ batchEventDispatchedListener,
104
+ sourceMountingManager,
105
+ markdownProps,
106
+ parserId
107
+ );
30
108
 
31
109
  return customFabricUIManager;
32
110
  } catch (NoSuchFieldException | IllegalAccessException e) {
@@ -12,17 +12,19 @@ public:
12
12
 
13
13
  MarkdownTextInputDecoratorState(){};
14
14
 
15
- #ifdef ANDROID
15
+ // TODO: Simplify once RN 0.81 is the lowest supported version
16
+ #if (defined(ANDROID) && REACT_NATIVE_MINOR_VERSION < 81) || (defined(RN_SERIALIZABLE_STATE) && REACT_NATIVE_MINOR_VERSION >= 81)
16
17
  MarkdownTextInputDecoratorState(
17
18
  MarkdownTextInputDecoratorState const &previousState, folly::dynamic data){};
18
- #endif
19
19
 
20
- #ifdef ANDROID
21
20
  folly::dynamic getDynamic() const {
22
21
  return {};
23
22
  }
23
+ #if REACT_NATIVE_MINOR_VERSION < 81
24
24
  MapBuffer getMapBuffer() const { return MapBufferBuilder::EMPTY(); };
25
- #endif
25
+ #endif // REACT_NATIVE_MINOR_VERSION < 81
26
+ #endif // (defined(ANDROID) && REACT_NATIVE_MINOR_VERSION < 81) || (defined(RN_SERIALIZABLE_STATE) && REACT_NATIVE_MINOR_VERSION >= 81)
27
+
26
28
  };
27
29
 
28
30
  } // namespace react
@@ -1,4 +1,3 @@
1
- /// <reference types="react-native/types/modules/Codegen" />
2
1
  import type { ColorValue, ViewProps } from 'react-native';
3
2
  import type { Float, Int32 } from 'react-native/Libraries/Types/CodegenTypes';
4
3
  interface CodeBlockStyle {
@@ -1 +1 @@
1
- {"version":3,"file":"MarkdownTextInputDecoratorViewNativeComponent.d.ts","sourceRoot":"","sources":["../../../src/MarkdownTextInputDecoratorViewNativeComponent.ts"],"names":[],"mappings":";AAAA,OAAO,KAAK,EAAC,UAAU,EAAE,SAAS,EAAC,MAAM,cAAc,CAAC;AAExD,OAAO,KAAK,EAAC,KAAK,EAAE,KAAK,EAAC,MAAM,2CAA2C,CAAC;AAG5E,UAAU,cAAc;IACtB,UAAU,EAAE,MAAM,CAAC;IACnB,QAAQ,EAAE,KAAK,CAAC;IAChB,KAAK,EAAE,UAAU,CAAC;IAClB,eAAe,EAAE,UAAU,CAAC;IAC5B,WAAW,CAAC,EAAE,UAAU,CAAC;IACzB,WAAW,C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CAAC;QAChB,SAAS,EAAE,KAAK,CAAC;QACjB,SAAS,EAAE,KAAK,CAAC;QACjB,YAAY,EAAE,KAAK,CAAC;QACpB,YAAY,EAAE,KAAK,CAAC;KACrB,CAAC;IACF,yBAAyB,CAAC,EAAE;QAC1B,eAAe,CAAC,EAAE,UAAU,CAAC;QAC7B,WAAW,CAAC,EAAE,KAAK,CAAC;QACpB,WAAW,CAAC,EAAE,UAAU,CAAC;QACzB,YAAY,CAAC,EAAE,KAAK,CAAC;QACrB,KAAK,CAAC,EAAE,KAAK,CAAC;QACd,MAAM,CAAC,EAAE,KAAK,CAAC;KAChB,CAAC;IACF,gBAAgB,CAAC,EAAE;QACjB,YAAY,CAAC,EAAE,UAAU,CAAC;QAC1B,cAAc,CAAC,EAAE,UAAU,CAAC;QAC5B,KAAK,CAAC,EAAE,KAAK,CAAC;QACd,MAAM,CAAC,EAAE,KAAK,CAAC;QACf,WAAW,CAAC,EAAE,KAAK,CAAC;KACrB,CAAC;CACH;AAED,UAAU,WAAY,SAAQ,SAAS;IACrC,aAAa,EAAE,aAAa,CAAC;IAC7B,QAAQ,EAAE,KAAK,CAAC;CACjB;;AAED,wBAEG;AAEH,YAAY,EAAC,aAAa,EAAC,CAAC"}
1
+ {"version":3,"file":"MarkdownTextInputDecoratorViewNativeComponent.d.ts","sourceRoot":"","sources":["../../../src/MarkdownTextInputDecoratorViewNativeComponent.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,UAAU,EAAE,SAAS,EAAC,MAAM,cAAc,CAAC;AAExD,OAAO,KAAK,EAAC,KAAK,EAAE,KAAK,EAAC,MAAM,2CAA2C,CAAC;AAG5E,UAAU,cAAc;IACtB,UAAU,EAAE,MAAM,CAAC;IACnB,QAAQ,EAAE,KAAK,CAAC;IAChB,KAAK,EAAE,UAAU,CAAC;IAClB,eAAe,EAAE,UAAU,CAAC;IAC5B,WAAW,CAAC,EAAE,UAAU,CAAC;IACzB,WAAW,CAAC,EAAE,KAAK,CAAC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E,KAAK,CAAC;QACjB,SAAS,EAAE,KAAK,CAAC;QACjB,YAAY,EAAE,KAAK,CAAC;QACpB,YAAY,EAAE,KAAK,CAAC;KACrB,CAAC;IACF,yBAAyB,CAAC,EAAE;QAC1B,eAAe,CAAC,EAAE,UAAU,CAAC;QAC7B,WAAW,CAAC,EAAE,KAAK,CAAC;QACpB,WAAW,CAAC,EAAE,UAAU,CAAC;QACzB,YAAY,CAAC,EAAE,KAAK,CAAC;QACrB,KAAK,CAAC,EAAE,KAAK,CAAC;QACd,MAAM,CAAC,EAAE,KAAK,CAAC;KAChB,CAAC;IACF,gBAAgB,CAAC,EAAE;QACjB,YAAY,CAAC,EAAE,UAAU,CAAC;QAC1B,cAAc,CAAC,EAAE,UAAU,CAAC;QAC5B,KAAK,CAAC,EAAE,KAAK,CAAC;QACd,MAAM,CAAC,EAAE,KAAK,CAAC;QACf,WAAW,CAAC,EAAE,KAAK,CAAC;KACrB,CAAC;CACH;AAED,UAAU,WAAY,SAAQ,SAAS;IACrC,aAAa,EAAE,aAAa,CAAC;IAC7B,QAAQ,EAAE,KAAK,CAAC;CACjB;;AAED,wBAEG;AAEH,YAAY,EAAC,aAAa,EAAC,CAAC"}
@@ -1,4 +1,3 @@
1
- /// <reference types="node" />
2
1
  type HistoryItem = {
3
2
  text: string;
4
3
  cursorPosition: number | null;
@@ -1 +1 @@
1
- {"version":3,"file":"InputHistory.d.ts","sourceRoot":"","sources":["../../../../src/web/InputHistory.ts"],"names":[],"mappings":";AAAA,KAAK,WAAW,GAAG;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,cAAc,EAAE,MAAM,GAAG,IAAI,CAAC;CAC/B,CAAC;AAEF,MAAM,CAAC,OAAO,OAAO,YAAY;IAC/B,KAAK,EAAE,MAAM,CAAC;IAEd,KAAK,EAAE,WAAW,EAAE,CAAC;IAErB,YAAY,EAAE,MAAM,CAAC;IAErB,WAAW,EAAE,MAAM,GAAG,IAAI,CAAQ;IAElC,OAAO,EAAE,MAA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IAKb,YAAY,CAAC,IAAI,EAAE,MAAM,EAAE,cAAc,EAAE,MAAM,GAAG,IAAI;IAkBxD,WAAW,IAAI,IAAI;IAQnB,GAAG,CAAC,IAAI,EAAE,MAAM,EAAE,cAAc,EAAE,MAAM,GAAG,IAAI;IAqB/C,IAAI,IAAI,WAAW,GAAG,IAAI;IA2B1B,IAAI,IAAI,WAAW,GAAG,IAAI;CAiB3B"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@expensify/react-native-live-markdown",
3
- "version": "0.1.302",
3
+ "version": "0.1.304",
4
4
  "description": "Drop-in replacement for React Native's TextInput component with Markdown formatting.",
5
5
  "main": "lib/commonjs/index",
6
6
  "module": "lib/module/index",
@@ -64,10 +64,11 @@
64
64
  "@commitlint/config-conventional": "^17.0.2",
65
65
  "@evilmartians/lefthook": "^1.5.0",
66
66
  "@lwc/eslint-plugin-lwc": "^1.7.2",
67
- "@react-native-community/cli": "19.0.0",
68
- "@react-native-community/cli-platform-android": "19.0.0",
69
- "@react-native-community/cli-platform-ios": "19.0.0",
70
- "@react-native/eslint-config": "0.80.1",
67
+ "@react-native-community/cli": "20.0.0",
68
+ "@react-native-community/cli-platform-android": "20.0.0",
69
+ "@react-native-community/cli-platform-ios": "20.0.0",
70
+ "@react-native/eslint-config": "0.81.4",
71
+ "@react-native/metro-config": "0.81.4",
71
72
  "@release-it/conventional-changelog": "^5.0.0",
72
73
  "@types/jest": "^29.5.14",
73
74
  "@types/react": "^19.1.0",
@@ -95,13 +96,13 @@
95
96
  "prettier": "2.8.8",
96
97
  "react": "19.1.0",
97
98
  "react-dom": "19.1.0",
98
- "react-native": "0.80.1",
99
+ "react-native": "0.81.4",
99
100
  "react-native-builder-bob": "^0.30.2",
100
- "react-native-reanimated": "3.18.0",
101
+ "react-native-reanimated": "3.19.0",
101
102
  "react-native-web": "^0.20.0",
102
103
  "release-it": "^15.0.0",
103
104
  "turbo": "^1.10.7",
104
- "typescript": "~5.3.3"
105
+ "typescript": "^5.8.3"
105
106
  },
106
107
  "peerDependencies": {
107
108
  "expensify-common": ">=2.0.148",