Options
All
  • Public
  • Public/Protected
  • All
Menu

Type parameters

  • SS

Hierarchy

Implements

Index

Constructors

constructor

  • Parameters

    Returns TermBasePicker

Properties

Protected SuggestionOfProperType

SuggestionOfProperType: object

Type declaration

Protected _ariaMap

_ariaMap: IPickerAriaIds

Protected _async

_async: Async

Gets the async instance associated with the component, created on demand. The async instance gives subclasses a way to execute setTimeout/setInterval async calls safely, where the callbacks will be cleared/ignored automatically after unmounting. The helpers within the async object also preserve the this pointer so that you don't need to "bind" the callbacks.

Protected _disposables

_disposables: IDisposable[]

Allows subclasses to push things to this._disposables to be auto disposed.

Protected _events

_events: EventGroup

Gets the event group instance assocaited with the component, created on demand. The event instance provides on/off methods for listening to DOM (or regular javascript object) events. The event callbacks will be automatically disconnected after unmounting. The helpers within the events object also preserve the this reference so that you don't need to "bind" the callbacks.

Protected _isFocusZoneInnerKeystroke

_isFocusZoneInnerKeystroke: function

Type declaration

    • (ev: KeyboardEvent<HTMLElement>): boolean
    • Parameters

      • ev: KeyboardEvent<HTMLElement>

      Returns boolean

Protected _shouldUpdateComponentRef

_shouldUpdateComponentRef: boolean

Controls whether the componentRef prop will be resolved by this component instance. If you are implementing a passthrough (higher-order component), you would set this to false and pass through the props to the inner component, allowing it to resolve the componentRef.

Protected addItem

addItem: function

Type declaration

Protected addItemByIndex

addItemByIndex: function

Type declaration

    • (index: number): void
    • Parameters

      • index: number

      Returns void

className

className: string

Gets the object's class name.

Protected currentPromise

currentPromise: PromiseLike<any> | undefined

dismissSuggestions

dismissSuggestions: function

Type declaration

    • (ev?: any): void
    • Parameters

      • Optional ev: any

      Returns void

Protected focusZone

focusZone: object

Type declaration

    • (component: IFocusZone | null): void
    • Parameters

      • component: IFocusZone | null

      Returns void

  • current: IFocusZone | null
  • value: IFocusZone | null

Protected input

input: object

Type declaration

    • (component: IAutofill | null): void
    • Parameters

      • component: IAutofill | null

      Returns void

  • current: IAutofill | null
  • value: IAutofill | null

items

items: IPickerTerm[]

Protected onGetMoreResults

onGetMoreResults: function

Type declaration

    • (): void
    • Returns void

Protected onInputBlur

onInputBlur: function

Type declaration

    • (ev: FocusEvent<HTMLInputElement | Autofill>): void
    • Parameters

      • ev: FocusEvent<HTMLInputElement | Autofill>

      Returns void

Protected onInputChange

onInputChange: function

Type declaration

    • (value: string): void
    • Parameters

      • value: string

      Returns void

Protected onInputFocus

onInputFocus: function

Type declaration

    • (ev: FocusEvent<HTMLInputElement | Autofill>): void
    • Parameters

      • ev: FocusEvent<HTMLInputElement | Autofill>

      Returns void

Protected onItemChange

onItemChange: function

Type declaration

    • Parameters

      Returns void

Protected onKeyDown

onKeyDown: function

Type declaration

    • (ev: KeyboardEvent<HTMLElement>): void
    • Parameters

      • ev: KeyboardEvent<HTMLElement>

      Returns void

Protected onSuggestionClick

onSuggestionClick: function

Type declaration

    • (ev: MouseEvent<HTMLElement>, item: any, index: number): void
    • Parameters

      • ev: MouseEvent<HTMLElement>
      • item: any
      • index: number

      Returns void

Protected onSuggestionRemove

onSuggestionRemove: function

Type declaration

    • (ev: MouseEvent<HTMLElement>, item: IPersonaProps, index: number): void
    • Parameters

      • ev: MouseEvent<HTMLElement>
      • item: IPersonaProps
      • index: number

      Returns void

refocusSuggestions

refocusSuggestions: function

Type declaration

    • (keyCode: KeyCodes): void
    • Parameters

      • keyCode: KeyCodes

      Returns void

Protected removeItem

removeItem: function

Type declaration

    • (item: IPickerItemProps<IPickerTerm>, focusNextItem?: boolean | undefined): void
    • Parameters

      • item: IPickerItemProps<IPickerTerm>
      • Optional focusNextItem: boolean | undefined

      Returns void

Protected removeItems

removeItems: function

Type declaration

    • (itemsToRemove: any[]): void
    • Parameters

      • itemsToRemove: any[]

      Returns void

Protected root

root: object

Type declaration

    • (component: HTMLDivElement | null): void
    • Parameters

      • component: HTMLDivElement | null

      Returns void

  • current: HTMLDivElement | null
  • value: HTMLDivElement | null

Protected selection

selection: Selection

Protected suggestionElement

suggestionElement: object

Type declaration

Protected suggestionStore

suggestionStore: SuggestionsController<IPickerTerm>

Static onError

onError: function
deprecated

Use React's error boundaries instead.

Type declaration

    • (errorMessage?: string, ex?: any): void
    • Parameters

      • Optional errorMessage: string
      • Optional ex: any

      Returns void

Methods

Optional UNSAFE_componentWillMount

  • UNSAFE_componentWillMount(): void

Optional UNSAFE_componentWillReceiveProps

  • UNSAFE_componentWillReceiveProps(nextProps: Readonly<IBasePickerProps<IPickerTerm>>, nextContext: any): void

Optional UNSAFE_componentWillUpdate

  • UNSAFE_componentWillUpdate(nextProps: Readonly<IBasePickerProps<IPickerTerm>>, nextState: Readonly<IBasePickerState>, nextContext: any): void

Protected _resolveRef

  • _resolveRef(refName: string): function
  • Helper to return a memoized ref resolver function.

    deprecated

    Use createRef from @uifabric/utilities

    Parameters

    • refName: string

      Name of the member to assign the ref to.

    Returns function

    A function instance keyed from the given refname.

      • (ref: React.ReactNode): React.ReactNode
      • Parameters

        • ref: React.ReactNode

        Returns React.ReactNode

Protected _updateComponentRef

  • _updateComponentRef(currentProps: IBaseProps | undefined, newProps?: IBaseProps): void
  • Updates the componentRef (by calling it with "this" when necessary.)

    Parameters

    • currentProps: IBaseProps | undefined
    • Optional newProps: IBaseProps

    Returns void

Protected _warnConditionallyRequiredProps

  • _warnConditionallyRequiredProps(requiredProps: string[], conditionalPropName: string, condition: boolean): void
  • Warns when props are required if a condition is met.

    Parameters

    • requiredProps: string[]

      The name of the props that are required when the condition is met.

    • conditionalPropName: string

      The name of the prop that the condition is based on.

    • condition: boolean

      Whether the condition is met.

    Returns void

Protected _warnDeprecations

  • _warnDeprecations(deprecationMap: ISettingsMap<IBasePickerProps<IPickerTerm>>): void
  • Warns when a deprecated props are being used.

    Parameters

    • deprecationMap: ISettingsMap<IBasePickerProps<IPickerTerm>>

      The map of deprecations, where key is the prop name and the value is either null or a replacement prop name.

    Returns void

Protected _warnMutuallyExclusive

  • _warnMutuallyExclusive(mutuallyExclusiveMap: ISettingsMap<IBasePickerProps<IPickerTerm>>): void
  • Warns when props which are mutually exclusive with each other are both used.

    Parameters

    • mutuallyExclusiveMap: ISettingsMap<IBasePickerProps<IPickerTerm>>

      The map of mutually exclusive props.

    Returns void

Protected canAddItems

  • canAddItems(): boolean
  • Returns boolean

completeSuggestion

  • completeSuggestion(): void
  • Returns void

Optional componentDidCatch

  • componentDidCatch(error: Error, errorInfo: ErrorInfo): void
  • Catches exceptions generated in descendant components. Unhandled exceptions will cause the entire component tree to unmount.

    Parameters

    • error: Error
    • errorInfo: ErrorInfo

    Returns void

