@onsvisual/svelte-components 1.1.41 → 1.1.42
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.
|
@@ -14,6 +14,11 @@
|
|
|
14
14
|
* @type {number|null}
|
|
15
15
|
*/
|
|
16
16
|
export let width = null;
|
|
17
|
+
/**
|
|
18
|
+
* Set z-index of tooltip, to ensure it appears in front of other elements
|
|
19
|
+
* @type {number}
|
|
20
|
+
*/
|
|
21
|
+
export let zIndex = 1;
|
|
17
22
|
|
|
18
23
|
let isHovered = false;
|
|
19
24
|
|
|
@@ -39,6 +44,7 @@
|
|
|
39
44
|
{#if isHovered}
|
|
40
45
|
<div
|
|
41
46
|
class="tooltip tooltip-{position}"
|
|
47
|
+
style:z-index={zIndex}
|
|
42
48
|
style:width={width != null ? `${width}px` : null}
|
|
43
49
|
style:white-space={width == null ? "nowrap" : "wrap"}
|
|
44
50
|
>
|
|
@@ -5,6 +5,7 @@ export default class Tooltip extends SvelteComponentTyped<{
|
|
|
5
5
|
width?: number | null | undefined;
|
|
6
6
|
text?: string | undefined;
|
|
7
7
|
position?: "top" | "bottom" | "left" | "right" | "middle" | undefined;
|
|
8
|
+
zIndex?: number | undefined;
|
|
8
9
|
}, {
|
|
9
10
|
[evt: string]: CustomEvent<any>;
|
|
10
11
|
}, {
|
|
@@ -20,6 +21,7 @@ declare const __propDef: {
|
|
|
20
21
|
width?: number | null | undefined;
|
|
21
22
|
text?: string | undefined;
|
|
22
23
|
position?: "top" | "bottom" | "left" | "right" | "middle" | undefined;
|
|
24
|
+
zIndex?: number | undefined;
|
|
23
25
|
};
|
|
24
26
|
events: {
|
|
25
27
|
[evt: string]: CustomEvent<any>;
|