@atomicservice/ascf-base 1.0.14 → 1.0.16

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 (501) hide show
  1. package/dist/index.d.mts +119 -31
  2. package/dist/index.d.ts +119 -31
  3. package/dist/index.js +340 -69
  4. package/dist/index.mjs +340 -69
  5. package/dist/media/service_app_icon_template.png +0 -0
  6. package/dist/templates/ascfDemos/app.css +283 -0
  7. package/dist/templates/ascfDemos/app.js +6 -0
  8. package/dist/templates/ascfDemos/app.json +124 -0
  9. package/dist/templates/ascfDemos/asui/as-cell/as-cell.css +18 -0
  10. package/dist/templates/ascfDemos/asui/as-cell/as-cell.hxml +11 -0
  11. package/dist/templates/ascfDemos/asui/as-cell/as-cell.js +29 -0
  12. package/dist/templates/ascfDemos/asui/as-cell/as-cell.json +4 -0
  13. package/dist/templates/ascfDemos/asui/as-container/as-container.css +48 -0
  14. package/dist/templates/ascfDemos/asui/as-container/as-container.hxml +11 -0
  15. package/dist/templates/ascfDemos/asui/as-container/as-container.js +35 -0
  16. package/dist/templates/ascfDemos/asui/as-container/as-container.json +4 -0
  17. package/dist/templates/ascfDemos/asui/as-toggle-list/as-toggle-list.css +43 -0
  18. package/dist/templates/ascfDemos/asui/as-toggle-list/as-toggle-list.hxml +19 -0
  19. package/dist/templates/ascfDemos/asui/as-toggle-list/as-toggle-list.js +41 -0
  20. package/dist/templates/ascfDemos/asui/as-toggle-list/as-toggle-list.json +4 -0
  21. package/dist/templates/ascfDemos/config/api.config.js +195 -0
  22. package/dist/templates/ascfDemos/config/component.config.js +152 -0
  23. package/dist/templates/ascfDemos/config/framework.config.js +29 -0
  24. package/dist/templates/ascfDemos/config/global.config.js +28 -0
  25. package/dist/templates/ascfDemos/config/open.config.js +41 -0
  26. package/dist/templates/ascfDemos/extConfig.json +5 -0
  27. package/dist/templates/ascfDemos/gitignore +15 -0
  28. package/dist/templates/ascfDemos/image/exitscreen.png +0 -0
  29. package/dist/templates/ascfDemos/image/fullscreen.png +0 -0
  30. package/dist/templates/ascfDemos/image/green_tri.png +0 -0
  31. package/dist/templates/ascfDemos/image/icon_api.svg +11 -0
  32. package/dist/templates/ascfDemos/image/icon_api_HL.svg +11 -0
  33. package/dist/templates/ascfDemos/image/icon_component.svg +11 -0
  34. package/dist/templates/ascfDemos/image/icon_component_HL.svg +11 -0
  35. package/dist/templates/ascfDemos/image/icon_framework.svg +10 -0
  36. package/dist/templates/ascfDemos/image/icon_framework_HL.svg +12 -0
  37. package/dist/templates/ascfDemos/image/icon_open.svg +11 -0
  38. package/dist/templates/ascfDemos/image/icon_open_HL.svg +10 -0
  39. package/dist/templates/ascfDemos/image/location.png +0 -0
  40. package/dist/templates/ascfDemos/image/logo_api.svg +17 -0
  41. package/dist/templates/ascfDemos/image/logo_component.svg +17 -0
  42. package/dist/templates/ascfDemos/image/logo_framework.svg +18 -0
  43. package/dist/templates/ascfDemos/image/logo_open.svg +16 -0
  44. package/dist/templates/ascfDemos/image/pause.png +0 -0
  45. package/dist/templates/ascfDemos/image/play.png +0 -0
  46. package/dist/templates/ascfDemos/image/plus.png +0 -0
  47. package/dist/templates/ascfDemos/image/record.png +0 -0
  48. package/dist/templates/ascfDemos/image/share.png +0 -0
  49. package/dist/templates/ascfDemos/image/stop.png +0 -0
  50. package/dist/templates/ascfDemos/image/test.gif +0 -0
  51. package/dist/templates/ascfDemos/image/toggle_arrow_down.svg +14 -0
  52. package/dist/templates/ascfDemos/image/toggle_arrow_right.svg +14 -0
  53. package/dist/templates/ascfDemos/image/toggle_arrow_up.svg +14 -0
  54. package/dist/templates/ascfDemos/image/trash.png +0 -0
  55. package/dist/templates/ascfDemos/packageA/index/index.css +0 -0
  56. package/dist/templates/ascfDemos/packageA/index/index.hxml +1 -0
  57. package/dist/templates/ascfDemos/packageA/index/index.js +1 -0
  58. package/dist/templates/ascfDemos/packageA/index/index.json +4 -0
  59. package/dist/templates/ascfDemos/page/API/image/brightness_dark.png +0 -0
  60. package/dist/templates/ascfDemos/page/API/image/brightness_light.png +0 -0
  61. package/dist/templates/ascfDemos/page/API/image/user.png +0 -0
  62. package/dist/templates/ascfDemos/page/API/image/wifi_0.png +0 -0
  63. package/dist/templates/ascfDemos/page/API/image/wifi_1.png +0 -0
  64. package/dist/templates/ascfDemos/page/API/image/wifi_2.png +0 -0
  65. package/dist/templates/ascfDemos/page/API/image/wifi_3.png +0 -0
  66. package/dist/templates/ascfDemos/page/API/image/wifi_4.png +0 -0
  67. package/dist/templates/ascfDemos/page/API/index.css +11 -0
  68. package/dist/templates/ascfDemos/page/API/index.hxml +8 -0
  69. package/dist/templates/ascfDemos/page/API/index.js +23 -0
  70. package/dist/templates/ascfDemos/page/API/index.json +8 -0
  71. package/dist/templates/ascfDemos/page/API/pages/add-contact/add-contact.js +27 -0
  72. package/dist/templates/ascfDemos/page/API/pages/appEvent/appEvent.css +7 -0
  73. package/dist/templates/ascfDemos/page/API/pages/appEvent/appEvent.hxml +39 -0
  74. package/dist/templates/ascfDemos/page/API/pages/appEvent/appEvent.js +238 -0
  75. package/dist/templates/ascfDemos/page/API/pages/appEvent/appEvent.json +3 -0
  76. package/dist/templates/ascfDemos/page/API/pages/battery/battery.css +4 -0
  77. package/dist/templates/ascfDemos/page/API/pages/battery/battery.hxml +16 -0
  78. package/dist/templates/ascfDemos/page/API/pages/battery/battery.js +34 -0
  79. package/dist/templates/ascfDemos/page/API/pages/battery/battery.json +3 -0
  80. package/dist/templates/ascfDemos/page/API/pages/bluetooth/bluetooth.css +49 -0
  81. package/dist/templates/ascfDemos/page/API/pages/bluetooth/bluetooth.hxml +18 -0
  82. package/dist/templates/ascfDemos/page/API/pages/bluetooth/bluetooth.js +143 -0
  83. package/dist/templates/ascfDemos/page/API/pages/bluetooth/bluetooth.json +3 -0
  84. package/dist/templates/ascfDemos/page/API/pages/calendar/calendar.css +0 -0
  85. package/dist/templates/ascfDemos/page/API/pages/calendar/calendar.hxml +6 -0
  86. package/dist/templates/ascfDemos/page/API/pages/calendar/calendar.js +37 -0
  87. package/dist/templates/ascfDemos/page/API/pages/calendar/calendar.json +3 -0
  88. package/dist/templates/ascfDemos/page/API/pages/camera/camera.css +40 -0
  89. package/dist/templates/ascfDemos/page/API/pages/camera/camera.hxml +27 -0
  90. package/dist/templates/ascfDemos/page/API/pages/camera/camera.js +153 -0
  91. package/dist/templates/ascfDemos/page/API/pages/camera/camera.json +3 -0
  92. package/dist/templates/ascfDemos/page/API/pages/canIUse/canIUse.css +27 -0
  93. package/dist/templates/ascfDemos/page/API/pages/canIUse/canIUse.hxml +7 -0
  94. package/dist/templates/ascfDemos/page/API/pages/canIUse/canIUse.js +22 -0
  95. package/dist/templates/ascfDemos/page/API/pages/canIUse/canIUse.json +3 -0
  96. package/dist/templates/ascfDemos/page/API/pages/choose-location/choose-location.css +1 -0
  97. package/dist/templates/ascfDemos/page/API/pages/choose-location/choose-location.hxml +45 -0
  98. package/dist/templates/ascfDemos/page/API/pages/choose-location/choose-location.js +26 -0
  99. package/dist/templates/ascfDemos/page/API/pages/choose-location/choose-location.json +3 -0
  100. package/dist/templates/ascfDemos/page/API/pages/compass/compass.css +47 -0
  101. package/dist/templates/ascfDemos/page/API/pages/compass/compass.hxml +29 -0
  102. package/dist/templates/ascfDemos/page/API/pages/compass/compass.js +84 -0
  103. package/dist/templates/ascfDemos/page/API/pages/compass/compass.json +3 -0
  104. package/dist/templates/ascfDemos/page/API/pages/compass/compass.png +0 -0
  105. package/dist/templates/ascfDemos/page/API/pages/contact/add-contact/add-contact.css +1 -0
  106. package/dist/templates/ascfDemos/page/API/pages/contact/add-contact/add-contact.hxml +53 -0
  107. package/dist/templates/ascfDemos/page/API/pages/contact/add-contact/add-contact.js +59 -0
  108. package/dist/templates/ascfDemos/page/API/pages/contact/add-contact/add-contact.json +3 -0
  109. package/dist/templates/ascfDemos/page/API/pages/contact/contact.css +29 -0
  110. package/dist/templates/ascfDemos/page/API/pages/contact/contact.hxml +34 -0
  111. package/dist/templates/ascfDemos/page/API/pages/contact/contact.js +47 -0
  112. package/dist/templates/ascfDemos/page/API/pages/contact/contact.json +3 -0
  113. package/dist/templates/ascfDemos/page/API/pages/deviceMotionListening/deviceMotionListening.css +21 -0
  114. package/dist/templates/ascfDemos/page/API/pages/deviceMotionListening/deviceMotionListening.hxml +20 -0
  115. package/dist/templates/ascfDemos/page/API/pages/deviceMotionListening/deviceMotionListening.js +35 -0
  116. package/dist/templates/ascfDemos/page/API/pages/deviceMotionListening/deviceMotionListening.json +3 -0
  117. package/dist/templates/ascfDemos/page/API/pages/downRefresh/downRefresh.css +0 -0
  118. package/dist/templates/ascfDemos/page/API/pages/downRefresh/downRefresh.hxml +3 -0
  119. package/dist/templates/ascfDemos/page/API/pages/downRefresh/downRefresh.js +16 -0
  120. package/dist/templates/ascfDemos/page/API/pages/downRefresh/downRefresh.json +5 -0
  121. package/dist/templates/ascfDemos/page/API/pages/download-file/download-file.css +6 -0
  122. package/dist/templates/ascfDemos/page/API/pages/download-file/download-file.hxml +4 -0
  123. package/dist/templates/ascfDemos/page/API/pages/download-file/download-file.js +42 -0
  124. package/dist/templates/ascfDemos/page/API/pages/download-file/download-file.json +3 -0
  125. package/dist/templates/ascfDemos/page/API/pages/env/env.css +1 -0
  126. package/dist/templates/ascfDemos/page/API/pages/env/env.hxml +16 -0
  127. package/dist/templates/ascfDemos/page/API/pages/env/env.js +15 -0
  128. package/dist/templates/ascfDemos/page/API/pages/env/env.json +3 -0
  129. package/dist/templates/ascfDemos/page/API/pages/file/file.css +9 -0
  130. package/dist/templates/ascfDemos/page/API/pages/file/file.hxml +8 -0
  131. package/dist/templates/ascfDemos/page/API/pages/file/file.js +75 -0
  132. package/dist/templates/ascfDemos/page/API/pages/file/file.json +3 -0
  133. package/dist/templates/ascfDemos/page/API/pages/fileManager/fileManager.css +16 -0
  134. package/dist/templates/ascfDemos/page/API/pages/fileManager/fileManager.hxml +17 -0
  135. package/dist/templates/ascfDemos/page/API/pages/fileManager/fileManager.js +16 -0
  136. package/dist/templates/ascfDemos/page/API/pages/fileManager/fileManager.json +3 -0
  137. package/dist/templates/ascfDemos/page/API/pages/get-ext-config/get-ext-config.css +0 -0
  138. package/dist/templates/ascfDemos/page/API/pages/get-ext-config/get-ext-config.hxml +3 -0
  139. package/dist/templates/ascfDemos/page/API/pages/get-ext-config/get-ext-config.js +22 -0
  140. package/dist/templates/ascfDemos/page/API/pages/get-ext-config/get-ext-config.json +3 -0
  141. package/dist/templates/ascfDemos/page/API/pages/get-fuzzy-location/get-fuzzy-location.css +27 -0
  142. package/dist/templates/ascfDemos/page/API/pages/get-fuzzy-location/get-fuzzy-location.hxml +10 -0
  143. package/dist/templates/ascfDemos/page/API/pages/get-fuzzy-location/get-fuzzy-location.js +25 -0
  144. package/dist/templates/ascfDemos/page/API/pages/get-fuzzy-location/get-fuzzy-location.json +3 -0
  145. package/dist/templates/ascfDemos/page/API/pages/get-hxml-info/get-hxml-info.css +47 -0
  146. package/dist/templates/ascfDemos/page/API/pages/get-hxml-info/get-hxml-info.hxml +35 -0
  147. package/dist/templates/ascfDemos/page/API/pages/get-hxml-info/get-hxml-info.js +29 -0
  148. package/dist/templates/ascfDemos/page/API/pages/get-hxml-info/get-hxml-info.json +3 -0
  149. package/dist/templates/ascfDemos/page/API/pages/get-location/get-location.css +27 -0
  150. package/dist/templates/ascfDemos/page/API/pages/get-location/get-location.hxml +10 -0
  151. package/dist/templates/ascfDemos/page/API/pages/get-location/get-location.js +23 -0
  152. package/dist/templates/ascfDemos/page/API/pages/get-location/get-location.json +3 -0
  153. package/dist/templates/ascfDemos/page/API/pages/get-system-info/get-system-info.css +1 -0
  154. package/dist/templates/ascfDemos/page/API/pages/get-system-info/get-system-info.hxml +38 -0
  155. package/dist/templates/ascfDemos/page/API/pages/get-system-info/get-system-info.js +51 -0
  156. package/dist/templates/ascfDemos/page/API/pages/get-system-info/get-system-info.json +3 -0
  157. package/dist/templates/ascfDemos/page/API/pages/get-system-info-sync/get-system-info-sync.css +1 -0
  158. package/dist/templates/ascfDemos/page/API/pages/get-system-info-sync/get-system-info-sync.hxml +39 -0
  159. package/dist/templates/ascfDemos/page/API/pages/get-system-info-sync/get-system-info-sync.js +45 -0
  160. package/dist/templates/ascfDemos/page/API/pages/get-system-info-sync/get-system-info-sync.json +3 -0
  161. package/dist/templates/ascfDemos/page/API/pages/getLaunchOptions/getLaunchOptions.css +12 -0
  162. package/dist/templates/ascfDemos/page/API/pages/getLaunchOptions/getLaunchOptions.hxml +24 -0
  163. package/dist/templates/ascfDemos/page/API/pages/getLaunchOptions/getLaunchOptions.js +17 -0
  164. package/dist/templates/ascfDemos/page/API/pages/getLaunchOptions/getLaunchOptions.json +3 -0
  165. package/dist/templates/ascfDemos/page/API/pages/getNetworkType/getNetworkType.css +10 -0
  166. package/dist/templates/ascfDemos/page/API/pages/getNetworkType/getNetworkType.hxml +4 -0
  167. package/dist/templates/ascfDemos/page/API/pages/getNetworkType/getNetworkType.js +15 -0
  168. package/dist/templates/ascfDemos/page/API/pages/getNetworkType/getNetworkType.json +3 -0
  169. package/dist/templates/ascfDemos/page/API/pages/gyroscope/gyroscope.css +18 -0
  170. package/dist/templates/ascfDemos/page/API/pages/gyroscope/gyroscope.hxml +29 -0
  171. package/dist/templates/ascfDemos/page/API/pages/gyroscope/gyroscope.js +111 -0
  172. package/dist/templates/ascfDemos/page/API/pages/gyroscope/gyroscope.json +3 -0
  173. package/dist/templates/ascfDemos/page/API/pages/image/image.css +40 -0
  174. package/dist/templates/ascfDemos/page/API/pages/image/image.hxml +17 -0
  175. package/dist/templates/ascfDemos/page/API/pages/image/image.js +82 -0
  176. package/dist/templates/ascfDemos/page/API/pages/image/image.json +3 -0
  177. package/dist/templates/ascfDemos/page/API/pages/intervalAndTimeOut/intervalAndTimeOut.css +0 -0
  178. package/dist/templates/ascfDemos/page/API/pages/intervalAndTimeOut/intervalAndTimeOut.hxml +10 -0
  179. package/dist/templates/ascfDemos/page/API/pages/intervalAndTimeOut/intervalAndTimeOut.js +54 -0
  180. package/dist/templates/ascfDemos/page/API/pages/intervalAndTimeOut/intervalAndTimeOut.json +3 -0
  181. package/dist/templates/ascfDemos/page/API/pages/make-phone-call/make-phone-call.css +17 -0
  182. package/dist/templates/ascfDemos/page/API/pages/make-phone-call/make-phone-call.hxml +6 -0
  183. package/dist/templates/ascfDemos/page/API/pages/make-phone-call/make-phone-call.js +15 -0
  184. package/dist/templates/ascfDemos/page/API/pages/make-phone-call/make-phone-call.json +3 -0
  185. package/dist/templates/ascfDemos/page/API/pages/navigationBar/navigationBar.css +6 -0
  186. package/dist/templates/ascfDemos/page/API/pages/navigationBar/navigationBar.hxml +10 -0
  187. package/dist/templates/ascfDemos/page/API/pages/navigationBar/navigationBar.js +93 -0
  188. package/dist/templates/ascfDemos/page/API/pages/navigationBar/navigationBar.json +4 -0
  189. package/dist/templates/ascfDemos/page/API/pages/navigator/navigate/navigate.css +0 -0
  190. package/dist/templates/ascfDemos/page/API/pages/navigator/navigate/navigate.hxml +1 -0
  191. package/dist/templates/ascfDemos/page/API/pages/navigator/navigate/navigate.js +2 -0
  192. package/dist/templates/ascfDemos/page/API/pages/navigator/navigate/navigate.json +3 -0
  193. package/dist/templates/ascfDemos/page/API/pages/navigator/navigator.css +0 -0
  194. package/dist/templates/ascfDemos/page/API/pages/navigator/navigator.hxml +6 -0
  195. package/dist/templates/ascfDemos/page/API/pages/navigator/navigator.js +22 -0
  196. package/dist/templates/ascfDemos/page/API/pages/navigator/navigator.json +3 -0
  197. package/dist/templates/ascfDemos/page/API/pages/navigator/redirect/redirect.css +0 -0
  198. package/dist/templates/ascfDemos/page/API/pages/navigator/redirect/redirect.hxml +1 -0
  199. package/dist/templates/ascfDemos/page/API/pages/navigator/redirect/redirect.js +2 -0
  200. package/dist/templates/ascfDemos/page/API/pages/navigator/redirect/redirect.json +3 -0
  201. package/dist/templates/ascfDemos/page/API/pages/open-location/open-location.css +1 -0
  202. package/dist/templates/ascfDemos/page/API/pages/open-location/open-location.hxml +48 -0
  203. package/dist/templates/ascfDemos/page/API/pages/open-location/open-location.js +44 -0
  204. package/dist/templates/ascfDemos/page/API/pages/open-location/open-location.json +3 -0
  205. package/dist/templates/ascfDemos/page/API/pages/page-scroll/page-scroll.css +11 -0
  206. package/dist/templates/ascfDemos/page/API/pages/page-scroll/page-scroll.hxml +13 -0
  207. package/dist/templates/ascfDemos/page/API/pages/page-scroll/page-scroll.js +35 -0
  208. package/dist/templates/ascfDemos/page/API/pages/page-scroll/page-scroll.json +3 -0
  209. package/dist/templates/ascfDemos/page/API/pages/request/request.css +0 -0
  210. package/dist/templates/ascfDemos/page/API/pages/request/request.hxml +3 -0
  211. package/dist/templates/ascfDemos/page/API/pages/request/request.js +34 -0
  212. package/dist/templates/ascfDemos/page/API/pages/request/request.json +3 -0
  213. package/dist/templates/ascfDemos/page/API/pages/scan-code/scan-code.css +35 -0
  214. package/dist/templates/ascfDemos/page/API/pages/scan-code/scan-code.hxml +9 -0
  215. package/dist/templates/ascfDemos/page/API/pages/scan-code/scan-code.js +16 -0
  216. package/dist/templates/ascfDemos/page/API/pages/scan-code/scan-code.json +3 -0
  217. package/dist/templates/ascfDemos/page/API/pages/set-tab-bar/set-tab-bar.css +30 -0
  218. package/dist/templates/ascfDemos/page/API/pages/set-tab-bar/set-tab-bar.hxml +17 -0
  219. package/dist/templates/ascfDemos/page/API/pages/set-tab-bar/set-tab-bar.js +61 -0
  220. package/dist/templates/ascfDemos/page/API/pages/set-tab-bar/set-tab-bar.json +4 -0
  221. package/dist/templates/ascfDemos/page/API/pages/setNavigationBarTitle/setNavigationBarTitle.css +24 -0
  222. package/dist/templates/ascfDemos/page/API/pages/setNavigationBarTitle/setNavigationBarTitle.hxml +7 -0
  223. package/dist/templates/ascfDemos/page/API/pages/setNavigationBarTitle/setNavigationBarTitle.js +15 -0
  224. package/dist/templates/ascfDemos/page/API/pages/setNavigationBarTitle/setNavigationBarTitle.json +3 -0
  225. package/dist/templates/ascfDemos/page/API/pages/setScreenBrightness/setScreenBrightness.css +28 -0
  226. package/dist/templates/ascfDemos/page/API/pages/setScreenBrightness/setScreenBrightness.hxml +14 -0
  227. package/dist/templates/ascfDemos/page/API/pages/setScreenBrightness/setScreenBrightness.js +47 -0
  228. package/dist/templates/ascfDemos/page/API/pages/setScreenBrightness/setScreenBrightness.json +3 -0
  229. package/dist/templates/ascfDemos/page/API/pages/setting/setting.css +12 -0
  230. package/dist/templates/ascfDemos/page/API/pages/setting/setting.hxml +77 -0
  231. package/dist/templates/ascfDemos/page/API/pages/setting/setting.js +19 -0
  232. package/dist/templates/ascfDemos/page/API/pages/setting/setting.json +3 -0
  233. package/dist/templates/ascfDemos/page/API/pages/showToast/loading/loading.css +3 -0
  234. package/dist/templates/ascfDemos/page/API/pages/showToast/loading/loading.hxml +4 -0
  235. package/dist/templates/ascfDemos/page/API/pages/showToast/loading/loading.js +30 -0
  236. package/dist/templates/ascfDemos/page/API/pages/showToast/loading/loading.json +3 -0
  237. package/dist/templates/ascfDemos/page/API/pages/showToast/modal/modal.css +3 -0
  238. package/dist/templates/ascfDemos/page/API/pages/showToast/modal/modal.hxml +4 -0
  239. package/dist/templates/ascfDemos/page/API/pages/showToast/modal/modal.js +38 -0
  240. package/dist/templates/ascfDemos/page/API/pages/showToast/modal/modal.json +3 -0
  241. package/dist/templates/ascfDemos/page/API/pages/showToast/toast/toast.css +3 -0
  242. package/dist/templates/ascfDemos/page/API/pages/showToast/toast/toast.hxml +3 -0
  243. package/dist/templates/ascfDemos/page/API/pages/showToast/toast/toast.js +16 -0
  244. package/dist/templates/ascfDemos/page/API/pages/showToast/toast/toast.json +3 -0
  245. package/dist/templates/ascfDemos/page/API/pages/storage/storage.css +22 -0
  246. package/dist/templates/ascfDemos/page/API/pages/storage/storage.hxml +15 -0
  247. package/dist/templates/ascfDemos/page/API/pages/storage/storage.js +140 -0
  248. package/dist/templates/ascfDemos/page/API/pages/storage/storage.json +3 -0
  249. package/dist/templates/ascfDemos/page/API/pages/upload-file/upload-file.css +10 -0
  250. package/dist/templates/ascfDemos/page/API/pages/upload-file/upload-file.hxml +13 -0
  251. package/dist/templates/ascfDemos/page/API/pages/upload-file/upload-file.js +41 -0
  252. package/dist/templates/ascfDemos/page/API/pages/upload-file/upload-file.json +3 -0
  253. package/dist/templates/ascfDemos/page/API/pages/vibrate/vibrate.css +7 -0
  254. package/dist/templates/ascfDemos/page/API/pages/vibrate/vibrate.hxml +8 -0
  255. package/dist/templates/ascfDemos/page/API/pages/vibrate/vibrate.js +11 -0
  256. package/dist/templates/ascfDemos/page/API/pages/vibrate/vibrate.json +3 -0
  257. package/dist/templates/ascfDemos/page/API/pages/video/index.css +20 -0
  258. package/dist/templates/ascfDemos/page/API/pages/video/index.hxml +14 -0
  259. package/dist/templates/ascfDemos/page/API/pages/video/index.js +38 -0
  260. package/dist/templates/ascfDemos/page/API/pages/video/index.json +3 -0
  261. package/dist/templates/ascfDemos/page/API/pages/video/video.css +17 -0
  262. package/dist/templates/ascfDemos/page/API/pages/video/video.hxml +7 -0
  263. package/dist/templates/ascfDemos/page/API/pages/video/video.js +23 -0
  264. package/dist/templates/ascfDemos/page/API/pages/video/video.json +3 -0
  265. package/dist/templates/ascfDemos/page/API/pages/webSocket/webSocket.css +33 -0
  266. package/dist/templates/ascfDemos/page/API/pages/webSocket/webSocket.hxml +17 -0
  267. package/dist/templates/ascfDemos/page/API/pages/webSocket/webSocket.js +103 -0
  268. package/dist/templates/ascfDemos/page/API/pages/webSocket/webSocket.json +3 -0
  269. package/dist/templates/ascfDemos/page/API/pages/wifi/wifi.css +95 -0
  270. package/dist/templates/ascfDemos/page/API/pages/wifi/wifi.hxml +32 -0
  271. package/dist/templates/ascfDemos/page/API/pages/wifi/wifi.js +42 -0
  272. package/dist/templates/ascfDemos/page/API/pages/wifi/wifi.json +3 -0
  273. package/dist/templates/ascfDemos/page/API/pages/wx/navigationBarTitle/navigationBarTitle.css +2 -0
  274. package/dist/templates/ascfDemos/page/API/pages/wx/navigationBarTitle/navigationBarTitle.hxml +19 -0
  275. package/dist/templates/ascfDemos/page/API/pages/wx/navigationBarTitle/navigationBarTitle.js +182 -0
  276. package/dist/templates/ascfDemos/page/API/pages/wx/navigationBarTitle/navigationBarTitle.json +4 -0
  277. package/dist/templates/ascfDemos/page/common/index.css +117 -0
  278. package/dist/templates/ascfDemos/page/common/lib/asui.css +1036 -0
  279. package/dist/templates/ascfDemos/page/component/image/green_tri.png +0 -0
  280. package/dist/templates/ascfDemos/page/component/image/location.png +0 -0
  281. package/dist/templates/ascfDemos/page/component/image/logo.png +0 -0
  282. package/dist/templates/ascfDemos/page/component/image/roadway.png +0 -0
  283. package/dist/templates/ascfDemos/page/component/index.css +11 -0
  284. package/dist/templates/ascfDemos/page/component/index.hxml +7 -0
  285. package/dist/templates/ascfDemos/page/component/index.js +10 -0
  286. package/dist/templates/ascfDemos/page/component/index.json +7 -0
  287. package/dist/templates/ascfDemos/page/component/pages/button/button.css +11 -0
  288. package/dist/templates/ascfDemos/page/component/pages/button/button.hxml +11 -0
  289. package/dist/templates/ascfDemos/page/component/pages/button/button.js +4 -0
  290. package/dist/templates/ascfDemos/page/component/pages/button/button.json +3 -0
  291. package/dist/templates/ascfDemos/page/component/pages/camera/camera.css +12 -0
  292. package/dist/templates/ascfDemos/page/component/pages/camera/camera.hxml +8 -0
  293. package/dist/templates/ascfDemos/page/component/pages/camera/camera.js +113 -0
  294. package/dist/templates/ascfDemos/page/component/pages/camera/camera.json +3 -0
  295. package/dist/templates/ascfDemos/page/component/pages/canvas/canvas.css +10 -0
  296. package/dist/templates/ascfDemos/page/component/pages/canvas/canvas.hxml +5 -0
  297. package/dist/templates/ascfDemos/page/component/pages/canvas/canvas.js +49 -0
  298. package/dist/templates/ascfDemos/page/component/pages/canvas/canvas.json +3 -0
  299. package/dist/templates/ascfDemos/page/component/pages/checkbox/checkbox.css +13 -0
  300. package/dist/templates/ascfDemos/page/component/pages/checkbox/checkbox.hxml +8 -0
  301. package/dist/templates/ascfDemos/page/component/pages/checkbox/checkbox.js +17 -0
  302. package/dist/templates/ascfDemos/page/component/pages/checkbox/checkbox.json +3 -0
  303. package/dist/templates/ascfDemos/page/component/pages/checkboxgroup/checkboxgroup.css +14 -0
  304. package/dist/templates/ascfDemos/page/component/pages/checkboxgroup/checkboxgroup.hxml +26 -0
  305. package/dist/templates/ascfDemos/page/component/pages/checkboxgroup/checkboxgroup.js +21 -0
  306. package/dist/templates/ascfDemos/page/component/pages/checkboxgroup/checkboxgroup.json +3 -0
  307. package/dist/templates/ascfDemos/page/component/pages/form/form.css +27 -0
  308. package/dist/templates/ascfDemos/page/component/pages/form/form.hxml +53 -0
  309. package/dist/templates/ascfDemos/page/component/pages/form/form.js +33 -0
  310. package/dist/templates/ascfDemos/page/component/pages/form/form.json +3 -0
  311. package/dist/templates/ascfDemos/page/component/pages/icon/icon.css +39 -0
  312. package/dist/templates/ascfDemos/page/component/pages/icon/icon.hxml +120 -0
  313. package/dist/templates/ascfDemos/page/component/pages/icon/icon.js +22 -0
  314. package/dist/templates/ascfDemos/page/component/pages/icon/icon.json +3 -0
  315. package/dist/templates/ascfDemos/page/component/pages/image/image.css +3 -0
  316. package/dist/templates/ascfDemos/page/component/pages/image/image.hxml +6 -0
  317. package/dist/templates/ascfDemos/page/component/pages/image/image.js +2 -0
  318. package/dist/templates/ascfDemos/page/component/pages/image/image.json +3 -0
  319. package/dist/templates/ascfDemos/page/component/pages/input/input.css +9 -0
  320. package/dist/templates/ascfDemos/page/component/pages/input/input.hxml +9 -0
  321. package/dist/templates/ascfDemos/page/component/pages/input/input.js +11 -0
  322. package/dist/templates/ascfDemos/page/component/pages/input/input.json +3 -0
  323. package/dist/templates/ascfDemos/page/component/pages/label/label.css +10 -0
  324. package/dist/templates/ascfDemos/page/component/pages/label/label.hxml +31 -0
  325. package/dist/templates/ascfDemos/page/component/pages/label/label.js +12 -0
  326. package/dist/templates/ascfDemos/page/component/pages/label/label.json +3 -0
  327. package/dist/templates/ascfDemos/page/component/pages/map/map.css +0 -0
  328. package/dist/templates/ascfDemos/page/component/pages/map/map.hxml +1 -0
  329. package/dist/templates/ascfDemos/page/component/pages/map/map.js +33 -0
  330. package/dist/templates/ascfDemos/page/component/pages/map/map.json +3 -0
  331. package/dist/templates/ascfDemos/page/component/pages/movable-area/movable-area.css +39 -0
  332. package/dist/templates/ascfDemos/page/component/pages/movable-area/movable-area.hxml +44 -0
  333. package/dist/templates/ascfDemos/page/component/pages/movable-area/movable-area.js +59 -0
  334. package/dist/templates/ascfDemos/page/component/pages/movable-area/movable-area.json +3 -0
  335. package/dist/templates/ascfDemos/page/component/pages/movable-view/movable-view.css +21 -0
  336. package/dist/templates/ascfDemos/page/component/pages/movable-view/movable-view.hxml +27 -0
  337. package/dist/templates/ascfDemos/page/component/pages/movable-view/movable-view.js +2 -0
  338. package/dist/templates/ascfDemos/page/component/pages/movable-view/movable-view.json +3 -0
  339. package/dist/templates/ascfDemos/page/component/pages/navigator/navigate/navigate.css +0 -0
  340. package/dist/templates/ascfDemos/page/component/pages/navigator/navigate/navigate.hxml +1 -0
  341. package/dist/templates/ascfDemos/page/component/pages/navigator/navigate/navigate.js +2 -0
  342. package/dist/templates/ascfDemos/page/component/pages/navigator/navigate/navigate.json +3 -0
  343. package/dist/templates/ascfDemos/page/component/pages/navigator/navigator.css +12 -0
  344. package/dist/templates/ascfDemos/page/component/pages/navigator/navigator.hxml +11 -0
  345. package/dist/templates/ascfDemos/page/component/pages/navigator/navigator.js +3 -0
  346. package/dist/templates/ascfDemos/page/component/pages/navigator/navigator.json +3 -0
  347. package/dist/templates/ascfDemos/page/component/pages/navigator/reLaunch/reLaunch.css +0 -0
  348. package/dist/templates/ascfDemos/page/component/pages/navigator/reLaunch/reLaunch.hxml +1 -0
  349. package/dist/templates/ascfDemos/page/component/pages/navigator/reLaunch/reLaunch.js +4 -0
  350. package/dist/templates/ascfDemos/page/component/pages/navigator/reLaunch/reLaunch.json +3 -0
  351. package/dist/templates/ascfDemos/page/component/pages/navigator/redirect/redirect.css +0 -0
  352. package/dist/templates/ascfDemos/page/component/pages/navigator/redirect/redirect.hxml +1 -0
  353. package/dist/templates/ascfDemos/page/component/pages/navigator/redirect/redirect.js +3 -0
  354. package/dist/templates/ascfDemos/page/component/pages/navigator/redirect/redirect.json +3 -0
  355. package/dist/templates/ascfDemos/page/component/pages/picker/picker.css +25 -0
  356. package/dist/templates/ascfDemos/page/component/pages/picker/picker.hxml +47 -0
  357. package/dist/templates/ascfDemos/page/component/pages/picker/picker.js +57 -0
  358. package/dist/templates/ascfDemos/page/component/pages/picker/picker.json +3 -0
  359. package/dist/templates/ascfDemos/page/component/pages/picker-view/picker-view.css +9 -0
  360. package/dist/templates/ascfDemos/page/component/pages/picker-view/picker-view.hxml +15 -0
  361. package/dist/templates/ascfDemos/page/component/pages/picker-view/picker-view.js +39 -0
  362. package/dist/templates/ascfDemos/page/component/pages/picker-view/picker-view.json +3 -0
  363. package/dist/templates/ascfDemos/page/component/pages/progress/progress.css +0 -0
  364. package/dist/templates/ascfDemos/page/component/pages/progress/progress.hxml +3 -0
  365. package/dist/templates/ascfDemos/page/component/pages/progress/progress.js +4 -0
  366. package/dist/templates/ascfDemos/page/component/pages/progress/progress.json +3 -0
  367. package/dist/templates/ascfDemos/page/component/pages/radio/radio.css +13 -0
  368. package/dist/templates/ascfDemos/page/component/pages/radio/radio.hxml +8 -0
  369. package/dist/templates/ascfDemos/page/component/pages/radio/radio.js +29 -0
  370. package/dist/templates/ascfDemos/page/component/pages/radio/radio.json +3 -0
  371. package/dist/templates/ascfDemos/page/component/pages/rich-text/rich-text.css +16 -0
  372. package/dist/templates/ascfDemos/page/component/pages/rich-text/rich-text.hxml +9 -0
  373. package/dist/templates/ascfDemos/page/component/pages/rich-text/rich-text.js +35 -0
  374. package/dist/templates/ascfDemos/page/component/pages/rich-text/rich-text.json +3 -0
  375. package/dist/templates/ascfDemos/page/component/pages/scroll-view/scroll-view.css +70 -0
  376. package/dist/templates/ascfDemos/page/component/pages/scroll-view/scroll-view.hxml +21 -0
  377. package/dist/templates/ascfDemos/page/component/pages/scroll-view/scroll-view.js +5 -0
  378. package/dist/templates/ascfDemos/page/component/pages/scroll-view/scroll-view.json +3 -0
  379. package/dist/templates/ascfDemos/page/component/pages/slider/slider.css +0 -0
  380. package/dist/templates/ascfDemos/page/component/pages/slider/slider.hxml +6 -0
  381. package/dist/templates/ascfDemos/page/component/pages/slider/slider.js +1 -0
  382. package/dist/templates/ascfDemos/page/component/pages/slider/slider.json +3 -0
  383. package/dist/templates/ascfDemos/page/component/pages/swiper/swiper.css +71 -0
  384. package/dist/templates/ascfDemos/page/component/pages/swiper/swiper.hxml +21 -0
  385. package/dist/templates/ascfDemos/page/component/pages/swiper/swiper.js +29 -0
  386. package/dist/templates/ascfDemos/page/component/pages/swiper/swiper.json +3 -0
  387. package/dist/templates/ascfDemos/page/component/pages/switch/switch.css +13 -0
  388. package/dist/templates/ascfDemos/page/component/pages/switch/switch.hxml +10 -0
  389. package/dist/templates/ascfDemos/page/component/pages/switch/switch.js +20 -0
  390. package/dist/templates/ascfDemos/page/component/pages/switch/switch.json +3 -0
  391. package/dist/templates/ascfDemos/page/component/pages/text/text.css +14 -0
  392. package/dist/templates/ascfDemos/page/component/pages/text/text.hxml +9 -0
  393. package/dist/templates/ascfDemos/page/component/pages/text/text.js +37 -0
  394. package/dist/templates/ascfDemos/page/component/pages/text/text.json +3 -0
  395. package/dist/templates/ascfDemos/page/component/pages/textarea/textarea.css +0 -0
  396. package/dist/templates/ascfDemos/page/component/pages/textarea/textarea.hxml +6 -0
  397. package/dist/templates/ascfDemos/page/component/pages/textarea/textarea.js +1 -0
  398. package/dist/templates/ascfDemos/page/component/pages/textarea/textarea.json +3 -0
  399. package/dist/templates/ascfDemos/page/component/pages/video/video.css +19 -0
  400. package/dist/templates/ascfDemos/page/component/pages/video/video.hxml +7 -0
  401. package/dist/templates/ascfDemos/page/component/pages/video/video.js +26 -0
  402. package/dist/templates/ascfDemos/page/component/pages/video/video.json +3 -0
  403. package/dist/templates/ascfDemos/page/component/pages/view/view.css +89 -0
  404. package/dist/templates/ascfDemos/page/component/pages/view/view.hxml +14 -0
  405. package/dist/templates/ascfDemos/page/component/pages/view/view.js +3 -0
  406. package/dist/templates/ascfDemos/page/component/pages/view/view.json +3 -0
  407. package/dist/templates/ascfDemos/page/component/pages/web-view/web-view.css +0 -0
  408. package/dist/templates/ascfDemos/page/component/pages/web-view/web-view.hxml +2 -0
  409. package/dist/templates/ascfDemos/page/component/pages/web-view/web-view.js +1 -0
  410. package/dist/templates/ascfDemos/page/component/pages/web-view/web-view.json +3 -0
  411. package/dist/templates/ascfDemos/page/framework/index.css +11 -0
  412. package/dist/templates/ascfDemos/page/framework/index.hxml +7 -0
  413. package/dist/templates/ascfDemos/page/framework/index.js +10 -0
  414. package/dist/templates/ascfDemos/page/framework/index.json +7 -0
  415. package/dist/templates/ascfDemos/page/open/index.css +11 -0
  416. package/dist/templates/ascfDemos/page/open/index.hxml +7 -0
  417. package/dist/templates/ascfDemos/page/open/index.js +14 -0
  418. package/dist/templates/ascfDemos/page/open/index.json +7 -0
  419. package/dist/templates/ascfDemos/page/open/pages/authorize/authorize.css +0 -0
  420. package/dist/templates/ascfDemos/page/open/pages/authorize/authorize.hxml +3 -0
  421. package/dist/templates/ascfDemos/page/open/pages/authorize/authorize.js +18 -0
  422. package/dist/templates/ascfDemos/page/open/pages/authorize/authorize.json +3 -0
  423. package/dist/templates/ascfDemos/page/open/pages/choose-address/choose-address.css +12 -0
  424. package/dist/templates/ascfDemos/page/open/pages/choose-address/choose-address.hxml +61 -0
  425. package/dist/templates/ascfDemos/page/open/pages/choose-address/choose-address.js +20 -0
  426. package/dist/templates/ascfDemos/page/open/pages/choose-address/choose-address.json +3 -0
  427. package/dist/templates/ascfDemos/page/open/pages/choose-invoice-title/choose-invoice-title.css +11 -0
  428. package/dist/templates/ascfDemos/page/open/pages/choose-invoice-title/choose-invoice-title.hxml +77 -0
  429. package/dist/templates/ascfDemos/page/open/pages/choose-invoice-title/choose-invoice-title.js +27 -0
  430. package/dist/templates/ascfDemos/page/open/pages/choose-invoice-title/choose-invoice-title.json +3 -0
  431. package/dist/templates/ascfDemos/page/open/pages/getPhoneNumber/getPhoneNumber.css +25 -0
  432. package/dist/templates/ascfDemos/page/open/pages/getPhoneNumber/getPhoneNumber.hxml +4 -0
  433. package/dist/templates/ascfDemos/page/open/pages/getPhoneNumber/getPhoneNumber.js +12 -0
  434. package/dist/templates/ascfDemos/page/open/pages/getPhoneNumber/getPhoneNumber.json +3 -0
  435. package/dist/templates/ascfDemos/page/open/pages/login/login.css +13 -0
  436. package/dist/templates/ascfDemos/page/open/pages/login/login.hxml +5 -0
  437. package/dist/templates/ascfDemos/page/open/pages/login/login.js +20 -0
  438. package/dist/templates/ascfDemos/page/open/pages/login/login.json +3 -0
  439. package/dist/templates/ascfDemos/page/open/pages/message/message.css +0 -0
  440. package/dist/templates/ascfDemos/page/open/pages/message/message.hxml +3 -0
  441. package/dist/templates/ascfDemos/page/open/pages/message/message.js +63 -0
  442. package/dist/templates/ascfDemos/page/open/pages/message/message.json +3 -0
  443. package/dist/templates/ascfDemos/page/open/pages/openSetting/openSetting.css +0 -0
  444. package/dist/templates/ascfDemos/page/open/pages/openSetting/openSetting.hxml +3 -0
  445. package/dist/templates/ascfDemos/page/open/pages/openSetting/openSetting.js +5 -0
  446. package/dist/templates/ascfDemos/page/open/pages/openSetting/openSetting.json +3 -0
  447. package/dist/templates/ascfDemos/video/tempVideo.mp4 +0 -0
  448. package/dist/templates/ascfDemosQs/app.json +129 -0
  449. package/dist/templates/ascfDemosQs/app_icon.png +0 -0
  450. package/dist/templates/ascfProject/AppScope/app.json5 +11 -0
  451. package/dist/templates/ascfProject/AppScope/resources/base/element/string.json +8 -0
  452. package/dist/templates/ascfProject/AppScope/resources/base/media/app_icon.png +0 -0
  453. package/dist/templates/ascfProject/build-profile.json5 +42 -0
  454. package/dist/templates/ascfProject/code-linter.json5 +20 -0
  455. package/dist/templates/ascfProject/entry/build-profile.json5 +28 -0
  456. package/dist/templates/ascfProject/entry/hvigorfile.ts +6 -0
  457. package/dist/templates/ascfProject/entry/obfuscation-rules.txt +23 -0
  458. package/dist/templates/ascfProject/entry/oh-package.json5 +11 -0
  459. package/dist/templates/ascfProject/entry/src/main/ets/abilitystage/AbilityStage.ets +7 -0
  460. package/dist/templates/ascfProject/entry/src/main/ets/entryability/EntryAbility.ets +4 -0
  461. package/dist/templates/ascfProject/entry/src/main/ets/pages/Index.ets +10 -0
  462. package/dist/templates/ascfProject/entry/src/main/module.json5 +65 -0
  463. package/dist/templates/ascfProject/entry/src/main/resources/base/element/color.json +8 -0
  464. package/dist/templates/ascfProject/entry/src/main/resources/base/element/string.json +16 -0
  465. package/dist/templates/ascfProject/entry/src/main/resources/base/media/startIcon.png +0 -0
  466. package/dist/templates/ascfProject/entry/src/main/resources/base/profile/main_pages.json +5 -0
  467. package/dist/templates/ascfProject/entry/src/main/resources/en_US/element/string.json +16 -0
  468. package/dist/templates/ascfProject/entry/src/main/resources/zh_CN/element/string.json +16 -0
  469. package/dist/templates/ascfProject/entry/src/mock/mock-config.json5 +2 -0
  470. package/dist/templates/ascfProject/entry/src/ohosTest/ets/test/Ability.test.ets +35 -0
  471. package/dist/templates/ascfProject/entry/src/ohosTest/ets/test/List.test.ets +5 -0
  472. package/dist/templates/ascfProject/entry/src/ohosTest/module.json5 +12 -0
  473. package/dist/templates/ascfProject/entry/src/test/List.test.ets +5 -0
  474. package/dist/templates/ascfProject/entry/src/test/LocalUnit.test.ets +33 -0
  475. package/dist/templates/ascfProject/gitignore +12 -0
  476. package/dist/templates/ascfProject/hvigor/hvigor-config.json5 +23 -0
  477. package/dist/templates/ascfProject/hvigorfile.ts +10 -0
  478. package/dist/templates/ascfProject/oh-package.json5 +9 -0
  479. package/dist/templates/ascfSrcHello/app.js +14 -0
  480. package/dist/templates/ascfSrcHello/app.json +5 -0
  481. package/dist/templates/ascfSrcHelloQs/app.json +11 -0
  482. package/dist/templates/ascfSrcHelloQs/app_icon.png +0 -0
  483. package/dist/templates/newComponent/comp.css +6 -0
  484. package/dist/templates/newComponent/comp.hxml +3 -0
  485. package/dist/templates/newComponent/comp.js +15 -0
  486. package/dist/templates/newComponent/comp.json +4 -0
  487. package/dist/templates/newPage/page.css +18 -0
  488. package/dist/templates/newPage/page.hxml +3 -0
  489. package/dist/templates/newPage/page.js +5 -0
  490. package/dist/templates/newPage/page.json +4 -0
  491. package/dist/templates/newServiceWidget/EntryCard/entry/base/snapshot/HelloWidget-1x2.png +0 -0
  492. package/dist/templates/newServiceWidget/EntryCard/entry/base/snapshot/HelloWidget-2x2.png +0 -0
  493. package/dist/templates/newServiceWidget/EntryCard/entry/base/snapshot/HelloWidget-2x4.png +0 -0
  494. package/dist/templates/newServiceWidget/EntryCard/entry/base/snapshot/HelloWidget-4x4.png +0 -0
  495. package/dist/templates/newServiceWidget/EntryCard/entry/base/snapshot/HelloWidget-6x4.png +0 -0
  496. package/dist/templates/newServiceWidget/entry/src/main/ets/entryformability/EntryFormAbility.ets +32 -0
  497. package/dist/templates/newServiceWidget/entry/src/main/ets/hellowidget/pages/HelloWidgetCard.ets +21 -0
  498. package/dist/templates/newServiceWidget/entry/src/main/module.json5 +19 -0
  499. package/dist/templates/newServiceWidget/entry/src/main/resources/base/element/string.json +20 -0
  500. package/dist/templates/newServiceWidget/entry/src/main/resources/base/profile/form_config.json +23 -0
  501. package/package.json +9 -4
