create-basicjs 0.1.3 → 0.1.5

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 (559) hide show
  1. package/README.md +2 -2
  2. package/bin/create-basicjs.js +31 -4
  3. package/bin/verify-package.js +1 -1
  4. package/package.json +2 -2
  5. package/payload/starter/AGENTS.md +11 -6
  6. package/payload/starter/README.md +1 -1
  7. package/payload/starter/_basic/VERSION +1 -1
  8. package/payload/starter/_basic/assets/cards/almond-blossom.png +0 -0
  9. package/payload/starter/_basic/assets/cards/blackberry.png +0 -0
  10. package/payload/starter/_basic/assets/cards/borage.png +0 -0
  11. package/payload/starter/_basic/assets/cards/chamomile.png +0 -0
  12. package/payload/starter/_basic/assets/cards/dill.png +0 -0
  13. package/payload/starter/_basic/assets/cards/eucalyptus.png +0 -0
  14. package/payload/starter/_basic/assets/cards/fennel.png +0 -0
  15. package/payload/starter/_basic/assets/cards/fig.png +0 -0
  16. package/payload/starter/_basic/assets/cards/juniper.png +0 -0
  17. package/payload/starter/_basic/assets/cards/lavender.png +0 -0
  18. package/payload/starter/_basic/assets/cards/lemon.png +0 -0
  19. package/payload/starter/_basic/assets/cards/olives.png +0 -0
  20. package/payload/starter/_basic/assets/cards/oregano.png +0 -0
  21. package/payload/starter/_basic/assets/cards/pepper.png +0 -0
  22. package/payload/starter/_basic/assets/cards/physalis.png +0 -0
  23. package/payload/starter/_basic/assets/cards/pomegranate.png +0 -0
  24. package/payload/starter/_basic/assets/cards/poppy.png +0 -0
  25. package/payload/starter/_basic/assets/cards/rosehip.png +0 -0
  26. package/payload/starter/_basic/assets/cards/saffron.png +0 -0
  27. package/payload/starter/_basic/assets/categories/cappuccino.png +0 -0
  28. package/payload/starter/_basic/assets/categories/chocolate-milk.png +0 -0
  29. package/payload/starter/_basic/assets/categories/coffee.png +0 -0
  30. package/payload/starter/_basic/assets/categories/frappe.png +0 -0
  31. package/payload/starter/_basic/assets/categories/iced-caffee.png +0 -0
  32. package/payload/starter/_basic/assets/categories/milkshake.png +0 -0
  33. package/payload/starter/_basic/assets/categories/orange-juice.png +0 -0
  34. package/payload/starter/_basic/assets/categories/tea.png +0 -0
  35. package/payload/starter/_basic/assets/fruids/brokoli.png +0 -0
  36. package/payload/starter/_basic/assets/fruids/cilek.png +0 -0
  37. package/payload/starter/_basic/assets/fruids/domates.png +0 -0
  38. package/payload/starter/_basic/assets/fruids/elma.png +0 -0
  39. package/payload/starter/_basic/assets/fruids/havuc.png +0 -0
  40. package/payload/starter/_basic/assets/fruids/karpuz.png +0 -0
  41. package/payload/starter/_basic/assets/fruids/limon.png +0 -0
  42. package/payload/starter/_basic/assets/fruids/muz.png +0 -0
  43. package/payload/starter/_basic/assets/fruids/nar.png +0 -0
  44. package/payload/starter/_basic/assets/fruids/patlican.png +0 -0
  45. package/payload/starter/_basic/assets/fruids/yabanmersini.png +0 -0
  46. package/payload/starter/_basic/assets/fruids/yesilbiber.png +0 -0
  47. package/payload/starter/_basic/basic/LICENSE +1 -1
  48. package/payload/starter/_basic/basic/basic.css +3 -6
  49. package/payload/starter/_basic/basic/basic.js +154 -60
  50. package/payload/starter/_basic/basic/basic.min.js +19 -6
  51. package/payload/starter/_basic/basic/scroll-bar.js +4 -2
  52. package/payload/starter/_basic/basic/scroll-bar.min.js +1 -0
  53. package/payload/starter/_basic/comp/accordion.js +659 -0
  54. package/payload/starter/_basic/comp/action-button.js +22 -23
  55. package/payload/starter/_basic/comp/action-tab-bar.js +8 -8
  56. package/payload/starter/_basic/comp/app-bar.js +12 -11
  57. package/payload/starter/_basic/comp/{badge-v2.js → badge.js} +51 -5
  58. package/payload/starter/_basic/comp/bottom-bar.js +31 -23
  59. package/payload/starter/_basic/comp/breadcrumbs.js +4 -2
  60. package/payload/starter/_basic/comp/canvas.js +652 -0
  61. package/payload/starter/_basic/comp/chat-view.js +827 -0
  62. package/payload/starter/_basic/comp/check-box.js +137 -21
  63. package/payload/starter/_basic/comp/code-editor.js +953 -0
  64. package/payload/starter/_basic/comp/{select-color.js → color-picker.js} +62 -29
  65. package/payload/starter/_basic/comp/context-menu.js +342 -30
  66. package/payload/starter/_basic/comp/{currency-input-b.js → currency-field.js} +48 -29
  67. package/payload/starter/_basic/comp/data-table.js +114 -42
  68. package/payload/starter/_basic/comp/{select-date.js → date-picker.js} +104 -52
  69. package/payload/starter/_basic/comp/dialog.js +214 -76
  70. package/payload/starter/_basic/comp/email-field.js +65 -0
  71. package/payload/starter/_basic/comp/{select-file.js → file-picker.js} +245 -57
  72. package/payload/starter/_basic/comp/filters.js +374 -60
  73. package/payload/starter/_basic/comp/form.js +38 -26
  74. package/payload/starter/_basic/comp/full-screen-select.js +36 -33
  75. package/payload/starter/_basic/comp/gauge.js +12 -8
  76. package/payload/starter/_basic/comp/graph-box.js +3911 -0
  77. package/payload/starter/_basic/comp/grid-group.js +185 -0
  78. package/payload/starter/_basic/comp/hold-to-confirm-button.js +16 -7
  79. package/payload/starter/_basic/comp/image-view.js +598 -0
  80. package/payload/starter/_basic/comp/item-list.js +507 -163
  81. package/payload/starter/_basic/comp/json-editor.js +3221 -0
  82. package/payload/starter/_basic/comp/json-view.js +597 -0
  83. package/payload/starter/_basic/comp/label-editor.js +22 -19
  84. package/payload/starter/_basic/comp/left-menu.js +97 -25
  85. package/payload/starter/_basic/comp/line-progress-bar.js +196 -45
  86. package/payload/starter/_basic/comp/loading-screen.js +49 -18
  87. package/payload/starter/_basic/comp/log-view.js +530 -0
  88. package/payload/starter/_basic/comp/{login-page-v2.js → login-page.js} +205 -106
  89. package/payload/starter/_basic/comp/markdown-view.js +1044 -0
  90. package/payload/starter/_basic/comp/menu-bar.js +624 -0
  91. package/payload/starter/_basic/comp/mini-graph-box.js +20 -11
  92. package/payload/starter/_basic/comp/minimal-accent.js +208 -0
  93. package/payload/starter/_basic/comp/notice.js +15 -13
  94. package/payload/starter/_basic/comp/{number-input-b.js → number-field.js} +26 -19
  95. package/payload/starter/_basic/comp/numeric-keyboard.js +15 -13
  96. package/payload/starter/_basic/comp/page-control.js +21 -4
  97. package/payload/starter/_basic/comp/page-header.js +7 -6
  98. package/payload/starter/_basic/comp/password-field.js +192 -0
  99. package/payload/starter/_basic/comp/period-bar.js +8 -7
  100. package/payload/starter/_basic/comp/{phone-input-b.js → phone-field.js} +80 -45
  101. package/payload/starter/_basic/comp/progress-bar.js +401 -85
  102. package/payload/starter/_basic/comp/property-panel.js +1022 -123
  103. package/payload/starter/_basic/comp/radio-button.js +79 -19
  104. package/payload/starter/_basic/comp/range-slider.js +569 -0
  105. package/payload/starter/_basic/comp/rich-text-editor.js +33 -30
  106. package/payload/starter/_basic/comp/scroll-area.js +308 -0
  107. package/payload/starter/_basic/comp/scrolling-text.js +10 -9
  108. package/payload/starter/_basic/comp/search-input.js +725 -0
  109. package/payload/starter/_basic/comp/search-results.js +60 -24
  110. package/payload/starter/_basic/comp/select-box.js +229 -107
  111. package/payload/starter/_basic/comp/settings-row.js +20 -19
  112. package/payload/starter/_basic/comp/side-panel.js +53 -10
  113. package/payload/starter/_basic/comp/slider-field.js +264 -88
  114. package/payload/starter/_basic/comp/slider.js +541 -86
  115. package/payload/starter/_basic/comp/smart-button.js +433 -352
  116. package/payload/starter/_basic/comp/smart-table.js +740 -185
  117. package/payload/starter/_basic/comp/sortable-list.js +47 -38
  118. package/payload/starter/_basic/comp/spark-line-box.js +25 -16
  119. package/payload/starter/_basic/comp/splitter.js +411 -0
  120. package/payload/starter/_basic/comp/status-bar.js +408 -0
  121. package/payload/starter/_basic/comp/step-bar.js +345 -0
  122. package/payload/starter/_basic/comp/stepper.js +77 -49
  123. package/payload/starter/_basic/comp/tabs.js +67 -18
  124. package/payload/starter/_basic/comp/tag-input.js +50 -10
  125. package/payload/starter/_basic/comp/tap-effect.js +6 -4
  126. package/payload/starter/_basic/comp/text-area-field.js +233 -0
  127. package/payload/starter/_basic/comp/text-field.js +1006 -0
  128. package/payload/starter/_basic/comp/time-line.js +102 -28
  129. package/payload/starter/_basic/comp/{select-time.js → time-picker.js} +104 -51
  130. package/payload/starter/_basic/comp/tiny-select.js +79 -39
  131. package/payload/starter/_basic/comp/tiny-table.js +12 -8
  132. package/payload/starter/_basic/comp/toast.js +87 -34
  133. package/payload/starter/_basic/comp/toggle.js +147 -27
  134. package/payload/starter/_basic/comp/tool-bar.js +760 -0
  135. package/payload/starter/_basic/comp/tooltip.js +80 -17
  136. package/payload/starter/_basic/comp/tree-view.js +124 -41
  137. package/payload/starter/_basic/comp/ui-effects.js +17 -11
  138. package/payload/starter/_basic/comp/ui-standards.js +5 -4
  139. package/payload/starter/_basic/comp/url-field.js +190 -0
  140. package/payload/starter/_basic/comp/web-view.js +70 -16
  141. package/payload/starter/_basic/docs/basic-js-animated-rules.md +15 -9
  142. package/payload/starter/_basic/docs/basic-js-code-rules.md +42 -5
  143. package/payload/starter/_basic/docs/basic-js-components.md +12 -17
  144. package/payload/starter/_basic/docs/basic-js-core.md +5 -4
  145. package/payload/starter/_basic/docs/component-index.md +245 -104
  146. package/payload/starter/_basic/docs/component-template.js +28 -24
  147. package/payload/starter/_basic/docs/handbook/00-introduction.md +6 -2
  148. package/payload/starter/_basic/docs/handbook/00-what-is-new.md +21 -0
  149. package/payload/starter/_basic/docs/handbook/01-label.md +4 -4
  150. package/payload/starter/_basic/docs/handbook/02-box.md +7 -7
  151. package/payload/starter/_basic/docs/handbook/03-image.md +4 -4
  152. package/payload/starter/_basic/docs/handbook/04-common-properties.md +6 -5
  153. package/payload/starter/_basic/docs/handbook/05-autolayout.md +8 -7
  154. package/payload/starter/_basic/docs/handbook/06-button.md +3 -3
  155. package/payload/starter/_basic/docs/handbook/07-input.md +3 -3
  156. package/payload/starter/_basic/docs/handbook/08-page.md +3 -3
  157. package/payload/starter/_basic/docs/handbook/09-useful-examples.md +39 -58
  158. package/payload/starter/_basic/docs/handbook/10-motion.md +6 -6
  159. package/payload/starter/_basic/docs/handbook/11-other-functions.md +1 -0
  160. package/payload/starter/_basic/docs/handbook/13-sound.md +3 -3
  161. package/payload/starter/_basic/docs/handbook/14-using-components.md +180 -0
  162. package/payload/starter/_basic/docs/handbook/15-making-a-component.md +338 -0
  163. package/payload/starter/_basic/docs/what-is-new.md +106 -0
  164. package/payload/starter/_basic/examples/accordion.htm +174 -0
  165. package/payload/starter/_basic/examples/action-button.htm +74 -32
  166. package/payload/starter/_basic/examples/action-tab-bar.htm +5 -6
  167. package/payload/starter/_basic/examples/app-bar.htm +63 -41
  168. package/payload/starter/_basic/examples/badge.htm +96 -0
  169. package/payload/starter/_basic/examples/bottom-bar-2.htm +61 -48
  170. package/payload/starter/_basic/examples/bottom-bar.htm +74 -16
  171. package/payload/starter/_basic/examples/breadcrumbs.htm +160 -150
  172. package/payload/starter/_basic/examples/canvas.htm +190 -0
  173. package/payload/starter/_basic/examples/chat-view.htm +143 -0
  174. package/payload/starter/_basic/examples/check-box-2.htm +71 -82
  175. package/payload/starter/_basic/examples/check-box-3.htm +72 -83
  176. package/payload/starter/_basic/examples/check-box.htm +207 -0
  177. package/payload/starter/_basic/examples/code-editor-2.htm +259 -0
  178. package/payload/starter/_basic/examples/code-editor.htm +225 -0
  179. package/payload/starter/_basic/examples/color-picker.htm +206 -0
  180. package/payload/starter/_basic/examples/context-menu.htm +180 -139
  181. package/payload/starter/_basic/examples/currency-field.htm +105 -0
  182. package/payload/starter/_basic/examples/data-table-2.htm +2 -1
  183. package/payload/starter/_basic/examples/data-table-3.htm +1 -1
  184. package/payload/starter/_basic/examples/data-table-4.htm +15 -12
  185. package/payload/starter/_basic/examples/data-table-5.htm +11 -3
  186. package/payload/starter/_basic/examples/data-table.htm +90 -40
  187. package/payload/starter/_basic/examples/date-picker.htm +239 -0
  188. package/payload/starter/_basic/examples/dialog-centered.htm +394 -40
  189. package/payload/starter/_basic/examples/dialog.htm +267 -46
  190. package/payload/starter/_basic/examples/email-field.htm +102 -0
  191. package/payload/starter/_basic/examples/file-picker.htm +296 -0
  192. package/payload/starter/_basic/examples/filters.htm +33 -22
  193. package/payload/starter/_basic/examples/{form-1.htm → form.htm} +18 -19
  194. package/payload/starter/_basic/examples/full-screen-select.htm +81 -58
  195. package/payload/starter/_basic/examples/gauge.htm +95 -81
  196. package/payload/starter/_basic/examples/graph-box.htm +365 -0
  197. package/payload/starter/_basic/examples/grid-group.htm +179 -0
  198. package/payload/starter/_basic/examples/hold-to-confirm-button.htm +102 -113
  199. package/payload/starter/_basic/examples/image-view.htm +195 -0
  200. package/payload/starter/_basic/examples/item-list-2.htm +138 -94
  201. package/payload/starter/_basic/examples/item-list.htm +191 -86
  202. package/payload/starter/_basic/examples/json-editor.htm +206 -0
  203. package/payload/starter/_basic/examples/json-view.htm +153 -0
  204. package/payload/starter/_basic/examples/label-editor.htm +85 -89
  205. package/payload/starter/_basic/examples/left-menu-2.htm +93 -0
  206. package/payload/starter/_basic/examples/left-menu.htm +42 -37
  207. package/payload/starter/_basic/examples/line-progress-bar.htm +155 -114
  208. package/payload/starter/_basic/examples/loading-screen.htm +149 -125
  209. package/payload/starter/_basic/examples/log-view.htm +175 -0
  210. package/payload/starter/_basic/examples/{login-page-dark-v2.htm → login-page-dark.htm} +265 -267
  211. package/payload/starter/_basic/examples/{login-page-v2.htm → login-page.htm} +266 -267
  212. package/payload/starter/_basic/examples/markdown-view.htm +220 -0
  213. package/payload/starter/_basic/examples/menu-bar-2.htm +225 -0
  214. package/payload/starter/_basic/examples/menu-bar.htm +145 -0
  215. package/payload/starter/_basic/examples/mini-graph-box.htm +98 -109
  216. package/payload/starter/_basic/examples/minimal-accent.htm +196 -0
  217. package/payload/starter/_basic/examples/minimal-theme.htm +432 -0
  218. package/payload/starter/_basic/examples/notice.htm +13 -4
  219. package/payload/starter/_basic/examples/number-field.htm +103 -0
  220. package/payload/starter/_basic/examples/numeric-keyboard.htm +44 -42
  221. package/payload/starter/_basic/examples/page-control.htm +181 -130
  222. package/payload/starter/_basic/examples/page-header.htm +57 -30
  223. package/payload/starter/_basic/examples/password-field.htm +117 -0
  224. package/payload/starter/_basic/examples/period-bar.htm +43 -29
  225. package/payload/starter/_basic/examples/phone-field-select-country.htm +292 -0
  226. package/payload/starter/_basic/examples/phone-field.htm +104 -0
  227. package/payload/starter/_basic/examples/progress-bar-ozden.htm +229 -92
  228. package/payload/starter/_basic/examples/progress-bar.htm +222 -174
  229. package/payload/starter/_basic/examples/property-panel.htm +152 -52
  230. package/payload/starter/_basic/examples/radio-button-2.htm +101 -109
  231. package/payload/starter/_basic/examples/radio-button-3.htm +81 -71
  232. package/payload/starter/_basic/examples/radio-button.htm +289 -0
  233. package/payload/starter/_basic/examples/range-slider.htm +171 -0
  234. package/payload/starter/_basic/examples/rich-text-editor.htm +115 -110
  235. package/payload/starter/_basic/examples/scroll-area.htm +293 -0
  236. package/payload/starter/_basic/examples/scrolling-text.htm +27 -6
  237. package/payload/starter/_basic/examples/search-input-2-light.htm +112 -0
  238. package/payload/starter/_basic/examples/search-input-3-dark.htm +105 -0
  239. package/payload/starter/_basic/examples/{search-input-v2-place.htm → search-input-place.htm} +25 -26
  240. package/payload/starter/_basic/examples/search-input.htm +159 -0
  241. package/payload/starter/_basic/examples/search-results.htm +85 -88
  242. package/payload/starter/_basic/examples/select-box-ozden-dark-text.htm +70 -0
  243. package/payload/starter/_basic/examples/select-box-ozden-item.htm +6 -5
  244. package/payload/starter/_basic/examples/select-box-ozden-text.htm +5 -3
  245. package/payload/starter/_basic/examples/select-box.htm +190 -159
  246. package/payload/starter/_basic/examples/settings-row.htm +92 -43
  247. package/payload/starter/_basic/examples/side-panel-2.htm +63 -25
  248. package/payload/starter/_basic/examples/side-panel.htm +84 -70
  249. package/payload/starter/_basic/examples/slider-2-classic.htm +152 -0
  250. package/payload/starter/_basic/examples/slider-field-ozden.htm +286 -0
  251. package/payload/starter/_basic/examples/slider-field.htm +174 -134
  252. package/payload/starter/_basic/examples/slider.htm +257 -180
  253. package/payload/starter/_basic/examples/smart-button-3-ozden.htm +170 -257
  254. package/payload/starter/_basic/examples/smart-button-4-dark.htm +86 -47
  255. package/payload/starter/_basic/examples/smart-button-5-features.htm +130 -125
  256. package/payload/starter/_basic/examples/smart-button-alternatif.htm +266 -0
  257. package/payload/starter/_basic/examples/smart-button.htm +207 -174
  258. package/payload/starter/_basic/examples/smart-table-2.htm +43 -56
  259. package/payload/starter/_basic/examples/smart-table-3.htm +148 -113
  260. package/payload/starter/_basic/examples/smart-table-4.htm +37 -50
  261. package/payload/starter/_basic/examples/{smart-table-1.htm → smart-table-5.htm} +37 -48
  262. package/payload/starter/_basic/examples/smart-table.htm +183 -0
  263. package/payload/starter/_basic/examples/sortable-list.htm +191 -142
  264. package/payload/starter/_basic/examples/spark-line-box.htm +149 -161
  265. package/payload/starter/_basic/examples/splitter.htm +164 -0
  266. package/payload/starter/_basic/examples/status-bar.htm +166 -0
  267. package/payload/starter/_basic/examples/step-bar.htm +129 -0
  268. package/payload/starter/_basic/examples/stepper-2.htm +71 -59
  269. package/payload/starter/_basic/examples/stepper.htm +146 -135
  270. package/payload/starter/_basic/examples/tabs-2.htm +58 -67
  271. package/payload/starter/_basic/examples/tabs.htm +197 -180
  272. package/payload/starter/_basic/examples/tag-input.htm +150 -153
  273. package/payload/starter/_basic/examples/tap-effect.htm +23 -19
  274. package/payload/starter/_basic/examples/text-area-field.htm +104 -0
  275. package/payload/starter/_basic/examples/text-field-2.htm +113 -0
  276. package/payload/starter/_basic/examples/text-field-3-style.htm +105 -0
  277. package/payload/starter/_basic/examples/text-field-4-custom-unit.htm +96 -0
  278. package/payload/starter/_basic/examples/{input-b-ex5-warning-icon.htm → text-field-5-warning-icon.htm} +19 -19
  279. package/payload/starter/_basic/examples/text-field-6-modern-dark.htm +114 -0
  280. package/payload/starter/_basic/examples/text-field-7-modern.htm +106 -0
  281. package/payload/starter/_basic/examples/text-field-8-light-dark.htm +159 -0
  282. package/payload/starter/_basic/examples/text-field.htm +163 -0
  283. package/payload/starter/_basic/examples/time-line.htm +180 -116
  284. package/payload/starter/_basic/examples/time-picker.htm +240 -0
  285. package/payload/starter/_basic/examples/tiny-select.htm +118 -86
  286. package/payload/starter/_basic/examples/tiny-table.htm +40 -34
  287. package/payload/starter/_basic/examples/toast.htm +145 -147
  288. package/payload/starter/_basic/examples/toggle-2.htm +99 -68
  289. package/payload/starter/_basic/examples/toggle-3.htm +104 -101
  290. package/payload/starter/_basic/examples/toggle.htm +161 -93
  291. package/payload/starter/_basic/examples/tool-bar.htm +172 -0
  292. package/payload/starter/_basic/examples/tooltip-2.htm +110 -60
  293. package/payload/starter/_basic/examples/tooltip-3.htm +124 -65
  294. package/payload/starter/_basic/examples/tooltip-4.htm +218 -0
  295. package/payload/starter/_basic/examples/tooltip.htm +206 -124
  296. package/payload/starter/_basic/examples/tree-view.htm +210 -182
  297. package/payload/starter/_basic/examples/ui-effects.htm +207 -185
  298. package/payload/starter/_basic/examples/ui-standards.htm +200 -139
  299. package/payload/starter/_basic/examples/url-field.htm +120 -0
  300. package/payload/starter/_basic/examples/web-view.htm +109 -110
  301. package/payload/starter/_basic/min/accordion.min.js +2 -0
  302. package/payload/starter/_basic/min/action-button.min.js +1 -1
  303. package/payload/starter/_basic/min/app-bar.min.js +1 -1
  304. package/payload/starter/_basic/min/badge.min.js +2 -0
  305. package/payload/starter/_basic/min/bottom-bar.min.js +1 -1
  306. package/payload/starter/_basic/min/canvas.min.js +2 -0
  307. package/payload/starter/_basic/min/chat-view.min.js +2 -0
  308. package/payload/starter/_basic/min/check-box.min.js +1 -1
  309. package/payload/starter/_basic/min/code-editor.min.js +2 -0
  310. package/payload/starter/_basic/min/color-picker.min.js +2 -0
  311. package/payload/starter/_basic/min/context-menu.min.js +1 -1
  312. package/payload/starter/_basic/min/currency-field.min.js +2 -0
  313. package/payload/starter/_basic/min/data-table.min.js +1 -1
  314. package/payload/starter/_basic/min/date-picker.min.js +2 -0
  315. package/payload/starter/_basic/min/dialog.min.js +1 -1
  316. package/payload/starter/_basic/min/email-field.min.js +2 -0
  317. package/payload/starter/_basic/min/file-picker.min.js +2 -0
  318. package/payload/starter/_basic/min/filters.min.js +1 -1
  319. package/payload/starter/_basic/min/form.min.js +1 -1
  320. package/payload/starter/_basic/min/full-screen-select.min.js +1 -1
  321. package/payload/starter/_basic/min/gauge.min.js +1 -1
  322. package/payload/starter/_basic/min/graph-box.min.js +2 -0
  323. package/payload/starter/_basic/min/grid-group.min.js +2 -0
  324. package/payload/starter/_basic/min/hold-to-confirm-button.min.js +1 -1
  325. package/payload/starter/_basic/min/image-view.min.js +2 -0
  326. package/payload/starter/_basic/min/item-list.min.js +1 -1
  327. package/payload/starter/_basic/min/json-editor.min.js +2 -0
  328. package/payload/starter/_basic/min/json-view.min.js +2 -0
  329. package/payload/starter/_basic/min/label-editor.min.js +1 -1
  330. package/payload/starter/_basic/min/left-menu.min.js +1 -1
  331. package/payload/starter/_basic/min/line-progress-bar.min.js +1 -1
  332. package/payload/starter/_basic/min/loading-screen.min.js +1 -1
  333. package/payload/starter/_basic/min/log-view.min.js +2 -0
  334. package/payload/starter/_basic/min/login-page.min.js +2 -0
  335. package/payload/starter/_basic/min/markdown-view.min.js +2 -0
  336. package/payload/starter/_basic/min/menu-bar.min.js +2 -0
  337. package/payload/starter/_basic/min/mini-graph-box.min.js +1 -1
  338. package/payload/starter/_basic/min/minimal-accent.min.js +2 -0
  339. package/payload/starter/_basic/min/notice.min.js +1 -1
  340. package/payload/starter/_basic/min/number-field.min.js +2 -0
  341. package/payload/starter/_basic/min/numeric-keyboard.min.js +1 -1
  342. package/payload/starter/_basic/min/page-control.min.js +1 -1
  343. package/payload/starter/_basic/min/password-field.min.js +2 -0
  344. package/payload/starter/_basic/min/phone-field.min.js +2 -0
  345. package/payload/starter/_basic/min/progress-bar.min.js +1 -1
  346. package/payload/starter/_basic/min/property-panel.min.js +1 -1
  347. package/payload/starter/_basic/min/radio-button.min.js +1 -1
  348. package/payload/starter/_basic/min/range-slider.min.js +2 -0
  349. package/payload/starter/_basic/min/rich-text-editor.min.js +1 -1
  350. package/payload/starter/_basic/min/scroll-area.min.js +2 -0
  351. package/payload/starter/_basic/min/scrolling-text.min.js +1 -1
  352. package/payload/starter/_basic/min/search-input.min.js +2 -0
  353. package/payload/starter/_basic/min/search-results.min.js +1 -1
  354. package/payload/starter/_basic/min/select-box.min.js +1 -1
  355. package/payload/starter/_basic/min/settings-row.min.js +1 -1
  356. package/payload/starter/_basic/min/side-panel.min.js +1 -1
  357. package/payload/starter/_basic/min/slider-field.min.js +1 -1
  358. package/payload/starter/_basic/min/slider.min.js +1 -1
  359. package/payload/starter/_basic/min/smart-button.min.js +1 -1
  360. package/payload/starter/_basic/min/smart-table.min.js +1 -1
  361. package/payload/starter/_basic/min/sortable-list.min.js +1 -1
  362. package/payload/starter/_basic/min/spark-line-box.min.js +1 -1
  363. package/payload/starter/_basic/min/splitter.min.js +2 -0
  364. package/payload/starter/_basic/min/status-bar.min.js +2 -0
  365. package/payload/starter/_basic/min/step-bar.min.js +2 -0
  366. package/payload/starter/_basic/min/stepper.min.js +1 -1
  367. package/payload/starter/_basic/min/tabs.min.js +1 -1
  368. package/payload/starter/_basic/min/tag-input.min.js +1 -1
  369. package/payload/starter/_basic/min/text-area-field.min.js +2 -0
  370. package/payload/starter/_basic/min/text-field.min.js +2 -0
  371. package/payload/starter/_basic/min/time-line.min.js +1 -1
  372. package/payload/starter/_basic/min/time-picker.min.js +2 -0
  373. package/payload/starter/_basic/min/tiny-select.min.js +1 -1
  374. package/payload/starter/_basic/min/toast.min.js +1 -1
  375. package/payload/starter/_basic/min/toggle.min.js +1 -1
  376. package/payload/starter/_basic/min/tool-bar.min.js +2 -0
  377. package/payload/starter/_basic/min/tooltip.min.js +1 -1
  378. package/payload/starter/_basic/min/tree-view.min.js +1 -1
  379. package/payload/starter/_basic/min/ui-effects.min.js +1 -1
  380. package/payload/starter/_basic/min/url-field.min.js +2 -0
  381. package/payload/starter/_basic/min/web-view.min.js +1 -1
  382. package/payload/templates/booking/app/app.js +11 -8
  383. package/payload/templates/booking/app/settings.js +4 -4
  384. package/payload/templates/booking/index.htm +3 -3
  385. package/payload/templates/booking/pages/account.js +6 -6
  386. package/payload/templates/booking/pages/book.js +1 -1
  387. package/payload/templates/booking/pages/services.js +5 -4
  388. package/payload/templates/classic/app/app.js +15 -11
  389. package/payload/templates/classic/app/settings.js +22 -20
  390. package/payload/templates/classic/assets/_attribute.txt +2 -0
  391. package/payload/templates/classic/assets/cards/dill.png +0 -0
  392. package/payload/templates/classic/assets/cards/fennel.png +0 -0
  393. package/payload/templates/classic/assets/cards/juniper.png +0 -0
  394. package/payload/templates/classic/assets/cards/olives.png +0 -0
  395. package/payload/templates/classic/assets/cards/oregano.png +0 -0
  396. package/payload/templates/classic/assets/cards/pepper.png +0 -0
  397. package/payload/templates/classic/assets/cards/rosehip.png +0 -0
  398. package/payload/templates/classic/assets/categories/cappuccino.png +0 -0
  399. package/payload/templates/classic/assets/categories/chocolate-milk.png +0 -0
  400. package/payload/templates/classic/assets/categories/coffee.png +0 -0
  401. package/payload/templates/classic/assets/categories/frappe.png +0 -0
  402. package/payload/templates/classic/assets/categories/iced-caffee.png +0 -0
  403. package/payload/templates/classic/assets/categories/milkshake.png +0 -0
  404. package/payload/templates/classic/assets/categories/orange-juice.png +0 -0
  405. package/payload/templates/classic/assets/categories/tea.png +0 -0
  406. package/payload/templates/classic/index.htm +2 -2
  407. package/payload/templates/classic/pages/example.js +10 -10
  408. package/payload/templates/classic/pages/examples.js +44 -43
  409. package/payload/templates/classic/pages/home.js +16 -15
  410. package/payload/templates/classic/pages/info-pages.js +5 -5
  411. package/payload/templates/classic/pages/search.js +8 -7
  412. package/payload/templates/classic/pages/settings.js +13 -13
  413. package/payload/templates/classic/pages/tasks.js +1 -0
  414. package/payload/templates/classic/pages/template-pages.js +12 -11
  415. package/payload/templates/coffee-shop/app/app.js +12 -8
  416. package/payload/templates/coffee-shop/app/settings.js +4 -4
  417. package/payload/templates/coffee-shop/index.htm +3 -3
  418. package/payload/templates/coffee-shop/pages/drink.js +1 -1
  419. package/payload/templates/coffee-shop/pages/menu.js +5 -4
  420. package/payload/templates/forms/TEMPLATE.md +1 -1
  421. package/payload/templates/forms/appointment-form.htm +55 -53
  422. package/payload/templates/forms/contact-form-to-mail.htm +38 -37
  423. package/payload/templates/forms/contact-form-to-supabase.htm +47 -46
  424. package/payload/templates/forms/dark-contact-form.htm +43 -40
  425. package/payload/templates/forms/event-registration-form.htm +80 -77
  426. package/payload/templates/forms/feedback-form.htm +54 -54
  427. package/payload/templates/forms/order-form.htm +88 -84
  428. package/payload/templates/forms/recruitment-form.htm +60 -60
  429. package/payload/templates/forms/service/readme.md +9 -8
  430. package/payload/templates/forms/service/send-form-mail.php +38 -21
  431. package/payload/templates/forms/support-ticket-form.htm +67 -65
  432. package/payload/templates/panel/common/module-page.js +2 -2
  433. package/payload/templates/panel/common/theme.js +37 -10
  434. package/payload/templates/panel/common/top-bar.js +45 -40
  435. package/payload/templates/panel/index.htm +63 -60
  436. package/payload/templates/panel/module10/greenhouse.htm +98 -113
  437. package/payload/templates/panel/module11/arduino-projects.htm +47 -58
  438. package/payload/templates/panel/module6/energy-hub.htm +71 -103
  439. package/payload/templates/panel/module7/3d-printers.htm +58 -81
  440. package/payload/templates/panel/module8/cold-rooms.htm +58 -79
  441. package/payload/templates/panel/module9/elevator-fleet.htm +72 -93
  442. package/payload/templates/panel/pages/activity.js +134 -152
  443. package/payload/templates/panel/pages/contents.js +291 -308
  444. package/payload/templates/panel/pages/customers.js +250 -267
  445. package/payload/templates/panel/pages/edit-user.js +31 -30
  446. package/payload/templates/panel/pages/home.js +39 -70
  447. package/payload/templates/panel/pages/media.js +166 -183
  448. package/payload/templates/panel/pages/notifications.js +7 -7
  449. package/payload/templates/panel/pages/orders.js +200 -217
  450. package/payload/templates/panel/pages/products.js +259 -278
  451. package/payload/templates/panel/pages/reports.js +74 -123
  452. package/payload/templates/panel/pages/roles.js +57 -60
  453. package/payload/templates/panel/pages/settings.js +127 -143
  454. package/payload/templates/panel/pages/user-actions.js +106 -110
  455. package/payload/templates/panel/pages/user-list.js +221 -238
  456. package/payload/templates/panel/pages/users.js +14 -29
  457. package/payload/templates/shop/TEMPLATE.md +1 -1
  458. package/payload/templates/shop/app/app.js +11 -8
  459. package/payload/templates/shop/app/settings.js +4 -4
  460. package/payload/templates/shop/index.htm +3 -3
  461. package/payload/templates/shop/pages/account.js +7 -7
  462. package/payload/templates/shop/pages/cart.js +1 -1
  463. package/payload/templates/shop/pages/checkout.js +2 -2
  464. package/payload/templates/shop/pages/product.js +2 -2
  465. package/payload/templates/shop/pages/shop.js +6 -5
  466. package/payload/templates/starter/TEMPLATE.md +1 -1
  467. package/payload/templates/starter/app/app.js +12 -8
  468. package/payload/templates/starter/app/settings.js +14 -11
  469. package/payload/templates/starter/index.htm +3 -3
  470. package/payload/templates/starter/pages/about.js +1 -1
  471. package/payload/templates/starter/pages/home.js +2 -2
  472. package/payload/templates/starter/pages/product.js +1 -1
  473. package/payload/templates/starter/pages/products.js +5 -5
  474. package/payload/templates/starter/pages/settings.js +1 -1
  475. package/payload/templates/starter/pages/tasks.js +8 -8
  476. package/payload/templates/starter/pages/website.js +1 -1
  477. package/payload/starter/_basic/comp/chart-box/chart-4.5.1.umd.min.js +0 -13
  478. package/payload/starter/_basic/comp/chart-box/chart-js-LICENSE.md +0 -9
  479. package/payload/starter/_basic/comp/chart-box.js +0 -868
  480. package/payload/starter/_basic/comp/email-input-b.js +0 -57
  481. package/payload/starter/_basic/comp/input-b.js +0 -759
  482. package/payload/starter/_basic/comp/password-input-b.js +0 -164
  483. package/payload/starter/_basic/comp/search-input-v2.js +0 -427
  484. package/payload/starter/_basic/comp/textarea-b.js +0 -184
  485. package/payload/starter/_basic/comp/url-input-b.js +0 -145
  486. package/payload/starter/_basic/examples/badgeV2.htm +0 -68
  487. package/payload/starter/_basic/examples/chart-box.htm +0 -287
  488. package/payload/starter/_basic/examples/check-box-1.htm +0 -220
  489. package/payload/starter/_basic/examples/currency-input-b.htm +0 -71
  490. package/payload/starter/_basic/examples/email-input-b.htm +0 -67
  491. package/payload/starter/_basic/examples/input-b-ex1.htm +0 -132
  492. package/payload/starter/_basic/examples/input-b-ex2.htm +0 -136
  493. package/payload/starter/_basic/examples/input-b-ex3-style.htm +0 -113
  494. package/payload/starter/_basic/examples/input-b-ex4-custom-unit.htm +0 -112
  495. package/payload/starter/_basic/examples/input-b-ex6-dark.htm +0 -108
  496. package/payload/starter/_basic/examples/input-b-ex7-ozden.htm +0 -153
  497. package/payload/starter/_basic/examples/number-input-b.htm +0 -68
  498. package/payload/starter/_basic/examples/password-input-b.htm +0 -70
  499. package/payload/starter/_basic/examples/phone-input-b-select-country.htm +0 -298
  500. package/payload/starter/_basic/examples/phone-input-b.htm +0 -72
  501. package/payload/starter/_basic/examples/radio-button-1.htm +0 -264
  502. package/payload/starter/_basic/examples/search-input-v2-ozden.htm +0 -128
  503. package/payload/starter/_basic/examples/search-input-v2.htm +0 -65
  504. package/payload/starter/_basic/examples/select-color.htm +0 -215
  505. package/payload/starter/_basic/examples/select-date.htm +0 -244
  506. package/payload/starter/_basic/examples/select-file.htm +0 -268
  507. package/payload/starter/_basic/examples/select-time.htm +0 -249
  508. package/payload/starter/_basic/examples/smart-button-2.htm +0 -220
  509. package/payload/starter/_basic/examples/textarea-b.htm +0 -76
  510. package/payload/starter/_basic/examples/unfinished-login-page-dark-supabase.htm +0 -221
  511. package/payload/starter/_basic/examples/unfinished-login-page-supabase.htm +0 -221
  512. package/payload/starter/_basic/examples/url-input-b.htm +0 -85
  513. package/payload/starter/_basic/min/badge-v2.min.js +0 -2
  514. package/payload/starter/_basic/min/chart-box.min.js +0 -2
  515. package/payload/starter/_basic/min/currency-input-b.min.js +0 -2
  516. package/payload/starter/_basic/min/email-input-b.min.js +0 -2
  517. package/payload/starter/_basic/min/input-b.min.js +0 -2
  518. package/payload/starter/_basic/min/login-page-v2.min.js +0 -2
  519. package/payload/starter/_basic/min/number-input-b.min.js +0 -2
  520. package/payload/starter/_basic/min/password-input-b.min.js +0 -2
  521. package/payload/starter/_basic/min/phone-input-b.min.js +0 -2
  522. package/payload/starter/_basic/min/search-input-v2.min.js +0 -2
  523. package/payload/starter/_basic/min/select-color.min.js +0 -2
  524. package/payload/starter/_basic/min/select-date.min.js +0 -2
  525. package/payload/starter/_basic/min/select-file.min.js +0 -2
  526. package/payload/starter/_basic/min/select-time.min.js +0 -2
  527. package/payload/starter/_basic/min/textarea-b.min.js +0 -2
  528. package/payload/starter/_basic/min/url-input-b.min.js +0 -2
  529. package/payload/templates/panel/common/bridge.min.js +0 -0
  530. package/payload/templates/panel/common/full-view.min.js +0 -1
  531. package/payload/templates/panel/common/main-view.min.js +0 -1
  532. package/payload/templates/panel/common/module-page.min.js +0 -1
  533. package/payload/templates/panel/common/right-view.min.js +0 -1
  534. package/payload/templates/panel/common/start-page.min.js +0 -1
  535. package/payload/templates/panel/common/top-bar-v25-07-29-1.js +0 -330
  536. package/payload/templates/panel/common/top-bar-v25-07-29-2.js +0 -265
  537. package/payload/templates/panel/common/top-bar.min.js +0 -1
  538. package/payload/templates/panel/common/ui-standards.min.js +0 -1
  539. package/payload/templates/panel/managers/database.min.js +0 -1
  540. package/payload/templates/panel/managers/login.min.js +0 -1
  541. package/payload/templates/panel/pages/_page-template.min.js +0 -1
  542. package/payload/templates/panel/pages/contents.min.js +0 -1
  543. package/payload/templates/panel/pages/edit-user.min.js +0 -1
  544. package/payload/templates/panel/pages/edit-users-table.min.js +0 -1
  545. package/payload/templates/panel/pages/home.min.js +0 -1
  546. package/payload/templates/panel/pages/notifications.min.js +0 -1
  547. package/payload/templates/panel/pages/reports.min.js +0 -1
  548. package/payload/templates/panel/pages/settings.min.js +0 -1
  549. package/payload/templates/panel/pages/user-actions.min.js +0 -2
  550. package/payload/templates/panel/pages/users.min.js +0 -1
  551. /package/payload/starter/_basic/comp/{password-input-b → password-field}/hide-btn.png +0 -0
  552. /package/payload/starter/_basic/comp/{password-input-b → password-field}/hide-btn2.png +0 -0
  553. /package/payload/starter/_basic/comp/{password-input-b → password-field}/show-btn.png +0 -0
  554. /package/payload/starter/_basic/comp/{password-input-b → password-field}/show-btn2.png +0 -0
  555. /package/payload/starter/_basic/comp/{search-input-v2 → search-input}/clear-round.svg +0 -0
  556. /package/payload/starter/_basic/comp/{search-input-v2 → search-input}/clear.svg +0 -0
  557. /package/payload/starter/_basic/comp/{search-input-v2 → search-input}/filter.png +0 -0
  558. /package/payload/starter/_basic/comp/{search-input-v2 → search-input}/filter.svg +0 -0
  559. /package/payload/starter/_basic/comp/{search-input-v2 → search-input}/search.svg +0 -0
