forked from cms/tibi-svelte-starter
Verlinkung zu externen URLs für Article hinzugefügt.
This commit is contained in:
parent
25a39dfac0
commit
65e8b7ffc8
@ -45,9 +45,9 @@ meta:
|
|||||||
meta:
|
meta:
|
||||||
label: { de: "Allgemein", en: "General" }
|
label: { de: "Allgemein", en: "General" }
|
||||||
subFields:
|
subFields:
|
||||||
|
- source: path
|
||||||
- source: locale
|
- source: locale
|
||||||
- source: tags
|
- source: tags
|
||||||
- source: path
|
|
||||||
- source: priority
|
- source: priority
|
||||||
- name: meta
|
- name: meta
|
||||||
meta:
|
meta:
|
||||||
@ -125,6 +125,15 @@ hooks:
|
|||||||
|
|
||||||
# Feldliste der Kollektion
|
# Feldliste der Kollektion
|
||||||
fields:
|
fields:
|
||||||
|
- name: path
|
||||||
|
type: string
|
||||||
|
index: [single, unique]
|
||||||
|
meta:
|
||||||
|
hideInRoot: true
|
||||||
|
label: { de: "Pfad", en: "Path" }
|
||||||
|
helperText:
|
||||||
|
de: "Der Pfad muss eindeutig sein und ohne ein Slash (/) beginnen und enden."
|
||||||
|
en: "The path must be unique and must start and end without a slash (/)."
|
||||||
- !include fields/_locale.yml
|
- !include fields/_locale.yml
|
||||||
- name: tags
|
- name: tags
|
||||||
type: string[]
|
type: string[]
|
||||||
@ -145,15 +154,6 @@ fields:
|
|||||||
name: "name"
|
name: "name"
|
||||||
params:
|
params:
|
||||||
sort: "name"
|
sort: "name"
|
||||||
- name: path
|
|
||||||
type: string
|
|
||||||
index: [single, unique]
|
|
||||||
meta:
|
|
||||||
hideInRoot: true
|
|
||||||
label: { de: "Pfad", en: "Path" }
|
|
||||||
helperText:
|
|
||||||
de: "Der Pfad muss eindeutig sein und ohne ein Slash (/) beginnen und enden."
|
|
||||||
en: "The path must be unique and must start and end without a slash (/)."
|
|
||||||
- name: priority
|
- name: priority
|
||||||
type: number
|
type: number
|
||||||
meta:
|
meta:
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
import { fade } from "svelte/transition"
|
import { fade } from "svelte/transition"
|
||||||
|
import { _ } from "svelte-i18n"
|
||||||
// import { navigate } from "svelte-routing"
|
// import { navigate } from "svelte-routing"
|
||||||
|
|
||||||
import TibiArticleMediaFile from "./TibiArticleMediaFile.svelte"
|
import TibiArticleMediaFile from "./TibiArticleMediaFile.svelte"
|
||||||
@ -86,6 +87,14 @@
|
|||||||
<div class="article-teaser">{@html article?.content?.types?.teaser}</div>
|
<div class="article-teaser">{@html article?.content?.types?.teaser}</div>
|
||||||
{/if}
|
{/if}
|
||||||
|
|
||||||
|
{#if article?.link?.url}
|
||||||
|
<a
|
||||||
|
href="{article?.link?.url}"
|
||||||
|
target="{article?.link?.target ? article?.link?.target : '_self'}"
|
||||||
|
class="article-link">{@html article?.link?.text ? article?.link?.text : $_("details")}</a
|
||||||
|
>
|
||||||
|
{/if}
|
||||||
|
|
||||||
{#if article?.content?.types?.details && showDetails}
|
{#if article?.content?.types?.details && showDetails}
|
||||||
<div class="article-details">{@html article?.content?.types?.details}</div>
|
<div class="article-details">{@html article?.content?.types?.details}</div>
|
||||||
{/if}
|
{/if}
|
||||||
@ -104,6 +113,14 @@
|
|||||||
<div class="article-teaser">{@html article?.content?.types?.teaser}</div>
|
<div class="article-teaser">{@html article?.content?.types?.teaser}</div>
|
||||||
{/if}
|
{/if}
|
||||||
|
|
||||||
|
{#if article?.link?.url}
|
||||||
|
<a
|
||||||
|
href="{article?.link?.url}"
|
||||||
|
target="{article?.link?.target ? article?.link?.target : '_self'}"
|
||||||
|
class="article-link">{@html article?.link?.text ? article?.link?.text : $_("details")}</a
|
||||||
|
>
|
||||||
|
{/if}
|
||||||
|
|
||||||
{#if article?.content?.types?.details && showDetails}
|
{#if article?.content?.types?.details && showDetails}
|
||||||
<div class="article-details">{@html article?.content?.types?.details}</div>
|
<div class="article-details">{@html article?.content?.types?.details}</div>
|
||||||
{/if}
|
{/if}
|
||||||
@ -131,9 +148,18 @@
|
|||||||
<div class="article-teaser">{@html article?.content?.types?.teaser}</div>
|
<div class="article-teaser">{@html article?.content?.types?.teaser}</div>
|
||||||
{/if}
|
{/if}
|
||||||
|
|
||||||
|
{#if article?.link?.url}
|
||||||
|
<a
|
||||||
|
href="{article?.link?.url}"
|
||||||
|
target="{article?.link?.target ? article?.link?.target : '_self'}"
|
||||||
|
class="article-link">{@html article?.link?.text ? article?.link?.text : $_("details")}</a
|
||||||
|
>
|
||||||
|
{/if}
|
||||||
|
|
||||||
{#if article?.content?.types?.details && showDetails}
|
{#if article?.content?.types?.details && showDetails}
|
||||||
<div class="article-details">{@html article?.content?.types?.details}</div>
|
<div class="article-details">{@html article?.content?.types?.details}</div>
|
||||||
{/if}
|
{/if}
|
||||||
|
|
||||||
{#if article?.content?.types?.media?.files?.length}
|
{#if article?.content?.types?.media?.files?.length}
|
||||||
<TibiArticleMediaFile
|
<TibiArticleMediaFile
|
||||||
collectionName="articles"
|
collectionName="articles"
|
||||||
@ -165,6 +191,14 @@
|
|||||||
<div class="article-teaser">{@html article?.content?.types?.teaser}</div>
|
<div class="article-teaser">{@html article?.content?.types?.teaser}</div>
|
||||||
{/if}
|
{/if}
|
||||||
|
|
||||||
|
{#if article?.link?.url}
|
||||||
|
<a
|
||||||
|
href="{article?.link?.url}"
|
||||||
|
target="{article?.link?.target ? article?.link?.target : '_self'}"
|
||||||
|
class="article-link">{@html article?.link?.text ? article?.link?.text : $_("details")}</a
|
||||||
|
>
|
||||||
|
{/if}
|
||||||
|
|
||||||
{#if article?.content?.types?.details && showDetails}
|
{#if article?.content?.types?.details && showDetails}
|
||||||
<div class="article-details">{@html article?.content?.types?.details}</div>
|
<div class="article-details">{@html article?.content?.types?.details}</div>
|
||||||
{/if}
|
{/if}
|
||||||
|
@ -20,4 +20,8 @@ article,
|
|||||||
font-size: 1.4rem;
|
font-size: 1.4rem;
|
||||||
line-height: 1.8rem;
|
line-height: 1.8rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.article-link {
|
||||||
|
text-decoration: underline;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -3,5 +3,6 @@
|
|||||||
"pageNotFoundInformation": "Die gesuchte Seite existiert nicht oder es ist ein anderer Fehler aufgetreten.<br/>Gehen Sie <a href=\"{backUrl}\"><strong>zurück</strong></a> oder gehen Sie zu <a href=\"{url}\"><strong>{url}</strong></a>, um eineneue Richtung zu wählen.",
|
"pageNotFoundInformation": "Die gesuchte Seite existiert nicht oder es ist ein anderer Fehler aufgetreten.<br/>Gehen Sie <a href=\"{backUrl}\"><strong>zurück</strong></a> oder gehen Sie zu <a href=\"{url}\"><strong>{url}</strong></a>, um eineneue Richtung zu wählen.",
|
||||||
"connectedContentNotFound": "Zur aktuellen Seite <a href=\"{url}\"><strong>{url}</strong></a> wurde für die gewählte Sprache \"<strong>{lang}</strong>\" keine Übersetzung gefunden!",
|
"connectedContentNotFound": "Zur aktuellen Seite <a href=\"{url}\"><strong>{url}</strong></a> wurde für die gewählte Sprache \"<strong>{lang}</strong>\" keine Übersetzung gefunden!",
|
||||||
"de": "Deutsch",
|
"de": "Deutsch",
|
||||||
"en": "Englisch"
|
"en": "Englisch",
|
||||||
|
"details": "Details"
|
||||||
}
|
}
|
@ -3,5 +3,6 @@
|
|||||||
"pageNotFoundInformation": "The page you are looking for doesn't exist or an other error occurred.<br/><a href=\"{backUrl}\"><strong>Go back</strong></a>, or head over to <a href=\"{url}\"><strong>{url}</strong></a> to choose a new direction.",
|
"pageNotFoundInformation": "The page you are looking for doesn't exist or an other error occurred.<br/><a href=\"{backUrl}\"><strong>Go back</strong></a>, or head over to <a href=\"{url}\"><strong>{url}</strong></a> to choose a new direction.",
|
||||||
"connectedContentNotFound": "No translation was found for the selected language \"<strong>{lang}</strong>\" for the current page <a href=\"{url}\"><strong>{url}</strong></a>!",
|
"connectedContentNotFound": "No translation was found for the selected language \"<strong>{lang}</strong>\" for the current page <a href=\"{url}\"><strong>{url}</strong></a>!",
|
||||||
"de": "German",
|
"de": "German",
|
||||||
"en": "English"
|
"en": "English",
|
||||||
|
"details": "Details"
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user