native-fn 1.0.89 → 1.1.0

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 (377) hide show
  1. package/dist/index.d.ts +747 -29
  2. package/dist/native.cjs +4283 -74
  3. package/dist/native.min.cjs +1 -1
  4. package/dist/native.min.mjs +1 -1
  5. package/dist/native.mjs +4283 -74
  6. package/dist/native.umd.js +4283 -74
  7. package/dist/native.umd.min.js +1 -1
  8. package/dist/plugin/app/index.cjs +637 -663
  9. package/dist/plugin/app/index.d.ts +4 -114
  10. package/dist/plugin/app/index.min.cjs +1 -1
  11. package/dist/plugin/app/index.min.mjs +1 -1
  12. package/dist/plugin/app/index.mjs +637 -663
  13. package/dist/plugin/app/index.umd.js +637 -663
  14. package/dist/plugin/app/index.umd.min.js +1 -1
  15. package/dist/plugin/app/src/plugin/app/constants/index.d.ts +13 -0
  16. package/dist/plugin/app/src/plugin/app/cores/index.d.ts +3 -2
  17. package/dist/plugin/app/src/plugin/app/index.d.ts +2 -11
  18. package/dist/plugin/app/src/plugin/app/types/app.d.ts +13 -3
  19. package/dist/plugin/app/src/plugin/app/types/index.d.ts +0 -15
  20. package/dist/plugin/app/src/plugin/appearance/cores/index.d.ts +2 -2
  21. package/dist/plugin/app/src/plugin/appearance/index.d.ts +2 -7
  22. package/dist/plugin/app/src/plugin/appearance/types/appearance.d.ts +6 -3
  23. package/dist/plugin/app/src/plugin/appearance/types/index.d.ts +0 -12
  24. package/dist/plugin/app/src/plugin/clipboard/cores/index.d.ts +2 -2
  25. package/dist/plugin/app/src/plugin/clipboard/index.d.ts +2 -4
  26. package/dist/plugin/app/src/plugin/clipboard/types/clipboard.d.ts +3 -1
  27. package/dist/plugin/app/src/plugin/clipboard/types/index.d.ts +0 -10
  28. package/dist/plugin/app/src/plugin/dimension/cores/index.d.ts +2 -2
  29. package/dist/plugin/app/src/plugin/dimension/index.d.ts +3 -4
  30. package/dist/plugin/app/src/plugin/dimension/types/dimensions.d.ts +4 -2
  31. package/dist/plugin/app/src/plugin/dimension/types/index.d.ts +0 -12
  32. package/dist/plugin/app/src/plugin/fullscreen/cores/index.d.ts +2 -2
  33. package/dist/plugin/app/src/plugin/fullscreen/index.d.ts +2 -4
  34. package/dist/plugin/app/src/plugin/fullscreen/types/fullscreen.d.ts +6 -4
  35. package/dist/plugin/app/src/plugin/fullscreen/types/index.d.ts +0 -10
  36. package/dist/plugin/app/src/plugin/platform/constants/index.d.ts +6 -6
  37. package/dist/plugin/app/src/plugin/platform/cores/index.d.ts +24 -6
  38. package/dist/plugin/app/src/plugin/platform/index.d.ts +2 -11
  39. package/dist/plugin/app/src/plugin/platform/types/index.d.ts +0 -10
  40. package/dist/plugin/app/src/plugin/platform/types/platform.d.ts +22 -14
  41. package/dist/plugin/app/src/plugin/theme/cores/index.d.ts +2 -2
  42. package/dist/plugin/app/src/plugin/theme/index.d.ts +2 -4
  43. package/dist/plugin/app/src/plugin/theme/types/index.d.ts +0 -10
  44. package/dist/plugin/app/src/plugin/theme/types/theme.d.ts +3 -1
  45. package/dist/plugin/app/src/types/native.d.ts +16 -26
  46. package/dist/plugin/appearance/index.cjs +392 -585
  47. package/dist/plugin/appearance/index.d.ts +4 -37
  48. package/dist/plugin/appearance/index.min.cjs +1 -1
  49. package/dist/plugin/appearance/index.min.mjs +1 -1
  50. package/dist/plugin/appearance/index.mjs +392 -585
  51. package/dist/plugin/appearance/index.umd.js +392 -585
  52. package/dist/plugin/appearance/index.umd.min.js +1 -1
  53. package/dist/plugin/appearance/src/plugin/app/constants/index.d.ts +13 -0
  54. package/dist/plugin/appearance/src/plugin/app/cores/index.d.ts +3 -2
  55. package/dist/plugin/appearance/src/plugin/app/index.d.ts +2 -11
  56. package/dist/plugin/appearance/src/plugin/app/types/app.d.ts +13 -3
  57. package/dist/plugin/appearance/src/plugin/app/types/index.d.ts +0 -15
  58. package/dist/plugin/appearance/src/plugin/appearance/cores/index.d.ts +2 -2
  59. package/dist/plugin/appearance/src/plugin/appearance/index.d.ts +2 -7
  60. package/dist/plugin/appearance/src/plugin/appearance/types/appearance.d.ts +6 -3
  61. package/dist/plugin/appearance/src/plugin/appearance/types/index.d.ts +0 -12
  62. package/dist/plugin/appearance/src/plugin/clipboard/cores/index.d.ts +2 -2
  63. package/dist/plugin/appearance/src/plugin/clipboard/index.d.ts +2 -4
  64. package/dist/plugin/appearance/src/plugin/clipboard/types/clipboard.d.ts +3 -1
  65. package/dist/plugin/appearance/src/plugin/clipboard/types/index.d.ts +0 -10
  66. package/dist/plugin/appearance/src/plugin/dimension/cores/index.d.ts +2 -2
  67. package/dist/plugin/appearance/src/plugin/dimension/index.d.ts +3 -4
  68. package/dist/plugin/appearance/src/plugin/dimension/types/dimensions.d.ts +4 -2
  69. package/dist/plugin/appearance/src/plugin/dimension/types/index.d.ts +0 -12
  70. package/dist/plugin/appearance/src/plugin/fullscreen/cores/index.d.ts +2 -2
  71. package/dist/plugin/appearance/src/plugin/fullscreen/index.d.ts +2 -4
  72. package/dist/plugin/appearance/src/plugin/fullscreen/types/fullscreen.d.ts +6 -4
  73. package/dist/plugin/appearance/src/plugin/fullscreen/types/index.d.ts +0 -10
  74. package/dist/plugin/appearance/src/plugin/platform/constants/index.d.ts +6 -6
  75. package/dist/plugin/appearance/src/plugin/platform/cores/index.d.ts +24 -6
  76. package/dist/plugin/appearance/src/plugin/platform/index.d.ts +2 -11
  77. package/dist/plugin/appearance/src/plugin/platform/types/index.d.ts +0 -10
  78. package/dist/plugin/appearance/src/plugin/platform/types/platform.d.ts +22 -14
  79. package/dist/plugin/appearance/src/plugin/theme/cores/index.d.ts +2 -2
  80. package/dist/plugin/appearance/src/plugin/theme/index.d.ts +2 -4
  81. package/dist/plugin/appearance/src/plugin/theme/types/index.d.ts +0 -10
  82. package/dist/plugin/appearance/src/plugin/theme/types/theme.d.ts +3 -1
  83. package/dist/plugin/appearance/src/types/native.d.ts +16 -26
  84. package/dist/plugin/clipboard/index.cjs +48 -822
  85. package/dist/plugin/clipboard/index.d.ts +4 -27
  86. package/dist/plugin/clipboard/index.min.cjs +1 -1
  87. package/dist/plugin/clipboard/index.min.mjs +1 -1
  88. package/dist/plugin/clipboard/index.mjs +48 -822
  89. package/dist/plugin/clipboard/index.umd.js +48 -822
  90. package/dist/plugin/clipboard/index.umd.min.js +1 -1
  91. package/dist/plugin/clipboard/src/plugin/app/constants/index.d.ts +13 -0
  92. package/dist/plugin/clipboard/src/plugin/app/cores/index.d.ts +3 -2
  93. package/dist/plugin/clipboard/src/plugin/app/index.d.ts +2 -11
  94. package/dist/plugin/clipboard/src/plugin/app/types/app.d.ts +13 -3
  95. package/dist/plugin/clipboard/src/plugin/app/types/index.d.ts +0 -15
  96. package/dist/plugin/clipboard/src/plugin/appearance/cores/index.d.ts +2 -2
  97. package/dist/plugin/clipboard/src/plugin/appearance/index.d.ts +2 -7
  98. package/dist/plugin/clipboard/src/plugin/appearance/types/appearance.d.ts +6 -3
  99. package/dist/plugin/clipboard/src/plugin/appearance/types/index.d.ts +0 -12
  100. package/dist/plugin/clipboard/src/plugin/clipboard/cores/index.d.ts +2 -2
  101. package/dist/plugin/clipboard/src/plugin/clipboard/index.d.ts +2 -4
  102. package/dist/plugin/clipboard/src/plugin/clipboard/types/clipboard.d.ts +3 -1
  103. package/dist/plugin/clipboard/src/plugin/clipboard/types/index.d.ts +0 -10
  104. package/dist/plugin/clipboard/src/plugin/dimension/cores/index.d.ts +2 -2
  105. package/dist/plugin/clipboard/src/plugin/dimension/index.d.ts +3 -4
  106. package/dist/plugin/clipboard/src/plugin/dimension/types/dimensions.d.ts +4 -2
  107. package/dist/plugin/clipboard/src/plugin/dimension/types/index.d.ts +0 -12
  108. package/dist/plugin/clipboard/src/plugin/fullscreen/cores/index.d.ts +2 -2
  109. package/dist/plugin/clipboard/src/plugin/fullscreen/index.d.ts +2 -4
  110. package/dist/plugin/clipboard/src/plugin/fullscreen/types/fullscreen.d.ts +6 -4
  111. package/dist/plugin/clipboard/src/plugin/fullscreen/types/index.d.ts +0 -10
  112. package/dist/plugin/clipboard/src/plugin/platform/constants/index.d.ts +6 -6
  113. package/dist/plugin/clipboard/src/plugin/platform/cores/index.d.ts +24 -6
  114. package/dist/plugin/clipboard/src/plugin/platform/index.d.ts +2 -11
  115. package/dist/plugin/clipboard/src/plugin/platform/types/index.d.ts +0 -10
  116. package/dist/plugin/clipboard/src/plugin/platform/types/platform.d.ts +22 -14
  117. package/dist/plugin/clipboard/src/plugin/theme/cores/index.d.ts +2 -2
  118. package/dist/plugin/clipboard/src/plugin/theme/index.d.ts +2 -4
  119. package/dist/plugin/clipboard/src/plugin/theme/types/index.d.ts +0 -10
  120. package/dist/plugin/clipboard/src/plugin/theme/types/theme.d.ts +3 -1
  121. package/dist/plugin/clipboard/src/types/native.d.ts +16 -26
  122. package/dist/plugin/dimension/index.cjs +3 -883
  123. package/dist/plugin/dimension/index.d.ts +4 -36
  124. package/dist/plugin/dimension/index.min.cjs +1 -1
  125. package/dist/plugin/dimension/index.min.mjs +1 -1
  126. package/dist/plugin/dimension/index.mjs +3 -883
  127. package/dist/plugin/dimension/index.umd.js +3 -883
  128. package/dist/plugin/dimension/index.umd.min.js +1 -1
  129. package/dist/plugin/dimension/src/plugin/app/constants/index.d.ts +13 -0
  130. package/dist/plugin/dimension/src/plugin/app/cores/index.d.ts +3 -2
  131. package/dist/plugin/dimension/src/plugin/app/index.d.ts +2 -11
  132. package/dist/plugin/dimension/src/plugin/app/types/app.d.ts +13 -3
  133. package/dist/plugin/dimension/src/plugin/app/types/index.d.ts +0 -15
  134. package/dist/plugin/dimension/src/plugin/appearance/cores/index.d.ts +2 -2
  135. package/dist/plugin/dimension/src/plugin/appearance/index.d.ts +2 -7
  136. package/dist/plugin/dimension/src/plugin/appearance/types/appearance.d.ts +6 -3
  137. package/dist/plugin/dimension/src/plugin/appearance/types/index.d.ts +0 -12
  138. package/dist/plugin/dimension/src/plugin/clipboard/cores/index.d.ts +2 -2
  139. package/dist/plugin/dimension/src/plugin/clipboard/index.d.ts +2 -4
  140. package/dist/plugin/dimension/src/plugin/clipboard/types/clipboard.d.ts +3 -1
  141. package/dist/plugin/dimension/src/plugin/clipboard/types/index.d.ts +0 -10
  142. package/dist/plugin/dimension/src/plugin/dimension/cores/index.d.ts +2 -2
  143. package/dist/plugin/dimension/src/plugin/dimension/index.d.ts +3 -4
  144. package/dist/plugin/dimension/src/plugin/dimension/types/dimensions.d.ts +4 -2
  145. package/dist/plugin/dimension/src/plugin/dimension/types/index.d.ts +0 -12
  146. package/dist/plugin/dimension/src/plugin/fullscreen/cores/index.d.ts +2 -2
  147. package/dist/plugin/dimension/src/plugin/fullscreen/index.d.ts +2 -4
  148. package/dist/plugin/dimension/src/plugin/fullscreen/types/fullscreen.d.ts +6 -4
  149. package/dist/plugin/dimension/src/plugin/fullscreen/types/index.d.ts +0 -10
  150. package/dist/plugin/dimension/src/plugin/platform/constants/index.d.ts +6 -6
  151. package/dist/plugin/dimension/src/plugin/platform/cores/index.d.ts +24 -6
  152. package/dist/plugin/dimension/src/plugin/platform/index.d.ts +2 -11
  153. package/dist/plugin/dimension/src/plugin/platform/types/index.d.ts +0 -10
  154. package/dist/plugin/dimension/src/plugin/platform/types/platform.d.ts +22 -14
  155. package/dist/plugin/dimension/src/plugin/theme/cores/index.d.ts +2 -2
  156. package/dist/plugin/dimension/src/plugin/theme/index.d.ts +2 -4
  157. package/dist/plugin/dimension/src/plugin/theme/types/index.d.ts +0 -10
  158. package/dist/plugin/dimension/src/plugin/theme/types/theme.d.ts +3 -1
  159. package/dist/plugin/dimension/src/types/native.d.ts +16 -26
  160. package/dist/plugin/fullscreen/index.cjs +391 -588
  161. package/dist/plugin/fullscreen/index.d.ts +4 -33
  162. package/dist/plugin/fullscreen/index.min.cjs +1 -1
  163. package/dist/plugin/fullscreen/index.min.mjs +1 -1
  164. package/dist/plugin/fullscreen/index.mjs +391 -588
  165. package/dist/plugin/fullscreen/index.umd.js +391 -588
  166. package/dist/plugin/fullscreen/index.umd.min.js +1 -1
  167. package/dist/plugin/fullscreen/src/plugin/app/constants/index.d.ts +13 -0
  168. package/dist/plugin/fullscreen/src/plugin/app/cores/index.d.ts +3 -2
  169. package/dist/plugin/fullscreen/src/plugin/app/index.d.ts +2 -11
  170. package/dist/plugin/fullscreen/src/plugin/app/types/app.d.ts +13 -3
  171. package/dist/plugin/fullscreen/src/plugin/app/types/index.d.ts +0 -15
  172. package/dist/plugin/fullscreen/src/plugin/appearance/cores/index.d.ts +2 -2
  173. package/dist/plugin/fullscreen/src/plugin/appearance/index.d.ts +2 -7
  174. package/dist/plugin/fullscreen/src/plugin/appearance/types/appearance.d.ts +6 -3
  175. package/dist/plugin/fullscreen/src/plugin/appearance/types/index.d.ts +0 -12
  176. package/dist/plugin/fullscreen/src/plugin/clipboard/cores/index.d.ts +2 -2
  177. package/dist/plugin/fullscreen/src/plugin/clipboard/index.d.ts +2 -4
  178. package/dist/plugin/fullscreen/src/plugin/clipboard/types/clipboard.d.ts +3 -1
  179. package/dist/plugin/fullscreen/src/plugin/clipboard/types/index.d.ts +0 -10
  180. package/dist/plugin/fullscreen/src/plugin/dimension/cores/index.d.ts +2 -2
  181. package/dist/plugin/fullscreen/src/plugin/dimension/index.d.ts +3 -4
  182. package/dist/plugin/fullscreen/src/plugin/dimension/types/dimensions.d.ts +4 -2
  183. package/dist/plugin/fullscreen/src/plugin/dimension/types/index.d.ts +0 -12
  184. package/dist/plugin/fullscreen/src/plugin/fullscreen/cores/index.d.ts +2 -2
  185. package/dist/plugin/fullscreen/src/plugin/fullscreen/index.d.ts +2 -4
  186. package/dist/plugin/fullscreen/src/plugin/fullscreen/types/fullscreen.d.ts +6 -4
  187. package/dist/plugin/fullscreen/src/plugin/fullscreen/types/index.d.ts +0 -10
  188. package/dist/plugin/fullscreen/src/plugin/platform/constants/index.d.ts +6 -6
  189. package/dist/plugin/fullscreen/src/plugin/platform/cores/index.d.ts +24 -6
  190. package/dist/plugin/fullscreen/src/plugin/platform/index.d.ts +2 -11
  191. package/dist/plugin/fullscreen/src/plugin/platform/types/index.d.ts +0 -10
  192. package/dist/plugin/fullscreen/src/plugin/platform/types/platform.d.ts +22 -14
  193. package/dist/plugin/fullscreen/src/plugin/theme/cores/index.d.ts +2 -2
  194. package/dist/plugin/fullscreen/src/plugin/theme/index.d.ts +2 -4
  195. package/dist/plugin/fullscreen/src/plugin/theme/types/index.d.ts +0 -10
  196. package/dist/plugin/fullscreen/src/plugin/theme/types/theme.d.ts +3 -1
  197. package/dist/plugin/fullscreen/src/types/native.d.ts +16 -26
  198. package/dist/plugin/platform/index.cjs +409 -488
  199. package/dist/plugin/platform/index.d.ts +4 -96
  200. package/dist/plugin/platform/index.min.cjs +1 -1
  201. package/dist/plugin/platform/index.min.mjs +1 -1
  202. package/dist/plugin/platform/index.mjs +409 -488
  203. package/dist/plugin/platform/index.umd.js +409 -488
  204. package/dist/plugin/platform/index.umd.min.js +1 -1
  205. package/dist/plugin/platform/src/plugin/app/constants/index.d.ts +13 -0
  206. package/dist/plugin/platform/src/plugin/app/cores/index.d.ts +3 -2
  207. package/dist/plugin/platform/src/plugin/app/index.d.ts +2 -11
  208. package/dist/plugin/platform/src/plugin/app/types/app.d.ts +13 -3
  209. package/dist/plugin/platform/src/plugin/app/types/index.d.ts +0 -15
  210. package/dist/plugin/platform/src/plugin/appearance/cores/index.d.ts +2 -2
  211. package/dist/plugin/platform/src/plugin/appearance/index.d.ts +2 -7
  212. package/dist/plugin/platform/src/plugin/appearance/types/appearance.d.ts +6 -3
  213. package/dist/plugin/platform/src/plugin/appearance/types/index.d.ts +0 -12
  214. package/dist/plugin/platform/src/plugin/clipboard/cores/index.d.ts +2 -2
  215. package/dist/plugin/platform/src/plugin/clipboard/index.d.ts +2 -4
  216. package/dist/plugin/platform/src/plugin/clipboard/types/clipboard.d.ts +3 -1
  217. package/dist/plugin/platform/src/plugin/clipboard/types/index.d.ts +0 -10
  218. package/dist/plugin/platform/src/plugin/dimension/cores/index.d.ts +2 -2
  219. package/dist/plugin/platform/src/plugin/dimension/index.d.ts +3 -4
  220. package/dist/plugin/platform/src/plugin/dimension/types/dimensions.d.ts +4 -2
  221. package/dist/plugin/platform/src/plugin/dimension/types/index.d.ts +0 -12
  222. package/dist/plugin/platform/src/plugin/fullscreen/cores/index.d.ts +2 -2
  223. package/dist/plugin/platform/src/plugin/fullscreen/index.d.ts +2 -4
  224. package/dist/plugin/platform/src/plugin/fullscreen/types/fullscreen.d.ts +6 -4
  225. package/dist/plugin/platform/src/plugin/fullscreen/types/index.d.ts +0 -10
  226. package/dist/plugin/platform/src/plugin/platform/constants/index.d.ts +6 -6
  227. package/dist/plugin/platform/src/plugin/platform/cores/index.d.ts +24 -6
  228. package/dist/plugin/platform/src/plugin/platform/index.d.ts +2 -11
  229. package/dist/plugin/platform/src/plugin/platform/types/index.d.ts +0 -10
  230. package/dist/plugin/platform/src/plugin/platform/types/platform.d.ts +22 -14
  231. package/dist/plugin/platform/src/plugin/theme/cores/index.d.ts +2 -2
  232. package/dist/plugin/platform/src/plugin/theme/index.d.ts +2 -4
  233. package/dist/plugin/platform/src/plugin/theme/types/index.d.ts +0 -10
  234. package/dist/plugin/platform/src/plugin/theme/types/theme.d.ts +3 -1
  235. package/dist/plugin/platform/src/types/native.d.ts +16 -26
  236. package/dist/plugin/theme/index.cjs +390 -461
  237. package/dist/plugin/theme/index.d.ts +4 -27
  238. package/dist/plugin/theme/index.min.cjs +1 -1
  239. package/dist/plugin/theme/index.min.mjs +1 -1
  240. package/dist/plugin/theme/index.mjs +390 -461
  241. package/dist/plugin/theme/index.umd.js +390 -461
  242. package/dist/plugin/theme/index.umd.min.js +1 -1
  243. package/dist/plugin/theme/src/plugin/app/constants/index.d.ts +13 -0
  244. package/dist/plugin/theme/src/plugin/app/cores/index.d.ts +3 -2
  245. package/dist/plugin/theme/src/plugin/app/index.d.ts +2 -11
  246. package/dist/plugin/theme/src/plugin/app/types/app.d.ts +13 -3
  247. package/dist/plugin/theme/src/plugin/app/types/index.d.ts +0 -15
  248. package/dist/plugin/theme/src/plugin/appearance/cores/index.d.ts +2 -2
  249. package/dist/plugin/theme/src/plugin/appearance/index.d.ts +2 -7
  250. package/dist/plugin/theme/src/plugin/appearance/types/appearance.d.ts +6 -3
  251. package/dist/plugin/theme/src/plugin/appearance/types/index.d.ts +0 -12
  252. package/dist/plugin/theme/src/plugin/clipboard/cores/index.d.ts +2 -2
  253. package/dist/plugin/theme/src/plugin/clipboard/index.d.ts +2 -4
  254. package/dist/plugin/theme/src/plugin/clipboard/types/clipboard.d.ts +3 -1
  255. package/dist/plugin/theme/src/plugin/clipboard/types/index.d.ts +0 -10
  256. package/dist/plugin/theme/src/plugin/dimension/cores/index.d.ts +2 -2
  257. package/dist/plugin/theme/src/plugin/dimension/index.d.ts +3 -4
  258. package/dist/plugin/theme/src/plugin/dimension/types/dimensions.d.ts +4 -2
  259. package/dist/plugin/theme/src/plugin/dimension/types/index.d.ts +0 -12
  260. package/dist/plugin/theme/src/plugin/fullscreen/cores/index.d.ts +2 -2
  261. package/dist/plugin/theme/src/plugin/fullscreen/index.d.ts +2 -4
  262. package/dist/plugin/theme/src/plugin/fullscreen/types/fullscreen.d.ts +6 -4
  263. package/dist/plugin/theme/src/plugin/fullscreen/types/index.d.ts +0 -10
  264. package/dist/plugin/theme/src/plugin/platform/constants/index.d.ts +6 -6
  265. package/dist/plugin/theme/src/plugin/platform/cores/index.d.ts +24 -6
  266. package/dist/plugin/theme/src/plugin/platform/index.d.ts +2 -11
  267. package/dist/plugin/theme/src/plugin/platform/types/index.d.ts +0 -10
  268. package/dist/plugin/theme/src/plugin/platform/types/platform.d.ts +22 -14
  269. package/dist/plugin/theme/src/plugin/theme/cores/index.d.ts +2 -2
  270. package/dist/plugin/theme/src/plugin/theme/index.d.ts +2 -4
  271. package/dist/plugin/theme/src/plugin/theme/types/index.d.ts +0 -10
  272. package/dist/plugin/theme/src/plugin/theme/types/theme.d.ts +3 -1
  273. package/dist/plugin/theme/src/types/native.d.ts +16 -26
  274. package/dist/src/constants/index.d.ts +1 -0
  275. package/dist/src/errors/not-supported-error.d.ts +2 -0
  276. package/dist/src/errors/permission-not-granted-error.d.ts +2 -0
  277. package/dist/src/plugin/Display/constants/index.d.ts +4 -0
  278. package/dist/src/plugin/Display/cores/index.d.ts +3 -0
  279. package/dist/src/plugin/Display/index.d.ts +3 -0
  280. package/dist/src/plugin/Display/types/display.d.ts +13 -0
  281. package/dist/src/plugin/Display/types/index.d.ts +1 -0
  282. package/dist/src/plugin/app/constants/index.d.ts +21 -0
  283. package/dist/src/plugin/app/cores/index.d.ts +10 -2
  284. package/dist/src/plugin/app/index.d.ts +2 -11
  285. package/dist/src/plugin/app/types/app.d.ts +73 -3
  286. package/dist/src/plugin/app/types/index.d.ts +0 -15
  287. package/dist/src/plugin/appearance/constants/index.d.ts +1 -4
  288. package/dist/src/plugin/appearance/index.d.ts +2 -7
  289. package/dist/src/plugin/appearance/types/appearance.d.ts +5 -2
  290. package/dist/src/plugin/appearance/types/appearanceInstance.d.ts +9 -0
  291. package/dist/src/plugin/appearance/types/index.d.ts +0 -12
  292. package/dist/src/plugin/badge/cores/index.d.ts +3 -0
  293. package/dist/src/plugin/badge/index.d.ts +3 -0
  294. package/dist/src/plugin/badge/types/badge.d.ts +10 -0
  295. package/dist/src/plugin/badge/types/index.d.ts +1 -0
  296. package/dist/src/plugin/battery/cores/index.d.ts +3 -0
  297. package/dist/src/plugin/battery/index.d.ts +3 -0
  298. package/dist/src/plugin/battery/types/battery.d.ts +26 -0
  299. package/dist/src/plugin/battery/types/index.d.ts +1 -0
  300. package/dist/src/plugin/clipboard/index.d.ts +2 -4
  301. package/dist/src/plugin/clipboard/types/clipboard.d.ts +2 -0
  302. package/dist/src/plugin/clipboard/types/index.d.ts +0 -10
  303. package/dist/src/plugin/dimension/constants/index.d.ts +42 -2
  304. package/dist/src/plugin/dimension/index.d.ts +3 -4
  305. package/dist/src/plugin/dimension/types/dimensions.d.ts +24 -1
  306. package/dist/src/plugin/dimension/types/index.d.ts +0 -12
  307. package/dist/src/plugin/dimension/utils/create-env-observer.d.ts +24 -0
  308. package/dist/src/plugin/fullscreen/cores/index.d.ts +3 -1
  309. package/dist/src/plugin/fullscreen/index.d.ts +2 -4
  310. package/dist/src/plugin/fullscreen/types/fullscreen.d.ts +11 -6
  311. package/dist/src/plugin/fullscreen/types/index.d.ts +0 -10
  312. package/dist/src/plugin/geolocation/constants/index.d.ts +2 -0
  313. package/dist/src/plugin/geolocation/cores/index.d.ts +3 -0
  314. package/dist/src/plugin/geolocation/index.d.ts +3 -0
  315. package/dist/src/plugin/geolocation/types/geolocation.d.ts +12 -0
  316. package/dist/src/plugin/geolocation/types/index.d.ts +1 -0
  317. package/dist/src/plugin/network/cores/index.d.ts +15 -0
  318. package/dist/src/plugin/network/index.d.ts +3 -0
  319. package/dist/src/plugin/network/types/index.d.ts +1 -0
  320. package/dist/src/plugin/network/types/network.d.ts +4 -0
  321. package/dist/src/plugin/notification/cores/index.d.ts +3 -0
  322. package/dist/src/plugin/notification/index.d.ts +3 -0
  323. package/dist/src/plugin/notification/types/index.d.ts +1 -0
  324. package/dist/src/plugin/notification/types/notification.d.ts +27 -0
  325. package/dist/src/plugin/open/constants/index.d.ts +28 -0
  326. package/dist/src/plugin/open/cores/index.d.ts +55 -0
  327. package/dist/src/plugin/open/errors/not-supported-error.d.ts +2 -0
  328. package/dist/src/plugin/open/errors/url-open-error.d.ts +2 -0
  329. package/dist/src/plugin/open/errors/user-cancel-error.d.ts +2 -0
  330. package/dist/src/plugin/open/index.d.ts +3 -0
  331. package/dist/src/plugin/open/types/index.d.ts +1 -0
  332. package/dist/src/plugin/open/types/open.d.ts +187 -0
  333. package/dist/src/plugin/permission/constants/index.d.ts +22 -0
  334. package/dist/src/plugin/permission/cores/index.d.ts +3 -0
  335. package/dist/src/plugin/permission/index.d.ts +3 -0
  336. package/dist/src/plugin/permission/types/index.d.ts +1 -0
  337. package/dist/src/plugin/permission/types/permission.d.ts +10 -0
  338. package/dist/src/plugin/pip/cores/index.d.ts +12 -0
  339. package/dist/src/plugin/pip/index.d.ts +3 -0
  340. package/dist/src/plugin/pip/types/index.d.ts +1 -0
  341. package/dist/src/plugin/pip/types/pip.d.ts +15 -0
  342. package/dist/src/plugin/platform/constants/index.d.ts +5 -6
  343. package/dist/src/plugin/platform/cores/index.d.ts +36 -5
  344. package/dist/src/plugin/platform/index.d.ts +2 -11
  345. package/dist/src/plugin/platform/types/index.d.ts +0 -10
  346. package/dist/src/plugin/platform/types/platform.d.ts +31 -14
  347. package/dist/src/plugin/pwa/cores/index.d.ts +3 -0
  348. package/dist/src/plugin/pwa/index.d.ts +3 -0
  349. package/dist/src/plugin/pwa/types/index.d.ts +1 -0
  350. package/dist/src/plugin/pwa/types/pwa.d.ts +8 -0
  351. package/dist/src/plugin/speech/cores/index.d.ts +53 -0
  352. package/dist/src/plugin/speech/index.d.ts +3 -0
  353. package/dist/src/plugin/speech/types/index.d.ts +1 -0
  354. package/dist/src/plugin/speech/types/speech.d.ts +9 -0
  355. package/dist/src/plugin/theme/index.d.ts +2 -4
  356. package/dist/src/plugin/theme/types/index.d.ts +0 -10
  357. package/dist/src/plugin/theme/types/theme.d.ts +2 -0
  358. package/dist/src/plugin/vibration/cores/index.d.ts +3 -0
  359. package/dist/src/plugin/vibration/index.d.ts +3 -0
  360. package/dist/src/plugin/vibration/types/index.d.ts +1 -0
  361. package/dist/src/plugin/vibration/types/vibration.d.ts +9 -0
  362. package/dist/src/types/event-listener.d.ts +35 -0
  363. package/dist/src/types/index.d.ts +3 -0
  364. package/dist/src/types/listener-entry.d.ts +0 -1
  365. package/dist/src/types/native.d.ts +30 -26
  366. package/dist/src/types/subscription-manager.d.ts +4 -0
  367. package/dist/src/utils/create-env-observer.d.ts +8 -0
  368. package/dist/src/utils/create-hidden-element.d.ts +1 -1
  369. package/dist/src/utils/create-subscription-manager.d.ts +2 -0
  370. package/dist/src/utils/defer.d.ts +1 -0
  371. package/dist/src/utils/event-listener.d.ts +3 -0
  372. package/dist/src/utils/keys.d.ts +1 -0
  373. package/dist/src/utils/now.d.ts +1 -0
  374. package/dist/src/utils/pad-start.d.ts +1 -0
  375. package/dist/src/utils/random-string.d.ts +1 -0
  376. package/dist/src/utils/set-style.d.ts +3 -0
  377. package/package.json +1 -1