@@ -1,2 +1,2 @@
1
1
  /* Bismillah */
2
- "use strict";const LabelEditorDefaults={key:"0",width:860,height:540,labels:[],savedStyles:[],storageKey:"",newLabel:{text:"Label {n}",fontSize:16,textColor:"#1F2328",color:"",bold:0,italic:0,textAlign:"left",fullWidth:0,padding:0,round:0,border:0,borderColor:"#1F2328"},colorPalette:["#1F2328","#5A5A5A","#9A9A9A","#D0D0D0","#FFFFFF","#C0392B","#E0A038","#8A5A00","#3E8E62","#1F6F6B","#2F6FB0","#5AA9E6","#7B61D9","#B45FC0","#E06AA0","#FFE0E0","#FFF3C4","#E3F4E8","#E1EEFB","#EFE7FB"],panelWidth:340,useScrollBar:1,texts:{title:"Labels",addButton:"+ Add label",empty:'No labels yet. Click "Add label" to create one.',panelTitle:"Properties",text:"Text",fontSize:"Font size",fontStyle:"Font style",bold:"Bold",italic:"Italic",align:"Alignment",left:"Left",center:"Center",right:"Right",width:"Width",widthAuto:"Auto",widthFull:"Full",textColor:"Text color",background:"Background",none:"None",colorOn:"Color",backgroundColor:"Background color",padding:"Padding",round:"Corner radius",border:"Border",borderColor:"Border color",savedStyles:"Saved styles",styleNamePlaceholder:"Style name",save:"Save",noStyles:"No saved styles yet. Style a label, write a name and save it.",applyHint:"Click a style to apply it to the selected label.",currentStyle:"Style: {name}",changed:"(changed)",noStyle:"No style",duplicate:"Duplicate",remove:"Delete",removeStyle:"Delete style"},onChange:function(e){},onSelect:function(e,t){},onStylesChange:function(e){},styleName:"classic",style:{box:{color:"#F4F5F2",border:1,borderColor:Black(.12),round:10},header:{color:White(1),dividerColor:Black(.08),titleColor:"#1F2328",titleSize:15},list:{color:"#F4F5F2",padding:24,gap:12,emptyColor:Black(.4)},selection:{color:"#2F6FB0",hoverColor:"rgba(47, 111, 176, 0.35)"},button:{color:"#1F2328",textColor:White(1),hoverColor:"#3A3F45",round:6,fontSize:13,height:36},secondaryButton:{color:Black(.06),textColor:"#1F2328",hoverColor:Black(.1),dangerTextColor:"#C0392B"},panel:{dividerColor:Black(.08),gap:18,captionColor:Black(.5),textColor:"#1F2328",hintColor:Black(.4)},input:{color:White(1),borderColor:Black(.2),focusColor:"#141414",textColor:"#1F2328",round:6,height:38},chip:{color:White(1),borderColor:Black(.14),activeBorderColor:"#2F6FB0",round:16,closeColor:Black(.4)},sidePanelStyleName:"classic",stepperStyleName:"classic",tabsStyleName:"classic",checkBoxStyleName:"classic",selectColorStyleName:"classic",sidePanelStyle:{},stepperStyle:{},tabsStyle:{},checkBoxStyle:{label:{fontSize:14}},selectColorStyle:{fieldText:{fontSize:13}},scrollBar:{bar_color:"#9A9A98",bar_mouseOverColor:"#6A6A68",bar_width:4,bar_round:3,bar_opacity:.4,bar_mouseOverOpacity:.9,bar_padding:2}}},LabelEditor=function(e={}){const t=[["SidePanel",typeof SidePanel],["Stepper",typeof Stepper],["SelectColor",typeof SelectColor],["Tabs",typeof Tabs],["CheckBox",typeof CheckBox]].filter(function(e){return"undefined"===e[1]}).map(function(e){return e[0]});t.length&&console.error("LabelEditor: Load these components before label-editor.js: "+t.join(", ")),basic.applyStylePackage(e,LabelEditor.styles,LabelEditorDefaults),mergeIntoIfMissing(e,LabelEditorDefaults);const o=e.style.box;e.color=o.color,e.border=o.border,e.borderColor=o.borderColor,e.round=o.round;const l=e.labels,r=e.savedStyles;e.labels=[],e.savedStyles=[];let n=startObject(e);const a=n.style,i=function(e){return JSON.parse(JSON.stringify(e||{}))},s=["text","fontSize","textColor","color","bold","italic","textAlign","fullWidth","padding","round","border","borderColor"].filter(function(e){return"text"!==e});let c=[],d=[],u=null,p=0,b=0;const h={},f={min:8,max:120},g={min:0,max:80},y={min:0,max:100},x={min:0,max:20},m="#FFF3C4",C=function(e,t,o,l){const r=Number(e);return isNaN(r)?l:Math.max(t,Math.min(o,Math.round(r)))},S=function(e,t){const o=Object.assign({},t||n.newLabel,e||{});return{text:String(o.text??""),fontSize:C(o.fontSize,f.min,f.max,16),textColor:String(o.textColor||"#1F2328"),color:String(o.color||""),bold:o.bold?1:0,italic:o.italic?1:0,textAlign:["left","center","right"].indexOf(o.textAlign)>-1?o.textAlign:"left",fullWidth:o.fullWidth?1:0,padding:C(o.padding,g.min,g.max,0),round:C(o.round,y.min,y.max,0),border:C(o.border,x.min,x.max,0),borderColor:String(o.borderColor||"#1F2328")}},v=function(e){const t={};return s.forEach(function(o){t[o]=e[o]}),t},k=function(e){return d.find(function(t){return t.name===e})||null},B=function(e){return c.indexOf(e)},A=function(){if(n.storageKey)try{basic.storage.save(n.storageKey,d)}catch(e){console.warn("LabelEditor: The styles could not be saved.")}},w=function(){n.savedStyles=n.getSavedStyles(),A(),_(),O(),n.onStylesChange(n)},N=function(){n.labels=n.getLabels(),n.onChange(n)},E=function(e){const t=e.label,o=e.props;t.plainText=o.text,t.fontSize=o.fontSize,t.textColor=o.textColor,t.color=o.color||"transparent",t.bold=o.bold,t.italic=o.italic,t.textAlign=o.textAlign,t.width=o.fullWidth?"100%":"auto",t.padding=o.padding,t.round=o.round,t.border=o.border,t.borderColor=o.borderColor,t.css.borderStyle="solid",t.aria={label:o.text||"Label"},t.elem.title=e.styleName?n.texts.currentStyle.replace("{name}",e.styleName):""},F=function(e,t){return t?"2px solid "+a.selection.color:e.isHover?"1px dashed "+a.selection.hoverColor:"none"},L=function(e){const t=e===u;e.label.css={outline:F(e,t),outlineOffset:t?"3px":"2px"},e.label.aria={selected:t?"true":"false"}},W=function(e,t){return"Enter"===t.key||" "===t.key?(t.preventDefault(),void T(e)):"Delete"!==t.key&&"Backspace"!==t.key||e!==u?void("ArrowDown"!==t.key&&"ArrowUp"!==t.key||(t.preventDefault(),function(e,t){const o=c[B(e)+t];o&&o.label.elem.focus()}(e,"ArrowDown"===t.key?1:-1))):(t.preventDefault(),void n.removeLabel(B(e)))},z=function(e){createIn(n.listWrapper,function(){e.label=Label({plainText:"",clickable:1}),e.label.css={maxWidth:"100%",boxSizing:"border-box",whiteSpace:"pre-wrap",overflowWrap:"break-word",minHeight:"1em"},e.label.cursor="pointer",e.label.shrink=0,e.label.tabIndex=0,e.label.role="option"}),E(e),L(e),e.label.on("click",function(t,o){o.stopPropagation(),T(e)}),e.label.on("mouseenter",function(){e.isHover=1,L(e)}),e.label.on("mouseleave",function(){e.isHover=0,L(e)}),e.label.on("keydown",function(t,o){W(e,o)})},G=function(){n.lblEmpty.visible=0==c.length?1:0,n.listScrollBar&&n.listScrollBar.refreshScroll()},T=function(e){const t=u;u=e||null,t&&t.label&&L(t),u?(L(u),u.label.elem.scrollIntoView({block:"nearest"}),P(),n.sidePanel.open()):1===n.sidePanel.isOpened&&(b=1,n.sidePanel.close(),b=0),t!==u&&n.onSelect(n,B(u))},D=function(e,t){if(!u)return;const o=S(Object.assign({},u.props,{[e]:t}),u.props);o[e]!==u.props[e]&&(u.props=o,"text"!==e&&u.styleName&&(u.styleChanged=1),E(u),O(),N())},P=function(){if(!u)return;const e=u.props;h.text.text=e.text,h.fontSize.setValue(e.fontSize,1),h.bold.setChecked(e.bold,1),h.italic.setChecked(e.italic,1),h.align.setValue(e.textAlign,1),h.width.setValue(e.fullWidth?"full":"auto",1),h.textColor.setColor(e.textColor,1),h.background.setValue(e.color?"color":"none",1),h.bgColor.setColor(e.color||m,1),h.bgField.visible=e.color?1:0,h.padding.setValue(e.padding,1),h.round.setValue(e.round,1),h.border.setValue(e.border,1),h.borderColor.setColor(e.borderColor,1),h.styleName.text=u.styleName||"",O()},O=function(){if(n.lblStyleInfo){if(u&&u.styleName){const e=u.styleChanged?" "+n.texts.changed:"";n.lblStyleInfo.plainText=n.texts.currentStyle.replace("{name}",u.styleName)+e}else n.lblStyleInfo.plainText=n.texts.noStyle;_()}},I=function(e){u&&n.applyStyle(e,B(u))},H=function(e){const t=u&&u.styleName===e.name,o=HGroup({width:"auto",height:"auto",align:"left center",gap:4,padding:[10,4],color:a.chip.color,round:a.chip.round,border:t?2:1,borderColor:t?a.chip.activeBorderColor:a.chip.borderColor});o.cursor="pointer",o.css.maxWidth="100%",o.role="button",o.elem.setAttribute("title",n.texts.applyHint),o.tabIndex=0,o.clickable=1;const l=e.props;Label({plainText:e.name,fontSize:Math.min(15,Math.max(11,l.fontSize)),textColor:l.textColor,color:l.color||"transparent",bold:l.bold,italic:l.italic,padding:l.color?[6,1]:0,round:4,ellipsis:1}).css.maxWidth="160px";const r=Label({text:LabelEditor.getCloseSvg(a.chip.closeColor,12),width:18,height:18,round:9,clickable:1});r.elem.style.display="flex",r.css={alignItems:"center",justifyContent:"center"},r.lineHeight="0",r.role="button",r.aria={label:n.texts.removeStyle+": "+e.name},r.on("click",function(t,o){o.stopPropagation(),n.removeStyle(e.name)}),endGroup(),o.on("click",function(){I(e.name)}),o.on("keydown",function(t,o){"Enter"!==o.key&&" "!==o.key||(o.preventDefault(),I(e.name))})},_=function(){n.chipHolder&&(n.chipWrapper&&n.chipWrapper.remove(),createIn(n.chipHolder,function(){n.chipWrapper=HGroup({width:"100%",height:"auto",align:"left top",gap:6,wrap:1}),n.chipWrapper.position="relative",0==d.length&&Label({plainText:n.texts.noStyles,width:"100%",fontSize:12,textColor:a.panel.hintColor}),d.forEach(H),endGroup()}))},j=function(e){const t=VGroup({width:"100%",height:"auto",align:"left top",gap:6});return t.css.alignItems="stretch",Label({plainText:e,fontSize:12,textColor:a.panel.captionColor}),t},V=function(){const e=HGroup({width:"100%",height:"auto",align:"left top",gap:12});return e.css.alignItems="flex-start",e},M=function(e){const t=j(e);return t.width="auto",t.css={flex:"1 1 0",minWidth:"0"},t},K=function(e){const t=Input({width:"100%",height:a.input.height,minimal:1,fontSize:14,color:a.input.color,textColor:a.input.textColor,round:a.input.round,border:1,borderColor:a.input.borderColor}),o=t.inputElement;return o.style.width="100%",o.style.height="100%",o.style.boxSizing="border-box",o.style.padding="0px 10px",o.style.backgroundColor="transparent",o.style.color=a.input.textColor,t.shrink=0,o.addEventListener("focus",function(){t.borderColor=a.input.focusColor}),o.addEventListener("blur",function(){t.borderColor=a.input.borderColor}),o.addEventListener("input",function(){e(t.text)}),t},R=function(e,t,o,l){return Stepper({width:"100%",height:a.input.height,value:e,min:e,max:t,ariaLabel:o,styleName:a.stepperStyleName,style:i(a.stepperStyle),onChange:function(e){D(l,e.value)}})},J=function(e,t){return SelectColor({width:"100%",height:a.input.height,colors:n.colorPalette.slice(),styleName:a.selectColorStyleName,style:i(a.selectColorStyle),onChange:function(o){o.value&&(t?t(o.value):D(e,o.value))}})},U=function(e,t){return Tabs({scale:1,width:"100%",variant:"pill",fullWidth:1,tabs:e,value:e[0].key,styleName:a.tabsStyleName,style:i(a.tabsStyle),onChange:function(e){t(e.value)}})},Y=function(e,t){return CheckBox({labelText:e,styleName:a.checkBoxStyleName,style:i(a.checkBoxStyle),onChange:function(e){D(t,e.checked)}})},q=function(e,t,o){const l=t?a.button:a.secondaryButton,r=Button({text:e,width:"auto",height:a.button.height,fontSize:a.button.fontSize,color:l.color,textColor:l.textColor,round:a.button.round});return r.css={backgroundImage:"none",boxShadow:"none",border:"0",padding:"0px 16px",whiteSpace:"nowrap",transition:"background-color 0.12s"},r.shrink=0,r.on("mouseenter",function(){r.color=l.hoverColor}),r.on("mouseleave",function(){r.color=l.color}),r.on("click",o),r};if(n.addLabel=function(e={},t=0){p++;const o=S(e);e&&void 0!==e.text||(o.text=String(n.newLabel.text||"").replace("{n}",String(p)));const l={props:o,styleName:"",styleChanged:0,label:null},r=e&&e.styleName;return r&&k(r)&&(l.styleName=r),c.push(l),z(l),G(),t&&(T(l),l.label.elem.focus({preventScroll:!0})),N(),c.length-1},n.removeLabel=function(e){const t=c[e];if(!t)return;t===u&&T(null),c.splice(e,1),t.label.remove(),G();const o=c[Math.min(e,c.length-1)];o&&!1===n.elem.contains(document.activeElement)&&o.label.elem.focus({preventScroll:!0}),N()},n.duplicateLabel=function(e){const t=c[e];if(!t)return-1;const o=Object.assign({},t.props,{styleName:t.styleName}),l=n.addLabel(o,0);return c[l].styleChanged=t.styleChanged,n.moveLabel(l,e+1),T(c[e+1]),e+1},n.moveLabel=function(e,t){const o=c[e];if(!o)return;const l=Math.max(0,Math.min(t,c.length-1));c.splice(e,1),c.splice(l,0,o);const r=c[l+1];n.listWrapper.elem.insertBefore(o.label.elem,r?r.label.elem:null),N()},n.selectLabel=function(e){T(c[e]||null)},n.getSelectedIndex=function(){return B(u)},n.getLabels=function(){return c.map(function(e){return Object.assign({},e.props,{styleName:e.styleName})})},n.setLabels=function(e){T(null),p=0,c=(Array.isArray(e)?e:[]).map(function(e){p++;const t=e&&e.styleName&&k(e.styleName)?e.styleName:"";return{props:S(e),styleName:t,styleChanged:0,label:null}}),n.listWrapper&&n.listWrapper.remove(),createIn(n.listArea,function(){n.listWrapper=VGroup({width:"100%",height:"auto",align:"left top",gap:a.list.gap,padding:a.list.padding}),n.listWrapper.position="relative",n.listWrapper.role="listbox",n.listWrapper.aria={label:n.texts.title},endGroup()}),c.forEach(z),G(),n.labels=n.getLabels()},n.saveStyle=function(e,t=-1){const o=t>=0?c[t]:u;if(e=String(e??"").trim(),!o||!e)return 0;const l=v(o.props),r=k(e);r?r.props=l:d.push({name:e,props:l}),o.styleName=e,o.styleChanged=0;let n=0;return c.forEach(function(t){t!==o&&t.styleName===e&&(t.props=S(Object.assign({},t.props,l),t.props),t.styleChanged=0,E(t),n=1)}),E(o),w(),(n||r)&&N(),1},n.applyStyle=function(e,t=-1){const o=t>=0?c[t]:u,l=k(e);return o&&l?(o.props=S(Object.assign({},o.props,l.props),o.props),o.styleName=l.name,o.styleChanged=0,E(o),o===u?P():_(),N(),1):0},n.removeStyle=function(e){const t=d.findIndex(function(t){return t.name===e});t<0||(d.splice(t,1),c.forEach(function(t){t.styleName===e&&(t.styleName="",t.styleChanged=0,E(t))}),w(),N())},n.getSavedStyles=function(){return d.map(function(e){return{name:e.name,props:Object.assign({},e.props)}})},n.setSavedStyles=function(e){d=[],(Array.isArray(e)?e:[]).forEach(function(e){const t=String((e&&e.name)??"").trim();t&&!k(t)&&d.push({name:t,props:v(S(e.props))})}),n.savedStyles=n.getSavedStyles(),A(),_(),O()},n.refresh=function(){c.forEach(E),G()},n.clipContent=1,n.layout=VGroup({width:"100%",height:"100%",align:"left top",gap:0}),n.layout.css.alignItems="stretch",n.header=HGroup({width:"100%",height:"auto",align:"left center",gap:8,padding:[16,10],color:a.header.color}),n.header.shrink=0,n.header.css.borderBottom="1px solid "+a.header.dividerColor,n.lblTitle=Label({plainText:n.texts.title,fontSize:a.header.titleSize,textColor:a.header.titleColor,bold:1}),n.lblTitle.css.flex="1 1 0",n.btnAdd=q(n.texts.addButton,1,function(){n.addLabel({},1)}),endGroup(),n.listHolder=startBox({width:"100%",height:"auto",color:a.list.color}),n.listHolder.css={flex:"1 1 0",minHeight:"0"},n.listArea=Box(0,0,"100%","100%",{color:"transparent",scrollY:1}),n.listArea.clickable=1,n.lblEmpty=Label({plainText:n.texts.empty,width:"100%",top:40,fontSize:14,textColor:a.list.emptyColor,textAlign:"center",padding:[24,0],visible:0}),1==n.useScrollBar&&"undefined"!=typeof ScrollBar){const e={scrollableBox:n.listArea,neverHide:0,showDots:0};n.listScrollBar=ScrollBar(Object.assign(e,a.scrollBar))}endBox(),endGroup();n.sidePanel=SidePanel({side:"right",panelSize:n.panelWidth,titleText:n.texts.panelTitle,ariaLabel:n.texts.panelTitle,showBackdrop:0,closeOnEscape:1,styleName:a.sidePanelStyleName,style:i(a.sidePanelStyle),onClose:function(){if(b||!n||!u)return;const e=u;T(null),e.label&&function(){const e=document.activeElement;return!e||e===document.body||!(!n.sidePanel||!n.sidePanel.elem.contains(e))}()&&e.label.elem.focus({preventScroll:!0})}}),n.own(n.sidePanel),n.sidePanel.startBody(),n.panelContent=VGroup({width:"100%",height:"auto",align:"left top",gap:a.panel.gap}),n.panelContent.css.alignItems="stretch",j(n.texts.text),h.text=K(function(e){D("text",e)}),h.text.inputElement.setAttribute("aria-label",n.texts.text),endGroup(),V(),M(n.texts.fontSize),h.fontSize=R(f.min,f.max,n.texts.fontSize,"fontSize"),endGroup(),M(n.texts.fontStyle),VGroup({width:"100%",height:"auto",align:"left top",gap:4}),h.bold=Y(n.texts.bold,"bold"),h.italic=Y(n.texts.italic,"italic"),endGroup(),endGroup(),endGroup(),j(n.texts.align);const Q=[{key:"left",text:n.texts.left},{key:"center",text:n.texts.center},{key:"right",text:n.texts.right}];h.align=U(Q,function(e){D("textAlign",e)}),endGroup(),j(n.texts.width);const X=[{key:"auto",text:n.texts.widthAuto},{key:"full",text:n.texts.widthFull}];h.width=U(X,function(e){D("fullWidth","full"===e?1:0)}),endGroup(),j(n.texts.textColor),h.textColor=J("textColor"),endGroup(),j(n.texts.background),h.background=U([{key:"none",text:n.texts.none},{key:"color",text:n.texts.colorOn}],function(e){D("color","color"===e?h.bgColor.value||m:""),h.bgField.visible="color"===e?1:0}),endGroup(),h.bgField=j(n.texts.backgroundColor),h.bgColor=J("color"),endGroup(),V(),M(n.texts.padding),h.padding=R(g.min,g.max,n.texts.padding,"padding"),endGroup(),M(n.texts.round),h.round=R(y.min,y.max,n.texts.round,"round"),endGroup(),endGroup(),V(),M(n.texts.border),h.border=R(x.min,x.max,n.texts.border,"border"),endGroup(),M(n.texts.borderColor),h.borderColor=J("borderColor"),endGroup(),endGroup(),HGroup({width:"100%",height:"auto",align:"left center",gap:8}),n.btnDuplicate=q(n.texts.duplicate,0,function(){u&&n.duplicateLabel(B(u))}),n.btnRemove=q(n.texts.remove,0,function(){u&&n.removeLabel(B(u))}),n.btnRemove.textColor=a.secondaryButton.dangerTextColor,endGroup(),Box({width:"100%",height:1,color:a.panel.dividerColor}),that.shrink=0,j(n.texts.savedStyles),n.lblStyleInfo=Label({plainText:"",width:"100%",fontSize:12,textColor:a.panel.textColor}),HGroup({width:"100%",height:"auto",align:"left center",gap:8}),h.styleName=K(function(){h.styleName.borderColor=a.input.focusColor}),h.styleName.width="auto",h.styleName.css={flex:"1 1 0",minWidth:"0"},h.styleName.inputElement.placeholder=n.texts.styleNamePlaceholder,h.styleName.inputElement.setAttribute("aria-label",n.texts.styleNamePlaceholder),n.btnSaveStyle=q(n.texts.save,1,function(){const e=String(h.styleName.text||"").trim();e?n.saveStyle(e):h.styleName.inputElement.focus()}),endGroup(),n.chipHolder=startBox({width:"100%",height:"auto",color:"transparent"}),endBox(),Label({plainText:n.texts.applyHint,width:"100%",fontSize:11,textColor:a.panel.hintColor}),endGroup(),endGroup(),n.sidePanel.endBody(),h.styleName.inputElement.addEventListener("keydown",function(e){"Enter"===e.key&&(e.preventDefault(),n.btnSaveStyle.elem.click())});n.listArea.on("click",function(e,t){(function(e){return!n.listWrapper||!n.listWrapper.elem.contains(e.target)||e.target===n.listWrapper.elem})(t)&&T(null)}),n.on("keydown",function(e,t){if("Escape"!==t.key||!u)return;t.preventDefault();const o=u;T(null),o.label.elem.focus({preventScroll:!0})});let Z=null;if(n.storageKey)try{Z=basic.storage.load(n.storageKey)}catch(e){Z=null}return n.setSavedStyles(Array.isArray(Z)?Z:r),n.setLabels(l),endObject(n)};LabelEditor.getCloseSvg=function(e,t){return'<svg xmlns="http://www.w3.org/2000/svg" width="'+t+'" height="'+t+'" viewBox="0 0 24 24" fill="none" stroke="'+e+'" stroke-width="2.4" stroke-linecap="round"><path d="M6 6l12 12M18 6L6 18"/></svg>'},LabelEditor.styles={classic:LabelEditorDefaults.style,dark:{style:{box:{color:"#1C1C1B",border:1,borderColor:"rgba(255, 255, 255, 0.10)",round:10},header:{color:"#232322",dividerColor:"rgba(255, 255, 255, 0.08)",titleColor:"rgba(255, 255, 255, 0.9)",titleSize:15},list:{color:"#1C1C1B",padding:24,gap:12,emptyColor:"rgba(255, 255, 255, 0.4)"},selection:{color:"#65A293",hoverColor:"rgba(101, 162, 147, 0.45)"},button:{color:"#3D7A6B",textColor:White(1),hoverColor:"#4A8A7A",round:6,fontSize:13,height:36},secondaryButton:{color:"rgba(255, 255, 255, 0.08)",textColor:"rgba(255, 255, 255, 0.85)",hoverColor:"rgba(255, 255, 255, 0.14)",dangerTextColor:"#E57B6B"},panel:{dividerColor:"rgba(255, 255, 255, 0.08)",gap:18,captionColor:"rgba(255, 255, 255, 0.5)",textColor:"rgba(255, 255, 255, 0.9)",hintColor:"rgba(255, 255, 255, 0.4)"},input:{color:"#2A2A29",borderColor:"rgba(255, 255, 255, 0.12)",focusColor:"#65A293",textColor:"rgba(255, 255, 255, 0.9)",round:6,height:38},chip:{color:"#2A2A29",borderColor:"rgba(255, 255, 255, 0.12)",activeBorderColor:"#65A293",round:16,closeColor:"rgba(255, 255, 255, 0.5)"},sidePanelStyleName:"dark",stepperStyleName:"dark",tabsStyleName:"dark",checkBoxStyleName:"dark",selectColorStyleName:"dark",selectColorStyle:{field:{color:"#2A2A29",borderColor:"rgba(255, 255, 255, 0.12)",round:6},fieldText:{fontSize:13}},scrollBar:{bar_color:"#8A8A88",bar_mouseOverColor:"#BFBFBD",bar_width:4,bar_round:3,bar_opacity:.4,bar_mouseOverOpacity:.9,bar_padding:2}},newLabel:{textColor:"#E8E8E6",borderColor:"#E8E8E6"},colorPalette:["#FFFFFF","#E8E8E6","#B5B5B3","#7A7A78","#2A2A29","#E57B6B","#F2B45A","#D9C36A","#7CC49A","#65A293","#6FA8DC","#8CC8F0","#A38BEA","#C98AD6","#F08DB8","#3A2523","#3A3220","#233528","#1F2E3A","#2E2840"]}};
2
+ "use strict";const LabelEditorDefaults={key:"0",width:860,height:540,labels:[],savedStyles:[],storageKey:"",newLabel:{text:"Label {n}",fontSize:16,textColor:"#1F2328",color:"",bold:0,italic:0,textAlign:"left",fullWidth:0,padding:0,round:0,border:0,borderColor:"#1F2328"},colorPalette:["#1F2328","#5A5A5A","#9A9A9A","#D0D0D0","#FFFFFF","#C0392B","#E0A038","#8A5A00","#3E8E62","#1F6F6B","#2F6FB0","#5AA9E6","#7B61D9","#B45FC0","#E06AA0","#FFE0E0","#FFF3C4","#E3F4E8","#E1EEFB","#EFE7FB"],panelWidth:340,useScrollBar:1,texts:{title:"Labels",addButton:"+ Add label",empty:'No labels yet. Click "Add label" to create one.',panelTitle:"Properties",text:"Text",fontSize:"Font size",fontStyle:"Font style",bold:"Bold",italic:"Italic",align:"Alignment",left:"Left",center:"Center",right:"Right",width:"Width",widthAuto:"Auto",widthFull:"Full",textColor:"Text color",background:"Background",none:"None",colorOn:"Color",backgroundColor:"Background color",padding:"Padding",round:"Corner radius",border:"Border",borderColor:"Border color",savedStyles:"Saved styles",styleNamePlaceholder:"Style name",save:"Save",noStyles:"No saved styles yet. Style a label, write a name and save it.",applyHint:"Click a style to apply it to the selected label.",currentStyle:"Style: {name}",changed:"(changed)",noStyle:"No style",duplicate:"Duplicate",remove:"Delete",removeStyle:"Delete style"},onChange:function(e){},onSelect:function(e,t){},onStylesChange:function(e){},styleName:"light",style:{box:{color:"#F4F5F2",border:1,borderColor:Black(.12),round:10},header:{color:White(1),dividerColor:Black(.08),titleColor:"#1F2328",titleSize:15},list:{color:"#F4F5F2",padding:24,gap:12,emptyColor:Black(.4)},selection:{color:"#2F6FB0",hoverColor:"rgba(47, 111, 176, 0.35)"},button:{color:"#1F2328",textColor:White(1),hoverColor:"#3A3F45",round:6,fontSize:13,height:36},secondaryButton:{color:Black(.06),textColor:"#1F2328",hoverColor:Black(.1),dangerTextColor:"#C0392B"},panel:{dividerColor:Black(.08),gap:18,captionColor:Black(.5),textColor:"#1F2328",hintColor:Black(.4)},input:{color:White(1),borderColor:Black(.2),focusColor:"#141414",textColor:"#1F2328",round:6,height:38},chip:{color:White(1),borderColor:Black(.14),activeBorderColor:"#2F6FB0",round:16,closeColor:Black(.4)},sidePanelStyleName:"light",stepperStyleName:"light",tabsStyleName:"light",checkBoxStyleName:"light",selectColorStyleName:"light",sidePanelStyle:{},stepperStyle:{},tabsStyle:{},checkBoxStyle:{label:{fontSize:14}},selectColorStyle:{fieldText:{fontSize:13}},scrollBar:{bar_color:"#9A9A98",bar_mouseOverColor:"#6A6A68",bar_width:4,bar_round:3,bar_opacity:.4,bar_mouseOverOpacity:.9,bar_padding:2}}},LabelEditor=function(e={}){const t=[["SidePanel",typeof SidePanel],["Stepper",typeof Stepper],["ColorPicker",typeof ColorPicker],["Tabs",typeof Tabs],["CheckBox",typeof CheckBox]].filter(function(e){return"undefined"===e[1]}).map(function(e){return e[0]});t.length&&console.error("LabelEditor: Load these components before label-editor.js: "+t.join(", ")),basic.applyStylePackage(e,LabelEditor.styles,LabelEditorDefaults),mergeIntoIfMissing(e,LabelEditorDefaults);const o=e.style.box;e.color=o.color,e.border=o.border,e.borderColor=o.borderColor,e.round=o.round;const l=e.labels,r=e.savedStyles;e.labels=[],e.savedStyles=[];let n=startObject(e);const a=n.style,i=function(e){return JSON.parse(JSON.stringify(e||{}))},s=["text","fontSize","textColor","color","bold","italic","textAlign","fullWidth","padding","round","border","borderColor"].filter(function(e){return"text"!==e});let c=[],d=[],u=null,p=0,b=0;const h={},f={min:8,max:120},g={min:0,max:80},y={min:0,max:100},x={min:0,max:20},m="#FFF3C4",C=function(e,t,o,l){const r=Number(e);return isNaN(r)?l:Math.max(t,Math.min(o,Math.round(r)))},S=function(e,t){const o=Object.assign({},t||n.newLabel,e||{});return{text:String(o.text??""),fontSize:C(o.fontSize,f.min,f.max,16),textColor:String(o.textColor||"#1F2328"),color:String(o.color||""),bold:o.bold?1:0,italic:o.italic?1:0,textAlign:["left","center","right"].indexOf(o.textAlign)>-1?o.textAlign:"left",fullWidth:o.fullWidth?1:0,padding:C(o.padding,g.min,g.max,0),round:C(o.round,y.min,y.max,0),border:C(o.border,x.min,x.max,0),borderColor:String(o.borderColor||"#1F2328")}},v=function(e){const t={};return s.forEach(function(o){t[o]=e[o]}),t},k=function(e){return d.find(function(t){return t.name===e})||null},B=function(e){return c.indexOf(e)},A=function(){if(n.storageKey)try{basic.storage.save(n.storageKey,d)}catch(e){console.warn("LabelEditor: The styles could not be saved.")}},w=function(){n.savedStyles=n.getSavedStyles(),A(),V(),O(),n.onStylesChange(n)},E=function(){n.labels=n.getLabels(),n.onChange(n)},N=function(e){const t=e.label,o=e.props;t.plainText=o.text,t.fontSize=o.fontSize,t.textColor=o.textColor,t.color=o.color||"transparent",t.bold=o.bold,t.italic=o.italic,t.textAlign=o.textAlign,t.width=o.fullWidth?"100%":"auto",t.padding=o.padding,t.round=o.round,t.border=o.border,t.borderColor=o.borderColor,t.css.borderStyle="solid",t.aria={label:o.text||"Label"},t.elem.title=e.styleName?n.texts.currentStyle.replace("{name}",e.styleName):""},F=function(e,t){return t?"2px solid "+a.selection.color:e.isHover?"1px dashed "+a.selection.hoverColor:"none"},L=function(e){const t=e===u;e.label.css={outline:F(e,t),outlineOffset:t?"3px":"2px"},e.label.aria={selected:t?"true":"false"}},W=function(e,t){return"Enter"===t.key||" "===t.key?(t.preventDefault(),void P(e)):"Delete"!==t.key&&"Backspace"!==t.key||e!==u?void("ArrowDown"!==t.key&&"ArrowUp"!==t.key||(t.preventDefault(),function(e,t){const o=c[B(e)+t];o&&o.label.elem.focus()}(e,"ArrowDown"===t.key?1:-1))):(t.preventDefault(),void n.removeLabel(B(e)))},z=function(e){createIn(n.listWrapper,function(){e.label=Label({plainText:"",clickable:1}),e.label.css={maxWidth:"100%",boxSizing:"border-box",whiteSpace:"pre-wrap",overflowWrap:"break-word",minHeight:"1em"},e.label.cursor="pointer",e.label.shrink=0,e.label.tabIndex=0,e.label.role="option"}),N(e),L(e),e.label.on("click",function(t,o){o.stopPropagation(),P(e)}),e.label.on("mouseenter",function(){e.isHover=1,L(e)}),e.label.on("mouseleave",function(){e.isHover=0,L(e)}),e.label.on("keydown",function(t,o){W(e,o)})},G=function(){n.lblEmpty.visible=0==c.length?1:0,n.listScrollBar&&n.listScrollBar.refreshScroll()},P=function(e){const t=u;u=e||null,t&&t.label&&L(t),u?(L(u),u.label.elem.scrollIntoView({block:"nearest"}),D(),n.sidePanel.open()):1===n.sidePanel.isOpened&&(b=1,n.sidePanel.close(),b=0),t!==u&&n.onSelect(n,B(u))},T=function(e,t){if(!u)return;const o=S(Object.assign({},u.props,{[e]:t}),u.props);o[e]!==u.props[e]&&(u.props=o,"text"!==e&&u.styleName&&(u.styleChanged=1),N(u),O(),E())},D=function(){if(!u)return;const e=u.props;h.text.text=e.text,h.fontSize.setValue(e.fontSize,1),h.bold.setChecked(e.bold,1),h.italic.setChecked(e.italic,1),h.align.setValue(e.textAlign,1),h.width.setValue(e.fullWidth?"full":"auto",1),h.textColor.setColor(e.textColor,1),h.background.setValue(e.color?"color":"none",1),h.bgColor.setColor(e.color||m,1),h.bgField.visible=e.color?1:0,h.padding.setValue(e.padding,1),h.round.setValue(e.round,1),h.border.setValue(e.border,1),h.borderColor.setColor(e.borderColor,1),h.styleName.text=u.styleName||"",O()},O=function(){if(n.lblStyleInfo){if(u&&u.styleName){const e=u.styleChanged?" "+n.texts.changed:"";n.lblStyleInfo.plainText=n.texts.currentStyle.replace("{name}",u.styleName)+e}else n.lblStyleInfo.plainText=n.texts.noStyle;V()}},I=function(e){u&&n.applyStyle(e,B(u))},H=function(e){const t=u&&u.styleName===e.name,o=HGroup({width:"auto",height:"auto",align:"left center",gap:4,padding:[10,4],color:a.chip.color,round:a.chip.round,border:t?2:1,borderColor:t?a.chip.activeBorderColor:a.chip.borderColor});o.cursor="pointer",o.css.maxWidth="100%",o.role="button",o.elem.setAttribute("title",n.texts.applyHint),o.tabIndex=0,o.clickable=1;const l=e.props;Label({plainText:e.name,fontSize:Math.min(15,Math.max(11,l.fontSize)),textColor:l.textColor,color:l.color||"transparent",bold:l.bold,italic:l.italic,padding:l.color?[6,1]:0,round:4,ellipsis:1}).css.maxWidth="160px";const r=Label({text:LabelEditor.getCloseSvg(a.chip.closeColor,12),width:18,height:18,round:9,clickable:1});r.elem.style.display="flex",r.css={alignItems:"center",justifyContent:"center"},r.lineHeight="0",r.role="button",r.aria={label:n.texts.removeStyle+": "+e.name},r.on("click",function(t,o){o.stopPropagation(),n.removeStyle(e.name)}),endGroup(),o.on("click",function(){I(e.name)}),o.on("keydown",function(t,o){"Enter"!==o.key&&" "!==o.key||(o.preventDefault(),I(e.name))})},V=function(){n.chipHolder&&(n.chipWrapper&&n.chipWrapper.remove(),createIn(n.chipHolder,function(){n.chipWrapper=HGroup({width:"100%",height:"auto",align:"left top",gap:6,wrap:1}),n.chipWrapper.position="relative",0==d.length&&Label({plainText:n.texts.noStyles,width:"100%",fontSize:12,textColor:a.panel.hintColor}),d.forEach(H),endGroup()}))},_=function(e){const t=VGroup({width:"100%",height:"auto",align:"left top",gap:6});return t.css.alignItems="stretch",Label({plainText:e,fontSize:12,textColor:a.panel.captionColor}),t},j=function(){const e=HGroup({width:"100%",height:"auto",align:"left top",gap:12});return e.css.alignItems="flex-start",e},M=function(e){const t=_(e);return t.width="auto",t.css={flex:"1 1 0",minWidth:"0"},t},K=function(e){const t=Input({width:"100%",height:a.input.height,minimal:1,fontSize:14,color:a.input.color,textColor:a.input.textColor,round:a.input.round,border:1,borderColor:a.input.borderColor}),o=t.inputElement;return o.style.width="100%",o.style.height="100%",o.style.boxSizing="border-box",o.style.padding="0px 10px",o.style.backgroundColor="transparent",o.style.color=a.input.textColor,t.shrink=0,o.addEventListener("focus",function(){t.borderColor=a.input.focusColor}),o.addEventListener("blur",function(){t.borderColor=a.input.borderColor}),o.addEventListener("input",function(){e(t.text)}),t},R=function(e,t,o,l){return Stepper({width:"100%",height:a.input.height,value:e,minValue:e,maxValue:t,ariaLabel:o,styleName:a.stepperStyleName,style:i(a.stepperStyle),onChange:function(e){T(l,e.value)}})},J=function(e,t){return ColorPicker({width:"100%",height:a.input.height,colors:n.colorPalette.slice(),styleName:a.selectColorStyleName,style:i(a.selectColorStyle),onChange:function(o){o.value&&(t?t(o.value):T(e,o.value))}})},U=function(e,t){return Tabs({scale:1,width:"100%",variant:"pill",fullWidth:1,tabs:e,value:e[0].key,styleName:a.tabsStyleName,style:i(a.tabsStyle),onChange:function(e){t(e.value)}})},Y=function(e,t){return CheckBox({labelText:e,styleName:a.checkBoxStyleName,style:i(a.checkBoxStyle),onChange:function(e){T(t,e.checked)}})},q=function(e,t,o){const l=t?a.button:a.secondaryButton,r=Button({text:e,width:"auto",height:a.button.height,fontSize:a.button.fontSize,color:l.color,textColor:l.textColor,round:a.button.round});return r.css={backgroundImage:"none",boxShadow:"none",border:"0",padding:"0px 16px",whiteSpace:"nowrap",transition:"background-color 0.12s"},r.shrink=0,r.on("mouseenter",function(){r.color=l.hoverColor}),r.on("mouseleave",function(){r.color=l.color}),r.on("click",o),r};if(n.addLabel=function(e={},t=0){p++;const o=S(e);e&&void 0!==e.text||(o.text=String(n.newLabel.text||"").replace("{n}",String(p)));const l={props:o,styleName:"",styleChanged:0,label:null},r=e&&e.styleName;return r&&k(r)&&(l.styleName=r),c.push(l),z(l),G(),t&&(P(l),l.label.elem.focus({preventScroll:!0})),E(),c.length-1},n.removeLabel=function(e){const t=c[e];if(!t)return;t===u&&P(null),c.splice(e,1),t.label.remove(),G();const o=c[Math.min(e,c.length-1)];o&&!1===n.elem.contains(document.activeElement)&&o.label.elem.focus({preventScroll:!0}),E()},n.duplicateLabel=function(e){const t=c[e];if(!t)return-1;const o=Object.assign({},t.props,{styleName:t.styleName}),l=n.addLabel(o,0);return c[l].styleChanged=t.styleChanged,n.moveLabel(l,e+1),P(c[e+1]),e+1},n.moveLabel=function(e,t){const o=c[e];if(!o)return;const l=Math.max(0,Math.min(t,c.length-1));c.splice(e,1),c.splice(l,0,o);const r=c[l+1];n.listWrapper.elem.insertBefore(o.label.elem,r?r.label.elem:null),E()},n.selectLabel=function(e){P(c[e]||null)},n.getSelectedIndex=function(){return B(u)},n.getLabels=function(){return c.map(function(e){return Object.assign({},e.props,{styleName:e.styleName})})},n.setLabels=function(e){P(null),p=0,c=(Array.isArray(e)?e:[]).map(function(e){p++;const t=e&&e.styleName&&k(e.styleName)?e.styleName:"";return{props:S(e),styleName:t,styleChanged:0,label:null}}),n.listWrapper&&n.listWrapper.remove(),createIn(n.listArea,function(){n.listWrapper=VGroup({width:"100%",height:"auto",align:"left top",gap:a.list.gap,padding:a.list.padding}),n.listWrapper.position="relative",n.listWrapper.role="listbox",n.listWrapper.aria={label:n.texts.title},endGroup()}),c.forEach(z),G(),n.labels=n.getLabels()},n.saveStyle=function(e,t=-1){const o=t>=0?c[t]:u;if(e=String(e??"").trim(),!o||!e)return 0;const l=v(o.props),r=k(e);r?r.props=l:d.push({name:e,props:l}),o.styleName=e,o.styleChanged=0;let n=0;return c.forEach(function(t){t!==o&&t.styleName===e&&(t.props=S(Object.assign({},t.props,l),t.props),t.styleChanged=0,N(t),n=1)}),N(o),w(),(n||r)&&E(),1},n.applyStyle=function(e,t=-1){const o=t>=0?c[t]:u,l=k(e);return o&&l?(o.props=S(Object.assign({},o.props,l.props),o.props),o.styleName=l.name,o.styleChanged=0,N(o),o===u?D():V(),E(),1):0},n.removeStyle=function(e){const t=d.findIndex(function(t){return t.name===e});t<0||(d.splice(t,1),c.forEach(function(t){t.styleName===e&&(t.styleName="",t.styleChanged=0,N(t))}),w(),E())},n.getSavedStyles=function(){return d.map(function(e){return{name:e.name,props:Object.assign({},e.props)}})},n.setSavedStyles=function(e){d=[],(Array.isArray(e)?e:[]).forEach(function(e){const t=String((e&&e.name)??"").trim();t&&!k(t)&&d.push({name:t,props:v(S(e.props))})}),n.savedStyles=n.getSavedStyles(),A(),V(),O()},n.refresh=function(){c.forEach(N),G()},n.clipContent=1,n.layout=VGroup({width:"100%",height:"100%",align:"left top",gap:0}),n.layout.css.alignItems="stretch",n.header=HGroup({width:"100%",height:"auto",align:"left center",gap:8,padding:[16,10],color:a.header.color}),n.header.shrink=0,n.header.css.borderBottom="1px solid "+a.header.dividerColor,n.lblTitle=Label({plainText:n.texts.title,fontSize:a.header.titleSize,textColor:a.header.titleColor,bold:1}),n.lblTitle.css.flex="1 1 0",n.btnAdd=q(n.texts.addButton,1,function(){n.addLabel({},1)}),endGroup(),n.listHolder=startBox({width:"100%",height:"auto",color:a.list.color}),n.listHolder.css={flex:"1 1 0",minHeight:"0"},n.listArea=Box(0,0,"100%","100%",{color:"transparent",scrollY:1}),n.listArea.clickable=1,n.lblEmpty=Label({plainText:n.texts.empty,width:"100%",top:40,fontSize:14,textColor:a.list.emptyColor,textAlign:"center",padding:[24,0],visible:0}),1==n.useScrollBar&&"undefined"!=typeof ScrollBar){const e={scrollableBox:n.listArea,neverHide:0,showDots:0};n.listScrollBar=ScrollBar(Object.assign(e,a.scrollBar))}endBox(),endGroup();n.sidePanel=SidePanel({side:"right",panelSize:n.panelWidth,titleText:n.texts.panelTitle,ariaLabel:n.texts.panelTitle,showBackdrop:0,closeOnEscape:1,styleName:a.sidePanelStyleName,style:i(a.sidePanelStyle),onClose:function(){if(b||!n||!u)return;const e=u;P(null),e.label&&function(){const e=document.activeElement;return!e||e===document.body||!(!n.sidePanel||!n.sidePanel.elem.contains(e))}()&&e.label.elem.focus({preventScroll:!0})}}),n.own(n.sidePanel),n.sidePanel.startBody(),n.panelContent=VGroup({width:"100%",height:"auto",align:"left top",gap:a.panel.gap}),n.panelContent.css.alignItems="stretch",_(n.texts.text),h.text=K(function(e){T("text",e)}),h.text.inputElement.setAttribute("aria-label",n.texts.text),endGroup(),j(),M(n.texts.fontSize),h.fontSize=R(f.min,f.max,n.texts.fontSize,"fontSize"),endGroup(),M(n.texts.fontStyle),VGroup({width:"100%",height:"auto",align:"left top",gap:4}),h.bold=Y(n.texts.bold,"bold"),h.italic=Y(n.texts.italic,"italic"),endGroup(),endGroup(),endGroup(),_(n.texts.align);const Q=[{key:"left",text:n.texts.left},{key:"center",text:n.texts.center},{key:"right",text:n.texts.right}];h.align=U(Q,function(e){T("textAlign",e)}),endGroup(),_(n.texts.width);const X=[{key:"auto",text:n.texts.widthAuto},{key:"full",text:n.texts.widthFull}];h.width=U(X,function(e){T("fullWidth","full"===e?1:0)}),endGroup(),_(n.texts.textColor),h.textColor=J("textColor"),endGroup(),_(n.texts.background),h.background=U([{key:"none",text:n.texts.none},{key:"color",text:n.texts.colorOn}],function(e){T("color","color"===e?h.bgColor.value||m:""),h.bgField.visible="color"===e?1:0}),endGroup(),h.bgField=_(n.texts.backgroundColor),h.bgColor=J("color"),endGroup(),j(),M(n.texts.padding),h.padding=R(g.min,g.max,n.texts.padding,"padding"),endGroup(),M(n.texts.round),h.round=R(y.min,y.max,n.texts.round,"round"),endGroup(),endGroup(),j(),M(n.texts.border),h.border=R(x.min,x.max,n.texts.border,"border"),endGroup(),M(n.texts.borderColor),h.borderColor=J("borderColor"),endGroup(),endGroup(),HGroup({width:"100%",height:"auto",align:"left center",gap:8}),n.btnDuplicate=q(n.texts.duplicate,0,function(){u&&n.duplicateLabel(B(u))}),n.btnRemove=q(n.texts.remove,0,function(){u&&n.removeLabel(B(u))}),n.btnRemove.textColor=a.secondaryButton.dangerTextColor,endGroup(),Box({width:"100%",height:1,color:a.panel.dividerColor}),that.shrink=0,_(n.texts.savedStyles),n.lblStyleInfo=Label({plainText:"",width:"100%",fontSize:12,textColor:a.panel.textColor}),HGroup({width:"100%",height:"auto",align:"left center",gap:8}),h.styleName=K(function(){h.styleName.borderColor=a.input.focusColor}),h.styleName.width="auto",h.styleName.css={flex:"1 1 0",minWidth:"0"},h.styleName.inputElement.placeholder=n.texts.styleNamePlaceholder,h.styleName.inputElement.setAttribute("aria-label",n.texts.styleNamePlaceholder),n.btnSaveStyle=q(n.texts.save,1,function(){const e=String(h.styleName.text||"").trim();e?n.saveStyle(e):h.styleName.inputElement.focus()}),endGroup(),n.chipHolder=startBox({width:"100%",height:"auto",color:"transparent"}),endBox(),Label({plainText:n.texts.applyHint,width:"100%",fontSize:11,textColor:a.panel.hintColor}),endGroup(),endGroup(),n.sidePanel.endBody(),h.styleName.inputElement.addEventListener("keydown",function(e){"Enter"===e.key&&(e.preventDefault(),n.btnSaveStyle.elem.click())});n.listArea.on("click",function(e,t){(function(e){return!n.listWrapper||!n.listWrapper.elem.contains(e.target)||e.target===n.listWrapper.elem})(t)&&P(null)}),n.on("keydown",function(e,t){if("Escape"!==t.key||!u)return;t.preventDefault();const o=u;P(null),o.label.elem.focus({preventScroll:!0})});let Z=null;if(n.storageKey)try{Z=basic.storage.load(n.storageKey)}catch(e){Z=null}return n.setSavedStyles(Array.isArray(Z)?Z:r),n.setLabels(l),endObject(n)};LabelEditor.getCloseSvg=function(e,t){return'<svg xmlns="http://www.w3.org/2000/svg" width="'+t+'" height="'+t+'" viewBox="0 0 24 24" fill="none" stroke="'+e+'" stroke-width="2.4" stroke-linecap="round"><path d="M6 6l12 12M18 6L6 18"/></svg>'},LabelEditor.styles={light:LabelEditorDefaults.style,dark:{style:{box:{color:"#1C1C1B",border:1,borderColor:"rgba(255, 255, 255, 0.10)",round:10},header:{color:"#232322",dividerColor:"rgba(255, 255, 255, 0.08)",titleColor:"rgba(255, 255, 255, 0.9)",titleSize:15},list:{color:"#1C1C1B",padding:24,gap:12,emptyColor:"rgba(255, 255, 255, 0.4)"},selection:{color:"#65A293",hoverColor:"rgba(101, 162, 147, 0.45)"},button:{color:"#3D7A6B",textColor:White(1),hoverColor:"#4A8A7A",round:6,fontSize:13,height:36},secondaryButton:{color:"rgba(255, 255, 255, 0.08)",textColor:"rgba(255, 255, 255, 0.85)",hoverColor:"rgba(255, 255, 255, 0.14)",dangerTextColor:"#E57B6B"},panel:{dividerColor:"rgba(255, 255, 255, 0.08)",gap:18,captionColor:"rgba(255, 255, 255, 0.5)",textColor:"rgba(255, 255, 255, 0.9)",hintColor:"rgba(255, 255, 255, 0.4)"},input:{color:"#2A2A29",borderColor:"rgba(255, 255, 255, 0.12)",focusColor:"#65A293",textColor:"rgba(255, 255, 255, 0.9)",round:6,height:38},chip:{color:"#2A2A29",borderColor:"rgba(255, 255, 255, 0.12)",activeBorderColor:"#65A293",round:16,closeColor:"rgba(255, 255, 255, 0.5)"},sidePanelStyleName:"dark",stepperStyleName:"dark",tabsStyleName:"dark",checkBoxStyleName:"dark",selectColorStyleName:"dark",selectColorStyle:{field:{color:"#2A2A29",borderColor:"rgba(255, 255, 255, 0.12)",round:6},fieldText:{fontSize:13}},scrollBar:{bar_color:"#8A8A88",bar_mouseOverColor:"#BFBFBD",bar_width:4,bar_round:3,bar_opacity:.4,bar_mouseOverOpacity:.9,bar_padding:2}},newLabel:{textColor:"#E8E8E6",borderColor:"#E8E8E6"},colorPalette:["#FFFFFF","#E8E8E6","#B5B5B3","#7A7A78","#2A2A29","#E57B6B","#F2B45A","#D9C36A","#7CC49A","#65A293","#6FA8DC","#8CC8F0","#A38BEA","#C98AD6","#F08DB8","#3A2523","#3A3220","#233528","#1F2E3A","#2E2840"]}},LabelEditor.styles.classic=LabelEditor.styles.light;
@@ -1,2 +1,2 @@
1
1
  /* Bismillah */
