Blog 6.6 layout
This commit is contained in:
parent
ae494b8d66
commit
85de808044
@ -89,7 +89,7 @@ class blog extends common
|
||||
];
|
||||
|
||||
//Paramètre longueur maximale des commentaires en nb de caractères
|
||||
public static $commentLength = [
|
||||
public static $commentsLength = [
|
||||
100 => '100 signes',
|
||||
250 => '250 signes',
|
||||
500 => '500 signes',
|
||||
@ -97,11 +97,19 @@ class blog extends common
|
||||
];
|
||||
|
||||
public static $articlesLenght = [
|
||||
0 => 'Article complet en pleine page',
|
||||
200 => 'Tableau : couverture + 200 signes',
|
||||
400 => 'Tableau : couverture + 400 signes',
|
||||
600 => 'Tableau : couverture + 600 signes',
|
||||
800 => 'Tableau : couverture + 800 signes'
|
||||
0 => 'Articles complets',
|
||||
600 => '600 signes',
|
||||
800 => '800 signes',
|
||||
1000 => '1000 signes',
|
||||
1200 => '1200 signes',
|
||||
1400 => '1400 signes',
|
||||
1600 => '1600 signes',
|
||||
1800 => '1800 signes',
|
||||
];
|
||||
|
||||
public static $articlesLayout = [
|
||||
false => 'Classique',
|
||||
true => 'Moderne',
|
||||
];
|
||||
|
||||
// Permissions d'un article
|
||||
@ -556,11 +564,12 @@ class blog extends common
|
||||
[
|
||||
'feeds' => $this->getInput('blogOptionShowFeeds', helper::FILTER_BOOLEAN),
|
||||
'feedsLabel' => $this->getInput('blogOptionFeedslabel', helper::FILTER_STRING_SHORT),
|
||||
'layout' => $this->getInput('blogOptionArticlesLayout', helper::FILTER_BOOLEAN),
|
||||
'articlesLenght' => $this->getInput('blogOptionArticlesLayout', helper::FILTER_BOOLEAN) === false ? $this->getInput('blogOptionArticlesLenght', helper::FILTER_INT): 0,
|
||||
'itemsperPage' => $this->getInput('blogOptionItemsperPage', helper::FILTER_INT, true),
|
||||
'articlesLenght' => $this->getInput('blogOptionArticlesLenght', helper::FILTER_INT),
|
||||
'versionData' => $this->getData(['module', $this->getUrl(0), 'config', 'versionData']),
|
||||
'dateFormat' => $this->getInput('blogOptionDateFormat'),
|
||||
'timeFormat' => $this->getInput('blogOptionTimeFormat'),
|
||||
'versionData' => $this->getData(['module', $this->getUrl(0), 'config', 'versionData']),
|
||||
]
|
||||
]);
|
||||
// Valeurs en sortie
|
||||
|
@ -60,10 +60,17 @@
|
||||
"Supprimer cet article ?": "Diesen Artikel löschen?",
|
||||
"Supprimer le commentaire ?": "Den Kommentar löschen?",
|
||||
"Supprimer tous les commentaires ?": "Alle Kommentare löschen?",
|
||||
"Tableau:couverture + 200 signes": "Tabelle:Cover + 200 Zeichen",
|
||||
"Tableau:couverture + 400 signes": "Tabelle:Abdeckung + 400 Zeichen",
|
||||
"Tableau:couverture + 600 signes": "Tabelle:Abdeckung + 600 Zeichen",
|
||||
"Tableau:couverture + 800 signes": "Tabelle:Abdeckung + 800 Zeichen",
|
||||
"200 signes": "200 Zeichen",
|
||||
"400 signes": "400 Zeichen",
|
||||
"600 signes": "600 Zeichen",
|
||||
"1000 signes": "1000 Zeichen",
|
||||
"1200 signes": "1200 Zeichen",
|
||||
"1400 signes": "1400 Zeichen",
|
||||
"1600 signes": "1600 Zeichen",
|
||||
"1800 signes": "1800 Zeichen",
|
||||
"Classique": "Klassisch",
|
||||
"Moderne": "Modern",
|
||||
"Disposition": "Anordnung",
|
||||
"Taille optimale de l'image de couverture:920 x 350 pixels.": "Optimale Größe des Titelbildes:920 x 350 Pixel.",
|
||||
"Texte de l'étiquette": "Beschriftungstext",
|
||||
"Tous les groupes": "Alle Gruppen",
|
||||
|
@ -60,10 +60,17 @@
|
||||
"Supprimer cet article ?": "Delete this article?",
|
||||
"Supprimer le commentaire ?": "Delete the comment?",
|
||||
"Supprimer tous les commentaires ?": "Delete all comments?",
|
||||
"Tableau:couverture + 200 signes": "Table:cover + 200 signs",
|
||||
"Tableau:couverture + 400 signes": "Table:cover + 400 signs",
|
||||
"Tableau:couverture + 600 signes": "Table:cover + 600 signs",
|
||||
"Tableau:couverture + 800 signes": "Table:cover + 800 signs",
|
||||
"200 signes": "200 characters",
|
||||
"400 signes": "400 characters",
|
||||
"600 signes": "600 characters",
|
||||
"1000 signes": "1000 characters",
|
||||
"1200 signes": "1200 characters",
|
||||
"1400 signes": "1400 characters",
|
||||
"1600 signes": "1600 characters",
|
||||
"1800 signes": "1800 characters",
|
||||
"Classique": "Classic",
|
||||
"Moderne": "Modern",
|
||||
"Disposition": "Layout",
|
||||
"Taille optimale de l'image de couverture:920 x 350 pixels.": "Optimal size of the cover image:920 x 350 pixels.",
|
||||
"Texte de l'étiquette": "Label text",
|
||||
"Tous les groupes": "All groups",
|
||||
|
@ -60,10 +60,17 @@
|
||||
"Supprimer cet article ?": "¿Borrar este artículo?",
|
||||
"Supprimer le commentaire ?": "¿Borrar el comentario?",
|
||||
"Supprimer tous les commentaires ?": "¿Borrar todos los comentarios?",
|
||||
"Tableau:couverture + 200 signes": "Tabla:portada + 200 caracteres",
|
||||
"Tableau:couverture + 400 signes": "Tabla:portada + 400 caracteres",
|
||||
"Tableau:couverture + 600 signes": "Tabla:portada + 600 caracteres",
|
||||
"Tableau:couverture + 800 signes": "Tabla:portada + 800 caracteres",
|
||||
"200 signes": "200 caracteres",
|
||||
"400 signes": "400 caracteres",
|
||||
"600 signes": "600 caracteres",
|
||||
"1000 signes": "1000 caracteres",
|
||||
"1200 signes": "1200 caracteres",
|
||||
"1400 signes": "1400 caracteres",
|
||||
"1600 signes": "1600 caracteres",
|
||||
"1800 signes": "1800 caracteres",
|
||||
"Classique": "Clásico",
|
||||
"Moderne": "Moderno",
|
||||
"Disposition": "Distribución",
|
||||
"Taille optimale de l'image de couverture:920 x 350 pixels.": "Tamaño de imagen de portada óptimo:920 x 350 píxeles.",
|
||||
"Texte de l'étiquette": "Texto de la etiqueta",
|
||||
"Tous les groupes": "Todos los grupos",
|
||||
|
@ -60,10 +60,18 @@
|
||||
"Supprimer cet article ?": "",
|
||||
"Supprimer le commentaire ?": "",
|
||||
"Supprimer tous les commentaires ?": "",
|
||||
"Tableau:couverture + 200 signes": "",
|
||||
"Tableau:couverture + 400 signes": "",
|
||||
"Tableau:couverture + 600 signes": "",
|
||||
"Tableau:couverture + 800 signes": "",
|
||||
"200 signes": "",
|
||||
"400 signes": "",
|
||||
"600 signes": "",
|
||||
"1000 signes": "",
|
||||
"1200 signes": "",
|
||||
"1400 signes": "",
|
||||
"1600 signes": "",
|
||||
"1800 signes": "",
|
||||
"Classique": "",
|
||||
"Moderne": "",
|
||||
"Disposition": "",
|
||||
"Aperçus": "",
|
||||
"Taille optimale de l'image de couverture:920 x 350 pixels.": "",
|
||||
"Texte de l'étiquette": "",
|
||||
"Tous les groupes": "",
|
||||
|
@ -60,10 +60,17 @@
|
||||
"Supprimer cet article ?": "Να διαγράψετε αυτό το άρθρο;",
|
||||
"Supprimer le commentaire ?": "Διαγράψτε το σχόλιο;",
|
||||
"Supprimer tous les commentaires ?": "Να διαγράψετε όλα τα σχόλια;",
|
||||
"Tableau:couverture + 200 signes": "Πίνακας:εξώφυλλο + 200 χαρακτήρες",
|
||||
"Tableau:couverture + 400 signes": "Πίνακας:εξώφυλλο + 400 χαρακτήρες",
|
||||
"Tableau:couverture + 600 signes": "Πίνακας:εξώφυλλο + 600 χαρακτήρες",
|
||||
"Tableau:couverture + 800 signes": "Πίνακας:εξώφυλλο + 800 χαρακτήρες",
|
||||
"200 signes": "200 χαρακτήρες",
|
||||
"400 signes": "400 χαρακτήρες",
|
||||
"600 signes": "600 χαρακτήρες",
|
||||
"1000 signes": "1000 χαρακτήρες",
|
||||
"1200 signes": "1200 χαρακτήρες",
|
||||
"1400 signes": "1400 χαρακτήρες",
|
||||
"1600 signes": "1600 χαρακτήρες",
|
||||
"1800 signes": "1800 χαρακτήρες",
|
||||
"Classique": "Κλασικό",
|
||||
"Moderne": "Μοντέρνο",
|
||||
"Disposition": "Διάταξη",
|
||||
"Taille optimale de l'image de couverture:920 x 350 pixels.": "Βέλτιστο μέγεθος εικόνας εξωφύλλου:920 x 350 pixels",
|
||||
"Texte de l'étiquette": "Κείμενο ετικέτας",
|
||||
"Tous les groupes": "Όλες οι ομάδες",
|
||||
|
@ -60,10 +60,17 @@
|
||||
"Supprimer cet article ?": "Elimina questo articolo?",
|
||||
"Supprimer le commentaire ?": "Elimina il commento?",
|
||||
"Supprimer tous les commentaires ?": "Elimina tutti i commenti?",
|
||||
"Tableau:couverture + 200 signes": "",
|
||||
"Tableau:couverture + 400 signes": "",
|
||||
"Tableau:couverture + 600 signes": "",
|
||||
"Tableau:couverture + 800 signes": "",
|
||||
"200 signes": "200 caratteri",
|
||||
"400 signes": "400 caratteri",
|
||||
"600 signes": "600 caratteri",
|
||||
"1000 signes": "1000 caratteri",
|
||||
"1200 signes": "1200 caratteri",
|
||||
"1400 signes": "1400 caratteri",
|
||||
"1600 signes": "1600 caratteri",
|
||||
"1800 signes": "1800 caratteri",
|
||||
"Classique": "Classico",
|
||||
"Moderne": "Moderno",
|
||||
"Disposition": "Layout",
|
||||
"Taille optimale de l'image de couverture:920 x 350 pixels.": "",
|
||||
"Texte de l'étiquette": "Testo dell'etichetta",
|
||||
"Tous les groupes": "Tutti i gruppi",
|
||||
|
@ -60,10 +60,17 @@
|
||||
"Supprimer cet article ?": "Excluir este artigo?",
|
||||
"Supprimer le commentaire ?": "Excluir o comentário?",
|
||||
"Supprimer tous les commentaires ?": "Excluir todos os comentários?",
|
||||
"Tableau:couverture + 200 signes": "",
|
||||
"Tableau:couverture + 400 signes": "",
|
||||
"Tableau:couverture + 600 signes": "",
|
||||
"Tableau:couverture + 800 signes": "",
|
||||
"200 signes": "200 caracteres",
|
||||
"400 signes": "400 caracteres",
|
||||
"600 signes": "600 caracteres",
|
||||
"1000 signes": "1000 caracteres",
|
||||
"1200 signes": "1200 caracteres",
|
||||
"1400 signes": "1400 caracteres",
|
||||
"1600 signes": "1600 caracteres",
|
||||
"1800 signes": "1800 caracteres",
|
||||
"Classique": "Clássico",
|
||||
"Moderne": "Moderno",
|
||||
"Disposition": "Disposição",
|
||||
"Taille optimale de l'image de couverture:920 x 350 pixels.": "",
|
||||
"Texte de l'étiquette": "Texto da etiqueta",
|
||||
"Tous les groupes": "Todos os grupos",
|
||||
|
@ -60,10 +60,17 @@
|
||||
"Supprimer cet article ?": "Bu makale silinsin mi?",
|
||||
"Supprimer le commentaire ?": "Yorum silinsin mi?",
|
||||
"Supprimer tous les commentaires ?": "",
|
||||
"Tableau:couverture + 200 signes": "",
|
||||
"Tableau:couverture + 400 signes": "",
|
||||
"Tableau:couverture + 600 signes": "",
|
||||
"Tableau:couverture + 800 signes": "",
|
||||
"200 signes": "200 karakter",
|
||||
"400 signes": "400 karakter",
|
||||
"600 signes": "600 karakter",
|
||||
"1000 signes": "1000 karakter",
|
||||
"1200 signes": "1200 karakter",
|
||||
"1400 signes": "1400 karakter",
|
||||
"1600 signes": "1600 karakter",
|
||||
"1800 signes": "1800 karakter",
|
||||
"Classique": "Klasik",
|
||||
"Moderne": "Modern",
|
||||
"Disposition": "Düzenleme",
|
||||
"Taille optimale de l'image de couverture:920 x 350 pixels.": "",
|
||||
"Texte de l'étiquette": "Etiket metni",
|
||||
"Tous les groupes": "Tüm gruplar",
|
||||
|
@ -117,7 +117,7 @@
|
||||
<?php echo template::checkbox('blogAddCommentApproved', true, 'Approbation par un modérateur'); ?>
|
||||
</div>
|
||||
<div class="col4 commentOptionsWrapper">
|
||||
<?php echo template::select('blogAddCommentMaxlength', $module::$commentLength,[
|
||||
<?php echo template::select('blogAddCommentMaxlength', $module::$commentsLength,[
|
||||
'help' => 'Choix du nombre maximum de caractères pour chaque commentaire de l\'article, mise en forme html comprise.',
|
||||
'label' => 'Caractères par commentaire'
|
||||
]); ?>
|
||||
|
@ -127,7 +127,7 @@
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4 commentOptionsWrapper">
|
||||
<?php echo template::select('blogEditCommentMaxlength', $module::$commentLength,[
|
||||
<?php echo template::select('blogEditCommentMaxlength', $module::$commentsLength,[
|
||||
'help' => 'Choix du nombre maximum de caractères pour chaque commentaire de l\'article, mise en forme html comprise.',
|
||||
'label' => 'Caractères par commentaire',
|
||||
'selected' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'commentMaxlength'])
|
||||
|
@ -1,10 +1,12 @@
|
||||
.rowArticle {
|
||||
margin-bottom: 10px !important;
|
||||
}
|
||||
|
||||
.blogPicture {
|
||||
float: none;
|
||||
border: 1px;
|
||||
}
|
||||
|
||||
.blogPicture img {
|
||||
width: 100%;
|
||||
height: auto;
|
||||
@ -18,15 +20,18 @@
|
||||
margin-top: 0;
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
|
||||
.blogArticlePicture {
|
||||
height: auto;
|
||||
border: 1px solid lightgray;
|
||||
box-shadow: 1px 1px 5px;
|
||||
}
|
||||
|
||||
.blogArticlePictureleft {
|
||||
float: left;
|
||||
margin: 15px 10px 5px 0;
|
||||
}
|
||||
|
||||
.blogArticlePictureright {
|
||||
float: right;
|
||||
margin: 15px 0 5px 10px;
|
||||
@ -35,32 +40,39 @@
|
||||
.blogPicture:hover {
|
||||
opacity: .7;
|
||||
}
|
||||
|
||||
.row:after {
|
||||
content: " ";
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
|
||||
.blogComment {
|
||||
padding-right: 10px;
|
||||
float: right;
|
||||
}
|
||||
|
||||
.blogTitle {
|
||||
/*background-color: #ECEFF1;*/
|
||||
padding: 0px;
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
|
||||
.blogContent {
|
||||
position: relative;
|
||||
float: left;
|
||||
margin-top: 5px;
|
||||
}
|
||||
.blogDate, .blogEdit {
|
||||
|
||||
.blogDate,
|
||||
.blogEdit {
|
||||
font-size: 0.8em;
|
||||
font-style: italic;
|
||||
/*
|
||||
color: grey;
|
||||
*/
|
||||
}
|
||||
|
||||
@media (max-width: 768px) {
|
||||
.blogContent {
|
||||
display: none;
|
||||
@ -77,15 +89,19 @@
|
||||
.pict20 {
|
||||
width: 20%;
|
||||
}
|
||||
|
||||
.pict30 {
|
||||
width: 30%;
|
||||
}
|
||||
|
||||
.pict40 {
|
||||
width: 40%;
|
||||
}
|
||||
|
||||
.pict50 {
|
||||
width: 50%;
|
||||
}
|
||||
|
||||
.pict100 {
|
||||
width: 100%;
|
||||
margin: 15px 0 20px 0;
|
||||
@ -98,24 +114,31 @@
|
||||
#rssFeed {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
#rssFeed p {
|
||||
display: inline;
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
.rowArticle {
|
||||
.rowArticle,
|
||||
article {
|
||||
position: relative;
|
||||
/* Autres styles pour les articles coupés */
|
||||
}
|
||||
|
||||
.readMoreContainer {
|
||||
position: absolute;
|
||||
}
|
||||
|
||||
.readMoreContainer,
|
||||
.readMoreModernContainer {
|
||||
bottom: 0px;
|
||||
width: 100%;
|
||||
height: 45%;
|
||||
background: linear-gradient(180deg, hsla(0, 0%, 100%, 0) 0, #f6f6f6 100%, #f6f6f6);
|
||||
}
|
||||
|
||||
|
||||
.readMoreButton {
|
||||
position: absolute;
|
||||
width: 20%;
|
||||
|
@ -11,7 +11,8 @@
|
||||
<?php if ($module::$articles): ?>
|
||||
<article>
|
||||
<?php foreach ($module::$articles as $articleId => $article): ?>
|
||||
<?php if ($this->getData(['module', $this->getUrl(0), 'config', 'articlesLenght']) === 0): ?>
|
||||
<?php if ($this->getData(['module', $this->getUrl(0), 'config', 'layout']) === true): ?>
|
||||
<div class="readMoreModernContainer">
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<h2 class="blogTitle">
|
||||
@ -46,7 +47,7 @@
|
||||
<?php echo $this->getData(['module', $this->getUrl(0), 'posts', $articleId, 'content']); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row verticalAlignMiddle">
|
||||
<div class="row">
|
||||
<div class="col6 blogEdit">
|
||||
<!-- Bloc edition -->
|
||||
<?php if (
|
||||
@ -96,8 +97,9 @@
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php else: ?>
|
||||
<div class="row rowArticle">
|
||||
<div class="row">
|
||||
<?php if (
|
||||
$article['picture'] &&
|
||||
file_exists(self::FILE_DIR . 'source/' . $article['picture'])
|
||||
@ -148,10 +150,13 @@
|
||||
<?php $lenght = $this->getData(['module', $this->getUrl(0), 'config', 'articlesLenght']) !== 0 ? $this->getData(['module', $this->getUrl(0), 'config', 'articlesLenght']) : 500 ?>
|
||||
<?php echo helper::subword(strip_tags($article['content'], '<br><p>'), 0, $lenght); ?>...
|
||||
<div class="readMoreContainer">
|
||||
<a href="<?php echo helper::baseUrl() . $this->getUrl(0) . '/' . $articleId; ?>"><button class="readMoreButton">Lire la suite</button></a>
|
||||
<a href="<?php echo helper::baseUrl() . $this->getUrl(0) . '/' . $articleId; ?>"><button
|
||||
class="readMoreButton">Lire la suite</button></a>
|
||||
<div class="readMoreContainer">
|
||||
<a href="<?php echo helper::baseUrl() . $this->getUrl(0) . '/' . $articleId; ?>">
|
||||
<button class="readMoreButton"><?php echo helper::translate('Lire la suite'); ?></button>
|
||||
<button class="readMoreButton">
|
||||
<?php echo helper::translate('Lire la suite'); ?>
|
||||
</button>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -14,11 +14,19 @@
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block">
|
||||
<h4><?php echo helper::translate('Paramètres');?></h4>
|
||||
<h4>
|
||||
<?php echo helper::translate('Paramètres'); ?>
|
||||
</h4>
|
||||
<div class="row">
|
||||
<div class="col4">
|
||||
<?php echo template::select('blogOptionArticlesLenght', $module::$articlesLenght, [
|
||||
<div class="col3">
|
||||
<?php echo template::select('blogOptionArticlesLayout', $module::$articlesLayout, [
|
||||
'label' => 'Disposition',
|
||||
'selected' => $this->getData(['module', $this->getUrl(0), 'config', 'layout'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<?php echo template::select('blogOptionArticlesLenght', $module::$articlesLenght, [
|
||||
'label' => 'Aperçus',
|
||||
'selected' => $this->getData(['module', $this->getUrl(0), 'config', 'articlesLenght'])
|
||||
]); ?>
|
||||
</div>
|
||||
@ -28,13 +36,13 @@
|
||||
'selected' => $this->getData(['module', $this->getUrl(0), 'config', 'itemsperPage'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<div class="col2">
|
||||
<?php echo template::select('blogOptionDateFormat', $module::$dateFormats, [
|
||||
'label' => 'Format des dates',
|
||||
'selected' => $this->getData(['module', $this->getUrl(0), 'config', 'dateFormat'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<div class="col2">
|
||||
<?php echo template::select('blogOptionTimeFormat', $module::$timeFormats, [
|
||||
'label' => 'Format des heures',
|
||||
'selected' => $this->getData(['module', $this->getUrl(0), 'config', 'timeFormat'])
|
||||
@ -42,12 +50,12 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col6">
|
||||
<div class="col8">
|
||||
<?php echo template::checkbox('blogOptionShowFeeds', true, 'Lien du flux RSS', [
|
||||
'checked' => $this->getData(['module', $this->getUrl(0), 'config', 'feeds']),
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col6">
|
||||
<div class="col4">
|
||||
<?php echo template::text('blogOptionFeedslabel', [
|
||||
'label' => 'Texte de l\'étiquette',
|
||||
'value' => $this->getData(['module', $this->getUrl(0), 'config', 'feedsLabel'])
|
||||
@ -61,4 +69,3 @@
|
||||
<div class="moduleVersion">Version n°
|
||||
<?php echo $module::VERSION; ?>
|
||||
</div>
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user