feat: 🎸 优化了播放器
This commit is contained in:
@@ -20,21 +20,20 @@
|
|||||||
|
|
||||||
.courses-video-player-header {
|
.courses-video-player-header {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 18px;
|
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
padding-bottom: 20px;
|
padding-bottom: 20px;
|
||||||
border-bottom: 1px solid #e5e6eb;
|
border-bottom: 1px solid #e5e6eb;
|
||||||
margin-bottom: 20px;
|
|
||||||
|
|
||||||
> span {
|
> span {
|
||||||
color: #2c7aff;
|
color: #2c7aff;
|
||||||
font-size: 10px;
|
font-size: 10px;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
/* 添加以下样式来防止点击时背景变色 */
|
||||||
|
-webkit-tap-highlight-color: transparent;
|
||||||
}
|
}
|
||||||
|
|
||||||
.courses-video-player-header-title {
|
.courses-video-player-header-title {
|
||||||
cursor: default;
|
cursor: default;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
|
|||||||
@@ -3,6 +3,10 @@ import Locked from "@/components/Locked";
|
|||||||
import "./index.css";
|
import "./index.css";
|
||||||
|
|
||||||
export default ({ className = "", isLock = false }) => {
|
export default ({ className = "", isLock = false }) => {
|
||||||
|
const handleClickBtn = (item) => {
|
||||||
|
console.log(item);
|
||||||
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className={`${className} courses-video-player-wrapper`}>
|
<div className={`${className} courses-video-player-wrapper`}>
|
||||||
{/* 直播板块 */}
|
{/* 直播板块 */}
|
||||||
@@ -16,14 +20,14 @@ export default ({ className = "", isLock = false }) => {
|
|||||||
) : (
|
) : (
|
||||||
<>
|
<>
|
||||||
<div className="courses-video-player-header">
|
<div className="courses-video-player-header">
|
||||||
<span>< 上一集</span>
|
<span onClick={() => handleClickBtn(1)}>< 上一集</span>
|
||||||
<span className="courses-video-player-header-title">
|
<span className="courses-video-player-header-title">
|
||||||
钢铁是怎样炼成的
|
钢铁是怎样炼成的
|
||||||
</span>
|
</span>
|
||||||
<span>下一集 ></span>
|
<span onClick={() => handleClickBtn(2)}>下一集 ></span>
|
||||||
</div>
|
</div>
|
||||||
<div className="courses-video-player-video">
|
<div className="courses-video-player-video">
|
||||||
<video src="" controls></video>
|
<video src="/live.mp4" autoPlay controls></video>
|
||||||
</div>
|
</div>
|
||||||
</>
|
</>
|
||||||
)}
|
)}
|
||||||
|
|||||||
@@ -1,6 +1,8 @@
|
|||||||
/* 就业管家知识树页面样式 */
|
/* 就业管家知识树页面样式 */
|
||||||
.career-tree-page {
|
.career-tree-page {
|
||||||
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
|
width: 1160px;
|
||||||
|
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen,
|
||||||
|
Ubuntu, Cantarell, sans-serif;
|
||||||
position: relative;
|
position: relative;
|
||||||
min-height: 100vh;
|
min-height: 100vh;
|
||||||
overflow-x: hidden;
|
overflow-x: hidden;
|
||||||
@@ -56,8 +58,6 @@
|
|||||||
position: relative;
|
position: relative;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
.top-content-wrapper {
|
.top-content-wrapper {
|
||||||
background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
|
background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
|
||||||
background-size: cover;
|
background-size: cover;
|
||||||
@@ -142,7 +142,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.menu-item.selected::after {
|
.menu-item.selected::after {
|
||||||
content: '';
|
content: "";
|
||||||
position: absolute;
|
position: absolute;
|
||||||
bottom: -2px;
|
bottom: -2px;
|
||||||
left: 50%;
|
left: 50%;
|
||||||
@@ -451,8 +451,6 @@
|
|||||||
margin-bottom: 0;
|
margin-bottom: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* SVG 连接线样式 */
|
/* SVG 连接线样式 */
|
||||||
.connection-canvas {
|
.connection-canvas {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
@@ -469,8 +467,6 @@
|
|||||||
fill: none;
|
fill: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* 所有屏幕尺寸确保布局稳定性 */
|
/* 所有屏幕尺寸确保布局稳定性 */
|
||||||
@media (min-width: 1201px) {
|
@media (min-width: 1201px) {
|
||||||
.section-content {
|
.section-content {
|
||||||
@@ -481,7 +477,7 @@
|
|||||||
flex-wrap: nowrap !important;
|
flex-wrap: nowrap !important;
|
||||||
justify-content: flex-start !important;
|
justify-content: flex-start !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.center-item {
|
.center-item {
|
||||||
/* 确保item的布局稳定 */
|
/* 确保item的布局稳定 */
|
||||||
display: block !important;
|
display: block !important;
|
||||||
@@ -501,7 +497,7 @@
|
|||||||
align-items: stretch !important;
|
align-items: stretch !important;
|
||||||
flex-wrap: nowrap !important;
|
flex-wrap: nowrap !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.center-item {
|
.center-item {
|
||||||
/* 在超大屏幕上确保item的布局稳定 */
|
/* 在超大屏幕上确保item的布局稳定 */
|
||||||
display: block !important;
|
display: block !important;
|
||||||
@@ -515,32 +511,32 @@
|
|||||||
.canvas-container {
|
.canvas-container {
|
||||||
width: 1200px;
|
width: 1200px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.left-panel {
|
.left-panel {
|
||||||
width: 220px;
|
width: 220px;
|
||||||
min-width: 220px;
|
min-width: 220px;
|
||||||
left: 20px;
|
left: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.right-panel {
|
.right-panel {
|
||||||
width: 220px;
|
width: 220px;
|
||||||
min-width: 220px;
|
min-width: 220px;
|
||||||
right: 20px;
|
right: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.top-menu-container {
|
.top-menu-container {
|
||||||
padding: 12px 20px;
|
padding: 12px 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.menu-panel {
|
.menu-panel {
|
||||||
gap: 6px;
|
gap: 6px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.menu-item {
|
.menu-item {
|
||||||
padding: 8px 16px;
|
padding: 8px 16px;
|
||||||
font-size: 13px;
|
font-size: 13px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.center-panel {
|
.center-panel {
|
||||||
width: 320px;
|
width: 320px;
|
||||||
padding: 24px 16px;
|
padding: 24px 16px;
|
||||||
@@ -551,28 +547,28 @@
|
|||||||
.canvas-container {
|
.canvas-container {
|
||||||
width: 1000px;
|
width: 1000px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.tree-layout {
|
.tree-layout {
|
||||||
gap: 10px;
|
gap: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.center-panel {
|
.center-panel {
|
||||||
width: 300px;
|
width: 300px;
|
||||||
padding: 24px 16px;
|
padding: 24px 16px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.left-panel {
|
.left-panel {
|
||||||
width: 200px;
|
width: 200px;
|
||||||
min-width: 200px;
|
min-width: 200px;
|
||||||
left: 10px;
|
left: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.right-panel {
|
.right-panel {
|
||||||
width: 200px;
|
width: 200px;
|
||||||
min-width: 200px;
|
min-width: 200px;
|
||||||
right: 10px;
|
right: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.menu-item {
|
.menu-item {
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
padding: 6px 12px;
|
padding: 6px 12px;
|
||||||
@@ -583,32 +579,32 @@
|
|||||||
.top-menu-container {
|
.top-menu-container {
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.menu-panel {
|
.menu-panel {
|
||||||
overflow-x: auto;
|
overflow-x: auto;
|
||||||
gap: 4px;
|
gap: 4px;
|
||||||
padding: 6px;
|
padding: 6px;
|
||||||
scrollbar-width: thin;
|
scrollbar-width: thin;
|
||||||
}
|
}
|
||||||
|
|
||||||
.menu-item {
|
.menu-item {
|
||||||
font-size: 11px;
|
font-size: 11px;
|
||||||
padding: 6px 10px;
|
padding: 6px 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.tree-layout {
|
.tree-layout {
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 30px;
|
gap: 30px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.left-column,
|
.left-column,
|
||||||
.center-column,
|
.center-column,
|
||||||
.right-column {
|
.right-column {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
max-width: 500px;
|
max-width: 500px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.left-panel,
|
.left-panel,
|
||||||
.right-panel {
|
.right-panel {
|
||||||
position: relative;
|
position: relative;
|
||||||
@@ -617,11 +613,11 @@
|
|||||||
left: auto;
|
left: auto;
|
||||||
right: auto;
|
right: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
.connection-canvas {
|
.connection-canvas {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* 确保小屏幕下也保持垂直布局 */
|
/* 确保小屏幕下也保持垂直布局 */
|
||||||
.section-content {
|
.section-content {
|
||||||
display: flex !important;
|
display: flex !important;
|
||||||
@@ -629,7 +625,7 @@
|
|||||||
align-items: stretch !important;
|
align-items: stretch !important;
|
||||||
flex-wrap: nowrap !important;
|
flex-wrap: nowrap !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.center-item {
|
.center-item {
|
||||||
display: block !important;
|
display: block !important;
|
||||||
width: 100% !important;
|
width: 100% !important;
|
||||||
@@ -641,28 +637,28 @@
|
|||||||
.top-menu-container {
|
.top-menu-container {
|
||||||
padding: 8px;
|
padding: 8px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.menu-panel {
|
.menu-panel {
|
||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
gap: 4px;
|
gap: 4px;
|
||||||
padding: 4px;
|
padding: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.menu-item {
|
.menu-item {
|
||||||
font-size: 10px;
|
font-size: 10px;
|
||||||
padding: 5px 8px;
|
padding: 5px 8px;
|
||||||
flex: 0 0 calc(33.333% - 4px);
|
flex: 0 0 calc(33.333% - 4px);
|
||||||
}
|
}
|
||||||
|
|
||||||
.top-content {
|
.top-content {
|
||||||
padding: 20px 10px;
|
padding: 20px 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.center-panel {
|
.center-panel {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
padding: 24px 16px;
|
padding: 24px 16px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* 确保移动端也保持垂直布局 */
|
/* 确保移动端也保持垂直布局 */
|
||||||
.section-content {
|
.section-content {
|
||||||
display: flex !important;
|
display: flex !important;
|
||||||
@@ -670,10 +666,10 @@
|
|||||||
align-items: stretch !important;
|
align-items: stretch !important;
|
||||||
flex-wrap: nowrap !important;
|
flex-wrap: nowrap !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.center-item {
|
.center-item {
|
||||||
display: block !important;
|
display: block !important;
|
||||||
width: 100% !important;
|
width: 100% !important;
|
||||||
margin-bottom: 0 !important;
|
margin-bottom: 0 !important;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user