mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2025-10-25 00:50:39 +00:00
Unify date/time dependencies (#2891)
Remove all date/time-related dependencies from the ui except `dayjs` and use `dayjs` for all tasks. --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
This commit is contained in:
@@ -5,9 +5,9 @@
|
||||
<script lang="ts" setup>
|
||||
import { computed, toRef } from 'vue';
|
||||
|
||||
import { useDate } from '~/compositions/useDate';
|
||||
import { useElapsedTime } from '~/compositions/useElapsedTime';
|
||||
import { PipelineStep, PipelineWorkflow } from '~/lib/api/types';
|
||||
import { durationAsNumber } from '~/utils/duration';
|
||||
|
||||
const props = defineProps<{
|
||||
step?: PipelineStep;
|
||||
@@ -16,6 +16,7 @@ const props = defineProps<{
|
||||
|
||||
const step = toRef(props, 'step');
|
||||
const workflow = toRef(props, 'workflow');
|
||||
const { durationAsNumber } = useDate();
|
||||
|
||||
const durationRaw = computed(() => {
|
||||
const start = (step.value ? step.value?.start_time : workflow.value?.start_time) || 0;
|
||||
|
||||
Reference in New Issue
Block a user