diff --git a/src/progress/progress.ts b/src/progress/progress.ts index b9342f33f..1f93a11c4 100644 --- a/src/progress/progress.ts +++ b/src/progress/progress.ts @@ -2,7 +2,7 @@ import { SuperComponent, wxComponent } from '../common/src/index'; import config from '../common/config'; import props from './props'; import { getBackgroundColor } from './utils'; -import { unitConvert, getRect } from '../common/utils'; +import { unitConvert } from '../common/utils'; const { prefix } = config; const name = `${prefix}-progress`; @@ -67,11 +67,6 @@ export default class Progress extends SuperComponent { }); }, - theme(theme) { - if (theme === 'circle') { - this.getInnerDiameter(); - } - }, trackColor(trackColor) { this.setData({ @@ -80,17 +75,4 @@ export default class Progress extends SuperComponent { }, }; - methods = { - getInnerDiameter() { - const { strokeWidth } = this.properties; - const wrapID = `.${name}__canvas--circle`; - if (strokeWidth) { - getRect(this, wrapID).then((wrapRect) => { - this.setData({ - innerDiameter: wrapRect.width - unitConvert(strokeWidth) * 2, - }); - }); - } - }, - }; } diff --git a/src/progress/progress.wxml b/src/progress/progress.wxml index cb8488be8..b84469050 100644 --- a/src/progress/progress.wxml +++ b/src/progress/progress.wxml @@ -80,7 +80,7 @@ >