From dc6232699ecc0a3d742009bd8c113063933fb412 Mon Sep 17 00:00:00 2001 From: Matt Hill Date: Fri, 19 May 2023 16:26:17 -0600 Subject: [PATCH] update specs a little --- lib/config/builder/value.ts | 14 +++++++------- lib/config/configTypes.ts | 1 - 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/lib/config/builder/value.ts b/lib/config/builder/value.ts index 84cbb3b..2e08a47 100644 --- a/lib/config/builder/value.ts +++ b/lib/config/builder/value.ts @@ -159,8 +159,9 @@ export class Value { patterns?: Pattern[] /** Default = 'text' */ inputmode?: ValueSpecText["inputmode"] - /** Immutable means it can only be configed at the first config then never again - Default is false */ + /** Immutable means it can only be configured at the first config then never again + * Default is false + */ immutable?: boolean generate?: null | RandomString }) { @@ -202,6 +203,10 @@ export class Value { patterns?: Pattern[] /** Default = 'text' */ inputmode?: ValueSpecText["inputmode"] + disabled?: string | false + /** Immutable means it can only be configured at the first config then never again + * Default is false + */ generate?: null | RandomString } >, @@ -240,7 +245,6 @@ export class Value { /** Immutable means it can only be configed at the first config then never again Default is false */ immutable?: boolean - generate?: null | RandomString }) { return new Value(async () => { const built: ValueSpecTextarea = { @@ -252,7 +256,6 @@ export class Value { type: "textarea" as const, disabled: false, immutable: a.immutable ?? false, - generate: a.generate ?? null, ...a, } return built @@ -271,7 +274,6 @@ export class Value { maxLength?: number | null placeholder?: string | null disabled?: false | string - generate?: null | RandomString } >, ) { @@ -286,7 +288,6 @@ export class Value { type: "textarea" as const, disabled: false, immutable: false, - generate: a.generate ?? null, ...a, } }, string) @@ -399,7 +400,6 @@ export class Value { description?: string | null warning?: string | null required: RequiredDefault - disabled?: false | string } >, diff --git a/lib/config/configTypes.ts b/lib/config/configTypes.ts index bcb4bcb..560afa9 100644 --- a/lib/config/configTypes.ts +++ b/lib/config/configTypes.ts @@ -55,7 +55,6 @@ export interface ValueSpecTextarea extends WithStandalone { maxLength: number | null required: boolean disabled: false | string - generate: null | RandomString /** Immutable means it can only be configed at the first config then never again */ immutable: boolean }