|
| 1 | +const uxAndAppearanceSettings = [ |
| 2 | + { |
| 3 | + id: 0, |
| 4 | + categoryName: "管家助手", |
| 5 | + child: [ |
| 6 | + { |
| 7 | + index: 0, |
| 8 | + id: "autoHideEasiAssistant", |
| 9 | + type: "switch", |
| 10 | + name: "自动最小化管家助手", |
| 11 | + description: "管家启动后, 自动将桌面右下角管家助手最小化至 Fab 形态", |
| 12 | + restart: true, |
| 13 | + reload: false, |
| 14 | + associateVal: ["ssa.ux.easiAssistant.notDisplay"], |
| 15 | + auraIf: () => true, |
| 16 | + defaultValue: false, |
| 17 | + auraDisable: () => { |
| 18 | + if (global.__HUGO_AURA_CONFIG__.ssa.ux.easiAssistant.notDisplay) { |
| 19 | + return { value: true, tooltip: '禁用 "隐藏管家助手" 以继续' }; |
| 20 | + } else { |
| 21 | + return { value: false }; |
| 22 | + } |
| 23 | + }, |
| 24 | + valueGetter: () => { |
| 25 | + return global.__HUGO_AURA_CONFIG__.ssa.ux.easiAssistant.autoHide; |
| 26 | + }, |
| 27 | + callbackFn: (newVal) => { |
| 28 | + if (typeof newVal !== "boolean") return; |
| 29 | + global.__HUGO_AURA_CONFIG__.ssa.ux.easiAssistant.autoHide = newVal; |
| 30 | + }, |
| 31 | + }, |
| 32 | + { |
| 33 | + index: 1, |
| 34 | + id: "notDisplayEasiAssistant", |
| 35 | + type: "switch", |
| 36 | + name: "隐藏管家助手", |
| 37 | + description: "管家启动后, 管家助手窗口将不再显示", |
| 38 | + restart: true, |
| 39 | + reload: false, |
| 40 | + associateVal: ["ssa.ux.easiAssistant.autoHide"], |
| 41 | + auraIf: () => true, |
| 42 | + defaultValue: false, |
| 43 | + auraDisable: () => { |
| 44 | + if (global.__HUGO_AURA_CONFIG__.ssa.ux.easiAssistant.autoHide) { |
| 45 | + return { value: true, tooltip: '禁用 "自动最小化管家助手" 以继续' }; |
| 46 | + } else { |
| 47 | + return { value: false }; |
| 48 | + } |
| 49 | + }, |
| 50 | + valueGetter: () => { |
| 51 | + return global.__HUGO_AURA_CONFIG__.ssa.ux.easiAssistant.notDisplay; |
| 52 | + }, |
| 53 | + callbackFn: (newVal) => { |
| 54 | + if (typeof newVal !== "boolean") return; |
| 55 | + global.__HUGO_AURA_CONFIG__.ssa.ux.easiAssistant.notDisplay = newVal; |
| 56 | + }, |
| 57 | + }, |
| 58 | + ], |
| 59 | + }, |
| 60 | +]; |
| 61 | + |
| 62 | +module.exports = { uxAndAppearanceSettings }; |
0 commit comments