diff --git a/src/index.html b/src/index.html
index 006577b..e850589 100644
--- a/src/index.html
+++ b/src/index.html
@@ -234,7 +234,7 @@
+
0 selected
diff --git a/src/renderer-queue.ts b/src/renderer-queue.ts
index 1ac08a7..a85138b 100644
--- a/src/renderer-queue.ts
+++ b/src/renderer-queue.ts
@@ -370,11 +370,11 @@ function updateMergeGroupButton(): void {
selectedQueueIds = selectedQueueIds.filter(id => validIds.has(id));
if (selectedQueueIds.length >= 2) {
- btn.style.display = '';
+ btn.classList.remove('is-hidden');
btn.textContent = `${UI_TEXT.mergeGroup.btn} (${selectedQueueIds.length})`;
btn.disabled = false;
} else {
- btn.style.display = 'none';
+ btn.classList.add('is-hidden');
}
}
diff --git a/src/renderer-streamers.ts b/src/renderer-streamers.ts
index 15931ad..34de2ed 100644
--- a/src/renderer-streamers.ts
+++ b/src/renderer-streamers.ts
@@ -188,7 +188,7 @@ function updateVodFilterCount(filteredCount: number, totalCount: number): void {
function syncVodFilterClearButton(): void {
const btn = document.getElementById('vodFilterClearBtn') as HTMLButtonElement | null;
if (!btn) return;
- btn.style.display = vodFilterQuery.trim() ? '' : 'none';
+ btn.classList.toggle('is-hidden', !vodFilterQuery.trim());
}
function onVodFilterInput(): void {
@@ -1018,7 +1018,7 @@ function updateVodBulkBar(): void {
const bar = document.getElementById('vodBulkBar');
if (!bar) return;
const count = selectedVodUrls.size;
- bar.style.display = count > 0 ? 'flex' : 'none';
+ bar.classList.toggle('is-hidden', count === 0);
const countEl = document.getElementById('vodBulkCount');
if (countEl) {
countEl.textContent = UI_TEXT.vods.bulkSelectedCount.replace('{count}', String(count));
diff --git a/src/styles.css b/src/styles.css
index 84f5c2b..253ea91 100644
--- a/src/styles.css
+++ b/src/styles.css
@@ -207,6 +207,7 @@ body {
animation has somewhere to live and the styling stays consistent
with the rest of the action surfaces. */
.vod-bulk-bar {
+ display: flex;
align-items: center;
gap: 10px;
padding: 10px 14px;
@@ -216,7 +217,8 @@ body {
margin-bottom: 12px;
flex-wrap: wrap;
box-shadow: 0 4px 16px rgba(145, 70, 255, 0.10);
- /* Animation fires whenever the JS flips display:none -> display:flex,
+ /* Animation fires whenever the bar transitions from display:none
+ (.is-hidden present) back to display:flex (.is-hidden removed),
because Animation events restart on each display change. */
animation: vod-bulk-bar-slide 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}
@@ -4479,6 +4481,14 @@ input[type="number"]::-webkit-outer-spin-button {
and the multitude of transition: all 0.2s declarations — anything
that involves motion. Critical for users with vestibular disorders
and a baseline accessibility expectation in 2025. */
+/* Generic hide utility. Use when an element's visible-state display
+ differs (button = inline-block, bulk-bar = flex, etc.) so a single
+ class can hide any of them without per-element .shown modifiers.
+ The !important wins over the base class's display declaration. */
+.is-hidden {
+ display: none !important;
+}
+
@media (prefers-reduced-motion: reduce) {
*,
*::before,