mirror of
https://github.com/gristlabs/grist-core.git
synced 2026-03-02 04:09:24 +00:00
be fussier about boot key; log more problems
This commit is contained in:
@@ -484,9 +484,7 @@ Please log in as an administrator.`),
|
||||
result: BootProbeResult,
|
||||
details: ProbeDetails|undefined) {
|
||||
|
||||
const status = (result.success !== undefined) ?
|
||||
(result.success ? '✅' : '❗') : '―';
|
||||
|
||||
const status = this._encodeSuccess(result);
|
||||
return dom.create(AdminSectionItem, {
|
||||
id: `probe-${info.id}`,
|
||||
name: info.id,
|
||||
@@ -521,6 +519,20 @@ Please log in as an administrator.`),
|
||||
],
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Give an icon summarizing success or failure. Factor in the
|
||||
* severity of the result for failures. This is crude, the
|
||||
* visualization of the results can be elaborated in future.
|
||||
*/
|
||||
private _encodeSuccess(result: BootProbeResult) {
|
||||
if (result.success === undefined) { return '―'; }
|
||||
if (result.success) { return '✅'; }
|
||||
if (result.severity === 'warning') { return '❗'; }
|
||||
if (result.severity === 'hmm') { return '?'; }
|
||||
// remaining case is a fault.
|
||||
return '❌';
|
||||
}
|
||||
}
|
||||
|
||||
//function maybeSwitchToggle(value: Observable<boolean|null>): DomContents {
|
||||
|
||||
Reference in New Issue
Block a user