chore: better variable typing
continuous-integration/drone/pr Build is failing Details

This commit is contained in:
Dominik Pschenitschni 2022-06-23 03:28:48 +02:00
parent 4005b91f88
commit 551f3f54e1
Signed by: dpschen
GPG Key ID: B257AC0149F43A77
7 changed files with 10 additions and 8 deletions

View File

@ -63,7 +63,7 @@ const LOAD_NOTIFICATIONS_INTERVAL = 10000
const store = useStore()
const router = useRouter()
const allNotifications = ref([])
const allNotifications = ref<NotificationModel[]>([])
const showNotifications = ref(false)
const popup = ref(null)

View File

@ -198,7 +198,7 @@ const props = defineProps({
const {t} = useI18n({useScope: 'global'})
const linkShares = ref([])
const linkShares = ref<LinkShareModel[]>([])
const linkShareService = shallowReactive(new LinkShareService())
const selectedRight = ref(RIGHTS.READ)
const name = ref('')

View File

@ -188,8 +188,8 @@ const commentEdit = reactive(new TaskCommentModel())
const newComment = reactive(new TaskCommentModel())
const saved = ref(null)
const saving = ref(null)
const saved = ref<TaskModel['id'] | null>(null)
const saving = ref<TaskModel['id'] | null>(null)
const userAvatar = computed(() => store.state.auth.info.getAvatarUrl(48))
const currentUserId = computed(() => store.state.auth.info.id)

View File

@ -47,6 +47,7 @@ const props = defineProps({
required: true,
},
canWrite: {
type: Boolean,
required: true,
},
})

View File

@ -38,7 +38,7 @@ const emit = defineEmits(['update:modelValue'])
const store = useStore()
const {t} = useI18n({useScope: 'global'})
const list = reactive<ListModel>(new ListModel())
const list: ListModel= reactive(new ListModel())
watch(
() => props.modelValue,

View File

@ -55,12 +55,13 @@
</template>
<script setup lang="ts">
import {ref, reactive, watch} from 'vue'
import TaskModel from '@/models/task'
import {ref, reactive, watch, type PropType} from 'vue'
import {TASK_REPEAT_MODES, type RepeatAfter} from '@/models/task'
import type TaskModel from '@/models/task'
const props = defineProps({
modelValue: {
type: Object as PropType<TaskModel>,
default: () => ({}),
required: true,
},

View File

@ -63,7 +63,7 @@ async function createNewList() {
}
showError.value = false
list.namespaceId = parseInt(route.params.namespaceId)
list.namespaceId = Number(route.params.namespaceId as string)
const newList = await store.dispatch('lists/createList', list)
await router.push({
name: 'list.index',