Update voice demo copy button
This commit is contained in:
@@ -171,9 +171,9 @@ async function copyChatId() {
|
|||||||
els.chatId.disabled = true;
|
els.chatId.disabled = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
els.copyChatIdBtn.textContent = "Copied";
|
els.copyChatIdBtn.classList.add("copied");
|
||||||
window.setTimeout(() => {
|
window.setTimeout(() => {
|
||||||
els.copyChatIdBtn.textContent = "Copy";
|
els.copyChatIdBtn.classList.remove("copied");
|
||||||
}, 1200);
|
}, 1200);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -43,7 +43,13 @@
|
|||||||
title="Copy Chat ID"
|
title="Copy Chat ID"
|
||||||
aria-label="Copy Chat ID"
|
aria-label="Copy Chat ID"
|
||||||
>
|
>
|
||||||
Copy
|
<svg class="copy-icon copy-icon--default" viewBox="0 0 16 16" width="14" height="14" fill="none" aria-hidden="true">
|
||||||
|
<rect x="5" y="5" width="8" height="9" rx="1.5" stroke="currentColor" stroke-width="1.4"/>
|
||||||
|
<path d="M3 11V3.5A1.5 1.5 0 0 1 4.5 2H11" stroke="currentColor" stroke-width="1.4" stroke-linecap="round"/>
|
||||||
|
</svg>
|
||||||
|
<svg class="copy-icon copy-icon--check" viewBox="0 0 16 16" width="14" height="14" fill="none" aria-hidden="true">
|
||||||
|
<path d="M3 8.5l3.5 3.5 6.5-7" stroke="currentColor" stroke-width="1.6" stroke-linecap="round" stroke-linejoin="round"/>
|
||||||
|
</svg>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</label>
|
</label>
|
||||||
|
|||||||
@@ -351,25 +351,42 @@ body {
|
|||||||
|
|
||||||
.chat-id-control__copy {
|
.chat-id-control__copy {
|
||||||
flex: 0 0 auto;
|
flex: 0 0 auto;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
width: 34px;
|
||||||
border: 1px solid var(--border);
|
border: 1px solid var(--border);
|
||||||
border-left: 0;
|
border-left: 0;
|
||||||
border-radius: 0 10px 10px 0;
|
border-radius: 0 10px 10px 0;
|
||||||
background: var(--bg-soft);
|
background: var(--bg-soft);
|
||||||
color: var(--text-dim);
|
color: var(--text-dim);
|
||||||
padding: 0 10px;
|
padding: 0;
|
||||||
font: inherit;
|
|
||||||
font-size: 12px;
|
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
transition: color 0.15s, border-color 0.15s, background 0.15s;
|
||||||
}
|
}
|
||||||
|
|
||||||
.chat-id-control__copy:disabled {
|
.chat-id-control__copy:disabled {
|
||||||
opacity: 0.55;
|
opacity: 0.45;
|
||||||
cursor: not-allowed;
|
cursor: not-allowed;
|
||||||
}
|
}
|
||||||
|
|
||||||
.chat-id-control__copy:not(:disabled):hover {
|
.chat-id-control__copy:not(:disabled):hover {
|
||||||
color: var(--text);
|
color: var(--accent-strong);
|
||||||
border-color: var(--accent);
|
border-color: var(--accent);
|
||||||
|
background: rgba(79, 140, 255, 0.08);
|
||||||
|
}
|
||||||
|
|
||||||
|
.chat-id-control__copy .copy-icon--check {
|
||||||
|
display: none;
|
||||||
|
color: var(--success);
|
||||||
|
}
|
||||||
|
|
||||||
|
.chat-id-control__copy.copied .copy-icon--default {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.chat-id-control__copy.copied .copy-icon--check {
|
||||||
|
display: block;
|
||||||
}
|
}
|
||||||
|
|
||||||
.status {
|
.status {
|
||||||
|
|||||||
Reference in New Issue
Block a user