feat(falukant): add visibility toggle for settings widget and update navigation labels
All checks were successful
Deploy to production / deploy (push) Successful in 2m8s
All checks were successful
Deploy to production / deploy (push) Successful in 2m8s
This commit is contained in:
@@ -57,7 +57,7 @@
|
|||||||
<div v-else>{{ setting }}</div>
|
<div v-else>{{ setting }}</div>
|
||||||
<span v-if="setting.unit"> {{ setting.unit }}</span>
|
<span v-if="setting.unit"> {{ setting.unit }}</span>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td v-if="showVisibility">
|
||||||
<select v-model="setting.visibility.id"
|
<select v-model="setting.visibility.id"
|
||||||
@change="handleVisibilityChange(setting.id, setting.visibility.id)">
|
@change="handleVisibilityChange(setting.id, setting.visibility.id)">
|
||||||
<option v-for="visibility in possibleVisibilities" :key="visibility.id" :value="visibility.id">
|
<option v-for="visibility in possibleVisibilities" :key="visibility.id" :value="visibility.id">
|
||||||
@@ -103,6 +103,10 @@ export default {
|
|||||||
settingsType: {
|
settingsType: {
|
||||||
type: String,
|
type: String,
|
||||||
required: true
|
required: true
|
||||||
|
},
|
||||||
|
showVisibility: {
|
||||||
|
type: Boolean,
|
||||||
|
default: true
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
@@ -116,8 +120,12 @@ export default {
|
|||||||
async fetchSettings() {
|
async fetchSettings() {
|
||||||
if (this.user && this.user.id) {
|
if (this.user && this.user.id) {
|
||||||
try {
|
try {
|
||||||
const visibilityResponse = await apiClient.get('/api/settings/visibilities');
|
if (this.showVisibility) {
|
||||||
this.possibleVisibilities = visibilityResponse.data;
|
const visibilityResponse = await apiClient.get('/api/settings/visibilities');
|
||||||
|
this.possibleVisibilities = visibilityResponse.data;
|
||||||
|
} else {
|
||||||
|
this.possibleVisibilities = [];
|
||||||
|
}
|
||||||
const userid = this.user.id;
|
const userid = this.user.id;
|
||||||
const response = await apiClient.post('/api/settings/filter', {
|
const response = await apiClient.post('/api/settings/filter', {
|
||||||
userid: userid,
|
userid: userid,
|
||||||
|
|||||||
@@ -56,6 +56,7 @@
|
|||||||
"m-settings": {
|
"m-settings": {
|
||||||
"homepage": "Sinugdanan",
|
"homepage": "Sinugdanan",
|
||||||
"account": "Account",
|
"account": "Account",
|
||||||
|
"falukant": "Falukant",
|
||||||
"personal": "Kaugalingon",
|
"personal": "Kaugalingon",
|
||||||
"view": "Panagway",
|
"view": "Panagway",
|
||||||
"flirt": "Flirt",
|
"flirt": "Flirt",
|
||||||
|
|||||||
@@ -56,6 +56,7 @@
|
|||||||
"m-settings": {
|
"m-settings": {
|
||||||
"homepage": "Startseite",
|
"homepage": "Startseite",
|
||||||
"account": "Account",
|
"account": "Account",
|
||||||
|
"falukant": "Falukant",
|
||||||
"personal": "Persönliches",
|
"personal": "Persönliches",
|
||||||
"view": "Aussehen",
|
"view": "Aussehen",
|
||||||
"flirt": "Flirt",
|
"flirt": "Flirt",
|
||||||
|
|||||||
@@ -56,6 +56,7 @@
|
|||||||
"m-settings": {
|
"m-settings": {
|
||||||
"homepage": "Homepage",
|
"homepage": "Homepage",
|
||||||
"account": "Account",
|
"account": "Account",
|
||||||
|
"falukant": "Falukant",
|
||||||
"personal": "Personal",
|
"personal": "Personal",
|
||||||
"view": "Appearance",
|
"view": "Appearance",
|
||||||
"flirt": "Flirt",
|
"flirt": "Flirt",
|
||||||
|
|||||||
@@ -56,6 +56,7 @@
|
|||||||
"m-settings": {
|
"m-settings": {
|
||||||
"homepage": "Página de inicio",
|
"homepage": "Página de inicio",
|
||||||
"account": "Account",
|
"account": "Account",
|
||||||
|
"falukant": "Falukant",
|
||||||
"personal": "Personal",
|
"personal": "Personal",
|
||||||
"view": "Apariencia",
|
"view": "Apariencia",
|
||||||
"flirt": "Flirt",
|
"flirt": "Flirt",
|
||||||
|
|||||||
@@ -56,6 +56,7 @@
|
|||||||
"m-settings": {
|
"m-settings": {
|
||||||
"homepage": "Page d'accueil",
|
"homepage": "Page d'accueil",
|
||||||
"account": "compte",
|
"account": "compte",
|
||||||
|
"falukant": "Falukant",
|
||||||
"personal": "Persönliches",
|
"personal": "Persönliches",
|
||||||
"view": "Regarder",
|
"view": "Regarder",
|
||||||
"flirt": "flirter",
|
"flirt": "flirter",
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<h2>{{ $t("settings.falukant.title") }}</h2>
|
<h2>{{ $t("settings.falukant.title") }}</h2>
|
||||||
<SettingsWidget :settingsType="'falukant'" />
|
<SettingsWidget :settingsType="'falukant'" :show-visibility="false" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user