mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-16 18:17:31 +08:00
style(components): fix build lint errors
This commit is contained in:
@ -148,7 +148,7 @@ export class Alert {
|
|||||||
return playAnimationAsync(animation);
|
return playAnimationAsync(animation);
|
||||||
}).then((animation) => {
|
}).then((animation) => {
|
||||||
animation.destroy();
|
animation.destroy();
|
||||||
const firstInput = this.el.querySelector('[tabindex]');
|
const firstInput = this.el.querySelector('[tabindex]') as HTMLElement;
|
||||||
if (firstInput) {
|
if (firstInput) {
|
||||||
firstInput.focus();
|
firstInput.focus();
|
||||||
}
|
}
|
||||||
|
@ -504,7 +504,7 @@ export class Datetime {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
const selectedIndex = column.selectedIndex = clamp(indexMin, column.selectedIndex, indexMax);
|
const selectedIndex = column.selectedIndex = clamp(indexMin, column.selectedIndex, indexMax);
|
||||||
opt = column.options[selectedIndex];
|
const opt = column.options[selectedIndex];
|
||||||
if (opt) {
|
if (opt) {
|
||||||
return opt.value;
|
return opt.value;
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@ export default function iosEnterAnimation(Animation: Animation, baseElm: HTMLEle
|
|||||||
let originY = 'top';
|
let originY = 'top';
|
||||||
let originX = 'left';
|
let originX = 'left';
|
||||||
|
|
||||||
const contentEl = baseElm.querySelector('.popover-content');
|
const contentEl = baseElm.querySelector('.popover-content') as HTMLElement;
|
||||||
const contentDimentions = contentEl.getBoundingClientRect();
|
const contentDimentions = contentEl.getBoundingClientRect();
|
||||||
const contentWidth = contentDimentions.width;
|
const contentWidth = contentDimentions.width;
|
||||||
const contentHeight = contentDimentions.height;
|
const contentHeight = contentDimentions.height;
|
||||||
@ -28,7 +28,7 @@ export default function iosEnterAnimation(Animation: Animation, baseElm: HTMLEle
|
|||||||
const targetWidth = (targetDim && targetDim.width) || 0;
|
const targetWidth = (targetDim && targetDim.width) || 0;
|
||||||
const targetHeight = (targetDim && targetDim.height) || 0;
|
const targetHeight = (targetDim && targetDim.height) || 0;
|
||||||
|
|
||||||
const arrowEl = baseElm.querySelector('.popover-arrow');
|
const arrowEl = baseElm.querySelector('.popover-arrow') as HTMLElement;
|
||||||
|
|
||||||
const arrowDim = arrowEl.getBoundingClientRect();
|
const arrowDim = arrowEl.getBoundingClientRect();
|
||||||
const arrowWidth = arrowDim.width;
|
const arrowWidth = arrowDim.width;
|
||||||
|
@ -7,7 +7,7 @@ export default function mdEnterAnimation(Animation: Animation, baseElm: HTMLElem
|
|||||||
let originY = 'top';
|
let originY = 'top';
|
||||||
let originX = 'left';
|
let originX = 'left';
|
||||||
|
|
||||||
const contentEl = baseElm.querySelector('.popover-content');
|
const contentEl = baseElm.querySelector('.popover-content') as HTMLElement;
|
||||||
const contentDimentions = contentEl.getBoundingClientRect();
|
const contentDimentions = contentEl.getBoundingClientRect();
|
||||||
const contentWidth = contentDimentions.width;
|
const contentWidth = contentDimentions.width;
|
||||||
const contentHeight = contentDimentions.height;
|
const contentHeight = contentDimentions.height;
|
||||||
|
@ -184,7 +184,7 @@ export class Searchbar {
|
|||||||
* based on whether there is a value in the searchbar or not.
|
* based on whether there is a value in the searchbar or not.
|
||||||
*/
|
*/
|
||||||
inputBlurred() {
|
inputBlurred() {
|
||||||
const inputEle = this.el.querySelector('.searchbar-input');
|
const inputEle = this.el.querySelector('.searchbar-input') as HTMLInputElement;
|
||||||
|
|
||||||
// _shouldBlur determines if it should blur
|
// _shouldBlur determines if it should blur
|
||||||
// if we are clearing the input we still want to stay focused in the input
|
// if we are clearing the input we still want to stay focused in the input
|
||||||
@ -240,8 +240,8 @@ export class Searchbar {
|
|||||||
*/
|
*/
|
||||||
positionPlaceholder() {
|
positionPlaceholder() {
|
||||||
const isRTL = document.dir === 'rtl';
|
const isRTL = document.dir === 'rtl';
|
||||||
const inputEle = this.el.querySelector('.searchbar-input');
|
const inputEle = this.el.querySelector('.searchbar-input') as HTMLInputElement;
|
||||||
const iconEle = this.el.querySelector('.searchbar-search-icon');
|
const iconEle = this.el.querySelector('.searchbar-search-icon') as HTMLElement;
|
||||||
|
|
||||||
if (this._shouldAlignLeft) {
|
if (this._shouldAlignLeft) {
|
||||||
inputEle.removeAttribute('style');
|
inputEle.removeAttribute('style');
|
||||||
@ -279,7 +279,7 @@ export class Searchbar {
|
|||||||
*/
|
*/
|
||||||
positionCancelButton() {
|
positionCancelButton() {
|
||||||
const isRTL = document.dir === 'rtl';
|
const isRTL = document.dir === 'rtl';
|
||||||
const cancelButton = this.el.querySelector('.searchbar-ios-cancel');
|
const cancelButton = this.el.querySelector('.searchbar-ios-cancel') as HTMLElement;
|
||||||
const shouldShowCancel = this.focused;
|
const shouldShowCancel = this.focused;
|
||||||
|
|
||||||
if (shouldShowCancel !== this._isCancelVisible) {
|
if (shouldShowCancel !== this._isCancelVisible) {
|
||||||
|
@ -7,7 +7,7 @@ export default function iosEnterAnimation(Animation: Animation, baseElm: HTMLEle
|
|||||||
const baseAnimation = new Animation();
|
const baseAnimation = new Animation();
|
||||||
|
|
||||||
const wrapperAnimation = new Animation();
|
const wrapperAnimation = new Animation();
|
||||||
const wrapperEle = baseElm.querySelector('.toast-wrapper');
|
const wrapperEle = baseElm.querySelector('.toast-wrapper') as HTMLElement;
|
||||||
wrapperAnimation.addElement(wrapperEle);
|
wrapperAnimation.addElement(wrapperEle);
|
||||||
|
|
||||||
switch (position) {
|
switch (position) {
|
||||||
|
@ -7,7 +7,7 @@ export default function iosLeaveAnimation(Animation: Animation, baseElm: HTMLEle
|
|||||||
const baseAnimation = new Animation();
|
const baseAnimation = new Animation();
|
||||||
|
|
||||||
const wrapperAnimation = new Animation();
|
const wrapperAnimation = new Animation();
|
||||||
const wrapperEle = baseElm.querySelector('.toast-wrapper');
|
const wrapperEle = baseElm.querySelector('.toast-wrapper') as HTMLElement;
|
||||||
wrapperAnimation.addElement(wrapperEle);
|
wrapperAnimation.addElement(wrapperEle);
|
||||||
switch (position) {
|
switch (position) {
|
||||||
case 'top':
|
case 'top':
|
||||||
|
@ -7,7 +7,7 @@ export default function mdEnterAnimation(Animation: Animation, baseElm: HTMLElem
|
|||||||
const baseAnimation = new Animation();
|
const baseAnimation = new Animation();
|
||||||
|
|
||||||
const wrapperAnimation = new Animation();
|
const wrapperAnimation = new Animation();
|
||||||
const wrapperEle = baseElm.querySelector('.toast-wrapper');
|
const wrapperEle = baseElm.querySelector('.toast-wrapper') as HTMLElement;
|
||||||
wrapperAnimation.addElement(wrapperEle);
|
wrapperAnimation.addElement(wrapperEle);
|
||||||
|
|
||||||
switch (position) {
|
switch (position) {
|
||||||
|
@ -7,7 +7,7 @@ export default function mdLeaveAnimation(Animation: Animation, baseElm: HTMLElem
|
|||||||
const baseAnimation = new Animation();
|
const baseAnimation = new Animation();
|
||||||
|
|
||||||
const wrapperAnimation = new Animation();
|
const wrapperAnimation = new Animation();
|
||||||
const wrapperEle = baseElm.querySelector('.toast-wrapper');
|
const wrapperEle = baseElm.querySelector('.toast-wrapper') as HTMLElement;
|
||||||
wrapperAnimation.addElement(wrapperEle);
|
wrapperAnimation.addElement(wrapperEle);
|
||||||
|
|
||||||
switch (position) {
|
switch (position) {
|
||||||
|
Reference in New Issue
Block a user