@caweb/framework 1.9.13 → 1.9.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/delta.asset.php +1 -1
- package/build/delta.js +23 -27
- package/build/delta.js.map +1 -1
- package/build/delta.min.asset.php +1 -1
- package/build/delta.min.js +1 -1
- package/build/delta.min.js.map +1 -1
- package/build/eureka.asset.php +1 -1
- package/build/eureka.js +23 -27
- package/build/eureka.js.map +1 -1
- package/build/eureka.min.asset.php +1 -1
- package/build/eureka.min.js +1 -1
- package/build/eureka.min.js.map +1 -1
- package/build/mono.asset.php +1 -1
- package/build/mono.js +23 -27
- package/build/mono.js.map +1 -1
- package/build/mono.min.asset.php +1 -1
- package/build/mono.min.js +1 -1
- package/build/mono.min.js.map +1 -1
- package/build/oceanside.asset.php +1 -1
- package/build/oceanside.js +23 -27
- package/build/oceanside.js.map +1 -1
- package/build/oceanside.min.asset.php +1 -1
- package/build/oceanside.min.js +1 -1
- package/build/oceanside.min.js.map +1 -1
- package/build/orangecounty.asset.php +1 -1
- package/build/orangecounty.js +23 -27
- package/build/orangecounty.js.map +1 -1
- package/build/orangecounty.min.asset.php +1 -1
- package/build/orangecounty.min.js +1 -1
- package/build/orangecounty.min.js.map +1 -1
- package/build/pasorobles.asset.php +1 -1
- package/build/pasorobles.js +23 -27
- package/build/pasorobles.js.map +1 -1
- package/build/pasorobles.min.asset.php +1 -1
- package/build/pasorobles.min.js +1 -1
- package/build/pasorobles.min.js.map +1 -1
- package/build/sacramento.asset.php +1 -1
- package/build/sacramento.js +23 -27
- package/build/sacramento.js.map +1 -1
- package/build/sacramento.min.asset.php +1 -1
- package/build/sacramento.min.js +1 -1
- package/build/sacramento.min.js.map +1 -1
- package/build/santabarbara.asset.php +1 -1
- package/build/santabarbara.js +23 -27
- package/build/santabarbara.js.map +1 -1
- package/build/santabarbara.min.asset.php +1 -1
- package/build/santabarbara.min.js +1 -1
- package/build/santabarbara.min.js.map +1 -1
- package/build/santacruz.asset.php +1 -1
- package/build/santacruz.js +23 -27
- package/build/santacruz.js.map +1 -1
- package/build/santacruz.min.asset.php +1 -1
- package/build/santacruz.min.js +1 -1
- package/build/santacruz.min.js.map +1 -1
- package/build/shasta.asset.php +1 -1
- package/build/shasta.js +23 -27
- package/build/shasta.js.map +1 -1
- package/build/shasta.min.asset.php +1 -1
- package/build/shasta.min.js +1 -1
- package/build/shasta.min.js.map +1 -1
- package/build/sierra.asset.php +1 -1
- package/build/sierra.js +23 -27
- package/build/sierra.js.map +1 -1
- package/build/sierra.min.asset.php +1 -1
- package/build/sierra.min.js +1 -1
- package/build/sierra.min.js.map +1 -1
- package/build/trinity.asset.php +1 -1
- package/build/trinity.js +23 -27
- package/build/trinity.js.map +1 -1
- package/build/trinity.min.asset.php +1 -1
- package/build/trinity.min.js +1 -1
- package/build/trinity.min.js.map +1 -1
- package/package.json +1 -1
- package/src/scripts/components/dark-mode.js +1 -1
- package/src/scripts/components/external-link.js +2 -2
- package/src/scripts/components/header.js +25 -26
- package/src/scripts/components/mobile-controls.js +1 -1
- package/src/scripts/components/return-top.js +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
<?php return array('dependencies' => array(), 'version' => '
|
|
1
|
+
<?php return array('dependencies' => array(), 'version' => '2bfb25e3ec6c17dfbc98');
|
package/build/pasorobles.js
CHANGED
|
@@ -6324,10 +6324,8 @@
|
|
|
6324
6324
|
|
|
6325
6325
|
"use strict";
|
|
6326
6326
|
__webpack_require__.r(__webpack_exports__);
|
|
6327
|
-
//@ts-check
|
|
6328
|
-
|
|
6329
6327
|
/* EXTERNAL LINK ICON */
|
|
6330
|
-
window.addEventListener('
|
|
6328
|
+
window.addEventListener('load', () => {
|
|
6331
6329
|
const ext = '<span class="ca-gov-icon-external-link" aria-hidden="true"></span><span class="sr-only">opens in a new window</span>';
|
|
6332
6330
|
|
|
6333
6331
|
// Add any exceptions to not render here
|
|
@@ -6355,14 +6353,15 @@ window.addEventListener('DOMContentLoaded', () => {
|
|
|
6355
6353
|
|
|
6356
6354
|
"use strict";
|
|
6357
6355
|
__webpack_require__.r(__webpack_exports__);
|
|
6358
|
-
|
|
6359
|
-
window.addEventListener('DOMContentLoaded', () => {
|
|
6356
|
+
window.addEventListener('load', () => {
|
|
6360
6357
|
let location_hash = window.location.hash.replace(/(\|)/g, "\\$1");
|
|
6361
6358
|
const header = document.querySelector('header');
|
|
6362
6359
|
const pageContainer = document.querySelector('#page-container');
|
|
6360
|
+
const alerts = header?.querySelector('.alerts');
|
|
6361
|
+
const utilityHeader = header?.querySelector('.utility-header');
|
|
6363
6362
|
|
|
6364
6363
|
// array of elements that are compacted
|
|
6365
|
-
const compactedElements = [
|
|
6364
|
+
const compactedElements = [alerts, utilityHeader].filter(Boolean);
|
|
6366
6365
|
const getCompactedElementsHeight = () => {
|
|
6367
6366
|
return compactedElements.reduce((total, element) => {
|
|
6368
6367
|
if (element instanceof HTMLElement) {
|
|
@@ -6373,16 +6372,21 @@ window.addEventListener('DOMContentLoaded', () => {
|
|
|
6373
6372
|
};
|
|
6374
6373
|
let compactedElementsHeight = getCompactedElementsHeight();
|
|
6375
6374
|
|
|
6376
|
-
//
|
|
6377
|
-
|
|
6378
|
-
|
|
6379
|
-
|
|
6380
|
-
|
|
6381
|
-
if (current instanceof HTMLElement && window.getComputedStyle(current).position === 'fixed') {
|
|
6382
|
-
topOffset += current.clientHeight;
|
|
6375
|
+
// resize observer function to watch if compacted elements change height, so we can update the compacted elements height when they change.
|
|
6376
|
+
const clientHeightObserver = entries => {
|
|
6377
|
+
for (const entry of entries) {
|
|
6378
|
+
// update the compacted elements height when the compacted entry changes., which can happen when google translate loads and changes the height of the utility header or when items wrap
|
|
6379
|
+
compactedElementsHeight = getCompactedElementsHeight();
|
|
6383
6380
|
}
|
|
6384
|
-
|
|
6385
|
-
|
|
6381
|
+
};
|
|
6382
|
+
|
|
6383
|
+
// observe compacted elements for height changes, so we can update the compacted elements height when they change.
|
|
6384
|
+
compactedElements.forEach(element => {
|
|
6385
|
+
if (element instanceof HTMLElement) {
|
|
6386
|
+
const observer = new ResizeObserver(clientHeightObserver);
|
|
6387
|
+
observer.observe(element);
|
|
6388
|
+
}
|
|
6389
|
+
});
|
|
6386
6390
|
|
|
6387
6391
|
// scroll to target
|
|
6388
6392
|
if (location_hash) {
|
|
@@ -6403,17 +6407,12 @@ window.addEventListener('DOMContentLoaded', () => {
|
|
|
6403
6407
|
// downscroll code passed the header height
|
|
6404
6408
|
if (document.body.scrollTop >= header.offsetHeight || document.documentElement.scrollTop >= header.offsetHeight) {
|
|
6405
6409
|
// move the header up to hide the compacted elements height, minus the top offset.
|
|
6406
|
-
header.style.top = `-${compactedElementsHeight
|
|
6410
|
+
header.style.top = `-${compactedElementsHeight}px`;
|
|
6407
6411
|
} else {
|
|
6408
6412
|
// reset header to initial position
|
|
6409
6413
|
// we need to set the header's top to the offset.
|
|
6410
6414
|
if (header) {
|
|
6411
|
-
header.style.top =
|
|
6412
|
-
}
|
|
6413
|
-
|
|
6414
|
-
// if we have a page container, we need to set its top padding to the offset
|
|
6415
|
-
if (pageContainer && pageContainer instanceof HTMLElement) {
|
|
6416
|
-
// pageContainer.style.paddingTop = `${topOffset}px`;
|
|
6415
|
+
header.style.top = 0;
|
|
6417
6416
|
}
|
|
6418
6417
|
}
|
|
6419
6418
|
};
|
|
@@ -6429,8 +6428,6 @@ window.addEventListener('DOMContentLoaded', () => {
|
|
|
6429
6428
|
// for each element with an id we add the scroll-margin-top
|
|
6430
6429
|
const updateScrollMarginTop = (/** @type Element */element) => {
|
|
6431
6430
|
if (element instanceof HTMLElement) {
|
|
6432
|
-
let scrollMarginHeight = header.clientHeight + topOffset;
|
|
6433
|
-
|
|
6434
6431
|
// if the elements offsetTop is greater than twice the header size,
|
|
6435
6432
|
// we can assume the header is compacted
|
|
6436
6433
|
// so we need to subtract the compacted elements height from the scroll margin.
|
|
@@ -6456,7 +6453,7 @@ window.addEventListener('DOMContentLoaded', () => {
|
|
|
6456
6453
|
|
|
6457
6454
|
"use strict";
|
|
6458
6455
|
__webpack_require__.r(__webpack_exports__);
|
|
6459
|
-
window.addEventListener('
|
|
6456
|
+
window.addEventListener('load', () => {
|
|
6460
6457
|
const isDesktopWidth = () => window.innerWidth > 992; //Maximum px for mobile width
|
|
6461
6458
|
|
|
6462
6459
|
const mainHeader = document.querySelector('header');
|
|
@@ -6562,8 +6559,7 @@ window.addEventListener('DOMContentLoaded', () => {
|
|
|
6562
6559
|
|
|
6563
6560
|
"use strict";
|
|
6564
6561
|
__webpack_require__.r(__webpack_exports__);
|
|
6565
|
-
|
|
6566
|
-
window.addEventListener('DOMContentLoaded', () => {
|
|
6562
|
+
window.addEventListener('load', () => {
|
|
6567
6563
|
document.querySelectorAll('.return-top').forEach(returnTop => returnTop.addEventListener('click', () => {
|
|
6568
6564
|
document.body.scrollTop = 0; // For Safari
|
|
6569
6565
|
document.documentElement.scrollTop = 0; // For Chrome, Firefox, IE and Opera
|