This commit is contained in:
2026-05-31 21:33:49 +08:00
parent 7fe94c7067
commit 7de0a87f27
2 changed files with 32 additions and 7 deletions
+27 -2
View File
@@ -4,6 +4,7 @@ import api from '@/api'
import type { IAlterInfo } from '@/api/info/type'
import { getImageURL } from '@/utils/images'
import router from '@/router'
import { useDialog } from '@/components/hooks/dialog'
function job_icon(child: IAlterInfo) {
return {
@@ -13,7 +14,9 @@ function job_icon(child: IAlterInfo) {
}
export default defineComponent(async () => {
const ignores = ['empty']
// const ignores = ['empty']
const { show, close, randomId } = useDialog()
// 获取角色相关信息,判定是否开放
function choose_job(child: IAlterInfo) {
@@ -27,7 +30,28 @@ export default defineComponent(async () => {
if (child.open) {
const options = child.options ?? []
if (options.length > 0) {
return
const id = randomId()
return await show({
id,
content: '请选择职业版本',
action: () => {
return (
<div class="flex items-center justify-around flex-wrap" style="width:200px">
{renderList(options, (option) => (
<calc-button
class="!w-40% !mb-2"
onClick={() => {
window.open('/character/' + (option.value || option.name), '_blank')
close(id, 'ok')
}}
>
{option.title}
</calc-button>
))}
</div>
)
},
})
} else {
return window.open('/character/' + (child.value || child.name), '_blank')
}
@@ -110,6 +134,7 @@ export default defineComponent(async () => {
class="flex flex-col"
style={`position: absolute;top: ${30 + 82 * 0}px;left: 800px;width: 160px;height: 150px;`}
onClick={() => router.push({ path: '/dnfhelper' })}
v-show={false}
>
<div
class="w-70px h-50px bg-no-repeat"