重新构建路由和配置样式文件

This commit is contained in:
2025-03-26 10:04:27 +08:00
parent a42a9990bf
commit 97ccf5a077
141 changed files with 88034 additions and 179 deletions
+97
View File
@@ -0,0 +1,97 @@
/**
* 基础样式文件
* 包含全局变量与Tailwind基础配置
*/
@tailwind base;
@tailwind components;
@tailwind utilities;
@layer base {
:root {
/* 主题颜色变量 */
--color-primary: #00684a;
--color-primary-hover: #005a3f;
--color-primary-light: rgba(0, 104, 74, 0.1);
/* 成功、警告、错误颜色 */
--color-success: #52c41a;
--color-warning: #faad14;
--color-error: #f5222d;
/* 中性色 */
--color-gray-50: #f8f9fa;
--color-gray-100: #f1f3f5;
--color-gray-200: #e9ecef;
--color-gray-300: #dee2e6;
--color-gray-400: #ced4da;
--color-gray-500: #adb5bd;
--color-gray-600: #868e96;
--color-gray-700: #495057;
--color-gray-800: #343a40;
--color-gray-900: #212529;
/* 字体设置 */
--font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
/* 间距倍数基准 */
--spacing-base: 0.25rem;
/* 圆角 */
--radius-sm: 0.125rem;
--radius-md: 0.25rem;
--radius-lg: 0.5rem;
--radius-xl: 1rem;
/* 阴影 */
--shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
--shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
--shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
/* 过渡 */
--transition-normal: 0.2s ease;
}
/* 基本元素样式 */
html, body {
@apply font-sans text-gray-800 antialiased;
scroll-behavior: smooth;
}
/* 文字选择颜色 */
::selection {
@apply bg-[rgba(0,104,74,0.2)] text-[#00684a];
}
/* 滚动条美化 */
::-webkit-scrollbar {
@apply w-2 h-2;
}
::-webkit-scrollbar-track {
@apply bg-gray-100;
}
::-webkit-scrollbar-thumb {
@apply bg-gray-300 rounded-full hover:bg-gray-400;
}
/* 链接样式 */
a {
@apply text-[#00684a] hover:text-[#005a3f] transition-colors duration-200;
}
/* 主要文本颜色 */
.text-primary {
@apply text-[#00684a];
}
.bg-primary {
@apply bg-[#00684a];
}
/* 平滑过渡 */
.transition-all-ease {
@apply transition-all duration-200 ease-in-out;
}
}
+100
View File
@@ -0,0 +1,100 @@
/**
* 标签组件样式
*/
@layer components {
/* 基础标签 */
.badge {
@apply inline-flex items-center px-2.5 py-0.5 rounded-full text-xs font-medium;
}
/* 标签尺寸 */
.badge-sm {
@apply px-2 py-0.5 text-xs;
}
.badge-md {
@apply px-2.5 py-1 text-sm;
}
.badge-lg {
@apply px-3 py-1 text-sm;
}
/* 标签颜色 */
.badge-primary {
@apply bg-[rgba(0,104,74,0.1)] text-[#00684a];
}
.badge-secondary {
@apply bg-gray-100 text-gray-800;
}
.badge-success {
@apply bg-[rgba(82,196,26,0.1)] text-[#52c41a];
}
.badge-warning {
@apply bg-[rgba(250,173,20,0.1)] text-[#faad14];
}
.badge-danger {
@apply bg-[rgba(245,34,45,0.1)] text-[#f5222d];
}
.badge-info {
@apply bg-[rgba(24,144,255,0.1)] text-[#1890ff];
}
/* 标签边框样式 */
.badge-outlined {
@apply bg-transparent border;
}
.badge-outlined.badge-primary {
@apply border-[#00684a] text-[#00684a];
}
.badge-outlined.badge-secondary {
@apply border-gray-300 text-gray-700;
}
.badge-outlined.badge-success {
@apply border-[#52c41a] text-[#52c41a];
}
.badge-outlined.badge-warning {
@apply border-[#faad14] text-[#faad14];
}
.badge-outlined.badge-danger {
@apply border-[#f5222d] text-[#f5222d];
}
.badge-outlined.badge-info {
@apply border-[#1890ff] text-[#1890ff];
}
/* 标签带图标 */
.badge-with-icon {
@apply pl-1.5;
}
.badge-with-icon i,
.badge-with-icon svg {
@apply mr-1;
}
/* 计数标签 */
.badge-count {
@apply absolute -top-1 -right-1 flex items-center justify-center h-4 w-4 rounded-full text-[10px] font-bold text-white;
}
.badge-count.badge-primary {
@apply bg-[#00684a] text-white;
}
.badge-count.badge-danger {
@apply bg-[#f5222d] text-white;
}
}
+77
View File
@@ -0,0 +1,77 @@
/**
* 按钮组件样式
*/
/* 基础按钮 */
.btn {
@apply inline-flex items-center justify-center px-4 py-2
border border-transparent rounded-md font-medium text-sm
focus:outline-none focus:ring-2 focus:ring-offset-2 transition-all duration-200
disabled:opacity-50 disabled:cursor-not-allowed;
}
/* 按钮尺寸 */
.btn-xs {
@apply px-2.5 py-1 text-xs;
}
.btn-sm {
@apply px-3 py-1.5 text-sm;
}
.btn-lg {
@apply px-5 py-2.5 text-base;
}
/* 按钮类型 */
.btn-primary {
@apply bg-[#00684a] text-white hover:bg-[#005a3f] focus:ring-[#00684a];
}
.btn-secondary {
@apply bg-gray-200 text-gray-800 hover:bg-gray-300 focus:ring-gray-300;
}
.btn-outline {
@apply bg-transparent border border-[#00684a] text-[#00684a]
hover:bg-[rgba(0,104,74,0.05)] focus:ring-[#00684a];
}
.btn-danger {
@apply bg-[#f5222d] text-white hover:bg-[#cf1f29] focus:ring-[#f5222d];
}
.btn-text {
@apply bg-transparent text-[#00684a] shadow-none border-none
hover:bg-[rgba(0,104,74,0.05)] focus:ring-0;
}
/* 图标按钮 */
.btn-icon {
@apply p-2 rounded-full;
}
.btn-icon.btn-sm {
@apply p-1.5;
}
.btn-icon i, .btn-icon svg {
@apply text-current w-5 h-5;
}
/* 按钮组 */
.btn-group {
@apply inline-flex;
}
.btn-group .btn {
@apply rounded-none;
}
.btn-group .btn:first-child {
@apply rounded-l-md;
}
.btn-group .btn:last-child {
@apply rounded-r-md;
}
+62
View File
@@ -0,0 +1,62 @@
/**
* 卡片组件样式
*/
/* 基础卡片 */
.card {
@apply bg-white rounded-lg shadow overflow-hidden transition-all duration-200;
}
.card:hover {
@apply shadow-md;
}
/* 卡片头部 */
.card-header {
@apply px-5 py-4 border-b border-gray-100 flex items-center justify-between;
}
.card-title {
@apply text-base font-medium text-gray-900;
}
.card-title i {
@apply text-xl mr-2 text-primary;
}
/* 卡片内容 */
.card-body {
@apply p-5;
}
/* 卡片底部 */
.card-footer {
@apply px-5 py-4 bg-gray-50 border-t border-gray-100;
}
/* 卡片变体 */
.card-compact {
@apply shadow-sm;
}
.card-compact .card-header {
@apply py-3;
}
.card-compact .card-body {
@apply p-4;
}
.card-compact .card-footer {
@apply py-3;
}
/* 卡片布局 */
.card-grid {
@apply grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4;
}
/* 内容卡片 */
.content-card {
@apply border border-gray-100 rounded-lg shadow-sm hover:shadow transition-shadow duration-200;
}
+130
View File
@@ -0,0 +1,130 @@
/**
* 表单组件样式
*/
@layer components {
/* 表单组 */
.form-group {
@apply mb-4;
}
.form-group:last-child {
@apply mb-0;
}
/* 表单标签 */
.form-label {
@apply block text-sm font-medium text-gray-700 mb-1;
}
.form-label.required::after {
content: "*";
@apply text-[#f5222d] ml-1;
}
/* 表单控件 */
.form-input,
.form-select,
.form-textarea {
@apply block w-full rounded-md border-gray-300 shadow-sm py-2 px-3 text-sm
focus:border-[#00684a] focus:ring focus:ring-[#00684a] focus:ring-opacity-20
disabled:bg-gray-100 disabled:text-gray-500 disabled:cursor-not-allowed;
}
.form-select {
@apply pr-10;
}
.form-textarea {
@apply min-h-[100px];
}
/* 表单控件尺寸 */
.form-input-sm,
.form-select-sm,
.form-textarea-sm {
@apply py-1.5 px-2.5 text-xs;
}
.form-input-lg,
.form-select-lg,
.form-textarea-lg {
@apply py-2.5 px-3.5 text-base;
}
/* 表单验证状态 */
.form-input.error,
.form-select.error,
.form-textarea.error {
@apply border-[#f5222d] focus:border-[#f5222d] focus:ring-[#f5222d];
}
.form-input.success,
.form-select.success,
.form-textarea.success {
@apply border-[#52c41a] focus:border-[#52c41a] focus:ring-[#52c41a];
}
/* 表单帮助文本 */
.form-help {
@apply mt-1 text-sm text-gray-500;
}
.form-error {
@apply mt-1 text-sm text-[#f5222d];
}
/* 表单复选框和单选框 */
.form-checkbox-group,
.form-radio-group {
@apply space-y-2;
}
.form-check {
@apply flex items-center;
}
.form-checkbox,
.form-radio {
@apply h-4 w-4 text-[#00684a] border-gray-300 focus:ring-[#00684a] focus:ring-opacity-20 rounded;
}
.form-radio {
@apply rounded-full;
}
.form-check-label {
@apply ml-2 block text-sm text-gray-700;
}
/* 行内表单 */
.form-inline {
@apply flex flex-wrap items-end space-x-2;
}
/* 水平表单 */
.form-horizontal .form-group {
@apply flex items-center;
}
.form-horizontal .form-label {
@apply w-1/3 mb-0;
}
.form-horizontal .form-control-container {
@apply w-2/3;
}
/* 搜索框 */
.search-box {
@apply relative flex;
}
.search-box input {
@apply pr-10;
}
.search-box button {
@apply absolute inset-y-0 right-0 flex items-center px-2;
}
}
+22
View File
@@ -0,0 +1,22 @@
/**
* 组件样式索引文件
* 集中导入所有组件样式
*/
/* 布局相关组件 */
@import "../layout.css";
/* 已合并到layout.css中 */
/* @import "./sidebar.css"; */
/* UI 基础组件 */
@import "./button.css";
@import "./card.css";
@import "./form.css";
@import "./table.css";
@import "./badge.css";
@import "./navigation.css";
/**
* 注意:如果上述导入的文件不存在,将会在构建时报错
* 请确保先创建这些文件,或者先注释掉不存在的文件
*/
+148
View File
@@ -0,0 +1,148 @@
/**
* 导航组件样式
*/
@layer components {
/* 顶部导航栏 */
.navbar {
@apply bg-white border-b border-gray-200 h-16 fixed top-0 right-0 left-0 z-20 flex items-center px-5;
}
.navbar-container {
@apply flex items-center justify-between w-full;
}
.navbar-brand {
@apply flex items-center space-x-2;
}
.navbar-brand-logo {
@apply h-8 w-auto;
}
.navbar-brand-text {
@apply font-medium text-lg text-gray-900;
}
.navbar-menu {
@apply flex items-center space-x-4;
}
.navbar-item {
@apply relative px-3 py-2 text-sm text-gray-600 hover:text-[#00684a] transition-colors;
}
.navbar-item.active {
@apply text-[#00684a] font-medium;
}
.navbar-item.active::after {
content: '';
@apply absolute bottom-0 left-0 w-full h-0.5 bg-[#00684a];
}
/* 标签页导航 */
.tabs {
@apply border-b border-gray-200;
}
.tabs-list {
@apply flex -mb-px space-x-6;
}
.tab-item {
@apply py-3 px-1 border-b-2 border-transparent text-sm font-medium text-gray-500
hover:text-gray-700 hover:border-gray-300 cursor-pointer;
}
.tab-item.active {
@apply border-[#00684a] text-[#00684a];
}
/* 面包屑导航 */
.breadcrumbs {
@apply flex items-center text-sm text-gray-500 mb-4;
}
.breadcrumb-item {
@apply flex items-center;
}
.breadcrumb-item:not(:last-child)::after {
content: "/";
@apply mx-2;
}
.breadcrumb-item:last-child {
@apply text-gray-800 font-medium;
}
/* 步骤导航 */
.steps {
@apply flex justify-between items-center;
}
.step-item {
@apply flex-1 relative;
}
.step-item:not(:last-child)::after {
content: '';
@apply absolute top-1/2 right-0 w-full h-0.5 bg-gray-200 -translate-y-1/2 z-0;
}
.step-item.active:not(:last-child)::after {
@apply bg-[#00684a];
}
.step-item.completed:not(:last-child)::after {
@apply bg-[#00684a];
}
.step-circle {
@apply h-8 w-8 rounded-full bg-white border-2 border-gray-300 flex items-center justify-center
text-xs font-medium text-gray-500 relative z-10;
}
.step-item.active .step-circle {
@apply border-[#00684a] text-[#00684a];
}
.step-item.completed .step-circle {
@apply bg-[#00684a] border-[#00684a] text-white;
}
.step-label {
@apply mt-2 text-xs font-medium text-gray-500 text-center;
}
.step-item.active .step-label {
@apply text-[#00684a];
}
.step-item.completed .step-label {
@apply text-[#00684a];
}
/* 下拉菜单 */
.dropdown {
@apply relative inline-block;
}
.dropdown-toggle {
@apply cursor-pointer;
}
.dropdown-menu {
@apply absolute right-0 z-10 w-48 mt-2 origin-top-right bg-white rounded-md shadow-lg
ring-1 ring-black ring-opacity-5 focus:outline-none py-1;
}
.dropdown-item {
@apply block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100 w-full text-left;
}
.dropdown-divider {
@apply my-1 border-t border-gray-100;
}
}
+87
View File
@@ -0,0 +1,87 @@
/**
* 表格组件样式
*/
@layer components {
/* 基础表格 */
.table-container {
@apply w-full overflow-x-auto;
}
.table {
@apply min-w-full divide-y divide-gray-200;
}
.table thead {
@apply bg-gray-50;
}
.table th {
@apply px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider;
}
.table tbody {
@apply bg-white divide-y divide-gray-200;
}
.table td {
@apply px-6 py-4 whitespace-nowrap text-sm text-gray-500;
}
.table tr:hover {
@apply bg-gray-50;
}
/* 紧凑表格 */
.table-compact th {
@apply px-4 py-2 text-xs;
}
.table-compact td {
@apply px-4 py-2 text-xs;
}
/* 边框表格 */
.table-bordered {
@apply border border-gray-200;
}
.table-bordered th,
.table-bordered td {
@apply border border-gray-200;
}
/* 条纹表格 */
.table-striped tbody tr:nth-child(odd) {
@apply bg-gray-50;
}
/* 可选择行表格 */
.table-selectable tbody tr {
@apply cursor-pointer;
}
.table-selectable tbody tr.selected {
@apply bg-[rgba(0,104,74,0.05)];
}
/* 表格分页 */
.table-pagination {
@apply flex items-center justify-between py-3 px-4 bg-white border-t border-gray-200;
}
.table-pagination-info {
@apply text-sm text-gray-500;
}
.table-pagination-actions {
@apply flex items-center space-x-2;
}
/* 响应式处理 */
@screen md {
.table-responsive {
@apply overflow-x-visible;
}
}
}
+19
View File
@@ -0,0 +1,19 @@
/**
* 主样式入口文件
* 本文件集中导入所有样式
*/
/* Tailwind 基础指令 */
@import "./base.css";
/* 组件样式 */
@import "./components/index.css";
/* 页面特定样式 */
@import "./pages/index.css";
/*
* 注意: 页面特定样式已经移到各自页面的links函数中按需加载
* 不再通过全局样式文件导入
*/
/* @import "./pages/index.css"; */
+201
View File
@@ -0,0 +1,201 @@
/**
* 全局布局样式
* 定义应用的主要布局结构
*/
/**
* 侧边栏基础样式
*/
.sidebar {
@apply w-[280px] h-screen bg-white border-r border-gray-100 flex flex-col
transition-all duration-300 fixed left-0 top-0 z-[100] overflow-y-auto
shadow-[0_0_15px_rgba(0,0,0,0.05)];
}
.sidebar.collapsed {
@apply w-20;
}
/* 侧边栏头部 */
.sidebar-header {
@apply h-16 border-b border-gray-100 flex items-center justify-between px-5;
}
.sidebar-logo {
@apply flex items-center space-x-2;
}
.sidebar-logo-img {
@apply h-8 w-auto;
}
.sidebar-logo-text {
@apply font-medium text-lg text-gray-900 transition-opacity duration-200;
}
.sidebar.collapsed .sidebar-logo-text {
@apply opacity-0 invisible;
}
.sidebar-toggle {
@apply bg-transparent border-none text-xl text-gray-500 cursor-pointer p-1
rounded transition-all duration-200;
}
.sidebar-toggle:hover {
@apply bg-gray-100;
}
/* 用户资料 */
.sidebar-user {
@apply flex items-center px-5 py-3 border-b border-gray-100;
}
.sidebar-user-avatar {
@apply w-10 h-10 rounded-full overflow-hidden flex-shrink-0;
}
.sidebar-user-info {
@apply ml-3 transition-opacity duration-200;
}
.sidebar.collapsed .sidebar-user-info {
@apply opacity-0 invisible;
}
.sidebar-user-name {
@apply text-sm font-medium text-gray-900;
}
.sidebar-user-role {
@apply text-xs text-gray-500;
}
/* 导航菜单 */
.sidebar-menu {
@apply flex-1 overflow-y-auto py-4 px-3;
}
.sidebar-menu-item {
@apply flex items-center py-3 px-4 text-gray-800 no-underline rounded-md
cursor-pointer transition-all duration-200 mb-1;
}
.sidebar-menu-item i {
@apply text-base w-6 text-center;
}
.sidebar-menu-icon {
@apply text-xl opacity-80 w-5 flex-shrink-0;
}
.sidebar-menu-text {
@apply ml-2.5 transition-opacity duration-200;
}
.sidebar.collapsed .sidebar-menu-text {
@apply opacity-0 invisible;
}
.sidebar-menu-badge {
@apply ml-auto bg-[#00684a] text-white text-xs font-semibold h-5 min-w-[20px] rounded-full
flex items-center justify-center px-1 transition-opacity duration-200;
}
.sidebar.collapsed .sidebar-menu-badge {
@apply opacity-0 invisible;
}
.sidebar-menu-item:hover {
@apply bg-[rgba(0,104,74,0.05)];
}
.sidebar-menu-item.active {
@apply bg-[rgba(0,104,74,0.1)] text-[#00684A] font-medium;
}
.sidebar-submenu {
@apply pl-7 mt-1 space-y-1 transition-all duration-200 overflow-hidden;
}
.sidebar-submenu-item {
@apply flex items-center px-3 py-2 rounded-md text-sm text-gray-500
hover:bg-gray-50 transition-colors duration-100;
}
.sidebar-submenu-item.active {
@apply text-[#00684a];
}
/* 侧边栏底部 */
.sidebar-footer {
@apply border-t border-gray-100 px-5 py-4;
}
/**
* 主布局容器
*/
.layout-container {
@apply flex min-h-screen bg-gray-50;
}
/**
* 主内容区域
*/
.main-content {
@apply flex-1 ml-[280px] transition-all duration-300 min-h-screen flex flex-col;
}
.main-content.sidebar-collapsed {
@apply ml-20;
}
.content-container {
@apply flex-1 p-5 overflow-auto;
}
/**
* 面包屑导航
*/
.breadcrumb {
@apply flex items-center text-sm text-gray-500 mb-4;
}
.breadcrumb-item {
@apply flex items-center;
}
.breadcrumb-item:not(:last-child)::after {
content: "/";
@apply mx-2;
}
.breadcrumb-item:last-child {
@apply text-gray-700 font-medium;
}
/**
* 响应式调整
*/
@screen sm {
.content-container {
@apply p-6;
}
}
@screen md {
.sidebar-toggle {
@apply block;
}
}
/**
* 暗色模式
*/
.dark .layout-container {
@apply bg-gray-900;
}
.dark .content-container {
@apply bg-gray-900 text-gray-200;
}
+144
View File
@@ -0,0 +1,144 @@
/**
* 首页特定样式
*/
/* 仪表盘容器 */
.dashboard-container {
@apply p-5;
}
/* 统计卡片 */
.stat-grid {
@apply grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-4 p-4;
}
.stat-card {
@apply bg-white rounded-lg p-4 shadow transition-all duration-200 relative;
}
.stat-card:hover {
@apply transform -translate-y-[3px] shadow-[0_4px_15px_rgba(0,0,0,0.1)];
}
.stat-title {
@apply text-sm text-gray-600 mb-2.5;
}
.stat-value {
@apply text-2xl font-semibold text-gray-900 mb-2.5;
}
.stat-trend {
@apply flex items-center text-xs;
}
.stat-trend.trend-up {
@apply text-[#52c41a];
}
.stat-trend.trend-down {
@apply text-[#f5222d];
}
.stat-icon {
@apply absolute right-4 top-4 text-2xl text-[#00684a] opacity-20;
}
/* 快捷访问网格 */
.shortcut-grid {
@apply grid grid-cols-2 sm:grid-cols-4 lg:grid-cols-8 gap-4 p-4;
}
.shortcut-item {
@apply flex flex-col items-center justify-center p-4 bg-white rounded-lg shadow
transition-all duration-200 cursor-pointer text-gray-900 h-24;
}
.shortcut-item:hover {
@apply transform -translate-y-[3px] shadow-[0_4px_12px_rgba(0,0,0,0.1)]
bg-[rgba(0,104,74,0.05)] text-[#00684a];
}
.shortcut-icon {
@apply text-2xl text-[#00684a] mb-2.5;
}
.shortcut-label {
@apply text-sm text-center;
}
/* 文档列表 */
.doc-list {
@apply space-y-3 p-4;
}
.doc-item {
@apply flex justify-between items-center p-3 border border-gray-100 rounded-lg hover:bg-gray-50 transition-colors duration-200;
}
.doc-info {
@apply flex items-center;
}
.doc-icon {
@apply text-2xl mr-3 text-primary;
}
.doc-name {
@apply text-sm font-medium text-gray-800 mb-1;
}
.doc-meta {
@apply text-xs text-gray-500;
}
.doc-status {
@apply flex items-center;
}
/* 状态标签 */
.status-badge {
@apply inline-flex items-center px-2 py-0.5 rounded-full text-xs font-medium;
}
.status-badge.status-success {
@apply bg-[rgba(0,104,74,0.1)] text-[#00684a];
}
.status-badge.status-warning {
@apply bg-[rgba(250,173,20,0.1)] text-[#faad14];
}
.status-badge.status-error {
@apply bg-[rgba(245,34,45,0.1)] text-[#f5222d];
}
/* 卡片样式 */
.dashboard-card {
@apply bg-white rounded-lg shadow p-5 mb-5 transition-all duration-200;
}
.dashboard-card:hover {
@apply transform -translate-y-[3px] shadow-[0_4px_15px_rgba(0,0,0,0.1)];
}
.card-title {
@apply text-base font-semibold mb-4 flex items-center text-gray-900;
}
.card-title i {
@apply text-xl text-[#00684a] mr-2;
}
/* 响应式调整 */
@screen md {
.stat-grid {
@apply grid-cols-2;
}
}
@screen lg {
.stat-grid {
@apply grid-cols-4;
}
}
+26
View File
@@ -0,0 +1,26 @@
/**
* 页面样式索引文件
* 集中导入所有页面特定样式
*/
/* 首页 */
@import "./home.css";
/* 评查点列表 */
@import "./rules_index.css";
/* 评查点分组 */
@import "./rule-groups.css";
/* 其他页面 - 待创建 */
/*
@import "./files.css";
@import "./rules.css";
@import "./reviews.css";
@import "./settings.css";
*/
/**
* 注意:如果上述导入的文件不存在,将会在构建时报错
* 请确保先创建这些文件,或者先注释掉不存在的文件
*/
+76
View File
@@ -0,0 +1,76 @@
/* 评查点分组管理页面样式 */
/* 树形结构样式 */
.tree-table .group-row {
transition: all 0.2s;
}
.tree-table .group-row:hover {
background-color: rgba(0, 104, 74, 0.05);
}
.tree-table .parent-row {
background-color: #f9f9f9;
font-weight: 500;
}
.tree-table .child-row {
border-left: 3px solid #f0f0f0;
}
.expand-icon {
width: 22px;
height: 22px;
border-radius: 4px;
display: inline-flex;
align-items: center;
justify-content: center;
cursor: pointer;
transition: all 0.2s;
}
.expand-icon:hover {
background-color: rgba(0, 104, 74, 0.1);
}
.group-badge {
display: inline-flex;
align-items: center;
padding: 2px 8px;
border-radius: 12px;
font-size: 12px;
margin-left: 8px;
}
.parent-badge {
background-color: rgba(0, 104, 74, 0.1);
color: var(--color-primary);
}
.child-badge {
background-color: rgba(0, 104, 74, 0.05);
color: var(--color-primary);
}
.badge {
display: inline-flex;
align-items: center;
justify-content: center;
padding: 2px 8px;
border-radius: 12px;
font-size: 12px;
}
/* 按钮文本样式,不与其他冲突 */
.btn-text {
background-color: transparent;
border: none;
color: var(--color-gray-800);
padding: 4px 8px;
}
/* 小尺寸按钮 */
.btn-sm {
padding: 4px 8px;
font-size: 12px;
}
+80
View File
@@ -0,0 +1,80 @@
/* 评查点列表页面样式 */
/* 筛选区域 */
.filter-card {
margin-bottom: 1rem;
}
/* 搜索框样式 */
.search-box {
display: flex;
align-items: center;
}
.search-box .form-input {
flex: 1;
border-top-right-radius: 0;
border-bottom-right-radius: 0;
}
.search-box .ant-btn {
border-top-left-radius: 0;
border-bottom-left-radius: 0;
}
/* 表格样式 */
.rules-table {
width: 100%;
margin-top: 1rem;
}
/* 表格操作列样式 */
.operations-cell {
white-space: nowrap;
}
/* 状态点样式 */
.status-dot {
display: inline-block;
width: 8px;
height: 8px;
border-radius: 50%;
margin-right: 5px;
}
.status-dot-success {
background-color: #52c41a;
}
.status-dot-default {
background-color: #d9d9d9;
}
/* 标签自定义样式 */
.rule-tag {
padding: 2px 8px;
font-size: 12px;
border-radius: 4px;
}
/* 表格行悬停效果 */
.ant-table tbody tr:hover {
background-color: rgba(0, 0, 0, 0.02);
}
/* 页面标题区域 */
.page-header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 1rem;
}
/* 卡片内容间距 */
.content-card {
padding: 0;
}
.content-card .ant-card-body {
padding: 0;
}
+342
View File
@@ -0,0 +1,342 @@
/**
* Tailwind CSS 配置
*
* 这个文件曾经包含所有样式定义,但现在已重组为更模块化的结构。
* 请使用 app/styles/index.css 作为主样式入口文件。
* 以下样式已转移到其他组件特定的CSS文件中,保留在此仅作备份参考。
*/
@import "./base.css";
:root {
--primary-color: #00684a;
--primary-hover: #005a40;
--primary-light: rgba(0, 104, 74, 0.1);
--success-color: #52c41a;
--warning-color: #faad14;
--error-color: #ff4d4f;
--text-color: rgba(0, 0, 0, 0.85);
--text-secondary: rgba(0, 0, 0, 0.45);
--border-color: #f0f0f0;
--bg-gray: #f5f5f5;
}
/*
@layer components {
/* 布局容器 */
/*
.layout-container {
@apply flex h-screen w-full overflow-hidden;
}
/* 侧边栏 */
/*
.sidebar {
@apply w-60 h-screen bg-blue-50 border-r border-gray-100 flex flex-col transition-all duration-300 fixed left-0 top-0 z-50 overflow-y-auto shadow-sm;
}
.sidebar.collapsed {
@apply w-16;
}
/* 主内容区 */
/*
.main-content {
@apply flex-1 p-5 overflow-y-auto ml-60 transition-all duration-300;
}
.main-content.sidebar-collapsed {
@apply ml-16;
}
/* 面包屑导航 */
/*
.breadcrumb {
@apply flex items-center text-sm text-gray-500 mb-4;
}
.breadcrumb-item {
@apply flex items-center;
}
.breadcrumb-item:not(:last-child)::after {
content: "/";
@apply mx-2 text-gray-400;
}
.breadcrumb-item:last-child {
@apply text-gray-700 font-medium;
}
/* 侧边栏菜单 */
/*
.sidebar-menu-item {
@apply py-2 px-4 hover:bg-gray-50 rounded-md transition-all duration-200 mb-1;
}
.sidebar-menu-item.active {
@apply bg-primary bg-opacity-10;
}
.sidebar-menu-item.active a {
@apply text-primary font-medium;
}
/* 卡片样式 */
/*
.dashboard-card {
@apply bg-white rounded-lg shadow-sm p-5 mb-5;
}
.card-title {
@apply text-base font-semibold mb-4 flex items-center text-gray-800;
}
.card-title i {
@apply text-xl mr-2 text-primary;
}
/* 统计卡片网格 */
/*
.stat-grid {
@apply grid grid-cols-1 md:grid-cols-4 gap-4;
}
/* 状态标签 */
/*
.status-badge {
@apply inline-flex items-center px-2 py-0.5 rounded-full text-xs font-medium;
}
.status-badge.status-success {
@apply bg-green-50 text-green-600;
}
.status-badge.status-warning {
@apply bg-yellow-50 text-yellow-600;
}
.status-badge.status-error {
@apply bg-red-50 text-red-600;
}
/* 状态点 */
/*
.status-dot {
@apply inline-block w-2 h-2 rounded-full mr-1.5;
}
.status-dot-success {
@apply bg-green-500;
}
.status-dot-warning {
@apply bg-yellow-500;
}
.status-dot-error {
@apply bg-red-500;
}
.status-dot-default {
@apply bg-gray-400;
}
/* 表单组件 */
/*
.form-label {
@apply block text-sm font-medium text-gray-700 mb-1;
}
.form-input {
@apply block w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-primary focus:border-primary sm:text-sm;
}
.form-select {
@apply block w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-primary focus:border-primary sm:text-sm;
}
.search-box {
@apply relative flex;
}
.search-box input {
@apply pr-10;
}
.search-box button {
@apply absolute inset-y-0 right-0 flex items-center px-2;
}
/* 表格样式 */
/*
.ant-table {
@apply w-full bg-white rounded-md overflow-hidden;
}
.ant-table th {
@apply py-3 px-4 text-left text-sm font-medium text-gray-600 bg-gray-50 border-b border-gray-200;
}
.ant-table td {
@apply py-3 px-4 text-sm text-gray-700 border-b border-gray-100;
}
.ant-table tr:hover td {
@apply bg-gray-50;
}
/* 按钮样式 */
/*
.ant-btn {
@apply inline-flex items-center justify-center px-4 py-2 border border-transparent rounded-md shadow-sm text-sm font-medium focus:outline-none transition-colors duration-200;
}
.ant-btn-primary {
@apply bg-primary text-white hover:bg-primary-dark;
}
.ant-btn-default {
@apply bg-white text-gray-700 border-gray-300 hover:bg-gray-50;
}
.ant-btn-danger {
@apply bg-white text-red-600 border-gray-300 hover:bg-red-50 hover:border-red-300;
}
.ant-btn-sm {
@apply px-2.5 py-1 text-xs;
}
/* 标签样式 */
/*
.ant-tag {
@apply inline-flex items-center px-2 py-0.5 rounded-md text-xs font-medium;
}
.ant-tag-blue {
@apply bg-blue-50 text-blue-600;
}
.ant-tag-green {
@apply bg-green-50 text-green-600;
}
.ant-tag-cyan {
@apply bg-cyan-50 text-cyan-600;
}
.ant-tag-purple {
@apply bg-purple-50 text-purple-600;
}
.ant-tag-orange {
@apply bg-orange-50 text-orange-600;
}
.ant-tag-red {
@apply bg-red-50 text-red-600;
}
/* 卡片样式 */
/*
.ant-card {
@apply bg-white rounded-md shadow-sm overflow-hidden mb-5;
}
.ant-card-body {
@apply p-5;
}
/* 评查结果面板 */
/*
.review-points-panel {
@apply bg-white rounded-md shadow-sm overflow-hidden h-full;
}
.review-panel-header {
@apply bg-primary bg-opacity-10 flex items-center;
}
/* 评查点样式 */
/*
.review-point-item {
@apply border-b border-gray-100 p-3 hover:bg-gray-50 cursor-pointer;
}
.review-point-header {
@apply flex items-center justify-between mb-1;
}
.review-point-title {
@apply text-sm font-medium text-gray-700;
}
.review-point-location {
@apply flex items-center text-xs text-gray-500;
}
/* 选项卡 */
/*
.tab-container {
@apply bg-white rounded-md shadow-sm overflow-hidden;
}
.tab-nav {
@apply flex border-b border-gray-200;
}
.tab-nav-item {
@apply flex items-center py-3 px-4 text-sm font-medium text-gray-600 cursor-pointer;
}
.tab-nav-item i {
@apply mr-1.5;
}
.tab-nav-item.active {
@apply text-primary border-b-2 border-primary;
}
.tab-content {
@apply p-4;
}
.tab-pane {
@apply hidden;
}
.tab-pane.active {
@apply block;
}
/* 辅助类 */
/*
.text-primary {
@apply text-green-700;
}
.bg-primary {
@apply bg-green-700;
}
.bg-primary-light {
@apply bg-green-50;
}
.text-success {
@apply text-green-600;
}
.text-warning {
@apply text-yellow-600;
}
.text-error {
@apply text-red-600;
}
.border-primary {
@apply border-green-700;
}
} */