Skip to content

Commit 708d54f

Browse files
committed
id Given
1 parent 9ecafb2 commit 708d54f

File tree

8 files changed

+139
-137
lines changed

8 files changed

+139
-137
lines changed

src/Component/AppBar.razor

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44
@inject NavigationManager nav
55
@inject IJSRuntime JSRuntime
66

7-
<header class="fixed top-0 left-0 right-0 z-50 tom-jerry-header shadow-lg">
7+
<header id="app-header" class="fixed top-0 left-0 right-0 z-50 tom-jerry-header shadow-lg">
88
<div class="max-w-7xl mx-auto px-2 sm:px-4">
99
<div class="flex items-center justify-between h-14 sm:h-16">
1010
<!-- Left Section -->
11-
<div class="flex items-center space-x-2 sm:space-x-4">
11+
<div id="header-left-section" class="flex items-center space-x-2 sm:space-x-4">
1212
<!-- Logo -->
13-
<div class="flex items-center space-x-2 sm:space-x-3 cursor-pointer" @onclick="GoToHomePage">
13+
<div id="app-logo" class="flex items-center space-x-2 sm:space-x-3 cursor-pointer" @onclick="GoToHomePage">
1414
<div class="tom-character">
1515
<div class="w-8 h-8 sm:w-10 sm:h-10 rounded-full overflow-hidden ring-2 ring-white/30 shadow-lg">
1616
<RandomSticker Category="classic" CssClass="w-full h-full" ImageCssClass="w-full h-full object-cover" AutoRefresh="true" RefreshIntervalSeconds="12" />
@@ -20,14 +20,14 @@
2020
</div>
2121

2222
<!-- Center Section - Search -->
23-
<div class="flex-1 max-w-xs sm:max-w-md md:max-w-2xl mx-2 sm:mx-4 md:mx-8">
23+
<div id="header-search-section" class="flex-1 max-w-xs sm:max-w-md md:max-w-2xl mx-2 sm:mx-4 md:mx-8">
2424
<RealTimeSearch />
2525
</div>
2626

2727
<!-- Right Section -->
28-
<div class="flex items-center space-x-1 sm:space-x-2">
28+
<div id="header-right-section" class="flex items-center space-x-1 sm:space-x-2">
2929
<!-- Quiz Button -->
30-
<button @onclick="GoToQuiz"
30+
<button id="header-quiz-btn" @onclick="GoToQuiz"
3131
class="hidden sm:flex items-center space-x-2 bg-cartoon-yellow text-amber-800 rounded-xl px-3 py-2 font-bold font-comic hover:bg-cartoon-orange transition-colors cartoon-rounded">
3232
<span class="text-lg">🧠</span>
3333
<span class="text-sm">Quiz</span>

src/Component/StickerGallery.razor

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@
33
@inject IStickerService StickerService
44
@inherits BaseComponent
55

