style: 新增独立mobile.css避免本地文件缓存
This commit is contained in:
+2
-1
@@ -4,7 +4,8 @@
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Mi Diario — 西班牙语日记</title>
|
||||
<link rel="stylesheet" href="style.css?v=20260802">
|
||||
<link rel="stylesheet" href="style.css">
|
||||
<link rel="stylesheet" href="mobile.css">
|
||||
</head>
|
||||
<body data-view="editor">
|
||||
<header id="mobile-header">
|
||||
|
||||
+134
@@ -0,0 +1,134 @@
|
||||
@media (max-width: 768px) {
|
||||
body { padding: 0; overflow-x: hidden; }
|
||||
|
||||
#mobile-header {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
position: sticky;
|
||||
top: 0;
|
||||
z-index: 85;
|
||||
height: 52px;
|
||||
padding: 0 0.6rem;
|
||||
background: var(--panel-bg);
|
||||
border-bottom: 1px solid var(--border);
|
||||
}
|
||||
#mobile-header button {
|
||||
width: 42px;
|
||||
height: 42px;
|
||||
border: none;
|
||||
background: none;
|
||||
font-size: 1.3rem;
|
||||
cursor: pointer;
|
||||
color: var(--text);
|
||||
}
|
||||
#mobile-title { font-weight: 700; font-size: 0.95rem; }
|
||||
|
||||
#mobile-menu-overlay {
|
||||
display: none;
|
||||
position: fixed;
|
||||
inset: 0;
|
||||
background: transparent;
|
||||
z-index: 100;
|
||||
}
|
||||
#mobile-menu-overlay.show { display: block; }
|
||||
#mobile-menu {
|
||||
position: absolute;
|
||||
left: 0.5rem;
|
||||
top: 56px;
|
||||
width: max-content;
|
||||
min-width: 190px;
|
||||
max-width: 84vw;
|
||||
max-height: calc(100vh - 72px);
|
||||
background: var(--panel-bg);
|
||||
border: 1px solid var(--border);
|
||||
border-radius: var(--radius);
|
||||
box-shadow: var(--shadow);
|
||||
padding: 0.6rem;
|
||||
overflow-y: auto;
|
||||
}
|
||||
.mobile-menu-head {
|
||||
font-weight: 700;
|
||||
font-size: 1.05rem;
|
||||
padding: 0.5rem 0.5rem 1rem;
|
||||
}
|
||||
#mobile-menu button, #mobile-menu a {
|
||||
display: flex;
|
||||
width: 100%;
|
||||
align-items: center;
|
||||
gap: 0.6rem;
|
||||
padding: 0.8rem 0.5rem;
|
||||
border: none;
|
||||
border-bottom: 1px solid var(--border);
|
||||
background: none;
|
||||
color: var(--text);
|
||||
font-size: 0.95rem;
|
||||
text-decoration: none;
|
||||
cursor: pointer;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
#app { display: block; padding: 0; }
|
||||
#panel-list, #panel-translate, #stats-panel { display: none; }
|
||||
#panel-editor {
|
||||
display: flex;
|
||||
min-height: calc(100vh - 52px);
|
||||
border: none;
|
||||
border-radius: 0;
|
||||
}
|
||||
|
||||
#panel-list {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
z-index: 70;
|
||||
border: none;
|
||||
border-radius: 0;
|
||||
max-height: none;
|
||||
}
|
||||
body[data-view="list"] #panel-list { display: flex; }
|
||||
#btn-back-list {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
width: 30px;
|
||||
height: 30px;
|
||||
border: 1px solid var(--border);
|
||||
border-radius: 6px;
|
||||
background: none;
|
||||
color: var(--text);
|
||||
font-size: 1rem;
|
||||
cursor: pointer;
|
||||
}
|
||||
#panel-list #entry-list { max-height: none; }
|
||||
|
||||
#panel-translate {
|
||||
position: fixed;
|
||||
top: 52px;
|
||||
right: 0;
|
||||
width: min(420px, 94vw);
|
||||
height: calc(100vh - 52px);
|
||||
z-index: 60;
|
||||
border: none;
|
||||
border-radius: 0;
|
||||
transform: translateX(100%);
|
||||
transition: transform 0.25s ease;
|
||||
pointer-events: none;
|
||||
}
|
||||
body[data-view="translate"] #panel-translate,
|
||||
body[data-view="stats"] #panel-translate {
|
||||
display: flex;
|
||||
transform: translateX(0);
|
||||
pointer-events: auto;
|
||||
}
|
||||
body[data-view="translate"] #stats-panel { display: flex; }
|
||||
body[data-view="stats"] #panel-translate > .panel-header,
|
||||
body[data-view="stats"] #panel-translate > .translate-section { display: none; }
|
||||
body[data-view="stats"] #stats-panel {
|
||||
display: flex;
|
||||
max-height: none;
|
||||
flex: 1;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user