123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876 |
- .modal-overlay {
- position: fixed;
- top: 0;
- left: 0;
- right: 0;
- bottom: 0;
- background-color: rgba(0, 0, 0, 0.5);
- display: flex;
- align-items: center;
- justify-content: center;
- z-index: 99;
- padding: 20px;
- }
- .modal-container {
- background: white;
- border-radius: 12px;
- max-width: 1200px;
- width: 100%;
- max-height: 90vh;
- display: flex;
- flex-direction: column;
- box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
- overflow: hidden;
- }
- .modal-header {
- padding: 24px;
- border-bottom: 1px solid #e5e7eb;
- display: flex;
- justify-content: space-between;
- align-items: flex-start;
- gap: 20px;
- flex-shrink: 0;
- .header-left {
- flex: 1;
- min-width: 0;
- .modal-title {
- font-size: 24px;
- font-weight: 600;
- color: #1f2937;
- margin: 0 0 12px 0;
- display: flex;
- align-items: center;
- gap: 8px;
- .title-icon {
- width: 28px;
- height: 28px;
- color: #3b82f6;
- }
- }
- .file-stats {
- display: flex;
- gap: 16px;
- flex-wrap: wrap;
- .stat-item {
- display: flex;
- flex-direction: column;
- align-items: center;
- min-width: 50px;
- .stat-number {
- font-size: 18px;
- font-weight: 600;
- color: #1f2937;
- line-height: 1;
- }
- .stat-label {
- font-size: 12px;
- color: #6b7280;
- margin-top: 2px;
- }
- }
- }
- }
- .header-right {
- display: flex;
- align-items: center;
- gap: 12px;
- flex-shrink: 0;
- .view-toggle {
- display: flex;
- border: 1px solid #e5e7eb;
- border-radius: 6px;
- overflow: hidden;
- .toggle-btn {
- background: white;
- border: none;
- padding: 8px 12px;
- cursor: pointer;
- display: flex;
- align-items: center;
- justify-content: center;
- transition: all 0.2s ease;
- color: #6b7280;
- svg {
- width: 18px;
- height: 18px;
- }
- &:hover {
- background-color: #f9fafb;
- }
- &.active {
- background-color: #3b82f6;
- color: white;
- }
- &:not(:last-child) {
- border-right: 1px solid #e5e7eb;
- }
- }
- }
- .search-box {
- position: relative;
- display: flex;
- align-items: center;
- .search-icon {
- position: absolute;
- left: 12px;
- width: 18px;
- height: 18px;
- color: #6b7280;
- }
- .search-input {
- padding: 8px 12px 8px 36px;
- border: 1px solid #e5e7eb;
- border-radius: 6px;
- font-size: 14px;
- width: 200px;
- outline: none;
- transition: border-color 0.2s ease;
- &:focus {
- border-color: #3b82f6;
- box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
- }
- }
- }
- .filter-select {
- padding: 8px 12px;
- border: 1px solid #e5e7eb;
- border-radius: 6px;
- font-size: 14px;
- outline: none;
- cursor: pointer;
- transition: border-color 0.2s ease;
- &:focus {
- border-color: #3b82f6;
- }
- }
- .close-btn {
- background: none;
- border: none;
- padding: 8px;
- border-radius: 6px;
- cursor: pointer;
- color: #6b7280;
- transition: all 0.2s ease;
- display: flex;
- align-items: center;
- justify-content: center;
- svg {
- width: 20px;
- height: 20px;
- }
- &:hover {
- background-color: #f3f4f6;
- color: #374151;
- }
- }
- }
- }
- .modal-content {
- flex: 1;
- padding: 24px;
- overflow-y: auto;
- min-height: 0;
- }
- .loading-state {
- display: flex;
- flex-direction: column;
- align-items: center;
- justify-content: center;
- padding: 60px 20px;
- color: #6b7280;
- .loading-spinner {
- width: 40px;
- height: 40px;
- border: 3px solid #e5e7eb;
- border-top: 3px solid #3b82f6;
- border-radius: 50%;
- animation: spin 1s linear infinite;
- margin-bottom: 16px;
- }
- p {
- margin: 0;
- font-size: 16px;
- }
- }
- .empty-state {
- text-align: center;
- padding: 60px 20px;
- color: #6b7280;
- .empty-icon {
- width: 64px;
- height: 64px;
- margin: 0 auto 16px;
- opacity: 0.3;
- }
- h3 {
- font-size: 18px;
- font-weight: 600;
- margin: 0 0 8px 0;
- color: #374151;
- }
- p {
- margin: 0;
- font-size: 14px;
- }
- }
- .files-grid {
- display: grid;
- grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
- gap: 20px;
- }
- .file-card {
- background: white;
- border: 1px solid #e5e7eb;
- border-radius: 8px;
- overflow: hidden;
- cursor: pointer;
- transition: all 0.2s ease;
- &:hover {
- border-color: #3b82f6;
- box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
- transform: translateY(-2px);
- }
- .file-preview {
- aspect-ratio: 16/9;
- background-color: #f9fafb;
- position: relative;
- overflow: hidden;
- .preview-image {
- width: 100%;
- height: 100%;
- object-fit: cover;
- }
- .preview-placeholder {
- display: flex;
- flex-direction: column;
- align-items: center;
- justify-content: center;
- height: 100%;
- padding: 20px;
- .file-icon {
- font-size: 48px;
- margin-bottom: 8px;
- opacity: 0.6;
- }
- .file-extension {
- font-size: 14px;
- font-weight: 600;
- color: #6b7280;
- background-color: #f3f4f6;
- padding: 4px 8px;
- border-radius: 4px;
- }
- }
- }
- .file-info {
- padding: 16px;
- .file-name {
- font-size: 14px;
- font-weight: 600;
- color: #1f2937;
- margin: 0 0 8px 0;
- line-height: 1.4;
- display: -webkit-box;
- -webkit-line-clamp: 2;
- -webkit-box-orient: vertical;
- overflow: hidden;
- }
- .file-meta {
- display: flex;
- gap: 8px;
- margin-bottom: 8px;
- font-size: 12px;
- color: #6b7280;
- .file-size {
- font-weight: 500;
- }
- }
- .file-description {
- margin-bottom: 12px;
- p {
- font-size: 12px;
- color: #6b7280;
- margin: 0;
- line-height: 1.4;
- display: -webkit-box;
- -webkit-line-clamp: 2;
- -webkit-box-orient: vertical;
- overflow: hidden;
- }
- }
- .file-footer {
- display: flex;
- justify-content: space-between;
- align-items: center;
- .uploader-info {
- display: flex;
- align-items: center;
- gap: 8px;
- flex: 1;
- min-width: 0;
- .uploader-avatar {
- width: 24px;
- height: 24px;
- border-radius: 50%;
- object-fit: cover;
- }
- .uploader-name {
- font-size: 12px;
- color: #374151;
- font-weight: 500;
- white-space: nowrap;
- overflow: hidden;
- text-overflow: ellipsis;
- }
- .source-badge {
- font-size: 10px;
- padding: 2px 6px;
- border-radius: 10px;
- font-weight: 500;
- white-space: nowrap;
- &.source-wxwork {
- background-color: #dcfce7;
- color: #166534;
- }
- &.source-manual {
- background-color: #dbeafe;
- color: #1e40af;
- }
- &.source-default {
- background-color: #f3f4f6;
- color: #6b7280;
- }
- }
- }
- .file-actions {
- .action-btn {
- background: none;
- border: none;
- padding: 6px;
- border-radius: 4px;
- cursor: pointer;
- color: #6b7280;
- transition: all 0.2s ease;
- display: flex;
- align-items: center;
- justify-content: center;
- svg {
- width: 16px;
- height: 16px;
- }
- &:hover {
- background-color: #f3f4f6;
- color: #374151;
- &.download-btn {
- background-color: #eff6ff;
- color: #3b82f6;
- }
- }
- &.download-btn:hover {
- background-color: #eff6ff;
- color: #3b82f6;
- }
- }
- }
- }
- }
- }
- .files-list {
- .file-list-item {
- display: flex;
- align-items: center;
- gap: 16px;
- padding: 16px;
- border-bottom: 1px solid #f3f4f6;
- cursor: pointer;
- transition: background-color 0.2s ease;
- &:hover {
- background-color: #f9fafb;
- }
- &:last-child {
- border-bottom: none;
- }
- .list-file-icon {
- width: 48px;
- height: 48px;
- border-radius: 6px;
- overflow: hidden;
- background-color: #f3f4f6;
- display: flex;
- align-items: center;
- justify-content: center;
- flex-shrink: 0;
- .list-preview-image {
- width: 100%;
- height: 100%;
- object-fit: cover;
- }
- .list-icon {
- font-size: 24px;
- }
- }
- .list-file-info {
- flex: 1;
- min-width: 0;
- .list-file-name {
- font-size: 14px;
- font-weight: 600;
- color: #1f2937;
- margin-bottom: 4px;
- }
- .list-file-meta {
- display: flex;
- gap: 12px;
- font-size: 12px;
- color: #6b7280;
- flex-wrap: wrap;
- .source-badge {
- font-size: 10px;
- padding: 2px 6px;
- border-radius: 10px;
- font-weight: 500;
- &.source-wxwork {
- background-color: #dcfce7;
- color: #166534;
- }
- &.source-manual {
- background-color: #dbeafe;
- color: #1e40af;
- }
- &.source-default {
- background-color: #f3f4f6;
- color: #6b7280;
- }
- }
- }
- .list-file-description {
- font-size: 12px;
- color: #6b7280;
- margin-top: 4px;
- display: -webkit-box;
- -webkit-line-clamp: 1;
- -webkit-box-orient: vertical;
- overflow: hidden;
- }
- }
- .list-file-actions {
- .action-btn {
- background: none;
- border: none;
- padding: 8px;
- border-radius: 4px;
- cursor: pointer;
- color: #6b7280;
- transition: all 0.2s ease;
- svg {
- width: 18px;
- height: 18px;
- }
- &:hover {
- background-color: #f3f4f6;
- color: #374151;
- &.download-btn {
- background-color: #eff6ff;
- color: #3b82f6;
- }
- }
- }
- }
- }
- }
- // 预览模态框
- .preview-overlay {
- position: fixed;
- top: 0;
- left: 0;
- right: 0;
- bottom: 0;
- background-color: rgba(0, 0, 0, 0.8);
- display: flex;
- align-items: center;
- justify-content: center;
- z-index: 100;
- padding: 20px;
- }
- .preview-container {
- background: white;
- border-radius: 12px;
- max-width: 90vw;
- max-height: 90vh;
- width: 100%;
- display: flex;
- flex-direction: column;
- overflow: hidden;
- .preview-header {
- padding: 20px;
- border-bottom: 1px solid #e5e7eb;
- display: flex;
- justify-content: space-between;
- align-items: center;
- h3 {
- font-size: 18px;
- font-weight: 600;
- color: #1f2937;
- margin: 0;
- flex: 1;
- min-width: 0;
- overflow: hidden;
- text-overflow: ellipsis;
- white-space: nowrap;
- }
- .preview-close {
- background: none;
- border: none;
- padding: 8px;
- border-radius: 6px;
- cursor: pointer;
- color: #6b7280;
- transition: all 0.2s ease;
- svg {
- width: 20px;
- height: 20px;
- }
- &:hover {
- background-color: #f3f4f6;
- color: #374151;
- }
- }
- }
- .preview-content {
- flex: 1;
- padding: 20px;
- display: flex;
- align-items: center;
- justify-content: center;
- background-color: #f9fafb;
- min-height: 300px;
- .preview-full-image {
- max-width: 100%;
- max-height: 100%;
- object-fit: contain;
- border-radius: 8px;
- }
- .preview-video {
- max-width: 100%;
- max-height: 100%;
- border-radius: 8px;
- }
- .preview-no-preview {
- text-align: center;
- color: #6b7280;
- .preview-icon-large {
- font-size: 64px;
- margin-bottom: 16px;
- opacity: 0.6;
- }
- p {
- margin: 0 0 16px 0;
- font-size: 16px;
- }
- .preview-download-btn {
- background: #3b82f6;
- color: white;
- border: none;
- padding: 10px 20px;
- border-radius: 6px;
- font-size: 14px;
- font-weight: 500;
- cursor: pointer;
- transition: all 0.2s ease;
- &:hover {
- background: #2563eb;
- }
- }
- }
- }
- .preview-footer {
- padding: 20px;
- border-top: 1px solid #e5e7eb;
- background-color: #f9fafb;
- .preview-meta {
- display: flex;
- gap: 16px;
- margin-bottom: 16px;
- font-size: 14px;
- color: #6b7280;
- flex-wrap: wrap;
- .source-badge {
- font-size: 12px;
- padding: 4px 8px;
- border-radius: 12px;
- font-weight: 500;
- &.source-wxwork {
- background-color: #dcfce7;
- color: #166534;
- }
- &.source-manual {
- background-color: #dbeafe;
- color: #1e40af;
- }
- &.source-default {
- background-color: #f3f4f6;
- color: #6b7280;
- }
- }
- }
- .preview-description {
- .description-textarea {
- width: 100%;
- min-height: 60px;
- padding: 12px;
- border: 1px solid #e5e7eb;
- border-radius: 6px;
- font-size: 14px;
- font-family: inherit;
- resize: vertical;
- outline: none;
- transition: border-color 0.2s ease;
- &:focus {
- border-color: #3b82f6;
- box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
- }
- &::placeholder {
- color: #9ca3af;
- }
- }
- }
- }
- }
- @keyframes spin {
- 0% { transform: rotate(0deg); }
- 100% { transform: rotate(360deg); }
- }
- // 响应式设计
- @media (max-width: 768px) {
- .modal-overlay {
- padding: 0;
- }
- .modal-container {
- max-height: 100vh;
- border-radius: 0;
- }
- .modal-header {
- padding: 16px;
- flex-direction: column;
- gap: 16px;
- .header-left {
- .modal-title {
- font-size: 20px;
- }
- .file-stats {
- justify-content: center;
- gap: 12px;
- }
- }
- .header-right {
- width: 100%;
- flex-direction: column;
- gap: 12px;
- .search-box .search-input {
- width: 100%;
- }
- }
- }
- .modal-content {
- padding: 16px;
- }
- .files-grid {
- grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
- gap: 16px;
- }
- .file-card {
- .file-info {
- padding: 12px;
- }
- .file-footer {
- flex-direction: column;
- gap: 8px;
- align-items: stretch;
- .uploader-info {
- justify-content: center;
- }
- .file-actions {
- justify-content: center;
- }
- }
- }
- .files-list {
- .file-list-item {
- padding: 12px;
- gap: 12px;
- .list-file-icon {
- width: 40px;
- height: 40px;
- }
- }
- }
- .preview-overlay {
- padding: 0;
- }
- .preview-container {
- max-width: 100vw;
- max-height: 100vh;
- border-radius: 0;
- }
- }
- @media (max-width: 480px) {
- .files-grid {
- grid-template-columns: 1fr;
- }
- .modal-header {
- .header-right {
- .view-toggle {
- justify-content: center;
- }
- .filter-select {
- width: 100%;
- }
- }
- }
- }
- .file-actions {
- display: flex;
- gap: 8px;
- margin-top: 8px;
- }
- .download-btn, .analyze-btn {
- padding: 6px 12px;
- border: none;
- border-radius: 4px;
- cursor: pointer;
- }
- .download-btn {
- background: #1976d2;
- color: #fff;
- }
- .analyze-btn {
- background: #6a1b9a;
- color: #fff;
- }
|