mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-23 22:17:40 +08:00
refactor(button): add ion-button attribute and icon attributes to style buttons
BREAKING CHANGES: - `<button>` becomes `<button ion-button>` - `<a button>` becomes `<a ion-button>` - `<button ion-item>` does not get the `ion-button` attribute - Buttons inside of `<ion-item-options>` do get the `ion-button` attribute - Removed the `category` attribute, this should be passed in `ion-button` instead. - Button attributes added for icons in buttons: `icon-only`, `icon-left`, and `icon-right` closes #7466
This commit is contained in:
@ -13,7 +13,7 @@
|
||||
|
||||
<ion-toolbar no-border-top>
|
||||
<ion-buttons end>
|
||||
<button>
|
||||
<button ion-button icon-only>
|
||||
<ion-icon name="search"></ion-icon>
|
||||
</button>
|
||||
</ion-buttons>
|
||||
@ -96,7 +96,7 @@
|
||||
</ion-segment-button>
|
||||
</ion-segment>
|
||||
|
||||
<button block dark (click)="toggleDisabled()">Toggle Disabled</button>
|
||||
<button ion-button block dark (click)="toggleDisabled()">Toggle Disabled</button>
|
||||
|
||||
</ion-content>
|
||||
|
||||
|
@ -21,7 +21,7 @@ class SegmentPage {
|
||||
template: `
|
||||
<ion-header>
|
||||
<ion-navbar hideBackButton>
|
||||
<button menuToggle>
|
||||
<button ion-button menuToggle>
|
||||
<ion-icon name="menu"></ion-icon>
|
||||
</button>
|
||||
<ion-title>
|
||||
|
@ -27,13 +27,13 @@
|
||||
|
||||
<ion-row>
|
||||
<ion-col>
|
||||
<button block (click)="signInType='new'">New</button>
|
||||
<button ion-button block (click)="signInType='new'">New</button>
|
||||
</ion-col>
|
||||
<ion-col>
|
||||
<button light block (click)="signInType='existing'">Existing</button>
|
||||
<button ion-button light block (click)="signInType='existing'">Existing</button>
|
||||
</ion-col>
|
||||
<ion-col>
|
||||
<button dark block (click)="signInType='test'" class="e2eSegmentTestButton">Test</button>
|
||||
<button ion-button dark block (click)="signInType='test'" class="e2eSegmentTestButton">Test</button>
|
||||
</ion-col>
|
||||
</ion-row>
|
||||
|
||||
@ -49,6 +49,6 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<button block (click)="goToPage2()">Next Page</button>
|
||||
<button ion-button block (click)="goToPage2()">Next Page</button>
|
||||
|
||||
</ion-content>
|
||||
|
Reference in New Issue
Block a user