dxd-style-code 0.1.7 → 0.1.8

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 (334) hide show
  1. package/dist/dxd-style-code.js +11974 -3725
  2. package/dist/dxd-style-code.umd.cjs +10 -1
  3. package/dist/style.css +1 -1
  4. package/package.json +13 -6
  5. package/src/components/atoms/DXAvatar/DXAvatar.stories.js +319 -0
  6. package/src/components/atoms/DXAvatar/DXAvatar.vue +167 -0
  7. package/src/components/atoms/DXAvatar/index.js +2 -0
  8. package/src/components/atoms/DXBackdrop/DXBackdrop.stories.js +341 -0
  9. package/src/components/atoms/DXBackdrop/DXBackdrop.vue +102 -0
  10. package/src/components/atoms/DXBackdrop/index.js +2 -0
  11. package/src/components/atoms/DXBadge/DXBadge.stories.js +239 -0
  12. package/src/components/atoms/DXBadge/DXBadge.vue +45 -0
  13. package/src/components/atoms/DXBadge/index.js +2 -0
  14. package/src/components/atoms/DXButton/DXButton.stories.js +178 -0
  15. package/src/components/atoms/DXButton/DXButton.vue +84 -0
  16. package/src/components/atoms/DXButton/index.js +2 -0
  17. package/src/components/atoms/DXCard/DXCard.stories.js +133 -0
  18. package/src/components/atoms/DXCard/DXCard.vue +46 -0
  19. package/src/components/atoms/DXCard/index.js +2 -0
  20. package/src/components/atoms/DXCheckbox/DXCheckbox.stories.js +294 -0
  21. package/src/components/atoms/DXCheckbox/DXCheckbox.vue +191 -0
  22. package/src/components/atoms/DXCheckbox/index.js +2 -0
  23. package/src/components/atoms/DXDivider/DXDivider.stories.js +135 -0
  24. package/src/components/atoms/DXDivider/DXDivider.vue +74 -0
  25. package/src/components/atoms/DXDivider/index.js +2 -0
  26. package/src/components/atoms/DXDropdownItem/DXDropdownItem.vue +116 -0
  27. package/src/components/atoms/DXDropdownItem/index.js +2 -0
  28. package/src/components/atoms/DXFormLabel/DXFormLabel.stories.js +194 -0
  29. package/src/components/atoms/DXFormLabel/DXFormLabel.vue +94 -0
  30. package/src/components/atoms/DXFormLabel/index.js +2 -0
  31. package/src/components/atoms/DXIcon/DXIcon.stories.js +156 -0
  32. package/src/components/atoms/DXIcon/DXIcon.vue +102 -0
  33. package/src/components/atoms/DXIcon/index.js +3 -0
  34. package/src/components/atoms/DXIconWrapper/DXIconWrapper.stories.js +237 -0
  35. package/src/components/atoms/DXIconWrapper/DXIconWrapper.vue +79 -0
  36. package/src/components/atoms/DXIconWrapper/index.js +2 -0
  37. package/src/components/atoms/DXInputAddon/DXInputAddon.stories.js +230 -0
  38. package/src/components/atoms/DXInputAddon/DXInputAddon.vue +64 -0
  39. package/src/components/atoms/DXInputAddon/index.js +2 -0
  40. package/src/components/atoms/DXLink/DXLink.stories.js +475 -0
  41. package/src/components/atoms/DXLink/DXLink.vue +229 -0
  42. package/src/components/atoms/DXLink/index.js +2 -0
  43. package/src/components/atoms/DXLoader/DXLoader.stories.js +280 -0
  44. package/src/components/atoms/DXLoader/DXLoader.vue +78 -0
  45. package/src/components/atoms/DXLoader/index.js +2 -0
  46. package/src/components/atoms/DXProgress/DXProgress.stories.js +312 -0
  47. package/src/components/atoms/DXProgress/DXProgress.vue +85 -0
  48. package/src/components/atoms/DXProgress/index.js +2 -0
  49. package/src/components/atoms/DXQuote/DXQuote.stories.js +255 -0
  50. package/src/components/atoms/DXQuote/DXQuote.vue +97 -0
  51. package/src/components/atoms/DXQuote/index.js +2 -0
  52. package/src/components/atoms/DXRadio/DXRadio.stories.js +277 -0
  53. package/src/components/atoms/DXRadio/DXRadio.vue +144 -0
  54. package/src/components/atoms/DXRadio/index.js +2 -0
  55. package/src/components/atoms/DXSkeleton/DXSkeleton.stories.js +50 -0
  56. package/src/components/atoms/DXSkeleton/DXSkeleton.vue +19 -0
  57. package/src/components/atoms/DXSkeleton/index.js +2 -0
  58. package/src/components/atoms/DXSlider/DXSlider.stories.js +522 -0
  59. package/src/components/atoms/DXSlider/DXSlider.vue +338 -0
  60. package/src/components/atoms/DXSlider/index.js +2 -0
  61. package/src/components/atoms/DXTags/DXTags.stories.js +206 -0
  62. package/src/components/atoms/DXTags/DXTags.vue +111 -0
  63. package/src/components/atoms/DXTags/index.js +2 -0
  64. package/src/components/atoms/DXToast/DXToast.stories.js +40 -0
  65. package/src/components/atoms/DXToast/DXToast.vue +32 -0
  66. package/src/components/atoms/DXToast/index.js +2 -0
  67. package/src/components/atoms/DXToggle/DXToggle.stories.js +143 -0
  68. package/src/components/atoms/DXToggle/DXToggle.vue +142 -0
  69. package/src/components/atoms/DXToggle/index.js +2 -0
  70. package/src/components/atoms/DXToggleButton/DXToggleButton.stories.js +513 -0
  71. package/src/components/atoms/DXToggleButton/DXToggleButton.vue +140 -0
  72. package/src/components/atoms/DXToggleButton/index.js +2 -0
  73. package/src/components/atoms/DXTooltip/DXTooltip.stories.js +243 -0
  74. package/src/components/atoms/DXTooltip/DXTooltip.vue +151 -0
  75. package/src/components/atoms/DXTooltip/index.js +2 -0
  76. package/src/components/atoms/index.js +24 -0
  77. package/src/components/layout/DXBox/DXBox.stories.js +238 -0
  78. package/src/components/layout/DXBox/DXBox.vue +198 -0
  79. package/src/components/layout/DXBox/index.js +2 -0
  80. package/src/components/layout/DXContainer/DXContainer.stories.js +147 -0
  81. package/src/components/layout/DXContainer/DXContainer.vue +83 -0
  82. package/src/components/layout/DXContainer/index.js +2 -0
  83. package/src/components/layout/DXFlex/DXFlex.stories.js +210 -0
  84. package/src/components/layout/DXFlex/DXFlex.vue +149 -0
  85. package/src/components/layout/DXFlex/index.js +2 -0
  86. package/src/components/layout/DXGrid/DXGrid.stories.js +238 -0
  87. package/src/components/layout/DXGrid/DXGrid.vue +167 -0
  88. package/src/components/layout/DXGrid/index.js +2 -0
  89. package/src/components/layout/DXSpacer/DXSpacer.stories.js +187 -0
  90. package/src/components/layout/DXSpacer/DXSpacer.vue +102 -0
  91. package/src/components/layout/DXSpacer/index.js +2 -0
  92. package/src/components/layout/DXStack/DXStack.stories.js +199 -0
  93. package/src/components/layout/DXStack/DXStack.vue +140 -0
  94. package/src/components/layout/DXStack/index.js +2 -0
  95. package/src/components/layout/index.js +8 -0
  96. package/src/components/molecules/DXActionButtons/DXActionButtons.stories.js +288 -0
  97. package/src/components/molecules/DXActionButtons/DXActionButtons.vue +106 -0
  98. package/src/components/molecules/DXActionButtons/index.js +2 -0
  99. package/src/components/molecules/DXAlert/DXAlert.stories.js +70 -0
  100. package/src/components/molecules/DXAlert/DXAlert.vue +116 -0
  101. package/src/components/molecules/DXAlert/index.js +2 -0
  102. package/src/components/molecules/DXBaseTable/DXBaseTable.stories.js +433 -0
  103. package/src/components/molecules/DXBaseTable/DXBaseTable.vue +459 -0
  104. package/src/components/molecules/DXBaseTable/index.js +4 -0
  105. package/src/components/molecules/DXBreadcrumb/DXBreadcrumb.stories.js +227 -0
  106. package/src/components/molecules/DXBreadcrumb/DXBreadcrumb.vue +96 -0
  107. package/src/components/molecules/DXBreadcrumb/index.js +2 -0
  108. package/src/components/molecules/DXButtonGroup/DXButtonGroup.stories.js +26 -0
  109. package/src/components/molecules/DXButtonGroup/DXButtonGroup.vue +78 -0
  110. package/src/components/molecules/DXButtonGroup/index.js +2 -0
  111. package/src/components/molecules/DXCloseButton/DXCloseButton.stories.js +53 -0
  112. package/src/components/molecules/DXCloseButton/DXCloseButton.vue +62 -0
  113. package/src/components/molecules/DXCloseButton/index.js +3 -0
  114. package/src/components/molecules/DXComboBox/DXComboBox.stories.js +62 -0
  115. package/src/components/molecules/DXComboBox/DXComboBox.vue +167 -0
  116. package/src/components/molecules/DXComboBox/index.js +2 -0
  117. package/src/components/molecules/DXCopyField/DXCopyField.stories.js +231 -0
  118. package/src/components/molecules/DXCopyField/DXCopyField.vue +75 -0
  119. package/src/components/molecules/DXCopyField/index.js +2 -0
  120. package/src/components/molecules/DXDataFilter/DXDataFilter.stories.js +275 -0
  121. package/src/components/molecules/DXDataFilter/DXDataFilter.vue +385 -0
  122. package/src/components/molecules/DXDataFilter/index.js +2 -0
  123. package/src/components/molecules/DXDatePicker/DXDatePicker.stories.js +42 -0
  124. package/src/components/molecules/DXDatePicker/DXDatePicker.vue +121 -0
  125. package/src/components/molecules/DXDatePicker/index.js +2 -0
  126. package/src/components/molecules/DXDropdownDivider/DXDropdownDivider.vue +30 -0
  127. package/src/components/molecules/DXDropdownDivider/index.js +2 -0
  128. package/src/components/molecules/DXFileUpload/DXFileUpload.stories.js +53 -0
  129. package/src/components/molecules/DXFileUpload/DXFileUpload.vue +199 -0
  130. package/src/components/molecules/DXFileUpload/index.js +2 -0
  131. package/src/components/molecules/DXFilterGroup/DXFilterGroup.stories.js +43 -0
  132. package/src/components/molecules/DXFilterGroup/DXFilterGroup.vue +43 -0
  133. package/src/components/molecules/DXFilterGroup/index.js +2 -0
  134. package/src/components/molecules/DXFormControl/DXFormControl.stories.js +69 -0
  135. package/src/components/molecules/DXFormControl/DXFormControl.vue +72 -0
  136. package/src/components/molecules/DXFormControl/index.js +2 -0
  137. package/src/components/molecules/DXInput/DXInput.stories.js +291 -0
  138. package/src/components/molecules/DXInput/DXInput.vue +156 -0
  139. package/src/components/molecules/DXInput/index.js +3 -0
  140. package/src/components/molecules/DXInputGroup/DXInputGroup.stories.js +228 -0
  141. package/src/components/molecules/DXInputGroup/DXInputGroup.vue +64 -0
  142. package/src/components/molecules/DXInputGroup/index.js +2 -0
  143. package/src/components/molecules/DXInputMask/DXInputMask.stories.js +53 -0
  144. package/src/components/molecules/DXInputMask/DXInputMask.vue +89 -0
  145. package/src/components/molecules/DXInputMask/index.js +2 -0
  146. package/src/components/molecules/DXMenu/DXMenu.stories.js +379 -0
  147. package/src/components/molecules/DXMenu/DXMenu.vue +331 -0
  148. package/src/components/molecules/DXMenu/README.md +479 -0
  149. package/src/components/molecules/DXMenu/index.js +2 -0
  150. package/src/components/molecules/DXPagination/DXPagination.stories.js +62 -0
  151. package/src/components/molecules/DXPagination/DXPagination.vue +123 -0
  152. package/src/components/molecules/DXPagination/index.js +2 -0
  153. package/src/components/molecules/DXPasswordInput/DXPasswordInput.stories.js +42 -0
  154. package/src/components/molecules/DXPasswordInput/DXPasswordInput.vue +74 -0
  155. package/src/components/molecules/DXPasswordInput/index.js +2 -0
  156. package/src/components/molecules/DXRadioCard/DXRadioCard.stories.js +60 -0
  157. package/src/components/molecules/DXRadioCard/DXRadioCard.vue +71 -0
  158. package/src/components/molecules/DXRadioCard/index.js +2 -0
  159. package/src/components/molecules/DXRadioGroup/DXRadioGroup.stories.js +297 -0
  160. package/src/components/molecules/DXRadioGroup/DXRadioGroup.vue +73 -0
  161. package/src/components/molecules/DXRadioGroup/index.js +2 -0
  162. package/src/components/molecules/DXRating/DXRating.stories.js +322 -0
  163. package/src/components/molecules/DXRating/DXRating.vue +402 -0
  164. package/src/components/molecules/DXRating/index.js +2 -0
  165. package/src/components/molecules/DXSearchBar/DXSearchBar.stories.js +357 -0
  166. package/src/components/molecules/DXSearchBar/DXSearchBar.vue +525 -0
  167. package/src/components/molecules/DXSearchBar/index.js +2 -0
  168. package/src/components/molecules/DXSearchSelect/DXSearchSelect.stories.js +50 -0
  169. package/src/components/molecules/DXSearchSelect/DXSearchSelect.vue +207 -0
  170. package/src/components/molecules/DXSearchSelect/index.js +2 -0
  171. package/src/components/molecules/DXSegmentedControl/DXSegmentedControl.stories.js +326 -0
  172. package/src/components/molecules/DXSegmentedControl/DXSegmentedControl.vue +116 -0
  173. package/src/components/molecules/DXSegmentedControl/index.js +2 -0
  174. package/src/components/molecules/DXSelect/DXSelect.stories.js +259 -0
  175. package/src/components/molecules/DXSelect/DXSelect.vue +149 -0
  176. package/src/components/molecules/DXSelect/index.js +3 -0
  177. package/src/components/molecules/DXStatCard/DXStatCard.stories.js +335 -0
  178. package/src/components/molecules/DXStatCard/DXStatCard.vue +309 -0
  179. package/src/components/molecules/DXStatCard/index.js +2 -0
  180. package/src/components/molecules/DXTableFiltersPanel/DXTableFiltersPanel.vue +72 -0
  181. package/src/components/molecules/DXTableFiltersPanel/index.js +7 -0
  182. package/src/components/molecules/DXTablePagination/DXTablePagination.stories.js +236 -0
  183. package/src/components/molecules/DXTablePagination/DXTablePagination.vue +93 -0
  184. package/src/components/molecules/DXTablePagination/index.js +2 -0
  185. package/src/components/molecules/DXTableToolbar/DXTableToolbar.stories.js +271 -0
  186. package/src/components/molecules/DXTableToolbar/DXTableToolbar.vue +102 -0
  187. package/src/components/molecules/DXTableToolbar/index.js +2 -0
  188. package/src/components/molecules/DXTextarea/DXTextarea.stories.js +239 -0
  189. package/src/components/molecules/DXTextarea/DXTextarea.vue +158 -0
  190. package/src/components/molecules/DXTextarea/index.js +3 -0
  191. package/src/components/molecules/DXTimePicker/DXTimePicker.stories.js +282 -0
  192. package/src/components/molecules/DXTimePicker/DXTimePicker.vue +640 -0
  193. package/src/components/molecules/DXTimePicker/index.js +2 -0
  194. package/src/components/molecules/DXValidationIcon/DXValidationIcon.stories.js +60 -0
  195. package/src/components/molecules/DXValidationIcon/DXValidationIcon.vue +53 -0
  196. package/src/components/molecules/DXValidationIcon/index.js +3 -0
  197. package/src/components/molecules/index.js +34 -0
  198. package/src/components/organisms/DXAccordion/DXAccordion.stories.js +33 -0
  199. package/src/components/organisms/DXAccordion/DXAccordion.vue +104 -0
  200. package/src/components/organisms/DXAccordion/index.js +2 -0
  201. package/src/components/organisms/DXAppLayout/DXAppLayout.stories.js +689 -0
  202. package/src/components/organisms/DXAppLayout/DXAppLayout.vue +460 -0
  203. package/src/components/organisms/DXAppLayout/index.js +2 -0
  204. package/src/components/organisms/DXAuthenticationForm/DXAuthenticationForm.stories.js +232 -0
  205. package/src/components/organisms/DXAuthenticationForm/DXAuthenticationForm.vue +458 -0
  206. package/src/components/organisms/DXAuthenticationForm/index.js +2 -0
  207. package/src/components/organisms/DXChartContainer/DXChartContainer.stories.js +286 -0
  208. package/src/components/organisms/DXChartContainer/DXChartContainer.vue +273 -0
  209. package/src/components/organisms/DXChartContainer/index.js +2 -0
  210. package/src/components/organisms/DXChatInterface/DXChatInterface.stories.js +164 -0
  211. package/src/components/organisms/DXChatInterface/DXChatInterface.vue +583 -0
  212. package/src/components/organisms/DXChatInterface/index.js +2 -0
  213. package/src/components/organisms/DXCommentSection/DXCommentSection.stories.js +173 -0
  214. package/src/components/organisms/DXCommentSection/DXCommentSection.vue +487 -0
  215. package/src/components/organisms/DXCommentSection/index.js +2 -0
  216. package/src/components/organisms/DXDashboardGrid/DXDashboardGrid.stories.js +331 -0
  217. package/src/components/organisms/DXDashboardGrid/DXDashboardGrid.vue +309 -0
  218. package/src/components/organisms/DXDashboardGrid/index.js +2 -0
  219. package/src/components/organisms/DXDashboardWidget/DXDashboardWidget.stories.js +271 -0
  220. package/src/components/organisms/DXDashboardWidget/DXDashboardWidget.vue +260 -0
  221. package/src/components/organisms/DXDashboardWidget/index.js +2 -0
  222. package/src/components/organisms/DXDataTable/DXDataTable.stories.js +247 -0
  223. package/src/components/organisms/DXDataTable/DXDataTable.vue +496 -0
  224. package/src/components/organisms/DXDataTable/index.js +2 -0
  225. package/src/components/organisms/DXDropdown/DXDropdown.stories.js +795 -0
  226. package/src/components/organisms/DXDropdown/DXDropdown.vue +238 -0
  227. package/src/components/organisms/DXDropdown/index.js +2 -0
  228. package/src/components/organisms/DXEmptyState/DXEmptyState.stories.js +37 -0
  229. package/src/components/organisms/DXEmptyState/DXEmptyState.vue +41 -0
  230. package/src/components/organisms/DXEmptyState/index.js +2 -0
  231. package/src/components/organisms/DXFormWizard/DXFormWizard.stories.js +378 -0
  232. package/src/components/organisms/DXFormWizard/DXFormWizard.vue +578 -0
  233. package/src/components/organisms/DXFormWizard/index.js +2 -0
  234. package/src/components/organisms/DXHeaderBar/DXHeaderBar.stories.js +448 -0
  235. package/src/components/organisms/DXHeaderBar/DXHeaderBar.vue +190 -0
  236. package/src/components/organisms/DXHeaderBar/index.js +2 -0
  237. package/src/components/organisms/DXMediaGallery/DXMediaGallery.stories.js +347 -0
  238. package/src/components/organisms/DXMediaGallery/DXMediaGallery.vue +422 -0
  239. package/src/components/organisms/DXMediaGallery/index.js +2 -0
  240. package/src/components/organisms/DXModal/DXModal.stories.js +138 -0
  241. package/src/components/organisms/DXModal/DXModal.vue +213 -0
  242. package/src/components/organisms/DXModal/index.js +2 -0
  243. package/src/components/organisms/DXNotificationCenter/DXNotificationCenter.stories.js +183 -0
  244. package/src/components/organisms/DXNotificationCenter/DXNotificationCenter.vue +566 -0
  245. package/src/components/organisms/DXNotificationCenter/index.js +2 -0
  246. package/src/components/organisms/DXReportGenerator/DXReportGenerator.stories.js +199 -0
  247. package/src/components/organisms/DXReportGenerator/DXReportGenerator.vue +344 -0
  248. package/src/components/organisms/DXReportGenerator/index.js +2 -0
  249. package/src/components/organisms/DXSettingsPanel/DXSettingsPanel.stories.js +245 -0
  250. package/src/components/organisms/DXSettingsPanel/DXSettingsPanel.vue +454 -0
  251. package/src/components/organisms/DXSettingsPanel/index.js +2 -0
  252. package/src/components/organisms/DXSidebar/DXSidebar.stories.js +316 -0
  253. package/src/components/organisms/DXSidebar/DXSidebar.vue +212 -0
  254. package/src/components/organisms/DXSidebar/index.js +2 -0
  255. package/src/components/organisms/DXSidebarMenu/DATA_STRUCTURE.md +299 -0
  256. package/src/components/organisms/DXSidebarMenu/DXSidebarMenu.stories.js +729 -0
  257. package/src/components/organisms/DXSidebarMenu/DXSidebarMenu.vue +257 -0
  258. package/src/components/organisms/DXSidebarMenu/DXSidebarMenuItem.vue +249 -0
  259. package/src/components/organisms/DXSidebarMenu/README.md +333 -0
  260. package/src/components/organisms/DXSidebarMenu/index.js +3 -0
  261. package/src/components/organisms/DXTable/DXTable.stories.js +550 -0
  262. package/src/components/organisms/DXTable/DXTable.vue +324 -0
  263. package/src/components/organisms/DXTable/index.js +2 -0
  264. package/src/components/organisms/DXTabs/DXTabs.stories.js +407 -0
  265. package/src/components/organisms/DXTabs/DXTabs.vue +301 -0
  266. package/src/components/organisms/DXTabs/index.js +2 -0
  267. package/src/components/organisms/DXUserProfileCard/DXUserProfileCard.stories.js +194 -0
  268. package/src/components/organisms/DXUserProfileCard/DXUserProfileCard.vue +403 -0
  269. package/src/components/organisms/DXUserProfileCard/index.js +2 -0
  270. package/src/components/organisms/DXWizard/DXWizard.stories.js +212 -0
  271. package/src/components/organisms/DXWizard/DXWizard.vue +615 -0
  272. package/src/components/organisms/DXWizard/index.js +2 -0
  273. package/src/components/organisms/index.js +25 -0
  274. package/src/components/typography/DXBlockquote/DXBlockquote.stories.js +33 -0
  275. package/src/components/typography/DXBlockquote/DXBlockquote.vue +44 -0
  276. package/src/components/typography/DXBlockquote/index.js +2 -0
  277. package/src/components/typography/DXCode/DXCode.stories.js +29 -0
  278. package/src/components/typography/DXCode/DXCode.vue +46 -0
  279. package/src/components/typography/DXCode/index.js +2 -0
  280. package/src/components/typography/DXHeading/DXHeading.stories.js +54 -0
  281. package/src/components/typography/DXHeading/DXHeading.vue +68 -0
  282. package/src/components/typography/DXHeading/index.js +2 -0
  283. package/src/components/typography/DXLabel/DXLabel.stories.js +40 -0
  284. package/src/components/typography/DXLabel/DXLabel.vue +49 -0
  285. package/src/components/typography/DXLabel/index.js +2 -0
  286. package/src/components/typography/DXList/DXList.stories.js +50 -0
  287. package/src/components/typography/DXList/DXList.vue +55 -0
  288. package/src/components/typography/DXList/index.js +2 -0
  289. package/src/components/typography/DXText/DXText.stories.js +47 -0
  290. package/src/components/typography/DXText/DXText.vue +67 -0
  291. package/src/components/typography/DXText/index.js +2 -0
  292. package/src/components/typography/index.js +8 -0
  293. package/src/components/utilities/DXAnimatePresence/DXAnimatePresence.stories.js +335 -0
  294. package/src/components/utilities/DXAnimatePresence/DXAnimatePresence.vue +207 -0
  295. package/src/components/utilities/DXAnimatePresence/index.js +2 -0
  296. package/src/components/utilities/DXBreakpointProvider/DXBreakpointProvider.stories.js +321 -0
  297. package/src/components/utilities/DXBreakpointProvider/DXBreakpointProvider.vue +158 -0
  298. package/src/components/utilities/DXBreakpointProvider/index.js +2 -0
  299. package/src/components/utilities/DXObserver/DXObserver.stories.js +324 -0
  300. package/src/components/utilities/DXObserver/DXObserver.vue +182 -0
  301. package/src/components/utilities/DXObserver/index.js +2 -0
  302. package/src/components/utilities/DXPortal/DXPortal.stories.js +267 -0
  303. package/src/components/utilities/DXPortal/DXPortal.vue +69 -0
  304. package/src/components/utilities/DXPortal/index.js +2 -0
  305. package/src/components/utilities/DXStaggeredAnimation/DXStaggeredAnimation.stories.js +339 -0
  306. package/src/components/utilities/DXStaggeredAnimation/DXStaggeredAnimation.vue +155 -0
  307. package/src/components/utilities/DXStaggeredAnimation/index.js +2 -0
  308. package/src/components/utilities/DXThemeProvider/DXThemeProvider.stories.js +327 -0
  309. package/src/components/utilities/DXThemeProvider/DXThemeProvider.vue +227 -0
  310. package/src/components/utilities/DXThemeProvider/index.js +2 -0
  311. package/src/components/utilities/DXTransitionGroup/DXTransitionGroup.stories.js +368 -0
  312. package/src/components/utilities/DXTransitionGroup/DXTransitionGroup.vue +212 -0
  313. package/src/components/utilities/DXTransitionGroup/index.js +2 -0
  314. package/src/components/utilities/index.js +9 -0
  315. package/src/composables/useAnimation.js +264 -0
  316. package/src/composables/useClassComposition.js +35 -0
  317. package/src/composables/useDataAttributes.js +83 -0
  318. package/src/composables/useMenu.js +88 -0
  319. package/src/composables/useSize.js +135 -0
  320. package/src/composables/useSpacing.js +37 -0
  321. package/src/composables/useTableColumns.js +88 -0
  322. package/src/composables/useTableData.js +82 -0
  323. package/src/composables/useTableFilter.js +158 -0
  324. package/src/composables/useTablePagination.js +89 -0
  325. package/src/composables/useTableSelection.js +77 -0
  326. package/src/composables/useTableSort.js +75 -0
  327. package/src/composables/useTabsScroll.js +88 -0
  328. package/src/composables/useVariant.js +700 -0
  329. package/src/index.js +86 -0
  330. package/src/styles/animations.css +171 -0
  331. package/src/styles/index.css +99 -0
  332. package/src/styles/tokens.js +123 -0
  333. package/src/utils/propTypes.js +77 -0
  334. package/src/utils/toggleButtonPresets.js +115 -0
