@carbon/vue 2.45.0 → 3.0.4-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (354) hide show
  1. package/README.md +34 -264
  2. package/dist/carbon-vue-3.common.js +27392 -0
  3. package/dist/carbon-vue-3.common.js.map +1 -0
  4. package/dist/carbon-vue-3.umd.js +27403 -0
  5. package/dist/carbon-vue-3.umd.js.map +1 -0
  6. package/dist/carbon-vue-3.umd.min.js +17 -0
  7. package/dist/carbon-vue-3.umd.min.js.map +1 -0
  8. package/dist/demo.html +1 -34
  9. package/package.json +185 -62
  10. package/src/components/CvAccordion/CvAccordion.stories.js +54 -0
  11. package/src/components/CvAccordion/CvAccordion.vue +95 -0
  12. package/src/components/CvAccordion/CvAccordionItem.vue +101 -0
  13. package/src/components/{cv-accordion/cv-accordion-skeleton.vue → CvAccordion/CvAccordionSkeleton.vue} +14 -18
  14. package/src/components/CvAccordion/_CvAccordionItemSkeleton.vue +30 -0
  15. package/src/components/CvAccordion/consts.js +17 -0
  16. package/src/components/CvAccordion/index.js +6 -0
  17. package/src/components/CvAspectRatio/CvAspectRatio.stories.js +56 -0
  18. package/src/components/CvAspectRatio/CvAspectRatio.stories.scss +4 -0
  19. package/src/components/CvAspectRatio/CvAspectRatio.vue +33 -0
  20. package/src/components/CvAspectRatio/consts.js +2 -0
  21. package/src/components/CvAspectRatio/index.js +4 -0
  22. package/src/components/CvBreadcrumb/CvBreadcrumb.stories.js +75 -0
  23. package/src/components/CvBreadcrumb/CvBreadcrumb.vue +37 -0
  24. package/src/components/CvBreadcrumb/CvBreadcrumbItem.vue +28 -0
  25. package/src/components/CvBreadcrumb/CvBreadcrumbSkeleton.vue +29 -0
  26. package/src/components/CvBreadcrumb/CvBreadcrumbSkeletonItem.vue +14 -0
  27. package/src/components/CvBreadcrumb/index.js +11 -0
  28. package/src/components/CvButton/CvButton.stories.js +119 -0
  29. package/src/components/CvButton/CvButton.vue +68 -0
  30. package/src/components/CvButton/CvButtonCommon.js +75 -0
  31. package/src/components/CvButton/CvButtonSet.stories.js +36 -0
  32. package/src/components/CvButton/CvButtonSet.vue +30 -0
  33. package/src/components/CvButton/CvIconButton.stories.js +139 -0
  34. package/src/components/CvButton/CvIconButton.vue +88 -0
  35. package/src/components/CvButton/index.js +7 -0
  36. package/src/components/CvButton/sbBtnPrefix.js +2 -0
  37. package/src/components/CvCheckbox/CvCheckbox.stories.js +111 -0
  38. package/src/components/CvCheckbox/CvCheckbox.vue +73 -0
  39. package/src/components/CvCheckbox/index.js +3 -0
  40. package/src/components/CvCodeSnippet/CvCodeSnippet.stories.js +181 -0
  41. package/src/components/CvCodeSnippet/CvCodeSnippet.stories.scss +4 -0
  42. package/src/components/CvCodeSnippet/CvCodeSnippet.vue +125 -0
  43. package/src/components/CvCodeSnippet/CvCodeSnippetSkeleton.vue +43 -0
  44. package/src/components/CvCodeSnippet/_CviCodeSnippetInline.vue +72 -0
  45. package/src/components/CvCodeSnippet/_CviCodeSnippetMultiline.vue +199 -0
  46. package/src/components/CvCodeSnippet/_CviCodeSnippetOneline.vue +106 -0
  47. package/src/components/CvCodeSnippet/consts.js +2 -0
  48. package/src/components/CvCodeSnippet/index.js +4 -0
  49. package/src/components/CvComboBox/CvComboBox.stories.js +174 -0
  50. package/src/components/CvComboBox/CvComboBox.vue +460 -0
  51. package/src/components/CvComboBox/index.js +3 -0
  52. package/src/components/CvContentSwitcher/CvContentSwitcher.stories.mdx +196 -0
  53. package/src/components/CvContentSwitcher/CvContentSwitcher.vue +64 -0
  54. package/src/components/CvContentSwitcher/CvContentSwitcherButton.vue +117 -0
  55. package/src/components/CvContentSwitcher/CvContentSwitcherContent.vue +21 -0
  56. package/src/components/CvContentSwitcher/cvContentSwitcherStore.js +30 -0
  57. package/src/components/CvContentSwitcher/index.js +3 -0
  58. package/src/components/CvCopyButton/CvCopyButton.stories.js +28 -0
  59. package/src/components/CvCopyButton/CvCopyButton.vue +45 -0
  60. package/src/components/CvCopyButton/_CviCopyButton.vue +71 -0
  61. package/src/components/CvCopyButton/index.js +3 -0
  62. package/src/components/CvDataTable/CvDataTable.stories.mdx +304 -0
  63. package/src/components/CvDataTable/CvDataTable.vue +648 -0
  64. package/src/components/CvDataTable/CvDataTableAction.vue +22 -0
  65. package/src/components/CvDataTable/CvDataTableCell.vue +11 -0
  66. package/src/components/CvDataTable/CvDataTableHeading.vue +143 -0
  67. package/src/components/CvDataTable/CvDataTableRow.vue +139 -0
  68. package/src/components/CvDataTable/CvDataTableSkeleton.vue +48 -0
  69. package/src/components/CvDataTable/_CvDataTableRowInner.vue +169 -0
  70. package/src/components/CvDataTable/cvDataTableStore.js +340 -0
  71. package/src/components/CvDataTable/index.js +3 -0
  72. package/src/components/CvEmpty/_CvEmpty.vue +22 -0
  73. package/src/components/CvGrid/CvColumn.vue +85 -0
  74. package/src/components/CvGrid/CvGrid.vue +42 -0
  75. package/src/components/{cv-grid/cv-row.vue → CvGrid/CvRow.vue} +8 -12
  76. package/src/components/CvGrid/GvGrid.stories.mdx +217 -0
  77. package/src/components/CvGrid/_SbContainer.vue +22 -0
  78. package/src/components/CvGrid/_cvColumnValidation.js +48 -0
  79. package/src/components/CvLink/CvLink.stories.js +169 -0
  80. package/src/components/CvLink/CvLink.vue +38 -0
  81. package/src/components/CvLink/index.js +4 -0
  82. package/src/components/CvList/CvList.stories.js +88 -0
  83. package/src/components/CvList/CvList.vue +50 -0
  84. package/src/components/CvList/CvListItem.vue +12 -0
  85. package/src/components/CvList/index.js +4 -0
  86. package/src/components/CvLoading/CvLoading.stories.js +78 -0
  87. package/src/components/CvLoading/CvLoading.stories.scss +4 -0
  88. package/src/components/CvLoading/CvLoading.vue +106 -0
  89. package/src/components/CvLoading/index.js +4 -0
  90. package/src/components/CvNotification/CvInlineNotification.stories.js +109 -0
  91. package/src/components/CvNotification/CvInlineNotification.vue +102 -0
  92. package/src/components/CvNotification/CvToastNotification.stories.js +108 -0
  93. package/src/components/CvNotification/CvToastNotification.vue +88 -0
  94. package/src/components/CvNotification/consts.js +31 -0
  95. package/src/components/CvNotification/index.js +5 -0
  96. package/src/components/CvOverflowMenu/CvOverflowMenu.stories.mdx +119 -0
  97. package/src/components/CvOverflowMenu/CvOverflowMenu.vue +283 -0
  98. package/src/components/{cv-overflow-menu/cv-overflow-menu-item.vue → CvOverflowMenu/CvOverflowMenuItem.vue} +26 -20
  99. package/src/components/CvOverflowMenu/index.js +3 -0
  100. package/src/components/CvPagination/CvPagination.stories.mdx +160 -0
  101. package/src/components/CvPagination/CvPagination.vue +246 -0
  102. package/src/components/CvPagination/index.js +3 -0
  103. package/src/components/CvSelect/CvSelect.stories.mdx +227 -0
  104. package/src/components/CvSelect/CvSelect.vue +224 -0
  105. package/src/components/CvSelect/CvSelectOptgroup.vue +9 -0
  106. package/src/components/CvSelect/CvSelectOption.vue +22 -0
  107. package/src/components/CvSelect/index.js +3 -0
  108. package/src/components/CvSkeletonText/CvSkeletonText.stories.js +56 -0
  109. package/src/components/CvSkeletonText/CvSkeletonText.vue +63 -0
  110. package/src/components/CvSkeletonText/index.js +3 -0
  111. package/src/components/CvSvg/_CvSvg.vue +48 -0
  112. package/src/components/CvSvg/__tests__/_TestIcon.vue +19 -0
  113. package/src/components/CvSvg/__tests__/test-svg.svg +5 -0
  114. package/src/components/CvTag/CvTag.stories.js +64 -0
  115. package/src/components/CvTag/CvTag.vue +105 -0
  116. package/src/components/CvTag/consts.js +15 -0
  117. package/src/components/CvTag/index.js +5 -0
  118. package/src/components/CvUIShell/CvHeader.vue +203 -0
  119. package/src/components/CvUIShell/CvHeaderGlobalAction.vue +105 -0
  120. package/src/components/{cv-ui-shell/cv-header-menu.vue → CvUIShell/CvHeaderMenu.vue} +41 -37
  121. package/src/components/CvUIShell/CvHeaderMenuButton.vue +103 -0
  122. package/src/components/CvUIShell/CvHeaderMenuItem.vue +38 -0
  123. package/src/components/CvUIShell/CvHeaderName.vue +25 -0
  124. package/src/components/CvUIShell/CvHeaderNav.vue +18 -0
  125. package/src/components/CvUIShell/CvHeaderPanel.vue +106 -0
  126. package/src/components/CvUIShell/CvSideNav.vue +131 -0
  127. package/src/components/CvUIShell/CvSideNavIcon.vue +17 -0
  128. package/src/components/CvUIShell/CvSideNavItems.vue +22 -0
  129. package/src/components/CvUIShell/CvSideNavLink.vue +47 -0
  130. package/src/components/CvUIShell/CvSideNavMenu.vue +85 -0
  131. package/src/components/CvUIShell/CvSideNavMenuDivider.vue +7 -0
  132. package/src/components/CvUIShell/CvSideNavMenuItem.vue +31 -0
  133. package/src/components/CvUIShell/CvSkipToContent.vue +20 -0
  134. package/src/components/CvUIShell/CvSwitcher.vue +9 -0
  135. package/src/components/CvUIShell/CvSwitcherItem.vue +9 -0
  136. package/src/components/CvUIShell/CvSwitcherItemLink.vue +26 -0
  137. package/src/components/CvUIShell/CvUIShell.stories.mdx +454 -0
  138. package/src/components/{cv-ui-shell/_cv-side-nav-footer.vue → CvUIShell/_CvSideNavFooter.vue} +11 -15
  139. package/src/components/CvUIShell/_CvSideNavLinkText.vue +9 -0
  140. package/src/components/CvWrapper/CvWrapper.js +23 -0
  141. package/src/global/component-utils/event-bus.js +23 -0
  142. package/src/global/component-utils/validators.js +14 -0
  143. package/src/global/settings.js +5 -0
  144. package/src/global/storybook-utils/__tests__/story-source-code.js +162 -0
  145. package/src/global/storybook-utils/controls-from-props.js +72 -0
  146. package/src/global/storybook-utils/index.js +5 -0
  147. package/src/global/storybook-utils/sbCompPrefix.js +1 -0
  148. package/src/global/storybook-utils/split-slot-args.js +14 -0
  149. package/src/global/storybook-utils/story-source-code.js +52 -0
  150. package/src/index.js +13 -83
  151. package/src/use/components.js +24 -0
  152. package/src/use/cvCheck.js +94 -0
  153. package/src/use/cvId.js +57 -0
  154. package/src/use/cvLink.js +42 -0
  155. package/src/use/cvTheme.js +30 -0
  156. package/src/use/index.js +1 -0
  157. package/src/use/overflow.js +37 -0
  158. package/dist/carbon-vue.common.js +0 -23411
  159. package/dist/carbon-vue.common.js.map +0 -1
  160. package/dist/carbon-vue.umd.js +0 -23421
  161. package/dist/carbon-vue.umd.js.map +0 -1
  162. package/dist/carbon-vue.umd.min.js +0 -30
  163. package/dist/carbon-vue.umd.min.js.map +0 -1
  164. package/src/assets/images/component-icons.svg +0 -57
  165. package/src/assets/images/example-icon-svg.js +0 -10
  166. package/src/assets/images/example-icon.svg +0 -6
  167. package/src/assets/images/example-icons.svg +0 -6
  168. package/src/carbon.yml +0 -442
  169. package/src/components/cv-accordion/_cv-accordion-item-skeleton.vue +0 -29
  170. package/src/components/cv-accordion/cv-accordion-item.vue +0 -87
  171. package/src/components/cv-accordion/cv-accordion.vue +0 -59
  172. package/src/components/cv-accordion/index.js +0 -5
  173. package/src/components/cv-aspect-ratio/cv-aspect-ratio.vue +0 -28
  174. package/src/components/cv-aspect-ratio/index.js +0 -2
  175. package/src/components/cv-breadcrumb/_cv-breadcrumb-item-skeleton.vue +0 -13
  176. package/src/components/cv-breadcrumb/cv-breadcrumb-item.vue +0 -28
  177. package/src/components/cv-breadcrumb/cv-breadcrumb-skeleton.vue +0 -30
  178. package/src/components/cv-breadcrumb/cv-breadcrumb.vue +0 -21
  179. package/src/components/cv-breadcrumb/index.js +0 -5
  180. package/src/components/cv-button/button-mixin.js +0 -91
  181. package/src/components/cv-button/cv-button-set.vue +0 -17
  182. package/src/components/cv-button/cv-button-skeleton.vue +0 -12
  183. package/src/components/cv-button/cv-button.vue +0 -19
  184. package/src/components/cv-button/cv-icon-button.vue +0 -42
  185. package/src/components/cv-button/index.js +0 -6
  186. package/src/components/cv-checkbox/cv-checkbox-skeleton.vue +0 -15
  187. package/src/components/cv-checkbox/cv-checkbox.vue +0 -70
  188. package/src/components/cv-checkbox/index.js +0 -3
  189. package/src/components/cv-code-snippet/_cv-code-snippet-inline.vue +0 -39
  190. package/src/components/cv-code-snippet/_cv-code-snippet-multiline.vue +0 -79
  191. package/src/components/cv-code-snippet/_cv-code-snippet-oneline.vue +0 -47
  192. package/src/components/cv-code-snippet/cv-code-snippet-skeleton.vue +0 -30
  193. package/src/components/cv-code-snippet/cv-code-snippet.vue +0 -83
  194. package/src/components/cv-code-snippet/index.js +0 -3
  195. package/src/components/cv-combo-box/cv-combo-box.vue +0 -386
  196. package/src/components/cv-combo-box/index.js +0 -3
  197. package/src/components/cv-content-switcher/cv-content-switcher-button.vue +0 -104
  198. package/src/components/cv-content-switcher/cv-content-switcher-content.vue +0 -26
  199. package/src/components/cv-content-switcher/cv-content-switcher-store.js +0 -22
  200. package/src/components/cv-content-switcher/cv-content-switcher.vue +0 -117
  201. package/src/components/cv-content-switcher/index.js +0 -4
  202. package/src/components/cv-data-table/_cv-data-table-row-inner.vue +0 -139
  203. package/src/components/cv-data-table/cv-data-table-action.vue +0 -25
  204. package/src/components/cv-data-table/cv-data-table-cell.vue +0 -14
  205. package/src/components/cv-data-table/cv-data-table-heading.vue +0 -109
  206. package/src/components/cv-data-table/cv-data-table-row.vue +0 -113
  207. package/src/components/cv-data-table/cv-data-table-skeleton.vue +0 -64
  208. package/src/components/cv-data-table/cv-data-table.vue +0 -525
  209. package/src/components/cv-data-table/index.js +0 -8
  210. package/src/components/cv-date-picker/cv-date-picker.vue +0 -362
  211. package/src/components/cv-date-picker/index.js +0 -3
  212. package/src/components/cv-date-picker/plugins/appendToPlugin.js +0 -52
  213. package/src/components/cv-date-picker/plugins/fixEventsPlugin.js +0 -75
  214. package/src/components/cv-date-picker/plugins/monthSelectPlugin.js +0 -66
  215. package/src/components/cv-date-picker/plugins/rangePlugin.js +0 -45
  216. package/src/components/cv-dropdown/cv-dropdown-item.vue +0 -84
  217. package/src/components/cv-dropdown/cv-dropdown-skeleton.vue +0 -20
  218. package/src/components/cv-dropdown/cv-dropdown.vue +0 -373
  219. package/src/components/cv-dropdown/index.js +0 -5
  220. package/src/components/cv-feedback-button/_cv-feedback-button.vue +0 -74
  221. package/src/components/cv-file-uploader/consts.js +0 -12
  222. package/src/components/cv-file-uploader/cv-file-uploader-skeleton.vue +0 -22
  223. package/src/components/cv-file-uploader/cv-file-uploader.vue +0 -348
  224. package/src/components/cv-file-uploader/index.js +0 -5
  225. package/src/components/cv-form/cv-form-group.vue +0 -32
  226. package/src/components/cv-form/cv-form-item.vue +0 -13
  227. package/src/components/cv-form/cv-form.vue +0 -13
  228. package/src/components/cv-form/index.js +0 -5
  229. package/src/components/cv-grid/cv-column.vue +0 -77
  230. package/src/components/cv-grid/cv-grid.vue +0 -32
  231. package/src/components/cv-grid/index.js +0 -5
  232. package/src/components/cv-icon/_cv-icon.vue +0 -30
  233. package/src/components/cv-inline-loading/consts.js +0 -8
  234. package/src/components/cv-inline-loading/cv-inline-loading.vue +0 -91
  235. package/src/components/cv-inline-loading/index.js +0 -4
  236. package/src/components/cv-inline-notification/cv-inline-notification.vue +0 -89
  237. package/src/components/cv-inline-notification/index.js +0 -3
  238. package/src/components/cv-link/cv-link.vue +0 -30
  239. package/src/components/cv-link/index.js +0 -3
  240. package/src/components/cv-list/cv-list-item.vue +0 -13
  241. package/src/components/cv-list/cv-list.vue +0 -42
  242. package/src/components/cv-list/index.js +0 -4
  243. package/src/components/cv-loading/cv-loading.vue +0 -86
  244. package/src/components/cv-loading/index.js +0 -3
  245. package/src/components/cv-modal/cv-modal.vue +0 -295
  246. package/src/components/cv-modal/index.js +0 -2
  247. package/src/components/cv-multi-select/cv-multi-select.vue +0 -484
  248. package/src/components/cv-multi-select/index.js +0 -3
  249. package/src/components/cv-number-input/cv-number-input-skeleton.vue +0 -14
  250. package/src/components/cv-number-input/cv-number-input.vue +0 -215
  251. package/src/components/cv-number-input/index.js +0 -3
  252. package/src/components/cv-overflow-menu/cv-overflow-menu.vue +0 -253
  253. package/src/components/cv-overflow-menu/index.js +0 -4
  254. package/src/components/cv-pagination/cv-pagination.vue +0 -268
  255. package/src/components/cv-pagination/index.js +0 -2
  256. package/src/components/cv-progress/cv-progress-step.vue +0 -135
  257. package/src/components/cv-progress/cv-progress.vue +0 -82
  258. package/src/components/cv-progress/index.js +0 -4
  259. package/src/components/cv-radio-button/cv-radio-button.vue +0 -40
  260. package/src/components/cv-radio-button/cv-radio-group.vue +0 -24
  261. package/src/components/cv-radio-button/index.js +0 -4
  262. package/src/components/cv-search/cv-search.vue +0 -194
  263. package/src/components/cv-search/index.js +0 -2
  264. package/src/components/cv-select/cv-select-optgroup.vue +0 -14
  265. package/src/components/cv-select/cv-select-option.vue +0 -14
  266. package/src/components/cv-select/cv-select.vue +0 -158
  267. package/src/components/cv-select/index.js +0 -4
  268. package/src/components/cv-skeleton-text/cv-skeleton-text.vue +0 -64
  269. package/src/components/cv-skeleton-text/index.js +0 -2
  270. package/src/components/cv-slider/cv-slider-skeleton.vue +0 -22
  271. package/src/components/cv-slider/cv-slider.vue +0 -247
  272. package/src/components/cv-slider/index.js +0 -4
  273. package/src/components/cv-structured-list/_cv-structured-list-item-selectable.vue +0 -37
  274. package/src/components/cv-structured-list/_cv-structured-list-item-standard.vue +0 -13
  275. package/src/components/cv-structured-list/cv-structured-list-data.vue +0 -23
  276. package/src/components/cv-structured-list/cv-structured-list-heading.vue +0 -13
  277. package/src/components/cv-structured-list/cv-structured-list-item.vue +0 -46
  278. package/src/components/cv-structured-list/cv-structured-list.vue +0 -38
  279. package/src/components/cv-structured-list/index.js +0 -5
  280. package/src/components/cv-svg/_cv-svg.vue +0 -38
  281. package/src/components/cv-tabs/cv-tab.vue +0 -68
  282. package/src/components/cv-tabs/cv-tabs-skeleton.vue +0 -20
  283. package/src/components/cv-tabs/cv-tabs.vue +0 -410
  284. package/src/components/cv-tabs/index.js +0 -5
  285. package/src/components/cv-tag/cv-tag-skeleton.vue +0 -19
  286. package/src/components/cv-tag/cv-tag.vue +0 -121
  287. package/src/components/cv-tag/index.js +0 -4
  288. package/src/components/cv-text-area/cv-text-area.vue +0 -98
  289. package/src/components/cv-text-area/index.js +0 -2
  290. package/src/components/cv-text-input/cv-text-input.vue +0 -173
  291. package/src/components/cv-text-input/index.js +0 -2
  292. package/src/components/cv-tile/_cv-tile-clickable.vue +0 -22
  293. package/src/components/cv-tile/_cv-tile-expandable.vue +0 -92
  294. package/src/components/cv-tile/_cv-tile-selectable.vue +0 -48
  295. package/src/components/cv-tile/_cv-tile-standard.vue +0 -11
  296. package/src/components/cv-tile/cv-tile.vue +0 -83
  297. package/src/components/cv-tile/index.js +0 -2
  298. package/src/components/cv-time-picker/cv-time-picker.vue +0 -138
  299. package/src/components/cv-time-picker/index.js +0 -2
  300. package/src/components/cv-toast-notification/cv-toast-notification.vue +0 -72
  301. package/src/components/cv-toast-notification/index.js +0 -2
  302. package/src/components/cv-toggle/cv-toggle-skeleton.vue +0 -25
  303. package/src/components/cv-toggle/cv-toggle.vue +0 -52
  304. package/src/components/cv-toggle/index.js +0 -3
  305. package/src/components/cv-toolbar/cv-toolbar-divider.vue +0 -11
  306. package/src/components/cv-toolbar/cv-toolbar-option.vue +0 -16
  307. package/src/components/cv-toolbar/cv-toolbar-search.vue +0 -40
  308. package/src/components/cv-toolbar/cv-toolbar-title.vue +0 -14
  309. package/src/components/cv-toolbar/cv-toolbar.vue +0 -13
  310. package/src/components/cv-toolbar/index.js +0 -6
  311. package/src/components/cv-tooltip/consts.js +0 -2
  312. package/src/components/cv-tooltip/cv-definition-tooltip.vue +0 -44
  313. package/src/components/cv-tooltip/cv-interactive-tooltip.vue +0 -241
  314. package/src/components/cv-tooltip/cv-tooltip.vue +0 -44
  315. package/src/components/cv-tooltip/index.js +0 -6
  316. package/src/components/cv-ui-shell/_cv-side-nav-link-text.vue +0 -13
  317. package/src/components/cv-ui-shell/cv-content.vue +0 -16
  318. package/src/components/cv-ui-shell/cv-header-global-action.vue +0 -84
  319. package/src/components/cv-ui-shell/cv-header-menu-button.vue +0 -80
  320. package/src/components/cv-ui-shell/cv-header-menu-item.vue +0 -36
  321. package/src/components/cv-ui-shell/cv-header-name.vue +0 -18
  322. package/src/components/cv-ui-shell/cv-header-nav.vue +0 -18
  323. package/src/components/cv-ui-shell/cv-header-panel.vue +0 -72
  324. package/src/components/cv-ui-shell/cv-header-side-nav-items.vue +0 -21
  325. package/src/components/cv-ui-shell/cv-header.vue +0 -119
  326. package/src/components/cv-ui-shell/cv-side-nav-divider.vue +0 -12
  327. package/src/components/cv-ui-shell/cv-side-nav-icon.vue +0 -16
  328. package/src/components/cv-ui-shell/cv-side-nav-items.vue +0 -21
  329. package/src/components/cv-ui-shell/cv-side-nav-link.vue +0 -54
  330. package/src/components/cv-ui-shell/cv-side-nav-menu-item.vue +0 -30
  331. package/src/components/cv-ui-shell/cv-side-nav-menu.vue +0 -84
  332. package/src/components/cv-ui-shell/cv-side-nav.vue +0 -97
  333. package/src/components/cv-ui-shell/cv-skip-to-content.vue +0 -19
  334. package/src/components/cv-ui-shell/cv-switcher-item-link.vue +0 -26
  335. package/src/components/cv-ui-shell/cv-switcher-item.vue +0 -13
  336. package/src/components/cv-ui-shell/cv-switcher.vue +0 -13
  337. package/src/components/cv-ui-shell/index.js +0 -45
  338. package/src/components/cv-wrapper/_cv-wrapper.js +0 -33
  339. package/src/directives/clickout.js +0 -29
  340. package/src/index-components-vue.js +0 -5
  341. package/src/internal/feature-flags.js +0 -22
  342. package/src/mixins/carbon-prefix-mixin.js +0 -7
  343. package/src/mixins/check-mixin.js +0 -106
  344. package/src/mixins/index.js +0 -12
  345. package/src/mixins/link-mixin.js +0 -23
  346. package/src/mixins/methods-mixin.js +0 -18
  347. package/src/mixins/notification-mixin.js +0 -18
  348. package/src/mixins/radio-mixin.js +0 -36
  349. package/src/mixins/theme-mixin.js +0 -23
  350. package/src/mixins/uid-mixin.js +0 -23
  351. package/src/thumbnails/inline-notification.svg +0 -23
  352. package/src/thumbnails/skeleton-text.svg +0 -15
  353. package/src/thumbnails/toast-notification.svg +0 -34
  354. /package/src/components/{cv-button → CvButton}/consts.js +0 -0
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # carbon-components-vue
1
+ # @carbon/vue-3
2
2
 
3
3
  <p align="center">
4
4
  <a href="https://github.com/carbon-design-system/carbon/blob/master/LICENSE">
@@ -18,10 +18,6 @@
18
18
  > Vue implementation of the Carbon Design System
19
19
  > A collection of [Carbon Components](https://github.com/carbon-design-system/carbon-components) implemented using <img src="https://vuejs.org/images/logo.png" width="20" alt="Vue logo"> [Vue.js](https://vuejs.org/).
20
20
 
21
- <div style="text-align: center">
22
- <img src="/docs/AtCarbonVue2.png" alt="@carbon/vue">
23
- </div>
24
-
25
21
  ## Carbon Vue library - A Carbon Community Project
26
22
 
27
23
  The [library](http://vue.carbondesignsystem.com/) provides front-end developers & engineers a collection of reusable Vue components to build websites and user interfaces. Adopting the library enables developers to use consistent markup, styles, and behavior in prototype and production work.
@@ -30,275 +26,49 @@ The [library](http://vue.carbondesignsystem.com/) provides front-end developers
30
26
 
31
27
  As a community project contributions are not only welcome, but essential for the maintenance and growth of this project.
32
28
 
33
- ## Changelog
34
-
35
- See [CHANGELOG.md](CHANGELOG.md)
36
-
37
- ## Current Components
38
-
39
- View available Vue.js components [here](http://vue.carbondesignsystem.com). Usage information is available when you click the blue `?` icon in the top right corner of the selected component.
40
-
41
- See [component status pages](https://www.carbondesignsystem.com/component-status) for the status of each component.
42
-
43
- ## Development
44
-
45
- Please refer to the [Contribution Guidelines](../../.github/CONTRIBUTING.md) before starting any work.
46
-
47
- ## Contributing
48
-
49
- Fork this repository, create a new branch, and submit a pull request to this repository. The PR will be used as part of a review process.
50
-
51
- NOTE: PR titles need to conform to sematic versioning pattern described <https://github.com/amannn/action-semantic-pull-request>
52
-
53
- e.g.
54
- Examples for valid PR titles:
55
-
56
- - fix: Correct typo.
57
- - feat: Add support for Node 12.
58
- - refactor!: Drop support for Node 6.
59
- - feat(ui): Add Button component.
60
-
61
- ## Usage
62
-
63
- ### General
64
-
65
- The components do not import any of the carbon styles themselves. Use the SCSS or CSS from carbon-components to provide the styling.
66
-
67
- - In your main js file (where you include Vue) you can include the styles wholesale: `import "carbon-components/css/carbon-components.min.css";`
68
- - You can also use the unpkg cdn to bring in the styles wholesale: unpkg.com/carbon-components/css/carbon-components.min.css aliases the latest minified css file.
69
- - If you prefer to build the SCSS, in the `<style>` tag of your top-level component you can include the styles wholesale: `@import "~carbon-components/scss/globals/scss/styles.scss";`
70
- - Check out the [Carbon Design System developers](https://www.carbondesignsystem.com/getting-started/developers/vanilla) page for information on including individual component styles into your project.
71
-
72
- ### List of Available Components
73
-
74
- View the available Carbon Vue components [here](http://vue.carbondesignsystem.com). Usage information is in the notes tab.
75
-
76
- ## Getting Started
77
-
78
- ### Quick Start (Vue CLI)
79
-
80
- Assuming we're starting with a new project through the [Vue CLI](https://cli.vuejs.org/) (not with the plain Vue Webpack template, which might not work):
81
-
82
- ```sh
83
- > vue create newprojectname
84
- Vue CLI v3.7.0
85
- ? Please pick a preset: Manually select features
86
- ? Check the features needed for your project: Babel, CSS Pre-processors
87
- ? Pick a CSS pre-processor (PostCSS, Autoprefixer and CSS Modules are supported by default): Sass/SCSS (with node-
88
- sass)
89
- ? Where do you prefer placing config for Babel, PostCSS, ESLint, etc.? In package.json
90
- ? Save this as a preset for future projects? No
91
- ```
92
-
93
- Using Yarn
94
-
95
- ```sh
96
- $ yarn add @carbon/vue
97
- ```
98
-
99
- Or npm
100
-
101
- ```sh
102
- $ npm install --save @carbon/vue
103
- ```
104
-
105
- In src/main.js add the following to include the carbon styles and components.
106
-
107
- ```js
108
- import 'carbon-components/css/carbon-components.css';
109
- import CarbonComponentsVue from '@carbon/vue/src/index';
110
- Vue.use(CarbonComponentsVue);
111
- ```
112
-
113
- Replace the contents of src/components/HelloWorld.vue with the following
114
-
115
- ```html
116
- <template>
117
- <div class="sample">
118
- <h1>Example use of @carbon/vue</h1>
119
- <cv-text-input label="Who are you?" v-model="yourName" placeholder="your name" />
120
- <cv-button @click="onClick">Hello {{yourName}}</cv-button>
121
- <cv-modal :visible="visible" @modal-hidden="modalClosed">
122
- <template slot="title">Welcome to @carbon/vue {{yourName}}</template>
123
- <template slot="content">
124
- <p>
125
- Lorem ipsum dolor sit amet, consectetur adipisicing elit, seed do eiusmod tempor incididunt ut labore et
126
- dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea
127
- commodo consequat.
128
- </p>
129
- </template>
130
- </cv-modal>
131
- </div>
132
- </template>
133
-
134
- <script>
135
- export default {
136
- name: 'HelloWorld',
137
- data() {
138
- return {
139
- yourName: '',
140
- visible: false,
141
- };
142
- },
143
- methods: {
144
- onClick() {
145
- this.visible = true;
146
- },
147
- modalClosed() {
148
- this.visible = false;
149
- },
150
- },
151
- };
152
- </script>
153
-
154
- <style>
155
- .sample {
156
- display: flex;
157
- flex-direction: column;
158
- justify-content: center;
159
- align-items: center;
160
- max-width: 600px;
161
- margin: 5% auto;
162
- }
163
-
164
- .cv-text-input {
165
- margin: 30px 0;
166
- }
167
- </style>
168
- ```
169
-
170
- That's it! Now start the server and start building.
171
-
172
- Using Yarn
173
-
174
- ```sh
175
- $ yarn serve
176
- ```
177
-
178
- Or npm
179
-
180
- ```sh
181
- $ npm serve
182
- ```
183
-
184
- ### Install
185
-
186
- Run the following command using [Yarn](https://yarnpkg.com/en/):
187
-
188
- ```bash
189
- yarn add @carbon/vue
190
- ```
191
-
192
- If you prefer [npm](https://www.npmjs.com/), use the following command instead:
193
-
194
- ```bash
195
- npm install --save @carbon/vue
196
- ```
197
-
198
- NOTE: [current-script-polyfill](https://www.npmjs.com/package/current-script-polyfill) is required for older browsers (_e.g._ IE11)
199
-
200
- ### Using the component library
201
-
202
- In your main js file (where you include Vue):
203
-
204
- ```javascript
205
- import CarbonComponentsVue from '@carbon/vue';
206
- Vue.use(CarbonComponentsVue);
207
- ```
208
-
209
- The above lines will register all the core components. You can register only the components you need if you prefer:
210
-
211
- ```
212
- Vue.use(CarbonComponentsVue, ['CvButton', 'CvTag']);
213
- ```
214
-
215
- ### Using the components directly or individually
216
-
217
- You can import the component source either for all core components or for the individual components you need.
218
-
219
- To import all the core components:
220
-
221
- ```javascript
222
- import CarbonComponentsVue from '@carbon/vue/src/index';
223
- Vue.use(CarbonComponentsVue);
224
- ```
225
-
226
- To import individual components:
29
+ ### Vue 3 Guidance
227
30
 
228
- ```javascript
229
- <script>
230
- ...
231
- import { CvButton } from '@carbon/vue';
232
- ...
233
- components: {
234
- CvButton,
235
- },
236
- ...
237
- </script>
238
- ```
31
+ We are actively working on components for Vue 3 and would love to get your help with this. If you want to contribute follow this guidance:
239
32
 
240
- Alternataively from source:
33
+ 1. Fork this repo and checkout the `vNext` branch
34
+ 2. Look to see which components have not yet been implemented. You can do this by comparing the components listed in the [Carbon React storybook](https://react.carbondesignsystem.com/?path=/story/getting-started-welcome--welcome) with the components in the `src/components` directory.
35
+ 3. When you find a component that interests you, look in the open issue list to see if someone else might already be working on it. Look for issues with a "V3 - Vue3" label. A "dibs" issue will have that label and a title of "[component name] work in progress" so for example "**CvDatePicker work in progress**".
36
+ 4. If no one else is already working on it, create an issue and label it as above.
37
+ - Work on the component and create a PR when you are ready.
38
+ - Components are expected to be implemented as [single file components](https://vuejs.org/guide/scaling-up/sfc.html) using the Vue [composition api](https://vuejs.org/guide/extras/composition-api-faq.html). See `CvCheckbox` as an example. The Vue 2 components use the options API.
39
+ - You should reference the existing Vue 2 component while developing the code. The existing components often have the community enhancements that need to be maintained.
40
+ - You should reference the DOM in the React components storybook and be sure to include any accessibility improvements that might be there.
41
+ - You should provide a story and test case for the component. For example:
42
+ ```
43
+ src/components/CvCheckbox/CvCheckbox.stories.js
44
+ src/components/CvCheckbox/CvCheckbox.vue
45
+ src/components/CvCheckbox/__tests__/CvCheckbox.spec.js
46
+ src/components/CvCheckbox/index.js
47
+ ```
48
+ - If you have question tag @davidnixon in your issue and let me know how I can help.
241
49
 
242
- ```javascript
243
- <script>
244
- ...
245
- import { CvButton } from '@carbon/vue/src';
246
- ...
247
- components: {
248
- CvButton,
249
- },
250
- ...
251
- </script>
252
- ```
50
+ ### Changelog
253
51
 
254
- or
52
+ [CHANGELOG.md](./packages/core/CHANGELOG.md)
255
53
 
256
- ```javascript
257
- <script>
258
- ...
259
- import { CvButton } from '@carbon/vue/src/components/cv-button';
260
- ...
261
- components: {
262
- CvButton,
263
- },
264
- ...
265
- </script>
266
- ```
54
+ ## Getting started
267
55
 
268
- or
56
+ [Usage and getting started instructions](./packages/core/README.md#getting-started) for @carbon/vue.
269
57
 
270
- ```javascript
271
- <script>
272
- ...
273
- import CvButton from '@carbon/vue/src/components/cv-button/cv-button';
274
- ...
275
- components: {
276
- CvButton,
277
- },
278
- ...
279
- </script>
280
- ```
58
+ ### List of available components
281
59
 
282
- Note: to import the component source you will need to ensure that Babel can process the source. We recommend the Babel preset `@vue/app`. If @carbon/vue is installed as a dependency in a `node_modules` folder or similar, you may need to enable Babel to process the source files, for example with the following lines, or similar, inside the `webpack.config.js` file:
60
+ View available Vue Components [here](http://vue.carbondesignsystem.com). Usage information is available in the notes provided with each story.
283
61
 
284
- ```javascript
285
- {
286
- test: /\.js$/,
287
- loader: 'babel-loader',
288
- include: [path.resolve(__dirname, 'node_modules/@carbon'), path.resolve(__dirname, 'src')]
289
- }
290
- ```
62
+ ## Building and publishing
291
63
 
292
- ### Using the components from unkpg
64
+ The following steps will build and publish the packages:
293
65
 
294
- In your html file, no need to babel.
66
+ - clone or download the repo;
67
+ - run `yarn` to install dependencies and bootstrap the packages;
68
+ - run `yarn build` to build all the packages including the storybook;
295
69
 
296
- ```html
297
- <script src="https://unpkg.com/vue@latest" />
298
- <script src="https://unpkg.com/@carbon/vue" />
299
- <script>
300
- Vue.use(window['carbon-vue'].default);
301
- <script>
70
+ If you just want to build an individual package you can limit the scope:
71
+ `yarn build --scope @carbon/vue`
72
+ `yarn build --scope storybook`
302
73
 
303
- . . . <cv-button>Hello</cv-button>
304
- ```
74
+ To start the storybook in a local server use `yarn start`.