Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
Personal Website
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
TheJoeCoder
Personal Website
Commits
2513e17a
Verified
Commit
2513e17a
authored
11 months ago
by
TheJoeCoder
Browse files
Options
Downloads
Patches
Plain Diff
Make social icons into a json file
parent
1b37e143
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
build_site.py
+3
-1
3 additions, 1 deletion
build_site.py
templates/index.html
+10
-8
10 additions, 8 deletions
templates/index.html
templates/social_icons.json
+32
-0
32 additions, 0 deletions
templates/social_icons.json
with
45 additions
and
9 deletions
build_site.py
+
3
−
1
View file @
2513e17a
...
...
@@ -38,7 +38,9 @@ for filename in files:
# Add to projects
projects
.
append
(
project
)
social_icons
=
json
.
load
(
open
(
"
templates/social_icons.json
"
,
"
r
"
))
# Format template
template
=
env
.
get_template
(
"
index.html
"
)
with
open
(
"
public/index.html
"
,
"
w
"
)
as
f
:
f
.
write
(
template
.
render
(
projects
=
projects
))
f
.
write
(
template
.
render
(
projects
=
projects
,
social_icons
=
social_icons
))
This diff is collapsed.
Click to expand it.
templates/index.html
+
10
−
8
View file @
2513e17a
...
...
@@ -22,14 +22,16 @@
<div
class=
"row mx-auto p-2 text-center"
>
<!-- Social icons -->
<p>
<a
class=
"social-link"
target=
"_blank"
href=
"https://rb9.xyz/yt"
><i
class=
"bi bi-youtube"
></i></a>
<a
class=
"social-link"
target=
"_blank"
href=
"https://git.rb9.xyz/TheJoeCoder"
><i
class=
"bi bi-gitlab"
></i></a>
<a
class=
"social-link"
target=
"_blank"
href=
"https://github.com/TheJoeCoder"
><i
class=
"bi bi-github"
></i></a>
<a
class=
"social-link"
target=
"_blank"
href=
"https://chat.radialbog9.com/@radialbog9"
><i
class=
"bi bi-mastodon"
></i></a>
{% for icon in social_icons %}
<a
class=
"social-link"
{%
if
icon.blank_target
%}
target=
"_blank"
{%
endif
%}
href=
"{{ icon.url }}"
{%
if
icon.title
%}
title=
"{{ icon.title }}"
{%
endif
%}
>
<i
class=
"bi {{ icon.icon }}"
></i>
</a>
{% endfor %}
</p>
</div>
<div
class=
"row mx-auto p-2 text-center"
>
...
...
This diff is collapsed.
Click to expand it.
templates/social_icons.json
0 → 100644
+
32
−
0
View file @
2513e17a
[
{
"title"
:
"Buy Me A Coffee"
,
"url"
:
"https://buymeacoff.ee/Radialbog9"
,
"icon"
:
"bi-wallet"
,
"blank_target"
:
true
},
{
"title"
:
"YouTube"
,
"url"
:
"https://rb9.xyz/yt"
,
"icon"
:
"bi-youtube"
,
"blank_target"
:
true
},
{
"title"
:
"GitLab"
,
"url"
:
"https://git.rb9.xyz/TheJoeCoder"
,
"icon"
:
"bi-gitlab"
,
"blank_target"
:
true
},
{
"title"
:
"GitHub"
,
"url"
:
"https://github.com/TheJoeCoder"
,
"icon"
:
"bi-github"
,
"blank_target"
:
true
},
{
"title"
:
"Mastodon"
,
"url"
:
"https://chat.radialbog9.com/@radialbog9"
,
"icon"
:
"bi-mastodon"
,
"blank_target"
:
true
}
]
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment