Better name for showing troubleshooting steps
Summary: Better name for toggling troubleshoot/main UI Reviewed By: antonk52 Differential Revision: D49411916 fbshipit-source-id: 1e5bd4e3e5742abef1fca41349bc8b16cf1229bf
This commit is contained in:
committed by
Facebook GitHub Bot
parent
a32f5e7544
commit
f897203a32
@@ -143,16 +143,16 @@
|
|||||||
window.location.reload();
|
window.location.reload();
|
||||||
});
|
});
|
||||||
|
|
||||||
function toggleUI(main) {
|
function toggleTroubleshoot(troubleshootOn) {
|
||||||
const root = document.getElementById('root');
|
const root = document.getElementById('root');
|
||||||
const troubleshoot = document.getElementById('troubleshoot');
|
const troubleshoot = document.getElementById('troubleshoot');
|
||||||
|
|
||||||
if (main) {
|
if (troubleshootOn) {
|
||||||
root.style.display = 'block';
|
|
||||||
troubleshoot.style.display = 'none';
|
|
||||||
} else {
|
|
||||||
root.style.display = 'none';
|
root.style.display = 'none';
|
||||||
troubleshoot.style.display = 'flex';
|
troubleshoot.style.display = 'flex';
|
||||||
|
} else {
|
||||||
|
root.style.display = 'block';
|
||||||
|
troubleshoot.style.display = 'none';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -216,10 +216,10 @@
|
|||||||
|
|
||||||
window.flipperShowMessage = showMessage;
|
window.flipperShowMessage = showMessage;
|
||||||
window.flipperShowNoConnection = () => {
|
window.flipperShowNoConnection = () => {
|
||||||
toggleUI(false);
|
toggleTroubleshoot(true);
|
||||||
};
|
};
|
||||||
window.flipperHideMessage = () => {
|
window.flipperHideMessage = () => {
|
||||||
toggleUI(true);
|
toggleTroubleshoot(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
// load correct theme (n.b. this doesn't handle system value specifically, will assume light in such cases)
|
// load correct theme (n.b. this doesn't handle system value specifically, will assume light in such cases)
|
||||||
|
|||||||
@@ -153,16 +153,16 @@
|
|||||||
window.location.reload();
|
window.location.reload();
|
||||||
});
|
});
|
||||||
|
|
||||||
function toggleUI(main) {
|
function toggleTroubleshoot(troubleshootOn) {
|
||||||
const root = document.getElementById('root');
|
const root = document.getElementById('root');
|
||||||
const troubleshoot = document.getElementById('troubleshoot');
|
const troubleshoot = document.getElementById('troubleshoot');
|
||||||
|
|
||||||
if (main) {
|
if (troubleshootOn) {
|
||||||
root.style.display = 'block';
|
|
||||||
troubleshoot.style.display = 'none';
|
|
||||||
} else {
|
|
||||||
root.style.display = 'none';
|
root.style.display = 'none';
|
||||||
troubleshoot.style.display = 'flex';
|
troubleshoot.style.display = 'flex';
|
||||||
|
} else {
|
||||||
|
root.style.display = 'block';
|
||||||
|
troubleshoot.style.display = 'none';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -184,13 +184,13 @@
|
|||||||
}
|
}
|
||||||
window.flipperShowMessage = showMessage;
|
window.flipperShowMessage = showMessage;
|
||||||
window.flipperShowNoConnection = () => {
|
window.flipperShowNoConnection = () => {
|
||||||
toggleUI(false);
|
toggleTroubleshoot(true);
|
||||||
};
|
};
|
||||||
window.flipperHideMessage = () => {
|
window.flipperHideMessage = () => {
|
||||||
const box = document.querySelector('.__infinity-dev-box-error');
|
const box = document.querySelector('.__infinity-dev-box-error');
|
||||||
box.setAttribute('hidden', true);
|
box.setAttribute('hidden', true);
|
||||||
|
|
||||||
toggleUI(true);
|
toggleTroubleshoot(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
const closeButton = document.createElement('button');
|
const closeButton = document.createElement('button');
|
||||||
|
|||||||
Reference in New Issue
Block a user