Resolve editor/type warnings (#7687)

* resolve editor/type warnings

* dont rename props
This commit is contained in:
Nitwel
2021-08-30 22:54:17 +02:00
committed by GitHub
parent b3e041fc09
commit 607e32ea36
22 changed files with 80 additions and 74 deletions

View File

@@ -224,10 +224,6 @@ body {
opacity: 0.1;
}
}
input {
//
}
}
.prepend,

View File

@@ -21,7 +21,7 @@ import { isPlainObject } from 'lodash';
export default defineComponent({
props: {
error: {
type: [Object, Error] as PropType<any>,
type: [Object, Error] as PropType<Record<string, any>>,
required: true,
},
},

View File

@@ -61,11 +61,10 @@
<script lang="ts">
import { useI18n } from 'vue-i18n';
import { defineComponent, PropType, computed, ref } from 'vue';
import { Field } from '@directus/shared/types';
import { Field, ValidationError } from '@directus/shared/types';
import FormFieldLabel from './form-field-label.vue';
import FormFieldMenu from './form-field-menu.vue';
import FormFieldInterface from './form-field-interface.vue';
import { ValidationError } from '@/types';
import { getJSType } from '@/utils/get-js-type';
import { isEqual } from 'lodash';

View File

@@ -152,7 +152,7 @@ export default defineComponent({
keydown: processValue,
blur: (e: Event) => {
trimIfEnabled();
attrs?.onBlur?.(e);
if (typeof attrs.onBlur === 'function') attrs.onBlur(e);
},
focus: (e: PointerEvent) => emit('focus', e),
}));

View File

@@ -90,6 +90,8 @@ export default defineComponent({
emits: ['update:modelValue'],
setup(props, { emit }) {
const visiblePages = computed<number[]>(() => {
if (props.totalVisible === undefined) return [];
let startPage: number;
let endPage: number;