2
- "use strict";const LeftMenuDefaults={key:"0",expandedWidth:250,topBarHeight:40,backgroundColor:"#141414",hoverColor:"rgba(255, 255, 255, 0.05)",selectedColor:"#583432",titleColor:"#8E342F",textColor:"rgba(255, 255, 255, 0.6)",selectedTextColor:"rgba(255, 255, 255, 0.95)",invertIconColor:1,openOnClick:"auto",items:[],onItemClick:function(t){},onMenuToggle:function(t){}},LeftMenu=function(t={}){mergeIntoIfMissing(t,LeftMenuDefaults);let o=startObject(t),e=0,n=null,r=0;const a=[],i=[];o.publicVar=1,o.state="collapsed";const c=function(t,e){if("normal"===e)return t.css.background="transparent",t.icon.opacity=.6,void(t.textLabel.textColor=o.textColor);const n="selected"===e?o.selectedColor:o.hoverColor;t.css.background=`linear-gradient(to right, ${n} 0%, rgba(0,0,0,0) 100%)`,t.icon.opacity=1,t.textLabel.textColor=o.selectedTextColor},l=function(t){const a=startBox({width:"100%",height:40,color:"transparent",clickable:1,position:"relative"});return a.setMotion("background-color 0.2s"),a.cursor="pointer",a.data=t,HGroup({align:"left center",gap:20,padding:[8,0]}),a.icon=Icon({width:24,height:24,color:"transparent",opacity:.6}),a.icon.load(t.icon),1==o.invertIconColor&&(that.css.filter="invert(100%)"),a.textLabel=Label({text:t.text,textColor:o.textColor,fontSize:18,color:"transparent"}),endGroup(),endBox(),a.on("click",function(a,i){i&&i.stopPropagation(),!r||e?(n!=t.key&&(t.dontSelect||s(t.key),o.onItemClick(t)),r&&p()):u()}),a.on("mouseover",function(){r||n!=t.key&&c(a,"hover")}),a.on("mouseout",function(){r||n!=t.key&&c(a,"normal")}),a},d=function(t){const e=startBox({width:"100%",height:29,color:"transparent",clickable:1,position:"relative"});e.data=t,Box(0,0,100,1,{color:o.titleColor}),that.top=14,that.opacity=.5,AutoLayout({align:"left center",padding:[40,0]});return Label({text:t.text,textColor:o.titleColor,fontSize:12,color:o.backgroundColor,padding:[12,0]}).css={fontWeight:"bold",textTransform:"uppercase"},endAutoLayout(),endBox(),e};o.clearSelection=function(){if(n){const t=i.find(t=>t.data.key===n);t&&"button"===t.data.type&&(c(t,"normal"),t.cursor="pointer"),n=null}};const s=function(t){o.clearSelection();const e=i.find(o=>o.data.key===t);e&&"button"===e.data.type&&(c(e,"selected"),e.cursor="default",n=t)},u=function(){e||(e=1,o.state="expanded",o.width=o.expandedWidth,o.onMenuToggle(1))},p=function(){e&&(e=0,o.state="collapsed",o.width=40,o.onMenuToggle(0))};o.setOpenOnClick=function(t){return o.openOnClick=t,r="auto"===t?window.matchMedia&&window.matchMedia("(hover: none)").matches||window.matchMedia&&window.matchMedia("(pointer: coarse)").matches?1:basic.isMobile():basic.isOn(t)?1:0,r||p(),r},o.isTapMode=function(){return r};const h=o.remove;o.superRemove=h,o.remove=function(){o&&(page.remove_onResize(f),h.call(o),o=null)},o.addItemToTop=function(t){a.push(t);const e="button"===t.type?l(t):d(t);return i.push(e),o.topBox.add(e),e},o.addItemToBottom=function(t){a.push(t);const e="button"===t.type?l(t):d(t);return i.push(e),o.bottomBox.add(e),e},o.removeItem=function(t){t===n&&o.clearSelection();const e=a.findIndex(o=>o.key===t);if(-1!==e){i[e].remove(),a.splice(e,1),i.splice(e,1)}},o.getSelectedItem=function(){return a.find(t=>t.key===n)},o.setSelectedItem=function(t){s(t)},o.expand=function(){u()},o.collapse=function(){p()},o.toggle=function(){e?p():u()},o.cursor="default",o.color=o.backgroundColor,o.height=`calc(100% - ${o.topBarHeight}px)`,o.width=40,o.bottom=0,o.left=0,o.round=0;o.scrollableBox=startBox(0,30,o.expandedWidth,0),that.color="transparent",that.scrollY=1,o.topBox=VGroup({align:"top left",gap:0,padding:0,height:"auto",width:"100%"}),that.position="relative",o.items.forEach(t=>{o.addItemToTop(t)}),endGroup(),endBox(),o.scrollBar=ScrollBar({scrollableBox:o.scrollableBox,bar_border:0,bar_round:3,bar_borderColor:"rgba(0, 0, 0, 1)",bar_width:4,bar_mouseOverWidth:4,bar_mouseOverColor:"#FFFFFF",bar_opacity:.4,bar_mouseOverOpacity:.9,bar_padding:2,bar_color:"#FFFFFF",neverHide:0,showDots:1});const f=function(){o.scrollableBox.height=o.height-60-o.bottomBox.height-30};return o.bottomBox=VGroup({align:"bottom left",gap:0,padding:0,height:"auto",width:o.expandedWidth}),that.bottom=30,that.left=0,that.color="transparent",o.bottomBox.onResize(function(t){f()}),page.onResize(f),endGroup(),o.setOpenOnClick(o.openOnClick),o.on("mouseenter",function(){r||u()}),o.on("mouseleave",function(){r||p()}),o.on("click",function(){r&&!e&&u()}),o.listenTo(document,"pointerdown",function(t,n){o&&r&&e&&(o.elem.contains(n.target)||p())},!0),endObject(o)};
2
+ "use strict";const LeftMenuDefaults={key:"0",expandedWidth:250,itemHeight:40,topBarHeight:40,backgroundColor:"#141414",hoverColor:"rgba(255, 255, 255, 0.05)",selectedColor:"#583432",titleColor:"#8E342F",textColor:"rgba(255, 255, 255, 0.6)",selectedTextColor:"rgba(255, 255, 255, 0.95)",allowHtml:0,invertIconColor:1,lineColor:"",expandedShadow:"",scrollBarColor:"#FFFFFF",openOnClick:"auto",items:[],onItemClick:function(o,t){},onMenuToggle:function(o,t){},styleName:"dark",style:{}},LeftMenu=function(o={}){basic.applyStylePackage(o,LeftMenu.styles,LeftMenuDefaults),mergeIntoIfMissing(o,LeftMenuDefaults);let t=startObject(o),e=0,n=null,r=0;const l=[],a=[];t.publicVar=1,t.state="collapsed";const i=function(o,e){const n=null==e?"":String(e);1==t.allowHtml?o.text=n:o.plainText=n},c=function(o,e){if("normal"===e)return o.css.background="transparent",o.icon.opacity=.6,void(o.textLabel.textColor=t.textColor);const n="selected"===e?t.selectedColor:t.hoverColor;o.css.background=`linear-gradient(to right, ${n} 0%, rgba(0,0,0,0) 100%)`,o.icon.opacity=1,o.textLabel.textColor=t.selectedTextColor},d=function(o){const l=startBox({width:"100%",height:t.itemHeight,color:"transparent",clickable:1,position:"relative"});return l.setMotion("background-color 0.2s"),l.cursor="pointer",l.data=o,HGroup({align:"left center",gap:20,padding:[8,0]}),l.icon=Icon({width:24,height:24,color:"transparent",opacity:.6}),l.icon.load(o.iconFile),1==t.invertIconColor&&(that.css.filter="invert(100%)"),l.textLabel=Label({textColor:t.textColor,fontSize:18,color:"transparent"}),i(l.textLabel,o.text),endGroup(),endBox(),l.on("click",function(l,a){a&&a.stopPropagation(),!r||e||"direct"===t.openOnClick?(n!=o.key&&(o.dontSelect||u(o.key),t.onItemClick(t,o)),r&&h()):p()}),l.on("mouseover",function(){r||n!=o.key&&c(l,"hover")}),l.on("mouseout",function(){r||n!=o.key&&c(l,"normal")}),l},s=function(o){const e=startBox({width:"100%",height:29,color:"transparent",clickable:1,position:"relative"});e.data=o,Box(0,0,100,1,{color:t.titleColor}),that.top=14,that.opacity=.5,AutoLayout({align:"left center",padding:[40,0]});const n=Label({textColor:t.titleColor,fontSize:12,color:t.backgroundColor,padding:[12,0]});return i(n,o.text),n.css={fontWeight:"bold",textTransform:"uppercase"},endAutoLayout(),endBox(),e};t.clearSelection=function(){if(n){const o=a.find(o=>o.data.key===n);o&&"button"===o.data.type&&(c(o,"normal"),o.cursor="pointer"),n=null}};const u=function(o){t.clearSelection();const e=a.find(t=>t.data.key===o);e&&"button"===e.data.type&&(c(e,"selected"),e.cursor="default",n=o)},p=function(){e||(e=1,t.state="expanded",t.width=t.expandedWidth,f(),t.onMenuToggle(t,1))},h=function(){e&&(e=0,t.state="collapsed",t.width=40,f(),t.onMenuToggle(t,0))},f=function(){t.boxShadow=e&&t.expandedShadow?t.expandedShadow:""};t.setOpenOnClick=function(o){return t.openOnClick=o,r="auto"===o?window.matchMedia&&window.matchMedia("(hover: none)").matches||window.matchMedia&&window.matchMedia("(pointer: coarse)").matches?1:basic.isMobile():"direct"===o||basic.isOn(o)?1:0,r||h(),r},t.isTapMode=function(){return r};const g=t.remove;t.superRemove=g,t.remove=function(){t&&(page.remove_onResize(b),g.call(t),t=null)},t.addItemToTop=function(o){l.push(o);const e="button"===o.type?d(o):s(o);return a.push(e),t.topBox.add(e),e},t.addItemToBottom=function(o){l.push(o);const e="button"===o.type?d(o):s(o);return a.push(e),t.bottomBox.add(e),e},t.removeItem=function(o){o===n&&t.clearSelection();const e=l.findIndex(t=>t.key===o);if(-1!==e){a[e].remove(),l.splice(e,1),a.splice(e,1)}},t.getSelectedItem=function(){return l.find(o=>o.key===n)},t.setSelectedItem=function(o){u(o)},t.expand=function(){p()},t.collapse=function(){h()},t.toggle=function(){e?h():p()},t.cursor="default",t.color=t.backgroundColor,t.height=`calc(100% - ${t.topBarHeight}px)`,t.width=40,t.bottom=0,t.left=0,t.round=0;t.scrollableBox=startBox(0,30,t.expandedWidth,0),that.color="transparent",that.scrollY=1,t.topBox=VGroup({align:"top left",gap:0,padding:0,height:"auto",width:"100%"}),that.position="relative",t.items.forEach(o=>{t.addItemToTop(o)}),endGroup(),endBox(),t.scrollBar=ScrollBar({scrollableBox:t.scrollableBox,bar_border:0,bar_round:3,bar_borderColor:"rgba(0, 0, 0, 1)",bar_width:4,bar_mouseOverWidth:4,bar_mouseOverColor:t.scrollBarColor,bar_opacity:.4,bar_mouseOverOpacity:.9,bar_padding:2,bar_color:t.scrollBarColor,neverHide:0,showDots:1});const b=function(){t.scrollableBox.height=t.height-60-t.bottomBox.height-30};return t.bottomBox=VGroup({align:"bottom left",gap:0,padding:0,height:"auto",width:t.expandedWidth}),that.bottom=30,that.left=0,that.color="transparent",t.bottomBox.onResize(function(o){b()}),page.onResize(b),endGroup(),t.lineColor&&(t.line=Box({right:0,top:0,width:1,height:"100%",color:t.lineColor})),t.setOpenOnClick(t.openOnClick),t.on("mouseenter",function(){r||p()}),t.on("mouseleave",function(){r||h()}),t.on("click",function(){r&&!e&&"direct"!==t.openOnClick&&p()}),t.listenTo(document,"pointerdown",function(o,n){t&&r&&e&&(t.elem.contains(n.target)||h())},!0),endObject(t)};LeftMenu.styles={dark:{style:{}},light:{style:{},backgroundColor:"#F7F7F5",hoverColor:Black(.05),selectedColor:"#D1ECEE",titleColor:"#3D8F96",textColor:Black(.6),selectedTextColor:Black(.88),invertIconColor:0,lineColor:Black(.08),expandedShadow:"6px 0 18px "+Black(.08),scrollBarColor:"#373836"}};
@@ -1,2 +1,2 @@
1
1
  /* Bismillah */
2
- "use strict";const LineProgressBarDefaults={width:300,height:50,progress:0,primaryColor:"indianred",secondaryColor:"lightgray",showValueLabel:!1,backgroundColor:"transparent"},LineProgressBar=function(o={}){mergeIntoIfMissing(o,LineProgressBarDefaults);const t=startObject(o);t.clipContent=0;const r={width:3,overhang:2,zIndex:10,color:"black"},e={width:2,overhang:1,zIndex:5},n=Math.floor(t.width/4),s=[];let i=null,a=null;t.currentProgress=t.progress;const c=function(){i=Label({text:"0%",fontSize:12,color:t.primaryColor,textColor:"white",position:"absolute",opacity:0,width:"auto",height:"auto",padding:[6,2],round:100}),t.add(i),i.setMotion("opacity 0.3s")},l=function(o,n){const s=4*o,i={color:o<=n?t.primaryColor:t.secondaryColor,width:1,overhang:0,zIndex:0};return o===n&&Object.assign(i,r),o!==n-1&&o!==n+1||Object.assign(i,e),i.left=s-(i.width-1)/2,i},h=function(o){i.text=Math.round(t.currentProgress)+"%",i.top=-25,i.left=function(o){return o<0?0:l(o,o).left+r.width/2}(o),i.css.transform="translateX(-50%)",i.opacity=1,i.color=t.primaryColor,a&&a(),a=t.after(1e3,function(){i.opacity=0})},d=function(){const o=function(){const o=Math.floor(t.currentProgress/100*n);return o>=n?n-1:o}();!function(o){for(let r=0;r<n;r++){const e=l(r,o),n=s[r];n.color=e.color,n.width=e.width,n.height=t.height+2*e.overhang,n.top=-e.overhang,n.left=e.left,n.round=3,n.opacity=1,n.zIndex=e.zIndex}}(o),t.showValueLabel&&i&&h(o)};return t.setProgress=function(o){o<0&&(o=0),o>100&&(o=100),t.currentProgress=o,d()},function(){const o=Box({width:t.width,height:t.height,color:"transparent",position:"absolute",left:0,top:0});for(let o=0;o<n;o++){const r=Box({width:1,height:t.height,left:4*o,top:0,color:t.secondaryColor,position:"absolute"});s.push(r)}o.add(...s),t.showValueLabel&&c()}(),d(),endObject(t)};void 0===window.ProgressBar&&(window.ProgressBar=LineProgressBar);
2
+ "use strict";const LineProgressBarDefaults={width:300,height:50,progress:0,primaryColor:"indianred",secondaryColor:"lightgray",lineWidth:1,lineGap:3,lineRound:3,headGrow:1,showValueLabel:!1,valueBubble:0,valueBubbleLook:{},animated:0,backgroundColor:"transparent"},LineProgressBar=function(o={}){mergeIntoIfMissing(o,LineProgressBarDefaults);const t=startObject(o);t.clipContent=0;const e=t.lineWidth+t.lineGap,n="full"===t.lineRound?t.lineWidth/2:t.lineRound,r={width:3*t.lineWidth,overhang:2,zIndex:10,color:"black"},i={width:2*t.lineWidth,overhang:1,zIndex:5};let l=0;const s=[];let a=null,c=null,u=null,d=null,h=0,f=0;t.currentProgress=t.progress;const p=function(){return Math.max(0,Math.floor(t.width/e))},g=function(){s.forEach(function(o){o.remove()}),s.length=0,l=p(),createIn(a,function(){for(let o=0;o<l;o++)s.push(Box({width:t.lineWidth,height:t.height,left:o*e,top:0,color:t.secondaryColor,position:"absolute"}))})},b=function(){c=Label({text:"0%",fontSize:12,color:t.primaryColor,textColor:"white",position:"absolute",opacity:0,width:"auto",height:"auto",padding:[6,2],round:100}),t.add(c),c.setMotion("opacity 0.3s")},m=function(){return Math.round(t.currentProgress/100*l)-1},w=function(o,n){const l=o*e,s={color:o<=n?t.primaryColor:t.secondaryColor,width:t.lineWidth,overhang:0,zIndex:0};return 1==t.headGrow&&(o===n&&Object.assign(s,r),o!==n-1&&o!==n+1||Object.assign(s,i)),s.left=l-(s.width-t.lineWidth)/2,s},y=function(o){for(let e=0;e<l;e++){const r=w(e,o),i=s[e];i.color=r.color,i.width=r.width,i.height=t.height+2*r.overhang,i.top=-r.overhang,i.left=r.left,i.round=n,i.opacity=1,i.zIndex=r.zIndex}},x=function(o){c.text=Math.round(t.currentProgress)+"%",c.top=-25,c.left=function(o){if(o<0)return 0;const t=w(o,o);return t.left+t.width/2}(o),c.css.transform="translateX(-50%)",c.opacity=1,c.color=t.primaryColor,u&&u(),u=t.after(1e3,function(){c.opacity=0})},v=function(){if("undefined"==typeof Tooltip)return void console.warn("LineProgressBar: valueBubble needs comp/tooltip.js (Tooltip).");const o=Object.assign({color:t.primaryColor},t.valueBubbleLook);o.zIndex=basic.zIndexAbove(t,2),d=Tooltip.createBubble("",o),t.own(d),t.listenTo(window,"scroll",M,!0),t.onPageResize(P),document.fonts&&"loaded"!=document.fonts.status&&document.fonts.ready.then(P)},C=function(){const o=d.elem.getBoundingClientRect();return Tooltip.toPagePoint(o.left+o.width/2,o.top)},P=function(o=!1){if(!d||d._isRemoved)return;const e=l>0&&Tooltip.isInSight(t),n=!0===o&&f&&1==t.animated&&!(window.matchMedia&&window.matchMedia("(prefers-reduced-motion: reduce)").matches)&&1==d.visible?C():null;d.visible=e?1:0,e&&(1==t.animated&&(d.setMotionNow("none"),d.css={transform:"none"}),d.label.plainText=Math.round(t.currentProgress)+"%",Tooltip.place(d,function(){const o=m();if(o>=0)return Tooltip.toPageRect(s[o]);const e=Tooltip.toPageRect(t);return{left:e.left,top:e.top,width:0,height:e.height}}(),"top"),n&&B(n))},B=function(o){const t=C();d.css={transform:"translate("+(o.x-t.x)+"px, "+(o.y-t.y)+"px)"},d.elem.offsetHeight,d.setMotionNow("transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1)"),d.css={transform:"none"}},M=function(){h||(h=1,requestAnimationFrame(function(){h=0,P()}))},z=function(){const o=m();y(o),t.showValueLabel&&c&&x(o),P(!0)};return t.setProgress=function(o){o<0&&(o=0),o>100&&(o=100),t.currentProgress=o,z()},t.setPrimaryColor=function(o){t.primaryColor=o,d&&!t.valueBubbleLook.color&&Tooltip.paintBubble(d,o),c&&(c.color=o),y(m())},t.setSecondaryColor=function(o){t.secondaryColor=o,y(m())},t.setAnimated=function(o){t.animated=1==o?1:0,1!=t.animated&&d&&(d.setMotionNow("none"),d.css={transform:"none"})},a=Box({width:"100%",height:"100%",color:"transparent",position:"absolute",left:0,top:0}),g(),t.showValueLabel&&b(),1==t.valueBubble&&v(),z(),t.onResize(function(){p()!==l&&g(),y(m()),P()}),f=1,endObject(t)};
@@ -1,2 +1,2 @@
1
1
  /* Bismillah */
2
- "use strict";const LoadingScreenDefaults={left:0,top:0,width:"100%",height:"100%",styleName:"light",iconFile:"",iconSvg:"",titleText:"",messageText:"",spinnerType:"clock",progress:-1,opened:1,minDuration:600,fadeDuration:.35,removeOnClose:0,onClose:function(e){},style:{box:{color:"#FFFFFF"},layout:{gap:14,padding:30},icon:{size:72,round:16,marginBottom:6},title:{fontSize:20,textColor:Black(.85),bold:1},message:{width:300,fontSize:15,textColor:Black(.5)},spinner:{size:30,thickness:3,color:"#3D7A6B",trackColor:Black(.1),speed:.8,marginTop:8},dots:{size:9,gap:7,color:"#3D7A6B"},clock:SmartButton.clocks.ozden,progress:{width:180,height:4,color:"#3D7A6B",trackColor:Black(.08),round:100}}},LoadingScreen=function(e={}){basic.applyStylePackage(e,LoadingScreen.styles,LoadingScreenDefaults),mergeIntoIfMissing(e,LoadingScreenDefaults),e.color=e.style.box.color,LoadingScreen.injectCss();let o=startObject(e);const t=o.style;let n=0,s=null,r=null;const i=function(){s&&s(),r&&r(),s=null,r=null},l=function(){s=null,o.opacity=0,r=o.after(1e3*o.fadeDuration,function(){r=null,o.visible=0,o.css.pointerEvents="none",o.onClose(o),o.removeOnClose&&o.remove()})};return o.open=function(){i(),o.opened=1,n=Date.now(),o.setMotionNow("none"),o.opacity=1,o.visible=1,o.css.pointerEvents="auto",o.bringToFront()},o.close=function(){if(!o.opened)return;o.opened=0,i(),o.setMotionNow("opacity "+o.fadeDuration+"s");const e=Math.max(0,o.minDuration-(Date.now()-n));s=o.after(e,l)},o.setTitle=function(e){o.titleText=e||"",o.titleLabel.text=o.titleText,o.titleLabel.visible=o.titleText?1:0},o.setMessage=function(e){o.messageText=e||"",o.messageLabel.text=o.messageText,o.messageLabel.visible=o.messageText?1:0},o.setProgress=function(e){e=Number(e),o.progress=isNaN(e)||e<0?-1:Math.min(e,1),function(){const e=o.progress>=0;o.progressTrack.visible=e?1:0,e&&(o.progressBar.css.width=100*o.progress+"%")}()},o.content=VGroup({align:"center center",gap:t.layout.gap,padding:t.layout.padding}),o.iconFile?(o.icon=Icon({width:t.icon.size,height:t.icon.size,round:t.icon.round}),o.icon.load(o.iconFile)):o.iconSvg&&(o.icon=Box({width:t.icon.size,height:t.icon.size,color:"transparent"}),o.icon.elem.innerHTML=o.iconSvg),o.icon&&(o.icon.css.marginBottom=t.icon.marginBottom+"px",o.icon.shrink=0),o.titleLabel=Label({text:o.titleText,fontSize:t.title.fontSize,textColor:t.title.textColor}),t.title.bold&&(o.titleLabel.css.fontFamily="opensans-bold"),o.titleLabel.css.textAlign="center",o.messageLabel=Label({text:o.messageText,width:t.message.width,fontSize:t.message.fontSize,textColor:t.message.textColor}),o.messageLabel.css={textAlign:"center",lineHeight:"1.45"},o.spinner=Box({width:t.spinner.size,height:t.spinner.size,color:"transparent",round:100}),o.spinner.css={border:t.spinner.thickness+"px solid "+t.spinner.trackColor,borderTopColor:t.spinner.color,boxSizing:"border-box",animation:"loadingScreenSpin "+t.spinner.speed+"s linear infinite",marginTop:t.spinner.marginTop+"px"},o.spinner.shrink=0,o.dots=SmartButton.createDots(t.dots),o.dots.css.marginTop=t.spinner.marginTop+"px",o.clock=Box({width:SmartButton.CLOCK_SIZE,height:SmartButton.CLOCK_SIZE,color:"transparent"}),o.clock.elem.innerHTML=SmartButton.createClockSvg(t.clock),o.clock.css.marginTop=t.spinner.marginTop+"px",o.clock.shrink=0,o.progressTrack=startBox({width:t.progress.width,height:t.progress.height,color:t.progress.trackColor,round:t.progress.round}),o.progressTrack.css.overflow="hidden",o.progressTrack.shrink=0,o.progressBar=Box(0,0,0,"100%",{color:t.progress.color,round:t.progress.round}),o.progressBar.setMotion("width 0.25s"),endBox(),endGroup(),o.titleLabel.visible=o.titleText?1:0,o.messageLabel.visible=o.messageText?1:0,o.spinner.visible="ring"===o.spinnerType?1:0,o.dots.visible="dots"===o.spinnerType?1:0,o.clock.visible="clock"===o.spinnerType?1:0,o.setProgress(o.progress),o.opened?(o.opened=0,o.open()):(o.visible=0,o.css.pointerEvents="none"),endObject(o)};LoadingScreen.clocks=SmartButton.clocks,LoadingScreen.styles={light:LoadingScreenDefaults.style,ozden:{box:{color:"#F0F1EE"},title:{textColor:"#232323"},message:{textColor:"rgba(35, 35, 35, 0.6)"},spinner:{color:"indianred"},dots:{color:"indianred"},progress:{color:"indianred",trackColor:Black(.08)},clock:LoadingScreen.clocks.ozden},ozdenDark:{box:{color:"#1B1B1B"},title:{textColor:White(.9)},message:{textColor:White(.55)},spinner:{color:"#F1C74A",trackColor:White(.12)},dots:{color:"#F1C74A"},progress:{color:"#F1C74A",trackColor:White(.12)},clock:LoadingScreen.clocks.ozdenDark},dark:{box:{color:"#141414"},title:{textColor:White(.9)},message:{textColor:White(.55)},spinner:{color:"#5FB39F",trackColor:White(.12)},dots:{color:"#5FB39F"},progress:{color:"#5FB39F",trackColor:White(.12)}}},LoadingScreen.injectCss=function(){basic.addCss("loading-screen-css","@keyframes loadingScreenSpin { to { transform: rotate(360deg); } }")};
2
+ "use strict";const LoadingScreenDefaults={left:0,top:0,width:"100%",height:"100%",styleName:"light",iconFile:"",iconSvg:"",titleText:"",allowHtml:0,messageText:"",spinnerType:"clock",progress:-1,opened:1,minDuration:600,fadeDuration:.35,removeOnClose:0,onClose:function(e){},style:{box:{color:"#FFFFFF"},layout:{gap:14,padding:30},icon:{size:72,round:16,marginBottom:6},title:{fontSize:20,textColor:Black(.85),bold:1},message:{width:300,fontSize:15,textColor:Black(.5)},spinner:{size:30,thickness:3,color:"#3D7A6B",trackColor:Black(.1),speed:.8,marginTop:8},dots:{size:9,gap:7,color:"#3D7A6B"},clock:SmartButton.clocks.ozden,progress:{width:180,height:4,color:"#3D7A6B",trackColor:Black(.08),round:100}}},LoadingScreen=function(e={}){basic.applyStylePackage(e,LoadingScreen.styles,LoadingScreenDefaults),mergeIntoIfMissing(e,LoadingScreenDefaults),e.color=e.style.box.color,LoadingScreen.injectCss();let o=startObject(e);const t=o.style;let n=0,i=null,r=null;const s=function(e,t){const n=null==t?"":String(t);1==o.allowHtml?e.text=n:e.plainText=n},l=function(){i&&i(),r&&r(),i=null,r=null},c=function(){i=null,o.opacity=0,r=o.after(1e3*o.fadeDuration,function(){r=null,o.visible=0,o.css.pointerEvents="none",o.onClose(o),o.removeOnClose&&o.remove()})};return o.open=function(){l(),o.opened=1,n=Date.now(),o.setMotionNow("none"),o.opacity=1,o.visible=1,o.css.pointerEvents="auto",o.bringToFront()},o.close=function(){if(!o.opened)return;o.opened=0,l(),o.setMotionNow("opacity "+o.fadeDuration+"s");const e=Math.max(0,o.minDuration-(Date.now()-n));i=o.after(e,c)},o.setTitleText=function(e){o.titleText=e||"",s(o.titleLabel,o.titleText),o.titleLabel.visible=o.titleText?1:0},o.setMessageText=function(e){o.messageText=e||"",s(o.messageLabel,o.messageText),o.messageLabel.visible=o.messageText?1:0},o.setProgress=function(e){e=Number(e),o.progress=isNaN(e)||e<0?-1:Math.min(e,1),function(){const e=o.progress>=0;o.progressTrack.visible=e?1:0,e&&(o.progressBar.css.width=100*o.progress+"%")}()},o.content=VGroup({align:"center center",gap:t.layout.gap,padding:t.layout.padding}),o.iconFile?(o.icon=Icon({width:t.icon.size,height:t.icon.size,round:t.icon.round}),o.icon.load(o.iconFile)):o.iconSvg&&(o.icon=Box({width:t.icon.size,height:t.icon.size,color:"transparent"}),o.icon.elem.innerHTML=o.iconSvg),o.icon&&(o.icon.css.marginBottom=t.icon.marginBottom+"px",o.icon.shrink=0),o.titleLabel=Label({fontSize:t.title.fontSize,textColor:t.title.textColor}),s(o.titleLabel,o.titleText),t.title.bold&&(o.titleLabel.css.fontFamily="opensans-bold"),o.titleLabel.css.textAlign="center",o.messageLabel=Label({width:t.message.width,fontSize:t.message.fontSize,textColor:t.message.textColor}),s(o.messageLabel,o.messageText),o.messageLabel.css={textAlign:"center",lineHeight:"1.45"},o.spinner=Box({width:t.spinner.size,height:t.spinner.size,color:"transparent",round:100}),o.spinner.css={border:t.spinner.thickness+"px solid "+t.spinner.trackColor,borderTopColor:t.spinner.color,boxSizing:"border-box",animation:"loadingScreenSpin "+t.spinner.speed+"s linear infinite",marginTop:t.spinner.marginTop+"px"},o.spinner.shrink=0,o.dots=SmartButton.createDots(t.dots),o.dots.css.marginTop=t.spinner.marginTop+"px",o.clock=Box({width:SmartButton.CLOCK_SIZE,height:SmartButton.CLOCK_SIZE,color:"transparent"}),o.clock.elem.innerHTML=SmartButton.createClockSvg(t.clock),o.clock.css.marginTop=t.spinner.marginTop+"px",o.clock.shrink=0,o.progressTrack=startBox({width:t.progress.width,height:t.progress.height,color:t.progress.trackColor,round:t.progress.round}),o.progressTrack.css.overflow="hidden",o.progressTrack.shrink=0,o.progressBar=Box(0,0,0,"100%",{color:t.progress.color,round:t.progress.round}),o.progressBar.setMotion("width 0.25s"),endBox(),endGroup(),o.titleLabel.visible=o.titleText?1:0,o.messageLabel.visible=o.messageText?1:0,o.spinner.visible="ring"===o.spinnerType?1:0,o.dots.visible="dots"===o.spinnerType?1:0,o.clock.visible="clock"===o.spinnerType?1:0,o.setProgress(o.progress),o.opened?(o.opened=0,o.open()):(o.visible=0,o.css.pointerEvents="none"),endObject(o)};LoadingScreen.clocks=SmartButton.clocks,LoadingScreen.styles={light:LoadingScreenDefaults.style,ozden:{box:{color:"#F0F1EE"},title:{textColor:"#232323"},message:{textColor:"rgba(35, 35, 35, 0.6)"},spinner:{color:"indianred"},dots:{color:"indianred"},progress:{color:"indianred",trackColor:Black(.08)},clock:LoadingScreen.clocks.ozden},ozdenDark:{box:{color:"#1B1B1B"},title:{textColor:White(.9)},message:{textColor:White(.55)},spinner:{color:"#F1C74A",trackColor:White(.12)},dots:{color:"#F1C74A"},progress:{color:"#F1C74A",trackColor:White(.12)},clock:LoadingScreen.clocks.ozdenDark},dark:{box:{color:"#141414"},title:{textColor:White(.9)},message:{textColor:White(.55)},spinner:{color:"#5FB39F",trackColor:White(.12)},dots:{color:"#5FB39F"},progress:{color:"#5FB39F",trackColor:White(.12)}}},LoadingScreen.createMinimalStyle=function(e){return{box:{color:e.ground},layout:{gap:10,padding:24},icon:{size:48,round:8,marginBottom:4},title:{fontSize:15,textColor:e.text,bold:1},message:{width:260,fontSize:13,textColor:e.softText},spinner:{size:24,thickness:2,color:e.ink,trackColor:e.track,speed:.8,marginTop:6},dots:{size:6,gap:5,color:e.ink},clock:Object.assign({},e.ring,{edgeWidth:2}),progress:{width:160,height:2,color:e.ink,trackColor:e.track,round:1}}},LoadingScreen.MINIMAL_COLORS={ground:"#FFFFFF",text:Black(.85),softText:Black(.55),ink:"#1F1F1F",track:Black(.12),ring:LoadingScreen.clocks.minimal},LoadingScreen.styles.minimal=LoadingScreen.createMinimalStyle(LoadingScreen.MINIMAL_COLORS),LoadingScreen.MINIMAL_DARK_COLORS={ground:"#1A1A19",text:White(.88),softText:White(.55),ink:"#EDEDEB",track:White(.14),ring:LoadingScreen.clocks.minimalDark},LoadingScreen.styles.minimalDark=LoadingScreen.createMinimalStyle(LoadingScreen.MINIMAL_DARK_COLORS),LoadingScreen.injectCss=function(){basic.addCss("loading-screen-css","@keyframes loadingScreenSpin { to { transform: rotate(360deg); } }")};
@@ -0,0 +1,2 @@
1
+ /* Bismillah */
2
+ "use strict";const LogViewDefaults={key:"0",width:"100%",height:260,lines:[],maxLines:1e3,autoScroll:1,showTime:1,showLevel:1,wrapLines:1,emptyText:"No output yet.",newLinesText:"{count} new",levelTexts:{info:"INFO",success:"OK",warn:"WARN",error:"ERROR",debug:"DEBUG"},ariaLabel:"Output",styleName:"light",style:{box:{color:"white",border:1,borderColor:Black(.14),round:8},line:{fontSize:13,lineHeight:20,fontFamily:'ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace',paddingX:10,space:1},area:{paddingY:6},time:{textColor:Black(.5)},levels:{info:{text:Black(.84),tag:"#2467B8",color:"transparent"},success:{text:"#1F7A5C",tag:"#1F7A5C",color:"transparent"},warn:{text:"#7A5000",tag:"#7A5000",color:"rgba(241, 199, 74, 0.2)"},error:{text:"#B93226",tag:"#B93226",color:"rgba(232, 121, 109, 0.14)"},debug:{text:Black(.55),tag:Black(.55),color:"transparent"}},empty:{fontSize:13,textColor:Black(.45)},newLines:{color:"#37474A",hoverColor:"#2A383B",textColor:"white",fontSize:12,height:28,paddingX:12,round:14,bottom:10,shadow:"0 2px 8px "+Black(.25)},scrollBar:{bar_color:"#9A9A98",bar_mouseOverColor:"#6A6A68",neverHide:0,showDots:0},focus:{ringColor:"rgba(63, 141, 148, 0.8)"}}},LogView=function(e={}){const o=e.style;basic.applyStylePackage(e,LogView.styles,LogViewDefaults),mergeIntoIfMissing(e,LogViewDefaults);const t=Array.isArray(e.lines)?e.lines:[];e.lines=[];const n=startObject(e);let l=n.style;let r=[],i=1,s=0,c=0,a=null;const u=function(e){return l.levels[e]||l.levels.info},p=function(e){return 0==r.length||r.indexOf(e)>=0},f=function(){const e=new Date;return[e.getHours(),e.getMinutes(),e.getSeconds()].map(basic.twoDigitFormat).join(":")},g=function(){const e=Object.keys(n.levelTexts).map(function(e){return n.levelTexts[e]});return Math.max.apply(null,e.map(function(e){return e.length}))},w=function(e){return(n.levelTexts[e.level]||String(e.level).toUpperCase()).padEnd(g())},h=function(e,o){return'<span style="color: '+o+'">'+basic.escapeHtml(e)+"</span>"},d=function(){const e=(1==n.showTime?9:0)+(1==n.showLevel?g()+1:0);return{paddingLeft:"calc("+e+"ch + "+l.line.paddingX+"px)",textIndent:-e+"ch"}},b=function(e){const o=u(e.level);e.row.props({fontSize:l.line.fontSize,lineHeight:l.line.lineHeight,fontFamily:l.line.fontFamily,textColor:o.text,color:o.color}),e.row.css={whiteSpace:1==n.wrapLines?"pre-wrap":"pre",overflowWrap:"anywhere",padding:l.line.space+"px "+l.line.paddingX+"px",...d()},e.row.text=function(e){let o="";return 1==n.showTime&&(o+=h(e.time,l.time.textColor)+" "),1==n.showLevel&&(o+=h(w(e),u(e.level).tag)+" "),o+basic.escapeHtml(e.text)}(e),e.row.visible=p(e.level)?1:0},m=function(e){e.row=Label({width:"auto",selectable:1,cursor:"text",shrink:0}),b(e)},x=function(){return 1!=n.autoScroll||!i||function(){const e=window.getSelection();return!(!e||e.isCollapsed||!n.elem.contains(e.anchorNode))}()},L=function(){if(n.maxLines<=0||n.lines.length<=n.maxLines)return;const e=n.scrollArea.elem,o=e.scrollHeight;n.lines.splice(0,n.lines.length-n.maxLines).forEach(function(e){e.row&&e.row.remove()}),x()&&(e.scrollTop-=o-e.scrollHeight)},B=function(){const e=n.lines.some(function(e){return p(e.level)});n.emptyGroup.visible=e?0:1,n.btnNewLines.visible=s>0?1:0,n.btnNewLines.plainText="↓ "+n.newLinesText.split("{count}").join(s)},y=function(){x()||(n.scrollArea.elem.scrollTop=n.scrollArea.elem.scrollHeight)},A=function(){a=null,L();const e=n.lines.filter(function(e){return!e.row});createIn(n.lineGroup,function(){e.forEach(m)}),1!=n.autoScroll||i||(s+=e.filter(function(e){return p(e.level)}).length),B(),y()},v=function(e,o,t){String(e).replace(/\r?\n$/,"").split(/\r?\n/).forEach(function(e){n.lines.push({text:e,level:o,time:t,row:null})})},C=function(){n.lineGroup.css.width=1==n.wrapLines?"100%":"max-content",n.lines.forEach(function(e){e.row&&b(e)}),B(),y()},S=function(){const e=l.newLines;n.props(l.box),n.scrollArea.setFocusRing(l.focus.ringColor),n.lineGroup.padding=[0,l.area.paddingY],n.lblEmpty.props(l.empty),n.btnNewLines.props({height:e.height,fontSize:e.fontSize,color:e.color,textColor:e.textColor,round:e.round,boxShadow:e.shadow}),n.btnNewLines.css.padding="0 "+e.paddingX+"px",n.btnNewLines.css.bottom=e.bottom+"px",n.btnNewLines.setFocusRing(l.focus.ringColor),T(),C()},T=function(){n.scrollBar&&(Object.assign(n.scrollBar,l.scrollBar),n.scrollBar.boxScrollBarTop.color=l.scrollBar.bar_color,n.scrollBar.boxScrollBarLeft.color=l.scrollBar.bar_color)};return n.addLine=function(e,o="info",t=""){v(e,o,t||f()),a||(a=n.after(0,A))},n.info=function(e){n.addLine(e,"info")},n.success=function(e){n.addLine(e,"success")},n.warn=function(e){n.addLine(e,"warn")},n.error=function(e){n.addLine(e,"error")},n.debug=function(e){n.addLine(e,"debug")},n.clearLines=function(){n.lines.forEach(function(e){e.row&&e.row.remove()}),n.lines=[],s=0,i=1,n.scrollArea.elem.scrollTop=0,c=0,B()},n.getText=function(){return n.lines.filter(function(e){return p(e.level)}).map(function(e){return(1==n.showTime?e.time+" ":"")+(1==n.showLevel?w(e)+" ":"")+e.text}).join("\n")},n.scrollToEnd=function(){i=1,s=0,n.scrollArea.elem.scrollTop=n.scrollArea.elem.scrollHeight,B()},n.setAutoScroll=function(e){n.autoScroll=basic.isOn(e)?1:0,1==n.autoScroll&&n.scrollToEnd()},n.setShowTime=function(e){n.showTime=basic.isOn(e)?1:0,C()},n.setShowLevel=function(e){n.showLevel=basic.isOn(e)?1:0,C()},n.setWrapLines=function(e){n.wrapLines=basic.isOn(e)?1:0,n.scrollArea.scrollX=1==n.wrapLines?0:1,C()},n.setMaxLines=function(e){n.maxLines=e,L(),B()},n.setLevels=function(e){r=Array.isArray(e)?e.slice():[],s=0,C()},n.setTheme=function(e){n.styleName=e,l=function(e){const t={styleName:e,style:o};return basic.applyStylePackage(t,LogView.styles,LogViewDefaults),mergeIntoIfMissing(t,LogViewDefaults),t.style}(e),n.style=l,S()},n.scrollArea=startBox(0,0,"100%","100%",{color:"transparent",scrollY:1}),n.scrollArea.scrollX=1==n.wrapLines?0:1,n.scrollArea.css.overflowAnchor="none",n.scrollArea.role="log",n.scrollArea.aria={label:n.ariaLabel},n.scrollArea.tabIndex=0,n.lineGroup=VGroup({width:1==n.wrapLines?"100%":"max-content",height:"auto",align:"left top",gap:0,css:{minWidth:"100%",boxSizing:"border-box",alignItems:"stretch"}}),endGroup(),endBox(),n.emptyGroup=VGroup({left:0,top:0,width:"100%",height:"100%",align:"center center",padding:12}),n.lblEmpty=Label({plainText:n.emptyText,textAlign:"center"}),endGroup(),n.btnNewLines=Button({width:"auto",css:{whiteSpace:"nowrap",left:"50%",top:"auto",transform:"translateX(-50%)"},visible:0}),n.btnNewLines.minimal=1,"undefined"!=typeof ScrollBar&&(n.scrollBar=ScrollBar(Object.assign({scrollableBox:n.scrollArea},l.scrollBar))),n.scrollArea.on("scroll",function(){if(n.scrollArea.elem.scrollTop===c)return;c=n.scrollArea.elem.scrollTop;const e=i;i=function(){const e=n.scrollArea.elem;return e.scrollHeight-e.scrollTop-e.clientHeight<=4}()?1:0,i&&!e&&(s=0,B())}),n.btnNewLines.on("click",n.scrollToEnd),n.btnNewLines.onHoverChange(function(e,o){e.color=o?l.newLines.hoverColor:l.newLines.color}),n.onResize(y),t.forEach(function(e){e&&"object"==typeof e?v(e.text,e.level||"info",e.time||f()):v(e,"info",f())}),S(),A(),endObject(n)};LogView.styles={light:LogViewDefaults.style,dark:{box:{color:"#1C1C1B",borderColor:White(.1)},time:{textColor:White(.48)},levels:{info:{text:White(.86),tag:"#7DBBEB",color:"transparent"},success:{text:"#7FE3B5",tag:"#7FE3B5",color:"transparent"},warn:{text:"#F1C74A",tag:"#F1C74A",color:"rgba(241, 199, 74, 0.1)"},error:{text:"#FF9F93",tag:"#FF9F93",color:"rgba(232, 121, 109, 0.14)"},debug:{text:White(.52),tag:White(.52),color:"transparent"}},empty:{textColor:White(.5)},newLines:{color:"#DDE5E6",hoverColor:"#F2F6F6",textColor:"#1C1C1B",shadow:"0 2px 8px "+Black(.5)},scrollBar:{bar_color:"#8A8A88",bar_mouseOverColor:"#BFBFBD"},focus:{ringColor:"rgba(111, 198, 205, 0.8)"}}};
@@ -0,0 +1,2 @@
1
+ /* Bismillah */
2
+ "use strict";const LoginPageDefaults={panelWidth:420,primaryColor:"#2C5A38",tab_backgroundColorBottom:"#242424",tab_backgroundColorTop:"#242424",tab_borderColor:White(.1),tab_border:1,tab_textColor:White(.75),tab_selectedColor:"#000000",tabWidth:"auto",tabStyle:{},inputStyleName:"",buttonStyleName:"",buttonTone:"",input_backgroundColor:"#141414",input_lineColor:"transparent",input_selectedBackgroundColor:"#202020",input_textColor:White(.85),input_border:1,input_borderColor:White(.1),orTextColor:White(.75),orLineColor:White(.1),panelName:"MY PANEL v25.08.11",allowHtml:0,onLoginClick:function(){},onSignupClick:function(){},showPasswordIconInvert:1,showPasswordIconFile:"",hidePasswordIconFile:"",waitingCoverColor:"rgba(0, 0, 0, 0.6)",waitingClock:"ozden",signupPasswordParams:{minLength:8,minLengthWarningText:"Password must be at least 8 characters",mustUseNumber:1,mustUseLetter:1,mustUseUppercase:0,mustUseLowercase:0,mustUseSpecialChar:0},style:{customLoginButton:{height:50,round:4,color:"#141414",gap:12,border:1,borderColor:White(.1),textColor:White(.75)}}},LoginPageLightStyle={panelName:"MY PANEL v25.08.11",primaryColor:"#65A293",tab_backgroundColorBottom:"#EFEFEF",tab_backgroundColorTop:"#EFEFEF",tab_border:1,tab_borderColor:Black(.2),tab_textColor:"#373836",tab_selectedColor:"white",tabStyle:{pillIndicator:{shadow:"0 1px 2px rgba(0, 0, 0, 0.12)"}},input_backgroundColor:"#F6F6F6",input_lineColor:"transparent",input_selectedBackgroundColor:"#F3F4E0",input_textColor:Black(.85),input_border:1,input_borderColor:Black(.1),orTextColor:Black(.75),orLineColor:Black(.1),showPasswordIconInvert:0,style:{customLoginButton:{height:50,round:4,color:"whitesmoke",gap:12,border:1,borderColor:Black(.2),textColor:Black(.75)}}},LoginPage=function(o={}){mergeIntoIfMissing(o,LoginPageDefaults),o.left=0,o.top=0,o.width="100%",o.height="100%";let t=startObject(o);const e=["login","signup"],n=function(o,e){const n=null==e?"":String(e);1==t.allowHtml?o.text=n:o.plainText=n};t.customButtonCount=0;const r=t.remove;t.superRemove=r,t.remove=function(){t._isRemoved||(clearTimeout(t.alertBox.timer),r.call(t))},t.setActiveTab=function(o){t.tabBar.setValue(e[o],1),0===o?(t.viewGroup.left=0,t.loginBox.opacity=1,t.signupBox.opacity=0):(t.viewGroup.left=-1*t.panelWidth,t.loginBox.opacity=0,t.signupBox.opacity=1),t.loginBox.elem.inert=0!==o,t.signupBox.elem.inert=0===o},t.createButtonWithIcon=function(o,e,r){t.customButtonCount++,t.boxOR.opacity=1,HGroup({width:"100%",position:"relative",...t.style.customLoginButton}),t.loginBox.add(that),that.cursor="pointer",that.on("click",r),UIEffects.press(that),Icon(0,0,24,24),that.load(e),Label({textColor:t.style.customLoginButton.textColor,fontSize:20}),n(that,o),endBox()};const a=function(){const o=Math.max(0,2-basic.num(t.tab_border)),n=JSON.parse(JSON.stringify(t.tabStyle||{}));mergeIntoIfMissing(n,function(o){return{pillBar:{color:t.tab_backgroundColorBottom,padding:[o,o],gap:3,round:8,border:t.tab_border,borderColor:t.tab_borderColor},tab:{fontSize:14,textColor:t.tab_textColor,padding:[12,4],round:6,minHeight:0},tabHover:{color:"transparent",textColor:t.tab_textColor},pillActive:{textColor:t.tab_textColor},pillIndicator:{color:t.tab_selectedColor,round:6,shadow:"none",motion:.2}}}(o)),t.tabBar=Tabs({scale:1,variant:"pill",width:t.tabWidth,fullWidth:"auto"===t.tabWidth?0:1,tabs:[{key:e[0],text:"LOGIN"},{key:e[1],text:"SIGN UP"}],value:e[0],showArrows:0,ariaLabel:"Login or sign up",style:n,onChange:function(o){t.setActiveTab(o.getIndex())}});const r=`linear-gradient(to bottom, ${t.tab_backgroundColorBottom}, ${t.tab_backgroundColorTop})`;t.tabBar.strip.css.background=r},i=function(){const o=LoadingScreen({opened:0,minDuration:0,fadeDuration:.2,style:{box:{color:t.waitingCoverColor},clock:LoadingScreen.clocks[t.waitingClock]||LoadingScreen.clocks.ozden}});t.waiting={screen:o,show:function(){t._isRemoved||o.open()},hide:function(){t._isRemoved||o.close()}}},l=function(o){t.inputStyleName||(o.background.round=4,o.background.border=t.input_border,o.background.borderColor=t.input_borderColor,o.warningBall.borderColor=Black(1),"textarea"!==o.type&&(o.input.textColor=t.input_textColor))},s=function(o,e){if(t.buttonStyleName)return SmartButton({styleName:t.buttonStyleName,tone:t.buttonTone,labelText:o,allowHtml:t.allowHtml,width:"100%",height:50,onClick:e});const r=Button({textColor:White(.75),fontSize:20,width:"100%",height:50,round:4,color:t.primaryColor,minimal:1});return n(r,o),r.clickable=1,r.cursor="pointer",UIEffects.press(r),r.on("click",function(o,t){1==r.clickable&&e(o,t)}),r},c=function(o,e){t.buttonStyleName?o.setEnabled(e?1:0):(o.clickable=e?1:0,o.css.filter=e?"grayscale(0%)":"grayscale(100%)")},d=function(){const o=t.loginEmail.getValue().length>0,e=t.loginPassword.getValue().length>0,n=0===t.loginEmail.status;c(t.loginBtn,o&&e&&n)},u=function(){const o=0===t.signupEmail.status,e=0===t.signupPassword.status,n=0===t.signupPassword2.status;c(t.signupBtn,o&&e&&n)};return function(){t.container=AutoLayout({flow:"vertical",align:"center top",width:"100%",height:"100%",padding:[30,50],gap:40}),t.title=Label({right:30,bottom:30,fontSize:20,textColor:White(.4),position:"absolute"}),n(t.title,t.panelName),a(),t.contentContainer=startBox({width:t.panelWidth,height:"auto",color:"transparent",clipContent:0}),t.viewGroup=HGroup({align:"left top",height:"auto",color:"transparent",width:2*t.panelWidth}),t.viewGroup.setMotion("left 0.2s"),t.loginBox=AutoLayout({flow:"vertical",align:"left top",gap:10,height:"auto",width:t.panelWidth,color:"transparent",opacity:0}),that.setMotion("opacity 0.2s");const o=t.inputStyleName?{width:"100%",leftPadding:16,rightPadding:16,styleName:t.inputStyleName}:{styleName:"modern",width:"100%",leftPadding:16,rightPadding:16,backgroundColor:t.input_backgroundColor,lineColor:t.input_lineColor,focusBackgroundColor:t.input_selectedBackgroundColor,focusLineColor:t.primaryColor};t.loginEmail=EmailField({...o,titleText:"EMAIL",placeholder:"example@site.com",required:0,maxLength:60,value:""}),l(that),that.onChange=function(){d()},t.loginPassword=PasswordField({...o,titleText:"PASSWORD",placeholder:"Enter your password",maxLength:60,showShowPasswordButton:1,required:0,showPasswordIconFile:t.showPasswordIconFile||PasswordFieldDefaults.showPasswordIconFile,hidePasswordIconFile:t.hidePasswordIconFile||PasswordFieldDefaults.hidePasswordIconFile,value:"",minLength:0,mustUseNumber:0,mustUseLetter:0,mustUseUppercase:0,mustUseLowercase:0,mustUseSpecialChar:0,invertIconColor:t.showPasswordIconInvert}),l(that),that.onChange=function(){d()},t.loginBtn=s("LOGIN",function(o,e){t.onLoginClick(o,e)}),t.boxOR=startBox({width:"100%",height:60,color:"transparent"}),that.opacity=0,Box(0,0,"100%",1,{color:t.orLineColor}),that.center("top"),that.top+=2,Label({text:"or",textColor:t.orTextColor,color:t.parentBox.color,padding:[12,6]}),that.center(),endBox(),endAutoLayout(),t.signupBox=AutoLayout({flow:"vertical",align:"left top",gap:10,height:"auto",width:t.panelWidth,color:"transparent"}),that.opacity=0,that.setMotion("opacity 0.2s"),t.signupEmail=EmailField({...o,titleText:"EMAIL",placeholder:"example@site.com",required:1,maxLength:60}),l(that),that.onChange=function(){u()},t.signupPassword=PasswordField({...o,titleText:"PASSWORD",placeholder:"Create a password",maxLength:60,showPasswordIconFile:t.showPasswordIconFile||PasswordFieldDefaults.showPasswordIconFile,hidePasswordIconFile:t.hidePasswordIconFile||PasswordFieldDefaults.hidePasswordIconFile,showShowPasswordButton:1,...t.signupPasswordParams,invertIconColor:t.showPasswordIconInvert}),l(that),that.onChange=function(){u()},t.signupPassword2=PasswordField({...o,titleText:"CONFIRM PASSWORD",placeholder:"Re-enter password",maxLength:60,showPasswordIconFile:t.showPasswordIconFile||PasswordFieldDefaults.showPasswordIconFile,hidePasswordIconFile:t.hidePasswordIconFile||PasswordFieldDefaults.hidePasswordIconFile,showShowPasswordButton:1,...t.signupPasswordParams,invertIconColor:t.showPasswordIconInvert}),l(that),that.onChange=function(){u()},t.signupBtn=s("SIGN UP",function(o,e){t.onSignupClick(o,e)}),endAutoLayout(),endGroup(),endBox(),endAutoLayout(),t.alertBox=startBox(0,0,"100%","100%",{color:Black(.8),opacity:0,clickable:0}),t.alertBox.setMotion("opacity 0.2s"),t.lblAlert=Label({left:40,top:40,text:"",textColor:"indianred",padding:[12,4],round:4,border:1,borderColor:White(.2)}),endBox(),t.showAlert=function(o="Error",e="indianred"){n(t.lblAlert,o),t.lblAlert.textColor=e,t.alertBox.opacity=1,t.alertBox.clickable=1,t.alertBox.timer&&clearTimeout(t.alertBox.timer),t.alertBox.timer=setTimeout(function(){t.alertBox.opacity=0,t.alertBox.clickable=0},1e3)},i(),d(),u(),t.setActiveTab(0)}(),endObject(t)};LoginPage.toSvgFile=function(o){return"data:image/svg+xml;utf8,"+encodeURIComponent(o)},LoginPage.GOOGLE_LOGO_SHAPES=[{color:"#4285F4",path:"M117.6,61.3636364 C117.6,57.1090909 117.218182,53.0181818 116.509091,49.0909091 L60,49.0909091 L60,72.3 L92.2909091,72.3 C90.9,79.8 86.6727273,86.1545455 80.3181818,90.4090909 L80.3181818,105.463636 L99.7090909,105.463636 C111.054545,95.0181818 117.6,79.6363636 117.6,61.3636364 L117.6,61.3636364 Z"},{color:"#34A853",path:"M60,120 C76.2,120 89.7818182,114.627273 99.7090909,105.463636 L80.3181818,90.4090909 C74.9454545,94.0090909 68.0727273,96.1363636 60,96.1363636 C44.3727273,96.1363636 31.1454545,85.5818182 26.4272727,71.4 L6.38181818,71.4 L6.38181818,86.9454545 C16.2545455,106.554545 36.5454545,120 60,120 L60,120 Z"},{color:"#FBBC05",path:"M26.4272727,71.4 C25.2272727,67.8 24.5454545,63.9545455 24.5454545,60 C24.5454545,56.0454545 25.2272727,52.2 26.4272727,48.6 L26.4272727,33.0545455 L6.38181818,33.0545455 C2.31818182,41.1545455 0,50.3181818 0,60 C0,69.6818182 2.31818182,78.8454545 6.38181818,86.9454545 L26.4272727,71.4 L26.4272727,71.4 Z"},{color:"#EA4335",path:"M60,23.8636364 C68.8090909,23.8636364 76.7181818,26.8909091 82.9363636,32.8363636 L100.145455,15.6272727 C89.7545455,5.94545455 76.1727273,0 60,0 C36.5454545,0 16.2545455,13.4454545 6.38181818,33.0545455 L26.4272727,48.6 C31.1454545,34.4181818 44.3727273,23.8636364 60,23.8636364 L60,23.8636364 Z"}],LoginPage.GOOGLE_LOGO=function(){const o=LoginPage.GOOGLE_LOGO_SHAPES.map(function(o){return'<path fill="'+o.color+'" d="'+o.path+'"/>'});return LoginPage.toSvgFile('<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 118 120">'+o.join("")+"</svg>")}(),LoginPage.APPLE_LOGO_PATH="M12.152 6.896c-.948 0-2.415-1.078-3.96-1.04-2.04.027-3.91 1.183-4.961 3.014-2.117 3.675-.546 9.103 1.519 12.09 1.013 1.454 2.208 3.09 3.792 3.039 1.52-.065 2.09-.987 3.935-.987 1.831 0 2.35.987 3.96.948 1.637-.026 2.676-1.48 3.676-2.948 1.156-1.688 1.636-3.325 1.662-3.415-.039-.013-3.182-1.221-3.22-4.857-.026-3.04 2.48-4.494 2.597-4.559-1.429-2.09-3.623-2.324-4.39-2.376-2-.156-3.675 1.09-4.61 1.09zM15.53 3.83c.843-1.012 1.4-2.427 1.245-3.83-1.207.052-2.662.805-3.532 1.818-.78.896-1.454 2.338-1.273 3.714 1.338.104 2.715-.688 3.559-1.701",LoginPage.getAppleLogo=function(o){return LoginPage.toSvgFile('<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">'+('<path fill="'+o+'" d="'+LoginPage.APPLE_LOGO_PATH+'"/>')+"</svg>")};
@@ -0,0 +1,2 @@
1
+ /* Bismillah */
2
+ "use strict";const MarkdownViewDefaults={key:"0",left:0,top:0,width:"100%",height:"100%",markdownText:"",emptyText:"",autoScroll:1,remotePictures:0,useScrollBar:1,ariaLabel:"Document",copyText:"Copy",copiedText:"Copied",onLinkClick:null,styleName:"light",style:{box:{color:"white"},page:{padding:[22,18],gap:12,maxWidth:820},text:{fontSize:15,lineRatio:1.6,textColor:Black(.8),softColor:Black(.5),strongColor:Black(.92)},heading:{fontSizes:[27,22,18,16,15,14],spaces:[16,14,10,8,6,6],lineRatio:1.3,textColor:Black(.92),lineColor:Black(.1),linePadding:6},link:{color:"#1F7A83",lineColor:"rgba(31, 122, 131, 0.35)"},inlineCode:{color:Black(.06)},quote:{textColor:Black(.62),lineColor:Black(.16),lineSize:3,padding:14},table:{lineColor:Black(.14),headColor:Black(.04)},line:{color:Black(.12),space:6},check:{color:Black(.3),onColor:"#1F7A83",markColor:"white"},code:{color:"#F6F6F4",border:1,borderColor:Black(.08),round:8,fontSize:13,lineHeight:20,fontFamily:'ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace',textColor:"#2B2B2A",padding:[14,2],bottomPadding:12,bar:{height:34,paddingRight:6,fontSize:12,textColor:Black(.5)},button:{height:26,padding:8,gap:5,round:6,fontSize:12,iconSize:14,textColor:Black(.6),hoverColor:Black(.07)}},codeStyleName:"light",empty:{fontSize:14,textColor:Black(.45)},focus:{ringColor:"rgba(63, 141, 148, 0.8)"},scrollBar:{bar_color:"#9A9A98",bar_mouseOverColor:"#6A6A68",bar_width:4,bar_round:3}}},MarkdownView=function(e={}){const o=e.style;basic.applyStylePackage(e,MarkdownView.styles,MarkdownViewDefaults),mergeIntoIfMissing(e,MarkdownViewDefaults);const t="auto"===String(e.height),n=startObject(e);let r=n.style,i=[];const a=new Map;let l=null,s=1,c=0;const d=function(){return MarkdownView.parse(n.markdownText,{remotePictures:n.remotePictures})},w=function(e,o){const t=Label(Object.assign({width:"100%",text:e,selectable:1},o));return t.elem.classList.add("markdown-view-text"),t},k=function(e,o){const t=o?n.copiedText:n.copyText;e.text=MarkdownView.copyButtonHtml(t,o),e.aria={label:t}},u=function(e){const o=r.code.button,t=Button({width:"auto",height:o.height,color:"transparent",round:o.round,fontSize:o.fontSize,textColor:o.textColor,shrink:0,css:{display:"flex",alignItems:"center",gap:o.gap+"px",padding:"0 "+o.padding+"px",whiteSpace:"nowrap"}});return t.minimal=1,t.elem.style.setProperty("--markdown-view-copy-icon",o.iconSize+"px"),t.setFocusRing(r.focus.ringColor),k(t,0),t.onHoverChange(function(e,t){e.color=t?o.hoverColor:"transparent"}),t.on("click",function(){!function(e,o){MarkdownView.copyToClipboard(o).then(function(){e.isRemoved||(k(e,1),n.after(1500,function(){e.isRemoved||k(e,0)}))}).catch(function(e){console.warn("MarkdownView: The code could not be copied. "+e)})}(t,e)}),t},p=function(e,o,t){return"heading"===e.type?function(e,o){const t=r.heading,n=t.fontSizes[e.level-1],i=w(e.html,{fontSize:n,lineHeight:Math.round(n*t.lineRatio),bold:1,textColor:t.textColor,role:"heading",aria:{level:e.level}});return o>0&&(i.css.marginTop=t.spaces[e.level-1]+"px"),e.level<=2&&(i.css.borderBottom="1px solid "+t.lineColor,i.css.paddingBottom=t.linePadding+"px"),a.set(e.id,i),i}(e,o):"quote"===e.type?function(e){const o=r.quote,t=VGroup({width:"100%",height:"auto",align:"left top",gap:r.page.gap,clipContent:0});return t.css.borderLeft=o.lineSize+"px solid "+o.lineColor,t.css.paddingLeft=o.padding+"px",t.css.boxSizing="border-box",e.blocks.forEach(function(e,t){p(e,t,o.textColor)}),endGroup(),t}(e):"code"===e.type?function(e){const o=r.code,t=VGroup({width:"100%",height:"auto",align:"left top",color:o.color,border:o.border,borderColor:o.borderColor,round:o.round}),n=HGroup({width:"100%",height:o.bar.height,align:"left center",shrink:0});n.css.padding="0 "+o.bar.paddingRight+"px 0 "+o.padding[0]+"px",n.css.boxSizing="border-box",Label({plainText:e.language,fontSize:o.bar.fontSize,textColor:o.bar.textColor,grow:1,ellipsis:1}),u(e.code),endGroup();const i=VGroup({width:"100%",height:"auto",align:"left top",padding:o.padding,clipContent:0});return i.scrollX=1,i.css.paddingBottom=o.bottomPadding+"px",Label({text:MarkdownView.codeHtml(e.code,e.language),fontSize:o.fontSize,lineHeight:o.lineHeight,textColor:o.textColor,selectable:1,css:{fontFamily:o.fontFamily,whiteSpace:"pre",width:"max-content",minWidth:"100%",overflow:"visible"}}).elem.classList.add("markdown-view-code"),endGroup(),endGroup(),t}(e):"line"===e.type?function(){const e=Box({width:"100%",height:1,color:r.line.color});return e.css.margin=r.line.space+"px 0",e}():function(e,o,t){return w(e.html,{fontSize:r.text.fontSize,lineHeight:Math.round(r.text.fontSize*r.text.lineRatio),textColor:t})}(e,0,t)},m=function(){l=null;const e=d().blocks,o=e.map(function(e){return JSON.stringify(e)});let t=0;for(;t<i.length&&i[t].key===o[t];)t++;i.splice(t).forEach(function(e){e.object.remove()}),createIn(n.blockGroup,function(){for(let n=t;n<e.length;n++)i.push({key:o[n],object:p(e[n],n,r.text.textColor)})}),g()},g=function(){const e=0===i.length&&""!==n.emptyText;n.lblEmpty.plainText=n.emptyText,n.lblEmpty.visible=e?1:0},h=function(){if(!n.scrollArea)return!0;const e=n.scrollArea.elem;return e.scrollHeight-e.scrollTop-e.clientHeight<=30},f=function(){const e=n.scrollArea.elem;e.scrollTop=e.scrollHeight,c=e.scrollTop},b=function(){n.scrollArea&&1==n.autoScroll&&s&&!function(){const e=window.getSelection();return!(!e||e.isCollapsed||!n.elem.contains(e.anchorNode))}()&&f()},x=function(){m(),b()},M=function(){const e=n.scrollArea.elem.scrollTop;e!==c&&(c=e,s=h()?1:0)},V=function(){n.scrollBar&&n.scrollBar.refreshScroll&&n.scrollBar.refreshScroll()},v=function(){n.props(r.box),n.blockGroup.gap=r.page.gap,n.blockGroup.padding=r.page.padding,n.blockGroup.css.maxWidth=r.page.maxWidth+"px",n.lblEmpty.props({fontSize:r.empty.fontSize,textColor:r.empty.textColor}),n.scrollArea&&n.scrollArea.setFocusRing(r.focus.ringColor),function(){const e={"--markdown-view-soft":r.text.softColor,"--markdown-view-strong":r.text.strongColor,"--markdown-view-link":r.link.color,"--markdown-view-link-line":r.link.lineColor,"--markdown-view-inline-code":r.inlineCode.color,"--markdown-view-table-line":r.table.lineColor,"--markdown-view-table-head":r.table.headColor,"--markdown-view-check":r.check.color,"--markdown-view-check-on":r.check.onColor,"--markdown-view-check-mark":r.check.markColor,"--markdown-view-ring":r.focus.ringColor,"--markdown-view-mono":r.code.fontFamily};Object.assign(e,MarkdownView.codeColors(r.codeStyleName)),Object.keys(e).forEach(function(o){n.elem.style.setProperty(o,e[o])})}(),n.scrollBar&&(Object.assign(n.scrollBar,r.scrollBar),n.scrollBar.boxScrollBarTop.color=r.scrollBar.bar_color,n.scrollBar.boxScrollBarLeft.color=r.scrollBar.bar_color)};n.setMarkdownText=function(e){n.markdownText=null==e?"":String(e),m(),s=h()?1:0},n.appendText=function(e){null!=e&&(n.markdownText+=String(e),l||(l=n.after(33,x)))},n.getMarkdownText=function(){return n.markdownText},n.clear=function(){n.setMarkdownText("")},n.setEmptyText=function(e){n.emptyText=null==e?"":String(e),g()},n.setAutoScroll=function(e){n.autoScroll=basic.isOn(e)?1:0,1==n.autoScroll&&n.scrollToEnd()},n.getHeadings=function(){return MarkdownView.headingsOf(d().blocks)},n.scrollToHeading=function(e){const o=a.get(MarkdownView.slug(e));if(!o||o.isRemoved)return;if(!n.scrollArea)return void o.elem.scrollIntoView({block:"start"});const t=n.scrollArea.elem,r=o.elem.getBoundingClientRect().top-t.getBoundingClientRect().top;t.scrollTop=Math.max(0,t.scrollTop+r-12)},n.scrollToTop=function(){n.scrollArea&&(n.scrollArea.elem.scrollTop=0)},n.scrollToEnd=function(){n.scrollArea&&(s=1,f())},n.setTheme=function(e){n.styleName=e,r=function(e){const t={styleName:e,style:o};return basic.applyStylePackage(t,MarkdownView.styles,MarkdownViewDefaults),mergeIntoIfMissing(t,MarkdownViewDefaults),t.style}(e),n.style=r,v(),function(){const e=n.scrollArea?n.scrollArea.elem.scrollTop:0;i.forEach(function(e){e.object.remove()}),i=[],m(),n.scrollArea&&(n.scrollArea.elem.scrollTop=e)}()};const C=function(){n.blockGroup=VGroup({width:"100%",height:"auto",align:"left top",position:"relative",clipContent:0}),n.blockGroup.css.margin="0 auto",n.blockGroup.css.boxSizing="border-box",n.lblEmpty=Label({width:"100%",textAlign:"center",visible:0}),endGroup()};return t?C():(n.scrollArea=startBox({left:0,top:0,width:"100%",height:"100%",color:"transparent"}),n.scrollArea.scrollY=1,n.scrollArea.role="document",n.scrollArea.aria={label:n.ariaLabel},n.scrollArea.tabIndex=0,C(),endBox(),1==n.useScrollBar&&"undefined"!=typeof ScrollBar&&(n.scrollBar=ScrollBar(Object.assign({scrollableBox:n.scrollArea,neverHide:0,showDots:0},r.scrollBar)))),MarkdownView.addCss(),v(),n.listenTo(n.blockGroup.elem,"click",function(e,o){const t=o.target.closest("a");if(!t)return;const r=t.getAttribute("href");if("#"===r.charAt(0))return o.preventDefault(),void n.scrollToHeading(r.slice(1));"function"==typeof n.onLinkClick&&(o.preventDefault(),n.onLinkClick(n,r))}),n.scrollArea&&(n.scrollArea.on("scroll",M),n.blockGroup.onResize(V)),n.setMarkdownText(n.markdownText),endObject(n)};MarkdownView.addCss=function(){basic.addCss("markdown-view",".markdown-view-text { overflow-wrap: break-word; }.markdown-view-text strong { font-family: opensans-bold; font-weight: normal; color: var(--markdown-view-strong); }.markdown-view-text[role=\"heading\"] strong { color: inherit; }.markdown-view-text em { font-style: italic; }.markdown-view-text del { opacity: 0.7; }.markdown-view-text code { font-family: var(--markdown-view-mono); font-size: 0.87em; padding: 0.12em 0.36em; border-radius: 4px; background: var(--markdown-view-inline-code); }.markdown-view-text a { color: var(--markdown-view-link); text-decoration: none; border-bottom: 1px solid var(--markdown-view-link-line); }.markdown-view-text a:hover { border-bottom-color: var(--markdown-view-link); }.markdown-view-text a:focus-visible { outline: 2px solid var(--markdown-view-ring); outline-offset: 2px; border-radius: 2px; }.markdown-view-text img { max-width: 100%; height: auto; border-radius: 6px; vertical-align: top; }.markdown-view-text ul, .markdown-view-text ol { margin: 0; padding-left: 24px; }.markdown-view-text li { margin: 4px 0; padding-left: 2px; }.markdown-view-text li::marker { color: var(--markdown-view-soft); }.markdown-view-text li.markdown-view-task { list-style: none; margin-left: -20px; }.markdown-view-check { display: inline-block; box-sizing: border-box; width: 15px; height: 15px; margin-right: 8px; vertical-align: -2px; border: 1.5px solid var(--markdown-view-check); border-radius: 4px; }.markdown-view-check-on { background: var(--markdown-view-check-on); border-color: var(--markdown-view-check-on); position: relative; }.markdown-view-check-on::after { content: ''; position: absolute; left: 3.5px; top: 0.5px; width: 3px; height: 7px; border: solid var(--markdown-view-check-mark); border-width: 0 1.5px 1.5px 0; transform: rotate(45deg); }.markdown-view-table { overflow-x: auto; }.markdown-view-table table { border-collapse: collapse; font-size: 0.93em; }.markdown-view-table th, .markdown-view-table td { border: 1px solid var(--markdown-view-table-line); padding: 7px 10px; text-align: left; vertical-align: top; }.markdown-view-table th { font-family: opensans-bold; font-weight: normal; background: var(--markdown-view-table-head); }.markdown-view-copy-icon { display: block; flex-shrink: 0; width: var(--markdown-view-copy-icon); height: var(--markdown-view-copy-icon); pointer-events: none; }.markdown-view-copy-icon svg { display: block; width: 100%; height: 100%; }"+MarkdownView.CODE_KINDS.map(function(e){return".markdown-view-code .code-editor-"+e+" { color: var(--markdown-view-kind-"+e+"); }"}).join(""))},MarkdownView.CODE_KINDS=["keyword","string","number","comment","builtin","function","property","tag","attribute","variable"],MarkdownView.codeColors=function(e){const o={};if("undefined"==typeof CodeEditor)return o;const t=Object.assign({},CodeEditor.styles.light.kinds,(CodeEditor.styles[e]||{}).kinds);return MarkdownView.CODE_KINDS.forEach(function(e){o["--markdown-view-kind-"+e]=t[e]}),o},MarkdownView.ICONS={copy:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="9" y="9" width="12" height="12" rx="2"/><path d="M5 15h-.5A1.5 1.5 0 0 1 3 13.5v-9A1.5 1.5 0 0 1 4.5 3h9A1.5 1.5 0 0 1 15 4.5V5"/></svg>',check:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.4" stroke-linecap="round" stroke-linejoin="round"><path d="M5 13l4.5 4.5L19 7"/></svg>'},MarkdownView.copyButtonHtml=function(e,o){return'<span class="markdown-view-copy-icon">'+(o?MarkdownView.ICONS.check:MarkdownView.ICONS.copy)+"</span><span>"+basic.escapeHtml(e)+"</span>"},MarkdownView.copyToClipboard=function(e){if(navigator.clipboard&&window.isSecureContext)return navigator.clipboard.writeText(e);const o=document.createElement("textarea");o.value=e,o.style.cssText="position: fixed; left: -9999px; top: 0;",document.body.appendChild(o),o.select();const t=document.execCommand("copy");return o.remove(),t?Promise.resolve():Promise.reject(new Error("The browser refused it."))},MarkdownView.LANGUAGE_NAMES={py:"python",python3:"python",js:"javascript",jsx:"javascript",ts:"javascript",tsx:"javascript",typescript:"javascript",node:"javascript",sh:"bash",shell:"bash",zsh:"bash",console:"bash",htm:"html",xml:"html",svg:"html"},MarkdownView.MAX_COLORED_LETTERS=2e5,MarkdownView.codeHtml=function(e,o){const t=MarkdownView.LANGUAGE_NAMES[o]||o,n="undefined"!=typeof CodeEditor?CodeEditor.languages[t]:null;if(!n||e.length>MarkdownView.MAX_COLORED_LETTERS)return basic.escapeHtml(e);let r=null;return e.split("\n").map(function(e){const o=CodeEditor.tokenizeLine(e,r,n);return r=o.state,o.parts.map(CodeEditor.partHtml).join("")}).join("\n")},MarkdownView.parse=function(e,o={}){const t={usedIds:Object.create(null),remotePictures:basic.isOn(o.remotePictures)},n=String(null==e?"":e).replace(/\r\n?/g,"\n").split("\n"),r=MarkdownView.parseBlocks(n,t),i=MarkdownView.headingsOf(r).find(function(e){return 1===e.level});return{blocks:r,title:i?i.text:""}},MarkdownView.headingsOf=function(e){const o=[];return e.forEach(function(e){"heading"===e.type&&o.push({id:e.id,level:e.level,text:e.text}),"quote"===e.type&&o.push.apply(o,MarkdownView.headingsOf(e.blocks))}),o},MarkdownView.RE={fence:/^(\s*)(`{3,}|~{3,})\s*([^\s`]*)[^`]*$/,heading:/^\s{0,3}(#{1,6})\s+(.*?)\s*#*\s*$/,underline:/^\s{0,3}(=+|-{2,})\s*$/,line:/^\s{0,3}(?:(?:\*\s*){3,}|(?:-\s*){3,}|(?:_\s*){3,})$/,quote:/^\s*>/,listItem:/^(\s*)([-*+]|\d+[.)])\s+(.*)$/,listNextLine:/^\s{2,}\S/,task:/^\[( |x|X)\]\s+(.*)$/,tableDivider:/^\s*\|?\s*:?-+:?\s*(\|\s*:?-+:?\s*)*\|?\s*$/,hardBreak:/ {2,}$|\\$/},MarkdownView.parseBlocks=function(e,o){const t={lines:e,at:0,blocks:[],context:o};for(;t.at<e.length;)e[t.at].trim()?MarkdownView.BLOCK_READERS.find(function(e){return e(t)}):t.at++;return t.blocks},MarkdownView.isTableStart=function(e,o){return!(-1===e[o].indexOf("|")||o+1>=e.length)&&(!!MarkdownView.RE.tableDivider.test(e[o+1])&&MarkdownView.tableCells(e[o]).length===MarkdownView.tableCells(e[o+1]).length)},MarkdownView.isBlockStart=function(e,o){const t=MarkdownView.RE,n=e[o];return t.fence.test(n)||t.heading.test(n)||t.line.test(n)||t.quote.test(n)||t.listItem.test(n)||MarkdownView.isTableStart(e,o)},MarkdownView.uniqueId=function(e,o){const t=MarkdownView.slug(e)||"section";return o[t]=(o[t]||0)+1,o[t]>1?t+"-"+o[t]:t},MarkdownView.headingBlock=function(e,o,t){const n=MarkdownView.plainText(o);return{type:"heading",level:e,html:MarkdownView.inlineHtml(o,t),text:n,id:MarkdownView.uniqueId(n,t.usedIds)}},MarkdownView.readCode=function(e){const o=MarkdownView.RE.fence.exec(e.lines[e.at]);if(!o)return!1;const t=new RegExp("^ {0,"+o[1].length+"}"),n=new RegExp("^\\s*"+o[2].charAt(0)+"{"+o[2].length+",}\\s*$"),r=[];for(e.at++;e.at<e.lines.length&&!n.test(e.lines[e.at]);)r.push(e.lines[e.at].replace(t,"")),e.at++;return e.at++,e.blocks.push({type:"code",language:o[3].toLowerCase(),code:r.join("\n")}),!0},MarkdownView.readHeading=function(e){const o=MarkdownView.RE.heading.exec(e.lines[e.at]);return!!o&&(e.blocks.push(MarkdownView.headingBlock(o[1].length,o[2],e.context)),e.at++,!0)},MarkdownView.readUnderlinedHeading=function(e){const o=e.lines[e.at+1],t=void 0===o?null:MarkdownView.RE.underline.exec(o);if(!t||MarkdownView.isBlockStart(e.lines,e.at))return!1;const n="="===t[1].charAt(0)?1:2;return e.blocks.push(MarkdownView.headingBlock(n,e.lines[e.at].trim(),e.context)),e.at+=2,!0},MarkdownView.readLine=function(e){return!!MarkdownView.RE.line.test(e.lines[e.at])&&(e.blocks.push({type:"line"}),e.at++,!0)},MarkdownView.readQuote=function(e){const o=MarkdownView.RE;if(!o.quote.test(e.lines[e.at]))return!1;const t=[];for(;e.at<e.lines.length&&o.quote.test(e.lines[e.at]);)t.push(e.lines[e.at].replace(/^\s*>\s?/,"")),e.at++;return e.blocks.push({type:"quote",blocks:MarkdownView.parseBlocks(t,e.context)}),!0},MarkdownView.isLineOfList=function(e){const o=MarkdownView.RE;return!(!e.trim()||o.fence.test(e)||o.line.test(e))&&(o.listItem.test(e)||o.listNextLine.test(e))},MarkdownView.readList=function(e){if(!MarkdownView.RE.listItem.test(e.lines[e.at]))return!1;const o=[];for(;e.at<e.lines.length&&MarkdownView.isLineOfList(e.lines[e.at]);)o.push(e.lines[e.at]),e.at++;return e.blocks.push({type:"list",html:MarkdownView.listHtml(o,e.context)}),!0},MarkdownView.readTable=function(e){if(!MarkdownView.isTableStart(e.lines,e.at))return!1;const o=e.lines[e.at],t=e.lines[e.at+1],n=[];for(e.at+=2;e.at<e.lines.length&&e.lines[e.at].indexOf("|")>-1&&e.lines[e.at].trim();)n.push(e.lines[e.at]),e.at++;return e.blocks.push({type:"table",html:MarkdownView.tableHtml(o,t,n,e.context)}),!0},MarkdownView.readParagraph=function(e){const o=[];for(;e.at<e.lines.length&&e.lines[e.at].trim()&&(!o.length||!MarkdownView.isBlockStart(e.lines,e.at));)o.push(e.lines[e.at]),e.at++;const t=o.map(function(t,n){const r=MarkdownView.RE.hardBreak.test(t)&&n<o.length-1,i=t.trim().replace(/\\$/,"");return MarkdownView.inlineHtml(i,e.context)+(r?"<br>":" ")}).join("");return e.blocks.push({type:"p",html:t.trim()}),!0},MarkdownView.BLOCK_READERS=[MarkdownView.readCode,MarkdownView.readHeading,MarkdownView.readUnderlinedHeading,MarkdownView.readLine,MarkdownView.readQuote,MarkdownView.readList,MarkdownView.readTable,MarkdownView.readParagraph],MarkdownView.readListItems=function(e){const o=[];return e.forEach(function(e){const t=MarkdownView.RE.listItem.exec(e);if(t){const e=/\d/.test(t[2]);o.push({indent:t[1].replace(/\t/g," ").length,isOrdered:e,start:parseInt(t[2],10),text:t[3]})}else o.length&&(o[o.length-1].text+=" "+e.trim())}),o},MarkdownView.listItemHtml=function(e,o){const t=MarkdownView.RE.task.exec(e.text);if(!t)return"<li>"+MarkdownView.inlineHtml(e.text,o);return'<li class="markdown-view-task"><span class="'+(" "===t[1]?"markdown-view-check":"markdown-view-check markdown-view-check-on")+'"></span>'+MarkdownView.inlineHtml(t[2],o)},MarkdownView.listStartHtml=function(e){return e.isOrdered?1===e.start?"<ol>":'<ol start="'+e.start+'">':"<ul>"},MarkdownView.listHtml=function(e,o){const t=MarkdownView.readListItems(e);let n=0;const r=function(e){const i=t[n];let a=MarkdownView.listStartHtml(i);for(;n<t.length&&t[n].indent===e;)a+=MarkdownView.listItemHtml(t[n],o),n++,n<t.length&&t[n].indent>e&&(a+=r(t[n].indent)),a+="</li>";return a+(i.isOrdered?"</ol>":"</ul>")};let i="";for(;n<t.length;)i+=r(t[n].indent);return i},MarkdownView.tableCells=function(e){return e.trim().replace(/\\\|/g,"").replace(/^\|/,"").replace(/\|$/,"").split("|").map(function(e){return e.split("").join("|").trim()})},MarkdownView.tableAlign=function(e){const o=e.startsWith(":"),t=e.endsWith(":");return o&&t?"center":t?"right":""},MarkdownView.tableRowHtml=function(e,o,t,n){let r="<tr>";return t.forEach(function(t,i){const a=t?' style="text-align: '+t+'"':"",l=i<e.length?e[i]:"";r+="<"+o+a+">"+MarkdownView.inlineHtml(l,n)+"</"+o+">"}),r+"</tr>"},MarkdownView.tableHtml=function(e,o,t,n){const r=MarkdownView.tableCells(o).map(MarkdownView.tableAlign),i=t.map(function(e){return MarkdownView.tableRowHtml(MarkdownView.tableCells(e),"td",r,n)}).join("");return'<div class="markdown-view-table"><table><thead>'+MarkdownView.tableRowHtml(MarkdownView.tableCells(e),"th",r,n)+"</thead><tbody>"+i+"</tbody></table></div>"},MarkdownView.KEEP_MARK="\0",MarkdownView.INLINE_RE={code:/(`+)\s?([^`]|[^`].*?[^`])\s?\1(?!`)/g,letter:/\\([!-/:-@[-`{-~])/g,picture:/!\[((?:\\.|[^\]\\])*)\]\(\s*<?((?:[^()\s<>]|\([^()\s]*\))+)>?(?:\s+"[^"]*")?\s*\)/g,link:/\[((?:\\.|[^[\]\\]|\[[^\]]*\])*)\]\(\s*<?((?:[^()\s<>]|\([^()\s]*\))+)>?(?:\s+"[^"]*")?\s*\)/g,bareAddress:/(^|[\s(*_~])(https?:\/\/[^\s<>]+[^\s<>.,;:)!?'"*_~])/g,lineBreak:/&lt;br\s*\/?&gt;/gi,strong:/\*\*([^\s*](?:.*?[^\s*])?)\*\*/g,strongLine:/(^|[^\w])__([^\s_](?:.*?[^\s_])?)__(?!\w)/g,emphasis:/(^|[^*\w])\*([^\s*](?:.*?[^\s*])?)\*(?!\*)/g,emphasisLine:/(^|[^\w])_([^\s_](?:.*?[^\s_])?)_(?!\w)/g,deleted:/~~([^\s~](?:.*?[^\s~])?)~~/g},MarkdownView.inlineHtml=function(e,o){const t=[],n=MarkdownView.formatLine(String(e).split(MarkdownView.KEEP_MARK).join(""),function(e){return t.push(e),MarkdownView.KEEP_MARK+(t.length-1)+MarkdownView.KEEP_MARK},o);return MarkdownView.putKeptParts(n,t)},MarkdownView.putKeptParts=function(e,o){const t=new RegExp(MarkdownView.KEEP_MARK+"(\\d+)"+MarkdownView.KEEP_MARK,"g");let n=e;for(;n.indexOf(MarkdownView.KEEP_MARK)>-1;)n=n.replace(t,function(e,t){return o[Number(t)]});return n},MarkdownView.formatLine=function(e,o,t){const n=MarkdownView.INLINE_RE;let r=e.replace(n.code,function(e,t,n){return o("<code>"+basic.escapeHtml(n)+"</code>")});return r=r.replace(n.picture,function(e,n,r){return o(MarkdownView.pictureHtml(MarkdownView.removeEscapes(r),MarkdownView.removeEscapes(n),t))}),r=r.replace(n.link,function(e,n,r){return o(MarkdownView.linkHtml(MarkdownView.removeEscapes(r),MarkdownView.formatLine(n,o,t)))}),r=r.replace(n.letter,function(e,t){return o(basic.escapeHtml(t))}),r=r.replace(n.bareAddress,function(e,t,n){return t+o(MarkdownView.linkHtml(n,basic.escapeHtml(n)))}),MarkdownView.formatWords(basic.escapeHtml(r))},MarkdownView.removeEscapes=function(e){return e.replace(MarkdownView.INLINE_RE.letter,"$1")},MarkdownView.formatWords=function(e){const o=MarkdownView.INLINE_RE;return e.replace(o.lineBreak,"<br>").replace(o.strong,"<strong>$1</strong>").replace(o.strongLine,"$1<strong>$2</strong>").replace(o.emphasis,"$1<em>$2</em>").replace(o.emphasisLine,"$1<em>$2</em>").replace(o.deleted,"<del>$1</del>")},MarkdownView.LINK_SCHEMES=/^(https?|mailto|tel):/i,MarkdownView.PICTURE_SCHEMES=/^(https?:|data:image\/)/i,MarkdownView.REMOTE_ADDRESS=/^(https?:)?\/\//i,MarkdownView.ANY_SCHEME=/^[a-z][a-z0-9+.-]*:/i,MarkdownView.isSafeAddress=function(e,o){if(e.indexOf(MarkdownView.KEEP_MARK)>-1)return!1;const t=e.replace(/[\p{C}\p{Z}]/gu,"");return!MarkdownView.ANY_SCHEME.test(t)||o.test(t)},MarkdownView.linkHtml=function(e,o){if(!MarkdownView.isSafeAddress(e,MarkdownView.LINK_SCHEMES))return o;const t="#"===e.charAt(0)?"":' target="_blank" rel="noopener noreferrer"';return'<a href="'+basic.escapeHtml(e)+'"'+t+">"+o+"</a>"},MarkdownView.pictureHtml=function(e,o,t){const n=basic.escapeHtml(o);return MarkdownView.isSafeAddress(e,MarkdownView.PICTURE_SCHEMES)?!t.remotePictures&&MarkdownView.REMOTE_ADDRESS.test(e)?MarkdownView.linkHtml(e,n||basic.escapeHtml(e)):'<img src="'+basic.escapeHtml(e)+'" alt="'+n+'">':n},MarkdownView.plainText=function(e){return String(e).replace(/!?\[([^\]]*)\]\([^)]*\)/g,"$1").replace(/[`*~]/g,"").replace(/(^|\s)_+|_+(\s|$)/g,"$1$2").replace(/\s+/g," ").trim()},MarkdownView.slug=function(e){return String(e).replace(/[ıİ]/g,"i").normalize("NFD").replace(/\p{M}/gu,"").toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"").slice(0,60)},MarkdownView.styles={light:MarkdownViewDefaults.style,dark:{box:{color:"#1C1C1B"},text:{textColor:White(.8),softColor:White(.5),strongColor:White(.94)},heading:{textColor:White(.94),lineColor:White(.12)},link:{color:"#6FC6CD",lineColor:"rgba(111, 198, 205, 0.35)"},inlineCode:{color:White(.1)},quote:{textColor:White(.62),lineColor:White(.2)},table:{lineColor:White(.16),headColor:White(.06)},line:{color:White(.14)},check:{color:White(.35),onColor:"#6FC6CD",markColor:"#1C1C1B"},code:{color:"#232322",borderColor:White(.08),textColor:"#E6E6E3",bar:{textColor:White(.5)},button:{textColor:White(.65),hoverColor:White(.09)}},codeStyleName:"dark",empty:{textColor:White(.5)},focus:{ringColor:"rgba(111, 198, 205, 0.8)"},scrollBar:{bar_color:"#8A8A88",bar_mouseOverColor:"#BFBFBD"}}};
@@ -0,0 +1,2 @@
1
+ /* Bismillah */
2
+ "use strict";const MenuBarDefaults={key:"0",left:0,top:0,width:"100%",height:34,menus:[],enabled:1,ariaLabel:"Menu bar",onClick:function(e,t,n){},onMenuOpen:function(e,t){},onMenuClose:function(e,t){},styleName:"light",style:{box:{color:"#F4F4F2",lineColor:Black(.12)},layout:{padding:4,gap:2},title:{fontSize:13,textColor:Black(.82),height:26,padding:10,round:5},titleHover:{color:Black(.07),borderColor:""},titleOpen:{color:Black(.11),borderColor:""},disabled:{opacity:.4},focus:{ringColor:"rgba(63, 141, 148, 0.8)"},menuStyleName:"light",menu:{item:{height:30,fontSize:13}},menuMinWidth:200}},MenuBar=function(e={}){const t=e.style;basic.applyStylePackage(e,MenuBar.styles,MenuBarDefaults),mergeIntoIfMissing(e,MenuBarDefaults);const n=startObject(e);let o=n.style,r=-1,i=-1,u=0,l=0;n.menuList=[];const a=function(e){return r==e},c=function(e){return 1==n.enabled&&!(void 0!==e.enabled&&!basic.isOn(e.enabled))},s=function(e){return Array.isArray(e.items)&&e.items.length>0},m=function(e){if("object"!=typeof e||null===e)return e;const t=Object.assign({},e);return t.barItem=e,t.onClick=null,e.shortcut&&(t.shortcut=MenuBar.shortcutText(e.shortcut)),Array.isArray(e.items)&&(t.items=e.items.map(m)),t},f=function(e){return(e.items||[]).map(m)},d=function(e,t){"function"==typeof e.onClick&&e.onClick(n,e,t),n.isRemoved||n.onClick(n,e,t)},y=function(e,t,n){const r=e.title,i=c(e.menu);let l="transparent";n&&i&&(l=o.titleHover.color),a(t)&&(l=o.titleOpen.color),r.color=l,o.title.border&&(r.borderColor=function(e,t){return a(e)&&o.titleOpen.borderColor?o.titleOpen.borderColor:t&&o.titleHover.borderColor?o.titleHover.borderColor:o.title.borderColor||"transparent"}(t,n&&i)),r.opacity=i?1:o.disabled.opacity,r.cursor=i?"pointer":"default",r.tabIndex=t==u?0:-1,r.aria={disabled:i?"false":"true"},s(e.menu)&&(r.aria={expanded:a(t)?"true":"false"})},p=function(){n.menuList.forEach(function(e,t){y(e,t,0)})},M=function(e,t){const o=n.menuList[e];o&&s(o.menu)&&c(o.menu)&&(n.closeMenu(),r=e,u=e,o.contextMenu.openBelow(o.title),t&&o.contextMenu.activateFirst(),p(),n.onMenuOpen(n,o.menu))},h=function(e,t,o){const r=n.menuList.length;for(let i=1;i<=r;i++){const u=(e+t*i+r*i)%r,l=n.menuList[u].menu;if(c(l)&&(!o||s(l)))return u}return-1},b=function(e,t){if(!(r>=0))if("ArrowRight"===t.key||"ArrowLeft"===t.key){t.preventDefault();const o=h(e,"ArrowRight"===t.key?1:-1,0);o>=0&&function(e){n.menuList[e]&&(u=e,p(),n.menuList[e].title.elem.focus())}(o)}else"ArrowDown"===t.key&&(t.preventDefault(),M(e,1))},g=function(e,t){return ContextMenu({items:f(e),styleName:o.menuStyleName,style:o.menu,minWidth:o.menuMinWidth,ariaLabel:e.text,onClick:function(t,n){d(n.barItem||n,e)},onClose:function(){!function(e){r==e&&(r=-1,p(),l&&n.menuList[e].title.elem.focus({preventScroll:!0}),n.onMenuClose(n,n.menuList[e].menu))}(t)},onSideKey:function(e,t){!function(e){const t=h(r,e,1);t>=0&&t!=r&&M(t,1)}(t)}})},B=function(e){e.props({height:o.title.height,fontSize:o.title.fontSize,textColor:o.title.textColor,round:o.title.round}),o.title.border&&e.props({border:o.title.border,borderColor:o.title.borderColor||"transparent"}),e.css.padding="0 "+o.title.padding+"px",e.setFocusRing(o.focus.ringColor)},C=function(e,t){const o=Button({width:"auto",color:"transparent",shrink:0,css:{whiteSpace:"nowrap"}});o.minimal=1,o.plainText=e.text,o.role="menuitem",s(e)&&(o.aria={haspopup:"menu"}),B(o);const u=g(e,t);return o.onHoverChange(function(o,i){y(n.menuList[t],t,i);i&&(r>=0&&r!=t)&&s(e)&&M(t,0)}),o.on("click",function(e,o){!function(e,t){const o=n.menuList[e];if(!c(o.menu))return;if(!s(o.menu))return void d(o.menu,o.menu);const r=0===t.detail,u=!r&&i==e;i=-1,u||M(e,r)}(t,o)}),o.on("keydown",function(e,n){b(t,n)}),{menu:e,title:o,contextMenu:u}},x=function(){n.closeMenu(),n.menuList.forEach(function(e){e.contextMenu.remove(),e.title.remove()}),n.menuList=[]},k=function(){n.color=o.box.color,n.css.borderBottom="1px solid "+o.box.lineColor,n.layout.gap=o.layout.gap,n.layout.padding=[o.layout.padding,0]},S=function(e){let t=null;return n.menuList.forEach(function(n){MenuBar.forEachItem(n.menu.items,function(o){t||o.key!=e||(t={item:o,entry:n})})}),t},O=function(e,t){const n=e.entry.contextMenu;n.getItemByKey(e.item.key)?t(n):n.setItems(f(e.entry.menu))};n.setMenus=function(e){n.menus=Array.isArray(e)?e.map(MenuBar.copyItem):[],x(),r=-1,u=Math.max(0,n.menus.findIndex(c)),n.menuList=n.menus.map(function(e,t){return createIn(n.layout,function(){return C(e,t)})}),p()},n.closeMenu=function(){const e=n.menuList[r];e&&e.contextMenu.close()},n.setItemEnabled=function(e,t){const n=S(e);n&&(n.item.enabled=basic.isOn(t)?1:0,O(n,function(t){t.setItemEnabled(e,n.item.enabled)}))},n.setItemChecked=function(e,t){const n=S(e);n&&(n.item.checked=basic.isOn(t)?1:0,O(n,function(t){t.setItemChecked(e,n.item.checked)}))},n.setEnabled=function(e){n.enabled=basic.isOn(e)?1:0,1!=n.enabled&&n.closeMenu(),p()},n.setTheme=function(e){n.styleName=e,o=function(e){const n={styleName:e,style:t};return basic.applyStylePackage(n,MenuBar.styles,MenuBarDefaults),mergeIntoIfMissing(n,MenuBarDefaults),n.style}(e),n.style=o,k(),n.menuList.forEach(function(e,t){B(e.title),e.contextMenu.remove(),e.contextMenu=g(e.menu,t)}),p()};const I=n.remove;return n.superRemove=I,n.remove=function(){n.isRemoved||(x(),I.call(n))},n.css.boxSizing="border-box",n.role="menubar",n.aria={label:n.ariaLabel},n.layout=HGroup({width:"100%",height:"100%",align:"left center",scrollX:1}),n.layout.css.scrollbarWidth="none",endGroup(),n.listenTo(window,"pointerdown",function(){i=r,l=0},!0),n.listenTo(window,"keydown",function(){l=1},!0),n.listenTo(window,"keydown",function(e,t){if(1!=n.enabled||t.defaultPrevented)return;const o=function(e){for(const t of n.menuList){const n=c(t.menu)?MenuBar.findShortcutItem(t.menu.items,e):null;if(n)return{item:n,menu:t.menu}}return null}(t);o&&!MenuBar.isDialogOpen()&&(t.preventDefault(),t.repeat||(n.closeMenu(),d(o.item,o.menu)))}),k(),n.setMenus(e.menus),endObject(n)};MenuBar.FIELD_KEYS=["c","v","x","a","z","y"],MenuBar.isMac=function(){return/Mac|iPhone|iPad/.test(navigator.platform||"")},MenuBar.parseShortcut=function(e){const t=String(e).toLowerCase().split("+").map(function(e){return e.trim()});return{ctrl:t.indexOf("ctrl")>=0||t.indexOf("cmd")>=0,shift:t.indexOf("shift")>=0,alt:t.indexOf("alt")>=0,key:t[t.length-1]}},MenuBar.isShortcutEvent=function(e,t){const n=t.ctrlKey||t.metaKey;if(e.ctrl!=n||e.shift!=t.shiftKey||e.alt!=t.altKey)return!1;return(" "===t.key?"space":String(t.key).toLowerCase())==e.key},MenuBar.copyItem=function(e){if("object"!=typeof e||null===e)return e;const t=Object.assign({},e);return Array.isArray(e.items)&&(t.items=e.items.map(MenuBar.copyItem)),t},MenuBar.forEachItem=function(e,t){(e||[]).forEach(function(e){"object"==typeof e&&null!==e&&(t(e),MenuBar.forEachItem(e.items,t))})},MenuBar.isTextField=function(e){return!(!e||!e.tagName)&&("INPUT"===e.tagName||"TEXTAREA"===e.tagName||e.isContentEditable)},MenuBar.isDialogOpen=function(){return Array.from(document.querySelectorAll('[aria-modal="true"]')).some(function(e){return e.getClientRects().length>0})},MenuBar.isKeyOfField=function(e){return!e.ctrl||MenuBar.FIELD_KEYS.indexOf(e.key)>=0&&!e.alt},MenuBar.isCopyOfSelection=function(e){return e.ctrl&&"c"===e.key&&!window.getSelection().isCollapsed},MenuBar.findShortcutItem=function(e,t){const n=MenuBar.isTextField(t.target);let o=null;return MenuBar.forEachItem(e,function(e){if(o||!e.shortcut)return;const r=MenuBar.parseShortcut(e.shortcut);MenuBar.isShortcutEvent(r,t)&&(n&&MenuBar.isKeyOfField(r)||MenuBar.isCopyOfSelection(r)||(void 0===e.enabled||basic.isOn(e.enabled))&&(o=e))}),o},MenuBar.shortcutText=function(e){if(!MenuBar.isMac())return String(e);const t=String(e).split("+").map(function(e){return e.trim()}),n=t[t.length-1],o=t.map(function(e){return e.toLowerCase()});let r="";return o.indexOf("alt")>=0&&(r+="⌥"),o.indexOf("shift")>=0&&(r+="⇧"),(o.indexOf("ctrl")>=0||o.indexOf("cmd")>=0)&&(r+="⌘"),r+n.toUpperCase()},MenuBar.styles={light:MenuBarDefaults.style,dark:{box:{color:"#232322",lineColor:White(.1)},title:{textColor:White(.86)},titleHover:{color:White(.09)},titleOpen:{color:White(.15)},focus:{ringColor:"rgba(111, 198, 205, 0.8)"},menuStyleName:"dark"}},MenuBar.createMinimalStyle=function(e){return{height:30,style:{box:{color:"transparent",lineColor:e.line},layout:{padding:2,gap:2},title:{fontSize:13,textColor:e.text,height:24,padding:9,round:3,border:1,borderColor:"transparent"},titleHover:{color:"transparent",borderColor:e.lineHover},titleOpen:{color:"transparent",borderColor:e.ink},disabled:{opacity:.4},focus:{ringColor:e.focus},menuStyleName:e.menuStyleName,menu:{item:{height:28,fontSize:13}},menuMinWidth:180}}},MenuBar.MINIMAL_COLORS={text:Black(.85),line:Black(.2),lineHover:Black(.45),ink:"#1F1F1F",focus:"#3D8BD9",menuStyleName:"minimal"},MenuBar.styles.minimal=MenuBar.createMinimalStyle(MenuBar.MINIMAL_COLORS),MenuBar.MINIMAL_DARK_COLORS={text:White(.88),line:White(.18),lineHover:White(.42),ink:"#EDEDEB",focus:"#7FB6DE",menuStyleName:"minimalDark"},MenuBar.styles.minimalDark=MenuBar.createMinimalStyle(MenuBar.MINIMAL_DARK_COLORS);
@@ -1,2 +1,2 @@
1
1
  /* Bismillah */
2
- "use strict";const MiniGraphBoxDefaults={key:"0",width:200,height:80,title:"Sold Items",valueText:"1.3K",iconFile:"",barColor:"tomato",values:[],maxValue:0,animated:1,showTooltip:1,valueFormat:function(t,o,e){return String(t)},onClick:function(t){},style:{box:{color:"whitesmoke",border:1,borderColor:Black(.6),round:4},text:{padding:8},title:{fontSize:12,textColor:Black(.5)},valueText:{fontSize:20,textColor:Black(.75)},icon:{width:24,height:24},bars:{height:30,minHeight:2,barWidth:3,gap:1,padding:2,round:1},tooltip:{color:Black(.8),textColor:"white",fontSize:11,padding:[6,2],round:4,gap:3,barOpacity:.55}}},MiniGraphBox=function(t={}){mergeIntoIfMissing(t,MiniGraphBoxDefaults);const o=t.style.box;t.color=o.color,t.border=o.border,t.borderColor=o.borderColor,t.round=o.round;let e=startObject(t);const n=e.style;let l=[],i=null;let a=-1;e.values=[],e.barCount=0;const r=function(t){return null!==t&&"object"==typeof t?{value:basic.num(t.value)||0,color:t.color||""}:{value:basic.num(t)||0,color:""}},u=function(){const t=e.elem.clientWidth-2*n.bars.padding,o=n.bars.barWidth+n.bars.gap;return Math.max(0,Math.floor((t+n.bars.gap)/o))},c=function(){e.barCount<=0||e.values.length>e.barCount&&(e.values=e.values.slice(e.values.length-e.barCount))},s=function(){if(e.maxValue>0)return e.maxValue;let t=0;return e.values.forEach(function(o){o.value>t&&(t=o.value)}),t},f=function(){l.forEach(function(t){t.remove()}),l=[],createIn(e.barGroup,function(){for(let t=0;t<e.barCount;t++){const t=Box({width:n.bars.barWidth,height:0,color:e.barColor,round:n.bars.round});t.shrink=0,t.motion="",l.push(t)}})},h=function(t,o){t.motion!==o&&(t.motion=o,t.setMotionNow(o))},p=function(t,o){if(t.value<=0||o<=0)return 0;const e=Math.round(Math.min(t.value,o)/o*n.bars.height);return Math.max(n.bars.minHeight,e)},b=function(t=-1){const o=s();l.forEach(function(n,l){const i=e.values[l],a=l==t;if(1!=e.animated||t>=0&&!a?h(n,"none"):a||h(n,"height 0.2s, background-color 0.2s"),!i)return n.height=0,void(n.elem.title="");const r=p(i,o);a&&1==e.animated&&(h(n,"none"),n.height=0,n.color=i.color||e.barColor,n.elem.offsetHeight,h(n,"height 0.2s")),n.height=r,n.color=i.color||e.barColor}),g()},d=function(){l.forEach(function(t,o){const e=a>=0&&o!=a;t.opacity=e?n.tooltip.barOpacity:1})},g=function(){const t=e.values[a],o=l[a];if(!t||!o||1!=e.showTooltip)return!(a>=0)||t&&o||(a=-1,d()),void(e.lblTooltip.visible=0);e.lblTooltip.plainText=e.valueFormat(t.value,a,e),e.lblTooltip.visible=1;const i=e.barGroup.elem.offsetLeft+o.elem.offsetLeft+o.elem.offsetWidth/2,r=e.lblTooltip.elem.offsetWidth,u=e.lblTooltip.elem.offsetHeight,c=e.elem.clientWidth-r,f=e.barGroup.elem.offsetTop+e.barGroup.elem.offsetHeight-p(t,s());e.lblTooltip.left=Math.round(Math.max(0,Math.min(c,i-r/2))),e.lblTooltip.top=Math.round(Math.max(0,f-u-n.tooltip.gap))},m=function(t){t!=a&&(a=t,d(),g())},v=function(){if(!e)return;const t=u();t!=e.barCount&&(e.barCount=t,f(),c(),a=-1,d()),b()};return e.addValue=function(t,o){const n=r(t);o&&(n.color=o),e.values.push(n),c(),b(e.values.length-1)},e.setValues=function(t){e.values=(t||[]).map(r),c(),b()},e.getValues=function(){return e.values.map(function(t){return t.value})},e.getLastValue=function(){const t=e.values[e.values.length-1];return t?t.value:null},e.clear=function(){e.values=[],b()},e.setTitle=function(t){e.title=t,e.lblTitle.text=t},e.setValueText=function(t){e.valueText=t,e.lblValueText.text=t},e.setIcon=function(t){e.iconFile=t||"",e.icon.visible=e.iconFile?1:0,e.iconFile&&e.icon.load(e.iconFile)},e.setBarColor=function(t){e.barColor=t,b()},e.setMaxValue=function(t){e.maxValue=basic.num(t)||0,b()},e.refresh=function(){v()},e.barGroup=HGroup({align:"left bottom",gap:n.bars.gap,padding:[n.bars.padding,0]}),endGroup(),VGroup({align:"left top",padding:n.text.padding,gap:0}),e.lblTitle=Label({text:e.title,fontSize:n.title.fontSize,textColor:n.title.textColor}),e.lblTitle.css={whiteSpace:"nowrap",marginBottom:"-6px"},e.lblValueText=Label({text:e.valueText,fontSize:n.valueText.fontSize,textColor:n.valueText.textColor}),e.lblValueText.css.whiteSpace="nowrap",endGroup(),HGroup({align:"right top",padding:n.text.padding,gap:0}),e.icon=Icon({width:n.icon.width,height:n.icon.height}),e.icon.elem.alt="",endGroup(),e.lblTooltip=Label({left:0,top:0,width:"auto",height:"auto",color:n.tooltip.color,textColor:n.tooltip.textColor,fontSize:n.tooltip.fontSize,padding:n.tooltip.padding,round:n.tooltip.round,visible:0,css:{whiteSpace:"nowrap",pointerEvents:"none"}}),e.on("click",function(){e.onClick(e)}),e.cursor="default",e.clickable=1,e.on("mousemove",function(t,o){m(function(t){const o=e.barGroup.elem.getBoundingClientRect(),l=o.width/(e.barGroup.elem.offsetWidth||1),i=(t.clientX-o.left)/l-n.bars.padding,a=n.bars.barWidth+n.bars.gap,r=Math.floor((i+n.bars.gap/2)/a);return r<0||r>=e.values.length?-1:r}(o))}),e.on("mouseleave",function(){m(-1)}),e.setIcon(e.iconFile),e.values=(t.values||[]).map(r),e.barCount=u(),f(),c(),b(),e.onResize(function(){i&&i(),i=e.after(30,function(){i=null,v()})}),endObject(e)};
2
+ "use strict";const MiniGraphBoxDefaults={key:"0",width:200,height:80,titleText:"Sold Items",valueText:"1.3K",allowHtml:0,iconFile:"",barColor:"tomato",values:[],maxValue:0,animated:1,showTooltip:1,valueFormat:function(t,o,e){return String(t)},onClick:function(t){},style:{box:{color:"whitesmoke",border:1,borderColor:Black(.6),round:4},text:{padding:8},title:{fontSize:12,textColor:Black(.5)},valueText:{fontSize:20,textColor:Black(.75)},icon:{width:24,height:24},bars:{height:30,minHeight:2,barWidth:3,gap:1,padding:2,round:1},tooltip:{color:Black(.8),textColor:"white",fontSize:11,padding:[6,2],round:4,gap:3,barOpacity:.55}}},MiniGraphBox=function(t={}){mergeIntoIfMissing(t,MiniGraphBoxDefaults);const o=t.style.box;t.color=o.color,t.border=o.border,t.borderColor=o.borderColor,t.round=o.round;let e=startObject(t);const l=e.style;let n=[],i=null;let a=-1;e.values=[],e.barCount=0;const r=function(t,o){const l=null==o?"":String(o);1==e.allowHtml?t.text=l:t.plainText=l},u=function(t){return null!==t&&"object"==typeof t?{value:basic.num(t.value)||0,color:t.color||""}:{value:basic.num(t)||0,color:""}},c=function(){const t=e.elem.clientWidth-2*l.bars.padding,o=l.bars.barWidth+l.bars.gap;return Math.max(0,Math.floor((t+l.bars.gap)/o))},s=function(){e.barCount<=0||e.values.length>e.barCount&&(e.values=e.values.slice(e.values.length-e.barCount))},f=function(){if(e.maxValue>0)return e.maxValue;let t=0;return e.values.forEach(function(o){o.value>t&&(t=o.value)}),t},h=function(){n.forEach(function(t){t.remove()}),n=[],createIn(e.barGroup,function(){for(let t=0;t<e.barCount;t++){const t=Box({width:l.bars.barWidth,height:0,color:e.barColor,round:l.bars.round});t.shrink=0,t.motion="",n.push(t)}})},p=function(t,o){t.motion!==o&&(t.motion=o,t.setMotionNow(o))},b=function(t,o){if(t.value<=0||o<=0)return 0;const e=Math.round(Math.min(t.value,o)/o*l.bars.height);return Math.max(l.bars.minHeight,e)},d=function(t=-1){const o=f();n.forEach(function(l,n){const i=e.values[n],a=n==t;if(1!=e.animated||t>=0&&!a?p(l,"none"):a||p(l,"height 0.2s, background-color 0.2s"),!i)return l.height=0,void(l.elem.title="");const r=b(i,o);a&&1==e.animated&&(p(l,"none"),l.height=0,l.color=i.color||e.barColor,l.elem.offsetHeight,p(l,"height 0.2s")),l.height=r,l.color=i.color||e.barColor}),m()},g=function(){n.forEach(function(t,o){const e=a>=0&&o!=a;t.opacity=e?l.tooltip.barOpacity:1})},m=function(){const t=e.values[a],o=n[a];if(!t||!o||1!=e.showTooltip)return!(a>=0)||t&&o||(a=-1,g()),void(e.lblTooltip.visible=0);e.lblTooltip.plainText=e.valueFormat(t.value,a,e),e.lblTooltip.visible=1;const i=e.barGroup.elem.offsetLeft+o.elem.offsetLeft+o.elem.offsetWidth/2,r=e.lblTooltip.elem.offsetWidth,u=e.lblTooltip.elem.offsetHeight,c=e.elem.clientWidth-r,s=e.barGroup.elem.offsetTop+e.barGroup.elem.offsetHeight-b(t,f());e.lblTooltip.left=Math.round(Math.max(0,Math.min(c,i-r/2))),e.lblTooltip.top=Math.round(Math.max(0,s-u-l.tooltip.gap))},v=function(t){t!=a&&(a=t,g(),m())},x=function(){if(!e)return;const t=c();t!=e.barCount&&(e.barCount=t,h(),s(),a=-1,g()),d()};return e.addValue=function(t,o){const l=u(t);o&&(l.color=o),e.values.push(l),s(),d(e.values.length-1)},e.setValues=function(t){e.values=(t||[]).map(u),s(),d()},e.getValues=function(){return e.values.map(function(t){return t.value})},e.getLastValue=function(){const t=e.values[e.values.length-1];return t?t.value:null},e.clear=function(){e.values=[],d()},e.setTitleText=function(t){e.titleText=t,r(e.lblTitle,t)},e.setValueText=function(t){e.valueText=t,r(e.lblValueText,t)},e.setIcon=function(t){e.iconFile=t||"",e.icon.visible=e.iconFile?1:0,e.iconFile&&e.icon.load(e.iconFile)},e.setBarColor=function(t){e.barColor=t,d()},e.setMaxValue=function(t){e.maxValue=basic.num(t)||0,d()},e.refresh=function(){x()},e.barGroup=HGroup({align:"left bottom",gap:l.bars.gap,padding:[l.bars.padding,0]}),endGroup(),VGroup({align:"left top",padding:l.text.padding,gap:0}),e.lblTitle=Label({fontSize:l.title.fontSize,textColor:l.title.textColor}),r(e.lblTitle,e.titleText),e.lblTitle.css={whiteSpace:"nowrap",marginBottom:"-6px"},e.lblValueText=Label({fontSize:l.valueText.fontSize,textColor:l.valueText.textColor}),r(e.lblValueText,e.valueText),e.lblValueText.css.whiteSpace="nowrap",endGroup(),HGroup({align:"right top",padding:l.text.padding,gap:0}),e.icon=Icon({width:l.icon.width,height:l.icon.height}),e.icon.elem.alt="",endGroup(),e.lblTooltip=Label({left:0,top:0,width:"auto",height:"auto",color:l.tooltip.color,textColor:l.tooltip.textColor,fontSize:l.tooltip.fontSize,padding:l.tooltip.padding,round:l.tooltip.round,visible:0,css:{whiteSpace:"nowrap",pointerEvents:"none"}}),e.on("click",function(){e.onClick(e)}),e.cursor="default",e.clickable=1,e.on("mousemove",function(t,o){v(function(t){const o=e.barGroup.elem.getBoundingClientRect(),n=o.width/(e.barGroup.elem.offsetWidth||1),i=(t.clientX-o.left)/n-l.bars.padding,a=l.bars.barWidth+l.bars.gap,r=Math.floor((i+l.bars.gap/2)/a);return r<0||r>=e.values.length?-1:r}(o))}),e.on("mouseleave",function(){v(-1)}),e.setIcon(e.iconFile),e.values=(t.values||[]).map(u),e.barCount=c(),h(),s(),d(),e.onResize(function(){i&&i(),i=e.after(30,function(){i=null,x()})}),endObject(e)};
@@ -0,0 +1,2 @@
1
+ /* Bismillah */
2
+ "use strict";const MinimalAccent={COMPONENTS:["Accordion","ChatView","CheckBox","ContextMenu","DataTable","Dialog","TextField","ItemList","JsonEditor","LoadingScreen","MenuBar","ProgressBar","RadioButton","RangeSlider","ScrollArea","SearchInput","SelectBox","ColorPicker","DatePicker","FilePicker","TimePicker","SidePanel","Slider","SliderField","SmartTable","Splitter","StatusBar","StepBar","Stepper","Tabs","TagInput","TimeLine","Toggle","ToolBar","TreeView"],WHITE:"#FFFFFF",DARK_GROUND:"#1A1A19",READABLE_CONTRAST:4.5,HOVER_SHADE:.12,VERY_DARK:.03,LIGHTEN_STEP:.05,addPackages:function(n,t,i=""){const e={light:n,dark:n+"Dark"},c=MinimalAccent.createInk(t,"light"),a=MinimalAccent.createInk(i||MinimalAccent.lightenForDarkGround(t),"dark");for(const n of MinimalAccent.COMPONENTS){const t=MinimalAccent.findComponent(n);t&&t.styles&&t.styles.minimal&&(t.styles[e.light]=MinimalAccent.createPackage(t,"light",c,e),t.styles[e.dark]=MinimalAccent.createPackage(t,"dark",a,e))}return MinimalAccent.addButtonLooks(e,c,a),MinimalAccent.addToastThemes(e,c,a),MinimalAccent.addTooltipLooks(e),e},createInk:function(n,t){const i=MinimalAccent.toRgb(n),e=MinimalAccent.luminance(i)<MinimalAccent.VERY_DARK,c="dark"===t||e,a=MinimalAccent.toRgb(c?MinimalAccent.WHITE:"#000000");return{ink:MinimalAccent.toHex(i),inkHover:MinimalAccent.toHex(MinimalAccent.mix(i,a,MinimalAccent.HOVER_SHADE)),onInk:MinimalAccent.textOn(i)}},lightenForDarkGround:function(n){const t=MinimalAccent.toRgb(n),i=MinimalAccent.toRgb(MinimalAccent.DARK_GROUND),e=MinimalAccent.toRgb(MinimalAccent.WHITE);for(let n=0;n<1;n+=MinimalAccent.LIGHTEN_STEP){const c=MinimalAccent.mix(t,e,n);if(MinimalAccent.contrast(c,i)>=MinimalAccent.READABLE_CONTRAST)return MinimalAccent.toHex(c)}return MinimalAccent.WHITE},findComponent:function(n){return Function("return (typeof "+n+' !== "undefined") ? '+n+" : null;")()},createPackage:function(n,t,i,e){const c="dark"===t,a=c?n.MINIMAL_DARK_COLORS:n.MINIMAL_COLORS,o=c?n.styles.minimalDark:n.styles.minimal;return a&&n.createMinimalStyle?n.createMinimalStyle(MinimalAccent.withInk(a,i,c,e)):o},withInk:function(n,t,i,e){const c=i?e.dark:e.light,a=i?["minimalDark","inkDark"]:["minimal","ink"],o=Object.assign({},n,t);for(const t of Object.keys(n))a.includes(n[t])&&(o[t]=c);return o},addButtonLooks:function(n,t,i){const e=MinimalAccent.findComponent("SmartButton");e&&e.styles.minimal&&(e.styles[n.light]=e.styles.minimal,e.styles[n.dark]=e.styles.minimalDark,e.tones[n.light]=MinimalAccent.createButtonTone(e,t),e.tones[n.dark]=MinimalAccent.createButtonTone(e,i))},createButtonTone:function(n,t){const i=t.onInk===MinimalAccent.WHITE?n.LIGHT_TEXT:t.onInk;return{color:t.ink,hover:t.inkHover,text:i,edge:t.ink,hoverEdge:t.inkHover}},addToastThemes:function(n,t,i){const e=MinimalAccent.findComponent("Toast");e&&e.THEMES&&e.THEMES.minimal&&(e.THEMES[n.light]=Object.assign({},e.THEMES.minimal,{actionText:t.ink}),e.THEMES[n.dark]=Object.assign({},e.THEMES.minimalDark,{actionText:i.ink}))},addTooltipLooks:function(n){const t=MinimalAccent.findComponent("Tooltip");t&&t.looks&&t.looks.minimal&&(t.looks[n.light]=t.looks.minimal,t.looks[n.dark]=t.looks.minimalDark)},toRgb:function(n){MinimalAccent.colorReader||(MinimalAccent.colorReader=document.createElement("canvas").getContext("2d"));const t=MinimalAccent.colorReader,i="#010203";t.fillStyle=i,t.fillStyle=String(n);const e=t.fillStyle;return e===i&&String(n).toLowerCase()!==i&&console.warn("MinimalAccent: not a color: "+n),e.startsWith("#")?[1,3,5].map(n=>parseInt(e.slice(n,n+2),16)):e.match(/[\d.]+/g).slice(0,3).map(Number)},toHex:function(n){return"#"+n.map(n=>Math.round(n).toString(16).padStart(2,"0")).join("").toUpperCase()},mix:function(n,t,i){return n.map((n,e)=>n+(t[e]-n)*i)},luminance:function(n){const t=n.map(function(n){const t=n/255;return t<=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4)});return.2126*t[0]+.7152*t[1]+.0722*t[2]},contrast:function(n,t){const i=MinimalAccent.luminance(n),e=MinimalAccent.luminance(t);return(Math.max(i,e)+.05)/(Math.min(i,e)+.05)},textOn:function(n){return MinimalAccent.contrast(n,MinimalAccent.toRgb(MinimalAccent.WHITE))>=MinimalAccent.contrast(n,MinimalAccent.toRgb(MinimalAccent.DARK_GROUND))?MinimalAccent.WHITE:MinimalAccent.DARK_GROUND}};
@@ -1,2 +1,2 @@
1
1
  /* Bismillah */
2
- "use strict";const NoticeDefaults={left:0,top:0,width:"100%",height:"100%",messageText:"No message",descText:"",type:"info",iconFile:"",allowHtml:0,displayTime:2e3,closeOnClick:1,onClose:function(e){},styleName:"classic",style:{cover:{color:"rgba(0, 0, 0, 0.2)",zIndex:5e4},message:{round:8,border:2,borderColor:"rgba(0, 0, 0, 0.2)",padding:[24,18],gap:20,maxWidth:480,boxShadow:"0px 0px 12px rgba(0, 0, 0, 0.1)"},text:{fontSize:20,textColor:"rgba(0, 0, 0, 0.8)",fontFamily:"opensans"},desc:{fontSize:17,opacity:.8},icon:{size:28,opacity:.95},motion:{startScale:.9}}},Notice=function(e={}){basic.applyStylePackage(e,Notice.styles,NoticeDefaults),mergeIntoIfMissing(e,NoticeDefaults);let o=startObject(e);const t=o.style;let c=0;const i=function(e,t){1==o.allowHtml?e.text=t:e.plainText=t};o.close=function(){o&&!c&&(c=1,Notice.current==o&&(Notice.current=null),o.onClose(o),o.remove())};const n=o.remove;o.superRemove=n,o.remove=function(){o&&(Notice.current==o&&(Notice.current=null),n.call(o),o=null)};const s=Notice.COLORS[o.type]||Notice.COLORS.info;return o.color=t.cover.color,o.zIndex=t.cover.zIndex,o.clickable=1,o.role="error"==o.type?"alert":"status",o.aria={live:"error"==o.type?"assertive":"polite"},HGroup({align:"center",clipContent:0}),o.message=HGroup({hug:1,align:"left center",gap:t.message.gap,padding:t.message.padding,color:s.color,round:t.message.round,border:t.message.border,borderColor:t.message.borderColor,boxShadow:t.message.boxShadow,css:{maxWidth:"min("+t.message.maxWidth+"px, calc(100% - 40px))"}}),o.iconFile&&(o.icon=Icon({width:t.icon.size,height:t.icon.size,opacity:t.icon.opacity}),o.icon.load(o.iconFile),o.icon.shrink=0),VGroup({hug:1,align:(o.iconFile?"left":"center")+" center",gap:2}),that.css={minWidth:"0px"},o.lblMessage=Label({...t.text,textColor:s.textColor||t.text.textColor,textAlign:o.iconFile?"left":"center"}),o.lblMessage.css={whiteSpace:"normal"},i(o.lblMessage,o.messageText),o.lblDesc=Label({...t.text,fontSize:t.desc.fontSize,opacity:t.desc.opacity,textColor:s.textColor||t.text.textColor,textAlign:o.iconFile?"left":"center"}),o.lblDesc.css={whiteSpace:"normal"},i(o.lblDesc,o.descText),o.lblDesc.visible=""!==o.descText&&null!==o.descText&&void 0!==o.descText?1:0,endGroup(),endGroup(),endGroup(),1==o.closeOnClick&&o.on("click",function(){o.close()}),o.listenTo(window,"keydown",function(e,t){"Escape"==t.key&&(t.preventDefault(),t.stopImmediatePropagation(),o.close())},!0),o.displayTime>0&&o.after(o.displayTime,function(){o.close()}),function(){if(window.matchMedia&&window.matchMedia("(prefers-reduced-motion: reduce)").matches)return;const e=o.message;e.opacity=0,e.css={transform:"scale("+t.motion.startScale+")"},o.opacity=0,e.elem.offsetHeight,e.setMotionNow("transform 0.2s, opacity 0.2s"),o.setMotionNow("opacity 0.2s"),e.opacity=1,e.css={transform:"none"},o.opacity=1}(),endObject(o)};Notice.COLORS={info:{color:"white",textColor:""},warning:{color:"#FFD541",textColor:"#141414"},error:{color:"#EE7553",textColor:"#141414"},note:{color:"#689BD2",textColor:"white"},success:{color:"seagreen",textColor:"white"}},Notice.current=null,Notice.show=function(e={}){for(;Notice.current;)Notice.close();return Notice.current=createIn(page,function(){return Notice(e)}),Notice.current},Notice.close=function(){Notice.current&&Notice.current.close()},Notice.styles={classic:NoticeDefaults.style};
2
+ "use strict";const NoticeDefaults={left:0,top:0,width:"100%",height:"100%",messageText:"No message",descriptionText:"",type:"info",iconFile:"",allowHtml:0,displayTime:2e3,closeOnClick:1,onClose:function(e){},styleName:"classic",style:{cover:{color:"rgba(0, 0, 0, 0.2)",zIndex:5e4},message:{round:8,border:2,borderColor:"rgba(0, 0, 0, 0.2)",padding:[24,18],gap:20,maxWidth:480,boxShadow:"0px 0px 12px rgba(0, 0, 0, 0.1)"},text:{fontSize:20,textColor:"rgba(0, 0, 0, 0.8)",fontFamily:"opensans"},desc:{fontSize:17,opacity:.8},icon:{size:28,opacity:.95},motion:{startScale:.9}}},Notice=function(e={}){basic.applyStylePackage(e,Notice.styles,NoticeDefaults),mergeIntoIfMissing(e,NoticeDefaults);let o=startObject(e);const t=o.style;let c=0;const i=function(e,t){1==o.allowHtml?e.text=t:e.plainText=t};o.close=function(){o&&!c&&(c=1,Notice.current==o&&(Notice.current=null),o.onClose(o),o.remove())};const n=o.remove;o.superRemove=n,o.remove=function(){o&&(Notice.current==o&&(Notice.current=null),n.call(o),o=null)};const r=Notice.COLORS[o.type]||Notice.COLORS.info;return o.color=t.cover.color,o.zIndex=t.cover.zIndex,o.clickable=1,o.role="error"==o.type?"alert":"status",o.aria={live:"error"==o.type?"assertive":"polite"},HGroup({align:"center",clipContent:0}),o.message=HGroup({hug:1,align:"left center",gap:t.message.gap,padding:t.message.padding,color:r.color,round:t.message.round,border:t.message.border,borderColor:t.message.borderColor,boxShadow:t.message.boxShadow,css:{maxWidth:"min("+t.message.maxWidth+"px, calc(100% - 40px))"}}),o.iconFile&&(o.icon=Icon({width:t.icon.size,height:t.icon.size,opacity:t.icon.opacity}),o.icon.load(o.iconFile),o.icon.shrink=0),VGroup({hug:1,align:(o.iconFile?"left":"center")+" center",gap:2}),that.css={minWidth:"0px"},o.lblMessage=Label({...t.text,textColor:r.textColor||t.text.textColor,textAlign:o.iconFile?"left":"center"}),o.lblMessage.css={whiteSpace:"normal"},i(o.lblMessage,o.messageText),o.lblDesc=Label({...t.text,fontSize:t.desc.fontSize,opacity:t.desc.opacity,textColor:r.textColor||t.text.textColor,textAlign:o.iconFile?"left":"center"}),o.lblDesc.css={whiteSpace:"normal"},i(o.lblDesc,o.descriptionText),o.lblDesc.visible=""!==o.descriptionText&&null!==o.descriptionText&&void 0!==o.descriptionText?1:0,endGroup(),endGroup(),endGroup(),1==o.closeOnClick&&o.on("click",function(){o.close()}),o.listenTo(window,"keydown",function(e,t){"Escape"==t.key&&(t.preventDefault(),t.stopImmediatePropagation(),o.close())},!0),o.displayTime>0&&o.after(o.displayTime,function(){o.close()}),function(){if(window.matchMedia&&window.matchMedia("(prefers-reduced-motion: reduce)").matches)return;const e=o.message;e.opacity=0,e.css={transform:"scale("+t.motion.startScale+")"},o.opacity=0,e.elem.offsetHeight,e.setMotionNow("transform 0.2s, opacity 0.2s"),o.setMotionNow("opacity 0.2s"),e.opacity=1,e.css={transform:"none"},o.opacity=1}(),endObject(o)};Notice.COLORS={info:{color:"white",textColor:""},warning:{color:"#FFD541",textColor:"#141414"},error:{color:"#EE7553",textColor:"#141414"},note:{color:"#689BD2",textColor:"white"},success:{color:"seagreen",textColor:"white"}},Notice.current=null,Notice.show=function(e={}){for(;Notice.current;)Notice.close();return Notice.current=createIn(page,function(){return Notice(e)}),Notice.current},Notice.close=function(){Notice.current&&Notice.current.close()},Notice.styles={classic:NoticeDefaults.style};
@@ -0,0 +1,2 @@
1
+ /* Bismillah */
2
+ "use strict";const NumberFieldDefaults={required:0,type:"number",titleText:"NUMERIC",maxLength:35,placeholder:"(auto)",allowNegative:0,allowDecimal:1,decimalSeparator:".",maxDecimalDigits:2},NumberField=function(e={}){mergeIntoIfMissing(e,NumberFieldDefaults);const a=startExtendedObject(TextField,e);return a.applyFormattedValueToInput=function(){let e=a.getValue(),l="0-9";a.allowNegative&&(l+="-"),a.allowDecimal&&(l+="\\"+a.decimalSeparator);const t=new RegExp(`[^${l}]`,"g");if(e=e.replace(t,""),a.allowNegative&&(e=e.replace(/(?!^)-/g,"")),a.allowDecimal){const l=a.decimalSeparator,t=e.split(l);t.length>2&&(t.splice(1,t.length-1,t.slice(1).join("")),e=t[0]+l+t[1]),2==t.length&&a.maxDecimalDigits>=0&&(t[1]=t[1].substring(0,a.maxDecimalDigits),e=t[0]+l+t[1])}0!=parseFloat(e)||e.includes(a.decimalSeparator)||e.includes("-")||(e="0"),e==a.decimalSeparator&&(e="0"+a.decimalSeparator),e=="-"+a.decimalSeparator&&(e="-0"+a.decimalSeparator),a.setValue(e)},"(auto)"==a.placeholder&&a.setPlaceholder(function(){let e="";return a.allowNegative&&(e="-"),e+="100",a.allowDecimal&&(e=e+a.decimalSeparator+"0".repeat(a.maxDecimalDigits)),e}()),endExtendedObject(a)};
@@ -1,2 +1,2 @@
1
1
  /* Bismillah */
2
- "use strict";const NumericKeyboardDefaults={width:"auto",height:"auto",keyLayout:"wide",titleText:"PIN",value:"",maxLength:4,mask:0,showValue:1,onChange:function(e){},onEnter:function(e){},styleName:"classic",style:{box:{color:"transparent"},layout:{gap:10,padding:[35,20]},title:{fontSize:18,textColor:"rgba(20, 20, 20, 0.5)"},value:{fontSize:35,textColor:"rgba(20, 20, 20, 0.9)",fontFamily:"opensans-bold",height:50},key:{size:80,gap:10,round:14,color:"white",border:1,borderColor:"rgba(0, 0, 0, 0.7)",fontSize:35,textColor:"#141414"},keyHover:{color:"#F7F7F7"},keyPressed:{color:"#E9E9E9"},enterKey:{color:"#141414",textColor:"white"},focus:{ringColor:"rgba(95, 158, 160, 0.6)"}}},NumericKeyboard=function(e={}){basic.applyStylePackage(e,NumericKeyboard.styles,NumericKeyboardDefaults),mergeIntoIfMissing(e,NumericKeyboardDefaults);let t=startObject(e);const o=t.style,l="back",r="enter",n={wide:[["1","2","3","4","5",l],["6","7","8","9","0"]],phone:[["1","2","3"],["4","5","6"],["7","8","9"],[l,"0",r]]},i={back:'<svg viewBox="0 0 24 24" width="38" height="38" fill="none" stroke="currentColor" stroke-width="1.6" stroke-linejoin="round" stroke-linecap="round" style="display: block"><path d="M9 5h11v14H9l-6-7z"/><path d="M12 9.5l5 5M17 9.5l-5 5"/></svg>',enter:'<svg viewBox="0 0 24 24" width="34" height="34" fill="none" stroke="currentColor" stroke-width="2" stroke-linejoin="round" stroke-linecap="round" style="display: block"><path d="M5 12.5l4.5 4.5L19 7.5"/></svg>'};t.keyList=[];const a=function(){t.lblValue&&(t.lblValue.plainText=t.mask?"•".repeat(t.value.length):t.value)},s=function(e,o){(e=String(null==e?"":e).replace(/\D/g,"").slice(0,t.maxLength))!==t.value&&(t.value=e,a(),o||t.onChange(t))},u=function(e){e!=r?e!=l?t.value.length>=t.maxLength||s(t.value+e):s(t.value.slice(0,-1)):t.onEnter(t)},c=function(e){const t=e.keyValue==r;let l=t?o.enterKey.color:o.key.color;e.isPressed&&!t?l=o.keyPressed.color:e.isHover&&!t&&(l=o.keyHover.color),e.color=l,t&&(e.opacity=e.isPressed?.8:1)};t.setValue=function(e,t=0){s(e,t)},t.getValue=function(){return t.value},t.clear=function(e=0){s("",e)},t.setTitle=function(e){t.titleText=e,t.aria={label:e||"Numeric keyboard"},t.lblTitle&&(t.lblTitle.plainText=e,t.lblTitle.visible=e?1:0)},t.props(o.box),t.tabIndex=0,t.role="group",t.aria={label:t.titleText||"Numeric keyboard"},t.setFocusRing(o.focus.ringColor);const y=n[t.keyLayout]||n.wide,g=Math.max.apply(null,y.map(function(e){return e.length}));t.layout=VGroup({hug:1,align:"center top",gap:0,padding:o.layout.padding,position:"relative",clipContent:0}),1==t.showValue&&(t.lblTitle=Label({...o.title,textAlign:"center"}),t.setTitle(t.titleText),t.lblValue=Label({...o.value,textAlign:"center",css:{lineHeight:o.value.height+"px",minHeight:o.value.height+"px",whiteSpace:"nowrap"}}),t.lblValue.css={marginBottom:o.layout.gap+"px"}),VGroup({hug:1,align:"left top",gap:o.key.gap,clipContent:0}),y.forEach(function(e){HGroup({hug:1,align:"left top",gap:o.key.gap,clipContent:0}),e.forEach(function(n,a){const s=a==e.length-1&&e.length<g?g-e.length+1:1,y=s*o.key.size+(s-1)*o.key.gap;t.keyList.push(function(e,t){const n=e==r,a=Label({width:t,height:o.key.size,round:o.key.round,border:o.key.border,borderColor:o.key.borderColor,fontSize:o.key.fontSize,textColor:n?o.enterKey.textColor:o.key.textColor,clickable:1,cursor:"pointer",role:"button",aria:{label:e==l?"Delete":n?"Enter":e},css:{display:"flex",alignItems:"center",justifyContent:"center",flexShrink:"0"}});a.text=i[e]||e,a.keyValue=e,a.isHover=0,a.isPressed=0,a.onHoverChange(function(e,t){a.isHover=t,t||(a.isPressed=0),c(a)}),a.on("pointerdown",function(){a.isPressed=1,c(a)});const s=function(){a.isPressed=0,c(a)};return a.on("pointerup",s),a.on("pointercancel",s),a.on("click",function(){u(e)}),c(a),a}(n,y))}),endGroup()}),endGroup(),endGroup(),t.on("keydown",function(e,t){if(!(t.ctrlKey||t.metaKey||t.altKey))return/^[0-9]$/.test(t.key)?(u(t.key),void t.preventDefault()):"Backspace"==t.key||"Delete"==t.key?(u(l),void t.preventDefault()):void("Enter"==t.key&&(t.preventDefault(),t.repeat||u(r)))});const d=t.value;return t.value="",s(d,1),a(),endObject(t)};NumericKeyboard.styles={classic:NumericKeyboardDefaults.style,dark:{title:{fontSize:18,textColor:"rgba(255, 255, 255, 0.5)"},value:{fontSize:35,textColor:"rgba(255, 255, 255, 0.92)",fontFamily:"opensans-bold",height:50},key:{size:80,gap:10,round:14,color:"#2B2D31",border:1,borderColor:"rgba(255, 255, 255, 0.18)",fontSize:35,textColor:"rgba(255, 255, 255, 0.9)"},keyHover:{color:"#33353A"},keyPressed:{color:"#3C3E44"},enterKey:{color:"#F2C14E",textColor:"#1B2632"},focus:{ringColor:"rgba(95, 179, 181, 0.7)"}}};
2
+ "use strict";const NumericKeyboardDefaults={width:"auto",height:"auto",keyLayout:"wide",titleText:"PIN",value:"",maxLength:4,mask:0,showValue:1,onChange:function(e){},onEnter:function(e){},styleName:"light",style:{box:{color:"transparent"},layout:{gap:10,padding:[35,20]},title:{fontSize:18,textColor:"rgba(20, 20, 20, 0.5)"},value:{fontSize:35,textColor:"rgba(20, 20, 20, 0.9)",fontFamily:"opensans-bold",height:50},key:{size:80,gap:10,round:14,color:"white",border:1,borderColor:"rgba(0, 0, 0, 0.7)",fontSize:35,textColor:"#141414"},keyHover:{color:"#F7F7F7"},keyPressed:{color:"#E9E9E9"},enterKey:{color:"#141414",textColor:"white"},focus:{ringColor:"rgba(95, 158, 160, 0.6)"}}},NumericKeyboard=function(e={}){basic.applyStylePackage(e,NumericKeyboard.styles,NumericKeyboardDefaults),mergeIntoIfMissing(e,NumericKeyboardDefaults);let t=startObject(e);const o=t.style,l="back",r="enter",n={wide:[["1","2","3","4","5",l],["6","7","8","9","0"]],phone:[["1","2","3"],["4","5","6"],["7","8","9"],[l,"0",r]]},i={back:'<svg viewBox="0 0 24 24" width="38" height="38" fill="none" stroke="currentColor" stroke-width="1.6" stroke-linejoin="round" stroke-linecap="round" style="display: block"><path d="M9 5h11v14H9l-6-7z"/><path d="M12 9.5l5 5M17 9.5l-5 5"/></svg>',enter:'<svg viewBox="0 0 24 24" width="34" height="34" fill="none" stroke="currentColor" stroke-width="2" stroke-linejoin="round" stroke-linecap="round" style="display: block"><path d="M5 12.5l4.5 4.5L19 7.5"/></svg>'};t.keyList=[];const a=function(){t.lblValue&&(t.lblValue.plainText=t.mask?"•".repeat(t.value.length):t.value)},s=function(e,o){(e=String(null==e?"":e).replace(/\D/g,"").slice(0,t.maxLength))!==t.value&&(t.value=e,a(),o||t.onChange(t))},u=function(e){e!=r?e!=l?t.value.length>=t.maxLength||s(t.value+e):s(t.value.slice(0,-1)):t.onEnter(t)},c=function(e){const t=e.keyValue==r;let l=t?o.enterKey.color:o.key.color;e.isPressed&&!t?l=o.keyPressed.color:e.isHover&&!t&&(l=o.keyHover.color),e.color=l,t&&(e.opacity=e.isPressed?.8:1)};t.setValue=function(e,t=0){s(e,t)},t.getValue=function(){return t.value},t.clear=function(e=0){s("",e)},t.setTitleText=function(e){t.titleText=e,t.aria={label:e||"Numeric keyboard"},t.lblTitle&&(t.lblTitle.plainText=e,t.lblTitle.visible=e?1:0)},t.props(o.box),t.tabIndex=0,t.role="group",t.aria={label:t.titleText||"Numeric keyboard"},t.setFocusRing(o.focus.ringColor);const y=n[t.keyLayout]||n.wide,g=Math.max.apply(null,y.map(function(e){return e.length}));t.layout=VGroup({hug:1,align:"center top",gap:0,padding:o.layout.padding,position:"relative",clipContent:0}),1==t.showValue&&(t.lblTitle=Label({...o.title,textAlign:"center"}),t.setTitleText(t.titleText),t.lblValue=Label({...o.value,textAlign:"center",css:{lineHeight:o.value.height+"px",minHeight:o.value.height+"px",whiteSpace:"nowrap"}}),t.lblValue.css={marginBottom:o.layout.gap+"px"}),VGroup({hug:1,align:"left top",gap:o.key.gap,clipContent:0}),y.forEach(function(e){HGroup({hug:1,align:"left top",gap:o.key.gap,clipContent:0}),e.forEach(function(n,a){const s=a==e.length-1&&e.length<g?g-e.length+1:1,y=s*o.key.size+(s-1)*o.key.gap;t.keyList.push(function(e,t){const n=e==r,a=Label({width:t,height:o.key.size,round:o.key.round,border:o.key.border,borderColor:o.key.borderColor,fontSize:o.key.fontSize,textColor:n?o.enterKey.textColor:o.key.textColor,clickable:1,cursor:"pointer",role:"button",aria:{label:e==l?"Delete":n?"Enter":e},css:{display:"flex",alignItems:"center",justifyContent:"center",flexShrink:"0"}});a.text=i[e]||e,a.keyValue=e,a.isHover=0,a.isPressed=0,a.onHoverChange(function(e,t){a.isHover=t,t||(a.isPressed=0),c(a)}),a.on("pointerdown",function(){a.isPressed=1,c(a)});const s=function(){a.isPressed=0,c(a)};return a.on("pointerup",s),a.on("pointercancel",s),a.on("click",function(){u(e)}),c(a),a}(n,y))}),endGroup()}),endGroup(),endGroup(),t.on("keydown",function(e,t){if(!(t.ctrlKey||t.metaKey||t.altKey))return/^[0-9]$/.test(t.key)?(u(t.key),void t.preventDefault()):"Backspace"==t.key||"Delete"==t.key?(u(l),void t.preventDefault()):void("Enter"==t.key&&(t.preventDefault(),t.repeat||u(r)))});const d=t.value;return t.value="",s(d,1),a(),endObject(t)};NumericKeyboard.styles={light:NumericKeyboardDefaults.style,dark:{title:{fontSize:18,textColor:"rgba(255, 255, 255, 0.5)"},value:{fontSize:35,textColor:"rgba(255, 255, 255, 0.92)",fontFamily:"opensans-bold",height:50},key:{size:80,gap:10,round:14,color:"#2B2D31",border:1,borderColor:"rgba(255, 255, 255, 0.18)",fontSize:35,textColor:"rgba(255, 255, 255, 0.9)"},keyHover:{color:"#33353A"},keyPressed:{color:"#3C3E44"},enterKey:{color:"#F2C14E",textColor:"#1B2632"},focus:{ringColor:"rgba(95, 179, 181, 0.7)"}}},NumericKeyboard.styles.classic=NumericKeyboard.styles.light;
@@ -1,2 +1,2 @@
1
1
  /* Bismillah */
2
- "use strict";const PageControlDefaults={key:"0",width:600,height:400,pages:[],value:null,transition:"slide",motion:.3,easing:"cubic-bezier(0.2, 0, 0, 1)",loop:0,swipe:1,swipeThreshold:.2,keyboard:1,dots:0,arrows:0,autoPlay:0,pageScroll:0,enabled:1,ariaLabel:"Pages",onBeforeChange:function(e,t,o){},onChange:function(e){},onClose:function(e,t){},style:{box:{color:"transparent",border:0,borderColor:"transparent",round:0},page:{color:"transparent"},dots:{size:8,gap:8,bottom:12,color:Black(.25),activeColor:"#141414",activeWidth:20,motion:.25},arrows:{size:36,side:10,color:White(.9),hoverColor:White(1),iconColor:"#141414",iconSize:18,round:100,shadow:"0 2px 8px rgba(0, 0, 0, 0.15)",disabledOpacity:.3},focus:{outlineColor:Black(0)},disabled:{opacity:.5}}},PageControl=function(e={}){mergeIntoIfMissing(e,PageControlDefaults);const t=e.style.box;e.color=t.color,e.border=t.border,e.borderColor=t.borderColor,e.round=t.round;const o=e.pages,n=e.value;e.pages=[],e.value=null;let r=startObject(e);const a=r.style,i="slide-vertical"===r.transition,s="fade"===r.transition,l="slide"===r.transition||i;let c=[],u=[],p=[],f=null,d=null,g=0,h=null;const b="0.15s";r.previousValue=null;const v=function(e){return c.find(function(t){return t.key===e})||null},w=function(e){return c.findIndex(function(t){return t.key===e})},x=function(){return r.motion>0?r.motion:0},y=function(e,t=0){return i?"translate(0, calc("+100*-e+"% + "+t+"px))":"translate(calc("+100*-e+"% + "+t+"px), 0)"},m=function(e){const t=e?x():0;r.track.css.transition=t>0?"transform "+t+"s "+r.easing:"none"},k=function(e=1){const t=Math.max(0,w(r.value));!function(e,t){if(l)return m(t),void(r.track.css.transform=y(e));const o=s&&t&&x()>0?"opacity "+x()+"s "+r.easing:"none";c.forEach(function(t,n){const r=n===e;t.page.css.transition=o,t.page.css.opacity=r?"1":"0",t.page.zIndex=r?1:0})}(t,e),function(e){c.forEach(function(t,o){const n=o===e;t.page.aria={hidden:n?"false":"true"},n?t.page.elem.removeAttribute("inert"):t.page.elem.setAttribute("inert",""),t.page.css.pointerEvents=n?"":"none"})}(t),P(),B()},P=function(){if(1!=r.dots)return;const e=w(r.value);u.forEach(function(t,o){const n=o===e;t.color=n?a.dots.activeColor:a.dots.color,t.width=n?a.dots.activeWidth:a.dots.size,t.aria={current:n?"true":"false"}})},C=function(e,t){const o=t&&1==r.enabled;e.css.opacity=o?"1":String(a.arrows.disabledOpacity),e.css.pointerEvents=o?"auto":"none",e.aria={disabled:t?"false":"true"}},B=function(){if(1!=r.arrows)return;const e=w(r.value),t=1==r.loop&&c.length>1;C(r.btnPrev,t||e>0),C(r.btnNext,t||e<c.length-1),r.btnPrev.visible=c.length>1?1:0,r.btnNext.visible=c.length>1?1:0},I=function(){1==r.dots&&(u.forEach(function(e){e.remove()}),u=[],c.forEach(function(e){let t=null;createIn(r.dotsBox,function(){t=Box({width:a.dots.size,height:a.dots.size,color:a.dots.color,round:100,clickable:1})}),t.shrink=0,t.cursor="pointer",t.css.transition="width "+a.dots.motion+"s, background-color "+a.dots.motion+"s",t.role="button",t.aria={label:"Page "+String(e.key)},t.on("click",function(t,o){o.stopPropagation(),r.open(e.key)}),u.push(t)}),r.dotsBox.visible=c.length>1?1:0,P())},S=function(){D(),r.autoPlay>0&&!(c.length<2)&&(d=r.every(1e3*r.autoPlay,function(){if(g||h&&h.active||1!=r.enabled)return;const e=w(r.value);r.open(c[(e+1)%c.length].key)}))},D=function(){d&&d(),d=null},z=function(e,t){if(!h||t.pointerId!==h.id)return;const o=h.active,n=h.x-h.startX,a=h.y-h.startY,s=Math.max(1,Date.now()-h.time);if(h=null,r.track.cursor="",!o)return;t.preventDefault(),r._swiped=1,r.after(50,function(){r._swiped=0});const l=w(r.value),u=function(e,t,o){const n=i?r.elem.clientHeight:r.elem.clientWidth,a=Math.abs(t)/o;let s=e;return(Math.abs(t)>n*r.swipeThreshold||a>.5)&&(s=t<0?e+1:e-1),1==r.loop&&(s=(s+c.length)%c.length),Math.max(0,Math.min(c.length-1,s))}(l,i?a:n,s);u!==l?r.open(c[u].key):k(1)};r.addPage=function(e,t=-1){const o=v(e);if(o)return console.warn("PageControl: A page with this key exists: "+e),o.page;let n=null;createIn(r.track,function(){n=Box({width:"100%",height:"100%",color:a.page.color})}),n.css={position:l?"relative":"absolute",left:"0px",top:"0px",flex:"0 0 100%",boxSizing:"border-box"},n.role="group",n.aria={label:String(e)},n.pageKey=e,1==r.pageScroll&&(n.scrollY=1),l||(n.css.opacity="0");const i={key:e,page:n};return t>=0&&t<c.length?(r.track.elem.insertBefore(n.elem,c[t].page.elem),c.splice(t,0,i)):c.push(i),r.pages=r.getKeys(),null===r.value&&(r.value=e),I(),k(0),S(),n},r.startPage=function(e){const t=r.getPage(e)||r.addPage(e);return p.push(getDefaultContainerBox()),t.wrapper&&t.wrapper.remove(),setDefaultContainerBox(t),t.wrapper=VGroup({width:"100%",height:1==r.pageScroll?"auto":"100%",align:"left top",gap:0,position:"relative"}),t.wrapper.css={alignItems:"stretch",minHeight:"100%"},t.wrapper},r.endPage=function(){endGroup();const e=p.pop();e&&setDefaultContainerBox(e)},r.getPage=function(e=r.value){const t=v(e);return t?t.page:null},r.getKeys=function(){return c.map(function(e){return e.key})},r.getIndex=function(e=r.value){return w(e)},r.getCount=function(){return c.length},r.open=function(e,t=0){if(!v(e))return console.warn("PageControl: No page with this key: "+e),0;if(r.value===e)return k(1),1;if(!1===r.onBeforeChange(r,r.value,e))return k(1),0;const o=r.value;return r.previousValue=o,r.value=e,k(1),function(e){if(f&&f(),f=null,null==e)return;const t="none"===r.transition?0:1e3*x()+30;f=r.after(t,function(){f=null,r.onClose(r,e)})}(o),r.autoPlay>0&&S(),t||r.onChange(r),1},r.openIndex=function(e,t=0){const o=c[e];return o?r.open(o.key,t):0},r.next=function(e=0){const t=w(r.value);if(t<0)return 0;let o=t+1;if(o>=c.length){if(1!=r.loop)return 0;o=0}return r.open(c[o].key,e)},r.previous=function(e=0){const t=w(r.value);if(t<0)return 0;let o=t-1;if(o<0){if(1!=r.loop)return 0;o=c.length-1}return r.open(c[o].key,e)},r.isFirst=function(){return 0===w(r.value)},r.isLast=function(){return w(r.value)===c.length-1},r.removePage=function(e,t=0){const o=w(e);if(o<0)return 0;const n=r.value===e;if(c[o].page.remove(),c.splice(o,1),r.pages=r.getKeys(),n){const t=c[o]||c[o-1]||null;r.previousValue=e,r.value=t?t.key:null}return I(),k(0),S(),n&&!t&&r.onChange(r),1},r.clear=function(){c.forEach(function(e){e.page.remove()}),c=[],r.pages=[],r.value=null,r.previousValue=null,I(),k(0),D()},r.setLoop=function(e){r.loop=basic.isOn(e)?1:0,B()},r.setAutoPlay=function(e){r.autoPlay=Number(e)||0,S()},r.setEnabled=function(e){r.enabled=basic.isOn(e)?1:0,r.css.opacity=1==r.enabled?"1":String(a.disabled.opacity),r.tabIndex=1==r.enabled&&1==r.keyboard?0:-1,B()},r.refresh=function(){k(0)},r.focus=function(){r.elem.focus({preventScroll:!0})},r.clipContent=1,r.clickable=1;if(r.css={outline:"none",touchAction:l&&1==r.swipe?i?"pan-x":"pan-y":""},r.role="region",r.aria={label:r.ariaLabel},r.track=Box(0,0,"100%","100%",{color:"transparent",clickable:1}),l&&(r.track.elem.style.display="flex",r.track.css.flexDirection=i?"column":"row"),r.track.css.userSelect="none",r.track.css.overflow="visible",1==r.dots&&(r.dotsBox=HGroup({width:"auto",height:"auto",align:"center center",gap:a.dots.gap,padding:[6,4]}),r.dotsBox.css={position:"absolute",left:"50%",top:"auto",bottom:a.dots.bottom+"px",transform:"translateX(-50%)",pointerEvents:"auto"},r.dotsBox.zIndex=5,r.dotsBox.role="group",r.dotsBox.aria={label:"Page dots"},endGroup()),1==r.arrows){const e=function(e){const t="left"===e,o=Label({text:PageControl.getArrowSvg(e,a.arrows.iconColor,a.arrows.iconSize),width:a.arrows.size,height:a.arrows.size,color:a.arrows.color,round:a.arrows.round,clickable:1});return o.css={position:"absolute",top:"50%",transform:"translateY(-50%)"},o.elem.style.display="flex",o.css={alignItems:"center",justifyContent:"center",transition:"background-color 0.15s, opacity "+b},o.lineHeight="0",o.cursor="pointer",o.zIndex=5,o.boxShadow=a.arrows.shadow,o.role="button",o.aria={label:t?"Previous page":"Next page"},t?o.css.left=a.arrows.side+"px":o.css={left:"auto",right:a.arrows.side+"px"},o.on("mouseenter",function(){o.color=a.arrows.hoverColor}),o.on("mouseleave",function(){o.color=a.arrows.color}),o.on("pointerdown",function(e,t){t.stopPropagation()}),o};r.btnPrev=e("left"),r.btnNext=e("right"),r.btnPrev.on("click",function(e,t){t.stopPropagation(),r.previous()}),r.btnNext.on("click",function(e,t){t.stopPropagation(),r.next()})}return r.on("pointerdown",function(e,t){1!=r.swipe||!l||1!=r.enabled||c.length<2||"mouse"===t.pointerType&&0!==t.button||(h={startX:t.clientX,startY:t.clientY,x:t.clientX,y:t.clientY,time:Date.now(),active:0,id:t.pointerId})}),r.on("pointermove",function(e,t){if(!h||t.pointerId!==h.id)return;h.x=t.clientX,h.y=t.clientY;const o=h.x-h.startX,n=h.y-h.startY;if(!h.active){const e=i?Math.abs(n):Math.abs(o),a=i?Math.abs(o):Math.abs(n);if(e<6||e<a)return;h.active=1,m(0),r.track.cursor="grabbing",function(e){if(r.elem.setPointerCapture)try{r.elem.setPointerCapture(e)}catch(e){}}(t.pointerId)}t.preventDefault();const a=w(r.value);let s=i?n:o;const l=0===a&&s>0,u=a===c.length-1&&s<0;(l||u)&&1!=r.loop&&(s/=3),r.track.css.transform=y(a,s)}),r.on("pointerup",z),r.on("pointercancel",z),r.on("keydown",function(e,t){if(1!=r.keyboard||1!=r.enabled)return;if(t.target!==r.elem)return;const o=i?"ArrowUp":"ArrowLeft",n=i?"ArrowDown":"ArrowRight";return t.key===n?(t.preventDefault(),void r.next()):t.key===o?(t.preventDefault(),void r.previous()):"Home"===t.key?(t.preventDefault(),void(c[0]&&r.open(c[0].key))):void("End"===t.key&&(t.preventDefault(),c.length&&r.open(c[c.length-1].key)))}),r.on("mouseenter",function(){g=1}),r.on("mouseleave",function(){g=0}),r.on("focus",function(){r.boxShadow="inset 0 0 0 2px "+a.focus.outlineColor}),r.on("blur",function(){r.boxShadow="none"}),r.listenTo(r.elem,"click",function(e,t){r._swiped&&(t.stopPropagation(),t.preventDefault(),r._swiped=0)},!0),(o||[]).forEach(function(e){r.addPage(e)}),null!=n&&v(n)&&(r.value=n),r.setEnabled(r.enabled),k(0),S(),endObject(r)};PageControl.getArrowSvg=function(e,t,o){return'<svg xmlns="http://www.w3.org/2000/svg" width="'+o+'" height="'+o+'" viewBox="0 0 24 24" fill="none" stroke="'+t+'" stroke-width="2.4" stroke-linecap="round" stroke-linejoin="round"><path d="'+("left"===e?"m15 6-6 6 6 6":"m9 6 6 6-6 6")+'"/></svg>'};
2
+ "use strict";const PageControlDefaults={key:"0",width:600,height:400,pages:[],value:null,transition:"slide",motion:.3,easing:"cubic-bezier(0.2, 0, 0, 1)",loop:0,swipe:1,swipeThreshold:.2,keyboard:1,dots:0,arrows:0,autoPlay:0,pageScroll:0,enabled:1,ariaLabel:"Pages",onBeforeChange:function(e,t,o){},onChange:function(e){},onClose:function(e,t){},style:{box:{color:"transparent",border:0,borderColor:"transparent",round:0},page:{color:"transparent"},dots:{size:8,gap:8,bottom:12,color:Black(.25),activeColor:"#141414",activeWidth:20,motion:.25},arrows:{size:36,side:10,color:White(.9),hoverColor:White(1),iconColor:"#141414",iconSize:18,round:100,shadow:"0 2px 8px rgba(0, 0, 0, 0.15)",disabledOpacity:.3},focus:{outlineColor:Black(0)},disabled:{opacity:.5}}},PageControl=function(e={}){mergeIntoIfMissing(e,PageControlDefaults);const t=e.style.box;e.color=t.color,e.border=t.border,e.borderColor=t.borderColor,e.round=t.round;const o=e.pages,n=e.value;e.pages=[],e.value=null;let r=startObject(e);const i=r.style,a="slide-vertical"===r.transition,s="fade"===r.transition,l="slide"===r.transition||a;let c=[],u=[],p=[],f=null,d=null,g=0,h=null;const b="0.15s";r.previousValue=null;const v=function(e){return c.find(function(t){return t.key===e})||null},w=function(e){return c.findIndex(function(t){return t.key===e})},y=function(){return r.motion>0?r.motion:0},x=function(e,t=0){return a?"translate(0, calc("+100*-e+"% + "+t+"px))":"translate(calc("+100*-e+"% + "+t+"px), 0)"},m=function(e){const t=e?y():0;r.track.css.transition=t>0?"transform "+t+"s "+r.easing:"none"},k=function(e=1){const t=Math.max(0,w(r.value));!function(e,t){if(l)return m(t),void(r.track.css.transform=x(e));const o=s&&t&&y()>0?"opacity "+y()+"s "+r.easing:"none";c.forEach(function(t,n){const r=n===e;t.page.css.transition=o,t.page.css.opacity=r?"1":"0",t.page.zIndex=r?1:0})}(t,e),function(e){c.forEach(function(t,o){const n=o===e;t.page.aria={hidden:n?"false":"true"},n?t.page.elem.removeAttribute("inert"):t.page.elem.setAttribute("inert",""),t.page.css.pointerEvents=n?"":"none"})}(t),P(),B()},P=function(){if(1!=r.dots)return;const e=w(r.value);u.forEach(function(t,o){const n=o===e;t.color=n?i.dots.activeColor:i.dots.color,t.width=n?i.dots.activeWidth:i.dots.size,t.aria={current:n?"true":"false"}})},C=function(e,t){const o=t&&1==r.enabled;e.css.opacity=o?"1":String(i.arrows.disabledOpacity),e.css.pointerEvents=o?"auto":"none",e.aria={disabled:t?"false":"true"}},B=function(){if(1!=r.arrows)return;const e=w(r.value),t=1==r.loop&&c.length>1;C(r.btnPrev,t||e>0),C(r.btnNext,t||e<c.length-1),r.btnPrev.visible=c.length>1?1:0,r.btnNext.visible=c.length>1?1:0},I=function(){1==r.dots&&(u.forEach(function(e){e.remove()}),u=[],c.forEach(function(e){let t=null;createIn(r.dotsBox,function(){t=Box({width:i.dots.size,height:i.dots.size,color:i.dots.color,round:100,clickable:1})}),t.shrink=0,t.cursor="pointer",t.css.transition="width "+i.dots.motion+"s, background-color "+i.dots.motion+"s",t.role="button",t.aria={label:"Page "+String(e.key)},t.on("click",function(t,o){o.stopPropagation(),1==r.enabled&&r.open(e.key)}),u.push(t)}),r.dotsBox.visible=c.length>1?1:0,P())},S=function(){D(),r.autoPlay>0&&!(c.length<2)&&(d=r.every(1e3*r.autoPlay,function(){if(g||h&&h.active||1!=r.enabled)return;const e=w(r.value);r.open(c[(e+1)%c.length].key)}))},D=function(){d&&d(),d=null},z=function(e,t){if(!h||t.pointerId!==h.id)return;const o=h.active,n=h.x-h.startX,i=h.y-h.startY,s=Math.max(1,Date.now()-h.time);if(h=null,r.track.cursor="",!o)return;t.preventDefault(),r._swiped=1,r.after(50,function(){r._swiped=0});const l=w(r.value),u=function(e,t,o){const n=a?r.elem.clientHeight:r.elem.clientWidth,i=Math.abs(t)/o;let s=e;return(Math.abs(t)>n*r.swipeThreshold||i>.5)&&(s=t<0?e+1:e-1),1==r.loop&&(s=(s+c.length)%c.length),Math.max(0,Math.min(c.length-1,s))}(l,a?i:n,s);u!==l?r.open(c[u].key):k(1)};r.addPage=function(e,t=-1){const o=v(e);if(o)return console.warn("PageControl: A page with this key exists: "+e),o.page;let n=null;createIn(r.track,function(){n=Box({width:"100%",height:"100%",color:i.page.color})}),n.css={position:l?"relative":"absolute",left:"0px",top:"0px",flex:"0 0 100%",boxSizing:"border-box"},n.role="group",n.aria={label:String(e)},n.pageKey=e,1==r.pageScroll&&(n.scrollY=1),l||(n.css.opacity="0");const a={key:e,page:n};return t>=0&&t<c.length?(r.track.elem.insertBefore(n.elem,c[t].page.elem),c.splice(t,0,a)):c.push(a),r.pages=r.getKeys(),null===r.value&&(r.value=e),I(),k(0),S(),n},r.startPage=function(e){const t=r.getPage(e)||r.addPage(e);return p.push(getDefaultContainerBox()),t.wrapper&&t.wrapper.remove(),setDefaultContainerBox(t),t.wrapper=VGroup({width:"100%",height:1==r.pageScroll?"auto":"100%",align:"left top",gap:0,position:"relative"}),t.wrapper.css={alignItems:"stretch",minHeight:"100%"},t.wrapper},r.endPage=function(){endGroup();const e=p.pop();e&&setDefaultContainerBox(e)},r.getPage=function(e=r.value){const t=v(e);return t?t.page:null},r.getKeys=function(){return c.map(function(e){return e.key})},r.getIndex=function(e=r.value){return w(e)},r.getCount=function(){return c.length},r.open=function(e,t=0){if(!v(e))return console.warn("PageControl: No page with this key: "+e),0;if(r.value===e)return k(1),1;if(!1===r.onBeforeChange(r,r.value,e))return k(1),0;const o=r.value;return r.previousValue=o,r.value=e,k(1),function(e){if(f&&f(),f=null,null==e)return;const t="none"===r.transition?0:1e3*y()+30;f=r.after(t,function(){f=null,r.onClose(r,e)})}(o),r.autoPlay>0&&S(),t||r.onChange(r),1},r.openIndex=function(e,t=0){const o=c[e];return o?r.open(o.key,t):0},r.next=function(e=0){const t=w(r.value);if(t<0)return 0;let o=t+1;if(o>=c.length){if(1!=r.loop)return 0;o=0}return r.open(c[o].key,e)},r.previous=function(e=0){const t=w(r.value);if(t<0)return 0;let o=t-1;if(o<0){if(1!=r.loop)return 0;o=c.length-1}return r.open(c[o].key,e)},r.isFirst=function(){return 0===w(r.value)},r.isLast=function(){return w(r.value)===c.length-1},r.removePage=function(e,t=0){const o=w(e);if(o<0)return 0;const n=r.value===e;if(c[o].page.remove(),c.splice(o,1),r.pages=r.getKeys(),n){const t=c[o]||c[o-1]||null;r.previousValue=e,r.value=t?t.key:null}return I(),k(0),S(),n&&!t&&r.onChange(r),1},r.clear=function(){c.forEach(function(e){e.page.remove()}),c=[],r.pages=[],r.value=null,r.previousValue=null,I(),k(0),D()},r.setLoop=function(e){r.loop=basic.isOn(e)?1:0,B()},r.setAutoPlay=function(e){r.autoPlay=Number(e)||0,S()},r.setEnabled=function(e){r.enabled=basic.isOn(e)?1:0,r.css.opacity=1==r.enabled?"1":String(i.disabled.opacity),r.tabIndex=1==r.enabled&&1==r.keyboard?0:-1,B()},r.refresh=function(){k(0)},r.focus=function(){r.elem.focus({preventScroll:!0})},r.clipContent=1,r.clickable=1;if(r.css={outline:"none",touchAction:l&&1==r.swipe?a?"pan-x":"pan-y":""},r.role="region",r.aria={label:r.ariaLabel},r.track=Box(0,0,"100%","100%",{color:"transparent",clickable:1}),l&&(r.track.elem.style.display="flex",r.track.css.flexDirection=a?"column":"row"),r.track.css.userSelect="none",r.track.css.overflow="visible",1==r.dots&&(r.dotsBox=HGroup({width:"auto",height:"auto",align:"center center",gap:i.dots.gap,padding:[6,4]}),r.dotsBox.css={position:"absolute",left:"50%",top:"auto",bottom:i.dots.bottom+"px",transform:"translateX(-50%)",pointerEvents:"auto"},r.dotsBox.zIndex=5,r.dotsBox.role="group",r.dotsBox.aria={label:"Page dots"},endGroup()),1==r.arrows){const e=function(e){const t="left"===e,o=Label({text:PageControl.getArrowSvg(e,i.arrows.iconColor,i.arrows.iconSize),width:i.arrows.size,height:i.arrows.size,color:i.arrows.color,round:i.arrows.round,clickable:1});return o.css={position:"absolute",top:"50%",transform:"translateY(-50%)"},o.elem.style.display="flex",o.css={alignItems:"center",justifyContent:"center",transition:"background-color 0.15s, opacity "+b},o.lineHeight="0",o.cursor="pointer",o.zIndex=5,o.boxShadow=i.arrows.shadow,o.role="button",o.aria={label:t?"Previous page":"Next page"},t?o.css.left=i.arrows.side+"px":o.css={left:"auto",right:i.arrows.side+"px"},o.on("mouseenter",function(){o.color=i.arrows.hoverColor}),o.on("mouseleave",function(){o.color=i.arrows.color}),o.on("pointerdown",function(e,t){t.stopPropagation()}),o};r.btnPrev=e("left"),r.btnNext=e("right"),r.btnPrev.on("click",function(e,t){t.stopPropagation(),r.previous()}),r.btnNext.on("click",function(e,t){t.stopPropagation(),r.next()})}return r.on("pointerdown",function(e,t){1!=r.swipe||!l||1!=r.enabled||c.length<2||"mouse"===t.pointerType&&0!==t.button||(h={startX:t.clientX,startY:t.clientY,x:t.clientX,y:t.clientY,time:Date.now(),active:0,id:t.pointerId})}),r.on("pointermove",function(e,t){if(!h||t.pointerId!==h.id)return;if("mouse"===t.pointerType&&0===t.buttons)return void function(){const e=h.active;h=null,r.track.cursor="",e&&k(1)}();h.x=t.clientX,h.y=t.clientY;const o=h.x-h.startX,n=h.y-h.startY;if(!h.active){const e=a?Math.abs(n):Math.abs(o),i=a?Math.abs(o):Math.abs(n);if(e<6||e<i)return;h.active=1,m(0),r.track.cursor="grabbing",function(e){if(r.elem.setPointerCapture)try{r.elem.setPointerCapture(e)}catch(e){}}(t.pointerId)}t.preventDefault();const i=w(r.value);let s=a?n:o;const l=0===i&&s>0,u=i===c.length-1&&s<0;(l||u)&&1!=r.loop&&(s/=3),r.track.css.transform=x(i,s)}),r.on("pointerup",z),r.on("pointercancel",z),r.on("keydown",function(e,t){if(1!=r.keyboard||1!=r.enabled)return;if(t.target!==r.elem)return;const o=a?"ArrowUp":"ArrowLeft",n=a?"ArrowDown":"ArrowRight";return t.key===n?(t.preventDefault(),void r.next()):t.key===o?(t.preventDefault(),void r.previous()):"Home"===t.key?(t.preventDefault(),void(c[0]&&r.open(c[0].key))):void("End"===t.key&&(t.preventDefault(),c.length&&r.open(c[c.length-1].key)))}),r.on("mouseenter",function(){g=1}),r.on("mouseleave",function(){g=0}),r.on("focus",function(){r.boxShadow=r.elem.matches(":focus-visible")?"inset 0 0 0 2px "+i.focus.outlineColor:"none"}),r.on("blur",function(){r.boxShadow="none"}),r.listenTo(r.elem,"click",function(e,t){r._swiped&&(t.stopPropagation(),t.preventDefault(),r._swiped=0)},!0),(o||[]).forEach(function(e){r.addPage(e)}),null!=n&&v(n)&&(r.value=n),r.setEnabled(r.enabled),k(0),S(),endObject(r)};PageControl.getArrowSvg=function(e,t,o){return'<svg xmlns="http://www.w3.org/2000/svg" width="'+o+'" height="'+o+'" viewBox="0 0 24 24" fill="none" stroke="'+t+'" stroke-width="2.4" stroke-linecap="round" stroke-linejoin="round"><path d="'+("left"===e?"m15 6-6 6 6 6":"m9 6 6 6-6 6")+'"/></svg>'};
@@ -0,0 +1,2 @@
1
+ /* Bismillah */
2
+ "use strict";const PasswordFieldDefaults={required:1,requiredText:"Password must be entered",type:"password",titleText:"PASSWORD",placeholder:"Enter your password",warningText:"",warningColor:"#E5885E",maxLength:25,showPassword:0,showShowPasswordButton:1,showPasswordIconFile:"data:image/svg+xml;utf8,"+encodeURIComponent('<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48" preserveAspectRatio="none" fill="none" stroke="#141414" stroke-width="3" stroke-linecap="round" stroke-linejoin="round"><path d="M3.5 23C9 13 15.5 9.5 24 9.5S39 13 44.5 23C39 33 32.5 36.5 24 36.5S9 33 3.5 23Z"/><circle cx="24" cy="23" r="6.5"/></svg>'),hidePasswordIconFile:"data:image/svg+xml;utf8,"+encodeURIComponent('<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48" preserveAspectRatio="none" fill="none" stroke="#141414" stroke-width="3" stroke-linecap="round" stroke-linejoin="round"><path d="M3.5 23C9 13 15.5 9.5 24 9.5S39 13 44.5 23C39 33 32.5 36.5 24 36.5S9 33 3.5 23Z"/><circle cx="24" cy="23" r="6.5"/><path d="M6 6.5L41 42"/></svg>'),eyeIconSize:"",showPasswordHintText:"Show Password",hidePasswordHintText:"Hide Password",minLength:6,minLengthWarningText:"Password must be at least 6 characters",mustUseNumber:1,mustUseNumberWarningText:"Password must contain at least one number",mustUseLetter:1,mustUseLetterWarningText:"Password must contain at least one letter",mustUseUppercase:0,mustUseUppercaseWarningText:"Password must contain at least one uppercase letter",mustUseLowercase:0,mustUseLowercaseWarningText:"Password must contain at least one lowercase letter",mustUseSpecialChar:0,mustUseSpecialCharWarningText:"Password must contain at least one special character",invertIconColor:0},PasswordField=function(e={}){basic.applyStylePackage(e,TextField.styles,TextFieldDefaults),mergeIntoIfMissing(e,PasswordFieldDefaults),e.showLeftBox=1;let t=startExtendedObject(TextField,e);t.isValid=function(){const e=t.getValue();return e.length<t.minLength?(t.setWarningText(t.minLengthWarningText),0):1!=t.mustUseNumber||/[0-9]/.test(e)?1!=t.mustUseLetter||/[a-zA-Z]/.test(e)?1!=t.mustUseUppercase||/[A-Z]/.test(e)?1!=t.mustUseLowercase||/[a-z]/.test(e)?1!=t.mustUseSpecialChar||/[^a-zA-Z0-9]/.test(e)?1:(t.setWarningText(t.mustUseSpecialCharWarningText),0):(t.setWarningText(t.mustUseLowercaseWarningText),0):(t.setWarningText(t.mustUseUppercaseWarningText),0):(t.setWarningText(t.mustUseLetterWarningText),0):(t.setWarningText(t.mustUseNumberWarningText),0)},t.setShowPassword=function(e){const s=0!=e;t.showPassword=s?1:0,t.input.inputElement.type=s?"text":"password",t.btnShowPassword.tooltip&&t.btnShowPassword.tooltip.setHintText(s?t.hidePasswordHintText:t.showPasswordHintText),t.btnShowPassword.load(s?t.hidePasswordIconFile:t.showPasswordIconFile)},t.refresh=function(){},t.input.inputElement.type="password";const s="above"===t.titlePosition&&"icon"===t.warningBallType;AutoLayout({align:"right center",padding:s?[0,0,t.rightPadding-20,0]:[10,0]}),t.leftBox.add(that);const o=t.inputHeight>=40?32:Math.round(.6*t.inputHeight),n=t.eyeIconSize||o;t.btnShowPassword=Icon({width:n,height:n,visible:t.showShowPasswordButton}),that.clickable=1,that.cursor="pointer",1!=t.invertIconColor&&1!=t.selectStyle.invertIconColor||(t.btnShowPassword.css.filter="invert(100%)"),endAutoLayout();const r=t.tooltipStyle;return"undefined"!=typeof Tooltip&&(t.btnShowPassword.tooltip=Tooltip({target:t.btnShowPassword,hintText:"",hintPosition:"left",lbl_border:r.border,lbl_color:r.color||r.hintColor,lbl_textColor:r.textColor,lbl_borderColor:r.borderColor,lbl_fontSize:r.fontSize,lbl_round:r.round}),t.own(t.btnShowPassword.tooltip)),t.btnShowPassword.on("click",function(){t.setShowPassword(1==t.showPassword?0:1)}),t.setShowPassword(t.showPassword),t.checkInputValue(),endExtendedObject(t)};
@@ -0,0 +1,2 @@
1
+ /* Bismillah */
2
+ "use strict";const PhoneFieldDefaults={required:1,titleText:"PHONE NUMBER",placeholder:"(auto)",warningText:"Invalid phone number format",warningColor:"#E5885E",countryCode:"+90",phoneMask:" (___) ___-____",unitText:"TR"},PhoneField=function(e={}){basic.applyStylePackage(e,TextField.styles,TextFieldDefaults),mergeIntoIfMissing(e,PhoneFieldDefaults),0==e.createInput&&(e.createInput=1);const t=startExtendedObject(TextField,e),n=t.input.inputElement;let u=t.countryCode;const o=function(){return t.countryCode+t.phoneMask},i=function(){if(!n)return;const e=n.value.indexOf("_");if(n.selectionStart===e)return;const u=-1!==e?e:n.value.length;n.setSelectionRange(u,u),t.after(0,()=>{n.setSelectionRange(u,u)})},r=function(e){const n=[u,t.countryCode].filter(function(t){return"string"==typeof t&&t.length>0&&0===e.indexOf(t)});return n.sort(function(e,t){return t.length-e.length}),n.length?e.substring(n[0].length):e},l=function(e,t){let n=0,u="";for(let o=0;o<e.length;o++)"_"===e[o]?n<t.length?(u+=t[n],n++):u+="_":u+=e[o];return u},a=function(e){let n=String(e).replace(/[^0-9]/g,"");const u=(t.phoneMask.match(/_/g)||[]).length,o=String(t.countryCode||"").replace(/[^0-9]/g,"");return n.length>u&&o&&0===n.indexOf("00"+o)&&(n=n.substring(2+o.length)),n.length>u&&o&&0===n.indexOf(o)&&(n=n.substring(o.length)),n.length>u&&"0"===n[0]&&(n=n.substring(1)),n.substring(0,u)},c=t.setValue;if(t.applyFormattedValueToInput=function(){let e=r(n.value).replace(/[^0-9]/g,"");const a=(t.phoneMask.match(/_/g)||[]).length;e=e.substring(0,a),c(l(o(),e)),u=t.countryCode,i()},t.setValue=function(e){const n=String(e??"");""!==n?(c(l(o(),a(r(n)))),u=t.countryCode):c("")},t.setPhoneMask=function(e){t.phoneMask=e,t.refreshInput()},t.setCountryCode=function(e){t.countryCode=e,t.refreshInput()},t.getValue=function(){const e=t.input.text;return e===o()?"":e},t.isValid=function(){const e=t.getValue();return e&&-1===e.indexOf("_")?1:0},t.refreshInput=function(){t.applyFormattedValueToInput(),t.checkIfInputIsRequiredAndEmpty(),t.showWarningIfNotValid(t.isValid()),i(),t.value=n.value},t.fillAutoPlaceholder=function(){t.setPlaceholder(t.countryCode+t.phoneMask.replace(/_/g,()=>Math.floor(10*Math.random())))},"(auto)"==t.placeholder&&t.fillAutoPlaceholder(),1==t.createInput){t.focusFunc=function(){t.paintFocus(1),""===n.value.trim()&&(n.value=o()),i(),t.checkIfInputIsRequiredAndEmpty(),t.showWarningIfNotValid(t.isValid()),t.onFocus(t)},t.blurFunc=function(){t.paintFocus(0),n.value==o()&&t.setValue(""),t.onBlur(t)};["mousedown","mouseup","click","select"].forEach(function(e){n.addEventListener(e,function(){i()})}),n.addEventListener("keydown",function(e){"Backspace"===e.key&&function(e){const u=n.selectionStart,r=n.value,l=o();if(u<=l.indexOf("_"))return e.preventDefault(),void i();const a=r.slice(0,u),c=r.slice(u);let s=a.length-1;for(;s>=0&&"_"!==l[s];)s--;s>=0&&(n.value=a.substring(0,s)+"_"+a.substring(s+1)+c),e.preventDefault(),i(),t.checkIfInputIsRequiredAndEmpty(),t.showWarningIfNotValid(t.isValid()),t.onChange(t)}(e)}),n.addEventListener("paste",function(e){const n=e.clipboardData?e.clipboardData.getData("text"):"";n&&(e.preventDefault(),c(l(o(),a(n))),i(),t.checkIfInputIsRequiredAndEmpty(),t.showWarningIfNotValid(t.isValid()),t.onChange(t))}),t.inputFunc=function(){t.refreshInput(),t.onChange(t)}}return""!==n.value&&t.setValue(n.value),t.checkInputValue(),endExtendedObject(t)};