Skip to content

Commit

Permalink
Readme updated
Browse files Browse the repository at this point in the history
  • Loading branch information
ekhmoi committed Oct 9, 2016
1 parent d28df92 commit c147cef
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ The floating action button can transform into a toolbar upon press or from a too

## Usage
```
<fab-toolbar [color]="'secondary'" [icon]="'more'" [enableBackdropDismiss]="'false'" [buttons]="buttons"></fab-toolbar>
<fab-toolbar [position]="'left" [color]="'light'" [icon]="'more'" [enableBackdropDismiss]="'false'" [buttons]="buttons"></fab-toolbar>
```

```
buttons = [
{icon: 'mail', handler: ()=> {console.log('close me')}},
{icon: 'alarm', handler: ()=> {console.log('close me')}},
{icon: 'laptop', handler: ()=> {console.log('dont close me'); return false}}
{icon: 'mail', title: 'Mail', color: 'dark', handler: ()=> {console.log('close me')}},
{icon: 'alarm', title: 'Alarm', color: 'dark', handler: ()=> {console.log('close me')}},
{icon: 'laptop', title: 'Laptop', color: 'dark', handler: ()=> {console.log('dont close me'); return false}}
]
```

Expand All @@ -28,26 +28,26 @@ buttons = [
* position: string - `left` or `right`
* icon: string - icon of the fab button
* enableBackdropDismiss: boolean - if false fab toolbar will stay open on click backdrop
* buttons: Array<{icon?: string, handler?: function}> if handler will return false toolbar will not close
* buttons: Array<{icon?: string, title?: string, color?: string, handler?: function}> if handler will return false toolbar will not close

## Install
Get files inside dist folder and copy to your project

* starting from Ionic 2 RC0.0 (AoT) you should provide all components inside app.module.ts

```
import { EkhmoiFabToolbar } from '../pages/fab-toolbar/fab-toolbar';
import { FabToolbar } from '../pages/fab-toolbar/fab-toolbar';
@NgModule({
declarations: [
EkhmoiFabToolbar
FabToolbar
],
imports: [
IonicModule.forRoot(MyApp)
],
bootstrap: [IonicApp],
entryComponents: [
EkhmoiFabToolbar
FabToolbar
]
})
```
Expand Down

0 comments on commit c147cef

Please sign in to comment.