Skip to content

Commit

Permalink
feat: 更新任务参数
Browse files Browse the repository at this point in the history
  • Loading branch information
bakashigure committed Oct 23, 2023
1 parent abb1621 commit 736e9f5
Show file tree
Hide file tree
Showing 3 changed files with 55 additions and 54 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,10 @@ import {
NCollapseItem,
NModal,
NPopconfirm,
NProgress,
NSelect,
NSpace,
NTooltip,
useDialog,
useMessage,
} from 'naive-ui'
Expand Down
88 changes: 34 additions & 54 deletions packages/renderer/src/components/Task/configurations/Recruit.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<script setup lang="ts">
import _ from 'lodash'
import { NCheckbox, NFormItem, NInputNumber } from 'naive-ui'
import { NCheckbox, NFormItem, NInputNumber, NTooltip } from 'naive-ui'
import { inject } from 'vue'
import type { GetConfig } from './types'
Expand Down Expand Up @@ -104,14 +104,7 @@ function handleExpediteUpdate(value: number | null) {
@update:value="handleExpediteUpdate"
/>
</NFormItem>
<NFormItem
label="自动刷新3星tag"
:show-label="true"
size="small"
label-align="left"
label-placement="left"
:show-feedback="false"
>
<NFormItem size="small" label-align="left" label-placement="left" :show-feedback="false">
<NCheckbox
:disabled="configurationDisabled.re"
:checked="configurations.refresh"
Expand All @@ -120,34 +113,29 @@ function handleExpediteUpdate(value: number | null) {
handleUpdateConfiguration('refresh', checked)
}
"
/>
>
自动刷新3星tag
</NCheckbox>
</NFormItem>
<NFormItem
label="跳过小车"
:show-label="true"
size="small"
label-align="left"
label-placement="left"
:show-feedback="false"
>
<NCheckbox
:disabled="configurationDisabled.re"
:checked="configurations.skip_robot"
@update:checked="
checked => {
handleUpdateConfiguration('skip_robot', checked)
}
"
/>
<NFormItem size="small" label-align="left" label-placement="left" :show-feedback="false">
<NTooltip trigger="hover">
<template #trigger>
<NCheckbox
:disabled="configurationDisabled.re"
:checked="configurations.skip_robot"
@update:checked="
checked => {
handleUpdateConfiguration('skip_robot', checked)
}
"
>
跳过小车
</NCheckbox>
</template>
是否在识别到小车词条时跳过
</NTooltip>
</NFormItem>
<NFormItem
label="自动确认3星"
:show-label="true"
size="small"
label-align="left"
label-placement="left"
:show-feedback="false"
>
<NFormItem size="small" label-align="left" label-placement="left" :show-feedback="false">
<NCheckbox
:disabled="configurationDisabled.re"
:checked="configurations.confirm.includes(3)"
Expand All @@ -156,16 +144,11 @@ function handleExpediteUpdate(value: number | null) {
handleConfirmUpdate(checked, 3)
}
"
/>
>
自动确认3星</NCheckbox
>
</NFormItem>
<NFormItem
label="自动确认4星"
:show-label="true"
size="small"
label-align="left"
label-placement="left"
:show-feedback="false"
>
<NFormItem size="small" label-align="left" label-placement="left" :show-feedback="false">
<NCheckbox
:disabled="configurationDisabled.re"
:checked="configurations.confirm.includes(4)"
Expand All @@ -174,16 +157,11 @@ function handleExpediteUpdate(value: number | null) {
handleConfirmUpdate(checked, 4)
}
"
/>
>
自动确认4星</NCheckbox
>
</NFormItem>
<NFormItem
label="自动确认5星"
:show-label="true"
size="small"
label-align="left"
label-placement="left"
:show-feedback="false"
>
<NFormItem size="small" label-align="left" label-placement="left" :show-feedback="false">
<NCheckbox
:disabled="configurationDisabled.re"
:checked="configurations.confirm.includes(5)"
Expand All @@ -192,7 +170,9 @@ function handleExpediteUpdate(value: number | null) {
handleConfirmUpdate(checked, 5)
}
"
/>
>
自动确认5星</NCheckbox
>
</NFormItem>
</div>
</template>
18 changes: 18 additions & 0 deletions packages/renderer/src/components/Task/configurations/Rogue.vue
Original file line number Diff line number Diff line change
Expand Up @@ -399,6 +399,24 @@ const squadOptionsSelector = computed(() => {
是否可以是非好友助战干员,仅在勾选'开局干员使用助战'时有效
</NTooltip>
</NFormItem>
<NFormItem>
<NTooltip trigger="hover">
<template #trigger>
<NCheckbox
:disabled="
configurationDisabled.re || props.configurations.theme !== RogueTheme.Mizuki
"
:checked="props.configurations.refresh_trader_with_dice"
@update:checked="
value => handleUpdateConfiguration('refresh_trader_with_dice', value)
"
>
刷新商店(指路鳞)
</NCheckbox>
</template>
是否用骰子刷新商店购买特殊商品,例如[指路鳞],目前只在水月主题下有效
</NTooltip>
</NFormItem>
</NSpace>
</NForm>
</div>
Expand Down

0 comments on commit 736e9f5

Please sign in to comment.