Merge master

This commit is contained in:
fredtempez 2020-02-01 20:52:49 +01:00
commit 17051b35d1
3 changed files with 51 additions and 37 deletions

View File

@ -1791,6 +1791,10 @@ class layout extends common {
break;
case 'youtubeId':
$socialUrl = 'https://www.youtube.com/channel/';
$title = 'Chaîne YouTube';
break;
case 'youtubeUserId':
$socialUrl = 'https://www.youtube.com/user/';
$title = 'YouTube';
break;
case 'githubId':
@ -1801,7 +1805,7 @@ class layout extends common {
$socialUrl = '';
}
if($socialId !== '') {
$socials .= '<a href="' . $socialUrl . $socialId . '" onclick="window.open(this.href);return false" data-tippy-content="' . $title . '">' . template::ico(substr($socialName, 0, -2)) . '</a>';
$socials .= '<a href="' . $socialUrl . $socialId . '" onclick="window.open(this.href);return false" data-tippy-content="' . $title . '">' . template::ico(substr(str_replace('User','',$socialName), 0, -2)) . '</a>';
}
}
if($socials !== '') {

View File

@ -398,6 +398,7 @@ class config extends common {
'pinterestId' => $this->getInput('configSocialPinterestId'),
'twitterId' => $this->getInput('configSocialTwitterId'),
'youtubeId' => $this->getInput('configSocialYoutubeId'),
'youtubeUserId' => $this->getInput('configSocialYoutubeUserId'),
'githubId' => $this->getInput('configSocialGithubId')
],
'timezone' => $this->getInput('configTimezone', helper::FILTER_STRING_SHORT, true),

View File

@ -124,45 +124,54 @@
'checked' => $this->getData(['config', 'autoUpdate']),
'help' => 'Vérification quotidienne des mises à jour.'
]); ?>
</div>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col6">
<div class="block">
<h4>Réseaux sociaux</h4>
<div class="row">
<div class="col6">
<?php echo template::text('configSocialFacebookId', [
'help' => 'Saisissez votre ID : https://www.facebook.com/[ID].',
'label' => 'Facebook',
'value' => $this->getData(['config', 'social', 'facebookId'])
]); ?>
</div>
<div class="col6">
<?php echo template::text('configSocialInstagramId', [
'help' => 'Saisissez votre ID : https://www.instagram.com/[ID].',
'label' => 'Instagram',
'value' => $this->getData(['config', 'social', 'instagramId'])
]); ?>
</div>
</div>
<div class="row">
<div class="col6">
<?php echo template::text('configSocialYoutubeId', [
'help' => 'Saisissez votre ID : https://www.youtube.com/channel/[ID].',
'label' => 'Youtube',
'value' => $this->getData(['config', 'social', 'youtubeId'])
]); ?>
</div>
<div class="col6">
<div class="col4">
<?php echo template::text('configSocialTwitterId', [
'help' => 'Saisissez votre ID : https://twitter.com/[ID].',
'label' => 'Twitter',
'value' => $this->getData(['config', 'social', 'twitterId'])
]); ?>
'value' => $this->getData(['config', 'social', 'twitterId'])
]); ?>
</div>
</div>
<div class="row">
<div class="col4">
<?php echo template::text('configSocialYoutubeId', [
'help' => 'ID de la chaîne : https://www.youtube.com/channel/[ID].',
'label' => 'Chaîne Youtube',
'value' => $this->getData(['config', 'social', 'youtubeId'])
]); ?>
</div>
<div class="col4">
<?php echo template::text('configSocialYoutubeUserId', [
'help' => 'Saisissez votre ID Utilisateur : https://www.youtube.com/user/[ID].',
'label' => 'Youtube',
'value' => $this->getData(['config', 'social', 'youtubeUserId'])
]); ?>
</div>
<div class="col4">
<?php echo template::text('configSocialPinterestId', [
'help' => 'Saisissez votre ID : https://pinterest.com/[ID].',
'label' => 'Pinterest',
'value' => $this->getData(['config', 'social', 'pinterestId'])
]); ?>
</div>
</div>
<div class="row">
<div class="col4 offset2">
<?php echo template::text('configSocialGithubId', [
'help' => 'Saisissez votre ID Github : https://github.com/[ID].',
'label' => 'Github',
'value' => $this->getData(['config', 'social', 'githubId'])
]); ?>
</div>
<div class="col4">
<?php echo template::text('configSocialLinkedinId', [
'help' => 'Saisissez votre ID Linkedin : https://fr.linkedin.com/in/[ID].',
'label' => 'Linkedin',
'value' => $this->getData(['config', 'social', 'linkedinId'])
]); ?>
</div>
</div>
</div>
<div class="row">