Compare commits
No commits in common. "main" and "v0.7.1" have entirely different histories.
4 changed files with 19 additions and 46 deletions
|
@ -29,7 +29,6 @@ mirror_list = {
|
|||
"aliyun": "https://mirrors.aliyun.com/pypi/simple/",
|
||||
"tuna": "https://mirrors.tuna.tsinghua.edu.cn/pypi/web/simple",
|
||||
"sjtu": "https://mirror.sjtu.edu.cn/pypi/web/simple",
|
||||
"ustc": "https://mirrors.ustc.edu.cn/pypi/simple",
|
||||
}
|
||||
|
||||
# 实例文件夹名
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
import 'vfonts/Lato.css'
|
||||
import 'vfonts/FiraCode.css'
|
||||
import './styles/global.css'
|
||||
|
||||
|
|
|
@ -175,8 +175,8 @@ async function handle_migrate(key) {
|
|||
显示日志
|
||||
</div>
|
||||
</n-space>
|
||||
<n-list class="instance_list" bordered>
|
||||
<n-list-item class="instance_list_item">
|
||||
<n-list class="instance-list" bordered>
|
||||
<n-list-item>
|
||||
<template #prefix>
|
||||
<n-checkbox
|
||||
v-model:checked="check_all"
|
||||
|
@ -187,26 +187,29 @@ async function handle_migrate(key) {
|
|||
>
|
||||
</template>
|
||||
</n-list-item>
|
||||
<n-list-item class="instance_list_item" v-for="(item, index) in conf.instances" :key="index">
|
||||
<n-list-item v-for="(item, index) in conf.instances" :key="index">
|
||||
<template #prefix>
|
||||
<n-checkbox v-model:checked="item.checked"></n-checkbox>
|
||||
</template>
|
||||
<n-space vertical>
|
||||
<n-space v-if="update_instance_name_index != index">
|
||||
<n-text class="instance_name">{{ item.name }}</n-text>
|
||||
<n-text>{{ item.name }}</n-text>
|
||||
<n-button size="tiny" @click="start_update_instance_name(index)">
|
||||
<template #icon>
|
||||
<n-icon :component="Pencil"></n-icon>
|
||||
</template>
|
||||
</n-button>
|
||||
<n-button @click="open_folder(item.path)" size="tiny">
|
||||
<template #icon>
|
||||
<n-icon :component="Folder"></n-icon>
|
||||
</template>
|
||||
</n-button>
|
||||
</n-space>
|
||||
<n-input
|
||||
v-else
|
||||
class="instance_name_input"
|
||||
:ref="(el) => setInstanceNameInputRef(el, index)"
|
||||
v-model:value="item.name"
|
||||
@blur="end_update_instance_name"
|
||||
clearable
|
||||
></n-input>
|
||||
</n-space>
|
||||
<template #suffix>
|
||||
|
@ -231,11 +234,6 @@ async function handle_migrate(key) {
|
|||
<n-icon :component="Stop"></n-icon>
|
||||
</template>
|
||||
</n-button>
|
||||
<n-button type="primary" ghost size="small" @click="open_folder(item.path)">
|
||||
<template #icon>
|
||||
<n-icon :component="Folder"></n-icon>
|
||||
</template>
|
||||
</n-button>
|
||||
<n-popconfirm @positive-click="delete_instance(index, item.path)">
|
||||
<template #trigger>
|
||||
<n-button type="error" ghost size="small">
|
||||
|
@ -258,18 +256,9 @@ async function handle_migrate(key) {
|
|||
.launch-btn {
|
||||
height: 38px;
|
||||
}
|
||||
.instance_list {
|
||||
.instance-list {
|
||||
overflow: auto;
|
||||
}
|
||||
.instance_list_item {
|
||||
height: 50px;
|
||||
}
|
||||
.instance_name {
|
||||
margin-left: 12px;
|
||||
}
|
||||
.instance_name_input {
|
||||
height: 35px;
|
||||
}
|
||||
.log {
|
||||
min-height: 40vh;
|
||||
max-height: 40vh;
|
||||
|
@ -280,6 +269,5 @@ async function handle_migrate(key) {
|
|||
}
|
||||
.is_show_log_switch {
|
||||
margin-right: 20px;
|
||||
text-align: center;
|
||||
}
|
||||
</style>
|
||||
|
|
|
@ -20,28 +20,6 @@ const steps = computed(() => [
|
|||
cwd: 'mower-ng'
|
||||
}
|
||||
])
|
||||
const mirror_options = [
|
||||
{
|
||||
label: 'PyPI',
|
||||
value: 'pypi',
|
||||
},
|
||||
{
|
||||
label: '阿里云镜像源',
|
||||
value: 'aliyun',
|
||||
},
|
||||
{
|
||||
label: '上海交通大学镜像源',
|
||||
value: 'sjtu',
|
||||
},
|
||||
{
|
||||
label: '清华大学镜像源',
|
||||
value: 'tuna',
|
||||
},
|
||||
{
|
||||
label: '中国科学技术大学镜像源',
|
||||
value: 'ustc',
|
||||
}
|
||||
]
|
||||
provide('steps', steps)
|
||||
const current_step = ref(1)
|
||||
provide('current_step', current_step)
|
||||
|
@ -62,7 +40,14 @@ provide('current_state', current_state)
|
|||
</n-radio-group>
|
||||
</n-form-item>
|
||||
<n-form-item label="PyPI 仓库镜像" :label-style="form_item_label_style">
|
||||
<n-select v-model:value="conf.mirror" :options="mirror_options" :disabled="running" />
|
||||
<n-radio-group v-model:value="conf.mirror" :disabled="running">
|
||||
<n-flex>
|
||||
<n-radio value="pypi">PyPI</n-radio>
|
||||
<n-radio value="aliyun">阿里云镜像站</n-radio>
|
||||
<n-radio value="sjtu">上海交通大学镜像站</n-radio>
|
||||
<n-radio value="tuna">清华大学镜像站</n-radio>
|
||||
</n-flex>
|
||||
</n-radio-group>
|
||||
</n-form-item>
|
||||
</n-form>
|
||||
<n-steps :current="current_step" :status="current_state" size="small">
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue