Jikkii commited on
Commit
ba77495
·
1 Parent(s): 981962d
Files changed (2) hide show
  1. index.html +128 -8
  2. style.css +91 -0
index.html CHANGED
@@ -18,6 +18,7 @@
18
  <script src="https://cdnjs.cloudflare.com/ajax/libs/iframe-resizer/4.3.2/iframeResizer.contentWindow.min.js"></script>
19
  <script src="https://cdnjs.cloudflare.com/ajax/libs/timeago.js/4.0.2/timeago.min.js"></script>
20
  <script src="https://cdn.tailwindcss.com"></script>
 
21
  <script>
22
  const REPO_NAME = "spaces/transformers-discussion-board/Support";
23
  const NUM_DISCUSSIONS = 5;
@@ -105,6 +106,58 @@
105
 
106
  hookPoint.appendChild(clone);
107
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
108
  }
109
 
110
  document.onreadystatechange = function (e) {
@@ -113,8 +166,8 @@
113
 
114
  // Check for system dark mode preference
115
  if (
116
- window.matchMedia &&
117
- window.matchMedia("(prefers-color-scheme: dark)").matches
118
  ) {
119
  document.documentElement.classList.add("dark");
120
  }
@@ -123,6 +176,7 @@
123
  </script>
124
  </head>
125
  <body class="dark:bg-gray-900 dark:text-white">
 
126
  <div class="flex flex-col p-12 md:p-32 font-sans">
127
  <h1 class="text-2xl font-bold mb-4">Transformers Discussions</h1>
128
  <h2 class="dark:text-gray-200">
@@ -130,9 +184,9 @@
130
  </h2>
131
  <p class="text-gray-500 dark:text-gray-400">
132
  <a
133
- href="https://huggingface.co/spaces/transformers-discussion-board/Support/discussions"
134
- class="underline hover:text-gray-800 dark:hover:text-gray-300"
135
- >Go to the community tab</a
136
  >
137
  to get started
138
  </p>
@@ -142,11 +196,11 @@
142
 
143
  <div class="hidden">
144
  <div
145
- id="template-discussion"
146
- class="relative h-[4.25rem] w-full overflow-hidden"
147
  >
148
  <a
149
- class="group flex h-full items-stretch overflow-hidden rounded-lg border border-gray-100 dark:border-gray-800"
150
  href="https://huggingface.co/spaces/huggingface/HuggingDiscussions/discussions/14"
151
  >
152
  <div
@@ -294,5 +348,71 @@
294
  </div>
295
  </div>
296
  </div>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
297
  </body>
298
  </html>
 
18
  <script src="https://cdnjs.cloudflare.com/ajax/libs/iframe-resizer/4.3.2/iframeResizer.contentWindow.min.js"></script>
19
  <script src="https://cdnjs.cloudflare.com/ajax/libs/timeago.js/4.0.2/timeago.min.js"></script>
20
  <script src="https://cdn.tailwindcss.com"></script>
21
+ <link rel="stylesheet" href="style.css">
22
  <script>
23
  const REPO_NAME = "spaces/transformers-discussion-board/Support";
24
  const NUM_DISCUSSIONS = 5;
 
106
 
107
  hookPoint.appendChild(clone);
108
  }
