mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-18 03:00:58 +08:00
fix(title): support color
This commit is contained in:
@ -12,6 +12,10 @@
|
||||
transform: translateZ(0);
|
||||
}
|
||||
|
||||
:host(.ion-color) {
|
||||
color: #{current-color(base)};
|
||||
}
|
||||
|
||||
.toolbar-title {
|
||||
display: block;
|
||||
|
||||
|
@ -1,5 +1,6 @@
|
||||
import { Component, Prop } from '@stencil/core';
|
||||
import { Color, Mode } from '../../interface';
|
||||
import { createColorClasses } from '../../utils/theme';
|
||||
|
||||
@Component({
|
||||
tag: 'ion-title',
|
||||
@ -21,6 +22,12 @@ export class ToolbarTitle {
|
||||
*/
|
||||
@Prop() color?: Color;
|
||||
|
||||
hostData() {
|
||||
return {
|
||||
class: createColorClasses(this.color)
|
||||
};
|
||||
}
|
||||
|
||||
render() {
|
||||
return [
|
||||
<div class="toolbar-title">
|
||||
|
Reference in New Issue
Block a user