MCPcopy Index your code
hub / github.com/gridstack/gridstack.js / _setupHelper

Method _setupHelper

src/dd-resizable.ts:225–242  ·  view source on GitHub ↗

@internal

()

Source from the content-addressed store, hash-verified

223
224 /** @internal */
225 protected _setupHelper(): DDResizable {
226 this.elOriginStyleVal = DDResizable._originStyleProp.map(prop => this.el.style[prop]);
227 this.parentOriginStylePosition = this.el.parentElement.style.position;
228
229 const parent = this.el.parentElement;
230 const dragTransform = Utils.getValuesFromTransformedElement(parent);
231 this.rectScale = {
232 x: dragTransform.xScale,
233 y: dragTransform.yScale
234 };
235
236 if (getComputedStyle(this.el.parentElement).position.match(/static/)) {
237 this.el.parentElement.style.position = 'relative';
238 }
239 this.el.style.position = 'absolute';
240 this.el.style.opacity = '0.8';
241 return this;
242 }
243
244 /** @internal */
245 protected _cleanHelper(): DDResizable {

Callers 1

_resizeStartMethod · 0.95

Calls 1

Tested by

no test coverage detected