6-
<div class="sticker-gallery">
6+
<div id="sticker-gallery" class="sticker-gallery">
77
@if (isLoading)
88
{
99
<!-- Loading State -->
10-
<div class="flex justify-center items-center py-8">
10+
<div id="sticker-loading-state" class="flex justify-center items-center py-8">
1111
<div class="flex space-x-2">
1212
<div class="w-4 h-4 bg-tom-blue rounded-full animate-bounce"></div>
1313
<div class="w-4 h-4 bg-cartoon-red rounded-full animate-bounce" style="animation-delay: 0.1s"></div>
@@ -18,24 +18,24 @@
1818
else if (stickers.Any())
1919
{
2020
<!-- Sticker Grid -->
21-
<div class="grid grid-cols-2 sm:grid-cols-3 md:grid-cols-4 lg:grid-cols-6 xl:grid-cols-8 gap-3 sm:gap-4">
21+
<div id="sticker-grid" class="grid grid-cols-2 sm:grid-cols-3 md:grid-cols-4 lg:grid-cols-6 xl:grid-cols-8 gap-3 sm:gap-4">
2222
@foreach (var sticker in stickers)
2323
{
24-
<div class="sticker-item group cursor-pointer" @onclick="() => OnStickerClick(sticker)">
24+
<div id="[email protected]" class="sticker-item group cursor-pointer" @onclick="() => OnStickerClick(sticker)">
2525
<div class="relative aspect-square bg-gradient-to-br from-soft-yellow to-cartoon-orange rounded-xl sm:rounded-2xl overflow-hidden border-2 border-jerry-brown shadow-lg hover:shadow-xl transition-all duration-300 group-hover:scale-110 group-hover:rotate-2">
2626
<img src="@sticker.ImagePath"
2727
alt="@sticker.DisplayName"
2828
class="w-full h-full object-cover group-hover:scale-110 transition-transform duration-300"/>
2929

3030
<!-- Hover Overlay -->
31-
<div class="absolute inset-0 bg-gradient-to-t from-black/50 to-transparent opacity-0 group-hover:opacity-100 transition-opacity duration-300">
31+
<div id="[email protected]" class="absolute inset-0 bg-gradient-to-t from-black/50 to-transparent opacity-0 group-hover:opacity-100 transition-opacity duration-300">
3232
<div class="absolute bottom-2 left-2 right-2">
3333
<p class="text-white text-xs font-comic font-bold text-center truncate">@sticker.DisplayName</p>
3434
</div>
3535
</div>
3636

3737
<!-- Category Badge -->
38-
<div class="absolute top-2 right-2 bg-jerry-brown text-white text-xs px-2 py-1 rounded-full font-bold font-comic opacity-0 group-hover:opacity-100 transition-opacity duration-300">
38+
<div id="[email protected]" class="absolute top-2 right-2 bg-jerry-brown text-white text-xs px-2 py-1 rounded-full font-bold font-comic opacity-0 group-hover:opacity-100 transition-opacity duration-300">
3939
@sticker.Category
4040
</div>
4141
</div>
@@ -46,7 +46,7 @@
4646
else
4747
{
4848
<!-- Empty State -->
49-
<div class="text-center py-12">
49+
<div id="sticker-empty-state" class="text-center py-12">
5050
<div class="text-gray-500">
5151
<svg class="w-16 h-16 mx-auto mb-4" fill="none" stroke="currentColor" viewBox="0 0 24 24">
5252
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M4 16l4.586-4.586a2 2 0 012.828 0L16 16m-2-2l1.586-1.586a2 2 0 012.828 0L20 14m-6-6h.01M6 20h12a2 2 0 002-2V6a2 2 0 00-2-2H6a2 2 0 00-2 2v12a2 2 0 002 2z"></path>

src/Component/Thumbnail.razor

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@
22
@using TomAndJerry.Model
33
@inject NavigationManager Nav
44

5-
<div class="tom-jerry-card cursor-pointer group p-2 sm:p-4" @onclick="GoToPage">
5+
<div id="[email protected]" class="tom-jerry-card cursor-pointer group p-2 sm:p-4" @onclick="GoToPage">
66
<!-- Thumbnail Container -->
7-
<div class="relative aspect-video bg-soft-yellow rounded-xl sm:rounded-2xl overflow-hidden mb-3 sm:mb-4 border-2 border-jerry-brown shadow-lg">
7+
<div id="[email protected]" class="relative aspect-video bg-soft-yellow rounded-xl sm:rounded-2xl overflow-hidden mb-3 sm:mb-4 border-2 border-jerry-brown shadow-lg">
88
<img src="@VideoModel.Thumbnail"
99
alt="@GetCleanTitle()"
1010
class="w-full h-full object-cover group-hover:scale-105 transition-transform duration-300"/>
1111

1212
<!-- Play Button Overlay -->
13-
<div class="absolute inset-0 flex items-center justify-center opacity-0 group-hover:opacity-100 transition-opacity duration-300">
13+
<div id="[email protected]" class="absolute inset-0 flex items-center justify-center opacity-0 group-hover:opacity-100 transition-opacity duration-300">
1414
<div class="w-16 h-16 sm:w-20 sm:h-20 bg-gradient-to-r from-tom-blue to-cartoon-red rounded-full flex items-center justify-center shadow-2xl cartoon-rounded animate-bounce-slow">
1515
<svg class="w-6 h-6 sm:w-8 sm:h-8 text-white ml-1" fill="currentColor" viewBox="0 0 20 20">
1616
<path fill-rule="evenodd" d="M10 18a8 8 0 100-16 8 8 0 000 16zM9.555 7.168A1 1 0 008 8v4a1 1 0 001.555.832l3-2a1 1 0 000-1.664l-3-2z" clip-rule="evenodd"/>
@@ -19,20 +19,20 @@
1919
</div>
2020

2121
<!-- Duration Badge -->
22-
<div class="absolute bottom-2 sm:bottom-3 right-2 sm:right-3 bg-jerry-brown text-white text-xs px-2 sm:px-3 py-1 rounded-full font-bold font-comic shadow-lg">
22+
<div id="[email protected]" class="absolute bottom-2 sm:bottom-3 right-2 sm:right-3 bg-jerry-brown text-white text-xs px-2 sm:px-3 py-1 rounded-full font-bold font-comic shadow-lg">
2323
7:30
2424
</div>
2525
</div>
2626

2727
<!-- Video Info -->
28-
<div class="space-y-2 sm:space-y-3">
28+
<div id="[email protected]" class="space-y-2 sm:space-y-3">
2929
<!-- Title -->
30-
<h3 class="font-bold text-amber-800 text-sm sm:text-base line-clamp-2 group-hover:text-blue-600 transition-colors font-cartoon">
30+
<h3 id="[email protected]" class="font-bold text-amber-800 text-sm sm:text-base line-clamp-2 group-hover:text-blue-600 transition-colors font-cartoon">
3131
@GetCleanTitle()
3232
</h3>
3333

3434
<!-- Channel Info -->
35-
<div class="flex items-center space-x-2 sm:space-x-3">
35+
<div id="[email protected]" class="flex items-center space-x-2 sm:space-x-3">
3636
<div class="jerry-character">
3737
<div class="w-6 h-6 sm:w-8 sm:h-8 rounded-full overflow-hidden ring-2 ring-cartoon-yellow shadow-lg">
3838
<RandomSticker CssClass="w-full h-full" ImageCssClass="w-full h-full object-cover" AutoRefresh="true" RefreshIntervalSeconds="15" />
@@ -42,7 +42,7 @@
4242
</div>
4343

4444
<!-- Stats -->
45-
<div class="text-xs sm:text-sm text-amber-800 font-comic font-semibold">
45+
<div id="[email protected]" class="text-xs sm:text-sm text-amber-800 font-comic font-semibold">
4646
<span class="bg-soft-yellow px-1.5 sm:px-2 py-0.5 sm:py-1 rounded-full">@GetRandomViews() views</span>
4747
<span class="mx-1 sm:mx-2">•</span>
4848
<span class="bg-soft-blue px-1.5 sm:px-2 py-0.5 sm:py-1 rounded-full">@GetRandomTimeAgo()</span>

0 commit comments

Comments
 (0)