109
+
110
+ const pypi_svg = `<svg clip-rule="evenodd" fill-rule="evenodd" height="20" stroke-linecap="square" stroke-linejoin="round" stroke-miterlimit="1.5" viewBox=".006 0 673.409 600" width="20" xmlns="http://www.w3.org/2000/svg"><path d="m.006 0h600v600h-600z" fill="#111827"/><g transform="translate(72.59 -63.209)"><path d="m673.41 236.016-64.271 8.252v281.357h64.276z" fill="#ffca1e" stroke="#d7c5b2" stroke-width="1.11" transform="matrix(1.02365 -.37275 .22115 .08093 -423.086 457.448)"/><path d="m609.139 244.268h64.276v281.357h-64.276z" fill="#ffd241" stroke="#d7c5b2" stroke-width=".35" transform="matrix(3.93359 -1.43837 0 .53084 -2266.43 1087.94)"/><path d="m609.139 244.268h64.276v281.357h-64.276z" fill="#2f6490" stroke="#d1e3f2" stroke-width=".62" transform="matrix(1.9604 -.71685 .2216 .07927 -1118.55 639.339)"/><path d="m609.139 244.268h64.276v281.357h-64.276z" fill="#3775a8" stroke="#d1e3f2" stroke-width="1.15" transform="matrix(1.02281 -.374 0 1.05695 -430.773 214.178)"/><path d="m609.139 244.268h64.276v281.357h-64.276z" fill="#2f6490" stroke="#fff" stroke-width="1.17" transform="matrix(-.97499 -.34924 0 1.05695 786.194 199.208)"/><path d="m609.139 244.268h64.276v281.357h-64.276z" fill="#efeeea" stroke="#d8d8d8" stroke-width="1.44" transform="matrix(-.97499 -.35652 0 .26885 786.194 618.355)"/><g stroke="#d1e3f2"><path d="m609.139 244.268h64.276v281.357h-64.276z" fill="#2f6490" stroke-width="1.44" transform="matrix(-.96834 -.35409 0 .53077 719.483 427.5)"/><path d="m609.139 244.268h64.276v281.357h-64.276z" fill="#3775a8" stroke-width="1.2" transform="matrix(.93554 -.3421 0 1.05695 -311.892 170.492)"/><path d="m609.139 244.268h64.276v281.357h-64.276z" fill="#3775a8" stroke-width="1.43" transform="matrix(.9742 -.35623 0 .53084 -463.744 428.761)"/><path d="m67.575 393.161 62.121 22.465 188.708-68.299m-125.165-29.141 124.732-45.602" fill="none"/></g><path d="m318.404 347.327 63.939-23.209" fill="none" stroke="#d7c5b2"/><path d="m609.139 244.268h64.276v281.357h-64.276z" fill="#2f6490" stroke="#d1e3f2" stroke-width="1.16" transform="matrix(.96788 -.35244 .22115 .08093 -576.168 513.583)"/><circle cx="637.517" cy="260.001" fill="#fff" r="15.71" transform="matrix(.7826 -.4024 .05494 .8614 -295.363 304.934)"/><path d="m195.786 198.125 61.696 22.126" fill="none" stroke="#d1e3f2"/><path d="m673.415 244.268h-64.276l.018 282.405 64.258-1.048z" fill="#ffd241" stroke="#d7c5b2" stroke-width="1.37" transform="matrix(1.02281 -.374 0 .52843 -430.773 491.983)"/><path d="m673.415 244.268h-64.276l.001 281.758 64.275-.401z" fill="#ffd241" stroke="#d7c5b2" stroke-width="1.48" transform="matrix(.93554 -.3421 0 .52743 -311.892 448.822)"/><circle cx="637.517" cy="260.001" fill="#fefdfd" r="15.71" transform="matrix(.77074 -.3963 .05156 .80832 -205.916 509.411)"/><path d="m192.412 468.059 126.028-45.977" fill="none" stroke="#d7c5b2"/></g></svg>`
111
+ const github_svg = `<svg width="20" height="20" viewBox="0 0 20 20" fill="#fff" xmlns="http://www.w3.org/2000/svg"><script xmlns=""/><path fill-rule="evenodd" clip-rule="evenodd" d="M8 0C3.58 0 0 3.58 0 8C0 11.54 2.29 14.53 5.47 15.59C5.87 15.66 6.02 15.42 6.02 15.21C6.02 15.02 6.01 14.39 6.01 13.72C4 14.09 3.48 13.23 3.32 12.78C3.23 12.55 2.84 11.84 2.5 11.65C2.22 11.5 1.82 11.13 2.49 11.12C3.12 11.11 3.57 11.7 3.72 11.94C4.44 13.15 5.59 12.81 6.05 12.6C6.12 12.08 6.33 11.73 6.56 11.53C4.78 11.33 2.92 10.64 2.92 7.58C2.92 6.71 3.23 5.99 3.74 5.43C3.66 5.23 3.38 4.41 3.82 3.31C3.82 3.31 4.49 3.1 6.02 4.13C6.66 3.95 7.34 3.86 8.02 3.86C8.7 3.86 9.38 3.95 10.02 4.13C11.55 3.09 12.22 3.31 12.22 3.31C12.66 4.41 12.38 5.23 12.3 5.43C12.81 5.99 13.12 6.7 13.12 7.58C13.12 10.65 11.25 11.33 9.47 11.53C9.76 11.78 10.01 12.26 10.01 13.01C10.01 14.08 10 14.94 10 15.21C10 15.42 10.15 15.67 10.55 15.59C13.71 14.53 16 11.53 16 8C16 3.58 12.42 0 8 0Z" transform="scale(64)" fill="#1B1F23"/></svg>`
112
+
113
+ const releases = [
114
+ {title: "v4.51.3", desc: "Patch release v4.51.3, released on 14th April, 2025"},
115
+ {title: "Janus (based on v4.51.3)", desc: "v4.51.3-Janus-preview, released on 22nd April, 2025"},
116
+ {title: "TimesFM (based on v4.51.3)", desc: "v4.51.3-TimesFM-preview, released on 22nd April, 2025"},
117
+ {title: "Qwen2.5-Omni (based on 4.51.3)", desc: "v4.51.3-Qwen2.5-Omni-preview, released on 22nd April, 2025"},
118
+ {title: "LlamaGuard-4 (based on v4.51.3)", desc: "v4.51.3-LlamaGuard-preview, released on 22nd April, 2025"},
119
+ {title: "BitNet (based on v4.51.3)", desc: "v4.51.3-BitNet-preview, released on 22nd April, 2025"},
120
+ {title: "CSM (based on v4.51.3)", desc: "v4.51.3-CSM-preview, released on 22nd April, 2025"},
121
+ {title: "D-FINE (based on v4.51.3)", desc: "v4.51.3-D-FINE-preview, released on 22nd April, 2025"},
122
+ {title: "GraniteMoeHybrid (based on v4.51.3)", desc: "v4.51.3-GraniteMoeHybrid-preview, released on 22nd April, 2025"},
123
+ {title: "SAM-HQ (based on v4.51.3)", desc: "v4.51.3-SAM-HQ-preview, released on 22nd April, 2025"},
124
+ ];
125
+
126
+ for (let i = 1; i < releases.length + 1; i++) {
127
+ const release = releases[i - 1];
128
+ const styleTop = `${i}0%`
129
+
130
+ const commitTree = document.getElementById('commit-tree');
131
+ const commitNode = document.createElement('div');
132
+ const tooltip = document.createElement('div')
133
+
134
+ commitNode.classList.add('commit-node');
135
+ commitNode.style.top = styleTop;
136
+
137
+ tooltip.innerHTML = `<div class="tooltip">
138
+ <div class="title relative h-[4.25rem] w-full overflow-hidden">
139
+ <a class="group flex h-full items-stretch overflow-hidden rounded-lg border border-gray-100 dark:border-gray-800"
140
+ href="https://huggingface.co/spaces/transformers-discussion-board/Support/discussions/5">
141
+ <div class="flex-1 overflow-hidden whitespace-nowrap px-4 bg-white dark:bg-gray-800 dark:bg-gradient-to-r dark:from-gray-900 dark:to-gray-950">
142
+ <div class="mt-2.5 flex items-center justify-between overflow-hidden leading-snug">
143
+ <div class="flex items-center overflow-hidden">
144
+ <h4 class="truncate font-semibold group-hover:underline dark:text-white">${release.title}</h4>
145
+ <div class="outer_svg">${pypi_svg}</div>
146
+ <div class="outer_svg">${github_svg}</div>
147
+ </div>
148
+ <div class="flex h-full items-start pt-2.5"></div>
149
+ </div>
150
+ </div>
151
+ </a>
152
+ <div class="desc absolute bottom-2.5 max-w-full truncate pl-4 pr-4 text-sm text-gray-500 dark:text-gray-400">
153
+ <span class="discussion-num">${release['desc']}</span>
154
+ </div>
155
+ </div>
156
+ </div>`
157
+
158
+ commitNode.appendChild(tooltip);
159
+ commitTree.appendChild(commitNode);
160
+ }
161
  }
