@nativescript/core 9.0.0-alpha.21 → 9.0.0-alpha.22

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 (1027) hide show
  1. package/LICENSE +19 -0
  2. package/abortcontroller/abortsignal.d.ts +23 -0
  3. package/abortcontroller/abortsignal.js +57 -0
  4. package/abortcontroller/abortsignal.js.map +1 -0
  5. package/abortcontroller/index.d.ts +20 -0
  6. package/abortcontroller/index.js +52 -0
  7. package/abortcontroller/index.js.map +1 -0
  8. package/accessibility/accessibility-common.d.ts +282 -0
  9. package/accessibility/accessibility-common.js +416 -0
  10. package/accessibility/accessibility-common.js.map +1 -0
  11. package/accessibility/accessibility-properties.d.ts +24 -0
  12. package/accessibility/accessibility-properties.js +118 -0
  13. package/accessibility/accessibility-properties.js.map +1 -0
  14. package/accessibility/index.d.ts +1 -0
  15. package/accessibility/index.js +2 -0
  16. package/accessibility/index.js.map +1 -0
  17. package/animation-frame/animation-native.android.d.ts +1 -0
  18. package/animation-frame/animation-native.android.js +4 -0
  19. package/animation-frame/animation-native.android.js.map +1 -0
  20. package/animation-frame/animation-native.ios.d.ts +1 -0
  21. package/animation-frame/animation-native.ios.js +3 -0
  22. package/animation-frame/animation-native.ios.js.map +1 -0
  23. package/animation-frame/index.js +81 -0
  24. package/animation-frame/index.js.map +1 -0
  25. package/application/application-common.d.ts +218 -0
  26. package/application/application-common.js +515 -0
  27. package/application/application-common.js.map +1 -0
  28. package/application/application-interfaces.d.ts +189 -0
  29. package/application/application-interfaces.js +2 -0
  30. package/application/application-interfaces.js.map +1 -0
  31. package/application/application-shims.d.ts +351 -0
  32. package/application/application-shims.js +353 -0
  33. package/application/application-shims.js.map +1 -0
  34. package/application/application.android.d.ts +71 -0
  35. package/application/application.android.js +1195 -0
  36. package/application/application.android.js.map +1 -0
  37. package/application/application.ios.d.ts +78 -0
  38. package/application/application.ios.js +871 -0
  39. package/application/application.ios.js.map +1 -0
  40. package/application/helpers-common.d.ts +50 -0
  41. package/application/helpers-common.js +153 -0
  42. package/application/helpers-common.js.map +1 -0
  43. package/application/helpers.android.d.ts +17 -0
  44. package/application/helpers.android.js +173 -0
  45. package/application/helpers.android.js.map +1 -0
  46. package/application/helpers.ios.d.ts +27 -0
  47. package/application/helpers.ios.js +62 -0
  48. package/application/helpers.ios.js.map +1 -0
  49. package/application/index.android.d.ts +2 -0
  50. package/application/index.android.js +3 -0
  51. package/application/index.android.js.map +1 -0
  52. package/application/index.ios.d.ts +2 -0
  53. package/application/index.ios.js +3 -0
  54. package/application/index.ios.js.map +1 -0
  55. package/application-settings/application-settings-common.d.ts +2 -0
  56. package/application-settings/application-settings-common.js +15 -0
  57. package/application-settings/application-settings-common.js.map +1 -0
  58. package/application-settings/index.android.d.ts +11 -0
  59. package/application-settings/index.android.js +124 -0
  60. package/application-settings/index.android.js.map +1 -0
  61. package/application-settings/index.ios.d.ts +11 -0
  62. package/application-settings/index.ios.js +81 -0
  63. package/application-settings/index.ios.js.map +1 -0
  64. package/bundle-entry-points.d.ts +1 -0
  65. package/bundle-entry-points.js +47 -0
  66. package/bundle-entry-points.js.map +1 -0
  67. package/color/color-common.d.ts +136 -0
  68. package/color/color-common.js +341 -0
  69. package/color/color-common.js.map +1 -0
  70. package/color/color-types.d.ts +49 -0
  71. package/color/color-types.js +3 -0
  72. package/color/color-types.js.map +1 -0
  73. package/color/color-utils.d.ts +38 -0
  74. package/color/color-utils.js +213 -0
  75. package/color/color-utils.js.map +1 -0
  76. package/color/index.android.d.ts +4 -0
  77. package/color/index.android.js +7 -0
  78. package/color/index.android.js.map +1 -0
  79. package/color/index.ios.d.ts +7 -0
  80. package/color/index.ios.js +19 -0
  81. package/color/index.ios.js.map +1 -0
  82. package/color/known-colors.d.ts +144 -0
  83. package/color/known-colors.js +165 -0
  84. package/color/known-colors.js.map +1 -0
  85. package/config/config.interface.d.ts +254 -0
  86. package/config/config.interface.js +2 -0
  87. package/config/config.interface.js.map +1 -0
  88. package/config/index.d.ts +1 -0
  89. package/config/index.js +2 -0
  90. package/config/index.js.map +1 -0
  91. package/connectivity/index.android.d.ts +11 -0
  92. package/connectivity/index.android.js +157 -0
  93. package/connectivity/index.android.js.map +1 -0
  94. package/connectivity/index.ios.d.ts +11 -0
  95. package/connectivity/index.ios.js +132 -0
  96. package/connectivity/index.ios.js.map +1 -0
  97. package/console/index.d.ts +14 -0
  98. package/console/index.js +33 -0
  99. package/console/index.js.map +1 -0
  100. package/core-types/animation-types.d.ts +11 -0
  101. package/core-types/animation-types.js +13 -0
  102. package/core-types/animation-types.js.map +1 -0
  103. package/core-types/index.d.ts +331 -0
  104. package/core-types/index.js +281 -0
  105. package/core-types/index.js.map +1 -0
  106. package/core-types/validators.d.ts +2 -0
  107. package/core-types/validators.js +18 -0
  108. package/core-types/validators.js.map +1 -0
  109. package/css/CSS3Parser.d.ts +184 -0
  110. package/css/CSS3Parser.js +534 -0
  111. package/css/CSS3Parser.js.map +1 -0
  112. package/css/CSSNativeScript.d.ts +14 -0
  113. package/css/CSSNativeScript.js +113 -0
  114. package/css/CSSNativeScript.js.map +1 -0
  115. package/css/css-tree-parser.d.ts +1 -0
  116. package/css/css-tree-parser.js +133 -0
  117. package/css/css-tree-parser.js.map +1 -0
  118. package/css/lib/parse/index.d.ts +1 -0
  119. package/css/lib/parse/index.js +500 -0
  120. package/css/lib/parse/index.js.map +1 -0
  121. package/css/parser.d.ts +70 -0
  122. package/css/parser.js +517 -0
  123. package/css/parser.js.map +1 -0
  124. package/css/reworkcss.d.ts +44 -0
  125. package/css/reworkcss.js +5 -0
  126. package/css/reworkcss.js.map +1 -0
  127. package/css/system-classes.d.ts +12 -0
  128. package/css/system-classes.js +47 -0
  129. package/css/system-classes.js.map +1 -0
  130. package/css-mediaquery/index.d.ts +27 -0
  131. package/css-mediaquery/index.js +118 -0
  132. package/css-mediaquery/index.js.map +1 -0
  133. package/css-value/reworkcss-value.d.ts +31 -0
  134. package/css-value/reworkcss-value.js +91 -0
  135. package/css-value/reworkcss-value.js.map +1 -0
  136. package/data/observable/index.d.ts +212 -0
  137. package/data/observable/index.js +440 -0
  138. package/data/observable/index.js.map +1 -0
  139. package/data/observable-array/index.d.ts +215 -0
  140. package/data/observable-array/index.js +325 -0
  141. package/data/observable-array/index.js.map +1 -0
  142. package/data/virtual-array/index.d.ts +72 -0
  143. package/data/virtual-array/index.js +133 -0
  144. package/data/virtual-array/index.js.map +1 -0
  145. package/debugger/InspectorBackendCommands.d.ts +1056 -0
  146. package/debugger/InspectorBackendCommands.js +578 -0
  147. package/debugger/InspectorBackendCommands.js.map +1 -0
  148. package/debugger/devtools-elements-interfaces.d.ts +16 -0
  149. package/debugger/devtools-elements-interfaces.js +2 -0
  150. package/debugger/devtools-elements-interfaces.js.map +1 -0
  151. package/debugger/devtools-elements.common.d.ts +7 -0
  152. package/debugger/devtools-elements.common.js +93 -0
  153. package/debugger/devtools-elements.common.js.map +1 -0
  154. package/debugger/devtools-elements.js +20 -0
  155. package/debugger/devtools-elements.js.map +1 -0
  156. package/debugger/dom-types.d.ts +24 -0
  157. package/debugger/dom-types.js +152 -0
  158. package/debugger/dom-types.js.map +1 -0
  159. package/debugger/index.d.ts +87 -0
  160. package/debugger/index.js +118 -0
  161. package/debugger/index.js.map +1 -0
  162. package/debugger/webinspector-css.d.ts +34 -0
  163. package/debugger/webinspector-css.js +72 -0
  164. package/debugger/webinspector-css.js.map +1 -0
  165. package/debugger/webinspector-dom.d.ts +33 -0
  166. package/debugger/webinspector-dom.js +75 -0
  167. package/debugger/webinspector-dom.js.map +1 -0
  168. package/debugger/webinspector-network.android.d.ts +79 -0
  169. package/debugger/webinspector-network.android.js +208 -0
  170. package/debugger/webinspector-network.android.js.map +1 -0
  171. package/debugger/webinspector-network.ios.d.ts +79 -0
  172. package/debugger/webinspector-network.ios.js +204 -0
  173. package/debugger/webinspector-network.ios.js.map +1 -0
  174. package/fetch/index.d.ts +72 -0
  175. package/fetch/index.js +529 -0
  176. package/fetch/index.js.map +1 -0
  177. package/file-system/file-system-access.android.d.ts +151 -0
  178. package/file-system/file-system-access.android.js +1162 -0
  179. package/file-system/file-system-access.android.js.map +1 -0
  180. package/file-system/file-system-access.ios.d.ts +85 -0
  181. package/file-system/file-system-access.ios.js +622 -0
  182. package/file-system/file-system-access.ios.js.map +1 -0
  183. package/file-system/index.js +873 -0
  184. package/file-system/index.js.map +1 -0
  185. package/fps-meter/fps-native.android.d.ts +11 -0
  186. package/fps-meter/fps-native.android.js +62 -0
  187. package/fps-meter/fps-native.android.js.map +1 -0
  188. package/fps-meter/fps-native.ios.d.ts +10 -0
  189. package/fps-meter/fps-native.ios.js +56 -0
  190. package/fps-meter/fps-native.ios.js.map +1 -0
  191. package/fps-meter/index.js +77 -0
  192. package/fps-meter/index.js.map +1 -0
  193. package/globals/global-utils.d.ts +27 -0
  194. package/globals/global-utils.js +67 -0
  195. package/globals/global-utils.js.map +1 -0
  196. package/globals/index.d.ts +3 -0
  197. package/globals/index.js +313 -0
  198. package/globals/index.js.map +1 -0
  199. package/http/http-interfaces.d.ts +84 -0
  200. package/http/http-interfaces.js +6 -0
  201. package/http/http-interfaces.js.map +1 -0
  202. package/http/http-request/http-request-common.d.ts +1 -0
  203. package/http/http-request/http-request-common.js +15 -0
  204. package/http/http-request/http-request-common.js.map +1 -0
  205. package/http/http-request/index.android.d.ts +3 -0
  206. package/http/http-request/index.android.js +274 -0
  207. package/http/http-request/index.android.js.map +1 -0
  208. package/http/http-request/index.ios.d.ts +3 -0
  209. package/http/http-request/index.ios.js +221 -0
  210. package/http/http-request/index.ios.js.map +1 -0
  211. package/http/http-shared.d.ts +5 -0
  212. package/http/http-shared.js +14 -0
  213. package/http/http-shared.js.map +1 -0
  214. package/http/index.js +72 -0
  215. package/http/index.js.map +1 -0
  216. package/image-asset/image-asset-common.d.ts +25 -0
  217. package/image-asset/image-asset-common.js +74 -0
  218. package/image-asset/image-asset-common.js.map +1 -0
  219. package/image-asset/index.android.d.ts +9 -0
  220. package/image-asset/index.android.js +33 -0
  221. package/image-asset/index.android.js.map +1 -0
  222. package/image-asset/index.ios.d.ts +10 -0
  223. package/image-asset/index.ios.js +57 -0
  224. package/image-asset/index.ios.js.map +1 -0
  225. package/image-source/image-source-common.d.ts +4 -0
  226. package/image-source/image-source-common.js +21 -0
  227. package/image-source/image-source-common.js.map +1 -0
  228. package/image-source/index.android.d.ts +58 -0
  229. package/image-source/index.android.js +371 -0
  230. package/image-source/index.android.js.map +1 -0
  231. package/image-source/index.ios.d.ts +59 -0
  232. package/image-source/index.ios.js +454 -0
  233. package/image-source/index.ios.js.map +1 -0
  234. package/index.js +39 -0
  235. package/index.js.map +1 -0
  236. package/inspector_modules.d.ts +7 -0
  237. package/inspector_modules.js +147 -0
  238. package/inspector_modules.js.map +1 -0
  239. package/matrix/index.js +45 -0
  240. package/matrix/index.js.map +1 -0
  241. package/media-query-list/index.d.ts +21 -0
  242. package/media-query-list/index.js +159 -0
  243. package/media-query-list/index.js.map +1 -0
  244. package/module-name-resolver/helpers.d.ts +14 -0
  245. package/module-name-resolver/helpers.js +27 -0
  246. package/module-name-resolver/helpers.js.map +1 -0
  247. package/module-name-resolver/index.d.ts +14 -0
  248. package/module-name-resolver/index.js +67 -0
  249. package/module-name-resolver/index.js.map +1 -0
  250. package/module-name-resolver/non-bundle-workflow-compat.d.ts +6 -0
  251. package/module-name-resolver/non-bundle-workflow-compat.js +128 -0
  252. package/module-name-resolver/non-bundle-workflow-compat.js.map +1 -0
  253. package/module-name-resolver/qualifier-matcher/index.d.ts +11 -0
  254. package/module-name-resolver/qualifier-matcher/index.js +141 -0
  255. package/module-name-resolver/qualifier-matcher/index.js.map +1 -0
  256. package/package.json +86 -86
  257. package/platform/common.d.ts +10 -0
  258. package/platform/common.js +14 -0
  259. package/platform/common.js.map +1 -0
  260. package/platform/device/index.android.d.ts +20 -0
  261. package/platform/device/index.android.js +78 -0
  262. package/platform/device/index.android.js.map +1 -0
  263. package/platform/device/index.ios.d.ts +19 -0
  264. package/platform/device/index.ios.js +69 -0
  265. package/platform/device/index.ios.js.map +1 -0
  266. package/platform/index.js +4 -0
  267. package/platform/index.js.map +1 -0
  268. package/platform/screen/index.android.d.ts +16 -0
  269. package/platform/screen/index.android.js +41 -0
  270. package/platform/screen/index.android.js.map +1 -0
  271. package/platform/screen/index.ios.d.ts +15 -0
  272. package/platform/screen/index.ios.js +35 -0
  273. package/platform/screen/index.ios.js.map +1 -0
  274. package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Headers/NSCCrypto.h +79 -0
  275. package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Headers/NSCWinterTC.h +20 -0
  276. package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Headers/NSString+WinterTC.h +21 -0
  277. package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Modules/module.modulemap +6 -0
  278. package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Resources/Info.plist +52 -0
  279. package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Versions/Current/Headers/NSCCrypto.h +79 -0
  280. package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Versions/Current/Headers/NSCWinterTC.h +20 -0
  281. package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Versions/Current/Headers/NSString+WinterTC.h +21 -0
  282. package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Versions/Current/Modules/module.modulemap +6 -0
  283. package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Versions/Current/NSCWinterTC +0 -0
  284. package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Versions/Current/Resources/Info.plist +52 -0
  285. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/NSCCrypto.h +60 -0
  286. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/NSData+Async.h +24 -0
  287. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/NSFileHandle+Async.h +22 -0
  288. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/NSString+Async.h +25 -0
  289. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/TNSLabel.h +16 -0
  290. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/TNSProcess.h +29 -0
  291. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/TNSWidgets.h +25 -0
  292. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/UIImage+TNSBlocks.h +26 -0
  293. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/UIView+PassThroughParent.h +17 -0
  294. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Modules/module.modulemap +6 -0
  295. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/PrivateHeaders/NSObject+Swizzling.h +17 -0
  296. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/PrivateHeaders/UIView+PropertyBag.h +18 -0
  297. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Resources/Info.plist +52 -0
  298. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/NSCCrypto.h +60 -0
  299. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/NSData+Async.h +24 -0
  300. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/NSFileHandle+Async.h +22 -0
  301. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/NSString+Async.h +25 -0
  302. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/TNSLabel.h +16 -0
  303. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/TNSProcess.h +29 -0
  304. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/TNSWidgets.h +25 -0
  305. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/UIImage+TNSBlocks.h +26 -0
  306. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/UIView+PassThroughParent.h +17 -0
  307. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Modules/module.modulemap +6 -0
  308. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/PrivateHeaders/NSObject+Swizzling.h +17 -0
  309. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/PrivateHeaders/UIView+PropertyBag.h +18 -0
  310. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Resources/Info.plist +52 -0
  311. package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/TNSWidgets +0 -0
  312. package/profiling/index.js +273 -0
  313. package/profiling/index.js.map +1 -0
  314. package/text/formatted-string.js +2 -0
  315. package/text/formatted-string.js.map +1 -0
  316. package/text/index.android.d.ts +9 -0
  317. package/text/index.android.js +11 -0
  318. package/text/index.android.js.map +1 -0
  319. package/text/index.ios.d.ts +9 -0
  320. package/text/index.ios.js +11 -0
  321. package/text/index.ios.js.map +1 -0
  322. package/text/span.js +2 -0
  323. package/text/span.js.map +1 -0
  324. package/text/text-common.d.ts +12 -0
  325. package/text/text-common.js +111 -0
  326. package/text/text-common.js.map +1 -0
  327. package/timer/index.android.d.ts +4 -0
  328. package/timer/index.android.js +83 -0
  329. package/timer/index.android.js.map +1 -0
  330. package/timer/index.ios.d.ts +4 -0
  331. package/timer/index.ios.js +68 -0
  332. package/timer/index.ios.js.map +1 -0
  333. package/trace/index.js +255 -0
  334. package/trace/index.js.map +1 -0
  335. package/ui/action-bar/action-bar-common.d.ts +85 -0
  336. package/ui/action-bar/action-bar-common.js +381 -0
  337. package/ui/action-bar/action-bar-common.js.map +1 -0
  338. package/ui/action-bar/index.android.d.ts +55 -0
  339. package/ui/action-bar/index.android.js +504 -0
  340. package/ui/action-bar/index.android.js.map +1 -0
  341. package/ui/action-bar/index.ios.d.ts +64 -0
  342. package/ui/action-bar/index.ios.js +616 -0
  343. package/ui/action-bar/index.ios.js.map +1 -0
  344. package/ui/activity-indicator/activity-indicator-common.d.ts +9 -0
  345. package/ui/activity-indicator/activity-indicator-common.js +22 -0
  346. package/ui/activity-indicator/activity-indicator-common.js.map +1 -0
  347. package/ui/activity-indicator/index.android.d.ts +15 -0
  348. package/ui/activity-indicator/index.android.js +54 -0
  349. package/ui/activity-indicator/index.android.js.map +1 -0
  350. package/ui/activity-indicator/index.ios.d.ts +16 -0
  351. package/ui/activity-indicator/index.ios.js +54 -0
  352. package/ui/activity-indicator/index.ios.js.map +1 -0
  353. package/ui/animation/animation-common.d.ts +30 -0
  354. package/ui/animation/animation-common.js +239 -0
  355. package/ui/animation/animation-common.js.map +1 -0
  356. package/ui/animation/animation-shared.d.ts +84 -0
  357. package/ui/animation/animation-shared.js +4 -0
  358. package/ui/animation/animation-shared.js.map +1 -0
  359. package/ui/animation/animation-types.d.ts +1 -0
  360. package/ui/animation/animation-types.js +3 -0
  361. package/ui/animation/animation-types.js.map +1 -0
  362. package/ui/animation/index.android.d.ts +23 -0
  363. package/ui/animation/index.android.js +432 -0
  364. package/ui/animation/index.android.js.map +1 -0
  365. package/ui/animation/index.ios.d.ts +28 -0
  366. package/ui/animation/index.ios.js +809 -0
  367. package/ui/animation/index.ios.js.map +1 -0
  368. package/ui/animation/keyframe-animation.d.ts +76 -0
  369. package/ui/animation/keyframe-animation.js +238 -0
  370. package/ui/animation/keyframe-animation.js.map +1 -0
  371. package/ui/builder/binding-builder.d.ts +13 -0
  372. package/ui/builder/binding-builder.js +171 -0
  373. package/ui/builder/binding-builder.js.map +1 -0
  374. package/ui/builder/component-builder/index.d.ts +7 -0
  375. package/ui/builder/component-builder/index.js +219 -0
  376. package/ui/builder/component-builder/index.js.map +1 -0
  377. package/ui/builder/index.d.ts +193 -0
  378. package/ui/builder/index.js +643 -0
  379. package/ui/builder/index.js.map +1 -0
  380. package/ui/button/button-common.d.ts +9 -0
  381. package/ui/button/button-common.js +26 -0
  382. package/ui/button/button-common.js.map +1 -0
  383. package/ui/button/index.android.d.ts +29 -0
  384. package/ui/button/index.android.js +168 -0
  385. package/ui/button/index.android.js.map +1 -0
  386. package/ui/button/index.ios.d.ts +36 -0
  387. package/ui/button/index.ios.js +298 -0
  388. package/ui/button/index.ios.js.map +1 -0
  389. package/ui/content-view/index.js +87 -0
  390. package/ui/content-view/index.js.map +1 -0
  391. package/ui/core/bindable/bindable-expressions.d.ts +7 -0
  392. package/ui/core/bindable/bindable-expressions.js +255 -0
  393. package/ui/core/bindable/bindable-expressions.js.map +1 -0
  394. package/ui/core/bindable/bindable-resources.d.ts +2 -0
  395. package/ui/core/bindable/bindable-resources.js +8 -0
  396. package/ui/core/bindable/bindable-resources.js.map +1 -0
  397. package/ui/core/bindable/bindable-types.d.ts +37 -0
  398. package/ui/core/bindable/bindable-types.js +3 -0
  399. package/ui/core/bindable/bindable-types.js.map +1 -0
  400. package/ui/core/bindable/index.d.ts +53 -0
  401. package/ui/core/bindable/index.js +555 -0
  402. package/ui/core/bindable/index.js.map +1 -0
  403. package/ui/core/control-state-change/index.android.d.ts +6 -0
  404. package/ui/core/control-state-change/index.android.js +8 -0
  405. package/ui/core/control-state-change/index.android.js.map +1 -0
  406. package/ui/core/control-state-change/index.ios.d.ts +10 -0
  407. package/ui/core/control-state-change/index.ios.js +43 -0
  408. package/ui/core/control-state-change/index.ios.js.map +1 -0
  409. package/ui/core/properties/index.d.ts +114 -0
  410. package/ui/core/properties/index.js +1290 -0
  411. package/ui/core/properties/index.js.map +1 -0
  412. package/ui/core/properties/property-shared.d.ts +35 -0
  413. package/ui/core/properties/property-shared.js +16 -0
  414. package/ui/core/properties/property-shared.js.map +1 -0
  415. package/ui/core/view/index.android.d.ts +144 -0
  416. package/ui/core/view/index.android.js +1696 -0
  417. package/ui/core/view/index.android.js.map +1 -0
  418. package/ui/core/view/index.ios.d.ts +142 -0
  419. package/ui/core/view/index.ios.js +1031 -0
  420. package/ui/core/view/index.ios.js.map +1 -0
  421. package/ui/core/view/view-common.d.ts +315 -0
  422. package/ui/core/view/view-common.js +1119 -0
  423. package/ui/core/view/view-common.js.map +1 -0
  424. package/ui/core/view/view-helper/index.android.d.ts +9 -0
  425. package/ui/core/view/view-helper/index.android.js +56 -0
  426. package/ui/core/view/view-helper/index.android.js.map +1 -0
  427. package/ui/core/view/view-helper/index.ios.d.ts +64 -0
  428. package/ui/core/view/view-helper/index.ios.js +363 -0
  429. package/ui/core/view/view-helper/index.ios.js.map +1 -0
  430. package/ui/core/view/view-helper/view-helper-common.d.ts +11 -0
  431. package/ui/core/view/view-helper/view-helper-common.js +159 -0
  432. package/ui/core/view/view-helper/view-helper-common.js.map +1 -0
  433. package/ui/core/view/view-helper/view-helper-shared.d.ts +5 -0
  434. package/ui/core/view/view-helper/view-helper-shared.js +6 -0
  435. package/ui/core/view/view-helper/view-helper-shared.js.map +1 -0
  436. package/ui/core/view/view-interfaces.d.ts +73 -0
  437. package/ui/core/view/view-interfaces.js +2 -0
  438. package/ui/core/view/view-interfaces.js.map +1 -0
  439. package/ui/core/view-base/index.d.ts +593 -0
  440. package/ui/core/view-base/index.js +1150 -0
  441. package/ui/core/view-base/index.js.map +1 -0
  442. package/ui/core/view-base/utils.d.ts +1 -0
  443. package/ui/core/view-base/utils.js +9 -0
  444. package/ui/core/view-base/utils.js.map +1 -0
  445. package/ui/core/weak-event-listener/index.js +123 -0
  446. package/ui/core/weak-event-listener/index.js.map +1 -0
  447. package/ui/date-picker/date-picker-common.d.ts +28 -0
  448. package/ui/date-picker/date-picker-common.js +82 -0
  449. package/ui/date-picker/date-picker-common.js.map +1 -0
  450. package/ui/date-picker/index.android.d.ts +19 -0
  451. package/ui/date-picker/index.android.js +133 -0
  452. package/ui/date-picker/index.android.js.map +1 -0
  453. package/ui/date-picker/index.ios.d.ts +27 -0
  454. package/ui/date-picker/index.ios.js +165 -0
  455. package/ui/date-picker/index.ios.js.map +1 -0
  456. package/ui/dialogs/dialogs-common.d.ts +211 -0
  457. package/ui/dialogs/dialogs-common.js +167 -0
  458. package/ui/dialogs/dialogs-common.js.map +1 -0
  459. package/ui/dialogs/index.android.d.ts +20 -0
  460. package/ui/dialogs/index.android.js +330 -0
  461. package/ui/dialogs/index.android.js.map +1 -0
  462. package/ui/dialogs/index.ios.d.ts +17 -0
  463. package/ui/dialogs/index.ios.js +293 -0
  464. package/ui/dialogs/index.ios.js.map +1 -0
  465. package/ui/editable-text-base/editable-text-base-common.d.ts +36 -0
  466. package/ui/editable-text-base/editable-text-base-common.js +91 -0
  467. package/ui/editable-text-base/editable-text-base-common.js.map +1 -0
  468. package/ui/editable-text-base/index.android.d.ts +48 -0
  469. package/ui/editable-text-base/index.android.js +499 -0
  470. package/ui/editable-text-base/index.android.js.map +1 -0
  471. package/ui/editable-text-base/index.ios.d.ts +20 -0
  472. package/ui/editable-text-base/index.ios.js +255 -0
  473. package/ui/editable-text-base/index.ios.js.map +1 -0
  474. package/ui/embedding/index.android.d.ts +4 -0
  475. package/ui/embedding/index.android.js +14 -0
  476. package/ui/embedding/index.android.js.map +1 -0
  477. package/ui/embedding/index.ios.d.ts +1 -0
  478. package/ui/embedding/index.ios.js +4 -0
  479. package/ui/embedding/index.ios.js.map +1 -0
  480. package/ui/enums/enums.js +6 -0
  481. package/ui/enums/enums.js.map +1 -0
  482. package/ui/enums/index.js +6 -0
  483. package/ui/enums/index.js.map +1 -0
  484. package/ui/frame/activity.android.d.ts +1 -0
  485. package/ui/frame/activity.android.js +113 -0
  486. package/ui/frame/activity.android.js.map +1 -0
  487. package/ui/frame/fragment.android.d.ts +3 -0
  488. package/ui/frame/fragment.android.js +90 -0
  489. package/ui/frame/fragment.android.js.map +1 -0
  490. package/ui/frame/fragment.ios.d.ts +3 -0
  491. package/ui/frame/fragment.ios.js +4 -0
  492. package/ui/frame/fragment.ios.js.map +1 -0
  493. package/ui/frame/fragment.transitions.android.d.ts +39 -0
  494. package/ui/frame/fragment.transitions.android.js +680 -0
  495. package/ui/frame/fragment.transitions.android.js.map +1 -0
  496. package/ui/frame/fragment.transitions.types.d.ts +6 -0
  497. package/ui/frame/fragment.transitions.types.js +2 -0
  498. package/ui/frame/fragment.transitions.types.js.map +1 -0
  499. package/ui/frame/frame-common.d.ts +101 -0
  500. package/ui/frame/frame-common.js +688 -0
  501. package/ui/frame/frame-common.js.map +1 -0
  502. package/ui/frame/frame-helper-for-android.d.ts +37 -0
  503. package/ui/frame/frame-helper-for-android.js +337 -0
  504. package/ui/frame/frame-helper-for-android.js.map +1 -0
  505. package/ui/frame/frame-helpers.d.ts +16 -0
  506. package/ui/frame/frame-helpers.js +19 -0
  507. package/ui/frame/frame-helpers.js.map +1 -0
  508. package/ui/frame/frame-interfaces.d.ts +130 -0
  509. package/ui/frame/frame-interfaces.js +7 -0
  510. package/ui/frame/frame-interfaces.js.map +1 -0
  511. package/ui/frame/frame-stack.d.ts +7 -0
  512. package/ui/frame/frame-stack.js +41 -0
  513. package/ui/frame/frame-stack.js.map +1 -0
  514. package/ui/frame/index.android.d.ts +93 -0
  515. package/ui/frame/index.android.js +919 -0
  516. package/ui/frame/index.android.js.map +1 -0
  517. package/ui/frame/index.ios.d.ts +57 -0
  518. package/ui/frame/index.ios.js +676 -0
  519. package/ui/frame/index.ios.js.map +1 -0
  520. package/ui/gestures/gestures-common.d.ts +32 -0
  521. package/ui/gestures/gestures-common.js +78 -0
  522. package/ui/gestures/gestures-common.js.map +1 -0
  523. package/ui/gestures/gestures-types.d.ts +108 -0
  524. package/ui/gestures/gestures-types.js +40 -0
  525. package/ui/gestures/gestures-types.js.map +1 -0
  526. package/ui/gestures/index.android.d.ts +49 -0
  527. package/ui/gestures/index.android.js +597 -0
  528. package/ui/gestures/index.android.js.map +1 -0
  529. package/ui/gestures/index.ios.d.ts +70 -0
  530. package/ui/gestures/index.ios.js +512 -0
  531. package/ui/gestures/index.ios.js.map +1 -0
  532. package/ui/gestures/touch-manager.d.ts +82 -0
  533. package/ui/gestures/touch-manager.js +268 -0
  534. package/ui/gestures/touch-manager.js.map +1 -0
  535. package/ui/html-view/html-view-common.d.ts +12 -0
  536. package/ui/html-view/html-view-common.js +31 -0
  537. package/ui/html-view/html-view-common.js.map +1 -0
  538. package/ui/html-view/index.android.d.ts +27 -0
  539. package/ui/html-view/index.android.js +90 -0
  540. package/ui/html-view/index.android.js.map +1 -0
  541. package/ui/html-view/index.ios.d.ts +22 -0
  542. package/ui/html-view/index.ios.js +101 -0
  543. package/ui/html-view/index.ios.js.map +1 -0
  544. package/ui/image/image-common.d.ts +45 -0
  545. package/ui/image/image-common.js +195 -0
  546. package/ui/image/image-common.js.map +1 -0
  547. package/ui/image/index.android.d.ts +23 -0
  548. package/ui/image/index.android.js +173 -0
  549. package/ui/image/index.android.js.map +1 -0
  550. package/ui/image/index.ios.d.ts +26 -0
  551. package/ui/image/index.ios.js +186 -0
  552. package/ui/image/index.ios.js.map +1 -0
  553. package/ui/image/symbol-effects-common.d.ts +36 -0
  554. package/ui/image/symbol-effects-common.js +35 -0
  555. package/ui/image/symbol-effects-common.js.map +1 -0
  556. package/ui/image/symbol-effects.android.d.ts +5 -0
  557. package/ui/image/symbol-effects.android.js +8 -0
  558. package/ui/image/symbol-effects.android.js.map +1 -0
  559. package/ui/image/symbol-effects.ios.d.ts +6 -0
  560. package/ui/image/symbol-effects.ios.js +79 -0
  561. package/ui/image/symbol-effects.ios.js.map +1 -0
  562. package/ui/image-cache/image-cache-common.d.ts +40 -0
  563. package/ui/image-cache/image-cache-common.js +176 -0
  564. package/ui/image-cache/image-cache-common.js.map +1 -0
  565. package/ui/image-cache/index.android.d.ts +11 -0
  566. package/ui/image-cache/index.android.js +76 -0
  567. package/ui/image-cache/index.android.js.map +1 -0
  568. package/ui/image-cache/index.ios.d.ts +11 -0
  569. package/ui/image-cache/index.ios.js +78 -0
  570. package/ui/image-cache/index.ios.js.map +1 -0
  571. package/ui/index.d.ts +90 -0
  572. package/ui/index.js +79 -0
  573. package/ui/index.js.map +1 -0
  574. package/ui/label/index.android.d.ts +13 -0
  575. package/ui/label/index.android.js +44 -0
  576. package/ui/label/index.android.js.map +1 -0
  577. package/ui/label/index.ios.d.ts +30 -0
  578. package/ui/label/index.ios.js +224 -0
  579. package/ui/label/index.ios.js.map +1 -0
  580. package/ui/layouts/absolute-layout/absolute-layout-common.d.ts +16 -0
  581. package/ui/layouts/absolute-layout/absolute-layout-common.js +72 -0
  582. package/ui/layouts/absolute-layout/absolute-layout-common.js.map +1 -0
  583. package/ui/layouts/absolute-layout/index.android.d.ts +6 -0
  584. package/ui/layouts/absolute-layout/index.android.js +26 -0
  585. package/ui/layouts/absolute-layout/index.android.js.map +1 -0
  586. package/ui/layouts/absolute-layout/index.ios.d.ts +10 -0
  587. package/ui/layouts/absolute-layout/index.ios.js +48 -0
  588. package/ui/layouts/absolute-layout/index.ios.js.map +1 -0
  589. package/ui/layouts/dock-layout/dock-layout-common.d.ts +14 -0
  590. package/ui/layouts/dock-layout/dock-layout-common.js +51 -0
  591. package/ui/layouts/dock-layout/dock-layout-common.js.map +1 -0
  592. package/ui/layouts/dock-layout/index.android.d.ts +8 -0
  593. package/ui/layouts/dock-layout/index.android.js +38 -0
  594. package/ui/layouts/dock-layout/index.android.js.map +1 -0
  595. package/ui/layouts/dock-layout/index.ios.d.ts +8 -0
  596. package/ui/layouts/dock-layout/index.ios.js +115 -0
  597. package/ui/layouts/dock-layout/index.ios.js.map +1 -0
  598. package/ui/layouts/flexbox-layout/flexbox-layout-common.d.ts +126 -0
  599. package/ui/layouts/flexbox-layout/flexbox-layout-common.js +403 -0
  600. package/ui/layouts/flexbox-layout/flexbox-layout-common.js.map +1 -0
  601. package/ui/layouts/flexbox-layout/index.android.d.ts +23 -0
  602. package/ui/layouts/flexbox-layout/index.android.js +152 -0
  603. package/ui/layouts/flexbox-layout/index.android.js.map +1 -0
  604. package/ui/layouts/flexbox-layout/index.ios.d.ts +44 -0
  605. package/ui/layouts/flexbox-layout/index.ios.js +1244 -0
  606. package/ui/layouts/flexbox-layout/index.ios.js.map +1 -0
  607. package/ui/layouts/grid-layout/grid-layout-common.d.ts +72 -0
  608. package/ui/layouts/grid-layout/grid-layout-common.js +358 -0
  609. package/ui/layouts/grid-layout/grid-layout-common.js.map +1 -0
  610. package/ui/layouts/grid-layout/index.android.d.ts +23 -0
  611. package/ui/layouts/grid-layout/index.android.js +122 -0
  612. package/ui/layouts/grid-layout/index.android.js.map +1 -0
  613. package/ui/layouts/grid-layout/index.ios.d.ts +28 -0
  614. package/ui/layouts/grid-layout/index.ios.js +778 -0
  615. package/ui/layouts/grid-layout/index.ios.js.map +1 -0
  616. package/ui/layouts/index.d.ts +10 -0
  617. package/ui/layouts/index.js +9 -0
  618. package/ui/layouts/index.js.map +1 -0
  619. package/ui/layouts/layout-base-common.d.ts +36 -0
  620. package/ui/layouts/layout-base-common.js +141 -0
  621. package/ui/layouts/layout-base-common.js.map +1 -0
  622. package/ui/layouts/layout-base.android.d.ts +17 -0
  623. package/ui/layouts/layout-base.android.js +50 -0
  624. package/ui/layouts/layout-base.android.js.map +1 -0
  625. package/ui/layouts/layout-base.ios.d.ts +13 -0
  626. package/ui/layouts/layout-base.ios.js +40 -0
  627. package/ui/layouts/layout-base.ios.js.map +1 -0
  628. package/ui/layouts/root-layout/index.android.d.ts +15 -0
  629. package/ui/layouts/root-layout/index.android.js +126 -0
  630. package/ui/layouts/root-layout/index.android.js.map +1 -0
  631. package/ui/layouts/root-layout/index.ios.d.ts +17 -0
  632. package/ui/layouts/root-layout/index.ios.js +101 -0
  633. package/ui/layouts/root-layout/index.ios.js.map +1 -0
  634. package/ui/layouts/root-layout/root-layout-common.d.ts +61 -0
  635. package/ui/layouts/root-layout/root-layout-common.js +422 -0
  636. package/ui/layouts/root-layout/root-layout-common.js.map +1 -0
  637. package/ui/layouts/root-layout/root-layout-stack.d.ts +5 -0
  638. package/ui/layouts/root-layout/root-layout-stack.js +19 -0
  639. package/ui/layouts/root-layout/root-layout-stack.js.map +1 -0
  640. package/ui/layouts/stack-layout/index.android.d.ts +7 -0
  641. package/ui/layouts/stack-layout/index.android.js +11 -0
  642. package/ui/layouts/stack-layout/index.android.js.map +1 -0
  643. package/ui/layouts/stack-layout/index.ios.d.ts +10 -0
  644. package/ui/layouts/stack-layout/index.ios.js +149 -0
  645. package/ui/layouts/stack-layout/index.ios.js.map +1 -0
  646. package/ui/layouts/stack-layout/stack-layout-common.d.ts +8 -0
  647. package/ui/layouts/stack-layout/stack-layout-common.js +19 -0
  648. package/ui/layouts/stack-layout/stack-layout-common.js.map +1 -0
  649. package/ui/layouts/wrap-layout/index.android.d.ts +10 -0
  650. package/ui/layouts/wrap-layout/index.android.js +18 -0
  651. package/ui/layouts/wrap-layout/index.android.js.map +1 -0
  652. package/ui/layouts/wrap-layout/index.ios.d.ts +8 -0
  653. package/ui/layouts/wrap-layout/index.ios.js +170 -0
  654. package/ui/layouts/wrap-layout/index.ios.js.map +1 -0
  655. package/ui/layouts/wrap-layout/wrap-layout-common.d.ts +15 -0
  656. package/ui/layouts/wrap-layout/wrap-layout-common.js +40 -0
  657. package/ui/layouts/wrap-layout/wrap-layout-common.js.map +1 -0
  658. package/ui/list-picker/index.android.d.ts +18 -0
  659. package/ui/list-picker/index.android.js +181 -0
  660. package/ui/list-picker/index.android.js.map +1 -0
  661. package/ui/list-picker/index.ios.d.ts +19 -0
  662. package/ui/list-picker/index.ios.js +99 -0
  663. package/ui/list-picker/index.ios.js.map +1 -0
  664. package/ui/list-picker/list-picker-common.d.ts +23 -0
  665. package/ui/list-picker/list-picker-common.js +78 -0
  666. package/ui/list-picker/list-picker-common.js.map +1 -0
  667. package/ui/list-view/index.android.d.ts +43 -0
  668. package/ui/list-view/index.android.js +368 -0
  669. package/ui/list-view/index.android.js.map +1 -0
  670. package/ui/list-view/index.ios.d.ts +52 -0
  671. package/ui/list-view/index.ios.js +460 -0
  672. package/ui/list-view/index.ios.js.map +1 -0
  673. package/ui/list-view/list-view-common.d.ts +66 -0
  674. package/ui/list-view/list-view-common.js +211 -0
  675. package/ui/list-view/list-view-common.js.map +1 -0
  676. package/ui/page/events.d.ts +6 -0
  677. package/ui/page/events.js +7 -0
  678. package/ui/page/events.js.map +1 -0
  679. package/ui/page/index.android.d.ts +16 -0
  680. package/ui/page/index.android.js +106 -0
  681. package/ui/page/index.android.js.map +1 -0
  682. package/ui/page/index.ios.d.ts +52 -0
  683. package/ui/page/index.ios.js +554 -0
  684. package/ui/page/index.ios.js.map +1 -0
  685. package/ui/page/page-common.d.ts +73 -0
  686. package/ui/page/page-common.js +191 -0
  687. package/ui/page/page-common.js.map +1 -0
  688. package/ui/placeholder/index.android.d.ts +12 -0
  689. package/ui/placeholder/index.android.js +21 -0
  690. package/ui/placeholder/index.android.js.map +1 -0
  691. package/ui/placeholder/index.js +16 -0
  692. package/ui/placeholder/index.js.map +1 -0
  693. package/ui/placeholder/placeholder-common.d.ts +11 -0
  694. package/ui/placeholder/placeholder-common.js +2 -0
  695. package/ui/placeholder/placeholder-common.js.map +1 -0
  696. package/ui/progress/index.android.d.ts +18 -0
  697. package/ui/progress/index.android.js +65 -0
  698. package/ui/progress/index.android.js.map +1 -0
  699. package/ui/progress/index.ios.d.ts +19 -0
  700. package/ui/progress/index.ios.js +45 -0
  701. package/ui/progress/index.ios.js.map +1 -0
  702. package/ui/progress/progress-common.d.ts +15 -0
  703. package/ui/progress/progress-common.js +34 -0
  704. package/ui/progress/progress-common.js.map +1 -0
  705. package/ui/proxy-view-container/index.d.ts +33 -0
  706. package/ui/proxy-view-container/index.js +247 -0
  707. package/ui/proxy-view-container/index.js.map +1 -0
  708. package/ui/repeater/index.d.ts +67 -0
  709. package/ui/repeater/index.js +225 -0
  710. package/ui/repeater/index.js.map +1 -0
  711. package/ui/scroll-view/index.android.d.ts +27 -0
  712. package/ui/scroll-view/index.android.js +157 -0
  713. package/ui/scroll-view/index.android.js.map +1 -0
  714. package/ui/scroll-view/index.ios.d.ts +27 -0
  715. package/ui/scroll-view/index.ios.js +174 -0
  716. package/ui/scroll-view/index.ios.js.map +1 -0
  717. package/ui/scroll-view/scroll-view-common.d.ts +32 -0
  718. package/ui/scroll-view/scroll-view-common.js +93 -0
  719. package/ui/scroll-view/scroll-view-common.js.map +1 -0
  720. package/ui/search-bar/index.android.d.ts +44 -0
  721. package/ui/search-bar/index.android.js +268 -0
  722. package/ui/search-bar/index.android.js.map +1 -0
  723. package/ui/search-bar/index.ios.d.ts +36 -0
  724. package/ui/search-bar/index.ios.js +206 -0
  725. package/ui/search-bar/index.ios.js.map +1 -0
  726. package/ui/search-bar/search-bar-common.d.ts +19 -0
  727. package/ui/search-bar/search-bar-common.js +43 -0
  728. package/ui/search-bar/search-bar-common.js.map +1 -0
  729. package/ui/segmented-bar/index.android.d.ts +42 -0
  730. package/ui/segmented-bar/index.android.js +286 -0
  731. package/ui/segmented-bar/index.android.js.map +1 -0
  732. package/ui/segmented-bar/index.ios.d.ts +28 -0
  733. package/ui/segmented-bar/index.ios.js +140 -0
  734. package/ui/segmented-bar/index.ios.js.map +1 -0
  735. package/ui/segmented-bar/segmented-bar-common.d.ts +37 -0
  736. package/ui/segmented-bar/segmented-bar-common.js +146 -0
  737. package/ui/segmented-bar/segmented-bar-common.js.map +1 -0
  738. package/ui/slider/index.android.d.ts +32 -0
  739. package/ui/slider/index.android.js +126 -0
  740. package/ui/slider/index.android.js.map +1 -0
  741. package/ui/slider/index.ios.d.ts +34 -0
  742. package/ui/slider/index.ios.js +145 -0
  743. package/ui/slider/index.ios.js.map +1 -0
  744. package/ui/slider/slider-common.d.ts +27 -0
  745. package/ui/slider/slider-common.js +69 -0
  746. package/ui/slider/slider-common.js.map +1 -0
  747. package/ui/styling/background-common.d.ts +78 -0
  748. package/ui/styling/background-common.js +241 -0
  749. package/ui/styling/background-common.js.map +1 -0
  750. package/ui/styling/background.android.d.ts +3 -0
  751. package/ui/styling/background.android.js +82 -0
  752. package/ui/styling/background.android.js.map +1 -0
  753. package/ui/styling/background.ios.d.ts +20 -0
  754. package/ui/styling/background.ios.js +1096 -0
  755. package/ui/styling/background.ios.js.map +1 -0
  756. package/ui/styling/box-shadow.d.ts +9 -0
  757. package/ui/styling/box-shadow.js +3 -0
  758. package/ui/styling/box-shadow.js.map +1 -0
  759. package/ui/styling/clip-path-function.d.ts +16 -0
  760. package/ui/styling/clip-path-function.js +25 -0
  761. package/ui/styling/clip-path-function.js.map +1 -0
  762. package/ui/styling/converters.d.ts +2 -0
  763. package/ui/styling/converters.js +41 -0
  764. package/ui/styling/converters.js.map +1 -0
  765. package/ui/styling/css-animation-parser.d.ts +14 -0
  766. package/ui/styling/css-animation-parser.js +187 -0
  767. package/ui/styling/css-animation-parser.js.map +1 -0
  768. package/ui/styling/css-selector.d.ts +270 -0
  769. package/ui/styling/css-selector.js +934 -0
  770. package/ui/styling/css-selector.js.map +1 -0
  771. package/ui/styling/css-shadow.d.ts +19 -0
  772. package/ui/styling/css-shadow.js +26 -0
  773. package/ui/styling/css-shadow.js.map +1 -0
  774. package/ui/styling/css-stroke.d.ts +12 -0
  775. package/ui/styling/css-stroke.js +19 -0
  776. package/ui/styling/css-stroke.js.map +1 -0
  777. package/ui/styling/css-transform.d.ts +2 -0
  778. package/ui/styling/css-transform.js +110 -0
  779. package/ui/styling/css-transform.js.map +1 -0
  780. package/ui/styling/css-utils.d.ts +7 -0
  781. package/ui/styling/css-utils.js +62 -0
  782. package/ui/styling/css-utils.js.map +1 -0
  783. package/ui/styling/font-common.d.ts +62 -0
  784. package/ui/styling/font-common.js +195 -0
  785. package/ui/styling/font-common.js.map +1 -0
  786. package/ui/styling/font-interfaces.d.ts +16 -0
  787. package/ui/styling/font-interfaces.js +2 -0
  788. package/ui/styling/font-interfaces.js.map +1 -0
  789. package/ui/styling/font.android.d.ts +15 -0
  790. package/ui/styling/font.android.js +226 -0
  791. package/ui/styling/font.android.js.map +1 -0
  792. package/ui/styling/font.ios.d.ts +18 -0
  793. package/ui/styling/font.ios.js +159 -0
  794. package/ui/styling/font.ios.js.map +1 -0
  795. package/ui/styling/length-shared.d.ts +52 -0
  796. package/ui/styling/length-shared.js +173 -0
  797. package/ui/styling/length-shared.js.map +1 -0
  798. package/ui/styling/linear-gradient.d.ts +13 -0
  799. package/ui/styling/linear-gradient.js +48 -0
  800. package/ui/styling/linear-gradient.js.map +1 -0
  801. package/ui/styling/style/index.d.ts +164 -0
  802. package/ui/styling/style/index.js +67 -0
  803. package/ui/styling/style/index.js.map +1 -0
  804. package/ui/styling/style-properties.d.ts +62 -0
  805. package/ui/styling/style-properties.js +1132 -0
  806. package/ui/styling/style-properties.js.map +1 -0
  807. package/ui/styling/style-scope.d.ts +87 -0
  808. package/ui/styling/style-scope.js +1020 -0
  809. package/ui/styling/style-scope.js.map +1 -0
  810. package/ui/styling/styling-profile.d.ts +1 -0
  811. package/ui/styling/styling-profile.js +4 -0
  812. package/ui/styling/styling-profile.js.map +1 -0
  813. package/ui/styling/styling-shared.d.ts +3 -0
  814. package/ui/styling/styling-shared.js +6 -0
  815. package/ui/styling/styling-shared.js.map +1 -0
  816. package/ui/switch/index.android.d.ts +23 -0
  817. package/ui/switch/index.android.js +113 -0
  818. package/ui/switch/index.android.js.map +1 -0
  819. package/ui/switch/index.ios.d.ts +25 -0
  820. package/ui/switch/index.ios.js +135 -0
  821. package/ui/switch/index.ios.js.map +1 -0
  822. package/ui/switch/switch-common.d.ts +12 -0
  823. package/ui/switch/switch-common.js +37 -0
  824. package/ui/switch/switch-common.js.map +1 -0
  825. package/ui/tab-view/index.android.d.ts +73 -0
  826. package/ui/tab-view/index.android.js +648 -0
  827. package/ui/tab-view/index.android.js.map +1 -0
  828. package/ui/tab-view/index.ios.d.ts +72 -0
  829. package/ui/tab-view/index.ios.js +589 -0
  830. package/ui/tab-view/index.ios.js.map +1 -0
  831. package/ui/tab-view/tab-view-common.d.ts +71 -0
  832. package/ui/tab-view/tab-view-common.js +262 -0
  833. package/ui/tab-view/tab-view-common.js.map +1 -0
  834. package/ui/text-base/formatted-string.js +163 -0
  835. package/ui/text-base/formatted-string.js.map +1 -0
  836. package/ui/text-base/index.android.d.ts +78 -0
  837. package/ui/text-base/index.android.js +556 -0
  838. package/ui/text-base/index.android.js.map +1 -0
  839. package/ui/text-base/index.ios.d.ts +53 -0
  840. package/ui/text-base/index.ios.js +458 -0
  841. package/ui/text-base/index.ios.js.map +1 -0
  842. package/ui/text-base/span.js +113 -0
  843. package/ui/text-base/span.js.map +1 -0
  844. package/ui/text-base/text-base-common.d.ts +98 -0
  845. package/ui/text-base/text-base-common.js +323 -0
  846. package/ui/text-base/text-base-common.js.map +1 -0
  847. package/ui/text-field/index.android.d.ts +10 -0
  848. package/ui/text-field/index.android.js +92 -0
  849. package/ui/text-field/index.android.js.map +1 -0
  850. package/ui/text-field/index.ios.d.ts +55 -0
  851. package/ui/text-field/index.ios.js +311 -0
  852. package/ui/text-field/index.ios.js.map +1 -0
  853. package/ui/text-field/text-field-common.d.ts +11 -0
  854. package/ui/text-field/text-field-common.js +25 -0
  855. package/ui/text-field/text-field-common.js.map +1 -0
  856. package/ui/text-view/index.android.d.ts +8 -0
  857. package/ui/text-view/index.android.js +24 -0
  858. package/ui/text-view/index.android.js.map +1 -0
  859. package/ui/text-view/index.ios.d.ts +58 -0
  860. package/ui/text-view/index.ios.js +427 -0
  861. package/ui/text-view/index.ios.js.map +1 -0
  862. package/ui/text-view/text-view-common.d.ts +32 -0
  863. package/ui/text-view/text-view-common.js +39 -0
  864. package/ui/text-view/text-view-common.js.map +1 -0
  865. package/ui/time-picker/index.android.d.ts +10 -0
  866. package/ui/time-picker/index.android.js +81 -0
  867. package/ui/time-picker/index.android.js.map +1 -0
  868. package/ui/time-picker/index.ios.d.ts +31 -0
  869. package/ui/time-picker/index.ios.js +138 -0
  870. package/ui/time-picker/index.ios.js.map +1 -0
  871. package/ui/time-picker/time-picker-common.d.ts +31 -0
  872. package/ui/time-picker/time-picker-common.js +176 -0
  873. package/ui/time-picker/time-picker-common.js.map +1 -0
  874. package/ui/transition/fade-transition.android.d.ts +4 -0
  875. package/ui/transition/fade-transition.android.js +28 -0
  876. package/ui/transition/fade-transition.android.js.map +1 -0
  877. package/ui/transition/fade-transition.ios.d.ts +17 -0
  878. package/ui/transition/fade-transition.ios.js +65 -0
  879. package/ui/transition/fade-transition.ios.js.map +1 -0
  880. package/ui/transition/flip-transition.android.d.ts +6 -0
  881. package/ui/transition/flip-transition.android.js +90 -0
  882. package/ui/transition/flip-transition.android.js.map +1 -0
  883. package/ui/transition/index.android.d.ts +19 -0
  884. package/ui/transition/index.android.js +37 -0
  885. package/ui/transition/index.android.js.map +1 -0
  886. package/ui/transition/index.ios.d.ts +14 -0
  887. package/ui/transition/index.ios.js +30 -0
  888. package/ui/transition/index.ios.js.map +1 -0
  889. package/ui/transition/modal-transition.android.d.ts +5 -0
  890. package/ui/transition/modal-transition.android.js +7 -0
  891. package/ui/transition/modal-transition.android.js.map +1 -0
  892. package/ui/transition/modal-transition.ios.d.ts +34 -0
  893. package/ui/transition/modal-transition.ios.js +182 -0
  894. package/ui/transition/modal-transition.ios.js.map +1 -0
  895. package/ui/transition/page-transition.android.d.ts +9 -0
  896. package/ui/transition/page-transition.android.js +293 -0
  897. package/ui/transition/page-transition.android.js.map +1 -0
  898. package/ui/transition/page-transition.ios.d.ts +35 -0
  899. package/ui/transition/page-transition.ios.js +199 -0
  900. package/ui/transition/page-transition.ios.js.map +1 -0
  901. package/ui/transition/shared-transition-helper.android.d.ts +9 -0
  902. package/ui/transition/shared-transition-helper.android.js +10 -0
  903. package/ui/transition/shared-transition-helper.android.js.map +1 -0
  904. package/ui/transition/shared-transition-helper.ios.d.ts +14 -0
  905. package/ui/transition/shared-transition-helper.ios.js +539 -0
  906. package/ui/transition/shared-transition-helper.ios.js.map +1 -0
  907. package/ui/transition/shared-transition.d.ts +271 -0
  908. package/ui/transition/shared-transition.js +215 -0
  909. package/ui/transition/shared-transition.js.map +1 -0
  910. package/ui/transition/slide-transition.android.d.ts +7 -0
  911. package/ui/transition/slide-transition.android.js +116 -0
  912. package/ui/transition/slide-transition.android.js.map +1 -0
  913. package/ui/transition/slide-transition.ios.d.ts +19 -0
  914. package/ui/transition/slide-transition.ios.js +95 -0
  915. package/ui/transition/slide-transition.ios.js.map +1 -0
  916. package/ui/utils.android.d.ts +5 -0
  917. package/ui/utils.android.js +16 -0
  918. package/ui/utils.android.js.map +1 -0
  919. package/ui/utils.ios.d.ts +11 -0
  920. package/ui/utils.ios.js +66 -0
  921. package/ui/utils.ios.js.map +1 -0
  922. package/ui/web-view/index.android.d.ts +18 -0
  923. package/ui/web-view/index.android.js +177 -0
  924. package/ui/web-view/index.android.js.map +1 -0
  925. package/ui/web-view/index.ios.d.ts +27 -0
  926. package/ui/web-view/index.ios.js +246 -0
  927. package/ui/web-view/index.ios.js.map +1 -0
  928. package/ui/web-view/web-view-common.d.ts +30 -0
  929. package/ui/web-view/web-view-common.js +74 -0
  930. package/ui/web-view/web-view-common.js.map +1 -0
  931. package/ui/web-view/web-view-interfaces.d.ts +11 -0
  932. package/ui/web-view/web-view-interfaces.js +2 -0
  933. package/ui/web-view/web-view-interfaces.js.map +1 -0
  934. package/utils/animation-helpers.d.ts +27 -0
  935. package/utils/animation-helpers.js +48 -0
  936. package/utils/animation-helpers.js.map +1 -0
  937. package/utils/common.d.ts +26 -0
  938. package/utils/common.js +139 -0
  939. package/utils/common.js.map +1 -0
  940. package/utils/constants.android.d.ts +2 -0
  941. package/utils/constants.android.js +5 -0
  942. package/utils/constants.android.js.map +1 -0
  943. package/utils/constants.ios.d.ts +2 -0
  944. package/utils/constants.ios.js +5 -0
  945. package/utils/constants.ios.js.map +1 -0
  946. package/utils/debug-source.d.ts +19 -0
  947. package/utils/debug-source.js +78 -0
  948. package/utils/debug-source.js.map +1 -0
  949. package/utils/debug.js +3 -0
  950. package/utils/debug.js.map +1 -0
  951. package/utils/index.android.d.ts +26 -0
  952. package/utils/index.android.js +205 -0
  953. package/utils/index.android.js.map +1 -0
  954. package/utils/index.ios.d.ts +22 -0
  955. package/utils/index.ios.js +113 -0
  956. package/utils/index.ios.js.map +1 -0
  957. package/utils/layout-helper/index.android.d.ts +24 -0
  958. package/utils/layout-helper/index.android.js +77 -0
  959. package/utils/layout-helper/index.android.js.map +1 -0
  960. package/utils/layout-helper/index.ios.d.ts +24 -0
  961. package/utils/layout-helper/index.ios.js +64 -0
  962. package/utils/layout-helper/index.ios.js.map +1 -0
  963. package/utils/layout-helper/layout-helper-common.d.ts +5 -0
  964. package/utils/layout-helper/layout-helper-common.js +49 -0
  965. package/utils/layout-helper/layout-helper-common.js.map +1 -0
  966. package/utils/layout-helper/layout-helper-shared.d.ts +9 -0
  967. package/utils/layout-helper/layout-helper-shared.js +13 -0
  968. package/utils/layout-helper/layout-helper-shared.js.map +1 -0
  969. package/utils/lazy.js +5 -0
  970. package/utils/lazy.js.map +1 -0
  971. package/utils/macrotask-scheduler.js +26 -0
  972. package/utils/macrotask-scheduler.js.map +1 -0
  973. package/utils/mainthread-helper.android.d.ts +3 -0
  974. package/utils/mainthread-helper.android.js +28 -0
  975. package/utils/mainthread-helper.android.js.map +1 -0
  976. package/utils/mainthread-helper.ios.d.ts +3 -0
  977. package/utils/mainthread-helper.ios.js +17 -0
  978. package/utils/mainthread-helper.ios.js.map +1 -0
  979. package/utils/module-merge.d.ts +1 -0
  980. package/utils/module-merge.js +8 -0
  981. package/utils/module-merge.js.map +1 -0
  982. package/utils/native-helper-for-android.d.ts +34 -0
  983. package/utils/native-helper-for-android.js +373 -0
  984. package/utils/native-helper-for-android.js.map +1 -0
  985. package/utils/native-helper.android.d.ts +42 -0
  986. package/utils/native-helper.android.js +30 -0
  987. package/utils/native-helper.android.js.map +1 -0
  988. package/utils/native-helper.ios.d.ts +79 -0
  989. package/utils/native-helper.ios.js +339 -0
  990. package/utils/native-helper.ios.js.map +1 -0
  991. package/utils/number-utils.d.ts +19 -0
  992. package/utils/number-utils.js +37 -0
  993. package/utils/number-utils.js.map +1 -0
  994. package/utils/platform-check.d.ts +4 -0
  995. package/utils/platform-check.js +21 -0
  996. package/utils/platform-check.js.map +1 -0
  997. package/utils/shared.d.ts +17 -0
  998. package/utils/shared.js +40 -0
  999. package/utils/shared.js.map +1 -0
  1000. package/utils/types.js +104 -0
  1001. package/utils/types.js.map +1 -0
  1002. package/utils/utils-shared.d.ts +1 -0
  1003. package/utils/utils-shared.js +8 -0
  1004. package/utils/utils-shared.js.map +1 -0
  1005. package/wgc/atob.d.ts +1 -0
  1006. package/wgc/atob.js +9 -0
  1007. package/wgc/atob.js.map +1 -0
  1008. package/wgc/btoa.d.ts +1 -0
  1009. package/wgc/btoa.js +9 -0
  1010. package/wgc/btoa.js.map +1 -0
  1011. package/wgc/crypto/SubtleCrypto.d.ts +63 -0
  1012. package/wgc/crypto/SubtleCrypto.js +551 -0
  1013. package/wgc/crypto/SubtleCrypto.js.map +1 -0
  1014. package/wgc/crypto/index.d.ts +8 -0
  1015. package/wgc/crypto/index.js +32 -0
  1016. package/wgc/crypto/index.js.map +1 -0
  1017. package/wgc/index.d.ts +2 -0
  1018. package/wgc/index.js +3 -0
  1019. package/wgc/index.js.map +1 -0
  1020. package/xhr/index.d.ts +113 -0
  1021. package/xhr/index.js +486 -0
  1022. package/xhr/index.js.map +1 -0
  1023. package/xml/index.d.ts +108 -0
  1024. package/xml/index.js +574 -0
  1025. package/xml/index.js.map +1 -0
  1026. package/css/package.json +0 -36
  1027. package/css-value/package.json +0 -23
