Fix lints in timeline and sub-note-content

This commit is contained in:
Norm 2022-08-19 15:36:22 -04:00
parent b79cb711ac
commit aa56cf5813
Signed by untrusted user: norm
GPG key ID: 7123E30E441E80DE
2 changed files with 5 additions and 7 deletions

View file

@ -33,7 +33,6 @@ const props = defineProps<{
note: misskey.entities.Note;
}>();
const isLong = (
props.note.cw == null && props.note.text != null && (
(props.note.text.split('\n').length > 9) ||

View file

@ -20,13 +20,12 @@
</template>
<script lang="ts" setup>
import { onMounted, onUnmounted, reactive, ref, watch } from 'vue';
import { useWidgetPropsManager, Widget, WidgetComponentEmits, WidgetComponentExpose, WidgetComponentProps } from './widget';
import { ref } from 'vue';
import { useWidgetPropsManager, Widget, WidgetComponentExpose } from './widget';
import { GetFormResultType } from '@/scripts/form';
import * as os from '@/os';
import MkContainer from '@/components/ui/container.vue';
import XTimeline from '@/components/timeline.vue';
import { $i } from '@/account';
import { i18n } from '@/i18n';
const name = 'timeline';
@ -63,7 +62,7 @@ type WidgetProps = GetFormResultType<typeof widgetPropsDef>;
//const props = defineProps<WidgetComponentProps<WidgetProps>>();
//const emit = defineEmits<WidgetComponentEmits<WidgetProps>>();
const props = defineProps<{ widget?: Widget<WidgetProps>; }>();
const emit = defineEmits<{ (ev: 'updateProps', props: WidgetProps); }>();
const emit = defineEmits<{ (ev: 'updateProps', widgetProps: WidgetProps); }>();
const { widgetProps, configure, save } = useWidgetPropsManager(name,
widgetPropsDef,
@ -73,12 +72,12 @@ const { widgetProps, configure, save } = useWidgetPropsManager(name,
const menuOpened = ref(false);
const setSrc = (src) => {
const setSrc = (src): void => {
widgetProps.src = src;
save();
};
const choose = async (ev) => {
const choose = async (ev): Promise<void> => {
menuOpened.value = true;
const [antennas, lists] = await Promise.all([
os.api('antennas/list'),