Skip to content

Commit a947e06

Browse files
committed
Added option to turn off background auto magic
1 parent 53b92ae commit a947e06

4 files changed

Lines changed: 13 additions & 3 deletions

File tree

src/web/OutputWaiter.mjs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -423,6 +423,8 @@ class OutputWaiter {
423423
*/
424424
backgroundMagic() {
425425
this.hideMagicButton();
426+
if (!this.app.options.autoMagic) return;
427+
426428
const sample = this.dishStr ? this.dishStr.slice(0, 1000) :
427429
this.dishBuffer ? this.dishBuffer.slice(0, 1000) : "";
428430

src/web/html/index.html

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,7 @@
285285
</button>
286286
<span id="stale-indicator" class="hidden" data-toggle="tooltip" title="The output is stale. The input or recipe has changed since this output was generated. Bake again to get the new value.">
287287
<i class="material-icons">access_time</i>
288-
</span>
288+
</span>
289289
</div>
290290
<div class="textarea-wrapper">
291291
<div id="output-highlighter" class="no-select"></div>
@@ -492,6 +492,13 @@ <h5 class="modal-title">Options</h5>
492492
Use meta key for keybindings (Windows ⊞/Command ⌘)
493493
</label>
494494
</div>
495+
496+
<div class="checkbox option-item">
497+
<label for="autoMagic">
498+
<input type="checkbox" option="autoMagic" id="autoMagic">
499+
Attempt to detect encoded data automagically
500+
</label>
501+
</div>
495502
</div>
496503
<div class="modal-footer">
497504
<button type="button" class="btn btn-secondary" id="reset-options">Reset options to default</button>

src/web/index.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,8 @@ function main() {
5151
theme: "classic",
5252
useMetaKey: false,
5353
ioDisplayThreshold: 512,
54-
logLevel: "info"
54+
logLevel: "info",
55+
autoMagic: true,
5556
};
5657

5758
document.removeEventListener("DOMContentLoaded", main, false);

src/web/stylesheets/utils/_overrides.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ optgroup {
165165
}
166166

167167
.nav-tabs .nav-link {
168-
color: var(--subtext-font-color);
168+
color: var(--subtext-font-colour);
169169
}
170170

171171
.nav-tabs>li>a.nav-link.active, .nav-tabs>li>a.nav-link.active:focus, .nav-tabs>li>a.nav-link.active:hover {

0 commit comments

Comments
 (0)