sprintify-ui 0.8.54 → 0.8.56
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/sprintify-ui.es.js +699 -692
- package/dist/types/composables/paginatedData.d.ts +1 -1
- package/dist/types/services/gantt/types.d.ts +1 -0
- package/package.json +1 -1
- package/src/components/BaseDataIterator.stories.js +2 -2
- package/src/components/BaseDataIterator.vue +7 -1
- package/src/components/BaseGantt.vue +4 -4
- package/src/composables/paginatedData.ts +1 -1
- package/src/services/gantt/timescale.ts +7 -0
- package/src/services/gantt/types.ts +1 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ComputedRef, Ref } from 'vue';
|
|
2
2
|
import { Collection, PaginatedCollection, ResourceCollection, PaginationMetadata } from '@/types';
|
|
3
|
-
export declare function useHasPaginatedData(data: Ref<Collection | PaginatedCollection | ResourceCollection | null | undefined>, page?: ComputedRef<number>, perPage?: ComputedRef<number>): {
|
|
3
|
+
export declare function useHasPaginatedData(data: Ref<Collection | PaginatedCollection | ResourceCollection | null | undefined>, page?: ComputedRef<number>, perPage?: ComputedRef<number | undefined>): {
|
|
4
4
|
items: ComputedRef<Collection>;
|
|
5
5
|
paginationMetadata: ComputedRef<PaginationMetadata | null>;
|
|
6
6
|
lastPage: ComputedRef<number>;
|
package/package.json
CHANGED
|
@@ -721,7 +721,13 @@ const dataInternal = computed<ResourceCollection | PaginatedCollection | Collect
|
|
|
721
721
|
const { items, paginationMetadata, lastPage } = useHasPaginatedData(
|
|
722
722
|
dataInternal,
|
|
723
723
|
page,
|
|
724
|
-
computed(() =>
|
|
724
|
+
computed(() => {
|
|
725
|
+
if (dataMode.value == REMOTE) {
|
|
726
|
+
return undefined;
|
|
727
|
+
}
|
|
728
|
+
|
|
729
|
+
return props.perPage;
|
|
730
|
+
}),
|
|
725
731
|
);
|
|
726
732
|
|
|
727
733
|
const itemsInternal = computed(() => {
|
|
@@ -111,11 +111,11 @@
|
|
|
111
111
|
|
|
112
112
|
<line
|
|
113
113
|
v-if="tick.align == 'middle'"
|
|
114
|
-
:x1="tick.width"
|
|
115
|
-
:x2="tick.width"
|
|
114
|
+
:x1="tick.width - tick.width"
|
|
115
|
+
:x2="tick.width - tick.width"
|
|
116
116
|
:y1="24"
|
|
117
117
|
:y2="HEADER_HEIGHT"
|
|
118
|
-
:stroke="slate[300]"
|
|
118
|
+
:stroke="tick.thick ? slate[400] : slate[300]"
|
|
119
119
|
></line>
|
|
120
120
|
</g>
|
|
121
121
|
</svg>
|
|
@@ -223,7 +223,7 @@
|
|
|
223
223
|
:y1="0"
|
|
224
224
|
:y2="height"
|
|
225
225
|
stroke="black"
|
|
226
|
-
:opacity="0.
|
|
226
|
+
:opacity="tick.thick ? 0.2 : 0.05"
|
|
227
227
|
></line>
|
|
228
228
|
</g>
|
|
229
229
|
</svg>
|
|
@@ -11,7 +11,7 @@ import { getItems } from '@/utils/getApiData';
|
|
|
11
11
|
export function useHasPaginatedData(
|
|
12
12
|
data: Ref<Collection | PaginatedCollection | ResourceCollection | null | undefined>,
|
|
13
13
|
page?: ComputedRef<number>,
|
|
14
|
-
perPage?: ComputedRef<number>,
|
|
14
|
+
perPage?: ComputedRef<number | undefined>,
|
|
15
15
|
) {
|
|
16
16
|
const items = computed(() => {
|
|
17
17
|
return getItems(data.value);
|
|
@@ -130,12 +130,19 @@ export class Timescale {
|
|
|
130
130
|
|
|
131
131
|
const label = current.toFormat(this.scale.tick.format);
|
|
132
132
|
|
|
133
|
+
let thick = false;
|
|
134
|
+
|
|
135
|
+
if (this.scale.tick.step == 'day' && [6, 1].includes(current.weekday)) {
|
|
136
|
+
thick = true;
|
|
137
|
+
}
|
|
138
|
+
|
|
133
139
|
const tick = {
|
|
134
140
|
date: current,
|
|
135
141
|
x,
|
|
136
142
|
width,
|
|
137
143
|
label,
|
|
138
144
|
align: this.scale.tick.align,
|
|
145
|
+
thick: thick,
|
|
139
146
|
} as Tick;
|
|
140
147
|
|
|
141
148
|
ticks.push(tick);
|