@@ -0,0 +1,1696 @@
1
+ import { getNativeScriptGlobals } from '../../../globals/global-utils';
2
+ import { ViewCommon, isEnabledProperty, originXProperty, originYProperty, isUserInteractionEnabledProperty, testIDProperty, AndroidHelper, statusBarStyleProperty } from './view-common';
3
+ import { paddingLeftProperty, paddingTopProperty, paddingRightProperty, paddingBottomProperty } from '../../styling/style-properties';
4
+ import { Length } from '../../styling/length-shared';
5
+ import { layout } from '../../../utils';
6
+ import { Trace } from '../../../trace';
7
+ import { hiddenProperty } from '../view-base';
8
+ import { isCssWideKeyword } from '../properties/property-shared';
9
+ import { perspectiveProperty, visibilityProperty, opacityProperty, horizontalAlignmentProperty, verticalAlignmentProperty, minWidthProperty, minHeightProperty, widthProperty, heightProperty, marginLeftProperty, marginTopProperty, marginRightProperty, marginBottomProperty, rotateProperty, rotateXProperty, rotateYProperty, scaleXProperty, scaleYProperty, translateXProperty, translateYProperty, zIndexProperty, backgroundInternalProperty, androidElevationProperty, androidDynamicElevationOffsetProperty } from '../../styling/style-properties';
10
+ import { Background, refreshBorderDrawable } from '../../styling/background';
11
+ import { profile } from '../../../profiling';
12
+ import { topmost } from '../../frame/frame-stack';
13
+ import { Screen } from '../../../platform';
14
+ import { isAppInBackground, updateA11yPropertiesCallback } from '../../../application/helpers-common';
15
+ import { updateContentDescription } from '../../../application/helpers';
16
+ import { accessibilityEnabledProperty, accessibilityHiddenProperty, accessibilityHintProperty, accessibilityIdentifierProperty, accessibilityLabelProperty, accessibilityLiveRegionProperty, accessibilityMediaSessionProperty, accessibilityRoleProperty, accessibilityStateProperty, accessibilityValueProperty } from '../../../accessibility/accessibility-properties';
17
+ import { AccessibilityLiveRegion, AccessibilityRole, AndroidAccessibilityEvent } from '../../../accessibility';
18
+ import * as Utils from '../../../utils';
19
+ import { SDK_VERSION } from '../../../utils/constants';
20
+ export * from './view-common';
21
+ // helpers (these are okay re-exported here)
22
+ export * from './view-helper';
23
+ // This one can eventually be cleaned up but causes issues with a lot of ui-suite plugins in particular if not exported here
24
+ export * from '../properties';
25
+ const DOMID = '_domId';
26
+ const androidBackPressedEvent = 'androidBackPressed';
27
+ const shortAnimTime = 17694720; // android.R.integer.config_shortAnimTime
28
+ const statePressed = 16842919; // android.R.attr.state_pressed
29
+ const stateEnabled = 16842910; // android.R.attr.state_enabled
30
+ const styleAnimationDialog = 16973826; // android.R.style.Animation_Dialog
31
+ const VERTICAL_GRAVITY_MASK = 112; // android.view.Gravity.VERTICAL_GRAVITY_MASK
32
+ const HORIZONTAL_GRAVITY_MASK = 7; // android.view.Gravity.HORIZONTAL_GRAVITY_MASK
33
+ const GRAVITY_LEFT = 3; // android.view.Gravity.LEFT
34
+ const GRAVITY_RIGHT = 5; // android.view.Gravity.RIGHT
35
+ const GRAVITY_TOP = 48; // android.view.Gravity.TOP
36
+ const GRAVITY_BOTTOM = 80; // android.view.Gravity.BOTTOM
37
+ const GRAVITY_CENTER_HORIZONTAL = 1; // android.view.Gravity.CENTER_HORIZONTAL
38
+ const GRAVITY_FILL_HORIZONTAL = 7; // android.view.Gravity.FILL_HORIZONTAL
39
+ const GRAVITY_CENTER_VERTICAL = 16; // android.view.Gravity.CENTER_VERTICAL
40
+ const GRAVITY_FILL_VERTICAL = 112; // android.view.Gravity.FILL_VERTICAL
41
+ const SYSTEM_UI_FLAG_LIGHT_STATUS_BAR = 0x00002000;
42
+ const STATUS_BAR_LIGHT_BCKG = -657931;
43
+ const STATUS_BAR_DARK_BCKG = 1711276032;
44
+ const modalMap = new Map();
45
+ let TouchListener;
46
+ let DialogFragment;
47
+ function initializeTouchListener() {
48
+ if (TouchListener) {
49
+ return;
50
+ }
51
+ var TouchListenerImpl = /** @class */ (function (_super) {
52
+ __extends(TouchListenerImpl, _super);
53
+ function TouchListenerImpl(owner) {
54
+ var _this = _super.call(this) || this;
55
+ _this.owner = new WeakRef(owner);
56
+ return global.__native(_this);
57
+ }
58
+ TouchListenerImpl.prototype.onTouch = function (view, event) {
59
+ var owner = this.owner.get();
60
+ if (!owner) {
61
+ return;
62
+ }
63
+ owner.handleGestureTouch(event);
64
+ var nativeView = owner.nativeViewProtected;
65
+ if (!nativeView || !nativeView.onTouchEvent) {
66
+ return false;
67
+ }
68
+ return nativeView.onTouchEvent(event);
69
+ };
70
+ var _a;
71
+ TouchListenerImpl = __decorate([
72
+ Interfaces([android.view.View.OnTouchListener]),
73
+ __metadata("design:paramtypes", [typeof (_a = typeof View !== "undefined" && View) === "function" ? _a : Object])
74
+ ], TouchListenerImpl);
75
+ return TouchListenerImpl;
76
+ }(java.lang.Object));
77
+ TouchListener = TouchListenerImpl;
78
+ }
79
+ function initializeDialogFragment() {
80
+ if (DialogFragment) {
81
+ return;
82
+ }
83
+ var DialogImpl = /** @class */ (function (_super) {
84
+ __extends(DialogImpl, _super);
85
+ function DialogImpl(fragment, context, themeResId) {
86
+ var _this = _super.call(this, context, themeResId) || this;
87
+ _this.fragment = fragment;
88
+ return global.__native(_this);
89
+ }
90
+ DialogImpl.prototype.onDetachedFromWindow = function () {
91
+ _super.prototype.onDetachedFromWindow.call(this);
92
+ this.fragment = null;
93
+ };
94
+ DialogImpl.prototype.onBackPressed = function () {
95
+ var view = this.fragment.owner;
96
+ var args = {
97
+ eventName: 'activityBackPressed',
98
+ object: view,
99
+ activity: view._context,
100
+ cancel: false,
101
+ };
102
+ // Fist fire application.android global event
103
+ getNativeScriptGlobals().events.notify(args);
104
+ if (args.cancel) {
105
+ return;
106
+ }
107
+ view.notify(args);
108
+ if (!args.cancel && !view.onBackPressed()) {
109
+ _super.prototype.onBackPressed.call(this);
110
+ }
111
+ };
112
+ return DialogImpl;
113
+ }(android.app.Dialog));
114
+ var DialogFragmentImpl = /** @class */ (function (_super) {
115
+ __extends(DialogFragmentImpl, _super);
116
+ function DialogFragmentImpl() {
117
+ var _this = _super.call(this) || this;
118
+ return global.__native(_this);
119
+ }
120
+ DialogFragmentImpl.prototype.onCreate = function (savedInstanceState) {
121
+ var _a;
122
+ _super.prototype.onCreate.call(this, savedInstanceState);
123
+ var ownerId = (_a = this.getArguments()) === null || _a === void 0 ? void 0 : _a.getInt(DOMID);
124
+ var options = getModalOptions(ownerId);
125
+ // The teardown when the activity is destroyed happens after the state is saved, but is not recoverable,
126
+ // Cancel the native dialog in this case or the app will crash with subsequent errors.
127
+ if (savedInstanceState != null && options === undefined) {
128
+ this.dismissAllowingStateLoss();
129
+ }
130
+ };
131
+ DialogFragmentImpl.prototype.onCreateDialog = function (savedInstanceState) {
132
+ var ownerId = this.getArguments().getInt(DOMID);
133
+ var options = getModalOptions(ownerId);
134
+ this.owner = options.owner;
135
+ // Set owner._dialogFragment to this in case the DialogFragment was recreated after app suspend
136
+ this.owner._dialogFragment = this;
137
+ this._fullscreen = options.fullscreen;
138
+ this._animated = options.animated;
139
+ this._cancelable = options.cancelable;
140
+ this._stretched = options.stretched;
141
+ this._dismissCallback = options.dismissCallback;
142
+ this._shownCallback = options.shownCallback;
143
+ this._windowSoftInputMode = options.windowSoftInputMode;
144
+ this.setStyle(androidx.fragment.app.DialogFragment.STYLE_NO_TITLE, 0);
145
+ var theme = this.getTheme();
146
+ if (this._fullscreen) {
147
+ // In fullscreen mode, get the application's theme.
148
+ theme = this.getActivity().getApplicationInfo().theme;
149
+ }
150
+ var dialog = new DialogImpl(this, this.getActivity(), theme);
151
+ // do not override alignment unless fullscreen modal will be shown;
152
+ // otherwise we might break component-level layout:
153
+ // https://github.com/NativeScript/NativeScript/issues/5392
154
+ if (!this._fullscreen && !this._stretched) {
155
+ this.owner.horizontalAlignment = 'center';
156
+ this.owner.verticalAlignment = 'middle';
157
+ }
158
+ else {
159
+ this.owner.horizontalAlignment = 'stretch';
160
+ this.owner.verticalAlignment = 'stretch';
161
+ }
162
+ // set the modal window animation
163
+ // https://github.com/NativeScript/NativeScript/issues/5989
164
+ if (this._animated) {
165
+ dialog.getWindow().setWindowAnimations(styleAnimationDialog);
166
+ }
167
+ dialog.setCanceledOnTouchOutside(this._cancelable);
168
+ return dialog;
169
+ };
170
+ DialogFragmentImpl.prototype.onCreateView = function (inflater, container, savedInstanceState) {
171
+ var owner = this.owner;
172
+ this.activity = new WeakRef(this.getActivity());
173
+ owner._setupAsRootView(this.getActivity());
174
+ owner._isAddedToNativeVisualTree = true;
175
+ // we need to set the window SoftInputMode here.
176
+ // it wont work is set in onStart
177
+ var window = this.getDialog().getWindow();
178
+ if (this._windowSoftInputMode !== undefined) {
179
+ window.setSoftInputMode(this._windowSoftInputMode);
180
+ }
181
+ else {
182
+ // the dialog seems to not follow the default activity softInputMode,
183
+ // thus set we set it here.
184
+ window.setSoftInputMode(owner._context.getWindow().getAttributes().softInputMode);
185
+ }
186
+ return owner.nativeViewProtected;
187
+ };
188
+ DialogFragmentImpl.prototype.onStart = function () {
189
+ _super.prototype.onStart.call(this);
190
+ if (this._fullscreen) {
191
+ var window = this.getDialog().getWindow();
192
+ var length = android.view.ViewGroup.LayoutParams.MATCH_PARENT;
193
+ window.setLayout(length, length);
194
+ // This removes the default backgroundDrawable so there are no margins.
195
+ window.setBackgroundDrawable(new android.graphics.drawable.ColorDrawable(android.graphics.Color.WHITE));
196
+ }
197
+ var owner = this.owner;
198
+ if (owner && !owner.isLoaded) {
199
+ owner.callLoaded();
200
+ }
201
+ this._shownCallback();
202
+ };
203
+ DialogFragmentImpl.prototype.onDismiss = function (dialog) {
204
+ var _a;
205
+ _super.prototype.onDismiss.call(this, dialog);
206
+ var manager = this.getFragmentManager();
207
+ var activity = (_a = this.activity) === null || _a === void 0 ? void 0 : _a.get();
208
+ if (manager && !(activity === null || activity === void 0 ? void 0 : activity.isChangingConfigurations())) {
209
+ removeModal(this.owner._domId);
210
+ this._dismissCallback();
211
+ }
212
+ var owner = this.owner;
213
+ if (owner && owner.isLoaded) {
214
+ owner.callUnloaded();
215
+ }
216
+ };
217
+ DialogFragmentImpl.prototype.onDestroy = function () {
218
+ var _a;
219
+ _super.prototype.onDestroy.call(this);
220
+ var owner = this.owner;
221
+ var activity = (_a = this.activity) === null || _a === void 0 ? void 0 : _a.get();
222
+ if (!(activity === null || activity === void 0 ? void 0 : activity.isChangingConfigurations())) {
223
+ this.activity = null;
224
+ }
225
+ if (owner) {
226
+ // Android calls onDestroy before onDismiss.
227
+ // Make sure we unload first and then call _tearDownUI.
228
+ if (owner.isLoaded) {
229
+ owner.callUnloaded();
230
+ }
231
+ owner._isAddedToNativeVisualTree = false;
232
+ owner._tearDownUI(true);
233
+ }
234
+ };
235
+ return DialogFragmentImpl;
236
+ }(androidx.fragment.app.DialogFragment));
237
+ DialogFragment = DialogFragmentImpl;
238
+ }
239
+ function saveModal(options) {
240
+ modalMap.set(options.owner._domId, options);
241
+ }
242
+ function removeModal(domId) {
243
+ modalMap.delete(domId);
244
+ }
245
+ function getModalOptions(domId) {
246
+ return modalMap.get(domId);
247
+ }
248
+ const INSET_LEFT = 0;
249
+ const INSET_TOP = 4;
250
+ const INSET_RIGHT = 8;
251
+ const INSET_BOTTOM = 12;
252
+ const INSET_LEFT_CONSUMED = 16;
253
+ const INSET_TOP_CONSUMED = 20;
254
+ const INSET_RIGHT_CONSUMED = 24;
255
+ const INSET_BOTTOM_CONSUMED = 28;
256
+ const OverflowEdgeNone = 0;
257
+ const OverflowEdgeLeft = 1;
258
+ const OverflowEdgeTop = 1 << 1;
259
+ const OverflowEdgeRight = 1 << 2;
260
+ const OverflowEdgeBottom = 1 << 3;
261
+ const OverflowEdgeDontApply = 1 << 4;
262
+ const OverflowEdgeLeftDontConsume = 1 << 5;
263
+ const OverflowEdgeTopDontConsume = 1 << 6;
264
+ const OverflowEdgeRightDontConsume = 1 << 7;
265
+ const OverflowEdgeBottomDontConsume = 1 << 8;
266
+ const OverflowEdgeAllButLeft = 1 << 9;
267
+ const OverflowEdgeAllButTop = 1 << 10;
268
+ const OverflowEdgeAllButRight = 1 << 11;
269
+ const OverflowEdgeAllButBottom = 1 << 12;
270
+ class Inset {
271
+ constructor(data) {
272
+ this.data = ArrayBuffer.from(data);
273
+ this.view = new DataView(this.data);
274
+ }
275
+ get left() {
276
+ return this.view.getInt32(INSET_LEFT, true);
277
+ }
278
+ set left(value) {
279
+ this.view.setInt32(INSET_LEFT, value, true);
280
+ }
281
+ get top() {
282
+ return this.view.getInt32(INSET_TOP, true);
283
+ }
284
+ set top(value) {
285
+ this.view.setInt32(INSET_TOP, value, true);
286
+ }
287
+ get right() {
288
+ return this.view.getInt32(INSET_RIGHT, true);
289
+ }
290
+ set right(value) {
291
+ this.view.setInt32(INSET_RIGHT, value, true);
292
+ }
293
+ get bottom() {
294
+ return this.view.getInt32(INSET_BOTTOM, true);
295
+ }
296
+ set bottom(value) {
297
+ this.view.setInt32(INSET_BOTTOM, value, true);
298
+ }
299
+ get leftConsumed() {
300
+ return this.view.getInt32(INSET_LEFT_CONSUMED, true) > 0;
301
+ }
302
+ set leftConsumed(value) {
303
+ this.view.setInt32(INSET_LEFT_CONSUMED, value ? 1 : 0, true);
304
+ }
305
+ get topConsumed() {
306
+ return this.view.getInt32(INSET_TOP_CONSUMED, true) > 0;
307
+ }
308
+ set topConsumed(value) {
309
+ this.view.setInt32(INSET_TOP_CONSUMED, value ? 1 : 0, true);
310
+ }
311
+ get rightConsumed() {
312
+ return this.view.getInt32(INSET_RIGHT_CONSUMED, true) > 0;
313
+ }
314
+ set rightConsumed(value) {
315
+ this.view.setInt32(INSET_RIGHT_CONSUMED, value ? 1 : 0, true);
316
+ }
317
+ get bottomConsumed() {
318
+ return this.view.getInt32(INSET_BOTTOM_CONSUMED, true) > 0;
319
+ }
320
+ set bottomConsumed(value) {
321
+ this.view.setInt32(INSET_BOTTOM_CONSUMED, value ? 1 : 0, true);
322
+ }
323
+ toString() {
324
+ return `Inset: left=${this.left}, top=${this.top}, right=${this.right}, bottom=${this.bottom}, ` + `leftConsumed=${this.leftConsumed}, topConsumed=${this.topConsumed}, ` + `rightConsumed=${this.rightConsumed}, bottomConsumed=${this.bottomConsumed}`;
325
+ }
326
+ toJSON() {
327
+ return {
328
+ left: this.left,
329
+ top: this.top,
330
+ right: this.right,
331
+ bottom: this.bottom,
332
+ leftConsumed: this.leftConsumed,
333
+ topConsumed: this.topConsumed,
334
+ rightConsumed: this.rightConsumed,
335
+ bottomConsumed: this.bottomConsumed,
336
+ };
337
+ }
338
+ }
339
+ export class View extends ViewCommon {
340
+ constructor() {
341
+ super(...arguments);
342
+ this._defaultOverflowEdge = OverflowEdgeNone;
343
+ this._defaultOverflowEdgeValue = 'none';
344
+ }
345
+ // TODO: Implement unobserve that detach the touchListener.
346
+ _observe(type, callback, thisArg) {
347
+ super._observe(type, callback, thisArg);
348
+ if (this.isLoaded && !this.touchListenerIsSet) {
349
+ this.setOnTouchListener();
350
+ }
351
+ }
352
+ addEventListener(eventNames, callback, thisArg, once) {
353
+ super.addEventListener(eventNames, callback, thisArg, once);
354
+ const isLayoutEvent = typeof eventNames === 'string' ? eventNames.indexOf(ViewCommon.layoutChangedEvent) !== -1 : false;
355
+ if (this.isLoaded && !this.layoutChangeListenerIsSet && isLayoutEvent) {
356
+ this.setOnLayoutChangeListener();
357
+ }
358
+ const isInsetEvent = typeof eventNames === 'string' ? eventNames.indexOf(ViewCommon.androidOverflowInsetEvent) !== -1 : false;
359
+ // only avaiable on LayoutBase
360
+ if (!this.insetListenerIsSet && isInsetEvent) {
361
+ this.setInsetListener();
362
+ }
363
+ }
364
+ removeEventListener(eventNames, callback, thisArg) {
365
+ super.removeEventListener(eventNames, callback, thisArg);
366
+ const isLayoutEvent = typeof eventNames === 'string' ? eventNames.indexOf(ViewCommon.layoutChangedEvent) !== -1 : false;
367
+ // Remove native listener only if there are no more user listeners for LayoutChanged event
368
+ if (this.isLoaded && this.layoutChangeListenerIsSet && isLayoutEvent && !this.needsOnLayoutChangeListener()) {
369
+ this.nativeViewProtected.removeOnLayoutChangeListener(this.layoutChangeListener);
370
+ this.layoutChangeListenerIsSet = false;
371
+ }
372
+ const isInsetEvent = typeof eventNames === 'string' ? eventNames.indexOf(ViewCommon.androidOverflowInsetEvent) !== -1 : false;
373
+ if (this.insetListenerIsSet && isInsetEvent && this.nativeViewProtected && this.nativeViewProtected.setInsetListener) {
374
+ this.nativeViewProtected.setInsetListener(null);
375
+ this.insetListenerIsSet = false;
376
+ }
377
+ }
378
+ setInsetListener() {
379
+ if (this.nativeViewProtected) {
380
+ if (this.nativeViewProtected.setInsetListener) {
381
+ const ref = new WeakRef(this);
382
+ this.nativeViewProtected.setInsetListener(new org.nativescript.widgets.LayoutBase.WindowInsetListener({
383
+ onApplyWindowInsets(param0) {
384
+ const owner = ref.get();
385
+ if (!owner) {
386
+ return;
387
+ }
388
+ const inset = new Inset(param0);
389
+ const args = {
390
+ eventName: ViewCommon.androidOverflowInsetEvent,
391
+ object: this,
392
+ inset,
393
+ };
394
+ owner.notify(args);
395
+ },
396
+ }));
397
+ this.insetListenerIsSet = true;
398
+ }
399
+ this.needsInsetListener = false;
400
+ }
401
+ else {
402
+ this.needsInsetListener = true;
403
+ }
404
+ }
405
+ _getChildFragmentManager() {
406
+ return null;
407
+ }
408
+ _getRootFragmentManager() {
409
+ if (!this._rootManager && this._context) {
410
+ this._rootManager = this._context.getSupportFragmentManager();
411
+ }
412
+ return this._rootManager;
413
+ }
414
+ _getFragmentManager() {
415
+ let manager = this._manager;
416
+ if (!manager) {
417
+ let view = this;
418
+ let frameOrTabViewItemFound = false;
419
+ while (view) {
420
+ // when interacting with nested fragments instead of using getSupportFragmentManager
421
+ // we must always use getChildFragmentManager instead;
422
+ // we have three sources of fragments -- Frame fragments, TabViewItem fragments, and
423
+ // modal dialog fragments
424
+ // modal -> frame / tabview (frame / tabview use modal CHILD fm)
425
+ const dialogFragment = view._dialogFragment;
426
+ if (dialogFragment) {
427
+ manager = dialogFragment.getChildFragmentManager();
428
+ break;
429
+ }
430
+ // - frame1 -> frame2 (frame2 uses frame1 CHILD fm)
431
+ // - tabview -> frame1 (frame1 uses tabview item CHILD fm)
432
+ // - frame1 -> tabview (tabview uses frame1 CHILD fm)
433
+ // - frame1 -> tabview -> frame2 (tabview uses frame1 CHILD fm; frame2 uses tabview item CHILD fm)
434
+ if (view._hasFragments) {
435
+ if (frameOrTabViewItemFound) {
436
+ manager = view._getChildFragmentManager();
437
+ break;
438
+ }
439
+ frameOrTabViewItemFound = true;
440
+ }
441
+ // the case is needed because _dialogFragment is on View
442
+ // but parent may be ViewBase.
443
+ view = view.parent;
444
+ }
445
+ if (!manager) {
446
+ manager = this._getRootFragmentManager();
447
+ }
448
+ this._manager = manager;
449
+ }
450
+ return manager;
451
+ }
452
+ // @ts-ignore
453
+ set androidOverflowEdge(value) {
454
+ if (typeof value !== 'string') {
455
+ return;
456
+ }
457
+ const nativeView = this.nativeViewProtected;
458
+ if (nativeView && nativeView.setOverflowEdge) {
459
+ if (value === 'none') {
460
+ nativeView.setOverflowEdge(OverflowEdgeNone);
461
+ }
462
+ else {
463
+ const newValue = parseEdges(value);
464
+ if (newValue !== null) {
465
+ nativeView.setOverflowEdge(newValue);
466
+ }
467
+ }
468
+ }
469
+ else {
470
+ const edge = parseEdges(value);
471
+ if (edge === null) {
472
+ return;
473
+ }
474
+ this._defaultOverflowEdgeValue = value;
475
+ this._defaultOverflowEdge = edge;
476
+ }
477
+ }
478
+ get androidOverflowEdge() {
479
+ const nativeView = this.nativeViewProtected;
480
+ if (nativeView && nativeView.getOverflowEdge) {
481
+ const overflowEdge = nativeView.getOverflowEdge();
482
+ switch (overflowEdge) {
483
+ case OverflowEdgeNone:
484
+ return 'none';
485
+ case OverflowEdgeLeft:
486
+ return 'left';
487
+ case OverflowEdgeTop:
488
+ return 'top';
489
+ case OverflowEdgeRight:
490
+ return 'right';
491
+ case OverflowEdgeBottom:
492
+ return 'bottom';
493
+ case OverflowEdgeDontApply:
494
+ return 'dont-apply';
495
+ case OverflowEdgeLeftDontConsume:
496
+ return 'left-dont-consume';
497
+ case OverflowEdgeTopDontConsume:
498
+ return 'top-dont-consume';
499
+ case OverflowEdgeRightDontConsume:
500
+ return 'right-dont-consume';
501
+ case OverflowEdgeBottomDontConsume:
502
+ return 'bottom-dont-consume';
503
+ case OverflowEdgeAllButLeft:
504
+ return 'all-but-left';
505
+ case OverflowEdgeAllButTop:
506
+ return 'all-but-top';
507
+ case OverflowEdgeAllButRight:
508
+ return 'all-but-right';
509
+ case OverflowEdgeAllButBottom:
510
+ return 'all-but-bottom';
511
+ default:
512
+ {
513
+ let value = '';
514
+ const overflowLeftConsume = (overflowEdge & OverflowEdgeLeft) == OverflowEdgeLeft;
515
+ const overflowTopConsume = (overflowEdge & OverflowEdgeTop) == OverflowEdgeTop;
516
+ const overflowRightConsume = (overflowEdge & OverflowEdgeRight) == OverflowEdgeRight;
517
+ const overflowBottomConsume = (overflowEdge & OverflowEdgeBottom) == OverflowEdgeBottom;
518
+ const overflowLeft = (overflowEdge & OverflowEdgeLeftDontConsume) == OverflowEdgeLeftDontConsume;
519
+ const overflowTop = (overflowEdge & OverflowEdgeTopDontConsume) == OverflowEdgeTopDontConsume;
520
+ const overflowRight = (overflowEdge & OverflowEdgeRightDontConsume) == OverflowEdgeRightDontConsume;
521
+ const overflowBottom = (overflowEdge & OverflowEdgeBottomDontConsume) == OverflowEdgeBottomDontConsume;
522
+ if (overflowLeftConsume) {
523
+ value += 'left';
524
+ }
525
+ if (overflowTopConsume) {
526
+ if (value.length > 0) {
527
+ value += ',';
528
+ }
529
+ value += 'top';
530
+ }
531
+ if (overflowRightConsume) {
532
+ if (value.length > 0) {
533
+ value += ',';
534
+ }
535
+ value += 'right';
536
+ }
537
+ if (overflowBottomConsume) {
538
+ if (value.length > 0) {
539
+ value += ',';
540
+ }
541
+ value += 'bottom';
542
+ }
543
+ if (overflowLeft) {
544
+ value += 'left-dont-consume';
545
+ }
546
+ if (overflowTop) {
547
+ if (value.length > 0) {
548
+ value += ',';
549
+ }
550
+ value += 'top-dont-consume';
551
+ }
552
+ if (overflowRight) {
553
+ if (value.length > 0) {
554
+ value += ',';
555
+ }
556
+ value += 'right-dont-consume';
557
+ }
558
+ if (overflowBottom) {
559
+ if (value.length > 0) {
560
+ value += ',';
561
+ }
562
+ value += 'bottom-dont-consume';
563
+ }
564
+ }
565
+ break;
566
+ }
567
+ }
568
+ else {
569
+ if (this._defaultOverflowEdgeValue) {
570
+ return this._defaultOverflowEdgeValue;
571
+ }
572
+ }
573
+ return 'none';
574
+ }
575
+ onLoaded() {
576
+ this._manager = null;
577
+ this._rootManager = null;
578
+ super.onLoaded();
579
+ this.setOnTouchListener();
580
+ }
581
+ onUnloaded() {
582
+ this._manager = null;
583
+ this._rootManager = null;
584
+ super.onUnloaded();
585
+ }
586
+ onBackPressed() {
587
+ const topmostFrame = topmost();
588
+ // Delegate back navigation handling to the topmost Frame
589
+ // when it's a child of the current View.
590
+ if (topmostFrame && topmostFrame._hasAncestorView(this)) {
591
+ return topmostFrame.onBackPressed();
592
+ }
593
+ return false;
594
+ }
595
+ handleGestureTouch(event) {
596
+ for (const type in this._gestureObservers) {
597
+ const list = this._gestureObservers[type];
598
+ list.forEach((element) => {
599
+ element.androidOnTouchEvent(event);
600
+ });
601
+ }
602
+ if (this.parent instanceof View) {
603
+ this.parent.handleGestureTouch(event);
604
+ }
605
+ }
606
+ hasGestureObservers() {
607
+ return this._gestureObservers && Object.keys(this._gestureObservers).length > 0;
608
+ }
609
+ initNativeView() {
610
+ super.initNativeView();
611
+ if (this.needsOnLayoutChangeListener()) {
612
+ this.setOnLayoutChangeListener();
613
+ }
614
+ if (!this.insetListenerIsSet && this.needsInsetListener) {
615
+ this.setInsetListener();
616
+ }
617
+ const nativeView = this.nativeViewProtected;
618
+ if (typeof this._defaultOverflowEdge === 'number') {
619
+ if (nativeView && nativeView.setOverflowEdge) {
620
+ nativeView.setOverflowEdge(this._defaultOverflowEdge);
621
+ }
622
+ }
623
+ }
624
+ needsOnLayoutChangeListener() {
625
+ return this.hasListeners(ViewCommon.layoutChangedEvent);
626
+ }
627
+ disposeNativeView() {
628
+ if (this.touchListenerIsSet) {
629
+ this.touchListenerIsSet = false;
630
+ if (this.nativeViewProtected) {
631
+ this.nativeViewProtected.setOnTouchListener(null);
632
+ }
633
+ }
634
+ if (this.layoutChangeListenerIsSet) {
635
+ this.layoutChangeListenerIsSet = false;
636
+ if (this.nativeViewProtected) {
637
+ this.nativeViewProtected.removeOnLayoutChangeListener(this.layoutChangeListener);
638
+ this.layoutChangeListener = null;
639
+ }
640
+ }
641
+ super.disposeNativeView();
642
+ }
643
+ setOnTouchListener() {
644
+ if (this.touchListenerIsSet || !this.nativeViewProtected || !this.hasGestureObservers()) {
645
+ return;
646
+ }
647
+ // do not set noop listener that handles the event (disabled listener) if IsUserInteractionEnabled is
648
+ // false as we might need the ability for the event to pass through to a parent view
649
+ initializeTouchListener();
650
+ this.touchListener = this.touchListener || new TouchListener(this);
651
+ this.nativeViewProtected.setOnTouchListener(this.touchListener);
652
+ this.touchListenerIsSet = true;
653
+ if (this.nativeViewProtected.setClickable) {
654
+ this.nativeViewProtected.setClickable(this.isUserInteractionEnabled);
655
+ }
656
+ }
657
+ setOnLayoutChangeListener() {
658
+ if (this.nativeViewProtected) {
659
+ const owner = this;
660
+ this.layoutChangeListenerIsSet = true;
661
+ this.layoutChangeListener =
662
+ this.layoutChangeListener ||
663
+ new android.view.View.OnLayoutChangeListener({
664
+ onLayoutChange(v, left, top, right, bottom, oldLeft, oldTop, oldRight, oldBottom) {
665
+ if (left !== oldLeft || top !== oldTop || right !== oldRight || bottom !== oldBottom) {
666
+ owner._raiseLayoutChangedEvent();
667
+ }
668
+ },
669
+ });
670
+ this.nativeViewProtected.addOnLayoutChangeListener(this.layoutChangeListener);
671
+ }
672
+ }
673
+ get isLayoutRequired() {
674
+ return !this.isLayoutValid;
675
+ }
676
+ get isLayoutValid() {
677
+ if (this.nativeViewProtected) {
678
+ return !this.nativeViewProtected.isLayoutRequested();
679
+ }
680
+ return false;
681
+ }
682
+ get _hasFragments() {
683
+ return false;
684
+ }
685
+ layoutNativeView(left, top, right, bottom) {
686
+ if (this.nativeViewProtected) {
687
+ this.nativeViewProtected.layout(left, top, right, bottom);
688
+ }
689
+ }
690
+ requestLayout() {
691
+ super.requestLayout();
692
+ if (this.nativeViewProtected) {
693
+ this.nativeViewProtected.requestLayout();
694
+ }
695
+ }
696
+ measure(widthMeasureSpec, heightMeasureSpec) {
697
+ super.measure(widthMeasureSpec, heightMeasureSpec);
698
+ this.onMeasure(widthMeasureSpec, heightMeasureSpec);
699
+ }
700
+ layout(left, top, right, bottom) {
701
+ super.layout(left, top, right, bottom);
702
+ this.onLayout(left, top, right, bottom);
703
+ }
704
+ onMeasure(widthMeasureSpec, heightMeasureSpec) {
705
+ const view = this.nativeViewProtected;
706
+ if (view) {
707
+ view.measure(widthMeasureSpec, heightMeasureSpec);
708
+ this.setMeasuredDimension(view.getMeasuredWidth(), view.getMeasuredHeight());
709
+ }
710
+ }
711
+ onLayout(left, top, right, bottom) {
712
+ const view = this.nativeViewProtected;
713
+ if (view) {
714
+ this.layoutNativeView(left, top, right, bottom);
715
+ }
716
+ }
717
+ _getCurrentLayoutBounds() {
718
+ if (this.nativeViewProtected && !this.isCollapsed) {
719
+ return {
720
+ left: this.nativeViewProtected.getLeft(),
721
+ top: this.nativeViewProtected.getTop(),
722
+ right: this.nativeViewProtected.getRight(),
723
+ bottom: this.nativeViewProtected.getBottom(),
724
+ };
725
+ }
726
+ else {
727
+ return { left: 0, top: 0, right: 0, bottom: 0 };
728
+ }
729
+ }
730
+ getMeasuredWidth() {
731
+ if (this.nativeViewProtected) {
732
+ return this.nativeViewProtected.getMeasuredWidth();
733
+ }
734
+ return super.getMeasuredWidth();
735
+ }
736
+ getMeasuredHeight() {
737
+ if (this.nativeViewProtected) {
738
+ return this.nativeViewProtected.getMeasuredHeight();
739
+ }
740
+ return super.getMeasuredHeight();
741
+ }
742
+ focus() {
743
+ if (this.nativeViewProtected) {
744
+ return this.nativeViewProtected.requestFocus();
745
+ }
746
+ return false;
747
+ }
748
+ getLocationInWindow() {
749
+ if (!this.nativeViewProtected || !this.nativeViewProtected.getWindowToken()) {
750
+ return undefined;
751
+ }
752
+ const nativeArray = Array.create('int', 2);
753
+ this.nativeViewProtected.getLocationInWindow(nativeArray);
754
+ return {
755
+ x: layout.toDeviceIndependentPixels(nativeArray[0]),
756
+ y: layout.toDeviceIndependentPixels(nativeArray[1]),
757
+ };
758
+ }
759
+ getLocationOnScreen() {
760
+ if (!this.nativeViewProtected || !this.nativeViewProtected.getWindowToken()) {
761
+ return undefined;
762
+ }
763
+ const nativeArray = Array.create('int', 2);
764
+ this.nativeViewProtected.getLocationOnScreen(nativeArray);
765
+ return {
766
+ x: layout.toDeviceIndependentPixels(nativeArray[0]),
767
+ y: layout.toDeviceIndependentPixels(nativeArray[1]),
768
+ };
769
+ }
770
+ getLocationRelativeTo(otherView) {
771
+ if (!this.nativeViewProtected || !this.nativeViewProtected.getWindowToken() || !otherView || !otherView.nativeViewProtected || !otherView.nativeViewProtected.getWindowToken() || this.nativeViewProtected.getWindowToken() !== otherView.nativeViewProtected.getWindowToken()) {
772
+ return undefined;
773
+ }
774
+ const myArray = Array.create('int', 2);
775
+ this.nativeViewProtected.getLocationOnScreen(myArray);
776
+ const otherArray = Array.create('int', 2);
777
+ otherView.nativeViewProtected.getLocationOnScreen(otherArray);
778
+ return {
779
+ x: layout.toDeviceIndependentPixels(myArray[0] - otherArray[0]),
780
+ y: layout.toDeviceIndependentPixels(myArray[1] - otherArray[1]),
781
+ };
782
+ }
783
+ static resolveSizeAndState(size, specSize, specMode, childMeasuredState) {
784
+ let result = size;
785
+ switch (specMode) {
786
+ case layout.UNSPECIFIED:
787
+ result = size;
788
+ break;
789
+ case layout.AT_MOST:
790
+ if (specSize < size) {
791
+ result = specSize | layout.MEASURED_STATE_TOO_SMALL;
792
+ }
793
+ break;
794
+ case layout.EXACTLY:
795
+ result = specSize;
796
+ break;
797
+ }
798
+ return result | (childMeasuredState & layout.MEASURED_STATE_MASK);
799
+ }
800
+ _showNativeModalView(parent, options) {
801
+ // if the app is in background while triggering _showNativeModalView
802
+ // then DialogFragment.show will trigger IllegalStateException: Can not perform this action after onSaveInstanceState
803
+ // so if in background we create an event to call _showNativeModalView when loaded (going back in foreground)
804
+ if (isAppInBackground() && !parent.isLoaded) {
805
+ const onLoaded = () => {
806
+ parent.off('loaded', onLoaded);
807
+ this._showNativeModalView(parent, options);
808
+ };
809
+ parent.on('loaded', onLoaded);
810
+ return;
811
+ }
812
+ super._showNativeModalView(parent, options);
813
+ initializeDialogFragment();
814
+ const df = new DialogFragment();
815
+ const args = new android.os.Bundle();
816
+ args.putInt(DOMID, this._domId);
817
+ df.setArguments(args);
818
+ let cancelable = true;
819
+ let windowSoftInputMode;
820
+ if (options.android) {
821
+ if (options.android.cancelable !== undefined) {
822
+ cancelable = !!options.android.cancelable;
823
+ console.log('ShowModalOptions.android.cancelable is deprecated. Use ShowModalOptions.cancelable instead.');
824
+ }
825
+ windowSoftInputMode = options.android.windowSoftInputMode;
826
+ }
827
+ cancelable = options.cancelable !== undefined ? !!options.cancelable : cancelable;
828
+ const dialogOptions = {
829
+ owner: this,
830
+ fullscreen: !!options.fullscreen,
831
+ animated: !!options.animated,
832
+ stretched: !!options.stretched,
833
+ cancelable: cancelable,
834
+ windowSoftInputMode: windowSoftInputMode,
835
+ shownCallback: () => this._raiseShownModallyEvent(),
836
+ dismissCallback: () => this.closeModal(),
837
+ };
838
+ saveModal(dialogOptions);
839
+ this._dialogFragment = df;
840
+ this._raiseShowingModallyEvent();
841
+ this._dialogFragment.show(parent._getRootFragmentManager(), this._domId.toString());
842
+ }
843
+ _hideNativeModalView(parent, whenClosedCallback) {
844
+ if (this._dialogFragment) {
845
+ const manager = this._dialogFragment.getFragmentManager();
846
+ if (manager) {
847
+ this._dialogFragment.dismissAllowingStateLoss();
848
+ }
849
+ }
850
+ this._dialogFragment = null;
851
+ whenClosedCallback();
852
+ }
853
+ [isEnabledProperty.setNative](value) {
854
+ this.nativeViewProtected.setEnabled(value);
855
+ }
856
+ [originXProperty.getDefault]() {
857
+ return this.nativeViewProtected.getPivotX();
858
+ }
859
+ [originXProperty.setNative](value) {
860
+ org.nativescript.widgets.OriginPoint.setX(this.nativeViewProtected, value);
861
+ }
862
+ [originYProperty.getDefault]() {
863
+ return this.nativeViewProtected.getPivotY();
864
+ }
865
+ [originYProperty.setNative](value) {
866
+ org.nativescript.widgets.OriginPoint.setY(this.nativeViewProtected, value);
867
+ }
868
+ [isUserInteractionEnabledProperty.setNative](value) {
869
+ this.nativeViewProtected.setClickable(value);
870
+ this.nativeViewProtected.setFocusable(value);
871
+ }
872
+ [hiddenProperty.getDefault]() {
873
+ return this.nativeViewProtected.getVisibility() === android.view.View.GONE;
874
+ }
875
+ [hiddenProperty.setNative](value) {
876
+ this.nativeViewProtected.setVisibility(value ? android.view.View.GONE : android.view.View.VISIBLE);
877
+ }
878
+ [visibilityProperty.getDefault]() {
879
+ const nativeVisibility = this.nativeViewProtected.getVisibility();
880
+ switch (nativeVisibility) {
881
+ case android.view.View.VISIBLE:
882
+ return 'visible';
883
+ case android.view.View.INVISIBLE:
884
+ return 'hidden';
885
+ case android.view.View.GONE:
886
+ return 'collapse';
887
+ default:
888
+ throw new Error(`Unsupported android.view.View visibility: ${nativeVisibility}. Currently supported values are android.view.View.VISIBLE, android.view.View.INVISIBLE, android.view.View.GONE.`);
889
+ }
890
+ }
891
+ [visibilityProperty.setNative](value) {
892
+ switch (value) {
893
+ case 'visible':
894
+ this.nativeViewProtected.setVisibility(android.view.View.VISIBLE);
895
+ break;
896
+ case 'hidden':
897
+ this.nativeViewProtected.setVisibility(android.view.View.INVISIBLE);
898
+ break;
899
+ case 'collapse':
900
+ this.nativeViewProtected.setVisibility(android.view.View.GONE);
901
+ break;
902
+ default:
903
+ throw new Error(`Invalid visibility value: ${value}. Valid values are: visible, hidden, collapse.`);
904
+ }
905
+ }
906
+ [opacityProperty.getDefault]() {
907
+ return this.nativeViewProtected.getAlpha();
908
+ }
909
+ [opacityProperty.setNative](value) {
910
+ this.nativeViewProtected.setAlpha(float(value));
911
+ }
912
+ [accessibilityRoleProperty.setNative](value) {
913
+ this.accessibilityRole = value;
914
+ updateA11yPropertiesCallback(this);
915
+ if (SDK_VERSION >= 28) {
916
+ this.nativeViewProtected?.setAccessibilityHeading(value === AccessibilityRole.Header);
917
+ }
918
+ }
919
+ [accessibilityLiveRegionProperty.setNative](value) {
920
+ switch (value) {
921
+ case AccessibilityLiveRegion.Assertive: {
922
+ this.nativeViewProtected.setAccessibilityLiveRegion(android.view.View.ACCESSIBILITY_LIVE_REGION_ASSERTIVE);
923
+ break;
924
+ }
925
+ case AccessibilityLiveRegion.Polite: {
926
+ this.nativeViewProtected.setAccessibilityLiveRegion(android.view.View.ACCESSIBILITY_LIVE_REGION_POLITE);
927
+ break;
928
+ }
929
+ default: {
930
+ this.nativeViewProtected.setAccessibilityLiveRegion(android.view.View.ACCESSIBILITY_LIVE_REGION_NONE);
931
+ break;
932
+ }
933
+ }
934
+ }
935
+ [accessibilityStateProperty.setNative](value) {
936
+ this.accessibilityState = value;
937
+ updateA11yPropertiesCallback(this);
938
+ }
939
+ [horizontalAlignmentProperty.getDefault]() {
940
+ return org.nativescript.widgets.ViewHelper.getHorizontalAlignment(this.nativeViewProtected);
941
+ }
942
+ [horizontalAlignmentProperty.setNative](value) {
943
+ const nativeView = this.nativeViewProtected;
944
+ const lp = nativeView.getLayoutParams() || new org.nativescript.widgets.CommonLayoutParams();
945
+ const gravity = lp.gravity;
946
+ const weight = lp.weight;
947
+ // Set only if params gravity exists.
948
+ if (gravity !== undefined) {
949
+ switch (value) {
950
+ case 'left':
951
+ lp.gravity = GRAVITY_LEFT | (gravity & VERTICAL_GRAVITY_MASK);
952
+ if (weight < 0) {
953
+ lp.weight = -2;
954
+ }
955
+ break;
956
+ case 'center':
957
+ lp.gravity = GRAVITY_CENTER_HORIZONTAL | (gravity & VERTICAL_GRAVITY_MASK);
958
+ if (weight < 0) {
959
+ lp.weight = -2;
960
+ }
961
+ break;
962
+ case 'right':
963
+ lp.gravity = GRAVITY_RIGHT | (gravity & VERTICAL_GRAVITY_MASK);
964
+ if (weight < 0) {
965
+ lp.weight = -2;
966
+ }
967
+ break;
968
+ case 'stretch':
969
+ lp.gravity = GRAVITY_FILL_HORIZONTAL | (gravity & VERTICAL_GRAVITY_MASK);
970
+ if (weight < 0) {
971
+ lp.weight = -1;
972
+ }
973
+ break;
974
+ }
975
+ nativeView.setLayoutParams(lp);
976
+ }
977
+ }
978
+ [verticalAlignmentProperty.getDefault]() {
979
+ return org.nativescript.widgets.ViewHelper.getVerticalAlignment(this.nativeViewProtected);
980
+ }
981
+ [verticalAlignmentProperty.setNative](value) {
982
+ const nativeView = this.nativeViewProtected;
983
+ const lp = nativeView.getLayoutParams() || new org.nativescript.widgets.CommonLayoutParams();
984
+ const gravity = lp.gravity;
985
+ const height = lp.height;
986
+ // Set only if params gravity exists.
987
+ if (gravity !== undefined) {
988
+ switch (value) {
989
+ case 'top':
990
+ lp.gravity = GRAVITY_TOP | (gravity & HORIZONTAL_GRAVITY_MASK);
991
+ if (height < 0) {
992
+ lp.height = -2;
993
+ }
994
+ break;
995
+ case 'middle':
996
+ lp.gravity = GRAVITY_CENTER_VERTICAL | (gravity & HORIZONTAL_GRAVITY_MASK);
997
+ if (height < 0) {
998
+ lp.height = -2;
999
+ }
1000
+ break;
1001
+ case 'bottom':
1002
+ lp.gravity = GRAVITY_BOTTOM | (gravity & HORIZONTAL_GRAVITY_MASK);
1003
+ if (height < 0) {
1004
+ lp.height = -2;
1005
+ }
1006
+ break;
1007
+ case 'stretch':
1008
+ lp.gravity = GRAVITY_FILL_VERTICAL | (gravity & HORIZONTAL_GRAVITY_MASK);
1009
+ if (height < 0) {
1010
+ lp.height = -1;
1011
+ }
1012
+ break;
1013
+ }
1014
+ nativeView.setLayoutParams(lp);
1015
+ }
1016
+ }
1017
+ [statusBarStyleProperty.getDefault]() {
1018
+ return this.style.statusBarStyle;
1019
+ }
1020
+ [statusBarStyleProperty.setNative](value) {
1021
+ this.updateStatusBarStyle(value);
1022
+ }
1023
+ updateStatusBarStyle(value) {
1024
+ if (SDK_VERSION < 21)
1025
+ return; // nothing we can do
1026
+ const window = this.getClosestWindow();
1027
+ // Ensure the window draws system bar backgrounds (required to color status bar)
1028
+ window.clearFlags(android.view.WindowManager.LayoutParams.FLAG_TRANSLUCENT_STATUS);
1029
+ window.addFlags(android.view.WindowManager.LayoutParams.FLAG_DRAWS_SYSTEM_BAR_BACKGROUNDS);
1030
+ const decorView = window.getDecorView();
1031
+ // API 30+ path (preferred)
1032
+ const controller = window.getInsetsController?.();
1033
+ if (controller && SDK_VERSION >= 30) {
1034
+ const APPEARANCE_LIGHT_STATUS_BARS = android.view.WindowInsetsController?.APPEARANCE_LIGHT_STATUS_BARS;
1035
+ if (typeof value === 'string') {
1036
+ this.style.statusBarStyle = value;
1037
+ if (value === 'light') {
1038
+ // light icons/text
1039
+ controller.setSystemBarsAppearance(0, APPEARANCE_LIGHT_STATUS_BARS);
1040
+ }
1041
+ else {
1042
+ // dark icons/text
1043
+ controller.setSystemBarsAppearance(APPEARANCE_LIGHT_STATUS_BARS, APPEARANCE_LIGHT_STATUS_BARS);
1044
+ }
1045
+ }
1046
+ else {
1047
+ if (value.color != null)
1048
+ window.setStatusBarColor(value.color);
1049
+ // No direct passthrough for systemUiVisibility on API 30+, use appearances instead
1050
+ }
1051
+ return;
1052
+ }
1053
+ // API 23–29 path (systemUiVisibility)
1054
+ if (SDK_VERSION >= 23) {
1055
+ if (typeof value === 'string') {
1056
+ this.style.statusBarStyle = value;
1057
+ let flags = decorView.getSystemUiVisibility();
1058
+ if (value === 'light') {
1059
+ // Add the LIGHT_STATUS_BAR bit without clobbering other flags
1060
+ flags |= android.view.View.SYSTEM_UI_FLAG_LIGHT_STATUS_BAR;
1061
+ decorView.setSystemUiVisibility(flags);
1062
+ }
1063
+ else {
1064
+ // Remove only the LIGHT_STATUS_BAR bit
1065
+ flags &= ~android.view.View.SYSTEM_UI_FLAG_LIGHT_STATUS_BAR;
1066
+ decorView.setSystemUiVisibility(flags);
1067
+ }
1068
+ }
1069
+ else {
1070
+ if (value.color != null)
1071
+ window.setStatusBarColor(value.color);
1072
+ if (value.systemUiVisibility != null) {
1073
+ // Preserve existing flags, don’t blindly overwrite to 0
1074
+ const merged = (decorView.getSystemUiVisibility() & ~android.view.View.SYSTEM_UI_FLAG_LIGHT_STATUS_BAR) | (value.systemUiVisibility & android.view.View.SYSTEM_UI_FLAG_LIGHT_STATUS_BAR);
1075
+ decorView.setSystemUiVisibility(merged);
1076
+ }
1077
+ }
1078
+ return;
1079
+ }
1080
+ // API 21–22: you can only change the background color; icon color is fixed (light)
1081
+ if (typeof value === 'object' && value.color != null) {
1082
+ window.setStatusBarColor(value.color);
1083
+ }
1084
+ }
1085
+ getClosestWindow() {
1086
+ // When it comes to modals, check parent as it may not be the modal root view itself
1087
+ const view = this.parent ?? this;
1088
+ const dialogFragment = view._dialogFragment;
1089
+ if (dialogFragment) {
1090
+ const dialog = dialogFragment.getDialog();
1091
+ if (dialog) {
1092
+ return dialog.getWindow();
1093
+ }
1094
+ }
1095
+ return this._context.getWindow();
1096
+ }
1097
+ [testIDProperty.setNative](value) {
1098
+ this.setAccessibilityIdentifier(this.nativeViewProtected, value);
1099
+ }
1100
+ setAccessibilityIdentifier(view, value) {
1101
+ const id = Utils.android.resources.getId(':id/nativescript_accessibility_id');
1102
+ if (id) {
1103
+ view.setTag(id, value);
1104
+ view.setTag(value);
1105
+ }
1106
+ if (this.testID && this.testID !== value)
1107
+ this.testID = value;
1108
+ if (this.accessibilityIdentifier !== value)
1109
+ this.accessibilityIdentifier = value;
1110
+ }
1111
+ [accessibilityEnabledProperty.setNative](value) {
1112
+ this.nativeViewProtected.setFocusable(!!value);
1113
+ updateA11yPropertiesCallback(this);
1114
+ }
1115
+ [accessibilityIdentifierProperty.setNative](value) {
1116
+ this.setAccessibilityIdentifier(this.nativeViewProtected, value);
1117
+ }
1118
+ [accessibilityValueProperty.setNative](value) {
1119
+ this._androidContentDescriptionUpdated = true;
1120
+ updateContentDescription(this);
1121
+ }
1122
+ [accessibilityLabelProperty.setNative](value) {
1123
+ this._androidContentDescriptionUpdated = true;
1124
+ updateContentDescription(this);
1125
+ }
1126
+ [accessibilityHintProperty.setNative](value) {
1127
+ this._androidContentDescriptionUpdated = true;
1128
+ updateContentDescription(this);
1129
+ }
1130
+ [accessibilityHiddenProperty.setNative](value) {
1131
+ if (value) {
1132
+ this.nativeViewProtected.setImportantForAccessibility(android.view.View.IMPORTANT_FOR_ACCESSIBILITY_NO_HIDE_DESCENDANTS);
1133
+ }
1134
+ else {
1135
+ this.nativeViewProtected.setImportantForAccessibility(android.view.View.IMPORTANT_FOR_ACCESSIBILITY_YES);
1136
+ }
1137
+ }
1138
+ [accessibilityMediaSessionProperty.setNative](value) {
1139
+ updateA11yPropertiesCallback(this);
1140
+ }
1141
+ [androidElevationProperty.getDefault]() {
1142
+ return this.getDefaultElevation();
1143
+ }
1144
+ [androidElevationProperty.setNative](value) {
1145
+ if (SDK_VERSION < 21) {
1146
+ return;
1147
+ }
1148
+ this.refreshStateListAnimator();
1149
+ }
1150
+ [androidDynamicElevationOffsetProperty.getDefault]() {
1151
+ return this.getDefaultDynamicElevationOffset();
1152
+ }
1153
+ [androidDynamicElevationOffsetProperty.setNative](value) {
1154
+ if (SDK_VERSION < 21) {
1155
+ return;
1156
+ }
1157
+ this.refreshStateListAnimator();
1158
+ }
1159
+ getDefaultElevation() {
1160
+ if (SDK_VERSION < 21) {
1161
+ return 0;
1162
+ }
1163
+ // NOTE: overriden in Button implementation as for widgets with StateListAnimator (Button)
1164
+ // nativeView.getElevation() returns 0 at the time of the getDefault() query
1165
+ return layout.toDeviceIndependentPixels(this.nativeViewProtected.getElevation());
1166
+ }
1167
+ getDefaultDynamicElevationOffset() {
1168
+ // NOTE: overriden in Button implementation
1169
+ return 0;
1170
+ }
1171
+ refreshStateListAnimator() {
1172
+ const nativeView = this.nativeViewProtected;
1173
+ const ObjectAnimator = android.animation.ObjectAnimator;
1174
+ const AnimatorSet = android.animation.AnimatorSet;
1175
+ const duration = nativeView.getContext().getResources().getInteger(shortAnimTime) / 2;
1176
+ let elevation = this.androidElevation;
1177
+ if (typeof elevation === 'undefined' || elevation === null) {
1178
+ elevation = this.getDefaultElevation();
1179
+ }
1180
+ elevation = layout.toDevicePixels(elevation);
1181
+ const z = layout.toDevicePixels(0);
1182
+ let pressedZ = this.androidDynamicElevationOffset;
1183
+ if (typeof pressedZ === 'undefined' || pressedZ === null) {
1184
+ pressedZ = this.getDefaultDynamicElevationOffset();
1185
+ }
1186
+ pressedZ = layout.toDevicePixels(pressedZ);
1187
+ const pressedSet = new AnimatorSet();
1188
+ pressedSet.playTogether(java.util.Arrays.asList([ObjectAnimator.ofFloat(nativeView, 'translationZ', [pressedZ]).setDuration(duration), ObjectAnimator.ofFloat(nativeView, 'elevation', [elevation]).setDuration(0)]));
1189
+ const notPressedSet = new AnimatorSet();
1190
+ notPressedSet.playTogether(java.util.Arrays.asList([ObjectAnimator.ofFloat(nativeView, 'translationZ', [z]).setDuration(duration), ObjectAnimator.ofFloat(nativeView, 'elevation', [elevation]).setDuration(0)]));
1191
+ const defaultSet = new AnimatorSet();
1192
+ defaultSet.playTogether(java.util.Arrays.asList([ObjectAnimator.ofFloat(nativeView, 'translationZ', [0]).setDuration(0), ObjectAnimator.ofFloat(nativeView, 'elevation', [0]).setDuration(0)]));
1193
+ const stateListAnimator = new android.animation.StateListAnimator();
1194
+ stateListAnimator.addState([statePressed, stateEnabled], pressedSet);
1195
+ stateListAnimator.addState([stateEnabled], notPressedSet);
1196
+ stateListAnimator.addState([], defaultSet);
1197
+ const currentAnimator = nativeView.getStateListAnimator();
1198
+ if (currentAnimator) {
1199
+ currentAnimator.jumpToCurrentState();
1200
+ }
1201
+ nativeView.setStateListAnimator(stateListAnimator);
1202
+ }
1203
+ [rotateProperty.setNative](value) {
1204
+ org.nativescript.widgets.ViewHelper.setRotate(this.nativeViewProtected, float(value));
1205
+ }
1206
+ [rotateXProperty.setNative](value) {
1207
+ org.nativescript.widgets.ViewHelper.setRotateX(this.nativeViewProtected, float(value));
1208
+ }
1209
+ [rotateYProperty.setNative](value) {
1210
+ org.nativescript.widgets.ViewHelper.setRotateY(this.nativeViewProtected, float(value));
1211
+ }
1212
+ [perspectiveProperty.setNative](value) {
1213
+ org.nativescript.widgets.ViewHelper.setPerspective(this.nativeViewProtected, float(value * Screen.mainScreen.scale));
1214
+ }
1215
+ [scaleXProperty.setNative](value) {
1216
+ org.nativescript.widgets.ViewHelper.setScaleX(this.nativeViewProtected, float(value));
1217
+ }
1218
+ [scaleYProperty.setNative](value) {
1219
+ org.nativescript.widgets.ViewHelper.setScaleY(this.nativeViewProtected, float(value));
1220
+ }
1221
+ [translateXProperty.setNative](value) {
1222
+ org.nativescript.widgets.ViewHelper.setTranslateX(this.nativeViewProtected, layout.toDevicePixels(value));
1223
+ }
1224
+ [translateYProperty.setNative](value) {
1225
+ org.nativescript.widgets.ViewHelper.setTranslateY(this.nativeViewProtected, layout.toDevicePixels(value));
1226
+ }
1227
+ [zIndexProperty.getDefault]() {
1228
+ return 0;
1229
+ }
1230
+ [zIndexProperty.setNative](value) {
1231
+ org.nativescript.widgets.ViewHelper.setZIndex(this.nativeViewProtected, value);
1232
+ }
1233
+ [backgroundInternalProperty.getDefault]() {
1234
+ const nativeView = this.nativeViewProtected;
1235
+ return AndroidHelper.getCopyOrDrawable(nativeView.getBackground(), nativeView.getResources());
1236
+ }
1237
+ [backgroundInternalProperty.setNative](value) {
1238
+ this._redrawNativeBackground(value);
1239
+ }
1240
+ [minWidthProperty.setNative](value) {
1241
+ if (this.parent instanceof CustomLayoutView && this.parent.nativeViewProtected) {
1242
+ this.parent._setChildMinWidthNative(this, value);
1243
+ }
1244
+ else {
1245
+ this._setMinWidthNative(value);
1246
+ }
1247
+ }
1248
+ [minHeightProperty.setNative](value) {
1249
+ if (this.parent instanceof CustomLayoutView && this.parent.nativeViewProtected) {
1250
+ this.parent._setChildMinHeightNative(this, value);
1251
+ }
1252
+ else {
1253
+ this._setMinHeightNative(value);
1254
+ }
1255
+ }
1256
+ _applyBackground(background, isBorderDrawable, onlyColor, backgroundDrawable) {
1257
+ const nativeView = this.nativeViewProtected;
1258
+ if (onlyColor) {
1259
+ const backgroundColor = background.color.android;
1260
+ if (isBorderDrawable) {
1261
+ // We need to duplicate the drawable or we lose the "default" cached drawable
1262
+ backgroundDrawable = nativeView._cachedDrawable != null ? AndroidHelper.getCopyOrDrawable(nativeView._cachedDrawable, nativeView.getResources()) : null;
1263
+ nativeView.setBackground(backgroundDrawable);
1264
+ }
1265
+ // Apply color to drawables when there is the need to maintain visual things like button ripple effect
1266
+ if (this.needsNativeDrawableFill && backgroundDrawable) {
1267
+ backgroundDrawable.mutate();
1268
+ AndroidHelper.setDrawableColor(backgroundColor, backgroundDrawable);
1269
+ backgroundDrawable.invalidateSelf();
1270
+ }
1271
+ else {
1272
+ nativeView.setBackgroundColor(backgroundColor);
1273
+ }
1274
+ }
1275
+ else {
1276
+ if (background.clearFlags & 1 /* BackgroundClearFlags.CLEAR_BACKGROUND_COLOR */) {
1277
+ if (backgroundDrawable) {
1278
+ backgroundDrawable.mutate();
1279
+ AndroidHelper.clearDrawableColor(backgroundDrawable);
1280
+ backgroundDrawable.invalidateSelf();
1281
+ }
1282
+ else {
1283
+ nativeView.setBackgroundColor(-1);
1284
+ }
1285
+ }
1286
+ if (background.isEmpty()) {
1287
+ // Reset background to default if not already set
1288
+ const defaultDrawable = nativeView._cachedDrawable ?? null;
1289
+ if (backgroundDrawable !== defaultDrawable) {
1290
+ nativeView.setBackground(defaultDrawable);
1291
+ }
1292
+ }
1293
+ else {
1294
+ if (isBorderDrawable) {
1295
+ // org.nativescript.widgets.BorderDrawable
1296
+ refreshBorderDrawable(this, backgroundDrawable);
1297
+ }
1298
+ else {
1299
+ const borderDrawable = new org.nativescript.widgets.BorderDrawable(layout.getDisplayDensity(), this.toString());
1300
+ refreshBorderDrawable(this, borderDrawable);
1301
+ nativeView.setBackground(borderDrawable);
1302
+ }
1303
+ }
1304
+ }
1305
+ }
1306
+ _drawBoxShadow(boxShadow) {
1307
+ const nativeView = this.nativeViewProtected;
1308
+ const config = {
1309
+ shadowColor: boxShadow.color.android,
1310
+ cornerRadius: Length.toDevicePixels(this.borderRadius, 0.0),
1311
+ spreadRadius: boxShadow.spreadRadius,
1312
+ blurRadius: boxShadow.blurRadius,
1313
+ offsetX: boxShadow.offsetX,
1314
+ offsetY: boxShadow.offsetY,
1315
+ };
1316
+ org.nativescript.widgets.Utils.drawBoxShadow(nativeView, JSON.stringify(config));
1317
+ }
1318
+ _redrawNativeBackground(value) {
1319
+ if (value instanceof Background) {
1320
+ this.onBackgroundOrBorderPropertyChanged();
1321
+ }
1322
+ else {
1323
+ const nativeView = this.nativeViewProtected;
1324
+ nativeView.setBackground(value);
1325
+ const style = this.style;
1326
+ const paddingTop = paddingTopProperty.isSet(style) ? this.effectivePaddingTop : this._defaultPaddingTop;
1327
+ const paddingRight = paddingRightProperty.isSet(style) ? this.effectivePaddingRight : this._defaultPaddingRight;
1328
+ const paddingBottom = paddingBottomProperty.isSet(style) ? this.effectivePaddingBottom : this._defaultPaddingBottom;
1329
+ const paddingLeft = paddingLeftProperty.isSet(style) ? this.effectivePaddingLeft : this._defaultPaddingLeft;
1330
+ if (this._isPaddingRelative) {
1331
+ nativeView.setPaddingRelative(paddingLeft, paddingTop, paddingRight, paddingBottom);
1332
+ }
1333
+ else {
1334
+ nativeView.setPadding(paddingLeft, paddingTop, paddingRight, paddingBottom);
1335
+ }
1336
+ }
1337
+ }
1338
+ onBackgroundOrBorderPropertyChanged() {
1339
+ const nativeView = this.nativeViewProtected;
1340
+ if (!nativeView) {
1341
+ return;
1342
+ }
1343
+ const background = this.style.backgroundInternal;
1344
+ const drawable = nativeView.getBackground();
1345
+ const isBorderDrawable = drawable instanceof org.nativescript.widgets.BorderDrawable;
1346
+ // Use undefined as not set. getBackground will never return undefined only Drawable or null;
1347
+ if (nativeView._cachedDrawable === undefined) {
1348
+ nativeView._cachedDrawable = drawable;
1349
+ }
1350
+ if (background.clearFlags & 2 /* BackgroundClearFlags.CLEAR_BOX_SHADOW */) {
1351
+ // Clear background if we're clearing the box shadow
1352
+ if (drawable instanceof org.nativescript.widgets.BoxShadowDrawable) {
1353
+ nativeView.setBackground(nativeView._cachedDrawable ?? null);
1354
+ }
1355
+ }
1356
+ // prettier-ignore
1357
+ const onlyColor = !background.hasBorderWidth()
1358
+ && !background.hasBorderRadius()
1359
+ && !background.hasBoxShadow()
1360
+ && !background.clipPath
1361
+ && !background.image
1362
+ && !!background.color;
1363
+ this._applyBackground(background, isBorderDrawable, onlyColor, drawable);
1364
+ if (background.hasBoxShadow()) {
1365
+ this._drawBoxShadow(background.getBoxShadow());
1366
+ }
1367
+ // TODO: Can we move BorderWidths as separate native setter?
1368
+ // This way we could skip setPadding if borderWidth is not changed.
1369
+ const leftPadding = Math.ceil(this.effectiveBorderLeftWidth + this.effectivePaddingLeft);
1370
+ const topPadding = Math.ceil(this.effectiveBorderTopWidth + this.effectivePaddingTop);
1371
+ const rightPadding = Math.ceil(this.effectiveBorderRightWidth + this.effectivePaddingRight);
1372
+ const bottomPadding = Math.ceil(this.effectiveBorderBottomWidth + this.effectivePaddingBottom);
1373
+ if (this._isPaddingRelative) {
1374
+ nativeView.setPaddingRelative(leftPadding, topPadding, rightPadding, bottomPadding);
1375
+ }
1376
+ else {
1377
+ nativeView.setPadding(leftPadding, topPadding, rightPadding, bottomPadding);
1378
+ }
1379
+ // reset clear flags
1380
+ background.clearFlags = 0 /* BackgroundClearFlags.NONE */;
1381
+ }
1382
+ accessibilityAnnouncement(message = this.accessibilityLabel) {
1383
+ this.sendAccessibilityEvent({
1384
+ androidAccessibilityEvent: AndroidAccessibilityEvent.ANNOUNCEMENT,
1385
+ message,
1386
+ });
1387
+ }
1388
+ accessibilityScreenChanged() {
1389
+ this.sendAccessibilityEvent({
1390
+ androidAccessibilityEvent: AndroidAccessibilityEvent.WINDOW_STATE_CHANGED,
1391
+ });
1392
+ }
1393
+ }
1394
+ View.androidBackPressedEvent = androidBackPressedEvent;
1395
+ __decorate([
1396
+ profile,
1397
+ __metadata("design:type", Function),
1398
+ __metadata("design:paramtypes", []),
1399
+ __metadata("design:returntype", void 0)
1400
+ ], View.prototype, "onLoaded", null);
1401
+ __decorate([
1402
+ profile,
1403
+ __metadata("design:type", Function),
1404
+ __metadata("design:paramtypes", []),
1405
+ __metadata("design:returntype", void 0)
1406
+ ], View.prototype, "onUnloaded", null);
1407
+ __decorate([
1408
+ profile,
1409
+ __metadata("design:type", Function),
1410
+ __metadata("design:paramtypes", []),
1411
+ __metadata("design:returntype", void 0)
1412
+ ], View.prototype, "requestLayout", null);
1413
+ function parseEdges(edges) {
1414
+ const values = edges.trim().split(',');
1415
+ let newValue = -1;
1416
+ for (let value of values) {
1417
+ const trimmedValue = value.trim();
1418
+ switch (trimmedValue) {
1419
+ case 'none':
1420
+ if (newValue === -1) {
1421
+ newValue = OverflowEdgeNone;
1422
+ }
1423
+ else {
1424
+ newValue |= OverflowEdgeNone;
1425
+ }
1426
+ break;
1427
+ case 'left':
1428
+ if (newValue === -1) {
1429
+ newValue = OverflowEdgeLeft;
1430
+ }
1431
+ else {
1432
+ newValue |= OverflowEdgeLeft;
1433
+ }
1434
+ break;
1435
+ case 'top':
1436
+ if (newValue === -1) {
1437
+ newValue = OverflowEdgeTop;
1438
+ }
1439
+ else {
1440
+ newValue |= OverflowEdgeTop;
1441
+ }
1442
+ break;
1443
+ case 'right':
1444
+ if (newValue === -1) {
1445
+ newValue = OverflowEdgeRight;
1446
+ }
1447
+ else {
1448
+ newValue |= OverflowEdgeRight;
1449
+ }
1450
+ break;
1451
+ case 'bottom':
1452
+ if (newValue === -1) {
1453
+ newValue = OverflowEdgeBottom;
1454
+ }
1455
+ else {
1456
+ newValue |= OverflowEdgeBottom;
1457
+ }
1458
+ break;
1459
+ case 'dont-apply':
1460
+ newValue = OverflowEdgeDontApply;
1461
+ break;
1462
+ case 'left-dont-consume':
1463
+ if (newValue === -1) {
1464
+ newValue = OverflowEdgeLeftDontConsume;
1465
+ }
1466
+ else {
1467
+ newValue |= OverflowEdgeLeftDontConsume;
1468
+ }
1469
+ break;
1470
+ case 'top-dont-consume':
1471
+ if (newValue === -1) {
1472
+ newValue = OverflowEdgeTopDontConsume;
1473
+ }
1474
+ else {
1475
+ newValue |= OverflowEdgeTopDontConsume;
1476
+ }
1477
+ break;
1478
+ case 'right-dont-consume':
1479
+ if (newValue === -1) {
1480
+ newValue = OverflowEdgeRightDontConsume;
1481
+ }
1482
+ else {
1483
+ newValue |= OverflowEdgeRightDontConsume;
1484
+ }
1485
+ break;
1486
+ case 'bottom-dont-consume':
1487
+ if (newValue === -1) {
1488
+ newValue = OverflowEdgeBottomDontConsume;
1489
+ }
1490
+ else {
1491
+ newValue |= OverflowEdgeBottomDontConsume;
1492
+ }
1493
+ case 'all-but-left':
1494
+ if (newValue === -1) {
1495
+ newValue = OverflowEdgeAllButLeft;
1496
+ }
1497
+ else {
1498
+ newValue |= OverflowEdgeAllButLeft;
1499
+ }
1500
+ case 'all-but-top':
1501
+ if (newValue === -1) {
1502
+ newValue = OverflowEdgeAllButTop;
1503
+ }
1504
+ else {
1505
+ newValue |= OverflowEdgeAllButTop;
1506
+ }
1507
+ case 'all-but-right':
1508
+ if (newValue === -1) {
1509
+ newValue = OverflowEdgeAllButRight;
1510
+ }
1511
+ else {
1512
+ newValue |= OverflowEdgeAllButRight;
1513
+ }
1514
+ case 'all-but-bottom':
1515
+ if (newValue === -1) {
1516
+ newValue = OverflowEdgeAllButBottom;
1517
+ }
1518
+ else {
1519
+ newValue |= OverflowEdgeAllButBottom;
1520
+ }
1521
+ break;
1522
+ }
1523
+ }
1524
+ if (newValue === -1) {
1525
+ return null;
1526
+ }
1527
+ return newValue;
1528
+ }
1529
+ export class ContainerView extends View {
1530
+ }
1531
+ export class CustomLayoutView extends ContainerView {
1532
+ createNativeView() {
1533
+ return new org.nativescript.widgets.ContentLayout(this._context);
1534
+ }
1535
+ _addViewToNativeVisualTree(child, atIndex = Number.MAX_SAFE_INTEGER) {
1536
+ super._addViewToNativeVisualTree(child);
1537
+ if (this.nativeViewProtected && child.nativeViewProtected) {
1538
+ if (Trace.isEnabled()) {
1539
+ Trace.write(`${this}.nativeView.addView(${child}.nativeView, ${atIndex})`, Trace.categories.VisualTreeEvents);
1540
+ }
1541
+ this.nativeViewProtected.addView(child.nativeViewProtected, atIndex);
1542
+ if (child instanceof View) {
1543
+ this._updateNativeLayoutParams(child);
1544
+ }
1545
+ return true;
1546
+ }
1547
+ return false;
1548
+ }
1549
+ _updateNativeLayoutParams(child) {
1550
+ // noop
1551
+ }
1552
+ _setChildMinWidthNative(child, value) {
1553
+ child._setMinWidthNative(value);
1554
+ }
1555
+ _setChildMinHeightNative(child, value) {
1556
+ child._setMinHeightNative(value);
1557
+ }
1558
+ _removeViewFromNativeVisualTree(child) {
1559
+ super._removeViewFromNativeVisualTree(child);
1560
+ const nativeView = this.nativeViewProtected;
1561
+ const childView = child.nativeViewProtected;
1562
+ if (nativeView && childView) {
1563
+ nativeView.removeView(childView);
1564
+ if (Trace.isEnabled()) {
1565
+ Trace.write(`${nativeView}.removeView(${childView})`, Trace.categories.VisualTreeEvents);
1566
+ Trace.notifyEvent(child, 'childInLayoutRemovedFromNativeVisualTree');
1567
+ }
1568
+ }
1569
+ }
1570
+ }
1571
+ const percentNotSupported = (view, value) => {
1572
+ throw new Error('PercentLength is not supported.');
1573
+ };
1574
+ function createNativePercentLengthProperty(options) {
1575
+ const { getter, setter, auto = 0 } = options;
1576
+ let setPixels, getPixels, setPercent;
1577
+ if (getter) {
1578
+ View.prototype[getter] = function () {
1579
+ if (options) {
1580
+ setPixels = options.setPixels;
1581
+ getPixels = options.getPixels;
1582
+ setPercent = options.setPercent || percentNotSupported;
1583
+ options = null;
1584
+ }
1585
+ const value = getPixels(this.nativeViewProtected);
1586
+ if (value == auto) {
1587
+ // tslint:disable-line
1588
+ return 'auto';
1589
+ }
1590
+ else {
1591
+ return { value, unit: 'px' };
1592
+ }
1593
+ };
1594
+ }
1595
+ if (setter) {
1596
+ View.prototype[setter] = function (length) {
1597
+ if (options) {
1598
+ setPixels = options.setPixels;
1599
+ getPixels = options.getPixels;
1600
+ setPercent = options.setPercent || percentNotSupported;
1601
+ options = null;
1602
+ }
1603
+ if (length == 'auto' || length == null || isCssWideKeyword(length)) {
1604
+ // tslint:disable-line
1605
+ setPixels(this.nativeViewProtected, auto);
1606
+ }
1607
+ else if (typeof length === 'number') {
1608
+ setPixels(this.nativeViewProtected, layout.round(layout.toDevicePixels(length)));
1609
+ }
1610
+ else if (length.unit == 'dip') {
1611
+ // tslint:disable-line
1612
+ setPixels(this.nativeViewProtected, layout.round(layout.toDevicePixels(length.value)));
1613
+ }
1614
+ else if (length.unit == 'px') {
1615
+ // tslint:disable-line
1616
+ setPixels(this.nativeViewProtected, layout.round(length.value));
1617
+ }
1618
+ else if (length.unit == '%') {
1619
+ // tslint:disable-line
1620
+ setPercent(this.nativeViewProtected, length.value);
1621
+ }
1622
+ else {
1623
+ throw new Error(`Unsupported PercentLength ${length}`);
1624
+ }
1625
+ };
1626
+ }
1627
+ }
1628
+ createNativePercentLengthProperty({
1629
+ setter: marginTopProperty.setNative,
1630
+ get setPixels() {
1631
+ return org.nativescript.widgets.ViewHelper.setMarginTop;
1632
+ },
1633
+ get setPercent() {
1634
+ return org.nativescript.widgets.ViewHelper.setMarginTopPercent;
1635
+ },
1636
+ });
1637
+ createNativePercentLengthProperty({
1638
+ setter: marginRightProperty.setNative,
1639
+ get setPixels() {
1640
+ return org.nativescript.widgets.ViewHelper.setMarginRight;
1641
+ },
1642
+ get setPercent() {
1643
+ return org.nativescript.widgets.ViewHelper.setMarginRightPercent;
1644
+ },
1645
+ });
1646
+ createNativePercentLengthProperty({
1647
+ setter: marginBottomProperty.setNative,
1648
+ get setPixels() {
1649
+ return org.nativescript.widgets.ViewHelper.setMarginBottom;
1650
+ },
1651
+ get setPercent() {
1652
+ return org.nativescript.widgets.ViewHelper.setMarginBottomPercent;
1653
+ },
1654
+ });
1655
+ createNativePercentLengthProperty({
1656
+ setter: marginLeftProperty.setNative,
1657
+ get setPixels() {
1658
+ return org.nativescript.widgets.ViewHelper.setMarginLeft;
1659
+ },
1660
+ get setPercent() {
1661
+ return org.nativescript.widgets.ViewHelper.setMarginLeftPercent;
1662
+ },
1663
+ });
1664
+ createNativePercentLengthProperty({
1665
+ setter: widthProperty.setNative,
1666
+ auto: -1, //android.view.ViewGroup.LayoutParams.MATCH_PARENT,
1667
+ get setPixels() {
1668
+ return org.nativescript.widgets.ViewHelper.setWidth;
1669
+ },
1670
+ get setPercent() {
1671
+ return org.nativescript.widgets.ViewHelper.setWidthPercent;
1672
+ },
1673
+ });
1674
+ createNativePercentLengthProperty({
1675
+ setter: heightProperty.setNative,
1676
+ auto: -1, //android.view.ViewGroup.LayoutParams.MATCH_PARENT,
1677
+ get setPixels() {
1678
+ return org.nativescript.widgets.ViewHelper.setHeight;
1679
+ },
1680
+ get setPercent() {
1681
+ return org.nativescript.widgets.ViewHelper.setHeightPercent;
1682
+ },
1683
+ });
1684
+ createNativePercentLengthProperty({
1685
+ setter: '_setMinWidthNative',
1686
+ get setPixels() {
1687
+ return org.nativescript.widgets.ViewHelper.setMinWidth;
1688
+ },
1689
+ });
1690
+ createNativePercentLengthProperty({
1691
+ setter: '_setMinHeightNative',
1692
+ get setPixels() {
1693
+ return org.nativescript.widgets.ViewHelper.setMinHeight;
1694
+ },
1695
+ });
1696
+ //# sourceMappingURL=index.android.js.map