not-bulma 1.2.39 → 1.2.40
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/package.json
CHANGED
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
export let showIcon = "eye";
|
|
9
9
|
export let hideIcon = "eye-slash";
|
|
10
10
|
export let maxLength = 20;
|
|
11
|
+
export let shadowClass = "has-background-primary-90";
|
|
11
12
|
export let tooltip = true;
|
|
12
13
|
export let tooltipTTL = 2000;
|
|
13
14
|
export let tooltipText = "Скопировано в буфер";
|
|
@@ -42,24 +43,25 @@
|
|
|
42
43
|
$: tooltipActive = tooltip && contentCopied;
|
|
43
44
|
</script>
|
|
44
45
|
|
|
45
|
-
<
|
|
46
|
+
<span
|
|
47
|
+
class={(hidden ? "is-censored " + shadowClass : "") +
|
|
48
|
+
" is-vertical-middle "}
|
|
49
|
+
style={`display:inline-block; width: ${maxLength}rem; height: var(--bulma-size-medium); overflow-x:hidden;`}
|
|
50
|
+
>{hidden ? "" : value}</span
|
|
51
|
+
>
|
|
52
|
+
{#if copiable}
|
|
46
53
|
<span
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
54
|
+
bind:this={tooltipTarget}
|
|
55
|
+
on:click={copyContent}
|
|
56
|
+
class={"icon is-small is-right is-clickable " +
|
|
57
|
+
(tooltipActive ? ` ${tooltipClass} ` : "") +
|
|
58
|
+
" is-vertical-middle"}><i class="fas fa-{copyIcon}" /></span
|
|
50
59
|
>
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
{/if}
|
|
60
|
-
{#if showable}
|
|
61
|
-
<span class="icon is-small is-right is-clickable" on:click={toggleView}
|
|
62
|
-
><i class="fas fa-{hidden ? showIcon : hideIcon}" /></span
|
|
63
|
-
>
|
|
64
|
-
{/if}
|
|
65
|
-
</p>
|
|
60
|
+
{/if}
|
|
61
|
+
{#if showable}
|
|
62
|
+
<span
|
|
63
|
+
class="icon is-small is-right is-clickable is-vertical-middle"
|
|
64
|
+
on:click={toggleView}
|
|
65
|
+
><i class="fas fa-{hidden ? showIcon : hideIcon}" /></span
|
|
66
|
+
>
|
|
67
|
+
{/if}
|