API reference for SfInputComponent

import {SfInputModule} from "@progress/sitefinity-component-framework";


selector: sf-input

Implements

  • ControlValueAccessor
  • AfterViewInit
  • OnInit
  • OnChanges

Constructors

Properties

ariaLabel: string

Sets the aria-label attribute of the input

ariaLabelValue: string

Aria-label attribute value

ariaLabelledby: string

Sets the aria-labelledby attribute of the input

autocomplete: string

Sets the autocomplete attribute. Valid for text mode only

autofocus: boolean

Sets whether to autofocus the input

disableStepDown: boolean

Sets whether to disable the step down

disableStepUp: boolean

Sets whether to disable the step up

disabled: boolean

Sets the input to be displayed as disabled. Valid for types 'text' and 'textarea'

droppedTooltip: boolean

Sets whether the tooltip is visible

enableStepperArrows: boolean

Enables stepper arrows for type number

hint: string | MarkupSection[]

The user friendly message that describes what this input is about

innerValue: any = ""

The inner value

isHintString: boolean

Sets whether the hint is from type string

label: string

The label of the input

look: string

Sets the additional css styles for the component

max: number

Sets the max attribute of the input

maxlength: any

Sets the maxlength attribute of the input and the textarea

min: number

Sets the min attribute of the input

minlength: any

Sets the minlength attribute of the input and the textarea

name: string

Sets the name and the id attributes of the input

onArrowDown: EventEmitter<any> = ...

onArrowDown emitter Triggered when the arrow down key is pressed

onArrowUp: EventEmitter<any> = ...

onArrowUp emitter Triggered when the arrow up key is pressed

onBlur: EventEmitter<any> = ...

Emits whenever the field loses focus

onClear: EventEmitter<any> = ...

Emits whenever the input is cleared

onEnter: EventEmitter<any> = ...

Emits whenever the Enter key is pressed

onEscape: EventEmitter<any> = ...

onEscape emitter Triggered when the escape key is pressed

onFocus: EventEmitter<any> = ...

Emits whenever the field gains focus

onInput: EventEmitter<any> = ...

Emits whenever the value of the input changes

pattern: any

Sets the pattern attribute of the input and the textarea

placeholder: string

The placeholder for the input that apperas with a little grey background when the input does not have a value

readonly: boolean

Sets the input to be dispalyed in readonly mode. Valid for types 'text' and 'textarea'

recommendedCharacters: number

Recommended characters shows a character counter to the side of the input that gives a visual feedback when the user is in valid range of the value

required: boolean

Sets the required attribute of the input and the textarea

rows: number

Sets the rows attribute of the textarea

showCharCounter: boolean

Whether to show a char counter next to the input

step: number

Sets the step attribute of the input

steppersButtonLook: string

Sets the css modifiers of the steppers buttons

steppersLook: string

Sets the css modifiers of the steppers

type: string = "text"

Sets the type of the input - text, textarea, number, title (default: text)

unit: string

Sets the unit to be displayed after the input. Eg. kg, km/h

unitCssClass: string

Sets the css class for the unit

unitLook: string

Sets the css modifiers of the unit

unitPosition: string

A css value that controls where the unit value is placed

validationMessages: string[]

Sets the validation messages

Accessors

  • get charCounterVisible(): boolean
  • Sets whether the char counter is visible

    Returns boolean

  • get exceedRecommendedCharacters(): boolean
  • Sets whether the recommended characters count is exceeded

    Returns boolean

  • get showClearButton(): boolean
  • Gets if the clear button should be visible

    Returns boolean

  • get value(): any
  • Get accessor

    Returns any

  • set value(v): void
  • Set accessor including call the onchange callback

    Parameters

    • v: any

    Returns void

Methods

  • Check whether to disable steppers

    Parameters

    • value: string
    • stepUp: boolean = true

    Returns boolean

  • Focuses the input

    Returns void

  • Focuses title type

    Returns void

  • Generates input css class

    Returns string

  • Generates steppers css modifiers/look

    Returns string

  • Generates unit css class

    Returns string

  • Handles arrow down key pressed

    Parameters

    • event: KeyboardEvent

    Returns void

  • Handles arrow up key pressed

    Parameters

    • event: KeyboardEvent

    Returns void

  • Set touched on blur Handles blur event

    Parameters

    • event: any

    Returns void

  • Handles clear event

    Returns void

  • Handles enter event

    Parameters

    • event: any

    Returns void

  • Handles escape key pressed

    Parameters

    • event: KeyboardEvent

    Returns void

  • Handles focus event

    Parameters

    • event: any

    Returns void

  • Handles input event

    Parameters

    • event: any

    Returns void

  • Handles paste

    Parameters

    • event: ClipboardEvent

    Returns void

  • Returns void

  • Parameters

    • changes: SimpleChanges

    Returns void

  • Returns void

  • Handles toggling of tooltip

    Returns void

  • Sets the cursor position at the end

    Parameters

    • el: HTMLElement

    Returns void

  • From ControlValueAccessor interface

    Parameters

    • fn: any

    Returns void

  • From ControlValueAccessor interface

    Parameters

    • fn: any

    Returns void

  • Step down method

    Returns void

  • Step up method

    Returns void

  • From ControlValueAccessor interface

    Parameters

    • value: any

    Returns void

Generated using TypeDoc