componentDidMount

  • componentDidMount(): void
  • Returns void

Optional componentDidUpdate

  • componentDidUpdate(prevProps: Readonly<IBasePickerProps<IPickerTerm>>, prevState: Readonly<IBasePickerState>, snapshot?: SS): void
  • Called immediately after updating occurs. Not called for the initial render.

    The snapshot is only present if getSnapshotBeforeUpdate is present and returns non-null.

    Parameters

    • prevProps: Readonly<IBasePickerProps<IPickerTerm>>
    • prevState: Readonly<IBasePickerState>
    • Optional snapshot: SS

    Returns void

Optional componentWillMount

  • componentWillMount(): void

componentWillReceiveProps

  • componentWillReceiveProps(newProps: IBasePickerProps<IPickerTerm>): void
  • Parameters

    Returns void

componentWillUnmount

  • componentWillUnmount(): void
  • Returns void

componentWillUpdate

  • componentWillUpdate(newProps: IBasePickerProps<IPickerTerm>, newState: IBasePickerState): void
  • Parameters

    • newProps: IBasePickerProps<IPickerTerm>
    • newState: IBasePickerState

    Returns void

focus

  • focus(): void
  • Returns void

focusInput

  • focusInput(): void
  • Returns void

Protected getActiveDescendant

  • getActiveDescendant(): string | undefined
  • Returns string | undefined

Optional getSnapshotBeforeUpdate

  • getSnapshotBeforeUpdate(prevProps: Readonly<IBasePickerProps<IPickerTerm>>, prevState: Readonly<IBasePickerState>): SS | null
  • Runs before React applies the result of render to the document, and returns an object to be given to componentDidUpdate. Useful for saving things such as scroll position before render causes changes to it.

    Note: the presence of getSnapshotBeforeUpdate prevents any of the deprecated lifecycle events from running.

    Parameters

    • prevProps: Readonly<IBasePickerProps<IPickerTerm>>
    • prevState: Readonly<IBasePickerState>

    Returns SS | null

Protected getSuggestionsAlert

  • getSuggestionsAlert(): Element | undefined
  • Returns Element | undefined

Protected onBackspace

  • onBackspace(ev: KeyboardEvent<HTMLElement>): void
  • Parameters

    • ev: KeyboardEvent<HTMLElement>

    Returns void

Protected onChange

  • Parameters

    Returns void

Protected onEmptyInputFocus

  • onEmptyInputFocus(): void
  • Returns void

Protected onSelectionChange

  • onSelectionChange(): void
  • Returns void

Protected onSuggestionSelect

  • onSuggestionSelect(): void
  • Returns void

render

  • render(): Element
  • Returns Element

Protected renderItems

  • renderItems(): Element[]
  • Returns Element[]

Protected renderSuggestions

  • renderSuggestions(): Element | null
  • Returns Element | null

Protected resetFocus

  • resetFocus(index?: number): void
  • Parameters

    • Optional index: number

    Returns void

Protected resolveNewValue

  • resolveNewValue(updatedValue: string, suggestions: IPickerTerm[]): void
  • Parameters

    Returns void

Optional shouldComponentUpdate

  • shouldComponentUpdate(nextProps: Readonly<IBasePickerProps<IPickerTerm>>, nextState: Readonly<IBasePickerState>, nextContext: any): boolean
  • Called to determine whether the change in props and state should trigger a re-render.

    Component always returns true. PureComponent implements a shallow comparison on props and state and returns true if any props or states have changed.

    If false is returned, Component#render, componentWillUpdate and componentDidUpdate will not be called.

    Parameters

    • nextProps: Readonly<IBasePickerProps<IPickerTerm>>
    • nextState: Readonly<IBasePickerState>
    • nextContext: any

    Returns boolean

Protected updateSuggestions

  • updateSuggestions(suggestions: any[]): void
  • Parameters

    • suggestions: any[]

    Returns void

Protected updateSuggestionsList

  • Parameters

    Returns void

Protected updateValue

  • updateValue(updatedValue: string): void
  • Parameters

    • updatedValue: string

    Returns void

Generated using TypeDoc