Class: AskNumberField
Defined in: packages/core/src/core/elicitation/types.ts:99
Number field descriptor — ask.number('Age').min(18).max(120)
Extends
AskField<number>
Constructors
Constructor
new AskNumberField(description): AskNumberField;Defined in: packages/core/src/core/elicitation/types.ts:51
Parameters
| Parameter | Type |
|---|---|
description | string | undefined |
Returns
AskNumberField
Inherited from
AskField<number>.constructorProperties
__type
readonly __type: number;Defined in: packages/core/src/core/elicitation/types.ts:44
Phantom brand for type inference — never accessed at runtime
Inherited from
Methods
default()
default(value): this;Defined in: packages/core/src/core/elicitation/types.ts:61
Set a default value for this field.
Parameters
| Parameter | Type | Description |
|---|---|---|
value | number | Default value shown pre-filled in the client form |
Returns
this
this for chaining
Inherited from
describe()
describe(desc): this;Defined in: packages/core/src/core/elicitation/types.ts:72
Set or override the field description.
Parameters
| Parameter | Type | Description |
|---|---|---|
desc | string | Human-readable label/description |
Returns
this
this for chaining
Inherited from
max()
max(n): this;Defined in: packages/core/src/core/elicitation/types.ts:120
Set the maximum value constraint.
Parameters
| Parameter | Type | Description |
|---|---|---|
n | number | Maximum (inclusive) |
Returns
this
this for chaining
min()
min(n): this;Defined in: packages/core/src/core/elicitation/types.ts:110
Set the minimum value constraint.
Parameters
| Parameter | Type | Description |
|---|---|---|
n | number | Minimum (inclusive) |
Returns
this
this for chaining