update admin light/dark mode
This commit is contained in:
+228
-86
@@ -1,33 +1,88 @@
|
|||||||
|
/* ═══════════════════════════════════════════════════
|
||||||
|
WebGIS P01 — main.css | Dark / Light Theme
|
||||||
|
═══════════════════════════════════════════════════ */
|
||||||
|
|
||||||
|
/* ── Design Tokens ── */
|
||||||
:root {
|
:root {
|
||||||
--primary: #6366F1;
|
--ease: cubic-bezier(0.4, 0, 0.2, 1);
|
||||||
--primary-hover: #4F46E5;
|
--transition: all 0.25s var(--ease);
|
||||||
--bg-dark: #0F172A;
|
|
||||||
--bg-glass: rgba(15, 23, 42, 0.75);
|
|
||||||
--border-glass: rgba(255, 255, 255, 0.1);
|
|
||||||
--text-light: #F8FAFC;
|
|
||||||
--text-muted: #94A3B8;
|
|
||||||
--radius: 20px;
|
|
||||||
--shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
|
|
||||||
--font: 'Inter', sans-serif;
|
--font: 'Inter', sans-serif;
|
||||||
|
--radius: 16px;
|
||||||
}
|
}
|
||||||
|
|
||||||
* { box-sizing: border-box; }
|
/* ── Dark Theme (default) ── */
|
||||||
|
[data-theme="dark"] {
|
||||||
|
--primary: #818CF8;
|
||||||
|
--primary-deep: #6366F1;
|
||||||
|
--primary-glow: rgba(99,102,241,0.3);
|
||||||
|
--bg-dark: #0A0F1E;
|
||||||
|
--bg-glass: rgba(17,24,39,0.82);
|
||||||
|
--bg-input: rgba(255,255,255,0.05);
|
||||||
|
--border-glass: rgba(255,255,255,0.08);
|
||||||
|
--border-focus: #6366F1;
|
||||||
|
--text-main: #F1F5F9;
|
||||||
|
--text-muted: #94A3B8;
|
||||||
|
--shadow: 0 25px 50px -12px rgba(0,0,0,0.55);
|
||||||
|
--dot-color: rgba(255,255,255,0.025);
|
||||||
|
--btn-spbu: #10B981;
|
||||||
|
--btn-jalan: #F59E0B;
|
||||||
|
--btn-kavling: #3B82F6;
|
||||||
|
--btn-rumah: #8B5CF6;
|
||||||
|
--btn-warga: #EF4444;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Light Theme ── */
|
||||||
|
[data-theme="light"] {
|
||||||
|
--primary: #4F46E5;
|
||||||
|
--primary-deep: #3730A3;
|
||||||
|
--primary-glow: rgba(79,70,229,0.15);
|
||||||
|
--bg-dark: #F0F4FF;
|
||||||
|
--bg-glass: rgba(255,255,255,0.92);
|
||||||
|
--bg-input: #FFFFFF;
|
||||||
|
--border-glass: #E2E8F0;
|
||||||
|
--border-focus: #4F46E5;
|
||||||
|
--text-main: #0F172A;
|
||||||
|
--text-muted: #64748B;
|
||||||
|
--shadow: 0 25px 50px -12px rgba(79,70,229,0.12);
|
||||||
|
--dot-color: rgba(79,70,229,0.035);
|
||||||
|
--btn-spbu: #059669;
|
||||||
|
--btn-jalan: #D97706;
|
||||||
|
--btn-kavling: #2563EB;
|
||||||
|
--btn-rumah: #7C3AED;
|
||||||
|
--btn-warga: #DC2626;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Reset ── */
|
||||||
|
*, *::before, *::after { box-sizing: border-box; }
|
||||||
|
|
||||||
body {
|
body {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
font-family: var(--font);
|
font-family: var(--font);
|
||||||
background: var(--bg-dark);
|
background: var(--bg-dark);
|
||||||
color: var(--text-light);
|
color: var(--text-main);
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
transition: background 0.3s var(--ease), color 0.3s var(--ease);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Dot grid background */
|
||||||
|
body::before {
|
||||||
|
content: '';
|
||||||
|
position: fixed;
|
||||||
|
inset: 0;
|
||||||
|
background-image: radial-gradient(circle, var(--dot-color) 1px, transparent 1px);
|
||||||
|
background-size: 28px 28px;
|
||||||
|
pointer-events: none;
|
||||||
|
z-index: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Map ── */
|
||||||
#map {
|
#map {
|
||||||
width: 100vw;
|
width: 100vw;
|
||||||
height: 100vh;
|
height: 100vh;
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Floating Dock */
|
/* ── Floating Dock ── */
|
||||||
.floating-dock {
|
.floating-dock {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 24px;
|
top: 24px;
|
||||||
@@ -37,90 +92,178 @@ body {
|
|||||||
backdrop-filter: blur(24px);
|
backdrop-filter: blur(24px);
|
||||||
-webkit-backdrop-filter: blur(24px);
|
-webkit-backdrop-filter: blur(24px);
|
||||||
border: 1px solid var(--border-glass);
|
border: 1px solid var(--border-glass);
|
||||||
border-radius: var(--radius);
|
border-radius: 20px;
|
||||||
padding: 24px;
|
padding: 20px;
|
||||||
width: 340px;
|
width: 320px;
|
||||||
box-shadow: var(--shadow);
|
box-shadow: var(--shadow);
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
gap: 20px;
|
gap: 16px;
|
||||||
max-height: calc(100vh - 48px);
|
max-height: calc(100vh - 48px);
|
||||||
overflow-y: auto;
|
overflow-y: auto;
|
||||||
|
transition: background 0.3s var(--ease), border-color 0.3s var(--ease);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Custom Scrollbar for Dock */
|
.floating-dock::-webkit-scrollbar { width: 4px; }
|
||||||
.floating-dock::-webkit-scrollbar { width: 6px; }
|
.floating-dock::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.15); border-radius: 10px; }
|
||||||
.floating-dock::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.2); border-radius: 10px; }
|
|
||||||
|
|
||||||
.header h2 { margin: 0 0 8px 0; font-size: 1.4rem; font-weight: 700; background: linear-gradient(135deg, #818CF8, #C084FC); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
|
/* ── Dock Top Bar ── */
|
||||||
.header p { margin: 0; font-size: 0.85rem; color: var(--text-muted); line-height: 1.5; }
|
.dock-topbar {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: space-between;
|
||||||
|
gap: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
/* Buttons */
|
.btn-back-portal {
|
||||||
.menu-group { display: flex; flex-direction: column; gap: 10px; }
|
display: inline-flex;
|
||||||
.menu-title { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 1px; color: var(--text-muted); font-weight: 600; margin-bottom: 4px; }
|
align-items: center;
|
||||||
|
gap: 6px;
|
||||||
|
padding: 5px 10px;
|
||||||
|
border-radius: 8px;
|
||||||
|
border: 1px solid var(--border-glass);
|
||||||
|
background: var(--bg-input);
|
||||||
|
color: var(--text-muted);
|
||||||
|
font-size: 0.72rem;
|
||||||
|
font-weight: 500;
|
||||||
|
cursor: pointer;
|
||||||
|
text-decoration: none;
|
||||||
|
transition: var(--transition);
|
||||||
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
.btn-back-portal:hover {
|
||||||
|
background: var(--primary-deep);
|
||||||
|
border-color: var(--primary-deep);
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
.dock-controls {
|
||||||
|
display: flex;
|
||||||
|
gap: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn-theme-dock {
|
||||||
|
width: 30px;
|
||||||
|
height: 30px;
|
||||||
|
border-radius: 8px;
|
||||||
|
border: 1px solid var(--border-glass);
|
||||||
|
background: var(--bg-input);
|
||||||
|
color: var(--text-muted);
|
||||||
|
cursor: pointer;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
font-size: 0.8rem;
|
||||||
|
transition: var(--transition);
|
||||||
|
}
|
||||||
|
.btn-theme-dock:hover {
|
||||||
|
background: var(--primary-deep);
|
||||||
|
border-color: var(--primary-deep);
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Header ── */
|
||||||
|
.header h2 {
|
||||||
|
margin: 0 0 6px 0;
|
||||||
|
font-size: 1.25rem;
|
||||||
|
font-weight: 700;
|
||||||
|
background: linear-gradient(135deg, var(--primary), #C084FC);
|
||||||
|
-webkit-background-clip: text;
|
||||||
|
-webkit-text-fill-color: transparent;
|
||||||
|
background-clip: text;
|
||||||
|
}
|
||||||
|
.header p {
|
||||||
|
margin: 0;
|
||||||
|
font-size: 0.8rem;
|
||||||
|
color: var(--text-muted);
|
||||||
|
line-height: 1.5;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Buttons ── */
|
||||||
|
.menu-group { display: flex; flex-direction: column; gap: 8px; }
|
||||||
|
.menu-title {
|
||||||
|
font-size: 0.7rem;
|
||||||
|
text-transform: uppercase;
|
||||||
|
letter-spacing: 0.08em;
|
||||||
|
color: var(--text-muted);
|
||||||
|
font-weight: 700;
|
||||||
|
margin-bottom: 2px;
|
||||||
|
}
|
||||||
|
|
||||||
.btn-action {
|
.btn-action {
|
||||||
background: rgba(255, 255, 255, 0.05);
|
background: var(--bg-input);
|
||||||
border: 1px solid var(--border-glass);
|
border: 1px solid var(--border-glass);
|
||||||
color: var(--text-light);
|
color: var(--text-main);
|
||||||
padding: 14px 16px;
|
padding: 11px 14px;
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
font-family: var(--font);
|
font-family: var(--font);
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 12px;
|
gap: 10px;
|
||||||
transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
transition: var(--transition);
|
||||||
font-size: 0.9rem;
|
font-size: 0.875rem;
|
||||||
text-align: left;
|
text-align: left;
|
||||||
}
|
}
|
||||||
|
|
||||||
.btn-action svg { width: 20px; height: 20px; flex-shrink: 0; }
|
.btn-action svg { width: 18px; height: 18px; flex-shrink: 0; }
|
||||||
|
|
||||||
.btn-action:hover {
|
.btn-action:hover {
|
||||||
background: rgba(255, 255, 255, 0.1);
|
background: rgba(255,255,255,0.08);
|
||||||
transform: translateX(4px);
|
transform: translateX(3px);
|
||||||
|
border-color: var(--primary);
|
||||||
|
}
|
||||||
|
|
||||||
|
[data-theme="light"] .btn-action:hover {
|
||||||
|
background: #EEF2FF;
|
||||||
}
|
}
|
||||||
|
|
||||||
.btn-action.active {
|
.btn-action.active {
|
||||||
background: var(--primary);
|
background: var(--primary-deep);
|
||||||
border-color: var(--primary);
|
border-color: var(--primary-deep);
|
||||||
box-shadow: 0 10px 15px -3px rgba(99, 102, 241, 0.4);
|
color: white;
|
||||||
|
box-shadow: 0 4px 12px var(--primary-glow);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Button Variants */
|
/* Button color variants */
|
||||||
.btn-spbu svg { color: #10B981; }
|
.btn-spbu svg { color: var(--btn-spbu); }
|
||||||
.btn-jalan svg { color: #F59E0B; }
|
.btn-jalan svg { color: var(--btn-jalan); }
|
||||||
.btn-kavling svg { color: #3B82F6; }
|
.btn-kavling svg { color: var(--btn-kavling); }
|
||||||
.btn-rumah svg { color: #8B5CF6; }
|
.btn-rumah svg { color: var(--btn-rumah); }
|
||||||
.btn-warga svg { color: #EF4444; }
|
.btn-warga svg { color: var(--btn-warga); }
|
||||||
|
|
||||||
/* Form Panel */
|
/* ── Form Panel ── */
|
||||||
.form-panel {
|
.form-panel {
|
||||||
background: rgba(0, 0, 0, 0.4);
|
background: rgba(0,0,0,0.3);
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
padding: 16px;
|
padding: 14px;
|
||||||
border: 1px solid var(--border-glass);
|
border: 1px solid var(--border-glass);
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
gap: 12px;
|
gap: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.form-group { display: flex; flex-direction: column; gap: 6px; }
|
[data-theme="light"] .form-panel {
|
||||||
.form-group label { font-size: 0.8rem; color: var(--text-muted); }
|
background: rgba(79,70,229,0.04);
|
||||||
|
}
|
||||||
|
|
||||||
|
.form-group { display: flex; flex-direction: column; gap: 5px; }
|
||||||
|
.form-group label { font-size: 0.78rem; color: var(--text-muted); font-weight: 500; }
|
||||||
|
|
||||||
.form-control {
|
.form-control {
|
||||||
background: rgba(255, 255, 255, 0.05);
|
background: var(--bg-input);
|
||||||
border: 1px solid var(--border-glass);
|
border: 1px solid var(--border-glass);
|
||||||
padding: 10px 12px;
|
padding: 9px 12px;
|
||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
color: white;
|
color: var(--text-main);
|
||||||
font-family: var(--font);
|
font-family: var(--font);
|
||||||
font-size: 0.9rem;
|
font-size: 0.875rem;
|
||||||
outline: none;
|
outline: none;
|
||||||
transition: border 0.2s;
|
transition: border 0.2s;
|
||||||
}
|
}
|
||||||
.form-control:focus { border-color: var(--primary); }
|
.form-control:focus { border-color: var(--border-focus); box-shadow: 0 0 0 3px var(--primary-glow); }
|
||||||
|
.form-control::placeholder { color: var(--text-muted); }
|
||||||
|
|
||||||
.checkbox-group {
|
.checkbox-group {
|
||||||
display: flex;
|
display: flex;
|
||||||
@@ -128,78 +271,77 @@ body {
|
|||||||
gap: 8px;
|
gap: 8px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
.checkbox-group input { width: 16px; height: 16px; accent-color: var(--primary); cursor: pointer; }
|
.checkbox-group input { width: 15px; height: 15px; accent-color: var(--primary); cursor: pointer; }
|
||||||
.checkbox-group span { font-size: 0.85rem; color: var(--text-light); }
|
.checkbox-group span { font-size: 0.82rem; color: var(--text-main); }
|
||||||
|
|
||||||
.btn-submit {
|
.btn-submit {
|
||||||
background: var(--primary);
|
background: var(--primary-deep);
|
||||||
color: white;
|
color: white;
|
||||||
border: none;
|
border: none;
|
||||||
padding: 12px;
|
padding: 11px;
|
||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
|
font-family: var(--font);
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
transition: background 0.2s;
|
transition: var(--transition);
|
||||||
|
font-size: 0.875rem;
|
||||||
}
|
}
|
||||||
.btn-submit:hover { background: var(--primary-hover); }
|
.btn-submit:hover { filter: brightness(1.1); transform: translateY(-1px); }
|
||||||
|
|
||||||
/* Leaflet Customizations */
|
/* ── Leaflet Customizations ── */
|
||||||
.leaflet-draw-toolbar { display: none !important; }
|
.leaflet-draw-toolbar { display: none !important; }
|
||||||
.leaflet-control-zoom { border: none !important; box-shadow: var(--shadow) !important; }
|
.leaflet-control-zoom { border: none !important; box-shadow: var(--shadow) !important; }
|
||||||
.leaflet-control-zoom a {
|
.leaflet-control-zoom a {
|
||||||
background: var(--bg-glass) !important;
|
background: var(--bg-glass) !important;
|
||||||
color: var(--text-light) !important;
|
color: var(--text-main) !important;
|
||||||
border-color: var(--border-glass) !important;
|
border-color: var(--border-glass) !important;
|
||||||
backdrop-filter: blur(10px);
|
backdrop-filter: blur(10px);
|
||||||
}
|
}
|
||||||
.leaflet-control-zoom a:hover { background: var(--primary) !important; }
|
.leaflet-control-zoom a:hover { background: var(--primary-deep) !important; color: white !important; }
|
||||||
|
|
||||||
/* Leaflet Popup Premium */
|
|
||||||
.leaflet-popup-content-wrapper {
|
.leaflet-popup-content-wrapper {
|
||||||
background: var(--bg-glass) !important;
|
background: var(--bg-glass) !important;
|
||||||
backdrop-filter: blur(16px) !important;
|
backdrop-filter: blur(16px) !important;
|
||||||
border: 1px solid var(--border-glass) !important;
|
border: 1px solid var(--border-glass) !important;
|
||||||
color: var(--text-light) !important;
|
color: var(--text-main) !important;
|
||||||
border-radius: 16px !important;
|
border-radius: 14px !important;
|
||||||
box-shadow: var(--shadow) !important;
|
box-shadow: var(--shadow) !important;
|
||||||
}
|
}
|
||||||
.leaflet-popup-tip { background: var(--bg-glass) !important; border: 1px solid var(--border-glass) !important; }
|
.leaflet-popup-tip { background: var(--bg-glass) !important; }
|
||||||
.leaflet-popup-content { margin: 16px !important; font-family: var(--font); }
|
.leaflet-popup-content { margin: 14px !important; font-family: var(--font); }
|
||||||
.leaflet-popup-content h3 { margin: 0 0 8px 0; font-size: 1.1rem; border-bottom: 1px solid var(--border-glass); padding-bottom: 8px; }
|
.leaflet-popup-content h3 { margin: 0 0 8px 0; font-size: 1rem; border-bottom: 1px solid var(--border-glass); padding-bottom: 8px; }
|
||||||
.leaflet-popup-content p { margin: 4px 0; font-size: 0.9rem; color: var(--text-muted); }
|
.leaflet-popup-content p { margin: 4px 0; font-size: 0.85rem; color: var(--text-muted); }
|
||||||
|
|
||||||
.leaflet-popup-content .btn-delete {
|
.leaflet-popup-content .btn-delete {
|
||||||
background: rgba(239, 68, 68, 0.1);
|
background: rgba(239,68,68,0.1);
|
||||||
color: #EF4444;
|
color: #EF4444;
|
||||||
border: 1px solid rgba(239, 68, 68, 0.3);
|
border: 1px solid rgba(239,68,68,0.3);
|
||||||
padding: 6px 12px;
|
padding: 6px 12px;
|
||||||
border-radius: 6px;
|
border-radius: 6px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
margin-top: 12px;
|
margin-top: 10px;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
transition: all 0.2s;
|
font-family: var(--font);
|
||||||
|
font-size: 0.85rem;
|
||||||
|
transition: var(--transition);
|
||||||
}
|
}
|
||||||
.leaflet-popup-content .btn-delete:hover { background: #EF4444; color: white; }
|
.leaflet-popup-content .btn-delete:hover { background: #EF4444; color: white; }
|
||||||
|
|
||||||
/* Custom Map Marker Icon Animation */
|
/* ── Toast ── */
|
||||||
.custom-icon div {
|
|
||||||
transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
|
||||||
}
|
|
||||||
.custom-icon:hover div {
|
|
||||||
transform: scale(1.1) translateY(-4px);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Toast Notification */
|
|
||||||
.toast-container {
|
.toast-container {
|
||||||
position: fixed; bottom: 24px; right: 24px; z-index: 9999;
|
position: fixed; bottom: 24px; right: 24px; z-index: 9999;
|
||||||
display: flex; flex-direction: column; gap: 10px;
|
display: flex; flex-direction: column; gap: 10px;
|
||||||
}
|
}
|
||||||
.toast {
|
.toast {
|
||||||
background: var(--bg-glass); backdrop-filter: blur(16px);
|
background: var(--bg-glass); backdrop-filter: blur(16px);
|
||||||
border: 1px solid var(--border-glass); border-left: 4px solid var(--primary);
|
border: 1px solid var(--border-glass); border-left: 4px solid var(--primary-deep);
|
||||||
padding: 16px 20px; border-radius: 12px; color: white; font-size: 0.9rem;
|
padding: 14px 18px; border-radius: 12px; color: var(--text-main); font-size: 0.875rem;
|
||||||
box-shadow: var(--shadow); animation: slideIn 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
box-shadow: var(--shadow); animation: slideIn 0.3s var(--ease);
|
||||||
}
|
}
|
||||||
.toast.error { border-left-color: #EF4444; }
|
.toast.error { border-left-color: #EF4444; }
|
||||||
.toast.success { border-left-color: #10B981; }
|
.toast.success { border-left-color: #10B981; }
|
||||||
|
|
||||||
@keyframes slideIn { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
|
@keyframes slideIn {
|
||||||
|
from { transform: translateX(100%); opacity: 0; }
|
||||||
|
to { transform: translateX(0); opacity: 1; }
|
||||||
|
}
|
||||||
|
|||||||
+43
-8
@@ -1,26 +1,44 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="id">
|
<html lang="id" data-theme="dark">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<title>WebGIS - Pertemuan 01</title>
|
<title>WebGIS — Pertemuan 01: Geometri Dasar</title>
|
||||||
|
<meta name="description" content="Modul 01 — Menggambar dan mengelola geometri spasial (titik, garis, poligon) berbasis WebGIS.">
|
||||||
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap" rel="stylesheet">
|
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap" rel="stylesheet">
|
||||||
<link rel="stylesheet" href="https://unpkg.com/leaflet@1.9.4/dist/leaflet.css" />
|
<link rel="stylesheet" href="https://unpkg.com/leaflet@1.9.4/dist/leaflet.css" />
|
||||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/leaflet.draw/1.0.4/leaflet.draw.css" />
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/leaflet.draw/1.0.4/leaflet.draw.css" />
|
||||||
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.0/css/all.min.css">
|
||||||
<link rel="stylesheet" href="css/main.css">
|
<link rel="stylesheet" href="css/main.css">
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
<!-- Peta -->
|
<!-- Map container -->
|
||||||
<div id="map"></div>
|
<div id="map"></div>
|
||||||
|
|
||||||
<!-- Floating Dock -->
|
<!-- Floating Dock -->
|
||||||
<div class="floating-dock">
|
<div class="floating-dock">
|
||||||
<div class="header">
|
|
||||||
<h2>P01: Geometri</h2>
|
<!-- Dock top bar: back + theme toggle -->
|
||||||
<p>Sistem Informasi Geografis dengan arsitektur modern.</p>
|
<div class="dock-topbar">
|
||||||
|
<a href="../../portal.html" class="btn-back-portal" title="Kembali ke Portal">
|
||||||
|
<i class="fas fa-chevron-left"></i>
|
||||||
|
Portal
|
||||||
|
</a>
|
||||||
|
<div class="dock-controls">
|
||||||
|
<button class="btn-theme-dock" id="themeToggle" title="Toggle tema" aria-label="Toggle dark/light mode">
|
||||||
|
<i class="fas fa-moon" id="themeIcon"></i>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- Header -->
|
||||||
|
<div class="header">
|
||||||
|
<h2>P01: Geometri Dasar</h2>
|
||||||
|
<p>Sistem Informasi Geografis — CRUD spasial titik, garis, dan area.</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Spatial tools -->
|
||||||
<div class="menu-group">
|
<div class="menu-group">
|
||||||
<div class="menu-title">Alat Spasial</div>
|
<div class="menu-title">Alat Spasial</div>
|
||||||
|
|
||||||
@@ -40,16 +58,33 @@
|
|||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- Dynamic Form Container -->
|
<!-- Dynamic form container -->
|
||||||
<div id="form-container" style="display: none;"></div>
|
<div id="form-container" style="display: none;"></div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- Toast Notification Container -->
|
<!-- Toast -->
|
||||||
<div id="toast-container" class="toast-container"></div>
|
<div id="toast-container" class="toast-container"></div>
|
||||||
|
|
||||||
<script src="https://unpkg.com/leaflet@1.9.4/dist/leaflet.js"></script>
|
<script src="https://unpkg.com/leaflet@1.9.4/dist/leaflet.js"></script>
|
||||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/leaflet.draw/1.0.4/leaflet.draw.js"></script>
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/leaflet.draw/1.0.4/leaflet.draw.js"></script>
|
||||||
|
<script>
|
||||||
|
// ── Theme toggle ──
|
||||||
|
const html = document.documentElement;
|
||||||
|
const btn = document.getElementById('themeToggle');
|
||||||
|
const icon = document.getElementById('themeIcon');
|
||||||
|
const saved = localStorage.getItem('portal-theme') || 'dark';
|
||||||
|
setTheme(saved);
|
||||||
|
btn.addEventListener('click', () => {
|
||||||
|
const next = html.getAttribute('data-theme') === 'dark' ? 'light' : 'dark';
|
||||||
|
setTheme(next);
|
||||||
|
localStorage.setItem('portal-theme', next);
|
||||||
|
});
|
||||||
|
function setTheme(t) {
|
||||||
|
html.setAttribute('data-theme', t);
|
||||||
|
icon.className = t === 'dark' ? 'fas fa-sun' : 'fas fa-moon';
|
||||||
|
}
|
||||||
|
</script>
|
||||||
<script type="module" src="js/app.js"></script>
|
<script type="module" src="js/app.js"></script>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
|
|||||||
@@ -14,12 +14,27 @@ export const initMap = (containerId) => {
|
|||||||
position: 'bottomright'
|
position: 'bottomright'
|
||||||
}).addTo(map);
|
}).addTo(map);
|
||||||
|
|
||||||
// Tile Layer Premium (CartoDB Dark Matter untuk Glass UI)
|
const isDark = document.documentElement.getAttribute('data-theme') === 'dark';
|
||||||
L.tileLayer('https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png', {
|
const tileUrl = isDark
|
||||||
|
? 'https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png'
|
||||||
|
: 'https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png';
|
||||||
|
|
||||||
|
// Tile Layer Premium (CartoDB Dark Matter / Light All)
|
||||||
|
const tileLayer = L.tileLayer(tileUrl, {
|
||||||
attribution: '© <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors © <a href="https://carto.com/attributions">CARTO</a>',
|
attribution: '© <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors © <a href="https://carto.com/attributions">CARTO</a>',
|
||||||
subdomains: 'abcd',
|
subdomains: 'abcd',
|
||||||
maxZoom: 20
|
maxZoom: 20
|
||||||
}).addTo(map);
|
}).addTo(map);
|
||||||
|
|
||||||
|
// Dynamic theme updater for tile layer
|
||||||
|
const observer = new MutationObserver(() => {
|
||||||
|
const dark = document.documentElement.getAttribute('data-theme') === 'dark';
|
||||||
|
tileLayer.setUrl(dark
|
||||||
|
? 'https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png'
|
||||||
|
: 'https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png'
|
||||||
|
);
|
||||||
|
});
|
||||||
|
observer.observe(document.documentElement, { attributes: true });
|
||||||
|
|
||||||
return map;
|
return map;
|
||||||
};
|
};
|
||||||
|
|||||||
+228
-86
@@ -1,33 +1,88 @@
|
|||||||
|
/* ═══════════════════════════════════════════════════
|
||||||
|
WebGIS P01 — main.css | Dark / Light Theme
|
||||||
|
═══════════════════════════════════════════════════ */
|
||||||
|
|
||||||
|
/* ── Design Tokens ── */
|
||||||
:root {
|
:root {
|
||||||
--primary: #6366F1;
|
--ease: cubic-bezier(0.4, 0, 0.2, 1);
|
||||||
--primary-hover: #4F46E5;
|
--transition: all 0.25s var(--ease);
|
||||||
--bg-dark: #0F172A;
|
|
||||||
--bg-glass: rgba(15, 23, 42, 0.75);
|
|
||||||
--border-glass: rgba(255, 255, 255, 0.1);
|
|
||||||
--text-light: #F8FAFC;
|
|
||||||
--text-muted: #94A3B8;
|
|
||||||
--radius: 20px;
|
|
||||||
--shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
|
|
||||||
--font: 'Inter', sans-serif;
|
--font: 'Inter', sans-serif;
|
||||||
|
--radius: 16px;
|
||||||
}
|
}
|
||||||
|
|
||||||
* { box-sizing: border-box; }
|
/* ── Dark Theme (default) ── */
|
||||||
|
[data-theme="dark"] {
|
||||||
|
--primary: #818CF8;
|
||||||
|
--primary-deep: #6366F1;
|
||||||
|
--primary-glow: rgba(99,102,241,0.3);
|
||||||
|
--bg-dark: #0A0F1E;
|
||||||
|
--bg-glass: rgba(17,24,39,0.82);
|
||||||
|
--bg-input: rgba(255,255,255,0.05);
|
||||||
|
--border-glass: rgba(255,255,255,0.08);
|
||||||
|
--border-focus: #6366F1;
|
||||||
|
--text-main: #F1F5F9;
|
||||||
|
--text-muted: #94A3B8;
|
||||||
|
--shadow: 0 25px 50px -12px rgba(0,0,0,0.55);
|
||||||
|
--dot-color: rgba(255,255,255,0.025);
|
||||||
|
--btn-spbu: #10B981;
|
||||||
|
--btn-jalan: #F59E0B;
|
||||||
|
--btn-kavling: #3B82F6;
|
||||||
|
--btn-rumah: #8B5CF6;
|
||||||
|
--btn-warga: #EF4444;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Light Theme ── */
|
||||||
|
[data-theme="light"] {
|
||||||
|
--primary: #4F46E5;
|
||||||
|
--primary-deep: #3730A3;
|
||||||
|
--primary-glow: rgba(79,70,229,0.15);
|
||||||
|
--bg-dark: #F0F4FF;
|
||||||
|
--bg-glass: rgba(255,255,255,0.92);
|
||||||
|
--bg-input: #FFFFFF;
|
||||||
|
--border-glass: #E2E8F0;
|
||||||
|
--border-focus: #4F46E5;
|
||||||
|
--text-main: #0F172A;
|
||||||
|
--text-muted: #64748B;
|
||||||
|
--shadow: 0 25px 50px -12px rgba(79,70,229,0.12);
|
||||||
|
--dot-color: rgba(79,70,229,0.035);
|
||||||
|
--btn-spbu: #059669;
|
||||||
|
--btn-jalan: #D97706;
|
||||||
|
--btn-kavling: #2563EB;
|
||||||
|
--btn-rumah: #7C3AED;
|
||||||
|
--btn-warga: #DC2626;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Reset ── */
|
||||||
|
*, *::before, *::after { box-sizing: border-box; }
|
||||||
|
|
||||||
body {
|
body {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
font-family: var(--font);
|
font-family: var(--font);
|
||||||
background: var(--bg-dark);
|
background: var(--bg-dark);
|
||||||
color: var(--text-light);
|
color: var(--text-main);
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
transition: background 0.3s var(--ease), color 0.3s var(--ease);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Dot grid background */
|
||||||
|
body::before {
|
||||||
|
content: '';
|
||||||
|
position: fixed;
|
||||||
|
inset: 0;
|
||||||
|
background-image: radial-gradient(circle, var(--dot-color) 1px, transparent 1px);
|
||||||
|
background-size: 28px 28px;
|
||||||
|
pointer-events: none;
|
||||||
|
z-index: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Map ── */
|
||||||
#map {
|
#map {
|
||||||
width: 100vw;
|
width: 100vw;
|
||||||
height: 100vh;
|
height: 100vh;
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Floating Dock */
|
/* ── Floating Dock ── */
|
||||||
.floating-dock {
|
.floating-dock {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 24px;
|
top: 24px;
|
||||||
@@ -37,90 +92,178 @@ body {
|
|||||||
backdrop-filter: blur(24px);
|
backdrop-filter: blur(24px);
|
||||||
-webkit-backdrop-filter: blur(24px);
|
-webkit-backdrop-filter: blur(24px);
|
||||||
border: 1px solid var(--border-glass);
|
border: 1px solid var(--border-glass);
|
||||||
border-radius: var(--radius);
|
border-radius: 20px;
|
||||||
padding: 24px;
|
padding: 20px;
|
||||||
width: 340px;
|
width: 320px;
|
||||||
box-shadow: var(--shadow);
|
box-shadow: var(--shadow);
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
gap: 20px;
|
gap: 16px;
|
||||||
max-height: calc(100vh - 48px);
|
max-height: calc(100vh - 48px);
|
||||||
overflow-y: auto;
|
overflow-y: auto;
|
||||||
|
transition: background 0.3s var(--ease), border-color 0.3s var(--ease);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Custom Scrollbar for Dock */
|
.floating-dock::-webkit-scrollbar { width: 4px; }
|
||||||
.floating-dock::-webkit-scrollbar { width: 6px; }
|
.floating-dock::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.15); border-radius: 10px; }
|
||||||
.floating-dock::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.2); border-radius: 10px; }
|
|
||||||
|
|
||||||
.header h2 { margin: 0 0 8px 0; font-size: 1.4rem; font-weight: 700; background: linear-gradient(135deg, #818CF8, #C084FC); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
|
/* ── Dock Top Bar ── */
|
||||||
.header p { margin: 0; font-size: 0.85rem; color: var(--text-muted); line-height: 1.5; }
|
.dock-topbar {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: space-between;
|
||||||
|
gap: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
/* Buttons */
|
.btn-back-portal {
|
||||||
.menu-group { display: flex; flex-direction: column; gap: 10px; }
|
display: inline-flex;
|
||||||
.menu-title { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 1px; color: var(--text-muted); font-weight: 600; margin-bottom: 4px; }
|
align-items: center;
|
||||||
|
gap: 6px;
|
||||||
|
padding: 5px 10px;
|
||||||
|
border-radius: 8px;
|
||||||
|
border: 1px solid var(--border-glass);
|
||||||
|
background: var(--bg-input);
|
||||||
|
color: var(--text-muted);
|
||||||
|
font-size: 0.72rem;
|
||||||
|
font-weight: 500;
|
||||||
|
cursor: pointer;
|
||||||
|
text-decoration: none;
|
||||||
|
transition: var(--transition);
|
||||||
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
.btn-back-portal:hover {
|
||||||
|
background: var(--primary-deep);
|
||||||
|
border-color: var(--primary-deep);
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
.dock-controls {
|
||||||
|
display: flex;
|
||||||
|
gap: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn-theme-dock {
|
||||||
|
width: 30px;
|
||||||
|
height: 30px;
|
||||||
|
border-radius: 8px;
|
||||||
|
border: 1px solid var(--border-glass);
|
||||||
|
background: var(--bg-input);
|
||||||
|
color: var(--text-muted);
|
||||||
|
cursor: pointer;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
font-size: 0.8rem;
|
||||||
|
transition: var(--transition);
|
||||||
|
}
|
||||||
|
.btn-theme-dock:hover {
|
||||||
|
background: var(--primary-deep);
|
||||||
|
border-color: var(--primary-deep);
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Header ── */
|
||||||
|
.header h2 {
|
||||||
|
margin: 0 0 6px 0;
|
||||||
|
font-size: 1.25rem;
|
||||||
|
font-weight: 700;
|
||||||
|
background: linear-gradient(135deg, var(--primary), #C084FC);
|
||||||
|
-webkit-background-clip: text;
|
||||||
|
-webkit-text-fill-color: transparent;
|
||||||
|
background-clip: text;
|
||||||
|
}
|
||||||
|
.header p {
|
||||||
|
margin: 0;
|
||||||
|
font-size: 0.8rem;
|
||||||
|
color: var(--text-muted);
|
||||||
|
line-height: 1.5;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Buttons ── */
|
||||||
|
.menu-group { display: flex; flex-direction: column; gap: 8px; }
|
||||||
|
.menu-title {
|
||||||
|
font-size: 0.7rem;
|
||||||
|
text-transform: uppercase;
|
||||||
|
letter-spacing: 0.08em;
|
||||||
|
color: var(--text-muted);
|
||||||
|
font-weight: 700;
|
||||||
|
margin-bottom: 2px;
|
||||||
|
}
|
||||||
|
|
||||||
.btn-action {
|
.btn-action {
|
||||||
background: rgba(255, 255, 255, 0.05);
|
background: var(--bg-input);
|
||||||
border: 1px solid var(--border-glass);
|
border: 1px solid var(--border-glass);
|
||||||
color: var(--text-light);
|
color: var(--text-main);
|
||||||
padding: 14px 16px;
|
padding: 11px 14px;
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
font-family: var(--font);
|
font-family: var(--font);
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 12px;
|
gap: 10px;
|
||||||
transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
transition: var(--transition);
|
||||||
font-size: 0.9rem;
|
font-size: 0.875rem;
|
||||||
text-align: left;
|
text-align: left;
|
||||||
}
|
}
|
||||||
|
|
||||||
.btn-action svg { width: 20px; height: 20px; flex-shrink: 0; }
|
.btn-action svg { width: 18px; height: 18px; flex-shrink: 0; }
|
||||||
|
|
||||||
.btn-action:hover {
|
.btn-action:hover {
|
||||||
background: rgba(255, 255, 255, 0.1);
|
background: rgba(255,255,255,0.08);
|
||||||
transform: translateX(4px);
|
transform: translateX(3px);
|
||||||
|
border-color: var(--primary);
|
||||||
|
}
|
||||||
|
|
||||||
|
[data-theme="light"] .btn-action:hover {
|
||||||
|
background: #EEF2FF;
|
||||||
}
|
}
|
||||||
|
|
||||||
.btn-action.active {
|
.btn-action.active {
|
||||||
background: var(--primary);
|
background: var(--primary-deep);
|
||||||
border-color: var(--primary);
|
border-color: var(--primary-deep);
|
||||||
box-shadow: 0 10px 15px -3px rgba(99, 102, 241, 0.4);
|
color: white;
|
||||||
|
box-shadow: 0 4px 12px var(--primary-glow);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Button Variants */
|
/* Button color variants */
|
||||||
.btn-spbu svg { color: #10B981; }
|
.btn-spbu svg { color: var(--btn-spbu); }
|
||||||
.btn-jalan svg { color: #F59E0B; }
|
.btn-jalan svg { color: var(--btn-jalan); }
|
||||||
.btn-kavling svg { color: #3B82F6; }
|
.btn-kavling svg { color: var(--btn-kavling); }
|
||||||
.btn-rumah svg { color: #8B5CF6; }
|
.btn-rumah svg { color: var(--btn-rumah); }
|
||||||
.btn-warga svg { color: #EF4444; }
|
.btn-warga svg { color: var(--btn-warga); }
|
||||||
|
|
||||||
/* Form Panel */
|
/* ── Form Panel ── */
|
||||||
.form-panel {
|
.form-panel {
|
||||||
background: rgba(0, 0, 0, 0.4);
|
background: rgba(0,0,0,0.3);
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
padding: 16px;
|
padding: 14px;
|
||||||
border: 1px solid var(--border-glass);
|
border: 1px solid var(--border-glass);
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
gap: 12px;
|
gap: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.form-group { display: flex; flex-direction: column; gap: 6px; }
|
[data-theme="light"] .form-panel {
|
||||||
.form-group label { font-size: 0.8rem; color: var(--text-muted); }
|
background: rgba(79,70,229,0.04);
|
||||||
|
}
|
||||||
|
|
||||||
|
.form-group { display: flex; flex-direction: column; gap: 5px; }
|
||||||
|
.form-group label { font-size: 0.78rem; color: var(--text-muted); font-weight: 500; }
|
||||||
|
|
||||||
.form-control {
|
.form-control {
|
||||||
background: rgba(255, 255, 255, 0.05);
|
background: var(--bg-input);
|
||||||
border: 1px solid var(--border-glass);
|
border: 1px solid var(--border-glass);
|
||||||
padding: 10px 12px;
|
padding: 9px 12px;
|
||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
color: white;
|
color: var(--text-main);
|
||||||
font-family: var(--font);
|
font-family: var(--font);
|
||||||
font-size: 0.9rem;
|
font-size: 0.875rem;
|
||||||
outline: none;
|
outline: none;
|
||||||
transition: border 0.2s;
|
transition: border 0.2s;
|
||||||
}
|
}
|
||||||
.form-control:focus { border-color: var(--primary); }
|
.form-control:focus { border-color: var(--border-focus); box-shadow: 0 0 0 3px var(--primary-glow); }
|
||||||
|
.form-control::placeholder { color: var(--text-muted); }
|
||||||
|
|
||||||
.checkbox-group {
|
.checkbox-group {
|
||||||
display: flex;
|
display: flex;
|
||||||
@@ -128,78 +271,77 @@ body {
|
|||||||
gap: 8px;
|
gap: 8px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
.checkbox-group input { width: 16px; height: 16px; accent-color: var(--primary); cursor: pointer; }
|
.checkbox-group input { width: 15px; height: 15px; accent-color: var(--primary); cursor: pointer; }
|
||||||
.checkbox-group span { font-size: 0.85rem; color: var(--text-light); }
|
.checkbox-group span { font-size: 0.82rem; color: var(--text-main); }
|
||||||
|
|
||||||
.btn-submit {
|
.btn-submit {
|
||||||
background: var(--primary);
|
background: var(--primary-deep);
|
||||||
color: white;
|
color: white;
|
||||||
border: none;
|
border: none;
|
||||||
padding: 12px;
|
padding: 11px;
|
||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
|
font-family: var(--font);
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
transition: background 0.2s;
|
transition: var(--transition);
|
||||||
|
font-size: 0.875rem;
|
||||||
}
|
}
|
||||||
.btn-submit:hover { background: var(--primary-hover); }
|
.btn-submit:hover { filter: brightness(1.1); transform: translateY(-1px); }
|
||||||
|
|
||||||
/* Leaflet Customizations */
|
/* ── Leaflet Customizations ── */
|
||||||
.leaflet-draw-toolbar { display: none !important; }
|
.leaflet-draw-toolbar { display: none !important; }
|
||||||
.leaflet-control-zoom { border: none !important; box-shadow: var(--shadow) !important; }
|
.leaflet-control-zoom { border: none !important; box-shadow: var(--shadow) !important; }
|
||||||
.leaflet-control-zoom a {
|
.leaflet-control-zoom a {
|
||||||
background: var(--bg-glass) !important;
|
background: var(--bg-glass) !important;
|
||||||
color: var(--text-light) !important;
|
color: var(--text-main) !important;
|
||||||
border-color: var(--border-glass) !important;
|
border-color: var(--border-glass) !important;
|
||||||
backdrop-filter: blur(10px);
|
backdrop-filter: blur(10px);
|
||||||
}
|
}
|
||||||
.leaflet-control-zoom a:hover { background: var(--primary) !important; }
|
.leaflet-control-zoom a:hover { background: var(--primary-deep) !important; color: white !important; }
|
||||||
|
|
||||||
/* Leaflet Popup Premium */
|
|
||||||
.leaflet-popup-content-wrapper {
|
.leaflet-popup-content-wrapper {
|
||||||
background: var(--bg-glass) !important;
|
background: var(--bg-glass) !important;
|
||||||
backdrop-filter: blur(16px) !important;
|
backdrop-filter: blur(16px) !important;
|
||||||
border: 1px solid var(--border-glass) !important;
|
border: 1px solid var(--border-glass) !important;
|
||||||
color: var(--text-light) !important;
|
color: var(--text-main) !important;
|
||||||
border-radius: 16px !important;
|
border-radius: 14px !important;
|
||||||
box-shadow: var(--shadow) !important;
|
box-shadow: var(--shadow) !important;
|
||||||
}
|
}
|
||||||
.leaflet-popup-tip { background: var(--bg-glass) !important; border: 1px solid var(--border-glass) !important; }
|
.leaflet-popup-tip { background: var(--bg-glass) !important; }
|
||||||
.leaflet-popup-content { margin: 16px !important; font-family: var(--font); }
|
.leaflet-popup-content { margin: 14px !important; font-family: var(--font); }
|
||||||
.leaflet-popup-content h3 { margin: 0 0 8px 0; font-size: 1.1rem; border-bottom: 1px solid var(--border-glass); padding-bottom: 8px; }
|
.leaflet-popup-content h3 { margin: 0 0 8px 0; font-size: 1rem; border-bottom: 1px solid var(--border-glass); padding-bottom: 8px; }
|
||||||
.leaflet-popup-content p { margin: 4px 0; font-size: 0.9rem; color: var(--text-muted); }
|
.leaflet-popup-content p { margin: 4px 0; font-size: 0.85rem; color: var(--text-muted); }
|
||||||
|
|
||||||
.leaflet-popup-content .btn-delete {
|
.leaflet-popup-content .btn-delete {
|
||||||
background: rgba(239, 68, 68, 0.1);
|
background: rgba(239,68,68,0.1);
|
||||||
color: #EF4444;
|
color: #EF4444;
|
||||||
border: 1px solid rgba(239, 68, 68, 0.3);
|
border: 1px solid rgba(239,68,68,0.3);
|
||||||
padding: 6px 12px;
|
padding: 6px 12px;
|
||||||
border-radius: 6px;
|
border-radius: 6px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
margin-top: 12px;
|
margin-top: 10px;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
transition: all 0.2s;
|
font-family: var(--font);
|
||||||
|
font-size: 0.85rem;
|
||||||
|
transition: var(--transition);
|
||||||
}
|
}
|
||||||
.leaflet-popup-content .btn-delete:hover { background: #EF4444; color: white; }
|
.leaflet-popup-content .btn-delete:hover { background: #EF4444; color: white; }
|
||||||
|
|
||||||
/* Custom Map Marker Icon Animation */
|
/* ── Toast ── */
|
||||||
.custom-icon div {
|
|
||||||
transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
|
||||||
}
|
|
||||||
.custom-icon:hover div {
|
|
||||||
transform: scale(1.1) translateY(-4px);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Toast Notification */
|
|
||||||
.toast-container {
|
.toast-container {
|
||||||
position: fixed; bottom: 24px; right: 24px; z-index: 9999;
|
position: fixed; bottom: 24px; right: 24px; z-index: 9999;
|
||||||
display: flex; flex-direction: column; gap: 10px;
|
display: flex; flex-direction: column; gap: 10px;
|
||||||
}
|
}
|
||||||
.toast {
|
.toast {
|
||||||
background: var(--bg-glass); backdrop-filter: blur(16px);
|
background: var(--bg-glass); backdrop-filter: blur(16px);
|
||||||
border: 1px solid var(--border-glass); border-left: 4px solid var(--primary);
|
border: 1px solid var(--border-glass); border-left: 4px solid var(--primary-deep);
|
||||||
padding: 16px 20px; border-radius: 12px; color: white; font-size: 0.9rem;
|
padding: 14px 18px; border-radius: 12px; color: var(--text-main); font-size: 0.875rem;
|
||||||
box-shadow: var(--shadow); animation: slideIn 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
box-shadow: var(--shadow); animation: slideIn 0.3s var(--ease);
|
||||||
}
|
}
|
||||||
.toast.error { border-left-color: #EF4444; }
|
.toast.error { border-left-color: #EF4444; }
|
||||||
.toast.success { border-left-color: #10B981; }
|
.toast.success { border-left-color: #10B981; }
|
||||||
|
|
||||||
@keyframes slideIn { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
|
@keyframes slideIn {
|
||||||
|
from { transform: translateX(100%); opacity: 0; }
|
||||||
|
to { transform: translateX(0); opacity: 1; }
|
||||||
|
}
|
||||||
|
|||||||
+92
-15
@@ -1,50 +1,127 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="id">
|
<html lang="id" data-theme="dark">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<title>WebGIS - Pertemuan 02</title>
|
<title>WebGIS — Pertemuan 02: Haversine & Tematik</title>
|
||||||
|
<meta name="description" content="Modul 02 — Pemetaan sosial dan analisis radius jarak Haversine berbasis WebGIS.">
|
||||||
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap" rel="stylesheet">
|
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap" rel="stylesheet">
|
||||||
<link rel="stylesheet" href="https://unpkg.com/leaflet@1.9.4/dist/leaflet.css" />
|
<link rel="stylesheet" href="https://unpkg.com/leaflet@1.9.4/dist/leaflet.css" />
|
||||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/leaflet.draw/1.0.4/leaflet.draw.css" />
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/leaflet.draw/1.0.4/leaflet.draw.css" />
|
||||||
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.0/css/all.min.css">
|
||||||
<link rel="stylesheet" href="css/main.css">
|
<link rel="stylesheet" href="css/main.css">
|
||||||
<style>
|
<style>
|
||||||
.result-item { background: rgba(255,255,255,0.05); padding: 8px 10px; border-radius: 8px; border: 1px solid var(--border-glass); display: flex; justify-content: space-between; align-items: center; }
|
.result-item {
|
||||||
.badge { background: var(--primary); padding: 2px 6px; border-radius: 12px; font-size: 0.7rem; font-weight: 700; color: white; }
|
background: var(--bg-input);
|
||||||
|
padding: 8px 10px;
|
||||||
|
border-radius: 8px;
|
||||||
|
border: 1px solid var(--border-glass);
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
align-items: center;
|
||||||
|
font-size: 0.82rem;
|
||||||
|
}
|
||||||
|
.badge {
|
||||||
|
background: var(--primary-deep);
|
||||||
|
padding: 2px 8px;
|
||||||
|
border-radius: 12px;
|
||||||
|
font-size: 0.68rem;
|
||||||
|
font-weight: 700;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
|
<!-- Map container -->
|
||||||
<div id="map"></div>
|
<div id="map"></div>
|
||||||
|
|
||||||
|
<!-- Floating Dock -->
|
||||||
<div class="floating-dock">
|
<div class="floating-dock">
|
||||||
|
|
||||||
|
<!-- Dock top bar -->
|
||||||
|
<div class="dock-topbar">
|
||||||
|
<a href="../../portal.html" class="btn-back-portal" title="Kembali ke Portal">
|
||||||
|
<i class="fas fa-chevron-left"></i>
|
||||||
|
Portal
|
||||||
|
</a>
|
||||||
|
<div class="dock-controls">
|
||||||
|
<button class="btn-theme-dock" id="themeToggle" title="Toggle tema" aria-label="Toggle dark/light mode">
|
||||||
|
<i class="fas fa-moon" id="themeIcon"></i>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Header -->
|
||||||
<div class="header">
|
<div class="header">
|
||||||
<h2>P02: Tematik & Jarak</h2>
|
<h2>P02: Tematik & Jarak</h2>
|
||||||
<p>Kumulatif P01 + Analisis radius jarak Haversine.</p>
|
<p>Kumulatif P01 + Analisis radius jarak Haversine.</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- Entitas Dasar (P01) -->
|
||||||
<div class="menu-group">
|
<div class="menu-group">
|
||||||
<div class="menu-title">Entitas Dasar (P01)</div>
|
<div class="menu-title">Entitas Dasar (P01)</div>
|
||||||
<button id="btn-draw-spbu" class="btn-action btn-spbu"><svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M17.657 16.657L13.414 20.9a1.998 1.998 0 01-2.827 0l-4.242-4.243a8 8 0 1111.314 0z"></path><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 11a3 3 0 11-6 0 3 3 0 016 0z"></path></svg> Tambah SPBU</button>
|
<button id="btn-draw-spbu" class="btn-action btn-spbu">
|
||||||
<button id="btn-draw-jalan" class="btn-action btn-jalan"><svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M13 7h8m0 0v8m0-8l-8 8-4-4-6 6"></path></svg> Tambah Jalan</button>
|
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M17.657 16.657L13.414 20.9a1.998 1.998 0 01-2.827 0l-4.242-4.243a8 8 0 1111.314 0z"></path><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 11a3 3 0 11-6 0 3 3 0 016 0z"></path></svg>
|
||||||
<button id="btn-draw-kavling" class="btn-action btn-kavling"><svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M4 6a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2H6a2 2 0 01-2-2V6zM14 6a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2h-2a2 2 0 01-2-2V6zM4 16a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2H6a2 2 0 01-2-2v-2zM14 16a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2h-2a2 2 0 01-2-2v-2z"></path></svg> Tambah Kavling</button>
|
Tambah SPBU
|
||||||
|
</button>
|
||||||
|
<button id="btn-draw-jalan" class="btn-action btn-jalan">
|
||||||
|
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M13 7h8m0 0v8m0-8l-8 8-4-4-6 6"></path></svg>
|
||||||
|
Tambah Jalan
|
||||||
|
</button>
|
||||||
|
<button id="btn-draw-kavling" class="btn-action btn-kavling">
|
||||||
|
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M4 6a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2H6a2 2 0 01-2-2V6zM14 6a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2h-2a2 2 0 01-2-2V6zM4 16a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2H6a2 2 0 01-2-2v-2zM14 16a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2h-2a2 2 0 01-2-2v-2z"></path></svg>
|
||||||
|
Tambah Kavling
|
||||||
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="menu-group" style="margin-top: 5px;">
|
<!-- Entitas Sosial (P02) -->
|
||||||
|
<div class="menu-group" style="margin-top:4px;">
|
||||||
<div class="menu-title">Entitas Sosial (P02)</div>
|
<div class="menu-title">Entitas Sosial (P02)</div>
|
||||||
<button id="btn-draw-rumah" class="btn-action btn-rumah"><svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M3 12l2-2m0 0l7-7 7 7M5 10v10a1 1 0 001 1h3m10-11l2 2m-2-2v10a1 1 0 01-1 1h-3m-6 0a1 1 0 001-1v-4a1 1 0 011-1h2a1 1 0 011 1v4a1 1 0 001 1m-6 0h6"></path></svg> Tambah Rumah Ibadah</button>
|
<button id="btn-draw-rumah" class="btn-action btn-rumah">
|
||||||
<button id="btn-draw-warga" class="btn-action btn-warga"><svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M17 20h5v-2a3 3 0 00-5.356-1.857M17 20H7m10 0v-2c0-.656-.126-1.283-.356-1.857M7 20H2v-2a3 3 0 015.356-1.857M7 20v-2c0-.656.126-1.283.356-1.857m0 0a5.002 5.002 0 019.288 0M15 7a3 3 0 11-6 0 3 3 0 016 0zm6 3a2 2 0 11-4 0 2 2 0 014 0zM7 10a2 2 0 11-4 0 2 2 0 014 0z"></path></svg> Tambah Warga Miskin</button>
|
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M3 12l2-2m0 0l7-7 7 7M5 10v10a1 1 0 001 1h3m10-11l2 2m-2-2v10a1 1 0 01-1 1h-3m-6 0a1 1 0 001-1v-4a1 1 0 011-1h2a1 1 0 011 1v4a1 1 0 001 1m-6 0h6"></path></svg>
|
||||||
|
Tambah Rumah Ibadah
|
||||||
|
</button>
|
||||||
|
<button id="btn-draw-warga" class="btn-action btn-warga">
|
||||||
|
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M17 20h5v-2a3 3 0 00-5.356-1.857M17 20H7m10 0v-2c0-.656-.126-1.283-.356-1.857M7 20H2v-2a3 3 0 015.356-1.857M7 20v-2c0-.656.126-1.283.356-1.857m0 0a5.002 5.002 0 019.288 0M15 7a3 3 0 11-6 0 3 3 0 016 0zm6 3a2 2 0 11-4 0 2 2 0 014 0zM7 10a2 2 0 11-4 0 2 2 0 014 0z"></path></svg>
|
||||||
|
Tambah Warga Miskin
|
||||||
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="instruction-panel" class="form-panel" style="margin-top: 5px;">
|
<!-- Analisis Jarak -->
|
||||||
<h3 style="margin:0 0 5px 0; font-size:0.9rem; color:var(--text-main);">Analisis Jarak</h3>
|
<div id="instruction-panel" class="form-panel" style="margin-top:2px;">
|
||||||
<p style="font-size:0.8rem; margin:0 0 10px 0; color:var(--text-muted);">Klik [Cek Radius] di popup Rumah Ibadah mana pun.</p>
|
<h3 style="margin:0 0 4px 0; font-size:0.85rem; color:var(--text-main); font-weight:600;">Analisis Jarak</h3>
|
||||||
<div id="radius-results" style="max-height:150px; overflow-y:auto; display:flex; flex-direction:column; gap:8px;"></div>
|
<p style="font-size:0.78rem; margin:0 0 8px 0; color:var(--text-muted);">Klik [Cek Radius] di popup Rumah Ibadah mana pun.</p>
|
||||||
|
<div id="radius-results" style="max-height:140px; overflow-y:auto; display:flex; flex-direction:column; gap:6px;"></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- Dynamic form container -->
|
||||||
<div id="form-container" style="display: none;"></div>
|
<div id="form-container" style="display: none;"></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- Toast -->
|
||||||
<div id="toast-container" class="toast-container"></div>
|
<div id="toast-container" class="toast-container"></div>
|
||||||
|
|
||||||
<script src="https://unpkg.com/leaflet@1.9.4/dist/leaflet.js"></script>
|
<script src="https://unpkg.com/leaflet@1.9.4/dist/leaflet.js"></script>
|
||||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/leaflet.draw/1.0.4/leaflet.draw.js"></script>
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/leaflet.draw/1.0.4/leaflet.draw.js"></script>
|
||||||
|
<script>
|
||||||
|
// ── Theme toggle ──
|
||||||
|
const html = document.documentElement;
|
||||||
|
const btn = document.getElementById('themeToggle');
|
||||||
|
const icon = document.getElementById('themeIcon');
|
||||||
|
const saved = localStorage.getItem('portal-theme') || 'dark';
|
||||||
|
setTheme(saved);
|
||||||
|
btn.addEventListener('click', () => {
|
||||||
|
const next = html.getAttribute('data-theme') === 'dark' ? 'light' : 'dark';
|
||||||
|
setTheme(next);
|
||||||
|
localStorage.setItem('portal-theme', next);
|
||||||
|
});
|
||||||
|
function setTheme(t) {
|
||||||
|
html.setAttribute('data-theme', t);
|
||||||
|
icon.className = t === 'dark' ? 'fas fa-sun' : 'fas fa-moon';
|
||||||
|
}
|
||||||
|
</script>
|
||||||
<script type="module" src="js/app.js"></script>
|
<script type="module" src="js/app.js"></script>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
@@ -14,12 +14,27 @@ export const initMap = (containerId) => {
|
|||||||
position: 'bottomright'
|
position: 'bottomright'
|
||||||
}).addTo(map);
|
}).addTo(map);
|
||||||
|
|
||||||
// Tile Layer Premium (CartoDB Dark Matter untuk Glass UI)
|
const isDark = document.documentElement.getAttribute('data-theme') === 'dark';
|
||||||
L.tileLayer('https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png', {
|
const tileUrl = isDark
|
||||||
|
? 'https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png'
|
||||||
|
: 'https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png';
|
||||||
|
|
||||||
|
// Tile Layer Premium (CartoDB Dark Matter / Light All)
|
||||||
|
const tileLayer = L.tileLayer(tileUrl, {
|
||||||
attribution: '© <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors © <a href="https://carto.com/attributions">CARTO</a>',
|
attribution: '© <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors © <a href="https://carto.com/attributions">CARTO</a>',
|
||||||
subdomains: 'abcd',
|
subdomains: 'abcd',
|
||||||
maxZoom: 20
|
maxZoom: 20
|
||||||
}).addTo(map);
|
}).addTo(map);
|
||||||
|
|
||||||
|
// Dynamic theme updater for tile layer
|
||||||
|
const observer = new MutationObserver(() => {
|
||||||
|
const dark = document.documentElement.getAttribute('data-theme') === 'dark';
|
||||||
|
tileLayer.setUrl(dark
|
||||||
|
? 'https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png'
|
||||||
|
: 'https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png'
|
||||||
|
);
|
||||||
|
});
|
||||||
|
observer.observe(document.documentElement, { attributes: true });
|
||||||
|
|
||||||
return map;
|
return map;
|
||||||
};
|
};
|
||||||
|
|||||||
+228
-86
@@ -1,33 +1,88 @@
|
|||||||
|
/* ═══════════════════════════════════════════════════
|
||||||
|
WebGIS P01 — main.css | Dark / Light Theme
|
||||||
|
═══════════════════════════════════════════════════ */
|
||||||
|
|
||||||
|
/* ── Design Tokens ── */
|
||||||
:root {
|
:root {
|
||||||
--primary: #6366F1;
|
--ease: cubic-bezier(0.4, 0, 0.2, 1);
|
||||||
--primary-hover: #4F46E5;
|
--transition: all 0.25s var(--ease);
|
||||||
--bg-dark: #0F172A;
|
|
||||||
--bg-glass: rgba(15, 23, 42, 0.75);
|
|
||||||
--border-glass: rgba(255, 255, 255, 0.1);
|
|
||||||
--text-light: #F8FAFC;
|
|
||||||
--text-muted: #94A3B8;
|
|
||||||
--radius: 20px;
|
|
||||||
--shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
|
|
||||||
--font: 'Inter', sans-serif;
|
--font: 'Inter', sans-serif;
|
||||||
|
--radius: 16px;
|
||||||
}
|
}
|
||||||
|
|
||||||
* { box-sizing: border-box; }
|
/* ── Dark Theme (default) ── */
|
||||||
|
[data-theme="dark"] {
|
||||||
|
--primary: #818CF8;
|
||||||
|
--primary-deep: #6366F1;
|
||||||
|
--primary-glow: rgba(99,102,241,0.3);
|
||||||
|
--bg-dark: #0A0F1E;
|
||||||
|
--bg-glass: rgba(17,24,39,0.82);
|
||||||
|
--bg-input: rgba(255,255,255,0.05);
|
||||||
|
--border-glass: rgba(255,255,255,0.08);
|
||||||
|
--border-focus: #6366F1;
|
||||||
|
--text-main: #F1F5F9;
|
||||||
|
--text-muted: #94A3B8;
|
||||||
|
--shadow: 0 25px 50px -12px rgba(0,0,0,0.55);
|
||||||
|
--dot-color: rgba(255,255,255,0.025);
|
||||||
|
--btn-spbu: #10B981;
|
||||||
|
--btn-jalan: #F59E0B;
|
||||||
|
--btn-kavling: #3B82F6;
|
||||||
|
--btn-rumah: #8B5CF6;
|
||||||
|
--btn-warga: #EF4444;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Light Theme ── */
|
||||||
|
[data-theme="light"] {
|
||||||
|
--primary: #4F46E5;
|
||||||
|
--primary-deep: #3730A3;
|
||||||
|
--primary-glow: rgba(79,70,229,0.15);
|
||||||
|
--bg-dark: #F0F4FF;
|
||||||
|
--bg-glass: rgba(255,255,255,0.92);
|
||||||
|
--bg-input: #FFFFFF;
|
||||||
|
--border-glass: #E2E8F0;
|
||||||
|
--border-focus: #4F46E5;
|
||||||
|
--text-main: #0F172A;
|
||||||
|
--text-muted: #64748B;
|
||||||
|
--shadow: 0 25px 50px -12px rgba(79,70,229,0.12);
|
||||||
|
--dot-color: rgba(79,70,229,0.035);
|
||||||
|
--btn-spbu: #059669;
|
||||||
|
--btn-jalan: #D97706;
|
||||||
|
--btn-kavling: #2563EB;
|
||||||
|
--btn-rumah: #7C3AED;
|
||||||
|
--btn-warga: #DC2626;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Reset ── */
|
||||||
|
*, *::before, *::after { box-sizing: border-box; }
|
||||||
|
|
||||||
body {
|
body {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
font-family: var(--font);
|
font-family: var(--font);
|
||||||
background: var(--bg-dark);
|
background: var(--bg-dark);
|
||||||
color: var(--text-light);
|
color: var(--text-main);
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
transition: background 0.3s var(--ease), color 0.3s var(--ease);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Dot grid background */
|
||||||
|
body::before {
|
||||||
|
content: '';
|
||||||
|
position: fixed;
|
||||||
|
inset: 0;
|
||||||
|
background-image: radial-gradient(circle, var(--dot-color) 1px, transparent 1px);
|
||||||
|
background-size: 28px 28px;
|
||||||
|
pointer-events: none;
|
||||||
|
z-index: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Map ── */
|
||||||
#map {
|
#map {
|
||||||
width: 100vw;
|
width: 100vw;
|
||||||
height: 100vh;
|
height: 100vh;
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Floating Dock */
|
/* ── Floating Dock ── */
|
||||||
.floating-dock {
|
.floating-dock {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 24px;
|
top: 24px;
|
||||||
@@ -37,90 +92,178 @@ body {
|
|||||||
backdrop-filter: blur(24px);
|
backdrop-filter: blur(24px);
|
||||||
-webkit-backdrop-filter: blur(24px);
|
-webkit-backdrop-filter: blur(24px);
|
||||||
border: 1px solid var(--border-glass);
|
border: 1px solid var(--border-glass);
|
||||||
border-radius: var(--radius);
|
border-radius: 20px;
|
||||||
padding: 24px;
|
padding: 20px;
|
||||||
width: 340px;
|
width: 320px;
|
||||||
box-shadow: var(--shadow);
|
box-shadow: var(--shadow);
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
gap: 20px;
|
gap: 16px;
|
||||||
max-height: calc(100vh - 48px);
|
max-height: calc(100vh - 48px);
|
||||||
overflow-y: auto;
|
overflow-y: auto;
|
||||||
|
transition: background 0.3s var(--ease), border-color 0.3s var(--ease);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Custom Scrollbar for Dock */
|
.floating-dock::-webkit-scrollbar { width: 4px; }
|
||||||
.floating-dock::-webkit-scrollbar { width: 6px; }
|
.floating-dock::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.15); border-radius: 10px; }
|
||||||
.floating-dock::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.2); border-radius: 10px; }
|
|
||||||
|
|
||||||
.header h2 { margin: 0 0 8px 0; font-size: 1.4rem; font-weight: 700; background: linear-gradient(135deg, #818CF8, #C084FC); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
|
/* ── Dock Top Bar ── */
|
||||||
.header p { margin: 0; font-size: 0.85rem; color: var(--text-muted); line-height: 1.5; }
|
.dock-topbar {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: space-between;
|
||||||
|
gap: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
/* Buttons */
|
.btn-back-portal {
|
||||||
.menu-group { display: flex; flex-direction: column; gap: 10px; }
|
display: inline-flex;
|
||||||
.menu-title { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 1px; color: var(--text-muted); font-weight: 600; margin-bottom: 4px; }
|
align-items: center;
|
||||||
|
gap: 6px;
|
||||||
|
padding: 5px 10px;
|
||||||
|
border-radius: 8px;
|
||||||
|
border: 1px solid var(--border-glass);
|
||||||
|
background: var(--bg-input);
|
||||||
|
color: var(--text-muted);
|
||||||
|
font-size: 0.72rem;
|
||||||
|
font-weight: 500;
|
||||||
|
cursor: pointer;
|
||||||
|
text-decoration: none;
|
||||||
|
transition: var(--transition);
|
||||||
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
.btn-back-portal:hover {
|
||||||
|
background: var(--primary-deep);
|
||||||
|
border-color: var(--primary-deep);
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
.dock-controls {
|
||||||
|
display: flex;
|
||||||
|
gap: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn-theme-dock {
|
||||||
|
width: 30px;
|
||||||
|
height: 30px;
|
||||||
|
border-radius: 8px;
|
||||||
|
border: 1px solid var(--border-glass);
|
||||||
|
background: var(--bg-input);
|
||||||
|
color: var(--text-muted);
|
||||||
|
cursor: pointer;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
font-size: 0.8rem;
|
||||||
|
transition: var(--transition);
|
||||||
|
}
|
||||||
|
.btn-theme-dock:hover {
|
||||||
|
background: var(--primary-deep);
|
||||||
|
border-color: var(--primary-deep);
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Header ── */
|
||||||
|
.header h2 {
|
||||||
|
margin: 0 0 6px 0;
|
||||||
|
font-size: 1.25rem;
|
||||||
|
font-weight: 700;
|
||||||
|
background: linear-gradient(135deg, var(--primary), #C084FC);
|
||||||
|
-webkit-background-clip: text;
|
||||||
|
-webkit-text-fill-color: transparent;
|
||||||
|
background-clip: text;
|
||||||
|
}
|
||||||
|
.header p {
|
||||||
|
margin: 0;
|
||||||
|
font-size: 0.8rem;
|
||||||
|
color: var(--text-muted);
|
||||||
|
line-height: 1.5;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Buttons ── */
|
||||||
|
.menu-group { display: flex; flex-direction: column; gap: 8px; }
|
||||||
|
.menu-title {
|
||||||
|
font-size: 0.7rem;
|
||||||
|
text-transform: uppercase;
|
||||||
|
letter-spacing: 0.08em;
|
||||||
|
color: var(--text-muted);
|
||||||
|
font-weight: 700;
|
||||||
|
margin-bottom: 2px;
|
||||||
|
}
|
||||||
|
|
||||||
.btn-action {
|
.btn-action {
|
||||||
background: rgba(255, 255, 255, 0.05);
|
background: var(--bg-input);
|
||||||
border: 1px solid var(--border-glass);
|
border: 1px solid var(--border-glass);
|
||||||
color: var(--text-light);
|
color: var(--text-main);
|
||||||
padding: 14px 16px;
|
padding: 11px 14px;
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
font-family: var(--font);
|
font-family: var(--font);
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 12px;
|
gap: 10px;
|
||||||
transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
transition: var(--transition);
|
||||||
font-size: 0.9rem;
|
font-size: 0.875rem;
|
||||||
text-align: left;
|
text-align: left;
|
||||||
}
|
}
|
||||||
|
|
||||||
.btn-action svg { width: 20px; height: 20px; flex-shrink: 0; }
|
.btn-action svg { width: 18px; height: 18px; flex-shrink: 0; }
|
||||||
|
|
||||||
.btn-action:hover {
|
.btn-action:hover {
|
||||||
background: rgba(255, 255, 255, 0.1);
|
background: rgba(255,255,255,0.08);
|
||||||
transform: translateX(4px);
|
transform: translateX(3px);
|
||||||
|
border-color: var(--primary);
|
||||||
|
}
|
||||||
|
|
||||||
|
[data-theme="light"] .btn-action:hover {
|
||||||
|
background: #EEF2FF;
|
||||||
}
|
}
|
||||||
|
|
||||||
.btn-action.active {
|
.btn-action.active {
|
||||||
background: var(--primary);
|
background: var(--primary-deep);
|
||||||
border-color: var(--primary);
|
border-color: var(--primary-deep);
|
||||||
box-shadow: 0 10px 15px -3px rgba(99, 102, 241, 0.4);
|
color: white;
|
||||||
|
box-shadow: 0 4px 12px var(--primary-glow);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Button Variants */
|
/* Button color variants */
|
||||||
.btn-spbu svg { color: #10B981; }
|
.btn-spbu svg { color: var(--btn-spbu); }
|
||||||
.btn-jalan svg { color: #F59E0B; }
|
.btn-jalan svg { color: var(--btn-jalan); }
|
||||||
.btn-kavling svg { color: #3B82F6; }
|
.btn-kavling svg { color: var(--btn-kavling); }
|
||||||
.btn-rumah svg { color: #8B5CF6; }
|
.btn-rumah svg { color: var(--btn-rumah); }
|
||||||
.btn-warga svg { color: #EF4444; }
|
.btn-warga svg { color: var(--btn-warga); }
|
||||||
|
|
||||||
/* Form Panel */
|
/* ── Form Panel ── */
|
||||||
.form-panel {
|
.form-panel {
|
||||||
background: rgba(0, 0, 0, 0.4);
|
background: rgba(0,0,0,0.3);
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
padding: 16px;
|
padding: 14px;
|
||||||
border: 1px solid var(--border-glass);
|
border: 1px solid var(--border-glass);
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
gap: 12px;
|
gap: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.form-group { display: flex; flex-direction: column; gap: 6px; }
|
[data-theme="light"] .form-panel {
|
||||||
.form-group label { font-size: 0.8rem; color: var(--text-muted); }
|
background: rgba(79,70,229,0.04);
|
||||||
|
}
|
||||||
|
|
||||||
|
.form-group { display: flex; flex-direction: column; gap: 5px; }
|
||||||
|
.form-group label { font-size: 0.78rem; color: var(--text-muted); font-weight: 500; }
|
||||||
|
|
||||||
.form-control {
|
.form-control {
|
||||||
background: rgba(255, 255, 255, 0.05);
|
background: var(--bg-input);
|
||||||
border: 1px solid var(--border-glass);
|
border: 1px solid var(--border-glass);
|
||||||
padding: 10px 12px;
|
padding: 9px 12px;
|
||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
color: white;
|
color: var(--text-main);
|
||||||
font-family: var(--font);
|
font-family: var(--font);
|
||||||
font-size: 0.9rem;
|
font-size: 0.875rem;
|
||||||
outline: none;
|
outline: none;
|
||||||
transition: border 0.2s;
|
transition: border 0.2s;
|
||||||
}
|
}
|
||||||
.form-control:focus { border-color: var(--primary); }
|
.form-control:focus { border-color: var(--border-focus); box-shadow: 0 0 0 3px var(--primary-glow); }
|
||||||
|
.form-control::placeholder { color: var(--text-muted); }
|
||||||
|
|
||||||
.checkbox-group {
|
.checkbox-group {
|
||||||
display: flex;
|
display: flex;
|
||||||
@@ -128,78 +271,77 @@ body {
|
|||||||
gap: 8px;
|
gap: 8px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
.checkbox-group input { width: 16px; height: 16px; accent-color: var(--primary); cursor: pointer; }
|
.checkbox-group input { width: 15px; height: 15px; accent-color: var(--primary); cursor: pointer; }
|
||||||
.checkbox-group span { font-size: 0.85rem; color: var(--text-light); }
|
.checkbox-group span { font-size: 0.82rem; color: var(--text-main); }
|
||||||
|
|
||||||
.btn-submit {
|
.btn-submit {
|
||||||
background: var(--primary);
|
background: var(--primary-deep);
|
||||||
color: white;
|
color: white;
|
||||||
border: none;
|
border: none;
|
||||||
padding: 12px;
|
padding: 11px;
|
||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
|
font-family: var(--font);
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
transition: background 0.2s;
|
transition: var(--transition);
|
||||||
|
font-size: 0.875rem;
|
||||||
}
|
}
|
||||||
.btn-submit:hover { background: var(--primary-hover); }
|
.btn-submit:hover { filter: brightness(1.1); transform: translateY(-1px); }
|
||||||
|
|
||||||
/* Leaflet Customizations */
|
/* ── Leaflet Customizations ── */
|
||||||
.leaflet-draw-toolbar { display: none !important; }
|
.leaflet-draw-toolbar { display: none !important; }
|
||||||
.leaflet-control-zoom { border: none !important; box-shadow: var(--shadow) !important; }
|
.leaflet-control-zoom { border: none !important; box-shadow: var(--shadow) !important; }
|
||||||
.leaflet-control-zoom a {
|
.leaflet-control-zoom a {
|
||||||
background: var(--bg-glass) !important;
|
background: var(--bg-glass) !important;
|
||||||
color: var(--text-light) !important;
|
color: var(--text-main) !important;
|
||||||
border-color: var(--border-glass) !important;
|
border-color: var(--border-glass) !important;
|
||||||
backdrop-filter: blur(10px);
|
backdrop-filter: blur(10px);
|
||||||
}
|
}
|
||||||
.leaflet-control-zoom a:hover { background: var(--primary) !important; }
|
.leaflet-control-zoom a:hover { background: var(--primary-deep) !important; color: white !important; }
|
||||||
|
|
||||||
/* Leaflet Popup Premium */
|
|
||||||
.leaflet-popup-content-wrapper {
|
.leaflet-popup-content-wrapper {
|
||||||
background: var(--bg-glass) !important;
|
background: var(--bg-glass) !important;
|
||||||
backdrop-filter: blur(16px) !important;
|
backdrop-filter: blur(16px) !important;
|
||||||
border: 1px solid var(--border-glass) !important;
|
border: 1px solid var(--border-glass) !important;
|
||||||
color: var(--text-light) !important;
|
color: var(--text-main) !important;
|
||||||
border-radius: 16px !important;
|
border-radius: 14px !important;
|
||||||
box-shadow: var(--shadow) !important;
|
box-shadow: var(--shadow) !important;
|
||||||
}
|
}
|
||||||
.leaflet-popup-tip { background: var(--bg-glass) !important; border: 1px solid var(--border-glass) !important; }
|
.leaflet-popup-tip { background: var(--bg-glass) !important; }
|
||||||
.leaflet-popup-content { margin: 16px !important; font-family: var(--font); }
|
.leaflet-popup-content { margin: 14px !important; font-family: var(--font); }
|
||||||
.leaflet-popup-content h3 { margin: 0 0 8px 0; font-size: 1.1rem; border-bottom: 1px solid var(--border-glass); padding-bottom: 8px; }
|
.leaflet-popup-content h3 { margin: 0 0 8px 0; font-size: 1rem; border-bottom: 1px solid var(--border-glass); padding-bottom: 8px; }
|
||||||
.leaflet-popup-content p { margin: 4px 0; font-size: 0.9rem; color: var(--text-muted); }
|
.leaflet-popup-content p { margin: 4px 0; font-size: 0.85rem; color: var(--text-muted); }
|
||||||
|
|
||||||
.leaflet-popup-content .btn-delete {
|
.leaflet-popup-content .btn-delete {
|
||||||
background: rgba(239, 68, 68, 0.1);
|
background: rgba(239,68,68,0.1);
|
||||||
color: #EF4444;
|
color: #EF4444;
|
||||||
border: 1px solid rgba(239, 68, 68, 0.3);
|
border: 1px solid rgba(239,68,68,0.3);
|
||||||
padding: 6px 12px;
|
padding: 6px 12px;
|
||||||
border-radius: 6px;
|
border-radius: 6px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
margin-top: 12px;
|
margin-top: 10px;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
transition: all 0.2s;
|
font-family: var(--font);
|
||||||
|
font-size: 0.85rem;
|
||||||
|
transition: var(--transition);
|
||||||
}
|
}
|
||||||
.leaflet-popup-content .btn-delete:hover { background: #EF4444; color: white; }
|
.leaflet-popup-content .btn-delete:hover { background: #EF4444; color: white; }
|
||||||
|
|
||||||
/* Custom Map Marker Icon Animation */
|
/* ── Toast ── */
|
||||||
.custom-icon div {
|
|
||||||
transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
|
||||||
}
|
|
||||||
.custom-icon:hover div {
|
|
||||||
transform: scale(1.1) translateY(-4px);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Toast Notification */
|
|
||||||
.toast-container {
|
.toast-container {
|
||||||
position: fixed; bottom: 24px; right: 24px; z-index: 9999;
|
position: fixed; bottom: 24px; right: 24px; z-index: 9999;
|
||||||
display: flex; flex-direction: column; gap: 10px;
|
display: flex; flex-direction: column; gap: 10px;
|
||||||
}
|
}
|
||||||
.toast {
|
.toast {
|
||||||
background: var(--bg-glass); backdrop-filter: blur(16px);
|
background: var(--bg-glass); backdrop-filter: blur(16px);
|
||||||
border: 1px solid var(--border-glass); border-left: 4px solid var(--primary);
|
border: 1px solid var(--border-glass); border-left: 4px solid var(--primary-deep);
|
||||||
padding: 16px 20px; border-radius: 12px; color: white; font-size: 0.9rem;
|
padding: 14px 18px; border-radius: 12px; color: var(--text-main); font-size: 0.875rem;
|
||||||
box-shadow: var(--shadow); animation: slideIn 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
box-shadow: var(--shadow); animation: slideIn 0.3s var(--ease);
|
||||||
}
|
}
|
||||||
.toast.error { border-left-color: #EF4444; }
|
.toast.error { border-left-color: #EF4444; }
|
||||||
.toast.success { border-left-color: #10B981; }
|
.toast.success { border-left-color: #10B981; }
|
||||||
|
|
||||||
@keyframes slideIn { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
|
@keyframes slideIn {
|
||||||
|
from { transform: translateX(100%); opacity: 0; }
|
||||||
|
to { transform: translateX(0); opacity: 1; }
|
||||||
|
}
|
||||||
|
|||||||
+103
-18
@@ -1,53 +1,138 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="id">
|
<html lang="id" data-theme="dark">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<title>WebGIS - Pertemuan 03</title>
|
<title>WebGIS — Pertemuan 03: Analisis Spasial</title>
|
||||||
|
<meta name="description" content="Modul 03 — Choropleth Map dinamis berbasis Point-in-Polygon berbasis WebGIS.">
|
||||||
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap" rel="stylesheet">
|
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap" rel="stylesheet">
|
||||||
<link rel="stylesheet" href="https://unpkg.com/leaflet@1.9.4/dist/leaflet.css" />
|
<link rel="stylesheet" href="https://unpkg.com/leaflet@1.9.4/dist/leaflet.css" />
|
||||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/leaflet.draw/1.0.4/leaflet.draw.css" />
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/leaflet.draw/1.0.4/leaflet.draw.css" />
|
||||||
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.0/css/all.min.css">
|
||||||
<link rel="stylesheet" href="css/main.css">
|
<link rel="stylesheet" href="css/main.css">
|
||||||
<style>
|
<style>
|
||||||
.result-item { background: rgba(255,255,255,0.05); padding: 8px 10px; border-radius: 8px; border: 1px solid var(--border-glass); display: flex; justify-content: space-between; align-items: center; }
|
.result-item {
|
||||||
.badge { background: var(--primary); padding: 2px 6px; border-radius: 12px; font-size: 0.7rem; font-weight: 700; color: white; }
|
background: var(--bg-input);
|
||||||
|
padding: 8px 10px;
|
||||||
|
border-radius: 8px;
|
||||||
|
border: 1px solid var(--border-glass);
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
align-items: center;
|
||||||
|
font-size: 0.82rem;
|
||||||
|
}
|
||||||
|
.badge {
|
||||||
|
background: var(--primary-deep);
|
||||||
|
padding: 2px 8px;
|
||||||
|
border-radius: 12px;
|
||||||
|
font-size: 0.68rem;
|
||||||
|
font-weight: 700;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.stat-row {
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
align-items: center;
|
||||||
|
font-size: 0.82rem;
|
||||||
|
}
|
||||||
|
.stat-row strong { font-weight: 700; }
|
||||||
</style>
|
</style>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
|
<!-- Map container -->
|
||||||
<div id="map"></div>
|
<div id="map"></div>
|
||||||
|
|
||||||
|
<!-- Floating Dock -->
|
||||||
<div class="floating-dock">
|
<div class="floating-dock">
|
||||||
|
|
||||||
|
<!-- Dock top bar -->
|
||||||
|
<div class="dock-topbar">
|
||||||
|
<a href="../../portal.html" class="btn-back-portal" title="Kembali ke Portal">
|
||||||
|
<i class="fas fa-chevron-left"></i>
|
||||||
|
Portal
|
||||||
|
</a>
|
||||||
|
<div class="dock-controls">
|
||||||
|
<button class="btn-theme-dock" id="themeToggle" title="Toggle tema" aria-label="Toggle dark/light mode">
|
||||||
|
<i class="fas fa-moon" id="themeIcon"></i>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Header -->
|
||||||
<div class="header">
|
<div class="header">
|
||||||
<h2>P03: Analisis Spasial</h2>
|
<h2>P03: Analisis Spasial</h2>
|
||||||
<p>Kumulatif P01 & P02 + Choropleth Map (Point in Polygon).</p>
|
<p>Kumulatif P01 & P02 + Choropleth Map (Point-in-Polygon).</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- Draw Tools -->
|
||||||
<div class="menu-group">
|
<div class="menu-group">
|
||||||
<div class="menu-title">Draw Tools</div>
|
<div class="menu-title">Draw Tools</div>
|
||||||
<button id="btn-draw-spbu" class="btn-action btn-spbu"><svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M17.657 16.657L13.414 20.9a1.998 1.998 0 01-2.827 0l-4.242-4.243a8 8 0 1111.314 0z"></path><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 11a3 3 0 11-6 0 3 3 0 016 0z"></path></svg> Tambah SPBU</button>
|
<button id="btn-draw-spbu" class="btn-action btn-spbu">
|
||||||
<button id="btn-draw-jalan" class="btn-action btn-jalan"><svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M13 7h8m0 0v8m0-8l-8 8-4-4-6 6"></path></svg> Tambah Jalan</button>
|
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M17.657 16.657L13.414 20.9a1.998 1.998 0 01-2.827 0l-4.242-4.243a8 8 0 1111.314 0z"></path><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 11a3 3 0 11-6 0 3 3 0 016 0z"></path></svg>
|
||||||
<button id="btn-draw-kavling" class="btn-action btn-kavling"><svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M4 6a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2H6a2 2 0 01-2-2V6zM14 6a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2h-2a2 2 0 01-2-2V6zM4 16a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2H6a2 2 0 01-2-2v-2zM14 16a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2h-2a2 2 0 01-2-2v-2z"></path></svg> Tambah Kavling</button>
|
Tambah SPBU
|
||||||
<button id="btn-draw-rumah" class="btn-action btn-rumah"><svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M3 12l2-2m0 0l7-7 7 7M5 10v10a1 1 0 001 1h3m10-11l2 2m-2-2v10a1 1 0 01-1 1h-3m-6 0a1 1 0 001-1v-4a1 1 0 011-1h2a1 1 0 011 1v4a1 1 0 001 1m-6 0h6"></path></svg> Tambah Rumah Ibadah</button>
|
</button>
|
||||||
<button id="btn-draw-warga" class="btn-action btn-warga"><svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M17 20h5v-2a3 3 0 00-5.356-1.857M17 20H7m10 0v-2c0-.656-.126-1.283-.356-1.857M7 20H2v-2a3 3 0 015.356-1.857M7 20v-2c0-.656.126-1.283.356-1.857m0 0a5.002 5.002 0 019.288 0M15 7a3 3 0 11-6 0 3 3 0 016 0zm6 3a2 2 0 11-4 0 2 2 0 014 0zM7 10a2 2 0 11-4 0 2 2 0 014 0z"></path></svg> Tambah Warga Miskin</button>
|
<button id="btn-draw-jalan" class="btn-action btn-jalan">
|
||||||
|
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M13 7h8m0 0v8m0-8l-8 8-4-4-6 6"></path></svg>
|
||||||
|
Tambah Jalan
|
||||||
|
</button>
|
||||||
|
<button id="btn-draw-kavling" class="btn-action btn-kavling">
|
||||||
|
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M4 6a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2H6a2 2 0 01-2-2V6zM14 6a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2h-2a2 2 0 01-2-2V6zM4 16a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2H6a2 2 0 01-2-2v-2zM14 16a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2h-2a2 2 0 01-2-2v-2z"></path></svg>
|
||||||
|
Tambah Kavling
|
||||||
|
</button>
|
||||||
|
<button id="btn-draw-rumah" class="btn-action btn-rumah">
|
||||||
|
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M3 12l2-2m0 0l7-7 7 7M5 10v10a1 1 0 001 1h3m10-11l2 2m-2-2v10a1 1 0 01-1 1h-3m-6 0a1 1 0 001-1v-4a1 1 0 011-1h2a1 1 0 011 1v4a1 1 0 001 1m-6 0h6"></path></svg>
|
||||||
|
Tambah Rumah Ibadah
|
||||||
|
</button>
|
||||||
|
<button id="btn-draw-warga" class="btn-action btn-warga">
|
||||||
|
<svg fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M17 20h5v-2a3 3 0 00-5.356-1.857M17 20H7m10 0v-2c0-.656-.126-1.283-.356-1.857M7 20H2v-2a3 3 0 015.356-1.857M7 20v-2c0-.656.126-1.283.356-1.857m0 0a5.002 5.002 0 019.288 0M15 7a3 3 0 11-6 0 3 3 0 016 0zm6 3a2 2 0 11-4 0 2 2 0 014 0zM7 10a2 2 0 11-4 0 2 2 0 014 0z"></path></svg>
|
||||||
|
Tambah Warga Miskin
|
||||||
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="choropleth-panel" class="form-panel" style="margin-top: 5px; background: rgba(16, 185, 129, 0.1); border-color: rgba(16, 185, 129, 0.3);">
|
<!-- Choropleth stats panel -->
|
||||||
<h3 style="margin:0 0 5px 0; font-size:0.9rem; color:#10B981;">Statistik Kavling (Choropleth)</h3>
|
<div id="choropleth-panel" class="form-panel" style="margin-top:4px; background:rgba(16,185,129,0.07); border-color:rgba(16,185,129,0.25);">
|
||||||
<p style="font-size:0.8rem; margin:0 0 10px 0; color:var(--text-muted);">Pewarnaan otomatis area kavling berdasarkan jumlah warga miskin yang bermukim di atasnya.</p>
|
<h3 style="margin:0 0 8px 0; font-size:0.85rem; color:#10B981; font-weight:600;">
|
||||||
<div style="display:flex; justify-content:space-between; margin-bottom:8px;">
|
<i class="fas fa-chart-area" style="margin-right:6px;"></i>Statistik Kavling (Choropleth)
|
||||||
<span style="font-size:0.8rem;">Total Penduduk Miskin:</span>
|
</h3>
|
||||||
<strong id="stat-total-warga" style="color:white;">0</strong>
|
<p style="font-size:0.78rem; margin:0 0 10px 0; color:var(--text-muted);">Pewarnaan otomatis area kavling berdasarkan jumlah warga miskin yang bermukim di atasnya.</p>
|
||||||
|
<div class="stat-row" style="margin-bottom:6px;">
|
||||||
|
<span>Total Penduduk Miskin:</span>
|
||||||
|
<strong id="stat-total-warga" style="color:var(--text-main);">0</strong>
|
||||||
</div>
|
</div>
|
||||||
<div style="display:flex; justify-content:space-between;">
|
<div class="stat-row">
|
||||||
<span style="font-size:0.8rem;">Kavling Padat (>2 warga):</span>
|
<span>Kavling Padat (>2 warga):</span>
|
||||||
<strong id="stat-kavling-merah" style="color:#EF4444;">0</strong>
|
<strong id="stat-kavling-merah" style="color:#EF4444;">0</strong>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- Dynamic form container -->
|
||||||
<div id="form-container" style="display: none;"></div>
|
<div id="form-container" style="display: none;"></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- Toast -->
|
||||||
<div id="toast-container" class="toast-container"></div>
|
<div id="toast-container" class="toast-container"></div>
|
||||||
|
|
||||||
<script src="https://unpkg.com/leaflet@1.9.4/dist/leaflet.js"></script>
|
<script src="https://unpkg.com/leaflet@1.9.4/dist/leaflet.js"></script>
|
||||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/leaflet.draw/1.0.4/leaflet.draw.js"></script>
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/leaflet.draw/1.0.4/leaflet.draw.js"></script>
|
||||||
|
<script>
|
||||||
|
// ── Theme toggle ──
|
||||||
|
const html = document.documentElement;
|
||||||
|
const btn = document.getElementById('themeToggle');
|
||||||
|
const icon = document.getElementById('themeIcon');
|
||||||
|
const saved = localStorage.getItem('portal-theme') || 'dark';
|
||||||
|
setTheme(saved);
|
||||||
|
btn.addEventListener('click', () => {
|
||||||
|
const next = html.getAttribute('data-theme') === 'dark' ? 'light' : 'dark';
|
||||||
|
setTheme(next);
|
||||||
|
localStorage.setItem('portal-theme', next);
|
||||||
|
});
|
||||||
|
function setTheme(t) {
|
||||||
|
html.setAttribute('data-theme', t);
|
||||||
|
icon.className = t === 'dark' ? 'fas fa-sun' : 'fas fa-moon';
|
||||||
|
}
|
||||||
|
</script>
|
||||||
<script type="module" src="js/app.js"></script>
|
<script type="module" src="js/app.js"></script>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
@@ -14,12 +14,27 @@ export const initMap = (containerId) => {
|
|||||||
position: 'bottomright'
|
position: 'bottomright'
|
||||||
}).addTo(map);
|
}).addTo(map);
|
||||||
|
|
||||||
// Tile Layer Premium (CartoDB Dark Matter untuk Glass UI)
|
const isDark = document.documentElement.getAttribute('data-theme') === 'dark';
|
||||||
L.tileLayer('https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png', {
|
const tileUrl = isDark
|
||||||
|
? 'https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png'
|
||||||
|
: 'https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png';
|
||||||
|
|
||||||
|
// Tile Layer Premium (CartoDB Dark Matter / Light All)
|
||||||
|
const tileLayer = L.tileLayer(tileUrl, {
|
||||||
attribution: '© <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors © <a href="https://carto.com/attributions">CARTO</a>',
|
attribution: '© <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors © <a href="https://carto.com/attributions">CARTO</a>',
|
||||||
subdomains: 'abcd',
|
subdomains: 'abcd',
|
||||||
maxZoom: 20
|
maxZoom: 20
|
||||||
}).addTo(map);
|
}).addTo(map);
|
||||||
|
|
||||||
|
// Dynamic theme updater for tile layer
|
||||||
|
const observer = new MutationObserver(() => {
|
||||||
|
const dark = document.documentElement.getAttribute('data-theme') === 'dark';
|
||||||
|
tileLayer.setUrl(dark
|
||||||
|
? 'https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png'
|
||||||
|
: 'https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png'
|
||||||
|
);
|
||||||
|
});
|
||||||
|
observer.observe(document.documentElement, { attributes: true });
|
||||||
|
|
||||||
return map;
|
return map;
|
||||||
};
|
};
|
||||||
|
|||||||
-320
@@ -1,320 +0,0 @@
|
|||||||
<!DOCTYPE html>
|
|
||||||
<html lang="id">
|
|
||||||
<head>
|
|
||||||
<meta charset="UTF-8">
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
||||||
<title>Portal WebGIS - Sistem Informasi Geografis</title>
|
|
||||||
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap" rel="stylesheet">
|
|
||||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.0/css/all.min.css">
|
|
||||||
<style>
|
|
||||||
:root {
|
|
||||||
/* Matching webgis_app/main.css */
|
|
||||||
--primary: #2563EB;
|
|
||||||
--primary-light: #3B82F6;
|
|
||||||
--primary-dark: #1D4ED8;
|
|
||||||
--accent: #10B981;
|
|
||||||
--bg-base: #F9FAFB;
|
|
||||||
--bg-surface: #FFFFFF;
|
|
||||||
--border-light: #E5E7EB;
|
|
||||||
--border-hover: #D1D5DB;
|
|
||||||
--text-primary: #111827;
|
|
||||||
--text-secondary: #4B5563;
|
|
||||||
--text-muted: #6B7280;
|
|
||||||
--radius-md: 8px;
|
|
||||||
--radius-lg: 12px;
|
|
||||||
--radius-xl: 16px;
|
|
||||||
--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: all 0.2s ease-in-out;
|
|
||||||
}
|
|
||||||
|
|
||||||
* {
|
|
||||||
margin: 0;
|
|
||||||
padding: 0;
|
|
||||||
box-sizing: border-box;
|
|
||||||
}
|
|
||||||
|
|
||||||
body {
|
|
||||||
font-family: 'Inter', sans-serif;
|
|
||||||
background-color: var(--bg-base);
|
|
||||||
color: var(--text-primary);
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
align-items: center;
|
|
||||||
min-height: 100vh;
|
|
||||||
-webkit-font-smoothing: antialiased;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar {
|
|
||||||
width: 100%;
|
|
||||||
background: var(--bg-surface);
|
|
||||||
border-bottom: 1px solid var(--border-light);
|
|
||||||
padding: 16px 32px;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
justify-content: space-between;
|
|
||||||
box-shadow: var(--shadow-sm);
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-brand {
|
|
||||||
font-size: 1.2rem;
|
|
||||||
font-weight: 700;
|
|
||||||
color: var(--primary);
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
gap: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.header {
|
|
||||||
text-align: center;
|
|
||||||
margin-top: 60px;
|
|
||||||
margin-bottom: 50px;
|
|
||||||
animation: slideDown 0.4s ease-out;
|
|
||||||
padding: 0 20px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.header-icon {
|
|
||||||
font-size: 3rem;
|
|
||||||
color: var(--primary);
|
|
||||||
margin-bottom: 16px;
|
|
||||||
background: #EFF6FF;
|
|
||||||
width: 80px;
|
|
||||||
height: 80px;
|
|
||||||
line-height: 80px;
|
|
||||||
border-radius: 50%;
|
|
||||||
display: inline-block;
|
|
||||||
}
|
|
||||||
|
|
||||||
.header h1 {
|
|
||||||
font-size: 2.5rem;
|
|
||||||
font-weight: 800;
|
|
||||||
color: var(--text-primary);
|
|
||||||
letter-spacing: -0.02em;
|
|
||||||
margin-bottom: 12px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.header p {
|
|
||||||
font-size: 1.05rem;
|
|
||||||
color: var(--text-secondary);
|
|
||||||
max-width: 600px;
|
|
||||||
margin: 0 auto;
|
|
||||||
line-height: 1.6;
|
|
||||||
}
|
|
||||||
|
|
||||||
.grid-container {
|
|
||||||
display: grid;
|
|
||||||
grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
|
|
||||||
gap: 24px;
|
|
||||||
width: 100%;
|
|
||||||
max-width: 1000px;
|
|
||||||
padding: 0 24px 60px 24px;
|
|
||||||
animation: fadeIn 0.6s ease-out forwards;
|
|
||||||
opacity: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.card {
|
|
||||||
background: var(--bg-surface);
|
|
||||||
border: 1px solid var(--border-light);
|
|
||||||
border-radius: var(--radius-lg);
|
|
||||||
padding: 30px;
|
|
||||||
text-decoration: none;
|
|
||||||
color: inherit;
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
box-shadow: var(--shadow-sm);
|
|
||||||
transition: var(--transition);
|
|
||||||
position: relative;
|
|
||||||
overflow: hidden;
|
|
||||||
}
|
|
||||||
|
|
||||||
.card:hover {
|
|
||||||
transform: translateY(-4px);
|
|
||||||
box-shadow: var(--shadow-md);
|
|
||||||
border-color: var(--border-hover);
|
|
||||||
}
|
|
||||||
|
|
||||||
.card-icon-wrap {
|
|
||||||
width: 48px;
|
|
||||||
height: 48px;
|
|
||||||
border-radius: var(--radius-md);
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
justify-content: center;
|
|
||||||
font-size: 1.5rem;
|
|
||||||
margin-bottom: 20px;
|
|
||||||
transition: var(--transition);
|
|
||||||
}
|
|
||||||
|
|
||||||
.card:nth-child(1) .card-icon-wrap { background: #EFF6FF; color: var(--primary); }
|
|
||||||
.card:nth-child(2) .card-icon-wrap { background: #ECFDF5; color: var(--accent); }
|
|
||||||
.card:nth-child(3) .card-icon-wrap { background: #FEF2F2; color: #EF4444; }
|
|
||||||
|
|
||||||
.card-number {
|
|
||||||
font-size: 0.75rem;
|
|
||||||
font-weight: 700;
|
|
||||||
color: var(--text-muted);
|
|
||||||
text-transform: uppercase;
|
|
||||||
letter-spacing: 0.05em;
|
|
||||||
margin-bottom: 8px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.card-title {
|
|
||||||
font-size: 1.2rem;
|
|
||||||
font-weight: 700;
|
|
||||||
margin-bottom: 10px;
|
|
||||||
color: var(--text-primary);
|
|
||||||
}
|
|
||||||
|
|
||||||
.card-desc {
|
|
||||||
font-size: 0.9rem;
|
|
||||||
color: var(--text-secondary);
|
|
||||||
line-height: 1.5;
|
|
||||||
flex-grow: 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
.card-footer {
|
|
||||||
margin-top: 24px;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
font-weight: 600;
|
|
||||||
color: var(--primary);
|
|
||||||
font-size: 0.9rem;
|
|
||||||
transition: var(--transition);
|
|
||||||
}
|
|
||||||
|
|
||||||
.card-footer i {
|
|
||||||
margin-left: 8px;
|
|
||||||
font-size: 0.8rem;
|
|
||||||
transition: transform 0.2s ease;
|
|
||||||
}
|
|
||||||
|
|
||||||
.card:hover .card-footer {
|
|
||||||
color: var(--primary-dark);
|
|
||||||
}
|
|
||||||
|
|
||||||
.card:hover .card-footer i {
|
|
||||||
transform: translateX(4px);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Final Card styling */
|
|
||||||
.card.final {
|
|
||||||
background: var(--primary);
|
|
||||||
border: 1px solid var(--primary-dark);
|
|
||||||
color: white;
|
|
||||||
}
|
|
||||||
|
|
||||||
.card.final .card-icon-wrap {
|
|
||||||
background: rgba(255, 255, 255, 0.2);
|
|
||||||
color: white;
|
|
||||||
}
|
|
||||||
|
|
||||||
.card.final .card-number {
|
|
||||||
color: rgba(255, 255, 255, 0.8);
|
|
||||||
}
|
|
||||||
|
|
||||||
.card.final .card-title {
|
|
||||||
color: white;
|
|
||||||
}
|
|
||||||
|
|
||||||
.card.final .card-desc {
|
|
||||||
color: rgba(255, 255, 255, 0.9);
|
|
||||||
}
|
|
||||||
|
|
||||||
.card.final .card-footer {
|
|
||||||
color: white;
|
|
||||||
}
|
|
||||||
|
|
||||||
.card.final:hover {
|
|
||||||
transform: translateY(-4px);
|
|
||||||
box-shadow: var(--shadow-lg);
|
|
||||||
background: var(--primary-dark);
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes slideDown {
|
|
||||||
from { opacity: 0; transform: translateY(-20px); }
|
|
||||||
to { opacity: 1; transform: translateY(0); }
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes fadeIn {
|
|
||||||
from { opacity: 0; transform: scale(0.98); }
|
|
||||||
to { opacity: 1; transform: scale(1); }
|
|
||||||
}
|
|
||||||
|
|
||||||
</style>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
|
|
||||||
<nav class="navbar">
|
|
||||||
<div class="navbar-brand">
|
|
||||||
<i class="fas fa-map-marked-alt"></i>
|
|
||||||
WebGIS Portal
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<header class="header">
|
|
||||||
<div class="header-icon">
|
|
||||||
<i class="fas fa-globe-asia"></i>
|
|
||||||
</div>
|
|
||||||
<h1>Sistem Informasi Geografis</h1>
|
|
||||||
<p>Direktori tugas dan proyek akhir mata kuliah Sistem Informasi Geografis. Pilih modul pembelajaran di bawah ini untuk memulai.</p>
|
|
||||||
</header>
|
|
||||||
|
|
||||||
<div class="grid-container">
|
|
||||||
|
|
||||||
<!-- Pertemuan 01 -->
|
|
||||||
<a href="01/frontend/" class="card" style="animation-delay: 0.1s;">
|
|
||||||
<div class="card-icon-wrap">
|
|
||||||
<i class="fas fa-draw-polygon"></i>
|
|
||||||
</div>
|
|
||||||
<div class="card-number">Pertemuan 01</div>
|
|
||||||
<h2 class="card-title">Geometri Dasar</h2>
|
|
||||||
<p class="card-desc">Fitur menggambar peta dasar dan CRUD spasial.</p>
|
|
||||||
<div class="card-footer">
|
|
||||||
Buka Modul <i class="fas fa-arrow-right"></i>
|
|
||||||
</div>
|
|
||||||
</a>
|
|
||||||
|
|
||||||
<!-- Pertemuan 02 -->
|
|
||||||
<a href="02/frontend/" class="card" style="animation-delay: 0.15s;">
|
|
||||||
<div class="card-icon-wrap">
|
|
||||||
<i class="fas fa-route"></i>
|
|
||||||
</div>
|
|
||||||
<div class="card-number">Pertemuan 02</div>
|
|
||||||
<h2 class="card-title">Haversine & Tematik</h2>
|
|
||||||
<p class="card-desc">Pemetaan sosial dan query pencarian radius jarak.</p>
|
|
||||||
<div class="card-footer">
|
|
||||||
Buka Modul <i class="fas fa-arrow-right"></i>
|
|
||||||
</div>
|
|
||||||
</a>
|
|
||||||
|
|
||||||
<!-- Pertemuan 03 -->
|
|
||||||
<a href="03/frontend/" class="card" style="animation-delay: 0.2s;">
|
|
||||||
<div class="card-icon-wrap">
|
|
||||||
<i class="fas fa-layer-group"></i>
|
|
||||||
</div>
|
|
||||||
<div class="card-number">Pertemuan 03</div>
|
|
||||||
<h2 class="card-title">Analisis Spasial</h2>
|
|
||||||
<p class="card-desc">Visualisasi Peta Choropleth dinamis (Point-in-Polygon).</p>
|
|
||||||
<div class="card-footer">
|
|
||||||
Buka Modul <i class="fas fa-arrow-right"></i>
|
|
||||||
</div>
|
|
||||||
</a>
|
|
||||||
|
|
||||||
<!-- Final (UAS) -->
|
|
||||||
<a href="webgis_app/" class="card final" style="animation-delay: 0.25s;">
|
|
||||||
<div class="card-icon-wrap">
|
|
||||||
<i class="fas fa-laptop-code"></i>
|
|
||||||
</div>
|
|
||||||
<div class="card-number">Proyek Akhir</div>
|
|
||||||
<h2 class="card-title">Final UAS</h2>
|
|
||||||
<p class="card-desc">Sistem komprehensif untuk evaluasi akhir semester.</p>
|
|
||||||
<div class="card-footer">
|
|
||||||
Buka Aplikasi <i class="fas fa-arrow-right"></i>
|
|
||||||
</div>
|
|
||||||
</a>
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
+673
@@ -0,0 +1,673 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="id" data-theme="dark">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<title>WebGIS Portal — Sistem Informasi Geografis</title>
|
||||||
|
<meta name="description" content="Portal WebGIS — Direktori modul dan proyek akhir mata kuliah Sistem Informasi Geografis.">
|
||||||
|
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=Space+Grotesk:wght@400;500;600;700&display=swap" rel="stylesheet">
|
||||||
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.0/css/all.min.css">
|
||||||
|
<style>
|
||||||
|
/* ══ DESIGN TOKENS ══ */
|
||||||
|
:root {
|
||||||
|
--font-sans: 'Inter', sans-serif;
|
||||||
|
--font-display: 'Space Grotesk', sans-serif;
|
||||||
|
--ease: cubic-bezier(0.4, 0, 0.2, 1);
|
||||||
|
--transition: all 0.25s var(--ease);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ══ DARK THEME (default) ══ */
|
||||||
|
[data-theme="dark"] {
|
||||||
|
--bg-page: #0A0F1E;
|
||||||
|
--bg-surface: #111827;
|
||||||
|
--bg-card: #141D2F;
|
||||||
|
--bg-card-hover:#1A2540;
|
||||||
|
--border: rgba(255,255,255,0.07);
|
||||||
|
--border-hover: rgba(99,102,241,0.5);
|
||||||
|
--text-primary: #F1F5F9;
|
||||||
|
--text-secondary:#94A3B8;
|
||||||
|
--text-muted: #64748B;
|
||||||
|
--primary: #6366F1;
|
||||||
|
--primary-glow: rgba(99,102,241,0.25);
|
||||||
|
--accent: #06B6D4;
|
||||||
|
--accent-2: #10B981;
|
||||||
|
--accent-3: #F43F5E;
|
||||||
|
--nav-bg: rgba(10,15,30,0.85);
|
||||||
|
--glass: rgba(17,24,39,0.8);
|
||||||
|
--shine: rgba(255,255,255,0.03);
|
||||||
|
--shadow-card: 0 4px 24px rgba(0,0,0,0.4);
|
||||||
|
--shadow-glow: 0 0 40px rgba(99,102,241,0.15);
|
||||||
|
--gradient-hero: linear-gradient(135deg, #0A0F1E 0%, #111827 50%, #0D1B2E 100%);
|
||||||
|
--dot-color: rgba(255,255,255,0.04);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ══ LIGHT THEME ══ */
|
||||||
|
[data-theme="light"] {
|
||||||
|
--bg-page: #F0F4FF;
|
||||||
|
--bg-surface: #FFFFFF;
|
||||||
|
--bg-card: #FFFFFF;
|
||||||
|
--bg-card-hover:#F8FAFF;
|
||||||
|
--border: #E2E8F0;
|
||||||
|
--border-hover: #6366F1;
|
||||||
|
--text-primary: #0F172A;
|
||||||
|
--text-secondary:#475569;
|
||||||
|
--text-muted: #94A3B8;
|
||||||
|
--primary: #4F46E5;
|
||||||
|
--primary-glow: rgba(79,70,229,0.12);
|
||||||
|
--accent: #0891B2;
|
||||||
|
--accent-2: #059669;
|
||||||
|
--accent-3: #E11D48;
|
||||||
|
--nav-bg: rgba(240,244,255,0.9);
|
||||||
|
--glass: rgba(255,255,255,0.9);
|
||||||
|
--shine: rgba(255,255,255,0.5);
|
||||||
|
--shadow-card: 0 4px 24px rgba(79,70,229,0.08);
|
||||||
|
--shadow-glow: 0 0 40px rgba(79,70,229,0.1);
|
||||||
|
--gradient-hero: linear-gradient(135deg, #EEF2FF 0%, #F0F4FF 50%, #E8F4FF 100%);
|
||||||
|
--dot-color: rgba(79,70,229,0.04);
|
||||||
|
}
|
||||||
|
|
||||||
|
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
|
||||||
|
html { scroll-behavior: smooth; }
|
||||||
|
|
||||||
|
body {
|
||||||
|
font-family: var(--font-sans);
|
||||||
|
background: var(--bg-page);
|
||||||
|
color: var(--text-primary);
|
||||||
|
min-height: 100vh;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
-webkit-font-smoothing: antialiased;
|
||||||
|
transition: background 0.3s var(--ease), color 0.3s var(--ease);
|
||||||
|
overflow-x: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Dot grid background ── */
|
||||||
|
body::before {
|
||||||
|
content: '';
|
||||||
|
position: fixed;
|
||||||
|
inset: 0;
|
||||||
|
background-image: radial-gradient(circle, var(--dot-color) 1px, transparent 1px);
|
||||||
|
background-size: 32px 32px;
|
||||||
|
pointer-events: none;
|
||||||
|
z-index: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Ambient glow orbs ── */
|
||||||
|
.orb {
|
||||||
|
position: fixed;
|
||||||
|
border-radius: 50%;
|
||||||
|
filter: blur(120px);
|
||||||
|
pointer-events: none;
|
||||||
|
z-index: 0;
|
||||||
|
transition: opacity 0.4s;
|
||||||
|
}
|
||||||
|
.orb-1 { width: 500px; height: 500px; background: var(--primary-glow); top: -100px; left: -100px; opacity: 0.6; }
|
||||||
|
.orb-2 { width: 400px; height: 400px; background: rgba(6,182,212,0.1); bottom: -80px; right: -80px; opacity: 0.5; }
|
||||||
|
|
||||||
|
/* ── Navbar ── */
|
||||||
|
.navbar {
|
||||||
|
position: sticky;
|
||||||
|
top: 0;
|
||||||
|
z-index: 100;
|
||||||
|
width: 100%;
|
||||||
|
background: var(--nav-bg);
|
||||||
|
backdrop-filter: blur(20px);
|
||||||
|
-webkit-backdrop-filter: blur(20px);
|
||||||
|
border-bottom: 1px solid var(--border);
|
||||||
|
padding: 0 32px;
|
||||||
|
height: 64px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: space-between;
|
||||||
|
transition: var(--transition);
|
||||||
|
}
|
||||||
|
|
||||||
|
.navbar-brand {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 12px;
|
||||||
|
font-family: var(--font-display);
|
||||||
|
font-size: 1.1rem;
|
||||||
|
font-weight: 700;
|
||||||
|
color: var(--text-primary);
|
||||||
|
text-decoration: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.brand-icon {
|
||||||
|
width: 36px;
|
||||||
|
height: 36px;
|
||||||
|
background: linear-gradient(135deg, var(--primary), var(--accent));
|
||||||
|
border-radius: 10px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
font-size: 0.95rem;
|
||||||
|
color: white;
|
||||||
|
flex-shrink: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.navbar-right {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.nav-pill {
|
||||||
|
background: var(--bg-card);
|
||||||
|
border: 1px solid var(--border);
|
||||||
|
border-radius: 20px;
|
||||||
|
padding: 4px 14px;
|
||||||
|
font-size: 0.75rem;
|
||||||
|
font-weight: 600;
|
||||||
|
color: var(--text-muted);
|
||||||
|
text-transform: uppercase;
|
||||||
|
letter-spacing: 0.06em;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Theme toggle ── */
|
||||||
|
.theme-toggle {
|
||||||
|
width: 40px;
|
||||||
|
height: 40px;
|
||||||
|
border-radius: 10px;
|
||||||
|
border: 1px solid var(--border);
|
||||||
|
background: var(--bg-card);
|
||||||
|
color: var(--text-secondary);
|
||||||
|
cursor: pointer;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
font-size: 1rem;
|
||||||
|
transition: var(--transition);
|
||||||
|
}
|
||||||
|
.theme-toggle:hover {
|
||||||
|
background: var(--primary);
|
||||||
|
border-color: var(--primary);
|
||||||
|
color: white;
|
||||||
|
transform: rotate(15deg);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Hero section ── */
|
||||||
|
.hero {
|
||||||
|
position: relative;
|
||||||
|
z-index: 1;
|
||||||
|
text-align: center;
|
||||||
|
padding: 80px 24px 60px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.hero-badge {
|
||||||
|
display: inline-flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 8px;
|
||||||
|
padding: 6px 16px;
|
||||||
|
border-radius: 100px;
|
||||||
|
background: var(--primary-glow);
|
||||||
|
border: 1px solid var(--border-hover);
|
||||||
|
font-size: 0.75rem;
|
||||||
|
font-weight: 600;
|
||||||
|
color: var(--primary);
|
||||||
|
letter-spacing: 0.06em;
|
||||||
|
text-transform: uppercase;
|
||||||
|
margin-bottom: 24px;
|
||||||
|
animation: fadeSlideDown 0.5s var(--ease) both;
|
||||||
|
}
|
||||||
|
|
||||||
|
.hero h1 {
|
||||||
|
font-family: var(--font-display);
|
||||||
|
font-size: clamp(2.2rem, 5vw, 3.8rem);
|
||||||
|
font-weight: 800;
|
||||||
|
line-height: 1.1;
|
||||||
|
letter-spacing: -0.03em;
|
||||||
|
margin-bottom: 20px;
|
||||||
|
animation: fadeSlideDown 0.5s var(--ease) 0.05s both;
|
||||||
|
}
|
||||||
|
|
||||||
|
.hero h1 .gradient-text {
|
||||||
|
background: linear-gradient(135deg, var(--primary), var(--accent));
|
||||||
|
-webkit-background-clip: text;
|
||||||
|
-webkit-text-fill-color: transparent;
|
||||||
|
background-clip: text;
|
||||||
|
}
|
||||||
|
|
||||||
|
.hero p {
|
||||||
|
font-size: 1.1rem;
|
||||||
|
color: var(--text-secondary);
|
||||||
|
max-width: 560px;
|
||||||
|
margin: 0 auto 48px;
|
||||||
|
line-height: 1.7;
|
||||||
|
animation: fadeSlideDown 0.5s var(--ease) 0.1s both;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Stats bar ── */
|
||||||
|
.stats-bar {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
gap: 32px;
|
||||||
|
margin-bottom: 64px;
|
||||||
|
animation: fadeSlideDown 0.5s var(--ease) 0.15s both;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
}
|
||||||
|
|
||||||
|
.stat-item {
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.stat-value {
|
||||||
|
font-family: var(--font-display);
|
||||||
|
font-size: 1.8rem;
|
||||||
|
font-weight: 700;
|
||||||
|
color: var(--text-primary);
|
||||||
|
line-height: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
.stat-label {
|
||||||
|
font-size: 0.75rem;
|
||||||
|
color: var(--text-muted);
|
||||||
|
text-transform: uppercase;
|
||||||
|
letter-spacing: 0.05em;
|
||||||
|
margin-top: 4px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.stat-divider {
|
||||||
|
width: 1px;
|
||||||
|
height: 40px;
|
||||||
|
background: var(--border);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Grid ── */
|
||||||
|
.grid-section {
|
||||||
|
position: relative;
|
||||||
|
z-index: 1;
|
||||||
|
width: 100%;
|
||||||
|
max-width: 1100px;
|
||||||
|
margin: 0 auto;
|
||||||
|
padding: 0 24px 80px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.section-label {
|
||||||
|
font-size: 0.75rem;
|
||||||
|
font-weight: 700;
|
||||||
|
color: var(--text-muted);
|
||||||
|
text-transform: uppercase;
|
||||||
|
letter-spacing: 0.1em;
|
||||||
|
margin-bottom: 24px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.section-label::after {
|
||||||
|
content: '';
|
||||||
|
flex: 1;
|
||||||
|
height: 1px;
|
||||||
|
background: var(--border);
|
||||||
|
}
|
||||||
|
|
||||||
|
.grid {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: repeat(3, 1fr);
|
||||||
|
gap: 20px;
|
||||||
|
margin-bottom: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Card ── */
|
||||||
|
.card {
|
||||||
|
background: var(--bg-card);
|
||||||
|
border: 1px solid var(--border);
|
||||||
|
border-radius: 20px;
|
||||||
|
padding: 28px;
|
||||||
|
text-decoration: none;
|
||||||
|
color: inherit;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
box-shadow: var(--shadow-card);
|
||||||
|
transition: var(--transition);
|
||||||
|
position: relative;
|
||||||
|
overflow: hidden;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
.card::before {
|
||||||
|
content: '';
|
||||||
|
position: absolute;
|
||||||
|
inset: 0;
|
||||||
|
background: var(--shine);
|
||||||
|
border-radius: inherit;
|
||||||
|
opacity: 0;
|
||||||
|
transition: opacity 0.3s;
|
||||||
|
}
|
||||||
|
|
||||||
|
.card:hover {
|
||||||
|
transform: translateY(-6px);
|
||||||
|
border-color: var(--border-hover);
|
||||||
|
box-shadow: var(--shadow-glow), var(--shadow-card);
|
||||||
|
background: var(--bg-card-hover);
|
||||||
|
}
|
||||||
|
|
||||||
|
.card:hover::before { opacity: 1; }
|
||||||
|
|
||||||
|
/* Number badge */
|
||||||
|
.card-num {
|
||||||
|
position: absolute;
|
||||||
|
top: 20px;
|
||||||
|
right: 20px;
|
||||||
|
font-family: var(--font-display);
|
||||||
|
font-size: 4rem;
|
||||||
|
font-weight: 900;
|
||||||
|
color: var(--border);
|
||||||
|
line-height: 1;
|
||||||
|
letter-spacing: -0.05em;
|
||||||
|
transition: var(--transition);
|
||||||
|
user-select: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.card:hover .card-num {
|
||||||
|
color: var(--primary-glow);
|
||||||
|
}
|
||||||
|
|
||||||
|
.card-icon-wrap {
|
||||||
|
width: 52px;
|
||||||
|
height: 52px;
|
||||||
|
border-radius: 14px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
font-size: 1.4rem;
|
||||||
|
margin-bottom: 24px;
|
||||||
|
transition: var(--transition);
|
||||||
|
}
|
||||||
|
|
||||||
|
.card:hover .card-icon-wrap {
|
||||||
|
transform: scale(1.08);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Card themes */
|
||||||
|
.card[data-type="p01"] .card-icon-wrap { background: rgba(99,102,241,0.15); color: #818CF8; }
|
||||||
|
.card[data-type="p02"] .card-icon-wrap { background: rgba(6,182,212,0.15); color: #22D3EE; }
|
||||||
|
.card[data-type="p03"] .card-icon-wrap { background: rgba(16,185,129,0.15); color: #34D399; }
|
||||||
|
.card[data-type="uas"] .card-icon-wrap { background: rgba(244,63,94,0.15); color: #FB7185; }
|
||||||
|
|
||||||
|
.card-tag {
|
||||||
|
font-size: 0.7rem;
|
||||||
|
font-weight: 700;
|
||||||
|
text-transform: uppercase;
|
||||||
|
letter-spacing: 0.1em;
|
||||||
|
color: var(--text-muted);
|
||||||
|
margin-bottom: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.card-title {
|
||||||
|
font-family: var(--font-display);
|
||||||
|
font-size: 1.25rem;
|
||||||
|
font-weight: 700;
|
||||||
|
color: var(--text-primary);
|
||||||
|
margin-bottom: 10px;
|
||||||
|
line-height: 1.3;
|
||||||
|
}
|
||||||
|
|
||||||
|
.card-desc {
|
||||||
|
font-size: 0.875rem;
|
||||||
|
color: var(--text-secondary);
|
||||||
|
line-height: 1.6;
|
||||||
|
flex-grow: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
.card-footer {
|
||||||
|
margin-top: 24px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 8px;
|
||||||
|
font-size: 0.85rem;
|
||||||
|
font-weight: 600;
|
||||||
|
color: var(--primary);
|
||||||
|
transition: var(--transition);
|
||||||
|
}
|
||||||
|
|
||||||
|
.card-footer .arrow {
|
||||||
|
width: 24px;
|
||||||
|
height: 24px;
|
||||||
|
border-radius: 6px;
|
||||||
|
background: var(--primary-glow);
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
font-size: 0.7rem;
|
||||||
|
transition: var(--transition);
|
||||||
|
}
|
||||||
|
|
||||||
|
.card:hover .card-footer { color: var(--primary); }
|
||||||
|
.card:hover .card-footer .arrow {
|
||||||
|
background: var(--primary);
|
||||||
|
color: white;
|
||||||
|
transform: translateX(3px);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Final (UAS) card — full-width special ── */
|
||||||
|
.card-uas {
|
||||||
|
grid-column: 1 / -1;
|
||||||
|
flex-direction: row;
|
||||||
|
align-items: center;
|
||||||
|
gap: 32px;
|
||||||
|
background: linear-gradient(135deg, var(--primary) 0%, #4338CA 100%);
|
||||||
|
border-color: transparent;
|
||||||
|
padding: 36px 40px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.card-uas::before { background: rgba(255,255,255,0.05); }
|
||||||
|
.card-uas:hover { border-color: rgba(255,255,255,0.2); }
|
||||||
|
|
||||||
|
.card-uas .card-icon-wrap {
|
||||||
|
background: rgba(255,255,255,0.15);
|
||||||
|
color: white;
|
||||||
|
width: 64px;
|
||||||
|
height: 64px;
|
||||||
|
font-size: 1.8rem;
|
||||||
|
flex-shrink: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.card-uas .card-tag { color: rgba(255,255,255,0.6); }
|
||||||
|
.card-uas .card-title { color: white; font-size: 1.6rem; }
|
||||||
|
.card-uas .card-desc { color: rgba(255,255,255,0.8); font-size: 1rem; }
|
||||||
|
.card-uas .card-footer { color: white; margin-top: 0; }
|
||||||
|
.card-uas .card-num { color: rgba(255,255,255,0.08); }
|
||||||
|
.card-uas .card-footer .arrow { background: rgba(255,255,255,0.2); color: white; }
|
||||||
|
.card-uas:hover .card-footer .arrow { background: white; color: var(--primary); }
|
||||||
|
|
||||||
|
.card-uas-text { flex: 1; }
|
||||||
|
|
||||||
|
/* ── Footer ── */
|
||||||
|
.footer {
|
||||||
|
position: relative;
|
||||||
|
z-index: 1;
|
||||||
|
margin-top: auto;
|
||||||
|
padding: 24px 32px;
|
||||||
|
border-top: 1px solid var(--border);
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: space-between;
|
||||||
|
font-size: 0.8rem;
|
||||||
|
color: var(--text-muted);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ══ ANIMATIONS ══ */
|
||||||
|
@keyframes fadeSlideDown {
|
||||||
|
from { opacity: 0; transform: translateY(-12px); }
|
||||||
|
to { opacity: 1; transform: translateY(0); }
|
||||||
|
}
|
||||||
|
|
||||||
|
.card { animation: fadeSlideUp 0.5s var(--ease) both; }
|
||||||
|
.card:nth-child(1) { animation-delay: 0.15s; }
|
||||||
|
.card:nth-child(2) { animation-delay: 0.2s; }
|
||||||
|
.card:nth-child(3) { animation-delay: 0.25s; }
|
||||||
|
.card:nth-child(4) { animation-delay: 0.3s; }
|
||||||
|
|
||||||
|
@keyframes fadeSlideUp {
|
||||||
|
from { opacity: 0; transform: translateY(20px); }
|
||||||
|
to { opacity: 1; transform: translateY(0); }
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ══ RESPONSIVE ══ */
|
||||||
|
@media (max-width: 900px) {
|
||||||
|
.grid { grid-template-columns: 1fr 1fr; }
|
||||||
|
.card-uas { flex-direction: column; text-align: center; }
|
||||||
|
.card-uas .card-footer { justify-content: center; }
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 600px) {
|
||||||
|
.grid { grid-template-columns: 1fr; }
|
||||||
|
.navbar { padding: 0 16px; }
|
||||||
|
.hero { padding: 48px 16px 40px; }
|
||||||
|
.stats-bar { gap: 20px; }
|
||||||
|
.stat-divider { display: none; }
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
|
||||||
|
<!-- Ambient orbs -->
|
||||||
|
<div class="orb orb-1"></div>
|
||||||
|
<div class="orb orb-2"></div>
|
||||||
|
|
||||||
|
<!-- Navbar -->
|
||||||
|
<nav class="navbar">
|
||||||
|
<a href="#" class="navbar-brand">
|
||||||
|
<div class="brand-icon"><i class="fas fa-map-marked-alt"></i></div>
|
||||||
|
WebGIS Portal
|
||||||
|
</a>
|
||||||
|
<div class="navbar-right">
|
||||||
|
<span class="nav-pill">SIG 2024/2025</span>
|
||||||
|
<button class="theme-toggle" id="themeToggle" title="Toggle tema" aria-label="Toggle dark/light mode">
|
||||||
|
<i class="fas fa-moon" id="themeIcon"></i>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</nav>
|
||||||
|
|
||||||
|
<!-- Hero -->
|
||||||
|
<section class="hero">
|
||||||
|
<div class="hero-badge">
|
||||||
|
<i class="fas fa-satellite-dish"></i>
|
||||||
|
Sistem Informasi Geografis
|
||||||
|
</div>
|
||||||
|
<h1>
|
||||||
|
Direktori Proyek<br>
|
||||||
|
<span class="gradient-text">WebGIS Interaktif</span>
|
||||||
|
</h1>
|
||||||
|
<p>Kumpulan modul pembelajaran dan proyek akhir mata kuliah Sistem Informasi Geografis. Pilih modul untuk memulai eksplorasi.</p>
|
||||||
|
|
||||||
|
<div class="stats-bar">
|
||||||
|
<div class="stat-item">
|
||||||
|
<div class="stat-value">3</div>
|
||||||
|
<div class="stat-label">Modul Praktikum</div>
|
||||||
|
</div>
|
||||||
|
<div class="stat-divider"></div>
|
||||||
|
<div class="stat-item">
|
||||||
|
<div class="stat-value">1</div>
|
||||||
|
<div class="stat-label">Proyek Akhir</div>
|
||||||
|
</div>
|
||||||
|
<div class="stat-divider"></div>
|
||||||
|
<div class="stat-item">
|
||||||
|
<div class="stat-value">GIS</div>
|
||||||
|
<div class="stat-label">Teknologi</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
|
||||||
|
<!-- Grid -->
|
||||||
|
<div class="grid-section">
|
||||||
|
<div class="section-label">Modul Pembelajaran</div>
|
||||||
|
|
||||||
|
<div class="grid">
|
||||||
|
<!-- Pertemuan 01 -->
|
||||||
|
<a href="01/frontend/" class="card" data-type="p01">
|
||||||
|
<span class="card-num">01</span>
|
||||||
|
<div class="card-icon-wrap">
|
||||||
|
<i class="fas fa-draw-polygon"></i>
|
||||||
|
</div>
|
||||||
|
<div class="card-tag">Pertemuan 01</div>
|
||||||
|
<h2 class="card-title">Geometri Dasar</h2>
|
||||||
|
<p class="card-desc">Menggambar dan mengelola geometri spasial: titik (SPBU), garis (Jalan), dan poligon (Kavling) dengan operasi CRUD.</p>
|
||||||
|
<div class="card-footer">
|
||||||
|
Buka Modul
|
||||||
|
<div class="arrow"><i class="fas fa-arrow-right"></i></div>
|
||||||
|
</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<!-- Pertemuan 02 -->
|
||||||
|
<a href="02/frontend/" class="card" data-type="p02">
|
||||||
|
<span class="card-num">02</span>
|
||||||
|
<div class="card-icon-wrap">
|
||||||
|
<i class="fas fa-route"></i>
|
||||||
|
</div>
|
||||||
|
<div class="card-tag">Pertemuan 02</div>
|
||||||
|
<h2 class="card-title">Haversine & Tematik</h2>
|
||||||
|
<p class="card-desc">Pemetaan sosial dengan analisis radius jarak Haversine dan visualisasi tematik data kemiskinan penduduk.</p>
|
||||||
|
<div class="card-footer">
|
||||||
|
Buka Modul
|
||||||
|
<div class="arrow"><i class="fas fa-arrow-right"></i></div>
|
||||||
|
</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<!-- Pertemuan 03 -->
|
||||||
|
<a href="03/frontend/" class="card" data-type="p03">
|
||||||
|
<span class="card-num">03</span>
|
||||||
|
<div class="card-icon-wrap">
|
||||||
|
<i class="fas fa-layer-group"></i>
|
||||||
|
</div>
|
||||||
|
<div class="card-tag">Pertemuan 03</div>
|
||||||
|
<h2 class="card-title">Analisis Spasial</h2>
|
||||||
|
<p class="card-desc">Choropleth Map dinamis berbasis Point-in-Polygon — pewarnaan otomatis area kavling oleh kepadatan warga miskin.</p>
|
||||||
|
<div class="card-footer">
|
||||||
|
Buka Modul
|
||||||
|
<div class="arrow"><i class="fas fa-arrow-right"></i></div>
|
||||||
|
</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<!-- Final UAS -->
|
||||||
|
<a href="webgis_app/" class="card card-uas" data-type="uas">
|
||||||
|
<span class="card-num">UAS</span>
|
||||||
|
<div class="card-icon-wrap">
|
||||||
|
<i class="fas fa-laptop-code"></i>
|
||||||
|
</div>
|
||||||
|
<div class="card-uas-text">
|
||||||
|
<div class="card-tag">Proyek Akhir — Final UAS</div>
|
||||||
|
<h2 class="card-title">Smart City WebGIS</h2>
|
||||||
|
<p class="card-desc">Sistem komprehensif manajemen kawasan kota dengan dashboard analitik, autentikasi peran, dan visualisasi peta interaktif real-time.</p>
|
||||||
|
<div class="card-footer" style="margin-top:20px;">
|
||||||
|
Buka Aplikasi
|
||||||
|
<div class="arrow"><i class="fas fa-arrow-right"></i></div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Footer -->
|
||||||
|
<footer class="footer">
|
||||||
|
<span>D1041231071 — Naufal Zaky Ramadhan</span>
|
||||||
|
<span>Sistem Informasi Geografis © 2025</span>
|
||||||
|
</footer>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
// ── Theme toggle ──
|
||||||
|
const html = document.documentElement;
|
||||||
|
const btn = document.getElementById('themeToggle');
|
||||||
|
const icon = document.getElementById('themeIcon');
|
||||||
|
|
||||||
|
// Persist preference
|
||||||
|
const saved = localStorage.getItem('portal-theme') || 'dark';
|
||||||
|
setTheme(saved);
|
||||||
|
|
||||||
|
btn.addEventListener('click', () => {
|
||||||
|
const next = html.getAttribute('data-theme') === 'dark' ? 'light' : 'dark';
|
||||||
|
setTheme(next);
|
||||||
|
localStorage.setItem('portal-theme', next);
|
||||||
|
});
|
||||||
|
|
||||||
|
function setTheme(t) {
|
||||||
|
html.setAttribute('data-theme', t);
|
||||||
|
icon.className = t === 'dark' ? 'fas fa-sun' : 'fas fa-moon';
|
||||||
|
btn.title = t === 'dark' ? 'Beralih ke Mode Terang' : 'Beralih ke Mode Gelap';
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
+620
-34
@@ -37,23 +37,584 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST') {
|
|||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="id">
|
<html lang="id" data-theme="dark">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<title>Login - WebGIS Smart City</title>
|
<title>Login — WebGIS Smart City</title>
|
||||||
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap" rel="stylesheet">
|
<meta name="description" content="Masuk ke sistem WebGIS Smart City Pontianak.">
|
||||||
|
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Space+Grotesk:wght@500;600;700&display=swap" rel="stylesheet">
|
||||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.0/css/all.min.css">
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.0/css/all.min.css">
|
||||||
<link rel="stylesheet" href="public_assets/css/global.css">
|
<style>
|
||||||
<link rel="stylesheet" href="public_assets/css/auth.css">
|
/* ══ DESIGN TOKENS ══ */
|
||||||
|
:root {
|
||||||
|
--font-sans: 'Inter', sans-serif;
|
||||||
|
--font-display: 'Space Grotesk', sans-serif;
|
||||||
|
--ease: cubic-bezier(0.4, 0, 0.2, 1);
|
||||||
|
--transition: all 0.25s var(--ease);
|
||||||
|
}
|
||||||
|
|
||||||
|
[data-theme="dark"] {
|
||||||
|
--bg-page: #0A0F1E;
|
||||||
|
--bg-card: #111827;
|
||||||
|
--bg-input: #1A2234;
|
||||||
|
--border: rgba(255,255,255,0.08);
|
||||||
|
--border-focus: #6366F1;
|
||||||
|
--text-primary: #F1F5F9;
|
||||||
|
--text-secondary:#94A3B8;
|
||||||
|
--text-muted: #64748B;
|
||||||
|
--primary: #6366F1;
|
||||||
|
--primary-dark: #4F46E5;
|
||||||
|
--primary-glow: rgba(99,102,241,0.25);
|
||||||
|
--accent: #06B6D4;
|
||||||
|
--error-bg: rgba(244,63,94,0.12);
|
||||||
|
--error-border: rgba(244,63,94,0.3);
|
||||||
|
--error-text: #FB7185;
|
||||||
|
--role-border: rgba(255,255,255,0.08);
|
||||||
|
--role-active-bg: rgba(99,102,241,0.15);
|
||||||
|
--role-active-border: #6366F1;
|
||||||
|
--shadow-card: 0 8px 48px rgba(0,0,0,0.5);
|
||||||
|
--dot-color: rgba(255,255,255,0.03);
|
||||||
|
}
|
||||||
|
|
||||||
|
[data-theme="light"] {
|
||||||
|
--bg-page: #EEF2FF;
|
||||||
|
--bg-card: #FFFFFF;
|
||||||
|
--bg-input: #F8FAFF;
|
||||||
|
--border: #E2E8F0;
|
||||||
|
--border-focus: #4F46E5;
|
||||||
|
--text-primary: #0F172A;
|
||||||
|
--text-secondary:#475569;
|
||||||
|
--text-muted: #94A3B8;
|
||||||
|
--primary: #4F46E5;
|
||||||
|
--primary-dark: #3730A3;
|
||||||
|
--primary-glow: rgba(79,70,229,0.12);
|
||||||
|
--accent: #0891B2;
|
||||||
|
--error-bg: #FFF1F2;
|
||||||
|
--error-border: #FECDD3;
|
||||||
|
--error-text: #BE123C;
|
||||||
|
--role-border: #E2E8F0;
|
||||||
|
--role-active-bg: #EEF2FF;
|
||||||
|
--role-active-border: #4F46E5;
|
||||||
|
--shadow-card: 0 8px 48px rgba(79,70,229,0.1);
|
||||||
|
--dot-color: rgba(79,70,229,0.04);
|
||||||
|
}
|
||||||
|
|
||||||
|
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
|
||||||
|
html { scroll-behavior: smooth; }
|
||||||
|
|
||||||
|
body {
|
||||||
|
font-family: var(--font-sans);
|
||||||
|
background: var(--bg-page);
|
||||||
|
color: var(--text-primary);
|
||||||
|
min-height: 100vh;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
-webkit-font-smoothing: antialiased;
|
||||||
|
transition: background 0.3s var(--ease), color 0.3s var(--ease);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Dot grid */
|
||||||
|
body::before {
|
||||||
|
content: '';
|
||||||
|
position: fixed;
|
||||||
|
inset: 0;
|
||||||
|
background-image: radial-gradient(circle, var(--dot-color) 1px, transparent 1px);
|
||||||
|
background-size: 28px 28px;
|
||||||
|
pointer-events: none;
|
||||||
|
z-index: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Ambient glow */
|
||||||
|
.orb {
|
||||||
|
position: fixed;
|
||||||
|
border-radius: 50%;
|
||||||
|
filter: blur(100px);
|
||||||
|
pointer-events: none;
|
||||||
|
z-index: 0;
|
||||||
|
}
|
||||||
|
.orb-1 { width: 400px; height: 400px; background: var(--primary-glow); top: -80px; right: -80px; opacity: 0.7; }
|
||||||
|
.orb-2 { width: 300px; height: 300px; background: rgba(6,182,212,0.08); bottom: -60px; left: -60px; opacity: 0.6; }
|
||||||
|
|
||||||
|
/* ── Top Bar ── */
|
||||||
|
.topbar {
|
||||||
|
position: sticky;
|
||||||
|
top: 0;
|
||||||
|
z-index: 100;
|
||||||
|
width: 100%;
|
||||||
|
padding: 0 24px;
|
||||||
|
height: 60px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: space-between;
|
||||||
|
background: transparent;
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn-back {
|
||||||
|
display: inline-flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 8px;
|
||||||
|
padding: 8px 16px;
|
||||||
|
border-radius: 10px;
|
||||||
|
border: 1px solid var(--border);
|
||||||
|
background: var(--bg-card);
|
||||||
|
color: var(--text-secondary);
|
||||||
|
font-size: 0.85rem;
|
||||||
|
font-weight: 500;
|
||||||
|
cursor: pointer;
|
||||||
|
text-decoration: none;
|
||||||
|
transition: var(--transition);
|
||||||
|
}
|
||||||
|
.btn-back:hover {
|
||||||
|
background: var(--primary);
|
||||||
|
border-color: var(--primary);
|
||||||
|
color: white;
|
||||||
|
transform: translateX(-2px);
|
||||||
|
}
|
||||||
|
.btn-back i { font-size: 0.75rem; }
|
||||||
|
|
||||||
|
.theme-toggle {
|
||||||
|
width: 38px;
|
||||||
|
height: 38px;
|
||||||
|
border-radius: 10px;
|
||||||
|
border: 1px solid var(--border);
|
||||||
|
background: var(--bg-card);
|
||||||
|
color: var(--text-secondary);
|
||||||
|
cursor: pointer;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
font-size: 0.95rem;
|
||||||
|
transition: var(--transition);
|
||||||
|
}
|
||||||
|
.theme-toggle:hover {
|
||||||
|
background: var(--primary);
|
||||||
|
border-color: var(--primary);
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Main Layout ── */
|
||||||
|
.login-page {
|
||||||
|
position: relative;
|
||||||
|
z-index: 1;
|
||||||
|
flex: 1;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
padding: 24px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.login-container {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: 1fr 1fr;
|
||||||
|
width: 100%;
|
||||||
|
max-width: 960px;
|
||||||
|
background: var(--bg-card);
|
||||||
|
border: 1px solid var(--border);
|
||||||
|
border-radius: 24px;
|
||||||
|
box-shadow: var(--shadow-card);
|
||||||
|
overflow: hidden;
|
||||||
|
animation: fadeIn 0.4s var(--ease) both;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Left panel (branding) ── */
|
||||||
|
.login-left {
|
||||||
|
background: linear-gradient(145deg, var(--primary) 0%, #4338CA 60%, #312E81 100%);
|
||||||
|
padding: 48px 40px;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
justify-content: space-between;
|
||||||
|
position: relative;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
.login-left::before {
|
||||||
|
content: '';
|
||||||
|
position: absolute;
|
||||||
|
width: 300px;
|
||||||
|
height: 300px;
|
||||||
|
border-radius: 50%;
|
||||||
|
background: rgba(255,255,255,0.06);
|
||||||
|
bottom: -80px;
|
||||||
|
right: -80px;
|
||||||
|
}
|
||||||
|
.login-left::after {
|
||||||
|
content: '';
|
||||||
|
position: absolute;
|
||||||
|
width: 180px;
|
||||||
|
height: 180px;
|
||||||
|
border-radius: 50%;
|
||||||
|
background: rgba(255,255,255,0.04);
|
||||||
|
top: -40px;
|
||||||
|
left: -40px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.left-brand {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.brand-icon {
|
||||||
|
width: 44px;
|
||||||
|
height: 44px;
|
||||||
|
background: rgba(255,255,255,0.15);
|
||||||
|
border-radius: 12px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
font-size: 1.2rem;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
.brand-name {
|
||||||
|
font-family: var(--font-display);
|
||||||
|
font-size: 1.1rem;
|
||||||
|
font-weight: 700;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
.left-body {
|
||||||
|
position: relative;
|
||||||
|
z-index: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
.left-title {
|
||||||
|
font-family: var(--font-display);
|
||||||
|
font-size: 2rem;
|
||||||
|
font-weight: 700;
|
||||||
|
color: white;
|
||||||
|
line-height: 1.2;
|
||||||
|
margin-bottom: 16px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.left-desc {
|
||||||
|
font-size: 0.9rem;
|
||||||
|
color: rgba(255,255,255,0.7);
|
||||||
|
line-height: 1.7;
|
||||||
|
margin-bottom: 32px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.feature-list {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
gap: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.feature-item {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 12px;
|
||||||
|
font-size: 0.85rem;
|
||||||
|
color: rgba(255,255,255,0.85);
|
||||||
|
}
|
||||||
|
|
||||||
|
.feature-icon {
|
||||||
|
width: 32px;
|
||||||
|
height: 32px;
|
||||||
|
border-radius: 8px;
|
||||||
|
background: rgba(255,255,255,0.12);
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
font-size: 0.85rem;
|
||||||
|
flex-shrink: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.left-footer {
|
||||||
|
position: relative;
|
||||||
|
z-index: 1;
|
||||||
|
font-size: 0.75rem;
|
||||||
|
color: rgba(255,255,255,0.4);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Right panel (form) ── */
|
||||||
|
.login-right {
|
||||||
|
padding: 48px 44px;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.form-header {
|
||||||
|
margin-bottom: 32px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.form-title {
|
||||||
|
font-family: var(--font-display);
|
||||||
|
font-size: 1.8rem;
|
||||||
|
font-weight: 700;
|
||||||
|
color: var(--text-primary);
|
||||||
|
letter-spacing: -0.02em;
|
||||||
|
margin-bottom: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.form-subtitle {
|
||||||
|
font-size: 0.9rem;
|
||||||
|
color: var(--text-secondary);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Role selector ── */
|
||||||
|
.role-selector {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: 1fr 1fr;
|
||||||
|
gap: 10px;
|
||||||
|
margin-bottom: 28px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.role-card { position: relative; cursor: pointer; }
|
||||||
|
|
||||||
|
.role-card input[type="radio"] {
|
||||||
|
position: absolute;
|
||||||
|
opacity: 0;
|
||||||
|
width: 0; height: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.role-card-label {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: center;
|
||||||
|
gap: 6px;
|
||||||
|
padding: 14px 10px;
|
||||||
|
border-radius: 12px;
|
||||||
|
border: 1.5px solid var(--role-border);
|
||||||
|
background: transparent;
|
||||||
|
cursor: pointer;
|
||||||
|
transition: var(--transition);
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.role-card input:checked + .role-card-label {
|
||||||
|
border-color: var(--role-active-border);
|
||||||
|
background: var(--role-active-bg);
|
||||||
|
}
|
||||||
|
|
||||||
|
.role-card-label:hover {
|
||||||
|
border-color: var(--border-focus);
|
||||||
|
background: var(--role-active-bg);
|
||||||
|
}
|
||||||
|
|
||||||
|
.role-card-icon {
|
||||||
|
font-size: 1.3rem;
|
||||||
|
line-height: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
.role-card input:checked + .role-card-label .role-card-icon {
|
||||||
|
color: var(--primary);
|
||||||
|
}
|
||||||
|
|
||||||
|
.role-card-name {
|
||||||
|
font-size: 0.85rem;
|
||||||
|
font-weight: 600;
|
||||||
|
color: var(--text-primary);
|
||||||
|
}
|
||||||
|
|
||||||
|
.role-card input:checked + .role-card-label .role-card-name {
|
||||||
|
color: var(--primary);
|
||||||
|
}
|
||||||
|
|
||||||
|
.role-card-desc {
|
||||||
|
font-size: 0.72rem;
|
||||||
|
color: var(--text-muted);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Error alert ── */
|
||||||
|
.alert-error {
|
||||||
|
background: var(--error-bg);
|
||||||
|
border: 1px solid var(--error-border);
|
||||||
|
border-radius: 10px;
|
||||||
|
padding: 12px 16px;
|
||||||
|
color: var(--error-text);
|
||||||
|
font-size: 0.875rem;
|
||||||
|
margin-bottom: 20px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 10px;
|
||||||
|
animation: shake 0.4s var(--ease);
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes shake {
|
||||||
|
0%, 100% { transform: translateX(0); }
|
||||||
|
20% { transform: translateX(-6px); }
|
||||||
|
40% { transform: translateX(6px); }
|
||||||
|
60% { transform: translateX(-4px); }
|
||||||
|
80% { transform: translateX(4px); }
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Form fields ── */
|
||||||
|
.field-group {
|
||||||
|
margin-bottom: 18px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.field-label {
|
||||||
|
display: block;
|
||||||
|
font-size: 0.82rem;
|
||||||
|
font-weight: 600;
|
||||||
|
color: var(--text-primary);
|
||||||
|
margin-bottom: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.field-wrap {
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
.field-icon {
|
||||||
|
position: absolute;
|
||||||
|
left: 14px;
|
||||||
|
top: 50%;
|
||||||
|
transform: translateY(-50%);
|
||||||
|
color: var(--text-muted);
|
||||||
|
font-size: 0.9rem;
|
||||||
|
pointer-events: none;
|
||||||
|
transition: color 0.2s;
|
||||||
|
}
|
||||||
|
|
||||||
|
.field-control {
|
||||||
|
width: 100%;
|
||||||
|
padding: 11px 14px 11px 40px;
|
||||||
|
border-radius: 10px;
|
||||||
|
border: 1.5px solid var(--border);
|
||||||
|
background: var(--bg-input);
|
||||||
|
color: var(--text-primary);
|
||||||
|
font-size: 0.9rem;
|
||||||
|
font-family: var(--font-sans);
|
||||||
|
outline: none;
|
||||||
|
transition: var(--transition);
|
||||||
|
}
|
||||||
|
|
||||||
|
.field-control:focus {
|
||||||
|
border-color: var(--border-focus);
|
||||||
|
box-shadow: 0 0 0 3px var(--primary-glow);
|
||||||
|
}
|
||||||
|
|
||||||
|
.field-control:focus ~ .field-icon,
|
||||||
|
.field-wrap:focus-within .field-icon {
|
||||||
|
color: var(--primary);
|
||||||
|
}
|
||||||
|
|
||||||
|
.field-control::placeholder { color: var(--text-muted); }
|
||||||
|
|
||||||
|
.btn-eye {
|
||||||
|
position: absolute;
|
||||||
|
right: 12px;
|
||||||
|
top: 50%;
|
||||||
|
transform: translateY(-50%);
|
||||||
|
background: none;
|
||||||
|
border: none;
|
||||||
|
color: var(--text-muted);
|
||||||
|
cursor: pointer;
|
||||||
|
padding: 4px;
|
||||||
|
border-radius: 6px;
|
||||||
|
font-size: 0.9rem;
|
||||||
|
transition: color 0.2s;
|
||||||
|
}
|
||||||
|
.btn-eye:hover { color: var(--primary); }
|
||||||
|
|
||||||
|
/* ── Submit button ── */
|
||||||
|
.btn-login {
|
||||||
|
width: 100%;
|
||||||
|
padding: 13px;
|
||||||
|
border-radius: 10px;
|
||||||
|
border: none;
|
||||||
|
background: linear-gradient(135deg, var(--primary), var(--primary-dark));
|
||||||
|
color: white;
|
||||||
|
font-size: 0.95rem;
|
||||||
|
font-weight: 600;
|
||||||
|
font-family: var(--font-sans);
|
||||||
|
cursor: pointer;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
gap: 8px;
|
||||||
|
transition: var(--transition);
|
||||||
|
box-shadow: 0 4px 12px var(--primary-glow);
|
||||||
|
margin-top: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn-login:hover {
|
||||||
|
transform: translateY(-2px);
|
||||||
|
box-shadow: 0 8px 20px var(--primary-glow);
|
||||||
|
filter: brightness(1.05);
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn-login:active {
|
||||||
|
transform: translateY(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Animations ── */
|
||||||
|
@keyframes fadeIn {
|
||||||
|
from { opacity: 0; transform: scale(0.97) translateY(12px); }
|
||||||
|
to { opacity: 1; transform: scale(1) translateY(0); }
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Responsive ── */
|
||||||
|
@media (max-width: 768px) {
|
||||||
|
.login-container { grid-template-columns: 1fr; }
|
||||||
|
.login-left { display: none; }
|
||||||
|
.login-right { padding: 36px 28px; }
|
||||||
|
}
|
||||||
|
</style>
|
||||||
</head>
|
</head>
|
||||||
<body class="auth-page">
|
<body>
|
||||||
|
|
||||||
<div class="auth-center">
|
<div class="orb orb-1"></div>
|
||||||
<div class="auth-form-wrap">
|
<div class="orb orb-2"></div>
|
||||||
<h2 class="auth-form-title">Selamat Datang</h2>
|
|
||||||
<p class="auth-form-subtitle">Masuk ke sistem WebGIS Smart City Pontianak.</p>
|
|
||||||
|
|
||||||
|
<!-- Top bar -->
|
||||||
|
<div class="topbar">
|
||||||
|
<a href="../portal.html" class="btn-back" id="backToPortal">
|
||||||
|
<i class="fas fa-chevron-left"></i>
|
||||||
|
Kembali ke Portal
|
||||||
|
</a>
|
||||||
|
<button class="theme-toggle" id="themeToggle" title="Toggle tema" aria-label="Toggle dark/light mode">
|
||||||
|
<i class="fas fa-moon" id="themeIcon"></i>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Login page -->
|
||||||
|
<main class="login-page">
|
||||||
|
<div class="login-container">
|
||||||
|
|
||||||
|
<!-- Left branding -->
|
||||||
|
<div class="login-left">
|
||||||
|
<div class="left-brand">
|
||||||
|
<div class="brand-icon"><i class="fas fa-map-marked-alt"></i></div>
|
||||||
|
<span class="brand-name">WebGIS Smart City</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="left-body">
|
||||||
|
<h2 class="left-title">Selamat Datang di<br>Sistem Informasi Geografis</h2>
|
||||||
|
<p class="left-desc">Platform manajemen data spasial kawasan kota Pontianak dengan visualisasi peta interaktif real-time.</p>
|
||||||
|
|
||||||
|
<div class="feature-list">
|
||||||
|
<div class="feature-item">
|
||||||
|
<div class="feature-icon"><i class="fas fa-map"></i></div>
|
||||||
|
Peta Interaktif Real-time
|
||||||
|
</div>
|
||||||
|
<div class="feature-item">
|
||||||
|
<div class="feature-icon"><i class="fas fa-chart-bar"></i></div>
|
||||||
|
Dashboard Analitik
|
||||||
|
</div>
|
||||||
|
<div class="feature-item">
|
||||||
|
<div class="feature-icon"><i class="fas fa-shield-alt"></i></div>
|
||||||
|
Autentikasi Multi-Peran
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="left-footer">
|
||||||
|
D1041231071 — Naufal Zaky Ramadhan © 2025
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Right form -->
|
||||||
|
<div class="login-right">
|
||||||
|
<div class="form-header">
|
||||||
|
<h1 class="form-title">Masuk ke Sistem</h1>
|
||||||
|
<p class="form-subtitle">Pilih peran dan masukkan kredensial Anda.</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Role selector -->
|
||||||
<div class="role-selector">
|
<div class="role-selector">
|
||||||
<label class="role-card">
|
<label class="role-card">
|
||||||
<input type="radio" name="role_display" value="admin" checked>
|
<input type="radio" name="role_display" value="admin" checked>
|
||||||
@@ -68,63 +629,88 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST') {
|
|||||||
<div class="role-card-label">
|
<div class="role-card-label">
|
||||||
<div class="role-card-icon"><i class="fas fa-user"></i></div>
|
<div class="role-card-icon"><i class="fas fa-user"></i></div>
|
||||||
<div class="role-card-name">Pengguna</div>
|
<div class="role-card-name">Pengguna</div>
|
||||||
<div class="role-card-desc">Lihat & analisis peta</div>
|
<div class="role-card-desc">Lihat & analisis peta</div>
|
||||||
</div>
|
</div>
|
||||||
</label>
|
</label>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<?php if ($error): ?>
|
<?php if ($error): ?>
|
||||||
<div class="auth-error">
|
<div class="alert-error">
|
||||||
<i class="fas fa-exclamation-circle"></i>
|
<i class="fas fa-exclamation-circle"></i>
|
||||||
<?= htmlspecialchars($error) ?>
|
<?= htmlspecialchars($error) ?>
|
||||||
</div>
|
</div>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
|
<form method="POST" autocomplete="on">
|
||||||
<form method="POST" class="auth-form">
|
<div class="field-group">
|
||||||
<div class="form-group">
|
<label class="field-label" for="usernameInput">Username</label>
|
||||||
<label class="form-label">Username</label>
|
<div class="field-wrap">
|
||||||
<div class="input-with-icon">
|
<i class="fas fa-user field-icon"></i>
|
||||||
<i class="fas fa-user input-icon"></i>
|
<input type="text" name="username" id="usernameInput" class="field-control"
|
||||||
<input type="text" name="username" class="form-control"
|
|
||||||
placeholder="Masukkan username"
|
placeholder="Masukkan username"
|
||||||
value="<?= htmlspecialchars($_POST['username'] ?? '') ?>"
|
value="<?= htmlspecialchars($_POST['username'] ?? '') ?>"
|
||||||
required autocomplete="username">
|
required autocomplete="username">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
|
||||||
<label class="form-label">Password</label>
|
<div class="field-group">
|
||||||
<div class="input-with-icon">
|
<label class="field-label" for="passwordInput">Password</label>
|
||||||
<i class="fas fa-lock input-icon"></i>
|
<div class="field-wrap">
|
||||||
<input type="password" name="password" class="form-control"
|
<i class="fas fa-lock field-icon"></i>
|
||||||
|
<input type="password" name="password" id="passwordInput" class="field-control"
|
||||||
placeholder="Masukkan password"
|
placeholder="Masukkan password"
|
||||||
required autocomplete="current-password"
|
required autocomplete="current-password">
|
||||||
id="passwordInput">
|
<button type="button" class="btn-eye" onclick="togglePass()" aria-label="Toggle password visibility">
|
||||||
<button type="button" class="input-icon" style="right:12px;left:auto;cursor:pointer;background:none;border:none;color:var(--text-muted);" onclick="togglePass()">
|
|
||||||
<i class="fas fa-eye" id="eyeIcon"></i>
|
<i class="fas fa-eye" id="eyeIcon"></i>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<button type="submit" class="btn btn-primary btn-login">
|
|
||||||
|
<button type="submit" class="btn-login" id="loginBtn">
|
||||||
<i class="fas fa-sign-in-alt"></i>
|
<i class="fas fa-sign-in-alt"></i>
|
||||||
Masuk ke Sistem
|
Masuk ke Sistem
|
||||||
</button>
|
</button>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
</main>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
// ── Password toggle ──
|
||||||
function togglePass() {
|
function togglePass() {
|
||||||
const inp = document.getElementById('passwordInput');
|
const inp = document.getElementById('passwordInput');
|
||||||
const ico = document.getElementById('eyeIcon');
|
const ico = document.getElementById('eyeIcon');
|
||||||
if (inp.type === 'password') {
|
const isPass = inp.type === 'password';
|
||||||
inp.type = 'text';
|
inp.type = isPass ? 'text' : 'password';
|
||||||
ico.className = 'fas fa-eye-slash';
|
ico.className = isPass ? 'fas fa-eye-slash' : 'fas fa-eye';
|
||||||
} else {
|
|
||||||
inp.type = 'password';
|
|
||||||
ico.className = 'fas fa-eye';
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// ── Theme toggle ──
|
||||||
|
const html = document.documentElement;
|
||||||
|
const btn = document.getElementById('themeToggle');
|
||||||
|
const icon = document.getElementById('themeIcon');
|
||||||
|
|
||||||
|
const saved = localStorage.getItem('portal-theme') || 'dark';
|
||||||
|
setTheme(saved);
|
||||||
|
|
||||||
|
btn.addEventListener('click', () => {
|
||||||
|
const next = html.getAttribute('data-theme') === 'dark' ? 'light' : 'dark';
|
||||||
|
setTheme(next);
|
||||||
|
localStorage.setItem('portal-theme', next);
|
||||||
|
});
|
||||||
|
|
||||||
|
function setTheme(t) {
|
||||||
|
html.setAttribute('data-theme', t);
|
||||||
|
icon.className = t === 'dark' ? 'fas fa-sun' : 'fas fa-moon';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// ── Loading state on submit ──
|
||||||
|
document.querySelector('form').addEventListener('submit', function() {
|
||||||
|
const loginBtn = document.getElementById('loginBtn');
|
||||||
|
loginBtn.innerHTML = '<i class="fas fa-spinner fa-spin"></i> Memproses...';
|
||||||
|
loginBtn.disabled = true;
|
||||||
|
});
|
||||||
</script>
|
</script>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?php
|
<?php
|
||||||
require_once __DIR__ . '/../core_config/database.php';
|
require_once __DIR__ . '/../core_config/database.php';
|
||||||
require_once __DIR__ . '/../core_config/middleware_auth.php';
|
require_once __DIR__ . '/../core_config/middleware_auth.php';
|
||||||
requireRole('admin');
|
requireRole('admin');
|
||||||
@@ -47,11 +47,11 @@ require_once __DIR__ . '/partials/header.php';
|
|||||||
?>
|
?>
|
||||||
|
|
||||||
<!-- ── Quick Access Map ── -->
|
<!-- ── Quick Access Map ── -->
|
||||||
<div class="card" style="background: #EFF6FF; border: 1px solid #BFDBFE; margin-bottom: 24px;">
|
<div class="card" style="background: var(--primary-glow); border: 1px solid var(--primary-light); margin-bottom: 24px;">
|
||||||
<div style="display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:16px;">
|
<div style="display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:16px;">
|
||||||
<div>
|
<div>
|
||||||
<h3 style="font-size:1.1rem; font-weight:700; margin-bottom:6px; color:#1E3A8A;">🗺️ Buka Peta Interaktif</h3>
|
<h3 style="font-size:1.1rem; font-weight:700; margin-bottom:6px; color:var(--text-primary);">🗺️ Buka Peta Interaktif</h3>
|
||||||
<p style="color:#3B82F6; font-size:0.88rem; max-width:500px;">
|
<p style="color:var(--text-secondary); font-size:0.88rem; max-width:500px;">
|
||||||
Tambahkan, edit, dan analisis data spasial langsung di peta. Mendukung drawing tool untuk semua layer data.
|
Tambahkan, edit, dan analisis data spasial langsung di peta. Mendukung drawing tool untuk semua layer data.
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
@@ -127,9 +127,9 @@ require_once __DIR__ . '/partials/header.php';
|
|||||||
<?php if ($recentSpbu): ?>
|
<?php if ($recentSpbu): ?>
|
||||||
<div style="display:flex; flex-direction:column; gap:8px;">
|
<div style="display:flex; flex-direction:column; gap:8px;">
|
||||||
<?php foreach ($recentSpbu as $s): ?>
|
<?php foreach ($recentSpbu as $s): ?>
|
||||||
<div style="display:flex; align-items:center; justify-content:space-between; padding:10px 12px; background:#F9FAFB; border:1px solid #E5E7EB; border-radius:8px;">
|
<div style="display:flex; align-items:center; justify-content:space-between; padding:10px 12px; background:var(--bg-elevated); border:1px solid var(--border-light); border-radius:8px;">
|
||||||
<div>
|
<div>
|
||||||
<div style="font-weight:600; font-size:0.88rem;"><?= htmlspecialchars($s['nama']) ?></div>
|
<div style="font-weight:600; font-size:0.88rem; color:var(--text-primary);"><?= htmlspecialchars($s['nama']) ?></div>
|
||||||
<div style="font-size:0.75rem; color:var(--text-muted);"><?= date('d M Y', strtotime($s['created_at'])) ?></div>
|
<div style="font-size:0.75rem; color:var(--text-muted);"><?= date('d M Y', strtotime($s['created_at'])) ?></div>
|
||||||
</div>
|
</div>
|
||||||
<span class="badge <?= $s['buka_24_jam'] ? 'badge-success' : 'badge-danger' ?>">
|
<span class="badge <?= $s['buka_24_jam'] ? 'badge-success' : 'badge-danger' ?>">
|
||||||
@@ -152,9 +152,9 @@ require_once __DIR__ . '/partials/header.php';
|
|||||||
<?php if ($recentWarga): ?>
|
<?php if ($recentWarga): ?>
|
||||||
<div style="display:flex; flex-direction:column; gap:8px;">
|
<div style="display:flex; flex-direction:column; gap:8px;">
|
||||||
<?php foreach ($recentWarga as $w): ?>
|
<?php foreach ($recentWarga as $w): ?>
|
||||||
<div style="display:flex; align-items:center; justify-content:space-between; padding:10px 12px; background:#F9FAFB; border:1px solid #E5E7EB; border-radius:8px;">
|
<div style="display:flex; align-items:center; justify-content:space-between; padding:10px 12px; background:var(--bg-elevated); border:1px solid var(--border-light); border-radius:8px;">
|
||||||
<div>
|
<div>
|
||||||
<div style="font-weight:600; font-size:0.88rem;"><?= htmlspecialchars($w['nama_kk']) ?></div>
|
<div style="font-weight:600; font-size:0.88rem; color:var(--text-primary);"><?= htmlspecialchars($w['nama_kk']) ?></div>
|
||||||
<div style="font-size:0.75rem; color:var(--text-muted);">Rp <?= number_format($w['penghasilan'],0,',','.') ?>/bln · <?= $w['jumlah_tanggungan'] ?> tanggungan</div>
|
<div style="font-size:0.75rem; color:var(--text-muted);">Rp <?= number_format($w['penghasilan'],0,',','.') ?>/bln · <?= $w['jumlah_tanggungan'] ?> tanggungan</div>
|
||||||
</div>
|
</div>
|
||||||
<span class="badge badge-warning"><?= $w['jumlah_tanggungan'] ?> org</span>
|
<span class="badge badge-warning"><?= $w['jumlah_tanggungan'] ?> org</span>
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?php
|
<?php
|
||||||
require_once __DIR__ . '/../core_config/database.php';
|
require_once __DIR__ . '/../core_config/database.php';
|
||||||
require_once __DIR__ . '/../core_config/middleware_auth.php';
|
require_once __DIR__ . '/../core_config/middleware_auth.php';
|
||||||
requireRole('admin');
|
requireRole('admin');
|
||||||
@@ -64,10 +64,10 @@ foreach($rows as $r) {
|
|||||||
</div>
|
</div>
|
||||||
<div class="form-group"><label class="form-label">Radius Bantuan (meter) *</label><input type="number" name="radius_bantuan_meter" class="form-control" min="100" max="10000" step="50" value="1000" required></div>
|
<div class="form-group"><label class="form-label">Radius Bantuan (meter) *</label><input type="number" name="radius_bantuan_meter" class="form-control" min="100" max="10000" step="50" value="1000" required></div>
|
||||||
<div class="form-group"><label class="form-label">Pilih Lokasi di Peta</label>
|
<div class="form-group"><label class="form-label">Pilih Lokasi di Peta</label>
|
||||||
<div id="miniMapTambah" style="height:200px;border-radius:8px;border:1px solid #E5E7EB;margin-bottom:10px;z-index:1;"></div>
|
<div id="miniMapTambah" style="height:200px;border-radius:8px;border:1px solid var(--border-light);margin-bottom:10px;z-index:1;"></div>
|
||||||
<div style="display:grid;grid-template-columns:1fr 1fr;gap:10px;">
|
<div style="display:grid;grid-template-columns:1fr 1fr;gap:10px;">
|
||||||
<input type="number" name="lat" id="latTambah" class="form-control" placeholder="Latitude" step="any" readonly style="background:#F9FAFB;">
|
<input type="number" name="lat" id="latTambah" class="form-control" placeholder="Latitude" step="any" readonly style="background:var(--bg-base); border-color:var(--border-light);">
|
||||||
<input type="number" name="lng" id="lngTambah" class="form-control" placeholder="Longitude" step="any" readonly style="background:#F9FAFB;">
|
<input type="number" name="lng" id="lngTambah" class="form-control" placeholder="Longitude" step="any" readonly style="background:var(--bg-base); border-color:var(--border-light);">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
@@ -104,7 +104,11 @@ window.openModal = function(id) {
|
|||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
if(!miniMap) {
|
if(!miniMap) {
|
||||||
miniMap = L.map('miniMapTambah').setView([-0.0583, 109.3448], 13);
|
miniMap = L.map('miniMapTambah').setView([-0.0583, 109.3448], 13);
|
||||||
L.tileLayer('https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png').addTo(miniMap);
|
const isDark = document.documentElement.getAttribute('data-theme') === 'dark';
|
||||||
|
const tileUrl = isDark
|
||||||
|
? 'https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png'
|
||||||
|
: 'https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png';
|
||||||
|
L.tileLayer(tileUrl).addTo(miniMap);
|
||||||
miniMap.on('click', function(e) {
|
miniMap.on('click', function(e) {
|
||||||
const lat = e.latlng.lat;
|
const lat = e.latlng.lat;
|
||||||
const lng = e.latlng.lng;
|
const lng = e.latlng.lng;
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?php
|
<?php
|
||||||
require_once __DIR__ . '/../core_config/database.php';
|
require_once __DIR__ . '/../core_config/database.php';
|
||||||
require_once __DIR__ . '/../core_config/middleware_auth.php';
|
require_once __DIR__ . '/../core_config/middleware_auth.php';
|
||||||
requireRole('admin');
|
requireRole('admin');
|
||||||
@@ -113,7 +113,7 @@ function badgeStatus($status) {
|
|||||||
<strong id="mapKategori"></strong><br>
|
<strong id="mapKategori"></strong><br>
|
||||||
<span style="color: var(--text-secondary);" id="mapDeskripsi"></span>
|
<span style="color: var(--text-secondary);" id="mapDeskripsi"></span>
|
||||||
</div>
|
</div>
|
||||||
<div id="miniMapLihat" style="height:300px;border-radius:8px;border:1px solid #E5E7EB;"></div>
|
<div id="miniMapLihat" style="height:300px;border-radius:8px;border:1px solid var(--border-light);"></div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -177,7 +177,11 @@ function lihatLokasi(r) {
|
|||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
if(!mapInstance) {
|
if(!mapInstance) {
|
||||||
mapInstance = L.map('miniMapLihat');
|
mapInstance = L.map('miniMapLihat');
|
||||||
L.tileLayer('https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png').addTo(mapInstance);
|
const isDark = document.documentElement.getAttribute('data-theme') === 'dark';
|
||||||
|
const tileUrl = isDark
|
||||||
|
? 'https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png'
|
||||||
|
: 'https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png';
|
||||||
|
L.tileLayer(tileUrl).addTo(mapInstance);
|
||||||
}
|
}
|
||||||
if(mapMarker) mapInstance.removeLayer(mapMarker);
|
if(mapMarker) mapInstance.removeLayer(mapMarker);
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?php
|
<?php
|
||||||
require_once __DIR__ . '/../core_config/database.php';
|
require_once __DIR__ . '/../core_config/database.php';
|
||||||
require_once __DIR__ . '/../core_config/middleware_auth.php';
|
require_once __DIR__ . '/../core_config/middleware_auth.php';
|
||||||
requireRole('admin');
|
requireRole('admin');
|
||||||
@@ -59,10 +59,10 @@ require_once __DIR__ . '/partials/header.php';
|
|||||||
<div class="form-group"><label class="form-label" style="display:flex;align-items:center;gap:10px;cursor:pointer;"><input type="checkbox" name="buka_24_jam" id="cb24jam" style="width:16px;height:16px;accent-color:var(--accent);"> Buka 24 Jam</label></div>
|
<div class="form-group"><label class="form-label" style="display:flex;align-items:center;gap:10px;cursor:pointer;"><input type="checkbox" name="buka_24_jam" id="cb24jam" style="width:16px;height:16px;accent-color:var(--accent);"> Buka 24 Jam</label></div>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="form-label">Pilih Lokasi di Peta *</label>
|
<label class="form-label">Pilih Lokasi di Peta *</label>
|
||||||
<div id="miniMapTambah" style="height:200px;border-radius:8px;border:1px solid #E5E7EB;margin-bottom:10px;z-index:1;"></div>
|
<div id="miniMapTambah" style="height:200px;border-radius:8px;border:1px solid var(--border-light);margin-bottom:10px;z-index:1;"></div>
|
||||||
<div style="display:grid;grid-template-columns:1fr 1fr;gap:10px;">
|
<div style="display:grid;grid-template-columns:1fr 1fr;gap:10px;">
|
||||||
<input type="number" name="lat" id="latTambah" class="form-control" placeholder="Latitude" step="any" required readonly style="background:#F9FAFB;">
|
<input type="number" name="lat" id="latTambah" class="form-control" placeholder="Latitude" step="any" required readonly style="background:var(--bg-base); border-color:var(--border-light);">
|
||||||
<input type="number" name="lng" id="lngTambah" class="form-control" placeholder="Longitude" step="any" required readonly style="background:#F9FAFB;">
|
<input type="number" name="lng" id="lngTambah" class="form-control" placeholder="Longitude" step="any" required readonly style="background:var(--bg-base); border-color:var(--border-light);">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
@@ -104,7 +104,11 @@ window.openModal = function(id) {
|
|||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
if(!miniMap) {
|
if(!miniMap) {
|
||||||
miniMap = L.map('miniMapTambah').setView([-0.0583, 109.3448], 13);
|
miniMap = L.map('miniMapTambah').setView([-0.0583, 109.3448], 13);
|
||||||
L.tileLayer('https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png').addTo(miniMap);
|
const isDark = document.documentElement.getAttribute('data-theme') === 'dark';
|
||||||
|
const tileUrl = isDark
|
||||||
|
? 'https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png'
|
||||||
|
: 'https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png';
|
||||||
|
L.tileLayer(tileUrl).addTo(miniMap);
|
||||||
miniMap.on('click', function(e) {
|
miniMap.on('click', function(e) {
|
||||||
const lat = e.latlng.lat;
|
const lat = e.latlng.lat;
|
||||||
const lng = e.latlng.lng;
|
const lng = e.latlng.lng;
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?php
|
<?php
|
||||||
require_once __DIR__ . '/../core_config/database.php';
|
require_once __DIR__ . '/../core_config/database.php';
|
||||||
require_once __DIR__ . '/../core_config/middleware_auth.php';
|
require_once __DIR__ . '/../core_config/middleware_auth.php';
|
||||||
requireRole('admin');
|
requireRole('admin');
|
||||||
@@ -45,10 +45,10 @@ require_once __DIR__ . '/partials/header.php';
|
|||||||
<div class="form-group"><label class="form-label">Penghasilan per Bulan (Rp)</label><input type="number" name="penghasilan" class="form-control" placeholder="0" min="0"></div>
|
<div class="form-group"><label class="form-label">Penghasilan per Bulan (Rp)</label><input type="number" name="penghasilan" class="form-control" placeholder="0" min="0"></div>
|
||||||
<div class="form-group"><label class="form-label">Jumlah Tanggungan (jiwa)</label><input type="number" name="jumlah_tanggungan" class="form-control" placeholder="0" min="0" max="20"></div>
|
<div class="form-group"><label class="form-label">Jumlah Tanggungan (jiwa)</label><input type="number" name="jumlah_tanggungan" class="form-control" placeholder="0" min="0" max="20"></div>
|
||||||
<div class="form-group"><label class="form-label">Pilih Lokasi di Peta *</label>
|
<div class="form-group"><label class="form-label">Pilih Lokasi di Peta *</label>
|
||||||
<div id="miniMapTambah" style="height:200px;border-radius:8px;border:1px solid #E5E7EB;margin-bottom:10px;z-index:1;"></div>
|
<div id="miniMapTambah" style="height:200px;border-radius:8px;border:1px solid var(--border-light);margin-bottom:10px;z-index:1;"></div>
|
||||||
<div style="display:grid;grid-template-columns:1fr 1fr;gap:10px;">
|
<div style="display:grid;grid-template-columns:1fr 1fr;gap:10px;">
|
||||||
<input type="number" name="lat" id="latTambah" class="form-control" placeholder="Latitude" step="any" required readonly style="background:#F9FAFB;">
|
<input type="number" name="lat" id="latTambah" class="form-control" placeholder="Latitude" step="any" required readonly style="background:var(--bg-base); border-color:var(--border-light);">
|
||||||
<input type="number" name="lng" id="lngTambah" class="form-control" placeholder="Longitude" step="any" required readonly style="background:#F9FAFB;">
|
<input type="number" name="lng" id="lngTambah" class="form-control" placeholder="Longitude" step="any" required readonly style="background:var(--bg-base); border-color:var(--border-light);">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
@@ -77,7 +77,11 @@ window.openModal = function(id) {
|
|||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
if(!miniMap) {
|
if(!miniMap) {
|
||||||
miniMap = L.map('miniMapTambah').setView([-0.0583, 109.3448], 13);
|
miniMap = L.map('miniMapTambah').setView([-0.0583, 109.3448], 13);
|
||||||
L.tileLayer('https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png').addTo(miniMap);
|
const isDark = document.documentElement.getAttribute('data-theme') === 'dark';
|
||||||
|
const tileUrl = isDark
|
||||||
|
? 'https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png'
|
||||||
|
: 'https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png';
|
||||||
|
L.tileLayer(tileUrl).addTo(miniMap);
|
||||||
miniMap.on('click', function(e) {
|
miniMap.on('click', function(e) {
|
||||||
const lat = e.latlng.lat;
|
const lat = e.latlng.lat;
|
||||||
const lng = e.latlng.lng;
|
const lng = e.latlng.lng;
|
||||||
|
|||||||
@@ -5,6 +5,32 @@
|
|||||||
<div class="toast-container" id="toastContainer"></div>
|
<div class="toast-container" id="toastContainer"></div>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
// ── Theme toggle ──
|
||||||
|
(function() {
|
||||||
|
const html = document.documentElement;
|
||||||
|
const saved = localStorage.getItem('portal-theme') || 'dark';
|
||||||
|
setAdminTheme(saved);
|
||||||
|
document.addEventListener('DOMContentLoaded', function() {
|
||||||
|
const btn = document.getElementById('adminThemeToggle');
|
||||||
|
const icon = document.getElementById('adminThemeIcon');
|
||||||
|
if (!btn) return;
|
||||||
|
btn.addEventListener('click', () => {
|
||||||
|
const next = html.getAttribute('data-theme') === 'dark' ? 'light' : 'dark';
|
||||||
|
setAdminTheme(next);
|
||||||
|
localStorage.setItem('portal-theme', next);
|
||||||
|
});
|
||||||
|
function updateIcon() {
|
||||||
|
if (icon) icon.className = html.getAttribute('data-theme') === 'dark' ? 'fas fa-sun' : 'fas fa-moon';
|
||||||
|
}
|
||||||
|
updateIcon();
|
||||||
|
});
|
||||||
|
function setAdminTheme(t) {
|
||||||
|
html.setAttribute('data-theme', t);
|
||||||
|
const icon = document.getElementById('adminThemeIcon');
|
||||||
|
if (icon) icon.className = t === 'dark' ? 'fas fa-sun' : 'fas fa-moon';
|
||||||
|
}
|
||||||
|
})();
|
||||||
|
|
||||||
// ── Clock ──
|
// ── Clock ──
|
||||||
function updateClock() {
|
function updateClock() {
|
||||||
const now = new Date();
|
const now = new Date();
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?php
|
<?php
|
||||||
/**
|
/**
|
||||||
* Admin Layout — sidebar + topbar
|
* Admin Layout — sidebar + topbar
|
||||||
* Include di awal setiap halaman admin setelah auth check.
|
* Include di awal setiap halaman admin setelah auth check.
|
||||||
@@ -8,7 +8,7 @@ $user = currentUser();
|
|||||||
$initial = strtoupper(substr($user['nama_lengkap'] ?: $user['username'], 0, 1));
|
$initial = strtoupper(substr($user['nama_lengkap'] ?: $user['username'], 0, 1));
|
||||||
?>
|
?>
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="id">
|
<html lang="id" data-theme="dark">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
@@ -105,6 +105,12 @@ $initial = strtoupper(substr($user['nama_lengkap'] ?: $user['username'], 0, 1));
|
|||||||
<a href="<?= app_url('panel_admin/peta_admin.php') ?>" class="btn btn-primary btn-sm">
|
<a href="<?= app_url('panel_admin/peta_admin.php') ?>" class="btn btn-primary btn-sm">
|
||||||
<i class="fas fa-map"></i> Buka Peta
|
<i class="fas fa-map"></i> Buka Peta
|
||||||
</a>
|
</a>
|
||||||
|
<button class="btn btn-ghost btn-sm" id="adminThemeToggle" title="Toggle tema" aria-label="Toggle dark/light mode" style="padding:8px 10px;">
|
||||||
|
<i class="fas fa-moon" id="adminThemeIcon"></i>
|
||||||
|
</button>
|
||||||
|
<a href="<?= app_url('../portal.html') ?>" class="btn btn-ghost btn-sm" title="Kembali ke Portal WebGIS">
|
||||||
|
<i class="fas fa-home"></i> Portal
|
||||||
|
</a>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="admin-content">
|
<div class="admin-content">
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?php
|
<?php
|
||||||
require_once __DIR__ . '/../core_config/database.php';
|
require_once __DIR__ . '/../core_config/database.php';
|
||||||
require_once __DIR__ . '/../core_config/middleware_auth.php';
|
require_once __DIR__ . '/../core_config/middleware_auth.php';
|
||||||
requireRole('user');
|
requireRole('user');
|
||||||
@@ -107,10 +107,10 @@ function badgeStatus($status) {
|
|||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="form-label">Pilih Lokasi di Peta *</label>
|
<label class="form-label">Pilih Lokasi di Peta *</label>
|
||||||
<div id="miniMapTambah" style="height:200px;border-radius:8px;border:1px solid #E5E7EB;margin-bottom:10px;z-index:1;"></div>
|
<div id="miniMapTambah" style="height:200px;border-radius:8px;border:1px solid var(--border-light);margin-bottom:10px;z-index:1;"></div>
|
||||||
<div style="display:grid;grid-template-columns:1fr 1fr;gap:10px;">
|
<div style="display:grid;grid-template-columns:1fr 1fr;gap:10px;">
|
||||||
<input type="number" name="lat" id="latTambah" class="form-control" placeholder="Latitude" step="any" required readonly style="background:#F9FAFB;">
|
<input type="number" name="lat" id="latTambah" class="form-control" placeholder="Latitude" step="any" required readonly style="background:var(--bg-base); border-color:var(--border-light);">
|
||||||
<input type="number" name="lng" id="lngTambah" class="form-control" placeholder="Longitude" step="any" required readonly style="background:#F9FAFB;">
|
<input type="number" name="lng" id="lngTambah" class="form-control" placeholder="Longitude" step="any" required readonly style="background:var(--bg-base); border-color:var(--border-light);">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
@@ -134,7 +134,11 @@ window.openModal = function(id) {
|
|||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
if(!miniMap) {
|
if(!miniMap) {
|
||||||
miniMap = L.map('miniMapTambah').setView([-0.0583, 109.3448], 13);
|
miniMap = L.map('miniMapTambah').setView([-0.0583, 109.3448], 13);
|
||||||
L.tileLayer('https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png').addTo(miniMap);
|
const isDark = document.documentElement.getAttribute('data-theme') === 'dark';
|
||||||
|
const tileUrl = isDark
|
||||||
|
? 'https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png'
|
||||||
|
: 'https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png';
|
||||||
|
L.tileLayer(tileUrl).addTo(miniMap);
|
||||||
miniMap.on('click', function(e) {
|
miniMap.on('click', function(e) {
|
||||||
const lat = e.latlng.lat;
|
const lat = e.latlng.lat;
|
||||||
const lng = e.latlng.lng;
|
const lng = e.latlng.lng;
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?php
|
<?php
|
||||||
require_once __DIR__ . '/../core_config/database.php';
|
require_once __DIR__ . '/../core_config/database.php';
|
||||||
require_once __DIR__ . '/../core_config/middleware_auth.php';
|
require_once __DIR__ . '/../core_config/middleware_auth.php';
|
||||||
requireRole('user');
|
requireRole('user');
|
||||||
@@ -39,7 +39,7 @@ $activeNav = 'dashboard';
|
|||||||
require_once __DIR__ . '/partials/header.php';
|
require_once __DIR__ . '/partials/header.php';
|
||||||
?>
|
?>
|
||||||
|
|
||||||
<div class="card" style="background: #FFFFFF; border: 1px solid #E5E7EB; border-radius: var(--radius-lg); padding: 24px; margin-bottom: 24px; box-shadow: 0 1px 3px rgba(0,0,0,0.05);">
|
<div class="card" style="background: var(--bg-surface); border: 1px solid var(--border-light); margin-bottom: 24px;">
|
||||||
<h2 style="font-size:1.4rem;font-weight:700;margin-bottom:6px;color:var(--text-primary);">👋 Selamat Datang, <?= htmlspecialchars(currentUser()['nama_lengkap'] ?: currentUser()['username']) ?>!</h2>
|
<h2 style="font-size:1.4rem;font-weight:700;margin-bottom:6px;color:var(--text-primary);">👋 Selamat Datang, <?= htmlspecialchars(currentUser()['nama_lengkap'] ?: currentUser()['username']) ?>!</h2>
|
||||||
<p style="color:var(--text-secondary);font-size:0.9rem;max-width:600px;">
|
<p style="color:var(--text-secondary);font-size:0.9rem;max-width:600px;">
|
||||||
Anda masuk sebagai <strong>Pengguna</strong>. Anda dapat melihat seluruh data spasial, analisis, dan berpartisipasi dengan mengirim Laporan Warga atau memberikan ulasan fasilitas.
|
Anda masuk sebagai <strong>Pengguna</strong>. Anda dapat melihat seluruh data spasial, analisis, dan berpartisipasi dengan mengirim Laporan Warga atau memberikan ulasan fasilitas.
|
||||||
@@ -97,10 +97,10 @@ require_once __DIR__ . '/partials/header.php';
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="card" style="background: #FFFFFF; border: 1px solid #E5E7EB; border-radius: var(--radius-lg); padding: 24px; box-shadow: 0 1px 3px rgba(0,0,0,0.05);">
|
<div class="card" style="background: var(--primary-glow); border: 1px solid var(--primary-light); margin-bottom: 24px;">
|
||||||
<div style="display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:16px;">
|
<div style="display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:16px;">
|
||||||
<div>
|
<div>
|
||||||
<h3 style="font-size:1.1rem; font-weight:700; margin-bottom:6px;">🗺️ Buka Peta Interaktif</h3>
|
<h3 style="font-size:1.1rem; font-weight:700; margin-bottom:6px; color:var(--text-primary);">🗺️ Buka Peta Interaktif</h3>
|
||||||
<p style="color:var(--text-secondary); font-size:0.88rem; max-width:500px;">
|
<p style="color:var(--text-secondary); font-size:0.88rem; max-width:500px;">
|
||||||
Lihat semua layer data spasial: SPBU, jalan, kavling, rumah ibadah, warga miskin, kawasan kumuh, dan analisis spasial.
|
Lihat semua layer data spasial: SPBU, jalan, kavling, rumah ibadah, warga miskin, kawasan kumuh, dan analisis spasial.
|
||||||
</p>
|
</p>
|
||||||
|
|||||||
@@ -5,6 +5,32 @@
|
|||||||
<div class="toast-container" id="toastContainer"></div>
|
<div class="toast-container" id="toastContainer"></div>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
// ── Theme toggle ──
|
||||||
|
(function() {
|
||||||
|
const html = document.documentElement;
|
||||||
|
const saved = localStorage.getItem('portal-theme') || 'dark';
|
||||||
|
setUserTheme(saved);
|
||||||
|
document.addEventListener('DOMContentLoaded', function() {
|
||||||
|
const btn = document.getElementById('userThemeToggle');
|
||||||
|
const icon = document.getElementById('userThemeIcon');
|
||||||
|
if (!btn) return;
|
||||||
|
btn.addEventListener('click', () => {
|
||||||
|
const next = html.getAttribute('data-theme') === 'dark' ? 'light' : 'dark';
|
||||||
|
setUserTheme(next);
|
||||||
|
localStorage.setItem('portal-theme', next);
|
||||||
|
});
|
||||||
|
function updateIcon() {
|
||||||
|
if (icon) icon.className = html.getAttribute('data-theme') === 'dark' ? 'fas fa-sun' : 'fas fa-moon';
|
||||||
|
}
|
||||||
|
updateIcon();
|
||||||
|
});
|
||||||
|
function setUserTheme(t) {
|
||||||
|
html.setAttribute('data-theme', t);
|
||||||
|
const icon = document.getElementById('userThemeIcon');
|
||||||
|
if (icon) icon.className = t === 'dark' ? 'fas fa-sun' : 'fas fa-moon';
|
||||||
|
}
|
||||||
|
})();
|
||||||
|
|
||||||
// ── Clock ──
|
// ── Clock ──
|
||||||
function updateClock() {
|
function updateClock() {
|
||||||
const now = new Date();
|
const now = new Date();
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?php
|
<?php
|
||||||
/**
|
/**
|
||||||
* User Layout — sidebar + topbar (read-only mode, beda style dari admin)
|
* User Layout — sidebar + topbar (read-only mode, beda style dari admin)
|
||||||
* Variables expected from parent: $pageTitle, $activeNav
|
* Variables expected from parent: $pageTitle, $activeNav
|
||||||
@@ -7,7 +7,7 @@ $user = currentUser();
|
|||||||
$initial = strtoupper(substr($user['nama_lengkap'] ?: $user['username'], 0, 1));
|
$initial = strtoupper(substr($user['nama_lengkap'] ?: $user['username'], 0, 1));
|
||||||
?>
|
?>
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="id">
|
<html lang="id" data-theme="dark">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
@@ -80,6 +80,12 @@ $initial = strtoupper(substr($user['nama_lengkap'] ?: $user['username'], 0, 1));
|
|||||||
<span class="badge badge-success" style="font-size:0.7rem;padding:5px 10px;">
|
<span class="badge badge-success" style="font-size:0.7rem;padding:5px 10px;">
|
||||||
<i class="fas fa-eye"></i> Mode Baca
|
<i class="fas fa-eye"></i> Mode Baca
|
||||||
</span>
|
</span>
|
||||||
|
<button class="btn btn-ghost btn-sm" id="userThemeToggle" title="Toggle tema" aria-label="Toggle dark/light mode" style="padding:8px 10px;">
|
||||||
|
<i class="fas fa-moon" id="userThemeIcon"></i>
|
||||||
|
</button>
|
||||||
|
<a href="<?= app_url('../portal.html') ?>" class="btn btn-ghost btn-sm" title="Kembali ke Portal WebGIS">
|
||||||
|
<i class="fas fa-home"></i> Portal
|
||||||
|
</a>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="admin-content">
|
<div class="admin-content">
|
||||||
|
|||||||
@@ -1,22 +1,24 @@
|
|||||||
/* =========================================================
|
/* =========================================================
|
||||||
WEBGIS PROJECT FINAL — Design System (main.css)
|
WEBGIS PROJECT FINAL — Design System (global.css)
|
||||||
========================================================= */
|
========================================================= */
|
||||||
|
|
||||||
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');
|
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');
|
||||||
|
|
||||||
:root {
|
/* ── Light Theme (default) ── */
|
||||||
/* Colors - Clean Light Theme */
|
:root, [data-theme="light"] {
|
||||||
--primary: #2563EB; /* Professional Blue */
|
/* Colors */
|
||||||
|
--primary: #2563EB;
|
||||||
--primary-light: #3B82F6;
|
--primary-light: #3B82F6;
|
||||||
--primary-dark: #1D4ED8;
|
--primary-dark: #1D4ED8;
|
||||||
|
--primary-glow: rgba(37, 99, 235, 0.08);
|
||||||
--accent: #10B981;
|
--accent: #10B981;
|
||||||
--danger: #EF4444;
|
--danger: #EF4444;
|
||||||
--warning: #F59E0B;
|
--warning: #F59E0B;
|
||||||
--info: #0EA5E9;
|
--info: #0EA5E9;
|
||||||
|
|
||||||
/* Backgrounds */
|
/* Backgrounds */
|
||||||
--bg-base: #F9FAFB; /* Very light gray */
|
--bg-base: #F9FAFB;
|
||||||
--bg-surface: #FFFFFF; /* Pure white */
|
--bg-surface: #FFFFFF;
|
||||||
--bg-elevated: #FFFFFF;
|
--bg-elevated: #FFFFFF;
|
||||||
--bg-card: #FFFFFF;
|
--bg-card: #FFFFFF;
|
||||||
|
|
||||||
@@ -25,9 +27,9 @@
|
|||||||
--border-hover: #D1D5DB;
|
--border-hover: #D1D5DB;
|
||||||
|
|
||||||
/* Text */
|
/* Text */
|
||||||
--text-primary: #111827; /* Near black */
|
--text-primary: #111827;
|
||||||
--text-secondary: #4B5563; /* Dark gray */
|
--text-secondary: #4B5563;
|
||||||
--text-muted: #6B7280; /* Medium gray */
|
--text-muted: #6B7280;
|
||||||
|
|
||||||
/* Sidebar */
|
/* Sidebar */
|
||||||
--sidebar-w: 260px;
|
--sidebar-w: 260px;
|
||||||
@@ -42,7 +44,34 @@
|
|||||||
--shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
|
--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-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);
|
--shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
|
||||||
--transition: all 0.2s ease-in-out;
|
--transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ── Dark Theme ── */
|
||||||
|
[data-theme="dark"] {
|
||||||
|
--primary: #818CF8;
|
||||||
|
--primary-light: #A5B4FC;
|
||||||
|
--primary-dark: #6366F1;
|
||||||
|
--primary-glow: rgba(129, 140, 248, 0.15);
|
||||||
|
--accent: #34D399;
|
||||||
|
--danger: #F87171;
|
||||||
|
--warning: #FCD34D;
|
||||||
|
--info: #38BDF8;
|
||||||
|
|
||||||
|
--bg-base: #0F172A;
|
||||||
|
--bg-surface: #1E293B;
|
||||||
|
--bg-elevated: #293548;
|
||||||
|
--bg-card: #1E293B;
|
||||||
|
|
||||||
|
--border-light: rgba(255,255,255,0.08);
|
||||||
|
--border-hover: rgba(129,140,248,0.45);
|
||||||
|
|
||||||
|
--text-primary: #F1F5F9;
|
||||||
|
--text-secondary: #94A3B8;
|
||||||
|
--text-muted: #64748B;
|
||||||
|
|
||||||
|
--sidebar-bg: #0F172A;
|
||||||
|
--sidebar-border: rgba(255,255,255,0.07);
|
||||||
}
|
}
|
||||||
|
|
||||||
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
|
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
|
||||||
@@ -57,6 +86,7 @@ body {
|
|||||||
line-height: 1.6;
|
line-height: 1.6;
|
||||||
min-height: 100vh;
|
min-height: 100vh;
|
||||||
-webkit-font-smoothing: antialiased;
|
-webkit-font-smoothing: antialiased;
|
||||||
|
transition: background 0.25s ease, color 0.25s ease;
|
||||||
}
|
}
|
||||||
|
|
||||||
a { color: var(--primary); text-decoration: none; transition: var(--transition); }
|
a { color: var(--primary); text-decoration: none; transition: var(--transition); }
|
||||||
@@ -67,6 +97,7 @@ a:hover { color: var(--primary-dark); }
|
|||||||
::-webkit-scrollbar-track { background: transparent; }
|
::-webkit-scrollbar-track { background: transparent; }
|
||||||
::-webkit-scrollbar-thumb { background: #CBD5E1; border-radius: 3px; }
|
::-webkit-scrollbar-thumb { background: #CBD5E1; border-radius: 3px; }
|
||||||
::-webkit-scrollbar-thumb:hover { background: #94A3B8; }
|
::-webkit-scrollbar-thumb:hover { background: #94A3B8; }
|
||||||
|
[data-theme="dark"] ::-webkit-scrollbar-thumb { background: #334155; }
|
||||||
|
|
||||||
/* ── Buttons ── */
|
/* ── Buttons ── */
|
||||||
.btn {
|
.btn {
|
||||||
@@ -83,7 +114,7 @@ a:hover { color: var(--primary-dark); }
|
|||||||
.btn-danger { background: var(--danger); color: #fff; }
|
.btn-danger { background: var(--danger); color: #fff; }
|
||||||
.btn-danger:hover { filter: brightness(0.95); }
|
.btn-danger:hover { filter: brightness(0.95); }
|
||||||
.btn-ghost { background: transparent; border: 1px solid var(--border-light); color: var(--text-secondary); }
|
.btn-ghost { background: transparent; border: 1px solid var(--border-light); color: var(--text-secondary); }
|
||||||
.btn-ghost:hover { background: #F3F4F6; color: var(--text-primary); border-color: var(--border-hover); }
|
.btn-ghost:hover { background: var(--bg-elevated); color: var(--text-primary); border-color: var(--border-hover); }
|
||||||
.btn-sm { padding: 6px 12px; font-size: 0.78rem; }
|
.btn-sm { padding: 6px 12px; font-size: 0.78rem; }
|
||||||
.btn-icon { padding: 8px; border-radius: var(--radius-sm); }
|
.btn-icon { padding: 8px; border-radius: var(--radius-sm); }
|
||||||
|
|
||||||
@@ -94,6 +125,7 @@ a:hover { color: var(--primary-dark); }
|
|||||||
border-radius: var(--radius-lg);
|
border-radius: var(--radius-lg);
|
||||||
padding: 24px;
|
padding: 24px;
|
||||||
box-shadow: var(--shadow-sm);
|
box-shadow: var(--shadow-sm);
|
||||||
|
transition: background 0.25s ease, border-color 0.25s ease;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ── Form Elements ── */
|
/* ── Form Elements ── */
|
||||||
@@ -101,12 +133,12 @@ a:hover { color: var(--primary-dark); }
|
|||||||
.form-label { display: block; font-size: 0.82rem; font-weight: 600; color: var(--text-primary); margin-bottom: 6px; }
|
.form-label { display: block; font-size: 0.82rem; font-weight: 600; color: var(--text-primary); margin-bottom: 6px; }
|
||||||
.form-control {
|
.form-control {
|
||||||
width: 100%; padding: 10px 14px; border-radius: var(--radius-md);
|
width: 100%; padding: 10px 14px; border-radius: var(--radius-md);
|
||||||
background: #FFFFFF; border: 1px solid var(--border-light);
|
background: var(--bg-surface); border: 1px solid var(--border-light);
|
||||||
color: var(--text-primary); font-size: 0.9rem; font-family: 'Inter', sans-serif;
|
color: var(--text-primary); font-size: 0.9rem; font-family: 'Inter', sans-serif;
|
||||||
outline: none; transition: var(--transition); box-shadow: var(--shadow-sm);
|
outline: none; transition: var(--transition); box-shadow: var(--shadow-sm);
|
||||||
}
|
}
|
||||||
.form-control:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15); }
|
.form-control:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15); }
|
||||||
.form-control::placeholder { color: #9CA3AF; }
|
.form-control::placeholder { color: var(--text-muted); }
|
||||||
select.form-control {
|
select.form-control {
|
||||||
appearance: none;
|
appearance: none;
|
||||||
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236B7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
|
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236B7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
|
||||||
@@ -124,20 +156,26 @@ textarea.form-control { resize: vertical; min-height: 80px; }
|
|||||||
.badge-warning { background: #FFFBEB; color: #B45309; border: 1px solid #FDE68A; }
|
.badge-warning { background: #FFFBEB; color: #B45309; border: 1px solid #FDE68A; }
|
||||||
.badge-info { background: #F0F9FF; color: #0369A1; border: 1px solid #BAE6FD; }
|
.badge-info { background: #F0F9FF; color: #0369A1; border: 1px solid #BAE6FD; }
|
||||||
|
|
||||||
|
[data-theme="dark"] .badge-primary { background: rgba(129,140,248,0.15); color: #A5B4FC; border-color: rgba(129,140,248,0.3); }
|
||||||
|
[data-theme="dark"] .badge-success { background: rgba(52,211,153,0.15); color: #6EE7B7; border-color: rgba(52,211,153,0.3); }
|
||||||
|
[data-theme="dark"] .badge-danger { background: rgba(248,113,113,0.15); color: #FCA5A5; border-color: rgba(248,113,113,0.3); }
|
||||||
|
[data-theme="dark"] .badge-warning { background: rgba(252,211,77,0.15); color: #FDE68A; border-color: rgba(252,211,77,0.3); }
|
||||||
|
[data-theme="dark"] .badge-info { background: rgba(56,189,248,0.15); color: #7DD3FC; border-color: rgba(56,189,248,0.3); }
|
||||||
|
|
||||||
/* ── Tables ── */
|
/* ── Tables ── */
|
||||||
.table-wrap { overflow-x: auto; border-radius: var(--radius-lg); border: 1px solid var(--border-light); background: var(--bg-surface); box-shadow: var(--shadow-sm); }
|
.table-wrap { overflow-x: auto; border-radius: var(--radius-lg); border: 1px solid var(--border-light); background: var(--bg-surface); box-shadow: var(--shadow-sm); }
|
||||||
.data-table { width: 100%; border-collapse: collapse; font-size: 0.88rem; }
|
.data-table { width: 100%; border-collapse: collapse; font-size: 0.88rem; }
|
||||||
.data-table thead th { background: #F9FAFB; padding: 14px 16px; text-align: left; font-size: 0.75rem; font-weight: 600; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.05em; white-space: nowrap; border-bottom: 1px solid var(--border-light); }
|
.data-table thead th { background: var(--bg-elevated); padding: 14px 16px; text-align: left; font-size: 0.75rem; font-weight: 600; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.05em; white-space: nowrap; border-bottom: 1px solid var(--border-light); }
|
||||||
.data-table tbody tr { border-bottom: 1px solid var(--border-light); transition: background 0.15s; }
|
.data-table tbody tr { border-bottom: 1px solid var(--border-light); transition: background 0.15s; }
|
||||||
.data-table tbody tr:last-child { border-bottom: none; }
|
.data-table tbody tr:last-child { border-bottom: none; }
|
||||||
.data-table tbody tr:hover { background: #F3F4F6; }
|
.data-table tbody tr:hover { background: var(--bg-elevated); }
|
||||||
.data-table td { padding: 14px 16px; color: var(--text-primary); vertical-align: middle; }
|
.data-table td { padding: 14px 16px; color: var(--text-primary); vertical-align: middle; }
|
||||||
.data-table .actions { display: flex; gap: 6px; }
|
.data-table .actions { display: flex; gap: 6px; }
|
||||||
|
|
||||||
/* ── Modal ── */
|
/* ── Modal ── */
|
||||||
.modal-overlay {
|
.modal-overlay {
|
||||||
display: none; position: fixed; inset: 0; z-index: 9999;
|
display: none; position: fixed; inset: 0; z-index: 9999;
|
||||||
background: rgba(17, 24, 39, 0.4); backdrop-filter: blur(2px);
|
background: rgba(17, 24, 39, 0.5); backdrop-filter: blur(4px);
|
||||||
align-items: center; justify-content: center;
|
align-items: center; justify-content: center;
|
||||||
}
|
}
|
||||||
.modal-overlay.active { display: flex; }
|
.modal-overlay.active { display: flex; }
|
||||||
@@ -152,7 +190,7 @@ textarea.form-control { resize: vertical; min-height: 80px; }
|
|||||||
.modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px; }
|
.modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px; }
|
||||||
.modal-title { font-size: 1.15rem; font-weight: 700; color: var(--text-primary); }
|
.modal-title { font-size: 1.15rem; font-weight: 700; color: var(--text-primary); }
|
||||||
.modal-close { background: none; border: none; color: var(--text-muted); cursor: pointer; font-size: 1.4rem; padding: 4px; border-radius: var(--radius-sm); transition: all 0.15s; }
|
.modal-close { background: none; border: none; color: var(--text-muted); cursor: pointer; font-size: 1.4rem; padding: 4px; border-radius: var(--radius-sm); transition: all 0.15s; }
|
||||||
.modal-close:hover { background: #F3F4F6; color: var(--text-primary); }
|
.modal-close:hover { background: var(--bg-elevated); color: var(--text-primary); }
|
||||||
.modal-footer { display: flex; gap: 12px; justify-content: flex-end; margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--border-light); }
|
.modal-footer { display: flex; gap: 12px; justify-content: flex-end; margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--border-light); }
|
||||||
|
|
||||||
/* ── Toast ── */
|
/* ── Toast ── */
|
||||||
@@ -176,7 +214,7 @@ textarea.form-control { resize: vertical; min-height: 80px; }
|
|||||||
width: min(360px, calc(100vw - 32px));
|
width: min(360px, calc(100vw - 32px));
|
||||||
padding: 13px 14px;
|
padding: 13px 14px;
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
background: #FFFFFF;
|
background: var(--bg-surface);
|
||||||
border: 1px solid #A7F3D0;
|
border: 1px solid #A7F3D0;
|
||||||
border-left: 4px solid var(--accent);
|
border-left: 4px solid var(--accent);
|
||||||
border-radius: var(--radius-md);
|
border-radius: var(--radius-md);
|
||||||
@@ -229,7 +267,7 @@ textarea.form-control { resize: vertical; min-height: 80px; }
|
|||||||
.page-header h1 { font-size: 1.6rem; font-weight: 700; color: var(--text-primary); letter-spacing: -0.02em; }
|
.page-header h1 { font-size: 1.6rem; font-weight: 700; color: var(--text-primary); letter-spacing: -0.02em; }
|
||||||
.page-header p { color: var(--text-secondary); margin-top: 6px; font-size: 0.9rem; }
|
.page-header p { color: var(--text-secondary); margin-top: 6px; font-size: 0.9rem; }
|
||||||
.page-header .breadcrumb { display: flex; gap: 8px; align-items: center; font-size: 0.82rem; color: var(--text-muted); margin-bottom: 12px; }
|
.page-header .breadcrumb { display: flex; gap: 8px; align-items: center; font-size: 0.82rem; color: var(--text-muted); margin-bottom: 12px; }
|
||||||
.page-header .breadcrumb .sep { color: #D1D5DB; }
|
.page-header .breadcrumb .sep { color: var(--border-hover); }
|
||||||
|
|
||||||
/* ── Utilities ── */
|
/* ── Utilities ── */
|
||||||
.text-muted { color: var(--text-muted); }
|
.text-muted { color: var(--text-muted); }
|
||||||
|
|||||||
@@ -763,3 +763,120 @@
|
|||||||
bottom: 66px;
|
bottom: 66px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* ══════════════════════════════
|
||||||
|
DARK THEME OVERRIDES FOR MAPS
|
||||||
|
══════════════════════════════ */
|
||||||
|
[data-theme="dark"] {
|
||||||
|
.map-wrap,
|
||||||
|
#admin-map,
|
||||||
|
#user-map,
|
||||||
|
.leaflet-container {
|
||||||
|
background: #0f172a;
|
||||||
|
}
|
||||||
|
|
||||||
|
.leaflet-control-attribution {
|
||||||
|
background: rgba(15, 23, 42, 0.9) !important;
|
||||||
|
border-color: var(--border-light);
|
||||||
|
}
|
||||||
|
|
||||||
|
.leaflet-control-zoom a,
|
||||||
|
.leaflet-draw-toolbar a {
|
||||||
|
background: var(--bg-surface) !important;
|
||||||
|
color: var(--text-primary) !important;
|
||||||
|
border-color: var(--border-light) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.leaflet-control-zoom a:hover,
|
||||||
|
.leaflet-draw-toolbar a:hover {
|
||||||
|
background: var(--bg-elevated) !important;
|
||||||
|
color: var(--primary-light) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.map-sidebar {
|
||||||
|
background: rgba(30, 41, 59, 0.95);
|
||||||
|
border-color: var(--border-light);
|
||||||
|
}
|
||||||
|
|
||||||
|
.map-panel-icon {
|
||||||
|
background: rgba(99, 102, 241, 0.15);
|
||||||
|
color: var(--primary-light);
|
||||||
|
border-color: rgba(99, 102, 241, 0.3);
|
||||||
|
}
|
||||||
|
|
||||||
|
.layer-item:hover {
|
||||||
|
background: rgba(255, 255, 255, 0.04);
|
||||||
|
border-color: var(--border-light);
|
||||||
|
}
|
||||||
|
|
||||||
|
.qs-item {
|
||||||
|
background: var(--bg-base);
|
||||||
|
border-color: var(--border-light);
|
||||||
|
}
|
||||||
|
|
||||||
|
.map-analysis {
|
||||||
|
background: rgba(30, 41, 59, 0.95);
|
||||||
|
border-color: var(--border-light);
|
||||||
|
}
|
||||||
|
|
||||||
|
.map-analysis button {
|
||||||
|
background: var(--bg-surface);
|
||||||
|
color: var(--text-secondary);
|
||||||
|
border-color: var(--border-light);
|
||||||
|
}
|
||||||
|
|
||||||
|
.map-analysis button:hover {
|
||||||
|
background: var(--bg-elevated);
|
||||||
|
color: var(--text-primary);
|
||||||
|
}
|
||||||
|
|
||||||
|
.map-analysis button.active {
|
||||||
|
color: #FFFFFF;
|
||||||
|
background: var(--primary-dark);
|
||||||
|
border-color: var(--primary-dark);
|
||||||
|
}
|
||||||
|
|
||||||
|
.spbu-panel {
|
||||||
|
background: rgba(30, 41, 59, 0.95);
|
||||||
|
border-color: var(--border-light);
|
||||||
|
}
|
||||||
|
|
||||||
|
.spbu-result {
|
||||||
|
background: var(--bg-base);
|
||||||
|
border-color: var(--border-light);
|
||||||
|
}
|
||||||
|
|
||||||
|
.spbu-result-distance {
|
||||||
|
color: var(--primary-light);
|
||||||
|
}
|
||||||
|
|
||||||
|
.leaflet-popup-content-wrapper {
|
||||||
|
background: var(--bg-surface) !important;
|
||||||
|
border-color: var(--border-light);
|
||||||
|
}
|
||||||
|
|
||||||
|
.leaflet-popup-tip {
|
||||||
|
background: var(--bg-surface) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.map-legend {
|
||||||
|
background: rgba(30, 41, 59, 0.95);
|
||||||
|
border-color: var(--border-light);
|
||||||
|
}
|
||||||
|
|
||||||
|
.legend-area {
|
||||||
|
background: rgba(255, 255, 255, 0.05);
|
||||||
|
}
|
||||||
|
|
||||||
|
.map-loading {
|
||||||
|
color: var(--text-primary);
|
||||||
|
background: rgba(15, 23, 42, 0.85);
|
||||||
|
}
|
||||||
|
|
||||||
|
.read-only-badge {
|
||||||
|
color: #6EE7B7;
|
||||||
|
background: rgba(52, 211, 153, 0.15);
|
||||||
|
border-color: rgba(52, 211, 153, 0.3);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -362,3 +362,55 @@ body.admin-page {
|
|||||||
.admin-main { margin-left: 0; }
|
.admin-main { margin-left: 0; }
|
||||||
.stats-grid { grid-template-columns: 1fr; }
|
.stats-grid { grid-template-columns: 1fr; }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* ══════════════════════════════
|
||||||
|
DARK THEME OVERRIDES FOR PANEL
|
||||||
|
══════════════════════════════ */
|
||||||
|
[data-theme="dark"] {
|
||||||
|
.nav-item:hover {
|
||||||
|
background: rgba(255, 255, 255, 0.05);
|
||||||
|
color: var(--text-primary);
|
||||||
|
}
|
||||||
|
|
||||||
|
.nav-item.active {
|
||||||
|
background: var(--primary-glow);
|
||||||
|
color: var(--primary-light);
|
||||||
|
}
|
||||||
|
|
||||||
|
.sidebar-footer {
|
||||||
|
background: #090d16;
|
||||||
|
}
|
||||||
|
|
||||||
|
.user-info {
|
||||||
|
background: #111827;
|
||||||
|
}
|
||||||
|
|
||||||
|
.user-avatar {
|
||||||
|
background: var(--primary-glow);
|
||||||
|
color: var(--primary-light);
|
||||||
|
}
|
||||||
|
|
||||||
|
.topbar-time {
|
||||||
|
background: var(--bg-elevated);
|
||||||
|
border-color: var(--border-light);
|
||||||
|
}
|
||||||
|
|
||||||
|
.search-box input {
|
||||||
|
background: var(--bg-surface);
|
||||||
|
border-color: var(--border-light);
|
||||||
|
}
|
||||||
|
|
||||||
|
.map-sidebar-floating {
|
||||||
|
background: var(--bg-surface);
|
||||||
|
border-color: var(--border-light);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Stat card styles for dark theme */
|
||||||
|
.stat-card.primary .stat-icon { background: rgba(37, 99, 235, 0.15); color: #818CF8; }
|
||||||
|
.stat-card.success .stat-icon { background: rgba(16, 185, 129, 0.15); color: #34D399; }
|
||||||
|
.stat-card.danger .stat-icon { background: rgba(239, 68, 68, 0.15); color: #F87171; }
|
||||||
|
.stat-card.warning .stat-icon { background: rgba(245, 158, 11, 0.15); color: #FCD34D; }
|
||||||
|
.stat-card.info .stat-icon { background: rgba(14, 165, 233, 0.15); color: #38BDF8; }
|
||||||
|
.stat-card.violet .stat-icon { background: rgba(124, 58, 237, 0.15); color: #A78BFA; }
|
||||||
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -87,11 +87,26 @@ function initMap() {
|
|||||||
|
|
||||||
L.control.zoom({ position: 'bottomright' }).addTo(state.map);
|
L.control.zoom({ position: 'bottomright' }).addTo(state.map);
|
||||||
|
|
||||||
L.tileLayer('https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png', {
|
const isDark = document.documentElement.getAttribute('data-theme') === 'dark';
|
||||||
|
const tileUrl = isDark
|
||||||
|
? 'https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png'
|
||||||
|
: 'https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png';
|
||||||
|
|
||||||
|
const tileLayer = L.tileLayer(tileUrl, {
|
||||||
attribution: '© OpenStreetMap, © CARTO',
|
attribution: '© OpenStreetMap, © CARTO',
|
||||||
subdomains: 'abcd',
|
subdomains: 'abcd',
|
||||||
maxZoom: 20
|
maxZoom: 20
|
||||||
}).addTo(state.map);
|
}).addTo(state.map);
|
||||||
|
|
||||||
|
// Dynamic theme updater for tile layer
|
||||||
|
const observer = new MutationObserver(() => {
|
||||||
|
const dark = document.documentElement.getAttribute('data-theme') === 'dark';
|
||||||
|
tileLayer.setUrl(dark
|
||||||
|
? 'https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png'
|
||||||
|
: 'https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png'
|
||||||
|
);
|
||||||
|
});
|
||||||
|
observer.observe(document.documentElement, { attributes: true });
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ── Fetch GeoJSON ── */
|
/* ── Fetch GeoJSON ── */
|
||||||
|
|||||||
@@ -81,11 +81,26 @@ function initMap() {
|
|||||||
|
|
||||||
L.control.zoom({ position: 'bottomright' }).addTo(state.map);
|
L.control.zoom({ position: 'bottomright' }).addTo(state.map);
|
||||||
|
|
||||||
L.tileLayer('https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png', {
|
const isDark = document.documentElement.getAttribute('data-theme') === 'dark';
|
||||||
|
const tileUrl = isDark
|
||||||
|
? 'https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png'
|
||||||
|
: 'https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png';
|
||||||
|
|
||||||
|
const tileLayer = L.tileLayer(tileUrl, {
|
||||||
attribution: '© OpenStreetMap, © CARTO',
|
attribution: '© OpenStreetMap, © CARTO',
|
||||||
subdomains: 'abcd',
|
subdomains: 'abcd',
|
||||||
maxZoom: 20
|
maxZoom: 20
|
||||||
}).addTo(state.map);
|
}).addTo(state.map);
|
||||||
|
|
||||||
|
// Dynamic theme updater for tile layer
|
||||||
|
const observer = new MutationObserver(() => {
|
||||||
|
const dark = document.documentElement.getAttribute('data-theme') === 'dark';
|
||||||
|
tileLayer.setUrl(dark
|
||||||
|
? 'https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png'
|
||||||
|
: 'https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png'
|
||||||
|
);
|
||||||
|
});
|
||||||
|
observer.observe(document.documentElement, { attributes: true });
|
||||||
}
|
}
|
||||||
|
|
||||||
async function fetchLayer(path) {
|
async function fetchLayer(path) {
|
||||||
|
|||||||
Reference in New Issue
Block a user