Auto-deploy: 2026-06-02 19:23:40
This commit is contained in:
13
popup.js
13
popup.js
@@ -287,7 +287,18 @@ function initDictation() {
|
|||||||
function stopRecording() {
|
function stopRecording() {
|
||||||
if (!isRecording) return;
|
if (!isRecording) return;
|
||||||
isRecording = false;
|
isRecording = false;
|
||||||
chrome.runtime.sendMessage({ type: 'STOP_RECORDING_FROM_POPUP' });
|
|
||||||
|
chrome.tabs.query({ active: true, currentWindow: true }, (tabs) => {
|
||||||
|
const activeTab = tabs[0];
|
||||||
|
if (activeTab && activeTab.id) {
|
||||||
|
chrome.tabs.sendMessage(activeTab.id, { type: 'STOP_RECORDING_FROM_POPUP' }, () => {
|
||||||
|
if (chrome.runtime.lastError) {
|
||||||
|
console.warn('Could not send STOP message to tab:', chrome.runtime.lastError.message);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
micBtn.style.background = 'linear-gradient(135deg, var(--accent), #9b5de5)';
|
micBtn.style.background = 'linear-gradient(135deg, var(--accent), #9b5de5)';
|
||||||
micBtn.innerHTML = '🎤';
|
micBtn.innerHTML = '🎤';
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user