feat: 分配视频源后设备卡片显示临时标签,源卡片半透明标记
This commit is contained in:
parent
c6c8978ea3
commit
6fcabebfe8
@ -277,11 +277,22 @@
|
||||
input.name = 'device_' + deviceID + '_source';
|
||||
input.value = sourceName;
|
||||
row.appendChild(input);
|
||||
// Hide source card
|
||||
// Visual badge on device row
|
||||
var badge = document.createElement('span');
|
||||
badge.className = 'console-source-badge';
|
||||
badge.textContent = sourceName;
|
||||
badge.style.cssText = 'display:inline-block;background:var(--primary-soft);color:var(--primary-strong);padding:1px 6px;border-radius:3px;font-size:10px;margin:2px 4px 2px 0';
|
||||
badge.setAttribute('data-source', sourceName);
|
||||
var header = row.querySelector('.console-header');
|
||||
if (header) header.appendChild(badge);
|
||||
// Mark source card as pending instead of hiding
|
||||
var card = document.querySelector('.console-source-assign[data-source="' + sourceName + '"]');
|
||||
if (card) {
|
||||
var sc = card.closest('.console-source-card');
|
||||
if (sc) sc.style.display = 'none';
|
||||
if (sc) {
|
||||
sc.style.opacity = '0.5';
|
||||
sc.style.borderStyle = 'dashed';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Binary file not shown.
Loading…
Reference in New Issue
Block a user