Fix that appear 'Unknown Team' in all team names

#1
Files changed (1) hide show
  1. index.html +2 -3
index.html CHANGED
@@ -32,9 +32,8 @@
32
  .map(file => {
33
  const url =
34
  `https://huggingface.co/datasets/LeRobot-worldwide-hackathon/submissions/resolve/main/${encodeURIComponent(file.path)}`;
35
- const match = file.path.match(/(?:team|group)[-_ ]?(\d+)/i);
36
- const team = match ? match[1] : null;
37
- const label = team ? `Team ${team}` : "Unknown Team";
38
  return {
39
  url,
40
  label,
 
32
  .map(file => {
33
  const url =
34
  `https://huggingface.co/datasets/LeRobot-worldwide-hackathon/submissions/resolve/main/${encodeURIComponent(file.path)}`;
35
+ const team = file.path.split('-')[0];
36
+ const label = team.length <= 3 ? `Team ${team}` : "Unknown Team";
 
37
  return {
38
  url,
39
  label,