package/dist/index.d.mts CHANGED
@@ -22,29 +22,27 @@ declare class Logger {
22
22
  }
23
23
  declare function getLogger(categories: any): Logger;
24
24
 
25
- declare const qsHostPkg = "com.enjoy.now.hmos";
26
- declare const LEGACY_PKG_NAME = "com.huawei.fastapp.dev/com.huawei.ascf.main.AscfActivity";
25
+ declare const FASTAPP_LOADER_PKG_NAME = "com.huawei.fastapp.dev";
27
26
  declare const LEGACY_DEVICE = "legacy";
28
27
  declare const HOS_DEVICE = "hos";
29
28
  declare const DEBUG_TYPE_VIEW = "view";
30
29
  declare const DEBUG_TYPE_SERVICE = "service";
31
- declare const BUILD_TARGET_QS = "quickapp";
32
- declare const BUILD_TARGET_AS = "atomicservice";
30
+ declare const HARMONY_OS = "HarmonyOS";
31
+ declare const HDC_CONNECTOR = "hdc";
32
+ declare const ADB_CONNECTOR = "adb";
33
+ declare const V8_PORT = "9229";
33
34
 
34
35
  type BuildModeType = 'debug' | 'release';
35
- type BuildTargetType = typeof BUILD_TARGET_AS | typeof BUILD_TARGET_QS;
36
36
  type BuildDeviceType = typeof HOS_DEVICE | typeof LEGACY_DEVICE;
