Skip to content

Commit e757255

Browse files
committed
Add social media links and GitHub stars display to tutorial pages
1 parent eadd8d4 commit e757255

10 files changed

+667
-1
lines changed

feascript-platform.html

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,68 @@ <h1 class="top">
5353
</a>
5454
</h1>
5555

56+
<div class="social-icons-top-right">
57+
<ul>
58+
<li>
59+
<a href="https://blog.feascript.com/" title="FEAScript blog">
60+
<img
61+
src="./assets/blog-icon-feascript.png"
62+
alt="Blog icon"
63+
style="height: 18px; vertical-align: middle"
64+
/>
65+
</a>
66+
</li>
67+
<li>
68+
<a href="https://www.youtube.com/@FEAScript" title="FEAScript YouTube">
69+
<img
70+
src="./assets/youtube-icon-feascript.svg"
71+
alt="YouTube icon"
72+
style="height: 18px; vertical-align: middle"
73+
/>
74+
</a>
75+
</li>
76+
<li>
77+
<a href="https://www.linkedin.com/company/feascript/" title="FEAScript LinkedIn">
78+
<img
79+
src="./assets/linkedin-icon-feascript.png"
80+
alt="LinkedIn icon"
81+
style="height: 18px; vertical-align: middle"
82+
/>
83+
</a>
84+
</li>
85+
<li>
86+
<a href="https://discord.gg/3DVjNcuW4f" title="FEAScript Discord">
87+
<img
88+
src="./assets/discord-icon-feascript.png"
89+
alt="Discord icon"
90+
style="height: 18px; vertical-align: middle"
91+
/>
92+
</a>
93+
</li>
94+
<li>
95+
<a href="https://github.com/FEAScript/FEAScript-core" title="FEAScript GitHub">
96+
<img
97+
src="./assets/github-icon-feascript.png"
98+
alt="GitHub icon"
99+
style="height: 20px; vertical-align: middle"
100+
/>
101+
<span
102+
id="github-stars"
103+
style="
104+
font-size: 0.9em;
105+
margin-left: 5px;
106+
vertical-align: middle;
107+
border: 1px solid #ddd;
108+
border-radius: 4px;
109+
padding: 1px 5px;
110+
background-color: #f8f8f8;
111+
"
112+
></span>
113+
</a>
114+
</li>
115+
</ul>
116+
</div>
117+
56118
<h1>A Visual Editor for the FEAScript Library</h1>
57119
<div class="highlight-container">
58120
<p>
@@ -114,6 +176,18 @@ <h1>Why Use FEAScript Platform</h1>
114176
</footer>
115177
<script>
116178
document.getElementById("currentYear").innerHTML = new Date().getFullYear();
179+
180+
// Fetch GitHub stars
181+
fetch("https://api.github.com/repos/FEAScript/FEAScript-core")
182+
.then((response) => response.json())
183+
.then((data) => {
184+
const starCount = data.stargazers_count;
185+
const starsElement = document.getElementById("github-stars");
186+
if (starsElement && starCount) {
187+
starsElement.innerHTML = `★ ${starCount}`;
188+
}
189+
})
190+
.catch((error) => console.error("Error fetching GitHub stars:", error));
117191
</script>
118192
</body>
119193
</html>

index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ <h1>A JavaScript Finite Element Simulation Library</h1>
109109
>
110110
</li>
111111
</ul>
112-
<!-- <li class="icon-link-start"> -->
112+
113113
<div class="social-icons-top-right">
114114
<ul>
115115
<li>

tutorials/advection-diffusion-1d.html

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,68 @@ <h1>Advection-Diffusion with a Gaussian Source Term Tutorial</h1>
7373
<li><a href="#results">Results</a></li>
7474
</ul>
7575

