@kestra-io/ui-libs 0.0.122 → 0.0.123
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ProsePre.vue.d.ts","sourceRoot":"","sources":["../../../src/components/content/ProsePre.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ProsePre.vue.d.ts","sourceRoot":"","sources":["../../../src/components/content/ProsePre.vue"],"names":[],"mappings":"AA0JI,KAAK,WAAW,GAAG;IACf,IAAI,EAAC,MAAM,CAAC;IACZ,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,MAAM,CAAC;CACjB,CAAC;AAiDN,iBAAS,cAAc;WAkGT,OAAO,IAA6B;;yBAZpB,GAAG;;;;;;;EAiBhC;AAmBD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;UA7KN,MAAM;cAFF,MAAM;gBACJ,MAAM;;;;OAsLzB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAapG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
|
package/package.json
CHANGED
|
@@ -9,11 +9,9 @@
|
|
|
9
9
|
{{ language }}
|
|
10
10
|
</div>
|
|
11
11
|
<template v-if="isHoveringCode">
|
|
12
|
-
<button ref="copyButton" class="copy">
|
|
13
|
-
<
|
|
14
|
-
|
|
15
|
-
@click="copyToClipboard"
|
|
16
|
-
/>
|
|
12
|
+
<button ref="copyButton" class="copy" @click="copyToClipboard" :disabled="copiedSuccessfully">
|
|
13
|
+
<CheckIcon v-if="copiedSuccessfully" />
|
|
14
|
+
<ContentCopy v-else />
|
|
17
15
|
</button>
|
|
18
16
|
<div ref="copyTooltip" v-if="!!copyIconResetTimer" id="copied-tooltip" role="tooltip">
|
|
19
17
|
Copied!
|
|
@@ -28,7 +26,7 @@
|
|
|
28
26
|
import {createPopper} from "@popperjs/core";
|
|
29
27
|
|
|
30
28
|
import ContentCopy from "vue-material-design-icons/ContentCopy.vue";
|
|
31
|
-
import
|
|
29
|
+
import CheckIcon from "vue-material-design-icons/Check.vue";
|
|
32
30
|
import {nextTick, Ref, ref} from "vue";
|
|
33
31
|
import Mermaid from "./Mermaid.vue";
|
|
34
32
|
|
|
@@ -44,12 +42,8 @@
|
|
|
44
42
|
meta: undefined,
|
|
45
43
|
})
|
|
46
44
|
|
|
47
|
-
const
|
|
48
|
-
ContentCopy,
|
|
49
|
-
Check
|
|
50
|
-
}
|
|
45
|
+
const copiedSuccessfully = ref(false)
|
|
51
46
|
|
|
52
|
-
const copyIcon = ref(icons.ContentCopy)
|
|
53
47
|
const copyIconResetTimer = ref()
|
|
54
48
|
const isHoveringCode = ref(false)
|
|
55
49
|
|
|
@@ -74,10 +68,10 @@
|
|
|
74
68
|
|
|
75
69
|
navigator.clipboard.writeText(props.code.trimEnd())
|
|
76
70
|
|
|
77
|
-
|
|
71
|
+
copiedSuccessfully.value = true;
|
|
78
72
|
|
|
79
73
|
copyIconResetTimer.value = setTimeout(() => {
|
|
80
|
-
|
|
74
|
+
copiedSuccessfully.value = false;
|
|
81
75
|
copyIconResetTimer.value = undefined;
|
|
82
76
|
}, 2000)
|
|
83
77
|
}
|