feat(UI): initial working frontend UI

This commit is contained in:
2025-10-09 17:12:55 +13:00
parent e8972cae38
commit 9e61d18bf6
26 changed files with 6885 additions and 3 deletions
+817
View File
@@ -0,0 +1,817 @@
/* Reset and base styles */
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
line-height: 1.6;
color: #333;
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
min-height: 100vh;
}
.container {
max-width: 1200px;
margin: 0 auto;
padding: 20px;
}
/* Header */
header {
text-align: center;
margin-bottom: 40px;
color: white;
position: relative;
}
header h1 {
font-size: 3rem;
font-weight: 700;
margin-bottom: 10px;
text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}
.subtitle {
font-size: 1.2rem;
opacity: 0.9;
font-weight: 300;
}
/* Authentication section */
.auth-section {
margin-top: 20px;
padding: 15px;
background: rgba(255, 255, 255, 0.1);
border-radius: 10px;
backdrop-filter: blur(10px);
border: 1px solid rgba(255, 255, 255, 0.2);
}
.auth-status {
display: flex;
justify-content: space-between;
align-items: center;
flex-wrap: wrap;
gap: 15px;
}
.auth-info {
display: flex;
align-items: center;
gap: 10px;
flex-wrap: wrap;
}
.auth-label {
font-weight: 600;
color: rgba(255, 255, 255, 0.9);
}
.auth-user {
font-weight: 500;
color: white;
background: rgba(255, 255, 255, 0.2);
padding: 4px 8px;
border-radius: 4px;
font-size: 0.9rem;
}
.auth-status-indicator {
font-weight: 600;
padding: 4px 8px;
border-radius: 4px;
font-size: 0.85rem;
}
.auth-status-indicator.connected {
background: rgba(40, 167, 69, 0.2);
color: #28a745;
border: 1px solid rgba(40, 167, 69, 0.3);
}
.auth-status-indicator.disconnected {
background: rgba(220, 53, 69, 0.2);
color: #dc3545;
border: 1px solid rgba(220, 53, 69, 0.3);
}
.auth-actions {
display: flex;
gap: 10px;
}
/* Main content */
main {
background: white;
border-radius: 15px;
padding: 30px;
box-shadow: 0 10px 30px rgba(0,0,0,0.2);
margin-bottom: 30px;
}
/* Download section */
.download-section {
margin-bottom: 40px;
}
.form-container {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
gap: 30px;
margin-bottom: 30px;
}
.form-container-unified {
max-width: 900px;
margin: 0 auto;
}
.form-card {
background: #f8f9fa;
padding: 25px;
border-radius: 10px;
border-left: 4px solid #667eea;
box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}
.form-card-unified {
background: #f8f9fa;
padding: 30px;
border-radius: 10px;
border-left: 4px solid #667eea;
box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}
.form-card h2,
.form-card-unified h2 {
color: #2c3e50;
margin-bottom: 20px;
font-size: 1.5rem;
}
.form-card:nth-child(2) {
border-left-color: #764ba2;
}
/* Form styles */
.download-form {
display: flex;
flex-direction: column;
gap: 15px;
}
.form-group {
display: flex;
flex-direction: column;
}
.form-group label {
margin-bottom: 5px;
font-weight: 600;
color: #555;
}
.form-group input,
.form-group select {
padding: 12px;
border: 2px solid #e1e8ed;
border-radius: 6px;
font-size: 1rem;
transition: border-color 0.3s ease;
}
.form-group input:focus,
.form-group select:focus {
outline: none;
border-color: #667eea;
box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}
/* Form layout enhancements */
.form-row {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 15px;
}
.form-section {
margin-top: 25px;
padding-top: 20px;
border-top: 1px solid #e9ecef;
}
.form-section h4 {
color: #2c3e50;
font-size: 1.1rem;
margin-bottom: 15px;
display: flex;
align-items: center;
gap: 8px;
}
.form-help {
font-size: 0.85rem;
color: #666;
margin-top: 4px;
line-height: 1.4;
}
/* Checkbox styles */
.checkbox-group {
display: flex;
flex-direction: column;
gap: 12px;
}
.checkbox-label {
display: flex;
align-items: center;
cursor: pointer;
font-weight: 500;
padding: 8px;
border-radius: 6px;
transition: background-color 0.2s ease;
}
.checkbox-label:hover {
background-color: #f0f2f5;
}
.checkbox-label input[type="checkbox"] {
display: none;
}
.checkmark {
width: 20px;
height: 20px;
border: 2px solid #ddd;
border-radius: 4px;
margin-right: 10px;
position: relative;
transition: all 0.2s ease;
}
.checkbox-label input[type="checkbox"]:checked + .checkmark {
background-color: #667eea;
border-color: #667eea;
}
.checkbox-label input[type="checkbox"]:checked + .checkmark::after {
content: '✓';
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
color: white;
font-size: 14px;
font-weight: bold;
}
/* Radio button styles */
.radio-group {
display: flex;
flex-direction: column;
gap: 10px;
}
.radio-label {
display: flex;
align-items: center;
cursor: pointer;
font-weight: 500;
padding: 8px;
border-radius: 6px;
transition: background-color 0.2s ease;
}
.radio-label:hover {
background-color: #f0f2f5;
}
.radio-label input[type="radio"] {
display: none;
}
.radio-custom {
width: 20px;
height: 20px;
border: 2px solid #ddd;
border-radius: 50%;
margin-right: 10px;
position: relative;
transition: all 0.2s ease;
}
.radio-label input[type="radio"]:checked + .radio-custom {
border-color: #667eea;
}
.radio-label input[type="radio"]:checked + .radio-custom::after {
content: '';
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
width: 10px;
height: 10px;
background-color: #667eea;
border-radius: 50%;
}
/* Mode Selection Styles */
.mode-section {
background: white;
padding: 20px;
border-radius: 8px;
margin-bottom: 25px;
border: 2px solid #e1e8ed;
}
.mode-radio-group {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
gap: 15px;
}
.mode-option {
background: white;
border: 2px solid #e1e8ed;
border-radius: 8px;
padding: 15px 12px;
transition: all 0.3s ease;
position: relative;
}
.mode-option:hover {
background-color: #f8f9fa;
border-color: #667eea;
transform: translateY(-2px);
box-shadow: 0 4px 12px rgba(102, 126, 234, 0.15);
}
.mode-option input[type="radio"]:checked + .radio-custom + .mode-label {
color: #667eea;
}
.mode-option input[type="radio"]:checked {
& ~ * {
border-color: #667eea;
}
}
.mode-option input[type="radio"]:checked + .radio-custom {
border-color: #667eea;
background-color: rgba(102, 126, 234, 0.1);
}
.mode-label {
display: flex;
flex-direction: column;
gap: 4px;
margin-left: 8px;
}
.mode-label strong {
font-size: 1rem;
color: #2c3e50;
}
.mode-label small {
font-size: 0.85rem;
color: #666;
font-weight: normal;
}
/* Tooltip Styles */
[data-tooltip] {
position: relative;
cursor: help;
}
[data-tooltip]::before {
content: attr(data-tooltip);
position: absolute;
bottom: calc(100% + 10px);
left: 50%;
transform: translateX(-50%) scale(0.95);
padding: 10px 15px;
background: #2c3e50;
color: white;
border-radius: 6px;
font-size: 0.85rem;
font-weight: 400;
line-height: 1.4;
white-space: normal;
width: max-content;
max-width: 280px;
opacity: 0;
pointer-events: none;
transition: all 0.2s ease;
z-index: 1000;
box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
[data-tooltip]::after {
content: '';
position: absolute;
bottom: calc(100% + 4px);
left: 50%;
transform: translateX(-50%) scale(0.95);
border: 6px solid transparent;
border-top-color: #2c3e50;
opacity: 0;
pointer-events: none;
transition: all 0.2s ease;
z-index: 1000;
}
[data-tooltip]:hover::before,
[data-tooltip]:hover::after {
opacity: 1;
transform: translateX(-50%) scale(1);
}
/* Button variations */
.btn-small {
padding: 8px 16px;
font-size: 0.9rem;
}
.btn-outline {
background: transparent;
border: 2px solid #6c757d;
color: #6c757d;
}
.btn-outline:hover {
background: #6c757d;
color: white;
}
/* Empty state styling */
.empty-state {
text-align: center;
padding: 40px 20px;
color: #666;
}
.empty-icon {
font-size: 3rem;
margin-bottom: 15px;
opacity: 0.5;
}
.empty-state p {
margin-bottom: 8px;
}
/* Downloads header */
.downloads-header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 15px;
}
/* Buttons */
.btn {
padding: 12px 24px;
border: none;
border-radius: 6px;
font-size: 1rem;
font-weight: 600;
cursor: pointer;
transition: all 0.3s ease;
text-transform: uppercase;
letter-spacing: 0.5px;
}
.btn-primary {
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
color: white;
}
.btn-primary:hover {
transform: translateY(-2px);
box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}
.btn-secondary {
background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
color: white;
}
.btn-secondary:hover {
transform: translateY(-2px);
box-shadow: 0 5px 15px rgba(118, 75, 162, 0.4);
}
/* Progress section */
.progress-section {
margin-bottom: 40px;
}
.progress-section h2 {
color: #2c3e50;
margin-bottom: 20px;
font-size: 1.8rem;
}
.progress-container {
background: #f8f9fa;
border-radius: 10px;
padding: 20px;
min-height: 100px;
display: flex;
align-items: center;
justify-content: center;
}
.no-downloads {
text-align: center;
color: #666;
}
.no-downloads p {
margin-bottom: 10px;
}
/* Downloads list */
.downloads-list {
background: #f8f9fa;
border-radius: 10px;
padding: 20px;
}
.downloads-list h3 {
margin-bottom: 15px;
color: #2c3e50;
}
.downloads-items {
display: flex;
flex-direction: column;
gap: 15px;
}
/* Progress card */
.progress-card {
background: white;
padding: 20px;
border-radius: 8px;
border-left: 4px solid #28a745;
box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
.progress-card.downloading {
border-left-color: #ffc107;
animation: pulse 2s infinite;
}
.progress-card.running {
border-left-color: #ffc107;
animation: pulse 2s infinite;
}
.progress-card.completed {
border-left-color: #28a745;
}
.progress-card.failed {
border-left-color: #dc3545;
}
.progress-card.error {
border-left-color: #dc3545;
}
.progress-header {
display: flex;
justify-content: between;
align-items: center;
margin-bottom: 15px;
}
.progress-info h4 {
color: #2c3e50;
margin-bottom: 5px;
}
.progress-meta {
font-size: 0.9rem;
color: #666;
}
.progress-status {
font-weight: 600;
padding: 4px 8px;
border-radius: 4px;
font-size: 0.8rem;
}
.status-starting {
background: #e7f3ff;
color: #0066cc;
}
.status-downloading {
background: #fff3cd;
color: #856404;
}
.status-completed {
background: #d4edda;
color: #155724;
}
.status-error {
background: #f8d7da;
color: #721c24;
}
/* Progress bar */
.progress-bar-container {
margin-bottom: 10px;
}
.progress-bar {
width: 100%;
height: 8px;
background: #e9ecef;
border-radius: 4px;
overflow: hidden;
}
.progress-fill {
height: 100%;
background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
border-radius: 4px;
transition: width 0.3s ease;
}
.progress-text {
font-size: 0.9rem;
color: #666;
margin-bottom: 8px;
}
.progress-details {
font-size: 0.8rem;
color: #888;
margin-top: 8px;
}
.progress-details div {
margin-bottom: 2px;
}
.progress-phase {
font-size: 0.85rem;
color: #555;
font-weight: 500;
margin-top: 4px;
}
.current-item {
font-size: 0.85rem;
color: #007bff;
font-weight: 500;
margin-top: 4px;
padding: 4px 8px;
background-color: rgba(0, 123, 255, 0.1);
border-radius: 4px;
border-left: 3px solid #007bff;
}
/* Progress controls buttons */
.progress-controls {
display: flex;
gap: 8px;
align-items: center;
}
.btn-retry {
padding: 6px 12px;
background: #ffc107;
color: #000;
border: none;
border-radius: 4px;
font-size: 0.85rem;
font-weight: 600;
cursor: pointer;
transition: all 0.2s ease;
text-transform: uppercase;
letter-spacing: 0.5px;
}
.btn-retry:hover {
background: #ffca2c;
transform: translateY(-1px);
box-shadow: 0 2px 8px rgba(255, 193, 7, 0.4);
}
.btn-retry:active {
transform: translateY(0);
}
/* Status section */
.status-section {
margin-bottom: 30px;
}
.status-card {
background: #f8f9fa;
padding: 20px;
border-radius: 10px;
border-left: 4px solid #17a2b8;
}
.status-card h3 {
color: #2c3e50;
margin-bottom: 15px;
}
.status-item {
display: flex;
justify-content: space-between;
margin-bottom: 10px;
padding: 8px 0;
border-bottom: 1px solid #e9ecef;
}
.status-item:last-child {
border-bottom: none;
}
.status-label {
font-weight: 600;
color: #555;
}
.status-value {
font-weight: 500;
}
.status-online {
color: #28a745;
}
.status-offline {
color: #dc3545;
}
/* Footer */
footer {
text-align: center;
color: white;
opacity: 0.8;
}
/* Animations */
@keyframes pulse {
0% { box-shadow: 0 2px 8px rgba(0,0,0,0.1); }
50% { box-shadow: 0 4px 16px rgba(255, 193, 7, 0.3); }
100% { box-shadow: 0 2px 8px rgba(0,0,0,0.1); }
}
/* Responsive design */
@media (max-width: 768px) {
.container {
padding: 15px;
}
header h1 {
font-size: 2.5rem;
}
.form-container {
grid-template-columns: 1fr;
}
.form-card {
margin-bottom: 20px;
}
.status-item {
flex-direction: column;
align-items: flex-start;
gap: 5px;
}
}
@media (max-width: 480px) {
header h1 {
font-size: 2rem;
}
main {
padding: 20px;
}
.form-card {
padding: 20px;
}
}
File diff suppressed because it is too large Load Diff