@dynect/base 0.10.0 → 0.10.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. package/package.json +1 -1
  2. package/src/runtime/components/base/event-calendar/AgendaView.vue +2 -0
  3. package/src/runtime/components/base/event-calendar/DayEventsOverflowPopup.vue +1 -0
  4. package/src/runtime/components/base/event-calendar/DayView.vue +2 -0
  5. package/src/runtime/components/base/event-calendar/EventCalendar.vue +2 -0
  6. package/src/runtime/components/base/event-calendar/EventModal.vue +2 -0
  7. package/src/runtime/components/base/event-calendar/MonthView.vue +1 -0
  8. package/src/runtime/components/base/event-calendar/WeekView.vue +2 -0
  9. package/src/runtime/components/base/event-calendar/composables/useAdvancedValidation.ts +1 -0
  10. package/src/runtime/components/base/event-calendar/composables/useCalendarUtils.ts +1 -0
  11. package/src/runtime/components/base/event-calendar/composables/useCompatibility.ts +1 -0
  12. package/src/runtime/components/base/event-calendar/composables/useDragAndDrop.ts +1 -0
  13. package/src/runtime/components/base/event-calendar/composables/useEventFiltering.ts +1 -0
  14. package/src/runtime/components/base/event-calendar/composables/useEventStatus.ts +1 -0
  15. package/src/runtime/components/base/event-calendar/composables/useMultiDayLayout.ts +1 -0
  16. package/src/runtime/components/base/event-calendar/composables/useRecurringEvents.ts +1 -0
  17. package/src/runtime/components/base/event-calendar/composables/useTimezone.ts +2 -0
  18. package/src/runtime/components/base/org-chart/index.vue +1 -0
  19. package/src/runtime/components/dynect/Autocomplete.vue +1 -0
  20. package/src/runtime/components/dynect/Dropzone.vue +2 -0
  21. package/src/runtime/components/dynect/Gantt.vue +1 -1
  22. package/src/runtime/components/dynect/Kanban.vue +1 -1
  23. package/src/runtime/components/dynect/Select.vue +1 -0
  24. package/src/runtime/components/dynect/SelectMultiple.vue +1 -0
  25. package/src/runtime/components/dynect/SwitchLanguage.vue +1 -0
  26. package/src/runtime/components/dynect/TagsInput.vue +1 -0
  27. package/src/runtime/components/dynect/Telephone.vue +1 -0
  28. package/src/runtime/components/ui/gantt/GanttCreateMarkerTrigger.vue +2 -0
  29. package/src/runtime/components/ui/gantt/GanttFeatureItem.vue +2 -0
  30. package/src/runtime/components/ui/gantt/GanttFeatureList.vue +1 -0
  31. package/src/runtime/components/ui/gantt/GanttFeatureListGroup.vue +1 -0
  32. package/src/runtime/components/ui/gantt/GanttHeader.vue +2 -0
  33. package/src/runtime/components/ui/gantt/GanttMarker.vue +2 -0
  34. package/src/runtime/components/ui/gantt/GanttSidebar.vue +1 -0
  35. package/src/runtime/components/ui/gantt/GanttSidebarGroup.vue +1 -0
  36. package/src/runtime/components/ui/gantt/GanttSidebarItem.vue +1 -0
  37. package/src/runtime/components/ui/gantt/GanttTimeline.vue +2 -0
  38. package/src/runtime/components/ui/gantt/GanttToday.vue +2 -0
  39. package/src/runtime/components/ui/gantt/GanttZoomControls.vue +1 -0
  40. package/src/runtime/components/ui/gantt/index.ts +1 -1
  41. package/src/runtime/components/ui/kanban/KanbanBoard.vue +1 -0
  42. package/src/runtime/components/ui/kanban/KanbanCard.vue +1 -0
  43. package/src/runtime/components/ui/kanban/KanbanCards.vue +1 -0
  44. package/src/runtime/components/ui/kanban/index.ts +1 -1
  45. package/src/runtime/composables/useDropzone.ts +1 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dynect/base",
