Manual float precision, toggle for old behavior (#1541)

* Add toggle for float rounding

* Add manual precision override
This commit is contained in:
City
2023-09-19 05:20:00 +02:00
committed by GitHub
parent 26cd8405dd
commit 7c93afd2cd
2 changed files with 26 additions and 5 deletions

View File

@@ -577,6 +577,25 @@ export class ComfyUI {
defaultValue: false,
});
this.settings.addSetting({
id: "Comfy.DisableFloatRounding",
name: "Disable rounding floats (requires page reload).",
type: "boolean",
defaultValue: false,
});
this.settings.addSetting({
id: "Comfy.FloatRoundingPrecision",
name: "Decimal places [0 = auto] (requires page reload).",
type: "slider",
attrs: {
min: 0,
max: 6,
step: 1,
},
defaultValue: 0,
});
const fileInput = $el("input", {
id: "comfy-file-input",
type: "file",