37
37
  type BuilderOptions = {
38
38
  projectRoot?: string;
39
39
  deviceId?: string;
40
40
  buildMode?: BuildModeType;
41
- targets?: BuildTargetType;
42
41
  deviceType?: BuildDeviceType;
43
42
  subCmd: string;
44
43
  };
45
44
  type DebuggerOptions = {
46
45
  open?: '' | 'default' | 'chrome' | 'edge';
47
- targets?: BuildTargetType;
48
46
  deviceType?: BuildDeviceType;
49
47
  deviceId?: string;
50
48
  bundleName?: string;
@@ -53,13 +51,11 @@ interface IInstallSpkShared {
53
51
  logger: any;
54
52
  projectRoot: any;
55
53
  deviceId: any;
56
- getSpkInfo: any;
57
- buildMode: any;
58
- startServer: any;
59
- tryAdbPortReversing: any;
60
- startHostPkgUrl: any;
61
- rportRmCmd: any;
62
- legacyPkg?: string;
54
+ }
55
+ interface IImageData {
56
+ data: Uint8ClampedArray;
57
+ width: number;
58
+ height: number;
63
59
  }
64
60
 
65
61
  declare function getDebugees(localPort: string | number): Promise<never[]>;
@@ -77,8 +73,9 @@ declare abstract class DebuggerProcess {
77
73
  abstract stopService(): any;
78
74
  abstract checkAndGetBundleName(): Promise<string | boolean | undefined>;
79
75
  openBrowser(type: any, localPort: any, fallback?: string): Promise<void>;
80
- startDebugServer(url: any): Promise<void>;
76
+ startDebugServer(url: String, v8WsUrl: string): Promise<void>;
81
77
  stopDebugServer(): void;
78
+ reversePort(port: number): Promise<boolean>;
82
79
  }
83
80
 
84
81
  declare class AscfDebugger extends DebuggerProcess {
@@ -114,8 +111,6 @@ declare abstract class BuildProcess {
114
111
  installDeps(): Promise<void>;
115
112
  prepareAssemble(projectRoot: string, args?: string[]): Promise<void>;
116
113
  abstract start(): void;
117
- abstract assembleHap(): void;
118
- abstract assembleApp(): void;
119
114
  abstract installHap(): void;
120
115
  abstract assembleAndInstallHap(): void;
121
116
  abstract uninstall(): void;
@@ -126,14 +121,14 @@ declare abstract class BuildProcess {
126
121
  init(): void;
127
122
  runCmdAsync(cmd: any, args?: string[], options?: any): Promise<any>;
128
123
  clean(): Promise<void>;
124
+ assembleHap(): Promise<void>;
125
+ assembleApp(): Promise<void>;
129
126
  }
130
127
 
131
128
  declare class AscfBuilder extends BuildProcess {
132
129
  constructor(options: BuilderOptions);
133
130
  runHdcCmdAsync(args?: string[], options?: any): Promise<any>;
134
131
  start(): Promise<void>;
135
- assembleHap(): Promise<void>;
136
- assembleApp(): Promise<void>;
137
132
  usingTmpDir(deviceId: any, cb: any): Promise<void>;
138
133
  installHap(): Promise<void>;
139
134
  assembleAndInstallHap(): Promise<void>;
@@ -147,6 +142,11 @@ declare function isMpProject(path: any): boolean;
147
142
 
148
143
  declare const IS_WIN32: boolean;
149
144
  declare const IS_MACOS: boolean;
145
+ declare const IS_OPENHARMONY: boolean;
146
+ declare const TOOLS_DIR_OSX = "/Applications/DevEco-Studio.app/Contents/tools";
147
+ declare const TOOLS_DIR_WIN = "C:\\Program Files\\Huawei\\DevEco Studio\\tools";
148
+ declare const TOOLS_DIR_OPENHARMONY = "/data/app";
149
+ declare const DEFAULT_TOOLS_DIR: string;
150
150
  declare function getDevEcoToolsDir(): string;
151
151
  declare function getPath(...args: any[]): string;
152
152
  declare function getNodePath(): string;
@@ -156,6 +156,7 @@ declare function getHvigorwPath(): string;
156
156
  declare function getDevEcoSdkHome(): string;
157
157
  declare function getHdcPath(): string;
158
158
  declare function getNodeBinPath(): string;
159
+ declare function getNodeDirPath(): string;
159
160
  declare function getJavaBinPath(): string;
160
161
 
161
162
  declare class AsyncResult<T> {
@@ -196,7 +197,7 @@ declare function ascfCompile(projectRoot: any, options?: any, onCp?: any): Promi
196
197
  declare function ascfConvert(input: any, projectRoot: any, options?: any): Promise<void>;
197
198
  declare function ascfGenCert(projectRoot: any, options: any): Promise<void>;
198
199
  declare function ascfGenP12(projectRoot: any, options: any): Promise<void>;
199
- declare function startDebugServerCmd(projectRoot: any, opts: any): Promise<unknown>;
200
+ declare function startDebugServerCmd(projectRoot: any, opts: any, progressObj: any): Promise<unknown>;
200
201
  declare function stopDebugServer(): void;
201
202
  declare function getDebugServerInfo(localPort: string | number, path: string): Promise<any>;
202
203
  declare function getAscfDebuggerPidFile(pid: any): string | undefined;
@@ -209,6 +210,41 @@ declare function parseJsonSafe<T>(jsonStr: any, def: T): T;
209
210
  declare function parseJsonFile<T>(filepath: any, def: T): T;
210
211
  declare function mergeJson(oldJson: any, newJson: any): any;
211
212
 
213
+ declare const FAIL = "FAIL";
214
+ declare class AtomicServiceAppIconChecker {
215
+ private iconImgData;
216
+ private templateIconImgData;
217
+ private width;
218
+ private height;
219
+ constructor(iconImageData: IImageData, templateIconImageData: IImageData);
220
+ static imageDataInit(iconUrl: string): Promise<{
221
+ iconImageData: IImageData;
222
+ templateIconImageData: IImageData;
223
+ }>;
224
+ private static loadImageToCanvas;
225
+ bgraToHsv(bgraData: Uint8ClampedArray): Uint8Array;
226
+ inRange(hsvData: Uint8ClampedArray): Uint8Array;
227
+ argwhere(mask: Uint8Array): number[][];
228
+ extractNonTransparentHSB(hsvData: Uint8Array, coordinates: number[][]): any;
229
+ hsvToHsb(h: number, s: number, v: number): [number, number, number];
230
+ isColorInBlackOrWhite(h: number, s: number, b: number): string | null;
231
+ isCompare(): string;
232
+ /**
233
+ * 计算图片的锯齿度百分比
234
+ * @returns 锯齿度百分比
235
+ */
236
+ calculateJaggednessByImageData(): number;
237
+ checkImgSize(): "FAIL: The atomic-service icon size does not meet the requirements(512px*512px)." | "The atomic-service icon size meets the requirements(512px*512px).";
238
+ /**
239
+ * 统计两张图中相同像素位置一个不透明而另一个透明的像素数量
240
+ * @returns 差异透明像素的数量
241
+ */
242
+ compareTransparency(): number;
243
+ isFeatures(): "FAIL: The outer circle line of the atomic-service icon does not comply with the specifications, or the center circle of the icon is incomplete and independent." | "The outer line of the atomic-service icon meets the specification requirements.";
244
+ isSharpness(): "FAIL: The atomic-service icon is not clear." | "The atomic-service icon is clear.";
245
+ check(): Promise<string[]>;
246
+ }
247
+
212
248
  /**
213
249
  * 获取ADB工具的路径。
214
250
  * 根据不同的操作系统平台(Windows, macOS, Linux),返回对应的ADB可执行文件路径。
@@ -219,9 +255,8 @@ declare function getAdbPath(): Promise<string>;
219
255
  declare function runAdbCmdAsync(args?: string[], options?: any): Promise<any>;
220
256
  declare const listTargets: () => Promise<any>;
221
257
  declare const getDeviceName: (deviceId: string) => Promise<string>;
222
- declare const tryAdbPortReversing: (deviceId: any, localPort: any, times?: number) => Promise<number | undefined>;
258
+ declare const tryAdbPortReversing: (deviceId: any, localPort: any, times?: number) => Promise<number>;
223
259
  declare const startHostPkg: (deviceId: string, bundleName: string) => Promise<string>;
224
- declare const startHostPkgUrl: (deviceId: string, bundleName: string, reqUrl: string, legacyPkg: string) => Promise<string>;
225
260
  declare const fportListCmd: (deviceId: string) => Promise<string>;
226
261
  declare const fportRmCmd: (deviceId: string, localnode: string) => Promise<string>;
227
262
  declare const fportCmd: (deviceId: string, localnode: string, remotenode: string) => Promise<string>;
@@ -229,16 +264,59 @@ declare const rportCmd: (deviceId: string, localnode: string, remotenode: string
229
264
  declare const rportRmCmd: (deviceId: string, devicenode: string) => Promise<string>;
230
265
  declare const getDevicesCmd: () => Promise<string>;
231
266
  declare const getLegacyDeviceName: (deviceId: any) => Promise<string>;
232
- declare const getLegacyProcess: (deviceId: any, bundleName: any) => Promise<string>;
267
+ declare const getLegacyProcess: (deviceId: any, hostPkg: any) => Promise<string>;
268
+ declare const getLegacyHosVersion: (deviceId: any) => Promise<string>;
233
269
  /**
234
270
  * 查找包安装信息
235
271
  *
236
272
  * @param deviceId 设备id
237
273
  * @param bundleName 包名
238
274
  */
239
- declare function getLegacyPackInfo(deviceId: any, bundleName: any): Promise<string>;
275
+ declare function getLegacyPackInfo(deviceId: any): Promise<string>;
240
276
  declare function getPid(deviceId: string, bundleName: string): Promise<string>;
241
277
 
278
+ type TemplateEngineOptions = {
279
+ force?: boolean;
280
+ dryRun?: boolean;
281
+ ejsOptions?: any;
282
+ webview?: any;
283
+ };
284
+ type TemplateContext = {
285
+ rootOut: string;
286
+ data: any;
287
+ };
288
+ type TemplateFile = {
289
+ type: 'template' | 'file' | 'modify' | 'delete' | 'copy' | 'rename';
290
+ tpl: string;
291
+ excludes?: string[];
292
+ path: string;
293
+ force?: boolean;
294
+ onModify?: (old: any, data?: any) => boolean;
295
+ };
296
+ type TemplateInfo = {
297
+ templateDir: string;
298
+ files: TemplateFile[];
299
+ };
300
+ declare class TemplateEngine {
301
+ private options;
302
+ constructor(options: TemplateEngineOptions);
303
+ mkdirSync(path: any): void;
304
+ copyFileSync(src: any, dest: any): void;
305
+ copyDirSync(src: any, dest: any, filter?: (sourceFullPath: string, destination: string) => boolean): void;
306
+ writeFileSync(filepath: any, content: any, encoding: any, force?: boolean): void;
307
+ fileRename(filePath: any): any;
308
+ generateByTemplateFile(templateInfo: TemplateInfo, ctx: TemplateContext, tplFile: TemplateFile): Promise<void>;
309
+ generate(templateInfo: TemplateInfo, ctx: TemplateContext): Promise<void[]>;
310
+ }
311
+ declare function createAscfProject(templatesDir: string, ctx: TemplateContext, options?: TemplateEngineOptions): Promise<void>;
312
+ declare function createAscfPage(templatesDir: string, ctx: TemplateContext, options?: TemplateEngineOptions): Promise<void[]>;
313
+ declare function createAscfComponent(templatesDir: string, ctx: TemplateContext, options?: TemplateEngineOptions): Promise<void[]>;
314
+ declare function createServiceWidget(templatesDir: string, ctx: TemplateContext, options?: TemplateEngineOptions): Promise<void[]>;
315
+
316
+ declare function fetchJson(url: string, options: any): Promise<any>;
317
+ declare function fetchHttpsJson(url: string, options: any): Promise<any>;
318
+ declare function downloadApk(url: string, outputDir: string, vscodeProgress: any, options: any): Promise<string>;
319
+
242
320
  declare function installAscfTools(): Promise<string>;
243
321
 
244
322
  /**
@@ -261,12 +339,13 @@ declare function hdcShared({ logger, getDevEcoSdkHome, getPath, getHdcPath }: {
261
339
  getPath: any;
262
340
  getHdcPath: any;
263
341
  }): {
264
- runCmd: (cmd: any, args?: string[], cb?: any, options?: any, onCp?: any) => child_process.ChildProcessWithoutNullStreams;
342
+ runCmd: (cmd: any, args?: string[], cb?: any, options?: any, onCp?: any, progressObj?: any) => child_process.ChildProcessWithoutNullStreams;
265
343
  runCmdAsync: (cmd: any, args?: string[], options?: any, onCp?: any) => Promise<any>;
266
344
  runExecAsync: (cmd: any, args?: string[], options?: any) => Promise<any>;
267
345
  runHdcCmd: (args?: string[], cb?: any, options?: any) => child_process.ChildProcessWithoutNullStreams;
268
346
  runHdcCmdAsync: (args?: string[], options?: any) => Promise<any>;
269
347
  getDeviceName: (deviceId: string) => Promise<string>;
348
+ getHosVersion: (deviceId: string) => Promise<string>;
270
349
  };
271
350
  type deviceType = typeof LEGACY_DEVICE | typeof HOS_DEVICE;
272
351
  declare class DeviceInfo {
@@ -310,7 +389,7 @@ declare class BuildProcessFactory {
310
389
  static create(options: BuilderOptions): Promise<BuildProcess>;
311
390
  }
312
391
  declare class DebuggerProcessFactory {
313
- static create(options: BuilderOptions): Promise<DebuggerProcess>;
392
+ static create(options: DebuggerOptions): Promise<DebuggerProcess>;
314
393
  }
315
394
 
316
395
  declare function devicesLegacyShared({ logger, runAdbCmdAsync }: {
@@ -319,9 +398,8 @@ declare function devicesLegacyShared({ logger, runAdbCmdAsync }: {
319
398
  }): {
320
399
  listTargets: () => Promise<any>;
321
400
  getDeviceName: (deviceId: string) => Promise<string>;
322
- tryAdbPortReversing: (deviceId: any, localPort: any, times?: number) => Promise<number | undefined>;
401
+ tryAdbPortReversing: (deviceId: any, localPort: any, times?: number) => Promise<number>;
323
402
  startHostPkg: (deviceId: string, bundleName: string) => Promise<string>;
324
- startHostPkgUrl: (deviceId: string, bundleName: string, reqUrl: string, legacyPkg: string) => Promise<string>;
325
403
  fportListCmd: (deviceId: string) => Promise<string>;
326
404
  fportRmCmd: (deviceId: string, localnode: string) => Promise<string>;
327
405
  fportCmd: (deviceId: string, localnode: string, remotenode: string) => Promise<string>;
@@ -329,7 +407,8 @@ declare function devicesLegacyShared({ logger, runAdbCmdAsync }: {
329
407
  rportRmCmd: (deviceId: string, devicenode: string) => Promise<string>;
330
408
  getDevicesCmd: () => Promise<string>;
331
409
  getLegacyDeviceName: (deviceId: any) => Promise<string>;
332
- getLegacyProcess: (deviceId: any, bundleName: any) => Promise<string>;
410
+ getLegacyProcess: (deviceId: any, hostPkg: any) => Promise<string>;
411
+ getLegacyHosVersion: (deviceId: any) => Promise<string>;
333
412
  };
334
413
 
335
414
  declare const ERROR_MSG: string;
@@ -341,6 +420,15 @@ declare function portManagerShared({ logger, fportListCmd, fportRmCmd, isPortRea
341
420
 
342
421
  declare function tryHdcPortReversing(deviceId: any, localPort: any, times?: number): Promise<number | undefined>;
343
422
 
344
- declare function installSpkShared({ logger, projectRoot, deviceId, getSpkInfo, buildMode, startServer, tryAdbPortReversing, startHostPkgUrl, rportRmCmd, legacyPkg }: IInstallSpkShared): Promise<void>;
423
+ declare function installSpkShared({ logger, projectRoot, deviceId }: IInstallSpkShared): Promise<void>;
424
+
425
+ declare class DebugPort {
426
+ port: number;
427
+ private static instance;
428
+ private constructor();
429
+ static getInstance(): DebugPort;
430
+ getPort(): number;
431
+ }
432
+ declare const debugPort: DebugPort;
345
433
 
346
- export { $async, ASCF_LOG_FILE, AscfBuilder, AscfDebugger, AsyncResult, BUILD_MODE_DEBUG, BUILD_MODE_RELEASE, BUILD_TARGET_AS, BUILD_TARGET_QS, BuildProcessFactory, DEBUG_TYPE_SERVICE, DEBUG_TYPE_VIEW, DebuggerProcessFactory, ERROR_MSG, HOS_DEVICE, IS_MACOS, IS_WIN32, LEGACY_DEVICE, LEGACY_PKG_NAME, ascfCompile, ascfConvert, ascfGenCert, ascfGenP12, ascfRun, clearAscfDepDirCache, configureLogger, copyDirectory, type deviceType, devicesLegacyShared, execSafe, findAvailablePort, fixHvigorPath, fportCmd, fportListCmd, fportRmCmd, getAdbPath, getAscfDebuggerPidFile, getAscfDepDir, getBuildProfile, getBundleInfo, getCmdAndArgs, getDebugServerInfo, getDebugees, getDevEcoSdkHome, getDevEcoToolsDir, getDeviceName, getDevicesCmd, getHdcPath, getHvigorwPath, getJavaBinPath, getLegacyDeviceName, getLegacyPackInfo, getLegacyProcess, getLogLevelGetter, getLogger, getNodeBinPath, getNodePath, getNpmPath, getOhpmPath, getPath, getPid, getProjectConfig, getSpkInfo, hasHvigor, hdcDeviceShared, hdcShared, installAscfTools, installSpkShared, isAscfProject, isDirectoryExists, isMpProject, isPortReachable, listTargets, maskLast4, mergeJson, normalizeBuildMode, openInBrowser, optArgIf, parseJsonFile, parseJsonSafe, portManagerShared, qsHostPkg, rportCmd, rportRmCmd, runAdbCmdAsync, setLogLevelGetter, setLoggerConfig, startDebugServerCmd, startHostPkg, startHostPkgUrl, startServer, stopDebugServer, tryAdbPortReversing, tryHdcPortReversing };
434
+ export { $async, ADB_CONNECTOR, ASCF_LOG_FILE, AscfBuilder, AscfDebugger, AsyncResult, AtomicServiceAppIconChecker, BUILD_MODE_DEBUG, BUILD_MODE_RELEASE, BuildProcessFactory, DEBUG_TYPE_SERVICE, DEBUG_TYPE_VIEW, DEFAULT_TOOLS_DIR, DebuggerProcessFactory, ERROR_MSG, FAIL, FASTAPP_LOADER_PKG_NAME, HARMONY_OS, HDC_CONNECTOR, HOS_DEVICE, IS_MACOS, IS_OPENHARMONY, IS_WIN32, LEGACY_DEVICE, TOOLS_DIR_OPENHARMONY, TOOLS_DIR_OSX, TOOLS_DIR_WIN, type TemplateContext, TemplateEngine, type TemplateEngineOptions, type TemplateFile, type TemplateInfo, V8_PORT, ascfCompile, ascfConvert, ascfGenCert, ascfGenP12, ascfRun, clearAscfDepDirCache, configureLogger, copyDirectory, createAscfComponent, createAscfPage, createAscfProject, createServiceWidget, debugPort, type deviceType, devicesLegacyShared, downloadApk, execSafe, fetchHttpsJson, fetchJson, findAvailablePort, fixHvigorPath, fportCmd, fportListCmd, fportRmCmd, getAdbPath, getAscfDebuggerPidFile, getAscfDepDir, getBuildProfile, getBundleInfo, getCmdAndArgs, getDebugServerInfo, getDebugees, getDevEcoSdkHome, getDevEcoToolsDir, getDeviceName, getDevicesCmd, getHdcPath, getHvigorwPath, getJavaBinPath, getLegacyDeviceName, getLegacyHosVersion, getLegacyPackInfo, getLegacyProcess, getLogLevelGetter, getLogger, getNodeBinPath, getNodeDirPath, getNodePath, getNpmPath, getOhpmPath, getPath, getPid, getProjectConfig, getSpkInfo, hasHvigor, hdcDeviceShared, hdcShared, installAscfTools, installSpkShared, isAscfProject, isDirectoryExists, isMpProject, isPortReachable, listTargets, maskLast4, mergeJson, normalizeBuildMode, openInBrowser, optArgIf, parseJsonFile, parseJsonSafe, portManagerShared, rportCmd, rportRmCmd, runAdbCmdAsync, setLogLevelGetter, setLoggerConfig, startDebugServerCmd, startHostPkg, startServer, stopDebugServer, tryAdbPortReversing, tryHdcPortReversing };
package/dist/index.d.ts CHANGED
@@ -22,29 +22,27 @@ declare class Logger {
22
22
  }
23
23
  declare function getLogger(categories: any): Logger;
24
24
 
25
- declare const qsHostPkg = "com.enjoy.now.hmos";
26
- declare const LEGACY_PKG_NAME = "com.huawei.fastapp.dev/com.huawei.ascf.main.AscfActivity";
25
+ declare const FASTAPP_LOADER_PKG_NAME = "com.huawei.fastapp.dev";
27
26
  declare const LEGACY_DEVICE = "legacy";
28
27
  declare const HOS_DEVICE = "hos";
29
28
  declare const DEBUG_TYPE_VIEW = "view";
30
29
  declare const DEBUG_TYPE_SERVICE = "service";
31
- declare const BUILD_TARGET_QS = "quickapp";
32
- declare const BUILD_TARGET_AS = "atomicservice";
30
+ declare const HARMONY_OS = "HarmonyOS";
31
+ declare const HDC_CONNECTOR = "hdc";
32
+ declare const ADB_CONNECTOR = "adb";
33
+ declare const V8_PORT = "9229";
33
34
 
34
35
  type BuildModeType = 'debug' | 'release';
35
- type BuildTargetType = typeof BUILD_TARGET_AS | typeof BUILD_TARGET_QS;
36
36
  type BuildDeviceType = typeof HOS_DEVICE | typeof LEGACY_DEVICE;
37
37
  type BuilderOptions = {
38
38
  projectRoot?: string;
39
39
  deviceId?: string;
40
40
  buildMode?: BuildModeType;
41
- targets?: BuildTargetType;
42
41
  deviceType?: BuildDeviceType;
43
42
  subCmd: string;
44
43
  };
45
44
  type DebuggerOptions = {
46
45
  open?: '' | 'default' | 'chrome' | 'edge';
47
- targets?: BuildTargetType;
48
46
  deviceType?: BuildDeviceType;
49
47
  deviceId?: string;
50
48
  bundleName?: string;
@@ -53,13 +51,11 @@ interface IInstallSpkShared {
53
51
  logger: any;
54
52
  projectRoot: any;
55
53
  deviceId: any;
56
- getSpkInfo: any;
57
- buildMode: any;
58
- startServer: any;
59
- tryAdbPortReversing: any;
60
- startHostPkgUrl: any;
61
- rportRmCmd: any;
62
- legacyPkg?: string;
54
+ }
55
+ interface IImageData {
56
+ data: Uint8ClampedArray;
57
+ width: number;
58
+ height: number;
63
59
  }
64
60
 
65
61
  declare function getDebugees(localPort: string | number): Promise<never[]>;
@@ -77,8 +73,9 @@ declare abstract class DebuggerProcess {
77
73
  abstract stopService(): any;
78
74
  abstract checkAndGetBundleName(): Promise<string | boolean | undefined>;
79
75
  openBrowser(type: any, localPort: any, fallback?: string): Promise<void>;
80
- startDebugServer(url: any): Promise<void>;
76
+ startDebugServer(url: String, v8WsUrl: string): Promise<void>;
81
77
  stopDebugServer(): void;
78
+ reversePort(port: number): Promise<boolean>;
82
79
  }
83
80
 
84
81
  declare class AscfDebugger extends DebuggerProcess {
@@ -114,8 +111,6 @@ declare abstract class BuildProcess {
114
111
  installDeps(): Promise<void>;
115
112
  prepareAssemble(projectRoot: string, args?: string[]): Promise<void>;
116
113
  abstract start(): void;
117
- abstract assembleHap(): void;
118
- abstract assembleApp(): void;
119
114
  abstract installHap(): void;
120
115
  abstract assembleAndInstallHap(): void;
121
116
  abstract uninstall(): void;
@@ -126,14 +121,14 @@ declare abstract class BuildProcess {
126
121
  init(): void;
127
122
  runCmdAsync(cmd: any, args?: string[], options?: any): Promise<any>;
128
123
  clean(): Promise<void>;
124
+ assembleHap(): Promise<void>;
125
+ assembleApp(): Promise<void>;
129
126
  }
130
127
 
131
128
  declare class AscfBuilder extends BuildProcess {
132
129
  constructor(options: BuilderOptions);
133
130
  runHdcCmdAsync(args?: string[], options?: any): Promise<any>;
134
131
  start(): Promise<void>;
135
- assembleHap(): Promise<void>;
136
- assembleApp(): Promise<void>;
137
132
  usingTmpDir(deviceId: any, cb: any): Promise<void>;
138
133
  installHap(): Promise<void>;
139
134
  assembleAndInstallHap(): Promise<void>;
@@ -147,6 +142,11 @@ declare function isMpProject(path: any): boolean;
147
142
 
148
143
  declare const IS_WIN32: boolean;
149
144
  declare const IS_MACOS: boolean;
145
+ declare const IS_OPENHARMONY: boolean;
146
+ declare const TOOLS_DIR_OSX = "/Applications/DevEco-Studio.app/Contents/tools";
147
+ declare const TOOLS_DIR_WIN = "C:\\Program Files\\Huawei\\DevEco Studio\\tools";
148
+ declare const TOOLS_DIR_OPENHARMONY = "/data/app";
149
+ declare const DEFAULT_TOOLS_DIR: string;
150
150
  declare function getDevEcoToolsDir(): string;
151
151
  declare function getPath(...args: any[]): string;
152
152
  declare function getNodePath(): string;
@@ -156,6 +156,7 @@ declare function getHvigorwPath(): string;
156
156
  declare function getDevEcoSdkHome(): string;
157
157
  declare function getHdcPath(): string;
158
158
  declare function getNodeBinPath(): string;
159
+ declare function getNodeDirPath(): string;
159
160
  declare function getJavaBinPath(): string;
160
161
 
161
162
  declare class AsyncResult<T> {
@@ -196,7 +197,7 @@ declare function ascfCompile(projectRoot: any, options?: any, onCp?: any): Promi
196
197
  declare function ascfConvert(input: any, projectRoot: any, options?: any): Promise<void>;
197
198
  declare function ascfGenCert(projectRoot: any, options: any): Promise<void>;
198
199
  declare function ascfGenP12(projectRoot: any, options: any): Promise<void>;
199
- declare function startDebugServerCmd(projectRoot: any, opts: any): Promise<unknown>;
200
+ declare function startDebugServerCmd(projectRoot: any, opts: any, progressObj: any): Promise<unknown>;
200
201
  declare function stopDebugServer(): void;
201
202
  declare function getDebugServerInfo(localPort: string | number, path: string): Promise<any>;
202
203
  declare function getAscfDebuggerPidFile(pid: any): string | undefined;
@@ -209,6 +210,41 @@ declare function parseJsonSafe<T>(jsonStr: any, def: T): T;
209
210
  declare function parseJsonFile<T>(filepath: any, def: T): T;
210
211
  declare function mergeJson(oldJson: any, newJson: any): any;
211
212
 
213
+ declare const FAIL = "FAIL";
214
+ declare class AtomicServiceAppIconChecker {
215
+ private iconImgData;
216
+ private templateIconImgData;
217
+ private width;
218
+ private height;
219
+ constructor(iconImageData: IImageData, templateIconImageData: IImageData);
220
+ static imageDataInit(iconUrl: string): Promise<{
221
+ iconImageData: IImageData;
222
+ templateIconImageData: IImageData;
223
+ }>;
224
+ private static loadImageToCanvas;
225
+ bgraToHsv(bgraData: Uint8ClampedArray): Uint8Array;
226
+ inRange(hsvData: Uint8ClampedArray): Uint8Array;
227
+ argwhere(mask: Uint8Array): number[][];
228
+ extractNonTransparentHSB(hsvData: Uint8Array, coordinates: number[][]): any;
229
+ hsvToHsb(h: number, s: number, v: number): [number, number, number];
230
+ isColorInBlackOrWhite(h: number, s: number, b: number): string | null;
231
+ isCompare(): string;
232
+ /**
233
+ * 计算图片的锯齿度百分比
234
+ * @returns 锯齿度百分比
235
+ */
236
+ calculateJaggednessByImageData(): number;
237
+ checkImgSize(): "FAIL: The atomic-service icon size does not meet the requirements(512px*512px)." | "The atomic-service icon size meets the requirements(512px*512px).";
238
+ /**
239
+ * 统计两张图中相同像素位置一个不透明而另一个透明的像素数量
240
+ * @returns 差异透明像素的数量
241
+ */
242
+ compareTransparency(): number;
243
+ isFeatures(): "FAIL: The outer circle line of the atomic-service icon does not comply with the specifications, or the center circle of the icon is incomplete and independent." | "The outer line of the atomic-service icon meets the specification requirements.";
244
+ isSharpness(): "FAIL: The atomic-service icon is not clear." | "The atomic-service icon is clear.";
245
+ check(): Promise<string[]>;
246
+ }
247
+
212
248
  /**
213
249
  * 获取ADB工具的路径。
214
250
  * 根据不同的操作系统平台(Windows, macOS, Linux),返回对应的ADB可执行文件路径。
@@ -219,9 +255,8 @@ declare function getAdbPath(): Promise<string>;
219
255
  declare function runAdbCmdAsync(args?: string[], options?: any): Promise<any>;
220
256
  declare const listTargets: () => Promise<any>;
221
257
  declare const getDeviceName: (deviceId: string) => Promise<string>;
222
- declare const tryAdbPortReversing: (deviceId: any, localPort: any, times?: number) => Promise<number | undefined>;
258
+ declare const tryAdbPortReversing: (deviceId: any, localPort: any, times?: number) => Promise<number>;
223
259
  declare const startHostPkg: (deviceId: string, bundleName: string) => Promise<string>;
224
- declare const startHostPkgUrl: (deviceId: string, bundleName: string, reqUrl: string, legacyPkg: string) => Promise<string>;
225
260
  declare const fportListCmd: (deviceId: string) => Promise<string>;
226
261
  declare const fportRmCmd: (deviceId: string, localnode: string) => Promise<string>;
227
262
  declare const fportCmd: (deviceId: string, localnode: string, remotenode: string) => Promise<string>;
@@ -229,16 +264,59 @@ declare const rportCmd: (deviceId: string, localnode: string, remotenode: string
229
264
  declare const rportRmCmd: (deviceId: string, devicenode: string) => Promise<string>;
230
265
  declare const getDevicesCmd: () => Promise<string>;
231
266
  declare const getLegacyDeviceName: (deviceId: any) => Promise<string>;
232
- declare const getLegacyProcess: (deviceId: any, bundleName: any) => Promise<string>;
267
+ declare const getLegacyProcess: (deviceId: any, hostPkg: any) => Promise<string>;
268
+ declare const getLegacyHosVersion: (deviceId: any) => Promise<string>;
233
269
  /**
234
270
  * 查找包安装信息
235
271
  *
236
272
  * @param deviceId 设备id
237
273
  * @param bundleName 包名
238
274
  */
239
- declare function getLegacyPackInfo(deviceId: any, bundleName: any): Promise<string>;
275
+ declare function getLegacyPackInfo(deviceId: any): Promise<string>;
240
276
  declare function getPid(deviceId: string, bundleName: string): Promise<string>;
241
277
 
278
+ type TemplateEngineOptions = {
279
+ force?: boolean;
280
+ dryRun?: boolean;
281
+ ejsOptions?: any;
282
+ webview?: any;
283
+ };
284
+ type TemplateContext = {
285
+ rootOut: string;
286
+ data: any;
287
+ };
288
+ type TemplateFile = {
289
+ type: 'template' | 'file' | 'modify' | 'delete' | 'copy' | 'rename';
290
+ tpl: string;
291
+ excludes?: string[];
292
+ path: string;
293
+ force?: boolean;
294
+ onModify?: (old: any, data?: any) => boolean;
295
+ };
296
+ type TemplateInfo = {
297
+ templateDir: string;
298
+ files: TemplateFile[];
299
+ };
300
+ declare class TemplateEngine {
301
+ private options;
302
+ constructor(options: TemplateEngineOptions);
303
+ mkdirSync(path: any): void;
304
+ copyFileSync(src: any, dest: any): void;
305
+ copyDirSync(src: any, dest: any, filter?: (sourceFullPath: string, destination: string) => boolean): void;
306
+ writeFileSync(filepath: any, content: any, encoding: any, force?: boolean): void;
307
+ fileRename(filePath: any): any;
308
+ generateByTemplateFile(templateInfo: TemplateInfo, ctx: TemplateContext, tplFile: TemplateFile): Promise<void>;
309
+ generate(templateInfo: TemplateInfo, ctx: TemplateContext): Promise<void[]>;
310
+ }
311
+ declare function createAscfProject(templatesDir: string, ctx: TemplateContext, options?: TemplateEngineOptions): Promise<void>;
312
+ declare function createAscfPage(templatesDir: string, ctx: TemplateContext, options?: TemplateEngineOptions): Promise<void[]>;
313
+ declare function createAscfComponent(templatesDir: string, ctx: TemplateContext, options?: TemplateEngineOptions): Promise<void[]>;
314
+ declare function createServiceWidget(templatesDir: string, ctx: TemplateContext, options?: TemplateEngineOptions): Promise<void[]>;
315
+
316
+ declare function fetchJson(url: string, options: any): Promise<any>;
317
+ declare function fetchHttpsJson(url: string, options: any): Promise<any>;
318
+ declare function downloadApk(url: string, outputDir: string, vscodeProgress: any, options: any): Promise<string>;
319
+
242
320
  declare function installAscfTools(): Promise<string>;
243
321
 
244
322
  /**
@@ -261,12 +339,13 @@ declare function hdcShared({ logger, getDevEcoSdkHome, getPath, getHdcPath }: {
261
339
  getPath: any;
262
340
  getHdcPath: any;
263
341
  }): {
264
- runCmd: (cmd: any, args?: string[], cb?: any, options?: any, onCp?: any) => child_process.ChildProcessWithoutNullStreams;
342
+ runCmd: (cmd: any, args?: string[], cb?: any, options?: any, onCp?: any, progressObj?: any) => child_process.ChildProcessWithoutNullStreams;
265
343
  runCmdAsync: (cmd: any, args?: string[], options?: any, onCp?: any) => Promise<any>;
266
344
  runExecAsync: (cmd: any, args?: string[], options?: any) => Promise<any>;
267
345
  runHdcCmd: (args?: string[], cb?: any, options?: any) => child_process.ChildProcessWithoutNullStreams;
268
346
  runHdcCmdAsync: (args?: string[], options?: any) => Promise<any>;
269
347
  getDeviceName: (deviceId: string) => Promise<string>;
348
+ getHosVersion: (deviceId: string) => Promise<string>;
270
349
  };
271
350
  type deviceType = typeof LEGACY_DEVICE | typeof HOS_DEVICE;
272
351
  declare class DeviceInfo {
@@ -310,7 +389,7 @@ declare class BuildProcessFactory {
310
389
  static create(options: BuilderOptions): Promise<BuildProcess>;
311
390
  }
312
391
  declare class DebuggerProcessFactory {
313
- static create(options: BuilderOptions): Promise<DebuggerProcess>;
392
+ static create(options: DebuggerOptions): Promise<DebuggerProcess>;
314
393
  }
315
394
 
316
395
  declare function devicesLegacyShared({ logger, runAdbCmdAsync }: {
@@ -319,9 +398,8 @@ declare function devicesLegacyShared({ logger, runAdbCmdAsync }: {
319
398
  }): {
320
399
  listTargets: () => Promise<any>;
321
400
  getDeviceName: (deviceId: string) => Promise<string>;
322
- tryAdbPortReversing: (deviceId: any, localPort: any, times?: number) => Promise<number | undefined>;
401
+ tryAdbPortReversing: (deviceId: any, localPort: any, times?: number) => Promise<number>;
323
402
  startHostPkg: (deviceId: string, bundleName: string) => Promise<string>;
324
- startHostPkgUrl: (deviceId: string, bundleName: string, reqUrl: string, legacyPkg: string) => Promise<string>;
325
403
  fportListCmd: (deviceId: string) => Promise<string>;
326
404
  fportRmCmd: (deviceId: string, localnode: string) => Promise<string>;
327
405
  fportCmd: (deviceId: string, localnode: string, remotenode: string) => Promise<string>;
@@ -329,7 +407,8 @@ declare function devicesLegacyShared({ logger, runAdbCmdAsync }: {
329
407
  rportRmCmd: (deviceId: string, devicenode: string) => Promise<string>;
330
408
  getDevicesCmd: () => Promise<string>;
331
409
  getLegacyDeviceName: (deviceId: any) => Promise<string>;
332
- getLegacyProcess: (deviceId: any, bundleName: any) => Promise<string>;
410
+ getLegacyProcess: (deviceId: any, hostPkg: any) => Promise<string>;
411
+ getLegacyHosVersion: (deviceId: any) => Promise<string>;
333
412
  };
334
413
 
335
414
  declare const ERROR_MSG: string;
@@ -341,6 +420,15 @@ declare function portManagerShared({ logger, fportListCmd, fportRmCmd, isPortRea
341
420
 
342
421
  declare function tryHdcPortReversing(deviceId: any, localPort: any, times?: number): Promise<number | undefined>;
343
422
 
344
- declare function installSpkShared({ logger, projectRoot, deviceId, getSpkInfo, buildMode, startServer, tryAdbPortReversing, startHostPkgUrl, rportRmCmd, legacyPkg }: IInstallSpkShared): Promise<void>;
423
+ declare function installSpkShared({ logger, projectRoot, deviceId }: IInstallSpkShared): Promise<void>;
424
+
425
+ declare class DebugPort {
426
+ port: number;
427
+ private static instance;
428
+ private constructor();
429
+ static getInstance(): DebugPort;
430
+ getPort(): number;
431
+ }
432
+ declare const debugPort: DebugPort;
345
433
 
346
- export { $async, ASCF_LOG_FILE, AscfBuilder, AscfDebugger, AsyncResult, BUILD_MODE_DEBUG, BUILD_MODE_RELEASE, BUILD_TARGET_AS, BUILD_TARGET_QS, BuildProcessFactory, DEBUG_TYPE_SERVICE, DEBUG_TYPE_VIEW, DebuggerProcessFactory, ERROR_MSG, HOS_DEVICE, IS_MACOS, IS_WIN32, LEGACY_DEVICE, LEGACY_PKG_NAME, ascfCompile, ascfConvert, ascfGenCert, ascfGenP12, ascfRun, clearAscfDepDirCache, configureLogger, copyDirectory, type deviceType, devicesLegacyShared, execSafe, findAvailablePort, fixHvigorPath, fportCmd, fportListCmd, fportRmCmd, getAdbPath, getAscfDebuggerPidFile, getAscfDepDir, getBuildProfile, getBundleInfo, getCmdAndArgs, getDebugServerInfo, getDebugees, getDevEcoSdkHome, getDevEcoToolsDir, getDeviceName, getDevicesCmd, getHdcPath, getHvigorwPath, getJavaBinPath, getLegacyDeviceName, getLegacyPackInfo, getLegacyProcess, getLogLevelGetter, getLogger, getNodeBinPath, getNodePath, getNpmPath, getOhpmPath, getPath, getPid, getProjectConfig, getSpkInfo, hasHvigor, hdcDeviceShared, hdcShared, installAscfTools, installSpkShared, isAscfProject, isDirectoryExists, isMpProject, isPortReachable, listTargets, maskLast4, mergeJson, normalizeBuildMode, openInBrowser, optArgIf, parseJsonFile, parseJsonSafe, portManagerShared, qsHostPkg, rportCmd, rportRmCmd, runAdbCmdAsync, setLogLevelGetter, setLoggerConfig, startDebugServerCmd, startHostPkg, startHostPkgUrl, startServer, stopDebugServer, tryAdbPortReversing, tryHdcPortReversing };
434
+ export { $async, ADB_CONNECTOR, ASCF_LOG_FILE, AscfBuilder, AscfDebugger, AsyncResult, AtomicServiceAppIconChecker, BUILD_MODE_DEBUG, BUILD_MODE_RELEASE, BuildProcessFactory, DEBUG_TYPE_SERVICE, DEBUG_TYPE_VIEW, DEFAULT_TOOLS_DIR, DebuggerProcessFactory, ERROR_MSG, FAIL, FASTAPP_LOADER_PKG_NAME, HARMONY_OS, HDC_CONNECTOR, HOS_DEVICE, IS_MACOS, IS_OPENHARMONY, IS_WIN32, LEGACY_DEVICE, TOOLS_DIR_OPENHARMONY, TOOLS_DIR_OSX, TOOLS_DIR_WIN, type TemplateContext, TemplateEngine, type TemplateEngineOptions, type TemplateFile, type TemplateInfo, V8_PORT, ascfCompile, ascfConvert, ascfGenCert, ascfGenP12, ascfRun, clearAscfDepDirCache, configureLogger, copyDirectory, createAscfComponent, createAscfPage, createAscfProject, createServiceWidget, debugPort, type deviceType, devicesLegacyShared, downloadApk, execSafe, fetchHttpsJson, fetchJson, findAvailablePort, fixHvigorPath, fportCmd, fportListCmd, fportRmCmd, getAdbPath, getAscfDebuggerPidFile, getAscfDepDir, getBuildProfile, getBundleInfo, getCmdAndArgs, getDebugServerInfo, getDebugees, getDevEcoSdkHome, getDevEcoToolsDir, getDeviceName, getDevicesCmd, getHdcPath, getHvigorwPath, getJavaBinPath, getLegacyDeviceName, getLegacyHosVersion, getLegacyPackInfo, getLegacyProcess, getLogLevelGetter, getLogger, getNodeBinPath, getNodeDirPath, getNodePath, getNpmPath, getOhpmPath, getPath, getPid, getProjectConfig, getSpkInfo, hasHvigor, hdcDeviceShared, hdcShared, installAscfTools, installSpkShared, isAscfProject, isDirectoryExists, isMpProject, isPortReachable, listTargets, maskLast4, mergeJson, normalizeBuildMode, openInBrowser, optArgIf, parseJsonFile, parseJsonSafe, portManagerShared, rportCmd, rportRmCmd, runAdbCmdAsync, setLogLevelGetter, setLoggerConfig, startDebugServerCmd, startHostPkg, startServer, stopDebugServer, tryAdbPortReversing, tryHdcPortReversing };