@mpxjs/webpack-plugin 2.10.14-beta.5 → 2.10.14-beta.7

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 (183) hide show
  1. package/lib/platform/template/wx/component-config/button.js +12 -3
  2. package/lib/runtime/components/react/context.ts +0 -1
  3. package/lib/runtime/components/react/dist/context.d.ts +3 -6
  4. package/lib/runtime/components/react/dist/context.d.ts.map +1 -0
  5. package/lib/runtime/components/react/dist/context.js +1 -1
  6. package/lib/runtime/components/react/dist/event.config.d.ts +1 -0
  7. package/lib/runtime/components/react/dist/event.config.d.ts.map +1 -0
  8. package/lib/runtime/components/react/dist/getInnerListeners.d.ts +1 -0
  9. package/lib/runtime/components/react/dist/getInnerListeners.d.ts.map +1 -0
  10. package/lib/runtime/components/react/dist/getInnerListeners.js +35 -21
  11. package/lib/runtime/components/react/dist/mpx-async-suspense.d.ts +1 -0
  12. package/lib/runtime/components/react/dist/mpx-async-suspense.d.ts.map +1 -0
  13. package/lib/runtime/components/react/dist/mpx-async-suspense.jsx +2 -2
  14. package/lib/runtime/components/react/dist/mpx-button.d.ts +1 -0
  15. package/lib/runtime/components/react/dist/mpx-button.d.ts.map +1 -0
  16. package/lib/runtime/components/react/dist/mpx-camera.d.ts +27 -0
  17. package/lib/runtime/components/react/dist/mpx-camera.d.ts.map +1 -0
  18. package/lib/runtime/components/react/dist/mpx-camera.jsx +197 -0
  19. package/lib/runtime/components/react/dist/mpx-canvas/Bus.d.ts +1 -0
  20. package/lib/runtime/components/react/dist/mpx-canvas/Bus.d.ts.map +1 -0
  21. package/lib/runtime/components/react/dist/mpx-canvas/CanvasGradient.d.ts +1 -0
  22. package/lib/runtime/components/react/dist/mpx-canvas/CanvasGradient.d.ts.map +1 -0
  23. package/lib/runtime/components/react/dist/mpx-canvas/CanvasRenderingContext2D.d.ts +1 -0
  24. package/lib/runtime/components/react/dist/mpx-canvas/CanvasRenderingContext2D.d.ts.map +1 -0
  25. package/lib/runtime/components/react/dist/mpx-canvas/Image.d.ts +1 -0
  26. package/lib/runtime/components/react/dist/mpx-canvas/Image.d.ts.map +1 -0
  27. package/lib/runtime/components/react/dist/mpx-canvas/ImageData.d.ts +1 -0
  28. package/lib/runtime/components/react/dist/mpx-canvas/ImageData.d.ts.map +1 -0
  29. package/lib/runtime/components/react/dist/mpx-canvas/constructorsRegistry.d.ts +1 -0
  30. package/lib/runtime/components/react/dist/mpx-canvas/constructorsRegistry.d.ts.map +1 -0
  31. package/lib/runtime/components/react/dist/mpx-canvas/html.d.ts +1 -0
  32. package/lib/runtime/components/react/dist/mpx-canvas/html.d.ts.map +1 -0
  33. package/lib/runtime/components/react/dist/mpx-canvas/index.d.ts +1 -0
  34. package/lib/runtime/components/react/dist/mpx-canvas/index.d.ts.map +1 -0
  35. package/lib/runtime/components/react/dist/mpx-canvas/utils.d.ts +1 -0
  36. package/lib/runtime/components/react/dist/mpx-canvas/utils.d.ts.map +1 -0
  37. package/lib/runtime/components/react/dist/mpx-checkbox-group.d.ts +1 -0
  38. package/lib/runtime/components/react/dist/mpx-checkbox-group.d.ts.map +1 -0
  39. package/lib/runtime/components/react/dist/mpx-checkbox.d.ts +1 -0
  40. package/lib/runtime/components/react/dist/mpx-checkbox.d.ts.map +1 -0
  41. package/lib/runtime/components/react/dist/mpx-form.d.ts +1 -0
  42. package/lib/runtime/components/react/dist/mpx-form.d.ts.map +1 -0
  43. package/lib/runtime/components/react/dist/mpx-icon/index.d.ts +1 -0
  44. package/lib/runtime/components/react/dist/mpx-icon/index.d.ts.map +1 -0
  45. package/lib/runtime/components/react/dist/mpx-image.d.ts +1 -0
  46. package/lib/runtime/components/react/dist/mpx-image.d.ts.map +1 -0
  47. package/lib/runtime/components/react/dist/mpx-image.jsx +81 -37
  48. package/lib/runtime/components/react/dist/mpx-inline-text.d.ts +1 -0
  49. package/lib/runtime/components/react/dist/mpx-inline-text.d.ts.map +1 -0
  50. package/lib/runtime/components/react/dist/mpx-input.d.ts +2 -7
  51. package/lib/runtime/components/react/dist/mpx-input.d.ts.map +1 -0
  52. package/lib/runtime/components/react/dist/mpx-input.jsx +19 -12
  53. package/lib/runtime/components/react/dist/mpx-keyboard-avoiding-view.d.ts +1 -0
  54. package/lib/runtime/components/react/dist/mpx-keyboard-avoiding-view.d.ts.map +1 -0
  55. package/lib/runtime/components/react/dist/mpx-keyboard-avoiding-view.jsx +15 -22
  56. package/lib/runtime/components/react/dist/mpx-label.d.ts +1 -0
  57. package/lib/runtime/components/react/dist/mpx-label.d.ts.map +1 -0
  58. package/lib/runtime/components/react/dist/mpx-movable-area.d.ts +1 -0
  59. package/lib/runtime/components/react/dist/mpx-movable-area.d.ts.map +1 -0
  60. package/lib/runtime/components/react/dist/mpx-movable-view.d.ts +5 -2
  61. package/lib/runtime/components/react/dist/mpx-movable-view.d.ts.map +1 -0
  62. package/lib/runtime/components/react/dist/mpx-movable-view.jsx +102 -34
  63. package/lib/runtime/components/react/dist/mpx-nav.d.ts +9 -0
  64. package/lib/runtime/components/react/dist/mpx-nav.d.ts.map +1 -0
  65. package/lib/runtime/components/react/dist/mpx-nav.jsx +132 -0
  66. package/lib/runtime/components/react/dist/mpx-navigator.d.ts +1 -0
  67. package/lib/runtime/components/react/dist/mpx-navigator.d.ts.map +1 -0
  68. package/lib/runtime/components/react/dist/mpx-picker/date.d.ts +1 -0
  69. package/lib/runtime/components/react/dist/mpx-picker/date.d.ts.map +1 -0
  70. package/lib/runtime/components/react/dist/mpx-picker/dateData.d.ts +1 -0
  71. package/lib/runtime/components/react/dist/mpx-picker/dateData.d.ts.map +1 -0
  72. package/lib/runtime/components/react/dist/mpx-picker/index.d.ts +1 -0
  73. package/lib/runtime/components/react/dist/mpx-picker/index.d.ts.map +1 -0
  74. package/lib/runtime/components/react/dist/mpx-picker/multiSelector.d.ts +1 -0
  75. package/lib/runtime/components/react/dist/mpx-picker/multiSelector.d.ts.map +1 -0
  76. package/lib/runtime/components/react/dist/mpx-picker/region.d.ts +1 -0
  77. package/lib/runtime/components/react/dist/mpx-picker/region.d.ts.map +1 -0
  78. package/lib/runtime/components/react/dist/mpx-picker/regionData.d.ts +1 -0
  79. package/lib/runtime/components/react/dist/mpx-picker/regionData.d.ts.map +1 -0
  80. package/lib/runtime/components/react/dist/mpx-picker/selector.d.ts +1 -0
  81. package/lib/runtime/components/react/dist/mpx-picker/selector.d.ts.map +1 -0
  82. package/lib/runtime/components/react/dist/mpx-picker/time.d.ts +1 -0
  83. package/lib/runtime/components/react/dist/mpx-picker/time.d.ts.map +1 -0
  84. package/lib/runtime/components/react/dist/mpx-picker/type.d.ts +1 -0
  85. package/lib/runtime/components/react/dist/mpx-picker/type.d.ts.map +1 -0
  86. package/lib/runtime/components/react/dist/mpx-picker-view/index.d.ts +2 -0
  87. package/lib/runtime/components/react/dist/mpx-picker-view/index.d.ts.map +1 -0
  88. package/lib/runtime/components/react/dist/mpx-picker-view/index.jsx +4 -3
  89. package/lib/runtime/components/react/dist/mpx-picker-view/pickerVIewContext.d.ts +1 -0
  90. package/lib/runtime/components/react/dist/mpx-picker-view/pickerVIewContext.d.ts.map +1 -0
  91. package/lib/runtime/components/react/dist/mpx-picker-view-column/index.d.ts +2 -0
  92. package/lib/runtime/components/react/dist/mpx-picker-view-column/index.d.ts.map +1 -0
  93. package/lib/runtime/components/react/dist/mpx-picker-view-column/index.jsx +15 -21
  94. package/lib/runtime/components/react/dist/mpx-picker-view-column/pickerViewColumnItem.d.ts +1 -0
  95. package/lib/runtime/components/react/dist/mpx-picker-view-column/pickerViewColumnItem.d.ts.map +1 -0
  96. package/lib/runtime/components/react/dist/mpx-picker-view-column/pickerViewColumnItem.jsx +8 -11
  97. package/lib/runtime/components/react/dist/mpx-picker-view-column/pickerViewColumnItemLite.d.ts +14 -0
  98. package/lib/runtime/components/react/dist/mpx-picker-view-column/pickerViewColumnItemLite.d.ts.map +1 -0
  99. package/lib/runtime/components/react/dist/mpx-picker-view-column/pickerViewColumnItemLite.jsx +20 -0
  100. package/lib/runtime/components/react/dist/mpx-picker-view-column/pickerViewFaces.d.ts +1 -0
  101. package/lib/runtime/components/react/dist/mpx-picker-view-column/pickerViewFaces.d.ts.map +1 -0
  102. package/lib/runtime/components/react/dist/mpx-picker-view-column/pickerViewIndicator.d.ts +1 -0
  103. package/lib/runtime/components/react/dist/mpx-picker-view-column/pickerViewIndicator.d.ts.map +1 -0
  104. package/lib/runtime/components/react/dist/mpx-picker-view-column/pickerViewMask.d.ts +1 -0
  105. package/lib/runtime/components/react/dist/mpx-picker-view-column/pickerViewMask.d.ts.map +1 -0
  106. package/lib/runtime/components/react/dist/mpx-popup/index.d.ts +1 -0
  107. package/lib/runtime/components/react/dist/mpx-popup/index.d.ts.map +1 -0
  108. package/lib/runtime/components/react/dist/mpx-popup/popupBase.d.ts +1 -0
  109. package/lib/runtime/components/react/dist/mpx-popup/popupBase.d.ts.map +1 -0
  110. package/lib/runtime/components/react/dist/mpx-portal/index.d.ts +1 -0
  111. package/lib/runtime/components/react/dist/mpx-portal/index.d.ts.map +1 -0
  112. package/lib/runtime/components/react/dist/mpx-portal/index.jsx +5 -1
  113. package/lib/runtime/components/react/dist/mpx-portal/portal-host.d.ts +1 -0
  114. package/lib/runtime/components/react/dist/mpx-portal/portal-host.d.ts.map +1 -0
  115. package/lib/runtime/components/react/dist/mpx-portal/portal-manager.d.ts +1 -0
  116. package/lib/runtime/components/react/dist/mpx-portal/portal-manager.d.ts.map +1 -0
  117. package/lib/runtime/components/react/dist/mpx-portal/portal-manager.jsx +3 -5
  118. package/lib/runtime/components/react/dist/mpx-progress.d.ts +24 -0
  119. package/lib/runtime/components/react/dist/mpx-progress.d.ts.map +1 -0
  120. package/lib/runtime/components/react/dist/mpx-progress.jsx +163 -0
  121. package/lib/runtime/components/react/dist/mpx-radio-group.d.ts +1 -0
  122. package/lib/runtime/components/react/dist/mpx-radio-group.d.ts.map +1 -0
  123. package/lib/runtime/components/react/dist/mpx-radio.d.ts +1 -0
  124. package/lib/runtime/components/react/dist/mpx-radio.d.ts.map +1 -0
  125. package/lib/runtime/components/react/dist/mpx-rich-text/html.d.ts +1 -0
  126. package/lib/runtime/components/react/dist/mpx-rich-text/html.d.ts.map +1 -0
  127. package/lib/runtime/components/react/dist/mpx-rich-text/index.d.ts +1 -0
  128. package/lib/runtime/components/react/dist/mpx-rich-text/index.d.ts.map +1 -0
  129. package/lib/runtime/components/react/dist/mpx-root-portal.d.ts +1 -0
  130. package/lib/runtime/components/react/dist/mpx-root-portal.d.ts.map +1 -0
  131. package/lib/runtime/components/react/dist/mpx-scroll-view.d.ts +1 -0
  132. package/lib/runtime/components/react/dist/mpx-scroll-view.d.ts.map +1 -0
  133. package/lib/runtime/components/react/dist/mpx-scroll-view.jsx +69 -51
  134. package/lib/runtime/components/react/dist/mpx-simple-text.d.ts +1 -0
  135. package/lib/runtime/components/react/dist/mpx-simple-text.d.ts.map +1 -0
  136. package/lib/runtime/components/react/dist/mpx-simple-view.d.ts +1 -0
  137. package/lib/runtime/components/react/dist/mpx-simple-view.d.ts.map +1 -0
  138. package/lib/runtime/components/react/dist/mpx-slider.d.ts +31 -0
  139. package/lib/runtime/components/react/dist/mpx-slider.d.ts.map +1 -0
  140. package/lib/runtime/components/react/dist/mpx-slider.jsx +321 -0
  141. package/lib/runtime/components/react/dist/mpx-sticky-header.d.ts +1 -0
  142. package/lib/runtime/components/react/dist/mpx-sticky-header.d.ts.map +1 -0
  143. package/lib/runtime/components/react/dist/mpx-sticky-section.d.ts +1 -0
  144. package/lib/runtime/components/react/dist/mpx-sticky-section.d.ts.map +1 -0
  145. package/lib/runtime/components/react/dist/mpx-swiper-item.d.ts +1 -0
  146. package/lib/runtime/components/react/dist/mpx-swiper-item.d.ts.map +1 -0
  147. package/lib/runtime/components/react/dist/mpx-swiper.d.ts +1 -0
  148. package/lib/runtime/components/react/dist/mpx-swiper.d.ts.map +1 -0
  149. package/lib/runtime/components/react/dist/mpx-swiper.jsx +9 -16
  150. package/lib/runtime/components/react/dist/mpx-switch.d.ts +1 -0
  151. package/lib/runtime/components/react/dist/mpx-switch.d.ts.map +1 -0
  152. package/lib/runtime/components/react/dist/mpx-text.d.ts +3 -1
  153. package/lib/runtime/components/react/dist/mpx-text.d.ts.map +1 -0
  154. package/lib/runtime/components/react/dist/mpx-text.jsx +33 -5
  155. package/lib/runtime/components/react/dist/mpx-textarea.d.ts +1 -0
  156. package/lib/runtime/components/react/dist/mpx-textarea.d.ts.map +1 -0
  157. package/lib/runtime/components/react/dist/mpx-video.d.ts +1 -0
  158. package/lib/runtime/components/react/dist/mpx-video.d.ts.map +1 -0
  159. package/lib/runtime/components/react/dist/mpx-view.d.ts +1 -0
  160. package/lib/runtime/components/react/dist/mpx-view.d.ts.map +1 -0
  161. package/lib/runtime/components/react/dist/mpx-view.jsx +1 -1
  162. package/lib/runtime/components/react/dist/mpx-web-view.d.ts +1 -0
  163. package/lib/runtime/components/react/dist/mpx-web-view.d.ts.map +1 -0
  164. package/lib/runtime/components/react/dist/mpx-web-view.jsx +21 -2
  165. package/lib/runtime/components/react/dist/parser.d.ts +1 -0
  166. package/lib/runtime/components/react/dist/parser.d.ts.map +1 -0
  167. package/lib/runtime/components/react/dist/useAnimationHooks.d.ts +1 -0
  168. package/lib/runtime/components/react/dist/useAnimationHooks.d.ts.map +1 -0
  169. package/lib/runtime/components/react/dist/useNodesRef.d.ts +1 -0
  170. package/lib/runtime/components/react/dist/useNodesRef.d.ts.map +1 -0
  171. package/lib/runtime/components/react/dist/utils.d.ts +1 -0
  172. package/lib/runtime/components/react/dist/utils.d.ts.map +1 -0
  173. package/lib/runtime/components/react/dist/utils.jsx +16 -6
  174. package/lib/runtime/components/react/mpx-input.tsx +1 -9
  175. package/lib/runtime/components/react/mpx-keyboard-avoiding-view.tsx +15 -13
  176. package/lib/runtime/components/react/nav.tsx +67 -76
  177. package/package.json +1 -1
  178. package/lib/runtime/components/react/dist/mpx-nav-container.d.ts +0 -9
  179. package/lib/runtime/components/react/dist/mpx-nav-container.jsx +0 -23
  180. package/lib/runtime/components/react/dist/nav.d.ts +0 -11
  181. package/lib/runtime/components/react/dist/nav.jsx +0 -141
  182. package/lib/runtime/components/react/dist/useNavShared.d.ts +0 -2
  183. package/lib/runtime/components/react/dist/useNavShared.js +0 -6
@@ -31,13 +31,16 @@ module.exports = function ({ print }) {
31
31
  const qaPropLog = print({ platform: 'qa', tag: TAG_NAME, isError: false })
32
32
  const wxPropValueLog = print({ platform: 'wx', tag: TAG_NAME, isError: false, type: 'value' })
33
33
  const iosValueLogError = print({ platform: 'ios', tag: TAG_NAME, isError: true, type: 'value' })
34
+ const iosValueLog = print({ platform: 'ios', tag: TAG_NAME, isError: false, type: 'value' })
34
35
  const iosPropLog = print({ platform: 'ios', tag: TAG_NAME, isError: false })
35
36
  const iosEventLog = print({ platform: 'ios', tag: TAG_NAME, isError: false, type: 'event' })
36
37
  const androidValueLogError = print({ platform: 'android', tag: TAG_NAME, isError: true, type: 'value' })
38
+ const androidValueLog = print({ platform: 'android', tag: TAG_NAME, isError: false, type: 'value' })
37
39
  const androidPropLog = print({ platform: 'android', tag: TAG_NAME, isError: false })
38
40
  const androidEventLog = print({ platform: 'android', tag: TAG_NAME, isError: false, type: 'event' })
39
41
 
40
42
  const harmonyValueLogError = print({ platform: 'harmony', tag: TAG_NAME, isError: true, type: 'value' })
43
+ const harmonyValueLog = print({ platform: 'harmony', tag: TAG_NAME, isError: false, type: 'value' })
41
44
  const harmonyPropLog = print({ platform: 'harmony', tag: TAG_NAME, isError: false })
42
45
  const harmonyEventLog = print({ platform: 'harmony', tag: TAG_NAME, isError: false, type: 'event' })
43
46
 
@@ -133,19 +136,25 @@ module.exports = function ({ print }) {
133
136
  ios ({ name, value }) {
134
137
  // TODO 此处open-type无其他属性支持了?
135
138
  const supported = ['share']
136
- if (!supported.includes(value)) {
139
+ if (isMustache(value)) {
140
+ iosValueLog({ name, value })
141
+ } else if (!supported.includes(value)) {
137
142
  iosValueLogError({ name, value })
138
143
  }
139
144
  },
140
145
  android ({ name, value }) {
141
146
  const supported = ['share']
142
- if (!supported.includes(value)) {
147
+ if (isMustache(value)) {
148
+ androidValueLog({ name, value })
149
+ } else if (!supported.includes(value)) {
143
150
  androidValueLogError({ name, value })
144
151
  }
145
152
  },
146
153
  harmony ({ name, value }) {
147
154
  const supported = ['share']
148
- if (!supported.includes(value)) {
155
+ if (isMustache(value)) {
156
+ harmonyValueLog({ name, value })
157
+ } else if (!supported.includes(value)) {
149
158
  harmonyValueLogError({ name, value })
150
159
  }
151
160
  }
@@ -12,7 +12,6 @@ export type KeyboardAvoidContextValue = MutableRefObject<{
12
12
  adjustPosition: boolean
13
13
  keyboardHeight?: number
14
14
  onKeyboardShow?: () => void
15
- enableNativeKeyboardAvoiding?: boolean
16
15
  } | null>
17
16
 
18
17
  export interface GroupValue {
@@ -7,9 +7,9 @@ export type KeyboardAvoidContextValue = MutableRefObject<{
7
7
  cursorSpacing: number;
8
8
  ref: MutableRefObject<any>;
9
9
  adjustPosition: boolean;
10
+ holdKeyboard?: boolean;
10
11
  keyboardHeight?: number;
11
12
  onKeyboardShow?: () => void;
12
- enableNativeKeyboardAvoiding?: boolean;
13
13
  } | null>;
14
14
  export interface GroupValue {
15
15
  [key: string]: {
@@ -55,10 +55,6 @@ export interface StickyContextValue {
55
55
  registerStickyHeader: Function;
56
56
  unregisterStickyHeader: Function;
57
57
  }
58
- export interface NavSharedValue {
59
- customNav?: React.ReactNode;
60
- setCustomNav: (value: React.ReactNode) => void;
61
- }
62
58
  export declare const MovableAreaContext: import("react").Context<{
63
59
  width: number;
64
60
  height: number;
@@ -76,4 +72,5 @@ export declare const KeyboardAvoidContext: import("react").Context<KeyboardAvoid
76
72
  export declare const ScrollViewContext: import("react").Context<ScrollViewContextValue>;
77
73
  export declare const PortalContext: import("react").Context<PortalContextValue>;
78
74
  export declare const StickyContext: import("react").Context<StickyContextValue>;
79
- export declare const NavSharedContext: import("react").Context<NavSharedValue>;
75
+ export declare const ProviderContext: import("react").Context<null>;
76
+ //# sourceMappingURL=context.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../context.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiB,QAAQ,EAAE,gBAAgB,EAAE,cAAc,EAAE,MAAM,OAAO,CAAA;AACjF,OAAO,EAAE,oBAAoB,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAA;AAG7D,MAAM,MAAM,iBAAiB,GAAG,gBAAgB,CAAC;IAC/C,aAAa,EAAE,CAAC,GAAG,EAAE,oBAAoB,CAAC,UAAU,CAAC,KAAK,IAAI,CAAA;CAC/D,CAAC,CAAA;AAEF,MAAM,MAAM,yBAAyB,GAAG,gBAAgB,CAAC;IACvD,aAAa,EAAE,MAAM,CAAA;IACrB,GAAG,EAAE,gBAAgB,CAAC,GAAG,CAAC,CAAA;IAC1B,cAAc,EAAE,OAAO,CAAA;IACvB,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,cAAc,CAAC,EAAE,MAAM,IAAI,CAAA;CAC5B,GAAG,IAAI,CAAC,CAAA;AAET,MAAM,WAAW,UAAU;IACzB,CAAC,GAAG,EAAE,MAAM,GAAG;QAAE,OAAO,EAAE,OAAO,CAAC;QAAC,QAAQ,EAAE,QAAQ,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC,CAAA;KAAE,CAAA;CACjF;AAED,MAAM,WAAW,iBAAiB;IAChC,UAAU,EAAE,UAAU,CAAA;IACtB,YAAY,EAAE,CAAC,GAAG,EAAE,oBAAoB,CAAC,UAAU,CAAC,KAAK,IAAI,CAAA;CAC9D;AAED,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,MAAM,GAAG,CAAA;IACnB,UAAU,EAAE,CAAC,EAAE,MAAM,EAAE,IAAI,EAAE,EAAE;QAAE,MAAM,CAAC,EAAE,GAAG,CAAC;QAAC,IAAI,CAAC,EAAE,MAAM,CAAA;KAAE,KAAK,IAAI,CAAA;CACxE;AAED,MAAM,WAAW,gBAAgB;IAC/B,aAAa,EAAE,GAAG,CAAC,MAAM,EAAE,cAAc,CAAC,CAAA;IAC1C,MAAM,EAAE,MAAM,IAAI,CAAA;IAClB,KAAK,EAAE,MAAM,IAAI,CAAA;CAClB;AAED,MAAM,WAAW,oBAAoB;IACnC,CAAC,GAAG,EAAE,MAAM,GAAG;QACb,eAAe,EAAE,MAAM,IAAI,CAAA;KAC5B,CAAA;CACF;AAED,MAAM,WAAW,kBAAkB;IACjC,KAAK,EAAE,CAAC,QAAQ,EAAE,KAAK,CAAC,SAAS,EAAE,GAAG,CAAC,EAAE,MAAM,GAAG,IAAI,EAAE,EAAE,CAAC,EAAE,MAAM,GAAG,IAAI,KAAK,MAAM,GAAG,SAAS,CAAA;IACjG,MAAM,EAAE,CAAC,GAAG,EAAE,MAAM,EAAE,QAAQ,EAAE,KAAK,CAAC,SAAS,KAAK,IAAI,CAAA;IACxD,OAAO,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAA;CAC/B;AAED,MAAM,WAAW,sBAAsB;IACrC,UAAU,EAAE,KAAK,CAAC,SAAS,CAAC,GAAG,CAAC,GAAG,IAAI,CAAA;IACvC,YAAY,EAAE,QAAQ,CAAC,KAAK,CAAA;CAC7B;AAED,MAAM,WAAW,iBAAiB;IAChC,MAAM,EAAE,MAAM,CAAA;IACd,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;CAChC;AAED,MAAM,WAAW,kBAAkB;IACjC,oBAAoB,EAAE,QAAQ,CAAA;IAC9B,sBAAsB,EAAE,QAAQ,CAAA;CACjC;AAED,eAAO,MAAM,kBAAkB;;;EAAyC,CAAA;AAExE,eAAO,MAAM,WAAW,kDAA+C,CAAA;AAEvE,eAAO,MAAM,oBAAoB,mDAAgD,CAAA;AAEjF,eAAO,MAAM,iBAAiB,mDAAgD,CAAA;AAE9E,eAAO,MAAM,YAAY,mDAAgD,CAAA;AAEzE,eAAO,MAAM,aAAa,+BAAsB,CAAA;AAEhD,eAAO,MAAM,UAAU,6BAAoB,CAAA;AAE3C,eAAO,MAAM,2BAA2B,sDAAmD,CAAA;AAE3F,eAAO,MAAM,YAAY,mDAAgD,CAAA;AAEzE,eAAO,MAAM,aAAa,6BAAoB,CAAA;AAE9C,eAAO,MAAM,oBAAoB,2DAAwD,CAAA;AAEzF,eAAO,MAAM,iBAAiB,iDAAmG,CAAA;AAEjI,eAAO,MAAM,aAAa,6CAAiD,CAAA;AAE3E,eAAO,MAAM,aAAa,6CAAkG,CAAA;AAE5H,eAAO,MAAM,eAAe,+BAAsB,CAAA"}
@@ -15,4 +15,4 @@ export const KeyboardAvoidContext = createContext(null);
15
15
  export const ScrollViewContext = createContext({ gestureRef: null, scrollOffset: new Animated.Value(0) });
16
16
  export const PortalContext = createContext(null);
17
17
  export const StickyContext = createContext({ registerStickyHeader: noop, unregisterStickyHeader: noop });
18
- export const NavSharedContext = createContext(null);
18
+ export const ProviderContext = createContext(null);
@@ -5,3 +5,4 @@ declare const eventConfigMap: {
5
5
  };
6
6
  };
7
7
  export default eventConfigMap;
8
+ //# sourceMappingURL=event.config.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"event.config.d.ts","sourceRoot":"","sources":["../event.config.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,cAAc,EAAE;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG;QAAE,OAAO,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,EAAE,CAAA;KAAE,CAAA;CAyB3E,CAAA;AAED,eAAe,cAAc,CAAA"}
@@ -5,3 +5,4 @@ export declare const getCustomEvent: (type: string | undefined, oe: any, { detai
5
5
  }, props?: Props) => any;
6
6
  declare const useInnerProps: (props?: Props, userRemoveProps?: RemoveProps, rawConfig?: RawConfig) => Record<string, (e: ExtendedNativeTouchEvent) => void> & Omit<Props, string>;
7
7
  export default useInnerProps;
8
+ //# sourceMappingURL=getInnerListeners.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getInnerListeners.d.ts","sourceRoot":"","sources":["../getInnerListeners.ts"],"names":[],"mappings":"AAIA,OAAO,EACL,KAAK,EAEL,SAAS,EAET,WAAW,EAEX,SAAS,EACT,wBAAwB,EAEzB,MAAM,2BAA2B,CAAA;AAsElC,eAAO,MAAM,cAAc,iCAErB,GAAG;;;WAKA,KAAK,QAgBb,CAAA;AAyID,QAAA,MAAM,aAAa,WACV,KAAK,6CAEA,SAAS,wBA8Dc,wBAAwB,KAAK,IAAI,uBA2BrE,CAAA;AACD,eAAe,aAAa,CAAA"}
@@ -3,7 +3,8 @@ import { collectDataset } from '@mpxjs/utils';
3
3
  import { omit, extendObject, useNavigation } from './utils';
4
4
  import eventConfigMap from './event.config';
5
5
  const globalEventState = {
6
- needPress: true
6
+ needPress: true,
7
+ identifier: null
7
8
  };
8
9
  const getTouchEvent = (type, event, config) => {
9
10
  const { navigation, propsRef, layoutRef } = config;
@@ -94,36 +95,48 @@ function checkIsNeedPress(e, type, ref) {
94
95
  ref.current.startTimer[type] = null;
95
96
  }
96
97
  }
98
+ function shouldHandleTapEvent(e, eventConfig) {
99
+ const { identifier } = e.nativeEvent.changedTouches[0];
100
+ return eventConfig.tap && globalEventState.identifier === identifier;
101
+ }
97
102
  function handleTouchstart(e, type, eventConfig) {
98
- // 阻止事件被释放放回对象池,导致对象复用 _stoppedEventTypes 状态被保留
99
103
  e.persist();
100
104
  const { innerRef } = eventConfig;
101
- globalEventState.needPress = true;
102
- innerRef.current.mpxPressInfo.detail = {
103
- x: e.nativeEvent.changedTouches[0].pageX,
104
- y: e.nativeEvent.changedTouches[0].pageY
105
- };
105
+ const touch = e.nativeEvent.changedTouches[0];
106
+ const { identifier } = touch;
107
+ const isSingle = e.nativeEvent.touches.length <= 1;
108
+ if (isSingle) {
109
+ // 仅在 touchstart 记录第一个单指触摸点
110
+ globalEventState.identifier = identifier;
111
+ globalEventState.needPress = true;
112
+ innerRef.current.mpxPressInfo.detail = {
113
+ x: touch.pageX,
114
+ y: touch.pageY
115
+ };
116
+ }
106
117
  handleEmitEvent('touchstart', e, type, eventConfig);
107
118
  if (eventConfig.longpress) {
108
- if (e._stoppedEventTypes?.has('longpress')) {
109
- return;
110
- }
111
- if (eventConfig.longpress.hasCatch) {
112
- e._stoppedEventTypes = e._stoppedEventTypes || new Set();
113
- e._stoppedEventTypes.add('longpress');
119
+ // 只有单指触摸时才启动长按定时器
120
+ if (isSingle) {
121
+ if (e._stoppedEventTypes?.has('longpress')) {
122
+ return;
123
+ }
124
+ if (eventConfig.longpress.hasCatch) {
125
+ e._stoppedEventTypes = e._stoppedEventTypes || new Set();
126
+ e._stoppedEventTypes.add('longpress');
127
+ }
128
+ innerRef.current.startTimer[type] && clearTimeout(innerRef.current.startTimer[type]);
129
+ innerRef.current.startTimer[type] = setTimeout(() => {
130
+ globalEventState.needPress = false;
131
+ handleEmitEvent('longpress', e, type, eventConfig);
132
+ }, 350);
114
133
  }
115
- innerRef.current.startTimer[type] && clearTimeout(innerRef.current.startTimer[type]);
116
- innerRef.current.startTimer[type] = setTimeout(() => {
117
- // 只要触发过longpress, 全局就不再触发tap
118
- globalEventState.needPress = false;
119
- handleEmitEvent('longpress', e, type, eventConfig);
120
- }, 350);
121
134
  }
122
135
  }
123
136
  function handleTouchmove(e, type, eventConfig) {
124
137
  const { innerRef } = eventConfig;
125
138
  handleEmitEvent('touchmove', e, type, eventConfig);
126
- if (eventConfig.tap) {
139
+ if (shouldHandleTapEvent(e, eventConfig)) {
127
140
  checkIsNeedPress(e, type, innerRef);
128
141
  }
129
142
  }
@@ -131,7 +144,8 @@ function handleTouchend(e, type, eventConfig) {
131
144
  const { innerRef, disableTap } = eventConfig;
132
145
  handleEmitEvent('touchend', e, type, eventConfig);
133
146
  innerRef.current.startTimer[type] && clearTimeout(innerRef.current.startTimer[type]);
134
- if (eventConfig.tap) {
147
+ // 只有单指触摸结束时才触发 tap
148
+ if (shouldHandleTapEvent(e, eventConfig)) {
135
149
  checkIsNeedPress(e, type, innerRef);
136
150
  if (!globalEventState.needPress || (type === 'bubble' && disableTap) || e._stoppedEventTypes?.has('tap')) {
137
151
  return;
@@ -10,3 +10,4 @@ interface AsyncSuspenseProps {
10
10
  }
11
11
  declare const AsyncSuspense: React.FC<AsyncSuspenseProps>;
12
12
  export default AsyncSuspense;
13
+ //# sourceMappingURL=mpx-async-suspense.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mpx-async-suspense.d.ts","sourceRoot":"","sources":["../mpx-async-suspense.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAY,aAAa,EAAkC,SAAS,EAAiB,MAAM,OAAO,CAAA;AAiGzG,UAAU,kBAAkB;IAC1B,IAAI,EAAE,WAAW,GAAG,MAAM,CAAA;IAC1B,SAAS,EAAE,MAAM,CAAA;IACjB,QAAQ,EAAE,MAAM,CAAA;IAChB,UAAU,EAAE,GAAG,CAAC;IAChB,UAAU,CAAC,EAAE,MAAM,aAAa,CAAC,OAAO,CAAC,CAAA;IACzC,WAAW,CAAC,EAAE,MAAM,aAAa,CAAC,OAAO,CAAC,CAAA;IAC1C,WAAW,EAAE,MAAM,OAAO,CAAC,SAAS,CAAC,CAAA;CACtC;AAID,QAAA,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAAC,kBAAkB,CA6E/C,CAAA;AAID,eAAe,aAAa,CAAA"}
@@ -100,8 +100,8 @@ const AsyncSuspense = ({ type, chunkName, moduleId, innerProps, getLoading, getF
100
100
  });
101
101
  });
102
102
  }
103
- if (type === 'page' && typeof mpxGlobal.__mpx.config?.rnConfig?.lazyLoadPageErrorHandler === 'function') {
104
- mpxGlobal.__mpx.config.rnConfig.lazyLoadPageErrorHandler({
103
+ if (type === 'page' && typeof mpxGlobal.__mpx.config?.rnConfig?.onLazyLoadPageError === 'function') {
104
+ mpxGlobal.__mpx.config.rnConfig.onLazyLoadPageError({
105
105
  subpackage: chunkName,
106
106
  errType: e.type
107
107
  });
@@ -66,3 +66,4 @@ export interface ButtonProps {
66
66
  }
67
67
  declare const Button: import("react").ForwardRefExoticComponent<ButtonProps & import("react").RefAttributes<HandlerRef<View, ButtonProps>>>;
68
68
  export default Button;
69
+ //# sourceMappingURL=mpx-button.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mpx-button.d.ts","sourceRoot":"","sources":["../mpx-button.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmCG;AACH,OAAO,EAAoC,SAAS,EAA+B,MAAM,OAAO,CAAA;AAChG,OAAO,EACL,IAAI,EAEJ,SAAS,EACT,SAAS,EAGT,oBAAoB,EAErB,MAAM,cAAc,CAAA;AAKrB,OAAoB,EAAE,UAAU,EAAE,MAAM,eAAe,CAAA;AAEvD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAA;AAGvD,MAAM,MAAM,IAAI,GAAG,SAAS,GAAG,SAAS,GAAG,MAAM,CAAA;AAOjD,MAAM,MAAM,QAAQ,GAAG,OAAO,GAAG,aAAa,CAAA;AAE9C,MAAM,MAAM,aAAa,GAAG,mBAAmB,GAAG,YAAY,CAAA;AAE9D,MAAM,WAAW,WAAW;IAC1B,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,IAAI,CAAC,EAAE,IAAI,CAAA;IACX,KAAK,CAAC,EAAE,OAAO,CAAA;IACf,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,aAAa,CAAC,EAAE,iBAAiB,CAAA;IACjC,kBAAkB,CAAC,EAAE,MAAM,CAAA;IAC3B,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,WAAW,CAAC,EAAE,QAAQ,CAAA;IACtB,WAAW,CAAC,EAAE,QAAQ,GAAG,OAAO,CAAA;IAChC,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,sBAAsB,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC5C,kBAAkB,CAAC,EAAE,MAAM,CAAA;IAC3B,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB,KAAK,CAAC,EAAE,SAAS,GAAG,SAAS,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IACnD,QAAQ,EAAE,SAAS,CAAA;IACnB,eAAe,CAAC,EAAE,CAAC,QAAQ,EAAE,GAAG,KAAK,IAAI,CAAA;IACzC,OAAO,CAAC,EAAE,CAAC,GAAG,EAAE,oBAAoB,CAAC,UAAU,CAAC,GAAG,OAAO,KAAK,IAAI,CAAA;CACpE;AA4GD,QAAA,MAAM,MAAM,uHAqOV,CAAA;AAIF,eAAe,MAAM,CAAA"}
@@ -0,0 +1,27 @@
1
+ import React from 'react';
2
+ interface CameraProps {
3
+ mode?: 'normal' | 'scanCode';
4
+ resolution?: 'low' | 'medium' | 'high';
5
+ devicePosition?: 'front' | 'back';
6
+ flash?: 'auto' | 'on' | 'off';
7
+ frameSize?: 'small' | 'medium' | 'large';
8
+ style?: Record<string, any>;
9
+ bindstop?: () => void;
10
+ binderror?: (error: {
11
+ message: string;
12
+ }) => void;
13
+ bindinitdone?: (result: {
14
+ type: string;
15
+ data: string;
16
+ }) => void;
17
+ bindscancode?: (result: {
18
+ type: string;
19
+ data: string;
20
+ }) => void;
21
+ }
22
+ type HandlerRef<T, P> = {
23
+ current: T | null;
24
+ };
25
+ declare const _camera: React.ForwardRefExoticComponent<CameraProps & React.RefAttributes<HandlerRef<any, CameraProps>>>;
26
+ export default _camera;
27
+ //# sourceMappingURL=mpx-camera.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mpx-camera.d.ts","sourceRoot":"","sources":["../mpx-camera.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA2E,MAAM,OAAO,CAAA;AAa/F,UAAU,WAAW;IACnB,IAAI,CAAC,EAAE,QAAQ,GAAG,UAAU,CAAA;IAC5B,UAAU,CAAC,EAAE,KAAK,GAAG,QAAQ,GAAG,MAAM,CAAA;IACtC,cAAc,CAAC,EAAE,OAAO,GAAG,MAAM,CAAA;IACjC,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,KAAK,CAAA;IAC7B,SAAS,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAA;IACxC,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC3B,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAA;IACrB,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE;QAAE,OAAO,EAAE,MAAM,CAAA;KAAE,KAAK,IAAI,CAAA;IAChD,YAAY,CAAC,EAAE,CAAC,MAAM,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,KAAK,IAAI,CAAA;IAC/D,YAAY,CAAC,EAAE,CAAC,MAAM,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,KAAK,IAAI,CAAA;CAChE;AA8BD,KAAK,UAAU,CAAC,CAAC,EAAE,CAAC,IAAI;IACtB,OAAO,EAAE,CAAC,GAAG,IAAI,CAAA;CAClB,CAAA;AAID,QAAA,MAAM,OAAO,kGAkNX,CAAA;AAIF,eAAe,OAAO,CAAA"}
@@ -0,0 +1,197 @@
1
+ import React, { forwardRef, useRef, useCallback, useContext, useState, useEffect } from 'react';
2
+ // import { Camera, useCameraDevice, useCodeScanner, useCameraFormat } from 'react-native-vision-camera'
3
+ import { getCustomEvent } from './getInnerListeners';
4
+ import { noop } from '@mpxjs/utils';
5
+ import { RouteContext } from './context';
6
+ const qualityValue = {
7
+ high: 90,
8
+ normal: 75,
9
+ low: 50,
10
+ original: 100
11
+ };
12
+ let RecordRes = null;
13
+ const _camera = forwardRef((props, ref) => {
14
+ // eslint-disable-next-line @typescript-eslint/no-var-requires
15
+ const { Camera, useCameraDevice, useCodeScanner, useCameraFormat } = require('react-native-vision-camera');
16
+ const cameraRef = useRef(null);
17
+ const { mode = 'normal', resolution = 'medium', devicePosition = 'back', flash = 'auto', frameSize = 'medium', bindinitdone, bindstop, bindscancode } = props;
18
+ const isPhoto = mode === 'normal';
19
+ const device = useCameraDevice(devicePosition || 'back');
20
+ const { navigation } = useContext(RouteContext) || {};
21
+ const [zoomValue, setZoomValue] = useState(1);
22
+ const [hasPermission, setHasPermission] = useState(null);
23
+ const hasCamera = useRef(false);
24
+ // 先定义常量,避免在条件判断后使用
25
+ const maxZoom = device?.maxZoom || 1;
26
+ const RESOLUTION_MAPPING = {
27
+ low: { width: 640, height: 480 },
28
+ medium: { width: 1280, height: 720 },
29
+ high: { width: 1920, height: 1080 }
30
+ };
31
+ const FRAME_SIZE_MAPPING = {
32
+ small: { width: 480, height: 360 },
33
+ medium: { width: 720, height: 540 },
34
+ large: { width: 1080, height: 810 }
35
+ };
36
+ // 所有 Hooks 必须在条件判断之前调用
37
+ const format = useCameraFormat(device, [
38
+ {
39
+ photoResolution: RESOLUTION_MAPPING[resolution],
40
+ videoResolution: FRAME_SIZE_MAPPING[frameSize] || RESOLUTION_MAPPING[resolution]
41
+ }
42
+ ]);
43
+ const codeScanner = useCodeScanner({
44
+ codeTypes: ['qr', 'ean-13'],
45
+ onCodeScanned: (codes) => {
46
+ const result = codes.map(code => code.value).join(',');
47
+ bindscancode && bindscancode(getCustomEvent('scancode', {}, {
48
+ detail: {
49
+ result: codes.map(code => code.value).join(',')
50
+ }
51
+ }));
52
+ }
53
+ });
54
+ const onInitialized = useCallback(() => {
55
+ bindinitdone && bindinitdone(getCustomEvent('initdone', {}, {
56
+ detail: {
57
+ maxZoom
58
+ }
59
+ }));
60
+ }, [bindinitdone, maxZoom]);
61
+ const onStopped = useCallback(() => {
62
+ bindstop && bindstop();
63
+ }, [bindstop]);
64
+ const camera = {
65
+ setZoom: (zoom) => {
66
+ setZoomValue(zoom);
67
+ },
68
+ takePhoto: (options = {}) => {
69
+ const { success = noop, fail = noop, complete = noop } = options;
70
+ cameraRef.current?.takePhoto?.({
71
+ quality: qualityValue[options.quality || 'normal']
72
+ }).then((res) => {
73
+ const result = {
74
+ errMsg: 'takePhoto:ok',
75
+ tempImagePath: res.path
76
+ };
77
+ success(result);
78
+ complete(result);
79
+ }).catch(() => {
80
+ const result = {
81
+ errMsg: 'takePhoto:fail'
82
+ };
83
+ fail(result);
84
+ complete(result);
85
+ });
86
+ },
87
+ startRecord: (options = {}) => {
88
+ let { timeout = 30, success = noop, fail = noop, complete = noop, timeoutCallback = noop } = options;
89
+ timeout = timeout > 300 ? 300 : timeout;
90
+ let recordTimer = null;
91
+ let isTimeout = false;
92
+ try {
93
+ const result = {
94
+ errMsg: 'startRecord:ok'
95
+ };
96
+ success(result);
97
+ complete(result);
98
+ cameraRef.current?.startRecording?.({
99
+ onRecordingError: (error) => {
100
+ if (recordTimer)
101
+ clearTimeout(recordTimer);
102
+ const errorResult = {
103
+ errMsg: 'startRecord:fail during recording',
104
+ error: error
105
+ };
106
+ timeoutCallback(errorResult);
107
+ },
108
+ onRecordingFinished: (video) => {
109
+ RecordRes = video;
110
+ if (recordTimer)
111
+ clearTimeout(recordTimer);
112
+ }
113
+ });
114
+ recordTimer = setTimeout(() => {
115
+ isTimeout = true;
116
+ cameraRef.current?.stopRecording().catch(() => {
117
+ // 忽略停止录制时的错误
118
+ });
119
+ }, timeout * 1000);
120
+ }
121
+ catch (error) {
122
+ if (recordTimer)
123
+ clearTimeout(recordTimer);
124
+ const result = {
125
+ errMsg: 'startRecord:fail ' + (error.message || 'unknown error')
126
+ };
127
+ fail(result);
128
+ complete(result);
129
+ }
130
+ },
131
+ stopRecord: (options = {}) => {
132
+ const { success = noop, fail = noop, complete = noop } = options;
133
+ try {
134
+ cameraRef.current?.stopRecording().then(() => {
135
+ setTimeout(() => {
136
+ if (RecordRes) {
137
+ const result = {
138
+ errMsg: 'stopRecord:ok',
139
+ tempVideoPath: RecordRes?.path,
140
+ duration: RecordRes.duration * 1000 // 转成ms
141
+ };
142
+ RecordRes = null;
143
+ success(result);
144
+ complete(result);
145
+ }
146
+ }, 200); // 延时200ms,确保录制结果已准备好
147
+ }).catch((e) => {
148
+ const result = {
149
+ errMsg: 'stopRecord:fail ' + (e.message || 'promise rejected')
150
+ };
151
+ fail(result);
152
+ complete(result);
153
+ });
154
+ }
155
+ catch (error) {
156
+ const result = {
157
+ errMsg: 'stopRecord:fail ' + (error.message || 'unknown error')
158
+ };
159
+ fail(result);
160
+ complete(result);
161
+ }
162
+ }
163
+ };
164
+ useEffect(() => {
165
+ if (navigation) {
166
+ if (navigation && !navigation.camera) {
167
+ navigation.camera = camera;
168
+ }
169
+ else {
170
+ hasCamera.current = true;
171
+ navigation.camera.multi = true;
172
+ }
173
+ }
174
+ const checkCameraPermission = async () => {
175
+ try {
176
+ const cameraPermission = global?.__mpx?.config?.rnConfig?.cameraPermission;
177
+ if (typeof cameraPermission === 'function') {
178
+ const permissionResult = await cameraPermission();
179
+ setHasPermission(permissionResult === true);
180
+ }
181
+ else {
182
+ setHasPermission(true);
183
+ }
184
+ }
185
+ catch (error) {
186
+ setHasPermission(false);
187
+ }
188
+ };
189
+ checkCameraPermission();
190
+ }, []);
191
+ if (!hasPermission || hasCamera.current || !device) {
192
+ return null;
193
+ }
194
+ return (<Camera ref={cameraRef} isActive={true} photo={true} video={true} onInitialized={onInitialized} onStopped={onStopped} device={device} flash={flash} format={format} codeScanner={!isPhoto ? codeScanner : undefined} style={{ flex: 1 }} zoom={zoomValue} {...props}/>);
195
+ });
196
+ _camera.displayName = 'MpxCamera';
197
+ export default _camera;
@@ -21,3 +21,4 @@ export default class Bus {
21
21
  clearBatchingTimeout(): void;
22
22
  }
23
23
  export {};
24
+ //# sourceMappingURL=Bus.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Bus.d.ts","sourceRoot":"","sources":["../../mpx-canvas/Bus.ts"],"names":[],"mappings":";AACA,UAAU,OAAO;IACf,EAAE,CAAC,EAAE,MAAM,CAAA;IACX,IAAI,EAAE,MAAM,CAAA;IACZ,OAAO,CAAC,EAAE,GAAG,CAAA;CACd;AACD,MAAM,CAAC,OAAO,OAAO,GAAG;IACtB,OAAO,EAAE,OAAO,CAAS;IACzB,iBAAiB,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,CAAC,OAAO,EAAE,OAAO,KAAK,IAAI,CAAA;KAAE,CAAK;IACrE,MAAM,EAAE,OAAO,EAAE,CAAK;IACtB,KAAK,EAAE,CAAC,OAAO,EAAE,OAAO,GAAG,OAAO,EAAE,KAAK,IAAI,CAAA;IAC7C,UAAU,EAAE,MAAM,CAAC,OAAO,GAAG,IAAI,CAAO;gBAC3B,IAAI,EAAE,CAAC,OAAO,EAAE,OAAO,GAAG,OAAO,EAAE,KAAK,IAAI;IAIzD,IAAI,CAAE,OAAO,EAAE,OAAO,GAAG,OAAO,CAAC,GAAG,CAAC;IAerC,MAAM,CAAE,OAAO,EAAE,OAAO,GAAG,IAAI;IAY/B,KAAK,IAAK,IAAI;IAId,MAAM,IAAK,IAAI;IAMf,aAAa,IAAK,IAAI;IAUtB,oBAAoB,IAAK,IAAI;CAM9B"}
@@ -5,3 +5,4 @@ export default class CanvasGradient {
5
5
  constructor(canvas: CanvasInstance, noOnConstruction?: boolean);
6
6
  postMessage(message: WebviewMessage): Promise<any>;
7
7
  }
8
+ //# sourceMappingURL=CanvasGradient.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CanvasGradient.d.ts","sourceRoot":"","sources":["../../mpx-canvas/CanvasGradient.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,cAAc,EAA0B,MAAM,SAAS,CAAA;AAGhF,MAAM,CAAC,OAAO,OAAO,cAAc;IACjC,OAAO,CAAC,MAAM,CAAiB;IAC/B,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;gBACN,MAAM,EAAE,cAAc,EAAE,gBAAgB,UAAQ;IAQ7D,WAAW,CAAE,OAAO,EAAE,cAAc;CAGrC"}
@@ -4,3 +4,4 @@ export default class CanvasRenderingContext2D {
4
4
  constructor(canvas: CanvasInstance);
5
5
  postMessage(message: WebviewMessage): Promise<any>;
6
6
  }
7
+ //# sourceMappingURL=CanvasRenderingContext2D.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CanvasRenderingContext2D.d.ts","sourceRoot":"","sources":["../../mpx-canvas/CanvasRenderingContext2D.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,cAAc,EAA4E,MAAM,SAAS,CAAA;AA0ElI,MAAM,CAAC,OAAO,OAAO,wBAAwB;IAC3C,MAAM,EAAE,cAAc,CAAA;gBACT,MAAM,EAAE,cAAc;IAOnC,WAAW,CAAE,OAAO,EAAE,cAAc;CAGrC"}
@@ -18,3 +18,4 @@ export declare class Image {
18
18
  get onerror(): ((...args: any[]) => void);
19
19
  }
20
20
  export declare function createImage(canvas: CanvasInstance, width?: number, height?: number): Image;
21
+ //# sourceMappingURL=Image.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Image.d.ts","sourceRoot":"","sources":["../../mpx-canvas/Image.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,cAAc,EAA6B,cAAc,EAAE,MAAM,SAAS,CAAA;AAUnG,qBAAa,KAAK;IAChB,CAAC,cAAc,CAAC,EAAE,MAAM,CAAC;IACzB,MAAM,EAAE,GAAG,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,aAAa,CAAM;IAC3B,OAAO,CAAC,cAAc,CAAM;IAC5B,OAAO,CAAC,OAAO,CAA6B;IAC5C,OAAO,CAAC,QAAQ,CAA6B;IAC7C,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;gBAEN,MAAM,EAAE,cAAc,EAAE,KAAK,CAAC,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,MAAM,EAAE,gBAAgB,UAAQ;IAuB9F,WAAW,CAAE,OAAO,EAAE,cAAc;IAIpC,gBAAgB,CAAE,IAAI,EAAE,MAAM,GAAG,OAAO,EAAE,UAAU,EAAE,QAAQ;IAsB9D,IAAI,MAAM,CAAE,QAAQ,EAAE,CAAC,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,IAAI,CAAC,EAQ/C;IAED,IAAI,MAAM,IAAK,CAAC,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,IAAI,CAAC,CAExC;IAED,IAAI,OAAO,CAAE,QAAQ,EAAE,CAAC,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,IAAI,CAAC,EAQhD;IAED,IAAI,OAAO,IAAM,CAAC,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,IAAI,CAAC,CAE1C;CACF;AAED,wBAAgB,WAAW,CAAE,MAAM,EAAE,cAAc,EAAE,KAAK,CAAC,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,MAAM,SAEnF"}
@@ -6,3 +6,4 @@ export default class ImageData {
6
6
  postMessage: (message: WebviewMessage) => Promise<any>;
7
7
  }
8
8
  export declare function createImageData(canvas: CanvasInstance, dataArray: number[], width: number, height: number): ImageData;
9
+ //# sourceMappingURL=ImageData.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ImageData.d.ts","sourceRoot":"","sources":["../../mpx-canvas/ImageData.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,cAAc,EACd,cAAc,EACf,MAAM,SAAS,CAAA;AAEhB,MAAM,CAAC,OAAO,OAAO,SAAS;IAC5B,MAAM,EAAE,cAAc,CAAC;IACvB,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;gBACN,MAAM,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,gBAAgB,CAAC,EAAE,OAAO;IAOnH,WAAW,YAAa,cAAc,kBAEpC;CACH;AAED,wBAAgB,eAAe,CAAE,MAAM,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,aAE1G"}
@@ -8,3 +8,4 @@ export declare function useConstructorsRegistry(): {
8
8
  register: (registerWebviewConstructor: Function) => void;
9
9
  getConstructor: (type: ConstructorType) => WebviewConstructor | undefined;
10
10
  };
11
+ //# sourceMappingURL=constructorsRegistry.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constructorsRegistry.d.ts","sourceRoot":"","sources":["../../mpx-canvas/constructorsRegistry.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAA;AAE5C,oBAAY,eAAe;IACzB,KAAK,UAAU;IACf,cAAc,mBAAmB;IACjC,SAAS,cAAc;CACxB;AAaD,wBAAgB,uBAAuB;2CACS,QAAQ,KAAG,IAAI;2BAM/B,eAAe,KAAG,kBAAkB,GAAG,SAAS;EAQ/E"}
@@ -1,2 +1,3 @@
1
1
  declare const _default: "<html><head>\n <meta content=\"width=device-width, initial-scale=1, maximum-scale=1, user-scaleable=no\" name=\"viewport\">\n <style>\n html {\n -ms-content-zooming: none;\n -ms-touch-action: pan-x pan-y;\n }\n body {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n margin: 0;\n padding: 0;\n overflow: hidden;\n }\n * {\n user-select: none;\n -ms-user-select: none;\n -moz-user-select: none;\n -webkit-user-select: none;\n }\n </style>\n </head>\n <body>\n <script>\n var scale = function (ratio) {\n return function (item) {\n if (typeof item === \"number\") {\n return item * ratio;\n }\n return item;\n };\n};\nfunction autoScaleCanvas(canvas) {\n var ctx = canvas.getContext(\"2d\");\n var ratio = window.devicePixelRatio || 1;\n if (ratio !== 1) {\n canvas.width *= ratio;\n canvas.height *= ratio;\n ctx.scale(ratio, ratio);\n ctx.isPointInPath = function () {\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i] = arguments[_i];\n }\n return CanvasRenderingContext2D.prototype.isPointInPath.apply(ctx, args.map(scale(ratio)));\n };\n }\n return canvas;\n}\nwindow.autoScaleCanvas = autoScaleCanvas;\n</script>\n<script>\n\nvar WEBVIEW_TARGET = '@@WEBVIEW_TARGET';\n\nvar ID = function () {\n return Math.random().toString(32).slice(2);\n};\n\nvar flattenObjectCopyValue = function (flatObj, srcObj, key) {\n var value = srcObj[key];\n if (typeof value === 'function') {\n return;\n }\n if (typeof value === 'object' && value instanceof Node) {\n return;\n }\n flatObj[key] = flattenObject(value);\n};\n\nvar flattenObject = function (object) {\n if (typeof object !== 'object' || object === null) {\n return object;\n }\n // Handle TypedArray\n if (object instanceof Uint8ClampedArray) {\n return Array.from(object);\n }\n var flatObject = {};\n for (var key in object) {\n flattenObjectCopyValue(flatObject, object, key);\n }\n for (var key in Object.getOwnPropertyNames(object)) {\n flattenObjectCopyValue(flatObject, object, key);\n }\n return flatObject;\n};\n\nvar AutoScaledCanvas = function (element) {\n this.element = element;\n};\n\nAutoScaledCanvas.prototype.toDataURL = function () {\n return this.element.toDataURL.apply(this.element, arguments);\n};\n\nAutoScaledCanvas.prototype.autoScale = function () {\n if (this.savedHeight !== undefined) {\n this.element.height = this.savedHeight;\n }\n if (this.savedWidth !== undefined) {\n this.element.width = this.savedWidth;\n }\n window.autoScaleCanvas(this.element);\n};\n\nObject.defineProperty(AutoScaledCanvas.prototype, 'width', {\n get: function () {\n return this.element.width;\n },\n set: function (value) {\n this.savedWidth = value;\n this.autoScale();\n return value;\n },\n});\n\nObject.defineProperty(AutoScaledCanvas.prototype, 'height', {\n get: function () {\n return this.element.height;\n },\n set: function (value) {\n this.savedHeight = value;\n this.autoScale();\n return value;\n },\n});\nvar toMessage = function (result) {\n if (result instanceof Blob) {\n return {\n type: 'blob',\n payload: btoa(result),\n meta: {},\n };\n }\n if (result instanceof Object) {\n if (!result[WEBVIEW_TARGET]) {\n var id = ID();\n result[WEBVIEW_TARGET] = id;\n targets[id] = result;\n }\n return {\n type: 'json',\n payload: flattenObject(result),\n args: toArgs(flattenObject(result)),\n meta: {\n target: result[WEBVIEW_TARGET],\n constructor: result.__constructorName__ || result.constructor.name,\n },\n };\n }\n return {\n type: 'json',\n payload: typeof result === 'string' ? result : JSON.stringify(result),\n meta: {},\n };\n};\nvar toArgs = function (result) {\n var args = [];\n for (var key in result) {\n if (result[key] !== undefined && key !== '@@WEBVIEW_TARGET') {\n args.push(result[key]);\n }\n }\n return args;\n};\n\nvar createObjectsFromArgs = function (args) {\n for (var index = 0; index < args.length; index += 1) {\n var currentArg = args[index];\n if (currentArg && currentArg.className !== undefined) {\n var className = currentArg.className, classArgs = currentArg.classArgs;\n // new ImageData,第一个参数需要是 Uint8ClampedArray\n var object = new (Function.prototype.bind.apply(constructors[className], [null].concat(classArgs)))();\n args[index] = object;\n }\n }\n return args;\n};\n\nvar canvas = document.createElement('canvas');\ncanvas.style.width = '100%';\ncanvas.style.height = '100%';\nvar autoScaledCanvas = new AutoScaledCanvas(canvas);\n\nvar targets = {\n canvas: autoScaledCanvas,\n context2D: canvas.getContext('2d'),\n};\n\nvar constructors = {\n CanvasGradient: CanvasGradient,\n Image: Image,\n ImageData: ImageData,\n Uint8ClampedArray: Uint8ClampedArray,\n};\n\nImage.bind =\n Image.bind ||\n function () {\n return Image;\n };\n\nImageData.bind =\n ImageData.bind ||\n function () {\n return ImageData;\n };\nUint8ClampedArray.bind =\n Uint8ClampedArray.bind ||\n function () {\n return Uint8ClampedArray;\n };\n\nvar populateRefs = function (arg) {\n if (arg && arg.__ref__) {\n return targets[arg.__ref__];\n }\n return arg;\n};\ndocument.body.appendChild(canvas);\n\nvar mergeObjects = function (target, source) {\n for (var key in source) {\n if (source.hasOwnProperty(key)) {\n target[key] = source[key];\n }\n }\n return target;\n};\n\nfunction handleMessage(message) {\n var id = message.id,\n type = message.type,\n payload = message.payload;\n\n switch (type) {\n case 'exec': {\n var target = payload.target,\n method = payload.method,\n args = payload.args;\n var result = targets[target][method].apply(targets[target], args.map(populateRefs));\n var msg = toMessage(result);\n\n if (typeof result === 'object' && !msg.meta.constructor) {\n for (var constructorName in constructors) {\n if (result instanceof constructors[constructorName]) {\n msg.meta.constructor = constructorName;\n }\n }\n }\n window.ReactNativeWebView.postMessage(JSON.stringify(mergeObjects({ id: id }, msg)));\n break;\n }\n case 'set': {\n var target = payload.target,\n key = payload.key,\n value = payload.value;\n targets[target][key] = populateRefs(value);\n break;\n }\n case 'construct': {\n var constructor = payload.constructor,\n target = payload.id,\n args = payload.args || [];\n var newArgs = createObjectsFromArgs(args);\n var object;\n try {\n object = new (Function.prototype.bind.apply(constructors[constructor], [null].concat(newArgs)))();\n }\n catch (error) {\n throw new Error('Error while constructing '.concat(constructor, ' ').concat(error.message));\n }\n object.__constructorName__ = constructor;\n var msg = toMessage({});\n targets[target] = object;\n window.ReactNativeWebView.postMessage(JSON.stringify(mergeObjects({ id: id }, msg)));\n break;\n }\n case 'listen': {\n var types = payload.types,\n target = payload.target;\n for (var i = 0; i < types.length; i++) {\n var eventType = types[i];\n targets[target].addEventListener(eventType, function (e) {\n const message = toMessage({\n type: 'event',\n payload: {\n type: e.type,\n target: mergeObjects(flattenObject(targets[target]), {\n [WEBVIEW_TARGET]: target,\n }),\n },\n });\n window.ReactNativeWebView.postMessage(\n JSON.stringify(mergeObjects({ id: id }, message))\n );\n });\n }\n break;\n}\n }\n}\nvar handleError = function (err, message) {\n window.ReactNativeWebView.postMessage(JSON.stringify({\n id: message.id,\n type: 'error',\n payload: {\n message: err.message,\n stack: err.stack,\n },\n }));\n document.removeEventListener('message', handleIncomingMessage);\n};\n\nfunction handleIncomingMessage(data) {\n if (Array.isArray(data)) {\n for (var i = 0; i < data.length; i++) {\n try {\n handleMessage(data[i]);\n } catch (err) {\n handleError(err, data[i]);\n }\n }\n } else {\n try {\n handleMessage(data);\n } catch (err) {\n handleError(err, data);\n }\n }\n}\n\nwindow.mpxWebviewMessageCallback = handleIncomingMessage\n</script>\n \n\n</body></html>";
2
2
  export default _default;
3
+ //# sourceMappingURL=html.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"html.d.ts","sourceRoot":"","sources":["../../mpx-canvas/html.ts"],"names":[],"mappings":";AAAA,wBAoVe"}
@@ -30,3 +30,4 @@ interface CanvasProps {
30
30
  }
31
31
  declare const _Canvas: import("react").ForwardRefExoticComponent<CanvasProps & import("react").RefAttributes<HandlerRef<CanvasProps & View, CanvasProps>>>;
32
32
  export default _Canvas;
33
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../mpx-canvas/index.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,OAAO,EAA4E,UAAU,EAAoB,MAAM,OAAO,CAAA;AAC9H,OAAO,EAAE,IAAI,EAAwB,oBAAoB,EAAE,MAAM,cAAc,CAAA;AAE/E,OAAoB,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAA;AAexD,OAAO,kBAAkB,CAAA;AAqBzB,UAAU,WAAW;IACnB,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC3B,eAAe,CAAC,EAAE,KAAK,CAAC,MAAM,CAAC,CAAA;IAC/B,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,kBAAkB,CAAC,EAAE,MAAM,CAAA;IAC3B,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB,sBAAsB,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC5C,cAAc,CAAC,EAAE,CAAC,KAAK,EAAE,oBAAoB,CAAC,UAAU,CAAC,KAAK,IAAI,CAAA;IAClE,aAAa,CAAC,EAAE,CAAC,KAAK,EAAE,oBAAoB,CAAC,UAAU,CAAC,KAAK,IAAI,CAAA;IACjE,YAAY,CAAC,EAAE,CAAC,KAAK,EAAE,oBAAoB,CAAC,UAAU,CAAC,KAAK,IAAI,CAAA;IAChE,eAAe,CAAC,EAAE,CAAC,KAAK,EAAE,oBAAoB,CAAC,UAAU,CAAC,KAAK,IAAI,CAAA;IACnE,WAAW,CAAC,EAAE,CAAC,KAAK,EAAE,oBAAoB,CAAC,UAAU,CAAC,KAAK,IAAI,CAAA;IAC/D,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE,oBAAoB,CAAC,UAAU,CAAC,KAAK,IAAI,CAAA;CAC9D;AAED,QAAA,MAAM,OAAO,qIAoPX,CAAA;AAIF,eAAe,OAAO,CAAA"}
@@ -50,3 +50,4 @@ export declare const useWebviewBinding: ({ targetName, properties, methods }: {
50
50
  properties?: Record<string, any> | undefined;
51
51
  methods?: string[] | undefined;
52
52
  }) => import("react").MutableRefObject<{}>;
53
+ //# sourceMappingURL=utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../mpx-canvas/utils.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAA;AAC9C,OAAO,GAAG,MAAM,OAAO,CAAA;AAEvB,eAAO,MAAM,cAAc,qBAAqB,CAAA;AAEhD,eAAO,MAAM,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAM,CAAA;AAEnD,eAAO,MAAM,EAAE,cAA4C,CAAA;AAS3D,MAAM,WAAW,QAAQ;IACvB,WAAW,EAAE,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,IAAI,CAAC;IACtC,CAAC,cAAc,CAAC,CAAC,EAAE,MAAM,CAAC;IAC1B,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;CACpB;AAED,MAAM,WAAW,kBAAkB;IACjC,KAAK,GAAG,IAAI,EAAE,GAAG,EAAE,GAAG,QAAQ,CAAC;IAC/B,gBAAgB,CAAC,EAAE,CAAC,GAAG,IAAI,EAAE,OAAO,EAAE,KAAK,QAAQ,CAAC;CACrD;AAED,MAAM,WAAW,cAAc;IAC7B,IAAI,EAAE,KAAK,GAAG,MAAM,GAAG,QAAQ,GAAG,OAAO,GAAG,WAAW,CAAA;IACvD,OAAO,EAAE;QACP,MAAM,CAAC,EAAE,MAAM,GAAG;YAAE,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;SAAE,CAAA;QACxC,GAAG,CAAC,EAAE,MAAM,CAAA;QACZ,KAAK,CAAC,EAAE,GAAG,CAAA;QACX,MAAM,CAAC,EAAE,MAAM,CAAA;QACf,IAAI,CAAC,EAAE,GAAG,EAAE,CAAA;QACZ,KAAK,CAAC,EAAE,MAAM,EAAE,CAAA;QAChB,IAAI,CAAC,EAAE,MAAM,CAAA;QACb,WAAW,CAAC,EAAE,MAAM,GAAG,QAAQ,CAAA;QAC/B,EAAE,CAAC,EAAE,MAAM,CAAA;KACZ,CAAA;CACF;AAED,MAAM,WAAW,cAAc;IAC7B,OAAO,EAAE,OAAO,GAAG,IAAI,CAAC;IACxB,GAAG,EAAE,GAAG,GAAG,IAAI,CAAC;IAChB,SAAS,EAAE,wBAAwB,CAAC;IACpC,UAAU,EAAE,CAAC,WAAW,EAAE,MAAM,KAAK,wBAAwB,GAAG,IAAI,CAAC;IACrE,WAAW,EAAE,CAAC,KAAK,CAAC,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,MAAM,KAAK,GAAG,CAAC;IACtD,WAAW,EAAE,CAAC,OAAO,EAAE,cAAc,KAAK,OAAO,CAAC,GAAG,CAAC,CAAC;IACvD,SAAS,EAAE,KAAK,CAAC,CAAC,OAAO,EAAE,GAAG,KAAK,IAAI,CAAC,CAAC;IACzC,kBAAkB,EAAE,CAAC,QAAQ,EAAE,CAAC,OAAO,EAAE,GAAG,KAAK,IAAI,KAAK,MAAM,IAAI,CAAC;IACrE,qBAAqB,EAAE,CAAC,QAAQ,EAAE,CAAC,OAAO,EAAE,GAAG,KAAK,IAAI,KAAK,IAAI,CAAC;IAClE,eAAe,EAAE,CAAC,SAAS,EAAE,MAAM,EAAE,EAAE,KAAK,CAAC,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,MAAM,KAAK,GAAG,CAAC;CAChF;AAED,eAAO,MAAM,qBAAqB,aAAc,QAAQ,cAAc,MAAM,KAAG,IAE9E,CAAA;AAED,eAAO,MAAM,yBAAyB,aAAc,QAAQ,cAAc,OAAO,MAAM,EAAE,GAAG,CAAC,KAAG,IA2B/F,CAAA;AAED,eAAO,MAAM,sBAAsB,aAAc,QAAQ,WAAW,MAAM,EAAE,KAAG,IAa9E,CAAA;AAED,eAAO,MAAM,0BAA0B,gBAAiB,kBAAkB,mBAAmB,MAAM,KAAG,IAwBrG,CAAA;AACD,eAAO,MAAM,iBAAiB;gBAKhB,MAAM;;;0CAenB,CAAA"}
@@ -18,3 +18,4 @@ export interface CheckboxGroupProps {
18
18
  }
19
19
  declare const CheckboxGroup: import("react").ForwardRefExoticComponent<CheckboxGroupProps & import("react").RefAttributes<HandlerRef<View, CheckboxGroupProps>>>;
20
20
  export default CheckboxGroup;
21
+ //# sourceMappingURL=mpx-checkbox-group.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mpx-checkbox-group.d.ts","sourceRoot":"","sources":["../mpx-checkbox-group.tsx"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAIL,SAAS,EAKV,MAAM,OAAO,CAAA;AACd,OAAO,EACL,IAAI,EACJ,oBAAoB,EACpB,SAAS,EACV,MAAM,cAAc,CAAA;AAIrB,OAAoB,EAAE,UAAU,EAAE,MAAM,eAAe,CAAA;AAIvD,MAAM,WAAW,kBAAkB;IACjC,IAAI,EAAE,MAAM,CAAA;IACZ,KAAK,CAAC,EAAE,SAAS,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IACvC,eAAe,CAAC,EAAE,OAAO,CAAA;IACzB,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,sBAAsB,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC5C,kBAAkB,CAAC,EAAE,MAAM,CAAA;IAC3B,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB,QAAQ,EAAE,SAAS,CAAA;IACnB,UAAU,CAAC,EAAE,CAAC,GAAG,EAAE,oBAAoB,CAAC,UAAU,CAAC,GAAG,OAAO,KAAK,IAAI,CAAA;CACvE;AAED,QAAA,MAAM,aAAa,qIAkJjB,CAAA;AAIF,eAAe,aAAa,CAAA"}
@@ -30,3 +30,4 @@ export interface CheckboxProps extends Selection {
30
30
  }
31
31
  declare const Checkbox: import("react").ForwardRefExoticComponent<CheckboxProps & import("react").RefAttributes<HandlerRef<View, CheckboxProps>>>;
32
32
  export default Checkbox;
33
+ //# sourceMappingURL=mpx-checkbox.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mpx-checkbox.d.ts","sourceRoot":"","sources":["../mpx-checkbox.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EAML,SAAS,EAKV,MAAM,OAAO,CAAA;AACd,OAAO,EACL,IAAI,EAEJ,SAAS,EACT,oBAAoB,EACrB,MAAM,cAAc,CAAA;AAGrB,OAAoB,EAAE,UAAU,EAAE,MAAM,eAAe,CAAA;AAMvD,UAAU,SAAS;IACjB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB;AAED,MAAM,WAAW,aAAc,SAAQ,SAAS;IAC9C,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,KAAK,CAAC,EAAE,SAAS,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IACvC,UAAU,CAAC,EAAE,KAAK,CAAC,MAAM,CAAC,CAAA;IAC1B,eAAe,CAAC,EAAE,OAAO,CAAA;IACzB,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,sBAAsB,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC5C,kBAAkB,CAAC,EAAE,MAAM,CAAA;IAC3B,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB,QAAQ,CAAC,EAAE,SAAS,CAAA;IACpB,OAAO,CAAC,EAAE,CAAC,GAAG,EAAE,oBAAoB,CAAC,UAAU,CAAC,GAAG,OAAO,KAAK,IAAI,CAAA;IACnE,SAAS,CAAC,EAAE,CAAC,GAAG,EAAE,oBAAoB,CAAC,UAAU,CAAC,GAAG,OAAO,EAAE,EAAE,OAAO,EAAE,EAAE;QAAE,OAAO,EAAE,OAAO,CAAA;KAAE,KAAK,IAAI,CAAA;CACzG;AA6BD,QAAA,MAAM,QAAQ,2HA8Jb,CAAA;AAID,eAAe,QAAQ,CAAA"}
@@ -25,3 +25,4 @@ interface FormProps {
25
25
  }
26
26
  declare const _Form: import("react").ForwardRefExoticComponent<FormProps & import("react").RefAttributes<HandlerRef<View, FormProps>>>;
27
27
  export default _Form;
28
+ //# sourceMappingURL=mpx-form.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mpx-form.d.ts","sourceRoot":"","sources":["../mpx-form.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAA;AACnC,OAAO,EAA2B,SAAS,EAA0B,MAAM,OAAO,CAAA;AAClF,OAAoB,EAAE,UAAU,EAAE,MAAM,eAAe,CAAA;AAIvD,UAAU,SAAS;IACjB,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC3B,QAAQ,CAAC,EAAE,SAAS,CAAA;IACpB,eAAe,CAAC,EAAE,OAAO,CAAA;IACzB,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,sBAAsB,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC5C,kBAAkB,CAAC,EAAE,MAAM,CAAA;IAC3B,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB,UAAU,CAAC,EAAE,CAAC,GAAG,EAAE;QACjB,MAAM,EAAE;YACN,KAAK,EAAE,GAAG,CAAA;SACX,CAAA;KACF,KAAK,IAAI,CAAA;IACV,SAAS,CAAC,EAAE,MAAM,IAAI,CAAA;CACvB;AAED,QAAA,MAAM,KAAK,mHA+FT,CAAA;AAIF,eAAe,KAAK,CAAA"}