@@ -213,758 +213,11 @@
213
213
  }
214
214
  };
215
215
 
216
- function compareVersion(lhs, rhs) {
217
- var pa = lhs.split('.');
218
- var pb = rhs.split('.');
219
- var length = Math.max(pa.length, pb.length);
220
- for (var i = 0; i < length; i++) {
221
- var a = void 0;
222
- var b = void 0;
223
- if (i < pa.length)
224
- a = parseInt(pa[i], 10);
225
- else
226
- a = 0;
227
- if (i < pb.length)
228
- b = parseInt(pb[i], 10);
229
- else
230
- b = 0;
231
- if (a > b)
232
- return 1;
233
- if (a < b)
234
- return -1;
235
- }
236
- return 0;
237
- }
238
-
239
- var OS;
240
- (function (OS) {
241
- OS["Unknown"] = "Unknown";
242
- OS["Android"] = "Android";
243
- OS["iOS"] = "iOS";
244
- OS["Windows"] = "Windows";
245
- OS["MacOS"] = "MacOS";
246
- })(OS || (OS = {}));
247
- var Devices;
248
- (function (Devices) {
249
- Devices["Unknown"] = "Unknown";
250
- Devices["Mobile"] = "Mobile";
251
- Devices["Desktop"] = "Desktop";
252
- })(Devices || (Devices = {}));
253
- var Engines;
254
- (function (Engines) {
255
- Engines["Unknown"] = "Unknown";
256
- Engines["EdgeHTML"] = "EdgeHTML";
257
- Engines["ArkWeb"] = "ArkWeb";
258
- Engines["Blink"] = "Blink";
259
- Engines["Presto"] = "Presto";
260
- Engines["WebKit"] = "WebKit";
261
- Engines["Trident"] = "Trident";
262
- Engines["NetFront"] = "NetFront";
263
- Engines["KHTML"] = "KHTML";
264
- Engines["Tasman"] = "Tasman";
265
- Engines["Gecko"] = "Gecko";
266
- })(Engines || (Engines = {}));
267
- var Browsers;
268
- (function (Browsers) {
269
- Browsers["Unknown"] = "Unknown";
270
- Browsers["Chrome"] = "Chrome";
271
- Browsers["Safari"] = "Safari";
272
- Browsers["Edge"] = "Edge";
273
- Browsers["Firefox"] = "Firefox";
274
- Browsers["Opera"] = "Opera";
275
- Browsers["IE"] = "IE";
276
- Browsers["SamsungInternet"] = "SamsungInternet";
277
- })(Browsers || (Browsers = {}));
278
- var CrossPlatformFramework;
279
- (function (CrossPlatformFramework) {
280
- CrossPlatformFramework["Unknown"] = "Unknown";
281
- CrossPlatformFramework["ReactNative"] = "ReactNative";
282
- CrossPlatformFramework["Electron"] = "Electron";
283
- CrossPlatformFramework["Cordova"] = "Cordova";
284
- })(CrossPlatformFramework || (CrossPlatformFramework = {}));
285
- var USER_AGENT = typeof globalThis.navigator !== 'undefined' && typeof globalThis.navigator.userAgent === 'string' ? globalThis.navigator.userAgent : '';
286
- var HIGH_ENTROPY_BRAND_NAME_MAP = {
287
- 'Google Chrome': 'Chrome',
288
- 'Microsoft Edge': 'Edge',
289
- 'Microsoft Edge WebView2': 'Edge WebView2',
290
- 'Android WebView': 'Chrome WebView',
291
- 'HeadlessChrome': 'Chrome Headless',
292
- 'OperaMobile': 'Opera Mobi',
293
- };
294
-
295
- var readyState = 'loading';
296
- var readyCallback = [];
297
- var pendingTasks = 0;
298
- var Platform = {
299
- os: { name: OS.Unknown, version: '' },
300
- engine: { name: Engines.Unknown, version: '' },
301
- browser: { name: Browsers.Unknown, version: '' },
302
- crossPlatformFramework: CrossPlatformFramework.Unknown,
303
- userAgent: USER_AGENT,
304
- get locale() {
305
- return getLocale();
306
- },
307
- get device() {
308
- if (this.os.name === OS.iOS || this.os.name === OS.Android)
309
- return Devices.Mobile;
310
- if (this.os.name === OS.Windows || this.os.name === OS.MacOS)
311
- return Devices.Desktop;
312
- return Devices.Unknown;
313
- },
314
- get renderer() {
315
- return getRenderer();
316
- },
317
- get isWebview() {
318
- return /; ?wv|applewebkit(?!.*safari)/i.test(this.userAgent);
319
- },
320
- get isNode() {
321
- return typeof globalThis.process !== 'undefined' && typeof globalThis.process.versions !== 'undefined' && typeof globalThis.process.versions.node !== 'undefined';
322
- },
323
- get isStandalone() {
324
- if (this.os.name === OS.iOS)
325
- return 'standalone' in globalThis.navigator && !!globalThis.navigator.standalone;
326
- if (!('matchMedia' in globalThis))
327
- return false;
328
- return globalThis.matchMedia('(display-mode: standalone)').matches;
329
- },
330
- onready: function (callback) {
331
- if (readyState === 'complete') {
332
- try {
333
- callback(this);
334
- }
335
- catch (_) {
336
- }
337
- }
338
- else {
339
- readyCallback.push(callback);
340
- }
341
- }
342
- };
343
- function resolveWindowsVersion(string) {
344
- if (typeof string === 'undefined')
345
- return '';
346
- var mapped = {
347
- '4.90': 'ME',
348
- 'NT3.51': 'NT 3.11',
349
- 'NT4.0': 'NT 4.0',
350
- 'NT 5.0': '2000',
351
- 'NT 5.1': 'XP',
352
- 'NT 5.2': 'XP',
353
- 'NT 6.0': 'Vista',
354
- 'NT 6.1': '7',
355
- 'NT 6.2': '8',
356
- 'NT 6.3': '8.1',
357
- 'NT 6.4': '10',
358
- 'NT 10.0': '10',
359
- 'ARM': 'RT'
360
- }[string];
361
- if (typeof mapped !== 'undefined')
362
- return mapped;
363
- return string;
364
- }
365
- function resolveUnderscoreVersion(string) {
366
- if (typeof string === 'undefined')
367
- return '';
368
- return string.replace(/_/g, '.');
369
- }
370
- var OS_RESOLVER_MAP = [
371
- [/windows nt (6\.[23]); arm/i, OS.Windows, resolveWindowsVersion],
372
- [/windows (?:phone|mobile|iot)(?: os)?[\/ ]?([\d.]*( se)?)/i, OS.Windows, resolveWindowsVersion],
373
- [/windows[\/ ](1[01]|2000|3\.1|7|8(\.1)?|9[58]|me|server 20\d\d( r2)?|vista|xp)/i, OS.Windows, resolveWindowsVersion],
374
- [/windows nt ?([\d.)]*)(?!.+xbox)/i, OS.Windows, resolveWindowsVersion],
375
- [/\bwin(?=3| ?9|n)(?:nt| 9x )?([\d.;]*)/i, OS.Windows, resolveWindowsVersion],
376
- [/windows ce\/?([\d.]*)/i, OS.Windows, resolveWindowsVersion],
377
- [/[adehimnop]{4,7}\b(?:.*os (\w+) like mac|; opera)/i, OS.iOS, resolveUnderscoreVersion],
378
- [/(?:ios;fbsv|ios(?=.+ip(?:ad|hone))|ip(?:ad|hone)(?: |.+i(?:pad)?)os)[\/ ]([\w.]+)/i, OS.iOS, resolveUnderscoreVersion],
379
- [/cfnetwork\/.+darwin/i, OS.iOS, resolveUnderscoreVersion],
380
- [/mac os x ?([\w. ]*)/i, OS.MacOS, resolveUnderscoreVersion],
381
- [/(?:macintosh|mac_powerpc\b)(?!.+(haiku|morphos))/i, OS.MacOS, resolveUnderscoreVersion],
382
- [/droid ([\w.]+)\b.+(android[- ]x86)/i, OS.Android],
383
- [/android\w*[-\/.; ]?([\d.]*)/i, OS.Android],
384
- ];
385
- var ENGINE_RESOLVER_MAP = [
386
- [/windows.+ edge\/([\w.]+)/i, Engines.EdgeHTML],
387
- [/arkweb\/([\w.]+)/i, Engines.ArkWeb],
388
- [/webkit\/537\.36.+chrome\/(?!27)([\w.]+)/i, Engines.Blink],
389
- [/presto\/([\w.]+)/i, Engines.Presto],
390
- [/webkit\/([\w.]+)/i, Engines.WebKit],
391
- [/trident\/([\w.]+)/i, Engines.Trident],
392
- [/netfront\/([\w.]+)/i, Engines.NetFront],
393
- [/khtml[\/ ]\(?([\w.]+)/i, Engines.KHTML],
394
- [/tasman[\/ ]\(?([\w.]+)/i, Engines.Tasman],
395
- [/rv:([\w.]{1,9})\b.+gecko/i, Engines.Gecko]
396
- ];
397
- var BROWSER_RESOLVER_MAP = [
398
- [/\b(?:crmo|crios)\/([\w.]+)/i, Browsers.Chrome],
399
- [/webview.+edge\/([\w.]+)/i, Browsers.Edge],
400
- [/edg(?:e|ios|a)?\/([\w.]+)/i, Browsers.Edge],
401
- [/opera mini\/([-\w.]+)/i, Browsers.Opera],
402
- [/opera [mobileta]{3,6}\b.+version\/([-\w.]+)/i, Browsers.Opera],
403
- [/opera(?:.+version\/|[\/ ]+)([\w.]+)/i, Browsers.Opera],
404
- [/opios[\/ ]+([\w.]+)/i, Browsers.Opera],
405
- [/\bop(?:rg)?x\/([\w.]+)/i, Browsers.Opera],
406
- [/\bopr\/([\w.]+)/i, Browsers.Opera],
407
- [/iemobile(?:browser|boat|jet)[\/ ]?([\d.]*)/i, Browsers.IE],
408
- [/(?:ms|\()ie ([\w.]+)/i, Browsers.IE],
409
- [/trident.+rv[: ]([\w.]{1,9})\b.+like gecko/i, Browsers.IE],
410
- [/\bfocus\/([\w.]+)/i, Browsers.Firefox],
411
- [/\bopt\/([\w.]+)/i, Browsers.Opera],
412
- [/coast\/([\w.]+)/i, Browsers.Opera],
413
- [/fxios\/([\w.-]+)/i, Browsers.Firefox],
414
- [/samsungbrowser\/([\w.]+)/i, Browsers.SamsungInternet],
415
- [/headlesschrome(?:\/([\w.]+)| )/i, Browsers.Chrome],
416
- [/wv\).+chrome\/([\w.]+).+edgw\//i, Browsers.Edge],
417
- [/ wv\).+(chrome)\/([\w.]+)/i, Browsers.Chrome],
418
- [/chrome\/([\w.]+) mobile/i, Browsers.Chrome],
419
- [/chrome\/v?([\w.]+)/i, Browsers.Chrome],
420
- [/version\/([\w.,]+) .*mobile(?:\/\w+ | ?)safari/i, Browsers.Safari],
421
- [/iphone .*mobile(?:\/\w+ | ?)safari/i, Browsers.Safari],
422
- [/version\/([\w.,]+) .*safari/i, Browsers.Safari],
423
- [/webkit.+?(?:mobile ?safari|safari)(\/[\w.]+)/i, Browsers.Safari, '1'],
424
- [/(?:mobile|tablet);.*firefox\/([\w.-]+)/i, Browsers.Firefox],
425
- [/mobile vr; rv:([\w.]+)\).+firefox/i, Browsers.Firefox],
426
- [/firefox\/([\w.]+)/i, Browsers.Firefox],
427
- ];
428
- function incrementPendingTasks() {
429
- pendingTasks++;
430
- }
431
- function decrementPendingTasks() {
432
- pendingTasks--;
433
- checkReady();
434
- }
435
- function checkReady() {
436
- if (pendingTasks === 0 && readyState === 'loading') {
437
- readyState = 'complete';
438
- for (var i = 0; i < readyCallback.length; i++) {
439
- try {
440
- readyCallback[i](Platform);
441
- }
442
- catch (_) {
443
- }
444
- }
445
- readyCallback.length = 0;
446
- }
447
- }
448
- function resolveSemanticWindowsVersion(version, defaultValue) {
449
- if (version.major === 10 && version.minor === 0 && version.build >= 22000)
450
- return '11';
451
- if (version.major === 10 && version.minor === 0 && version.build < 22000)
452
- return '10';
453
- if (version.major === 6 && version.minor === 3)
454
- return '8.1';
455
- if (version.major === 6 && version.minor === 2)
456
- return '8';
457
- if (version.major === 6 && version.minor === 1)
458
- return '7';
459
- if (version.major === 6 && version.minor === 0)
460
- return 'Vista';
461
- if (version.major === 5 && version.minor === 1)
462
- return 'XP';
463
- if (version.major === 5 && version.minor === 2)
464
- return 'XP';
465
- if (version.major === 5 && version.minor === 0)
466
- return '2000';
467
- if (version.major === 4 && version.minor === 90)
468
- return 'ME';
469
- if (version.major === 4 && version.minor === 0)
470
- return 'NT 4.0';
471
- if (version.major === 3 && version.minor === 51)
472
- return 'NT 3.11';
473
- return defaultValue;
474
- }
475
- function resolveSemanticDarwinVersion(version, defaultValue) {
476
- if (version.major >= 24)
477
- return '' + (version.major - 9) + '.' + version.minor + '.' + version.build;
478
- if (version.major === 23)
479
- return '14.' + version.minor + '.' + version.build;
480
- if (version.major === 22)
481
- return '13.' + version.minor + '.' + version.build;
482
- if (version.major === 21)
483
- return '12.' + version.minor + '.' + version.build;
484
- if (version.major === 20)
485
- return '11.' + version.minor + '.' + version.build;
486
- if (version.major === 19)
487
- return '10.15.' + version.minor;
488
- if (version.major === 18)
489
- return '10.14.' + version.minor;
490
- if (version.major === 17)
491
- return '10.13.' + version.minor;
492
- if (version.major === 16)
493
- return '10.12.' + version.minor;
494
- if (version.major === 15)
495
- return '10.11.' + version.minor;
496
- if (version.major === 14)
497
- return '10.10.' + version.minor;
498
- if (version.major === 13)
499
- return '10.9.' + version.minor;
500
- if (version.major >= 5 && version.major <= 12)
501
- return '10.' + (version.major - 4) + '.' + version.minor;
502
- return defaultValue;
503
- }
504
- function resolveSemanticAndroidVersion(version, defaultValue) {
505
- if (version.major >= 36)
506
- return '16';
507
- if (version.major === 35)
508
- return '15';
509
- if (version.major === 34)
510
- return '14';
511
- if (version.major === 33)
512
- return '13';
513
- if (version.major === 32)
514
- return '12.1';
515
- if (version.major === 31)
516
- return '12';
517
- if (version.major === 30)
518
- return '11';
519
- if (version.major === 29)
520
- return '10';
521
- if (version.major === 28)
522
- return '9';
523
- if (version.major === 27)
524
- return '8.1';
525
- if (version.major === 26)
526
- return '8.0';
527
- if (version.major === 25)
528
- return '7.1';
529
- if (version.major === 24)
530
- return '7.0';
531
- if (version.major === 23)
532
- return '6.0';
533
- if (version.major === 22)
534
- return '5.1';
535
- if (version.major === 21)
536
- return '5.0';
537
- if (version.major === 20)
538
- return '4.4';
539
- if (version.major === 19)
540
- return '4.4';
541
- if (version.major === 18)
542
- return '4.3';
543
- if (version.major === 17)
544
- return '4.2';
545
- if (version.major === 16)
546
- return '4.1';
547
- if (version.major === 15)
548
- return '4.0.3';
549
- if (version.major === 14)
550
- return '4.0';
551
- if (version.major === 13)
552
- return '3.2';
553
- if (version.major === 12)
554
- return '3.1';
555
- if (version.major === 11)
556
- return '3.0';
557
- if (version.major === 10)
558
- return '2.3.3';
559
- if (version.major === 9)
560
- return '2.3';
561
- if (version.major === 8)
562
- return '2.2';
563
- if (version.major === 7)
564
- return '2.1';
565
- if (version.major === 6)
566
- return '2.0.1';
567
- if (version.major === 5)
568
- return '2.0';
569
- if (version.major === 4)
570
- return '1.6';
571
- if (version.major === 3)
572
- return '1.5';
573
- if (version.major === 2)
574
- return '1.1';
575
- if (version.major === 1)
576
- return '1.0';
577
- return defaultValue;
578
- }
579
- function resolveVersion(string, resolver) {
580
- if (typeof resolver === 'function')
581
- return resolver(string);
582
- if (typeof resolver === 'string')
583
- return resolver;
584
- if (typeof string === 'undefined')
585
- return '';
586
- return string;
587
- }
588
- function normalizeBrand(entry) {
589
- if (entry === null || typeof entry === 'undefined')
590
- return { brand: '', version: '' };
591
- if (typeof entry === 'string')
592
- return { brand: entry, version: '' };
593
- return { brand: entry.brand, version: entry.version };
594
- }
595
- function getSemanticVersion(string) {
596
- var parts = string.split('.');
597
- return {
598
- major: parseInt(parts[0] || '0'),
599
- minor: parseInt(parts[1] || '0'),
600
- build: parseInt(parts[2] || '0')
601
- };
602
- }
603
- function parseOSFromCordova() {
604
- Platform.crossPlatformFramework = CrossPlatformFramework.Cordova;
605
- if (typeof globalThis.device !== 'undefined') {
606
- switch (globalThis.device.platform) {
607
- case 'Android':
608
- Platform.os = {
609
- name: OS.Android,
610
- version: globalThis.device.version,
611
- };
612
- break;
613
- case 'iOS':
614
- Platform.os = {
615
- name: OS.iOS,
616
- version: globalThis.device.version,
617
- };
618
- break;
619
- }
620
- }
621
- decrementPendingTasks();
622
- }
623
- function getRenderer() {
624
- if (typeof globalThis.document === 'undefined')
625
- return '';
626
- var canvas = globalThis.document.createElement('canvas');
627
- if (typeof canvas.getContext !== 'function')
628
- return '';
629
- var context = canvas.getContext('webgl2') || canvas.getContext('experimental-webgl') || canvas.getContext('webgl');
630
- if (context === null)
631
- return '';
632
- if (context instanceof WebGLRenderingContext || 'getParameter' in context && typeof context.getParameter === 'function') {
633
- var extension = context.getExtension('WEBGL_debug_renderer_info');
634
- if (extension === null)
635
- return context.getParameter(context.RENDERER);
636
- else
637
- return context.getParameter(extension.UNMASKED_RENDERER_WEBGL);
638
- }
639
- else {
640
- return '';
641
- }
642
- }
643
- function normalizeLocale(locale) {
644
- if (locale === null || typeof locale === 'undefined')
645
- return locale;
646
- if (locale.length === 0)
647
- return null;
648
- locale = locale.replace(/_/g, '-');
649
- if (locale === 'C' || locale.toLowerCase() === 'posix')
650
- return 'en-US';
651
- if (locale.indexOf('.') !== -1)
652
- return normalizeLocale(locale.split('.')[0]);
653
- if (locale.indexOf('@') !== -1)
654
- return normalizeLocale(locale.split('@')[0]);
655
- var parts = locale.split('-');
656
- if (parts.length === 0)
657
- return null;
658
- parts[0] = parts[0].toLowerCase();
659
- if (parts.length > 1 && parts[1].length === 2)
660
- parts[1] = parts[1].toUpperCase();
661
- if (parts.length > 2 && parts[1].length === 4)
662
- parts[1] = parts[1].charAt(0).toUpperCase() + parts[1].slice(1).toLowerCase();
663
- return parts.join('-');
664
- }
665
- function getLocale() {
666
- var locale = {
667
- language: null,
668
- languages: [],
669
- timezone: null,
670
- timezoneOffset: 0,
671
- };
672
- function addLanguages(language) {
673
- for (var i = 0; i < language.length; i++)
674
- addLanguage(language[i]);
675
- }
676
- function addLanguage(language) {
677
- language = normalizeLocale(language);
678
- if (typeof language === "string" && locale.languages.indexOf(language) === -1) {
679
- if (locale.language === null)
680
- locale.language = language;
681
- locale.languages.push(language);
682
- }
683
- }
684
- if (Platform.crossPlatformFramework === CrossPlatformFramework.ReactNative) {
685
- try {
686
- var reactNative = require('react-native');
687
- var nativeModules = reactNative.NativeModules;
688
- if (typeof nativeModules.SettingsManager !== 'undefined') {
689
- var settingManager = nativeModules.SettingsManager;
690
- if (typeof settingManager !== 'undefined') {
691
- var constant = typeof settingManager.getConstants === 'function'
692
- ? settingManager.getConstants()
693
- : settingManager;
694
- if (typeof constant !== 'undefined' && typeof constant.settings !== 'undefined') {
695
- var settings = constant.settings;
696
- if (typeof settings.AppleLocale === 'string')
697
- addLanguage(settings.AppleLocale);
698
- if (Array.isArray(settings.AppleLanguages) && settings.AppleLanguages.length > 0)
699
- addLanguages(settings.AppleLanguages);
700
- }
701
- }
702
- }
703
- if (typeof nativeModules.I18nManager !== 'undefined') {
704
- var i18nManager = nativeModules.I18nManager;
705
- if (typeof i18nManager !== 'undefined') {
706
- var constant = typeof i18nManager.getConstants === 'function'
707
- ? i18nManager.getConstants()
708
- : i18nManager;
709
- if (typeof constant !== 'undefined' && typeof constant.localeIdentifier !== 'undefined')
710
- addLanguage(constant.localeIdentifier);
711
- }
712
- }
713
- }
714
- catch (_) {
715
- }
716
- }
717
- if (Platform.crossPlatformFramework === CrossPlatformFramework.Electron) {
718
- try {
719
- var electron = require('electron');
720
- var app = electron.app;
721
- if (typeof app.getLocale !== 'undefined')
722
- addLanguage(app.getLocale());
723
- if (typeof app.getSystemLocale !== 'undefined')
724
- addLanguage(app.getSystemLocale());
725
- if (typeof app.getPreferredSystemLanguages !== 'undefined')
726
- addLanguages(app.getPreferredSystemLanguages());
727
- }
728
- catch (_) {
729
- }
730
- }
731
- if (typeof Intl !== 'undefined') {
732
- try {
733
- addLanguage(Intl.DateTimeFormat().resolvedOptions().locale);
734
- }
735
- catch (_) {
736
- }
737
- try {
738
- locale.timezone = Intl.DateTimeFormat().resolvedOptions().timeZone;
739
- }
740
- catch (_) {
741
- }
742
- }
743
- if (typeof globalThis.navigator !== 'undefined') {
744
- if (typeof globalThis.navigator.languages !== 'undefined')
745
- addLanguages(globalThis.navigator.languages);
746
- if (typeof globalThis.navigator.language !== 'undefined')
747
- addLanguage(globalThis.navigator.language);
748
- if (typeof globalThis.navigator.userLanguage !== 'undefined')
749
- addLanguage(globalThis.navigator.userLanguage);
750
- if (typeof globalThis.navigator.browserLanguage !== 'undefined')
751
- addLanguage(globalThis.navigator.browserLanguage);
752
- if (typeof globalThis.navigator.systemLanguage !== 'undefined')
753
- addLanguage(globalThis.navigator.systemLanguage);
754
- }
755
- try {
756
- locale.timezoneOffset = new Date().getTimezoneOffset();
757
- }
758
- catch (_) {
759
- }
760
- return locale;
761
- }
762
- function init() {
763
- if ((typeof globalThis.process !== 'undefined' && typeof globalThis.process.versions !== 'undefined' && typeof globalThis.process.versions.electron !== 'undefined') || (/ electron\//i.test(USER_AGENT)))
764
- Platform.crossPlatformFramework = CrossPlatformFramework.Electron;
765
- if (typeof globalThis.navigator !== 'undefined' && globalThis.navigator.product === 'ReactNative')
766
- Platform.crossPlatformFramework = CrossPlatformFramework.ReactNative;
767
- for (var i = 0; i < OS_RESOLVER_MAP.length; i++) {
768
- var map = OS_RESOLVER_MAP[i];
769
- var regexp = map[0];
770
- var os = map[1];
771
- var resolver = map[2];
772
- var matched = Platform.userAgent.match(regexp);
773
- if (matched !== null) {
774
- Platform.os = {
775
- name: os,
776
- version: resolveVersion(matched[1], resolver),
777
- };
778
- break;
779
- }
780
- }
781
- if (Platform.os.name === OS.iOS && compareVersion(Platform.os.version, '18.6') === 0) {
782
- var version = /\) Version\/([\d.]+)/.exec(Platform.userAgent);
783
- if (version !== null && parseInt(version[1].substring(0, 2), 10) >= 26)
784
- Platform.os.version = version[1];
785
- }
786
- for (var i = 0; i < ENGINE_RESOLVER_MAP.length; i++) {
787
- var map = ENGINE_RESOLVER_MAP[i];
788
- var regexp = map[0];
789
- var engine = map[1];
790
- var resolver = map[2];
791
- var matched = Platform.userAgent.match(regexp);
792
- if (matched !== null) {
793
- Platform.engine = {
794
- name: engine,
795
- version: resolveVersion(matched[1], resolver),
796
- };
797
- break;
798
- }
799
- }
800
- for (var i = 0; i < BROWSER_RESOLVER_MAP.length; i++) {
801
- var map = BROWSER_RESOLVER_MAP[i];
802
- var regexp = map[0];
803
- var browser = map[1];
804
- var resolver = map[2];
805
- var matched = Platform.userAgent.match(regexp);
806
- if (matched !== null) {
807
- Platform.browser = {
808
- name: browser,
809
- version: resolveVersion(matched[1], resolver),
810
- };
811
- break;
812
- }
813
- }
814
- if (Platform.crossPlatformFramework === CrossPlatformFramework.ReactNative) {
815
- try {
816
- var reactNative = require('react-native');
817
- var platform = reactNative.Platform;
818
- var os = platform.OS;
819
- var release = '' + platform.Version;
820
- var version = getSemanticVersion(release);
821
- switch (os) {
822
- case 'android':
823
- Platform.os = {
824
- name: OS.Android,
825
- version: resolveSemanticAndroidVersion(version, release),
826
- };
827
- break;
828
- case 'ios':
829
- Platform.os = {
830
- name: OS.iOS,
831
- version: release,
832
- };
833
- break;
834
- case 'windows':
835
- Platform.os = {
836
- name: OS.Windows,
837
- version: resolveSemanticWindowsVersion(version, release),
838
- };
839
- break;
840
- case 'macos':
841
- Platform.os = {
842
- name: OS.MacOS,
843
- version: release,
844
- };
845
- break;
846
- }
847
- }
848
- catch (_) {
849
- }
850
- finally {
851
- }
852
- }
853
- if (Platform.isNode) {
854
- try {
855
- var os = require('os');
856
- var platform = os.platform();
857
- var release = os.release();
858
- var version = getSemanticVersion(release);
859
- switch (platform) {
860
- case 'win32':
861
- Platform.os = {
862
- name: OS.Windows,
863
- version: resolveSemanticWindowsVersion(version, release),
864
- };
865
- break;
866
- case 'darwin':
867
- Platform.os = {
868
- name: OS.MacOS,
869
- version: resolveSemanticDarwinVersion(version, release),
870
- };
871
- break;
872
- case 'android':
873
- Platform.os = {
874
- name: OS.Android,
875
- version: release,
876
- };
877
- break;
878
- case 'linux':
879
- if (/android/i.test(release)) {
880
- Platform.os = {
881
- name: OS.Android,
882
- version: release,
883
- };
884
- }
885
- break;
886
- }
887
- }
888
- catch (_) {
889
- }
890
- finally {
891
- }
892
- }
893
- if (typeof globalThis.document !== 'undefined') {
894
- if (typeof globalThis.device !== 'undefined') {
895
- parseOSFromCordova();
896
- }
897
- else {
898
- globalThis.document.addEventListener("deviceready", parseOSFromCordova, false);
899
- }
900
- }
901
- if (typeof globalThis.navigator !== 'undefined' && typeof globalThis.navigator.userAgentData !== 'undefined' && typeof globalThis.navigator.userAgentData.getHighEntropyValues !== 'undefined') {
902
- incrementPendingTasks();
903
- globalThis.navigator.userAgentData.getHighEntropyValues(['brands', 'fullVersionList', 'mobile', 'model', 'platform', 'platformVersion', 'architecture', 'formFactors', 'bitness', 'uaFullVersion', 'wow64'])
904
- .then(function (result) {
905
- try {
906
- var brands = result.fullVersionList || result.brands || [];
907
- var platformVersion = result.platformVersion;
908
- var platform = result.platform;
909
- var browserName = Platform.browser.name;
910
- var prevBrandName = null;
911
- for (var i = 0; i < brands.length; i++) {
912
- var brand = normalizeBrand(brands[i]);
913
- var brandVersion = brand.version;
914
- var brandName = brand.brand;
915
- if (/not.a.brand/i.test(brandName))
916
- continue;
917
- if (prevBrandName === null || (/Chrom/.test(prevBrandName) && brandName !== 'Chromium') || (prevBrandName === 'Edge' && /WebView2/.test(brandName))) {
918
- brandName = HIGH_ENTROPY_BRAND_NAME_MAP[brandName] || brandName;
919
- prevBrandName = browserName;
920
- if (prevBrandName === null || /Chrom/.test(prevBrandName) || !/Chrom/.test(brandName)) {
921
- browserName = brandName;
922
- if (browserName === 'Chrome' || browserName === 'Chrome WebView' || browserName === 'Chrome Headless')
923
- Platform.browser.name = Browsers.Chrome;
924
- else if (browserName === 'Edge' || browserName === 'Edge WebView2')
925
- Platform.browser.name = Browsers.Edge;
926
- else if (browserName === 'Opera Mobi')
927
- Platform.browser.name = Browsers.Opera;
928
- Platform.browser.version = brandVersion;
929
- }
930
- prevBrandName = brandName;
931
- }
932
- if (brandName === 'Chromium')
933
- Platform.engine.version = brandVersion;
934
- }
935
- if (typeof platformVersion === 'string') {
936
- if (Platform.os.name === OS.Windows)
937
- Platform.os.version = parseInt(platformVersion.split('.')[0], 10) >= 13 ? '11' : '10';
938
- else
939
- Platform.os.version = platformVersion;
940
- }
941
- if (typeof platform === 'string') {
942
- if (/android/i.test(platform))
943
- Platform.os.name = OS.Android;
944
- else if (/ios|iphone|ipad/i.test(platform))
945
- Platform.os.name = OS.iOS;
946
- else if (/windows|win32/i.test(platform))
947
- Platform.os.name = OS.Windows;
948
- else if (/macos|macintel/i.test(platform))
949
- Platform.os.name = OS.MacOS;
950
- }
951
- if (result.mobile === true)
952
- Platform.device = Devices.Mobile;
953
- }
954
- catch (_) {
955
- }
956
- finally {
957
- decrementPendingTasks();
958
- }
959
- });
960
- }
961
- checkReady();
962
- }
963
- init();
964
-
965
216
  var Clipboard = {
966
217
  copy: copy,
967
- paste: paste
218
+ paste: paste,
219
+ Constants: {},
220
+ Errors: {},
968
221
  };
969
222
  function isObject(item) {
970
223
  return item !== null && typeof item === 'object';
@@ -978,11 +231,18 @@
978
231
  function isElement(item) {
979
232
  return isObject(item) && typeof item.innerText !== 'undefined';
980
233
  }
234
+ function isSelection(item) {
235
+ return Object.prototype.toString.call(item) === '[object Selection]';
236
+ }
981
237
  function convertToString(item) {
982
238
  if (isElement(item)) {
983
- return item.innerHTML;
239
+ if ('value' in item && typeof item.value === 'string')
240
+ return item.value;
241
+ return item.textContent;
984
242
  }
985
- else if (isSerializable(item)) {
243
+ if (isSelection(item))
244
+ return item.toString();
245
+ if (isSerializable(item)) {
986
246
  try {
987
247
  return JSON.stringify(item);
988
248
  }
@@ -995,6 +255,20 @@
995
255
  }
996
256
  return item;
997
257
  }
258
+ function convertToHTML(item) {
259
+ var html = null;
260
+ if (isElement(item))
261
+ html = item.outerHTML;
262
+ if (isSelection(item) && item.rangeCount > 0) {
263
+ var div = globalThis.document.createElement('div');
264
+ for (var i = 0; i < item.rangeCount; i++)
265
+ div.appendChild(item.getRangeAt(i).cloneContents());
266
+ html = div.innerHTML;
267
+ }
268
+ if (html === null)
269
+ return;
270
+ return html;
271
+ }
998
272
  function supportsClipboardAPI() {
999
273
  return (isSecureContext() && typeof navigator !== 'undefined' && 'clipboard' in navigator);
1000
274
  }
@@ -1006,49 +280,28 @@
1006
280
  }
1007
281
  function copy(item) {
1008
282
  var text = convertToString(item);
1009
- if (Platform.crossPlatformFramework === CrossPlatformFramework.Electron) {
1010
- return copyViaElectron(text);
1011
- }
1012
- else if (supportsClipboardWriteAPI()) {
1013
- return copyViaClipboardAPI(text)
283
+ var html = convertToHTML(item);
284
+ if (supportsClipboardWriteAPI()) {
285
+ return copyViaClipboardAPI(text, html)
1014
286
  .then(function (success) {
1015
287
  if (success)
1016
288
  return true;
1017
- return copyViaLegacy(text);
289
+ return copyViaLegacy(text, html);
1018
290
  })
1019
291
  .catch(function () {
1020
- return copyViaLegacy(text);
1021
- });
1022
- }
1023
- return Promise.resolve(copyViaLegacy(text));
1024
- }
1025
- function copyViaElectron(text) {
1026
- try {
1027
- var electron_1 = require('electron');
1028
- return new Promise(function (resolve) {
1029
- try {
1030
- electron_1.clipboard.writeText(text);
1031
- electron_1.clipboard.writeHTML(text);
1032
- resolve(true);
1033
- }
1034
- catch (_) {
1035
- resolve(false);
1036
- }
292
+ return copyViaLegacy(text, html);
1037
293
  });
1038
294
  }
1039
- catch (_) {
1040
- return Promise.resolve(false);
1041
- }
295
+ return Promise.resolve(copyViaLegacy(text, html));
1042
296
  }
1043
- function copyViaClipboardAPI(text) {
297
+ function copyViaClipboardAPI(text, html) {
1044
298
  try {
1045
299
  if ('ClipboardItem' in window && 'write' in navigator.clipboard) {
1046
- return navigator.clipboard.write([
1047
- new ClipboardItem({
1048
- 'text/html': new Blob([text], { type: 'text/html' }),
1049
- 'text/plain': new Blob([text], { type: 'text/plain' })
1050
- })
1051
- ])
300
+ var items = {};
301
+ if (typeof html !== 'undefined')
302
+ items['text/html'] = new Blob([html], { type: 'text/html' });
303
+ items['text/plain'] = new Blob([text], { type: 'text/plain' });
304
+ return navigator.clipboard.write([new ClipboardItem(items)])
1052
305
  .then(function () {
1053
306
  return true;
1054
307
  })
@@ -1071,7 +324,7 @@
1071
324
  }
1072
325
  return Promise.resolve(false);
1073
326
  }
1074
- function copyViaSelection(text) {
327
+ function copyViaSelection(text, html) {
1075
328
  if (!globalThis.getSelection || !globalThis.document.createRange)
1076
329
  return false;
1077
330
  var div = createHiddenElement('div');
@@ -1091,7 +344,8 @@
1091
344
  try {
1092
345
  if (event.clipboardData !== null && typeof event.clipboardData.setData === 'function') {
1093
346
  event.preventDefault();
1094
- event.clipboardData.setData('text/html', text);
347
+ if (typeof html !== 'undefined')
348
+ event.clipboardData.setData('text/html', html);
1095
349
  event.clipboardData.setData('text/plain', text);
1096
350
  }
1097
351
  }
@@ -1116,11 +370,13 @@
1116
370
  return false;
1117
371
  }
1118
372
  }
1119
- function copyViaClipboardData(text) {
373
+ function copyViaClipboardData(text, html) {
1120
374
  var windowWithClipboardData = window;
1121
375
  var clipboardData = windowWithClipboardData.clipboardData;
1122
376
  if (typeof clipboardData !== 'undefined' && typeof clipboardData.setData === 'function') {
1123
377
  try {
378
+ if (typeof html !== 'undefined')
379
+ clipboardData.setData('HTML', html);
1124
380
  return clipboardData.setData('Text', text);
1125
381
  }
1126
382
  catch (_) {
@@ -1129,14 +385,11 @@
1129
385
  }
1130
386
  return false;
1131
387
  }
1132
- function copyViaLegacy(text) {
1133
- return copyViaSelection(text) || copyViaClipboardData(text);
388
+ function copyViaLegacy(text, html) {
389
+ return copyViaSelection(text, html) || copyViaClipboardData(text, html);
1134
390
  }
1135
391
  function paste() {
1136
- if (Platform.crossPlatformFramework === CrossPlatformFramework.Electron) {
1137
- return pasteViaElectron();
1138
- }
1139
- else if (supportsClipboardReadAPI()) {
392
+ if (supportsClipboardReadAPI()) {
1140
393
  return pasteViaClipboardAPI()
1141
394
  .then(function (text) {
1142
395
  if (text !== null)
@@ -1149,25 +402,6 @@
1149
402
  }
1150
403
  return Promise.resolve(pasteViaLegacy());
1151
404
  }
1152
- function pasteViaElectron() {
1153
- try {
1154
- var electron_2 = require('electron');
1155
- return new Promise(function (resolve) {
1156
- try {
1157
- var html = electron_2.clipboard.readHTML();
1158
- if (html)
1159
- return resolve(html.replace(/<meta[^>]*\bcharset\b[^>]*>/i, ''));
1160
- return resolve(electron_2.clipboard.readText() || '');
1161
- }
1162
- catch (_) {
1163
- resolve('');
1164
- }
1165
- });
1166
- }
1167
- catch (_) {
1168
- return Promise.resolve('');
1169
- }
1170
- }
1171
405
  function pasteViaClipboardAPI() {
1172
406
  try {
1173
407
  if ('ClipboardItem' in window && 'read' in navigator.clipboard) {
@@ -1279,14 +513,6 @@
1279
513
  EventListenerUtils.remove(globalThis.document, { type: 'paste', callback: onPaste });
1280
514
  }
1281
515
 
1282
- var NativeClipboardPlugin = {
1283
- installed: false,
1284
- name: 'Clipboard',
1285
- module: Clipboard,
1286
- Constants: {},
1287
- Errors: {}
1288
- };
1289
-
1290
- return NativeClipboardPlugin;
516
+ return Clipboard;
1291
517
 
1292
518
  }));