Skip to main content

City of Norwalk, Fair Housing Officer

Citation
City of Norwalk, Fair Housing Officer
Jurisdiction
Norwalk (municipal)
Source
Official source

Full Text

1,578 chars
// Outer banner padding (push banner down)
const outerSizingTS = $("#bannerContainerTS");
// Inner banner padding (push banner content down) - Transparent header OR on attaching headers
const innerSizingTS = $("#bannerSizingTS");
const bodyContainerTS = $("#bodyContainerTS");

const forceUnfixClassTS = "forceUnfixTS";

const fixedTopTS = $(".fixedTopTS");
const fixedBottomTS = $(".fixedBottomTS");
const fixedLeftTS = $(".fixedLeftTS");

var initialTopTS;
var topAttachTS;
if (fixedTopTS && fixedTopTS.length === 1) {
initialTopTS = getValueTS(fixedTopTS, 'top');
const attachment = fixedTopTS.attr('data-attach');
if (attachment) topAttachTS = $("#" + attachment);
if (!topAttachTS || topAttachTS.length !== 1) topAttachTS = undefined;
}

function resizeAdjustmentTS() {
const editing = isPageEditingTS();

// Fixed top script
(function () {
if (!fixedTopTS || fixedTopTS.length !== 1 || initialTopTS === undefined) return;

if (editing) {
fixedTopTS[0].classList.add(forceUnfixClassTS);
} else {
fixedTopTS[0].classList.remove(forceUnfixClassTS);
}

const topPosition = fixedTopTS.css('position');
if (topPosition === 'fixed') {
if (topAttachTS) {
scrollAdjustmentTS();
} else {
const anchorHeight = anchor.outerHeight() - 1;
fixedTopTS.css('top', anchorHeight + initialTopTS);
}
} else {
fixedTopTS.css('top', initialTopTS);
}

if (topPosition === 'fixed' || topPosition === 'absolute') {
// Bump the banner content down
if (isTransparentTS(fixedTopTS)) {
innerSizingTS.css('padding-top', initialTopTS + fixedTopTS.outerHeight() - 1);
outerSizingTS.css('padding-top', '');