build(projects): update tsconfig、eslintrc

This commit is contained in:
Soybean
2022-03-12 16:21:40 +08:00
parent 4093dcd6dc
commit 75de2b0604
131 changed files with 1174 additions and 1140 deletions

View File

@@ -38,7 +38,7 @@ type Option = DropdownOption & {
const props = withDefaults(defineProps<Props>(), {
visible: false,
currentPath: ''
currentPath: '',
});
const emit = defineEmits<Emits>();
@@ -52,7 +52,7 @@ const dropdownVisible = computed({
},
set(visible: boolean) {
emit('update:visible', visible);
}
},
});
function hide() {
@@ -64,29 +64,29 @@ const options = computed<Option[]>(() => [
label: '重新加载',
key: 'reload-current',
disabled: props.currentPath !== tab.activeTab,
icon: iconifyRender('ant-design:reload-outlined')
icon: iconifyRender('ant-design:reload-outlined'),
},
{
label: '关闭',
key: 'close-current',
disabled: props.currentPath === tab.homeTab.path,
icon: iconifyRender('ant-design:close-outlined')
icon: iconifyRender('ant-design:close-outlined'),
},
{
label: '关闭其他',
key: 'close-other',
icon: iconifyRender('ant-design:column-width-outlined')
icon: iconifyRender('ant-design:column-width-outlined'),
},
{
label: '关闭左侧',
key: 'close-left',
icon: iconifyRender('mdi:format-horizontal-align-left')
icon: iconifyRender('mdi:format-horizontal-align-left'),
},
{
label: '关闭右侧',
key: 'close-right',
icon: iconifyRender('mdi:format-horizontal-align-right')
}
icon: iconifyRender('mdi:format-horizontal-align-right'),
},
]);
const actionMap = new Map<DropdownKey, () => void>([
@@ -94,32 +94,32 @@ const actionMap = new Map<DropdownKey, () => void>([
'reload-current',
() => {
app.reloadPage();
}
},
],
[
'close-current',
() => {
tab.removeTab(props.currentPath);
}
},
],
[
'close-other',
() => {
tab.clearTab([props.currentPath]);
}
},
],
[
'close-left',
() => {
tab.clearLeftTab(props.currentPath);
}
},
],
[
'close-right',
() => {
tab.clearRightTab(props.currentPath);
}
]
},
],
]);
function handleDropdown(optionKey: string) {

View File

@@ -64,7 +64,7 @@ const dropdown = reactive({
visible: false,
x: 0,
y: 0,
currentPath: ''
currentPath: '',
});
function showDropdown() {
dropdown.visible = true;
@@ -92,7 +92,7 @@ watch(
getActiveTabClientX();
},
{
immediate: true
immediate: true,
}
);