-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FEATURE] add setting to make socials enable/disable (#48)
- Loading branch information
Showing
4 changed files
with
95 additions
and
81 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
150 changes: 80 additions & 70 deletions
150
local_packages/portfolio/Configuration/Sets/Base/settings.definitions.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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: '' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
socials: | ||
enable: true | ||
facebook: | ||
link: 'https://www.facebook.com/' | ||
instagram: | ||
|
14 changes: 8 additions & 6 deletions
14
local_packages/portfolio/Resources/Private/Templates/partials/Socials.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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> |