MCPcopy Create free account
hub / github.com/mailvelope/mailvelope / setFrameDim

Method setFrameDim

src/content-scripts/decryptFrame.js:104–120  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

102 }
103
104 setFrameDim() {
105 if (this.dDialog === null) {
106 super.setFrameDim();
107 } else {
108 const {height} = this.pgpRange.getBoundingClientRect();
109 let {width} = this.pgpElement.parentElement.getBoundingClientRect();
110 if (!width || !height) {
111 return;
112 }
113 // less 1px border and 2 pixel box-shadow
114 width -= 3;
115 this.eFrame.style.width = `${width}px`;
116 // set absolute dims for performance reasons
117 this.dDialog.style.width = `${width}px`;
118 this.dDialog.style.height = `${height}px`;
119 }
120 }
121}

Callers 1

inlineDialogMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected