mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-18 19:21:34 +08:00
fix(all): type issues with TS 3.2
This commit is contained in:

committed by
Manu MA

parent
63cbc92741
commit
aa9d0d4282
@ -42,7 +42,7 @@ export class Anchor implements ComponentInterface {
|
|||||||
return (
|
return (
|
||||||
<a
|
<a
|
||||||
href={this.href}
|
href={this.href}
|
||||||
onClick={ev => openURL(this.win, this.href, ev, this.routerDirection)}
|
onClick={(ev: Event) => openURL(this.win, this.href, ev, this.routerDirection)}
|
||||||
>
|
>
|
||||||
<slot></slot>
|
<slot></slot>
|
||||||
</a>
|
</a>
|
||||||
|
@ -79,7 +79,7 @@ export class BackButton implements ComponentInterface {
|
|||||||
<button
|
<button
|
||||||
type="button"
|
type="button"
|
||||||
class="button-native"
|
class="button-native"
|
||||||
onClick={ev => this.onClick(ev)}
|
onClick={(ev: Event) => this.onClick(ev)}
|
||||||
>
|
>
|
||||||
<span class="button-inner">
|
<span class="button-inner">
|
||||||
{backButtonIcon && <ion-icon icon={backButtonIcon} lazy={false}></ion-icon>}
|
{backButtonIcon && <ion-icon icon={backButtonIcon} lazy={false}></ion-icon>}
|
||||||
|
@ -421,16 +421,16 @@ export class Datetime implements ComponentInterface {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
private calcMinMax(now?: Date) {
|
private calcMinMax() {
|
||||||
const todaysYear = (now || new Date()).getFullYear();
|
const todaysYear = new Date().getFullYear();
|
||||||
|
|
||||||
if (this.yearValues !== undefined) {
|
if (this.yearValues !== undefined) {
|
||||||
const years = convertToArrayOfNumbers(this.yearValues, 'year');
|
const years = convertToArrayOfNumbers(this.yearValues, 'year');
|
||||||
if (this.min === undefined) {
|
if (this.min === undefined) {
|
||||||
this.min = Math.min.apply(Math, years);
|
this.min = Math.min(...years).toString();
|
||||||
}
|
}
|
||||||
if (this.max === undefined) {
|
if (this.max === undefined) {
|
||||||
this.max = Math.max.apply(Math, years);
|
this.max = Math.max(...years).toString();
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (this.min === undefined) {
|
if (this.min === undefined) {
|
||||||
|
@ -122,7 +122,7 @@ export class FabButton implements ComponentInterface {
|
|||||||
onFocus={this.onFocus}
|
onFocus={this.onFocus}
|
||||||
onKeyUp={this.onKeyUp}
|
onKeyUp={this.onKeyUp}
|
||||||
onBlur={this.onBlur}
|
onBlur={this.onBlur}
|
||||||
onClick={ev => openURL(this.win, this.href, ev, this.routerDirection)}
|
onClick={(ev: Event) => openURL(this.win, this.href, ev, this.routerDirection)}
|
||||||
>
|
>
|
||||||
<span class="close-icon">
|
<span class="close-icon">
|
||||||
<ion-icon name="close" lazy={false}></ion-icon>
|
<ion-icon name="close" lazy={false}></ion-icon>
|
||||||
|
@ -99,7 +99,7 @@ export class PickerColumnCmp implements ComponentInterface {
|
|||||||
let translateZ = 0;
|
let translateZ = 0;
|
||||||
const { col, rotateFactor } = this;
|
const { col, rotateFactor } = this;
|
||||||
const selectedIndex = col.selectedIndex = this.indexForY(-y);
|
const selectedIndex = col.selectedIndex = this.indexForY(-y);
|
||||||
const durationStr = (duration === 0) ? null : duration + 'ms';
|
const durationStr = (duration === 0) ? '' : duration + 'ms';
|
||||||
const scaleStr = `scale(${this.scaleFactor})`;
|
const scaleStr = `scale(${this.scaleFactor})`;
|
||||||
|
|
||||||
const children = this.optsEl.children;
|
const children = this.optsEl.children;
|
||||||
|
Reference in New Issue
Block a user