Class: DateInput
dg.DateInput
Input control base. Could be used for editing Property values as well. The root is a div that consists of captionLabel and input.
Hierarchy
InputBase
<dayjs.Dayjs
|null
>↳
DateInput
Constructors
constructor
• new DateInput(dart
, onChanged?
)
Parameters
Name | Type | Default value |
---|---|---|
dart | any | undefined |
onChanged | any | null |
Overrides
Defined in
Properties
dart
• dart: any
Overrides
Defined in
Accessors
caption
• get
caption(): string
Returns
string
Inherited from
InputBase.caption
Defined in
• set
caption(s
): void
Parameters
Name | Type |
---|---|
s | string |
Returns
void
Inherited from
InputBase.caption
Defined in
captionLabel
• get
captionLabel(): HTMLElement
Returns
HTMLElement
Inherited from
InputBase.captionLabel
Defined in
classList
• get
classList(): DOMTokenList
Returns
DOMTokenList
Inherited from
InputBase.classList
Defined in
dataType
• get
dataType(): string
Data type this input can edit. See Type.
Returns
string
Inherited from
InputBase.dataType
Defined in
enabled
• get
enabled(): boolean
Whether the input is enabled
Returns
boolean
Inherited from
InputBase.enabled
Defined in
• set
enabled(v
): void
Parameters
Name | Type |
---|---|
v | boolean |
Returns
void
Inherited from
InputBase.enabled
Defined in
format
• get
format(): string
Value format.
Returns
string
Inherited from
InputBase.format
Defined in
• set
format(s
): void
Parameters
Name | Type |
---|---|
s | string |
Returns
void
Inherited from
InputBase.format
Defined in
input
• get
input(): HTMLElement
Returns the actual input
Returns
HTMLElement
Inherited from
InputBase.input
Defined in
inputType
• get
inputType(): string
Input type identifier (such as "Slider" for the slider input). See InputType.
Returns
string
Inherited from
InputBase.inputType
Defined in
notify
• get
notify(): boolean
Whether events are thrown on value set
Returns
boolean
Inherited from
InputBase.notify
Defined in
• set
notify(v
): void
Parameters
Name | Type |
---|---|
v | boolean |
Returns
void
Inherited from
InputBase.notify
Defined in
nullable
• get
nullable(): boolean
Whether empty values are allowed
Returns
boolean
Inherited from
InputBase.nullable
Defined in
• set
nullable(v
): void
Parameters
Name | Type |
---|---|
v | boolean |
Returns
void
Inherited from
InputBase.nullable
Defined in
property
• get
property(): any
Property if associated with
Returns
any
Inherited from
InputBase.property
Defined in
• set
property(p
): void
Parameters
Name | Type |
---|---|
p | Property |
Returns
void
Inherited from
InputBase.property
Defined in
readOnly
• get
readOnly(): boolean
Whether the input is readonly
Returns
boolean
Inherited from
InputBase.readOnly
Defined in
• set
readOnly(v
): void
Parameters
Name | Type |
---|---|
v | boolean |
Returns
void
Inherited from
InputBase.readOnly
Defined in
root
• get
root(): HTMLElement
Visual root (typically a div element that contains caption and input)
Returns
HTMLElement
Inherited from
InputBase.root
Defined in
stringValue
• get
stringValue(): string
String representation of the value
Returns
string
Inherited from
InputBase.stringValue
Defined in
• set
stringValue(s
): void
Parameters
Name | Type |
---|---|
s | string |
Returns
void
Inherited from
InputBase.stringValue
Defined in
value
• get
value(): null
| Dayjs
Input value
Returns
null
| Dayjs
Overrides
InputBase.value
Defined in
• set
value(x
): void
Parameters
Name | Type |
---|---|
x | null | Dayjs |
Returns
void
Overrides
InputBase.value
Defined in
Methods
addCaption
▸ addCaption(caption
): InputBase
<null
| Dayjs
>
Adds the specified caption
Parameters
Name | Type |
---|---|
caption | string |
Returns
InputBase
<null
| Dayjs
>
Inherited from
Defined in
addOptions
▸ addOptions(options
): InputBase
<null
| Dayjs
>
Adds the specified options
Parameters
Name | Type |
---|---|
options | HTMLElement |
Returns
InputBase
<null
| Dayjs
>
Inherited from
Defined in
addPatternMenu
▸ addPatternMenu(pattern
): void
Adds a usage example to the input's hamburger menu
Parameters
Name | Type |
---|---|
pattern | any |
Returns
void
Inherited from
Defined in
addPostfix
▸ addPostfix(postfix
): InputBase
<null
| Dayjs
>
Adds the specified postfix
Parameters
Name | Type |
---|---|
postfix | string |
Returns
InputBase
<null
| Dayjs
>
Inherited from
Defined in
addValidator
▸ addValidator(validator
): void
Adds a validator that accepts a string representation of the edited value and returns null if valid, or error message if invalid
Parameters
Name | Type |
---|---|
validator | (value : string ) => null | string |
Returns
void
Inherited from
Defined in
fireChanged
▸ fireChanged(): any
Fires the 'changed' event (value has changed). See also fireInput
Returns
any
Inherited from
Defined in
fireInput
▸ fireInput(): any
Fires the 'input' event (user input). See also fireChanged
Returns
any
Inherited from
Defined in
init
▸ init(): any
Returns
any
Inherited from
Defined in
load
▸ load(s
): any
Loads the value. Used in dialog history. See also load
Parameters
Name | Type |
---|---|
s | any |
Returns
any
Inherited from
Defined in
onChanged
▸ onChanged(callback
): StreamSubscription
Occurs when [value] is changed, either by user or programmatically.
Parameters
Name | Type |
---|---|
callback | Function |
Returns
Inherited from
Defined in
onInput
▸ onInput(callback
): StreamSubscription
Occurs when [value] is changed by user.
Parameters
Name | Type |
---|---|
callback | Function |
Returns
Inherited from
Defined in
save
▸ save(): any
Saves the value. Used in dialog history. See also load
Returns
any
Inherited from
Defined in
setTooltip
▸ setTooltip(msg
, tooltipCheck?
): InputBase
<null
| Dayjs
>
Sets the tooltip
Parameters
Name | Type | Default value |
---|---|---|
msg | string | undefined |
tooltipCheck | null | () => boolean | null |
Returns
InputBase
<null
| Dayjs
>
Inherited from
Defined in
forColumn
▸ Static
forColumn<T
>(column
): InputBase
<null
| T
>
Creates input for the specified column
Type parameters
Name | Type |
---|---|
T | any |
Parameters
Name | Type |
---|---|
column | Column <T > |
Returns
InputBase
<null
| T
>
Inherited from
Defined in
forInputType
▸ Static
forInputType(inputType
): InputBase
<any
>
Creates input for the specified input type
Parameters
Name | Type |
---|---|
inputType | string | InputType |
Returns
InputBase
<any
>
Inherited from
Defined in
forProperty
▸ Static
forProperty(property
, source?
): InputBase
<any
>
Creates input for the specified property, and optionally binds it to the specified object
Parameters
Name | Type | Default value |
---|---|---|
property | Property | undefined |
source | any | null |
Returns
InputBase
<any
>