chore(portal,operator): upgrade to Nuxt 4
Upgrade both Nuxt apps to Nuxt 4.4.6 (vue-tsc 3, TypeScript 5.6, undici 7) and add a root tsconfig.json to each app. Fix the strict-null / noUncheckedIndexedAccess errors surfaced by Nuxt 4's stricter generated tsconfig and vue-tsc 3. Drop the nuxt-oidc-auth pnpm patch (Nuxt 4 fixes the prepare:types crash natively).
This commit is contained in:
@@ -15,7 +15,7 @@ const initials = computed(() =>
|
||||
.split(' ')
|
||||
.filter(Boolean)
|
||||
.slice(0, 2)
|
||||
.map((p) => p[0].toUpperCase())
|
||||
.map((p) => p.charAt(0).toUpperCase())
|
||||
.join(''),
|
||||
)
|
||||
|
||||
|
||||
@@ -10,7 +10,10 @@ const route = useRoute()
|
||||
|
||||
const open = ref(false)
|
||||
|
||||
const displayName = computed(() => user.value?.userInfo?.name || user.value?.userName || 'operator')
|
||||
const displayName = computed<string>(() => {
|
||||
const name = (user.value?.userInfo as { name?: string } | undefined)?.name
|
||||
return name || (user.value?.userName as string | undefined) || 'operator'
|
||||
})
|
||||
const email = computed(() => (user.value?.userInfo as { email?: string } | undefined)?.email ?? '')
|
||||
|
||||
function toggle() {
|
||||
|
||||
Reference in New Issue
Block a user