Home Reference Source
import Search from '@osjs/client/src/search.js'
public class | source

Search

Search Service

Constructor Summary

Public Constructor
public

constructor(core: Core)

Create Search instance

Member Summary

Public Members
public

$element: Element

Search root DOM element

public

Core instance reference

public

Last focused window

public

Wired actions

Method Summary

Public Methods
public

Destroy Search instance

public

focus()

Focuses UI

public

hide()

Hides UI

public

async init()

Initializes Search Service

public

async search(pattern: string): Promise<FileMetadata[]>

Performs a search across all mounts

public

show()

Shows UI

Public Constructors

public constructor(core: Core) source

Create Search instance

Params:

NameTypeAttributeDescription
core Core

Core reference

Public Members

public $element: Element source

Search root DOM element

public core: Core source

Core instance reference

public focusLastWindow: Window source

Last focused window

public ui: Object source

Wired actions

Public Methods

public destroy() source

Destroy Search instance

public focus() source

Focuses UI

public hide() source

Hides UI

public async init() source

Initializes Search Service

Performs a search across all mounts

Params:

NameTypeAttributeDescription
pattern string

Search query

Return:

Promise<FileMetadata[]>

public show() source

Shows UI