@shijiu/jsview-vue 2.2.128 → 2.2.373

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 (325) hide show
  1. package/bin/browser/BrowserApic.vue.mjs +4 -15
  2. package/bin/browser/BrowserApic2.vue.mjs +4 -15
  3. package/bin/browser/BrowserApicLib.mjs +32 -26
  4. package/bin/browser/BrowserAudio.vue.mjs +2 -10
  5. package/bin/browser/BrowserJsvFragShaderView.vue.mjs +79 -0
  6. package/bin/browser/BrowserJsvLatex.vue.mjs +39 -16
  7. package/bin/browser/BrowserPreload.vue.mjs +1 -5
  8. package/bin/browser/BrowserQrcode.vue.mjs +1 -5
  9. package/bin/browser/BrowserSpray.vue.mjs +2 -12
  10. package/bin/browser/BrowserTextureAnim.vue.mjs +2 -12
  11. package/bin/export-sfc.mjs +3 -3
  12. package/bin/jsview-vue-common.mjs +3 -3
  13. package/bin/jsview-vue.mjs +4636 -2325
  14. package/bin/types/JsViewEngineWidget/CheckType.d.ts +4 -0
  15. package/bin/types/JsViewEngineWidget/JsvFocus/JsvFocusBlock.vue.d.ts +37 -33
  16. package/bin/types/JsViewEngineWidget/JsvFocus/JsvFocusHub.d.ts +4 -0
  17. package/bin/types/JsViewEngineWidget/JsvFocus/JsvFocusManager.d.ts +21 -6
  18. package/bin/types/JsViewEngineWidget/MetroWidget/Const.d.ts +4 -0
  19. package/bin/types/JsViewEngineWidget/MetroWidget/Dispatcher.d.ts +14 -12
  20. package/bin/types/JsViewEngineWidget/MetroWidget/ListWidget.vue.d.ts +17 -6
  21. package/bin/types/JsViewEngineWidget/MetroWidget/MetroWidget.vue.d.ts +283 -6
  22. package/bin/types/JsViewEngineWidget/MetroWidget/MetroWidgetSetup.d.ts +9 -3
  23. package/bin/types/JsViewEngineWidget/MetroWidget/PageUpdater.d.ts +4 -0
  24. package/bin/types/JsViewEngineWidget/MetroWidget/RenderItem.d.ts +7 -0
  25. package/bin/types/JsViewEngineWidget/MetroWidget/Slide.d.ts +4 -0
  26. package/bin/types/JsViewEngineWidget/MetroWidget/SlotComponent.vue.d.ts +4 -0
  27. package/bin/types/JsViewEngineWidget/MetroWidget/VisibleInfo.d.ts +4 -0
  28. package/bin/types/JsViewEngineWidget/MetroWidget/WidgetRectInfo.d.ts +4 -0
  29. package/bin/types/JsViewEngineWidget/RangeModel.d.ts +4 -0
  30. package/bin/types/JsViewEngineWidget/TemplateParser/CommonMetroTemplate.d.ts +4 -0
  31. package/bin/types/JsViewEngineWidget/TemplateParser/Fence.d.ts +4 -0
  32. package/bin/types/JsViewEngineWidget/TemplateParser/ListMetroTemplate.d.ts +5 -0
  33. package/bin/types/JsViewEngineWidget/TemplateParser/MetroTemplate.d.ts +4 -0
  34. package/bin/types/JsViewEngineWidget/TemplateParser/TemplateItemAdder.d.ts +5 -1
  35. package/bin/types/JsViewEngineWidget/TemplateParser/index.d.ts +4 -0
  36. package/bin/types/JsViewEngineWidget/WidgetCommon.d.ts +4 -0
  37. package/bin/types/JsViewEngineWidget/index.d.ts +14 -1
  38. package/bin/types/JsViewPlugin/JsvAccount/JsvAccount.d.ts +4 -0
  39. package/bin/types/JsViewPlugin/JsvAudio/AudioProxy.d.ts +4 -0
  40. package/bin/types/JsViewPlugin/JsvAudio/BrowserAudio/BrowserAudio.vue.d.ts +4 -0
  41. package/bin/types/JsViewPlugin/JsvAudio/BrowserAudio/JsvSystemAudio.vue.d.ts +4 -0
  42. package/bin/types/JsViewPlugin/JsvAudio/CheckType.d.ts +4 -0
  43. package/bin/types/JsViewPlugin/JsvAudio/Events.d.ts +4 -0
  44. package/bin/types/JsViewPlugin/JsvAudio/JsvAudio.vue.d.ts +4 -0
  45. package/bin/types/JsViewPlugin/JsvAudio/JsvAudioBridgeProxy.d.ts +4 -0
  46. package/bin/types/JsViewPlugin/JsvAudio/JsvAudioProxy.vue.d.ts +4 -0
  47. package/bin/types/JsViewPlugin/JsvAudio/PluginLoader.d.ts +4 -0
  48. package/bin/types/JsViewPlugin/JsvAudio/ScreenLockManager.d.ts +4 -0
  49. package/bin/types/JsViewPlugin/JsvAudio/index.d.ts +4 -0
  50. package/bin/types/JsViewPlugin/JsvAudio/version.d.ts +5 -0
  51. package/bin/types/JsViewPlugin/JsvLatex/BrowserDomBuilder.d.ts +4 -0
  52. package/bin/types/JsViewPlugin/JsvLatex/BrowserJsvLatex.vue.d.ts +4 -0
  53. package/bin/types/JsViewPlugin/JsvLatex/Color.d.ts +4 -0
  54. package/bin/types/JsViewPlugin/JsvLatex/JsvLatex.vue.d.ts +24 -0
  55. package/bin/types/JsViewPlugin/JsvLatex/JsvLatexBridgeProxy.d.ts +4 -0
  56. package/bin/types/JsViewPlugin/JsvLatex/JsvLatexProxy.vue.d.ts +4 -0
  57. package/bin/types/JsViewPlugin/JsvLatex/PluginLoader.d.ts +4 -0
  58. package/bin/types/JsViewPlugin/JsvLatex/index.d.ts +5 -0
  59. package/bin/types/JsViewPlugin/JsvLatex/version.d.ts +4 -0
  60. package/bin/types/JsViewPlugin/index.d.ts +4 -0
  61. package/bin/types/JsViewVueTools/ConstSymbol.d.ts +6 -2
  62. package/bin/types/JsViewVueTools/DebugContentShellJBridge.d.ts +4 -0
  63. package/bin/types/JsViewVueTools/DebugTool.d.ts +4 -0
  64. package/bin/types/JsViewVueTools/DefaultKeyMap.d.ts +4 -0
  65. package/bin/types/JsViewVueTools/FeatureActive.d.ts +14 -0
  66. package/bin/types/JsViewVueTools/ForgeConstDefine.d.ts +4 -0
  67. package/bin/types/JsViewVueTools/ForgeHandles.d.ts +7 -3
  68. package/bin/types/JsViewVueTools/JsvDemoTester.d.ts +4 -0
  69. package/bin/types/JsViewVueTools/JsvDynamicCssStyle.d.ts +20 -1
  70. package/bin/types/JsViewVueTools/JsvDynamicKeyFrames.d.ts +21 -2
  71. package/bin/types/JsViewVueTools/JsvFederationTools.d.ts +20 -0
  72. package/bin/types/JsViewVueTools/JsvHashHistory.d.ts +4 -0
  73. package/bin/types/JsViewVueTools/JsvImpactTracer.d.ts +8 -4
  74. package/bin/types/JsViewVueTools/JsvPerformance.d.ts +9 -0
  75. package/bin/types/JsViewVueTools/JsvPreDownloader.d.ts +55 -0
  76. package/bin/types/JsViewVueTools/JsvRefTaker.d.ts +28 -3
  77. package/bin/types/JsViewVueTools/JsvRuntimeBridge.d.ts +50 -0
  78. package/bin/types/JsViewVueTools/JsvStyleClass.d.ts +4 -0
  79. package/bin/types/JsViewVueTools/JsvStyleSheetsDeclarer.d.ts +21 -1
  80. package/bin/types/JsViewVueTools/JsvTextTools.d.ts +85 -27
  81. package/bin/types/JsViewVueTools/JsvTextureDefines.d.ts +4 -0
  82. package/bin/types/JsViewVueTools/JsvTextureLoadTool.d.ts +67 -0
  83. package/bin/types/JsViewVueTools/JsvTextureStore/CanvasTexture/CanvasTexture.d.ts +4 -0
  84. package/bin/types/JsViewVueTools/JsvTextureStore/CanvasTexture/CommandList.d.ts +4 -0
  85. package/bin/types/JsViewVueTools/JsvTextureStore/CanvasTexture/Path.d.ts +4 -0
  86. package/bin/types/JsViewVueTools/JsvTextureStore/CapturedTexture/CapturedTexture.d.ts +4 -0
  87. package/bin/types/JsViewVueTools/JsvTextureStore/JsvTextureStore.d.ts +73 -3
  88. package/bin/types/JsViewVueTools/JsvTextureStore/Store.d.ts +4 -0
  89. package/bin/types/JsViewVueTools/JsvTextureStore/Texture.d.ts +4 -0
  90. package/bin/types/JsViewVueTools/NinePatchHelper.d.ts +5 -1
  91. package/bin/types/JsViewVueTools/TextureManagerTools.d.ts +11 -0
  92. package/bin/types/JsViewVueTools/TypeCheckAndSet.d.ts +4 -0
  93. package/bin/types/JsViewVueTools/index.d.ts +26 -11
  94. package/bin/types/JsViewVueWidget/JsvActorMove/ActorControlBase.d.ts +4 -0
  95. package/bin/types/JsViewVueWidget/JsvActorMove/JsvActorMove.vue.d.ts +38 -0
  96. package/bin/types/JsViewVueWidget/JsvActorMove/JsvActorMoveControl.d.ts +4 -0
  97. package/bin/types/JsViewVueWidget/JsvActorMove/index.d.ts +4 -0
  98. package/bin/types/JsViewVueWidget/JsvApic/JsvApic/BrowserApic.vue.d.ts +5 -1
  99. package/bin/types/JsViewVueWidget/JsvApic/JsvApic/JsvApic.vue.d.ts +28 -1
  100. package/bin/types/JsViewVueWidget/JsvApic/JsvApic/index.d.ts +4 -0
  101. package/bin/types/JsViewVueWidget/JsvApic/JsvApic2/BrowserApic2.vue.d.ts +5 -1
  102. package/bin/types/JsViewVueWidget/JsvApic/JsvApic2/JsvApic2.vue.d.ts +29 -1
  103. package/bin/types/JsViewVueWidget/JsvApic/JsvApic2/index.d.ts +4 -0
  104. package/bin/types/JsViewVueWidget/JsvApic/JsvBrowserApicLib/ApicDataBase.d.ts +4 -0
  105. package/bin/types/JsViewVueWidget/JsvApic/JsvBrowserApicLib/BrowserApicLib.d.ts +4 -0
  106. package/bin/types/JsViewVueWidget/JsvApic/JsvBrowserApicLib/GifData.d.ts +4 -0
  107. package/bin/types/JsViewVueWidget/JsvApic/JsvBrowserApicLib/NormalLoopTool.d.ts +4 -0
  108. package/bin/types/JsViewVueWidget/JsvApic/JsvBrowserApicLib/PartLoopTool.d.ts +4 -0
  109. package/bin/types/JsViewVueWidget/JsvApic/JsvBrowserApicLib/SingleLoopTool.d.ts +4 -0
  110. package/bin/types/JsViewVueWidget/JsvApic/JsvBrowserApicLib/Viewer.d.ts +6 -1
  111. package/bin/types/JsViewVueWidget/JsvApic/JsvBrowserApicLib/WebpData.d.ts +4 -0
  112. package/bin/types/JsViewVueWidget/JsvApic/JsvCommonLoopToolBase.d.ts +4 -0
  113. package/bin/types/JsViewVueWidget/JsvClipDiv/JsvClipDiv.vue.d.ts +74 -0
  114. package/bin/types/JsViewVueWidget/JsvClipDiv/index.d.ts +5 -0
  115. package/bin/types/JsViewVueWidget/JsvConnectLine/ArcLineManager.d.ts +4 -0
  116. package/bin/types/JsViewVueWidget/JsvConnectLine/JsvConnectLine.vue.d.ts +21 -0
  117. package/bin/types/JsViewVueWidget/JsvConnectLine/index.d.ts +4 -0
  118. package/bin/types/JsViewVueWidget/JsvDragBox/JsvDragBox.vue.d.ts +109 -0
  119. package/bin/types/JsViewVueWidget/JsvDriftScope/JsvDriftScope.vue.d.ts +108 -0
  120. package/bin/types/JsViewVueWidget/JsvDriftScope/index.d.ts +5 -0
  121. package/bin/types/JsViewVueWidget/JsvEnableRenderBreak.vue.d.ts +4 -0
  122. package/bin/types/JsViewVueWidget/JsvFilterView.vue.d.ts +19 -0
  123. package/bin/types/JsViewVueWidget/JsvFlexCell/JsvFlexDiv.vue.d.ts +34 -0
  124. package/bin/types/JsViewVueWidget/JsvFlexCell/JsvScreenFlex.vue.d.ts +106 -0
  125. package/bin/types/JsViewVueWidget/JsvFlexCell/index.d.ts +6 -2
  126. package/bin/types/JsViewVueWidget/JsvFragShaderView/BrowserJsvFragShaderView.vue.d.ts +19 -0
  127. package/bin/types/JsViewVueWidget/JsvFragShaderView/JsvFragShaderView.vue.d.ts +60 -0
  128. package/bin/types/JsViewVueWidget/JsvFragShaderView/index.d.ts +6 -0
  129. package/bin/types/JsViewVueWidget/JsvFreeMoveActor/ActorControl.d.ts +47 -17
  130. package/bin/types/JsViewVueWidget/JsvFreeMoveActor/CallbackManager.d.ts +4 -0
  131. package/bin/types/JsViewVueWidget/JsvFreeMoveActor/ForgeTypeDefine.d.ts +4 -0
  132. package/bin/types/JsViewVueWidget/JsvFreeMoveActor/FreeMoveActor.vue.d.ts +25 -0
  133. package/bin/types/JsViewVueWidget/JsvFreeMoveActor/JsvEnvBlocker.vue.d.ts +22 -0
  134. package/bin/types/JsViewVueWidget/JsvFreeMoveActor/NexusNode.d.ts +4 -0
  135. package/bin/types/JsViewVueWidget/JsvFreeMoveActor/SetAction.d.ts +9 -5
  136. package/bin/types/JsViewVueWidget/JsvFreeMoveActor/SetCondition.d.ts +8 -2
  137. package/bin/types/JsViewVueWidget/JsvFreeMoveActor/SetState.d.ts +11 -7
  138. package/bin/types/JsViewVueWidget/JsvFreeMoveActor/SyncLinkManager.d.ts +22 -0
  139. package/bin/types/JsViewVueWidget/JsvFreeMoveActor/index.d.ts +6 -0
  140. package/bin/types/JsViewVueWidget/JsvGrid.vue.d.ts +73 -0
  141. package/bin/types/JsViewVueWidget/JsvHole.d.ts +17 -0
  142. package/bin/types/JsViewVueWidget/JsvInput/Cursor.vue.d.ts +14 -34
  143. package/bin/types/JsViewVueWidget/JsvInput/EditViewOperator.d.ts +48 -0
  144. package/bin/types/JsViewVueWidget/JsvInput/EditVisibleArea.d.ts +27 -0
  145. package/bin/types/JsViewVueWidget/JsvInput/JsvInput.vue.d.ts +64 -209
  146. package/bin/types/JsViewVueWidget/JsvInput/SharedDefine.d.ts +17 -0
  147. package/bin/types/JsViewVueWidget/JsvInput/SystemTextTools.d.ts +14 -0
  148. package/bin/types/JsViewVueWidget/JsvInput/index.d.ts +4 -0
  149. package/bin/types/JsViewVueWidget/JsvLine/JsvLine.vue.d.ts +20 -0
  150. package/bin/types/JsViewVueWidget/JsvLine/LineManager.d.ts +4 -0
  151. package/bin/types/JsViewVueWidget/JsvLine/index.d.ts +4 -0
  152. package/bin/types/JsViewVueWidget/JsvMarquee.vue.d.ts +21 -0
  153. package/bin/types/JsViewVueWidget/JsvMaskClipDiv.vue.d.ts +20 -0
  154. package/bin/types/JsViewVueWidget/JsvMindMap/Constant.d.ts +4 -0
  155. package/bin/types/JsViewVueWidget/JsvMindMap/DataTree.d.ts +7 -1
  156. package/bin/types/JsViewVueWidget/JsvMindMap/Geometry.d.ts +4 -0
  157. package/bin/types/JsViewVueWidget/JsvMindMap/JsvMindMap.vue.d.ts +90 -0
  158. package/bin/types/JsViewVueWidget/JsvMindMap/index.d.ts +4 -0
  159. package/bin/types/JsViewVueWidget/JsvMindMap/rtree.d.ts +4 -0
  160. package/bin/types/JsViewVueWidget/JsvNativeSharedDiv.vue.d.ts +24 -0
  161. package/bin/types/JsViewVueWidget/JsvNinePatch.vue.d.ts +31 -0
  162. package/bin/types/JsViewVueWidget/JsvPieChart.vue.d.ts +17 -0
  163. package/bin/types/JsViewVueWidget/JsvPosterDiv.vue.d.ts +17 -0
  164. package/bin/types/JsViewVueWidget/JsvPosterImage.vue.d.ts +18 -0
  165. package/bin/types/JsViewVueWidget/JsvPreload/BrowserPreload.vue.d.ts +4 -0
  166. package/bin/types/JsViewVueWidget/JsvPreload/JsvPreload.vue.d.ts +42 -0
  167. package/bin/types/JsViewVueWidget/JsvPreload/index.d.ts +4 -0
  168. package/bin/types/JsViewVueWidget/JsvProgressBar.vue.d.ts +19 -0
  169. package/bin/types/JsViewVueWidget/JsvQrcode/BrowserQrcode.vue.d.ts +4 -0
  170. package/bin/types/JsViewVueWidget/JsvQrcode/JsvQrcode.vue.d.ts +25 -0
  171. package/bin/types/JsViewVueWidget/JsvQrcode/index.d.ts +4 -0
  172. package/bin/types/JsViewVueWidget/JsvRadarChart.vue.d.ts +24 -0
  173. package/bin/types/JsViewVueWidget/JsvRipple/Constant.d.ts +4 -0
  174. package/bin/types/JsViewVueWidget/JsvRipple/JsvRipple.vue.d.ts +45 -0
  175. package/bin/types/JsViewVueWidget/JsvRipple/index.d.ts +4 -0
  176. package/bin/types/JsViewVueWidget/JsvScaleTextBox.vue.d.ts +18 -0
  177. package/bin/types/JsViewVueWidget/JsvScrollBox/JsvScrollBox.vue.d.ts +65 -1
  178. package/bin/types/JsViewVueWidget/JsvScrollBox/JsvScrollFollow.vue.d.ts +157 -0
  179. package/bin/types/JsViewVueWidget/JsvScrollBox/ScrollInnerSymbol.d.ts +8 -0
  180. package/bin/types/JsViewVueWidget/JsvScrollBox/ScrollSymbol.d.ts +13 -4
  181. package/bin/types/JsViewVueWidget/JsvScrollBox/index.d.ts +6 -0
  182. package/bin/types/JsViewVueWidget/JsvSector.vue.d.ts +18 -0
  183. package/bin/types/JsViewVueWidget/JsvSoundPool.d.ts +42 -0
  184. package/bin/types/JsViewVueWidget/JsvSpray/BrowserSpray.vue.d.ts +4 -0
  185. package/bin/types/JsViewVueWidget/JsvSpray/JsvSpray.vue.d.ts +40 -0
  186. package/bin/types/JsViewVueWidget/JsvSpray/index.d.ts +4 -0
  187. package/bin/types/JsViewVueWidget/JsvSpriteAnim/FrameBuidler.d.ts +4 -0
  188. package/bin/types/JsViewVueWidget/JsvSpriteAnim/JsvSpriteAnim.vue.d.ts +52 -0
  189. package/bin/types/JsViewVueWidget/JsvSpriteAnim/JsvSpriteLoader.vue.d.ts +16 -0
  190. package/bin/types/JsViewVueWidget/JsvSpriteAnim/JsvSpriteTools.d.ts +4 -0
  191. package/bin/types/JsViewVueWidget/JsvSpriteAnim/SpriteController.d.ts +4 -0
  192. package/bin/types/JsViewVueWidget/JsvSpriteAnim/index.d.ts +4 -0
  193. package/bin/types/JsViewVueWidget/JsvSpriteAnim/sAnimationToken.d.ts +4 -0
  194. package/bin/types/JsViewVueWidget/JsvSwiper/JsvSwiper.vue.d.ts +39 -0
  195. package/bin/types/JsViewVueWidget/JsvSwiper/index.d.ts +4 -0
  196. package/bin/types/JsViewVueWidget/JsvSwiper3D/JsvSwiper.vue.d.ts +24 -0
  197. package/bin/types/JsViewVueWidget/JsvSwiper3D/index.d.ts +4 -0
  198. package/bin/types/JsViewVueWidget/JsvTextBox.vue.d.ts +26 -0
  199. package/bin/types/JsViewVueWidget/JsvTextureAnim/BrowserTextureAnim.vue.d.ts +4 -0
  200. package/bin/types/JsViewVueWidget/JsvTextureAnim/CommonType.d.ts +4 -0
  201. package/bin/types/JsViewVueWidget/JsvTextureAnim/JsvTextureAnim.vue.d.ts +7 -2
  202. package/bin/types/JsViewVueWidget/JsvTextureAnim/index.d.ts +4 -0
  203. package/bin/types/JsViewVueWidget/JsvTouchModeSwitcher.vue.d.ts +100 -0
  204. package/bin/types/JsViewVueWidget/JsvVisibleSensor/JsvVisibleSensor.vue.d.ts +25 -0
  205. package/bin/types/JsViewVueWidget/JsvVisibleSensor/index.d.ts +4 -0
  206. package/bin/types/JsViewVueWidget/index.d.ts +9 -0
  207. package/bin/types/index.d.ts +4 -0
  208. package/index.d.ts +8 -0
  209. package/package.json +1 -1
  210. package/tools/config/rollup.config.mjs +1 -0
  211. package/tools/config/toolkit.mjs +81 -0
  212. package/tools/config/tsconfig.json +1 -0
  213. package/tools/config/vite.config.ts +24 -14
  214. package/tools/jsview-vue-build.mjs +66 -21
  215. package/utils/JsViewEngineWidget/JsvFocus/JsvFocusBlock.vue +6 -2
  216. package/utils/JsViewEngineWidget/JsvFocus/{JsvFocusManager.js → JsvFocusManager.ts} +34 -15
  217. package/utils/JsViewEngineWidget/MetroWidget/Dispatcher.ts +20 -0
  218. package/utils/JsViewEngineWidget/MetroWidget/ListWidget.vue +30 -11
  219. package/utils/JsViewEngineWidget/MetroWidget/MetroWidget.vue +54 -15
  220. package/utils/JsViewEngineWidget/MetroWidget/MetroWidgetSetup.js +509 -268
  221. package/utils/JsViewEngineWidget/MetroWidget/RenderItem.ts +11 -0
  222. package/utils/JsViewEngineWidget/MetroWidget/TaskManager.ts +8 -0
  223. package/utils/JsViewEngineWidget/TemplateParser/CommonMetroTemplate.ts +20 -10
  224. package/utils/JsViewEngineWidget/TemplateParser/ListMetroTemplate.ts +33 -9
  225. package/utils/JsViewEngineWidget/TemplateParser/MetroTemplate.ts +2 -2
  226. package/utils/JsViewEngineWidget/TemplateParser/TemplateItemAdder.ts +7 -0
  227. package/utils/JsViewEngineWidget/{index.js → index.ts} +1 -1
  228. package/utils/JsViewPlugin/JsvAudio/AudioProxy.js +21 -2
  229. package/utils/JsViewPlugin/JsvAudio/version.js +1 -1
  230. package/utils/JsViewPlugin/JsvAudio/version.mjs +1 -1
  231. package/utils/JsViewPlugin/JsvLatex/BrowserDomBuilder.js +13 -3
  232. package/utils/JsViewPlugin/JsvLatex/BrowserJsvLatex.vue +27 -6
  233. package/utils/JsViewPlugin/JsvLatex/JsvLatex.vue +34 -28
  234. package/utils/JsViewPlugin/JsvLatex/index.js +22 -0
  235. package/utils/JsViewVueTools/ConstSymbol.ts +2 -2
  236. package/utils/JsViewVueTools/FeatureActive.ts +84 -0
  237. package/utils/JsViewVueTools/ForgeHandles.ts +7 -3
  238. package/utils/JsViewVueTools/JsvDynamicCssStyle.js +2 -0
  239. package/utils/JsViewVueTools/JsvDynamicKeyFrames.ts +2 -0
  240. package/utils/JsViewVueTools/JsvImpactTracer.js +2 -0
  241. package/utils/JsViewVueTools/JsvPreDownloader.ts +5 -4
  242. package/utils/JsViewVueTools/JsvRefTaker.js +1 -2
  243. package/utils/JsViewVueTools/JsvRuntimeBridge.js +67 -1
  244. package/utils/JsViewVueTools/JsvStyleClass.js +2 -0
  245. package/utils/JsViewVueTools/JsvStyleSheetsDeclarer.js +2 -0
  246. package/utils/JsViewVueTools/JsvTextTools.ts +223 -0
  247. package/utils/JsViewVueTools/JsvTextureLoadTool.ts +233 -0
  248. package/utils/JsViewVueTools/JsvTextureStore/CapturedTexture/CapturedTexture.ts +4 -1
  249. package/utils/JsViewVueTools/JsvTextureStore/JsvTextureStore.ts +8 -4
  250. package/utils/JsViewVueTools/JsvTextureStore/Texture.ts +1 -0
  251. package/utils/JsViewVueTools/TextureManagerTools.ts +17 -0
  252. package/utils/JsViewVueTools/index.js +22 -19
  253. package/utils/JsViewVueWidget/JsvActorMove/JsvActorMove.vue +2 -0
  254. package/utils/JsViewVueWidget/JsvApic/JsvApic/BrowserApic.vue +2 -2
  255. package/utils/JsViewVueWidget/JsvApic/JsvApic/JsvApic.vue +13 -5
  256. package/utils/JsViewVueWidget/JsvApic/JsvApic2/BrowserApic2.vue +2 -2
  257. package/utils/JsViewVueWidget/JsvApic/JsvApic2/JsvApic2.vue +15 -4
  258. package/utils/JsViewVueWidget/JsvApic/JsvBrowserApicLib/Viewer.js +8 -3
  259. package/utils/JsViewVueWidget/JsvClipDiv/JsvClipDiv.vue +44 -0
  260. package/utils/JsViewVueWidget/JsvClipDiv/index.ts +1 -0
  261. package/utils/JsViewVueWidget/JsvConnectLine/JsvConnectLine.vue +7 -1
  262. package/utils/JsViewVueWidget/JsvDragBox/JsvDragBox.vue +219 -0
  263. package/utils/JsViewVueWidget/JsvDriftScope/JsvDriftScope.vue +84 -0
  264. package/utils/JsViewVueWidget/JsvDriftScope/index.ts +1 -0
  265. package/utils/JsViewVueWidget/JsvFilterView.vue +2 -0
  266. package/utils/JsViewVueWidget/JsvFlexCell/JsvFlexDiv.vue +5 -2
  267. package/utils/JsViewVueWidget/JsvFlexCell/JsvScreenFlex.vue +145 -0
  268. package/utils/JsViewVueWidget/JsvFlexCell/index.js +2 -5
  269. package/utils/JsViewVueWidget/JsvFragShaderView/BrowserJsvFragShaderView.vue +75 -0
  270. package/utils/JsViewVueWidget/JsvFragShaderView/JsvFragShaderView.vue +293 -0
  271. package/utils/JsViewVueWidget/JsvFragShaderView/index.js +18 -0
  272. package/utils/JsViewVueWidget/JsvFreeMoveActor/ActorControl.ts +142 -63
  273. package/utils/JsViewVueWidget/JsvFreeMoveActor/FreeMoveActor.vue +9 -0
  274. package/utils/JsViewVueWidget/JsvFreeMoveActor/JsvEnvBlocker.vue +2 -0
  275. package/utils/JsViewVueWidget/JsvFreeMoveActor/SetAction.ts +15 -6
  276. package/utils/JsViewVueWidget/JsvFreeMoveActor/SetCondition.ts +19 -7
  277. package/utils/JsViewVueWidget/JsvFreeMoveActor/SetState.ts +15 -11
  278. package/utils/JsViewVueWidget/JsvFreeMoveActor/SyncLinkManager.ts +120 -0
  279. package/utils/JsViewVueWidget/JsvFreeMoveActor/index.js +5 -1
  280. package/utils/JsViewVueWidget/JsvGrid.vue +2 -0
  281. package/utils/JsViewVueWidget/JsvHole.js +2 -0
  282. package/utils/JsViewVueWidget/JsvInput/Cursor.vue +49 -45
  283. package/utils/JsViewVueWidget/JsvInput/EditViewOperator.ts +320 -0
  284. package/utils/JsViewVueWidget/JsvInput/EditVisibleArea.ts +222 -0
  285. package/utils/JsViewVueWidget/JsvInput/JsvInput.vue +281 -681
  286. package/utils/JsViewVueWidget/JsvInput/SharedDefine.ts +17 -0
  287. package/utils/JsViewVueWidget/JsvInput/SystemTextTools.ts +47 -0
  288. package/utils/JsViewVueWidget/JsvLine/JsvLine.vue +2 -0
  289. package/utils/JsViewVueWidget/JsvMarquee.vue +2 -0
  290. package/utils/JsViewVueWidget/JsvMaskClipDiv.vue +2 -0
  291. package/utils/JsViewVueWidget/JsvMindMap/DataTree.ts +14 -1
  292. package/utils/JsViewVueWidget/JsvMindMap/JsvMindMap.vue +277 -117
  293. package/utils/JsViewVueWidget/JsvNativeSharedDiv.vue +91 -68
  294. package/utils/JsViewVueWidget/JsvNinePatch.vue +18 -1
  295. package/utils/JsViewVueWidget/JsvPieChart.vue +2 -0
  296. package/utils/JsViewVueWidget/JsvPosterDiv.vue +2 -0
  297. package/utils/JsViewVueWidget/JsvPosterImage.vue +2 -0
  298. package/utils/JsViewVueWidget/JsvPreload/JsvPreload.vue +2 -0
  299. package/utils/JsViewVueWidget/JsvProgressBar.vue +2 -0
  300. package/utils/JsViewVueWidget/JsvQrcode/JsvQrcode.vue +10 -11
  301. package/utils/JsViewVueWidget/JsvRadarChart.vue +2 -0
  302. package/utils/JsViewVueWidget/JsvRipple/Constant.js +2 -2
  303. package/utils/JsViewVueWidget/JsvRipple/JsvRipple.vue +3 -1
  304. package/utils/JsViewVueWidget/JsvScaleTextBox.vue +2 -0
  305. package/utils/JsViewVueWidget/JsvScrollBox/JsvScrollBox.vue +266 -48
  306. package/utils/JsViewVueWidget/JsvScrollBox/JsvScrollFollow.vue +477 -0
  307. package/utils/JsViewVueWidget/JsvScrollBox/ScrollInnerSymbol.ts +9 -0
  308. package/utils/JsViewVueWidget/JsvScrollBox/ScrollSymbol.ts +13 -4
  309. package/utils/JsViewVueWidget/JsvScrollBox/index.ts +3 -0
  310. package/utils/JsViewVueWidget/JsvSector.vue +2 -0
  311. package/utils/JsViewVueWidget/JsvSoundPool.js +2 -0
  312. package/utils/JsViewVueWidget/JsvSpray/JsvSpray.vue +30 -13
  313. package/utils/JsViewVueWidget/JsvSpriteAnim/JsvSpriteAnim.vue +2 -0
  314. package/utils/JsViewVueWidget/JsvSpriteAnim/JsvSpriteLoader.vue +2 -0
  315. package/utils/JsViewVueWidget/JsvSwiper/JsvSwiper.vue +2 -0
  316. package/utils/JsViewVueWidget/JsvSwiper3D/JsvSwiper.vue +2 -0
  317. package/utils/JsViewVueWidget/JsvTextBox.vue +2 -4
  318. package/utils/JsViewVueWidget/JsvTextureAnim/JsvTextureAnim.vue +44 -41
  319. package/utils/JsViewVueWidget/JsvTouchModeSwitcher.vue +101 -0
  320. package/utils/JsViewVueWidget/JsvVideo.vue +2 -2
  321. package/utils/JsViewVueWidget/JsvVisibleSensor/JsvVisibleSensor.vue +2 -0
  322. package/utils/JsViewVueWidget/index.js +5 -0
  323. package/utils/JsViewEngineWidget/MetroWidget/Dispatcher.js +0 -19
  324. package/utils/JsViewVueTools/JsvTextTools.js +0 -89
  325. package/utils/JsViewVueWidget/JsvScrollBox/index.js +0 -2
@@ -0,0 +1,477 @@
1
+ <!--
2
+ * @file
3
+ *
4
+ * 【模块 export 内容】
5
+ * JsvScrollFollow:Vue高阶组件,响应并同步JsvScrollBox的移动的div/ninePatch特殊类型的进度展示组件
6
+ * props说明:
7
+ * proxyType {ScorllBoxStyle.*} (必填,非响应式!!) 下面的几个类型中选一种:
8
+ SizeDiv: 一个普通的div, 进度信息影响div的width/height, proxyProps里面主要设置backgroundColor
9
+ SizeClip: 对子内容进行剪切的div, 此类型不支持proxyProps的设置, 只有varWidth和varHeight能为变量
10
+ (本组件会额外赋予overflow:hidden, 以及剪切区域自由移动的data-jsv-vw-mask-separate)
11
+ JsvNinePatch: JsvNinePatch组件类型
12
+ * proxyProps {Object} (选填,响应式) 传给代理类型的props,例如JsvNinePatch时,JsvNinePatch的props设置
13
+ * varLeft/varTop/varWidth/varHeight(number|Object):
14
+ (选填, 但至少有一个值, 响应式) 当为number时为固定值,
15
+ TODO: 响应式改动后立即同步进度处理还没完成
16
+ 为Object时必须是{start:number, end:number}格式
17
+ 其中start对应 JsvScrollBox 进度起始值时的位置,end对应 JsvScrollBox 进度终点值的位置
18
+ 特别注意: left/Top, width/height分别是两种变换,不能这两组不能同时都为变值
19
+ * syncWith {String} (必填,响应式) 进度联动组件来源,内容为联动来源的linkName
20
+ * syncType {ScrollBoxStyle.*}
21
+ * (选填,响应式) 决定syncWith的联动模式,当syncWith设置后才能生效, 默认为 SyncForward
22
+ * SyncForward(默认值): 同进同退, mySelf = sourcePercent
23
+ * SyncReverse: 进退反向, mySelf = (1 - sourcePercent)
24
+ *
25
+ * template说明:
26
+ 当proxyType为clipDiv可以放置<template>子节点,所有子节点不做改变直接作为本节点的子,以slot形式
27
+ * expose函数说明:
28
+ * setSensor(sensitivity:number, callback:Function<percent:number, x:number, y:number>) 设置运动后触发的回调
29
+ * sensitivity为回调敏感度, 每移动多少像素进行回调,适当放大(推荐10以上)可以极大减小对js回调过多引起的性能降低
30
+ *
31
+ -->
32
+
33
+ <template>
34
+ <div v-if="cProxyType == ScrollBoxStyle.SizeClip" v-bind="rSizeClipOutProps">
35
+ <div ref="rSliderViewRef" v-bind="rSizeClipInnerProps">
36
+ <div data-jsv-vw-mask-dock="true">
37
+ <slot />
38
+ </div>
39
+ </div>
40
+ </div>
41
+ <div
42
+ v-else-if="cProxyType == ScrollBoxStyle.SizeDiv"
43
+ ref="rSliderViewRef"
44
+ v-bind="rSizeDivProps"
45
+ />
46
+ <JsvNinePatch
47
+ :onDivRef="onNinePatchRef"
48
+ v-else-if="cProxyType == ScrollBoxStyle.JsvNinePatch"
49
+ v-bind="rNinePatchMergedProps"
50
+ />
51
+ </template>
52
+
53
+ <script setup lang="ts">
54
+ import {
55
+ shallowRef,
56
+ watchEffect,
57
+ onMounted,
58
+ onUnmounted,
59
+ defineExpose,
60
+ withDefaults,
61
+ defineProps,
62
+ } from "vue";
63
+ import ActControl from "../JsvFreeMoveActor/ActorControl";
64
+ import { ScrollBoxStyle } from "./ScrollSymbol";
65
+ import { GetSyncLinkManager } from "../JsvFreeMoveActor/SyncLinkManager";
66
+ import { NexusNode } from "../JsvFreeMoveActor/NexusNode";
67
+ import { ScrollInnerStyle } from "./ScrollInnerSymbol";
68
+ import JsvNinePatch from "../JsvNinePatch.vue";
69
+ import {
70
+ FeatureNames,
71
+ JsvUseFeature,
72
+ } from "../../JsViewVueTools/FeatureActive";
73
+
74
+ const rProps = withDefaults(
75
+ defineProps<{
76
+ // 所代理节点的类型
77
+ // 取值范围: ScrollBoxStyle.SizeClip, ScrollBoxStyle.JsvNinePatch, ScrollBoxStyle.SizeDiv
78
+ proxyType: symbol;
79
+
80
+ // 传给所代理节点的props
81
+ proxyProps?: Object;
82
+
83
+ // left的值或者跟随scroll进度信息的变化范围
84
+ varLeft?: number | object;
85
+
86
+ // top的值或者跟随scroll进度信息的变化范围
87
+ varTop?: number | object;
88
+
89
+ // width的值或者跟随scroll进度信息的变化范围
90
+ varWidth?: number | object;
91
+
92
+ // height的值或者跟随scroll进度信息的变化范围
93
+ varHeight?: number | object;
94
+
95
+ // 进度同步源的linkName
96
+ syncWith: string;
97
+
98
+ // 进度同步的模式(同向还是反向)
99
+ // 取值范围: ScrollBoxStyle.SyncForward, ScrollBoxStyle.SyncReverse
100
+ syncType?: symbol;
101
+ }>(),
102
+ {
103
+ varMode: ScrollBoxStyle.Position,
104
+ varLeft: 0,
105
+ varTop: 0,
106
+ varWidth: 0,
107
+ varHeight: 0,
108
+ syncType: ScrollBoxStyle.SyncForward,
109
+ }
110
+ );
111
+
112
+ // 激活引擎中的功能支持
113
+ JsvUseFeature("JsvScrollFollow", FeatureNames.TouchReceiver);
114
+
115
+ /** 本地类型定义 **/
116
+ interface PosSizeType {
117
+ start: number;
118
+ end: number;
119
+ }
120
+
121
+ /** 本地常量 **/
122
+ const cProxyType = rProps.proxyType;
123
+
124
+ // SizeClip和JsvNinePatch都是size调整模式
125
+ // TODO: 其他模式可能会有Position模式,后续再补充
126
+ const cVarMode = ScrollBoxStyle.Size;
127
+
128
+ const cSyncLinkManager = GetSyncLinkManager();
129
+ const cSliderActor = new ActControl();
130
+
131
+ // Actor condition group id(1~9可任意用)
132
+ const cSensorConditionGroup = 1;
133
+ const cLinkConditionGroup = 2;
134
+
135
+ /** 本地非响应式变量 **/
136
+ let vSyncWithNameCache: String | null = null; // 当前关联的SyncLinkSource的名称
137
+ let vSyncTypeCache: Symbol = ScrollBoxStyle.SyncForward;
138
+ let vWaitMasterLinkSourceReady: Promise<void> | null = null;
139
+ let vSyncLinkNexusNode: NexusNode | null = null;
140
+ let vTargetViewReady = false;
141
+ let vCurrentPercent: number = 0;
142
+
143
+ // 设置同步区域
144
+ let vMainDivTop: PosSizeType = {
145
+ start: NaN,
146
+ end: NaN,
147
+ };
148
+ let vMainDivLeft: PosSizeType = {
149
+ start: NaN,
150
+ end: NaN,
151
+ };
152
+ let vMainDivWidth: PosSizeType = {
153
+ start: NaN,
154
+ end: NaN,
155
+ };
156
+ let vMainDivHeight: PosSizeType = {
157
+ start: NaN,
158
+ end: NaN,
159
+ };
160
+
161
+ /** 本地响应式变量 **/
162
+ let rSliderViewRef = shallowRef(null);
163
+ let rSizeClipOutProps: any = shallowRef(null);
164
+ let rSizeClipInnerProps: any = shallowRef(null);
165
+ let rNinePatchMergedProps: any = shallowRef(null);
166
+ let rSizeDivProps: any = shallowRef(null);
167
+
168
+ function resetPosSizeInfo(
169
+ source: number | Object,
170
+ varRef: PosSizeType,
171
+ allowVar: boolean
172
+ ): boolean {
173
+ let tmpVal = { start: 0, end: 0 };
174
+
175
+ if (typeof source == "number") {
176
+ tmpVal.start = source;
177
+ tmpVal.end = source;
178
+ } else {
179
+ tmpVal.start = (source as any).start ? (source as any).start : 0;
180
+ tmpVal.end = (source as any).end ? (source as any).end : 0;
181
+ }
182
+
183
+ if (tmpVal.start != varRef.start || tmpVal.end != varRef.start) {
184
+ varRef.start = tmpVal.start;
185
+ varRef.end = tmpVal.end;
186
+ if (varRef.start != varRef.end && allowVar) {
187
+ if (!allowVar) {
188
+ return false;
189
+ }
190
+ }
191
+ return true;
192
+ } else {
193
+ return false;
194
+ }
195
+ }
196
+
197
+ // rProps变化的watchEffect
198
+ watchEffect(() => {
199
+ // 其余属性变化
200
+ let reactChangedMerged: boolean = false;
201
+ {
202
+ let changed: boolean = false;
203
+ changed = resetPosSizeInfo(
204
+ rProps.varTop,
205
+ vMainDivTop,
206
+ cVarMode == ScrollBoxStyle.Position
207
+ );
208
+ reactChangedMerged ||= changed;
209
+ changed = resetPosSizeInfo(
210
+ rProps.varLeft,
211
+ vMainDivLeft,
212
+ cVarMode == ScrollBoxStyle.Position
213
+ );
214
+ reactChangedMerged ||= changed;
215
+ changed = resetPosSizeInfo(
216
+ rProps.varWidth,
217
+ vMainDivWidth,
218
+ cVarMode == ScrollBoxStyle.Size
219
+ );
220
+ reactChangedMerged ||= changed;
221
+ changed = resetPosSizeInfo(
222
+ rProps.varHeight,
223
+ vMainDivHeight,
224
+ cVarMode == ScrollBoxStyle.Size
225
+ );
226
+ reactChangedMerged ||= changed;
227
+ }
228
+
229
+ if (reactChangedMerged) {
230
+ rebuildAckSync();
231
+ }
232
+
233
+ // 在 rebuildAckSync 之后,确认syncWith是否变化,变化则重建参照的SyncLinkSource
234
+ if (
235
+ vSyncWithNameCache != rProps.syncWith ||
236
+ vSyncTypeCache != rProps.syncType
237
+ ) {
238
+ vSyncWithNameCache = rProps.syncWith;
239
+ vSyncTypeCache = rProps.syncType;
240
+ changeSyncLink(vSyncWithNameCache);
241
+ }
242
+
243
+ // slider div属性变化(放在最后,因为style里面的top/left要参考varTop/varLeft/varWidth/varHeight)
244
+ {
245
+ let divStyle = {
246
+ // 对应模式的动态变量设置为0(width/height设置为100为了进行测试),否则使用其start作为固定值
247
+ top: cVarMode == ScrollBoxStyle.Position ? 0 : vMainDivTop.start,
248
+ left: cVarMode == ScrollBoxStyle.Position ? 0 : vMainDivLeft.start,
249
+ width: cVarMode == ScrollBoxStyle.Size ? 0 : vMainDivWidth.start,
250
+ height: cVarMode == ScrollBoxStyle.Size ? 0 : vMainDivHeight.start,
251
+ };
252
+ switch (cProxyType) {
253
+ // SizeClip
254
+ case ScrollBoxStyle.SizeClip:
255
+ {
256
+ if (rProps.proxyProps) {
257
+ console.warn("clipDiv not support proxyProps");
258
+ }
259
+ rSizeClipOutProps.value = {
260
+ style: {
261
+ top: divStyle.top,
262
+ left: divStyle.left,
263
+ },
264
+ };
265
+ rSizeClipInnerProps.value = {
266
+ style: {
267
+ width: divStyle.width,
268
+ height: divStyle.height,
269
+ overflow: "hidden",
270
+ },
271
+ "data-jsv-vw-mmask-drift": "true", // 将clip视窗做成drift模式
272
+ };
273
+ }
274
+ break;
275
+
276
+ // JsvNinePatch
277
+ case ScrollBoxStyle.JsvNinePatch:
278
+ {
279
+ rNinePatchMergedProps.value = {
280
+ ...rProps.proxyProps,
281
+ style: {
282
+ ...divStyle,
283
+ },
284
+ };
285
+ }
286
+ break;
287
+
288
+ // SizeDiv
289
+ case ScrollBoxStyle.SizeDiv:
290
+ {
291
+ let proxyStyle: any = null;
292
+ if ((rProps.proxyProps as any)?.style) {
293
+ proxyStyle = (rProps.proxyProps as any)?.style;
294
+ }
295
+ rProps.proxyProps;
296
+ rSizeDivProps.value = {
297
+ style: {
298
+ ...proxyStyle,
299
+ ...divStyle,
300
+ },
301
+ };
302
+ }
303
+ break;
304
+
305
+ default:
306
+ // Unknown types
307
+ console.error("unknown proxy type=" + cProxyType?.toString());
308
+ return;
309
+ }
310
+ }
311
+ });
312
+
313
+ function changeSyncLink(newSyncSourceName: String) {
314
+ // 清理原Link nexusNode
315
+ vSyncLinkNexusNode = null;
316
+ rebuildAckSync();
317
+
318
+ if (newSyncSourceName != null) {
319
+ // 创建新Source的Ready promise, 在确认目标节点存在后再获取NexusNode来创建condition
320
+ // 注意此Promise要在unMounted时通过UnListen进行反注册,才能规避内存泄漏
321
+ vWaitMasterLinkSourceReady = cSyncLinkManager
322
+ .WaitSourceMounted(newSyncSourceName)
323
+ .then(() => {
324
+ // 获取Link nexusNode。此引用不用专门释放,没有内存泄漏问题
325
+ vSyncLinkNexusNode =
326
+ cSyncLinkManager.GetSourceNexusNode(newSyncSourceName);
327
+ rebuildAckSync();
328
+ });
329
+ }
330
+ }
331
+
332
+ function rebuildAckSync() {
333
+ if (!vTargetViewReady) return;
334
+
335
+ // 清理老设定
336
+ cSliderActor.run((cmds) => [
337
+ cmds.state().removeConditionByGroup(cLinkConditionGroup),
338
+ ]);
339
+
340
+ if (vSyncLinkNexusNode != null) {
341
+ // 创建运动跟随的condition
342
+ let vertSet: PosSizeType, horiSet: PosSizeType;
343
+ if (cVarMode == ScrollBoxStyle.Position) {
344
+ vertSet = vMainDivTop;
345
+ horiSet = vMainDivLeft;
346
+ } else {
347
+ vertSet = vMainDivHeight;
348
+ horiSet = vMainDivWidth;
349
+ }
350
+
351
+ cSliderActor.run((cmds) => [
352
+ cmds
353
+ .condition(cLinkConditionGroup, true)
354
+ .movementSync(vSyncLinkNexusNode!)
355
+ .then([
356
+ cmds
357
+ .action()
358
+ .ackMovementSync(
359
+ horiSet.start,
360
+ horiSet.end,
361
+ vertSet.start,
362
+ vertSet.end,
363
+ 0b11,
364
+ vSyncTypeCache == ScrollBoxStyle.SyncForward ? 1 : 2
365
+ ),
366
+ ]),
367
+ cmds
368
+ .condition(cLinkConditionGroup, true)
369
+ .onNexusEvent(
370
+ vSyncLinkNexusNode!,
371
+ ScrollInnerStyle.UpdatePercentNexusCode
372
+ )
373
+ .then([
374
+ (pointInfo: any) => {
375
+ vCurrentPercent = positionToPercent(pointInfo);
376
+ },
377
+ ]),
378
+ ]);
379
+ }
380
+ }
381
+
382
+ // setSensor 函数声明
383
+ function setSensor(callback: Function, sensitivity: number) {
384
+ cSliderActor.run((cmds) => [
385
+ cmds.state().removeConditionByGroup(cSensorConditionGroup),
386
+ ]);
387
+ if (callback != null) {
388
+ cSliderActor.run((cmds) => [
389
+ cmds
390
+ .condition(cSensorConditionGroup, true)
391
+ .onMovement(sensitivity) // 设置x或y移动超过12时才触发回调,以此减少回调的频次,规避js的性能影响
392
+ .then([
393
+ (pointInfo: any) => {
394
+ let percent: number = positionToPercent(pointInfo);
395
+ vCurrentPercent = percent;
396
+ callback(percent, pointInfo.xPos, pointInfo.yPos);
397
+ },
398
+ ]),
399
+ ]);
400
+ }
401
+ }
402
+
403
+ function positionToPercent(pointInfo: any): number {
404
+ let percent = 0;
405
+ if (cVarMode == ScrollBoxStyle.Position) {
406
+ if (vMainDivTop.start != vMainDivTop.end) {
407
+ percent = pointInfo.yPos / (vMainDivTop.end - vMainDivTop.start);
408
+ } else if (vMainDivLeft.start != vMainDivLeft.end) {
409
+ percent = pointInfo.xPos / (vMainDivLeft.end - vMainDivLeft.start);
410
+ }
411
+ } else {
412
+ if (vMainDivHeight.start != vMainDivHeight.end) {
413
+ percent = pointInfo.yPos / (vMainDivHeight.end - vMainDivHeight.start);
414
+ } else if (vMainDivWidth.start != vMainDivWidth.end) {
415
+ percent = pointInfo.xPos / (vMainDivWidth.end - vMainDivWidth.start);
416
+ }
417
+ }
418
+ return percent;
419
+ }
420
+
421
+ function onNinePatchRef(divRef: any) {
422
+ // 理论上此回调会在本组件onMounted前调用
423
+ // 这样在onMounted中就可以正常使用
424
+ rSliderViewRef.value = divRef;
425
+
426
+ initViewControl();
427
+ }
428
+
429
+ function initViewControl() {
430
+ if (rSliderViewRef.value == null) {
431
+ return;
432
+ }
433
+
434
+ if (vTargetViewReady) {
435
+ // already inited, not allow init twice
436
+ return;
437
+ }
438
+
439
+ vTargetViewReady = true;
440
+
441
+ // 构建slider的FreeMove控制对象
442
+ let sliderView = (rSliderViewRef.value as any).jsvGetProxyView(
443
+ cProxyType != ScrollBoxStyle.SizeDiv
444
+ );
445
+ if (cVarMode == ScrollBoxStyle.Size) {
446
+ cSliderActor.asSizeMode();
447
+ }
448
+ cSliderActor.bindForgeView(sliderView, true);
449
+
450
+ // 设置关联区域
451
+ rebuildAckSync();
452
+ }
453
+
454
+ function currentPercent(): number {
455
+ return vCurrentPercent;
456
+ }
457
+
458
+ onMounted(() => {
459
+ initViewControl();
460
+ });
461
+
462
+ onUnmounted(() => {
463
+ /** 关于LinkSource的释放 **/
464
+ // 释放作为linkSource slave时的句柄
465
+ if (vWaitMasterLinkSourceReady != null) {
466
+ cSyncLinkManager.UnListen(vWaitMasterLinkSourceReady);
467
+ vWaitMasterLinkSourceReady = null;
468
+ }
469
+ });
470
+
471
+ defineExpose({
472
+ setSensor,
473
+ currentPercent,
474
+ });
475
+ </script>
476
+
477
+ <style lang="scss" scoped></style>
@@ -0,0 +1,9 @@
1
+
2
+
3
+ const ScrollInnerStyle = {
4
+ UpdatePercentNexusCode: 10001,
5
+ }
6
+
7
+ export {
8
+ ScrollInnerStyle
9
+ }
@@ -1,15 +1,24 @@
1
1
 
