@royaloperahouse/harmonic 1.0.8-d → 1.0.8-e
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/dist/harmonic.cjs.development.js +2 -2
- package/dist/harmonic.cjs.development.js.map +1 -1
- package/dist/harmonic.cjs.production.min.js +1 -1
- package/dist/harmonic.cjs.production.min.js.map +1 -1
- package/dist/harmonic.esm.js +2 -2
- package/dist/harmonic.esm.js.map +1 -1
- package/package.json +1 -1
package/dist/harmonic.esm.js
CHANGED
|
@@ -12270,7 +12270,7 @@ var AnchorTabBar = function AnchorTabBar(_ref) {
|
|
|
12270
12270
|
}, []);
|
|
12271
12271
|
useEffect(function () {
|
|
12272
12272
|
var scrollTriggerCheck = function scrollTriggerCheck() {
|
|
12273
|
-
var elementGap =
|
|
12273
|
+
var elementGap = LIST_ITEM_GAP;
|
|
12274
12274
|
var reachedItem = tabs == null ? void 0 : tabs.find(function (item) {
|
|
12275
12275
|
var targetSectionElement = document.getElementById(item.id);
|
|
12276
12276
|
if (!targetSectionElement) return false;
|
|
@@ -12293,7 +12293,7 @@ var AnchorTabBar = function AnchorTabBar(_ref) {
|
|
|
12293
12293
|
offsetWidth = tabLinkElement.offsetWidth;
|
|
12294
12294
|
var isInView = offsetLeft >= scrollLeft && offsetLeft + offsetWidth < scrollLeft + clientWidth;
|
|
12295
12295
|
if (!isInView && tabListRef != null && tabListRef.current) {
|
|
12296
|
-
tabListRef.current.scrollLeft = offsetLeft;
|
|
12296
|
+
tabListRef.current.scrollLeft = offsetLeft - LIST_ITEM_GAP;
|
|
12297
12297
|
}
|
|
12298
12298
|
setSelectedItem(reachedItem.id);
|
|
12299
12299
|
}
|