From 30771975b96e747a289b829431522ab795fa20a8 Mon Sep 17 00:00:00 2001 From: lenghui Date: Tue, 3 Dec 2024 11:35:02 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A1=8C=E5=86=85=E6=A0=B7=E5=BC=8F=E6=8A=BD?= =?UTF-8?q?=E7=A6=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- vueHomilyLink/src/views/LiveView.vue | 47 ++++++++++++++++++++++++++---------- 1 file changed, 34 insertions(+), 13 deletions(-) diff --git a/vueHomilyLink/src/views/LiveView.vue b/vueHomilyLink/src/views/LiveView.vue index 24d4104..9c042cb 100644 --- a/vueHomilyLink/src/views/LiveView.vue +++ b/vueHomilyLink/src/views/LiveView.vue @@ -4,25 +4,19 @@
节目1 -
- 即将开播
-
- {{getDateDay(live.startTime)}} {{ live.startTime.slice(11, 16)}}开播
+
即将开播
+
{{ getDateDay(live.startTime) }} {{ live.startTime.slice(11, 16) }}开播
{{ live.liveName }}
-
+
- 节目1 + 节目1
{{ live.user.userName }}
- 预约 + 预约 已预约
@@ -156,6 +150,7 @@ function getDateDay(startTime) { function booking(liveId, userId) { alert("预约成功!"); } + @@ -186,7 +181,7 @@ function booking(liveId, userId) { width: 209px; } -.card img { +.card .cover-image img { width: 100%; height: 100%; /*图片占满整个卡片*/ @@ -201,6 +196,31 @@ function booking(liveId, userId) { border-radius: 8px; } +/*即将开播图层*/ +.overlay { + position: absolute; + z-index: 2; + text-align: center; + top: 30%; + left: 50%; + transform: translate(-50%, -50%); + color: #fff; + font-size: 18px; +} + +/*开播时间*/ +.start-time { + position: absolute; + z-index: 2; + text-align: center; + top: 60%; + left: 50%; + transform: translate(-50%, -50%); + color: #ffffffaf; + font-size: 15px; + width: 120px; +} + .cover-image::before { content: " "; position: absolute; @@ -212,6 +232,7 @@ function booking(liveId, userId) { background-color: rgba(0, 0, 0, 0.3); border-radius: 8px; } + /*用于隐藏样式*/ .cover-image.no-overlay::before { display: none;