@@ -0,0 +1,331 @@
1
+ import { ref } from 'vue';
2
+ import DXDashboardGrid from './DXDashboardGrid.vue';
3
+ import DXStatCard from '../../molecules/DXStatCard/DXStatCard.vue';
4
+ import DXCard from '../../atoms/DXCard/DXCard.vue';
5
+ import DXButton from '../../atoms/DXButton/DXButton.vue';
6
+ import { UserGroupIcon, ChartBarIcon, CurrencyDollarIcon } from '@heroicons/vue/24/outline';
7
+
8
+ export default {
9
+ title: 'Organisms/DXDashboardGrid',
10
+ component: DXDashboardGrid,
11
+ tags: ['autodocs'],
12
+ parameters: {
13
+ docs: {
14
+ description: {
15
+ component: `
16
+ # DXDashboardGrid
17
+
18
+ Сетка для дашборда с поддержкой drag-and-drop для перестановки виджетов.
19
+
20
+ ## Назначение
21
+
22
+ DXDashboardGrid предоставляет настраиваемую сетку для создания дашбордов с виджетами.
23
+ Поддерживает перестановку виджетов через drag-and-drop и изменение их размеров.
24
+
25
+ ## Архитектура
26
+
27
+ ### Использует
28
+ - \`vue-draggable-next\` - для drag-and-drop функциональности
29
+ - \`DXStatCard\` - для карточек статистики (через slot)
30
+ - \`useClassComposition\` composable - для стилей
31
+ - \`useSpacing\` composable - для отступов
32
+
33
+ ### Используется в
34
+ - Настраиваемые дашборды
35
+ - Панели мониторинга
36
+ - Аналитические панели
37
+
38
+ ## Внутренняя логика
39
+
40
+ ### Grid Layout
41
+ Использует CSS Grid для размещения виджетов. Каждый виджет занимает определенное
42
+ количество колонок (w) и строк (h).
43
+
44
+ ### Drag-and-Drop
45
+ Виджеты можно перетаскивать за handle (иконка в правом верхнем углу).
46
+ При перетаскивании вычисляется новая позиция виджета.
47
+
48
+ ### Размеры виджетов
49
+ Каждый виджет имеет свойства w (ширина в колонках) и h (высота в строках).
50
+
51
+ ## Особенности
52
+
53
+ ### Редактируемый режим
54
+ При \`editable={false}\` drag-and-drop отключается, виджеты становятся статичными.
55
+
56
+ ### Кастомные виджеты
57
+ Используйте slot \`widget\` для кастомного отображения виджетов.
58
+
59
+ ### События
60
+ Компонент эмитит события при перемещении, добавлении и удалении виджетов.
61
+ `,
62
+ },
63
+ },
64
+ },
65
+ argTypes: {
66
+ columns: {
67
+ control: 'number',
68
+ min: 1,
69
+ max: 12,
70
+ description: 'Количество колонок в сетке.',
71
+ table: {
72
+ type: { summary: 'number' },
73
+ defaultValue: { summary: '12' },
74
+ category: 'Layout',
75
+ },
76
+ },
77
+ rowHeight: {
78
+ control: 'number',
79
+ min: 50,
80
+ max: 200,
81
+ step: 10,
82
+ description: 'Высота строки в пикселях.',
83
+ table: {
84
+ type: { summary: 'number' },
85
+ defaultValue: { summary: '100' },
86
+ category: 'Layout',
87
+ },
88
+ },
89
+ editable: {
90
+ control: 'boolean',
91
+ description: 'Редактируемый режим (drag-and-drop включен).',
92
+ table: {
93
+ type: { summary: 'boolean' },
94
+ defaultValue: { summary: 'true' },
95
+ category: 'Behavior',
96
+ },
97
+ },
98
+ },
99
+ };
100
+
101
+ const defaultWidgets = [
102
+ {
103
+ id: 1,
104
+ w: 4,
105
+ h: 2,
106
+ type: 'stat',
107
+ title: 'Пользователи',
108
+ config: { title: 'Всего', value: 1250, icon: UserGroupIcon },
109
+ },
110
+ {
111
+ id: 2,
112
+ w: 4,
113
+ h: 2,
114
+ type: 'stat',
115
+ title: 'Продажи',
116
+ config: { title: 'Сегодня', value: 45230, icon: ChartBarIcon },
117
+ },
118
+ {
119
+ id: 3,
120
+ w: 4,
121
+ h: 2,
122
+ type: 'stat',
123
+ title: 'Доход',
124
+ config: { title: 'За месяц', value: 125000, icon: CurrencyDollarIcon },
125
+ },
126
+ {
127
+ id: 4,
128
+ w: 6,
129
+ h: 3,
130
+ type: 'chart',
131
+ title: 'График продаж',
132
+ },
133
+ {
134
+ id: 5,
135
+ w: 6,
136
+ h: 3,
137
+ type: 'table',
138
+ title: 'Последние заказы',
139
+ },
140
+ ];
141
+
142
+ export const Default = {
143
+ args: {
144
+ columns: 12,
145
+ rowHeight: 100,
146
+ editable: true,
147
+ },
148
+ parameters: {
149
+ docs: {
150
+ description: {
151
+ story: 'Базовый дашборд с виджетами. Перетаскивайте виджеты за иконку в правом верхнем углу.',
152
+ },
153
+ },
154
+ },
155
+ render: (args) => ({
156
+ components: { DXDashboardGrid, DXStatCard, DXCard },
157
+ setup() {
158
+ const widgets = ref([...defaultWidgets]);
159
+ return { args, widgets };
160
+ },
161
+ template: `
162
+ <DXDashboardGrid v-bind="args" v-model:widgets="widgets">
163
+ <template #widget="{ widget }">
164
+ <DXCard v-if="widget.type === 'stat'" class="h-full">
165
+ <DXStatCard
166
+ :title="widget.config.title"
167
+ :value="widget.config.value"
168
+ :icon="widget.config.icon"
169
+ />
170
+ </DXCard>
171
+ <DXCard v-else class="h-full p-4">
172
+ <h3 class="font-semibold mb-2">{{ widget.title }}</h3>
173
+ <p class="text-sm text-slate-600">Контент виджета {{ widget.type }}</p>
174
+ </DXCard>
175
+ </template>
176
+ </DXDashboardGrid>
177
+ `,
178
+ }),
179
+ };
180
+
181
+ export const WithStatCards = {
182
+ parameters: {
183
+ docs: {
184
+ description: {
185
+ story: 'Дашборд с карточками статистики. Использует DXStatCard для отображения метрик.',
186
+ },
187
+ },
188
+ },
189
+ render: () => ({
190
+ components: { DXDashboardGrid, DXStatCard, DXCard },
191
+ setup() {
192
+ const widgets = ref([
193
+ {
194
+ id: 1,
195
+ w: 3,
196
+ h: 2,
197
+ type: 'stat',
198
+ config: {
199
+ title: 'Всего пользователей',
200
+ value: 1250,
201
+ icon: UserGroupIcon,
202
+ },
203
+ },
204
+ {
205
+ id: 2,
206
+ w: 3,
207
+ h: 2,
208
+ type: 'stat',
209
+ config: {
210
+ title: 'Продажи',
211
+ value: 45230,
212
+ valueFormat: 'currency',
213
+ currency: 'USD',
214
+ trend: { value: 12.5, direction: 'up' },
215
+ icon: ChartBarIcon,
216
+ },
217
+ },
218
+ {
219
+ id: 3,
220
+ w: 3,
221
+ h: 2,
222
+ type: 'stat',
223
+ config: {
224
+ title: 'Конверсия',
225
+ value: 24.5,
226
+ valueFormat: 'percentage',
227
+ trend: { value: 3.2, direction: 'up' },
228
+ icon: CurrencyDollarIcon,
229
+ color: 'success',
230
+ },
231
+ },
232
+ {
233
+ id: 4,
234
+ w: 3,
235
+ h: 2,
236
+ type: 'stat',
237
+ config: {
238
+ title: 'Новые заказы',
239
+ value: 89,
240
+ icon: UserGroupIcon,
241
+ color: 'primary',
242
+ },
243
+ },
244
+ ]);
245
+ return { widgets };
246
+ },
247
+ template: `
248
+ <DXDashboardGrid :widgets="widgets" :columns="12" :row-height="120">
249
+ <template #widget="{ widget }">
250
+ <DXCard class="h-full">
251
+ <DXStatCard
252
+ :title="widget.config.title"
253
+ :value="widget.config.value"
254
+ :value-format="widget.config.valueFormat"
255
+ :currency="widget.config.currency"
256
+ :trend="widget.config.trend"
257
+ :icon="widget.config.icon"
258
+ :color="widget.config.color"
259
+ />
260
+ </DXCard>
261
+ </template>
262
+ </DXDashboardGrid>
263
+ `,
264
+ }),
265
+ };
266
+
267
+ export const ReadOnly = {
268
+ args: {
269
+ columns: 12,
270
+ rowHeight: 100,
271
+ editable: false,
272
+ },
273
+ parameters: {
274
+ docs: {
275
+ description: {
276
+ story: 'Дашборд в режиме только для чтения. Drag-and-drop отключен.',
277
+ },
278
+ },
279
+ },
280
+ render: (args) => ({
281
+ components: { DXDashboardGrid, DXCard },
282
+ setup() {
283
+ const widgets = ref([...defaultWidgets]);
284
+ return { args, widgets };
285
+ },
286
+ template: `
287
+ <DXDashboardGrid v-bind="args" v-model:widgets="widgets">
288
+ <template #widget="{ widget }">
289
+ <DXCard class="h-full p-4">
290
+ <h3 class="font-semibold mb-2">{{ widget.title }}</h3>
291
+ <p class="text-sm text-slate-600">Виджет {{ widget.type }}</p>
292
+ </DXCard>
293
+ </template>
294
+ </DXDashboardGrid>
295
+ `,
296
+ }),
297
+ };
298
+
299
+ export const CustomSizes = {
300
+ parameters: {
301
+ docs: {
302
+ description: {
303
+ story: 'Дашборд с различными размерами виджетов. Виджеты имеют разные значения w и h.',
304
+ },
305
+ },
306
+ },
307
+ render: () => ({
308
+ components: { DXDashboardGrid, DXCard },
309
+ setup() {
310
+ const widgets = ref([
311
+ { id: 1, w: 6, h: 2, title: 'Большой виджет 1' },
312
+ { id: 2, w: 3, h: 2, title: 'Маленький виджет 1' },
313
+ { id: 3, w: 3, h: 2, title: 'Маленький виджет 2' },
314
+ { id: 4, w: 4, h: 4, title: 'Высокий виджет' },
315
+ { id: 5, w: 8, h: 2, title: 'Широкий виджет' },
316
+ ]);
317
+ return { widgets };
318
+ },
319
+ template: `
320
+ <DXDashboardGrid :widgets="widgets" :columns="12" :row-height="100">
321
+ <template #widget="{ widget }">
322
+ <DXCard class="h-full p-4">
323
+ <h3 class="font-semibold mb-2">{{ widget.title }}</h3>
324
+ <p class="text-sm text-slate-600">Размер: {{ widget.w }}x{{ widget.h }}</p>
325
+ </DXCard>
326
+ </template>
327
+ </DXDashboardGrid>
328
+ `,
329
+ }),
330
+ };
331
+
@@ -0,0 +1,309 @@
1
+ <template>
2
+ <div
3
+ :class="gridClasses"
4
+ :style="gridStyles"
5
+ data-component="DXDashboardGrid"
6
+ :data-columns="columns"
7
+ :data-editable="editable"
8
+ >
9
+ <vuedraggable
10
+ v-model="internalWidgets"
11
+ :animation="200"
12
+ :disabled="!editable"
13
+ handle=".drag-handle"
14
+ :group="{ name: 'widgets', pull: false, put: false }"
15
+ item-key="id"
16
+ @start="handleDragStart"
17
+ @end="handleDragEnd"
18
+ @change="handleDragChange"
19
+ >
20
+ <template #item="{ element: widget }">
21
+ <div
22
+ :class="widgetClasses"
23
+ :style="widgetStyles(widget)"
24
+ >
25
+ <div v-if="editable" class="drag-handle absolute top-2 right-2 z-10 cursor-move">
26
+ <DXIcon
27
+ :icon="Bars3Icon"
28
+ size="sm"
29
+ class="text-slate-400 hover:text-slate-600"
30
+ />
31
+ </div>
32
+ <slot name="widget" :widget="widget">
33
+ <div class="p-4 bg-white border border-slate-200 rounded-lg h-full">
34
+ <h3 class="font-semibold mb-2">{{ widget.title || `Виджет ${widget.id}` }}</h3>
35
+ <p class="text-sm text-slate-600">Используйте slot widget для кастомного контента</p>
36
+ </div>
37
+ </slot>
38
+ </div>
39
+ </template>
40
+ </vuedraggable>
41
+ </div>
42
+ </template>
43
+
44
+ <script setup>
45
+ import { ref, computed, watch } from "vue";
46
+ import { useClassComposition } from "@/composables/useClassComposition";
47
+ import { useSpacing } from "@/composables/useSpacing";
48
+ import { VueDraggableNext as vuedraggable } from "vue-draggable-next";
49
+ import DXIcon from "../../atoms/DXIcon/DXIcon.vue";
50
+ import { Bars3Icon } from "@heroicons/vue/24/outline";
51
+
52
+ const props = defineProps({
53
+ /**
54
+ * Массив виджетов (v-model)
55
+ * Формат: [{ id, x, y, w, h, type, title?, config? }]
56
+ */
57
+ widgets: {
58
+ type: Array,
59
+ required: true,
60
+ default: () => [],
61
+ },
62
+ /**
63
+ * Количество колонок в сетке
64
+ * @default 12
65
+ */
66
+ columns: { type: Number, default: 12 },
67
+ /**
68
+ * Высота строки в пикселях
69
+ * @default 100
70
+ */
71
+ rowHeight: { type: Number, default: 100 },
72
+ /**
73
+ * Редактируемый режим (drag-and-drop включен)
74
+ * @default true
75
+ */
76
+ editable: { type: Boolean, default: true },
77
+ /**
78
+ * Отступ между виджетами: none | xs | sm | md | lg | xl
79
+ * @default 'md'
80
+ */
81
+ gap: {
82
+ type: String,
83
+ default: "md",
84
+ validator: (v) => ["none", "xs", "sm", "md", "lg", "xl"].includes(v),
85
+ },
86
+ });
87
+
88
+ const emit = defineEmits([
89
+ "update:widgets",
90
+ "widget-move",
91
+ "widget-resize",
92
+ "widget-add",
93
+ "widget-remove",
94
+ ]);
95
+
96
+ const internalWidgets = ref([...props.widgets]);
97
+ const isDragging = ref(false);
98
+
99
+ /**
100
+ * Классы для grid контейнера
101
+ *
102
+ * @description
103
+ * Вычисляет классы для grid контейнера с использованием CSS Grid.
104
+ *
105
+ * @returns {Array} Массив классов
106
+ */
107
+ const gridClasses = computed(() =>
108
+ useClassComposition("relative w-full")
109
+ );
110
+
111
+ /**
112
+ * Стили для grid контейнера
113
+ *
114
+ * @description
115
+ * Вычисляет стили для grid контейнера с количеством колонок и отступами.
116
+ *
117
+ * @returns {Object} Объект со стилями
118
+ */
119
+ const gridStyles = computed(() => ({
120
+ display: "grid",
121
+ gridTemplateColumns: `repeat(${props.columns}, 1fr)`,
122
+ gridAutoRows: `${props.rowHeight}px`,
123
+ gap: gapValue.value,
124
+ }));
125
+
126
+ /**
127
+ * Стили для grid контейнера
128
+ *
129
+ * @description
130
+ * Вычисляет стили для grid контейнера с количеством колонок.
131
+ *
132
+ * @returns {Object} Объект со стилями
133
+ */
134
+ /**
135
+ * Значение gap для CSS
136
+ *
137
+ * @description
138
+ * Преобразует gap prop в значение для CSS.
139
+ *
140
+ * @returns {string} Значение gap
141
+ */
142
+ const gapValue = computed(() => {
143
+ const gapMap = {
144
+ none: "0px",
145
+ xs: "4px",
146
+ sm: "8px",
147
+ md: "16px",
148
+ lg: "24px",
149
+ xl: "32px",
150
+ };
151
+ return gapMap[props.gap] || gapMap.md;
152
+ });
153
+
154
+ /**
155
+ * Классы для виджета
156
+ *
157
+ * @description
158
+ * Вычисляет классы для каждого виджета.
159
+ *
160
+ * @returns {Array} Массив классов
161
+ */
162
+ const widgetClasses = computed(() =>
163
+ useClassComposition(
164
+ "relative transition-all",
165
+ {
166
+ "cursor-move": props.editable && isDragging.value,
167
+ "cursor-default": !props.editable,
168
+ }
169
+ )
170
+ );
171
+
172
+ /**
173
+ * Стили для виджета
174
+ *
175
+ * @description
176
+ * Вычисляет стили для позиционирования виджета в grid.
177
+ *
178
+ * @param {Object} widget - Виджет
179
+ * @returns {Object} Объект со стилями
180
+ */
181
+ function widgetStyles(widget) {
182
+ return {
183
+ gridColumn: `span ${widget.w || 4}`,
184
+ gridRow: `span ${widget.h || 2}`,
185
+ };
186
+ }
187
+
188
+ /**
189
+ * Обработчик начала перетаскивания
190
+ *
191
+ * @description
192
+ * Вызывается при начале перетаскивания виджета.
193
+ *
194
+ * @param {Object} event - Событие drag
195
+ */
196
+ function handleDragStart(event) {
197
+ isDragging.value = true;
198
+ }
199
+
200
+ /**
201
+ * Обработчик окончания перетаскивания
202
+ *
203
+ * @description
204
+ * Вызывается при окончании перетаскивания виджета.
205
+ *
206
+ * @param {Object} event - Событие drag
207
+ */
208
+ function handleDragEnd(event) {
209
+ isDragging.value = false;
210
+
211
+ // Вычисляем новую позицию виджета
212
+ const widget = internalWidgets.value[event.newIndex];
213
+ if (widget) {
214
+ // Обновляем позицию на основе нового индекса
215
+ const newPosition = calculatePosition(event.newIndex);
216
+ emit("widget-move", widget.id, newPosition);
217
+ }
218
+ }
219
+
220
+ /**
221
+ * Обработчик изменения при перетаскивании
222
+ *
223
+ * @description
224
+ * Вызывается при изменении порядка виджетов.
225
+ *
226
+ * @param {Object} event - Событие изменения
227
+ */
228
+ function handleDragChange(event) {
229
+ if (event.added) {
230
+ // Виджет добавлен
231
+ const widget = event.added.element;
232
+ emit("widget-add", widget);
233
+ } else if (event.removed) {
234
+ // Виджет удален
235
+ const widget = event.removed.element;
236
+ emit("widget-remove", widget);
237
+ } else if (event.moved) {
238
+ // Виджет перемещен
239
+ const widget = event.moved.element;
240
+ const newPosition = calculatePosition(event.moved.newIndex);
241
+ emit("widget-move", widget.id, newPosition);
242
+ }
243
+ }
244
+
245
+ /**
246
+ * Вычисление позиции виджета
247
+ *
248
+ * @description
249
+ * Вычисляет позицию (x, y) виджета на основе его индекса в grid.
250
+ *
251
+ * @param {number} index - Индекс виджета
252
+ * @returns {Object} Объект с позицией { x, y }
253
+ */
254
+ function calculatePosition(index) {
255
+ // Упрощенная логика: вычисляем позицию на основе индекса
256
+ // В реальной реализации нужно учитывать размеры виджетов
257
+ let currentX = 0;
258
+ let currentY = 0;
259
+ let currentRowHeight = 0;
260
+
261
+ for (let i = 0; i < index; i++) {
262
+ const widget = internalWidgets.value[i];
263
+ const widgetW = widget.w || 4;
264
+ const widgetH = widget.h || 2;
265
+
266
+ if (currentX + widgetW > props.columns) {
267
+ // Переход на новую строку
268
+ currentX = 0;
269
+ currentY += currentRowHeight;
270
+ currentRowHeight = widgetH;
271
+ } else {
272
+ currentX += widgetW;
273
+ currentRowHeight = Math.max(currentRowHeight, widgetH);
274
+ }
275
+ }
276
+
277
+ return { x: currentX, y: currentY };
278
+ }
279
+
280
+ // Синхронизация с prop widgets
281
+ watch(
282
+ () => props.widgets,
283
+ (newWidgets) => {
284
+ internalWidgets.value = [...newWidgets];
285
+ },
286
+ { deep: true }
287
+ );
288
+
289
+ // Синхронизация изменений с родителем
290
+ watch(
291
+ internalWidgets,
292
+ (newWidgets) => {
293
+ emit("update:widgets", newWidgets);
294
+ },
295
+ { deep: true }
296
+ );
297
+ </script>
298
+
299
+ <style scoped>
300
+ /* Стили для drag-and-drop */
301
+ :deep(.sortable-ghost) {
302
+ opacity: 0.3;
303
+ }
304
+
305
+ :deep(.sortable-drag) {
306
+ opacity: 0.5;
307
+ }
308
+ </style>
309
+
@@ -0,0 +1,2 @@
1
+ export { default } from './DXDashboardGrid.vue';
2
+