ant-design/components/theme/util/calc/calculator.ts
MadCcc bacaad0262
feat: calc support no unit (#45775)
* chore: calc support no unit

* test: add test case

* test: add test case
2023-11-10 14:54:16 +08:00

12 lines
382 B
TypeScript

export default abstract class AbstractCalculator {
abstract add(num: number | string | AbstractCalculator): this;
abstract sub(num: number | string | AbstractCalculator): this;
abstract mul(num: number | string | AbstractCalculator): this;
abstract div(num: number | string | AbstractCalculator): this;
abstract equal(options?: { unit?: boolean }): string | number;
}