From 7f48ad7939773a9bc02aad98dbc5e11a35d132e1 Mon Sep 17 00:00:00 2001 From: zuoxiao <zuoxiao> Date: 星期二, 19 八月 2025 15:42:32 +0800 Subject: [PATCH] 更新项目配置,启用URL检查功能;修改监测页面状态管理逻辑,优化在线状态的判断方式,提升用户体验和代码可读性。 --- pages/stationMonitor/stationMonitor.wxss | 969 ++++++++------------------------------------------------ 1 files changed, 139 insertions(+), 830 deletions(-) diff --git a/pages/stationMonitor/stationMonitor.wxss b/pages/stationMonitor/stationMonitor.wxss index 1a97158..b377ea2 100644 --- a/pages/stationMonitor/stationMonitor.wxss +++ b/pages/stationMonitor/stationMonitor.wxss @@ -18,7 +18,8 @@ padding: 0; margin: 0; background-color: #f5f5f5; - height: 100vh; /* 鍥哄畾楂樺害涓鸿鍙i珮搴� */ + height: 100vh; + /* 鍥哄畾楂樺害涓鸿鍙i珮搴� */ width: 100%; box-sizing: border-box; /* 闃叉浠讳綍婊氬姩 */ @@ -40,13 +41,16 @@ background-color: #fff; padding: 4rpx 0; width: 100%; - flex-shrink: 0; /* 闃叉琚帇缂� */ + flex-shrink: 0; + /* 闃叉琚帇缂� */ box-shadow: 0 4rpx 8rpx rgba(0, 0, 0, 0.05); border-bottom: 1rpx solid #eaeaea; - position: sticky; /* 浣跨敤sticky瀹氫綅 */ + position: sticky; + /* 浣跨敤sticky瀹氫綅 */ top: 0; z-index: 9999; - background-color: #fff; /* 纭繚鑳屾櫙鑹� */ + background-color: #fff; + /* 纭繚鑳屾櫙鑹� */ /* 鍑忓皬tabs楂樺害 */ height: 100rpx; box-sizing: border-box; @@ -152,12 +156,17 @@ box-sizing: border-box; /* 浣跨敤flex: 1濉厖鍓╀綑绌洪棿 */ flex: 1; - min-height: 0; /* 鍏佽flex椤圭洰鏀剁缉 */ - overflow-y: auto; /* 鍨傜洿婊氬姩 */ - overflow-x: hidden; /* 闅愯棌姘村钩婊氬姩 */ + min-height: 0; + /* 鍏佽flex椤圭洰鏀剁缉 */ + overflow-y: auto; + /* 鍨傜洿婊氬姩 */ + overflow-x: hidden; + /* 闅愯棌姘村钩婊氬姩 */ /* 闅愯棌婊氬姩鏉� */ - -ms-overflow-style: none; /* IE and Edge */ - scrollbar-width: none; /* Firefox */ + -ms-overflow-style: none; + /* IE and Edge */ + scrollbar-width: none; + /* Firefox */ /* 涓簍abs鐣欏嚭绌洪棿 */ margin-top: 0; } @@ -186,6 +195,7 @@ opacity: 0; transform: translateY(20rpx); } + to { opacity: 1; transform: translateY(0); @@ -466,31 +476,32 @@ .tab-name { font-size: 20rpx; } - + .tab-icon { width: 40rpx; height: 40rpx; } - + .tab-item { padding: 16rpx 2rpx; - width: 25%; /* 纭繚灏忓睆骞曚笅涔熷潎鍒� */ + width: 25%; + /* 纭繚灏忓睆骞曚笅涔熷潎鍒� */ } - + /* 姘旇薄绔欐暟鎹」鍝嶅簲寮忓瓧浣� */ .weather-data-item .data-label { font-size: 22rpx; } - + .weather-data-item .data-value { font-size: 28rpx; } - + .weather-data-item .data-icon { width: 50rpx; height: 50rpx; } - + .weather-data-item .data-icon image { width: 32rpx; height: 32rpx; @@ -502,30 +513,30 @@ .tab-name { font-size: 18rpx; } - + .tab-icon { width: 36rpx; height: 36rpx; } - + .tab-item { padding: 12rpx 1rpx; } - + /* 姘旇薄绔欐暟鎹」瓒呭皬灞忓箷鍝嶅簲寮忓瓧浣� */ .weather-data-item .data-label { font-size: 20rpx; } - + .weather-data-item .data-value { font-size: 24rpx; } - + .weather-data-item .data-icon { width: 46rpx; height: 46rpx; } - + .weather-data-item .data-icon image { width: 30rpx; height: 30rpx; @@ -536,81 +547,44 @@ .camera-list { display: flex; flex-direction: column; - /* gap: 20rpx; */ - margin: 0; - width: 100%; - box-sizing: border-box; - /* 纭繚鍦ㄤ笉鍚岃澶囦笂鐨勪竴鑷存�� */ - max-width: 100vw; - overflow-x: hidden; - /* 鏂板锛氱Щ闄ゅ乏鍙冲唴杈硅窛锛岀‘淇濆畬鍏ㄥ~鍏� */ - /* padding: 0; */ - /* 鏂板锛氬己鍒剁害鏉燂紝闃叉ezplayer瓒呭嚭 */ - /* contain: layout style paint; */ - /* 鏂板锛氬己鍒跺乏瀵归綈锛屾棤浠讳綍杈硅窛 */ - /* left: 0 !important; - right: 0 !important; */ + gap: 20rpx; + } .camera-item { - width: 100%; - max-width: 100%; - min-width: 0; background: white; - border-radius: 16rpx; - /* 绉婚櫎宸﹀彸鍐呰竟璺濓紝纭繚瀹屽叏濉厖 */ - padding: 24rpx 0; - box-shadow: 0 4rpx 16rpx rgba(0, 0, 0, 0.08); - box-sizing: border-box; - margin: 0; - position: relative; - overflow: hidden; - /* 纭繚鍦ㄤ笉鍚岃澶囦笂鐨勬樉绀轰竴鑷存�� */ - flex-shrink: 0; - flex-grow: 0; - /* 鏂板锛氬己鍒剁害鏉燂紝闃叉ezplayer瓒呭嚭 */ - contain: layout style paint; - /* 鏂板锛氬己鍒跺乏瀵归綈锛屾棤浠讳綍杈硅窛 */ - left: 0 !important; - right: 0 !important; + border-radius: 12rpx; + margin-bottom: 10rpx; + + box-shadow: 0 2rpx 8rpx rgba(0, 0, 0, 0.1); } /* 鎽勫儚澶村ご閮� */ .camera-header { - width: 100%; - max-width: 100%; - min-width: 0; display: flex; justify-content: space-between; align-items: center; - margin-bottom: 20rpx; - box-sizing: border-box; - /* 闃叉鏂囧瓧婧㈠嚭 */ - overflow: hidden; - margin: 20rpx 10rpx; + margin-bottom: 16rpx; + margin-top: 15rpx; + margin-left: 15rpx; + margin-right: 15rpx; } .camera-name { - font-size: 32rpx; + font-size: 28rpx; font-weight: 600; color: #333; flex: 1; - min-width: 0; - /* 鏂囧瓧婧㈠嚭澶勭悊 */ white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .camera-status { - padding: 8rpx 16rpx; - border-radius: 20rpx; - font-size: 24rpx; + padding: 6rpx 12rpx; + border-radius: 16rpx; + font-size: 22rpx; font-weight: 500; - white-space: nowrap; - flex-shrink: 0; - /* 纭繚鐘舵�佹爣绛句笉琚帇缂� */ - min-width: fit-content; } .camera-status.online { @@ -629,52 +603,42 @@ .camera-video-container { position: relative; width: 100%; - max-width: 100%; - min-width: 0; - /* height: 400rpx; */ - /* 绉婚櫎鎵�鏈夎楗版�ф牱寮忥紝纭繚瀹屽叏濉厖 */ - border-radius: 0; + height: 100%; + border-radius: 8rpx; overflow: hidden; - margin: 0; - padding: 0; - box-sizing: border-box; - background-color: transparent; - border: none; - /* 纭繚鍦ㄤ笉鍚岃澶囦笂鐨勬樉绀轰竴鑷存�� */ - flex-shrink: 0; - /* 闃叉ezplayer瓒呭嚭瀹瑰櫒 - 寮哄寲绾︽潫 */ - overflow: hidden !important; - /* 鏂板锛氱粷瀵瑰畾浣嶇害鏉� */ - position: relative !important; - /* 鏂板锛氬己鍒跺搴︾害鏉燂紝闃叉ezplayer瓒呭嚭 */ - max-width: 100vw !important; - /* 鏂板锛氱‘淇濆鍣ㄤ笉浼氳秴鍑虹埗鍏冪礌 */ - contain: layout style paint !important; - /* 鏂板锛氬己鍒跺乏瀵归綈锛岄槻姝㈠彸绉� */ - left: 0 !important; - right: 0 !important; - /* 鏂板锛氬己鍒跺~鍏呮暣涓睆骞� */ - /* width: 100vw !important; - min-width: 100vw !important; */ + background-color: #f5f5f5; } -/* 绉婚櫎璋冭瘯杈规锛岄伩鍏嶅奖鍝峞zplayer鏄剧ず */ -/* 鍔犺浇鐘舵�� */ -.video-loading { - width: 100%; - height: 100%; - max-width: 100%; - min-width: 0; + +/* 瑙嗛鐘舵�佹牱寮� */ +.video-loading, +.video-error, +.video-offline, +.video-no-url { display: flex; flex-direction: column; align-items: center; justify-content: center; - background-color: #f8f9fa; - /* 纭繚鍦ㄤ笉鍚岃澶囦笂鐨勬樉绀轰竴鑷存�� */ - flex-shrink: 0; + height: 100%; + text-align: center; } +.video-loading { + background-color: #f8f9fa; +} + +.video-error { + background-color: #fff2f0; + border: 1rpx solid #ffccc7; +} + +.video-offline, +.video-no-url { + background-color: #f5f5f5; +} + +/* 鍔犺浇鍔ㄧ敾 */ .loading-spinner { width: 60rpx; height: 60rpx; @@ -683,8 +647,6 @@ border-radius: 50%; animation: spin 1s linear infinite; margin-bottom: 16rpx; - /* 纭繚鍔ㄧ敾鍦ㄤ笉鍚岃澶囦笂鐨勪竴鑷存�� */ - flex-shrink: 0; } @keyframes spin { @@ -692,650 +654,75 @@ 100% { transform: rotate(360deg); } } -.loading-text { - font-size: 26rpx; +.loading-text, +.error-text, +.offline-text, +.no-url-text { + font-size: 24rpx; color: #666; - font-weight: 500; - text-align: center; - /* 纭繚鏂囧瓧鍦ㄤ笉鍚岃澶囦笂鐨勪竴鑷存�� */ - white-space: nowrap; - overflow: hidden; - text-overflow: ellipsis; - max-width: 100%; -} - -/* 閿欒鐘舵�� */ -.video-error { - width: 100%; - height: 100%; - max-width: 100%; - min-width: 0; - display: flex; - flex-direction: column; - align-items: center; - justify-content: center; - background-color: #fff2f0; - border: 1rpx solid #ffccc7; - /* 纭繚鍦ㄤ笉鍚岃澶囦笂鐨勬樉绀轰竴鑷存�� */ - flex-shrink: 0; -} - -.error-icon { - width: 80rpx; - height: 80rpx; - opacity: 0.6; - margin-bottom: 16rpx; - filter: grayscale(100%) brightness(0) saturate(100%) invert(27%) sepia(51%) saturate(2878%) hue-rotate(346deg) brightness(104%) contrast(97%); - /* 纭繚鍥炬爣鍦ㄤ笉鍚岃澶囦笂鐨勪竴鑷存�� */ - flex-shrink: 0; + margin-top: 8rpx; } .error-text { - font-size: 26rpx; color: #ff4d4f; - font-weight: 500; - margin-bottom: 20rpx; - text-align: center; - /* 纭繚鏂囧瓧鍦ㄤ笉鍚岃澶囦笂鐨勪竴鑷存�� */ - white-space: nowrap; - overflow: hidden; - text-overflow: ellipsis; - max-width: 100%; } +/* 鍥炬爣鏍峰紡 */ +.error-icon, +.offline-icon, +.no-url-icon { + width: 60rpx; + height: 60rpx; + opacity: 0.5; +} + +/* 閲嶈瘯鎸夐挳 */ .retry-btn { display: flex; align-items: center; - gap: 8rpx; - padding: 12rpx 24rpx; + gap: 6rpx; + padding: 8rpx 16rpx; background-color: #ff4d4f; color: white; border: none; - border-radius: 20rpx; - font-size: 24rpx; - transition: all 0.3s ease; - /* 纭繚鎸夐挳鍦ㄤ笉鍚岃澶囦笂鐨勪竴鑷存�� */ - flex-shrink: 0; - min-width: fit-content; + border-radius: 16rpx; + font-size: 22rpx; + margin-top: 12rpx; } .retry-btn:active { background-color: #cf1322; - transform: scale(0.98); } .retry-icon { - width: 24rpx; - height: 24rpx; - filter: brightness(0) invert(1); - /* 纭繚鍥炬爣鍦ㄤ笉鍚岃澶囦笂鐨勪竴鑷存�� */ - flex-shrink: 0; -} - -/* 鏃犳挱鏀惧湴鍧�鐘舵�� */ -.video-no-url { - width: 100%; - height: 100%; - max-width: 100%; - min-width: 0; - display: flex; - flex-direction: column; - align-items: center; - justify-content: center; - background-color: #f5f5f5; - /* 纭繚鍦ㄤ笉鍚岃澶囦笂鐨勬樉绀轰竴鑷存�� */ - flex-shrink: 0; -} - -.no-url-icon { - width: 80rpx; - height: 80rpx; - opacity: 0.4; - margin-bottom: 16rpx; - filter: grayscale(100%); - /* 纭繚鍥炬爣鍦ㄤ笉鍚岃澶囦笂鐨勪竴鑷存�� */ - flex-shrink: 0; -} - -.no-url-text { - font-size: 26rpx; - color: #999; - font-weight: 500; - text-align: center; - /* 纭繚鏂囧瓧鍦ㄤ笉鍚岃澶囦笂鐨勪竴鑷存�� */ - white-space: nowrap; - overflow: hidden; - text-overflow: ellipsis; - max-width: 100%; -} - -.video-wrapper { - position: relative; - width: 100%; - height: 100%; - max-width: 100%; - min-width: 0; - display: flex; - align-items: center; - justify-content: center; - /* 纭繚鍦ㄤ笉鍚岃澶囦笂鐨勬樉绀轰竴鑷存�� */ - flex-shrink: 0; - /* 闃叉鍐呭婧㈠嚭 */ - overflow: hidden !important; - /* 鏂板锛氱粷瀵瑰畾浣嶇害鏉� */ - position: relative !important; - /* 鏂板锛氱Щ闄ゆ墍鏈夎竟璺濆拰鍐呰竟璺� */ - margin: 0 !important; - padding: 0 !important; - /* 鏂板锛氬己鍒跺乏瀵归綈 */ - left: 0 !important; - right: 0 !important; -} - -/* ezplayer缁勪欢鏍峰紡浼樺寲 - 淇瓒呭嚭灞忓箷闂 */ -.video-wrapper ezplayer { - width: 100% !important; - height: 100% !important; - max-width: 100% !important; - min-width: 0 !important; - border-radius: 12rpx; - overflow: hidden !important; - /* 纭繚鍦ㄤ笉鍚岃澶囦笂鐨勬樉绀轰竴鑷存�� */ - flex-shrink: 0; - /* 闃叉瓒呭嚭灞忓箷鐨勫叧閿缃� */ - position: absolute !important; - left: 0 !important; - right: 0 !important; - top: 0 !important; - bottom: 0 !important; - /* 寮哄埗绾︽潫灏哄 - 淇鏈�灏忓搴﹂棶棰� */ - max-width: 100% !important; - max-height: 100% !important; - /* 鏂板锛氬己鍒剁害鏉熷埌鐖跺鍣� */ - transform: none !important; - transform-origin: center center !important; - /* 鏂板锛氱‘淇濅笉瓒呭嚭杈圭晫 */ - clip-path: inset(0 0 0 0) !important; - /* 鏂板锛氶槻姝换浣曞舰寮忕殑婧㈠嚭 */ - contain: layout style paint !important; - /* 鏂板锛氬己鍒跺搴︾害鏉燂紝瑕嗙洊ezplayer鐨勬渶灏忓搴﹂檺鍒� */ - min-width: 0 !important; - min-height: 0 !important; - /* 鏂板锛氱‘淇濈粍浠跺畬鍏ㄧ害鏉熷湪瀹瑰櫒鍐� */ - box-sizing: border-box !important; - /* 鏂板锛氱Щ闄ゆ墍鏈夎竟璺濆拰鍐呰竟璺� */ - margin: 0 !important; - padding: 0 !important; - /* 鏂板锛氬己鍒跺畬鍏ㄥ~鍏呭鍣� */ - inset: 0 !important; -} - -/* 閽堝ezplayer缁勪欢鐨勭壒娈婄害鏉� */ -.video-wrapper ezplayer { - /* 纭繚缁勪欢涓嶄細瓒呭嚭鐖跺鍣� */ - box-sizing: border-box !important; - /* 闃叉姘村钩婊氬姩 */ - overflow-x: hidden !important; - overflow-y: hidden !important; - /* 纭繚鍦╢lex瀹瑰櫒涓殑琛屼负 */ - flex: 0 0 auto !important; - /* 闃叉缂╂斁闂 */ - transform-origin: top left !important; - /* 纭繚杈规鍦嗚鐢熸晥 */ - border-radius: 12rpx !important; - /* 鏂板锛氬己鍒跺昂瀵哥害鏉� */ - min-width: 0 !important; - min-height: 0 !important; - /* 鏂板锛氶槻姝换浣曞舰寮忕殑鎷変几 */ - flex-basis: auto !important; - flex-grow: 0 !important; - flex-shrink: 0 !important; - /* 鏂板锛氱‘淇濆畾浣嶆纭� */ - position: absolute !important; - top: 0 !important; - left: 0 !important; - right: 0 !important; - bottom: 0 !important; - /* 鏂板锛氬己鍒跺搴﹀拰楂樺害 */ - width: 100% !important; - height: 100% !important; -} - -/* 鏂板锛氫笓闂ㄥ鐞唀zplayer鏆傚仠鐘舵�佺殑鏍峰紡 */ -.video-wrapper ezplayer[data-paused="true"], -.video-wrapper ezplayer.paused { - /* 寮哄埗绾︽潫瀹藉害锛岄槻姝㈣秴鍑哄睆骞� */ - width: 100% !important; - max-width: 100% !important; - min-width: 0 !important; - /* 纭繚缁勪欢瀹屽叏鍦ㄥ鍣ㄥ唴 */ - position: absolute !important; - left: 0 !important; - right: 0 !important; - /* 闃叉浠讳綍褰㈠紡鐨勬孩鍑� */ - overflow: hidden !important; - /* 寮哄埗绾︽潫鍒扮埗瀹瑰櫒 */ - contain: layout style paint !important; -} - -/* 鏂板锛氫娇鐢–SS Grid寮哄埗绾︽潫ezplayer */ -.video-wrapper { - display: grid !important; - grid-template-columns: 1fr !important; - grid-template-rows: 1fr !important; - place-items: stretch !important; -} - -/* 鏂板锛氬彧閽堝鎽勫儚澶寸浉鍏冲厓绱犲己鍒剁害鏉� */ -.camera-list, -.camera-item, -.camera-video-container, -.video-wrapper, -.camera-header, -.camera-name, -.camera-status, -.camera-video-container > ezplayer, -.video-wrapper > ezplayer { - max-width: 100% !important; - min-width: 0 !important; - box-sizing: border-box !important; - overflow: hidden !important; -} - -/* 鏂板锛氬己鍒剁Щ闄ゆ墍鏈夊彲鑳界殑杈硅窛鍜岃楗� */ -.camera-list, -.camera-item, -.camera-video-container, -.video-wrapper { - margin: 0 !important; - padding: 0 !important; - border: none !important; - border-radius: 0 !important; - box-shadow: none !important; - background: transparent !important; -} - -/* 鏂板锛氱壒鍒拡瀵筫zplayer鐨勫己鍒剁害鏉� */ -ezplayer { - width: 100vw !important; - height: 100% !important; - max-width: 100vw !important; - max-height: 100% !important; - min-width: 100vw !important; - min-height: 0 !important; - position: absolute !important; - left: 0 !important; - right: 0 !important; - top: 0 !important; - bottom: 0 !important; - overflow: hidden !important; - box-sizing: border-box !important; - contain: layout style paint !important; - /* 鏂板锛氬己鍒跺~鍏呮暣涓睆骞曞搴� */ - margin: 0 !important; - padding: 0 !important; - transform: none !important; - transform-origin: center center !important; - /* 鏂板锛氬己鍒剁Щ闄ゆ墍鏈夎楗� */ - border: none !important; - border-radius: 0 !important; - box-shadow: none !important; - background: transparent !important; - /* 鏂板锛氬己鍒剁害鏉熷埌灞忓箷杈圭紭 */ - inset: 0 !important; -} - -.video-wrapper ezplayer { - grid-column: 1 !important; - grid-row: 1 !important; - place-self: stretch !important; - /* 寮哄埗瀹屽叏濉厖缃戞牸鍗曞厓鏍� */ - width: 100% !important; - height: 100% !important; - max-width: 100% !important; - max-height: 100% !important; - min-width: 0 !important; - min-height: 0 !important; -} - -/* 瑙嗛鍖呰鍣ㄧ殑缁濆瀹氫綅绾︽潫 */ -.video-wrapper { - position: relative; - width: 100%; - height: 100%; - max-width: 100%; - min-width: 0; - display: flex; - align-items: center; - justify-content: center; - /* 纭繚鍦ㄤ笉鍚岃澶囦笂鐨勬樉绀轰竴鑷存�� */ - flex-shrink: 0; - /* 闃叉鍐呭婧㈠嚭 */ - overflow: hidden !important; - /* 鏂板锛氱粷瀵瑰畾浣嶇害鏉� */ - position: relative !important; -} - -.live-player { - width: 100%; - height: 100%; - max-width: 100%; - min-width: 0; - background-color: #000; - border-radius: 12rpx; - /* 纭繚鍦ㄤ笉鍚岃澶囦笂鐨勬樉绀轰竴鑷存�� */ - flex-shrink: 0; -} - -.video-overlay { - position: absolute; - top: 0; - left: 0; - right: 0; - bottom: 0; - background: rgba(0, 0, 0, 0.3); - display: flex; - align-items: center; - justify-content: center; - z-index: 10; -} - -.play-overlay { - width: 80rpx; - height: 80rpx; - background: rgba(0, 0, 0, 0.6); - border-radius: 50%; - display: flex; - align-items: center; - justify-content: center; - transition: all 0.3s ease; -} - -.play-overlay:active { - transform: scale(0.9); -} - -.play-icon { - width: 40rpx; - height: 40rpx; + width: 20rpx; + height: 20rpx; filter: brightness(0) invert(1); } -.video-info { - position: absolute; - bottom: 0; - left: 0; - right: 0; - background: linear-gradient(transparent, rgba(0, 0, 0, 0.7)); - padding: 20rpx 16rpx 16rpx; - color: white; - display: flex; - justify-content: space-between; - align-items: center; -} - -.video-time { - font-size: 24rpx; - opacity: 0.9; -} - -.video-status { - font-size: 22rpx; - opacity: 0.8; - color: #52c41a; -} - -/* 鎾斁鎺у埗鎸夐挳 */ -.video-controls { - position: absolute; - top: 16rpx; - right: 16rpx; - display: flex; - gap: 12rpx; - z-index: 20; -} - -.control-btn { - width: 60rpx; - height: 60rpx; - background: rgba(0, 0, 0, 0.6); - border-radius: 50%; - display: flex; - align-items: center; - justify-content: center; - transition: all 0.3s ease; -} - -.control-btn:active { - transform: scale(0.9); - background: rgba(0, 0, 0, 0.8); -} - -.control-icon { - width: 32rpx; - height: 32rpx; - filter: brightness(0) invert(1); -} - -/* 璋冭瘯鎸夐挳 */ -.debug-controls { - position: absolute; - bottom: 16rpx; - right: 16rpx; - z-index: 20; -} - -.debug-btn { - padding: 8rpx 16rpx; - background: rgba(255, 0, 0, 0.7); - border-radius: 20rpx; - font-size: 20rpx; - color: white; -} - -/* 绂荤嚎鐘舵�� */ -.video-offline { +/* 瑙嗛鎾斁鍣ㄥ鍣� */ +.video-wrapper { width: 100%; height: 100%; - max-width: 100%; - min-width: 0; - background-color: #f5f5f5; - display: flex; - flex-direction: column; - align-items: center; - justify-content: center; - border-radius: 12rpx; - /* 纭繚鍦ㄤ笉鍚岃澶囦笂鐨勬樉绀轰竴鑷存�� */ - flex-shrink: 0; } -.offline-icon { - width: 80rpx; - height: 80rpx; - opacity: 0.4; - margin-bottom: 16rpx; - filter: grayscale(100%); - /* 纭繚鍥炬爣鍦ㄤ笉鍚岃澶囦笂鐨勪竴鑷存�� */ - flex-shrink: 0; -} - -.offline-text { - font-size: 28rpx; - color: #999; - font-weight: 500; - text-align: center; - /* 纭繚鏂囧瓧鍦ㄤ笉鍚岃澶囦笂鐨勪竴鑷存�� */ - white-space: nowrap; - overflow: hidden; - text-overflow: ellipsis; - max-width: 100%; -} - -/* 鎿嶄綔鎸夐挳 */ -.camera-actions { +.video-wrapper-ezplayer { width: 100%; - max-width: 100%; - min-width: 0; - display: flex; - gap: 16rpx; - box-sizing: border-box; - /* 纭繚鍦ㄤ笉鍚岃澶囦笂鐨勬樉绀轰竴鑷存�� */ - flex-shrink: 0; + height: 100%; } -.action-btn { - flex: 1; - height: 72rpx; - border-radius: 36rpx; - font-size: 26rpx; - border: none; - display: flex; - align-items: center; - justify-content: center; - gap: 8rpx; - transition: all 0.3s ease; - box-sizing: border-box; - /* 纭繚鎸夐挳鍦ㄤ笉鍚岃澶囦笂鐨勪竴鑷存�� */ - min-width: 0; - overflow: hidden; -} -.action-btn.primary { - background-color: #1890FF; - color: white; -} -.action-btn.primary:active { - background-color: #096dd9; - transform: scale(0.98); -} -.action-btn.secondary { - background-color: #f5f5f5; - color: #666; - border: 1rpx solid #d9d9d9; -} -.action-btn.secondary:active { - background-color: #e8e8e8; - transform: scale(0.98); -} -/* 绂佺敤鐘舵�� */ -.action-btn[disabled] { - background-color: #f5f5f5 !important; - color: #bfbfbf !important; - border-color: #d9d9d9 !important; - cursor: not-allowed; - opacity: 0.6; - /* 纭繚绂佺敤鐘舵�佸湪涓嶅悓璁惧涓婄殑涓�鑷存�� */ - transform: none !important; -} -.action-btn[disabled]:active { - transform: none !important; - background-color: #f5f5f5 !important; -} -.action-btn.primary[disabled] { - background-color: #d9d9d9 !important; - color: #bfbfbf !important; -} -.action-btn.secondary[disabled] { - background-color: #f5f5f5 !important; - color: #bfbfbf !important; - border-color: #d9d9d9 !important; -} -.action-icon { - width: 32rpx; - height: 32rpx; - /* 纭繚鍥炬爣鍦ㄤ笉鍚岃澶囦笂鐨勪竴鑷存�� */ - flex-shrink: 0; -} -/* 鍝嶅簲寮忎紭鍖� - 纭繚鍦ㄤ笉鍚岃澶囦笂鐨勪竴鑷存�� */ -@media (max-width: 400px) { - .camera-item { - padding: 20rpx; - margin-bottom: 16rpx; - } - - .camera-header { - margin-bottom: 16rpx; - } - - .camera-name { - font-size: 28rpx; - } - - .camera-status { - font-size: 22rpx; - padding: 6rpx 12rpx; - } - - .camera-video-container { - height: 320rpx; - margin-bottom: 16rpx; - } - - .action-btn { - height: 64rpx; - font-size: 24rpx; - } - - .action-icon { - width: 28rpx; - height: 28rpx; - } -} -/* 纭繚鍦ㄤ笉鍚岃澶囦笂鐨勪竴鑷存�� - 棰濆鐨勫吋瀹规�у鐞� */ -.camera-item { - /* 闃叉鍦ㄤ笉鍚岃澶囦笂鐨勫竷灞�宸紓 */ - transform: translateZ(0); - backface-visibility: hidden; - perspective: 1000px; -} -.camera-video-container { - /* 闃叉鍦ㄤ笉鍚岃澶囦笂鐨勬樉绀哄樊寮� */ - transform: translateZ(0); - backface-visibility: hidden; -} - -/* 淇鍙兘鐨勬孩鍑洪棶棰� */ -.camera-list { - max-width: 100%; - overflow: hidden; - /* 纭繚鍦ㄤ笉鍚岃澶囦笂鐨勪竴鑷存�� */ - transform: translateZ(0); -} - -.camera-item { - overflow: hidden; - /* 纭繚鍦ㄤ笉鍚岃澶囦笂鐨勪竴鑷存�� */ - transform: translateZ(0); -} - -/* 閽堝鐪熸満鐨勭壒娈婁紭鍖� */ -@media screen and (max-device-width: 750px) { - .camera-item { - /* 鐪熸満涓婂彲鑳介渶瑕佺◢寰皟鏁撮棿璺� */ - margin-bottom: 16rpx; - } - - .camera-video-container { - /* 鐪熸満涓婂彲鑳介渶瑕佺◢寰皟鏁撮珮搴� */ - height: 380rpx; - } - - .action-btn { - /* 鐪熸満涓婂彲鑳介渶瑕佺◢寰皟鏁撮珮搴� */ - height: 68rpx; - } -} /* 鍦熷¥澧掓儏绔欎笓鐢ㄦ牱寮� */ .weather-data-item.soil-item { @@ -1400,8 +787,10 @@ display: flex; flex-direction: column; gap: 8rpx; - min-width: 0; /* 闃叉鍐呭婧㈠嚭 */ - overflow: hidden; /* 闅愯棌婧㈠嚭鍐呭 */ + min-width: 0; + /* 闃叉鍐呭婧㈠嚭 */ + overflow: hidden; + /* 闅愯棌婧㈠嚭鍐呭 */ } .weather-data-item.soil-item .data-label { @@ -1409,9 +798,12 @@ color: #333; font-weight: 500; line-height: 1.4; - white-space: nowrap; /* 闃叉鏍囩鎹㈣ */ - overflow: hidden; /* 闅愯棌婧㈠嚭鍐呭 */ - text-overflow: ellipsis; /* 鏄剧ず鐪佺暐鍙� */ + white-space: nowrap; + /* 闃叉鏍囩鎹㈣ */ + overflow: hidden; + /* 闅愯棌婧㈠嚭鍐呭 */ + text-overflow: ellipsis; + /* 鏄剧ず鐪佺暐鍙� */ } .weather-data-item.soil-item .data-value { @@ -1419,9 +811,12 @@ color: #1890ff; font-weight: 700; line-height: 1.2; - white-space: nowrap; /* 闃叉鏁板�兼崲琛� */ - overflow: hidden; /* 闅愯棌婧㈠嚭鍐呭 */ - text-overflow: ellipsis; /* 鏄剧ず鐪佺暐鍙� */ + white-space: nowrap; + /* 闃叉鏁板�兼崲琛� */ + overflow: hidden; + /* 闅愯棌婧㈠嚭鍐呭 */ + text-overflow: ellipsis; + /* 鏄剧ず鐪佺暐鍙� */ } /* 鍦熷¥澧掓儏绔欏浘鏍囦紭鍖� */ @@ -1451,30 +846,30 @@ grid-template-columns: 1fr 1fr; gap: 12rpx; } - + .weather-data-item.soil-item { padding: 16rpx; margin-bottom: 8rpx; } - + .weather-data-item.soil-item .data-label { font-size: 22rpx; } - + .weather-data-item.soil-item .data-value { font-size: 28rpx; } - + .weather-data-item.soil-item .data-icon { width: 50rpx; height: 50rpx; } - + .weather-data-item.soil-item .data-icon image { width: 32rpx; height: 32rpx; } -} +} /* 瓒呭皬灞忓箷鍝嶅簲寮忎紭鍖� */ @media (max-width: 320px) { @@ -1482,25 +877,25 @@ grid-template-columns: 1fr 1fr; gap: 8rpx; } - + .weather-data-item.soil-item { padding: 12rpx; margin-bottom: 6rpx; } - + .weather-data-item.soil-item .data-label { font-size: 20rpx; } - + .weather-data-item.soil-item .data-value { font-size: 24rpx; } - + .weather-data-item.soil-item .data-icon { width: 46rpx; height: 46rpx; } - + .weather-data-item.soil-item .data-icon image { width: 30rpx; height: 30rpx; @@ -1707,138 +1102,52 @@ padding: 12rpx 16rpx; margin-bottom: 16rpx; } - + .section-title { font-size: 24rpx; margin-bottom: 12rpx; } - + .switch-container { gap: 40rpx; } - + .switch-item { gap: 12rpx; } - + .switch-label { font-size: 22rpx; } - + .custom-switch { transform: scale(1.0); } - + .monitoring-data .data-grid { grid-template-columns: 1fr; gap: 16rpx; } - + .monitoring-data .data-item { padding: 20rpx; } - + .monitoring-data .data-item .data-label { font-size: 24rpx; } - + .monitoring-data .data-item .data-value { font-size: 32rpx; } - + .monitoring-data .data-item .data-icon { width: 50rpx; height: 50rpx; } - + .monitoring-data .data-item .data-icon image { width: 32rpx; height: 32rpx; } -} - -/* ezplayer缁勪欢鏍峰紡 - 闃叉鍙樺舰鍜岃秴鍑哄睆骞� */ -.video-wrapper ezplayer { - /* 鍩虹灏哄绾︽潫 */ - width: 100% !important; - height: 100% !important; - max-width: 100% !important; - max-height: 100% !important; - min-width: 0 !important; - min-height: 0 !important; - - /* 浣嶇疆绾︽潫 */ - position: relative !important; - left: 0 !important; - right: 0 !important; - top: 0 !important; - bottom: 0 !important; - - /* 婧㈠嚭鎺у埗 */ - overflow: hidden !important; - clip-path: inset(0 0 0 0) !important; - - /* 鍙樻崲绾︽潫 */ - transform: none !important; - transform-origin: center center !important; - - /* 甯冨眬绾︽潫 */ - contain: layout style paint !important; - flex-basis: auto !important; - flex-grow: 0 !important; - flex-shrink: 0 !important; - - /* 鐩掓ā鍨嬬害鏉� */ - box-sizing: border-box !important; - margin: 0 !important; - padding: 0 !important; - - /* 娓叉煋浼樺寲 */ - backface-visibility: hidden !important; - perspective: 1000px !important; - will-change: auto !important; - - /* 鐪熸満鐗规畩澶勭悊 */ - -webkit-transform: none !important; - -webkit-transform-origin: center center !important; - -webkit-backface-visibility: hidden !important; - -webkit-perspective: 1000px !important; -} - -/* 鐪熸満涓婄殑鐗规畩绾︽潫 */ -@media screen and (max-device-width: 750px) { - .video-wrapper ezplayer { - /* 鐪熸満涓婃洿涓ユ牸鐨勭害鏉� */ - max-width: 100vw !important; - max-height: 100vh !important; - left: 0 !important; - right: 0 !important; - top: 0 !important; - bottom: 0 !important; - - /* 闃叉鐪熸満涓婄殑缂╂斁闂 */ - -webkit-transform: scale(1) !important; - transform: scale(1) !important; - - /* 鐪熸満涓婄殑婧㈠嚭鎺у埗 */ - overflow: hidden !important; - clip: rect(0, auto, auto, 0) !important; - } -} - -/* 鏆傚仠鐘舵�佺殑鐗规畩澶勭悊 */ -.video-wrapper ezplayer[data-paused="true"] { - /* 鏆傚仠鏃朵繚鎸佸昂瀵� */ - width: 100% !important; - height: 100% !important; - max-width: 100% !important; - max-height: 100% !important; - - /* 鏆傚仠鏃堕槻姝㈠彉褰� */ - transform: none !important; - -webkit-transform: none !important; - - /* 鏆傚仠鏃剁殑婧㈠嚭鎺у埗 */ - overflow: hidden !important; - clip-path: inset(0 0 0 0) !important; -} \ No newline at end of file +} \ No newline at end of file -- Gitblit v1.8.0