js+css实现炫酷项目任务管理表格代码
代码语言:html
所属分类:表格
代码描述:js+css实现炫酷项目任务管理表格代码
代码标签: js css 炫酷 项目 任务 管理 表格 代码
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>炫酷表格示例</title>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
<style>
:root {
--primary-color: #4361ee;
--secondary-color: #3f37c9;
--accent-color: #4cc9f0;
--dark-color: #2b2d42;
--light-color: #f8f9fa;
--success-color: #4ad66d;
--warning-color: #f8961e;
--danger-color: #ef233c;
}
* {
margin: 0;
padding: 0;
box-sizing: border-box;
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}
body {
background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
min-height: 100vh;
padding: 40px 20px;
color: var(--dark-color);
}
.container {
max-width: 1200px;
margin: 0 auto;
}
h1 {
text-align: center;
margin-bottom: 30px;
color: var(--secondary-color);
font-size: 2.5rem;
text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
position: relative;
display: inline-block;
left: 50%;
transform: translateX(-50%);
}
h1::after {
content: '';
position: absolute;
bottom: -10px;
left: 0;
width: 100%;
height: 4px;
background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
border-radius: 2px;
}
.table-container {
background-color: white;
border-radius: 12px;
box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
overflow: hidden;
margin-bottom: 30px;
transition: all 0.3s ease;
}
.table-container:hover {
transform: translateY(-5px);
box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
}
.table-header {
background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
color: white;
padding: 20px;
display: flex;
justify-content: space-between;
align-items: center;
}
.table-title {
font-size: 1.5rem;
font-weight: 600;
}
.search-box {
position: relative;
width: 250px;
}
.search-box input {
width: 100%;
padding: 10px 15px 10px 40px;
border: none;
border-radius: 30px;
background-color: rgba(255, 255, 255, 0.2);
color: white;
font-size: 0.9rem;
transition: all 0.3s ease;
}
.search-box input::placeholder {
color: rgba(255, 255, 255, 0.7);
}
.search-box input:focus {
outline: none;
background-color: rgba(255, 255, 255, 0.3);
box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.2);
}
.search-box i {
position: absolute;
left: 15px;
top: 50%;
transform: translateY(-50%);
color: white;
}
table {
width: 100%;
border-collapse: collapse;
table-layout: fixed;
}
thead {
background-color: var(--light-color);
border-bottom: 2px solid #e9ecef;
}
th {
padding: 15px;
text-align: left;
font-weight: 600;
color: var(--dark-color);
text-transform: uppercase;
font-size: 0.8rem;
letter-spacing: 0.5px;
position: relative;
}
th:not(:last-child)::after {
content: '';
position: absolute;
right: 0;
top: 50%;
transform: translateY(-50%);
height: 60%;
width: 1px;
background-color: #dee2e6;
}
th.sortable {
cursor: pointer;
transition: all 0.2s ease;
}
th.sortable:hover {
color: var(--primary-color);
}
th.sortable::before {
content: '\f0dc';
font-family: 'Font Awesome 6 Free';
font-weight: 900;
margin-right: 5px;
font-size: 0.7rem;
opacity: 0.5;
}
th.asc::before {
content: '\f0de';
opacity: 1;
color: var(--primary-color);
}
th.desc::before {
content: '\f0dd';
opacity: 1;
color: var(--primary-color);
}
tbody tr {
border-bottom: 1px solid #e9ecef;
transition: all 0.........完整代码请登录后点击上方下载按钮下载查看
网友评论0