3
- "version": "0.10.0",
3
+ "version": "0.10.2",
4
4
  "description": "Reusable Nuxt base module — components, composables, utils, plugins and i18n from the Dynect design system.",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -1,4 +1,6 @@
1
1
  <script setup lang="ts">
2
+ import { formatDateTime } from '../../../utils/date';
3
+ import { toLowerCase } from '../../../utils/function';
2
4
  import { computed } from 'vue';
3
5
  import type { CalendarEvent } from './types';
4
6
  import LocationDisplay from './LocationDisplay.vue';
@@ -1,4 +1,5 @@
1
1
  <script setup lang="ts">
2
+ import { formatDateTime } from '../../../utils/date';
2
3
  import { computed, ref } from 'vue';
3
4
  import type { CalendarEvent } from './types';
4
5
 
@@ -1,4 +1,6 @@
1
1
  <script setup lang="ts">
2
+ import { formatDateTime } from '../../../utils/date';
3
+ import { debounce, throttle } from '../../../utils/function';
2
4
  import { computed, ref } from 'vue';
3
5
  import type { CalendarEvent, DayColumnData, TimeSlot } from './types';
4
6
  import { useCalendarUtils } from './composables/useCalendarUtils';
@@ -1,4 +1,6 @@
1
1
  <script setup lang="ts">
2
+ import { addDays, addMonths, addWeeks, eachDayOfInterval, endOfDay, endOfMonth, endOfWeek, formatDateTime, isSameDay, isWithinInterval, startOfDay, startOfMonth, startOfWeek, subDays } from '../../../utils/date';
3
+ import { toUpperCase } from '../../../utils/function';
2
4
  import { computed, ref, shallowRef, watch } from 'vue';
3
5
  import { useKeyboardNavigation } from './composables/useKeyboardNavigation';
4
6
  import { useDragAndDropSystem } from './composables/useDragAndDrop';
@@ -1,4 +1,6 @@
1
1
  <script setup lang="ts">
2
+ import { addHours, getDay, getDayNameShort, isBefore, setHours } from '../../../utils/date';
3
+ import { convertDateTime, toLowerCase } from '../../../utils/function';
2
4
  import { Form, useForm } from 'vee-validate';
3
5
  import { computed, reactive, ref, watch } from 'vue';
4
6
  import { useId } from 'nuxt/app';
@@ -1,4 +1,5 @@
1
1
  <script setup lang="ts">
2
+ import { formatDateTime, isSameDay, startOfDay, subDays } from '../../../utils/date';
2
3
  import { computed, onUnmounted, ref } from 'vue';
3
4
  import type { CalendarEvent, MonthViewDay } from './types';
4
5
  import DayEventsOverflowPopup from './DayEventsOverflowPopup.vue';
@@ -1,4 +1,6 @@
1
1
  <script setup lang="ts">
2
+ import { formatDateTime } from '../../../utils/date';
3
+ import { debounce, throttle } from '../../../utils/function';
2
4
  import { computed, onMounted, ref } from 'vue';
3
5
  import type { CalendarEvent, DayColumnData, TimeSlot } from './types';
4
6
  import { useCalendarUtils } from './composables/useCalendarUtils';
@@ -1,3 +1,4 @@
1
+ import { toLowerCase } from '../../../../utils/function';
1
2
  import { readonly, ref } from 'vue';
2
3
  import type { CalendarEvent, RecurringPattern } from '../types';
3
4
 
@@ -1,3 +1,4 @@
1
+ import { differenceInMinutes, eachHourOfInterval, endOfDay, formatDateTime, setHours, setMinutes, startOfDay } from '../../../../utils/date';
1
2
  import type { CalendarEvent, TimeSlot } from '../types';
2
3
 
3
4
  export const PIXELS_PER_HOUR_CONFIG = 60; // Can be made configurable
@@ -1,3 +1,4 @@
1
+ import { toLowerCase } from '../../../../utils/function';
1
2
  import { readonly, ref } from 'vue';
