MCPcopy Create free account
hub / github.com/play-co/devkit / sizeToCSS

Function sizeToCSS

src/web/ui/Chrome.js:466–472  ·  view source on GitHub ↗
(size, scale)

Source from the content-addressed store, hash-verified

464 };
465
466 function sizeToCSS(size, scale) {
467 scale = scale || 1;
468 return {
469 width: size && size.width ? size.width * scale + 'px' : '100%',
470 height: size && size.height ? size.height * scale + 'px' : '100%'
471 };
472 }
473
474 this._setViewport = function (size, viewport, zoom) {
475 $.style(this.contents, sizeToCSS(size, zoom));

Callers 1

Chrome.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…