添加chapter和lesson
This commit is contained in:
@@ -1,4 +1,8 @@
|
||||
|
||||
/* Teacherboard 样式 */
|
||||
/* 按钮样式 */
|
||||
|
||||
|
||||
.teacherboard {
|
||||
padding: 20px;
|
||||
font-family: Arial, sans-serif;
|
||||
@@ -62,6 +66,206 @@
|
||||
z-index: 9999;
|
||||
border-radius: 15px; /* 添加圆角 */
|
||||
}
|
||||
/* 基本的课程卡片样式 */
|
||||
.course-card {
|
||||
width: 150px;
|
||||
height: 200px;
|
||||
margin: 10px;
|
||||
border: 1px solid #ddd;
|
||||
border-radius: 8px;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.course-image {
|
||||
width: 100%;
|
||||
height: 100px;
|
||||
object-fit: cover;
|
||||
}
|
||||
|
||||
.course-info {
|
||||
padding: 10px;
|
||||
}
|
||||
|
||||
.course-name {
|
||||
font-size: 16px;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.course-description {
|
||||
font-size: 14px;
|
||||
color: #777;
|
||||
}
|
||||
|
||||
/* 空的添加课程按钮卡片 */
|
||||
.add-course-card {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
background-color: #f0f0f0;
|
||||
border: 1px dashed #bbb;
|
||||
}
|
||||
/* 模态框背景 */
|
||||
.modal {
|
||||
display: none; /* 初始时隐藏 */
|
||||
position: fixed;
|
||||
z-index: 1; /* 保证浮窗在顶部 */
|
||||
left: 0;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background-color: rgba(0, 0, 0, 0.5); /* 半透明的黑色背景 */
|
||||
}
|
||||
|
||||
/* 浮窗内容 */
|
||||
.modal-content {
|
||||
background-color: #fff;
|
||||
margin: 15% auto;
|
||||
padding: 20px;
|
||||
border-radius: 10px;
|
||||
width: 40%;
|
||||
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
|
||||
}
|
||||
|
||||
/* 按钮样式 */
|
||||
.modal-buttons {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
}
|
||||
/* 基本样式,保证输入框和下拉框占满整行 */
|
||||
input[type="text"], select {
|
||||
width: 100%; /* 占满一行 */
|
||||
padding: 12px; /* 增加内边距 */
|
||||
font-size: 16px; /* 调整字体大小 */
|
||||
margin: 10px 0; /* 上下留间距 */
|
||||
border: 2px solid #ccc; /* 边框 */
|
||||
border-radius: 8px; /* 圆角边框 */
|
||||
background-color: #f9f9f9; /* 背景色 */
|
||||
transition: border 0.3s ease, box-shadow 0.3s ease; /* 添加过渡效果 */
|
||||
}
|
||||
|
||||
/* 鼠标悬停时输入框的效果 */
|
||||
input[type="text"]:focus, select:focus {
|
||||
border-color: #4CAF50; /* 聚焦时的边框颜色 */
|
||||
box-shadow: 0 0 10px rgba(76, 175, 80, 0.5); /* 聚焦时的阴影效果 */
|
||||
outline: none; /* 去掉默认的聚焦框 */
|
||||
}
|
||||
|
||||
/* 给表单标签添加样式 */
|
||||
label {
|
||||
font-size: 18px; /* 增加字体大小 */
|
||||
font-weight: bold; /* 加粗字体 */
|
||||
margin-bottom: 8px; /* 下方间距 */
|
||||
display: block; /* 使标签占一行 */
|
||||
color: #333; /* 标签字体颜色 */
|
||||
}
|
||||
|
||||
/* 按钮部分 */
|
||||
.modal-buttons {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
margin-top: 20px; /* 上方间距 */
|
||||
}
|
||||
|
||||
|
||||
|
||||
/* 添加课程按钮样式 */
|
||||
.add-course-button {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
width: 50px;
|
||||
height: 50px;
|
||||
border-radius: 50%;
|
||||
background-color: #4CAF50;
|
||||
color: white;
|
||||
font-size: 30px;
|
||||
font-weight: bold;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.add-course-button:hover {
|
||||
background-color: #45a049;
|
||||
}
|
||||
.cover-image-container {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.cover-image-placeholder {
|
||||
width: 150px;
|
||||
height: 150px;
|
||||
border: 1px solid #ddd;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.modal-buttons button {
|
||||
width: 48%;
|
||||
padding: 12px 0;
|
||||
font-size: 16px;
|
||||
background-color: #4CAF50;
|
||||
color: white;
|
||||
border: none;
|
||||
border-radius: 8px;
|
||||
cursor: pointer;
|
||||
transition: background-color 0.3s ease;
|
||||
}
|
||||
|
||||
.modal-buttons button:hover {
|
||||
background-color: #45a049;
|
||||
}
|
||||
|
||||
.modal-buttons button[type="button"] {
|
||||
background-color: #f44336;
|
||||
}
|
||||
|
||||
.modal-buttons button[type="button"]:hover {
|
||||
background-color: #e53935;
|
||||
}
|
||||
.plus-sign {
|
||||
font-size: 30px;
|
||||
color: #888;
|
||||
}
|
||||
|
||||
#cover-preview {
|
||||
width: 150px;
|
||||
height: 150px;
|
||||
margin-top: 10px;
|
||||
}
|
||||
/* 课程描述文本框样式 */
|
||||
#course-description {
|
||||
width: 100%; /* 让 textarea 占据整个父容器的宽度 */
|
||||
height: 150px; /* 设置适当的高度 */
|
||||
padding: 10px; /* 内边距,让文本与边框之间有一定的间距 */
|
||||
font-size: 16px; /* 设置字体大小 */
|
||||
font-family: Arial, sans-serif; /* 字体样式 */
|
||||
border: 1px solid #ddd; /* 边框颜色 */
|
||||
border-radius: 8px; /* 边框圆角,使其更加圆润 */
|
||||
resize: vertical; /* 允许用户垂直调整大小 */
|
||||
box-sizing: border-box; /* 包含内边距和边框在内的总宽高 */
|
||||
transition: border-color 0.3s, box-shadow 0.3s; /* 鼠标悬浮和聚焦时的动画效果 */
|
||||
}
|
||||
|
||||
/* 课程描述文本框的聚焦样式 */
|
||||
#course-description:focus {
|
||||
border-color: #4CAF50; /* 聚焦时改变边框颜色 */
|
||||
box-shadow: 0 0 8px rgba(76, 175, 80, 0.4); /* 聚焦时加上绿色的阴影 */
|
||||
outline: none; /* 去掉聚焦时的默认外轮廓 */
|
||||
}
|
||||
|
||||
/* 课程描述标签样式 */
|
||||
label[for="course-description"] {
|
||||
font-size: 18px; /* 标签字体大小 */
|
||||
font-weight: bold; /* 加粗字体 */
|
||||
margin-bottom: 8px; /* 标签与文本框之间的间距 */
|
||||
display: block; /* 将标签设置为块级元素,保证换行 */
|
||||
color: #333; /* 标签颜色 */
|
||||
}
|
||||
|
||||
.course-details.open {
|
||||
right: 0; /* 打开时显示 */
|
||||
@@ -71,7 +275,8 @@
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 20px;
|
||||
font-size: 18px;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.details-header button {
|
||||
@@ -81,6 +286,39 @@
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.close-btn {
|
||||
background: transparent;
|
||||
border: none;
|
||||
font-size: 20px;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.add-chapter-btn {
|
||||
margin-top: 20px;
|
||||
padding: 10px 15px;
|
||||
background-color: #4CAF50;
|
||||
color: white;
|
||||
border: none;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.add-chapter-btn:hover {
|
||||
background-color: #45a049;
|
||||
}
|
||||
|
||||
.course-card {
|
||||
border: 1px solid #ddd;
|
||||
padding: 15px;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.course-card:hover {
|
||||
background-color: #f1f1f1;
|
||||
}
|
||||
|
||||
#courseDetails.open {
|
||||
right: 0; /* 打开侧边栏 */
|
||||
}
|
||||
.details-content {
|
||||
padding-right: 20px;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user