1.目前发现在折线图里面series的data数据类型定义有bug,应该是data: Array<string | number>,代码位置oh_modules/.ohpm/+mccharts@1.0.2/oh_modules/@mcui/mccharts/src/main/ets/utils/chartInterface.ts
// 数据层的特征接口
interface SeriesInterface {
name: string,
color?: string,
lineStyle?: InterfaceObj,
barStyle?: InterfaceObj,
label?: InterfaceObj,
itemStyle?: InterfaceObj,
labelLine?: InterfaceObj,
emphasis?: InterfaceObj,
stack?: string,
symbolSize?: Number | Function,
data: Array<string | number> | InterfaceObj[],//InterfaceObj[]
//但是后面又有其他情况,现在改成了
}
2. 报错:'app.float.xxxxx'无法引用,resource.base.element中没有float.json,写成font.json了。
报错文件位置:
oh_modules/.ohpm/@mcui+mccharts@1.0.2/oh_modules/@mcui/mccharts/src/main/ets/components/mainpage/Tooltip.ets文件导致
但是我全部统一为font也没有用,不过可能是卡住了这是解决方法但是没及时反应。
最后选择注释:
@extend(Text) function fancy (tooltipInfo: InterfaceObj) {
.fontSize(tooltipInfo.textStyle.fontSize )//|| $r('app.float.fontSize')
.fontColor(tooltipInfo.textStyle.color )//|| $r('app.float.color')
.fontWeight(tooltipInfo.textStyle.fontWeight)// || $r('app.float.fontWeight')
.fontFamily(tooltipInfo.textStyle.fontFamily )//|| $r('app.float.fontFamily')
}