Commit Graph

14 Commits

Author SHA1 Message Date
Brandy Carney
8e64a28ed3 fix(range): set disabled state from FormControl 2017-01-12 17:02:47 -05:00
Manu Mtz.-Almeida
9895b86015 fix(range): fixes when step size is bigger than range
fixes #8830
fixes #8802
2016-10-21 17:21:23 +02:00
Brandy Carney
55a0257dbc refactor(colors): color should be added as an input instead of directly adding the color to the component
BREAKING CHANGES:

Colors should be passed in the `color` input on components, not added
individually as an attribute on the component.

For example:

```
<ion-tabs primary>
```

Becomes

```
<ion-tabs color=”primary”>
```

Or to bind an expression to color:

```
<ion-navbar [color]="barColor">
   ...
</ion-navbar>
```

```ts
@Component({
  templateUrl: 'build/pages/about/about.html'
})
export class AboutPage {
  barColor: string;

  constructor(private nav: NavController, platform: Platform) {
    this.barColor = platform.is('android') ? 'primary' : 'light';
  }
}
```

Reason for this change:
It was difficult to dynamically add colors to components, especially if
the name of the color attribute was unknown in the template.
This change keeps the css flat since we aren’t chaining color
attributes on components and instead we assign a class to the component
which includes the color’s name.
This allows you to easily toggle a component between multiple colors.
Speeds up performance because we are no longer reading through all of
the attributes to grab the color ones.

references #7467
closes #7087 closes #7401 closes #7523
2016-08-23 17:16:55 -04:00
Brandy Carney
938864e8d0 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
2016-08-16 17:11:02 -04:00
Manu Mtz.-Almeida
5a8fe82c3a fix(range): ion-label stacked with ion-range (#7050)
fixes #7046
2016-07-08 14:34:46 -04:00
Adam Bradley
060d064325 Merge branch '2.0' into layout-refactor
# Conflicts:
#	src/components/tabs/test/advanced/index.ts
2016-06-21 11:37:47 -05:00
Adam Bradley
1a8f6d745d test(header): update header markup 2016-06-17 11:43:30 -05:00
Manu Mtz.-Almeida
55eccb3493 feat(range): add debounce input for ionChange event
Closes #6894
2016-06-16 12:34:46 -05:00
Manu Mtz.-Almeida
ccd926b8ae feat(range): range can be disabled 2016-06-08 08:46:31 -05:00
Brandy Carney
fc819dd9c4 feat(range): add ability to add labels to the left/right of range
using `range-left` and `range-right` inside of `ion-range` will place
the element to the left or right of the range.

references #5422
2016-05-31 20:11:09 -04:00
Adam Bradley
b59e5afe22 chore(range): emit ionChange on range 2016-05-31 16:24:13 -05:00
Brandy Carney
061af93b3c fix(range): update the styling for all modes
references #5422
2016-05-31 16:11:47 -04:00
Brandy Carney
af6d5e4be4 feat(range): add md and wp styling, tweak ios styling
references #5422
2016-05-27 18:37:32 -04:00
Adam Bradley
2c6e11b10d feat(range): create ion-range input 2016-05-27 13:20:36 -05:00