2
3
  interface BrowserCapabilities {
3
4
  hasNativeUUID: boolean;
@@ -1,3 +1,4 @@
1
+ import { endOfDay, setHours, setMinutes, startOfDay } from '../../../../utils/date';
1
2
  import { computed, reactive, ref } from 'vue';
2
3
  import { makeDraggable, makeDroppable, type IDragEvent } from '@vue-dnd-kit/core';
3
4
  import type { CalendarEvent } from '../types';
@@ -1,3 +1,4 @@
1
+ import { endOfDay, endOfMonth, isSameDay, isWithinInterval, startOfDay, startOfMonth } from '../../../../utils/date';
1
2
  import { type ComputedRef, computed } from 'vue';
2
3
  import type { CalendarEvent } from '../types';
3
4
 
@@ -1,3 +1,4 @@
1
+ import { endOfDay, isPast } from '../../../../utils/date';
1
2
  import { type ComputedRef, computed } from 'vue';
2
3
  import type { CalendarEvent, EventStatus } from '../types';
3
4
 
@@ -1,3 +1,4 @@
1
+ import { endOfDay, formatDateTime, isWithinInterval, startOfDay } from '../../../../utils/date';
1
2
  import { type ComputedRef, computed } from 'vue';
2
3
  import type { CalendarEvent, MonthViewDay } from '../types';
3
4
 
@@ -1,3 +1,4 @@
1
+ import { addDays, addMonths, addWeeks, addYears, formatDateTime, getDay, getDayNameShort, isAfter, isBefore, setDay } from '../../../../utils/date';
1
2
  import { type ComputedRef, computed } from 'vue';
2
3
  import type { CalendarEvent, RecurringPattern } from '../types';
3
4
 
@@ -1,3 +1,5 @@
1
+ import { TZDate, formatDateTime } from '../../../../utils/date';
2
+ import { getAllTimezones } from '../../../../utils/function';
1
3
  import { type ComputedRef, computed, ref } from 'vue';
2
4
  import type { CalendarEvent } from '../types';
3
5
  import { getLocalTimeZone } from '@internationalized/date';
@@ -1,4 +1,5 @@
1
1
  <script setup lang="ts">
2
+ import { toLowerCase } from '../../../utils/function';
2
3
  import { onBeforeUnmount, onMounted, ref, shallowRef, watch } from 'vue';
3
4
  import { OrgChart } from './main';
4
5
  import { SVG_ICONS, createIconSVG } from './svg-icons';
@@ -1,4 +1,5 @@
1
1
  <script setup lang="ts">
2
+ import { toLowerCase } from '../../utils/function';
2
3
  import { useField } from 'vee-validate';
3
4
  import { computed, ref } from 'vue';
4
5
  import { useId } from 'nuxt/app';
@@ -95,6 +95,8 @@
95
95
  </template>
96
96
 
97
97
  <script setup lang="ts">
98
+ import { toLowerCase } from '../../utils/function';
99
+ import { useDropzone } from '../../composables/useDropzone';
98
100
  import { useField } from 'vee-validate';
99
101
  import { computed, onMounted, onUnmounted, ref, watch } from 'vue';
100
102
  import { useId } from 'nuxt/app';
@@ -91,7 +91,7 @@
91
91
  <script setup lang="ts" generic="T extends DynectGanttFeature">
92
92
  import { computed } from 'vue';
93
93
  import { cn } from '@/lib/utils';
94
- import type { GanttFeature, GanttRange } from '@/composables/useGantt';
94
+ import type { GanttFeature, GanttRange } from '../../composables/useGantt';
95
95
 
96
96
  export interface DynectGanttFeature extends GanttFeature {
97
97
  [key: string]: any;
@@ -52,7 +52,7 @@
52
52
 
53
53
  <script setup lang="ts" generic="T extends KanbanItemProps, C extends KanbanColumnProps">
54
54
  import { cn } from '@/lib/utils';
55
- import type { KanbanItemProps, KanbanColumnProps } from '@/composables/useKanban';
55
+ import type { KanbanItemProps, KanbanColumnProps } from '../../composables/useKanban';
56
56
 
57
57
  export interface DynectKanbanColumn extends KanbanColumnProps {
58
58
  color?: string;
@@ -1,4 +1,5 @@
1
1
  <script setup lang="ts">
2
+ import { toLowerCase } from '../../utils/function';
2
3
  import { Field, useField } from 'vee-validate';
3
4
  import { computed, ref } from 'vue';
4
5
  import { useId } from 'nuxt/app';
@@ -1,4 +1,5 @@
1
1
  <script setup lang="ts">
2
+ import { toLowerCase } from '../../utils/function';
2
3
  import { Field, useField } from 'vee-validate';
3
4
  import { computed, ref } from 'vue';
4
5
  import { useId } from 'nuxt/app';
@@ -1,4 +1,5 @@
1
1
  <script setup lang="ts">
2
+ import { toUpperCase } from '../../utils/function';
2
3
  import { useI18n } from 'vue-i18n';
3
4
  import { cn } from '@/lib/utils';
4
5
  const { locale, setLocale } = useI18n();
@@ -101,6 +101,7 @@
101
101
  </template>
102
102
 
103
103
  <script setup lang="ts">
104
+ import { toLowerCase } from '../../utils/function';
104
105
  import { Field, useField } from 'vee-validate';
105
106
  import { computed, readonly, ref, watch } from 'vue';
106
107
  import { useId } from 'nuxt/app';
@@ -107,6 +107,7 @@
107
107
  </template>
108
108
 
109
109
  <script setup lang="ts">
110
+ import { capitalizeFirstLetter, countryList, toLowerCase, toUpperCase } from '../../utils/function';
110
111
  import { useField } from 'vee-validate';
111
112
  import { computed, nextTick, onMounted, reactive, readonly, ref, watch } from 'vue';
112
113
  import { parsePhoneNumberFromString, type CountryCode, type NumberFormat } from 'libphonenumber-js/max';
@@ -3,6 +3,8 @@
3
3
  </template>
4
4
 
5
5
  <script setup lang="ts">
6
+ import { addDays, addMonths, addWeeks } from '../../../utils/date';
7
+ import { useGantt } from '../../../composables/useGantt';
6
8
  export interface GanttCreateMarkerTriggerProps {
7
9
  onCreateMarker?: (date: Date) => void;
8
10
  }
@@ -51,6 +51,8 @@
51
51
  </template>
52
52
 
53
53
  <script setup lang="ts">
54
+ import { addDays, differenceInDays, formatDateTime } from '../../../utils/date';
55
+ import { useGantt } from '../../../composables/useGantt';
54
56
  import { computed, onUnmounted, ref } from 'vue';
55
57
  import { cn } from '@/lib/utils';
56
58
 
@@ -5,6 +5,7 @@
5
5
  </template>
6
6
 
7
7
  <script setup lang="ts">
8
+ import { useGantt } from '../../../composables/useGantt';
8
9
  import { cn } from '@/lib/utils';
9
10
 
10
11
  export interface GanttFeatureListProps {
@@ -9,6 +9,7 @@
9
9
  </template>
10
10
 
11
11
  <script setup lang="ts">
12
+ import { useGantt } from '../../../composables/useGantt';
12
13
  import { cn } from '@/lib/utils';
13
14
 
14
15
  export interface GanttFeatureListGroupProps {
@@ -83,6 +83,8 @@
83
83
  </template>
84
84
 
85
85
  <script setup lang="ts">
86
+ import { getDay } from '../../../utils/date';
87
+ import { useGantt } from '../../../composables/useGantt';
86
88
  import { cn } from '@/lib/utils';
87
89
 
88
90
  export interface GanttHeaderProps {
@@ -23,6 +23,8 @@
23
23
  </template>
24
24
 
25
25
  <script setup lang="ts">
26
+ import { addDays, formatDateTime } from '../../../utils/date';
27
+ import { useGantt } from '../../../composables/useGantt';
26
28
  import { computed, onUnmounted, ref } from 'vue';
27
29
  import { cn } from '@/lib/utils';
28
30
 
@@ -15,6 +15,7 @@
15
15
  </template>
16
16
 
17
17
  <script setup lang="ts">
18
+ import { useGantt } from '../../../composables/useGantt';
18
19
  import { onMounted, onUnmounted, ref } from 'vue';
19
20
  import { cn } from '@/lib/utils';
20
21
 
@@ -13,6 +13,7 @@
13
13
  </template>
14
14
 
15
15
  <script setup lang="ts">
16
+ import { useGantt } from '../../../composables/useGantt';
16
17
  import { cn } from '@/lib/utils';
17
18
 
18
19
  export interface GanttSidebarGroupProps {
@@ -11,6 +11,7 @@
11
11
  </template>
12
12
 
13
13
  <script setup lang="ts">
14
+ import { useGantt } from '../../../composables/useGantt';
14
15
  import { cn } from '@/lib/utils';
15
16
 
16
17
  export interface GanttSidebarItemProps {
@@ -7,6 +7,8 @@
7
7
  </template>
8
8
 
9
9
  <script setup lang="ts">
10
+ import { throttle } from '../../../utils/function';
11
+ import { useGantt } from '../../../composables/useGantt';
10
12
  import { computed, onMounted, onUnmounted, ref } from 'vue';
11
13
  import { cn } from '@/lib/utils';
12
14
 
@@ -17,6 +17,8 @@
17
17
  </template>
18
18
 
19
19
  <script setup lang="ts">
20
+ import { formatDateTime } from '../../../utils/date';
21
+ import { useGantt } from '../../../composables/useGantt';
20
22
  import { computed } from 'vue';
21
23
  import { cn } from '@/lib/utils';
22
24
 
@@ -25,6 +25,7 @@
25
25
  </template>
26
26
 
27
27
  <script setup lang="ts">
28
+ import { useGantt } from '../../../composables/useGantt';
28
29
  const gantt = useGantt();
29
30
 
30
31
  const handleZoomIn = () => {
@@ -14,5 +14,5 @@ export { default as GanttCreateMarkerTrigger } from './GanttCreateMarkerTrigger.
14
14
  export { default as GanttZoomControls } from './GanttZoomControls.vue';
15
15
 
16
16
  // Gantt composable and types
17
- export type { GanttFeature, GanttRange } from '@/composables/useGantt';
17
+ export type { GanttFeature, GanttRange } from '../../../composables/useGantt';
18
18
  export type { GanttMarkerProps } from './GanttMarker.vue';
@@ -6,6 +6,7 @@
6
6
  </template>
7
7
 
8
8
  <script setup lang="ts">
9
+ import { useKanbanContext } from '../../../composables/useKanban';
9
10
  import { computed, ref } from 'vue';
10
11
  import { makeDroppable } from '@vue-dnd-kit/core';
11
12
  import { cn } from '@/lib/utils';
@@ -9,6 +9,7 @@
9
9
  </template>
10
10
 
11
11
  <script setup lang="ts" generic="T extends KanbanItemProps">
12
+ import { useKanbanContext } from '../../../composables/useKanban';
12
13
  import { computed, ref } from 'vue';
13
14
  import { makeDraggable } from '@vue-dnd-kit/core';
14
15
  import { cn } from '@/lib/utils';
@@ -8,6 +8,7 @@
8
8
  </template>
9
9
 
10
10
  <script setup lang="ts" generic="T extends KanbanItemProps">
11
+ import { useKanbanContext } from '../../../composables/useKanban';
11
12
  import { computed } from 'vue';
12
13
  import { cn } from '@/lib/utils';
13
14
 
@@ -5,4 +5,4 @@ export { default as KanbanCards } from './KanbanCards.vue';
5
5
  export { default as KanbanHeader } from './KanbanHeader.vue';
6
6
 
7
7
  // Export types
8
- export type { KanbanItemProps, KanbanColumnProps } from '@/composables/useKanban';
8
+ export type { KanbanItemProps, KanbanColumnProps } from '../../../composables/useKanban';
@@ -1,3 +1,4 @@
1
+ import { toLowerCase } from '../utils/function';
1
2
  import { ref, type Ref } from 'vue';
2
3
  import { useNuxtApp } from 'nuxt/app';
3
4