API reference for Angular Material toolbar
import {MatToolbarModule} from '@angular/material/toolbar';
Directives
MatToolbarRow
Selector: mat-toolbar-row
Exported as: matToolbarRow
MatToolbar
Selector: mat-toolbar
Exported as: matToolbarProperties
Name | Description |
---|---|
@Input()
|
Theme color of the toolbar. This API is supported in M2 themes only, it has no effect in M3 themes. For color customization in M3, see https://material.angular.io/components/toolbar/styling. For information on applying color variants in M3, see https://material.angular.io/guide/material-2-theming#optional-add-backwards-compatibility-styles-for-color-variants |
API reference for Angular Material toolbar-testing
import {MatToolbarHarness} from '@angular/material/toolbar/testing';
Classes
MatToolbarHarness
extends
ContentContainerComponentHarness
Harness for interacting with a standard mat-toolbar in tests.
Properties
Name | Description |
---|---|
|
Methods
async
getAllChildLoaders
|
|
---|---|
Parameters | |
selector S
|
|
Returns | |
Promise<HarnessLoader[]>
|
|
async
getAllHarnesses
|
|
---|---|
Parameters | |
query HarnessQuery<T>
|
|
Returns | |
Promise<T[]>
|
|
async
getChildLoader
|
|
---|---|
Parameters | |
selector S
|
|
Returns | |
Promise<HarnessLoader>
|
|
async
getHarness
|
|
---|---|
Parameters | |
query HarnessQuery<T>
|
|
Returns | |
Promise<T>
|
|
async
getHarnessOrNull
|
|
---|---|
Parameters | |
query HarnessQuery<T>
|
|
Returns | |
Promise<T | null>
|
|
async
getRowsAsText
|
|
---|---|
Gets the text of each row in the toolbar. |
|
Returns | |
Promise<string[]>
|
|
async
hasHarness
|
|
---|---|
Parameters | |
query HarnessQuery<T>
|
|
Returns | |
Promise<boolean>
|
|
async
hasMultipleRows
|
|
---|---|
Whether the toolbar has multiple rows. |
|
Returns | |
Promise<boolean>
|
|
async
host
|
|
---|---|
Gets a |
|
Returns | |
Promise<TestElement>
|
|
static
with
|
|
---|---|
Gets a |
|
Parameters | |
options ToolbarHarnessFilters = {}
|
Options for filtering which card instances are considered a match. |
Returns | |
HarnessPredicate<MatToolbarHarness>
|
a |
Interfaces
ToolbarHarnessFilters
A set of criteria that can be used to filter a list of MatToolbarHarness
instances.
Properties
Name | Description |
---|---|
|
Only find instances whose text matches the given value. |