mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-17 02:31:34 +08:00
fix(searchbar): allow setting of toolbar color and searchbar color (#17474)
* fix(searchbar): allow setting of toolbar color and searchbar color * fix test label typo
This commit is contained in:
@ -156,11 +156,11 @@
|
||||
// Searchbar in Toolbar Color
|
||||
// -----------------------------------------
|
||||
|
||||
:host-context(ion-toolbar.ion-color) {
|
||||
:host-context(ion-toolbar.ion-color):not(.ion-color) {
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
:host-context(ion-toolbar.ion-color) .searchbar-cancel-button {
|
||||
:host-context(ion-toolbar.ion-color):not(.ion-color) .searchbar-cancel-button {
|
||||
color: currentColor;
|
||||
}
|
||||
|
||||
@ -170,13 +170,13 @@
|
||||
opacity: $searchbar-ios-input-icon-opacity;
|
||||
}
|
||||
|
||||
:host-context(ion-toolbar.ion-color) .searchbar-input {
|
||||
:host-context(ion-toolbar.ion-color):not(.ion-color) .searchbar-input {
|
||||
background: rgba(var(--ion-color-contrast-rgb), $searchbar-ios-input-background-color-alpha);
|
||||
color: currentColor;
|
||||
}
|
||||
|
||||
:host-context(ion-toolbar.ion-color) .searchbar-clear-button {
|
||||
:host-context(ion-toolbar.ion-color):not(.ion-color) .searchbar-clear-button {
|
||||
color: currentColor;
|
||||
|
||||
opacity: $searchbar-ios-input-icon-opacity;
|
||||
}
|
||||
}
|
@ -78,6 +78,11 @@
|
||||
<ion-toolbar color="dark">
|
||||
<ion-searchbar show-cancel-button placeholder="Filter Schedules"></ion-searchbar>
|
||||
</ion-toolbar>
|
||||
|
||||
<h5 padding-start padding-top> Search - Dark Toolbar, Primary Search </h5>
|
||||
<ion-toolbar color="dark">
|
||||
<ion-searchbar show-cancel-button color="primary" placeholder="Filter Schedules"></ion-searchbar>
|
||||
</ion-toolbar>
|
||||
|
||||
<ion-grid>
|
||||
<ion-row>
|
||||
@ -138,4 +143,4 @@
|
||||
</style>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
</html>
|
Reference in New Issue
Block a user