Refactor BackButton component in Show.vue to use route name instead of URL; update PostAuthorsList.vue to correct conditional rendering for authors list display.
This commit is contained in:
@@ -92,7 +92,7 @@ export default {
|
|||||||
<BasicPageContainer breakpoint="md">
|
<BasicPageContainer breakpoint="md">
|
||||||
<div class="space-y-5 md:space-y-10">
|
<div class="space-y-5 md:space-y-10">
|
||||||
<div class="space-y-3">
|
<div class="space-y-3">
|
||||||
<BackButton :link="$page.props.urlPrev" title="Назад"/>
|
<BackButton link="client.post.index" title="Назад"/>
|
||||||
<BaseBreadcrumbs :breadcrumbs="breadcrumbs">
|
<BaseBreadcrumbs :breadcrumbs="breadcrumbs">
|
||||||
<BreadcrumbsItem title="Новости" :url="route('client.post.index')" />
|
<BreadcrumbsItem title="Новости" :url="route('client.post.index')" />
|
||||||
<BreadcrumbsItem :title="post.data.title" :url="$page.url" />
|
<BreadcrumbsItem :title="post.data.title" :url="$page.url" />
|
||||||
|
|||||||
@@ -1,15 +1,10 @@
|
|||||||
<template>
|
<template>
|
||||||
<!-- List -->
|
<dl v-if="!(authors[0] === 'Без автора' && null)" class="flex flex-col sm:flex-row gap-1 items-baseline">
|
||||||
<dl v-if="authors[0] === 'Без автора' && null" class="flex flex-col sm:flex-row gap-1 items-baseline">
|
|
||||||
<!-- items-baseline выравнивает по базовой линии -->
|
|
||||||
<dt class="min-w-40">
|
<dt class="min-w-40">
|
||||||
<h3 class="block text-sm text-gray-500 m-0 underline">Над статьей работали:</h3>
|
<h3 class="block text-sm text-gray-500 m-0 underline">Над статьей работали:</h3>
|
||||||
<!-- m-0 убирает margin -->
|
|
||||||
</dt>
|
</dt>
|
||||||
<dd class="m-0">
|
<dd class="m-0">
|
||||||
<!-- m-0 для dd на всякий случай -->
|
|
||||||
<ul class="m-0 inline-flex flex-wrap items-center">
|
<ul class="m-0 inline-flex flex-wrap items-center">
|
||||||
<!-- flex-wrap и items-center для красивого списка -->
|
|
||||||
<li
|
<li
|
||||||
v-for="(author, index) in authors"
|
v-for="(author, index) in authors"
|
||||||
:key="index"
|
:key="index"
|
||||||
|
|||||||
Reference in New Issue
Block a user