@brightspot/ui 6.7.0 → 6.7.1-pr.401.2026.10.22
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/storybook/project.json +1 -1
- package/package.json +1 -1
- package/src/legacy/tool-ui/src/AnalyticsWidget.ts +19 -9
- package/src/legacy/tool-ui/src/main/webapp/dist/{v4.b1cc13348e098860f3f2.js → v4.eea68972e75f531f0f9c.js} +2 -2
- package/src/legacy/tool-ui/src/main/webapp/dist/{v5.a627e1a0e699d6dc16d2.js → v5.dab916118c83ba0a0fdb.js} +2 -2
- /package/src/legacy/tool-ui/src/main/webapp/dist/{v4.b1cc13348e098860f3f2.js.LICENSE.txt → v4.eea68972e75f531f0f9c.js.LICENSE.txt} +0 -0
- /package/src/legacy/tool-ui/src/main/webapp/dist/{v5.a627e1a0e699d6dc16d2.js.LICENSE.txt → v5.dab916118c83ba0a0fdb.js.LICENSE.txt} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"generatedAt":
|
|
1
|
+
{"generatedAt":1792649730439,"hasCustomBabel":false,"hasCustomWebpack":false,"hasStaticDirs":true,"hasStorybookEslint":true,"refCount":0,"knownPackages":{"testPackages":{"@storybook/addon-vitest":"10.2.12","@vitest/browser-playwright":"4.1.11","playwright":"1.58.2","vitest":"4.1.11"},"stylingPackages":{"tailwindcss":"^3.4.13","autoprefixer":"10.4.21"}},"hasRouterPackage":false,"packageManager":{"type":"yarn","agent":"yarn","nodeLinker":"undefined"},"preview":{"usesGlobals":true},"framework":{"name":"@storybook/web-components-vite","options":{}},"builder":"@storybook/builder-vite","renderer":"@storybook/web-components","portableStoriesFileCount":0,"applicationFileCount":6,"storybookVersion":"10.2.12","storybookVersionSpecifier":"10.2.12","language":"typescript","storybookPackages":{"@storybook/addon-themes":{"version":"10.2.12"},"@storybook/web-components-vite":{"version":"10.2.12"},"@wc-toolkit/storybook-helpers":{"version":"10.0.0"},"eslint-plugin-storybook":{"version":"10.0.7"},"storybook":{}},"addons":{"@storybook/addon-docs":{"version":"10.2.12"},"@storybook/addon-vitest":{"version":"10.2.12"}},"packageJsonType":"module"}
|
package/package.json
CHANGED
|
@@ -46,19 +46,29 @@ export default class AnalyticsWidget {
|
|
|
46
46
|
}
|
|
47
47
|
|
|
48
48
|
private init(): void {
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
49
|
+
const tabElement = this.element.closest<HTMLElement>('[data-tab]')
|
|
50
|
+
|
|
51
|
+
if (tabElement) {
|
|
52
|
+
// Listen for tab activation
|
|
53
|
+
$(tabElement).on('tabbedShow', () => {
|
|
53
54
|
// Only load if tab is actually selected/visible, not just during initial setup
|
|
54
|
-
|
|
55
|
-
if (
|
|
56
|
-
!this.isLoaded &&
|
|
57
|
-
!tabElement?.classList.contains('TC-unselected')
|
|
58
|
-
) {
|
|
55
|
+
if (!this.isLoaded && !tabElement.classList.contains('TC-unselected')) {
|
|
59
56
|
this.loadAnalyticsData()
|
|
60
57
|
}
|
|
61
58
|
})
|
|
59
|
+
} else {
|
|
60
|
+
// Bottom, Right and Top placements have no tab to fire tabbedShow, so load
|
|
61
|
+
// the first time the widget scrolls into view instead.
|
|
62
|
+
const observer = new IntersectionObserver((entries) => {
|
|
63
|
+
if (entries.some((entry) => entry.isIntersecting)) {
|
|
64
|
+
observer.disconnect()
|
|
65
|
+
if (!this.isLoaded) {
|
|
66
|
+
this.loadAnalyticsData()
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
})
|
|
70
|
+
observer.observe(this.element)
|
|
71
|
+
}
|
|
62
72
|
|
|
63
73
|
// Listen for period selector changes
|
|
64
74
|
if (this.periodSelector) {
|