1.'props.percent' is possibly 'undefined'.ts(18048)/type‘string’|‘undefined’类型不能赋值给type‘string’/或者ts2345之类的错误对报错位置加上as 类型断言即可
2.The inferred type of this node exceeds the maximum length the compiler will serialize. An explicit type annotation is needed.ts(7056) 在函数名后面添加返回数据类型以及函数参数类型