diff --git a/src/assets/icons/eye.svg b/src/assets/icons/eye.svg new file mode 100644 index 0000000..9b4d290 --- /dev/null +++ b/src/assets/icons/eye.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/src/views/main-header.vue b/src/views/main-header.vue index 406d949..54f3a83 100644 --- a/src/views/main-header.vue +++ b/src/views/main-header.vue @@ -124,7 +124,7 @@ } const onSettings = () => { hideProfilePopover() - console.log('settings') + router.push('/settings') } const onLogout = () => { hideProfilePopover() diff --git a/src/views/setting/components/Radio.vue b/src/views/setting/components/Radio.vue index 8d2376c..7c05e54 100644 --- a/src/views/setting/components/Radio.vue +++ b/src/views/setting/components/Radio.vue @@ -29,6 +29,7 @@ const props = defineProps<{ modelValue: string | number | boolean | Array | null options: Option[] // 按钮选项数组 multiple?: boolean // 是否支持多选,默认为 false + max?: number // 多选时最多可选数量,不传则不限制 }>() const emit = defineEmits<{ @@ -54,6 +55,9 @@ const selectOption = (value: any) => { if (index >= 0) { current.splice(index, 1) } else { + if (typeof props.max === 'number' && props.max > 0 && current.length >= props.max) { + current.shift() + } current.push(value) } emit('update:modelValue', current) diff --git a/src/views/setting/index.vue b/src/views/setting/index.vue index 831ddb5..1a8eed3 100644 --- a/src/views/setting/index.vue +++ b/src/views/setting/index.vue @@ -18,9 +18,7 @@ - - - + {{ fullName }} @@ -28,113 +26,66 @@ - - - - - FIRST NAME - - - - - - LAST NAME - - - + + + + FIRST NAME + {{ displayData.firstName }} + + - - - USERNAME - - + + LAST NAME + {{ displayData.lastName }} + + - Your public username on Stylish Parade. - - - - ROLE - - - - Select up to 2 labels that suit you. - + + USERNAME + {{ displayData.username }} + + + + + Your public username on Stylish Parade. + + + ROLE + + + + + Select up to 2 labels that suit you. + + SOCIAL LINKS Link {{ index + 1 }} - + {{ item }} + - + + + + + - - - - - - - FIRST NAME - {{ displayData.firstName }} - - - LAST NAME - {{ displayData.lastName }} - - - - - USERNAME - {{ displayData.username }} - - Your public username on Stylish Parade. - - - ROLE - - - {{ item }} - - - {{ item }} - - - - Select up to 2 labels that suit you. - - - SOCIAL LINKS - - - Link {{ index + 1 }} - {{ item }} - - - - - + @@ -147,72 +98,72 @@ + - EMAIL - - - {{ displayData.email }} - - CANCEL - - - - - {{ displayData.email }} - + + EMAIL + {{ displayData.email }} + + CANCEL + + - + NEW EMAIL ADDRESS - + - Verify + Verify - + - PASSWORD - - - ......... - - CANCEL - - - - - ......... - + + PASSWORD + ......... + + CANCEL + + - - - NEW PASSWORD - - - - You must satisfy ALL password conditions to register. + + NEW PASSWORD + + + You must satisfy ALL password conditions to register. + - - CURRENT PASSWORD - - - + + CURRENT PASSWORD + + - + + @@ -227,40 +178,26 @@ DISPLAY LANGUAGE - - - - - - - - - {{ displayData.language }} - + + {{ displayData.language }} + + + + + + REGION - - - - - - - - - {{ displayData.region }} - + + {{ displayData.region }} + + + + + + @@ -285,10 +222,8 @@