|
@@ -35,7 +35,7 @@ export const NAME = 'snippet-results';
|
|
|
|
|
|
|
|
// prettier-ignore
|
|
// prettier-ignore
|
|
|
const TEMPLATE = `
|
|
const TEMPLATE = `
|
|
|
-<div class="snippet-row">
|
|
|
|
|
|
|
+<div class="snippet-row" data-bind="visible: visible" style="display: none;">
|
|
|
<div class="snippet-tab-actions">
|
|
<div class="snippet-tab-actions">
|
|
|
<div class="btn-group">
|
|
<div class="btn-group">
|
|
|
<button class="btn btn-editor btn-mini disable-feedback" data-bind="toggle: showGrid, css: { 'active': showGrid }"><i class="fa fa-fw fa-th"></i> ${ I18n('Grid') }</button>
|
|
<button class="btn btn-editor btn-mini disable-feedback" data-bind="toggle: showGrid, css: { 'active': showGrid }"><i class="fa fa-fw fa-th"></i> ${ I18n('Grid') }</button>
|
|
@@ -158,6 +158,12 @@ class SnippetResults extends DisposableComponent {
|
|
|
|
|
|
|
|
this.hasData = ko.pureComputed(() => this.data().length);
|
|
this.hasData = ko.pureComputed(() => this.data().length);
|
|
|
|
|
|
|
|
|
|
+ this.notebookMode = ko.pureComputed(() => !this.editorMode() || this.isPresentationMode());
|
|
|
|
|
+
|
|
|
|
|
+ this.visible = ko.pureComputed(
|
|
|
|
|
+ () => !this.notebookMode() || this.executing() || this.hasResultSet()
|
|
|
|
|
+ );
|
|
|
|
|
+
|
|
|
const trackedObservables = {
|
|
const trackedObservables = {
|
|
|
showGrid: true,
|
|
showGrid: true,
|
|
|
showChart: false
|
|
showChart: false
|