@flux-ui/components 3.0.0-next.58 → 3.0.0-next.59
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/dist/component/FluxButtonStack.vue.d.ts +1 -1
- package/dist/component/FluxCalendar.vue.d.ts +63 -2
- package/dist/component/{FluxCalendarEvent.vue.d.ts → FluxCalendarItem.vue.d.ts} +9 -7
- package/dist/component/FluxClickablePane.vue.d.ts +1 -1
- package/dist/component/FluxDivider.vue.d.ts +1 -1
- package/dist/component/FluxFilter.vue.d.ts +1 -1
- package/dist/component/FluxFilterBar.vue.d.ts +1 -1
- package/dist/component/FluxFormInput.vue.d.ts +2 -2
- package/dist/component/FluxFormInputAddition.vue.d.ts +1 -1
- package/dist/component/FluxFormTreeViewSelect.vue.d.ts +3 -3
- package/dist/component/FluxGallery.vue.d.ts +1 -1
- package/dist/component/FluxInfo.vue.d.ts +1 -1
- package/dist/component/FluxKanbanColumn.vue.d.ts +2 -2
- package/dist/component/{FluxKanbanCard.vue.d.ts → FluxKanbanItem.vue.d.ts} +1 -1
- package/dist/component/FluxMenuItem.vue.d.ts +1 -1
- package/dist/component/FluxNotice.vue.d.ts +1 -1
- package/dist/component/FluxPaneHeader.vue.d.ts +1 -1
- package/dist/component/FluxPressable.vue.d.ts +1 -1
- package/dist/component/FluxPrompt.vue.d.ts +3 -3
- package/dist/component/FluxSplitButton.vue.d.ts +1 -1
- package/dist/component/FluxStack.vue.d.ts +1 -1
- package/dist/component/FluxTab.vue.d.ts +1 -1
- package/dist/component/FluxTabBar.vue.d.ts +4 -1
- package/dist/component/FluxTabs.vue.d.ts +4 -1
- package/dist/component/FluxTimelineItem.vue.d.ts +1 -1
- package/dist/component/calendar/FluxCalendarItemDisplay.vue.d.ts +9 -0
- package/dist/component/calendar/FluxCalendarMonthView.vue.d.ts +19 -0
- package/dist/component/calendar/FluxCalendarTimeGridView.vue.d.ts +36 -0
- package/dist/component/calendar/index.d.ts +3 -0
- package/dist/component/index.d.ts +2 -2
- package/dist/component/primitive/DialogLayout.vue.d.ts +1 -1
- package/dist/component/primitive/SelectBase.vue.d.ts +3 -3
- package/dist/composable/index.d.ts +3 -0
- package/dist/composable/private/index.d.ts +5 -8
- package/dist/composable/private/useKanban.d.ts +2 -2
- package/dist/composable/private/useKanbanAutoScroll.d.ts +13 -0
- package/dist/composable/useCalendarInjection.d.ts +2 -0
- package/dist/composable/useKanbanInjection.d.ts +2 -0
- package/dist/composable/useTabBarInjection.d.ts +2 -0
- package/dist/data/di.d.ts +54 -12
- package/dist/data/i18n.d.ts +4 -0
- package/dist/index.css +1500 -1221
- package/dist/index.js +9339 -8216
- package/dist/index.js.map +1 -1
- package/package.json +6 -6
- package/src/component/FluxAction.vue +1 -1
- package/src/component/FluxActionBar.vue +2 -2
- package/src/component/FluxActionPane.vue +1 -1
- package/src/component/FluxAdaptiveGroup.vue +2 -2
- package/src/component/FluxAdaptiveSlot.vue +2 -2
- package/src/component/FluxAlert.vue +1 -1
- package/src/component/FluxAnimatedColors.vue +1 -1
- package/src/component/FluxAspectRatio.vue +1 -1
- package/src/component/FluxAvatar.vue +2 -2
- package/src/component/FluxBadge.vue +2 -2
- package/src/component/FluxBorderShine.vue +1 -1
- package/src/component/FluxBoxedIcon.vue +1 -1
- package/src/component/FluxButton.vue +2 -2
- package/src/component/FluxButtonGroup.vue +1 -1
- package/src/component/FluxButtonStack.vue +1 -1
- package/src/component/FluxCalendar.vue +588 -179
- package/src/component/FluxCalendarItem.vue +79 -0
- package/src/component/FluxCheckbox.vue +2 -2
- package/src/component/FluxChip.vue +2 -2
- package/src/component/FluxClickablePane.vue +2 -2
- package/src/component/FluxColorPicker.vue +2 -2
- package/src/component/FluxColorSelect.vue +3 -3
- package/src/component/FluxColumn.vue +1 -1
- package/src/component/FluxCommandPalette.vue +4 -4
- package/src/component/FluxCommandPaletteGroup.vue +1 -1
- package/src/component/FluxCommandPaletteItem.vue +1 -1
- package/src/component/FluxComment.vue +2 -2
- package/src/component/FluxConfirm.vue +1 -1
- package/src/component/FluxContainer.vue +1 -1
- package/src/component/FluxDataTable.vue +1 -2
- package/src/component/FluxDatePicker.vue +3 -3
- package/src/component/FluxDestructiveButton.vue +1 -1
- package/src/component/FluxDisabled.vue +1 -1
- package/src/component/FluxDivider.vue +2 -2
- package/src/component/FluxDotPattern.vue +1 -1
- package/src/component/FluxDropZone.vue +4 -4
- package/src/component/FluxExpandable.vue +3 -3
- package/src/component/FluxExpandableGroup.vue +2 -2
- package/src/component/FluxFader.vue +1 -1
- package/src/component/FluxFaderItem.vue +1 -1
- package/src/component/FluxFilter.vue +2 -2
- package/src/component/FluxFilterBar.vue +5 -6
- package/src/component/FluxFilterBase.vue +2 -2
- package/src/component/FluxFilterDate.vue +2 -2
- package/src/component/FluxFilterDateRange.vue +2 -2
- package/src/component/FluxFilterOption.vue +2 -2
- package/src/component/FluxFilterOptionAsync.vue +1 -1
- package/src/component/FluxFilterOptions.vue +2 -2
- package/src/component/FluxFilterOptionsAsync.vue +1 -1
- package/src/component/FluxFilterRange.vue +2 -2
- package/src/component/FluxFilterWindow.vue +3 -3
- package/src/component/FluxFlickeringGrid.vue +1 -1
- package/src/component/FluxFlyout.vue +2 -2
- package/src/component/FluxFocalPointEditor.vue +3 -3
- package/src/component/FluxFocalPointImage.vue +1 -1
- package/src/component/FluxForm.vue +1 -1
- package/src/component/FluxFormColumn.vue +1 -1
- package/src/component/FluxFormDateInput.vue +3 -3
- package/src/component/FluxFormDateRangeInput.vue +4 -4
- package/src/component/FluxFormDateTimeInput.vue +3 -3
- package/src/component/FluxFormField.vue +3 -3
- package/src/component/FluxFormFieldAddition.vue +1 -1
- package/src/component/FluxFormGrid.vue +1 -1
- package/src/component/FluxFormInput.vue +3 -3
- package/src/component/FluxFormInputAddition.vue +2 -2
- package/src/component/FluxFormInputGroup.vue +2 -2
- package/src/component/FluxFormPinInput.vue +3 -3
- package/src/component/FluxFormRangeSlider.vue +3 -3
- package/src/component/FluxFormRow.vue +1 -1
- package/src/component/FluxFormSection.vue +1 -1
- package/src/component/FluxFormSelect.vue +4 -4
- package/src/component/FluxFormSelectAsync.vue +6 -6
- package/src/component/FluxFormSlider.vue +2 -2
- package/src/component/FluxFormTextArea.vue +2 -2
- package/src/component/FluxFormTimeZonePicker.vue +4 -4
- package/src/component/FluxFormTreeViewSelect.vue +9 -12
- package/src/component/FluxGallery.vue +3 -3
- package/src/component/FluxGalleryItem.vue +1 -1
- package/src/component/FluxGrid.vue +1 -1
- package/src/component/FluxGridColumn.vue +1 -1
- package/src/component/FluxGridPattern.vue +1 -1
- package/src/component/FluxIcon.vue +2 -2
- package/src/component/FluxInfo.vue +2 -2
- package/src/component/FluxItem.vue +1 -1
- package/src/component/FluxItemActions.vue +1 -1
- package/src/component/FluxItemContent.vue +1 -1
- package/src/component/FluxItemMedia.vue +1 -1
- package/src/component/FluxItemStack.vue +1 -1
- package/src/component/FluxKanban.vue +6 -13
- package/src/component/FluxKanbanColumn.vue +42 -36
- package/src/component/FluxKanbanItem.vue +162 -0
- package/src/component/FluxLayerPane.vue +1 -1
- package/src/component/FluxLayerPaneSecondary.vue +1 -1
- package/src/component/FluxLegend.vue +1 -1
- package/src/component/FluxLink.vue +1 -1
- package/src/component/FluxMenu.vue +1 -1
- package/src/component/FluxMenuCollapsible.vue +3 -3
- package/src/component/FluxMenuGroup.vue +1 -1
- package/src/component/FluxMenuItem.vue +2 -2
- package/src/component/FluxMenuSubHeader.vue +1 -1
- package/src/component/FluxMenuTitle.vue +1 -1
- package/src/component/FluxNotice.vue +3 -3
- package/src/component/FluxOverflowBar.vue +1 -1
- package/src/component/FluxOverlay.vue +3 -3
- package/src/component/FluxOverlayProvider.vue +2 -2
- package/src/component/FluxPagination.vue +3 -3
- package/src/component/FluxPaginationBar.vue +2 -2
- package/src/component/FluxPaginationButton.vue +1 -1
- package/src/component/FluxPane.vue +1 -1
- package/src/component/FluxPaneBody.vue +1 -1
- package/src/component/FluxPaneFooter.vue +1 -1
- package/src/component/FluxPaneGroup.vue +1 -1
- package/src/component/FluxPaneHeader.vue +2 -2
- package/src/component/FluxPaneIllustration.vue +1 -1
- package/src/component/FluxPaneMedia.vue +1 -1
- package/src/component/FluxPercentageBar.vue +1 -1
- package/src/component/FluxPersona.vue +1 -1
- package/src/component/FluxPlaceholder.vue +1 -1
- package/src/component/FluxPressable.vue +1 -1
- package/src/component/FluxPrimaryButton.vue +1 -1
- package/src/component/FluxPrimaryLinkButton.vue +1 -1
- package/src/component/FluxProgressBar.vue +2 -2
- package/src/component/FluxPrompt.vue +1 -1
- package/src/component/FluxPublishButton.vue +1 -1
- package/src/component/FluxQuantitySelector.vue +2 -2
- package/src/component/FluxRemove.vue +2 -2
- package/src/component/FluxRoot.vue +2 -2
- package/src/component/FluxRow.vue +1 -1
- package/src/component/FluxSecondaryButton.vue +1 -1
- package/src/component/FluxSecondaryLinkButton.vue +1 -1
- package/src/component/FluxSegmentedControl.vue +1 -1
- package/src/component/FluxSeparator.vue +1 -1
- package/src/component/FluxSlideOver.vue +3 -3
- package/src/component/FluxSnackbar.vue +2 -2
- package/src/component/FluxSnackbarProvider.vue +2 -2
- package/src/component/FluxSpacer.vue +1 -1
- package/src/component/FluxSpinner.vue +1 -1
- package/src/component/FluxSplitButton.vue +2 -2
- package/src/component/FluxStack.vue +2 -2
- package/src/component/FluxStatistic.vue +2 -2
- package/src/component/FluxStepper.vue +1 -1
- package/src/component/FluxStepperStep.vue +1 -1
- package/src/component/FluxStepperSteps.vue +2 -2
- package/src/component/FluxTab.vue +2 -2
- package/src/component/FluxTabBar.vue +75 -7
- package/src/component/FluxTabBarItem.vue +35 -4
- package/src/component/FluxTable.vue +3 -4
- package/src/component/FluxTableActions.vue +1 -1
- package/src/component/FluxTableBar.vue +3 -3
- package/src/component/FluxTableCell.vue +3 -3
- package/src/component/FluxTableHeader.vue +3 -3
- package/src/component/FluxTableRow.vue +1 -1
- package/src/component/FluxTabs.vue +10 -4
- package/src/component/FluxTag.vue +2 -2
- package/src/component/FluxTicks.vue +1 -1
- package/src/component/FluxTimeline.vue +1 -1
- package/src/component/FluxTimelineItem.vue +2 -2
- package/src/component/FluxToggle.vue +2 -2
- package/src/component/FluxToolbar.vue +2 -2
- package/src/component/FluxTooltip.vue +1 -1
- package/src/component/FluxTooltipProvider.vue +3 -3
- package/src/component/FluxTreeView.vue +3 -4
- package/src/component/FluxWindow.vue +1 -1
- package/src/component/calendar/FluxCalendarItemDisplay.vue +117 -0
- package/src/component/calendar/FluxCalendarMonthView.vue +134 -0
- package/src/component/calendar/FluxCalendarTimeGridView.vue +550 -0
- package/src/component/calendar/index.ts +3 -0
- package/src/component/index.ts +2 -2
- package/src/component/primitive/CoordinatePicker.vue +2 -2
- package/src/component/primitive/CoordinatePickerThumb.vue +2 -2
- package/src/component/primitive/DialogLayout.vue +1 -1
- package/src/component/primitive/FilterBadge.vue +2 -2
- package/src/component/primitive/FilterItem.vue +1 -1
- package/src/component/primitive/FilterMenuRenderer.ts +2 -2
- package/src/component/primitive/FilterOptionBase.vue +6 -6
- package/src/component/primitive/SelectBase.vue +13 -13
- package/src/component/primitive/SliderBase.vue +3 -3
- package/src/component/primitive/SliderThumb.vue +2 -2
- package/src/component/primitive/SliderTrack.vue +1 -1
- package/src/component/primitive/TreeNodeRenderer.vue +3 -4
- package/src/component/primitive/VNodeRenderer.ts +1 -2
- package/src/composable/index.ts +3 -0
- package/src/composable/private/index.ts +5 -8
- package/src/composable/private/useAsyncFilterOptions.ts +2 -2
- package/src/composable/private/useCommandPalette.ts +2 -2
- package/src/composable/private/useDateFlyout.ts +1 -1
- package/src/composable/private/useDropdownPopup.ts +1 -1
- package/src/composable/private/useFilterOption.ts +2 -2
- package/src/composable/private/useFormSelect.ts +2 -3
- package/src/composable/private/useKanban.ts +167 -244
- package/src/composable/private/useKanbanAutoScroll.ts +95 -0
- package/src/composable/private/useTranslate.ts +1 -2
- package/src/composable/private/useTreeView.ts +1 -1
- package/src/composable/useAdaptiveGroupInjection.ts +1 -1
- package/src/composable/useBreakpoints.ts +1 -2
- package/src/composable/useCalendarInjection.ts +6 -0
- package/src/composable/useDisabled.ts +1 -2
- package/src/composable/useDisabledInjection.ts +1 -1
- package/src/composable/useExpandableGroupInjection.ts +1 -1
- package/src/composable/useFilterInjection.ts +1 -1
- package/src/composable/useFlyoutInjection.ts +1 -1
- package/src/composable/useFormFieldInjection.ts +1 -1
- package/src/composable/useKanbanInjection.ts +12 -0
- package/src/composable/useTabBarInjection.ts +10 -0
- package/src/composable/useTableInjection.ts +1 -1
- package/src/composable/useTooltipInjection.ts +1 -1
- package/src/css/component/Action.module.scss +1 -1
- package/src/css/component/AdaptiveSlot.module.scss +5 -7
- package/src/css/component/Avatar.module.scss +1 -1
- package/src/css/component/Badge.module.scss +1 -1
- package/src/css/component/Button.module.scss +1 -1
- package/src/css/component/Calendar.module.scss +274 -44
- package/src/css/component/Chip.module.scss +1 -1
- package/src/css/component/Color.module.scss +1 -1
- package/src/css/component/CommandPalette.module.scss +1 -1
- package/src/css/component/DatePicker.module.scss +1 -1
- package/src/css/component/Expandable.module.scss +1 -1
- package/src/css/component/Form.module.scss +1 -1
- package/src/css/component/Gallery.module.scss +1 -1
- package/src/css/component/Grid.module.scss +1 -1
- package/src/css/component/Item.module.scss +1 -1
- package/src/css/component/{FluxKanban.module.scss → Kanban.module.scss} +56 -79
- package/src/css/component/Layout.module.scss +1 -1
- package/src/css/component/Menu.module.scss +1 -1
- package/src/css/component/Notice.module.scss +1 -1
- package/src/css/component/Overlay.module.scss +4 -4
- package/src/css/component/Pagination.module.scss +1 -1
- package/src/css/component/Pane.module.scss +2 -1
- package/src/css/component/Placeholder.module.scss +1 -1
- package/src/css/component/Remove.module.scss +1 -1
- package/src/css/component/SegmentedControl.module.scss +1 -1
- package/src/css/component/Snackbar.module.scss +1 -1
- package/src/css/component/Tab.module.scss +138 -34
- package/src/css/component/Table.module.scss +1 -1
- package/src/css/component/TreeView.module.scss +1 -1
- package/src/css/component/TreeViewSelect.module.scss +1 -1
- package/src/css/component/base/Button.module.scss +1 -1
- package/src/css/component/primitive/Slider.module.scss +1 -1
- package/src/css/component/primitive/TreeNode.module.scss +1 -1
- package/src/css/variables.scss +2 -2
- package/src/data/di.ts +64 -11
- package/src/data/filter.ts +3 -3
- package/src/data/i18n.ts +4 -0
- package/src/data/store.ts +1 -2
- package/src/transition/FluxBreakthroughTransition.vue +1 -1
- package/src/transition/FluxFadeTransition.vue +1 -1
- package/src/transition/FluxOverlayTransition.vue +1 -1
- package/src/transition/FluxRouteTransition.vue +1 -1
- package/src/transition/FluxSlideOverTransition.vue +1 -1
- package/src/transition/FluxTooltipTransition.vue +1 -1
- package/src/transition/FluxVerticalWindowTransition.vue +1 -1
- package/src/transition/FluxWindowTransition.vue +1 -1
- package/src/util/createDialogRenderer.ts +3 -4
- package/src/util/createLabelForDateRange.ts +1 -1
- package/src/component/FluxCalendarEvent.vue +0 -42
- package/src/component/FluxKanbanCard.vue +0 -199
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
2
|
import { defineComponent } from 'vue';
|
|
3
|
-
import { FluxSlideOverTransition } from '
|
|
4
|
-
import { createDialogRenderer } from '
|
|
5
|
-
import $style from '
|
|
3
|
+
import { FluxSlideOverTransition } from '~flux/components/transition';
|
|
4
|
+
import { createDialogRenderer } from '~flux/components/util';
|
|
5
|
+
import $style from '~flux/components/css/component/Overlay.module.scss';
|
|
6
6
|
|
|
7
7
|
export default defineComponent({
|
|
8
8
|
emits: ['close'],
|
|
@@ -75,12 +75,12 @@
|
|
|
75
75
|
import type { FluxColor, FluxIconName, FluxSnackbarObject } from '@flux-ui/types';
|
|
76
76
|
import { clsx } from 'clsx';
|
|
77
77
|
import { computed, onBeforeUnmount, ref, watch, watchEffect } from 'vue';
|
|
78
|
-
import { addSnackbar, removeSnackbar, updateSnackbar } from '
|
|
78
|
+
import { addSnackbar, removeSnackbar, updateSnackbar } from '~flux/components/data';
|
|
79
79
|
import FluxAction from './FluxAction.vue';
|
|
80
80
|
import FluxIcon from './FluxIcon.vue';
|
|
81
81
|
import FluxProgressBar from './FluxProgressBar.vue';
|
|
82
82
|
import FluxSpinner from './FluxSpinner.vue';
|
|
83
|
-
import $style from '
|
|
83
|
+
import $style from '~flux/components/css/component/Snackbar.module.scss';
|
|
84
84
|
|
|
85
85
|
const emit = defineEmits<{
|
|
86
86
|
action: [string];
|
|
@@ -22,9 +22,9 @@
|
|
|
22
22
|
lang="ts"
|
|
23
23
|
setup>
|
|
24
24
|
import type { FluxSnackbarObject } from '@flux-ui/types';
|
|
25
|
-
import { useFluxStore } from '
|
|
25
|
+
import { useFluxStore } from '~flux/components/data';
|
|
26
26
|
import FluxSnackbar from './FluxSnackbar.vue';
|
|
27
|
-
import $style from '
|
|
27
|
+
import $style from '~flux/components/css/component/Snackbar.module.scss';
|
|
28
28
|
|
|
29
29
|
const {snackbars} = useFluxStore();
|
|
30
30
|
|
|
@@ -27,11 +27,11 @@
|
|
|
27
27
|
<script
|
|
28
28
|
setup
|
|
29
29
|
lang="ts">
|
|
30
|
-
import type { VNode } from 'vue';
|
|
31
30
|
import type { FluxDirection, FluxIconName } from '@flux-ui/types';
|
|
31
|
+
import type { VNode } from 'vue';
|
|
32
32
|
import FluxFlyout from './FluxFlyout.vue';
|
|
33
33
|
import FluxSecondaryButton from './FluxSecondaryButton.vue';
|
|
34
|
-
import $style from '
|
|
34
|
+
import $style from '~flux/components/css/component/Button.module.scss';
|
|
35
35
|
|
|
36
36
|
const {
|
|
37
37
|
buttonIcon = 'ellipsis-h'
|
|
@@ -18,10 +18,10 @@
|
|
|
18
18
|
<script
|
|
19
19
|
lang="ts"
|
|
20
20
|
setup>
|
|
21
|
-
import type { VNode } from 'vue';
|
|
22
21
|
import type { FluxDirection } from '@flux-ui/types';
|
|
23
22
|
import { clsx } from 'clsx';
|
|
24
|
-
import
|
|
23
|
+
import type { VNode } from 'vue';
|
|
24
|
+
import $style from '~flux/components/css/component/Layout.module.scss';
|
|
25
25
|
|
|
26
26
|
const {
|
|
27
27
|
direction = 'vertical',
|
|
@@ -57,10 +57,10 @@
|
|
|
57
57
|
import { MDASH } from '@basmilius/utils';
|
|
58
58
|
import type { FluxColor, FluxDirection, FluxIconName } from '@flux-ui/types';
|
|
59
59
|
import { clsx } from 'clsx';
|
|
60
|
+
import FluxBoxedIcon from './FluxBoxedIcon.vue';
|
|
60
61
|
import FluxIcon from './FluxIcon.vue';
|
|
61
62
|
import FluxPane from './FluxPane.vue';
|
|
62
|
-
import $style from '
|
|
63
|
-
import FluxBoxedIcon from '$flux/component/FluxBoxedIcon.vue';
|
|
63
|
+
import $style from '~flux/components/css/component/Statistic.module.scss';
|
|
64
64
|
|
|
65
65
|
const {
|
|
66
66
|
changeColor = 'gray',
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
setup>
|
|
25
25
|
import { flattenVNodeTree } from '@flux-ui/internals';
|
|
26
26
|
import { computed, ref, unref, type VNode, watch } from 'vue';
|
|
27
|
-
import { FluxWindowTransition } from '
|
|
27
|
+
import { FluxWindowTransition } from '~flux/components/transition';
|
|
28
28
|
import FluxDynamicView from './FluxDynamicView.vue';
|
|
29
29
|
import FluxStepperSteps from './FluxStepperSteps.vue';
|
|
30
30
|
|
|
@@ -38,9 +38,9 @@
|
|
|
38
38
|
setup>
|
|
39
39
|
import { clsx } from 'clsx';
|
|
40
40
|
import { computed } from 'vue';
|
|
41
|
-
import { FluxFadeTransition } from '
|
|
41
|
+
import { FluxFadeTransition } from '~flux/components/transition';
|
|
42
42
|
import FluxIcon from './FluxIcon.vue';
|
|
43
|
-
import $style from '
|
|
43
|
+
import $style from '~flux/components/css/component/Stepper.module.scss';
|
|
44
44
|
|
|
45
45
|
const emit = defineEmits<{
|
|
46
46
|
activate: [number];
|
|
@@ -9,9 +9,9 @@
|
|
|
9
9
|
<script
|
|
10
10
|
lang="ts"
|
|
11
11
|
setup>
|
|
12
|
-
import type { VNode } from 'vue';
|
|
13
12
|
import type { FluxIconName } from '@flux-ui/types';
|
|
14
|
-
import
|
|
13
|
+
import type { VNode } from 'vue';
|
|
14
|
+
import $style from '~flux/components/css/component/Tab.module.scss';
|
|
15
15
|
|
|
16
16
|
defineProps<{
|
|
17
17
|
readonly icon?: FluxIconName;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<nav
|
|
3
|
-
:class="$style.
|
|
3
|
+
:class="isPills ? $style.tabBarPills : $style.tabBarDefault"
|
|
4
4
|
role="tablist"
|
|
5
5
|
aria-orientation="horizontal">
|
|
6
6
|
<FluxFadeTransition>
|
|
@@ -17,10 +17,17 @@
|
|
|
17
17
|
<div
|
|
18
18
|
ref="tabBar"
|
|
19
19
|
:class="clsx(
|
|
20
|
-
$style.
|
|
20
|
+
isPills ? $style.tabBarTabsPills : $style.tabBarTabsDefault,
|
|
21
21
|
isEndArrowVisible && $style.isEndMasked,
|
|
22
22
|
isStartArrowVisible && $style.isStartMasked
|
|
23
23
|
)">
|
|
24
|
+
<div
|
|
25
|
+
v-if="activeItemWidth > 0"
|
|
26
|
+
:class="isPills ? $style.tabBarHighlightPills : $style.tabBarHighlightDefault"
|
|
27
|
+
:style="{
|
|
28
|
+
left: `${activeItemX}px`,
|
|
29
|
+
width: `${activeItemWidth}px`
|
|
30
|
+
}"/>
|
|
24
31
|
<slot/>
|
|
25
32
|
</div>
|
|
26
33
|
|
|
@@ -40,13 +47,18 @@
|
|
|
40
47
|
<script
|
|
41
48
|
lang="ts"
|
|
42
49
|
setup>
|
|
43
|
-
import { useMutationObserver } from '@basmilius/common';
|
|
50
|
+
import { useMutationObserver, useResizeObserver } from '@basmilius/common';
|
|
44
51
|
import { unrefTemplateElement, useEventListener } from '@flux-ui/internals';
|
|
45
52
|
import { clsx } from 'clsx';
|
|
46
|
-
import { onMounted, ref, useTemplateRef, type VNode } from 'vue';
|
|
47
|
-
import {
|
|
53
|
+
import { onMounted, provide, ref, toRef, useTemplateRef, watch, type Ref, type VNode } from 'vue';
|
|
54
|
+
import { FluxTabBarInjectionKey } from '~flux/components/data';
|
|
55
|
+
import { FluxFadeTransition } from '~flux/components/transition';
|
|
48
56
|
import FluxIcon from './FluxIcon.vue';
|
|
49
|
-
import $style from '
|
|
57
|
+
import $style from '~flux/components/css/component/Tab.module.scss';
|
|
58
|
+
|
|
59
|
+
const { isPills } = defineProps<{
|
|
60
|
+
readonly isPills?: boolean;
|
|
61
|
+
}>();
|
|
50
62
|
|
|
51
63
|
defineSlots<{
|
|
52
64
|
default(): VNode[];
|
|
@@ -55,13 +67,38 @@
|
|
|
55
67
|
const tabBarRef = useTemplateRef<HTMLElement>('tabBar');
|
|
56
68
|
|
|
57
69
|
useEventListener(tabBarRef, 'scroll', () => checkScroll());
|
|
58
|
-
useMutationObserver(tabBarRef, () =>
|
|
70
|
+
useMutationObserver(tabBarRef, () => {
|
|
71
|
+
checkScroll();
|
|
72
|
+
updateHighlight();
|
|
73
|
+
}, {childList: true});
|
|
74
|
+
useResizeObserver(tabBarRef, () => updateHighlight());
|
|
59
75
|
|
|
60
76
|
const isEndArrowVisible = ref(false);
|
|
61
77
|
const isStartArrowVisible = ref(false);
|
|
78
|
+
const activeItemX = ref(0);
|
|
79
|
+
const activeItemWidth = ref(0);
|
|
80
|
+
|
|
81
|
+
const items = new Map<Element, Ref<boolean>>();
|
|
82
|
+
const itemUnwatchers = new Map<Element, () => void>();
|
|
62
83
|
|
|
63
84
|
onMounted(() => checkScroll());
|
|
64
85
|
|
|
86
|
+
provide(FluxTabBarInjectionKey, {
|
|
87
|
+
isPills: toRef(() => isPills ?? false),
|
|
88
|
+
registerItem(element, isActive) {
|
|
89
|
+
items.set(element, isActive);
|
|
90
|
+
const unwatch = watch(isActive, () => updateHighlight(), {flush: 'post', immediate: true});
|
|
91
|
+
itemUnwatchers.set(element, unwatch);
|
|
92
|
+
},
|
|
93
|
+
unregisterItem(element) {
|
|
94
|
+
const unwatch = itemUnwatchers.get(element);
|
|
95
|
+
unwatch?.();
|
|
96
|
+
itemUnwatchers.delete(element);
|
|
97
|
+
items.delete(element);
|
|
98
|
+
updateHighlight();
|
|
99
|
+
}
|
|
100
|
+
});
|
|
101
|
+
|
|
65
102
|
function checkScroll(): void {
|
|
66
103
|
const tabBar = unrefTemplateElement(tabBarRef)!;
|
|
67
104
|
|
|
@@ -75,6 +112,37 @@
|
|
|
75
112
|
isStartArrowVisible.value = tabBar.scrollLeft > 0;
|
|
76
113
|
}
|
|
77
114
|
|
|
115
|
+
function updateHighlight(): void {
|
|
116
|
+
const tabBar = unrefTemplateElement(tabBarRef);
|
|
117
|
+
|
|
118
|
+
if (!tabBar) {
|
|
119
|
+
return;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
let activeElement: HTMLElement | null = null;
|
|
123
|
+
|
|
124
|
+
for (const [element, isActive] of items) {
|
|
125
|
+
if (isActive.value) {
|
|
126
|
+
activeElement = element as HTMLElement;
|
|
127
|
+
break;
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
if (!activeElement) {
|
|
132
|
+
activeItemWidth.value = 0;
|
|
133
|
+
return;
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
const width = activeElement.offsetWidth;
|
|
137
|
+
|
|
138
|
+
if (width === 0) {
|
|
139
|
+
return;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
activeItemX.value = activeElement.offsetLeft;
|
|
143
|
+
activeItemWidth.value = width;
|
|
144
|
+
}
|
|
145
|
+
|
|
78
146
|
function scrollToEnd(): void {
|
|
79
147
|
const tabBar = unrefTemplateElement(tabBarRef)!;
|
|
80
148
|
tabBar.scrollBy({
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
<FluxPressable
|
|
3
3
|
ref="tab"
|
|
4
4
|
:component-type="type"
|
|
5
|
-
:class="
|
|
5
|
+
:class="itemClass"
|
|
6
6
|
type="button"
|
|
7
7
|
role="tab"
|
|
8
8
|
:aria-disabled="disabled ? true : undefined"
|
|
@@ -29,11 +29,11 @@
|
|
|
29
29
|
lang="ts"
|
|
30
30
|
setup>
|
|
31
31
|
import type { FluxIconName, FluxPressableType, FluxTo } from '@flux-ui/types';
|
|
32
|
-
import { type ComponentPublicInstance, toRef, unref, useTemplateRef, watch } from 'vue';
|
|
33
|
-
import { useDisabled } from '
|
|
32
|
+
import { type ComponentPublicInstance, computed, onBeforeUnmount, onMounted, toRef, unref, useTemplateRef, watch } from 'vue';
|
|
33
|
+
import { useDisabled, useTabBarInjection } from '~flux/components/composable';
|
|
34
34
|
import FluxIcon from './FluxIcon.vue';
|
|
35
35
|
import FluxPressable from './FluxPressable.vue';
|
|
36
|
-
import $style from '
|
|
36
|
+
import $style from '~flux/components/css/component/Tab.module.scss';
|
|
37
37
|
|
|
38
38
|
const emit = defineEmits<{
|
|
39
39
|
click: [MouseEvent];
|
|
@@ -58,8 +58,39 @@
|
|
|
58
58
|
}>();
|
|
59
59
|
|
|
60
60
|
const disabled = useDisabled(toRef(() => componentDisabled));
|
|
61
|
+
const tabBar = useTabBarInjection();
|
|
61
62
|
const tabRef = useTemplateRef<ComponentPublicInstance>('tab');
|
|
62
63
|
|
|
64
|
+
const itemClass = computed(() => {
|
|
65
|
+
if (tabBar.isPills.value) {
|
|
66
|
+
return isActive ? $style.tabBarItemPillsActive : $style.tabBarItemPills;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
return isActive ? $style.tabBarItemDefaultActive : $style.tabBarItemDefault;
|
|
70
|
+
});
|
|
71
|
+
|
|
72
|
+
let registeredElement: Element | null = null;
|
|
73
|
+
|
|
74
|
+
onMounted(() => {
|
|
75
|
+
const tab = unref(tabRef);
|
|
76
|
+
|
|
77
|
+
if (!tab) {
|
|
78
|
+
return;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
registeredElement = tab.$el;
|
|
82
|
+
tabBar.registerItem(registeredElement!, toRef(() => !!isActive));
|
|
83
|
+
});
|
|
84
|
+
|
|
85
|
+
onBeforeUnmount(() => {
|
|
86
|
+
if (!registeredElement) {
|
|
87
|
+
return;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
tabBar.unregisterItem(registeredElement);
|
|
91
|
+
registeredElement = null;
|
|
92
|
+
});
|
|
93
|
+
|
|
63
94
|
function onClick(evt: MouseEvent): void {
|
|
64
95
|
if (unref(disabled)) {
|
|
65
96
|
evt.preventDefault();
|
|
@@ -45,14 +45,13 @@
|
|
|
45
45
|
<script
|
|
46
46
|
lang="ts"
|
|
47
47
|
setup>
|
|
48
|
-
import type
|
|
49
|
-
import {
|
|
50
|
-
import { FluxTableInjectionKey } from '$flux/data';
|
|
48
|
+
import { provide, type VNode } from 'vue';
|
|
49
|
+
import { FluxTableInjectionKey } from '~flux/components/data';
|
|
51
50
|
import FluxPaneBody from './FluxPaneBody.vue';
|
|
52
51
|
import FluxSpinner from './FluxSpinner.vue';
|
|
53
52
|
import FluxTableCell from './FluxTableCell.vue';
|
|
54
53
|
import FluxTableRow from './FluxTableRow.vue';
|
|
55
|
-
import $style from '
|
|
54
|
+
import $style from '~flux/components/css/component/Table.module.scss';
|
|
56
55
|
|
|
57
56
|
const {
|
|
58
57
|
captionSide = 'bottom',
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
setup>
|
|
10
10
|
import type { VNode } from 'vue';
|
|
11
11
|
import FluxActionStack from './FluxActionStack.vue';
|
|
12
|
-
import $style from '
|
|
12
|
+
import $style from '~flux/components/css/component/Table.module.scss';
|
|
13
13
|
|
|
14
14
|
defineSlots<{
|
|
15
15
|
default(): VNode[];
|
|
@@ -20,10 +20,10 @@
|
|
|
20
20
|
<script
|
|
21
21
|
lang="ts"
|
|
22
22
|
setup>
|
|
23
|
-
import type { VNode } from 'vue';
|
|
24
|
-
import { useTableInjection } from '$flux/composable';
|
|
25
23
|
import { clsx } from 'clsx';
|
|
26
|
-
import
|
|
24
|
+
import type { VNode } from 'vue';
|
|
25
|
+
import { useTableInjection } from '~flux/components/composable';
|
|
26
|
+
import $style from '~flux/components/css/component/Table.module.scss';
|
|
27
27
|
|
|
28
28
|
defineSlots<{
|
|
29
29
|
default(): VNode[];
|
|
@@ -24,10 +24,10 @@
|
|
|
24
24
|
<script
|
|
25
25
|
lang="ts"
|
|
26
26
|
setup>
|
|
27
|
-
import type { VNode } from 'vue';
|
|
28
27
|
import { clsx } from 'clsx';
|
|
29
|
-
import {
|
|
30
|
-
import
|
|
28
|
+
import type { VNode } from 'vue';
|
|
29
|
+
import { useTableInjection } from '~flux/components/composable';
|
|
30
|
+
import $style from '~flux/components/css/component/Table.module.scss';
|
|
31
31
|
|
|
32
32
|
const {
|
|
33
33
|
contentDirection = 'row'
|
|
@@ -66,15 +66,15 @@
|
|
|
66
66
|
import type { FluxIconName } from '@flux-ui/types';
|
|
67
67
|
import { clsx } from 'clsx';
|
|
68
68
|
import { computed, type VNode } from 'vue';
|
|
69
|
-
import { useTableInjection } from '
|
|
70
|
-
import { useTranslate } from '
|
|
69
|
+
import { useTableInjection } from '~flux/components/composable';
|
|
70
|
+
import { useTranslate } from '~flux/components/composable/private';
|
|
71
71
|
import FluxFlyout from './FluxFlyout.vue';
|
|
72
72
|
import FluxIcon from './FluxIcon.vue';
|
|
73
73
|
import FluxMenu from './FluxMenu.vue';
|
|
74
74
|
import FluxMenuGroup from './FluxMenuGroup.vue';
|
|
75
75
|
import FluxMenuItem from './FluxMenuItem.vue';
|
|
76
76
|
import FluxSeparator from './FluxSeparator.vue';
|
|
77
|
-
import $style from '
|
|
77
|
+
import $style from '~flux/components/css/component/Table.module.scss';
|
|
78
78
|
|
|
79
79
|
defineEmits<{
|
|
80
80
|
sort: ['ascending' | 'descending' | null];
|
|
@@ -3,7 +3,9 @@
|
|
|
3
3
|
<slot
|
|
4
4
|
v-bind="{children, modelValue, tabs, activate}"
|
|
5
5
|
name="tabs">
|
|
6
|
-
<FluxTabBar
|
|
6
|
+
<FluxTabBar
|
|
7
|
+
:class="$style.tabsBar"
|
|
8
|
+
:is-pills="isPills">
|
|
7
9
|
<template
|
|
8
10
|
v-for="(tab, index) of tabs"
|
|
9
11
|
:key="index">
|
|
@@ -36,16 +38,20 @@
|
|
|
36
38
|
import { flattenVNodeTree, getComponentProps } from '@flux-ui/internals';
|
|
37
39
|
import type { FluxIconName } from '@flux-ui/types';
|
|
38
40
|
import { cloneVNode, computed, ref, unref, useId, type VNode, watch } from 'vue';
|
|
39
|
-
import { FluxWindowTransition } from '
|
|
40
|
-
import { VNodeRenderer } from './primitive';
|
|
41
|
+
import { FluxWindowTransition } from '~flux/components/transition';
|
|
41
42
|
import FluxTabBar from './FluxTabBar.vue';
|
|
42
43
|
import FluxTabBarItem from './FluxTabBarItem.vue';
|
|
43
|
-
import
|
|
44
|
+
import { VNodeRenderer } from './primitive';
|
|
45
|
+
import $style from '~flux/components/css/component/Tab.module.scss';
|
|
44
46
|
|
|
45
47
|
const modelValue = defineModel<number>({
|
|
46
48
|
default: 0
|
|
47
49
|
});
|
|
48
50
|
|
|
51
|
+
defineProps<{
|
|
52
|
+
readonly isPills?: boolean;
|
|
53
|
+
}>();
|
|
54
|
+
|
|
49
55
|
const slots = defineSlots<{
|
|
50
56
|
default(): VNode[];
|
|
51
57
|
|
|
@@ -53,11 +53,11 @@
|
|
|
53
53
|
setup>
|
|
54
54
|
import type { FluxButtonEmits, FluxColor, FluxIconName, FluxPressableType, FluxTo } from '@flux-ui/types';
|
|
55
55
|
import { clsx } from 'clsx';
|
|
56
|
-
import { useTranslate } from '
|
|
56
|
+
import { useTranslate } from '~flux/components/composable/private';
|
|
57
57
|
import FluxIcon from './FluxIcon.vue';
|
|
58
58
|
import FluxPressable from './FluxPressable.vue';
|
|
59
59
|
import FluxSpinner from './FluxSpinner.vue';
|
|
60
|
-
import $style from '
|
|
60
|
+
import $style from '~flux/components/css/component/Badge.module.scss';
|
|
61
61
|
|
|
62
62
|
const emit = defineEmits<FluxButtonEmits & {
|
|
63
63
|
delete: [];
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
setup>
|
|
30
30
|
import { generateStepTicks } from '@basmilius/utils';
|
|
31
31
|
import { computed } from 'vue';
|
|
32
|
-
import $style from '
|
|
32
|
+
import $style from '~flux/components/css/component/primitive/Slider.module.scss';
|
|
33
33
|
|
|
34
34
|
const {
|
|
35
35
|
lower,
|
|
@@ -52,11 +52,11 @@
|
|
|
52
52
|
<script
|
|
53
53
|
lang="ts"
|
|
54
54
|
setup>
|
|
55
|
-
import type { VNode } from 'vue';
|
|
56
55
|
import type { FluxColor, FluxIconName } from '@flux-ui/types';
|
|
57
56
|
import { clsx } from 'clsx';
|
|
57
|
+
import type { VNode } from 'vue';
|
|
58
58
|
import FluxIcon from './FluxIcon.vue';
|
|
59
|
-
import $style from '
|
|
59
|
+
import $style from '~flux/components/css/component/Timeline.module.scss';
|
|
60
60
|
|
|
61
61
|
const {
|
|
62
62
|
color = 'gray'
|
|
@@ -43,9 +43,9 @@
|
|
|
43
43
|
import type { FluxFormInputBaseProps, FluxIconName } from '@flux-ui/types';
|
|
44
44
|
import { clsx } from 'clsx';
|
|
45
45
|
import { toRef } from 'vue';
|
|
46
|
-
import { useDisabled, useFormFieldInjection } from '
|
|
46
|
+
import { useDisabled, useFormFieldInjection } from '~flux/components/composable';
|
|
47
47
|
import FluxIcon from './FluxIcon.vue';
|
|
48
|
-
import $style from '
|
|
48
|
+
import $style from '~flux/components/css/component/Form.module.scss';
|
|
49
49
|
|
|
50
50
|
const modelValue = defineModel<boolean>({
|
|
51
51
|
default: false
|
|
@@ -18,10 +18,10 @@
|
|
|
18
18
|
<script
|
|
19
19
|
lang="ts"
|
|
20
20
|
setup>
|
|
21
|
-
import type { VNode } from 'vue';
|
|
22
21
|
import { clsx } from 'clsx';
|
|
22
|
+
import type { VNode } from 'vue';
|
|
23
23
|
import FluxStack from './FluxStack.vue';
|
|
24
|
-
import $style from '
|
|
24
|
+
import $style from '~flux/components/css/component/Toolbar.module.scss';
|
|
25
25
|
|
|
26
26
|
defineProps<{
|
|
27
27
|
readonly floatingMode?: 'free' | 'top-start' | 'top-end' | 'bottom-start' | 'bottom-end';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
2
|
import { defineComponent, getCurrentInstance, onMounted, onUnmounted, type PropType, ref, type SlotsType, type VNode } from 'vue';
|
|
3
|
-
import { addTooltip, removeTooltip } from '
|
|
3
|
+
import { addTooltip, removeTooltip } from '~flux/components/data';
|
|
4
4
|
|
|
5
5
|
export default defineComponent({
|
|
6
6
|
props: {
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
import { unrefTemplateElement } from '@flux-ui/internals';
|
|
3
3
|
import { clsx } from 'clsx';
|
|
4
4
|
import { computed, defineComponent, h, provide, ref, unref, watch } from 'vue';
|
|
5
|
-
import { FluxTooltipInjectionKey, useFluxStore } from '
|
|
6
|
-
import { FluxTooltipTransition } from '
|
|
7
|
-
import $style from '
|
|
5
|
+
import { FluxTooltipInjectionKey, useFluxStore } from '~flux/components/data';
|
|
6
|
+
import { FluxTooltipTransition } from '~flux/components/transition';
|
|
7
|
+
import $style from '~flux/components/css/component/Tooltip.module.scss';
|
|
8
8
|
|
|
9
9
|
type Transition = 'above' | 'below' | 'end' | 'start';
|
|
10
10
|
|
|
@@ -35,10 +35,9 @@
|
|
|
35
35
|
import type { FluxColor, FluxTreeViewOption } from '@flux-ui/types';
|
|
36
36
|
import { clsx } from 'clsx';
|
|
37
37
|
import { computed, ref, unref, useTemplateRef } from 'vue';
|
|
38
|
-
import type
|
|
39
|
-
import {
|
|
40
|
-
import
|
|
41
|
-
import $style from '$flux/css/component/TreeView.module.scss';
|
|
38
|
+
import { flattenVisible, type TreeFlatNode, useTreeView } from '~flux/components/composable/private';
|
|
39
|
+
import { TreeNodeRenderer } from './primitive';
|
|
40
|
+
import $style from '~flux/components/css/component/TreeView.module.scss';
|
|
42
41
|
|
|
43
42
|
type FlatNode = TreeFlatNode<FluxTreeViewOption>;
|
|
44
43
|
|