Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: ionic-team/ionic-framework
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v3.9.0
Choose a base ref
...
head repository: ionic-team/ionic-framework
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v3.9.1
Choose a head ref
  • 2 commits
  • 3 files changed
  • 2 contributors

Commits on Nov 8, 2017

  1. Copy the full SHA
    248a1ce View commit details
  2. Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    e1948be View commit details
Showing with 115 additions and 8 deletions.
  1. +104 −0 CHANGELOG.md
  2. +2 −2 package.json
  3. +9 −6 src/components/datetime/datetime.ts
104 changes: 104 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,107 @@
<a name="3.9.0"></a>
# [3.9.0](https://github.com/ionic-team/ionic/compare/v3.8.0...v3.9.0) (2017-11-08)

### Upgrade Instructions
`ionic-angular` 3.9.0 adds support for `@angular` 5.0.0 :tada:! It is a drop-in replacement for `ionic-angular` 3.8.x.

To update, remove existing `node_modules` and any lock files, and then update `package.json` to the following deps.

```
"dependencies" : {
...
"@angular/common": "5.0.0",
"@angular/compiler": "5.0.0",
"@angular/compiler-cli": "5.0.0",
"@angular/core": "5.0.0",
"@angular/forms": "5.0.0",
"@angular/http": "5.0.0",
"@angular/platform-browser": "5.0.0",
"@angular/platform-browser-dynamic": "5.0.0",
"@ionic/storage": "2.1.3",
"ionic-angular": "3.9.0",
"rxjs": "5.5.2",
"zone.js": "0.8.18"
...
},
"devDependencies: {
"@ionic/app-scripts": "3.1.0"
"typescript" : "2.4.2"
}
```

If your app uses RXJS, see the instructions below to update.

### RXJS 5.5.2 Updates

The recent update of RXJS includes a change in how operators are applied.

Traditionally, operators were applied like this:

```typescript
import 'rxjs/add/operator/debounceTime';
import 'rxjs/add/operator/switchMap';

export MyClass {


someMethod(){
// Using Reactive Forms
this.input.valueChanges
.debounceTime(500)
.switchMap(inputVal => this.service.get(inputVal))
.subscribe(res => console.log(res))
}
}
```

This approach involved modifying the Observable prototype and patching on the
methods.

RXJS 5.5 introduces a different way to do this that can lead to significantly
smaller code bundles, lettable operators.

To use lettable operators, modify the code from above to look like this:

```typescript
//Use Deep imports here for smallest bunlde size
import { debounceTime } from 'rxjs/operators/debounceTime';
import { switch } from 'rxjs/operators/switchMap';

export MyClass {


someMethod(){
// Using Reactive Forms
// We use the new `.pipe` method on the observable
// too apply operators now

this.input.valueChanges
.pipe(
debounceTime(500),
switchMap(inputVal => this.service.get(inputVal))
)
.subscribe(res => console.log(res))
}
}
```

This slight change allows only import the operators we need in our code. This will result in a smaller, faster application. This example uses Deep Imports, which allow the module we want to import to be isolated.

Take a look at [this
doc](https://github.com/ReactiveX/rxjs/blob/master/doc/lettable-operators.md) for more information.

### Bug Fixes

* **action-sheet:** move box-shadow to first group ([4f3e91b](https://github.com/ionic-team/ionic/commit/4f3e91b))
* **alert:** focus input after it is ready ([#13259](https://github.com/ionic-team/ionic/issues/13259)) ([e555eae](https://github.com/ionic-team/ionic/commit/e555eae))
* **datetime:** use spread operator to copy pickerOptions ([#13202](https://github.com/ionic-team/ionic/issues/13202)) ([2ab8385](https://github.com/ionic-team/ionic/commit/2ab8385)), closes [#11641](https://github.com/ionic-team/ionic/issues/11641)
* **input:** better support for WKKeyboard ([#13106](https://github.com/ionic-team/ionic/issues/13106)) ([e7ac15f](https://github.com/ionic-team/ionic/commit/e7ac15f))
* **tabs:** no safe area padding for top tabs ([236e7f8](https://github.com/ionic-team/ionic/commit/236e7f8))
* **tap-click:** clear activated state on activable element when appropriate ([#13258](https://github.com/ionic-team/ionic/issues/13258)) ([5742540](https://github.com/ionic-team/ionic/commit/5742540)), closes [#13044](https://github.com/ionic-team/ionic/issues/13044)
* **VirtualScroll:** stop from resizing while out of view ([#13143](https://github.com/ionic-team/ionic/issues/13143)) ([6978bb5](https://github.com/ionic-team/ionic/commit/6978bb5))



<a name="3.8.0"></a>
# [3.8.0](https://github.com/ionic-team/ionic/compare/v3.7.1...v3.8.0) (2017-10-26)

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"private": true,
"name": "ionic2",
"version": "3.8.0",
"version": "3.9.0",
"description": "A powerful framework for building mobile and progressive web apps with JavaScript and Angular",
"keywords": [
"ionic",
@@ -147,4 +147,4 @@
"pre-push#master": [
"test"
]
}
}
15 changes: 9 additions & 6 deletions src/components/datetime/datetime.ts
Original file line number Diff line number Diff line change
@@ -525,17 +525,20 @@ export class DateTime extends BaseInput<DateTimeData> implements AfterContentIni
// the user may have assigned some options specifically for the picker
const pickerOptions = {...this.pickerOptions};

// Configure picker under the hood
const picker = this._picker = this._pickerCtrl.create(pickerOptions);
picker.addButton({
// Add a cancel and done button by default to the picker
const defaultButtons = [{
text: this.cancelText,
role: 'cancel',
handler: () => this.ionCancel.emit(this)
});
picker.addButton({
}, {
text: this.doneText,
handler: (data: any) => this.value = data,
});
}];

pickerOptions.buttons = (pickerOptions.buttons || []).concat(defaultButtons);

// Configure picker under the hood
const picker = this._picker = this._pickerCtrl.create(pickerOptions);

picker.ionChange.subscribe(() => {
this.validate();