MCPcopy Create free account
hub / github.com/TruthHun/BookStack / positionLineWidget

Function positionLineWidget

static/mergely/lib/codemirror.js:1057–1073  ·  view source on GitHub ↗
(widget, node, lineView, dims)

Source from the content-addressed store, hash-verified

1055 }
1056
1057 function positionLineWidget(widget, node, lineView, dims) {
1058 if (widget.noHScroll) {
1059 (lineView.alignable || (lineView.alignable = [])).push(node);
1060 var width = dims.wrapperWidth;
1061 node.style.left = dims.fixedPos + "px";
1062 if (!widget.coverGutter) {
1063 width -= dims.gutterTotalWidth;
1064 node.style.paddingLeft = dims.gutterTotalWidth + "px";
1065 }
1066 node.style.width = width + "px";
1067 }
1068 if (widget.coverGutter) {
1069 node.style.zIndex = 5;
1070 node.style.position = "relative";
1071 if (!widget.noHScroll) node.style.marginLeft = -dims.gutterTotalWidth + "px";
1072 }
1073 }
1074
1075 // POSITION OBJECT
1076

Callers 1

insertLineWidgetsForFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected