✨ Added way to remove scalebox from part
This commit is contained in:
parent
ded5795ebe
commit
9fcb116c96
1 changed files with 23 additions and 0 deletions
|
@ -10,6 +10,29 @@ export default {
|
|||
},
|
||||
macros: {
|
||||
scalebox: function(so) {
|
||||
// Passing `false` will remove the scalebox
|
||||
if (so === false) {
|
||||
for (let id of [
|
||||
"__scaleboxMetricTopLeft",
|
||||
"__scaleboxMetricTopRight",
|
||||
"__scaleboxMetricBottomRight",
|
||||
"__scaleboxMetricBottomLeft",
|
||||
"__scaleboxImperialTopLeft",
|
||||
"__scaleboxImperialTopRight",
|
||||
"__scaleboxImperialBottomRight",
|
||||
"__scaleboxImperialBottomLeft",
|
||||
"__scaleboxLead",
|
||||
"__scaleboxTitle",
|
||||
"__scaleboxText",
|
||||
"__scaleboxLink",
|
||||
"__scaleboxMetric",
|
||||
"__scaleboxImperial"
|
||||
])
|
||||
delete this.points[id];
|
||||
for (let id of ["__scaleboxMetric", "__scaleboxImperial"])
|
||||
delete this.paths[id];
|
||||
return true;
|
||||
}
|
||||
// Box points
|
||||
this.points.__scaleboxMetricTopLeft = new this.Point(
|
||||
so.at.x - 50,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue