@nmorph/nmorph-ui-kit 2.2.12 → 2.2.15

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 (420) hide show
  1. package/README.md +11 -7
  2. package/dist/assets/icons/add-location.svg.js +5 -5
  3. package/dist/assets/icons/aim.svg.js +4 -4
  4. package/dist/assets/icons/alarm-clock.svg.js +4 -4
  5. package/dist/assets/icons/apple.svg.js +3 -3
  6. package/dist/assets/icons/archive.svg.js +4 -4
  7. package/dist/assets/icons/arrow-down.svg.js +3 -3
  8. package/dist/assets/icons/arrow-left.svg.js +3 -3
  9. package/dist/assets/icons/arrow-right.svg.js +3 -3
  10. package/dist/assets/icons/arrow-up.svg.js +3 -3
  11. package/dist/assets/icons/audio.svg.js +3 -3
  12. package/dist/assets/icons/avatar.svg.js +3 -3
  13. package/dist/assets/icons/back.svg.js +4 -4
  14. package/dist/assets/icons/bell-filled.svg.js +3 -3
  15. package/dist/assets/icons/bell.svg.js +5 -5
  16. package/dist/assets/icons/bicycle.svg.js +2 -2
  17. package/dist/assets/icons/bottom-left.svg.js +4 -4
  18. package/dist/assets/icons/bottom-right.svg.js +4 -4
  19. package/dist/assets/icons/bottom.svg.js +3 -3
  20. package/dist/assets/icons/burger.svg.js +3 -3
  21. package/dist/assets/icons/calendar.svg.js +3 -3
  22. package/dist/assets/icons/camera.svg.js +3 -3
  23. package/dist/assets/icons/caret-bottom.svg.js +3 -3
  24. package/dist/assets/icons/caret-left.svg.js +3 -3
  25. package/dist/assets/icons/caret-right.svg.js +3 -3
  26. package/dist/assets/icons/caret-top.svg.js +3 -3
  27. package/dist/assets/icons/cellphone.svg.js +3 -3
  28. package/dist/assets/icons/chat-dot-round.svg.js +4 -4
  29. package/dist/assets/icons/chat-dot-square.svg.js +4 -4
  30. package/dist/assets/icons/chat-line-round.svg.js +4 -4
  31. package/dist/assets/icons/chat-line-square.svg.js +4 -4
  32. package/dist/assets/icons/chat-round.svg.js +3 -3
  33. package/dist/assets/icons/chat-square.svg.js +3 -3
  34. package/dist/assets/icons/check.svg.js +3 -3
  35. package/dist/assets/icons/checked.svg.js +3 -3
  36. package/dist/assets/icons/cherry.svg.js +3 -3
  37. package/dist/assets/icons/chevron-double-down.svg.js +3 -3
  38. package/dist/assets/icons/chevron-down.svg.js +3 -3
  39. package/dist/assets/icons/chrome-filled.svg.js +5 -5
  40. package/dist/assets/icons/circle-check-filled.svg.js +3 -3
  41. package/dist/assets/icons/circle-check.svg.js +4 -4
  42. package/dist/assets/icons/circle-close-filled.svg.js +3 -3
  43. package/dist/assets/icons/circle-close.svg.js +4 -4
  44. package/dist/assets/icons/circle-plus-filled.svg.js +3 -3
  45. package/dist/assets/icons/circle-plus.svg.js +5 -5
  46. package/dist/assets/icons/clock.svg.js +5 -5
  47. package/dist/assets/icons/close.svg.js +3 -3
  48. package/dist/assets/icons/cloudy.svg.js +3 -3
  49. package/dist/assets/icons/code.svg.js +3 -3
  50. package/dist/assets/icons/coffee-cup.svg.js +3 -3
  51. package/dist/assets/icons/coffee.svg.js +3 -3
  52. package/dist/assets/icons/coin.svg.js +5 -5
  53. package/dist/assets/icons/collection-tag.svg.js +3 -3
  54. package/dist/assets/icons/collection.svg.js +4 -4
  55. package/dist/assets/icons/compass.svg.js +4 -4
  56. package/dist/assets/icons/connection.svg.js +4 -4
  57. package/dist/assets/icons/coordinate.svg.js +4 -4
  58. package/dist/assets/icons/copy-document.svg.js +4 -4
  59. package/dist/assets/icons/copy.svg.js +3 -3
  60. package/dist/assets/icons/cpu.svg.js +4 -4
  61. package/dist/assets/icons/credit-card.svg.js +4 -4
  62. package/dist/assets/icons/crop.svg.js +4 -4
  63. package/dist/assets/icons/cross.svg.js +3 -3
  64. package/dist/assets/icons/delete-filled.svg.js +3 -3
  65. package/dist/assets/icons/delete.svg.js +3 -3
  66. package/dist/assets/icons/dessert.svg.js +3 -3
  67. package/dist/assets/icons/discount.svg.js +4 -4
  68. package/dist/assets/icons/doc.svg.js +3 -3
  69. package/dist/assets/icons/document-add.svg.js +3 -3
  70. package/dist/assets/icons/document-checked.svg.js +3 -3
  71. package/dist/assets/icons/document-copy.svg.js +3 -3
  72. package/dist/assets/icons/document-delete.svg.js +3 -3
  73. package/dist/assets/icons/document-remove.svg.js +3 -3
  74. package/dist/assets/icons/document.svg.js +3 -3
  75. package/dist/assets/icons/download.svg.js +3 -3
  76. package/dist/assets/icons/edit-pen.svg.js +3 -3
  77. package/dist/assets/icons/edit.svg.js +4 -4
  78. package/dist/assets/icons/enlarge.svg.js +3 -3
  79. package/dist/assets/icons/error.svg.js +4 -4
  80. package/dist/assets/icons/exit-square.svg.js +4 -4
  81. package/dist/assets/icons/exit.svg.js +4 -4
  82. package/dist/assets/icons/expand.svg.js +3 -3
  83. package/dist/assets/icons/eye-blocked.svg.js +4 -4
  84. package/dist/assets/icons/eye.svg.js +3 -3
  85. package/dist/assets/icons/failed.svg.js +3 -3
  86. package/dist/assets/icons/files.svg.js +3 -3
  87. package/dist/assets/icons/film.svg.js +4 -4
  88. package/dist/assets/icons/filter.svg.js +3 -3
  89. package/dist/assets/icons/finished.svg.js +3 -3
  90. package/dist/assets/icons/flag.svg.js +3 -3
  91. package/dist/assets/icons/fold.svg.js +3 -3
  92. package/dist/assets/icons/folder-add.svg.js +3 -3
  93. package/dist/assets/icons/folder-checked.svg.js +3 -3
  94. package/dist/assets/icons/folder-delete.svg.js +3 -3
  95. package/dist/assets/icons/folder-opened.svg.js +3 -3
  96. package/dist/assets/icons/folder.svg.js +3 -3
  97. package/dist/assets/icons/food.svg.js +3 -3
  98. package/dist/assets/icons/fork-spoon.svg.js +3 -3
  99. package/dist/assets/icons/full-screen.svg.js +3 -3
  100. package/dist/assets/icons/goblet-full.svg.js +3 -3
  101. package/dist/assets/icons/gold-medal.svg.js +4 -4
  102. package/dist/assets/icons/goods-filled.svg.js +3 -3
  103. package/dist/assets/icons/goods.svg.js +3 -3
  104. package/dist/assets/icons/google.svg.js +6 -6
  105. package/dist/assets/icons/grape.svg.js +3 -3
  106. package/dist/assets/icons/grid.svg.js +3 -3
  107. package/dist/assets/icons/guide.svg.js +4 -4
  108. package/dist/assets/icons/handbag.svg.js +3 -3
  109. package/dist/assets/icons/headset.svg.js +3 -3
  110. package/dist/assets/icons/histogram.svg.js +3 -3
  111. package/dist/assets/icons/hot-water.svg.js +3 -3
  112. package/dist/assets/icons/house.svg.js +3 -3
  113. package/dist/assets/icons/ice-cream-round.svg.js +3 -3
  114. package/dist/assets/icons/ice-drink.svg.js +3 -3
  115. package/dist/assets/icons/image.svg.js +4 -4
  116. package/dist/assets/icons/info-filled.svg.js +3 -3
  117. package/dist/assets/icons/info.svg.js +4 -4
  118. package/dist/assets/icons/key.svg.js +3 -3
  119. package/dist/assets/icons/knife-fork.svg.js +3 -3
  120. package/dist/assets/icons/lightning.svg.js +4 -4
  121. package/dist/assets/icons/link.svg.js +3 -3
  122. package/dist/assets/icons/list.svg.js +3 -3
  123. package/dist/assets/icons/loader.svg.js +2 -2
  124. package/dist/assets/icons/loading.svg.js +3 -3
  125. package/dist/assets/icons/location-filled.svg.js +3 -3
  126. package/dist/assets/icons/location-information.svg.js +5 -5
  127. package/dist/assets/icons/location.svg.js +4 -4
  128. package/dist/assets/icons/lock.svg.js +4 -4
  129. package/dist/assets/icons/logo.svg.js +4 -4
  130. package/dist/assets/icons/lollipop.svg.js +3 -3
  131. package/dist/assets/icons/magic-stick.svg.js +3 -3
  132. package/dist/assets/icons/magnet.svg.js +3 -3
  133. package/dist/assets/icons/male.svg.js +5 -5
  134. package/dist/assets/icons/management.svg.js +3 -3
  135. package/dist/assets/icons/map-location.svg.js +4 -4
  136. package/dist/assets/icons/medal.svg.js +4 -4
  137. package/dist/assets/icons/memo.svg.js +5 -5
  138. package/dist/assets/icons/menu.svg.js +3 -3
  139. package/dist/assets/icons/message-box.svg.js +3 -3
  140. package/dist/assets/icons/message.svg.js +4 -4
  141. package/dist/assets/icons/mic.svg.js +3 -3
  142. package/dist/assets/icons/microphone.svg.js +3 -3
  143. package/dist/assets/icons/minus-thin.svg.js +3 -3
  144. package/dist/assets/icons/minus.svg.js +3 -3
  145. package/dist/assets/icons/money.svg.js +5 -5
  146. package/dist/assets/icons/monitor.svg.js +3 -3
  147. package/dist/assets/icons/moon.svg.js +3 -3
  148. package/dist/assets/icons/more-filled.svg.js +3 -3
  149. package/dist/assets/icons/more.svg.js +3 -3
  150. package/dist/assets/icons/mostly-cloudy.svg.js +3 -3
  151. package/dist/assets/icons/mouse.svg.js +4 -4
  152. package/dist/assets/icons/mug.svg.js +3 -3
  153. package/dist/assets/icons/mute-notification.svg.js +4 -4
  154. package/dist/assets/icons/mute.svg.js +4 -4
  155. package/dist/assets/icons/no-smoking.svg.js +3 -3
  156. package/dist/assets/icons/notebook.svg.js +4 -4
  157. package/dist/assets/icons/notification.svg.js +4 -4
  158. package/dist/assets/icons/office-building.svg.js +5 -5
  159. package/dist/assets/icons/operation.svg.js +3 -3
  160. package/dist/assets/icons/opportunity.svg.js +3 -3
  161. package/dist/assets/icons/orange.svg.js +3 -3
  162. package/dist/assets/icons/paperclip.svg.js +3 -3
  163. package/dist/assets/icons/partly-cloudy.svg.js +4 -4
  164. package/dist/assets/icons/pause.svg.js +3 -3
  165. package/dist/assets/icons/pear.svg.js +3 -3
  166. package/dist/assets/icons/phone-filled.svg.js +3 -3
  167. package/dist/assets/icons/phone.svg.js +3 -3
  168. package/dist/assets/icons/picture.svg.js +4 -4
  169. package/dist/assets/icons/pie-chart.svg.js +4 -4
  170. package/dist/assets/icons/place.svg.js +5 -5
  171. package/dist/assets/icons/platform.svg.js +3 -3
  172. package/dist/assets/icons/play.svg.js +3 -3
  173. package/dist/assets/icons/plus-thin.svg.js +3 -3
  174. package/dist/assets/icons/plus.svg.js +3 -3
  175. package/dist/assets/icons/pointer.svg.js +3 -3
  176. package/dist/assets/icons/position.svg.js +3 -3
  177. package/dist/assets/icons/postcard.svg.js +4 -4
  178. package/dist/assets/icons/pouring.svg.js +3 -3
  179. package/dist/assets/icons/present.svg.js +6 -6
  180. package/dist/assets/icons/price-tag.svg.js +4 -4
  181. package/dist/assets/icons/printer.svg.js +3 -3
  182. package/dist/assets/icons/promotion.svg.js +3 -3
  183. package/dist/assets/icons/quartz-watch.svg.js +5 -5
  184. package/dist/assets/icons/question-filled.svg.js +3 -3
  185. package/dist/assets/icons/rank.svg.js +3 -3
  186. package/dist/assets/icons/reading-lamp.svg.js +4 -4
  187. package/dist/assets/icons/reading.svg.js +4 -4
  188. package/dist/assets/icons/record.svg.js +3 -3
  189. package/dist/assets/icons/refresh-left.svg.js +3 -3
  190. package/dist/assets/icons/refresh-right.svg.js +3 -3
  191. package/dist/assets/icons/refresh.svg.js +3 -3
  192. package/dist/assets/icons/refrigerator.svg.js +3 -3
  193. package/dist/assets/icons/remove-filled.svg.js +3 -3
  194. package/dist/assets/icons/remove.svg.js +4 -4
  195. package/dist/assets/icons/right.svg.js +3 -3
  196. package/dist/assets/icons/rotate-left.svg.js +3 -3
  197. package/dist/assets/icons/rotate-right.svg.js +3 -3
  198. package/dist/assets/icons/scale-to-original.svg.js +3 -3
  199. package/dist/assets/icons/school.svg.js +5 -5
  200. package/dist/assets/icons/scissor.svg.js +3 -3
  201. package/dist/assets/icons/search.svg.js +3 -3
  202. package/dist/assets/icons/select.svg.js +3 -3
  203. package/dist/assets/icons/sell.svg.js +3 -3
  204. package/dist/assets/icons/semi-select.svg.js +3 -3
  205. package/dist/assets/icons/service.svg.js +3 -3
  206. package/dist/assets/icons/setting.svg.js +3 -3
  207. package/dist/assets/icons/share.svg.js +3 -3
  208. package/dist/assets/icons/ship.svg.js +3 -3
  209. package/dist/assets/icons/shop.svg.js +3 -3
  210. package/dist/assets/icons/shopping-bag.svg.js +4 -4
  211. package/dist/assets/icons/shopping-cart-full.svg.js +4 -4
  212. package/dist/assets/icons/shopping-cart.svg.js +3 -3
  213. package/dist/assets/icons/shrink.svg.js +3 -3
  214. package/dist/assets/icons/smoking.svg.js +4 -4
  215. package/dist/assets/icons/soccer.svg.js +3 -3
  216. package/dist/assets/icons/sold-out.svg.js +3 -3
  217. package/dist/assets/icons/sort-down.svg.js +3 -3
  218. package/dist/assets/icons/sort-up.svg.js +3 -3
  219. package/dist/assets/icons/sort.svg.js +3 -3
  220. package/dist/assets/icons/stamp.svg.js +3 -3
  221. package/dist/assets/icons/star-filled.svg.js +3 -3
  222. package/dist/assets/icons/star.svg.js +3 -3
  223. package/dist/assets/icons/stop.svg.js +3 -3
  224. package/dist/assets/icons/success-filled.svg.js +3 -3
  225. package/dist/assets/icons/success.svg.js +3 -3
  226. package/dist/assets/icons/sugar.svg.js +3 -3
  227. package/dist/assets/icons/sunny.svg.js +3 -3
  228. package/dist/assets/icons/sunrise.svg.js +3 -3
  229. package/dist/assets/icons/sunset.svg.js +3 -3
  230. package/dist/assets/icons/switch-button.svg.js +4 -4
  231. package/dist/assets/icons/switch-filled.svg.js +4 -4
  232. package/dist/assets/icons/switch.svg.js +3 -3
  233. package/dist/assets/icons/takeaway-box.svg.js +3 -3
  234. package/dist/assets/icons/ticket.svg.js +3 -3
  235. package/dist/assets/icons/tickets.svg.js +3 -3
  236. package/dist/assets/icons/time.svg.js +3 -3
  237. package/dist/assets/icons/timer.svg.js +5 -5
  238. package/dist/assets/icons/toilet-paper.svg.js +4 -4
  239. package/dist/assets/icons/tools.svg.js +3 -3
  240. package/dist/assets/icons/top-left.svg.js +4 -4
  241. package/dist/assets/icons/top-right.svg.js +4 -4
  242. package/dist/assets/icons/top.svg.js +3 -3
  243. package/dist/assets/icons/trend-charts.svg.js +3 -3
  244. package/dist/assets/icons/triangle-down.svg.js +3 -3
  245. package/dist/assets/icons/trophy-base.svg.js +3 -3
  246. package/dist/assets/icons/trophy.svg.js +3 -3
  247. package/dist/assets/icons/turn-off.svg.js +4 -4
  248. package/dist/assets/icons/umbrella.svg.js +3 -3
  249. package/dist/assets/icons/unlock.svg.js +4 -4
  250. package/dist/assets/icons/upload-filled.svg.js +3 -3
  251. package/dist/assets/icons/upload.svg.js +3 -3
  252. package/dist/assets/icons/user-filled.svg.js +3 -3
  253. package/dist/assets/icons/user.svg.js +3 -3
  254. package/dist/assets/icons/users.svg.js +4 -4
  255. package/dist/assets/icons/van.svg.js +3 -3
  256. package/dist/assets/icons/video-pause.svg.js +3 -3
  257. package/dist/assets/icons/video-play.svg.js +3 -3
  258. package/dist/assets/icons/video.svg.js +4 -4
  259. package/dist/assets/icons/view.svg.js +3 -3
  260. package/dist/assets/icons/wallet-filled.svg.js +3 -3
  261. package/dist/assets/icons/wallet.svg.js +5 -5
  262. package/dist/assets/icons/warn-triangle-filled.svg.js +3 -3
  263. package/dist/assets/icons/warning.svg.js +4 -4
  264. package/dist/assets/icons/watch.svg.js +5 -5
  265. package/dist/assets/icons/wind-power.svg.js +3 -3
  266. package/dist/assets/icons/zoom-in.svg.js +3 -3
  267. package/dist/assets/icons/zoom-out.svg.js +3 -3
  268. package/dist/components/basic/nmorph-button/NmorphButton.css +1 -1
  269. package/dist/components/basic/nmorph-icon/NmorphIcon.css +1 -1
  270. package/dist/components/basic/nmorph-icon/NmorphIcon.vue2.js +11 -11
  271. package/dist/components/basic/nmorph-link/NmorphLink.css +1 -1
  272. package/dist/components/data/nmorph-avatar/NmorphAvatar.vue2.js +1 -1
  273. package/dist/components/data/nmorph-badge/NmorphBadge.css +1 -1
  274. package/dist/components/data/nmorph-calendar/NmorphCalendar.css +1 -1
  275. package/dist/components/data/nmorph-calendar/inner-components/nmorph-calendar-header/NmorphCalendarHeader.css +1 -1
  276. package/dist/components/data/nmorph-card/NmorphCard.css +1 -1
  277. package/dist/components/data/nmorph-collapse/components/nmorph-collapse-item/NmorphCollapseItem.css +1 -1
  278. package/dist/components/data/nmorph-image-preview/NmorphImagePreview.css +1 -1
  279. package/dist/components/data/nmorph-image-preview/NmorphImagePreview.vue2.js +8 -8
  280. package/dist/components/data/nmorph-pagination/NmorphPagination.css +1 -1
  281. package/dist/components/data/nmorph-pagination/NmorphPagination.vue.js +13 -12
  282. package/dist/components/data/nmorph-pagination/NmorphPagination.vue2.js +46 -40
  283. package/dist/components/data/nmorph-progress/NmorphProgress.css +1 -1
  284. package/dist/components/data/nmorph-skeleton/components/NmorphSkeletonItem.css +1 -1
  285. package/dist/components/data/nmorph-table/NmorphTable.css +1 -1
  286. package/dist/components/data/nmorph-table/NmorphTable.vue.js +228 -103
  287. package/dist/components/data/nmorph-table/NmorphTable.vue2.js +49 -30
  288. package/dist/components/data/nmorph-table/inner-components/nmorph-sort-button/NmorphSortButton.css +1 -1
  289. package/dist/components/data/nmorph-tag-list/NmorphTagList.vue.js +2 -3
  290. package/dist/components/data/nmorph-tag-list/components/nmorph-tag-item/NmorphTagItem.css +1 -1
  291. package/dist/components/feedback/nmorph-alert/NmorphAlert.css +1 -1
  292. package/dist/components/feedback/nmorph-callout/NmorphCallout.css +1 -1
  293. package/dist/components/feedback/nmorph-dialog/NmorphDialog.css +1 -1
  294. package/dist/components/feedback/nmorph-dialog/NmorphDialog.vue2.js +16 -16
  295. package/dist/components/feedback/nmorph-tooltip/NmorphTooltip.css +1 -1
  296. package/dist/components/feedback/nmorph-tooltip/NmorphTooltip.vue.js +3 -3
  297. package/dist/components/form/nmorph-autocomplete/NmorphAutocomplete.css +1 -1
  298. package/dist/components/form/nmorph-autocomplete/NmorphAutocomplete.vue.js +91 -35
  299. package/dist/components/form/nmorph-autocomplete/NmorphAutocomplete.vue2.js +49 -36
  300. package/dist/components/form/nmorph-checkbox/NmorphCheckbox.css +1 -1
  301. package/dist/components/form/nmorph-checkbox/NmorphCheckbox.vue.js +1 -1
  302. package/dist/components/form/nmorph-color-picker/NmorphColorPicker.css +1 -1
  303. package/dist/components/form/nmorph-color-picker/NmorphColorPicker.vue2.js +11 -10
  304. package/dist/components/form/nmorph-date-picker/NmorphDatePicker.css +1 -1
  305. package/dist/components/form/nmorph-date-picker/NmorphDatePicker.vue2.js +3 -3
  306. package/dist/components/form/nmorph-date-picker/inner-components/nmorph-date-picker-header/NmorphDatePickerHeader.css +1 -1
  307. package/dist/components/form/nmorph-date-picker/inner-components/nmorph-date-picker-header/NmorphDatePickerHeader.vue.js +12 -12
  308. package/dist/components/form/nmorph-date-picker/inner-components/nmorph-year-month-picker/NmorphYearMonthPicker.css +1 -1
  309. package/dist/components/form/nmorph-date-picker/inner-components/nmorph-year-month-picker/NmorphYearMonthPicker.vue.js +6 -6
  310. package/dist/components/form/nmorph-file-upload/NmorphFileUpload.css +1 -1
  311. package/dist/components/form/nmorph-file-upload/NmorphFileUpload.vue.js +3 -3
  312. package/dist/components/form/nmorph-form/components/nmorph-form-item/inner-components/nmorph-validation-icon/NmorphValidationIcon.css +1 -1
  313. package/dist/components/form/nmorph-number-input/NmorphNumberInput.css +1 -1
  314. package/dist/components/form/nmorph-radio/NmorphRadio.css +1 -1
  315. package/dist/components/form/nmorph-radio/NmorphRadio.vue.js +1 -1
  316. package/dist/components/form/nmorph-select/NmorphSelect.css +1 -1
  317. package/dist/components/form/nmorph-select/NmorphSelect.vue.js +113 -59
  318. package/dist/components/form/nmorph-select/NmorphSelect.vue2.js +105 -76
  319. package/dist/components/form/nmorph-select/components/nmorph-select-option/NmorphSelectOption.css +1 -1
  320. package/dist/components/form/nmorph-select/components/nmorph-select-option/NmorphSelectOption.vue.js +2 -2
  321. package/dist/components/form/nmorph-select/components/nmorph-select-option/NmorphSelectOption.vue2.js +12 -10
  322. package/dist/components/form/nmorph-select-button/NmorphSelectButton.css +1 -1
  323. package/dist/components/form/nmorph-select-button/components/nmorph-select-button-item/NmorphSelectButtonItem.css +1 -1
  324. package/dist/components/form/nmorph-slider/NmorphSlider.css +1 -1
  325. package/dist/components/form/nmorph-switch/NmorphSwitch.css +1 -1
  326. package/dist/components/navigation/nmorph-backtop/NmorphBacktop.css +1 -1
  327. package/dist/components/navigation/nmorph-backtop/NmorphBacktop.vue.js +52 -42
  328. package/dist/components/navigation/nmorph-backtop/NmorphBacktop.vue2.js +31 -28
  329. package/dist/components/navigation/nmorph-breadcrumb/components/nmorph-breadcrumb-item/NmorphBreadcrumbItem.vue2.js +6 -6
  330. package/dist/components/navigation/nmorph-dropdown/NmorphDropdown.css +1 -1
  331. package/dist/components/navigation/nmorph-dropdown/NmorphDropdown.vue.js +29 -42
  332. package/dist/components/navigation/nmorph-dropdown/NmorphDropdown.vue2.js +42 -23
  333. package/dist/components/navigation/nmorph-tabs/NmorphTabs.css +1 -1
  334. package/dist/components/navigation/nmorph-tabs/NmorphTabs.vue.js +3 -3
  335. package/dist/components/others/nmorph-overlay/NmorphOverlay.css +1 -1
  336. package/dist/components/others/nmorph-overlay/NmorphOverlay.vue.js +29 -24
  337. package/dist/components/others/nmorph-overlay/NmorphOverlay.vue2.js +17 -15
  338. package/dist/components/providers/nmorph-notification-provider/NmorphNotificationProvider.css +1 -1
  339. package/dist/components/providers/nmorph-notification-provider/NmorphNotificationProvider.vue.js +2 -3
  340. package/dist/hooks/use-common-styles.js +32 -10
  341. package/dist/hooks/use-placement.js +76 -44
  342. package/dist/hooks/use-virtual-list.js +46 -0
  343. package/dist/index.es.js +22 -19
  344. package/dist/index.umd.js +56 -29
  345. package/dist/nuxt.mjs +48 -38
  346. package/dist/outside-hooks/use-nmorph-browser.js +9 -9
  347. package/dist/outside-hooks/use-nmorph-theme.js +133 -87
  348. package/dist/package.json.js +1 -1
  349. package/dist/plugin.js +31 -27
  350. package/dist/src/components/basic/nmorph-button/NmorphButton.vue.d.ts +5 -3
  351. package/dist/src/components/basic/nmorph-icon/NmorphIcon.vue.d.ts +1 -1
  352. package/dist/src/components/basic/nmorph-link/NmorphLink.vue.d.ts +1 -1
  353. package/dist/src/components/basic/nmorph-scroll/NmorphScroll.vue.d.ts +3 -1
  354. package/dist/src/components/data/nmorph-avatar/NmorphAvatar.vue.d.ts +2 -1
  355. package/dist/src/components/data/nmorph-badge/NmorphBadge.vue.d.ts +3 -1
  356. package/dist/src/components/data/nmorph-calendar/NmorphCalendar.vue.d.ts +2 -2
  357. package/dist/src/components/data/nmorph-calendar/inner-components/nmorph-calendar-header/NmorphCalendarHeader.vue.d.ts +1 -1
  358. package/dist/src/components/data/nmorph-card/NmorphCard.vue.d.ts +1 -1
  359. package/dist/src/components/data/nmorph-carousel/NmorphCarousel.vue.d.ts +3 -1
  360. package/dist/src/components/data/nmorph-collapse/NmorphCollapse.vue.d.ts +1 -1
  361. package/dist/src/components/data/nmorph-collapse/components/nmorph-collapse-item/NmorphCollapseItem.vue.d.ts +3 -1
  362. package/dist/src/components/data/nmorph-image-preview/NmorphImagePreview.vue.d.ts +1 -0
  363. package/dist/src/components/data/nmorph-progress/NmorphProgress.vue.d.ts +6 -4
  364. package/dist/src/components/data/nmorph-skeleton/NmorphSkeleton.vue.d.ts +1 -1
  365. package/dist/src/components/data/nmorph-skeleton/components/NmorphSkeletonItem.vue.d.ts +1 -1
  366. package/dist/src/components/data/nmorph-table/NmorphTable.vue.d.ts +12 -1
  367. package/dist/src/components/data/nmorph-table/components/nmorph-table-column/NmorphTableColumn.vue.d.ts +3 -1
  368. package/dist/src/components/data/nmorph-table/inner-components/nmorph-sort-button/NmorphSortButton.vue.d.ts +1 -1
  369. package/dist/src/components/data/nmorph-table/types.d.ts +2 -2
  370. package/dist/src/components/data/nmorph-tag-list/NmorphTagList.vue.d.ts +1 -1
  371. package/dist/src/components/data/nmorph-tag-list/components/nmorph-tag-item/NmorphTagItem.vue.d.ts +1 -1
  372. package/dist/src/components/feedback/nmorph-callout/NmorphCallout.vue.d.ts +1 -1
  373. package/dist/src/components/feedback/nmorph-dialog/NmorphDialog.vue.d.ts +1 -0
  374. package/dist/src/components/feedback/nmorph-tooltip/NmorphTooltip.vue.d.ts +6 -2
  375. package/dist/src/components/form/nmorph-autocomplete/NmorphAutocomplete.vue.d.ts +16 -2
  376. package/dist/src/components/form/nmorph-checkbox/NmorphCheckbox.vue.d.ts +3 -1
  377. package/dist/src/components/form/nmorph-checkbox-group/NmorphCheckboxGroup.vue.d.ts +1 -1
  378. package/dist/src/components/form/nmorph-color-picker/NmorphColorPicker.vue.d.ts +3 -1
  379. package/dist/src/components/form/nmorph-date-picker/NmorphDatePicker.vue.d.ts +5 -2
  380. package/dist/src/components/form/nmorph-date-picker/inner-components/nmorph-clear-button/NmorphClearButton.vue.d.ts +1 -1
  381. package/dist/src/components/form/nmorph-date-picker/inner-components/nmorph-date-picker-content/NmorphDatePickerContent.vue.d.ts +1 -1
  382. package/dist/src/components/form/nmorph-date-picker/inner-components/nmorph-date-picker-header/NmorphDatePickerHeader.vue.d.ts +1 -1
  383. package/dist/src/components/form/nmorph-date-picker/inner-components/nmorph-year-month-picker/NmorphYearMonthPicker.vue.d.ts +1 -1
  384. package/dist/src/components/form/nmorph-file-upload/NmorphFileUpload.vue.d.ts +3 -1
  385. package/dist/src/components/form/nmorph-form/NmorphForm.vue.d.ts +1 -1
  386. package/dist/src/components/form/nmorph-form/components/nmorph-form-item/NmorphFormItem.vue.d.ts +1 -1
  387. package/dist/src/components/form/nmorph-form/components/nmorph-form-item/inner-components/nmorph-error-box/NmorphErrorBox.vue.d.ts +1 -1
  388. package/dist/src/components/form/nmorph-form/components/nmorph-form-item/inner-components/nmorph-validation-icon/NmorphValidationIcon.vue.d.ts +1 -1
  389. package/dist/src/components/form/nmorph-number-input/NmorphNumberInput.vue.d.ts +3 -1
  390. package/dist/src/components/form/nmorph-otp-input/NmorphOTPInput.vue.d.ts +1 -1
  391. package/dist/src/components/form/nmorph-radio/NmorphRadio.vue.d.ts +3 -1
  392. package/dist/src/components/form/nmorph-radio-group/NmorphRadioGroup.vue.d.ts +1 -1
  393. package/dist/src/components/form/nmorph-select/NmorphSelect.vue.d.ts +13 -1
  394. package/dist/src/components/form/nmorph-select/components/nmorph-select-option/NmorphSelectOption.vue.d.ts +2 -1
  395. package/dist/src/components/form/nmorph-select/types.d.ts +1 -0
  396. package/dist/src/components/form/nmorph-select-button/NmorphSelectButton.vue.d.ts +1 -1
  397. package/dist/src/components/form/nmorph-select-button/components/nmorph-select-button-item/NmorphSelectButtonItem.vue.d.ts +3 -1
  398. package/dist/src/components/form/nmorph-switch/NmorphSwitch.vue.d.ts +7 -5
  399. package/dist/src/components/form/nmorph-text-input/NmorphTextInput.vue.d.ts +5 -3
  400. package/dist/src/components/navigation/nmorph-backtop/NmorphBacktop.vue.d.ts +10 -1
  401. package/dist/src/components/navigation/nmorph-breadcrumb/NmorphBreadcrumb.vue.d.ts +1 -1
  402. package/dist/src/components/navigation/nmorph-breadcrumb/components/nmorph-breadcrumb-item/NmorphBreadcrumbItem.vue.d.ts +1 -2
  403. package/dist/src/components/navigation/nmorph-breadcrumb/types.d.ts +1 -2
  404. package/dist/src/components/navigation/nmorph-dropdown/NmorphDropdown.vue.d.ts +9 -2
  405. package/dist/src/components/navigation/nmorph-tabs/NmorphTabs.vue.d.ts +1 -1
  406. package/dist/src/components/others/nmorph-divider/NmorphDivider.vue.d.ts +1 -1
  407. package/dist/src/components/others/nmorph-overlay/NmorphOverlay.vue.d.ts +5 -0
  408. package/dist/src/components/providers/nmorph-notification-provider/NmorphNotificationProvider.vue.d.ts +2 -2
  409. package/dist/src/hooks/index.d.ts +1 -0
  410. package/dist/src/hooks/use-common-styles.d.ts +1 -0
  411. package/dist/src/hooks/use-placement.d.ts +8 -4
  412. package/dist/src/hooks/use-virtual-list.d.ts +21 -0
  413. package/dist/src/nuxt/module.d.ts +3 -2
  414. package/dist/src/outside-hooks/use-nmorph-notification.d.ts +2 -2
  415. package/dist/src/outside-hooks/use-nmorph-theme.d.ts +1 -0
  416. package/dist/src/plugin.d.ts +2 -0
  417. package/dist/src/types/index.d.ts +3 -1
  418. package/dist/style.css +1 -1
  419. package/package.json +8 -7
  420. package/dist/src/components/form/nmorph-slider/NmorphSlider.vue.d.ts +0 -15
