Skip to content

Commit 02d0672

Browse files
committed
refactor: resolve oxlint warnings
1 parent 1e7a71f commit 02d0672

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

app/composables/useCommandPaletteCommands.ts

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -145,10 +145,11 @@ export function useCommandPaletteCommands() {
145145
]
146146
: rootViewCommands.value
147147

148-
return base.map(command => ({
149-
...command,
150-
keywords: [...command.keywords, groupLabel(command.group)],
151-
}))
148+
return base.map(command =>
149+
Object.assign(command, {
150+
keywords: [...command.keywords, groupLabel(command.group)],
151+
}),
152+
)
152153
})
153154

154155
const { results } = useFuse(trimmedQuery, commands, {

app/composables/useCommandPaletteGlobalCommands.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,12 +120,12 @@ export function useCommandPaletteGlobalCommands() {
120120
const currentBackgroundThemeLabel = computed(() => {
121121
const id = selectedBackgroundTheme.value
122122
if (!id) return t('settings.background_themes.neutral')
123-
return backgroundThemes.value.find(t => t.id === id)?.label ?? id
123+
return backgroundThemes.value.find(theme => theme.id === id)?.label ?? id
124124
})
125125
const currentBackgroundThemePreview = computed(() => {
126126
const id = selectedBackgroundTheme.value
127127
if (!id) return null
128-
return backgroundThemes.value.find(t => t.id === id)?.value ?? null
128+
return backgroundThemes.value.find(theme => theme.id === id)?.value ?? null
129129
})
130130
const localeCommands = computed<CommandPaletteCommand[]>(() =>
131131
locales.value.map(entry => {

0 commit comments

Comments
 (0)