2
2
 
3
- const ScrollStyle = {
3
+ const ScrollBoxStyle = {
4
4
  // 运动模式
5
5
  DrawerMode: Symbol("DrawerMode"),
6
6
  PinMode: Symbol("PinMode"),
7
7
 
8
8
  // 同步模式
9
- SyncParallel: Symbol("AckParallel"), // 百分比完全对齐的同步模式
10
- SyncRevert: Symbol("SyncRevert"), // (1-百分比)的同步模式
9
+ SyncForward: Symbol("SyncForward"), // 百分比完全对齐的同步模式
10
+ SyncReverse: Symbol("SyncReverse"), // (1-百分比)的同步模式
11
+
12
+ // Follow的同步模式
13
+ Position: Symbol("Position"),
14
+ Size: Symbol("Size"),
15
+
16
+ // Follow的类型定义
17
+ SizeDiv: Symbol("SizeDiv"),
18
+ SizeClip: Symbol("SizeClip"),
19
+ JsvNinePatch: Symbol("JsvNinePatch"),
11
20
  }
12
21
 
13
22
  export {
14
- ScrollStyle
23
+ ScrollBoxStyle
15
24
  }
@@ -0,0 +1,3 @@
1
+ export { default as JsvScrollBox } from "./JsvScrollBox.vue"
2
+ export { default as JsvScrollFollow } from "./JsvScrollFollow.vue"
3
+ export * from "./ScrollSymbol"
@@ -1,4 +1,6 @@
1
1
  <!--
2
+ * @file
3
+ *
2
4
  * 【模块 export 内容】
3
5
  * JsvSector:Vue高阶组件,扇形图。
4
6
  * props说明:
@@ -3,6 +3,8 @@
3
3
  */
4
4
 
5
5
  /*!
6
+ * @file
7
+ *
6
8
  * 【模块 export 内容】
7
9
  * JsvSoundPool: 面向对象的类,用于播放效果音,创建JsvSoundPool对象后通过request的回调获得AudioController句柄后进行控制
8
10
  * 功能函数: (参数说明见函数本体)
@@ -5,6 +5,8 @@
5
5
  -->
6
6
 
7
7
  <!--
8
+ * @file
9
+ *
8
10
  * 【模块 export 内容】
9
11
  * JsvSpray:Vue高阶组件,粒子效果控件
10
12
  * prop说明:
@@ -15,9 +17,9 @@
15
17
  * prop中的sprayStyle说明:
16
18
  * type {int} (必需)喷射类型 0: 一次喷射 1: 持续喷射
17
19
  * particleNum {int} (必需)粒子个数
18
- * deltaAngle {int} (必需)粒子喷射角度范围。如设30则粒子喷射范围为div上边法向正负30度
19
- * deltaWidth {int} (必需)粒子喷射位置宽度范围
20
- * deltaHeight {int} (必需)粒子喷射位置高度范围
20
+ * deltaAngle {int} (必需)粒子喷射角度范围(角度)。如设30则粒子喷射范围为div上边法向正负30度
21
+ * deltaWidth {int} (必需)粒子喷射位置宽度范围, 会在左右两侧各deltaWidth的范围内随机出现粒子
22
+ * deltaHeight {int} (必需)粒子喷射位置高度范围, 会在上下两侧各deltaHeight的范围内随机出现粒子
21
23
  * pointSizeMin {int} (必需)粒子尺寸下限(像素)
22
24
  * pointSizeMax {int} (必需)粒子尺寸上限(像素)
23
25
  * speedMin {float} (必需)粒子速度下限
@@ -26,13 +28,16 @@
26
28
  * lifeMax {int} (必需)粒子生命周期上限(ms)
27
29
  * accelerateX {float} (必需)水平方向加速度
28
30
  * accelerateY {float} (必需)垂直方向加速度
29
- * addNumSpeed {float} 持续喷射时,起始粒子添加速度(个/ms), 默认为0.001
31
+ * addNumSpeed {float} (废弃)持续喷射时,起始粒子添加速度(个/ms), 默认为0.001
32
+ * particleAddSpeed {float} 持续喷射时,起始粒子添加速度(个/ms), 默认为0.001
30
33
  * enableFade {boolean} 粒子淡出开关, 默认为false
31
34
  * enableShrink {boolean} 粒子缩小开关, 默认为false
32
- * angularVelocityMin {float} 角速度最小值, 默认为0
33
- * angularVelocityMax {float} 角速度最大值, 默认为0
35
+ * angularVelocityMin {float} 角速度最小值(角度/秒), 默认为0
36
+ * angularVelocityMax {float} 角速度最大值(角度/秒), 默认为0
34
37
  * alphaMin {float} 透明度最小值, 默认为1
35
38
  * alphaMax {float} 透明度最大值, 默认为1
39
+ * angleMin {float} 角度最小值(角度)
40
+ * angleMax {float} 角度最大值(角度)
36
41
  -->
37
42
  <script>
38
43
  import { Forge } from "@shijiu/jsview/dom/jsv-forge-define";
@@ -61,9 +66,10 @@ let buildForgeView = (pointRes, sprayStyle, sizeRef, ignoreClip) => {
61
66
  );
62
67
  }
63
68
  const spray_view = new Forge.SprayView(texture_setting);
64
- const add_num_per_frame = sprayStyle.addNumSpeed
65
- ? sprayStyle.addNumSpeed
66
- : 0.001;
69
+ let add_speed = .1;
70
+ if (typeof sprayStyle.particleAddSpeed == "number") {
71
+ add_speed = sprayStyle.particleAddSpeed;
72
+ }
67
73
  const accelerate_x =
68
74
  typeof sprayStyle.accelerateX !== "undefined" ? sprayStyle.accelerateX : 0;
69
75
  const accelerate_y =
@@ -76,8 +82,8 @@ let buildForgeView = (pointRes, sprayStyle, sizeRef, ignoreClip) => {
76
82
  typeof sprayStyle.angularVelocityMin === "number" &&
77
83
  typeof sprayStyle.angularVelocityMax === "number"
78
84
  ) {
79
- angularVelocityMin = sprayStyle.angularVelocityMin;
80
- angularVelocityMax = sprayStyle.angularVelocityMax;
85
+ angularVelocityMin = (sprayStyle.angularVelocityMin / 180) * 3.1415;
86
+ angularVelocityMax = (sprayStyle.angularVelocityMax / 180) * 3.1415;
81
87
  }
82
88
  let alphaMin = 1,
83
89
  alphaMax = 1;
@@ -95,10 +101,19 @@ let buildForgeView = (pointRes, sprayStyle, sizeRef, ignoreClip) => {
95
101
  lifeMin = sprayStyle.lifeMin > 50000 ? 50000 : sprayStyle.lifeMin;
96
102
  lifeMax = sprayStyle.lifeMax > 50000 ? 50000 : sprayStyle.lifeMax;
97
103
  }
104
+
105
+ let angleMin = 0, angleMax = 0;
106
+ if (typeof sprayStyle.angleMin == "number" && typeof sprayStyle.angleMax == "number") {
107
+ if (sprayStyle.angleMin <= sprayStyle.angleMax) {
108
+ angleMin = (sprayStyle.angleMin / 180) * 3.1415;
109
+ angleMax = (sprayStyle.angleMax / 180) * 3.1415;
110
+ }
111
+ }
112
+
98
113
  spray_view.SetSprayInfo(
99
114
  sprayStyle.type,
100
115
  sprayStyle.particleNum,
101
- add_num_per_frame,
116
+ add_speed,
102
117
  (sprayStyle.deltaAngle / 180) * 3.1415,
103
118
  sprayStyle.deltaWidth,
104
119
  sprayStyle.deltaHeight,
@@ -116,7 +131,9 @@ let buildForgeView = (pointRes, sprayStyle, sizeRef, ignoreClip) => {
116
131
  angularVelocityMin,
117
132
  angularVelocityMax,
118
133
  alphaMin,
119
- alphaMax
134
+ alphaMax,
135
+ angleMin,
136
+ angleMax,
120
137
  );
121
138
  const view_width =
122
139
  sprayStyle.deltaWidth === 0 ? 1 : 2 * sprayStyle.deltaWidth;
@@ -1,4 +1,6 @@
1
1
  <!--
2
+ * @file
3
+ *
2
4
  * 【模块 export 内容】
3
5
  * JsvSpriteAnim: 描画动态的精灵图(雪碧图)
4
6
  * 注意: PC模拟环境中,动画执行完成如果在onAnimEnd立刻进行不显示的话,可能闪一帧残留图像,在盒子不会有这个问题
@@ -1,4 +1,6 @@
1
1
  <!--
2
+ * @file
3
+ *
2
4
  * 【模块 export 内容】
3
5
  * JsvSpriteLoader: 雪碧图资源加载器
4
6
  * prop说明:
@@ -1,4 +1,6 @@
1
1
  <!--
2
+ * @file
3
+ *
2
4
  * 【模块 export 内容】
3
5
  * JsvSwiper:Vue高阶组件,图片轮播组件
4
6
  * props说明:
@@ -1,4 +1,6 @@
1
1
  <!--
2
+ * @file
3
+ *
2
4
  * 【模块 export 内容】
3
5
  * JsvSwiper3D:Vue高阶组件,图片轮播3D组件
4
6
  * props说明:
@@ -1,8 +1,6 @@
1
1
  <!--
2
- * Created by chunfeng.luo@qcast.cn on 10/13/20.
3
- */
4
-
5
- /*
2
+ * @file
3
+ *
6
4
  * JsvTextBox:Vue高阶组件,用于文字绘制要精细调整的场景,
7
5
  * 注意: 其中Jsv打头的属性为内部属性,不要在组件外直接使用,规避后续调整时进行变名等调整导致使用不了。
8
6
  * props说明: