bitboss-ui 2.1.134 → 3.0.0-alpha.1
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.
- package/LICENSE +21 -0
- package/README.md +244 -21
- package/bin/bitboss-ui-mcp.mjs +557 -0
- package/bin/bitboss-ui.mjs +626 -0
- package/dist/ai/BbAccordion.md +522 -113
- package/dist/ai/BbAlert.md +377 -197
- package/dist/ai/BbAsterisk.md +46 -0
- package/dist/ai/BbAvatar.md +454 -178
- package/dist/ai/BbBadge.md +695 -225
- package/dist/ai/BbBadgeButton.md +54 -0
- package/dist/ai/BbBaseButton.md +489 -0
- package/dist/ai/BbBaseCheckbox.md +49 -0
- package/dist/ai/BbBaseCheckboxGroup.md +64 -0
- package/dist/ai/BbBaseCheckboxIcon.md +174 -0
- package/dist/ai/BbBaseColorInput.md +64 -0
- package/dist/ai/BbBaseColorPalette.md +39 -0
- package/dist/ai/BbBaseDatePicker.md +42 -0
- package/dist/ai/BbBaseDatePickerInput.md +73 -0
- package/dist/ai/BbBaseInputContainer.md +48 -0
- package/dist/ai/BbBaseNumberInput.md +71 -0
- package/dist/ai/BbBaseRadio.md +46 -0
- package/dist/ai/BbBaseRadioGroup.md +63 -0
- package/dist/ai/BbBaseRadioIcon.md +187 -0
- package/dist/ai/BbBaseRating.md +51 -0
- package/dist/ai/BbBaseSelect.md +88 -0
- package/dist/ai/BbBaseSlider.md +56 -0
- package/dist/ai/BbBaseSwitch.md +49 -0
- package/dist/ai/BbBaseSwitchGroup.md +64 -0
- package/dist/ai/BbBaseSwitchIcon.md +184 -0
- package/dist/ai/BbBaseTag.md +68 -0
- package/dist/ai/BbBaseTextInput.md +75 -0
- package/dist/ai/BbBaseTextarea.md +62 -0
- package/dist/ai/BbBaseTimePickerInput.md +62 -0
- package/dist/ai/BbBreadcrumbs.md +542 -503
- package/dist/ai/BbButton.md +767 -636
- package/dist/ai/BbCheckbox.md +572 -254
- package/dist/ai/BbCheckboxGroup.md +561 -361
- package/dist/ai/BbCollapsible.md +419 -103
- package/dist/ai/BbColorInput.md +529 -323
- package/dist/ai/BbColorPalette.md +565 -330
- package/dist/ai/BbConfirm.md +612 -136
- package/dist/ai/BbConfirmPortal.md +28 -0
- package/dist/ai/BbDatePicker.md +244 -0
- package/dist/ai/BbDatePickerInput.md +706 -388
- package/dist/ai/BbDialog.md +770 -99
- package/dist/ai/BbDropdown.md +1054 -763
- package/dist/ai/BbDropdownButton.md +511 -615
- package/dist/ai/BbDropdownGroup.md +34 -0
- package/dist/ai/BbDropzone.md +1148 -436
- package/dist/ai/BbForm.md +239 -0
- package/dist/ai/BbIcon.md +379 -212
- package/dist/ai/BbIndicator.md +283 -0
- package/dist/ai/BbNumberInput.md +713 -355
- package/dist/ai/BbOffCanvas.md +875 -498
- package/dist/ai/BbPagination.md +483 -535
- package/dist/ai/BbPopover.md +583 -546
- package/dist/ai/BbProgress.md +456 -69
- package/dist/ai/BbRadio.md +343 -229
- package/dist/ai/BbRadioGroup.md +426 -353
- package/dist/ai/BbRating.md +361 -226
- package/dist/ai/BbSelect.md +1380 -536
- package/dist/ai/BbSelectPopover.md +1240 -1579
- package/dist/ai/BbSlider.md +478 -257
- package/dist/ai/BbSmoothHeight.md +472 -139
- package/dist/ai/BbSpinner.md +718 -131
- package/dist/ai/BbSwitch.md +549 -119
- package/dist/ai/BbSwitchGroup.md +503 -214
- package/dist/ai/BbTable.md +1956 -2358
- package/dist/ai/BbTabs.md +1113 -0
- package/dist/ai/BbTabsList.md +29 -0
- package/dist/ai/BbTabsPanes.md +27 -0
- package/dist/ai/BbTabsRoot.md +57 -0
- package/dist/ai/BbTag.md +393 -292
- package/dist/ai/BbTextInput.md +852 -333
- package/dist/ai/BbTextarea.md +836 -255
- package/dist/ai/BbTimePicker.md +231 -0
- package/dist/ai/BbTimePickerInput.md +196 -0
- package/dist/ai/BbToast.md +624 -196
- package/dist/ai/BbToastPortal.md +28 -0
- package/dist/ai/BbTooltip.md +443 -346
- package/dist/ai/BbTree.md +984 -235
- package/dist/ai/ChipsBox.md +27 -199
- package/dist/ai/ClearableButton.md +21 -55
- package/dist/ai/CommaBox.md +25 -200
- package/dist/ai/CommonInputWrapper.md +42 -0
- package/dist/ai/CommonPopover.md +30 -510
- package/dist/ai/ErrorIcon.md +19 -56
- package/dist/ai/FlatListBox.md +35 -379
- package/dist/ai/GroupedListBox.md +37 -535
- package/dist/ai/GuidesComponent.md +21 -0
- package/dist/ai/ListBox.md +38 -231
- package/dist/ai/OptionsContainer.md +34 -253
- package/dist/ai/WarningIcon.md +21 -0
- package/dist/ai/components.json +15883 -0
- package/dist/ai/composables/useBbConfig.md +80 -0
- package/dist/ai/composables/useBbFormContext.md +110 -0
- package/dist/ai/composables/useBbTableContext.md +164 -0
- package/dist/ai/composables/useBbTabsContext.md +118 -0
- package/dist/ai/composables/useBroadcastChannelInstance.md +97 -0
- package/dist/ai/composables/useConfirm.md +306 -0
- package/dist/ai/composables/useCountdown.md +84 -0
- package/dist/ai/composables/useId.md +60 -0
- package/dist/ai/composables/useMobile.md +85 -0
- package/dist/ai/composables/useToast.md +230 -0
- package/dist/ai/guides/agent-contract.md +108 -0
- package/dist/ai/guides/ai-router.md +111 -0
- package/dist/ai/guides/app-layout.md +295 -0
- package/dist/ai/guides/coherence-playbook.md +136 -0
- package/dist/ai/guides/component-picker.md +195 -0
- package/dist/ai/guides/design-language.md +461 -0
- package/dist/ai/guides/design-tokens.md +424 -0
- package/dist/ai/guides/fetch-items-playbook.md +161 -0
- package/dist/ai/guides/floating-bottom-panel.md +191 -0
- package/dist/ai/guides/icons-policy.md +257 -0
- package/dist/ai/guides/inertia-helpers.md +1394 -0
- package/dist/ai/guides/inline-edit-playbook.md +258 -0
- package/dist/ai/guides/installation-and-plugin-setup.md +377 -0
- package/dist/ai/guides/migration/components/bb-alert.md +37 -0
- package/dist/ai/guides/migration/components/bb-avatar.md +24 -0
- package/dist/ai/guides/migration/components/bb-badge.md +110 -0
- package/dist/ai/guides/migration/components/bb-breadcrumbs.md +26 -0
- package/dist/ai/guides/migration/components/bb-button.md +55 -0
- package/dist/ai/guides/migration/components/bb-checkbox-group.md +54 -0
- package/dist/ai/guides/migration/components/bb-checkbox.md +45 -0
- package/dist/ai/guides/migration/components/bb-chip.md +35 -0
- package/dist/ai/guides/migration/components/bb-collapsible.md +26 -0
- package/dist/ai/guides/migration/components/bb-color-input.md +23 -0
- package/dist/ai/guides/migration/components/bb-color-palette.md +31 -0
- package/dist/ai/guides/migration/components/bb-date-picker-input.md +84 -0
- package/dist/ai/guides/migration/components/bb-dialog.md +46 -0
- package/dist/ai/guides/migration/components/bb-dropdown-button.md +31 -0
- package/dist/ai/guides/migration/components/bb-dropdown.md +36 -0
- package/dist/ai/guides/migration/components/bb-dropzone.md +27 -0
- package/dist/ai/guides/migration/components/bb-icon.md +27 -0
- package/dist/ai/guides/migration/components/bb-off-canvas.md +25 -0
- package/dist/ai/guides/migration/components/bb-offcanvas.md +54 -0
- package/dist/ai/guides/migration/components/bb-pagination.md +24 -0
- package/dist/ai/guides/migration/components/bb-popover.md +52 -0
- package/dist/ai/guides/migration/components/bb-rating.md +24 -0
- package/dist/ai/guides/migration/components/bb-select-popover.md +58 -0
- package/dist/ai/guides/migration/components/bb-select.md +68 -0
- package/dist/ai/guides/migration/components/bb-slider.md +25 -0
- package/dist/ai/guides/migration/components/bb-smooth-height.md +45 -0
- package/dist/ai/guides/migration/components/bb-spinner.md +23 -0
- package/dist/ai/guides/migration/components/bb-table.md +66 -0
- package/dist/ai/guides/migration/components/bb-tabs.md +47 -0
- package/dist/ai/guides/migration/components/bb-tag.md +29 -0
- package/dist/ai/guides/migration/components/bb-text-input.md +37 -0
- package/dist/ai/guides/migration/components/bb-toast.md +47 -0
- package/dist/ai/guides/migration/components/bb-tooltip.md +34 -0
- package/dist/ai/guides/migration/components/bb-tree.md +77 -0
- package/dist/ai/guides/migration/components/use-confirm.md +46 -0
- package/dist/ai/guides/migration/v2-to-v3.md +649 -0
- package/dist/ai/guides/options-items-playbook.md +222 -0
- package/dist/ai/guides/page-shell.md +314 -0
- package/dist/ai/guides/validated-forms.md +177 -0
- package/dist/ai/index.md +156 -32
- package/dist/ai/recipes/inertia/approvals-inbox.md +1598 -0
- package/dist/ai/recipes/inertia/inline-edit-workspace.md +1733 -0
- package/dist/ai/recipes/inertia/onboarding.md +1765 -0
- package/dist/ai/recipes/inertia/ownership-atlas.md +1281 -0
- package/dist/ai/recipes/inertia/record-form.md +1442 -0
- package/dist/ai/recipes/inertia/records-workspace.md +1328 -0
- package/dist/ai/recipes/inertia/upload-center.md +1926 -0
- package/dist/ai/recipes/inertia/wizard-form.md +1477 -0
- package/dist/ai/recipes/nuxt/approvals-inbox.md +1561 -0
- package/dist/ai/recipes/nuxt/inline-edit-workspace.md +1690 -0
- package/dist/ai/recipes/nuxt/onboarding.md +1698 -0
- package/dist/ai/recipes/nuxt/record-form.md +1456 -0
- package/dist/ai/recipes/nuxt/records-workspace.md +1314 -0
- package/dist/ai/recipes/nuxt/upload-center.md +1847 -0
- package/dist/ai/recipes/nuxt/wizard-form.md +1486 -0
- package/dist/ai/recipes/vue/approvals-inbox.md +1479 -0
- package/dist/ai/recipes/vue/inline-edit-workspace.md +1581 -0
- package/dist/ai/recipes/vue/onboarding.md +1653 -0
- package/dist/ai/recipes/vue/record-form.md +1540 -0
- package/dist/ai/recipes/vue/records-workspace.md +1230 -0
- package/dist/ai/recipes/vue/upload-center.md +1806 -0
- package/dist/ai/recipes/vue/wizard-form.md +1418 -0
- package/dist/ai/source/BbAccordion.md +122 -0
- package/dist/ai/source/BbAlert.md +396 -0
- package/dist/ai/source/BbAsterisk.md +32 -0
- package/dist/ai/source/BbAvatar.md +256 -0
- package/dist/ai/source/BbBadge.md +560 -0
- package/dist/ai/source/BbBadgeButton.md +490 -0
- package/dist/ai/source/BbBaseButton.md +682 -0
- package/dist/ai/source/BbBaseCheckbox.md +459 -0
- package/dist/ai/source/BbBaseCheckboxGroup.md +554 -0
- package/dist/ai/source/BbBaseCheckboxIcon.md +201 -0
- package/dist/ai/source/BbBaseColorInput.md +413 -0
- package/dist/ai/source/BbBaseColorPalette.md +934 -0
- package/dist/ai/source/BbBaseDatePicker.md +1001 -0
- package/dist/ai/source/BbBaseDatePickerInput.md +1781 -0
- package/dist/ai/source/BbBaseInputContainer.md +1148 -0
- package/dist/ai/source/BbBaseNumberInput.md +615 -0
- package/dist/ai/source/BbBaseRadio.md +377 -0
- package/dist/ai/source/BbBaseRadioGroup.md +499 -0
- package/dist/ai/source/BbBaseRadioIcon.md +153 -0
- package/dist/ai/source/BbBaseRating.md +573 -0
- package/dist/ai/source/BbBaseSelect.md +895 -0
- package/dist/ai/source/BbBaseSlider.md +1085 -0
- package/dist/ai/source/BbBaseSwitch.md +246 -0
- package/dist/ai/source/BbBaseSwitchGroup.md +302 -0
- package/dist/ai/source/BbBaseSwitchIcon.md +206 -0
- package/dist/ai/source/BbBaseTag.md +688 -0
- package/dist/ai/source/BbBaseTextInput.md +511 -0
- package/dist/ai/source/BbBaseTextarea.md +480 -0
- package/dist/ai/source/BbBaseTimePickerInput.md +1013 -0
- package/dist/ai/source/BbBreadcrumbs.md +811 -0
- package/dist/ai/source/BbButton.md +990 -0
- package/dist/ai/source/BbCheckbox.md +319 -0
- package/dist/ai/source/BbCheckboxGroup.md +412 -0
- package/dist/ai/source/BbCollapsible.md +133 -0
- package/dist/ai/source/BbColorInput.md +315 -0
- package/dist/ai/source/BbColorPalette.md +361 -0
- package/dist/ai/source/BbConfirm.md +173 -0
- package/dist/ai/source/BbConfirmPortal.md +74 -0
- package/dist/ai/source/BbDatePicker.md +725 -0
- package/dist/ai/source/BbDatePickerInput.md +518 -0
- package/dist/ai/source/BbDialog.md +812 -0
- package/dist/ai/source/BbDropdown.md +2369 -0
- package/dist/ai/source/BbDropdownButton.md +313 -0
- package/dist/ai/source/BbDropdownGroup.md +1249 -0
- package/dist/ai/source/BbDropzone.md +749 -0
- package/dist/ai/source/BbForm.md +100 -0
- package/dist/ai/source/BbIcon.md +212 -0
- package/dist/ai/source/BbIndicator.md +298 -0
- package/dist/ai/source/BbNumberInput.md +365 -0
- package/dist/ai/source/BbOffCanvas.md +1260 -0
- package/dist/ai/source/BbPagination.md +829 -0
- package/dist/ai/source/BbPopover.md +853 -0
- package/dist/ai/source/BbProgress.md +140 -0
- package/dist/ai/source/BbRadio.md +294 -0
- package/dist/ai/source/BbRadioGroup.md +401 -0
- package/dist/ai/source/BbRating.md +362 -0
- package/dist/ai/source/BbSelect.md +681 -0
- package/dist/ai/source/BbSelectPopover.md +2209 -0
- package/dist/ai/source/BbSlider.md +371 -0
- package/dist/ai/source/BbSmoothHeight.md +261 -0
- package/dist/ai/source/BbSpinner.md +127 -0
- package/dist/ai/source/BbSwitch.md +175 -0
- package/dist/ai/source/BbSwitchGroup.md +240 -0
- package/dist/ai/source/BbTable.md +3348 -0
- package/dist/ai/source/BbTabs.md +403 -0
- package/dist/ai/source/BbTabsList.md +578 -0
- package/dist/ai/source/BbTabsPanes.md +368 -0
- package/dist/ai/source/BbTabsRoot.md +372 -0
- package/dist/ai/source/BbTag.md +383 -0
- package/dist/ai/source/BbTextInput.md +345 -0
- package/dist/ai/source/BbTextarea.md +330 -0
- package/dist/ai/source/BbTimePicker.md +591 -0
- package/dist/ai/source/BbTimePickerInput.md +367 -0
- package/dist/ai/source/BbToast.md +524 -0
- package/dist/ai/source/BbToastPortal.md +482 -0
- package/dist/ai/source/BbTooltip.md +508 -0
- package/dist/ai/source/BbTree.md +319 -0
- package/dist/ai/source/ChipsBox.md +201 -0
- package/dist/ai/source/ClearableButton.md +70 -0
- package/dist/ai/source/CommaBox.md +202 -0
- package/dist/ai/source/CommonInputWrapper.md +554 -0
- package/dist/ai/source/CommonPopover.md +606 -0
- package/dist/ai/source/ErrorIcon.md +43 -0
- package/dist/ai/source/FlatListBox.md +396 -0
- package/dist/ai/source/GroupedListBox.md +540 -0
- package/dist/ai/source/GuidesComponent.md +383 -0
- package/dist/ai/source/ListBox.md +238 -0
- package/dist/ai/source/OptionsContainer.md +191 -0
- package/dist/ai/source/WarningIcon.md +47 -0
- package/dist/alert-variants.d.ts +12 -0
- package/dist/assets/css/reset.css_inline.js +4 -0
- package/dist/assets/svgs/alert.svg_raw.js +4 -0
- package/dist/assets/svgs/calendar.svg_raw.js +4 -0
- package/dist/assets/svgs/check_stroke.svg_raw.js +4 -0
- package/dist/assets/svgs/chevron_down.svg_raw.js +4 -0
- package/dist/assets/svgs/chevron_right.svg_raw.js +4 -0
- package/dist/assets/svgs/clear.svg_raw.js +4 -0
- package/dist/assets/svgs/clock.svg_raw.js +4 -0
- package/dist/assets/svgs/error.svg_raw.js +4 -0
- package/dist/assets/svgs/search.svg_raw.js +4 -0
- package/dist/assets/svgs/sort.svg_raw.js +4 -0
- package/dist/assets/svgs/spinner.svg_raw.js +4 -0
- package/dist/assets/svgs/user.svg_raw.js +4 -0
- package/dist/badge-variants.d.ts +18 -0
- package/dist/button-variants.d.ts +15 -0
- package/dist/components/BbAccordion/BbAccordion.vue.d.ts +9 -3
- package/dist/components/BbAccordion/BbAccordion.vue.js +6 -0
- package/dist/components/BbAccordion/BbAccordion.vue_vue_type_script_setup_true_lang.js +66 -0
- package/dist/components/BbAccordion/types.d.ts +10 -7
- package/dist/components/BbAlert/BbAlert.vue.d.ts +12 -3
- package/dist/components/BbAlert/BbAlert.vue.js +6 -0
- package/dist/components/BbAlert/BbAlert.vue_vue_type_script_setup_true_lang.js +65 -0
- package/dist/components/BbAlert/types.d.ts +51 -12
- package/dist/components/BbAsterisk/BbAsterisk.vue.d.ts +3 -0
- package/dist/components/BbAsterisk/BbAsterisk.vue.js +6 -0
- package/dist/components/BbAsterisk/BbAsterisk.vue_vue_type_script_setup_true_lang.js +13 -0
- package/dist/components/BbAvatar/BbAvatar.vue.d.ts +5 -0
- package/dist/components/BbAvatar/BbAvatar.vue.js +6 -0
- package/dist/components/BbAvatar/BbAvatar.vue_vue_type_script_setup_true_lang.js +78 -0
- package/dist/components/BbAvatar/types.d.ts +4 -5
- package/dist/components/BbBadge/BadgeAppendIcon.vue.d.ts +3 -0
- package/dist/components/BbBadge/BadgeAppendIcon.vue.js +5 -0
- package/dist/components/BbBadge/BadgeAppendIcon.vue_vue_type_script_setup_true_lang.js +22 -0
- package/dist/components/BbBadge/BadgeBodyContent.vue.d.ts +15 -0
- package/dist/components/BbBadge/BadgeBodyContent.vue.js +5 -0
- package/dist/components/BbBadge/BadgeBodyContent.vue_vue_type_script_setup_true_lang.js +34 -0
- package/dist/components/BbBadge/BbBadge.vue.d.ts +8 -1
- package/dist/components/BbBadge/BbBadge.vue.js +6 -0
- package/dist/components/BbBadge/BbBadge.vue_vue_type_script_setup_true_lang.js +83 -0
- package/dist/components/BbBadge/BbBadgeButton.vue.d.ts +12 -0
- package/dist/components/BbBadge/BbBadgeButton.vue.js +5 -0
- package/dist/components/BbBadge/BbBadgeButton.vue_vue_type_script_setup_true_lang.js +54 -0
- package/dist/components/BbBadge/badgeButtonContext.d.ts +27 -0
- package/dist/components/BbBadge/badgeButtonContext.js +5 -0
- package/dist/components/BbBadge/types.d.ts +61 -16
- package/dist/components/BbBaseButton/BbBaseButton.vue.d.ts +13 -0
- package/dist/components/BbBaseButton/BbBaseButton.vue.js +6 -0
- package/dist/components/BbBaseButton/BbBaseButton.vue_vue_type_script_setup_true_lang.js +171 -0
- package/dist/components/BbBaseButton/RouterComponent.vue.js +5 -0
- package/dist/components/BbBaseButton/RouterComponent.vue_vue_type_script_setup_true_lang.js +28 -0
- package/dist/components/BbBaseButton/types.d.ts +191 -0
- package/dist/components/BbBaseButton/types.js +33 -0
- package/dist/components/BbBaseCheckbox/BbBaseCheckbox.vue.d.ts +40 -0
- package/dist/components/BbBaseCheckbox/BbBaseCheckbox.vue.js +6 -0
- package/dist/components/BbBaseCheckbox/BbBaseCheckbox.vue_vue_type_script_setup_true_lang.js +145 -0
- package/dist/components/BbBaseCheckbox/types.d.ts +222 -0
- package/dist/components/BbBaseCheckboxGroup/BbBaseCheckboxGroup.vue.d.ts +19 -0
- package/dist/components/BbBaseCheckboxGroup/BbBaseCheckboxGroup.vue.js +6 -0
- package/dist/components/BbBaseCheckboxGroup/BbBaseCheckboxGroup.vue_vue_type_script_setup_true_lang.js +190 -0
- package/dist/components/BbBaseCheckboxGroup/types.d.ts +257 -0
- package/dist/components/BbBaseCheckboxIcon/BbBaseCheckboxIcon.vue.d.ts +4 -0
- package/dist/components/BbBaseCheckboxIcon/BbBaseCheckboxIcon.vue.js +6 -0
- package/dist/components/BbBaseCheckboxIcon/BbBaseCheckboxIcon.vue_vue_type_script_setup_true_lang.js +43 -0
- package/dist/components/BbBaseCheckboxIcon/types.d.ts +47 -0
- package/dist/components/BbBaseColorInput/BbBaseColorInput.vue.d.ts +42 -0
- package/dist/components/BbBaseColorInput/BbBaseColorInput.vue.js +6 -0
- package/dist/components/BbBaseColorInput/BbBaseColorInput.vue_vue_type_script_setup_true_lang.js +178 -0
- package/dist/components/BbBaseColorInput/types.d.ts +207 -0
- package/dist/components/BbBaseColorPalette/BbBaseColorPalette.vue.d.ts +13 -0
- package/dist/components/BbBaseColorPalette/BbBaseColorPalette.vue.js +6 -0
- package/dist/components/BbBaseColorPalette/BbBaseColorPalette.vue_vue_type_script_setup_true_lang.js +395 -0
- package/dist/components/BbBaseColorPalette/types.d.ts +40 -0
- package/dist/components/BbBaseDatePicker/BbBaseDatePicker.vue.js +6 -0
- package/dist/components/BbBaseDatePicker/BbBaseDatePicker.vue_vue_type_script_setup_true_lang.js +300 -0
- package/dist/components/BbBaseDatePicker/BbBaseDatePickerInputDaySelector.vue.d.ts +44 -0
- package/dist/components/BbBaseDatePicker/BbBaseDatePickerInputDaySelector.vue.js +5 -0
- package/dist/components/BbBaseDatePicker/BbBaseDatePickerInputDaySelector.vue_vue_type_script_setup_true_lang.js +310 -0
- package/dist/components/BbBaseDatePicker/BbBaseDatePickerMonthSelector.vue.d.ts +5 -0
- package/dist/components/BbBaseDatePicker/BbBaseDatePickerMonthSelector.vue.js +5 -0
- package/dist/components/BbBaseDatePicker/BbBaseDatePickerMonthSelector.vue_vue_type_script_setup_true_lang.js +63 -0
- package/dist/components/BbBaseDatePicker/BbBaseDatePickerYearSelector.vue.d.ts +5 -0
- package/dist/components/BbBaseDatePicker/BbBaseDatePickerYearSelector.vue.js +5 -0
- package/dist/components/BbBaseDatePicker/BbBaseDatePickerYearSelector.vue_vue_type_script_setup_true_lang.js +75 -0
- package/dist/components/BbBaseDatePicker/typeahead.d.ts +112 -0
- package/dist/components/BbBaseDatePicker/typeahead.js +37 -0
- package/dist/components/BbBaseDatePicker/types.d.ts +97 -0
- package/dist/components/BbBaseDatePicker/useDatePickerContext.d.ts +58 -0
- package/dist/components/BbBaseDatePicker/useDatePickerContext.js +11 -0
- package/dist/components/BbBaseDatePickerInput/BbBaseDatePickerInput.vue.d.ts +30 -0
- package/dist/components/BbBaseDatePickerInput/BbBaseDatePickerInput.vue.js +6 -0
- package/dist/components/BbBaseDatePickerInput/BbBaseDatePickerInput.vue_vue_type_script_setup_true_lang.js +713 -0
- package/dist/components/BbBaseDatePickerInput/BbBaseDatePickerTimeSelector.vue.d.ts +30 -0
- package/dist/components/BbBaseDatePickerInput/BbBaseDatePickerTimeSelector.vue.js +6 -0
- package/dist/components/BbBaseDatePickerInput/BbBaseDatePickerTimeSelector.vue_vue_type_script_setup_true_lang.js +204 -0
- package/dist/components/BbBaseDatePickerInput/types.d.ts +309 -0
- package/dist/components/BbBaseInputContainer/BbBaseInputContainer.vue.d.ts +17 -0
- package/dist/components/BbBaseInputContainer/BbBaseInputContainer.vue.js +6 -0
- package/dist/components/BbBaseInputContainer/BbBaseInputContainer.vue_vue_type_script_setup_true_lang.js +184 -0
- package/dist/components/BbBaseInputContainer/types.d.ts +185 -0
- package/dist/components/BbBaseNumberInput/BbBaseNumberInput.vue.d.ts +52 -0
- package/dist/components/BbBaseNumberInput/BbBaseNumberInput.vue.js +6 -0
- package/dist/components/BbBaseNumberInput/BbBaseNumberInput.vue_vue_type_script_setup_true_lang.js +211 -0
- package/dist/components/BbBaseNumberInput/types.d.ts +211 -0
- package/dist/components/BbBaseRadio/BbBaseRadio.vue.d.ts +33 -0
- package/dist/components/BbBaseRadio/BbBaseRadio.vue.js +6 -0
- package/dist/components/BbBaseRadio/BbBaseRadio.vue_vue_type_script_setup_true_lang.js +114 -0
- package/dist/components/BbBaseRadio/types.d.ts +179 -0
- package/dist/components/BbBaseRadioGroup/BbBaseRadioGroup.vue.d.ts +19 -0
- package/dist/components/BbBaseRadioGroup/BbBaseRadioGroup.vue.js +6 -0
- package/dist/components/BbBaseRadioGroup/BbBaseRadioGroup.vue_vue_type_script_setup_true_lang.js +172 -0
- package/dist/components/BbBaseRadioGroup/types.d.ts +215 -0
- package/dist/components/BbBaseRadioIcon/BbBaseRadioIcon.vue.d.ts +4 -0
- package/dist/components/BbBaseRadioIcon/BbBaseRadioIcon.vue.js +6 -0
- package/dist/components/BbBaseRadioIcon/BbBaseRadioIcon.vue_vue_type_script_setup_true_lang.js +28 -0
- package/dist/components/BbBaseRadioIcon/types.d.ts +41 -0
- package/dist/components/BbBaseRating/BbBaseRating.vue.d.ts +38 -0
- package/dist/components/BbBaseRating/BbBaseRating.vue.js +6 -0
- package/dist/components/BbBaseRating/BbBaseRating.vue_vue_type_script_setup_true_lang.js +184 -0
- package/dist/components/BbBaseRating/types.d.ts +168 -0
- package/dist/components/BbBaseSelect/BbBaseSelect.vue.d.ts +19 -0
- package/dist/components/BbBaseSelect/BbBaseSelect.vue.js +6 -0
- package/dist/components/BbBaseSelect/BbBaseSelect.vue_vue_type_script_setup_true_lang.js +307 -0
- package/dist/components/BbBaseSelect/types.d.ts +294 -0
- package/dist/components/BbBaseSlider/BbBaseSlider.vue.d.ts +35 -0
- package/dist/components/BbBaseSlider/BbBaseSlider.vue.js +6 -0
- package/dist/components/BbBaseSlider/BbBaseSlider.vue_vue_type_script_setup_true_lang.js +324 -0
- package/dist/components/BbBaseSlider/types.d.ts +200 -0
- package/dist/components/BbBaseSwitch/BbBaseSwitch.vue.d.ts +35 -0
- package/dist/components/BbBaseSwitch/BbBaseSwitch.vue.js +6 -0
- package/dist/components/BbBaseSwitch/BbBaseSwitch.vue_vue_type_script_setup_true_lang.js +146 -0
- package/dist/components/BbBaseSwitch/types.d.ts +10 -0
- package/dist/components/BbBaseSwitchGroup/BbBaseSwitchGroup.vue.d.ts +19 -0
- package/dist/components/BbBaseSwitchGroup/BbBaseSwitchGroup.vue.js +6 -0
- package/dist/components/BbBaseSwitchGroup/BbBaseSwitchGroup.vue_vue_type_script_setup_true_lang.js +190 -0
- package/dist/components/BbBaseSwitchGroup/types.d.ts +8 -0
- package/dist/components/BbBaseSwitchIcon/BbBaseSwitchIcon.vue.d.ts +4 -0
- package/dist/components/BbBaseSwitchIcon/BbBaseSwitchIcon.vue.js +6 -0
- package/dist/components/BbBaseSwitchIcon/BbBaseSwitchIcon.vue_vue_type_script_setup_true_lang.js +30 -0
- package/dist/components/BbBaseSwitchIcon/types.d.ts +48 -0
- package/dist/components/BbBaseTag/BbBaseTag.vue.d.ts +50 -0
- package/dist/components/BbBaseTag/BbBaseTag.vue.js +6 -0
- package/dist/components/BbBaseTag/BbBaseTag.vue_vue_type_script_setup_true_lang.js +266 -0
- package/dist/components/BbBaseTag/types.d.ts +160 -0
- package/dist/components/BbBaseTextInput/BbBaseTextInput.vue.d.ts +45 -0
- package/dist/components/BbBaseTextInput/BbBaseTextInput.vue.js +6 -0
- package/dist/components/BbBaseTextInput/BbBaseTextInput.vue_vue_type_script_setup_true_lang.js +200 -0
- package/dist/components/BbBaseTextInput/types.d.ts +209 -0
- package/dist/components/BbBaseTextarea/BbBaseTextarea.vue.d.ts +39 -0
- package/dist/components/BbBaseTextarea/BbBaseTextarea.vue.js +6 -0
- package/dist/components/BbBaseTextarea/BbBaseTextarea.vue_vue_type_script_setup_true_lang.js +175 -0
- package/dist/components/BbBaseTextarea/types.d.ts +170 -0
- package/dist/components/BbBaseTimePickerInput/BbBaseTimePickerInput.vue.d.ts +27 -0
- package/dist/components/BbBaseTimePickerInput/BbBaseTimePickerInput.vue.js +6 -0
- package/dist/components/BbBaseTimePickerInput/BbBaseTimePickerInput.vue_vue_type_script_setup_true_lang.js +517 -0
- package/dist/components/BbBaseTimePickerInput/types.d.ts +151 -0
- package/dist/components/BbBreadcrumbs/BbBreadcrumbs.vue.d.ts +0 -1
- package/dist/components/BbBreadcrumbs/BbBreadcrumbs.vue.js +6 -0
- package/dist/components/BbBreadcrumbs/BbBreadcrumbs.vue_vue_type_script_setup_true_lang.js +224 -0
- package/dist/components/BbBreadcrumbs/estimateBreadcrumbItemWidth.js +47 -0
- package/dist/components/BbBreadcrumbs/types.d.ts +33 -22
- package/dist/components/BbButton/BbButton.vue.d.ts +6 -5
- package/dist/components/BbButton/BbButton.vue.js +6 -0
- package/dist/components/BbButton/BbButton.vue_vue_type_script_setup_true_lang.js +177 -0
- package/dist/components/BbButton/types.d.ts +48 -47
- package/dist/components/BbCheckbox/BbCheckbox.vue.d.ts +4 -3
- package/dist/components/BbCheckbox/BbCheckbox.vue.js +6 -0
- package/dist/components/BbCheckbox/BbCheckbox.vue_vue_type_script_setup_true_lang.js +146 -0
- package/dist/components/BbCheckbox/types.d.ts +24 -10
- package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue.d.ts +2 -13
- package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue.js +6 -0
- package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue_vue_type_script_setup_true_lang.js +190 -0
- package/dist/components/BbCheckboxGroup/types.d.ts +44 -23
- package/dist/components/BbCollapsible/BbCollapsible.vue.d.ts +2 -1
- package/dist/components/BbCollapsible/BbCollapsible.vue.js +6 -0
- package/dist/components/BbCollapsible/BbCollapsible.vue_vue_type_script_setup_true_lang.js +31 -0
- package/dist/components/BbCollapsible/types.d.ts +10 -9
- package/dist/components/BbColorInput/BbColorInput.vue.d.ts +10 -1
- package/dist/components/BbColorInput/BbColorInput.vue.js +6 -0
- package/dist/components/BbColorInput/BbColorInput.vue_vue_type_script_setup_true_lang.js +177 -0
- package/dist/components/BbColorInput/types.d.ts +37 -11
- package/dist/components/BbColorPalette/BbColorPalette.vue.d.ts +5 -8
- package/dist/components/BbColorPalette/BbColorPalette.vue.js +5 -0
- package/dist/components/BbColorPalette/BbColorPalette.vue_vue_type_script_setup_true_lang.js +125 -0
- package/dist/components/BbColorPalette/types.d.ts +66 -53
- package/dist/components/BbConfirm/BbConfirm.vue.js +6 -0
- package/dist/components/BbConfirm/BbConfirm.vue_vue_type_script_setup_true_lang.js +130 -0
- package/dist/components/BbConfirm/BbConfirmPortal.vue.d.ts +5 -6
- package/dist/components/BbConfirm/BbConfirmPortal.vue.js +5 -0
- package/dist/components/BbConfirm/BbConfirmPortal.vue_vue_type_script_setup_true_lang.js +19 -0
- package/dist/components/BbDatePicker/BbDatePicker.vue.d.ts +37 -0
- package/dist/components/BbDatePicker/BbDatePicker.vue.js +6 -0
- package/dist/components/BbDatePicker/BbDatePicker.vue_vue_type_script_setup_true_lang.js +319 -0
- package/dist/components/BbDatePicker/types.d.ts +155 -0
- package/dist/components/BbDatePickerInput/BbDatePickerInput.vue.d.ts +3 -1
- package/dist/components/BbDatePickerInput/BbDatePickerInput.vue.js +6 -0
- package/dist/components/BbDatePickerInput/BbDatePickerInput.vue_vue_type_script_setup_true_lang.js +179 -0
- package/dist/components/BbDatePickerInput/types.d.ts +127 -16
- package/dist/components/BbDialog/BbDialog.vue.d.ts +8 -6
- package/dist/components/BbDialog/BbDialog.vue.js +6 -0
- package/dist/components/BbDialog/BbDialog.vue_vue_type_script_setup_true_lang.js +214 -0
- package/dist/components/BbDialog/types.d.ts +146 -1
- package/dist/components/BbDialog/useDialogStack.d.ts +5 -0
- package/dist/components/BbDialog/useDialogStack.js +20 -0
- package/dist/components/BbDropdown/AdaptiveDropdown.vue.d.ts +18 -0
- package/dist/components/BbDropdown/AdaptiveDropdown.vue.js +6 -0
- package/dist/components/BbDropdown/AdaptiveDropdown.vue_vue_type_script_setup_true_lang.js +116 -0
- package/dist/components/BbDropdown/BbDropdown.vue.d.ts +14 -7
- package/dist/components/BbDropdown/BbDropdown.vue.js +6 -0
- package/dist/components/BbDropdown/BbDropdown.vue_vue_type_script_setup_true_lang.js +560 -0
- package/dist/components/BbDropdown/BbDropdownGroup.vue.d.ts +44 -0
- package/dist/components/BbDropdown/BbDropdownGroup.vue.js +5 -0
- package/dist/components/BbDropdown/BbDropdownGroup.vue_vue_type_script_setup_true_lang.js +36 -0
- package/dist/components/BbDropdown/BbDropdownList.vue.d.ts +27 -0
- package/dist/components/BbDropdown/BbDropdownList.vue.js +6 -0
- package/dist/components/BbDropdown/BbDropdownList.vue_vue_type_script_setup_true_lang.js +464 -0
- package/dist/components/BbDropdown/DropdownPipelineResolver.vue.d.ts +16 -0
- package/dist/components/BbDropdown/DropdownPipelineResolver.vue.js +5 -0
- package/dist/components/BbDropdown/DropdownPipelineResolver.vue_vue_type_script_setup_true_lang.js +168 -0
- package/dist/components/BbDropdown/normalizeGroups.d.ts +18 -0
- package/dist/components/BbDropdown/normalizeGroups.js +46 -0
- package/dist/components/BbDropdown/types.d.ts +457 -45
- package/dist/components/BbDropdown/types.js +4 -0
- package/dist/components/BbDropdown/useDropdownContext.d.ts +89 -0
- package/dist/components/BbDropdown/useDropdownContext.js +9 -0
- package/dist/components/BbDropdown/useDropdownGroupRegistry.d.ts +108 -0
- package/dist/components/BbDropdown/useDropdownGroupRegistry.js +5 -0
- package/dist/components/BbDropdownButton/BbDropdownButton.vue.d.ts +3 -3
- package/dist/components/BbDropdownButton/BbDropdownButton.vue.js +6 -0
- package/dist/components/BbDropdownButton/BbDropdownButton.vue_vue_type_script_setup_true_lang.js +119 -0
- package/dist/components/BbDropdownButton/types.d.ts +45 -52
- package/dist/components/BbDropzone/BbDropzone.vue.d.ts +5 -4
- package/dist/components/BbDropzone/BbDropzone.vue.js +6 -0
- package/dist/components/BbDropzone/BbDropzone.vue_vue_type_script_setup_true_lang.js +284 -0
- package/dist/components/BbDropzone/types.d.ts +55 -7
- package/dist/components/BbIcon/BbIcon.vue.d.ts +3 -2
- package/dist/components/BbIcon/BbIcon.vue.js +6 -0
- package/dist/components/BbIcon/BbIcon.vue_vue_type_script_setup_true_lang.js +65 -0
- package/dist/components/BbIcon/types.d.ts +6 -19
- package/dist/components/BbIndicator/BbIndicator.vue.d.ts +14 -0
- package/dist/components/BbIndicator/BbIndicator.vue.js +6 -0
- package/dist/components/BbIndicator/BbIndicator.vue_vue_type_script_setup_true_lang.js +56 -0
- package/dist/components/BbIndicator/types.d.ts +49 -0
- package/dist/components/BbNumberInput/BbNumberInput.vue.d.ts +12 -6
- package/dist/components/BbNumberInput/BbNumberInput.vue.js +6 -0
- package/dist/components/BbNumberInput/BbNumberInput.vue_vue_type_script_setup_true_lang.js +194 -0
- package/dist/components/BbNumberInput/types.d.ts +31 -4
- package/dist/components/BbOffCanvas/BbOffCanvas.vue.d.ts +10 -10
- package/dist/components/BbOffCanvas/BbOffCanvas.vue.js +6 -0
- package/dist/components/BbOffCanvas/BbOffCanvas.vue_vue_type_script_setup_true_lang.js +284 -0
- package/dist/components/BbOffCanvas/types.d.ts +71 -39
- package/dist/components/BbOffCanvas/useOffCanvasStack.d.ts +25 -0
- package/dist/components/BbOffCanvas/useOffCanvasStack.js +68 -0
- package/dist/components/BbPagination/BbPagination.vue.d.ts +3 -4
- package/dist/components/BbPagination/BbPagination.vue.js +6 -0
- package/dist/components/BbPagination/BbPagination.vue_vue_type_script_setup_true_lang.js +244 -0
- package/dist/components/BbPagination/paginationFit.d.ts +38 -0
- package/dist/components/BbPagination/paginationFit.js +13 -0
- package/dist/components/BbPagination/types.d.ts +51 -16
- package/dist/components/BbPopover/BbPopover.vue.d.ts +10 -15
- package/dist/components/BbPopover/BbPopover.vue.js +6 -0
- package/dist/components/BbPopover/BbPopover.vue_vue_type_script_setup_true_lang.js +310 -0
- package/dist/components/BbPopover/escapeStack.d.ts +6 -0
- package/dist/components/BbPopover/escapeStack.js +10 -0
- package/dist/components/BbPopover/types.d.ts +84 -31
- package/dist/components/BbProgress/BbProgress.vue.d.ts +1 -0
- package/dist/components/BbProgress/BbProgress.vue.js +6 -0
- package/dist/components/BbProgress/BbProgress.vue_vue_type_script_setup_true_lang.js +36 -0
- package/dist/components/BbProgress/types.d.ts +15 -1
- package/dist/components/BbRadio/BbRadio.vue.d.ts +5 -3
- package/dist/components/BbRadio/BbRadio.vue.js +6 -0
- package/dist/components/BbRadio/BbRadio.vue_vue_type_script_setup_true_lang.js +133 -0
- package/dist/components/BbRadio/types.d.ts +23 -9
- package/dist/components/BbRadioGroup/BbRadioGroup.vue.d.ts +4 -14
- package/dist/components/BbRadioGroup/BbRadioGroup.vue.js +6 -0
- package/dist/components/BbRadioGroup/BbRadioGroup.vue_vue_type_script_setup_true_lang.js +184 -0
- package/dist/components/BbRadioGroup/types.d.ts +41 -22
- package/dist/components/BbRating/BbRating.vue.d.ts +4 -1
- package/dist/components/BbRating/BbRating.vue.js +6 -0
- package/dist/components/BbRating/BbRating.vue_vue_type_script_setup_true_lang.js +150 -0
- package/dist/components/BbRating/types.d.ts +37 -10
- package/dist/components/BbSelect/BbSelect.vue.d.ts +2 -11
- package/dist/components/BbSelect/BbSelect.vue.js +6 -0
- package/dist/components/BbSelect/BbSelect.vue_vue_type_script_setup_true_lang.js +241 -0
- package/dist/components/BbSelect/types.d.ts +105 -59
- package/dist/components/BbSelectPopover/BbSelectPopover.vue.d.ts +1 -10
- package/dist/components/BbSelectPopover/BbSelectPopover.vue.js +6 -0
- package/dist/components/BbSelectPopover/BbSelectPopover.vue_vue_type_script_setup_true_lang.js +637 -0
- package/dist/components/BbSelectPopover/types.d.ts +189 -102
- package/dist/components/BbSlider/BbSlider.vue.d.ts +3 -6
- package/dist/components/BbSlider/BbSlider.vue.js +6 -0
- package/dist/components/BbSlider/BbSlider.vue_vue_type_script_setup_true_lang.js +166 -0
- package/dist/components/BbSlider/types.d.ts +37 -13
- package/dist/components/BbSmoothHeight/BbSmoothHeight.vue.d.ts +3 -1
- package/dist/components/BbSmoothHeight/BbSmoothHeight.vue.js +6 -0
- package/dist/components/BbSmoothHeight/BbSmoothHeight.vue_vue_type_script_setup_true_lang.js +79 -0
- package/dist/components/BbSmoothHeight/types.d.ts +13 -2
- package/dist/components/BbSpinner/BbSpinner.vue.d.ts +1 -1
- package/dist/components/BbSpinner/BbSpinner.vue.js +6 -0
- package/dist/components/BbSpinner/BbSpinner.vue_vue_type_script_setup_true_lang.js +30 -0
- package/dist/components/BbSpinner/types.d.ts +10 -3
- package/dist/components/BbSwitch/BbSwitch.vue.d.ts +5 -3
- package/dist/components/BbSwitch/BbSwitch.vue.js +6 -0
- package/dist/components/BbSwitch/BbSwitch.vue_vue_type_script_setup_true_lang.js +142 -0
- package/dist/components/BbSwitch/types.d.ts +3 -1
- package/dist/components/BbSwitchGroup/BbSwitchGroup.vue.d.ts +4 -14
- package/dist/components/BbSwitchGroup/BbSwitchGroup.vue.js +6 -0
- package/dist/components/BbSwitchGroup/BbSwitchGroup.vue_vue_type_script_setup_true_lang.js +190 -0
- package/dist/components/BbSwitchGroup/types.d.ts +3 -22
- package/dist/components/BbTable/BbTable.vue.d.ts +53 -31
- package/dist/components/BbTable/BbTable.vue.js +6 -0
- package/dist/components/BbTable/BbTable.vue_vue_type_script_setup_true_lang.js +889 -0
- package/dist/components/BbTable/types.d.ts +176 -37
- package/dist/components/BbTable/utils.d.ts +9 -1
- package/dist/components/BbTable/utils.js +53 -0
- package/dist/components/BbTabs/BbTabs.vue.d.ts +20 -0
- package/dist/components/BbTabs/BbTabs.vue.js +6 -0
- package/dist/components/BbTabs/BbTabs.vue_vue_type_script_setup_true_lang.js +64 -0
- package/dist/components/BbTabs/BbTabsList.vue.d.ts +19 -0
- package/dist/components/BbTabs/BbTabsList.vue.js +6 -0
- package/dist/components/BbTabs/BbTabsList.vue_vue_type_script_setup_true_lang.js +123 -0
- package/dist/components/BbTabs/BbTabsPanes.vue.d.ts +16 -0
- package/dist/components/BbTabs/BbTabsPanes.vue.js +6 -0
- package/dist/components/BbTabs/BbTabsPanes.vue_vue_type_script_setup_true_lang.js +35 -0
- package/dist/components/BbTabs/BbTabsRoot.vue.d.ts +20 -0
- package/dist/components/BbTabs/BbTabsRoot.vue.js +5 -0
- package/dist/components/BbTabs/BbTabsRoot.vue_vue_type_script_setup_true_lang.js +55 -0
- package/dist/components/BbTabs/types.d.ts +264 -0
- package/dist/components/BbTag/BbTag.vue.d.ts +19 -6
- package/dist/components/BbTag/BbTag.vue.js +6 -0
- package/dist/components/BbTag/BbTag.vue_vue_type_script_setup_true_lang.js +187 -0
- package/dist/components/BbTag/types.d.ts +48 -17
- package/dist/components/BbTextInput/BbTextInput.vue.d.ts +10 -1
- package/dist/components/BbTextInput/BbTextInput.vue.js +6 -0
- package/dist/components/BbTextInput/BbTextInput.vue_vue_type_script_setup_true_lang.js +195 -0
- package/dist/components/BbTextInput/types.d.ts +24 -4
- package/dist/components/BbTextarea/BbTextarea.vue.d.ts +10 -1
- package/dist/components/BbTextarea/BbTextarea.vue.js +6 -0
- package/dist/components/BbTextarea/BbTextarea.vue_vue_type_script_setup_true_lang.js +178 -0
- package/dist/components/BbTextarea/types.d.ts +26 -2
- package/dist/components/BbTimePicker/BbTimePicker.vue.d.ts +33 -0
- package/dist/components/BbTimePicker/BbTimePicker.vue.js +6 -0
- package/dist/components/BbTimePicker/BbTimePicker.vue_vue_type_script_setup_true_lang.js +244 -0
- package/dist/components/BbTimePicker/types.d.ts +129 -0
- package/dist/components/BbTimePickerInput/BbTimePickerInput.vue.d.ts +25 -0
- package/dist/components/BbTimePickerInput/BbTimePickerInput.vue.js +6 -0
- package/dist/components/BbTimePickerInput/BbTimePickerInput.vue_vue_type_script_setup_true_lang.js +157 -0
- package/dist/components/BbTimePickerInput/types.d.ts +165 -0
- package/dist/components/BbToast/BbToast.vue.d.ts +2 -3
- package/dist/components/BbToast/BbToast.vue.js +6 -0
- package/dist/components/BbToast/BbToast.vue_vue_type_script_setup_true_lang.js +35 -0
- package/dist/components/BbToast/BbToastMessage.vue.d.ts +17 -8
- package/dist/components/BbToast/BbToastMessage.vue.js +5 -0
- package/dist/components/BbToast/BbToastMessage.vue_vue_type_script_setup_true_lang.js +170 -0
- package/dist/components/BbToast/BbToastPortal.vue.d.ts +30 -0
- package/dist/components/BbToast/BbToastPortal.vue.js +5 -0
- package/dist/components/BbToast/BbToastPortal.vue_vue_type_script_setup_true_lang.js +19 -0
- package/dist/components/BbToast/BbToastRegion.vue.d.ts +8 -0
- package/dist/components/BbToast/BbToastRegion.vue.js +5 -0
- package/dist/components/BbToast/BbToastRegion.vue_vue_type_script_setup_true_lang.js +100 -0
- package/dist/components/BbToast/types.d.ts +69 -5
- package/dist/components/BbTooltip/BbTooltip.vue.d.ts +4 -3
- package/dist/components/BbTooltip/BbTooltip.vue.js +6 -0
- package/dist/components/BbTooltip/BbTooltip.vue_vue_type_script_setup_true_lang.js +160 -0
- package/dist/components/BbTooltip/types.d.ts +61 -11
- package/dist/components/BbTree/BbTree.vue.d.ts +26 -13
- package/dist/components/BbTree/BbTree.vue.js +6 -0
- package/dist/components/BbTree/BbTree.vue_vue_type_script_setup_true_lang.js +55 -0
- package/dist/components/BbTree/BbTreeLevel.vue.d.ts +19 -0
- package/dist/components/BbTree/BbTreeLevel.vue.js +5 -0
- package/dist/components/BbTree/BbTreeLevel.vue_vue_type_script_setup_true_lang.js +94 -0
- package/dist/components/BbTree/context.d.ts +17 -0
- package/dist/components/BbTree/context.js +4 -0
- package/dist/components/BbTree/types.d.ts +93 -42
- package/dist/components/ChipsBox/ChipsBox.vue.d.ts +2 -1
- package/dist/components/ChipsBox/ChipsBox.vue.js +5 -0
- package/dist/components/ChipsBox/ChipsBox.vue_vue_type_script_setup_true_lang.js +98 -0
- package/dist/components/ChipsBox/types.d.ts +12 -5
- package/dist/components/ClearableButton/ClearableButton.vue.d.ts +2 -1
- package/dist/components/ClearableButton/ClearableButton.vue.js +6 -0
- package/dist/components/ClearableButton/ClearableButton.vue_vue_type_script_setup_true_lang.js +19 -0
- package/dist/components/ClearableButton/types.d.ts +7 -1
- package/dist/components/CloseIcon/CloseButton.vue.d.ts +5 -0
- package/dist/components/CloseIcon/CloseButton.vue.js +7 -0
- package/dist/components/CloseIcon/CloseButton.vue_vue_type_script_setup_true_lang.js +23 -0
- package/dist/components/CloseIcon/types.d.ts +2 -0
- package/dist/components/CommaBox/CommaBox.vue.d.ts +2 -1
- package/dist/components/CommaBox/CommaBox.vue.js +6 -0
- package/dist/components/CommaBox/CommaBox.vue_vue_type_script_setup_true_lang.js +81 -0
- package/dist/components/CommaBox/types.d.ts +6 -7
- package/dist/components/CommonInputWrapper/CommonInputWrapper.vue.d.ts +19 -0
- package/dist/components/CommonInputWrapper/CommonInputWrapper.vue.js +6 -0
- package/dist/components/CommonInputWrapper/CommonInputWrapper.vue_vue_type_script_setup_true_lang.js +107 -0
- package/dist/components/CommonInputWrapper/types.d.ts +96 -0
- package/dist/components/CommonPopover/CommonPopover.vue.d.ts +3 -3
- package/dist/components/CommonPopover/CommonPopover.vue.js +6 -0
- package/dist/components/CommonPopover/CommonPopover.vue_vue_type_script_setup_true_lang.js +160 -0
- package/dist/components/CommonPopover/types.d.ts +61 -16
- package/dist/components/ErrorIcon/ErrorIcon.vue.d.ts +2 -0
- package/dist/components/ErrorIcon/ErrorIcon.vue.js +6 -0
- package/dist/components/ErrorIcon/ErrorIcon.vue_vue_type_script_setup_true_lang.js +16 -0
- package/dist/components/FlatListBox/FlatListBox.vue.d.ts +2 -5
- package/dist/components/FlatListBox/FlatListBox.vue.js +5 -0
- package/dist/components/FlatListBox/FlatListBox.vue_vue_type_script_setup_true_lang.js +167 -0
- package/dist/components/FlatListBox/types.d.ts +1 -1
- package/dist/components/GroupedListBox/GroupedListBox.vue.d.ts +2 -5
- package/dist/components/GroupedListBox/GroupedListBox.vue.js +5 -0
- package/dist/components/GroupedListBox/GroupedListBox.vue_vue_type_script_setup_true_lang.js +218 -0
- package/dist/components/ListBox/ListBox.vue.d.ts +3 -6
- package/dist/components/ListBox/ListBox.vue.js +5 -0
- package/dist/components/ListBox/ListBox.vue_vue_type_script_setup_true_lang.js +112 -0
- package/dist/components/ListBox/types.d.ts +1 -1
- package/dist/components/OptionsContainer/OptionsContainer.vue.d.ts +1 -0
- package/dist/components/OptionsContainer/OptionsContainer.vue.js +5 -0
- package/dist/components/OptionsContainer/OptionsContainer.vue_vue_type_script_setup_true_lang.js +52 -0
- package/dist/components/OptionsContainer/types.d.ts +14 -24
- package/dist/components/Transitions/ScaleFade.vue.js +5 -0
- package/dist/components/Transitions/ScaleFade.vue_vue_type_script_setup_true_lang.js +47 -0
- package/dist/components/Transitions/Slide.vue.js +7 -0
- package/dist/components/Transitions/Slide.vue_vue_type_script_setup_true_lang.js +28 -0
- package/dist/components/WarningIcon/WarningIcon.vue.d.ts +5 -0
- package/dist/components/WarningIcon/WarningIcon.vue.js +6 -0
- package/dist/components/WarningIcon/WarningIcon.vue_vue_type_script_setup_true_lang.js +16 -0
- package/dist/components/WarningIcon/types.d.ts +3 -0
- package/dist/composables/__testResets.d.ts +1 -0
- package/dist/composables/useActiveInactiveState.d.ts +4 -0
- package/dist/composables/useActiveInactiveState.js +21 -0
- package/dist/composables/useBaseOptions.d.ts +3 -3
- package/dist/composables/useBaseOptions.js +31 -0
- package/dist/composables/useBbConfig.d.ts +8 -37
- package/dist/composables/useBbConfig.js +5 -0
- package/dist/composables/useBbDropdownContext.d.ts +89 -0
- package/dist/composables/useBbDropdownContext.js +46 -0
- package/dist/composables/useBbFormContext.d.ts +90 -0
- package/dist/composables/useBbFormContext.js +69 -0
- package/dist/composables/useBbTableContext.d.ts +195 -0
- package/dist/composables/useBbTableContext.js +208 -0
- package/dist/composables/useBbTabsContext.d.ts +111 -0
- package/dist/composables/useBbTabsContext.js +219 -0
- package/dist/composables/useBreakpoint.d.ts +13 -0
- package/dist/composables/useBreakpoint.js +39 -0
- package/dist/composables/useBroadcastChannelInstance.d.ts +1 -3
- package/dist/composables/useBroadcastChannelInstance.js +39 -0
- package/dist/composables/useCancelableFunction.js +37 -0
- package/dist/composables/useCoherence.js +16 -0
- package/dist/composables/useConfirm.d.ts +257 -67
- package/dist/composables/useConfirm.js +122 -0
- package/dist/composables/useCountdown.js +42 -0
- package/dist/composables/useHashedWatcher.d.ts +17 -0
- package/dist/composables/useHashedWatcher.js +14 -0
- package/dist/composables/useId.d.ts +3 -2
- package/dist/composables/useIndexById.js +16 -0
- package/dist/composables/useInertiaPage.d.ts +10 -0
- package/dist/composables/useInertiaPage.js +8 -0
- package/dist/composables/useItemText.js +17 -0
- package/dist/composables/useItemValue.js +9 -0
- package/dist/composables/useItemsGetter.d.ts +1 -1
- package/dist/composables/useItemsGetter.js +30 -0
- package/dist/composables/useListboxFocus.js +66 -0
- package/dist/composables/useLocale.d.ts +1 -1
- package/dist/composables/useLocale.js +11 -0
- package/dist/composables/useLogger.d.ts +1 -1
- package/dist/composables/useLogger.js +10 -0
- package/dist/composables/useMinimalQueue.d.ts +1 -1
- package/dist/composables/useMobile.js +7 -0
- package/dist/composables/useOnFalsy.d.ts +2 -0
- package/dist/composables/useOnFalsy.js +9 -0
- package/dist/composables/useOnTruthy.d.ts +7 -0
- package/dist/composables/useOnTruthy.js +9 -0
- package/dist/composables/usePrefill.d.ts +2 -1
- package/dist/composables/usePrefill.js +24 -0
- package/dist/composables/useQuery.d.ts +15 -3
- package/dist/composables/useQuery.js +42 -0
- package/dist/composables/useRoute.js +11 -0
- package/dist/composables/useRouter.js +8 -0
- package/dist/composables/useSafeArea.d.ts +51 -0
- package/dist/composables/useSafeArea.js +16 -0
- package/dist/composables/useSegmentedFields.d.ts +103 -0
- package/dist/composables/useSegmentedFields.js +152 -0
- package/dist/composables/useTableWidthContext.d.ts +5 -0
- package/dist/composables/useTableWidthContext.js +42 -0
- package/dist/composables/useToast.d.ts +17 -73
- package/dist/composables/useToast.js +49 -0
- package/dist/composables/useTopLayer.d.ts +9 -0
- package/dist/composables/useTopLayer.js +7 -0
- package/dist/composables/useUntil.js +13 -0
- package/dist/composables/useViewportWidth.d.ts +17 -0
- package/dist/composables/useViewportWidth.js +6 -0
- package/dist/confirm-variants.d.ts +10 -0
- package/dist/deprecation/ai-deprecations.json.d.ts +784 -0
- package/dist/deprecation/ai-deprecations.json.js +4 -0
- package/dist/deprecation/removedProps.d.ts +3 -0
- package/dist/deprecation/removedProps.js +13 -0
- package/dist/directives/bbColor.d.ts +65 -0
- package/dist/directives/bbColor.js +24 -0
- package/dist/directives/bbDate.d.ts +66 -0
- package/dist/directives/bbDate.js +24 -0
- package/dist/directives/bbDropdown.d.ts +15 -11
- package/dist/directives/bbDropdown.js +23 -0
- package/dist/directives/bbTime.d.ts +64 -0
- package/dist/directives/bbTime.js +24 -0
- package/dist/directives/bbTooltip.d.ts +16 -11
- package/dist/directives/bbTooltip.js +24 -0
- package/dist/dropdown-item-variants.d.ts +10 -0
- package/dist/i18n/index.d.ts +51 -3
- package/dist/i18n/index.js +27 -0
- package/dist/i18n/locales/cs.json +115 -0
- package/dist/i18n/locales/da.json +115 -0
- package/dist/i18n/locales/de.json +115 -0
- package/dist/i18n/locales/el.json +115 -0
- package/dist/i18n/locales/en.json +115 -0
- package/dist/i18n/locales/es.json +115 -0
- package/dist/i18n/locales/fi.json +115 -0
- package/dist/i18n/locales/fr.json +115 -0
- package/dist/i18n/locales/hu.json +115 -0
- package/dist/i18n/locales/it.json +115 -0
- package/dist/i18n/locales/ja.json +115 -0
- package/dist/i18n/locales/ko.json +115 -0
- package/dist/i18n/locales/nb.json +115 -0
- package/dist/i18n/locales/nl.json +115 -0
- package/dist/i18n/locales/pl.json +115 -0
- package/dist/i18n/locales/pt.json +115 -0
- package/dist/i18n/locales/ro.json +115 -0
- package/dist/i18n/locales/ru.json +115 -0
- package/dist/i18n/locales/sv.json +115 -0
- package/dist/i18n/locales/tr.json +115 -0
- package/dist/i18n/locales/uk.json +115 -0
- package/dist/i18n/locales/zh-cn.json +115 -0
- package/dist/icons-whitelist.d.ts +8 -0
- package/dist/index.d.ts +94 -79
- package/dist/index.js +76 -82
- package/dist/indicator-variants.d.ts +13 -0
- package/dist/llms-full.txt +77073 -0
- package/dist/llms-medium.txt +1334 -0
- package/dist/llms.txt +103 -0
- package/dist/locale-blueprint.json +141 -0
- package/dist/nuxt-module.d.ts +3 -0
- package/dist/nuxt.js +19 -0
- package/dist/plugin.d.ts +4 -0
- package/dist/plugin.js +22 -0
- package/dist/reset.css +1 -0
- package/dist/reset.d.ts +0 -0
- package/dist/runtime/nuxt-plugin.d.ts +2 -0
- package/dist/runtime/nuxt-plugin.js +24 -0
- package/dist/styles.css +2 -0
- package/dist/styles.d.ts +0 -0
- package/dist/toast-variants.d.ts +13 -0
- package/dist/tooltip-variants.d.ts +10 -0
- package/dist/types/ActionButton.d.ts +32 -0
- package/dist/types/AlertVariant.d.ts +16 -0
- package/dist/types/BadgeVariant.d.ts +16 -0
- package/dist/types/ButtonVariant.d.ts +17 -0
- package/dist/types/Classes.d.ts +1 -1
- package/dist/types/ColumnName.d.ts +1 -1
- package/dist/types/CommonProps.d.ts +66 -279
- package/dist/types/Config.d.ts +84 -0
- package/dist/types/ConfirmVariant.d.ts +15 -0
- package/dist/types/DropdownItemVariant.d.ts +18 -0
- package/dist/types/Icon.d.ts +5 -7
- package/dist/types/IndicatorVariant.d.ts +16 -0
- package/dist/types/InputDirection.d.ts +15 -0
- package/dist/types/ItemAccessor.d.ts +21 -0
- package/dist/types/Placement.d.ts +6 -0
- package/dist/types/ResponsiveSize.d.ts +20 -0
- package/dist/types/SizeScale.d.ts +8 -0
- package/dist/types/ToastVariant.d.ts +17 -0
- package/dist/types/TooltipVariant.d.ts +18 -0
- package/dist/utilities/functions/bytesToUnit.d.ts +2 -0
- package/dist/utilities/functions/bytesToUnit.js +18 -0
- package/dist/utilities/functions/clampPrecision.js +10 -0
- package/dist/utilities/functions/convertDateValue.d.ts +23 -10
- package/dist/utilities/functions/convertDateValue.js +12 -0
- package/dist/utilities/functions/deburr.js +5 -0
- package/dist/utilities/functions/empty.js +5 -0
- package/dist/utilities/functions/flattenTree.d.ts +1 -1
- package/dist/utilities/functions/hash.js +5 -0
- package/dist/utilities/functions/isDateDisabled.d.ts +1 -0
- package/dist/utilities/functions/isDateDisabled.js +20 -0
- package/dist/utilities/functions/isEqual.js +5 -0
- package/dist/utilities/functions/isNotEmpty.js +5 -0
- package/dist/utilities/functions/matchAnyKey.d.ts +1 -1
- package/dist/utilities/functions/matchAnyKey.js +15 -0
- package/dist/utilities/functions/parseSize.d.ts +1 -1
- package/dist/utilities/functions/parseSize.js +15 -0
- package/dist/utilities/functions/percentage.js +11 -0
- package/dist/utilities/functions/pipe.d.ts +1 -1
- package/dist/utilities/functions/reject.d.ts +25 -0
- package/dist/utilities/functions/reject.js +28 -0
- package/dist/utilities/functions/resolveEnumProp.d.ts +19 -0
- package/dist/utilities/functions/resolveEnumProp.js +5 -0
- package/dist/utilities/functions/slotKey.d.ts +13 -0
- package/dist/utilities/functions/slotKey.js +4 -0
- package/dist/utilities/functions/sort.d.ts +2 -2
- package/dist/utilities/functions/sort.js +19 -0
- package/dist/utilities/functions/throttle.js +5 -0
- package/dist/utilities/functions/waitFor.d.ts +9 -2
- package/dist/utilities/functions/waitFor.js +14 -0
- package/dist/utilities/functions/warnRemovedAttrs.d.ts +11 -0
- package/dist/utilities/functions/warnRemovedAttrs.js +20 -0
- package/dist/utilities/functions/when.js +5 -0
- package/dist/utilities/misc/iconsInjectionKey.d.ts +15 -0
- package/dist/utilities/misc/iconsInjectionKey.js +4 -0
- package/dist/utilities/misc/transitions.d.ts +5 -0
- package/dist/utilities/misc/transitions.js +8 -0
- package/dist/utils/injectLibraryStyles.d.ts +6 -0
- package/dist/utils/injectLibraryStyles.js +38 -0
- package/dist/validated/BbCheckbox.vue.d.ts +29 -0
- package/dist/validated/BbCheckbox.vue.js +5 -0
- package/dist/validated/BbCheckbox.vue_vue_type_script_setup_true_lang.js +75 -0
- package/dist/validated/BbCheckboxGroup.vue.d.ts +34 -0
- package/dist/validated/BbCheckboxGroup.vue.js +5 -0
- package/dist/validated/BbCheckboxGroup.vue_vue_type_script_setup_true_lang.js +76 -0
- package/dist/validated/BbColorInput.vue.d.ts +36 -0
- package/dist/validated/BbColorInput.vue.js +5 -0
- package/dist/validated/BbColorInput.vue_vue_type_script_setup_true_lang.js +71 -0
- package/dist/validated/BbDatePickerInput.vue.d.ts +40 -0
- package/dist/validated/BbDatePickerInput.vue.js +5 -0
- package/dist/validated/BbDatePickerInput.vue_vue_type_script_setup_true_lang.js +87 -0
- package/dist/validated/BbDropzone.vue.d.ts +24 -0
- package/dist/validated/BbDropzone.vue.js +5 -0
- package/dist/validated/BbDropzone.vue_vue_type_script_setup_true_lang.js +45 -0
- package/dist/validated/BbForm.vue.d.ts +28 -0
- package/dist/validated/BbForm.vue.js +5 -0
- package/dist/validated/BbForm.vue_vue_type_script_setup_true_lang.js +42 -0
- package/dist/validated/BbNumberInput.vue.d.ts +36 -0
- package/dist/validated/BbNumberInput.vue.js +5 -0
- package/dist/validated/BbNumberInput.vue_vue_type_script_setup_true_lang.js +72 -0
- package/dist/validated/BbRadioGroup.vue.d.ts +34 -0
- package/dist/validated/BbRadioGroup.vue.js +5 -0
- package/dist/validated/BbRadioGroup.vue_vue_type_script_setup_true_lang.js +75 -0
- package/dist/validated/BbRating.vue.d.ts +30 -0
- package/dist/validated/BbRating.vue.js +5 -0
- package/dist/validated/BbRating.vue_vue_type_script_setup_true_lang.js +63 -0
- package/dist/validated/BbSelect.vue.d.ts +46 -0
- package/dist/validated/BbSelect.vue.js +5 -0
- package/dist/validated/BbSelect.vue_vue_type_script_setup_true_lang.js +100 -0
- package/dist/validated/BbSlider.vue.d.ts +36 -0
- package/dist/validated/BbSlider.vue.js +5 -0
- package/dist/validated/BbSlider.vue_vue_type_script_setup_true_lang.js +69 -0
- package/dist/validated/BbSwitch.vue.d.ts +29 -0
- package/dist/validated/BbSwitch.vue.js +5 -0
- package/dist/validated/BbSwitch.vue_vue_type_script_setup_true_lang.js +75 -0
- package/dist/validated/BbSwitchGroup.vue.d.ts +34 -0
- package/dist/validated/BbSwitchGroup.vue.js +5 -0
- package/dist/validated/BbSwitchGroup.vue_vue_type_script_setup_true_lang.js +76 -0
- package/dist/validated/BbTag.vue.d.ts +36 -0
- package/dist/validated/BbTag.vue.js +5 -0
- package/dist/validated/BbTag.vue_vue_type_script_setup_true_lang.js +72 -0
- package/dist/validated/BbTextInput.vue.d.ts +36 -0
- package/dist/validated/BbTextInput.vue.js +5 -0
- package/dist/validated/BbTextInput.vue_vue_type_script_setup_true_lang.js +72 -0
- package/dist/validated/BbTextarea.vue.d.ts +36 -0
- package/dist/validated/BbTextarea.vue.js +5 -0
- package/dist/validated/BbTextarea.vue_vue_type_script_setup_true_lang.js +70 -0
- package/dist/validated/BbTimePickerInput.vue.d.ts +36 -0
- package/dist/validated/BbTimePickerInput.vue.js +5 -0
- package/dist/validated/BbTimePickerInput.vue_vue_type_script_setup_true_lang.js +78 -0
- package/dist/validated/index.d.ts +29 -0
- package/dist/validated/useValidatedField.d.ts +52 -0
- package/dist/validated/useValidatedField.js +51 -0
- package/dist/validated.js +21 -0
- package/dist/vite-plugin.d.ts +217 -0
- package/dist/vite.js +530 -0
- package/llms.txt +105 -0
- package/package.json +161 -59
- package/scripts/lib/__fixtures__/validated-manifest.json +65 -0
- package/scripts/lib/ensure-manifest.mjs +39 -0
- package/scripts/lib/eslint-plugin-autofix.node.test.mjs +109 -0
- package/scripts/lib/eslint-plugin.mjs +285 -0
- package/scripts/lib/eslint-plugin.node.test.mjs +161 -0
- package/scripts/lib/html-attributes.mjs +191 -0
- package/scripts/lib/mcp-config.mjs +126 -0
- package/scripts/lib/migrate-fix.mjs +115 -0
- package/scripts/lib/validate-bb-markup.mjs +421 -0
- package/dist/ai/BaseButton.md +0 -449
- package/dist/ai/BaseCheckbox.md +0 -512
- package/dist/ai/BaseCheckboxGroup.md +0 -597
- package/dist/ai/BaseColorInput.md +0 -461
- package/dist/ai/BaseDatePicker.md +0 -739
- package/dist/ai/BaseDatePickerInput.md +0 -1517
- package/dist/ai/BaseDialog.md +0 -610
- package/dist/ai/BaseInputContainer.md +0 -570
- package/dist/ai/BaseNumberInput.md +0 -509
- package/dist/ai/BaseRadio.md +0 -405
- package/dist/ai/BaseRadioGroup.md +0 -535
- package/dist/ai/BaseRating.md +0 -489
- package/dist/ai/BaseSelect.md +0 -1742
- package/dist/ai/BaseSlider.md +0 -871
- package/dist/ai/BaseSwitch.md +0 -322
- package/dist/ai/BaseSwitchGroup.md +0 -298
- package/dist/ai/BaseTag.md +0 -623
- package/dist/ai/BaseTextInput.md +0 -392
- package/dist/ai/BaseTextarea.md +0 -398
- package/dist/ai/BbChip.md +0 -147
- package/dist/ai/BbIntersection.md +0 -120
- package/dist/ai/BbRatio.md +0 -61
- package/dist/ai/BbRows.md +0 -307
- package/dist/ai/BbTab.md +0 -950
- package/dist/ai/CommonInputInnerContainer.md +0 -414
- package/dist/ai/CommonInputOuterContainer.md +0 -55
- package/dist/components/BaseButton/BaseButton.vue.d.ts +0 -14
- package/dist/components/BaseButton/types.d.ts +0 -159
- package/dist/components/BaseCheckbox/BaseCheckbox.vue.d.ts +0 -39
- package/dist/components/BaseCheckbox/types.d.ts +0 -213
- package/dist/components/BaseCheckboxGroup/BaseCheckboxGroup.vue.d.ts +0 -30
- package/dist/components/BaseCheckboxGroup/types.d.ts +0 -282
- package/dist/components/BaseColorInput/BaseColorInput.vue.d.ts +0 -35
- package/dist/components/BaseColorInput/ColorPalette.vue.d.ts +0 -13
- package/dist/components/BaseColorInput/types.d.ts +0 -233
- package/dist/components/BaseDatePicker/BaseDatePickerHeader.vue.d.ts +0 -15
- package/dist/components/BaseDatePicker/BaseDatePickerInputDaySelector.vue.d.ts +0 -58
- package/dist/components/BaseDatePicker/BaseDatePickerMonthSelector.vue.d.ts +0 -12
- package/dist/components/BaseDatePicker/BaseDatePickerYearSelector.vue.d.ts +0 -12
- package/dist/components/BaseDatePicker/types.d.ts +0 -100
- package/dist/components/BaseDatePickerInput/BaseDatePickerInput.vue.d.ts +0 -26
- package/dist/components/BaseDatePickerInput/types.d.ts +0 -206
- package/dist/components/BaseDialog/BaseDialog.vue.d.ts +0 -37
- package/dist/components/BaseDialog/types.d.ts +0 -180
- package/dist/components/BaseInputContainer/BaseInputContainer.vue.d.ts +0 -18
- package/dist/components/BaseInputContainer/types.d.ts +0 -126
- package/dist/components/BaseNumberInput/BaseNumberInput.vue.d.ts +0 -46
- package/dist/components/BaseNumberInput/types.d.ts +0 -191
- package/dist/components/BaseRadio/BaseRadio.vue.d.ts +0 -31
- package/dist/components/BaseRadio/types.d.ts +0 -173
- package/dist/components/BaseRadioGroup/BaseRadioGroup.vue.d.ts +0 -30
- package/dist/components/BaseRadioGroup/types.d.ts +0 -240
- package/dist/components/BaseRating/BaseRating.vue.d.ts +0 -35
- package/dist/components/BaseRating/types.d.ts +0 -144
- package/dist/components/BaseSelect/BaseSelect.vue.d.ts +0 -28
- package/dist/components/BaseSelect/types.d.ts +0 -470
- package/dist/components/BaseSlider/BaseSlider.vue.d.ts +0 -38
- package/dist/components/BaseSlider/types.d.ts +0 -201
- package/dist/components/BaseSwitch/BaseSwitch.vue.d.ts +0 -34
- package/dist/components/BaseSwitch/types.d.ts +0 -25
- package/dist/components/BaseSwitchGroup/BaseSwitchGroup.vue.d.ts +0 -30
- package/dist/components/BaseSwitchGroup/types.d.ts +0 -8
- package/dist/components/BaseTag/BaseTag.vue.d.ts +0 -37
- package/dist/components/BaseTag/types.d.ts +0 -136
- package/dist/components/BaseTextInput/BaseTextInput.vue.d.ts +0 -33
- package/dist/components/BaseTextInput/types.d.ts +0 -166
- package/dist/components/BaseTextarea/BaseTextarea.vue.d.ts +0 -31
- package/dist/components/BaseTextarea/types.d.ts +0 -151
- package/dist/components/BbChip/BbChip.vue.d.ts +0 -17
- package/dist/components/BbChip/types.d.ts +0 -23
- package/dist/components/BbIntersection/BbIntersection.vue.d.ts +0 -23
- package/dist/components/BbIntersection/types.d.ts +0 -36
- package/dist/components/BbRatio/BbRatio.vue.d.ts +0 -14
- package/dist/components/BbRatio/types.d.ts +0 -15
- package/dist/components/BbRows/BbRows.vue.d.ts +0 -62
- package/dist/components/BbRows/types.d.ts +0 -21
- package/dist/components/BbTab/BbTab.vue.d.ts +0 -27
- package/dist/components/BbTab/types.d.ts +0 -186
- package/dist/components/CommonInputInnerContainer/CommonInputInnerContainer.vue.d.ts +0 -15
- package/dist/components/CommonInputInnerContainer/types.d.ts +0 -47
- package/dist/components/CommonInputOuterContainer/CommonInputOuterContainer.vue.d.ts +0 -11
- package/dist/components/CommonInputOuterContainer/types.d.ts +0 -16
- package/dist/composables/useModalsState.d.ts +0 -5
- package/dist/composables/useQueue.d.ts +0 -58
- package/dist/composables/useWizard.d.ts +0 -85
- package/dist/i18n/en.d.ts +0 -67
- package/dist/i18n/it.d.ts +0 -67
- package/dist/index.css +0 -2
- package/dist/index100.js +0 -6
- package/dist/index101.js +0 -300
- package/dist/index102.js +0 -16
- package/dist/index103.js +0 -16
- package/dist/index104.js +0 -27
- package/dist/index109.js +0 -19
- package/dist/index11.js +0 -42
- package/dist/index110.js +0 -12
- package/dist/index111.js +0 -19
- package/dist/index112.js +0 -25
- package/dist/index114.js +0 -7
- package/dist/index115.js +0 -241
- package/dist/index116.js +0 -5
- package/dist/index117.js +0 -42
- package/dist/index118.js +0 -5
- package/dist/index119.js +0 -53
- package/dist/index120.js +0 -5
- package/dist/index121.js +0 -32
- package/dist/index122.js +0 -5
- package/dist/index124.js +0 -52
- package/dist/index125.js +0 -5
- package/dist/index126.js +0 -223
- package/dist/index128.js +0 -6
- package/dist/index129.js +0 -162
- package/dist/index13.js +0 -92
- package/dist/index130.js +0 -25
- package/dist/index131.js +0 -51
- package/dist/index132.js +0 -5
- package/dist/index133.js +0 -607
- package/dist/index135.js +0 -6
- package/dist/index136.js +0 -14
- package/dist/index137.js +0 -153
- package/dist/index139.js +0 -6
- package/dist/index14.js +0 -306
- package/dist/index140.js +0 -224
- package/dist/index141.js +0 -5
- package/dist/index143.js +0 -128
- package/dist/index145.js +0 -6
- package/dist/index146.js +0 -8
- package/dist/index147.js +0 -182
- package/dist/index149.js +0 -6
- package/dist/index15.js +0 -10
- package/dist/index151.js +0 -4
- package/dist/index152.js +0 -95
- package/dist/index154.js +0 -6
- package/dist/index155.js +0 -168
- package/dist/index157.js +0 -6
- package/dist/index158.js +0 -145
- package/dist/index16.js +0 -59
- package/dist/index160.js +0 -6
- package/dist/index161.js +0 -53
- package/dist/index163.js +0 -6
- package/dist/index164.js +0 -16
- package/dist/index166.js +0 -35
- package/dist/index168.js +0 -6
- package/dist/index169.js +0 -89
- package/dist/index171.js +0 -6
- package/dist/index172.js +0 -82
- package/dist/index174.js +0 -6
- package/dist/index175.js +0 -38
- package/dist/index176.js +0 -461
- package/dist/index177.js +0 -28
- package/dist/index178.js +0 -66
- package/dist/index18.js +0 -35
- package/dist/index180.js +0 -162
- package/dist/index181.js +0 -5
- package/dist/index182.js +0 -217
- package/dist/index183.js +0 -5
- package/dist/index184.js +0 -112
- package/dist/index185.js +0 -5
- package/dist/index186.js +0 -459
- package/dist/index188.js +0 -6
- package/dist/index19.js +0 -4
- package/dist/index192.js +0 -268
- package/dist/index194.js +0 -6
- package/dist/index195.js +0 -124
- package/dist/index197.js +0 -6
- package/dist/index198.js +0 -174
- package/dist/index2.js +0 -20
- package/dist/index20.js +0 -9
- package/dist/index200.js +0 -6
- package/dist/index201.js +0 -224
- package/dist/index203.js +0 -6
- package/dist/index204.js +0 -135
- package/dist/index206.js +0 -6
- package/dist/index207.js +0 -5
- package/dist/index208.js +0 -170
- package/dist/index21.js +0 -35
- package/dist/index210.js +0 -6
- package/dist/index211.js +0 -37
- package/dist/index213.js +0 -6
- package/dist/index214.js +0 -63
- package/dist/index216.js +0 -6
- package/dist/index217.js +0 -74
- package/dist/index219.js +0 -6
- package/dist/index22.js +0 -6
- package/dist/index220.js +0 -65
- package/dist/index222.js +0 -6
- package/dist/index223.js +0 -67
- package/dist/index225.js +0 -6
- package/dist/index226.js +0 -41
- package/dist/index228.js +0 -6
- package/dist/index229.js +0 -10
- package/dist/index23.js +0 -7
- package/dist/index230.js +0 -22
- package/dist/index232.js +0 -8
- package/dist/index233.js +0 -297
- package/dist/index235.js +0 -6
- package/dist/index236.js +0 -47
- package/dist/index237.js +0 -165
- package/dist/index239.js +0 -6
- package/dist/index24.js +0 -9
- package/dist/index241.js +0 -159
- package/dist/index243.js +0 -6
- package/dist/index244.js +0 -134
- package/dist/index246.js +0 -6
- package/dist/index247.js +0 -167
- package/dist/index249.js +0 -6
- package/dist/index25.js +0 -24
- package/dist/index250.js +0 -147
- package/dist/index252.js +0 -6
- package/dist/index253.js +0 -35
- package/dist/index255.js +0 -6
- package/dist/index256.js +0 -65
- package/dist/index258.js +0 -6
- package/dist/index259.js +0 -19
- package/dist/index260.js +0 -5
- package/dist/index261.js +0 -160
- package/dist/index263.js +0 -6
- package/dist/index264.js +0 -60
- package/dist/index266.js +0 -6
- package/dist/index267.js +0 -134
- package/dist/index269.js +0 -6
- package/dist/index27.js +0 -4
- package/dist/index271.js +0 -206
- package/dist/index273.js +0 -6
- package/dist/index274.js +0 -85
- package/dist/index275.js +0 -5
- package/dist/index276.js +0 -55
- package/dist/index277.js +0 -5
- package/dist/index278.js +0 -164
- package/dist/index28.js +0 -8
- package/dist/index280.js +0 -6
- package/dist/index281.js +0 -145
- package/dist/index283.js +0 -6
- package/dist/index284.js +0 -11
- package/dist/index285.js +0 -200
- package/dist/index287.js +0 -6
- package/dist/index288.js +0 -241
- package/dist/index29.js +0 -7
- package/dist/index290.js +0 -6
- package/dist/index291.js +0 -21
- package/dist/index293.js +0 -6
- package/dist/index294.js +0 -125
- package/dist/index296.js +0 -6
- package/dist/index297.js +0 -161
- package/dist/index299.js +0 -6
- package/dist/index30.js +0 -118
- package/dist/index300.js +0 -127
- package/dist/index302.js +0 -6
- package/dist/index303.js +0 -20
- package/dist/index305.js +0 -6
- package/dist/index306.js +0 -116
- package/dist/index307.js +0 -5
- package/dist/index308.js +0 -507
- package/dist/index31.js +0 -10
- package/dist/index310.js +0 -6
- package/dist/index311.js +0 -196
- package/dist/index313.js +0 -6
- package/dist/index314.js +0 -142
- package/dist/index316.js +0 -6
- package/dist/index317.js +0 -134
- package/dist/index319.js +0 -6
- package/dist/index32.js +0 -28
- package/dist/index320.js +0 -162
- package/dist/index322.js +0 -6
- package/dist/index323.js +0 -319
- package/dist/index325.js +0 -6
- package/dist/index326.js +0 -40
- package/dist/index327.js +0 -43
- package/dist/index328.js +0 -665
- package/dist/index33.js +0 -5
- package/dist/index330.js +0 -6
- package/dist/index331.js +0 -155
- package/dist/index333.js +0 -6
- package/dist/index334.js +0 -142
- package/dist/index336.js +0 -6
- package/dist/index337.js +0 -155
- package/dist/index339.js +0 -6
- package/dist/index34.js +0 -112
- package/dist/index340.js +0 -58
- package/dist/index341.js +0 -5
- package/dist/index342.js +0 -20
- package/dist/index344.js +0 -6
- package/dist/index345.js +0 -142
- package/dist/index347.js +0 -6
- package/dist/index349.js +0 -109
- package/dist/index351.js +0 -6
- package/dist/index353.js +0 -24
- package/dist/index354.js +0 -23
- package/dist/index355.js +0 -839
- package/dist/index356.js +0 -474
- package/dist/index357.js +0 -52
- package/dist/index358.js +0 -7
- package/dist/index36.js +0 -6
- package/dist/index38.js +0 -63
- package/dist/index39.js +0 -63
- package/dist/index40.js +0 -9
- package/dist/index42.js +0 -8
- package/dist/index43.js +0 -179
- package/dist/index44.js +0 -21
- package/dist/index46.js +0 -385
- package/dist/index48.js +0 -6
- package/dist/index49.js +0 -33
- package/dist/index5.js +0 -34
- package/dist/index50.js +0 -12
- package/dist/index51.js +0 -8
- package/dist/index52.js +0 -106
- package/dist/index53.js +0 -330
- package/dist/index54.js +0 -97
- package/dist/index55.js +0 -328
- package/dist/index56.js +0 -28
- package/dist/index57.js +0 -102
- package/dist/index58.js +0 -157
- package/dist/index6.js +0 -38
- package/dist/index60.js +0 -6
- package/dist/index61.js +0 -131
- package/dist/index62.js +0 -5
- package/dist/index65.js +0 -35
- package/dist/index66.js +0 -26
- package/dist/index68.js +0 -6
- package/dist/index69.js +0 -54
- package/dist/index7.js +0 -58
- package/dist/index71.js +0 -6
- package/dist/index72.js +0 -14
- package/dist/index74.js +0 -6
- package/dist/index75.js +0 -159
- package/dist/index77.js +0 -6
- package/dist/index78.js +0 -4
- package/dist/index79.js +0 -4
- package/dist/index80.js +0 -54
- package/dist/index81.js +0 -5
- package/dist/index82.js +0 -5
- package/dist/index83.js +0 -141
- package/dist/index85.js +0 -6
- package/dist/index86.js +0 -65
- package/dist/index88.js +0 -6
- package/dist/index89.js +0 -30
- package/dist/index9.js +0 -11
- package/dist/index90.js +0 -19
- package/dist/index91.js +0 -17
- package/dist/index92.js +0 -9
- package/dist/index93.js +0 -34
- package/dist/index95.js +0 -16
- package/dist/index96.js +0 -10
- package/dist/index97.js +0 -18
- package/dist/index98.js +0 -189
- package/dist/types/VoidHtmlElements.d.ts +0 -1
- package/dist/utilities/functions/add.d.ts +0 -1
- package/dist/utilities/functions/booleanishToBoolean.d.ts +0 -6
- package/dist/utilities/functions/capitalize.d.ts +0 -4
- package/dist/utilities/functions/cloneDeep.d.ts +0 -1
- package/dist/utilities/functions/debounce.d.ts +0 -1
- package/dist/utilities/functions/drop.d.ts +0 -1
- package/dist/utilities/functions/exceedsPrecision.d.ts +0 -1
- package/dist/utilities/functions/findRight.d.ts +0 -4
- package/dist/utilities/functions/findRightIndex.d.ts +0 -4
- package/dist/utilities/functions/flow.d.ts +0 -1
- package/dist/utilities/functions/getHueFromRGB.d.ts +0 -9
- package/dist/utilities/functions/groupBy.d.ts +0 -6
- package/dist/utilities/functions/gt.d.ts +0 -7
- package/dist/utilities/functions/hexToRGB.d.ts +0 -7
- package/dist/utilities/functions/hslToHex.d.ts +0 -1
- package/dist/utilities/functions/includes.d.ts +0 -1
- package/dist/utilities/functions/initial.d.ts +0 -1
- package/dist/utilities/functions/isCssColor.d.ts +0 -5
- package/dist/utilities/functions/lt.d.ts +0 -7
- package/dist/utilities/functions/makeUrl.d.ts +0 -1
- package/dist/utilities/functions/mapKeys.d.ts +0 -5
- package/dist/utilities/functions/mapValues.d.ts +0 -1
- package/dist/utilities/functions/matchesPropertyInsensitive.d.ts +0 -1
- package/dist/utilities/functions/max.d.ts +0 -2
- package/dist/utilities/functions/mean.d.ts +0 -4
- package/dist/utilities/functions/merge.d.ts +0 -11
- package/dist/utilities/functions/millisecondsTo.d.ts +0 -1
- package/dist/utilities/functions/negate.d.ts +0 -4
- package/dist/utilities/functions/normalizeItemGroups.d.ts +0 -13
- package/dist/utilities/functions/omit.d.ts +0 -2
- package/dist/utilities/functions/overEvery.d.ts +0 -4
- package/dist/utilities/functions/pick.d.ts +0 -1
- package/dist/utilities/functions/replace.d.ts +0 -1
- package/dist/utilities/functions/replaceInTree.d.ts +0 -4
- package/dist/utilities/functions/retry.d.ts +0 -5
- package/dist/utilities/functions/roundToTheNearest.d.ts +0 -8
- package/dist/utilities/functions/set.d.ts +0 -15
- package/dist/utilities/functions/stub.d.ts +0 -6
- package/dist/utilities/functions/transposePercent.d.ts +0 -9
- package/dist/utilities/functions/tryTo.d.ts +0 -2
- package/dist/utilities/functions/uniqBy.d.ts +0 -1
- /package/dist/{index64.js → _virtual/_plugin-vue_export-helper.js} +0 -0
- /package/dist/components/{BaseButton → BbBaseButton}/RouterComponent.vue.d.ts +0 -0
- /package/dist/components/{BaseDatePicker/BaseDatePicker.vue.d.ts → BbBaseDatePicker/BbBaseDatePicker.vue.d.ts} +0 -0
- /package/dist/{index165.js → composables/useArray.js} +0 -0
- /package/dist/{index17.js → composables/useFrameworkDetection.js} +0 -0
- /package/dist/{index12.js → composables/useId.js} +0 -0
- /package/dist/{index352.js → directives/createPopoverDirective.js} +0 -0
- /package/dist/{index107.js → utilities/functions/chunk.js} +0 -0
- /package/dist/{index8.js → utilities/functions/clamp.js} +0 -0
- /package/dist/{index150.js → utilities/functions/curry.js} +0 -0
- /package/dist/{index45.js → utilities/functions/extractDomContainer.js} +0 -0
- /package/dist/{index270.js → utilities/functions/findInTree.js} +0 -0
- /package/dist/{index348.js → utilities/functions/flattenTree.js} +0 -0
- /package/dist/{index41.js → utilities/functions/get.js} +0 -0
- /package/dist/{index189.js → utilities/functions/head.js} +0 -0
- /package/dist/{index108.js → utilities/functions/identity.js} +0 -0
- /package/dist/{index179.js → utilities/functions/indexBy.js} +0 -0
- /package/dist/{index37.js → utilities/functions/isHex.js} +0 -0
- /package/dist/{index94.js → utilities/functions/isNil.js} +0 -0
- /package/dist/{index26.js → utilities/functions/isNotNil.js} +0 -0
- /package/dist/{index105.js → utilities/functions/last.js} +0 -0
- /package/dist/{index142.js → utilities/functions/noop.js} +0 -0
- /package/dist/{index231.js → utilities/functions/parseWidthString.js} +0 -0
- /package/dist/{index240.js → utilities/functions/pickBy.js} +0 -0
- /package/dist/{index123.js → utilities/functions/range.js} +0 -0
- /package/dist/{index190.js → utilities/functions/snapToStep.js} +0 -0
- /package/dist/{index191.js → utilities/functions/transpose.js} +0 -0
- /package/dist/{index106.js → utilities/functions/validateDateFormat.js} +0 -0
- /package/dist/{index10.js → utilities/functions/wait.js} +0 -0
|
@@ -0,0 +1,1698 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: Workspace Onboarding (Nuxt)
|
|
3
|
+
summary: Full-anatomy workspace onboarding for Nuxt — a live BbProgress header, an accordion checklist whose steps do the real work inline (integration switches, tag-input invites, a mini project form, CSV import with real byte progress), data loaded with useAsyncData and mutations resolved through $fetch + refresh(), all through one coopting page context.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Recipe: Workspace Onboarding (Nuxt)
|
|
7
|
+
|
|
8
|
+
The onboarding checklist adapted for **Nuxt**: the same live progress header,
|
|
9
|
+
single-open accordion whose steps carry the real actions inline, and "see
|
|
10
|
+
what you'll get" preview peeks — but the checklist state loads through
|
|
11
|
+
`useAsyncData` and every mutation is a `$fetch` call followed by `refresh()`,
|
|
12
|
+
so the server stays the single source of truth for step statuses. Anatomy,
|
|
13
|
+
components, the context shape, copy and data are identical to the Vue
|
|
14
|
+
recipe; only the data/mutation layer changes.
|
|
15
|
+
|
|
16
|
+
Sibling recipes: [Vue](../vue/onboarding.md) ·
|
|
17
|
+
[Inertia](../inertia/onboarding.md).
|
|
18
|
+
|
|
19
|
+
## Prerequisites
|
|
20
|
+
|
|
21
|
+
- `<BbConfirm />` and `<BbToast />` mounted once in `app.vue`.
|
|
22
|
+
- [App Layout](../../guides/app-layout.md) and
|
|
23
|
+
[Page Shell](../../guides/page-shell.md) copied into `src/components/layout/`
|
|
24
|
+
per their guides — this page assumes the chrome exists and renders inside
|
|
25
|
+
it.
|
|
26
|
+
- Server routes: `GET /api/onboarding` (returns `{ steps, connectedIntegrations,
|
|
27
|
+
workspace, invites, firstProject, importedCustomers, reminders }`), plus the
|
|
28
|
+
mutation routes referenced below (`PATCH /api/onboarding/steps/:id`,
|
|
29
|
+
`POST /api/onboarding/integrations/:id/connect`,
|
|
30
|
+
`POST /api/onboarding/invites`, `POST /api/onboarding/project`,
|
|
31
|
+
`POST /api/onboarding/customers/import`, `PATCH /api/onboarding/reminders`,
|
|
32
|
+
`POST /api/onboarding/dismiss`).
|
|
33
|
+
|
|
34
|
+
## Key ideas
|
|
35
|
+
|
|
36
|
+
- **One coopting page context.** `provideOnboardingWorkspace()` joins the
|
|
37
|
+
page-shell stack once, owns the step statuses, the integration and invite
|
|
38
|
+
state, and every action. Every leaf calls `useOnboardingWorkspace()` and
|
|
39
|
+
nothing else — zero prop drilling anywhere on the page.
|
|
40
|
+
- **`useAsyncData` loads the checklist once; every mutation ends in
|
|
41
|
+
`refresh()`.** There is exactly one status writer path: `$fetch` the
|
|
42
|
+
mutation, then `refresh()` re-pulls `/api/onboarding` and a single watcher
|
|
43
|
+
re-seeds every local field (`steps`, `integrations`, `invites`,
|
|
44
|
+
`firstProject`, `reminders`) from the fresh response — no mutation patches
|
|
45
|
+
local state by hand except the optimistic switches.
|
|
46
|
+
- **Steps act inline; the checklist ticks itself.** Each step body _is_ the
|
|
47
|
+
feature: switches connect integrations, a tag input sends invites, a mini
|
|
48
|
+
form creates the project, a dropzone imports the CSV. Completing the real
|
|
49
|
+
action persists the step status through one private `persistStatus` —
|
|
50
|
+
the same verb the manual "Mark as done" / "Skip for now" ghosts use.
|
|
51
|
+
- **Single-open accordion, modeled — not wrapped.** `BbAccordion` is one
|
|
52
|
+
panel per boolean; there is no group component by design. One
|
|
53
|
+
`activeStep` key in the context derives every panel's `model-value`, and
|
|
54
|
+
finishing a step advances the key to the next unfinished one.
|
|
55
|
+
- **CSV upload progress needs raw `XMLHttpRequest`.** `ofetch` (Nuxt's
|
|
56
|
+
`$fetch`) has no upload-progress hook, so the one import mutation wraps
|
|
57
|
+
`XMLHttpRequest` directly to drive real bytes into `BbProgress`; every
|
|
58
|
+
other mutation on the page uses `$fetch`.
|
|
59
|
+
- **Previews ride the shell stack.** "See what you'll get" pushes a
|
|
60
|
+
`step-preview` peek (replace semantics — previews never stack); the peek
|
|
61
|
+
is a workbench: identity header, benefit list, a stat, and a "Set it up
|
|
62
|
+
now" action that jumps back to the step.
|
|
63
|
+
- **Checklist archetype, so rows 4/5/7/8 of the standard anatomy don't
|
|
64
|
+
apply**: no filter rail, no tabs, no pagination, no selection/bulk bar —
|
|
65
|
+
and no page search, since the page has no filterable collection. Page
|
|
66
|
+
Shell, breadcrumbs topbar and the stacked peek sidebar stay.
|
|
67
|
+
- **Buttons are `md` by default**; one `variant="primary"` on the page
|
|
68
|
+
("Go to dashboard" in the topbar); step submits are `secondary`,
|
|
69
|
+
done/skip/preview are `ghost`; "Dismiss onboarding" rides `useConfirm`.
|
|
70
|
+
|
|
71
|
+
## Page anatomy
|
|
72
|
+
|
|
73
|
+
```
|
|
74
|
+
OnboardingChecklist/
|
|
75
|
+
Index.vue ← assembly: PageShell slots, accordion loop, thin
|
|
76
|
+
context.ts ← coopting page context (shell + useAsyncData + actions)
|
|
77
|
+
ProgressHeader.vue ← title, dismiss, BbProgress + "4 of 7 complete"
|
|
78
|
+
StepHeader.vue ← status icon, title, minutes, chevron (in the header button)
|
|
79
|
+
StepActions.vue ← per-step done / skip / preview footer row
|
|
80
|
+
ProfileStep.vue ← step 1 body: completed-at-signup summary + edit link
|
|
81
|
+
IntegrationsStep.vue ← step 2 body: BbSwitch rows (Stripe, QuickBooks, Slack, Drive)
|
|
82
|
+
InviteStep.vue ← step 3 body: BbTag emails + role BbSelect + send
|
|
83
|
+
FirstProjectStep.vue ← step 4 body: mini create-project form
|
|
84
|
+
ImportCustomersStep.vue ← step 5 body: BbDropzone CSV + BbProgress upload
|
|
85
|
+
FirstInvoiceStep.vue ← step 6 body: link-out to the invoice composer
|
|
86
|
+
RemindersStep.vue ← step 7 body: reminders switch + cadence select
|
|
87
|
+
StepPreviewPeek.vue ← sidebar "what you'll get" workbench per step
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
Chrome assumed from the guides: [App Layout](../../guides/app-layout.md)
|
|
91
|
+
(left nav + fat footer) and [Page Shell](../../guides/page-shell.md). The
|
|
92
|
+
dismiss confirmation renders through the app-wide `useConfirm` host, so this
|
|
93
|
+
page needs no `#dialogs` content of its own.
|
|
94
|
+
|
|
95
|
+
## Action inventory
|
|
96
|
+
|
|
97
|
+
| # | Action | Trigger | Mechanism |
|
|
98
|
+
| --- | -------------------------------- | ----------------------------------- | ------------------------------------------------------------------ |
|
|
99
|
+
| 1 | Go to dashboard | topbar, the page's one `primary` | navigation (`/dashboard`) |
|
|
100
|
+
| 2 | Dismiss onboarding | progress header, ghost | `useConfirm` (destructive) → `$fetch` + `navigateTo` + toast |
|
|
101
|
+
| 3 | Expand / collapse a step | accordion header (single-open) | `activeStep` key derives each panel's `model-value` |
|
|
102
|
+
| 4 | See what you'll get | every step footer | `previewStep(id)` → shell peek (replace) |
|
|
103
|
+
| 5 | Mark step done / skip step | step footer ghosts | `completeStep` / `skipStep` → `$fetch` + `refresh()` |
|
|
104
|
+
| 6 | Connect / disconnect integration | switch rows in _Connect your tools_ | optimistic toggle, `readonly` in flight, revert + toast on failure |
|
|
105
|
+
| 7 | Compose the invite list | `BbTag` (Enter/comma, max 10) | local ref; `duplicate`/`max` surfaced via `errors` |
|
|
106
|
+
| 8 | Choose the invite role | `BbSelect` beside the tags | local ref |
|
|
107
|
+
| 9 | Send invitations | secondary button in step body | `sendInvites` → `$fetch` + auto-complete + toast |
|
|
108
|
+
| 10 | Create the first project | mini form submit | `createProject` → `$fetch` + auto-complete + toast |
|
|
109
|
+
| 11 | Import customers CSV | `BbDropzone` + Import button | `importCustomers`; `BbProgress` driven by real XHR upload bytes |
|
|
110
|
+
| 12 | Open the invoice composer | outline button in step 6 | navigation (`/invoices/create`) |
|
|
111
|
+
| 13 | Turn reminders on / pick cadence | switch + select in step 7 | `setReminders` / `setReminderCadence` + toast |
|
|
112
|
+
| 14 | Jump to a step from its preview | peek footer | `jumpToStep(id)` → open step + close peek |
|
|
113
|
+
| 15 | Edit the workspace profile | link in the completed profile step | navigation (`/settings/general`) |
|
|
114
|
+
| 16 | Close the peek | shell chrome | shell stack close |
|
|
115
|
+
|
|
116
|
+
## The code
|
|
117
|
+
|
|
118
|
+
### context.ts
|
|
119
|
+
|
|
120
|
+
```ts
|
|
121
|
+
// OnboardingChecklist/context.ts
|
|
122
|
+
import {
|
|
123
|
+
computed,
|
|
124
|
+
inject,
|
|
125
|
+
provide,
|
|
126
|
+
reactive,
|
|
127
|
+
ref,
|
|
128
|
+
watch,
|
|
129
|
+
type ComputedRef,
|
|
130
|
+
type InjectionKey,
|
|
131
|
+
type Ref,
|
|
132
|
+
} from 'vue';
|
|
133
|
+
import { useConfirm, useToast } from 'bitboss-ui';
|
|
134
|
+
import {
|
|
135
|
+
usePageShellContext,
|
|
136
|
+
type PageShellContext,
|
|
137
|
+
} from '@/components/layout/usePageShellContext';
|
|
138
|
+
import type {
|
|
139
|
+
InviteRole,
|
|
140
|
+
PendingInvite,
|
|
141
|
+
Project,
|
|
142
|
+
ProjectDraft,
|
|
143
|
+
ReminderCadence,
|
|
144
|
+
WorkspaceProfile,
|
|
145
|
+
} from '@/types';
|
|
146
|
+
|
|
147
|
+
export type StepId =
|
|
148
|
+
| 'profile'
|
|
149
|
+
| 'integrations'
|
|
150
|
+
| 'invites'
|
|
151
|
+
| 'first-project'
|
|
152
|
+
| 'import-customers'
|
|
153
|
+
| 'first-invoice'
|
|
154
|
+
| 'reminders';
|
|
155
|
+
|
|
156
|
+
export type StepStatus = 'todo' | 'complete' | 'skipped';
|
|
157
|
+
|
|
158
|
+
export interface OnboardingStep {
|
|
159
|
+
id: StepId;
|
|
160
|
+
title: string;
|
|
161
|
+
description: string;
|
|
162
|
+
/** Rough time estimate shown in the header while the step is open. */
|
|
163
|
+
minutes: number;
|
|
164
|
+
status: StepStatus;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
export interface WorkspaceIntegration {
|
|
168
|
+
id: string;
|
|
169
|
+
name: string;
|
|
170
|
+
description: string;
|
|
171
|
+
/** Full static literal — the production icon scanner only bundles names it can see. */
|
|
172
|
+
icon: string;
|
|
173
|
+
connected: boolean;
|
|
174
|
+
/** True while a connect/disconnect request is in flight (drives `readonly`). */
|
|
175
|
+
busy: boolean;
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
/** What the stacked sidebar can show: the per-step "what you'll get" preview. */
|
|
179
|
+
export type PeekItem = { type: 'step-preview'; stepId: StepId };
|
|
180
|
+
|
|
181
|
+
/** The whole `/api/onboarding` response — the single source of truth. */
|
|
182
|
+
type OnboardingState = {
|
|
183
|
+
steps: Record<StepId, StepStatus>;
|
|
184
|
+
connectedIntegrations: string[];
|
|
185
|
+
workspace: WorkspaceProfile;
|
|
186
|
+
invites: PendingInvite[];
|
|
187
|
+
firstProject: Project | null;
|
|
188
|
+
importedCustomers: number | null;
|
|
189
|
+
reminders: { enabled: boolean; cadence: ReminderCadence };
|
|
190
|
+
};
|
|
191
|
+
|
|
192
|
+
export interface OnboardingWorkspaceContext {
|
|
193
|
+
// -- Coopted contexts ------------------------------------------------------
|
|
194
|
+
shell: PageShellContext<PeekItem>;
|
|
195
|
+
// -- Page-owned state ------------------------------------------------------
|
|
196
|
+
steps: OnboardingStep[];
|
|
197
|
+
/** The one open panel; `null` collapses everything (single-open accordion). */
|
|
198
|
+
activeStep: Ref<StepId | null>;
|
|
199
|
+
/** Steps no longer todo (complete or skipped) — drives the progress bar. */
|
|
200
|
+
doneCount: ComputedRef<number>;
|
|
201
|
+
allDone: ComputedRef<boolean>;
|
|
202
|
+
workspace: Ref<WorkspaceProfile | null>;
|
|
203
|
+
integrations: WorkspaceIntegration[];
|
|
204
|
+
invites: Ref<PendingInvite[]>;
|
|
205
|
+
firstProject: Ref<Project | null>;
|
|
206
|
+
importState: {
|
|
207
|
+
uploading: boolean;
|
|
208
|
+
sentBytes: number;
|
|
209
|
+
totalBytes: number;
|
|
210
|
+
importedCount: number | null;
|
|
211
|
+
};
|
|
212
|
+
reminders: { enabled: boolean; cadence: ReminderCadence };
|
|
213
|
+
// -- Step grammar ----------------------------------------------------------
|
|
214
|
+
openStep: (id: StepId | null) => void;
|
|
215
|
+
previewStep: (id: StepId) => void;
|
|
216
|
+
jumpToStep: (id: StepId) => void;
|
|
217
|
+
// -- Actions (complete: $fetch + refresh + toast) ----------------------------
|
|
218
|
+
completeStep: (id: StepId) => Promise<void>;
|
|
219
|
+
skipStep: (id: StepId) => Promise<void>;
|
|
220
|
+
toggleIntegration: (
|
|
221
|
+
integration: WorkspaceIntegration,
|
|
222
|
+
next: boolean
|
|
223
|
+
) => Promise<void>;
|
|
224
|
+
sendInvites: (emails: string[], role: InviteRole) => Promise<void>;
|
|
225
|
+
createProject: (draft: ProjectDraft) => Promise<void>;
|
|
226
|
+
importCustomers: (file: File) => Promise<void>;
|
|
227
|
+
setReminders: (enabled: boolean) => Promise<void>;
|
|
228
|
+
setReminderCadence: (cadence: ReminderCadence) => Promise<void>;
|
|
229
|
+
dismissOnboarding: () => Promise<void>;
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
const key: InjectionKey<OnboardingWorkspaceContext> = Symbol(
|
|
233
|
+
'onboarding-workspace'
|
|
234
|
+
);
|
|
235
|
+
|
|
236
|
+
// ofetch has no upload-progress hook, so the one import mutation drives real
|
|
237
|
+
// bytes through a plain XMLHttpRequest instead — every other mutation below
|
|
238
|
+
// uses $fetch.
|
|
239
|
+
const uploadWithProgress = (
|
|
240
|
+
url: string,
|
|
241
|
+
body: FormData,
|
|
242
|
+
onProgress: (sentBytes: number, totalBytes: number) => void
|
|
243
|
+
): Promise<{ imported: number }> =>
|
|
244
|
+
new Promise((resolve, reject) => {
|
|
245
|
+
const xhr = new XMLHttpRequest();
|
|
246
|
+
xhr.open('POST', url);
|
|
247
|
+
xhr.upload.addEventListener('progress', (event) => {
|
|
248
|
+
if (event.lengthComputable) onProgress(event.loaded, event.total);
|
|
249
|
+
});
|
|
250
|
+
xhr.addEventListener('load', () => {
|
|
251
|
+
if (xhr.status >= 200 && xhr.status < 300) {
|
|
252
|
+
resolve(JSON.parse(xhr.responseText));
|
|
253
|
+
} else {
|
|
254
|
+
reject(new Error(`Import failed (${xhr.status}).`));
|
|
255
|
+
}
|
|
256
|
+
});
|
|
257
|
+
xhr.addEventListener('error', () => reject(new Error('Import failed.')));
|
|
258
|
+
xhr.send(body);
|
|
259
|
+
});
|
|
260
|
+
|
|
261
|
+
export function provideOnboardingWorkspace(): OnboardingWorkspaceContext {
|
|
262
|
+
const { toast } = useToast();
|
|
263
|
+
const { confirm } = useConfirm();
|
|
264
|
+
|
|
265
|
+
// -- Coopt the specific contexts: once, here, for the whole page. ----------
|
|
266
|
+
const shell = usePageShellContext<PeekItem>();
|
|
267
|
+
|
|
268
|
+
// -- The checklist definition lives client-side; the server owns statuses. -
|
|
269
|
+
const steps = reactive<OnboardingStep[]>([
|
|
270
|
+
{
|
|
271
|
+
id: 'profile',
|
|
272
|
+
title: 'Set up your company profile',
|
|
273
|
+
description: 'Legal name, billing address and tax details.',
|
|
274
|
+
minutes: 2,
|
|
275
|
+
status: 'todo',
|
|
276
|
+
},
|
|
277
|
+
{
|
|
278
|
+
id: 'integrations',
|
|
279
|
+
title: 'Connect your tools',
|
|
280
|
+
description:
|
|
281
|
+
'Stripe for payments, QuickBooks for the books, Slack for alerts.',
|
|
282
|
+
minutes: 3,
|
|
283
|
+
status: 'todo',
|
|
284
|
+
},
|
|
285
|
+
{
|
|
286
|
+
id: 'invites',
|
|
287
|
+
title: 'Invite your teammates',
|
|
288
|
+
description:
|
|
289
|
+
'Billing works better when the whole team sees the same numbers.',
|
|
290
|
+
minutes: 2,
|
|
291
|
+
status: 'todo',
|
|
292
|
+
},
|
|
293
|
+
{
|
|
294
|
+
id: 'first-project',
|
|
295
|
+
title: 'Create your first project',
|
|
296
|
+
description:
|
|
297
|
+
'Projects group invoices, budgets and time entries per client.',
|
|
298
|
+
minutes: 1,
|
|
299
|
+
status: 'todo',
|
|
300
|
+
},
|
|
301
|
+
{
|
|
302
|
+
id: 'import-customers',
|
|
303
|
+
title: 'Import your customers',
|
|
304
|
+
description: 'Bring your existing customer list over as a CSV.',
|
|
305
|
+
minutes: 5,
|
|
306
|
+
status: 'todo',
|
|
307
|
+
},
|
|
308
|
+
{
|
|
309
|
+
id: 'first-invoice',
|
|
310
|
+
title: 'Send your first invoice',
|
|
311
|
+
description: 'Compose, preview and send — payment link included.',
|
|
312
|
+
minutes: 4,
|
|
313
|
+
status: 'todo',
|
|
314
|
+
},
|
|
315
|
+
{
|
|
316
|
+
id: 'reminders',
|
|
317
|
+
title: 'Turn on payment reminders',
|
|
318
|
+
description: 'Stop chasing overdue invoices by hand.',
|
|
319
|
+
minutes: 1,
|
|
320
|
+
status: 'todo',
|
|
321
|
+
},
|
|
322
|
+
]);
|
|
323
|
+
|
|
324
|
+
// Icon names are full static literals: the production icon scanner bundles
|
|
325
|
+
// only literals it can see, and brand SVGs live in the app's iconDir.
|
|
326
|
+
const integrations = reactive<WorkspaceIntegration[]>([
|
|
327
|
+
{
|
|
328
|
+
id: 'stripe',
|
|
329
|
+
name: 'Stripe',
|
|
330
|
+
description: 'Accept card payments; payouts reconcile against invoices.',
|
|
331
|
+
icon: 'local:stripe',
|
|
332
|
+
connected: false,
|
|
333
|
+
busy: false,
|
|
334
|
+
},
|
|
335
|
+
{
|
|
336
|
+
id: 'quickbooks',
|
|
337
|
+
name: 'QuickBooks Online',
|
|
338
|
+
description: 'Push paid invoices straight into your accounting.',
|
|
339
|
+
icon: 'local:quickbooks',
|
|
340
|
+
connected: false,
|
|
341
|
+
busy: false,
|
|
342
|
+
},
|
|
343
|
+
{
|
|
344
|
+
id: 'slack',
|
|
345
|
+
name: 'Slack',
|
|
346
|
+
description: 'A message in #finance when an invoice is paid or overdue.',
|
|
347
|
+
icon: 'local:slack',
|
|
348
|
+
connected: false,
|
|
349
|
+
busy: false,
|
|
350
|
+
},
|
|
351
|
+
{
|
|
352
|
+
id: 'google-drive',
|
|
353
|
+
name: 'Google Drive',
|
|
354
|
+
description: 'Attach contracts and receipts from your shared drives.',
|
|
355
|
+
icon: 'local:google-drive',
|
|
356
|
+
connected: false,
|
|
357
|
+
busy: false,
|
|
358
|
+
},
|
|
359
|
+
]);
|
|
360
|
+
|
|
361
|
+
const activeStep = ref<StepId | null>(null);
|
|
362
|
+
const workspace = ref<WorkspaceProfile | null>(null);
|
|
363
|
+
const invites = ref<PendingInvite[]>([]);
|
|
364
|
+
const firstProject = ref<Project | null>(null);
|
|
365
|
+
const importState = reactive({
|
|
366
|
+
uploading: false,
|
|
367
|
+
sentBytes: 0,
|
|
368
|
+
totalBytes: 0,
|
|
369
|
+
importedCount: null as number | null,
|
|
370
|
+
});
|
|
371
|
+
const reminders = reactive({
|
|
372
|
+
enabled: false,
|
|
373
|
+
cadence: '3-7-14' as ReminderCadence,
|
|
374
|
+
});
|
|
375
|
+
|
|
376
|
+
// Skipped counts as done: the bar rewards moving on, like Linear's checklist.
|
|
377
|
+
const doneCount = computed(
|
|
378
|
+
() => steps.filter((step) => step.status !== 'todo').length
|
|
379
|
+
);
|
|
380
|
+
const allDone = computed(() => doneCount.value === steps.length);
|
|
381
|
+
|
|
382
|
+
const step = (id: StepId): OnboardingStep =>
|
|
383
|
+
steps.find((candidate) => candidate.id === id)!;
|
|
384
|
+
|
|
385
|
+
// -- Data: one useAsyncData load; every mutation ends in refresh(). --------
|
|
386
|
+
const { data, refresh } = useAsyncData<OnboardingState>('onboarding', () =>
|
|
387
|
+
$fetch<OnboardingState>('/api/onboarding')
|
|
388
|
+
);
|
|
389
|
+
|
|
390
|
+
let hasOpenedFirstStep = false;
|
|
391
|
+
watch(
|
|
392
|
+
data,
|
|
393
|
+
(state) => {
|
|
394
|
+
if (!state) return;
|
|
395
|
+
for (const item of steps) item.status = state.steps[item.id];
|
|
396
|
+
const connected = new Set(state.connectedIntegrations);
|
|
397
|
+
for (const integration of integrations)
|
|
398
|
+
integration.connected = connected.has(integration.id);
|
|
399
|
+
workspace.value = state.workspace;
|
|
400
|
+
invites.value = state.invites;
|
|
401
|
+
firstProject.value = state.firstProject;
|
|
402
|
+
importState.importedCount = state.importedCustomers;
|
|
403
|
+
reminders.enabled = state.reminders.enabled;
|
|
404
|
+
reminders.cadence = state.reminders.cadence;
|
|
405
|
+
// Open the first unfinished step once, the first time data arrives.
|
|
406
|
+
if (!hasOpenedFirstStep) {
|
|
407
|
+
activeStep.value =
|
|
408
|
+
steps.find((candidate) => candidate.status === 'todo')?.id ?? null;
|
|
409
|
+
hasOpenedFirstStep = true;
|
|
410
|
+
}
|
|
411
|
+
},
|
|
412
|
+
{ immediate: true }
|
|
413
|
+
);
|
|
414
|
+
|
|
415
|
+
// -- Step grammar ----------------------------------------------------------------
|
|
416
|
+
const openStep = (id: StepId | null) => {
|
|
417
|
+
activeStep.value = id;
|
|
418
|
+
};
|
|
419
|
+
// Previews replace: a checklist preview never stacks on another preview.
|
|
420
|
+
const previewStep = (id: StepId) =>
|
|
421
|
+
shell.push({ type: 'step-preview', stepId: id }, true);
|
|
422
|
+
// From the peek back into the page: open the step and drop the sidebar.
|
|
423
|
+
const jumpToStep = (id: StepId) => {
|
|
424
|
+
activeStep.value = id;
|
|
425
|
+
shell.close();
|
|
426
|
+
};
|
|
427
|
+
const openNextTodo = (after: StepId) => {
|
|
428
|
+
const index = steps.findIndex((candidate) => candidate.id === after);
|
|
429
|
+
const next = [...steps.slice(index + 1), ...steps.slice(0, index)].find(
|
|
430
|
+
(candidate) => candidate.status === 'todo'
|
|
431
|
+
);
|
|
432
|
+
activeStep.value = next?.id ?? null;
|
|
433
|
+
};
|
|
434
|
+
|
|
435
|
+
// -- Actions --------------------------------------------------------------------
|
|
436
|
+
// The one status writer: $fetch then refresh() re-seeds the whole page from
|
|
437
|
+
// the server response. Domain actions (send invites, import…) auto-check
|
|
438
|
+
// their step through it; the manual done/skip ghosts use the same verb.
|
|
439
|
+
const persistStatus = async (id: StepId, status: StepStatus) => {
|
|
440
|
+
if (step(id).status === status) return;
|
|
441
|
+
await $fetch(`/api/onboarding/steps/${id}`, {
|
|
442
|
+
method: 'PATCH',
|
|
443
|
+
body: { status },
|
|
444
|
+
});
|
|
445
|
+
await refresh();
|
|
446
|
+
};
|
|
447
|
+
|
|
448
|
+
const completeStep = async (id: StepId) => {
|
|
449
|
+
const title = step(id).title;
|
|
450
|
+
await persistStatus(id, 'complete');
|
|
451
|
+
toast({ title: `"${title}" checked off.`, variant: 'success' });
|
|
452
|
+
openNextTodo(id);
|
|
453
|
+
};
|
|
454
|
+
|
|
455
|
+
// Skipping is quiet: it is a dismissal, not an achievement.
|
|
456
|
+
const skipStep = async (id: StepId) => {
|
|
457
|
+
await persistStatus(id, 'skipped');
|
|
458
|
+
openNextTodo(id);
|
|
459
|
+
};
|
|
460
|
+
|
|
461
|
+
// Optimistic, per the BbSwitch doctrine: flip now, revert + toast on failure.
|
|
462
|
+
// `busy` drives `readonly` so conflicting toggles cannot queue.
|
|
463
|
+
const toggleIntegration = async (
|
|
464
|
+
integration: WorkspaceIntegration,
|
|
465
|
+
next: boolean
|
|
466
|
+
) => {
|
|
467
|
+
integration.busy = true;
|
|
468
|
+
integration.connected = next;
|
|
469
|
+
try {
|
|
470
|
+
await $fetch(
|
|
471
|
+
`/api/onboarding/integrations/${integration.id}/${next ? 'connect' : 'disconnect'}`,
|
|
472
|
+
{ method: 'POST' }
|
|
473
|
+
);
|
|
474
|
+
toast({
|
|
475
|
+
title: `${integration.name} ${next ? 'connected' : 'disconnected'}.`,
|
|
476
|
+
variant: 'success',
|
|
477
|
+
});
|
|
478
|
+
if (next) await persistStatus('integrations', 'complete');
|
|
479
|
+
} catch {
|
|
480
|
+
integration.connected = !next;
|
|
481
|
+
toast({
|
|
482
|
+
title: `Could not ${next ? 'connect' : 'disconnect'} ${integration.name}.`,
|
|
483
|
+
variant: 'destructive',
|
|
484
|
+
});
|
|
485
|
+
} finally {
|
|
486
|
+
integration.busy = false;
|
|
487
|
+
}
|
|
488
|
+
};
|
|
489
|
+
|
|
490
|
+
const sendInvites = async (emails: string[], role: InviteRole) => {
|
|
491
|
+
await $fetch('/api/onboarding/invites', {
|
|
492
|
+
method: 'POST',
|
|
493
|
+
body: { emails, role },
|
|
494
|
+
});
|
|
495
|
+
await persistStatus('invites', 'complete');
|
|
496
|
+
toast({
|
|
497
|
+
title: `${emails.length} invitation${emails.length === 1 ? '' : 's'} sent.`,
|
|
498
|
+
variant: 'success',
|
|
499
|
+
});
|
|
500
|
+
};
|
|
501
|
+
|
|
502
|
+
const createProject = async (draft: ProjectDraft) => {
|
|
503
|
+
await $fetch('/api/onboarding/project', { method: 'POST', body: draft });
|
|
504
|
+
await persistStatus('first-project', 'complete');
|
|
505
|
+
toast({ title: `${draft.name} created.`, variant: 'success' });
|
|
506
|
+
};
|
|
507
|
+
|
|
508
|
+
const importCustomers = async (file: File) => {
|
|
509
|
+
importState.uploading = true;
|
|
510
|
+
importState.totalBytes = file.size;
|
|
511
|
+
importState.sentBytes = 0;
|
|
512
|
+
try {
|
|
513
|
+
const body = new FormData();
|
|
514
|
+
body.append('file', file);
|
|
515
|
+
const result = await uploadWithProgress(
|
|
516
|
+
'/api/onboarding/customers/import',
|
|
517
|
+
body,
|
|
518
|
+
(sentBytes, totalBytes) => {
|
|
519
|
+
importState.sentBytes = sentBytes;
|
|
520
|
+
importState.totalBytes = totalBytes;
|
|
521
|
+
}
|
|
522
|
+
);
|
|
523
|
+
importState.importedCount = result.imported;
|
|
524
|
+
await persistStatus('import-customers', 'complete');
|
|
525
|
+
toast({
|
|
526
|
+
title: `${result.imported} customers imported.`,
|
|
527
|
+
variant: 'success',
|
|
528
|
+
});
|
|
529
|
+
} finally {
|
|
530
|
+
importState.uploading = false;
|
|
531
|
+
}
|
|
532
|
+
};
|
|
533
|
+
|
|
534
|
+
const setReminders = async (enabled: boolean) => {
|
|
535
|
+
reminders.enabled = enabled;
|
|
536
|
+
try {
|
|
537
|
+
await $fetch('/api/onboarding/reminders', {
|
|
538
|
+
method: 'PATCH',
|
|
539
|
+
body: { enabled, cadence: reminders.cadence },
|
|
540
|
+
});
|
|
541
|
+
if (enabled) await persistStatus('reminders', 'complete');
|
|
542
|
+
toast({
|
|
543
|
+
title: enabled
|
|
544
|
+
? 'Payment reminders are on.'
|
|
545
|
+
: 'Payment reminders turned off.',
|
|
546
|
+
variant: 'success',
|
|
547
|
+
});
|
|
548
|
+
} catch {
|
|
549
|
+
reminders.enabled = !enabled;
|
|
550
|
+
toast({ title: 'Could not update reminders.', variant: 'destructive' });
|
|
551
|
+
}
|
|
552
|
+
};
|
|
553
|
+
|
|
554
|
+
const setReminderCadence = async (cadence: ReminderCadence) => {
|
|
555
|
+
reminders.cadence = cadence;
|
|
556
|
+
await $fetch('/api/onboarding/reminders', {
|
|
557
|
+
method: 'PATCH',
|
|
558
|
+
body: { enabled: reminders.enabled, cadence },
|
|
559
|
+
});
|
|
560
|
+
toast({ title: 'Reminder schedule updated.', variant: 'success' });
|
|
561
|
+
};
|
|
562
|
+
|
|
563
|
+
const dismissOnboarding = async () => {
|
|
564
|
+
const ok = await confirm({
|
|
565
|
+
variant: 'destructive',
|
|
566
|
+
title: 'Dismiss onboarding',
|
|
567
|
+
text: 'Hide the setup checklist for everyone in this workspace? Unfinished steps stay available under Settings → Setup.',
|
|
568
|
+
yes: 'Dismiss',
|
|
569
|
+
no: 'Keep it',
|
|
570
|
+
});
|
|
571
|
+
if (!ok) return;
|
|
572
|
+
await $fetch('/api/onboarding/dismiss', { method: 'POST' });
|
|
573
|
+
toast({
|
|
574
|
+
title: 'Onboarding dismissed. Find it again under Settings → Setup.',
|
|
575
|
+
variant: 'success',
|
|
576
|
+
});
|
|
577
|
+
await navigateTo('/dashboard');
|
|
578
|
+
};
|
|
579
|
+
|
|
580
|
+
const ctx: OnboardingWorkspaceContext = {
|
|
581
|
+
shell,
|
|
582
|
+
steps,
|
|
583
|
+
activeStep,
|
|
584
|
+
doneCount,
|
|
585
|
+
allDone,
|
|
586
|
+
workspace,
|
|
587
|
+
integrations,
|
|
588
|
+
invites,
|
|
589
|
+
firstProject,
|
|
590
|
+
importState,
|
|
591
|
+
reminders,
|
|
592
|
+
openStep,
|
|
593
|
+
previewStep,
|
|
594
|
+
jumpToStep,
|
|
595
|
+
completeStep,
|
|
596
|
+
skipStep,
|
|
597
|
+
toggleIntegration,
|
|
598
|
+
sendInvites,
|
|
599
|
+
createProject,
|
|
600
|
+
importCustomers,
|
|
601
|
+
setReminders,
|
|
602
|
+
setReminderCadence,
|
|
603
|
+
dismissOnboarding,
|
|
604
|
+
};
|
|
605
|
+
provide(key, ctx);
|
|
606
|
+
return ctx;
|
|
607
|
+
}
|
|
608
|
+
|
|
609
|
+
export function useOnboardingWorkspace(): OnboardingWorkspaceContext {
|
|
610
|
+
const ctx = inject(key);
|
|
611
|
+
if (!ctx)
|
|
612
|
+
throw new Error(
|
|
613
|
+
'useOnboardingWorkspace() called outside OnboardingChecklist'
|
|
614
|
+
);
|
|
615
|
+
return ctx;
|
|
616
|
+
}
|
|
617
|
+
```
|
|
618
|
+
|
|
619
|
+
### Index.vue — the assembly
|
|
620
|
+
|
|
621
|
+
```vue
|
|
622
|
+
<!-- OnboardingChecklist/Index.vue -->
|
|
623
|
+
<template>
|
|
624
|
+
<PageShell>
|
|
625
|
+
<!-- Topbar: breadcrumbs left, the page's one primary action right. -->
|
|
626
|
+
<template #topbar>
|
|
627
|
+
<div class="flex items-center justify-between gap-4 border-b px-4 py-2">
|
|
628
|
+
<!-- Breadcrumbs take the row's slack on a stable basis (min-w-0 flex-auto);
|
|
629
|
+
without it their overflow recompute fights the flex layout every frame. -->
|
|
630
|
+
<BbBreadcrumbs
|
|
631
|
+
class="min-w-0 flex-auto"
|
|
632
|
+
:items="[
|
|
633
|
+
{ key: 'dashboard', text: 'Dashboard', to: '/dashboard' },
|
|
634
|
+
{ key: 'getting-started', text: 'Getting started' },
|
|
635
|
+
]"
|
|
636
|
+
/>
|
|
637
|
+
<BbButton
|
|
638
|
+
append:icon="lucide:arrow-right"
|
|
639
|
+
class="shrink-0"
|
|
640
|
+
to="/dashboard"
|
|
641
|
+
variant="primary"
|
|
642
|
+
>
|
|
643
|
+
Go to dashboard
|
|
644
|
+
</BbButton>
|
|
645
|
+
</div>
|
|
646
|
+
</template>
|
|
647
|
+
|
|
648
|
+
<div class="mx-auto flex w-full max-w-3xl flex-col gap-6 p-4">
|
|
649
|
+
<ProgressHeader />
|
|
650
|
+
|
|
651
|
+
<!-- Single-open checklist: one active key in the context derives every
|
|
652
|
+
panel's model-value; opening one closes the rest, and clicking the
|
|
653
|
+
open header collapses everything (payload is false → key null). -->
|
|
654
|
+
<div class="flex flex-col divide-y rounded-[var(--bb-radius)] border">
|
|
655
|
+
<BbAccordion
|
|
656
|
+
v-for="item in ctx.steps"
|
|
657
|
+
:key="item.id"
|
|
658
|
+
:model-value="ctx.activeStep.value === item.id"
|
|
659
|
+
@update:model-value="(open) => ctx.openStep(open ? item.id : null)"
|
|
660
|
+
>
|
|
661
|
+
<template #header="{ value }">
|
|
662
|
+
<StepHeader :open="value" :step="item" />
|
|
663
|
+
</template>
|
|
664
|
+
<div class="flex flex-col gap-4 px-11 pb-4">
|
|
665
|
+
<component :is="stepBodies[item.id]" />
|
|
666
|
+
<StepActions :step="item" />
|
|
667
|
+
</div>
|
|
668
|
+
</BbAccordion>
|
|
669
|
+
</div>
|
|
670
|
+
|
|
671
|
+
<p class="text-xs text-gray-500">
|
|
672
|
+
Stuck on a step?
|
|
673
|
+
<BbButton size="sm" to="/docs/setup" variant="link"
|
|
674
|
+
>Read the setup guide</BbButton
|
|
675
|
+
>
|
|
676
|
+
— it covers every integration and the CSV format.
|
|
677
|
+
</p>
|
|
678
|
+
</div>
|
|
679
|
+
|
|
680
|
+
<!-- The peek sidebar: the shell owns back/close; we render by type. -->
|
|
681
|
+
<template #sidebar>
|
|
682
|
+
<StepPreviewPeek
|
|
683
|
+
v-if="ctx.shell.current.value?.type === 'step-preview'"
|
|
684
|
+
:step-id="ctx.shell.current.value.stepId"
|
|
685
|
+
/>
|
|
686
|
+
</template>
|
|
687
|
+
</PageShell>
|
|
688
|
+
</template>
|
|
689
|
+
|
|
690
|
+
<script setup lang="ts">
|
|
691
|
+
import type { Component } from 'vue';
|
|
692
|
+
import { BbAccordion, BbBreadcrumbs, BbButton } from 'bitboss-ui';
|
|
693
|
+
import PageShell from '@/components/layout/PageShell.vue';
|
|
694
|
+
import { provideOnboardingWorkspace, type StepId } from './context';
|
|
695
|
+
import FirstInvoiceStep from './FirstInvoiceStep.vue';
|
|
696
|
+
import FirstProjectStep from './FirstProjectStep.vue';
|
|
697
|
+
import ImportCustomersStep from './ImportCustomersStep.vue';
|
|
698
|
+
import IntegrationsStep from './IntegrationsStep.vue';
|
|
699
|
+
import InviteStep from './InviteStep.vue';
|
|
700
|
+
import ProfileStep from './ProfileStep.vue';
|
|
701
|
+
import ProgressHeader from './ProgressHeader.vue';
|
|
702
|
+
import RemindersStep from './RemindersStep.vue';
|
|
703
|
+
import StepActions from './StepActions.vue';
|
|
704
|
+
import StepHeader from './StepHeader.vue';
|
|
705
|
+
import StepPreviewPeek from './StepPreviewPeek.vue';
|
|
706
|
+
|
|
707
|
+
const ctx = provideOnboardingWorkspace();
|
|
708
|
+
|
|
709
|
+
// Each step body is its own component — a lookup, not a `type` prop.
|
|
710
|
+
const stepBodies: Record<StepId, Component> = {
|
|
711
|
+
profile: ProfileStep,
|
|
712
|
+
integrations: IntegrationsStep,
|
|
713
|
+
invites: InviteStep,
|
|
714
|
+
'first-project': FirstProjectStep,
|
|
715
|
+
'import-customers': ImportCustomersStep,
|
|
716
|
+
'first-invoice': FirstInvoiceStep,
|
|
717
|
+
reminders: RemindersStep,
|
|
718
|
+
};
|
|
719
|
+
</script>
|
|
720
|
+
```
|
|
721
|
+
|
|
722
|
+
### ProgressHeader.vue
|
|
723
|
+
|
|
724
|
+
```vue
|
|
725
|
+
<!-- OnboardingChecklist/ProgressHeader.vue -->
|
|
726
|
+
<template>
|
|
727
|
+
<header class="flex flex-col gap-3">
|
|
728
|
+
<div class="flex items-start justify-between gap-4">
|
|
729
|
+
<div class="flex flex-col gap-1">
|
|
730
|
+
<h1 class="text-xl font-semibold">Set up Acme</h1>
|
|
731
|
+
<p class="text-sm text-gray-500">
|
|
732
|
+
A few steps to get your billing workspace ready for the whole team.
|
|
733
|
+
</p>
|
|
734
|
+
</div>
|
|
735
|
+
<BbButton variant="ghost" @click="ctx.dismissOnboarding">
|
|
736
|
+
Dismiss onboarding
|
|
737
|
+
</BbButton>
|
|
738
|
+
</div>
|
|
739
|
+
|
|
740
|
+
<div class="flex flex-col gap-1.5">
|
|
741
|
+
<div class="flex items-center justify-between gap-4 text-sm">
|
|
742
|
+
<span class="font-medium">
|
|
743
|
+
{{
|
|
744
|
+
ctx.allDone.value
|
|
745
|
+
? 'All set — your workspace is ready.'
|
|
746
|
+
: 'Your setup checklist'
|
|
747
|
+
}}
|
|
748
|
+
</span>
|
|
749
|
+
<span class="text-gray-500">
|
|
750
|
+
{{ ctx.doneCount.value }} of {{ ctx.steps.length }} complete
|
|
751
|
+
</span>
|
|
752
|
+
</div>
|
|
753
|
+
<!-- Real units in, no pre-computed percentage: max = number of steps. -->
|
|
754
|
+
<BbProgress
|
|
755
|
+
aria-label="Setup progress"
|
|
756
|
+
:aria-valuetext="`${ctx.doneCount.value} of ${ctx.steps.length} steps complete`"
|
|
757
|
+
:max="ctx.steps.length"
|
|
758
|
+
:model-value="ctx.doneCount.value"
|
|
759
|
+
/>
|
|
760
|
+
</div>
|
|
761
|
+
</header>
|
|
762
|
+
</template>
|
|
763
|
+
|
|
764
|
+
<script setup lang="ts">
|
|
765
|
+
import { BbButton, BbProgress } from 'bitboss-ui';
|
|
766
|
+
import { useOnboardingWorkspace } from './context';
|
|
767
|
+
|
|
768
|
+
const ctx = useOnboardingWorkspace();
|
|
769
|
+
</script>
|
|
770
|
+
```
|
|
771
|
+
|
|
772
|
+
### StepHeader.vue
|
|
773
|
+
|
|
774
|
+
```vue
|
|
775
|
+
<!-- OnboardingChecklist/StepHeader.vue -->
|
|
776
|
+
<template>
|
|
777
|
+
<!-- Rendered INSIDE the accordion's header button: everything here is
|
|
778
|
+
non-interactive and click-transparent by design — the whole row toggles. -->
|
|
779
|
+
<span class="flex w-full items-center gap-3 px-3 py-3 text-left">
|
|
780
|
+
<BbIcon
|
|
781
|
+
class="shrink-0"
|
|
782
|
+
:class="step.status === 'complete' ? 'text-green-600' : 'text-gray-400'"
|
|
783
|
+
:icon="statusIcon"
|
|
784
|
+
size="20"
|
|
785
|
+
/>
|
|
786
|
+
<span class="flex min-w-0 flex-1 flex-col">
|
|
787
|
+
<span
|
|
788
|
+
class="text-sm font-medium"
|
|
789
|
+
:class="step.status === 'todo' ? '' : 'text-gray-500'"
|
|
790
|
+
>
|
|
791
|
+
{{ step.title }}
|
|
792
|
+
</span>
|
|
793
|
+
<span class="truncate text-xs text-gray-500">{{ step.description }}</span>
|
|
794
|
+
</span>
|
|
795
|
+
<span
|
|
796
|
+
v-if="step.status === 'skipped'"
|
|
797
|
+
class="shrink-0 text-xs uppercase tracking-wide text-gray-400"
|
|
798
|
+
>
|
|
799
|
+
Skipped
|
|
800
|
+
</span>
|
|
801
|
+
<span
|
|
802
|
+
v-else-if="step.status === 'todo'"
|
|
803
|
+
class="shrink-0 text-xs text-gray-400"
|
|
804
|
+
>
|
|
805
|
+
~{{ step.minutes }} min
|
|
806
|
+
</span>
|
|
807
|
+
<BbIcon
|
|
808
|
+
class="shrink-0 text-gray-400 transition-transform"
|
|
809
|
+
:class="open ? 'rotate-180' : ''"
|
|
810
|
+
icon="lucide:chevron-down"
|
|
811
|
+
size="16"
|
|
812
|
+
/>
|
|
813
|
+
</span>
|
|
814
|
+
</template>
|
|
815
|
+
|
|
816
|
+
<script setup lang="ts">
|
|
817
|
+
import { computed } from 'vue';
|
|
818
|
+
import { BbIcon } from 'bitboss-ui';
|
|
819
|
+
import type { OnboardingStep } from './context';
|
|
820
|
+
|
|
821
|
+
const props = defineProps<{ open: boolean; step: OnboardingStep }>();
|
|
822
|
+
|
|
823
|
+
// Full literals — the production icon scanner needs complete names.
|
|
824
|
+
const icons = {
|
|
825
|
+
todo: 'lucide:circle-dashed',
|
|
826
|
+
complete: 'lucide:circle-check',
|
|
827
|
+
skipped: 'lucide:circle-check',
|
|
828
|
+
} as const;
|
|
829
|
+
const statusIcon = computed(() => icons[props.step.status]);
|
|
830
|
+
</script>
|
|
831
|
+
```
|
|
832
|
+
|
|
833
|
+
### StepActions.vue
|
|
834
|
+
|
|
835
|
+
```vue
|
|
836
|
+
<!-- OnboardingChecklist/StepActions.vue -->
|
|
837
|
+
<template>
|
|
838
|
+
<footer class="flex flex-wrap items-center gap-2 border-t pt-3">
|
|
839
|
+
<template v-if="step.status === 'todo'">
|
|
840
|
+
<BbButton
|
|
841
|
+
prepend:icon="lucide:check"
|
|
842
|
+
variant="ghost"
|
|
843
|
+
@click="() => ctx.completeStep(step.id)"
|
|
844
|
+
>
|
|
845
|
+
Mark as done
|
|
846
|
+
</BbButton>
|
|
847
|
+
<BbButton variant="ghost" @click="() => ctx.skipStep(step.id)">
|
|
848
|
+
Skip for now
|
|
849
|
+
</BbButton>
|
|
850
|
+
</template>
|
|
851
|
+
<span v-else class="text-xs text-gray-500">
|
|
852
|
+
{{ step.status === 'complete' ? 'Completed' : 'Skipped' }} — revisit any
|
|
853
|
+
time from Settings → Setup.
|
|
854
|
+
</span>
|
|
855
|
+
<BbButton
|
|
856
|
+
append:icon="lucide:chevron-right"
|
|
857
|
+
class="ml-auto"
|
|
858
|
+
variant="ghost"
|
|
859
|
+
@click="() => ctx.previewStep(step.id)"
|
|
860
|
+
>
|
|
861
|
+
See what you'll get
|
|
862
|
+
</BbButton>
|
|
863
|
+
</footer>
|
|
864
|
+
</template>
|
|
865
|
+
|
|
866
|
+
<script setup lang="ts">
|
|
867
|
+
import { BbButton } from 'bitboss-ui';
|
|
868
|
+
import { useOnboardingWorkspace } from './context';
|
|
869
|
+
import type { OnboardingStep } from './context';
|
|
870
|
+
|
|
871
|
+
defineProps<{ step: OnboardingStep }>();
|
|
872
|
+
|
|
873
|
+
const ctx = useOnboardingWorkspace();
|
|
874
|
+
</script>
|
|
875
|
+
```
|
|
876
|
+
|
|
877
|
+
### ProfileStep.vue
|
|
878
|
+
|
|
879
|
+
```vue
|
|
880
|
+
<!-- OnboardingChecklist/ProfileStep.vue -->
|
|
881
|
+
<template>
|
|
882
|
+
<div v-if="ctx.workspace.value" class="flex flex-col gap-3 text-sm">
|
|
883
|
+
<p class="text-gray-600">
|
|
884
|
+
Done at signup — these details appear on every invoice you send.
|
|
885
|
+
</p>
|
|
886
|
+
<dl class="grid grid-cols-[auto_1fr] gap-x-6 gap-y-1.5">
|
|
887
|
+
<dt class="text-gray-500">Company</dt>
|
|
888
|
+
<dd>{{ ctx.workspace.value.company }}</dd>
|
|
889
|
+
<dt class="text-gray-500">Billing address</dt>
|
|
890
|
+
<dd>{{ ctx.workspace.value.address }}</dd>
|
|
891
|
+
<dt class="text-gray-500">Tax ID</dt>
|
|
892
|
+
<dd>{{ ctx.workspace.value.taxId }}</dd>
|
|
893
|
+
<dt class="text-gray-500">Currency</dt>
|
|
894
|
+
<dd>{{ ctx.workspace.value.currency }}</dd>
|
|
895
|
+
</dl>
|
|
896
|
+
<div>
|
|
897
|
+
<BbButton
|
|
898
|
+
prepend:icon="lucide:pencil"
|
|
899
|
+
size="sm"
|
|
900
|
+
to="/settings/general"
|
|
901
|
+
variant="link"
|
|
902
|
+
>
|
|
903
|
+
Edit workspace profile
|
|
904
|
+
</BbButton>
|
|
905
|
+
</div>
|
|
906
|
+
</div>
|
|
907
|
+
</template>
|
|
908
|
+
|
|
909
|
+
<script setup lang="ts">
|
|
910
|
+
import { BbButton } from 'bitboss-ui';
|
|
911
|
+
import { useOnboardingWorkspace } from './context';
|
|
912
|
+
|
|
913
|
+
const ctx = useOnboardingWorkspace();
|
|
914
|
+
</script>
|
|
915
|
+
```
|
|
916
|
+
|
|
917
|
+
### IntegrationsStep.vue
|
|
918
|
+
|
|
919
|
+
```vue
|
|
920
|
+
<!-- OnboardingChecklist/IntegrationsStep.vue -->
|
|
921
|
+
<template>
|
|
922
|
+
<div class="flex flex-col text-sm">
|
|
923
|
+
<p class="pb-1 text-gray-600">
|
|
924
|
+
Flip a switch to connect — you'll be sent through the provider's consent
|
|
925
|
+
screen the first time.
|
|
926
|
+
</p>
|
|
927
|
+
<div
|
|
928
|
+
v-for="integration in ctx.integrations"
|
|
929
|
+
:key="integration.id"
|
|
930
|
+
class="flex items-center gap-3 border-b py-2.5 last:border-b-0"
|
|
931
|
+
>
|
|
932
|
+
<BbIcon class="shrink-0" :icon="integration.icon" size="20" />
|
|
933
|
+
<div class="flex min-w-0 flex-1 flex-col">
|
|
934
|
+
<span class="font-medium">{{ integration.name }}</span>
|
|
935
|
+
<span class="truncate text-xs text-gray-500">
|
|
936
|
+
{{ integration.description }}
|
|
937
|
+
</span>
|
|
938
|
+
</div>
|
|
939
|
+
<!-- Instant-effect toggle: the context flips optimistically, holds the
|
|
940
|
+
switch readonly while in flight, and reverts + toasts on failure. -->
|
|
941
|
+
<BbSwitch
|
|
942
|
+
hide-label
|
|
943
|
+
:label="`Connect ${integration.name}`"
|
|
944
|
+
:model-value="integration.connected"
|
|
945
|
+
:name="`integration-${integration.id}`"
|
|
946
|
+
:readonly="integration.busy"
|
|
947
|
+
@update:model-value="(next) => ctx.toggleIntegration(integration, next)"
|
|
948
|
+
/>
|
|
949
|
+
</div>
|
|
950
|
+
</div>
|
|
951
|
+
</template>
|
|
952
|
+
|
|
953
|
+
<script setup lang="ts">
|
|
954
|
+
import { BbIcon, BbSwitch } from 'bitboss-ui';
|
|
955
|
+
import { useOnboardingWorkspace } from './context';
|
|
956
|
+
|
|
957
|
+
const ctx = useOnboardingWorkspace();
|
|
958
|
+
</script>
|
|
959
|
+
```
|
|
960
|
+
|
|
961
|
+
### InviteStep.vue
|
|
962
|
+
|
|
963
|
+
```vue
|
|
964
|
+
<!-- OnboardingChecklist/InviteStep.vue -->
|
|
965
|
+
<template>
|
|
966
|
+
<div class="flex flex-col gap-3 text-sm">
|
|
967
|
+
<p class="text-gray-600">
|
|
968
|
+
Paste addresses or type them — Enter or a comma adds each one.
|
|
969
|
+
</p>
|
|
970
|
+
|
|
971
|
+
<div class="flex flex-wrap items-end gap-2">
|
|
972
|
+
<BbTag
|
|
973
|
+
v-model="emails"
|
|
974
|
+
class="min-w-64 flex-1"
|
|
975
|
+
compact
|
|
976
|
+
:divider="['Enter', ',']"
|
|
977
|
+
:errors="inviteError"
|
|
978
|
+
label="Email addresses"
|
|
979
|
+
:max="10"
|
|
980
|
+
placeholder="ada.rossi@acme.com"
|
|
981
|
+
prepend:icon="lucide:mail"
|
|
982
|
+
@duplicate="
|
|
983
|
+
(email) => (inviteError = `${email} is already in the list.`)
|
|
984
|
+
"
|
|
985
|
+
@max="() => (inviteError = 'You can invite up to 10 people at once.')"
|
|
986
|
+
/>
|
|
987
|
+
<BbSelect
|
|
988
|
+
v-model="role"
|
|
989
|
+
class="w-44"
|
|
990
|
+
compact
|
|
991
|
+
item-text="label"
|
|
992
|
+
item-value="value"
|
|
993
|
+
:items="roles"
|
|
994
|
+
label="Role"
|
|
995
|
+
label-mode="outside"
|
|
996
|
+
/>
|
|
997
|
+
<BbButton prepend:icon="lucide:send" variant="secondary" @click="send">
|
|
998
|
+
Send invitations
|
|
999
|
+
</BbButton>
|
|
1000
|
+
</div>
|
|
1001
|
+
|
|
1002
|
+
<ul v-if="ctx.invites.value.length" class="flex flex-col gap-1">
|
|
1003
|
+
<li
|
|
1004
|
+
v-for="invite in ctx.invites.value"
|
|
1005
|
+
:key="invite.email"
|
|
1006
|
+
class="flex items-center justify-between gap-2 text-xs"
|
|
1007
|
+
>
|
|
1008
|
+
<span>{{ invite.email }}</span>
|
|
1009
|
+
<span class="text-gray-500"
|
|
1010
|
+
>{{ invite.role }} · invited {{ invite.sentAt }}</span
|
|
1011
|
+
>
|
|
1012
|
+
</li>
|
|
1013
|
+
</ul>
|
|
1014
|
+
</div>
|
|
1015
|
+
</template>
|
|
1016
|
+
|
|
1017
|
+
<script setup lang="ts">
|
|
1018
|
+
import { ref } from 'vue';
|
|
1019
|
+
import { BbButton, BbSelect, BbTag } from 'bitboss-ui';
|
|
1020
|
+
import { useOnboardingWorkspace } from './context';
|
|
1021
|
+
import type { InviteRole } from '@/types';
|
|
1022
|
+
|
|
1023
|
+
const ctx = useOnboardingWorkspace();
|
|
1024
|
+
|
|
1025
|
+
// Draft state only this leaf touches: local refs, not context fields.
|
|
1026
|
+
const emails = ref<string[]>([]);
|
|
1027
|
+
const role = ref<InviteRole>('member');
|
|
1028
|
+
const inviteError = ref('');
|
|
1029
|
+
|
|
1030
|
+
const roles: { value: InviteRole; label: string }[] = [
|
|
1031
|
+
{ value: 'admin', label: 'Admin' },
|
|
1032
|
+
{ value: 'member', label: 'Member' },
|
|
1033
|
+
{ value: 'accountant', label: 'Accountant' },
|
|
1034
|
+
];
|
|
1035
|
+
|
|
1036
|
+
// Returning the promise lets the button's automatic loading track the send.
|
|
1037
|
+
const send = async () => {
|
|
1038
|
+
inviteError.value = '';
|
|
1039
|
+
if (emails.value.length === 0) {
|
|
1040
|
+
inviteError.value = 'Add at least one email address.';
|
|
1041
|
+
return;
|
|
1042
|
+
}
|
|
1043
|
+
const invalid = emails.value.filter((email) => !email.includes('@'));
|
|
1044
|
+
if (invalid.length > 0) {
|
|
1045
|
+
inviteError.value = `${invalid.join(', ')} ${invalid.length === 1 ? 'is' : 'are'} not a valid address.`;
|
|
1046
|
+
return;
|
|
1047
|
+
}
|
|
1048
|
+
await ctx.sendInvites(emails.value, role.value);
|
|
1049
|
+
emails.value = [];
|
|
1050
|
+
};
|
|
1051
|
+
</script>
|
|
1052
|
+
```
|
|
1053
|
+
|
|
1054
|
+
### FirstProjectStep.vue
|
|
1055
|
+
|
|
1056
|
+
```vue
|
|
1057
|
+
<!-- OnboardingChecklist/FirstProjectStep.vue -->
|
|
1058
|
+
<template>
|
|
1059
|
+
<!-- Already created (by this session or a teammate): show it, not the form. -->
|
|
1060
|
+
<div v-if="ctx.firstProject.value" class="flex items-center gap-2 text-sm">
|
|
1061
|
+
<BbIcon class="text-green-600" icon="lucide:circle-check" size="16" />
|
|
1062
|
+
<span>
|
|
1063
|
+
<span class="font-medium">{{ ctx.firstProject.value.name }}</span>
|
|
1064
|
+
is ready for its first invoice.
|
|
1065
|
+
</span>
|
|
1066
|
+
<BbButton
|
|
1067
|
+
append:icon="lucide:arrow-up-right"
|
|
1068
|
+
size="sm"
|
|
1069
|
+
:to="`/projects/${ctx.firstProject.value.id}`"
|
|
1070
|
+
variant="link"
|
|
1071
|
+
>
|
|
1072
|
+
Open project
|
|
1073
|
+
</BbButton>
|
|
1074
|
+
</div>
|
|
1075
|
+
|
|
1076
|
+
<form
|
|
1077
|
+
v-else
|
|
1078
|
+
class="flex flex-col gap-3 text-sm"
|
|
1079
|
+
novalidate
|
|
1080
|
+
@submit.prevent="submit"
|
|
1081
|
+
>
|
|
1082
|
+
<p class="text-gray-600">
|
|
1083
|
+
A project keeps one client's invoices, budget and time entries together.
|
|
1084
|
+
</p>
|
|
1085
|
+
<div class="flex flex-wrap items-end gap-2">
|
|
1086
|
+
<BbTextInput
|
|
1087
|
+
v-model="draft.name"
|
|
1088
|
+
class="min-w-56 flex-1"
|
|
1089
|
+
compact
|
|
1090
|
+
:errors="nameError"
|
|
1091
|
+
label="Project name"
|
|
1092
|
+
label-mode="outside"
|
|
1093
|
+
placeholder="Website redesign"
|
|
1094
|
+
/>
|
|
1095
|
+
<BbTextInput
|
|
1096
|
+
v-model="draft.client"
|
|
1097
|
+
class="min-w-56 flex-1"
|
|
1098
|
+
compact
|
|
1099
|
+
label="Client"
|
|
1100
|
+
label-mode="outside"
|
|
1101
|
+
placeholder="Globex Corporation"
|
|
1102
|
+
/>
|
|
1103
|
+
<BbButton prepend:icon="lucide:plus" type="submit" variant="secondary">
|
|
1104
|
+
Create project
|
|
1105
|
+
</BbButton>
|
|
1106
|
+
</div>
|
|
1107
|
+
</form>
|
|
1108
|
+
</template>
|
|
1109
|
+
|
|
1110
|
+
<script setup lang="ts">
|
|
1111
|
+
import { reactive, ref } from 'vue';
|
|
1112
|
+
import { BbButton, BbIcon, BbTextInput } from 'bitboss-ui';
|
|
1113
|
+
import { useOnboardingWorkspace } from './context';
|
|
1114
|
+
|
|
1115
|
+
const ctx = useOnboardingWorkspace();
|
|
1116
|
+
|
|
1117
|
+
const draft = reactive({ name: '', client: '' });
|
|
1118
|
+
const nameError = ref('');
|
|
1119
|
+
|
|
1120
|
+
// Returning the promise lets the submit button track the async work.
|
|
1121
|
+
const submit = () => {
|
|
1122
|
+
nameError.value = '';
|
|
1123
|
+
if (!draft.name.trim()) {
|
|
1124
|
+
nameError.value = 'Give the project a name.';
|
|
1125
|
+
return;
|
|
1126
|
+
}
|
|
1127
|
+
return ctx.createProject({ ...draft });
|
|
1128
|
+
};
|
|
1129
|
+
</script>
|
|
1130
|
+
```
|
|
1131
|
+
|
|
1132
|
+
### ImportCustomersStep.vue
|
|
1133
|
+
|
|
1134
|
+
```vue
|
|
1135
|
+
<!-- OnboardingChecklist/ImportCustomersStep.vue -->
|
|
1136
|
+
<template>
|
|
1137
|
+
<div class="flex flex-col gap-3 text-sm">
|
|
1138
|
+
<!-- Already imported: report it instead of showing an empty dropzone. -->
|
|
1139
|
+
<div
|
|
1140
|
+
v-if="ctx.importState.importedCount !== null"
|
|
1141
|
+
class="flex items-center gap-2"
|
|
1142
|
+
>
|
|
1143
|
+
<BbIcon class="text-green-600" icon="lucide:circle-check" size="16" />
|
|
1144
|
+
<span>
|
|
1145
|
+
<span class="font-medium">{{ ctx.importState.importedCount }}</span>
|
|
1146
|
+
customers imported.
|
|
1147
|
+
</span>
|
|
1148
|
+
<BbButton
|
|
1149
|
+
append:icon="lucide:arrow-up-right"
|
|
1150
|
+
size="sm"
|
|
1151
|
+
to="/customers"
|
|
1152
|
+
variant="link"
|
|
1153
|
+
>
|
|
1154
|
+
View customers
|
|
1155
|
+
</BbButton>
|
|
1156
|
+
</div>
|
|
1157
|
+
|
|
1158
|
+
<template v-else>
|
|
1159
|
+
<!-- MIME + extension pairing: Excel exports often carry a non-CSV MIME
|
|
1160
|
+
type (or none at all on drag-drop) — '.csv' is what admits them. -->
|
|
1161
|
+
<BbDropzone
|
|
1162
|
+
v-model="file"
|
|
1163
|
+
:accept="['text/csv', '.csv']"
|
|
1164
|
+
:disabled="ctx.importState.uploading"
|
|
1165
|
+
:errors="fileError"
|
|
1166
|
+
:max-size="10 * 1024 * 1024"
|
|
1167
|
+
@error="onReject"
|
|
1168
|
+
>
|
|
1169
|
+
<template #default="{ dragging, focused, open }">
|
|
1170
|
+
<div
|
|
1171
|
+
class="flex flex-col items-center gap-2 rounded-[var(--bb-radius)] border-2 border-dashed p-6 text-center transition-colors"
|
|
1172
|
+
:class="[
|
|
1173
|
+
dragging
|
|
1174
|
+
? 'border-[color:var(--bb-primary)] bg-[color:var(--bb-panel)]'
|
|
1175
|
+
: '',
|
|
1176
|
+
focused ? 'ring-2 ring-[color:var(--bb-ring)]' : '',
|
|
1177
|
+
]"
|
|
1178
|
+
>
|
|
1179
|
+
<BbIcon
|
|
1180
|
+
class="text-gray-400"
|
|
1181
|
+
icon="lucide:file-spreadsheet"
|
|
1182
|
+
size="24"
|
|
1183
|
+
/>
|
|
1184
|
+
<p class="font-medium">
|
|
1185
|
+
{{
|
|
1186
|
+
dragging ? 'Drop your CSV here' : 'Drag your customers CSV here'
|
|
1187
|
+
}}
|
|
1188
|
+
</p>
|
|
1189
|
+
<p class="text-xs text-gray-500">
|
|
1190
|
+
We map name, email, VAT number and address columns. Up to 10 MB.
|
|
1191
|
+
</p>
|
|
1192
|
+
<BbButton size="sm" variant="ghost" @click="open"
|
|
1193
|
+
>or browse files</BbButton
|
|
1194
|
+
>
|
|
1195
|
+
</div>
|
|
1196
|
+
</template>
|
|
1197
|
+
</BbDropzone>
|
|
1198
|
+
|
|
1199
|
+
<!-- Captured, not yet imported: confirm before touching the workspace. -->
|
|
1200
|
+
<div v-if="file" class="flex items-center gap-2">
|
|
1201
|
+
<BbIcon
|
|
1202
|
+
class="shrink-0 text-gray-400"
|
|
1203
|
+
icon="lucide:file-text"
|
|
1204
|
+
size="16"
|
|
1205
|
+
/>
|
|
1206
|
+
<span class="min-w-0 flex-1 truncate">
|
|
1207
|
+
{{ file.name }}
|
|
1208
|
+
<span class="text-xs text-gray-500"
|
|
1209
|
+
>· {{ formatSize(file.size) }}</span
|
|
1210
|
+
>
|
|
1211
|
+
</span>
|
|
1212
|
+
<BbButton
|
|
1213
|
+
aria-label="Remove selected file"
|
|
1214
|
+
:disabled="ctx.importState.uploading"
|
|
1215
|
+
icon="lucide:x"
|
|
1216
|
+
size="sm"
|
|
1217
|
+
variant="ghost"
|
|
1218
|
+
@click="() => (file = null)"
|
|
1219
|
+
/>
|
|
1220
|
+
<BbButton
|
|
1221
|
+
:disabled="ctx.importState.uploading"
|
|
1222
|
+
prepend:icon="lucide:upload"
|
|
1223
|
+
variant="secondary"
|
|
1224
|
+
@click="startImport"
|
|
1225
|
+
>
|
|
1226
|
+
Import customers
|
|
1227
|
+
</BbButton>
|
|
1228
|
+
</div>
|
|
1229
|
+
|
|
1230
|
+
<!-- The dropzone captures; the context uploads and drives the bar. -->
|
|
1231
|
+
<div v-if="ctx.importState.uploading" class="flex flex-col gap-1">
|
|
1232
|
+
<BbProgress
|
|
1233
|
+
aria-label="Upload progress"
|
|
1234
|
+
:max="ctx.importState.totalBytes"
|
|
1235
|
+
:model-value="ctx.importState.sentBytes"
|
|
1236
|
+
/>
|
|
1237
|
+
<span class="text-xs text-gray-500">
|
|
1238
|
+
Uploading… {{ formatSize(ctx.importState.sentBytes) }} of
|
|
1239
|
+
{{ formatSize(ctx.importState.totalBytes) }}
|
|
1240
|
+
</span>
|
|
1241
|
+
</div>
|
|
1242
|
+
</template>
|
|
1243
|
+
</div>
|
|
1244
|
+
</template>
|
|
1245
|
+
|
|
1246
|
+
<script setup lang="ts">
|
|
1247
|
+
import { ref } from 'vue';
|
|
1248
|
+
import { BbButton, BbDropzone, BbIcon, BbProgress } from 'bitboss-ui';
|
|
1249
|
+
import type { DropZoneError } from 'bitboss-ui';
|
|
1250
|
+
import { useOnboardingWorkspace } from './context';
|
|
1251
|
+
|
|
1252
|
+
const ctx = useOnboardingWorkspace();
|
|
1253
|
+
|
|
1254
|
+
// The captured-but-not-imported file is this leaf's own state.
|
|
1255
|
+
const file = ref<File | null>(null);
|
|
1256
|
+
const fileError = ref('');
|
|
1257
|
+
|
|
1258
|
+
// Rejects never reach the model — map the typed error to a message and feed
|
|
1259
|
+
// it back through `errors` (the display is a round-trip, not automatic).
|
|
1260
|
+
const onReject = (error: DropZoneError) => {
|
|
1261
|
+
fileError.value =
|
|
1262
|
+
error.type === 'maxSize'
|
|
1263
|
+
? `${error.filename} is ${error.formattedSize} — the limit is ${error.formattedMaxSize}.`
|
|
1264
|
+
: error.type === 'accept'
|
|
1265
|
+
? `${error.filename} is not a CSV file.`
|
|
1266
|
+
: `${error.filename} was rejected.`;
|
|
1267
|
+
};
|
|
1268
|
+
|
|
1269
|
+
const startImport = async () => {
|
|
1270
|
+
if (!file.value) return;
|
|
1271
|
+
fileError.value = '';
|
|
1272
|
+
await ctx.importCustomers(file.value);
|
|
1273
|
+
file.value = null;
|
|
1274
|
+
};
|
|
1275
|
+
|
|
1276
|
+
const formatSize = (bytes: number) =>
|
|
1277
|
+
bytes >= 1024 * 1024
|
|
1278
|
+
? `${(bytes / 1024 / 1024).toFixed(1)} MB`
|
|
1279
|
+
: `${Math.max(1, Math.round(bytes / 1024))} KB`;
|
|
1280
|
+
</script>
|
|
1281
|
+
```
|
|
1282
|
+
|
|
1283
|
+
### FirstInvoiceStep.vue
|
|
1284
|
+
|
|
1285
|
+
```vue
|
|
1286
|
+
<!-- OnboardingChecklist/FirstInvoiceStep.vue -->
|
|
1287
|
+
<template>
|
|
1288
|
+
<div class="flex flex-col gap-3 text-sm">
|
|
1289
|
+
<p class="text-gray-600">
|
|
1290
|
+
The composer walks you through line items, taxes and payment terms. Every
|
|
1291
|
+
invoice goes out with a payment link — customers pay by card or bank
|
|
1292
|
+
transfer without creating an account. This step checks itself off when
|
|
1293
|
+
your first invoice is sent.
|
|
1294
|
+
</p>
|
|
1295
|
+
<div>
|
|
1296
|
+
<BbButton
|
|
1297
|
+
append:icon="lucide:arrow-up-right"
|
|
1298
|
+
prepend:icon="lucide:receipt"
|
|
1299
|
+
to="/invoices/create"
|
|
1300
|
+
variant="outline"
|
|
1301
|
+
>
|
|
1302
|
+
Open the invoice composer
|
|
1303
|
+
</BbButton>
|
|
1304
|
+
</div>
|
|
1305
|
+
</div>
|
|
1306
|
+
</template>
|
|
1307
|
+
|
|
1308
|
+
<script setup lang="ts">
|
|
1309
|
+
import { BbButton } from 'bitboss-ui';
|
|
1310
|
+
</script>
|
|
1311
|
+
```
|
|
1312
|
+
|
|
1313
|
+
### RemindersStep.vue
|
|
1314
|
+
|
|
1315
|
+
```vue
|
|
1316
|
+
<!-- OnboardingChecklist/RemindersStep.vue -->
|
|
1317
|
+
<template>
|
|
1318
|
+
<div class="flex flex-col gap-3 text-sm">
|
|
1319
|
+
<!-- Instant-effect switch: the context applies optimistically and reverts
|
|
1320
|
+
with a toast if the server rejects the change. -->
|
|
1321
|
+
<BbSwitch
|
|
1322
|
+
description="Email customers automatically when an invoice goes overdue. Replies land in your inbox."
|
|
1323
|
+
label="Automatic payment reminders"
|
|
1324
|
+
:model-value="ctx.reminders.enabled"
|
|
1325
|
+
name="payment-reminders"
|
|
1326
|
+
@update:model-value="(next) => ctx.setReminders(next)"
|
|
1327
|
+
/>
|
|
1328
|
+
<BbSelect
|
|
1329
|
+
v-if="ctx.reminders.enabled"
|
|
1330
|
+
class="max-w-72"
|
|
1331
|
+
compact
|
|
1332
|
+
item-text="label"
|
|
1333
|
+
item-value="value"
|
|
1334
|
+
:items="cadences"
|
|
1335
|
+
label="Reminder schedule"
|
|
1336
|
+
label-mode="outside"
|
|
1337
|
+
:model-value="ctx.reminders.cadence"
|
|
1338
|
+
@update:model-value="(cadence) => ctx.setReminderCadence(cadence)"
|
|
1339
|
+
/>
|
|
1340
|
+
</div>
|
|
1341
|
+
</template>
|
|
1342
|
+
|
|
1343
|
+
<script setup lang="ts">
|
|
1344
|
+
import { BbSelect, BbSwitch } from 'bitboss-ui';
|
|
1345
|
+
import { useOnboardingWorkspace } from './context';
|
|
1346
|
+
import type { ReminderCadence } from '@/types';
|
|
1347
|
+
|
|
1348
|
+
const ctx = useOnboardingWorkspace();
|
|
1349
|
+
|
|
1350
|
+
const cadences: { value: ReminderCadence; label: string }[] = [
|
|
1351
|
+
{ value: '3-7-14', label: '3, 7 and 14 days overdue' },
|
|
1352
|
+
{ value: '7', label: '7 days overdue' },
|
|
1353
|
+
{ value: '7-30', label: '7 and 30 days overdue' },
|
|
1354
|
+
];
|
|
1355
|
+
</script>
|
|
1356
|
+
```
|
|
1357
|
+
|
|
1358
|
+
### StepPreviewPeek.vue
|
|
1359
|
+
|
|
1360
|
+
```vue
|
|
1361
|
+
<!-- OnboardingChecklist/StepPreviewPeek.vue -->
|
|
1362
|
+
<template>
|
|
1363
|
+
<div class="flex flex-col gap-4 text-sm">
|
|
1364
|
+
<!-- Identity header. -->
|
|
1365
|
+
<header class="flex items-center gap-3">
|
|
1366
|
+
<span
|
|
1367
|
+
class="flex h-9 w-9 shrink-0 items-center justify-center rounded-[var(--bb-radius)] border"
|
|
1368
|
+
>
|
|
1369
|
+
<BbIcon :icon="preview.icon" size="18" />
|
|
1370
|
+
</span>
|
|
1371
|
+
<div class="flex min-w-0 flex-col">
|
|
1372
|
+
<h2 class="text-base font-semibold">{{ preview.title }}</h2>
|
|
1373
|
+
<p class="text-xs text-gray-500">{{ preview.tagline }}</p>
|
|
1374
|
+
</div>
|
|
1375
|
+
</header>
|
|
1376
|
+
|
|
1377
|
+
<p
|
|
1378
|
+
v-if="step.status !== 'todo'"
|
|
1379
|
+
class="flex items-center gap-1.5 text-xs text-gray-500"
|
|
1380
|
+
>
|
|
1381
|
+
<!-- Green is earned: skipped reads as reached-but-unmeasured, not done. -->
|
|
1382
|
+
<BbIcon
|
|
1383
|
+
:class="step.status === 'complete' ? 'text-green-600' : 'text-gray-400'"
|
|
1384
|
+
icon="lucide:circle-check"
|
|
1385
|
+
size="14"
|
|
1386
|
+
/>
|
|
1387
|
+
{{
|
|
1388
|
+
step.status === 'complete'
|
|
1389
|
+
? 'Already done in this workspace.'
|
|
1390
|
+
: 'Skipped — you can still set it up.'
|
|
1391
|
+
}}
|
|
1392
|
+
</p>
|
|
1393
|
+
|
|
1394
|
+
<!-- What you'll get. -->
|
|
1395
|
+
<section class="flex flex-col gap-2.5">
|
|
1396
|
+
<h3 class="text-xs font-semibold uppercase tracking-wide text-gray-500">
|
|
1397
|
+
What you'll get
|
|
1398
|
+
</h3>
|
|
1399
|
+
<ul class="flex flex-col gap-2.5">
|
|
1400
|
+
<li
|
|
1401
|
+
v-for="bullet in preview.bullets"
|
|
1402
|
+
:key="bullet.title"
|
|
1403
|
+
class="flex gap-2"
|
|
1404
|
+
>
|
|
1405
|
+
<BbIcon
|
|
1406
|
+
class="mt-0.5 shrink-0 text-gray-400"
|
|
1407
|
+
:icon="bullet.icon"
|
|
1408
|
+
size="14"
|
|
1409
|
+
/>
|
|
1410
|
+
<div class="flex flex-col">
|
|
1411
|
+
<span class="font-medium">{{ bullet.title }}</span>
|
|
1412
|
+
<span class="text-xs text-gray-500">{{ bullet.text }}</span>
|
|
1413
|
+
</div>
|
|
1414
|
+
</li>
|
|
1415
|
+
</ul>
|
|
1416
|
+
</section>
|
|
1417
|
+
|
|
1418
|
+
<!-- One concrete number beats three adjectives. -->
|
|
1419
|
+
<div class="rounded-[var(--bb-radius)] border p-3">
|
|
1420
|
+
<p class="text-lg font-semibold">{{ preview.stat.value }}</p>
|
|
1421
|
+
<p class="text-xs text-gray-500">{{ preview.stat.label }}</p>
|
|
1422
|
+
</div>
|
|
1423
|
+
|
|
1424
|
+
<footer class="mt-2 flex items-center gap-2 border-t pt-3">
|
|
1425
|
+
<BbButton
|
|
1426
|
+
v-if="step.status === 'todo'"
|
|
1427
|
+
prepend:icon="lucide:check"
|
|
1428
|
+
variant="secondary"
|
|
1429
|
+
@click="() => ctx.jumpToStep(stepId)"
|
|
1430
|
+
>
|
|
1431
|
+
Set it up now
|
|
1432
|
+
</BbButton>
|
|
1433
|
+
<BbButton v-else variant="ghost" @click="() => ctx.jumpToStep(stepId)">
|
|
1434
|
+
Review this step
|
|
1435
|
+
</BbButton>
|
|
1436
|
+
</footer>
|
|
1437
|
+
</div>
|
|
1438
|
+
</template>
|
|
1439
|
+
|
|
1440
|
+
<script setup lang="ts">
|
|
1441
|
+
import { computed } from 'vue';
|
|
1442
|
+
import { BbButton, BbIcon } from 'bitboss-ui';
|
|
1443
|
+
import { useOnboardingWorkspace, type StepId } from './context';
|
|
1444
|
+
|
|
1445
|
+
const props = defineProps<{ stepId: StepId }>();
|
|
1446
|
+
|
|
1447
|
+
const ctx = useOnboardingWorkspace();
|
|
1448
|
+
|
|
1449
|
+
const step = computed(
|
|
1450
|
+
() => ctx.steps.find((candidate) => candidate.id === props.stepId)!
|
|
1451
|
+
);
|
|
1452
|
+
const preview = computed(() => previews[props.stepId]);
|
|
1453
|
+
|
|
1454
|
+
interface StepPreview {
|
|
1455
|
+
icon: string;
|
|
1456
|
+
title: string;
|
|
1457
|
+
tagline: string;
|
|
1458
|
+
bullets: { icon: string; title: string; text: string }[];
|
|
1459
|
+
stat: { value: string; label: string };
|
|
1460
|
+
}
|
|
1461
|
+
|
|
1462
|
+
// Presentation content with a single consumer: it lives in the leaf, not the
|
|
1463
|
+
// context. Icon names are full static literals for the production scanner.
|
|
1464
|
+
const previews: Record<StepId, StepPreview> = {
|
|
1465
|
+
profile: {
|
|
1466
|
+
icon: 'lucide:building-2',
|
|
1467
|
+
title: 'A complete company profile',
|
|
1468
|
+
tagline: 'Set once, printed on every document.',
|
|
1469
|
+
bullets: [
|
|
1470
|
+
{
|
|
1471
|
+
icon: 'lucide:file-text',
|
|
1472
|
+
title: 'Compliant invoices',
|
|
1473
|
+
text: 'Legal name, address and tax ID appear on every PDF automatically.',
|
|
1474
|
+
},
|
|
1475
|
+
{
|
|
1476
|
+
icon: 'lucide:euro',
|
|
1477
|
+
title: 'One currency for the books',
|
|
1478
|
+
text: 'Amounts, totals and reports all use your workspace currency.',
|
|
1479
|
+
},
|
|
1480
|
+
],
|
|
1481
|
+
stat: {
|
|
1482
|
+
value: '2 min',
|
|
1483
|
+
label: 'to update it later under Settings → General',
|
|
1484
|
+
},
|
|
1485
|
+
},
|
|
1486
|
+
integrations: {
|
|
1487
|
+
icon: 'lucide:link',
|
|
1488
|
+
title: 'Your tools, wired together',
|
|
1489
|
+
tagline:
|
|
1490
|
+
'Payments, accounting and alerts stop being three separate chores.',
|
|
1491
|
+
bullets: [
|
|
1492
|
+
{
|
|
1493
|
+
icon: 'lucide:credit-card',
|
|
1494
|
+
title: 'Payments reconcile themselves',
|
|
1495
|
+
text: 'Stripe payouts are matched against open invoices automatically.',
|
|
1496
|
+
},
|
|
1497
|
+
{
|
|
1498
|
+
icon: 'lucide:receipt',
|
|
1499
|
+
title: 'Books stay current',
|
|
1500
|
+
text: 'Paid invoices flow into QuickBooks the moment they settle.',
|
|
1501
|
+
},
|
|
1502
|
+
{
|
|
1503
|
+
icon: 'lucide:bell',
|
|
1504
|
+
title: 'The team finds out in Slack',
|
|
1505
|
+
text: '#finance gets a message on every paid and overdue invoice.',
|
|
1506
|
+
},
|
|
1507
|
+
],
|
|
1508
|
+
stat: {
|
|
1509
|
+
value: '9 days',
|
|
1510
|
+
label: 'faster average payment for teams with Stripe connected',
|
|
1511
|
+
},
|
|
1512
|
+
},
|
|
1513
|
+
invites: {
|
|
1514
|
+
icon: 'lucide:users',
|
|
1515
|
+
title: 'Everyone on the same numbers',
|
|
1516
|
+
tagline: 'Roles keep access right-sized from day one.',
|
|
1517
|
+
bullets: [
|
|
1518
|
+
{
|
|
1519
|
+
icon: 'lucide:user-plus',
|
|
1520
|
+
title: 'Sign-in with work email',
|
|
1521
|
+
text: 'Invitees join with their address — no shared passwords.',
|
|
1522
|
+
},
|
|
1523
|
+
{
|
|
1524
|
+
icon: 'lucide:key-round',
|
|
1525
|
+
title: 'Permissions per role',
|
|
1526
|
+
text: 'Accountants see reports; members see their own projects.',
|
|
1527
|
+
},
|
|
1528
|
+
{
|
|
1529
|
+
icon: 'lucide:clock',
|
|
1530
|
+
title: 'Invitations expire safely',
|
|
1531
|
+
text: 'Unaccepted invites lapse after 7 days and can be re-sent.',
|
|
1532
|
+
},
|
|
1533
|
+
],
|
|
1534
|
+
stat: { value: '10', label: 'invitations per batch' },
|
|
1535
|
+
},
|
|
1536
|
+
'first-project': {
|
|
1537
|
+
icon: 'lucide:folder',
|
|
1538
|
+
title: 'A home for each client',
|
|
1539
|
+
tagline: 'Projects keep invoices, budgets and time in one place.',
|
|
1540
|
+
bullets: [
|
|
1541
|
+
{
|
|
1542
|
+
icon: 'lucide:folder-open',
|
|
1543
|
+
title: 'Everything grouped',
|
|
1544
|
+
text: 'Invoices, budgets and time entries organized per client.',
|
|
1545
|
+
},
|
|
1546
|
+
{
|
|
1547
|
+
icon: 'lucide:chart-line',
|
|
1548
|
+
title: 'Profitability from day one',
|
|
1549
|
+
text: 'A per-project margin view as soon as the first invoice is paid.',
|
|
1550
|
+
},
|
|
1551
|
+
],
|
|
1552
|
+
stat: {
|
|
1553
|
+
value: '3',
|
|
1554
|
+
label: 'projects created by the average team in week one',
|
|
1555
|
+
},
|
|
1556
|
+
},
|
|
1557
|
+
'import-customers': {
|
|
1558
|
+
icon: 'lucide:file-spreadsheet',
|
|
1559
|
+
title: 'Your customer list, moved over',
|
|
1560
|
+
tagline: 'The CSV you already have is enough.',
|
|
1561
|
+
bullets: [
|
|
1562
|
+
{
|
|
1563
|
+
icon: 'lucide:upload',
|
|
1564
|
+
title: 'Columns mapped for you',
|
|
1565
|
+
text: 'Name, email, VAT number and address are detected automatically.',
|
|
1566
|
+
},
|
|
1567
|
+
{
|
|
1568
|
+
icon: 'lucide:check',
|
|
1569
|
+
title: 'No double imports',
|
|
1570
|
+
text: 'Rows are merged by email — re-running an import never duplicates.',
|
|
1571
|
+
},
|
|
1572
|
+
],
|
|
1573
|
+
stat: { value: '5,000', label: 'rows per import' },
|
|
1574
|
+
},
|
|
1575
|
+
'first-invoice': {
|
|
1576
|
+
icon: 'lucide:receipt',
|
|
1577
|
+
title: 'Your first invoice, out the door',
|
|
1578
|
+
tagline: 'Composed, sent and tracked in one flow.',
|
|
1579
|
+
bullets: [
|
|
1580
|
+
{
|
|
1581
|
+
icon: 'lucide:send',
|
|
1582
|
+
title: 'Sent from your domain',
|
|
1583
|
+
text: 'Invoices arrive from billing@your-company, not a noreply void.',
|
|
1584
|
+
},
|
|
1585
|
+
{
|
|
1586
|
+
icon: 'lucide:banknote',
|
|
1587
|
+
title: 'Payment link included',
|
|
1588
|
+
text: 'Customers pay by card or bank transfer without an account.',
|
|
1589
|
+
},
|
|
1590
|
+
{
|
|
1591
|
+
icon: 'lucide:clock',
|
|
1592
|
+
title: 'Overdue tracking starts itself',
|
|
1593
|
+
text: 'Due dates and aging are tracked from the moment you hit send.',
|
|
1594
|
+
},
|
|
1595
|
+
],
|
|
1596
|
+
stat: {
|
|
1597
|
+
value: '2×',
|
|
1598
|
+
label: 'faster payment on invoices with a payment link',
|
|
1599
|
+
},
|
|
1600
|
+
},
|
|
1601
|
+
reminders: {
|
|
1602
|
+
icon: 'lucide:bell',
|
|
1603
|
+
title: 'Overdue chasing, automated',
|
|
1604
|
+
tagline: 'Polite nudges on a schedule you choose.',
|
|
1605
|
+
bullets: [
|
|
1606
|
+
{
|
|
1607
|
+
icon: 'lucide:clock',
|
|
1608
|
+
title: 'A schedule, not a scramble',
|
|
1609
|
+
text: 'Reminders at 3, 7 and 14 days overdue — or the cadence you pick.',
|
|
1610
|
+
},
|
|
1611
|
+
{
|
|
1612
|
+
icon: 'lucide:mail',
|
|
1613
|
+
title: 'Replies reach a human',
|
|
1614
|
+
text: 'Customers answer straight into your inbox thread.',
|
|
1615
|
+
},
|
|
1616
|
+
],
|
|
1617
|
+
stat: {
|
|
1618
|
+
value: '38%',
|
|
1619
|
+
label: 'fewer invoices reach 30 days overdue with reminders on',
|
|
1620
|
+
},
|
|
1621
|
+
},
|
|
1622
|
+
};
|
|
1623
|
+
</script>
|
|
1624
|
+
```
|
|
1625
|
+
|
|
1626
|
+
## Why it is built this way
|
|
1627
|
+
|
|
1628
|
+
- **The context coopts the shell, leaves consume.** The only specific
|
|
1629
|
+
context on a checklist page is the peek stack; `provideOnboardingWorkspace()`
|
|
1630
|
+
joins it once and thirteen components share step state, integration
|
|
1631
|
+
state and every action through one `useOnboardingWorkspace()` call. No
|
|
1632
|
+
component receives a callback prop; the only data props are the `step` /
|
|
1633
|
+
`stepId` an item renders (`StepHeader`, `StepActions`, `StepPreviewPeek`)
|
|
1634
|
+
— everything else is injection.
|
|
1635
|
+
- **One fetch, one refresh path.** `useAsyncData('onboarding', …)` loads the
|
|
1636
|
+
whole checklist once; `persistStatus` is the single place that `$fetch`s a
|
|
1637
|
+
mutation and calls `refresh()` — a `watch(data, …, { immediate: true })`
|
|
1638
|
+
re-seeds every local field from the fresh response, so `steps`,
|
|
1639
|
+
`integrations`, `invites`, `firstProject` and `reminders` can never drift
|
|
1640
|
+
from what the server actually persisted.
|
|
1641
|
+
- **Single-open is one key, per the BbAccordion doctrine.** `BbAccordion`
|
|
1642
|
+
is deliberately one panel per boolean with no group wrapper; the
|
|
1643
|
+
`activeStep` key derives each `model-value`, the `update:modelValue`
|
|
1644
|
+
payload (`false` on closing the open header) resets it to `null`, and
|
|
1645
|
+
`openNextTodo` gives the Linear feel of the checklist walking itself
|
|
1646
|
+
forward. No watchers force-closing siblings.
|
|
1647
|
+
- **Headers stay passive, actions live in the body.** The accordion header
|
|
1648
|
+
is already a `<button>`; the status icon, minutes estimate and chevron in
|
|
1649
|
+
`StepHeader` are click-transparent metadata. Everything interactive —
|
|
1650
|
+
done, skip, preview, the step's real controls — is body content, so the
|
|
1651
|
+
markup stays valid and the click target stays whole.
|
|
1652
|
+
- **`ofetch` has no upload-progress hook.** Every mutation on this page is a
|
|
1653
|
+
plain `$fetch` except the CSV import, which needs real bytes for
|
|
1654
|
+
`BbProgress` — that one call drops to a raw `XMLHttpRequest` wrapped in a
|
|
1655
|
+
promise. It is the only exception, called out explicitly so it doesn't
|
|
1656
|
+
read as an inconsistency.
|
|
1657
|
+
- **Every rung of the state ladder is deliberate.** Draft state one leaf
|
|
1658
|
+
touches is a local ref (invite emails and role, the project draft, the
|
|
1659
|
+
captured CSV file, the reject message); everything two components read
|
|
1660
|
+
sits on the context (statuses, `importState` driving `BbProgress`,
|
|
1661
|
+
reminders); nothing on this page outlives it, so no store is involved.
|
|
1662
|
+
- **The switch promise is kept.** Integration and reminder toggles apply
|
|
1663
|
+
optimistically, hold the control `readonly` while the request flies, and
|
|
1664
|
+
revert with a `destructive` toast on failure — the async-save pattern
|
|
1665
|
+
from the BbSwitch guide, owned by context actions so no leaf ever talks
|
|
1666
|
+
to `$fetch` or toasts on its own.
|
|
1667
|
+
- **The dropzone captures; the context uploads.** `BbDropzone` has no
|
|
1668
|
+
request surface by design: the leaf holds the captured `File`, maps the
|
|
1669
|
+
typed `@error` union back through `errors` (the display round-trip), and
|
|
1670
|
+
`importCustomers` drives `BbProgress` from real bytes — `max` is the file
|
|
1671
|
+
size, never a pre-computed percentage.
|
|
1672
|
+
- **Previews are peeks, not dialogs.** "See what you'll get" is the
|
|
1673
|
+
checklist's version of clicking a record's name: `previewStep` pushes
|
|
1674
|
+
onto the coopted shell stack with `replace` (previews never stack), and
|
|
1675
|
+
`jumpToStep` owns the way back — leaves never touch the stack grammar
|
|
1676
|
+
directly.
|
|
1677
|
+
- **Sizing and variants:** `md`-first throughout the bodies (28px buttons
|
|
1678
|
+
flush beside `compact` inputs in the invite and project rows); `sm` only
|
|
1679
|
+
for genuinely dense spots (inline links, the file-row remove); exactly
|
|
1680
|
+
one `variant="primary"` (Go to dashboard); step submits are `secondary`;
|
|
1681
|
+
dismissal is a ghost gated by a `destructive` `useConfirm`.
|
|
1682
|
+
|
|
1683
|
+
## Variations
|
|
1684
|
+
|
|
1685
|
+
- **Personal onboarding**: scope statuses per user instead of per
|
|
1686
|
+
workspace (`$fetch('/api/onboarding', { query: { scope: 'user' } })`)
|
|
1687
|
+
and drop the workspace-wide dismiss confirm copy; the page shape is
|
|
1688
|
+
unchanged.
|
|
1689
|
+
- **Sequential (gated) steps**: lock each accordion until the previous
|
|
1690
|
+
step is done by rendering the body's controls `disabled` with an
|
|
1691
|
+
explanatory line; for hard gates with per-step validation, the
|
|
1692
|
+
wizard-form recipe is the full treatment.
|
|
1693
|
+
- **Preview follows the open step**: call `previewStep(id)` from
|
|
1694
|
+
`openStep` so the sidebar always previews the active step; keep the
|
|
1695
|
+
explicit footer button for touch users.
|
|
1696
|
+
- **All-done celebration**: when `allDone` flips, swap `ProgressHeader`'s
|
|
1697
|
+
copy block for a success panel with the dashboard CTA and a "book an
|
|
1698
|
+
onboarding call" link.
|