feat: add dark mode and switch button
This commit is contained in:
+105
-18
@@ -26,12 +26,35 @@
|
||||
--footer-bg: #f0f0f0;
|
||||
--main-bg: #ffffff;
|
||||
--text-color: #000000;
|
||||
--text-secondary: #666666;
|
||||
--tag-bg: #f8f8f8;
|
||||
--tag-border: #e0e0e0;
|
||||
--search-bg: #e0e0e0;
|
||||
--card-bg: #ffffff;
|
||||
--card-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
|
||||
--divider-color: #e5e5e5;
|
||||
--border-color: #e0e0e0;
|
||||
--hover-bg: rgba(0, 0, 0, 0.05);
|
||||
}
|
||||
|
||||
/* Dark theme */
|
||||
[data-theme="dark"] {
|
||||
--primary-red: #FF4444;
|
||||
--primary-green: #00AA00;
|
||||
--primary-black: #ffffff;
|
||||
--sidebar-bg: #1e1e1e;
|
||||
--footer-bg: #1a1a1a;
|
||||
--main-bg: #121212;
|
||||
--text-color: #ffffff;
|
||||
--text-secondary: #b3b3b3;
|
||||
--tag-bg: #2d2d2d;
|
||||
--tag-border: #404040;
|
||||
--search-bg: #333333;
|
||||
--card-bg: #1e1e1e;
|
||||
--card-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
|
||||
--divider-color: #404040;
|
||||
--border-color: #404040;
|
||||
--hover-bg: rgba(255, 255, 255, 0.1);
|
||||
}
|
||||
|
||||
body {
|
||||
@@ -86,6 +109,14 @@ select:focus {
|
||||
--tag-bg: #E8E8E8;
|
||||
--search-bg: #D0D0D0;
|
||||
}
|
||||
|
||||
[data-theme="dark"] {
|
||||
--text-color: #ffffff;
|
||||
--primary-red: #FF6666;
|
||||
--card-bg: #000000;
|
||||
--sidebar-bg: #111111;
|
||||
--main-bg: #000000;
|
||||
}
|
||||
}
|
||||
|
||||
img {
|
||||
@@ -143,7 +174,7 @@ img {
|
||||
}
|
||||
|
||||
.nav-item:hover {
|
||||
background-color: rgba(0, 0, 0, 0.05);
|
||||
background-color: var(--hover-bg);
|
||||
}
|
||||
|
||||
/* PWA Install Button */
|
||||
@@ -412,6 +443,50 @@ img {
|
||||
color: var(--text-color);
|
||||
}
|
||||
|
||||
/* Theme toggle button */
|
||||
#theme-toggle {
|
||||
transition: transform 0.3s ease, background-color 0.3s ease;
|
||||
}
|
||||
|
||||
#theme-toggle:hover {
|
||||
background-color: var(--hover-bg);
|
||||
border-radius: 50%;
|
||||
transform: scale(1.1);
|
||||
}
|
||||
|
||||
#theme-toggle:active {
|
||||
transform: scale(0.95);
|
||||
}
|
||||
|
||||
/* Theme transition for smooth switching */
|
||||
* {
|
||||
transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
|
||||
}
|
||||
|
||||
/* Dark theme specific adjustments */
|
||||
[data-theme="dark"] .mt-container {
|
||||
--mt-color-bg: var(--card-bg);
|
||||
--mt-color-content-txt: var(--text-color);
|
||||
}
|
||||
|
||||
[data-theme="dark"] img {
|
||||
opacity: 0.9;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .video-thumbnail img {
|
||||
opacity: 0.85;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .video-thumbnail:hover img {
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
/* Améliorer le contraste des icônes en mode sombre */
|
||||
[data-theme="dark"] .fa-play-circle {
|
||||
color: rgba(255, 255, 255, 0.9);
|
||||
text-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
|
||||
}
|
||||
|
||||
/* Priorité plus élevée pour les couleurs des réseaux sociaux */
|
||||
.icon-button i.icon-facebook,
|
||||
.icon-button i.icon-youtube,
|
||||
@@ -666,11 +741,11 @@ img {
|
||||
border-radius: 50px;
|
||||
font-size: 15px;
|
||||
font-weight: 600;
|
||||
background: linear-gradient(135deg, var(--tag-bg), #f0f0f0);
|
||||
background: var(--tag-bg);
|
||||
cursor: pointer;
|
||||
transition: all 0.25s cubic-bezier(0.25, 0.46, 0.45, 0.94);
|
||||
text-decoration: none;
|
||||
color: #222;
|
||||
color: var(--text-color);
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
@@ -819,7 +894,7 @@ img {
|
||||
|
||||
.video-channel {
|
||||
font-size: 14px;
|
||||
color: #555;
|
||||
color: var(--text-secondary);
|
||||
margin-bottom: 8px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
@@ -846,7 +921,7 @@ img {
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
background-color: #e5e5e5;
|
||||
color: #666;
|
||||
color: var(--text-secondary);
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
@@ -857,6 +932,7 @@ img {
|
||||
line-height: 1.4;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
.video-metadata {
|
||||
@@ -864,7 +940,7 @@ img {
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
font-size: 12px;
|
||||
color: #666;
|
||||
color: var(--text-secondary);
|
||||
margin-top: auto;
|
||||
}
|
||||
|
||||
@@ -1219,10 +1295,10 @@ img {
|
||||
width: calc(100% - 250px);
|
||||
padding: 50px 30px 30px;
|
||||
background-color: var(--footer-bg);
|
||||
border-top: 1px solid #e0e0e0;
|
||||
border-top: 1px solid var(--border-color);
|
||||
box-sizing: border-box;
|
||||
align-self: stretch;
|
||||
color: #444;
|
||||
color: var(--text-color);
|
||||
}
|
||||
|
||||
.footer-header {
|
||||
@@ -1231,7 +1307,7 @@ img {
|
||||
align-items: center;
|
||||
margin-bottom: 40px;
|
||||
padding-bottom: 30px;
|
||||
border-bottom: 1px solid #e0e0e0;
|
||||
border-bottom: 1px solid var(--border-color);
|
||||
max-width: 1200px;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
@@ -1260,7 +1336,7 @@ img {
|
||||
font-size: 18px;
|
||||
font-weight: 600;
|
||||
margin-bottom: 10px;
|
||||
color: #333;
|
||||
color: var(--text-color);
|
||||
}
|
||||
|
||||
.footer-email {
|
||||
@@ -1268,7 +1344,7 @@ img {
|
||||
}
|
||||
|
||||
.footer-email a {
|
||||
color: #555;
|
||||
color: var(--text-secondary);
|
||||
text-decoration: none;
|
||||
transition: color 0.2s;
|
||||
}
|
||||
@@ -1299,7 +1375,7 @@ img {
|
||||
font-size: 18px;
|
||||
font-weight: 700;
|
||||
margin-bottom: 20px;
|
||||
color: #333;
|
||||
color: var(--text-color);
|
||||
position: relative;
|
||||
padding-bottom: 10px;
|
||||
}
|
||||
@@ -1325,7 +1401,7 @@ img {
|
||||
}
|
||||
|
||||
.footer-links a {
|
||||
color: #555;
|
||||
color: var(--text-secondary);
|
||||
text-decoration: none;
|
||||
font-size: 15px;
|
||||
transition: all 0.2s;
|
||||
@@ -1373,9 +1449,9 @@ img {
|
||||
|
||||
.footer-copyright {
|
||||
padding-top: 25px;
|
||||
border-top: 1px solid #e0e0e0;
|
||||
border-top: 1px solid var(--border-color);
|
||||
font-size: 14px;
|
||||
color: #666;
|
||||
color: var(--text-secondary);
|
||||
max-width: 1200px;
|
||||
margin: 0 auto;
|
||||
text-align: center;
|
||||
@@ -1806,6 +1882,11 @@ i.icon-tiktok,
|
||||
color: #000000 !important; /* Noir TikTok */
|
||||
}
|
||||
|
||||
[data-theme="dark"] .header i.icon-tiktok,
|
||||
[data-theme="dark"] .header .fab.fa-tiktok.icon-tiktok {
|
||||
color: #ffffff !important; /* Blanc TikTok en mode sombre - header seulement */
|
||||
}
|
||||
|
||||
i.icon-tiktok-accent {
|
||||
color: #EE1D52 !important; /* Rouge TikTok */
|
||||
}
|
||||
@@ -1816,6 +1897,12 @@ i.icon-x,
|
||||
color: #000000 !important; /* Noir X (anciennement Twitter) */
|
||||
}
|
||||
|
||||
[data-theme="dark"] .header i.icon-x,
|
||||
[data-theme="dark"] .header .fab.fa-x-twitter.icon-x,
|
||||
[data-theme="dark"] .header .fab.fa-x.icon-x {
|
||||
color: #ffffff !important; /* Blanc X en mode sombre - header seulement */
|
||||
}
|
||||
|
||||
i.icon-mastodon,
|
||||
.fab.fa-mastodon.icon-mastodon {
|
||||
color: #563ACC !important; /* Violet Mastodon */
|
||||
@@ -2097,7 +2184,7 @@ i.icon-mastodon,
|
||||
|
||||
.no-videos-message p {
|
||||
font-size: 16px;
|
||||
color: #666;
|
||||
color: var(--text-secondary);
|
||||
margin-bottom: 25px;
|
||||
}
|
||||
|
||||
@@ -2202,7 +2289,7 @@ i.icon-mastodon,
|
||||
}
|
||||
|
||||
.search-instructions p {
|
||||
color: #666;
|
||||
color: var(--text-secondary);
|
||||
line-height: 1.5;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
@@ -2282,7 +2369,7 @@ i.icon-mastodon,
|
||||
|
||||
.page-dots {
|
||||
margin: 0 5px;
|
||||
color: #666;
|
||||
color: var(--text-secondary);
|
||||
}
|
||||
|
||||
/* Styles pour les hashtags dans le menu mobile */
|
||||
|
||||
Reference in New Issue
Block a user