@@ -1,49 +1,36 @@
1
1
  import './NmorphDropdown.css';
2
2
  import n from "./NmorphDropdown.vue2.js";
3
- import { openBlock as d, createElementBlock as i, normalizeStyle as r, createVNode as t, withCtx as m, createElementVNode as p, normalizeClass as a, renderSlot as l } from "vue";
3
+ import { openBlock as r, createBlock as t, withCtx as d, createElementBlock as i, normalizeStyle as p, normalizeClass as l, renderSlot as a, createCommentVNode as m } from "vue";
4
4
  /* empty css */
5
5
  import s from "../../../_virtual/_plugin-vue_export-helper.js";
6
- function c(e, h, f, o, w, _) {
7
- return d(), i(
8
- "div",
9
- {
10
- style: r({
11
- "--nmorph-dropdown-width": o.width,
12
- "--nmorph-dropdown-min-width": o.getCssSize(o.props.minWidth) || "auto",
13
- "--nmorph-dropdown-max-width": o.getCssSize(o.props.maxWidth) || "none"
14
- })
15
- },
16
- [
17
- t(o.NmorphOverlay, {
18
- show: o.props.open,
19
- transparent: "",
20
- "z-index": o.props.zIndex,
21
- onOnOutsideClick: o.outsideClickHandler
22
- }, {
23
- default: m(() => [
24
- p(
25
- "div",
26
- {
27
- ref: "dropdownDOMRef",
28
- class: a(o.modifiers),
29
- style: r({ left: `${o.placementCoords.x}`, top: `${o.placementCoords.y}` })
30
- },
31
- [
32
- l(e.$slots, "default")
33
- ],
34
- 6
35
- /* CLASS, STYLE */
36
- )
37
- ]),
38
- _: 3
39
- /* FORWARDED */
40
- }, 8, ["show", "z-index"])
41
- ],
42
- 4
43
- /* STYLE */
44
- );
6
+ function c(e, f, _, o, h, w) {
7
+ return r(), t(o.NmorphOverlay, {
8
+ show: o.props.open,
9
+ transparent: "",
10
+ "z-index": o.props.zIndex,
11
+ onOnOutsideClick: o.outsideClickHandler
12
+ }, {
13
+ default: d(() => [
14
+ o.props.open ? (r(), i(
15
+ "div",
16
+ {
17
+ key: 0,
18
+ ref: "dropdownDOMRef",
19
+ class: l(o.modifiers),
20
+ style: p(o.dropdownStyle)
21
+ },
22
+ [
23
+ a(e.$slots, "default")
24
+ ],
25
+ 6
26
+ /* CLASS, STYLE */
27
+ )) : m("v-if", !0)
28
+ ]),
29
+ _: 3
30
+ /* FORWARDED */
31
+ }, 8, ["show", "z-index"]);
45
32
  }
46
- const k = /* @__PURE__ */ s(n, [["render", c], ["__file", "/builds/ketjo/nmorph/library/src/components/navigation/nmorph-dropdown/NmorphDropdown.vue"]]);
33
+ const z = /* @__PURE__ */ s(n, [["render", c], ["__file", "/builds/ketjo/nmorph/library/src/components/navigation/nmorph-dropdown/NmorphDropdown.vue"]]);
47
34
  export {
48
- k as default
35
+ z as default
49
36
  };
@@ -1,42 +1,61 @@
1
1
  import './NmorphDropdown.css';
2
- import { defineComponent as a, ref as c, computed as l } from "vue";
3
- import { useModifiers as y } from "../../../utils/create-modifiers.js";
4
- import { usePlacement as h } from "../../../hooks/use-placement.js";
5
- import O from "../../others/nmorph-overlay/NmorphOverlay.vue.js";
6
- const w = /* @__PURE__ */ a({
2
+ import { defineComponent as v, ref as w, toRef as r, computed as n, watch as b } from "vue";
3
+ import { useModifiers as x } from "../../../utils/create-modifiers.js";
4
+ import { usePlacement as O } from "../../../hooks/use-placement.js";
5
+ import q from "../../others/nmorph-overlay/NmorphOverlay.vue.js";
6
+ const g = /* @__PURE__ */ v({
7
7
  __name: "NmorphDropdown",
8
8
  props: {
9
9
  open: { type: Boolean, required: !0 },
10
10
  relativeElement: { type: null, required: !0 },
11
+ placement: { type: null, required: !1, default: "bottom" },
11
12
  width: { type: [Number, String], required: !1, default: 160 },
12
- minWidth: { type: [Number, String], required: !1 },
13
- maxWidth: { type: [Number, String], required: !1 },
13
+ minWidth: { type: [Number, String], required: !1, default: void 0 },
14
+ maxWidth: { type: [Number, String], required: !1, default: void 0 },
14
15
  xOffset: { type: Number, required: !1, default: 0 },
15
16
  yOffset: { type: Number, required: !1, default: 0 },
16
17
  fillWidth: { type: Boolean, required: !1, default: !0 },
17
- zIndex: { type: Number, required: !1 }
18
+ zIndex: { type: Number, required: !1, default: void 0 }
18
19
  },
19
20
  emits: ["on-outside-click"],
20
- setup(s, { expose: d, emit: f }) {
21
- d();
22
- const e = s, r = f, o = c(null), { placementCoords: m } = h({
23
- initialPlacement: "bottom",
24
- contentDOMElement: o,
25
- relativeElement: e.relativeElement,
26
- yOffset: e.yOffset,
27
- xOffset: e.xOffset
28
- }), u = l(
29
- () => y({
21
+ setup(s, { expose: f, emit: c }) {
22
+ f();
23
+ const e = s, l = c, d = w(null), { placementCoords: i, placementReady: p, adjustPlacement: a } = O({
24
+ initialPlacement: r(e, "placement"),
25
+ contentDOMElement: d,
26
+ relativeElement: r(e, "relativeElement"),
27
+ yOffset: r(e, "yOffset"),
28
+ xOffset: r(e, "xOffset"),
29
+ enabled: r(e, "open")
30
+ }), h = n(
31
+ () => x({
30
32
  "nmorph-dropdown": [`${!e.open && "closed"}`]
31
33
  })
32
- ), i = (t) => typeof t == "number" ? `${t}px` : t, p = l(() => e.fillWidth ? `${e.relativeElement?.clientWidth}px` : i(e.width)), n = { props: e, emit: r, dropdownDOMRef: o, placementCoords: m, modifiers: u, getCssSize: i, width: p, outsideClickHandler: () => {
33
- r("on-outside-click");
34
+ ), o = (t) => typeof t == "number" ? `${t}px` : t, u = n(
35
+ () => e.fillWidth && e.relativeElement ? `${e.relativeElement.clientWidth}px` : o(e.width)
36
+ ), y = n(() => ({
37
+ "--nmorph-dropdown-width": u.value,
38
+ "--nmorph-dropdown-min-width": o(e.minWidth) || "auto",
39
+ "--nmorph-dropdown-max-width": o(e.maxWidth) || "none",
40
+ left: i.value.x,
41
+ top: i.value.y,
42
+ visibility: e.open && p.value ? "visible" : "hidden"
43
+ }));
44
+ b(
45
+ () => e.open,
46
+ (t) => {
47
+ t && a();
48
+ },
49
+ { flush: "post" }
50
+ );
51
+ const m = { props: e, emit: l, dropdownDOMRef: d, placementCoords: i, placementReady: p, adjustPlacement: a, modifiers: h, getCssSize: o, width: u, dropdownStyle: y, outsideClickHandler: () => {
52
+ l("on-outside-click");
34
53
  }, get NmorphOverlay() {
35
- return O;
54
+ return q;
36
55
  } };
37
- return Object.defineProperty(n, "__isScriptSetup", { enumerable: !1, value: !0 }), n;
56
+ return Object.defineProperty(m, "__isScriptSetup", { enumerable: !1, value: !0 }), m;
38
57
  }
39
58
  });
40
59
  export {
41
- w as default
60
+ g as default
42
61
  };
@@ -1 +1 @@
1
- .nmorph-tabs{border-radius:var(--default-border-radius)}.nmorph-tabs .nmorph-tabs__label-list{display:flex;padding:var(--indentation-02);border-top-left-radius:var(--default-border-radius);border-top-right-radius:var(--default-border-radius);background:var(--nmorph-main-color);box-shadow:var(--base-shadow-width) var(--base-shadow-width) var(--base-shadow-blur) var(--nmorph-dark-shade-color),calc(-1 * var(--base-shadow-width)) calc(-1 * var(--base-shadow-width)) var(--base-shadow-blur) var(--nmorph-light-shade-color)}.nmorph-tabs .nmorph-tabs__label{margin-right:var(--indentation-02);padding:var(--indentation-03);border-radius:var(--default-border-radius);cursor:pointer;background:var(--nmorph-main-color);box-shadow:var(--base-shadow-width) var(--base-shadow-width) var(--base-shadow-blur) var(--nmorph-dark-shade-color),calc(-1 * var(--base-shadow-width)) calc(-1 * var(--base-shadow-width)) var(--base-shadow-blur) var(--nmorph-light-shade-color)}.nmorph-tabs .nmorph-tabs__label.nmorph-tabs__label--disabled{cursor:not-allowed;opacity:.6}.nmorph-tabs .nmorph-tabs__label.nmorph-tabs__label--selected{background:var(--nmorph-main-color);box-shadow:inset var(--base-shadow-width) var(--base-shadow-width) var(--base-shadow-blur) var(--nmorph-dark-shade-color),inset calc(-1 * var(--base-shadow-width)) calc(-1 * var(--base-shadow-width)) var(--base-shadow-blur) var(--nmorph-light-shade-color)}.nmorph-tabs .nmorph-tabs__content__wrapper{padding:var(--indentation-02);border-bottom-right-radius:var(--default-border-radius);border-bottom-left-radius:var(--default-border-radius);background:var(--nmorph-main-color);box-shadow:var(--base-shadow-width) var(--base-shadow-width) var(--base-shadow-blur) var(--nmorph-dark-shade-color),calc(-1 * var(--base-shadow-width)) calc(-1 * var(--base-shadow-width)) var(--base-shadow-blur) var(--nmorph-light-shade-color)}.nmorph-tabs .nmorph-tabs__content{padding:var(--indentation-03);border-radius:var(--default-border-radius);background:var(--nmorph-main-color);box-shadow:inset var(--base-shadow-width) var(--base-shadow-width) var(--base-shadow-blur) var(--nmorph-dark-shade-color),inset calc(-1 * var(--base-shadow-width)) calc(-1 * var(--base-shadow-width)) var(--base-shadow-blur) var(--nmorph-light-shade-color)}.nmorph-tabs.nmorph-tabs--stretch .nmorph-tabs__label{width:100%}
1
+ .nmorph-tabs{border-radius:var(--default-border-radius)}.nmorph-tabs .nmorph-tabs__label-list{display:flex;padding:var(--indentation-02);background:var(--nmorph-main-color);border-top-left-radius:var(--default-border-radius);border-top-right-radius:var(--default-border-radius);box-shadow:var(--base-shadow-width) var(--base-shadow-width) var(--base-shadow-blur) var(--nmorph-dark-shade-color),calc(-1 * var(--base-shadow-width)) calc(-1 * var(--base-shadow-width)) var(--base-shadow-blur) var(--nmorph-light-shade-color)}.nmorph-tabs .nmorph-tabs__label{margin-right:var(--indentation-02);padding:var(--indentation-03);background:var(--nmorph-main-color);border-radius:var(--default-border-radius);box-shadow:var(--base-shadow-width) var(--base-shadow-width) var(--base-shadow-blur) var(--nmorph-dark-shade-color),calc(-1 * var(--base-shadow-width)) calc(-1 * var(--base-shadow-width)) var(--base-shadow-blur) var(--nmorph-light-shade-color);cursor:pointer}.nmorph-tabs .nmorph-tabs__label.nmorph-tabs__label--disabled{cursor:not-allowed;opacity:.6}.nmorph-tabs .nmorph-tabs__label.nmorph-tabs__label--selected{background:var(--nmorph-main-color);box-shadow:inset var(--base-shadow-width) var(--base-shadow-width) var(--base-shadow-blur) var(--nmorph-dark-shade-color),inset calc(-1 * var(--base-shadow-width)) calc(-1 * var(--base-shadow-width)) var(--base-shadow-blur) var(--nmorph-light-shade-color)}.nmorph-tabs .nmorph-tabs__content__wrapper{padding:var(--indentation-02);background:var(--nmorph-main-color);border-bottom-right-radius:var(--default-border-radius);border-bottom-left-radius:var(--default-border-radius);box-shadow:var(--base-shadow-width) var(--base-shadow-width) var(--base-shadow-blur) var(--nmorph-dark-shade-color),calc(-1 * var(--base-shadow-width)) calc(-1 * var(--base-shadow-width)) var(--base-shadow-blur) var(--nmorph-light-shade-color)}.nmorph-tabs .nmorph-tabs__content{padding:var(--indentation-03);background:var(--nmorph-main-color);border-radius:var(--default-border-radius);box-shadow:inset var(--base-shadow-width) var(--base-shadow-width) var(--base-shadow-blur) var(--nmorph-dark-shade-color),inset calc(-1 * var(--base-shadow-width)) calc(-1 * var(--base-shadow-width)) var(--base-shadow-blur) var(--nmorph-light-shade-color)}.nmorph-tabs.nmorph-tabs--stretch .nmorph-tabs__label{width:100%}
@@ -3,7 +3,7 @@ import m from "./NmorphTabs.vue2.js";
3
3
  import { openBlock as n, createElementBlock as s, normalizeClass as t, renderSlot as a, createElementVNode as r, Fragment as i, renderList as d, toDisplayString as l, createCommentVNode as _, withDirectives as h, vShow as p } from "vue";
4
4
  /* empty css */
5
5
  import f from "../../../_virtual/_plugin-vue_export-helper.js";
6
- const b = { class: "nmorph-tabs__label-list" }, v = ["id", "onClick", "custom"], u = { key: 0 }, k = { class: "nmorph-tabs__content__wrapper" }, g = { class: "nmorph-tabs__content" }, y = ["id"], C = { key: 0 };
6
+ const b = { class: "nmorph-tabs__label-list" }, v = ["id", "custom", "onClick"], u = { key: 0 }, k = { class: "nmorph-tabs__content__wrapper" }, g = { class: "nmorph-tabs__content" }, y = ["id"], C = { key: 0 };
7
7
  function T(c, I, N, e, V, w) {
8
8
  return n(), s(
9
9
  "div",
@@ -23,8 +23,8 @@ function T(c, I, N, e, V, w) {
23
23
  { "nmorph-tabs__label--selected": o.name === e.props.modelValue },
24
24
  { "nmorph-tabs__label--disabled": o.disabled }
25
25
  ]]),
26
- onClick: (S) => e.changeTab(o),
27
- custom: o.disabled
26
+ custom: o.disabled,
27
+ onClick: (S) => e.changeTab(o)
28
28
  }, [
29
29
  e.slots.default ? _("v-if", !0) : (n(), s(
30
30
  "div",
@@ -1 +1 @@
1
- .nmorph-overlay{opacity:0;pointer-events:none;position:fixed;top:0;left:0;width:100vw;height:100vh;overflow:hidden;background:var(--nmorph-overlay-color);transition:ease-in-out var(--transition-02) opacity;z-index:var(--nmorph-overlay-z-index)}.nmorph-overlay.nmorph-overlay--transparent{background:transparent}.nmorph-overlay.nmorph-overlay--show{opacity:1;pointer-events:auto}
1
+ .nmorph-overlay{position:fixed;top:0;left:0;z-index:var(--nmorph-overlay-z-index);width:100vw;height:100vh;overflow:hidden;background:var(--nmorph-overlay-color);opacity:0;transition:ease-in-out var(--transition-02) opacity;pointer-events:none}.nmorph-overlay.nmorph-overlay--transparent{background:transparent}.nmorph-overlay.nmorph-overlay--show{opacity:1;pointer-events:auto}
@@ -1,30 +1,35 @@
1
1
  import './NmorphOverlay.css';
2
- import t from "./NmorphOverlay.vue2.js";
3
- import { openBlock as n, createElementBlock as i, withModifiers as e, normalizeStyle as s, normalizeClass as m, createElementVNode as a, renderSlot as p } from "vue";
2
+ import s from "./NmorphOverlay.vue2.js";
3
+ import { openBlock as i, createBlock as n, Teleport as p, createElementVNode as e, withModifiers as l, normalizeStyle as a, normalizeClass as d, renderSlot as m } from "vue";
4
4
  /* empty css */
5
5
  import c from "../../../_virtual/_plugin-vue_export-helper.js";
6
- function d(l, r, f, o, _, v) {
7
- return n(), i(
8
- "div",
9
- {
10
- class: m(o.modifiers),
11
- style: s({ "--nmorph-overlay-z-index": o.zIndex }),
12
- onClick: e(o.clickHandler, ["stop"])
13
- },
14
- [
15
- a("div", {
16
- class: "nmorph-overlay__slot",
17
- onClick: r[0] || (r[0] = e(() => {
18
- }, ["stop"]))
19
- }, [
20
- p(l.$slots, "default")
21
- ])
22
- ],
23
- 6
24
- /* CLASS, STYLE */
25
- );
6
+ function f(t, r, _, o, h, v) {
7
+ return i(), n(p, {
8
+ to: o.props.teleportTo,
9
+ disabled: o.props.disabledTeleport || !o.props.show
10
+ }, [
11
+ e(
12
+ "div",
13
+ {
14
+ class: d(o.modifiers),
15
+ style: a({ "--nmorph-overlay-z-index": o.zIndex }),
16
+ onClick: l(o.clickHandler, ["stop"])
17
+ },
18
+ [
19
+ e("div", {
20
+ class: "nmorph-overlay__slot",
21
+ onClick: r[0] || (r[0] = l(() => {
22
+ }, ["stop"]))
23
+ }, [
24
+ m(t.$slots, "default")
25
+ ])
26
+ ],
27
+ 6
28
+ /* CLASS, STYLE */
29
+ )
30
+ ], 8, ["to", "disabled"]);
26
31
  }
27
- const x = /* @__PURE__ */ c(t, [["render", d], ["__file", "/builds/ketjo/nmorph/library/src/components/others/nmorph-overlay/NmorphOverlay.vue"]]);
32
+ const z = /* @__PURE__ */ c(s, [["render", f], ["__file", "/builds/ketjo/nmorph/library/src/components/others/nmorph-overlay/NmorphOverlay.vue"]]);
28
33
  export {
29
- x as default
34
+ z as default
30
35
  };
@@ -1,30 +1,32 @@
1
1
  import './NmorphOverlay.css';
2
- import { defineComponent as d, computed as t } from "vue";
3
- import { useModifiers as m } from "../../../utils/create-modifiers.js";
4
- import { useZIndex as c } from "../../../hooks/use-z-index.js";
5
- const h = /* @__PURE__ */ d({
2
+ import { defineComponent as p, computed as r } from "vue";
3
+ import { useModifiers as u } from "../../../utils/create-modifiers.js";
4
+ import { useZIndex as f } from "../../../hooks/use-z-index.js";
5
+ const y = /* @__PURE__ */ p({
6
6
  __name: "NmorphOverlay",
7
7
  props: {
8
8
  show: { type: Boolean, required: !0 },
9
9
  transparent: { type: Boolean, required: !1, default: !1 },
10
- zIndex: { type: Number, required: !1 }
10
+ zIndex: { type: Number, required: !1, default: void 0 },
11
+ teleportTo: { type: null, required: !1, default: "body" },
12
+ disabledTeleport: { type: Boolean, required: !1, default: !1 }
11
13
  },
12
14
  emits: ["on-outside-click"],
13
- setup(n, { expose: s, emit: i }) {
14
- s();
15
- const e = n, p = c(
16
- t(() => e.show),
15
+ setup(s, { expose: n, emit: a }) {
16
+ n();
17
+ const e = s, l = f(
18
+ r(() => e.show),
17
19
  () => e.zIndex
18
- ), a = t(
19
- () => m({
20
+ ), d = r(
21
+ () => u({
20
22
  "nmorph-overlay": [`${e.show && "show"}`, `${e.transparent && "transparent"}`]
21
23
  })
22
- ), u = () => {
23
- r("on-outside-click");
24
- }, r = i, o = { props: e, zIndex: p, modifiers: a, clickHandler: u, emit: r };
24
+ ), i = () => {
25
+ t("on-outside-click");
26
+ }, t = a, o = { props: e, zIndex: l, modifiers: d, clickHandler: i, emit: t };
25
27
  return Object.defineProperty(o, "__isScriptSetup", { enumerable: !1, value: !0 }), o;
26
28
  }
27
29
  });
28
30
  export {
29
- h as default
31
+ y as default
30
32
  };
@@ -1 +1 @@
1
- .nmorph-notification-provider{position:fixed;inset:0;width:100vw;height:100vh;pointer-events:none}.nmorph-notification-provider .nmorph-notification-provider__notification{width:fit-content;height:fit-content;margin:1rem;pointer-events:all;transition:transform .5s ease,opacity .5s ease-in-out}.nmorph-notification-provider .nmorph-notification-provider__list{display:flex;flex-direction:column;width:fit-content;max-width:100vw;position:fixed;pointer-events:none}.nmorph-notification-provider .nmorph-notification-move{transition:transform .5s ease}.nmorph-notification-provider .nmorph-notification-provider__list--top-left{top:0;left:0;align-items:flex-start}.nmorph-notification-provider .nmorph-notification-provider__list--top-right{top:0;right:0;align-items:flex-end}.nmorph-notification-provider .nmorph-notification-provider__list--bottom-left{bottom:0;left:0;align-items:flex-start}.nmorph-notification-provider .nmorph-notification-provider__list--bottom-right{right:0;bottom:0;align-items:flex-end}.nmorph-notification-provider .nmorph-notification-provider__list--top-center{top:0;left:50%;align-items:center;transform:translate(-50%)}.nmorph-notification-provider .nmorph-notification-provider__list--bottom-center{bottom:0;left:50%;align-items:center;transform:translate(-50%)}.nmorph-notification-provider .nmorph-notification-provider__list--top-left .nmorph-notification-enter-active,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-left .nmorph-notification-enter-active,.nmorph-notification-provider .nmorph-notification-provider__list--top-right .nmorph-notification-enter-active,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-right .nmorph-notification-enter-active,.nmorph-notification-provider .nmorph-notification-provider__list--top-center .nmorph-notification-enter-active,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-center .nmorph-notification-enter-active,.nmorph-notification-provider .nmorph-notification-provider__list--top-left .nmorph-notification-leave-active,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-left .nmorph-notification-leave-active,.nmorph-notification-provider .nmorph-notification-provider__list--top-right .nmorph-notification-leave-active,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-right .nmorph-notification-leave-active,.nmorph-notification-provider .nmorph-notification-provider__list--top-center .nmorph-notification-leave-active,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-center .nmorph-notification-leave-active{transition:transform .5s ease,opacity .5s ease-in-out}.nmorph-notification-provider .nmorph-notification-provider__list--top-left .nmorph-notification-enter-from,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-left .nmorph-notification-enter-from{transform:translate(-100%)}.nmorph-notification-provider .nmorph-notification-provider__list--top-right .nmorph-notification-enter-from,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-right .nmorph-notification-enter-from{transform:translate(100%)}.nmorph-notification-provider .nmorph-notification-provider__list--top-center .nmorph-notification-enter-from{transform:translateY(-100%)}.nmorph-notification-provider .nmorph-notification-provider__list--bottom-center .nmorph-notification-enter-from{transform:translateY(100%)}.nmorph-notification-provider .nmorph-notification-provider__list--top-left .nmorph-notification-leave-to,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-left .nmorph-notification-leave-to{transform:translate(-100%)}.nmorph-notification-provider .nmorph-notification-provider__list--top-right .nmorph-notification-leave-to,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-right .nmorph-notification-leave-to{transform:translate(100%)}.nmorph-notification-provider .nmorph-notification-provider__list--top-center .nmorph-notification-leave-to{transform:translateY(-100%)}.nmorph-notification-provider .nmorph-notification-provider__list--bottom-center .nmorph-notification-leave-to{transform:translateY(100%)}.nmorph-notification-provider .nmorph-notification-enter-from{opacity:0}.nmorph-notification-provider .nmorph-notification-enter-to{transform:translate(0);opacity:1}.nmorph-notification-provider .nmorph-notification-leave-active{overflow:hidden}.nmorph-notification-provider .nmorph-notification-leave-active .nmorph-icon{--color: var(--nmorph-text-color);display:flex;align-items:center;width:var(--width);min-width:var(--width);height:var(--height);min-height:var(--height)}.nmorph-notification-provider .nmorph-notification-leave-active .nmorph-icon--small{--width: 14px;--height: 14px}.nmorph-notification-provider .nmorph-notification-leave-active .nmorph-icon--medium{--width: 20px;--height: 20px}.nmorph-notification-provider .nmorph-notification-leave-active .nmorph-icon--large{--width: 32px;--height: 32px}.nmorph-notification-provider .nmorph-notification-leave-active .nmorph-icon__content{display:flex;align-items:center;justify-content:center;width:var(--width);min-width:var(--width);height:var(--height);min-height:var(--height);overflow:hidden}.nmorph-notification-provider .nmorph-notification-leave-active .nmorph-alert__close .nmorph-icon,.nmorph-notification-provider .nmorph-notification-leave-active .nmorph-alert__content,.nmorph-notification-provider .nmorph-notification-leave-active .nmorph-alert__content-title{--color: var(--nmorph-white-color)}.nmorph-notification-provider .nmorph-notification-leave-active.nmorph-alert--success .nmorph-alert__icon .nmorph-icon{--color: var(--nmorph-success-color)}.nmorph-notification-provider .nmorph-notification-leave-active.nmorph-alert--error .nmorph-alert__icon .nmorph-icon{--color: var(--nmorph-error-color)}.nmorph-notification-provider .nmorph-notification-leave-active.nmorph-alert--warning .nmorph-alert__icon .nmorph-icon{--color: var(--nmorph-warn-color)}.nmorph-notification-provider .nmorph-notification-leave-active.nmorph-alert--info .nmorph-alert__icon .nmorph-icon{--color: var(--nmorph-info-color)}.nmorph-notification-provider .nmorph-notification-leave-active svg{width:100%;height:100%;fill:var(--color);stroke-width:0}.nmorph-notification-provider .nmorph-notification-leave-active path{stroke:var(--color)}.nmorph-notification-provider .nmorph-notification-leave-to{opacity:0;pointer-events:none}.nmorph-notification-provider .nmorph-notification-provider__list--top-left .nmorph-notification-provider__notification--closing,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-left .nmorph-notification-provider__notification--closing{position:absolute;transform:translate(-100%);opacity:0;pointer-events:none}.nmorph-notification-provider .nmorph-notification-provider__list--top-right .nmorph-notification-provider__notification--closing,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-right .nmorph-notification-provider__notification--closing{position:absolute;transform:translate(100%);opacity:0;pointer-events:none}.nmorph-notification-provider .nmorph-notification-provider__list--top-center .nmorph-notification-provider__notification--closing{position:absolute;transform:translateY(-100%);opacity:0;pointer-events:none}.nmorph-notification-provider .nmorph-notification-provider__list--bottom-center .nmorph-notification-provider__notification--closing{position:absolute;transform:translateY(100%);opacity:0;pointer-events:none}
1
+ .nmorph-notification-provider{position:fixed;inset:0;width:100vw;height:100vh;pointer-events:none}.nmorph-notification-provider .nmorph-notification-provider__notification{width:fit-content;height:fit-content;margin:1rem;transition:transform .5s ease,opacity .5s ease-in-out;pointer-events:all}.nmorph-notification-provider .nmorph-notification-provider__list{position:fixed;display:flex;flex-direction:column;width:fit-content;max-width:100vw;pointer-events:none}.nmorph-notification-provider .nmorph-notification-move{transition:transform .5s ease}.nmorph-notification-provider .nmorph-notification-provider__list--top-left{top:0;left:0;align-items:flex-start}.nmorph-notification-provider .nmorph-notification-provider__list--top-right{top:0;right:0;align-items:flex-end}.nmorph-notification-provider .nmorph-notification-provider__list--bottom-left{bottom:0;left:0;align-items:flex-start}.nmorph-notification-provider .nmorph-notification-provider__list--bottom-right{right:0;bottom:0;align-items:flex-end}.nmorph-notification-provider .nmorph-notification-provider__list--top-center{top:0;left:50%;align-items:center;transform:translate(-50%)}.nmorph-notification-provider .nmorph-notification-provider__list--bottom-center{bottom:0;left:50%;align-items:center;transform:translate(-50%)}.nmorph-notification-provider .nmorph-notification-provider__list--top-left .nmorph-notification-enter-active,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-left .nmorph-notification-enter-active,.nmorph-notification-provider .nmorph-notification-provider__list--top-right .nmorph-notification-enter-active,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-right .nmorph-notification-enter-active,.nmorph-notification-provider .nmorph-notification-provider__list--top-center .nmorph-notification-enter-active,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-center .nmorph-notification-enter-active,.nmorph-notification-provider .nmorph-notification-provider__list--top-left .nmorph-notification-leave-active,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-left .nmorph-notification-leave-active,.nmorph-notification-provider .nmorph-notification-provider__list--top-right .nmorph-notification-leave-active,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-right .nmorph-notification-leave-active,.nmorph-notification-provider .nmorph-notification-provider__list--top-center .nmorph-notification-leave-active,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-center .nmorph-notification-leave-active{transition:transform .5s ease,opacity .5s ease-in-out}.nmorph-notification-provider .nmorph-notification-provider__list--top-left .nmorph-notification-enter-from,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-left .nmorph-notification-enter-from{transform:translate(-100%)}.nmorph-notification-provider .nmorph-notification-provider__list--top-right .nmorph-notification-enter-from,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-right .nmorph-notification-enter-from{transform:translate(100%)}.nmorph-notification-provider .nmorph-notification-provider__list--top-center .nmorph-notification-enter-from{transform:translateY(-100%)}.nmorph-notification-provider .nmorph-notification-provider__list--bottom-center .nmorph-notification-enter-from{transform:translateY(100%)}.nmorph-notification-provider .nmorph-notification-provider__list--top-left .nmorph-notification-leave-to,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-left .nmorph-notification-leave-to{transform:translate(-100%)}.nmorph-notification-provider .nmorph-notification-provider__list--top-right .nmorph-notification-leave-to,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-right .nmorph-notification-leave-to{transform:translate(100%)}.nmorph-notification-provider .nmorph-notification-provider__list--top-center .nmorph-notification-leave-to{transform:translateY(-100%)}.nmorph-notification-provider .nmorph-notification-provider__list--bottom-center .nmorph-notification-leave-to{transform:translateY(100%)}.nmorph-notification-provider .nmorph-notification-enter-from{opacity:0}.nmorph-notification-provider .nmorph-notification-enter-to{transform:translate(0);opacity:1}.nmorph-notification-provider .nmorph-notification-leave-active{overflow:hidden}.nmorph-notification-provider .nmorph-notification-leave-active .nmorph-icon{--color: var(--nmorph-text-color);display:flex;align-items:center;width:var(--width);min-width:var(--width);height:var(--height);min-height:var(--height)}.nmorph-notification-provider .nmorph-notification-leave-active .nmorph-icon--small{--width: 14px;--height: 14px}.nmorph-notification-provider .nmorph-notification-leave-active .nmorph-icon--medium{--width: 20px;--height: 20px}.nmorph-notification-provider .nmorph-notification-leave-active .nmorph-icon--large{--width: 32px;--height: 32px}.nmorph-notification-provider .nmorph-notification-leave-active .nmorph-icon__content{display:flex;justify-content:center;align-items:center;width:var(--width);min-width:var(--width);height:var(--height);min-height:var(--height);overflow:hidden}.nmorph-notification-provider .nmorph-notification-leave-active .nmorph-alert__close .nmorph-icon,.nmorph-notification-provider .nmorph-notification-leave-active .nmorph-alert__content,.nmorph-notification-provider .nmorph-notification-leave-active .nmorph-alert__content-title{--color: var(--nmorph-white-color)}.nmorph-notification-provider .nmorph-notification-leave-active.nmorph-alert--success .nmorph-alert__icon .nmorph-icon{--color: var(--nmorph-success-color)}.nmorph-notification-provider .nmorph-notification-leave-active.nmorph-alert--error .nmorph-alert__icon .nmorph-icon{--color: var(--nmorph-error-color)}.nmorph-notification-provider .nmorph-notification-leave-active.nmorph-alert--warning .nmorph-alert__icon .nmorph-icon{--color: var(--nmorph-warn-color)}.nmorph-notification-provider .nmorph-notification-leave-active.nmorph-alert--info .nmorph-alert__icon .nmorph-icon{--color: var(--nmorph-info-color)}.nmorph-notification-provider .nmorph-notification-leave-active svg{width:100%;height:100%;fill:var(--color);stroke-width:0}.nmorph-notification-provider .nmorph-notification-leave-active path{stroke:var(--color)}.nmorph-notification-provider .nmorph-notification-leave-to{opacity:0;pointer-events:none}.nmorph-notification-provider .nmorph-notification-provider__list--top-left .nmorph-notification-provider__notification--closing,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-left .nmorph-notification-provider__notification--closing{position:absolute;transform:translate(-100%);opacity:0;pointer-events:none}.nmorph-notification-provider .nmorph-notification-provider__list--top-right .nmorph-notification-provider__notification--closing,.nmorph-notification-provider .nmorph-notification-provider__list--bottom-right .nmorph-notification-provider__notification--closing{position:absolute;transform:translate(100%);opacity:0;pointer-events:none}.nmorph-notification-provider .nmorph-notification-provider__list--top-center .nmorph-notification-provider__notification--closing{position:absolute;transform:translateY(-100%);opacity:0;pointer-events:none}.nmorph-notification-provider .nmorph-notification-provider__list--bottom-center .nmorph-notification-provider__notification--closing{position:absolute;transform:translateY(100%);opacity:0;pointer-events:none}
@@ -30,9 +30,8 @@ function h(v, u, y, o, k, x) {
30
30
  class: [
31
31
  "nmorph-notification-provider__notification",
32
32
  o.closingIds.includes(r.id) && "nmorph-notification-provider__notification--closing"
33
- ],
34
- ref_for: !0
35
- }, r, {
33
+ ]
34
+ }, { ref_for: !0 }, r, {
36
35
  onClose: () => o.closeHandler(r.id)
37
36
  }), null, 16, ["style", "class", "onClose"]))),
38
37
  128
@@ -1,4 +1,4 @@
1
- import { nmorphCombined as p, nmorphInset as o, nmorphOutset as e, title1 as s, title2 as d, title3 as l, title4 as m, body1 as n, body2 as c, body3 as i, body4 as u } from "../utils/theme-style.js";
1
+ import { nmorphCombined as p, nmorphInset as t, nmorphOutset as e, title1 as s, title2 as d, title3 as l, title4 as m, body1 as n, body2 as c, body3 as i, body4 as u } from "../utils/theme-style.js";
2
2
  const b = {
3
3
  "nmorph-body-4": u,
4
4
  "nmorph-body-3": i,
@@ -9,10 +9,10 @@ const b = {
9
9
  "nmorph-title-2": d,
10
10
  "nmorph-title-1": s,
11
11
  "nmorph--shadow-outset": e,
12
- "nmorph--shadow-inset": o,
12
+ "nmorph--shadow-inset": t,
13
13
  "nmorph--shadow-combined": p
14
- }, g = () => {
15
- let t = `
14
+ }, v = () => {
15
+ let r = `
16
16
  :root {
17
17
  --font-size-tiny: 10px;
18
18
  --font-size-extra-small: 12px;
@@ -186,6 +186,14 @@ const b = {
186
186
  background: var(--nmorph-main-color);
187
187
  }
188
188
 
189
+ :root[nmorph-data-theme='light'] {
190
+ --nmorph-scroll-color-scheme: light;
191
+ }
192
+
193
+ :root[nmorph-data-theme='dark'] {
194
+ --nmorph-scroll-color-scheme: dark;
195
+ }
196
+
189
197
  .nmorph--basic-component {
190
198
  --height: var(--default-thickness-component);
191
199
 
@@ -226,6 +234,13 @@ const b = {
226
234
  color: var(--nmorph-placeholder-text-color);
227
235
  }
228
236
 
237
+ @supports (-webkit-touch-callout: none) {
238
+ .nmorph-native-input {
239
+ font-size: 16px;
240
+ font-size: max(16px, var(--nmorph-ios-native-input-font-size, 16px));
241
+ }
242
+ }
243
+
229
244
  .nmorph--fill {
230
245
  width: 100%;
231
246
  }
@@ -379,7 +394,7 @@ const b = {
379
394
  text-indent: var(--nmorph-text-input-indentation);
380
395
  border: none;
381
396
  border-radius: var(--default-border-radius);
382
- ${o()}
397
+ ${t()}
383
398
  }
384
399
 
385
400
  .nmorph-text-input--with-action input {
@@ -500,6 +515,9 @@ const b = {
500
515
 
501
516
  .nmorph-scroll {
502
517
  --thumb-color: var(--nmorph-scroll-thumb-color, var(--nmorph-text-color));
518
+ color-scheme: var(--nmorph-scroll-color-scheme, light);
519
+ scrollbar-color: var(--thumb-color) transparent;
520
+ scrollbar-width: thin;
503
521
  }
504
522
 
505
523
  .nmorph-scroll::-webkit-scrollbar {
@@ -512,7 +530,7 @@ const b = {
512
530
 
513
531
  .nmorph-scroll::-webkit-scrollbar-track {
514
532
  border-radius: var(--border-radius-40);
515
- ${o()}
533
+ ${t()}
516
534
  }
517
535
 
518
536
  .nmorph-scroll::-webkit-scrollbar-thumb {
@@ -525,14 +543,18 @@ const b = {
525
543
  }
526
544
  `;
527
545
  for (const [a, h] of Object.entries(b))
528
- t += `
546
+ r += `
529
547
  .${a} {
530
548
  ${h()}
531
549
  }
532
550
  `;
533
- const r = document.createElement("style");
534
- r.innerHTML = t, document.head.appendChild(r);
551
+ return r;
552
+ }, x = () => {
553
+ if (typeof document > "u" || document.getElementById("nmorph-common-styles")) return;
554
+ const o = document.createElement("style");
555
+ o.id = "nmorph-common-styles", o.innerHTML = v(), document.head.appendChild(o);
535
556
  };
536
557
  export {
537
- g as useCommonStyles
558
+ v as getCommonStyles,
559
+ x as useCommonStyles
538
560
  };
@@ -1,57 +1,89 @@
1
- import { ref as p, inject as R, watch as S, onMounted as W, onUnmounted as k, nextTick as E } from "vue";
2
- const T = (b) => {
3
- const { initialPlacement: y, relativeElement: s, contentDOMElement: c, yOffset: u = 0, xOffset: v = 0 } = b, e = p(y), r = p({ x: "0px", y: "0px" }), C = R("nmorph"), a = p(null);
4
- S(
5
- () => C.browser,
1
+ import { ref as b, unref as n, inject as T, watch as F, onMounted as U, onUnmounted as X, nextTick as S } from "vue";
2
+ const G = (j) => {
3
+ const { initialPlacement: g, relativeElement: y, contentDOMElement: u, yOffset: L = 0, xOffset: O = 0, enabled: h } = j, R = b(n(g)), C = b({ x: "0px", y: "0px" }), v = b(!1), k = T("nmorph"), P = { passive: !0, capture: !0 };
4
+ let w = null;
5
+ F(
6
+ () => k?.browser,
6
7
  () => {
7
- n();
8
+ o();
8
9
  },
9
10
  { deep: !0 }
10
- ), W(() => {
11
- n(), L(), $(), h.observe(document.body, {
12
- childList: !0,
13
- subtree: !0
14
- }), f();
15
- }), k(() => {
16
- O(), h.disconnect();
17
- });
18
- const f = () => {
19
- E(() => {
20
- c.value && n();
11
+ ), U(() => {
12
+ o(), V(), window.addEventListener("resize", o, { passive: !0 }), w = new MutationObserver(() => {
13
+ M();
14
+ }), w.observe(document.body, { childList: !0, subtree: !0 }), M();
15
+ }), X(() => {
16
+ W(), window.removeEventListener("resize", o), w?.disconnect();
17
+ }), F(
18
+ () => [n(g), n(y), n(O), n(L), n(h)],
19
+ () => {
20
+ o();
21
+ },
22
+ { flush: "post" }
23
+ );
24
+ const M = () => {
25
+ S(() => {
26
+ u.value && o();
21
27
  });
22
- }, h = new MutationObserver(() => {
23
- f();
24
- }), L = () => {
25
- let t = c.value;
26
- for (; t; ) {
27
- const o = window.getComputedStyle(t);
28
- if (o.overflowY === "auto" || o.overflowY === "scroll") {
29
- a.value = t;
30
- break;
31
- }
32
- t = t.parentElement;
33
- }
34
- }, $ = () => {
35
- a.value ? a.value.addEventListener("scroll", n, { passive: !0 }) : window.addEventListener("scroll", n, { passive: !0 });
36
- }, O = () => {
37
- a.value ? a.value.removeEventListener("scroll", n) : window.removeEventListener("scroll", n);
38
- }, n = () => {
39
- E(() => {
40
- if (!c.value || !s) {
41
- console.warn("There is no relative element or content DOM element");
28
+ }, A = () => h === void 0 || n(h) !== !1, q = (e) => {
29
+ const [s, t] = e.split("-");
30
+ return {
31
+ side: s,
32
+ align: t || "start",
33
+ hasAlign: !!t
34
+ };
35
+ }, z = (e, s, t) => t ? `${e}-${s}` : e, B = () => n(y), H = (e, s, t, l, d, r, i) => e === "top" && t - i < 0 ? "bottom" : e === "bottom" && t + d + i > window.innerHeight ? "top" : e === "left" && s - r < 0 ? "right" : e === "right" && s + l + r > window.innerWidth ? "left" : e, V = () => {
36
+ window.addEventListener("scroll", o, P);
37
+ }, W = () => {
38
+ window.removeEventListener("scroll", o, P);
39
+ }, o = () => {
40
+ S(() => {
41
+ if (typeof window > "u") return;
42
+ if (!A()) {
43
+ v.value = !1;
42
44
  return;
43
45
  }
44
- const t = c.value.getBoundingClientRect(), o = t.width, d = t.height, w = "value" in s ? s.value : s;
45
- if (!w) {
46
- console.warn("Relative element is not an HTMLElement");
46
+ const e = B();
47
+ if (!u.value || !e) {
48
+ v.value = !1;
47
49
  return;
48
50
  }
49
- const m = w.getBoundingClientRect(), { x: l, y: i } = m, x = m.width, g = m.height, H = window.innerWidth, M = window.innerHeight;
50
- e.value === "top" && i - d < 0 && (e.value = "bottom"), e.value === "bottom" && i + g + d > M && (e.value = "top"), e.value === "left" && l - o < 0 && (e.value = "right"), e.value === "right" && l + x + o > H && (e.value = "left"), e.value === "top" && (r.value = { x: `${l + v}px`, y: `${i - d + u}px` }), e.value === "bottom" && (r.value = { x: `${l + v}px`, y: `${i + g + u}px` }), e.value === "right" && (r.value = { x: `${l + x + v}px`, y: `${i + u}px` }), e.value === "left" && (r.value = { x: `${l - o + v}px`, y: `${i + u}px` });
51
+ const s = u.value.getBoundingClientRect(), t = s.width, l = s.height, d = e.getBoundingClientRect(), { x: r, y: i } = d, m = d.width, p = d.height, D = n(O) || 0, N = n(L) || 0, f = q(n(g)), a = H(
52
+ f.side,
53
+ r,
54
+ i,
55
+ m,
56
+ p,
57
+ t,
58
+ l
59
+ );
60
+ let E = r, x = i;
61
+ if (a === "top" || a === "bottom") {
62
+ const c = {
63
+ start: r,
64
+ center: r + m / 2 - t / 2,
65
+ end: r + m - t
66
+ };
67
+ E = c[f.align] ?? c.start, x = a === "top" ? i - l : i + p;
68
+ }
69
+ if (a === "left" || a === "right") {
70
+ const c = {
71
+ start: i,
72
+ center: i + p / 2 - l / 2,
73
+ end: i + p - l
74
+ };
75
+ E = a === "left" ? r - t : r + m, x = c[f.align] ?? c.start;
76
+ }
77
+ R.value = z(a, f.align, f.hasAlign), C.value = { x: `${E + D}px`, y: `${x + N}px` }, v.value = !0, typeof requestAnimationFrame == "function" && requestAnimationFrame(() => {
78
+ const c = B();
79
+ if (!u.value || !c || !A()) return;
80
+ const $ = u.value.getBoundingClientRect();
81
+ ($.width !== t || $.height !== l) && o();
82
+ });
51
83
  });
52
84
  };
53
- return { placement: e, placementCoords: r };
85
+ return { placement: R, placementCoords: C, placementReady: v, adjustPlacement: o };
54
86
  };
55
87
  export {
56
- T as usePlacement
88
+ G as usePlacement
57
89
  };