You've already forked lubo_comment_query
样式
This commit is contained in:
@@ -5,61 +5,96 @@
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<link href="{{ mix('/css/app.css') }}" rel="stylesheet"/>
|
||||
</head>
|
||||
<body>
|
||||
<body class="bg-gray-50 dark:bg-gray-900 min-h-screen flex flex-col text-gray-900 dark:text-gray-100">
|
||||
@include("common.header")
|
||||
<form class="max-w xl:max-w-5xl lg:max-w-2xl md:max-w-lg mx-2 md:mx-auto form py-2" action="">
|
||||
<label for="keyword">查找视频标题,空格隔开查找多个关键词</label>
|
||||
<input class="border border-black" type="text" name="keyword" id="keyword" value="{{$keyword}}">
|
||||
<input class="border border-black" type="submit">
|
||||
</form>
|
||||
@foreach($video_list as $video)
|
||||
<div class="max-w xl:max-w-5xl lg:max-w-2xl md:max-w-lg mx-2 md:mx-auto px-2 md:px-4 py-4 bg-white border border-gray-200 rounded-lg shadow-md my-4 dark:bg-gray-800">
|
||||
<div>
|
||||
<a href="/video/{{$video->id}}" class="text-2xl font-bold text-gray-700 dark:text-white hover:text-gray-600 dark:hover:text-gray-200 hover:underline" tabindex="0" role="link">{{$video->title}}</a>
|
||||
<div class="px-2 md:px-4 lg:px-8 mt-2 flex items-center justify-between">
|
||||
<span class="text-sm font-light text-gray-600 dark:text-gray-400 hidden md:block">投稿时间:{{$video->created_at}}</span>
|
||||
|
||||
<main class="flex-grow container mx-auto px-4 sm:px-6 lg:px-8 py-8">
|
||||
<div class="max-w-5xl mx-auto">
|
||||
<form class="bg-white dark:bg-gray-800 p-6 rounded-xl shadow-sm mb-8 transition-colors duration-200" action="">
|
||||
<label for="keyword" class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-2">查找视频标题</label>
|
||||
<div class="relative flex items-center">
|
||||
<input type="text" name="keyword" id="keyword" value="{{$keyword}}"
|
||||
class="block w-full rounded-l-lg border-gray-300 dark:border-gray-600 dark:bg-gray-700 dark:text-white shadow-sm focus:border-indigo-500 focus:ring-indigo-500 sm:text-sm py-3"
|
||||
placeholder="输入关键词,空格隔开...">
|
||||
<button type="submit" class="inline-flex items-center px-6 py-3 border border-transparent text-base font-medium rounded-r-lg shadow-sm text-white bg-indigo-600 hover:bg-indigo-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500 transition-colors duration-200">
|
||||
搜索
|
||||
</button>
|
||||
</div>
|
||||
<p class="px-2 md:px-4 lg:px-8 mt-2 text-gray-600 dark:text-gray-300">视频时长:{{$video->total_duration}}</p>
|
||||
@if($video->danmakus_count > 0)
|
||||
<p class="px-2 md:px-4 lg:px-8 mt-2 text-gray-600 dark:text-gray-300">
|
||||
弹幕数量:{{$video->danmakus_count}}
|
||||
@if($video->bilibili_danmakus_count > 0)
|
||||
<img class="w-4 h-4 inline-block" src="https://cdn.jerryyan.net/luboimg/bilibili.ico" alt="B站" title="包含B站直播弹幕">
|
||||
@endif
|
||||
@if($video->ixigua_danmakus_count > 0)
|
||||
<img class="w-4 h-4 inline-block" src="https://cdn.jerryyan.net/luboimg/ixigua.ico" alt="西瓜视频" title="包含西瓜视频直播弹幕">
|
||||
@endif
|
||||
@if($video->douyin_danmakus_count > 0)
|
||||
<img class="w-4 h-4 inline-block" src="https://cdn.jerryyan.net/luboimg/douyin.ico" alt="抖音" title="包含抖音直播弹幕">
|
||||
@endif
|
||||
</p>
|
||||
@endif
|
||||
@if($video->programs_count > 0)
|
||||
<p class="px-2 md:px-4 lg:px-8 mt-2 text-gray-600 dark:text-gray-300">节目数量:{{$video->programs_count}}</p>
|
||||
@endif
|
||||
<p class="mt-2 text-xs text-gray-500 dark:text-gray-400">支持多个关键词组合搜索</p>
|
||||
</form>
|
||||
|
||||
<div class="space-y-6">
|
||||
@foreach($video_list as $video)
|
||||
<div class="bg-white dark:bg-gray-800 rounded-xl shadow-sm border border-gray-100 dark:border-gray-700 hover:shadow-md transition-shadow duration-200 overflow-hidden">
|
||||
<div class="p-6">
|
||||
<div class="flex justify-between items-start mb-3">
|
||||
<a href="/video/{{$video->id}}" class="text-xl font-bold text-gray-900 dark:text-white hover:text-indigo-600 dark:hover:text-indigo-400 transition-colors line-clamp-1">
|
||||
{{$video->title}}
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<div class="grid grid-cols-1 md:grid-cols-2 gap-4 text-sm text-gray-600 dark:text-gray-400 mb-4 bg-gray-50 dark:bg-gray-700/30 p-4 rounded-lg">
|
||||
<div class="flex items-center">
|
||||
<span class="font-medium mr-2">投稿时间:</span>
|
||||
{{$video->created_at}}
|
||||
</div>
|
||||
<div class="flex items-center">
|
||||
<span class="font-medium mr-2">视频时长:</span>
|
||||
{{$video->total_duration}}
|
||||
</div>
|
||||
@if($video->danmakus_count > 0)
|
||||
<div class="flex items-center">
|
||||
<span class="font-medium mr-2">弹幕数量:</span>
|
||||
{{$video->danmakus_count}}
|
||||
<div class="flex space-x-2 ml-2">
|
||||
@if($video->bilibili_danmakus_count > 0)
|
||||
<img class="w-4 h-4" src="https://cdn.jerryyan.net/luboimg/bilibili.ico" alt="B站" title="包含B站直播弹幕">
|
||||
@endif
|
||||
@if($video->ixigua_danmakus_count > 0)
|
||||
<img class="w-4 h-4" src="https://cdn.jerryyan.net/luboimg/ixigua.ico" alt="西瓜视频" title="包含西瓜视频直播弹幕">
|
||||
@endif
|
||||
@if($video->douyin_danmakus_count > 0)
|
||||
<img class="w-4 h-4" src="https://cdn.jerryyan.net/luboimg/douyin.ico" alt="抖音" title="包含抖音直播弹幕">
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
@if($video->programs_count > 0)
|
||||
<div class="flex items-center">
|
||||
<span class="font-medium mr-2">节目数量:</span>
|
||||
{{$video->programs_count}}
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
|
||||
<div class="flex flex-wrap items-center gap-4 text-sm border-t dark:border-gray-700 pt-4">
|
||||
<a href="https://www.bilibili.com/video/{{$video->bvid}}" target="_blank" class="inline-flex items-center text-indigo-600 dark:text-indigo-400 hover:text-indigo-800 dark:hover:text-indigo-300 font-medium transition-colors">
|
||||
去B站浏览
|
||||
<svg class="w-4 h-4 ml-1" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M10 6H6a2 2 0 00-2 2v10a2 2 0 002 2h10a2 2 0 002-2v-4M14 4h6m0 0v6m0-6L10 14"></path></svg>
|
||||
</a>
|
||||
@if($video->danmakus_count > 0)
|
||||
<a href="/danmakus/{{$video->bvid}}" class="inline-flex items-center text-gray-700 dark:text-gray-300 hover:text-indigo-600 dark:hover:text-indigo-400 transition-colors">
|
||||
<svg class="w-4 h-4 mr-1" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M8 10h.01M12 10h.01M16 10h.01M9 16H5a2 2 0 01-2-2V6a2 2 0 012-2h14a2 2 0 012 2v8a2 2 0 01-2 2h-5l-5 5v-5z"></path></svg>
|
||||
直播弹幕明细
|
||||
</a>
|
||||
@endif
|
||||
@if($video->programs_count > 0)
|
||||
<a href="/video/{{$video->id}}" class="inline-flex items-center text-gray-700 dark:text-gray-300 hover:text-indigo-600 dark:hover:text-indigo-400 transition-colors">
|
||||
<svg class="w-4 h-4 mr-1" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M4 6h16M4 10h16M4 14h16M4 18h16"></path></svg>
|
||||
节目列表
|
||||
</a>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
</div>
|
||||
|
||||
<div class="flex items-center gap-4 mt-4">
|
||||
<a href="https://www.bilibili.com/video/{{$video->bvid}}" target="_blank" class="inline-flex text-blue-600 dark:text-blue-400 hover:underline" tabindex="0" role="link">
|
||||
去B站浏览
|
||||
<svg class="w-5 h-5 ml-2" fill="currentColor" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path d="M11 3a1 1 0 100 2h2.586l-6.293 6.293a1 1 0 101.414 1.414L15 6.414V9a1 1 0 102 0V4a1 1 0 00-1-1h-5z"></path><path d="M5 5a2 2 0 00-2 2v8a2 2 0 002 2h8a2 2 0 002-2v-3a1 1 0 10-2 0v3H5V7h3a1 1 0 000-2H5z"></path></svg>
|
||||
</a>
|
||||
@if($video->danmakus_count > 0)
|
||||
<a href="/danmakus/{{$video->bvid}}" class="inline-flex text-blue-600 dark:text-blue-400 hover:underline" tabindex="0" role="link">
|
||||
直播弹幕明细
|
||||
</a>
|
||||
@endif
|
||||
@if($video->programs_count > 0)
|
||||
<a href="/video/{{$video->id}}" class="inline-flex text-blue-600 dark:text-blue-400 hover:underline" tabindex="0" role="link">
|
||||
节目列表
|
||||
</a>
|
||||
@endif
|
||||
<div class="mt-8">
|
||||
{{$video_list->onEachSide(1)->links()}}
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
<div class="max-w xl:max-w-5xl lg:max-w-2xl md:max-w-lg mx-2 md:mx-auto sticky bottom-0">
|
||||
{{$video_list->links()}}
|
||||
</div>
|
||||
</main>
|
||||
@include("common.footer")
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
@@ -1,44 +1,87 @@
|
||||
<html lang="zh">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>录播弹幕查询</title>
|
||||
<title>录播弹幕查询 - {{$video->title}}</title>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<link href="{{ mix('/css/app.css') }}" rel="stylesheet"/>
|
||||
</head>
|
||||
<body>
|
||||
<body class="bg-gray-50 dark:bg-gray-900 min-h-screen flex flex-col text-gray-900 dark:text-gray-100">
|
||||
@include("common.header")
|
||||
<div>
|
||||
<h3 class="text-2xl font-bold">{{$video->title}}</h3>
|
||||
<h4 class="text-lg">弹幕数:{{$video->danmakus_count}}</h4>
|
||||
</div>
|
||||
<form action="">
|
||||
<label for="keyword">查找弹幕关键词,支持搜索用户名,空格隔开查找多个关键词</label>
|
||||
<input class="border border-black" type="text" name="keyword" id="keyword" value="{{$keyword}}">
|
||||
<input class="border border-black" type="submit">
|
||||
</form>
|
||||
<table class="table-auto border-collapse w-full lg:border lg:border-black">
|
||||
<thead>
|
||||
<tr class="border border-black sticky bg-white lg:static top-0 left-0 right-0">
|
||||
<th class="border border-black">发送人</th>
|
||||
<th class="border border-black">弹幕内容</th>
|
||||
<th class="border border-black">发送时间</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach($danmakus as $danmaku)
|
||||
<tr>
|
||||
<td class="border">
|
||||
<x-links.user_link :name="$danmaku->from" :plt-id="$danmaku->platform_id" :mid="$danmaku->from_mid"></x-links.user_link>
|
||||
</td>
|
||||
<td class="border">{{$danmaku->content}}</td>
|
||||
<td class="border text-sm">{{$danmaku->created_at}}</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
</table>
|
||||
<div class="max-w xl:max-w-5xl lg:max-w-2xl md:max-w-lg mx-2 md:mx-auto sticky bottom-0">
|
||||
{{$danmakus->links()}}
|
||||
</div>
|
||||
|
||||
<main class="flex-grow container mx-auto px-4 sm:px-6 lg:px-8 py-8">
|
||||
<div class="max-w-7xl mx-auto">
|
||||
|
||||
<div class="mb-8">
|
||||
<h1 class="text-2xl font-bold text-gray-900 dark:text-white mb-2">{{$video->title}}</h1>
|
||||
<div class="flex items-center text-sm text-gray-500 dark:text-gray-400">
|
||||
<span class="mr-4">弹幕总数:{{$video->danmakus_count}}</span>
|
||||
<a class="inline-flex items-center text-indigo-600 dark:text-indigo-400 hover:text-indigo-800 dark:hover:text-indigo-300 font-medium transition-colors" href="https://www.bilibili.com/video/{{$video->bvid}}" target="_blank">
|
||||
<svg class="w-4 h-4 mr-1" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M10 6H6a2 2 0 00-2 2v10a2 2 0 002 2h10a2 2 0 002-2v-4M14 4h6m0 0v6m0-6L10 14"></path></svg>
|
||||
前往B站
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<form class="bg-white dark:bg-gray-800 p-6 rounded-xl shadow-sm mb-8 transition-colors duration-200" action="">
|
||||
<label for="keyword" class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-2">查找弹幕关键词 / 用户名</label>
|
||||
<div class="relative flex items-center">
|
||||
<input type="text" name="keyword" id="keyword" value="{{$keyword}}"
|
||||
class="block w-full rounded-l-lg border-gray-300 dark:border-gray-600 dark:bg-gray-700 dark:text-white shadow-sm focus:border-indigo-500 focus:ring-indigo-500 sm:text-sm py-3"
|
||||
placeholder="输入内容或用户名...">
|
||||
<button type="submit" class="inline-flex items-center px-6 py-3 border border-transparent text-base font-medium rounded-r-lg shadow-sm text-white bg-indigo-600 hover:bg-indigo-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500 transition-colors duration-200">
|
||||
搜索
|
||||
</button>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
<!-- Desktop Table -->
|
||||
<div class="hidden md:block bg-white dark:bg-gray-800 shadow overflow-hidden rounded-lg">
|
||||
<table class="min-w-full divide-y divide-gray-200 dark:divide-gray-700">
|
||||
<thead class="bg-gray-50 dark:bg-gray-700">
|
||||
<tr>
|
||||
<th scope="col" class="px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-gray-300 uppercase tracking-wider w-1/5">发送人</th>
|
||||
<th scope="col" class="px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-gray-300 uppercase tracking-wider w-3/5">弹幕内容</th>
|
||||
<th scope="col" class="px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-gray-300 uppercase tracking-wider w-1/5">发送时间</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody class="bg-white dark:bg-gray-800 divide-y divide-gray-200 dark:divide-gray-700">
|
||||
@foreach($danmakus as $danmaku)
|
||||
<tr class="hover:bg-gray-50 dark:hover:bg-gray-700 transition-colors">
|
||||
<td class="px-6 py-4 whitespace-nowrap text-sm font-medium">
|
||||
<x-links.user_link :name="$danmaku->from" :plt-id="$danmaku->platform_id" :mid="$danmaku->from_mid"></x-links.user_link>
|
||||
</td>
|
||||
<td class="px-6 py-4 text-sm text-gray-900 dark:text-gray-100">
|
||||
{{$danmaku->content}}
|
||||
</td>
|
||||
<td class="px-6 py-4 whitespace-nowrap text-sm text-gray-500 dark:text-gray-400">
|
||||
{{$danmaku->created_at}}
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<!-- Mobile List -->
|
||||
<div class="md:hidden space-y-4">
|
||||
@foreach($danmakus as $danmaku)
|
||||
<div class="bg-white dark:bg-gray-800 p-4 rounded-lg shadow-sm border border-gray-100 dark:border-gray-700">
|
||||
<div class="flex justify-between items-start mb-2">
|
||||
<div class="text-sm font-bold">
|
||||
<x-links.user_link :name="$danmaku->from" :plt-id="$danmaku->platform_id" :mid="$danmaku->from_mid"></x-links.user_link>
|
||||
</div>
|
||||
<div class="text-xs text-gray-400">{{$danmaku->created_at}}</div>
|
||||
</div>
|
||||
<p class="text-gray-900 dark:text-gray-100 text-base">{{$danmaku->content}}</p>
|
||||
</div>
|
||||
@endforeach
|
||||
</div>
|
||||
|
||||
<div class="mt-8">
|
||||
{{$danmakus->onEachSide(1)->links()}}
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
@include("common.footer")
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
Reference in New Issue
Block a user