comand-component-library 4.1.65 → 4.1.66

Sign up to get free protection for your applications and to get access to all the features.
@@ -1906,7 +1906,7 @@ const Y = /* @__PURE__ */ P(ss, [["render", ys]]), bs = {
1906
1906
  mounted() {
1907
1907
  if (this.relatedId) {
1908
1908
  const e = document.getElementById(this.relatedId);
1909
- e && (document.querySelector(this.scrollContainer).addEventListener("scroll", this.hideTooltip), document.addEventListener("keyup", this.hideTooltipOnEsc), this.toggleVisibilityByClick ? e.addEventListener("click", this.toggleTooltipVisibility) : (e.addEventListener("mouseenter", this.showTooltip), e.addEventListener("mouseleave", this.hideTooltip)));
1909
+ e && (this.scrollContainer && (document.querySelector(this.scrollContainer).addEventListener("scroll", this.hideTooltip), document.addEventListener("keyup", this.hideTooltipOnEsc)), this.toggleVisibilityByClick ? e.addEventListener("click", this.toggleTooltipVisibility) : (e.addEventListener("mouseenter", this.showTooltip), e.addEventListener("mouseleave", this.hideTooltip)));
1910
1910
  }
1911
1911
  },
1912
1912
  methods: {
@@ -2180,7 +2180,7 @@ const Bs = /* @__PURE__ */ P(ks, [["render", Is]]), Fs = {
2180
2180
  name: "CmdTooltipForFormElements",
2181
2181
  props: {
2182
2182
  /**
2183
- * scrollContainerForTooltip
2183
+ * specify a scroll-container which scrolling hides the tooltip
2184
2184
  */
2185
2185
  scrollContainerForTooltip: {
2186
2186
  type: String,
@@ -2618,6 +2618,9 @@ const fn = {
2618
2618
  };
2619
2619
  },
2620
2620
  props: {
2621
+ /**
2622
+ * specify a scroll-container which scrolling hides the tooltip
2623
+ */
2621
2624
  scrollContainerForTooltip: {
2622
2625
  type: String,
2623
2626
  required: !1
@@ -18547,7 +18550,7 @@ function c1(e, n, t, s, i, o) {
18547
18550
  })
18548
18551
  ], 64);
18549
18552
  }
18550
- const bo = /* @__PURE__ */ P(e1, [["render", c1]]), u1 = "comand-component-library", m1 = "4.1.65", h1 = "GPL-3.0-only", p1 = "CoManD-UI", f1 = "module", g1 = {
18553
+ const bo = /* @__PURE__ */ P(e1, [["render", c1]]), u1 = "comand-component-library", m1 = "4.1.66", h1 = "GPL-3.0-only", p1 = "CoManD-UI", f1 = "module", g1 = {
18551
18554
  prepublishOnly: "npm run build-lib",
18552
18555
  dev: "vite",
18553
18556
  build: "vite build",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "comand-component-library",
3
- "version": "4.1.65",
3
+ "version": "4.1.66",
4
4
  "license": "GPL-3.0-only",
5
5
  "author": "CoManD-UI",
6
6
  "private": false,
@@ -284,6 +284,9 @@ export default {
284
284
  }
285
285
  },
286
286
  props: {
287
+ /**
288
+ * specify a scroll-container which scrolling hides the tooltip
289
+ */
287
290
  scrollContainerForTooltip: {
288
291
  type: String,
289
292
  required: false
@@ -117,8 +117,10 @@ export default {
117
117
  const relatedElement = document.getElementById(this.relatedId)
118
118
 
119
119
  if(relatedElement) {
120
- document.querySelector(this.scrollContainer).addEventListener("scroll", this.hideTooltip) // avoid fixed tooltip on scroll
121
- document.addEventListener("keyup", this.hideTooltipOnEsc) // close tooltip by using "escape"-key
120
+ if(this.scrollContainer) {
121
+ document.querySelector(this.scrollContainer).addEventListener("scroll", this.hideTooltip) // avoid fixed tooltip on scroll
122
+ document.addEventListener("keyup", this.hideTooltipOnEsc) // close tooltip by using "escape"-key
123
+ }
122
124
 
123
125
  if (this.toggleVisibilityByClick) {
124
126
  relatedElement.addEventListener("click", this.toggleTooltipVisibility)
@@ -23,7 +23,7 @@ export default {
23
23
  name: "CmdTooltipForFormElements",
24
24
  props: {
25
25
  /**
26
- * scrollContainerForTooltip
26
+ * specify a scroll-container which scrolling hides the tooltip
27
27
  */
28
28
  scrollContainerForTooltip: {
29
29
  type: String,