style: standardize UI across tools, optimize QR layout, and configure Husky/ESLint

This commit is contained in:
2026-03-03 13:39:56 +00:00
parent b1cc8ab5a1
commit c5293ca9fe
13 changed files with 1220 additions and 582 deletions

View File

@@ -272,6 +272,7 @@ const isUrl = (string) => {
<div class="tool-panel">
<div class="panel-header" v-if="!isFullscreen">
<h2 class="tool-title">QR Scanner</h2>
<div class="header-actions"></div>
</div>
<Teleport to="body" :disabled="!isFullscreen">
@@ -375,24 +376,6 @@ const isUrl = (string) => {
flex-direction: column;
}
.tool-panel {
display: flex;
flex-direction: column;
height: 100%;
gap: 1.5rem;
padding: 1.5rem;
}
.panel-header {
display: flex;
justify-content: center;
align-items: center;
margin-bottom: 0.5rem;
margin-top: 0;
position: relative;
width: 100%;
}
.scanner-content {
display: flex;
flex-direction: column;
@@ -478,8 +461,6 @@ const isUrl = (string) => {
transform: scaleX(-1);
}
/* front mirror canvas removed */
.error-overlay {
position: absolute;
top: 0;
@@ -538,18 +519,6 @@ const isUrl = (string) => {
backdrop-filter: blur(4px);
}
/* Removed legacy scan frame overlay - using shape detection rendering via track instead */
.results-section {
flex: 1;
display: flex;
flex-direction: column;
overflow: hidden;
background: var(--glass-bg);
border: 1px solid var(--glass-border);
border-radius: 12px;
}
.scanner-content.is-fullscreen .results-section {
position: relative;
flex: 1;
@@ -565,55 +534,6 @@ const isUrl = (string) => {
flex-direction: column;
}
.results-header {
padding: 1rem;
border-bottom: 1px solid var(--glass-border);
display: flex;
justify-content: space-between;
align-items: center;
}
.results-header h3 {
margin: 0;
font-size: 1.1rem;
color: var(--text-strong);
}
.header-actions {
display: flex;
align-items: center;
gap: 0.5rem;
}
.codes-list {
flex: 1;
overflow-y: auto;
padding: 0;
}
.code-item {
display: flex;
justify-content: space-between;
align-items: center;
padding: 1rem;
border-bottom: 1px solid var(--glass-border);
transition: background 0.2s;
}
.code-item:last-child {
border-bottom: none;
}
.code-item:hover {
background: var(--list-hover-bg);
}
.code-content {
flex: 1;
overflow: hidden;
padding-right: 1rem;
}
.code-value {
color: var(--primary-accent);
font-family: monospace;
@@ -637,12 +557,6 @@ const isUrl = (string) => {
color: var(--text-secondary);
}
.item-actions {
display: flex;
gap: 0.5rem;
align-items: center;
}
.format-badge {
background: rgba(255, 255, 255, 0.1);
padding: 0 0.4rem;
@@ -654,32 +568,6 @@ const isUrl = (string) => {
background: rgba(0, 0, 0, 0.1);
}
.icon-btn {
background: none;
border: none;
color: var(--text-secondary);
cursor: pointer;
padding: 0.4rem;
border-radius: 4px;
transition: all 0.2s;
display: flex;
align-items: center;
justify-content: center;
}
.icon-btn:hover {
color: var(--text-color);
background: rgba(255, 255, 255, 0.1);
}
:global(:root[data-theme="light"]) .icon-btn:hover {
background: rgba(0, 0, 0, 0.05);
}
.delete-btn:hover {
color: #ef4444;
}
.empty-state {
flex: 1;
display: flex;