final
Change-Id: Icf4ec3950a6bd1e066fa4a1976af36721af62a06
diff --git a/front/src/SharedStyles.css b/front/src/SharedStyles.css
index 730a76e..49c13e6 100644
--- a/front/src/SharedStyles.css
+++ b/front/src/SharedStyles.css
@@ -1156,15 +1156,31 @@
transform: translateY(-1px);
}
-/* 动画定义 */
-@keyframes backgroundShift {
- 0%, 100% { opacity: 1; }
- 50% { opacity: 0.7; }
+/* 发布页面专用样式 */
+.publish-text-rain {
+ position: fixed;
+ top: 0;
+ left: 0;
+ width: 100%;
+ height: 100%;
+ pointer-events: none;
+ overflow: hidden;
+ z-index: 1;
}
-@keyframes meteorFall {
+.publish-text-rain .text-drop {
+ position: absolute;
+ font-size: 16px;
+ font-weight: 600;
+ animation: publishTextFall linear infinite;
+ opacity: 0.7;
+ filter: drop-shadow(0 2px 4px rgba(144, 238, 144, 0.3));
+ font-family: 'Lora', serif;
+}
+
+@keyframes publishTextFall {
0% {
- transform: translateY(-100vh) translateX(-50px) rotate(0deg);
+ transform: translateY(-100vh) rotate(0deg);
opacity: 0;
}
10% {
@@ -1174,246 +1190,638 @@
opacity: 0.8;
}
100% {
- transform: translateY(100vh) translateX(50px) rotate(360deg);
+ transform: translateY(100vh) rotate(360deg);
opacity: 0;
}
}
-@keyframes gardenFloat {
+.publish-form-container {
+ max-width: 900px;
+ margin: 0 auto;
+}
+
+.publish-form-advanced {
+ background: rgba(255, 255, 255, 0.98);
+ border-radius: 25px;
+ padding: 40px;
+ border: 2px solid rgba(144, 238, 144, 0.2);
+ position: relative;
+ overflow: hidden;
+ box-shadow: 0 20px 60px rgba(45, 80, 22, 0.12);
+}
+
+.publish-form-advanced::before {
+ content: '';
+ position: absolute;
+ top: -2px;
+ left: -2px;
+ right: -2px;
+ bottom: -2px;
+ background: linear-gradient(45deg,
+ #90ee90 0%,
+ #98fb98 25%,
+ #f0fff0 50%,
+ #98fb98 75%,
+ #90ee90 100%);
+ border-radius: 27px;
+ z-index: -1;
+ animation: borderGlow 5s ease-in-out infinite;
+}
+
+.form-section {
+ margin-bottom: 35px;
+ padding: 25px;
+ background: rgba(240, 255, 240, 0.2);
+ border-radius: 20px;
+ border: 1px solid rgba(144, 238, 144, 0.2);
+ transition: all 0.3s ease;
+}
+
+.form-section:hover {
+ background: rgba(240, 255, 240, 0.3);
+ transform: translateY(-2px);
+ box-shadow: 0 8px 25px rgba(45, 80, 22, 0.1);
+}
+
+.section-header {
+ display: flex;
+ align-items: center;
+ margin-bottom: 20px;
+ padding-bottom: 15px;
+ border-bottom: 2px solid rgba(144, 238, 144, 0.2);
+}
+
+.section-header h3 {
+ color: #2d5016;
+ font-size: 20px;
+ font-weight: 600;
+ margin: 0;
+ font-family: 'Playfair Display', serif;
+}
+
+.form-grid {
+ display: grid;
+ grid-template-columns: 1fr 1fr;
+ gap: 25px;
+}
+
+.form-field {
+ display: flex;
+ flex-direction: column;
+ margin-bottom: 20px;
+}
+
+.form-field label {
+ color: #2d5016;
+ font-weight: 600;
+ margin-bottom: 8px;
+ font-size: 16px;
+ display: flex;
+ align-items: center;
+ font-family: 'Lora', serif;
+}
+
+.select-wrapper {
+ position: relative;
+}
+
+.modern-select {
+ width: 100%;
+ padding: 15px 20px;
+ border: 2px solid rgba(144, 238, 144, 0.3);
+ border-radius: 15px;
+ font-size: 16px;
+ background: rgba(255, 255, 255, 0.9);
+ color: #2d5016;
+ transition: all 0.3s ease;
+ appearance: none;
+ cursor: pointer;
+ font-family: 'Lora', serif;
+}
+
+.modern-select:focus {
+ outline: none;
+ border-color: #90ee90;
+ background: rgba(255, 255, 255, 1);
+ box-shadow: 0 0 0 3px rgba(144, 238, 144, 0.2);
+ transform: translateY(-2px);
+}
+
+.modern-select::after {
+ content: '▼';
+ position: absolute;
+ right: 15px;
+ top: 50%;
+ transform: translateY(-50%);
+ color: #90ee90;
+ pointer-events: none;
+}
+
+.modern-input {
+ width: 100%;
+ padding: 15px 20px;
+ border: 2px solid rgba(144, 238, 144, 0.3);
+ border-radius: 15px;
+ font-size: 16px;
+ background: rgba(255, 255, 255, 0.9);
+ color: #2d5016;
+ transition: all 0.3s ease;
+ font-family: 'Lora', serif;
+ box-sizing: border-box;
+}
+
+.modern-input:focus {
+ outline: none;
+ border-color: #90ee90;
+ background: rgba(255, 255, 255, 1);
+ box-shadow: 0 0 0 3px rgba(144, 238, 144, 0.2);
+ transform: translateY(-2px);
+}
+
+.modern-textarea {
+ width: 100%;
+ padding: 15px 20px;
+ border: 2px solid rgba(144, 238, 144, 0.3);
+ border-radius: 15px;
+ font-size: 16px;
+ background: rgba(255, 255, 255, 0.9);
+ color: #2d5016;
+ transition: all 0.3s ease;
+ resize: vertical;
+ min-height: 120px;
+ font-family: 'Lora', serif;
+ line-height: 1.6;
+ box-sizing: border-box;
+}
+
+.modern-textarea:focus {
+ outline: none;
+ border-color: #90ee90;
+ background: rgba(255, 255, 255, 1);
+ box-shadow: 0 0 0 3px rgba(144, 238, 144, 0.2);
+ transform: translateY(-2px);
+}
+
+/* 文件上传区域 */
+.file-upload-area {
+ border: 3px dashed rgba(144, 238, 144, 0.4);
+ border-radius: 20px;
+ padding: 40px;
+ text-align: center;
+ background: rgba(240, 255, 240, 0.3);
+ transition: all 0.3s ease;
+ cursor: pointer;
+ position: relative;
+ overflow: hidden;
+}
+
+.file-upload-area:hover {
+ border-color: #90ee90;
+ background: rgba(240, 255, 240, 0.5);
+ transform: translateY(-3px);
+ box-shadow: 0 10px 30px rgba(45, 80, 22, 0.15);
+}
+
+/* 拖拽上传状态样式 */
+.file-upload-area.drag-over {
+ border-color: #2d5016 !important;
+ background: rgba(144, 238, 144, 0.2) !important;
+ transform: translateY(-5px) scale(1.02);
+ box-shadow:
+ 0 15px 40px rgba(45, 80, 22, 0.25),
+ 0 0 0 3px rgba(144, 238, 144, 0.3);
+ animation: dragPulse 1.5s ease-in-out infinite;
+}
+
+.file-upload-area.drag-over .upload-main-text {
+ color: #2d5016 !important;
+ font-weight: 700;
+ transform: scale(1.05);
+}
+
+.file-upload-area.drag-over .upload-sub-text {
+ color: #1a5c1a !important;
+ font-weight: 600;
+}
+
+@keyframes dragPulse {
0%, 100% {
- transform: translateY(0px) rotate(0deg);
- opacity: 0.4;
+ box-shadow:
+ 0 15px 40px rgba(45, 80, 22, 0.25),
+ 0 0 0 3px rgba(144, 238, 144, 0.3);
}
50% {
- transform: translateY(-15px) rotate(180deg);
- opacity: 0.6;
+ box-shadow:
+ 0 20px 50px rgba(45, 80, 22, 0.35),
+ 0 0 0 5px rgba(144, 238, 144, 0.4);
}
}
-@keyframes userBarFloat {
- 0%, 100% {
- transform: translateY(0px);
- }
- 50% {
- transform: translateY(-3px);
- }
+/* 拖拽时的全局遮罩效果 */
+.file-upload-area.drag-over::after {
+ content: '';
+ position: absolute;
+ top: -5px;
+ left: -5px;
+ right: -5px;
+ bottom: -5px;
+ border: 3px dashed #2d5016;
+ border-radius: 25px;
+ background: rgba(144, 238, 144, 0.1);
+ animation: dashRotate 2s linear infinite;
+ pointer-events: none;
}
-@keyframes borderGlow {
- 0%, 100% {
- opacity: 0.6;
- }
- 50% {
- opacity: 1;
- }
-}
-
-@keyframes iconDance {
- 0%, 100% {
- transform: scale(1) rotate(0deg);
+@keyframes dashRotate {
+ 0% {
+ border-color: #2d5016;
+ transform: rotate(0deg);
}
25% {
- transform: scale(1.1) rotate(5deg);
+ border-color: #90ee90;
}
50% {
- transform: scale(1.2) rotate(0deg);
+ border-color: #2d5016;
+ transform: rotate(180deg);
}
75% {
- transform: scale(1.1) rotate(-5deg);
+ border-color: #90ee90;
+ }
+ 100% {
+ border-color: #2d5016;
+ transform: rotate(360deg);
}
}
-@keyframes iconPulse {
+/* 文件上传区域增强过渡效果 */
+.file-upload-area {
+ position: relative;
+ transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
+}
+
+.file-upload-label {
+ transition: all 0.3s ease;
+ z-index: 10;
+ position: relative;
+}
+
+.upload-main-text,
+.upload-sub-text {
+ transition: all 0.3s ease;
+}
+
+/* 防止拖拽时的默认行为 */
+.file-upload-area * {
+ pointer-events: none;
+}
+
+.file-upload-area label {
+ pointer-events: auto;
+}
+
+.file-upload-area input {
+ pointer-events: auto;
+}
+
+/* 文件上传隐藏输入框 */
+.file-input-hidden {
+ display: none;
+}
+
+.file-upload-label {
+ display: flex;
+ flex-direction: column;
+ align-items: center;
+ cursor: pointer;
+ padding: 20px;
+ border-radius: 15px;
+ transition: all 0.3s ease;
+}
+
+.upload-text {
+ display: flex;
+ flex-direction: column;
+ align-items: center;
+ gap: 8px;
+}
+
+.upload-main-text {
+ font-size: 18px;
+ font-weight: 600;
+ color: #2d5016;
+ transition: all 0.3s ease;
+ font-family: 'Playfair Display', serif;
+}
+
+.upload-sub-text {
+ font-size: 14px;
+ color: #4a7c59;
+ font-style: italic;
+ transition: all 0.3s ease;
+ text-align: center;
+ font-family: 'Lora', serif;
+}
+
+/* 上传进度区域样式 */
+.upload-progress-section {
+ margin: 30px 0;
+ padding: 25px;
+ background: rgba(144, 238, 144, 0.1);
+ border-radius: 20px;
+ border: 2px solid rgba(144, 238, 144, 0.3);
+ animation: progressGlow 2s ease-in-out infinite;
+}
+
+@keyframes progressGlow {
0%, 100% {
- transform: scale(1);
+ border-color: rgba(144, 238, 144, 0.3);
+ box-shadow: 0 0 10px rgba(144, 238, 144, 0.1);
}
50% {
- transform: scale(1.1);
+ border-color: rgba(144, 238, 144, 0.5);
+ box-shadow: 0 0 20px rgba(144, 238, 144, 0.2);
+ }
+}
+
+.progress-header {
+ display: flex;
+ justify-content: space-between;
+ align-items: center;
+ margin-bottom: 15px;
+ font-family: 'Lora', serif;
+ font-weight: 600;
+ color: #2d5016;
+ font-size: 16px;
+}
+
+.progress-bar {
+ width: 100%;
+ height: 12px;
+ background: rgba(255, 255, 255, 0.8);
+ border-radius: 10px;
+ overflow: hidden;
+ border: 2px solid rgba(144, 238, 144, 0.3);
+ position: relative;
+}
+
+.progress-fill {
+ height: 100%;
+ background: linear-gradient(90deg,
+ #90ee90 0%,
+ #98fb98 25%,
+ #2d5016 50%,
+ #98fb98 75%,
+ #90ee90 100%);
+ border-radius: 8px;
+ transition: width 0.3s ease;
+ position: relative;
+ animation: progressShine 2s ease-in-out infinite;
+}
+
+@keyframes progressShine {
+ 0% {
+ background-position: -100% 0;
+ }
+ 100% {
+ background-position: 100% 0;
+ }
+}
+
+.progress-fill::after {
+ content: '';
+ position: absolute;
+ top: 0;
+ left: -100%;
+ width: 100%;
+ height: 100%;
+ background: linear-gradient(90deg,
+ transparent 0%,
+ rgba(255, 255, 255, 0.4) 50%,
+ transparent 100%);
+ animation: progressShineEffect 2s ease-in-out infinite;
+}
+
+@keyframes progressShineEffect {
+ 0% {
+ left: -100%;
+ }
+ 100% {
+ left: 100%;
+ }
+}
+
+/* 表单提交区域样式 */
+.form-submit-section {
+ display: flex;
+ flex-direction: column;
+ align-items: center;
+ justify-content: center;
+ text-align: center;
+ margin: 40px auto;
+ padding: 30px;
+ background: rgba(240, 255, 240, 0.3);
+ border-radius: 20px;
+ border: 2px dashed rgba(144, 238, 144, 0.4);
+ position: relative;
+ overflow: hidden;
+ max-width: 400px;
+}
+
+.form-submit-section::before {
+ content: '';
+ position: absolute;
+ top: -50%;
+ left: -50%;
+ width: 200%;
+ height: 200%;
+ background: radial-gradient(circle, rgba(144, 238, 144, 0.1) 0%, transparent 70%);
+ animation: submitAreaFloat 8s ease-in-out infinite;
+ pointer-events: none;
+}
+
+@keyframes submitAreaFloat {
+ 0%, 100% {
+ transform: translate(-50%, -50%) rotate(0deg);
+ }
+ 50% {
+ transform: translate(-50%, -50%) rotate(180deg);
+ }
+}
+
+/* 发布提交按钮样式 */
+.publish-submit-btn {
+ background: linear-gradient(135deg, #2d5016 0%, #4a7c59 25%, #90ee90 50%, #4a7c59 75%, #2d5016 100%);
+ background-size: 300% 300%;
+ color: white;
+ border: none;
+ padding: 18px 45px;
+ font-size: 18px;
+ font-weight: 600;
+ border-radius: 25px;
+ cursor: pointer;
+ transition: all 0.4s ease;
+ position: relative;
+ overflow: hidden;
+ font-family: 'Playfair Display', serif;
+ letter-spacing: 1px;
+ box-shadow:
+ 0 8px 25px rgba(45, 80, 22, 0.3),
+ inset 0 1px 0 rgba(255, 255, 255, 0.2);
+ animation: buttonGradient 3s ease-in-out infinite;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ min-width: 180px;
+ margin: 0 auto;
+ z-index: 10;
+}
+
+.publish-submit-btn::before {
+ content: '';
+ position: absolute;
+ top: 0;
+ left: -100%;
+ width: 100%;
+ height: 100%;
+ background: linear-gradient(90deg,
+ transparent 0%,
+ rgba(255, 255, 255, 0.3) 50%,
+ transparent 100%);
+ transition: left 0.6s ease;
+}
+
+.publish-submit-btn:hover::before {
+ left: 100%;
+}
+
+.publish-submit-btn:hover {
+ transform: translateY(-3px) scale(1.05);
+ box-shadow:
+ 0 12px 35px rgba(45, 80, 22, 0.4),
+ 0 0 0 3px rgba(144, 238, 144, 0.3),
+ inset 0 1px 0 rgba(255, 255, 255, 0.3);
+ background-position: 100% 100%;
+}
+
+.publish-submit-btn:active {
+ transform: translateY(-1px) scale(1.02);
+ transition: all 0.1s ease;
+}
+
+.publish-submit-btn:disabled {
+ opacity: 0.7;
+ cursor: not-allowed;
+ transform: none;
+ animation: none;
+}
+
+.publish-submit-btn:disabled:hover {
+ transform: none;
+ box-shadow: 0 8px 25px rgba(45, 80, 22, 0.3);
+}
+
+@keyframes buttonGradient {
+ 0%, 100% {
+ background-position: 0% 50%;
+ }
+ 50% {
+ background-position: 100% 50%;
+ }
+}
+
+/* 加载动画样式 */
+.loading-spinner {
+ width: 20px;
+ height: 20px;
+ border: 3px solid rgba(255, 255, 255, 0.3);
+ border-top: 3px solid white;
+ border-radius: 50%;
+ animation: loadingSpin 1s linear infinite;
+ margin-right: 12px;
+}
+
+@keyframes loadingSpin {
+ 0% {
+ transform: rotate(0deg);
+ }
+ 100% {
+ transform: rotate(360deg);
+ }
+}
+
+/* 提交提示样式 */
+.submit-tips {
+ margin: 20px auto 0;
+ color: #4a7c59;
+ font-size: 14px;
+ font-style: italic;
+ padding: 15px;
+ background: rgba(144, 238, 144, 0.1);
+ border-radius: 15px;
+ border: 1px solid rgba(144, 238, 144, 0.2);
+ font-family: 'Lora', serif;
+ line-height: 1.5;
+ position: relative;
+ overflow: hidden;
+ text-align: center;
+ max-width: 350px;
+}
+
+.submit-tips::before {
+ content: '';
+ position: absolute;
+ top: -2px;
+ left: -100%;
+ width: 100%;
+ height: calc(100% + 4px);
+ background: linear-gradient(90deg,
+ transparent 0%,
+ rgba(144, 238, 144, 0.2) 50%,
+ transparent 100%);
+ animation: tipShine 4s ease-in-out infinite;
+}
+
+@keyframes tipShine {
+ 0%, 80%, 100% {
+ left: -100%;
+ }
+ 10%, 70% {
+ left: 100%;
}
}
/* 响应式设计 */
-@media (max-width: 1200px) {
- .emerald-user-bar {
- width: 440px;
- right: 20px;
- }
-
- .emerald-nav-bar {
- margin: 100px 20px 20px;
- padding: 16px 20px;
- grid-template-columns: repeat(6, 1fr);
- }
-
- .emerald-nav-item {
- min-width: 80px;
- padding: 12px 16px;
- }
-}
-
@media (max-width: 768px) {
- .emerald-user-bar {
- position: relative;
- top: 0;
- right: 0;
- width: 100%;
- margin: 20px 0;
- flex-direction: column;
- gap: 16px;
+ .form-grid {
+ grid-template-columns: 1fr;
+ gap: 20px;
}
- .emerald-brand-section {
- margin-right: 0;
- justify-content: center;
+ .publish-form-advanced {
+ padding: 25px;
+ margin: 20px;
}
- .emerald-user-stats {
- flex-direction: column;
- gap: 8px;
- width: 100%;
+ .file-upload-area {
+ padding: 30px 20px;
}
- .emerald-nav-bar {
- margin: 20px 10px;
- padding: 16px;
- grid-template-columns: repeat(4, 1fr);
- gap: 12px;
+ .upload-main-text {
+ font-size: 16px;
}
- .emerald-nav-item {
- min-width: 70px;
- padding: 10px 12px;
- }
-
- .emerald-nav-icon {
- font-size: 24px !important;
- }
-
- .emerald-nav-label {
+ .upload-sub-text {
font-size: 12px;
}
- .emerald-content-section {
- margin: 20px 10px;
- padding: 20px 15px;
+ .publish-submit-btn {
+ padding: 15px 35px;
+ font-size: 16px;
+ min-width: 160px;
}
- .meteor {
- font-size: 14px;
- }
-
- .garden-element {
- font-size: 20px;
- }
-
- .forum-toolbar {
- flex-direction: column;
- gap: 15px;
- padding: 15px 20px;
- }
-
- .search-section {
- width: 100%;
- max-width: none;
- }
-
- .search-input-container {
- max-width: none;
- }
-
- .forum-search-input {
- border-radius: 25px 0 0 25px;
- }
-
- .forum-search-btn {
- border-radius: 0 25px 25px 0;
- padding: 14px 16px;
- }
-
- .forum-post-card {
+ .form-submit-section {
padding: 20px;
- }
-
- .post-header {
- flex-direction: column;
- align-items: flex-start;
- gap: 10px;
- }
-
- .post-footer {
- flex-direction: column;
- align-items: flex-start;
- gap: 10px;
- }
-}
-
-@media (max-width: 480px) {
- .emerald-nav-bar {
- grid-template-columns: repeat(3, 1fr);
- gap: 8px;
- padding: 12px;
- }
-
- .emerald-nav-item {
- min-width: 60px;
- padding: 8px 10px;
- }
-
- .emerald-nav-icon {
- font-size: 20px !important;
- }
-
- .emerald-nav-label {
- font-size: 11px;
- }
-
- .emerald-table-section {
- margin: 20px 10px;
- padding: 20px 15px;
- }
-
- .emerald-table th,
- .emerald-table td {
- padding: 10px 12px;
- font-size: 13px;
- }
-
- .forum-toolbar {
- padding: 12px 15px;
- }
-
- .search-section {
- flex-direction: column;
- gap: 10px;
- }
-
- .forum-search-input {
- border-radius: 20px;
- border: 2px solid rgba(144, 238, 144, 0.3);
- border-bottom: none;
- }
-
- .forum-search-btn {
- border-radius: 20px;
- border: 2px solid rgba(144, 238, 144, 0.3);
- border-top: none;
- width: 100%;
- }
-
- .post-detail-title {
- font-size: 24px;
- }
-
- .post-detail-content {
- font-size: 14px;
- }
-
- .reply-textarea {
- padding: 15px;
- }
-
- .submit-reply-btn {
- padding: 10px 20px;
- font-size: 14px;
+ margin-top: 30px;
}
}