디자인 다크 모드 수정
This commit is contained in:
485
settings.h
485
settings.h
@@ -9,352 +9,211 @@ const char settings_html[] PROGMEM = R"rawliteral(
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
|
||||
<title>Settings - Byun CAN Logger</title>
|
||||
<style>
|
||||
* { margin: 0; padding: 0; box-sizing: border-box; }
|
||||
:root {
|
||||
--bg: #0e1117;
|
||||
--panel: #161b24;
|
||||
--card: #1c2230;
|
||||
--border: #2d3748;
|
||||
--accent: #43cea2;
|
||||
--green: #3fb950;
|
||||
--blue: #58a6ff;
|
||||
--red: #f85149;
|
||||
--yellow: #e3b341;
|
||||
--purple: #bc8cff;
|
||||
--text: #e6edf3;
|
||||
--muted: #8b949e;
|
||||
--r: 8px;
|
||||
}
|
||||
* { margin:0; padding:0; box-sizing:border-box; }
|
||||
html, body { min-height:100%; }
|
||||
body {
|
||||
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
|
||||
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
|
||||
min-height: 100vh;
|
||||
padding: 10px;
|
||||
}
|
||||
.container {
|
||||
max-width: 800px;
|
||||
margin: 0 auto;
|
||||
background: white;
|
||||
border-radius: 15px;
|
||||
box-shadow: 0 20px 60px rgba(0,0,0,0.3);
|
||||
overflow: hidden;
|
||||
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
|
||||
background: var(--bg); color: var(--text);
|
||||
overflow-x: hidden; font-size: 14px;
|
||||
}
|
||||
|
||||
/* Header */
|
||||
.header {
|
||||
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
|
||||
color: #666;
|
||||
padding: 20px;
|
||||
text-align: center;
|
||||
background: linear-gradient(135deg,#1a2744 0%,#1e1a3a 100%);
|
||||
padding: 11px 16px; border-bottom: 1px solid var(--border);
|
||||
display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
|
||||
}
|
||||
.header h1 { font-size: 1.8em; margin-bottom: 5px; }
|
||||
.header p { opacity: 0.9; font-size: 0.9em; }
|
||||
/* ========== 통일된 네비게이션 ========== */
|
||||
.nav {
|
||||
background: #f8f9fa;
|
||||
padding: 0;
|
||||
border-bottom: 2px solid #e0e0e0;
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
.header h1 {
|
||||
font-size: 1.0em; font-weight: 700; color: var(--accent);
|
||||
display: flex; align-items: center; gap: 8px;
|
||||
}
|
||||
|
||||
.nav a {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
padding: 15px 20px;
|
||||
text-decoration: none;
|
||||
color: #666;
|
||||
font-weight: 500;
|
||||
font-size: 0.95em;
|
||||
border-bottom: 3px solid transparent;
|
||||
transition: all 0.3s;
|
||||
.header p { font-size: 0.78em; color: var(--muted); margin:0; }
|
||||
.badge {
|
||||
background: rgba(67,206,162,.15); color: var(--accent);
|
||||
padding: 2px 8px; border-radius: 12px; font-size: 0.65em;
|
||||
font-weight: 600; border: 1px solid rgba(67,206,162,.3);
|
||||
white-space: nowrap;
|
||||
min-width: 120px;
|
||||
}
|
||||
|
||||
.nav a:hover {
|
||||
background: #e9ecef;
|
||||
color: #667eea;
|
||||
transform: translateY(-2px);
|
||||
.header-spacer { flex:1; }
|
||||
|
||||
/* Nav */
|
||||
.nav {
|
||||
background: var(--panel); border-bottom: 1px solid var(--border);
|
||||
display: flex; overflow-x: auto; -webkit-overflow-scrolling: touch;
|
||||
scrollbar-width: none;
|
||||
}
|
||||
|
||||
.nav a.active {
|
||||
color: #764ba2;
|
||||
border-bottom-color: #764ba2;
|
||||
background: white;
|
||||
font-weight: 600;
|
||||
.nav::-webkit-scrollbar { display:none; }
|
||||
.nav a {
|
||||
display: inline-flex; align-items: center;
|
||||
padding: 10px 13px; text-decoration: none; color: var(--muted);
|
||||
font-size: 0.78em; font-weight: 500;
|
||||
border-bottom: 2px solid transparent; white-space: nowrap;
|
||||
transition: color .2s, border-color .2s;
|
||||
}
|
||||
.content { padding: 30px; }
|
||||
|
||||
.settings-section {
|
||||
background: #f8f9fa;
|
||||
padding: 25px;
|
||||
border-radius: 10px;
|
||||
margin-bottom: 20px;
|
||||
box-shadow: 0 2px 8px rgba(0,0,0,0.05);
|
||||
.nav a:hover { color: var(--text); }
|
||||
.nav a.active { color: var(--accent); border-bottom-color: var(--accent); }
|
||||
|
||||
/* Content */
|
||||
.content { padding: 12px; }
|
||||
|
||||
/* Headings */
|
||||
h2 {
|
||||
color: var(--accent); margin: 14px 0 10px;
|
||||
font-size: 0.82em; font-weight: 700; text-transform: uppercase;
|
||||
letter-spacing: .5px; padding-bottom: 6px;
|
||||
border-bottom: 1px solid var(--border);
|
||||
}
|
||||
|
||||
.section-title {
|
||||
color: #333;
|
||||
font-size: 1.3em;
|
||||
margin-bottom: 20px;
|
||||
padding-bottom: 10px;
|
||||
border-bottom: 3px solid #667eea;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 10px;
|
||||
h3 {
|
||||
color: var(--text); font-size: 0.85em; font-weight: 600;
|
||||
margin-bottom: 10px; padding-bottom: 6px;
|
||||
border-bottom: 1px solid var(--border);
|
||||
}
|
||||
|
||||
.form-group {
|
||||
margin-bottom: 20px;
|
||||
|
||||
/* Buttons */
|
||||
.btn, button {
|
||||
padding: 6px 13px; border: 1px solid var(--border);
|
||||
border-radius: var(--r); background: var(--bg); color: var(--muted);
|
||||
font-size: 0.8em; font-weight: 600; cursor: pointer;
|
||||
font-family: inherit; transition: all .15s; white-space: nowrap;
|
||||
-webkit-tap-highlight-color: transparent; touch-action: manipulation;
|
||||
}
|
||||
|
||||
.form-group:last-child {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.btn:hover, button:hover { border-color: var(--accent); color: var(--accent); }
|
||||
.btn:active, button:active { transform: scale(.97); }
|
||||
.btn-primary { border-color:var(--blue); color:var(--blue); }
|
||||
.btn-success { border-color:var(--accent); color:var(--accent); }
|
||||
.btn-danger { border-color:var(--red); color:var(--red); }
|
||||
.btn-warning { border-color:var(--yellow); color:var(--yellow); }
|
||||
.btn-secondary{ border-color:var(--muted); color:var(--muted); }
|
||||
.btn-primary:hover { background:rgba(88,166,255,.10); }
|
||||
.btn-success:hover { background:rgba(67,206,162,.10); }
|
||||
.btn-danger:hover { background:rgba(248,81,73,.10); }
|
||||
.btn-warning:hover { background:rgba(227,179,65,.10); }
|
||||
.btn-secondary:hover{ background:rgba(139,148,158,.10); }
|
||||
.btn-small { padding:4px 9px; font-size:.75em; }
|
||||
.button-group, .btn-group { display:flex; gap:6px; flex-wrap:wrap; margin-top:10px; }
|
||||
|
||||
/* Forms */
|
||||
label {
|
||||
display: block;
|
||||
font-weight: 600;
|
||||
color: #333;
|
||||
margin-bottom: 8px;
|
||||
font-size: 0.95em;
|
||||
display:block; font-weight:600; color:var(--muted);
|
||||
margin-bottom:4px; font-size:.78em;
|
||||
text-transform:uppercase; letter-spacing:.3px;
|
||||
}
|
||||
|
||||
.help-text {
|
||||
font-size: 0.85em;
|
||||
color: #666;
|
||||
margin-top: 5px;
|
||||
line-height: 1.4;
|
||||
input[type="text"], input[type="password"], input[type="number"],
|
||||
select, textarea {
|
||||
width:100%; padding:7px 10px;
|
||||
border:1px solid var(--border); border-radius:var(--r);
|
||||
font-size:.85em; font-family:inherit;
|
||||
background:var(--bg); color:var(--text);
|
||||
transition:border-color .2s;
|
||||
}
|
||||
|
||||
input[type="text"],
|
||||
input[type="password"] {
|
||||
width: 100%;
|
||||
padding: 12px 15px;
|
||||
border: 2px solid #e1e8ed;
|
||||
border-radius: 8px;
|
||||
font-size: 0.95em;
|
||||
transition: all 0.3s;
|
||||
background: white;
|
||||
input:focus, select:focus, textarea:focus {
|
||||
outline:none; border-color:var(--accent);
|
||||
box-shadow:0 0 0 2px rgba(67,206,162,.10);
|
||||
}
|
||||
|
||||
input[type="text"]:focus,
|
||||
input[type="password"]:focus {
|
||||
outline: none;
|
||||
border-color: #667eea;
|
||||
box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
|
||||
input[type="checkbox"], input[type="radio"] {
|
||||
width:15px; height:15px; cursor:pointer; accent-color:var(--accent);
|
||||
}
|
||||
|
||||
input[type="checkbox"] {
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
cursor: pointer;
|
||||
margin-right: 10px;
|
||||
select option { background:var(--panel); color:var(--text); }
|
||||
|
||||
/* Panels */
|
||||
.section, .settings-section, .send-panel, .stats,
|
||||
.control-panel, .auto-trigger-section {
|
||||
background:var(--panel); border:1px solid var(--border);
|
||||
border-radius:var(--r); padding:13px; margin-bottom:10px;
|
||||
}
|
||||
|
||||
.checkbox-group {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-bottom: 15px;
|
||||
.form-group { margin-bottom:12px; }
|
||||
.form-group:last-child { margin-bottom:0; }
|
||||
.help-text { font-size:.76em; color:var(--muted); margin-top:4px; line-height:1.4; }
|
||||
.form-row {
|
||||
display:grid;
|
||||
grid-template-columns:repeat(auto-fit,minmax(min(100%,190px),1fr));
|
||||
gap:10px; margin-bottom:10px;
|
||||
}
|
||||
|
||||
.checkbox-group label {
|
||||
margin-bottom: 0;
|
||||
cursor: pointer;
|
||||
user-select: none;
|
||||
.form-row label { text-transform:none; font-size:.78em; }
|
||||
.checkbox-group, .checkbox-row {
|
||||
display:flex; align-items:center; gap:8px;
|
||||
margin-bottom:8px; padding:7px 10px;
|
||||
background:var(--card); border-radius:6px; border:1px solid var(--border);
|
||||
}
|
||||
|
||||
.sta-settings {
|
||||
background: #f0f4f8;
|
||||
padding: 20px;
|
||||
border-radius: 8px;
|
||||
margin-top: 15px;
|
||||
border-left: 4px solid #667eea;
|
||||
.checkbox-group label, .checkbox-row label {
|
||||
text-transform:none; cursor:pointer; margin-bottom:0;
|
||||
color:var(--text); font-size:.85em; letter-spacing:0;
|
||||
}
|
||||
|
||||
.sta-settings.disabled {
|
||||
opacity: 0.5;
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
.button-group {
|
||||
display: flex;
|
||||
gap: 15px;
|
||||
margin-top: 30px;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
button {
|
||||
flex: 1;
|
||||
min-width: 150px;
|
||||
padding: 14px 28px;
|
||||
border: none;
|
||||
border-radius: 8px;
|
||||
font-size: 1em;
|
||||
font-weight: 700;
|
||||
cursor: pointer;
|
||||
transition: all 0.3s;
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 0.5px;
|
||||
}
|
||||
|
||||
.btn-save {
|
||||
background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
|
||||
color: #666;
|
||||
box-shadow: 0 4px 15px rgba(17, 153, 142, 0.3);
|
||||
}
|
||||
|
||||
.btn-save:hover {
|
||||
transform: translateY(-2px);
|
||||
box-shadow: 0 6px 20px rgba(17, 153, 142, 0.4);
|
||||
}
|
||||
|
||||
.btn-cancel {
|
||||
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
|
||||
color: #666;
|
||||
box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
|
||||
}
|
||||
|
||||
.btn-cancel:hover {
|
||||
transform: translateY(-2px);
|
||||
box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
|
||||
}
|
||||
|
||||
button:active {
|
||||
transform: translateY(0);
|
||||
}
|
||||
|
||||
|
||||
/* Alerts */
|
||||
.alert {
|
||||
padding: 15px 20px;
|
||||
border-radius: 8px;
|
||||
margin-bottom: 20px;
|
||||
display: none;
|
||||
align-items: center;
|
||||
gap: 12px;
|
||||
animation: slideDown 0.3s ease-out;
|
||||
padding:9px 13px; border-radius:var(--r);
|
||||
margin-bottom:10px; display:none;
|
||||
align-items:center; gap:9px;
|
||||
font-size:.83em; font-weight:600;
|
||||
border:1px solid var(--border); background:var(--panel); color:var(--text);
|
||||
}
|
||||
|
||||
@keyframes slideDown {
|
||||
from {
|
||||
opacity: 0;
|
||||
transform: translateY(-10px);
|
||||
}
|
||||
to {
|
||||
opacity: 1;
|
||||
transform: translateY(0);
|
||||
}
|
||||
.alert.show { display:flex; }
|
||||
.alert-success { border-color:rgba(67,206,162,.4); color:var(--accent); background:rgba(67,206,162,.07); }
|
||||
.alert-info { border-color:rgba(88,166,255,.4); color:var(--blue); background:rgba(88,166,255,.07); }
|
||||
.alert-warning { border-color:rgba(227,179,65,.4); color:var(--yellow); background:rgba(227,179,65,.07); }
|
||||
.alert-icon { font-size:1.15em; }
|
||||
.alert-text { flex:1; }
|
||||
@keyframes slideDown { from{opacity:0;transform:translateY(-6px);}to{opacity:1;transform:translateY(0);} }
|
||||
|
||||
/* Connection status */
|
||||
.connection-status {
|
||||
position:fixed; top:10px; right:10px;
|
||||
padding:4px 11px; border-radius:20px;
|
||||
font-size:.75em; font-weight:600; z-index:1000;
|
||||
border:1px solid var(--border); background:var(--panel); color:var(--muted);
|
||||
}
|
||||
|
||||
.alert.show {
|
||||
display: flex;
|
||||
.connection-status.connected { border-color:rgba(67,206,162,.5); color:var(--accent); background:rgba(67,206,162,.08); }
|
||||
.connection-status.disconnected { border-color:rgba(248,81,73,.5); color:var(--red); background:rgba(248,81,73,.08); }
|
||||
|
||||
@media (max-width:480px) { .content{padding:8px;} h2{font-size:.78em;} }
|
||||
|
||||
/* settings.h specific */
|
||||
.section-title {
|
||||
color:var(--accent); font-size:.85em; font-weight:700;
|
||||
margin-bottom:14px; padding-bottom:7px; border-bottom:1px solid var(--border);
|
||||
display:flex; align-items:center; gap:7px;
|
||||
text-transform:uppercase; letter-spacing:.4px;
|
||||
}
|
||||
|
||||
.alert-success {
|
||||
background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
|
||||
color: #666;
|
||||
.sta-settings {
|
||||
background:var(--card); padding:13px; border-radius:var(--r);
|
||||
margin-top:10px; border:1px solid var(--border); border-left:3px solid var(--blue);
|
||||
}
|
||||
|
||||
.alert-info {
|
||||
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.alert-warning {
|
||||
background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.alert-icon {
|
||||
font-size: 1.5em;
|
||||
}
|
||||
|
||||
.alert-text {
|
||||
flex: 1;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.sta-settings.disabled { opacity:.4; pointer-events:none; }
|
||||
.btn-save { border-color:var(--accent); color:var(--accent); flex:1; min-width:130px; padding:9px 18px; }
|
||||
.btn-save:hover { background:rgba(67,206,162,.10); }
|
||||
.btn-cancel { border-color:var(--muted); color:var(--muted); flex:1; min-width:130px; padding:9px 18px; }
|
||||
.btn-cancel:hover { background:rgba(139,148,158,.10); }
|
||||
.info-box {
|
||||
background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
|
||||
border-left: 4px solid #667eea;
|
||||
padding: 15px 20px;
|
||||
border-radius: 8px;
|
||||
margin-top: 15px;
|
||||
}
|
||||
|
||||
.info-box-title {
|
||||
font-weight: 700;
|
||||
color: #333;
|
||||
margin-bottom: 8px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
.info-box-text {
|
||||
color: #555;
|
||||
font-size: 0.9em;
|
||||
line-height: 1.6;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/* ========== 반응형 디자인 ========== */
|
||||
@media (max-width: 768px) {
|
||||
body {
|
||||
padding: 5px;
|
||||
}
|
||||
|
||||
.container {
|
||||
border-radius: 10px;
|
||||
}
|
||||
|
||||
.header {
|
||||
padding: 15px;
|
||||
flex-direction: column;
|
||||
text-align: center;
|
||||
gap: 10px;
|
||||
}
|
||||
|
||||
.header h1 {
|
||||
font-size: 1.4em;
|
||||
}
|
||||
|
||||
.nav {
|
||||
padding: 5px;
|
||||
}
|
||||
|
||||
.nav a {
|
||||
padding: 12px 15px;
|
||||
font-size: 0.85em;
|
||||
}
|
||||
|
||||
.content {
|
||||
padding: 15px;
|
||||
}
|
||||
|
||||
.btn {
|
||||
padding: 10px 20px;
|
||||
font-size: 13px;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-width: 769px) and (max-width: 1024px) {
|
||||
.header h1 {
|
||||
font-size: 1.6em;
|
||||
}
|
||||
|
||||
.nav a {
|
||||
padding: 13px 18px;
|
||||
font-size: 0.9em;
|
||||
}
|
||||
|
||||
.content {
|
||||
padding: 25px;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-width: 1025px) {
|
||||
.content {
|
||||
padding: 30px;
|
||||
}
|
||||
background:rgba(88,166,255,.06); border:1px solid rgba(88,166,255,.2);
|
||||
border-left:3px solid var(--blue); padding:11px 13px; border-radius:var(--r); margin-top:10px;
|
||||
}
|
||||
.info-box-title { font-weight:700; color:var(--blue); margin-bottom:5px; display:flex; align-items:center; gap:5px; font-size:.83em; }
|
||||
.info-box-text { color:var(--muted); font-size:.80em; line-height:1.6; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="container">
|
||||
<div class="header">
|
||||
<div class="header">
|
||||
<h1>⚙️ Settings</h1>
|
||||
<p>Configure WiFi and System Settings</p>
|
||||
</div>
|
||||
|
||||
<div class="nav">
|
||||
<div class="nav">
|
||||
<a href="/">📊 Monitor</a>
|
||||
<a href="/transmit">📤 Transmit</a>
|
||||
<a href="/graph">📈 Graph</a>
|
||||
@@ -364,7 +223,7 @@ const char settings_html[] PROGMEM = R"rawliteral(
|
||||
<a href="/serial2">📟 Serial2</a>
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
<div class="content">
|
||||
<div id="alert-success" class="alert alert-success">
|
||||
<span class="alert-icon">✓</span>
|
||||
<span class="alert-text">Settings saved successfully!</span>
|
||||
@@ -420,7 +279,7 @@ const char settings_html[] PROGMEM = R"rawliteral(
|
||||
<div class="help-text">외부 WiFi 비밀번호</div>
|
||||
</div>
|
||||
|
||||
<div id="sta-status" style="display: none; margin-top: 15px; padding: 12px; background: #e8f5e9; border-radius: 6px; color: #2e7d32; font-weight: 600;">
|
||||
<div id="sta-status" style="display:none;margin-top:9px;padding:8px 12px;background:rgba(67,206,162,.10);border-radius:6px;color:var(--accent);font-weight:600;border:1px solid rgba(67,206,162,.2);">
|
||||
✓ WiFi 연결됨: <span id="sta-ip"></span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user