import { ResizableRequestParam, NgxMoveableComponent } from "ngx-moveable"; import { ViewChild, Component } from "@angular/core"; @Component({ selector: "ngx-app", templateUrl: "./App.component.html" }) export default class NgxAppComponent { @ViewChild("moveableRef") moveableRef!: NgxMoveableComponent; onClick() { this.moveableRef!.request( "resizable", { deltaHeight: 12 }, true ); } onResize(e) { e.target.style.width = `${e.width}px`; e.target.style.height = `${e.height}px`; const input = document.querySelector(".input")!; input.innerHTML = JSON.stringify({ dist: e.dist, width: e.width, height: e.height }); } }