Skip to content

Commit

Permalink
[FEATURE] add setting to make socials enable/disable (#48)
Browse files Browse the repository at this point in the history
  • Loading branch information
DatFaili authored Apr 10, 2024
1 parent 27e0692 commit 0034a51
Show file tree
Hide file tree
Showing 4 changed files with 95 additions and 81 deletions.
11 changes: 6 additions & 5 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -1,71 +1,81 @@
settings:
socials.facebook.link:
label: 'Facebook Link'
description: 'Link to your Facebook profile'
type: string
default: ''
socials.instagram.link:
label: 'Instagram Link'
description: 'Link to your Instagram profile'
type: string
default: ''
socials.threads.link:
label: 'Threads Link'
description: 'Link to your Threads profile'
type: string
default: ''
socials.whatsapp.link:
label: 'Threads Link'
description: 'Link to your Whatsapp channel'
type: string
default: ''
socials.youtube.link:
label: 'Youtube Link'
description: 'Link to your Youtube channel'
type: string
default: ''
socials.vimeo.link:
label: 'Vimeo Link'
description: 'Link to your Vimeo channel'
type: string
default: ''
socials.xing.link:
label: 'XING Link'
description: 'Link to your XING profile'
type: string
default: ''
socials.linkedin.link:
label: 'LinkedIn Link'
description: 'Link to your LinkedIn profile'
type: string
default: ''
socials.snapchat.link:
label: 'Snapchat Link'
description: 'Link to your Snapchat profile'
type: string
default: ''
socials.tiktok.link:
label: 'TikTok Link'
description: 'Link to your TikTok channel'
type: string
default: ''
socials.reddit.link:
label: 'Reddit Link'
description: 'Link to your Reddit profile'
type: string
default: ''
socials.x.link:
label: 'X/Twitter Link'
description: 'Link to your X/Twitter profile'
type: string
default: ''
socials.twitch.link:
label: 'Twitch Link'
description: 'Link to your Twitch profile'
type: string
default: ''
socials.tumblr.link:
label: 'Tumblr Link'
description: 'Link to your Tumblr profile'
type: string
default: ''
socials.enabled:
label: 'Enable Social Links'
description: 'Enable social links in the footer'
type: boolean
default: true
socials.facebook.link:
label: 'Facebook Link'
description: 'Link to your Facebook profile'
type: string
default: ''
socials.instagram.link:
label: 'Instagram Link'
description: 'Link to your Instagram profile'
type: string
default: ''
socials.threads.link:
label: 'Threads Link'
description: 'Link to your Threads profile'
type: string
default: ''
socials.whatsapp.link:
label: 'Threads Link'
description: 'Link to your Whatsapp channel'
type: string
default: ''
socials.youtube.link:
label: 'Youtube Link'
description: 'Link to your Youtube channel'
type: string
default: ''
socials.vimeo.link:
label: 'Vimeo Link'
description: 'Link to your Vimeo channel'
type: string
default: ''
socials.xing.link:
label: 'XING Link'
description: 'Link to your XING profile'
type: string
default: ''
socials.linkedin.link:
label: 'LinkedIn Link'
description: 'Link to your LinkedIn profile'
type: string
default: ''
socials.snapchat.link:
label: 'Snapchat Link'
description: 'Link to your Snapchat profile'
type: string
default: ''
socials.tiktok.link:
label: 'TikTok Link'
description: 'Link to your TikTok channel'
type: string
default: ''
socials.reddit.link:
label: 'Reddit Link'
description: 'Link to your Reddit profile'
type: string
default: ''
socials.x.link:
label: 'X/Twitter Link'
description: 'Link to your X/Twitter profile'
type: string
default: ''
socials.twitch.link:
label: 'Twitch Link'
description: 'Link to your Twitch channel'
type: string
default: ''
socials.tumblr.link:
label: 'Tumblr Link'
description: 'Link to your Tumblr profile'
type: string
default: ''
socials.pinterest.link:
label: 'Pinterest Link'
description: 'Link to your Pinterest profile'
type: string
default: ''
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
socials:
enable: true
facebook:
link: 'https://www.facebook.com/'
instagram:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
<f:for each="{settings.socials}" as="socialItem" key="label">
<f:if condition="{socialItem.link}">
<f:comment>The Icons/Classes needs to be named like the key in die Base/settings.yaml</f:comment>
<a href="{socialItem.link}" title="{label}" class="{label}">{label}</a>
</f:if>
</f:for>
<f:if condition="{settings.socials.enable}">
<f:for each="{settings.socials}" as="socialItem" key="label">
<f:if condition="{socialItem.link}">
<f:comment>The Icons/Classes needs to be named like the key in die Base/settings.yaml</f:comment>
<a href="{socialItem.link}" title="{label}" class="{label}">{label}</a>
</f:if>
</f:for>
</f:if>

0 comments on commit 0034a51

Please sign in to comment.