Spaces:
Running
Running
Update script.js
Browse files
script.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
| 1 |
-
// 👻 GhostPack
|
| 2 |
|
| 3 |
// Smooth scrolling
|
| 4 |
document.querySelectorAll('a.nav-link').forEach(anchor => {
|
|
@@ -35,4 +35,43 @@ document.querySelectorAll('.card').forEach(card => {
|
|
| 35 |
card.style.transform = 'translateY(0) scale(1)';
|
| 36 |
card.style.boxShadow = '0 0 25px rgba(0, 255, 204, 0.5)';
|
| 37 |
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 38 |
});
|
|
|
|
| 1 |
+
// 👻 GhostPack Spectral Interactivity 😈
|
| 2 |
|
| 3 |
// Smooth scrolling
|
| 4 |
document.querySelectorAll('a.nav-link').forEach(anchor => {
|
|
|
|
| 35 |
card.style.transform = 'translateY(0) scale(1)';
|
| 36 |
card.style.boxShadow = '0 0 25px rgba(0, 255, 204, 0.5)';
|
| 37 |
});
|
| 38 |
+
});
|
| 39 |
+
|
| 40 |
+
// Enable tooltips
|
| 41 |
+
const tooltipTriggerList = document.querySelectorAll('[data-bs-toggle="tooltip"]');
|
| 42 |
+
const tooltipList = [...tooltipTriggerList].map(tooltipTriggerEl => new bootstrap.Tooltip(tooltipTriggerEl));
|
| 43 |
+
|
| 44 |
+
// Speed chart
|
| 45 |
+
const ctx = document.getElementById('speedChart').getContext('2d');
|
| 46 |
+
new Chart(ctx, {
|
| 47 |
+
type: 'bar',
|
| 48 |
+
data: {
|
| 49 |
+
labels: ['GTX 1650 (6GB)', 'RTX 3050 (8GB)', 'RTX 3060 (12GB)', 'RTX 4090 (24GB)'],
|
| 50 |
+
datasets: [{
|
| 51 |
+
label: 'Frame Generation Time (s)',
|
| 52 |
+
data: [22, 17.5, 12.5, 2],
|
| 53 |
+
backgroundColor: ['#00ffcc', '#00cc99', '#00aaff', '#ffcc00'],
|
| 54 |
+
borderColor: ['#00cc99', '#009966', '#0088cc', '#cc9900'],
|
| 55 |
+
borderWidth: 1
|
| 56 |
+
}]
|
| 57 |
+
},
|
| 58 |
+
options: {
|
| 59 |
+
scales: {
|
| 60 |
+
y: {
|
| 61 |
+
beginAtZero: true,
|
| 62 |
+
title: {
|
| 63 |
+
display: true,
|
| 64 |
+
text: 'Seconds per Frame',
|
| 65 |
+
color: '#ffffff'
|
| 66 |
+
},
|
| 67 |
+
ticks: { color: '#ffffff' }
|
| 68 |
+
},
|
| 69 |
+
x: {
|
| 70 |
+
ticks: { color: '#ffffff' }
|
| 71 |
+
}
|
| 72 |
+
},
|
| 73 |
+
plugins: {
|
| 74 |
+
legend: { labels: { color: '#ffffff' } }
|
| 75 |
+
}
|
| 76 |
+
}
|
| 77 |
});
|