feat: add texts configuration
This commit is contained in:
@@ -31,7 +31,7 @@
|
||||
</div>
|
||||
|
||||
<div v-else-if="hasMore === false" class="text-xs text-center mt-4 pt-4 mb-2 border-t">
|
||||
{{ settings.noMoreProductsMessage }}
|
||||
{{ settings.texts.no_more_products }}
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -23,7 +23,11 @@ export const useSettingsStore = defineStore('settings', {
|
||||
'--product_list_title_max_lines': 2,
|
||||
}
|
||||
},
|
||||
noMoreProductsMessage: '🔚 Это всё по текущему запросу. Попробуйте уточнить фильтры или поиск.',
|
||||
texts: {
|
||||
no_more_products: 'Нет товаров',
|
||||
empty_cart: 'Корзина пуста',
|
||||
order_created_success: 'Заказ успешно оформлен.',
|
||||
},
|
||||
}),
|
||||
|
||||
actions: {
|
||||
@@ -46,6 +50,7 @@ export const useSettingsStore = defineStore('settings', {
|
||||
this.feature_coupons = settings.feature_coupons;
|
||||
this.feature_vouchers = settings.feature_vouchers;
|
||||
this.currency_code = settings.currency_code;
|
||||
this.texts = settings.texts;
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
@@ -125,7 +125,7 @@
|
||||
class="text-center rounded-2xl"
|
||||
>
|
||||
<div class="text-5xl mb-4">🛒</div>
|
||||
<p class="text-lg mb-3">Ваша корзина пуста</p>
|
||||
<p class="text-lg mb-3">{{ settings.texts.empty_cart }}</p>
|
||||
<RouterLink class="btn btn-primary" to="/">Начать покупки</RouterLink>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
</div>
|
||||
|
||||
<p class="text-2xl font-bold mb-3">Спасибо за заказ!</p>
|
||||
<p class="text-center mb-4">Ваш заказ успешно оформлен и будет обработан в ближайшее время.</p>
|
||||
<p class="text-center mb-4">{{ settings.texts.order_created_success }}</p>
|
||||
|
||||
<ul v-if="checkout.order" class="list w-full bg-base-200 mb-4">
|
||||
<li class="list-row flex justify-between">
|
||||
@@ -41,9 +41,11 @@ import {useCheckoutStore} from "@/stores/CheckoutStore.js";
|
||||
import {onMounted} from "vue";
|
||||
import {useYaMetrikaStore} from "@/stores/yaMetrikaStore.js";
|
||||
import {useRoute} from "vue-router";
|
||||
import {useSettingsStore} from "@/stores/SettingsStore.js";
|
||||
|
||||
const checkout = useCheckoutStore();
|
||||
const yaMetrika = useYaMetrikaStore();
|
||||
const settings = useSettingsStore();
|
||||
const route = useRoute();
|
||||
|
||||
onMounted(() => {
|
||||
|
||||
Reference in New Issue
Block a user