162
 
163
  document.onreadystatechange = function (e) {
 
166
 
167
  // Check for system dark mode preference
168
  if (
169
+ window.matchMedia &&
170
+ window.matchMedia("(prefers-color-scheme: dark)").matches
171
  ) {
172
  document.documentElement.classList.add("dark");
173
  }
 
176
  </script>
177
  </head>
178
  <body class="dark:bg-gray-900 dark:text-white">
179
+ <div class="commit-timeline">
180
  <div class="flex flex-col p-12 md:p-32 font-sans">
181
  <h1 class="text-2xl font-bold mb-4">Transformers Discussions</h1>
182
  <h2 class="dark:text-gray-200">
 
184
  </h2>
185
  <p class="text-gray-500 dark:text-gray-400">
186
  <a
187
+ href="https://huggingface.co/spaces/transformers-discussion-board/Support/discussions"
188
+ class="underline hover:text-gray-800 dark:hover:text-gray-300"
189
+ >Go to the community tab</a
190
  >
191
  to get started
192
  </p>
 
196
 
197
  <div class="hidden">
198
  <div
199
+ id="template-discussion"
200
+ class="relative h-[4.25rem] w-full overflow-hidden"
201
  >
202
  <a
203
+ class="group flex h-full items-stretch overflow-hidden rounded-lg border border-gray-100 dark:border-gray-800"
204
  href="https://huggingface.co/spaces/huggingface/HuggingDiscussions/discussions/14"
205
  >
206
  <div
 
348
  </div>
349
  </div>
350
  </div>
351
+ <div class="commit-tree" id="commit-tree">
352
+ <!-- <div class="commit-node" style="top: 10%;">-->
353
+ <!-- <div class="tooltip">-->
354
+ <!-- <div class="title relative h-[4.25rem] w-full overflow-hidden">-->
355
+ <!-- <a class="group flex h-full items-stretch overflow-hidden rounded-lg border border-gray-100 dark:border-gray-800" href="https://huggingface.co/spaces/transformers-discussion-board/Support/discussions/5">-->
356
+ <!-- <div class="flex-1 overflow-hidden whitespace-nowrap px-4 bg-white dark:bg-gray-800 dark:bg-gradient-to-r dark:from-gray-900 dark:to-gray-950">-->
357
+ <!-- <div class="mt-2.5 flex items-center justify-between overflow-hidden leading-snug">-->
358
+ <!-- <div class="flex items-center overflow-hidden">-->
359
+ <!-- <h4 class="truncate font-semibold group-hover:underline dark:text-white">MLCD (based on 4.51.3)</h4>-->
360
+ <!-- </div>-->
361
+ <!-- <div class="flex h-full items-start pt-2.5"></div>-->
362
+ <!-- </div>-->
363
+ <!-- </div>-->
364
+ <!-- </a>-->
365
+ <!-- <div class="desc absolute bottom-2.5 max-w-full truncate pl-4 pr-4 text-sm text-gray-500 dark:text-gray-400">-->
366
+ <!-- <span class="discussion-num">v4.51.3-MLCD-preview,</span>-->
367
+ <!-- <span class="timeago">22nd April, 2025</span>-->
368
+ <!-- </div>-->
369
+ <!-- </div>-->
370
+ <!-- </div>-->
371
+ <!-- </div>-->
372
+ <!-- <div class="commit-node" style="top: 20%;">-->
373
+ <!-- <div class="tooltip">-->
374
+ <!-- <div class="relative h-[4.25rem] w-full overflow-hidden">-->
375
+ <!-- <a class="group flex h-full items-stretch overflow-hidden rounded-lg border border-gray-100 dark:border-gray-800" href="https://huggingface.co/spaces/transformers-discussion-board/Support/discussions/5">-->
376
+ <!-- <div class="flex-1 overflow-hidden whitespace-nowrap px-4 bg-white dark:bg-gray-800 dark:bg-gradient-to-r dark:from-gray-900 dark:to-gray-950">-->
377
+ <!-- <div class="mt-2.5 flex items-center justify-between overflow-hidden leading-snug">-->
378
+ <!-- <div class="flex items-center overflow-hidden">-->
379
+ <!-- <h4 class="truncate font-semibold group-hover:underline dark:text-white">Janus (based on v4.51.3)</h4>-->
380
+ <!-- </div>-->
381
+ <!-- <div class="flex h-full items-start pt-2.5"></div>-->
382
+ <!-- </div>-->
383
+ <!-- </div>-->
384
+ <!-- </a>-->
385
+ <!-- <div class="absolute bottom-2.5 max-w-full truncate pl-4 pr-4 text-sm text-gray-500 dark:text-gray-400">-->
386
+ <!-- <span class="discussion-num">v4.51.3-Janus-preview,</span>-->
387
+ <!-- <span class="timeago">8th of May, 2025</span>-->
388
+ <!-- </div>-->
389
+ <!-- </div>-->
390
+ <!-- </div>-->
391
+ <!-- </div>-->
392
+ <!-- <div class="commit-node" style="top: 30%;">-->
393
+ <!-- <div class="tooltip">Update Dependencies<br>def456</div>-->
394
+ <!-- </div>-->
395
+ <!-- <div class="commit-node" style="top: 40%;">-->
396
+ <!-- <div class="tooltip">Update Dependencies<br>def456</div>-->
397
+ <!-- </div>-->
398
+ <!-- <div class="commit-node" style="top: 50%;">-->
399
+ <!-- <div class="tooltip">Update Dependencies<br>def456</div>-->
400
+ <!-- </div>-->
401
+ <!-- <div class="commit-node" style="top: 60%;">-->
402
+ <!-- <div class="tooltip">Fix Bug<br>ghi789</div>-->
403
+ <!-- </div>-->
404
+ <!-- <div class="commit-node" style="top: 70%;">-->
405
+ <!-- <div class="tooltip">Fix Bug<br>ghi789</div>-->
406
+ <!-- </div>-->
407
+ <!-- <div class="commit-node" style="top: 80%;">-->
408
+ <!-- <div class="tooltip">Fix Bug<br>ghi789</div>-->
409
+ <!-- </div>-->
410
+ <!-- <div class="commit-node" style="top: 90%;">-->
411
+ <!-- <div class="tooltip">Fix Bug<br>ghi789</div>-->
412
+ <!-- </div>-->
413
+ <!-- <div class="commit-node" style="top: 100%;">-->
414
+ <!-- <div class="tooltip">Fix Bug<br>ghi789</div>-->
415
+ <!-- </div>-->
416
+ </div>
417
  </body>
418
  </html>
style.css CHANGED
@@ -26,3 +26,94 @@ p {
26
  .card p:last-child {
27
  margin-bottom: 0;
28
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
26
  .card p:last-child {
27
  margin-bottom: 0;
28
  }
29
+
30
+ .commit-timeline {
31
+ display: flex;
32
+ flex-direction: row;
33
+ }
34
+
35
+ /* Container for the vertical line and nodes */
36
+ .commit-tree {
37
+ position: relative;
38
+ height: 42.5rem; /* Full viewport height */
39
+ width: 100%;
40
+ }
41
+
42
+ /* Vertical line using pseudo-element */
43
+ .commit-tree::before {
44
+ content: '';
45
+ position: absolute;
46
+ left: 50%;
47
+ top: 0;
48
+ bottom: 0;
49
+ width: 4px;
50
+ background: linear-gradient(rgb(17 24 39 / var(--tw-bg-opacity, 1)) 0%, #e5e7eb 50%, #e5e7eb 100%);
51
+ }
52
+
53
+ /* Commit node styling */
54
+ .commit-node {
55
+ position: absolute;
56
+ left: 50%;
57
+ transform: translateX(calc(-50% + 2px));
58
+ width: 12px;
59
+ height: 12px;
60
+ background-color: #e5e7eb; /* Blue circle */
61
+ border-radius: 50%;
62
+ cursor: pointer;
63
+ z-index: 1;
64
+ display: flex;
65
+ flex-direction: row;
66
+ }
67
+
68
+ .outer_svg {
69
+
70
+ }
71
+
72
+ /* Tooltip styling */
73
+ .tooltip {
74
+ width: 350px;
75
+ text-align: center;
76
+ border-radius: 6px;
77
+ padding: 8px;
78
+ position: absolute;
79
+ z-index: 2;
80
+ left: 120%; /* Position to the right of the node */
81
+ top: 50%;
82
+ transform: translateY(-50%);
83
+ white-space: nowrap;
84
+ font-size: 14px;
85
+ transition: all 0.3s;
86
+ }
87
+
88
+ .tooltip:hover {
89
+ width: 500px;
90
+ }
91
+
92
+ .tooltip .title {
93
+ height: 2.6rem;
94
+ transition: all 0.3s;
95
+ }
96
+
97
+
98
+ .tooltip:hover .title {
99
+ height: 4.25rem;
100
+ }
101
+
102
+ .tooltip .desc {
103
+ visibility: hidden;
104
+ transition: all 0.3s;
105
+ opacity: 0;
106
+ }
107
+
108
+ .tooltip:hover .desc {
109
+ visibility: visible;
110
+ opacity: 1;
111
+ }
112
+
113
+
114
+ /*!* Show tooltip on hover *!*/
115
+ /*.commit-node:hover .tooltip {*/
116
+ /* visibility: visible;*/
117
+ /* opacity: 1;*/
118
+ /* top: 50%;*/
119
+ /*}*/