76+
<div class="social-icons-top-right">
77+
<ul>
78+
<li>
79+
<a href="https://blog.feascript.com/" title="FEAScript blog">
80+
<img
81+
src="../assets/blog-icon-feascript.png"
82+
alt="Blog icon"
83+
style="height: 18px; vertical-align: middle"
84+
/>
85+
</a>
86+
</li>
87+
<li>
88+
<a href="https://www.youtube.com/@FEAScript" title="FEAScript YouTube">
89+
<img
90+
src="../assets/youtube-icon-feascript.svg"
91+
alt="YouTube icon"
92+
style="height: 18px; vertical-align: middle"
93+
/>
94+
</a>
95+
</li>
96+
<li>
97+
<a href="https://www.linkedin.com/company/feascript/" title="FEAScript LinkedIn">
98+
<img
99+
src="../assets/linkedin-icon-feascript.png"
100+
alt="LinkedIn icon"
101+
style="height: 18px; vertical-align: middle"
102+
/>
103+
</a>
104+
</li>
105+
<li>
106+
<a href="https://discord.gg/3DVjNcuW4f" title="FEAScript Discord">
107+
<img
108+
src="../assets/discord-icon-feascript.png"
109+
alt="Discord icon"
110+
style="height: 18px; vertical-align: middle"
111+
/>
112+
</a>
113+
</li>
114+
<li>
115+
<a href="https://github.com/FEAScript/FEAScript-core" title="FEAScript GitHub">
116+
<img
117+
src="../assets/github-icon-feascript.png"
118+
alt="GitHub icon"
119+
style="height: 20px; vertical-align: middle"
120+
/>
121+
<span
122+
id="github-stars"
123+
style="
124+
font-size: 0.9em;
125+
margin-left: 5px;
126+
vertical-align: middle;
127+
border: 1px solid #ddd;
128+
border-radius: 4px;
129+
padding: 1px 5px;
130+
background-color: #f8f8f8;
131+
"
132+
></span>
133+
</a>
134+
</li>
135+
</ul>
136+
</div>
137+
76138
<div class="highlight-container">
77139
<p>
78140
In this tutorial, we address an advection-diffusion problem in a one-dimensional domain with a
@@ -284,6 +346,18 @@ <h2 id="results"><a name="Results"></a>Results</h2>
284346
</footer>
285347
<script>
286348
document.getElementById("currentYear").innerHTML = new Date().getFullYear();
349+
350+
// Fetch GitHub stars
351+
fetch("https://api.github.com/repos/FEAScript/FEAScript-core")
352+
.then((response) => response.json())
353+
.then((data) => {
354+
const starCount = data.stargazers_count;
355+
const starsElement = document.getElementById("github-stars");
356+
if (starsElement && starCount) {
357+
starsElement.innerHTML = `★ ${starCount}`;
358+
}
359+
})
360+
.catch((error) => console.error("Error fetching GitHub stars:", error));
287361
</script>
288362
</body>
289363
</html>

tutorials/heat-conduction-1d-wall.html

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,68 @@ <h1>Heat Conduction Through a Wall Tutorial</h1>
7373
<li><a href="#results">Results</a></li>
7474
</ul>
7575

76+
<div class="social-icons-top-right">
77+
<ul>
78+
<li>
79+
<a href="https://blog.feascript.com/" title="FEAScript blog">
80+
<img
81+
src="../assets/blog-icon-feascript.png"
82+
alt="Blog icon"
83+
style="height: 18px; vertical-align: middle"
84+
/>
85+
</a>
86+
</li>
87+
<li>
88+
<a href="https://www.youtube.com/@FEAScript" title="FEAScript YouTube">
89+
<img
90+
src="../assets/youtube-icon-feascript.svg"
91+
alt="YouTube icon"
92+
style="height: 18px; vertical-align: middle"
93+
/>
94+
</a>
95+
</li>
96+
<li>
97+
<a href="https://www.linkedin.com/company/feascript/" title="FEAScript LinkedIn">
98+
<img
99+
src="../assets/linkedin-icon-feascript.png"
100+
alt="LinkedIn icon"
101+
style="height: 18px; vertical-align: middle"
102+
/>
103+
</a>
104+
</li>
105+
<li>
106+
<a href="https://discord.gg/3DVjNcuW4f" title="FEAScript Discord">
107+
<img
108+
src="../assets/discord-icon-feascript.png"
109+
alt="Discord icon"
110+
style="height: 18px; vertical-align: middle"
111+
/>
112+
</a>
113+
</li>
114+
<li>
115+
<a href="https://github.com/FEAScript/FEAScript-core" title="FEAScript GitHub">
116+
<img
117+
src="../assets/github-icon-feascript.png"
118+
alt="GitHub icon"
119+
style="height: 20px; vertical-align: middle"
120+
/>
121+
<span
122+
id="github-stars"
123+
style="
124+
font-size: 0.9em;
125+
margin-left: 5px;
126+
vertical-align: middle;
127+
border: 1px solid #ddd;
128+
border-radius: 4px;
129+
padding: 1px 5px;
130+
background-color: #f8f8f8;
131+
"
132+
></span>
133+
</a>
134+
</li>
135+
</ul>
136+
</div>
137+
76138
<div class="highlight-container">
77139
<p>
78140
In this tutorial, we study steady-state heat flow through a wall. We can simplify this problem to one
@@ -262,6 +324,18 @@ <h2 id="results"><a name="Results"></a>Results</h2>
262324
</footer>
263325
<script>
264326
document.getElementById("currentYear").innerHTML = new Date().getFullYear();
327+
328+
// Fetch GitHub stars
329+
fetch("https://api.github.com/repos/FEAScript/FEAScript-core")
330+
.then((response) => response.json())
331+
.then((data) => {
332+
const starCount = data.stargazers_count;
333+
const starsElement = document.getElementById("github-stars");
334+
if (starsElement && starCount) {
335+
starsElement.innerHTML = `★ ${starCount}`;
336+
}
337+
})
338+
.catch((error) => console.error("Error fetching GitHub stars:", error));
265339
</script>
266340
</body>
267341
</html>

tutorials/heat-conduction-2d-fin-gmsh.html

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,68 @@ <h1>Heat Conduction in a 2D Fin Tutorial (Gmsh Mesh)</h1>
7676
<li><a href="#results">Results</a></li>
7777
</ul>
7878

79+
<div class="social-icons-top-right">
80+
<ul>
81+
<li>
82+
<a href="https://blog.feascript.com/" title="FEAScript blog">
83+
<img
84+
src="../assets/blog-icon-feascript.png"
85+
alt="Blog icon"
86+
style="height: 18px; vertical-align: middle"
87+
/>
88+
</a>
89+
</li>
90+
<li>
91+
<a href="https://www.youtube.com/@FEAScript" title="FEAScript YouTube">
92+
<img
93+
src="../assets/youtube-icon-feascript.svg"
94+
alt="YouTube icon"
95+
style="height: 18px; vertical-align: middle"
96+
/>
97+
</a>
98+
</li>
99+
<li>
100+
<a href="https://www.linkedin.com/company/feascript/" title="FEAScript LinkedIn">
101+
<img
102+
src="../assets/linkedin-icon-feascript.png"
103+
alt="LinkedIn icon"
104+
style="height: 18px; vertical-align: middle"
105+
/>
106+
</a>
107+
</li>
108+
<li>
109+
<a href="https://discord.gg/3DVjNcuW4f" title="FEAScript Discord">
110+
<img
111+
src="../assets/discord-icon-feascript.png"
112+
alt="Discord icon"
113+
style="height: 18px; vertical-align: middle"
114+
/>
115+
</a>
116+
</li>
117+
<li>
118+
<a href="https://github.com/FEAScript/FEAScript-core" title="FEAScript GitHub">
119+
<img
120+
src="../assets/github-icon-feascript.png"
121+
alt="GitHub icon"
122+
style="height: 20px; vertical-align: middle"
123+
/>
124+
<span
125+
id="github-stars"
126+
style="
127+
font-size: 0.9em;
128+
margin-left: 5px;
129+
vertical-align: middle;
130+
border: 1px solid #ddd;
131+
border-radius: 4px;
132+
padding: 1px 5px;
133+
background-color: #f8f8f8;
134+
"
135+
></span>
136+
</a>
137+
</li>
138+
</ul>
139+
</div>
140+
79141
<div class="highlight-container">
80142
<p>
81143
This page demonstrates solving the 2D heat conduction fin problem using a Gmsh-generated mesh.
@@ -383,6 +445,18 @@ <h2 id="results"><a name="results"></a>Results</h2>
383445
</footer>
384446
<script>
385447
document.getElementById("currentYear").innerHTML = new Date().getFullYear();
448+
449+
// Fetch GitHub stars
450+
fetch("https://api.github.com/repos/FEAScript/FEAScript-core")
451+
.then((response) => response.json())
452+
.then((data) => {
453+
const starCount = data.stargazers_count;
454+
const starsElement = document.getElementById("github-stars");
455+
if (starsElement && starCount) {
456+
starsElement.innerHTML = `★ ${starCount}`;
457+
}
458+
})
459+
.catch((error) => console.error("Error fetching GitHub stars:", error));
386460
</script>
387461
</body>
388462
</html>

0 commit comments

Comments
 (0)