| 12096 | : void 0; |
| 12097 | } |
| 12098 | getScaleComponent(e) { |
| 12099 | if (!this.component.scales) |
| 12100 | throw new Error( |
| 12101 | "getScaleComponent cannot be called before parseScale(). Make sure you have called parseScale or use parseUnitModelWithScale().", |
| 12102 | ); |
| 12103 | const t = this.component.scales[e]; |
| 12104 | return t && !t.merged |
| 12105 | ? t |
| 12106 | : this.parent |
| 12107 | ? this.parent.getScaleComponent(e) |
| 12108 | : void 0; |
| 12109 | } |
| 12110 | getScaleType(e) { |
| 12111 | const t = this.getScaleComponent(e); |
| 12112 | return t ? t.get("type") : void 0; |