@dialpad/dialtone-vue 3.162.1 → 3.164.0
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/component-documentation.json +1 -1
- package/dist/components/hovercard/hovercard.vue.cjs +30 -4
- package/dist/components/hovercard/hovercard.vue.cjs.map +1 -1
- package/dist/components/hovercard/hovercard.vue.js +32 -6
- package/dist/components/hovercard/hovercard.vue.js.map +1 -1
- package/dist/components/popover/popover.vue.cjs +23 -45
- package/dist/components/popover/popover.vue.cjs.map +1 -1
- package/dist/components/popover/popover.vue.js +23 -45
- package/dist/components/popover/popover.vue.js.map +1 -1
- package/dist/components/rich_text_editor/extensions/image/image.cjs +30 -0
- package/dist/components/rich_text_editor/extensions/image/image.cjs.map +1 -0
- package/dist/components/rich_text_editor/extensions/image/image.js +30 -0
- package/dist/components/rich_text_editor/extensions/image/image.js.map +1 -0
- package/dist/components/rich_text_editor/extensions/image/index.cjs +5 -0
- package/dist/components/rich_text_editor/extensions/image/index.cjs.map +1 -0
- package/dist/components/rich_text_editor/extensions/image/index.js +5 -0
- package/dist/components/rich_text_editor/extensions/image/index.js.map +1 -0
- package/dist/components/rich_text_editor/rich_text_editor.vue.cjs +2 -2
- package/dist/components/rich_text_editor/rich_text_editor.vue.cjs.map +1 -1
- package/dist/components/rich_text_editor/rich_text_editor.vue.js +2 -2
- package/dist/components/rich_text_editor/rich_text_editor.vue.js.map +1 -1
- package/dist/recipes/buttons/callbar_button/callbar_button.vue.cjs +2 -4
- package/dist/recipes/buttons/callbar_button/callbar_button.vue.cjs.map +1 -1
- package/dist/recipes/buttons/callbar_button/callbar_button.vue.js +2 -4
- package/dist/recipes/buttons/callbar_button/callbar_button.vue.js.map +1 -1
- package/dist/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.cjs +1 -2
- package/dist/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.cjs.map +1 -1
- package/dist/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.js +1 -2
- package/dist/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.js.map +1 -1
- package/dist/recipes/cards/ivr_node/ivr_node.vue.cjs +10 -20
- package/dist/recipes/cards/ivr_node/ivr_node.vue.cjs.map +1 -1
- package/dist/recipes/cards/ivr_node/ivr_node.vue.js +11 -21
- package/dist/recipes/cards/ivr_node/ivr_node.vue.js.map +1 -1
- package/dist/recipes/cards/ivr_node/ivr_node_constants.cjs +18 -18
- package/dist/recipes/cards/ivr_node/ivr_node_constants.cjs.map +1 -1
- package/dist/recipes/cards/ivr_node/ivr_node_constants.js +18 -18
- package/dist/recipes/cards/ivr_node/ivr_node_constants.js.map +1 -1
- package/dist/recipes/chips/grouped_chip/grouped_chip.vue.cjs +1 -3
- package/dist/recipes/chips/grouped_chip/grouped_chip.vue.cjs.map +1 -1
- package/dist/recipes/chips/grouped_chip/grouped_chip.vue.js +1 -3
- package/dist/recipes/chips/grouped_chip/grouped_chip.vue.js.map +1 -1
- package/dist/recipes/comboboxes/combobox_multi_select/combobox_multi_select.vue.cjs +6 -1
- package/dist/recipes/comboboxes/combobox_multi_select/combobox_multi_select.vue.cjs.map +1 -1
- package/dist/recipes/comboboxes/combobox_multi_select/combobox_multi_select.vue.js +6 -1
- package/dist/recipes/comboboxes/combobox_multi_select/combobox_multi_select.vue.js.map +1 -1
- package/dist/recipes/conversation_view/editor/editor.vue.cjs +94 -96
- package/dist/recipes/conversation_view/editor/editor.vue.cjs.map +1 -1
- package/dist/recipes/conversation_view/editor/editor.vue.js +95 -97
- package/dist/recipes/conversation_view/editor/editor.vue.js.map +1 -1
- package/dist/recipes/conversation_view/emoji_row/emoji_row.vue.cjs +1 -1
- package/dist/recipes/conversation_view/emoji_row/emoji_row.vue.cjs.map +1 -1
- package/dist/recipes/conversation_view/emoji_row/emoji_row.vue.js +1 -1
- package/dist/recipes/conversation_view/emoji_row/emoji_row.vue.js.map +1 -1
- package/dist/recipes/conversation_view/feed_item_pill/feed_item_pill.vue.cjs +1 -1
- package/dist/recipes/conversation_view/feed_item_pill/feed_item_pill.vue.cjs.map +1 -1
- package/dist/recipes/conversation_view/feed_item_pill/feed_item_pill.vue.js +1 -1
- package/dist/recipes/conversation_view/feed_item_pill/feed_item_pill.vue.js.map +1 -1
- package/dist/recipes/conversation_view/message_input/message_input.vue.cjs +1 -1
- package/dist/recipes/conversation_view/message_input/message_input.vue.cjs.map +1 -1
- package/dist/recipes/conversation_view/message_input/message_input.vue.js +1 -1
- package/dist/recipes/conversation_view/message_input/message_input.vue.js.map +1 -1
- package/dist/recipes/item_layout/contact_info/contact_info.vue.cjs +6 -1
- package/dist/recipes/item_layout/contact_info/contact_info.vue.cjs.map +1 -1
- package/dist/recipes/item_layout/contact_info/contact_info.vue.js +6 -1
- package/dist/recipes/item_layout/contact_info/contact_info.vue.js.map +1 -1
- package/dist/recipes/leftbar/contact_row/contact_row.vue.cjs +8 -12
- package/dist/recipes/leftbar/contact_row/contact_row.vue.cjs.map +1 -1
- package/dist/recipes/leftbar/contact_row/contact_row.vue.js +8 -12
- package/dist/recipes/leftbar/contact_row/contact_row.vue.js.map +1 -1
- package/dist/recipes/leftbar/general_row/general_row_constants.cjs +11 -11
- package/dist/recipes/leftbar/general_row/general_row_constants.cjs.map +1 -1
- package/dist/recipes/leftbar/general_row/general_row_constants.js +11 -11
- package/dist/recipes/leftbar/general_row/general_row_constants.js.map +1 -1
- package/dist/recipes/leftbar/general_row/leftbar_general_row_icon.vue.cjs +7 -13
- package/dist/recipes/leftbar/general_row/leftbar_general_row_icon.vue.cjs.map +1 -1
- package/dist/recipes/leftbar/general_row/leftbar_general_row_icon.vue.js +7 -13
- package/dist/recipes/leftbar/general_row/leftbar_general_row_icon.vue.js.map +1 -1
- package/dist/recipes/notices/top_banner_info/top_banner_info.vue.cjs +8 -8
- package/dist/recipes/notices/top_banner_info/top_banner_info.vue.cjs.map +1 -1
- package/dist/recipes/notices/top_banner_info/top_banner_info.vue.js +8 -8
- package/dist/recipes/notices/top_banner_info/top_banner_info.vue.js.map +1 -1
- package/dist/types/components/hovercard/hovercard.vue.d.ts.map +1 -1
- package/dist/types/components/rich_text_editor/extensions/image/image.d.ts +2 -0
- package/dist/types/components/rich_text_editor/extensions/image/image.d.ts.map +1 -0
- package/dist/types/components/rich_text_editor/extensions/image/index.d.ts +3 -0
- package/dist/types/components/rich_text_editor/extensions/image/index.d.ts.map +1 -0
- package/dist/types/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.d.ts.map +1 -1
- package/dist/types/recipes/cards/ivr_node/ivr_node.vue.d.ts +1 -1
- package/dist/types/recipes/cards/ivr_node/ivr_node.vue.d.ts.map +1 -1
- package/dist/types/recipes/cards/ivr_node/ivr_node_constants.d.ts +11 -11
- package/dist/types/recipes/chips/grouped_chip/grouped_chip.vue.d.ts.map +1 -1
- package/dist/types/recipes/comboboxes/combobox_multi_select/combobox_multi_select.vue.d.ts.map +1 -1
- package/dist/types/recipes/conversation_view/editor/editor.vue.d.ts.map +1 -1
- package/dist/types/recipes/conversation_view/feed_item_pill/feed_item_pill.vue.d.ts +1 -1
- package/dist/types/recipes/conversation_view/message_input/message_input.vue.d.ts.map +1 -1
- package/dist/types/recipes/item_layout/contact_info/contact_info.vue.d.ts.map +1 -1
- package/dist/types/recipes/leftbar/contact_row/contact_row.vue.d.ts +1 -1
- package/dist/types/recipes/leftbar/general_row/general_row_constants.d.ts +6 -6
- package/dist/types/recipes/leftbar/general_row/leftbar_general_row_icon.vue.d.ts +0 -1
- package/package.json +8 -4
- package/dist/components/hovercard/timer.cjs +0 -60
- package/dist/components/hovercard/timer.cjs.map +0 -1
- package/dist/components/hovercard/timer.js +0 -60
- package/dist/components/hovercard/timer.js.map +0 -1
- package/dist/types/components/hovercard/timer.d.ts +0 -3
- package/dist/types/components/hovercard/timer.d.ts.map +0 -1
- package/dist/types/recipes/conversation_view/attachment_carousel/attachment_carousel_constants.d.ts +0 -6
- package/dist/types/recipes/conversation_view/attachment_carousel/attachment_carousel_constants.d.ts.map +0 -1
|
@@ -38,27 +38,27 @@ export namespace IVR_NODE_LABELS {
|
|
|
38
38
|
let assign_1: string;
|
|
39
39
|
export { assign_1 as assign };
|
|
40
40
|
}
|
|
41
|
-
export namespace
|
|
42
|
-
import promptmenu_2 =
|
|
41
|
+
export namespace IVR_NODE_CLASS_MAPPING {
|
|
42
|
+
import promptmenu_2 = IVR_NODE_CLASSES.PROMPT;
|
|
43
43
|
export { promptmenu_2 as promptmenu };
|
|
44
|
-
import promptcollect_2 =
|
|
44
|
+
import promptcollect_2 = IVR_NODE_CLASSES.PROMPT;
|
|
45
45
|
export { promptcollect_2 as promptcollect };
|
|
46
|
-
import promptplay_2 =
|
|
46
|
+
import promptplay_2 = IVR_NODE_CLASSES.PROMPT;
|
|
47
47
|
export { promptplay_2 as promptplay };
|
|
48
|
-
import gotoexpert_2 =
|
|
48
|
+
import gotoexpert_2 = IVR_NODE_CLASSES.LOGIC;
|
|
49
49
|
export { gotoexpert_2 as gotoexpert };
|
|
50
|
-
import branch_2 =
|
|
50
|
+
import branch_2 = IVR_NODE_CLASSES.LOGIC;
|
|
51
51
|
export { branch_2 as branch };
|
|
52
|
-
import goto_2 =
|
|
52
|
+
import goto_2 = IVR_NODE_CLASSES.LOGIC;
|
|
53
53
|
export { goto_2 as goto };
|
|
54
|
-
import assign_2 =
|
|
54
|
+
import assign_2 = IVR_NODE_CLASSES.LOGIC;
|
|
55
55
|
export { assign_2 as assign };
|
|
56
|
-
import transfer_2 =
|
|
56
|
+
import transfer_2 = IVR_NODE_CLASSES.TERMINAL;
|
|
57
57
|
export { transfer_2 as transfer };
|
|
58
|
-
import hangup_2 =
|
|
58
|
+
import hangup_2 = IVR_NODE_CLASSES.TERMINAL;
|
|
59
59
|
export { hangup_2 as hangup };
|
|
60
60
|
}
|
|
61
|
-
declare namespace
|
|
61
|
+
declare namespace IVR_NODE_CLASSES {
|
|
62
62
|
namespace PROMPT {
|
|
63
63
|
let normal: string;
|
|
64
64
|
let selected: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"grouped_chip.vue.d.ts","sourceRoot":"","sources":["../../../../../recipes/chips/grouped_chip/grouped_chip.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"grouped_chip.vue.d.ts","sourceRoot":"","sources":["../../../../../recipes/chips/grouped_chip/grouped_chip.vue"],"names":[],"mappings":"AAgEA;;;;;+BAsF+B,gBAAgB"}
|
package/dist/types/recipes/comboboxes/combobox_multi_select/combobox_multi_select.vue.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"combobox_multi_select.vue.d.ts","sourceRoot":"","sources":["../../../../../recipes/comboboxes/combobox_multi_select/combobox_multi_select.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"combobox_multi_select.vue.d.ts","sourceRoot":"","sources":["../../../../../recipes/comboboxes/combobox_multi_select/combobox_multi_select.vue"],"names":[],"mappings":"AAoHA;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"editor.vue.d.ts","sourceRoot":"","sources":["../../../../../recipes/conversation_view/editor/editor.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"editor.vue.d.ts","sourceRoot":"","sources":["../../../../../recipes/conversation_view/editor/editor.vue"],"names":[],"mappings":"AAkLA;"}
|
|
@@ -63,7 +63,7 @@ declare const _default: import('vue').DefineComponent<{
|
|
|
63
63
|
ariaLabel: string;
|
|
64
64
|
}, {}>;
|
|
65
65
|
showChevronIcon(): any;
|
|
66
|
-
toggleableClass(): "" | "d-
|
|
66
|
+
toggleableClass(): "" | "d-recipe-feed-item-pill--toggleable";
|
|
67
67
|
borderClass(): any;
|
|
68
68
|
}, {
|
|
69
69
|
onClick(): void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"message_input.vue.d.ts","sourceRoot":"","sources":["../../../../../recipes/conversation_view/message_input/message_input.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"message_input.vue.d.ts","sourceRoot":"","sources":["../../../../../recipes/conversation_view/message_input/message_input.vue"],"names":[],"mappings":"AA2NA;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"contact_info.vue.d.ts","sourceRoot":"","sources":["../../../../../recipes/item_layout/contact_info/contact_info.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"contact_info.vue.d.ts","sourceRoot":"","sources":["../../../../../recipes/item_layout/contact_info/contact_info.vue"],"names":[],"mappings":"AA8GA;"}
|
|
@@ -64,7 +64,7 @@ declare const _default: import('vue').DefineComponent<{
|
|
|
64
64
|
default: string;
|
|
65
65
|
};
|
|
66
66
|
}, any, any, {
|
|
67
|
-
|
|
67
|
+
presenceFontColorClass(): any;
|
|
68
68
|
contactRowListeners(): {
|
|
69
69
|
[k: string]: any;
|
|
70
70
|
};
|
|
@@ -15,16 +15,16 @@ export namespace LEFTBAR_GENERAL_ROW_TYPES {
|
|
|
15
15
|
let SCHEDULED: string;
|
|
16
16
|
}
|
|
17
17
|
export const LEFTBAR_GENERAL_ROW_CONTACT_CENTER_COLORS: {
|
|
18
|
+
'magenta-100': string;
|
|
18
19
|
'magenta-200': string;
|
|
19
|
-
'green-200': string;
|
|
20
|
-
'gold-300': string;
|
|
21
|
-
'purple-600': string;
|
|
22
20
|
'magenta-300': string;
|
|
23
|
-
'
|
|
21
|
+
'magenta-400': string;
|
|
22
|
+
'green-200': string;
|
|
24
23
|
'green-500': string;
|
|
24
|
+
'gold-300': string;
|
|
25
25
|
'purple-100': string;
|
|
26
|
-
'
|
|
27
|
-
'
|
|
26
|
+
'purple-300': string;
|
|
27
|
+
'purple-600': string;
|
|
28
28
|
'black-300': string;
|
|
29
29
|
};
|
|
30
30
|
export const LEFTBAR_GENERAL_ROW_CONTACT_CENTER_VALIDATION_ERROR: string;
|
|
@@ -46,7 +46,6 @@ declare const _default: import('vue').DefineComponent<{
|
|
|
46
46
|
ariaLabel: string;
|
|
47
47
|
}, {}> | undefined;
|
|
48
48
|
contactCenterIconClasses(): any[];
|
|
49
|
-
dialbotClasses(): string[];
|
|
50
49
|
}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
|
|
51
50
|
type: {
|
|
52
51
|
type: StringConstructor;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dialpad/dialtone-vue",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.164.0",
|
|
4
4
|
"description": "Vue component library for Dialpad's design system Dialtone",
|
|
5
5
|
"files": [
|
|
6
6
|
"dist"
|
|
@@ -38,16 +38,20 @@
|
|
|
38
38
|
"@dialpad/dialtone-icons": "4.32.0"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
|
+
"@storybook/addon-a11y": "7.6.20",
|
|
42
|
+
"@storybook/addon-essentials": "7.6.20",
|
|
43
|
+
"@storybook/addon-links": "7.6.20",
|
|
41
44
|
"@storybook/vue3": "7.6.20",
|
|
42
45
|
"@storybook/vue3-vite": "7.6.20",
|
|
43
46
|
"@vue/test-utils": "^2.4.0",
|
|
47
|
+
"storybook-dark-mode": "^3.0.3",
|
|
44
48
|
"vue": "^3.3.4",
|
|
45
|
-
"@dialpad/
|
|
46
|
-
"@dialpad/dialtone
|
|
49
|
+
"@dialpad/dialtone-css": "8.46.5",
|
|
50
|
+
"@dialpad/generator-dialtone": "0.1.0"
|
|
47
51
|
},
|
|
48
52
|
"peerDependencies": {
|
|
49
53
|
"vue": ">=3.2",
|
|
50
|
-
"@dialpad/dialtone-css": "^8.46.
|
|
54
|
+
"@dialpad/dialtone-css": "^8.46.5"
|
|
51
55
|
},
|
|
52
56
|
"bugs": {
|
|
53
57
|
"email": "dialtone@dialpad.com"
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
-
const vue = require("vue");
|
|
4
|
-
const tooltip_constants = require("../tooltip/tooltip_constants.cjs");
|
|
5
|
-
const useTimer = function() {
|
|
6
|
-
const current = vue.ref(null);
|
|
7
|
-
let timerLeave, timerEnter;
|
|
8
|
-
let start = null;
|
|
9
|
-
let prevCard = null;
|
|
10
|
-
function enter(id) {
|
|
11
|
-
if (prevCard) {
|
|
12
|
-
const time = Date.now() - start + 100;
|
|
13
|
-
if (timerLeave) clearTimeout(timerLeave);
|
|
14
|
-
if (prevCard !== id) {
|
|
15
|
-
timerLeave = setTimeout(
|
|
16
|
-
() => {
|
|
17
|
-
if (current.value !== null) {
|
|
18
|
-
start = Date.now();
|
|
19
|
-
}
|
|
20
|
-
current.value = null;
|
|
21
|
-
},
|
|
22
|
-
time
|
|
23
|
-
);
|
|
24
|
-
if (timerEnter) clearTimeout(timerEnter);
|
|
25
|
-
timerEnter = setTimeout(
|
|
26
|
-
() => {
|
|
27
|
-
current.value = id;
|
|
28
|
-
prevCard = id;
|
|
29
|
-
},
|
|
30
|
-
time
|
|
31
|
-
);
|
|
32
|
-
}
|
|
33
|
-
} else {
|
|
34
|
-
timerEnter = setTimeout(() => {
|
|
35
|
-
current.value = id;
|
|
36
|
-
prevCard = id;
|
|
37
|
-
}, tooltip_constants.TOOLTIP_DELAY_MS);
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
function leave() {
|
|
41
|
-
if (timerEnter) {
|
|
42
|
-
clearTimeout(timerEnter);
|
|
43
|
-
timerEnter = null;
|
|
44
|
-
}
|
|
45
|
-
start = Date.now();
|
|
46
|
-
timerLeave = setTimeout(() => {
|
|
47
|
-
current.value = null;
|
|
48
|
-
prevCard = null;
|
|
49
|
-
}, tooltip_constants.TOOLTIP_DELAY_MS);
|
|
50
|
-
}
|
|
51
|
-
let instance = null;
|
|
52
|
-
return () => {
|
|
53
|
-
if (instance === null) {
|
|
54
|
-
instance = { current, enter, leave };
|
|
55
|
-
}
|
|
56
|
-
return instance;
|
|
57
|
-
};
|
|
58
|
-
}();
|
|
59
|
-
exports.default = useTimer;
|
|
60
|
-
//# sourceMappingURL=timer.cjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"timer.cjs","sources":["../../../components/hovercard/timer.js"],"sourcesContent":["import { ref } from 'vue';\nimport { TOOLTIP_DELAY_MS } from '@/components/tooltip/index.js';\n\nexport default (function () {\n const current = ref(null);\n let timerLeave, timerEnter;\n let start = null;\n let prevCard = null;\n\n // Handles the timer for when the event that opens the hovercard\n // is triggered.\n // If no hovercard is active, it sets a delay of TOOLTIP_DELAY_MS.\n // If there was an active hovercard, the delay depends on the time it takes\n // to move from one anchor to the other.\n function enter (id) {\n if (prevCard) {\n const time = Date.now() - start + 100;\n if (timerLeave) clearTimeout(timerLeave);\n if (prevCard !== id) {\n timerLeave = setTimeout(\n () => {\n if (current.value !== null) {\n start = Date.now();\n }\n current.value = null;\n },\n time,\n );\n if (timerEnter) clearTimeout(timerEnter);\n timerEnter = setTimeout(\n () => {\n current.value = id;\n prevCard = id;\n },\n time,\n );\n }\n } else {\n timerEnter = setTimeout(() => {\n current.value = id;\n prevCard = id;\n }, TOOLTIP_DELAY_MS);\n }\n }\n\n // Handles the timer for when the event that closes the hovercard\n // is triggered.\n function leave () {\n if (timerEnter) {\n clearTimeout(timerEnter);\n timerEnter = null;\n }\n start = Date.now();\n timerLeave = setTimeout(() => {\n current.value = null;\n prevCard = null;\n }, TOOLTIP_DELAY_MS);\n }\n\n let instance = null;\n\n return () => {\n if (instance === null) {\n instance = { current, enter, leave };\n }\n return instance;\n };\n})();\n"],"names":["ref","TOOLTIP_DELAY_MS"],"mappings":";;;;AAGA,MAAA,WAAgB,WAAY;AAC1B,QAAM,UAAUA,QAAI,IAAI;AACxB,MAAI,YAAY;AAChB,MAAI,QAAQ;AACZ,MAAI,WAAW;AAOf,WAAS,MAAO,IAAI;AAClB,QAAI,UAAU;AACZ,YAAM,OAAO,KAAK,IAAG,IAAK,QAAQ;AAClC,UAAI,WAAY,cAAa,UAAU;AACvC,UAAI,aAAa,IAAI;AACnB,qBAAa;AAAA,UACX,MAAM;AACJ,gBAAI,QAAQ,UAAU,MAAM;AAC1B,sBAAQ,KAAK;YACd;AACD,oBAAQ,QAAQ;AAAA,UACjB;AAAA,UACD;AAAA,QACV;AACQ,YAAI,WAAY,cAAa,UAAU;AACvC,qBAAa;AAAA,UACX,MAAM;AACJ,oBAAQ,QAAQ;AAChB,uBAAW;AAAA,UACZ;AAAA,UACD;AAAA,QACV;AAAA,MACO;AAAA,IACP,OAAW;AACL,mBAAa,WAAW,MAAM;AAC5B,gBAAQ,QAAQ;AAChB,mBAAW;AAAA,MACZ,GAAEC,kBAAgB,gBAAA;AAAA,IACpB;AAAA,EACF;AAID,WAAS,QAAS;AAChB,QAAI,YAAY;AACd,mBAAa,UAAU;AACvB,mBAAa;AAAA,IACd;AACD,YAAQ,KAAK;AACb,iBAAa,WAAW,MAAM;AAC5B,cAAQ,QAAQ;AAChB,iBAAW;AAAA,IACZ,GAAEA,kBAAgB,gBAAA;AAAA,EACpB;AAED,MAAI,WAAW;AAEf,SAAO,MAAM;AACX,QAAI,aAAa,MAAM;AACrB,iBAAW,EAAE,SAAS,OAAO,MAAK;AAAA,IACnC;AACD,WAAO;AAAA,EACX;AACA,EAAI;;"}
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
import { ref } from "vue";
|
|
2
|
-
import { TOOLTIP_DELAY_MS } from "../tooltip/tooltip_constants.js";
|
|
3
|
-
const useTimer = function() {
|
|
4
|
-
const current = ref(null);
|
|
5
|
-
let timerLeave, timerEnter;
|
|
6
|
-
let start = null;
|
|
7
|
-
let prevCard = null;
|
|
8
|
-
function enter(id) {
|
|
9
|
-
if (prevCard) {
|
|
10
|
-
const time = Date.now() - start + 100;
|
|
11
|
-
if (timerLeave) clearTimeout(timerLeave);
|
|
12
|
-
if (prevCard !== id) {
|
|
13
|
-
timerLeave = setTimeout(
|
|
14
|
-
() => {
|
|
15
|
-
if (current.value !== null) {
|
|
16
|
-
start = Date.now();
|
|
17
|
-
}
|
|
18
|
-
current.value = null;
|
|
19
|
-
},
|
|
20
|
-
time
|
|
21
|
-
);
|
|
22
|
-
if (timerEnter) clearTimeout(timerEnter);
|
|
23
|
-
timerEnter = setTimeout(
|
|
24
|
-
() => {
|
|
25
|
-
current.value = id;
|
|
26
|
-
prevCard = id;
|
|
27
|
-
},
|
|
28
|
-
time
|
|
29
|
-
);
|
|
30
|
-
}
|
|
31
|
-
} else {
|
|
32
|
-
timerEnter = setTimeout(() => {
|
|
33
|
-
current.value = id;
|
|
34
|
-
prevCard = id;
|
|
35
|
-
}, TOOLTIP_DELAY_MS);
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
function leave() {
|
|
39
|
-
if (timerEnter) {
|
|
40
|
-
clearTimeout(timerEnter);
|
|
41
|
-
timerEnter = null;
|
|
42
|
-
}
|
|
43
|
-
start = Date.now();
|
|
44
|
-
timerLeave = setTimeout(() => {
|
|
45
|
-
current.value = null;
|
|
46
|
-
prevCard = null;
|
|
47
|
-
}, TOOLTIP_DELAY_MS);
|
|
48
|
-
}
|
|
49
|
-
let instance = null;
|
|
50
|
-
return () => {
|
|
51
|
-
if (instance === null) {
|
|
52
|
-
instance = { current, enter, leave };
|
|
53
|
-
}
|
|
54
|
-
return instance;
|
|
55
|
-
};
|
|
56
|
-
}();
|
|
57
|
-
export {
|
|
58
|
-
useTimer as default
|
|
59
|
-
};
|
|
60
|
-
//# sourceMappingURL=timer.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"timer.js","sources":["../../../components/hovercard/timer.js"],"sourcesContent":["import { ref } from 'vue';\nimport { TOOLTIP_DELAY_MS } from '@/components/tooltip/index.js';\n\nexport default (function () {\n const current = ref(null);\n let timerLeave, timerEnter;\n let start = null;\n let prevCard = null;\n\n // Handles the timer for when the event that opens the hovercard\n // is triggered.\n // If no hovercard is active, it sets a delay of TOOLTIP_DELAY_MS.\n // If there was an active hovercard, the delay depends on the time it takes\n // to move from one anchor to the other.\n function enter (id) {\n if (prevCard) {\n const time = Date.now() - start + 100;\n if (timerLeave) clearTimeout(timerLeave);\n if (prevCard !== id) {\n timerLeave = setTimeout(\n () => {\n if (current.value !== null) {\n start = Date.now();\n }\n current.value = null;\n },\n time,\n );\n if (timerEnter) clearTimeout(timerEnter);\n timerEnter = setTimeout(\n () => {\n current.value = id;\n prevCard = id;\n },\n time,\n );\n }\n } else {\n timerEnter = setTimeout(() => {\n current.value = id;\n prevCard = id;\n }, TOOLTIP_DELAY_MS);\n }\n }\n\n // Handles the timer for when the event that closes the hovercard\n // is triggered.\n function leave () {\n if (timerEnter) {\n clearTimeout(timerEnter);\n timerEnter = null;\n }\n start = Date.now();\n timerLeave = setTimeout(() => {\n current.value = null;\n prevCard = null;\n }, TOOLTIP_DELAY_MS);\n }\n\n let instance = null;\n\n return () => {\n if (instance === null) {\n instance = { current, enter, leave };\n }\n return instance;\n };\n})();\n"],"names":[],"mappings":";;AAGA,MAAA,WAAgB,WAAY;AAC1B,QAAM,UAAU,IAAI,IAAI;AACxB,MAAI,YAAY;AAChB,MAAI,QAAQ;AACZ,MAAI,WAAW;AAOf,WAAS,MAAO,IAAI;AAClB,QAAI,UAAU;AACZ,YAAM,OAAO,KAAK,IAAG,IAAK,QAAQ;AAClC,UAAI,WAAY,cAAa,UAAU;AACvC,UAAI,aAAa,IAAI;AACnB,qBAAa;AAAA,UACX,MAAM;AACJ,gBAAI,QAAQ,UAAU,MAAM;AAC1B,sBAAQ,KAAK;YACd;AACD,oBAAQ,QAAQ;AAAA,UACjB;AAAA,UACD;AAAA,QACV;AACQ,YAAI,WAAY,cAAa,UAAU;AACvC,qBAAa;AAAA,UACX,MAAM;AACJ,oBAAQ,QAAQ;AAChB,uBAAW;AAAA,UACZ;AAAA,UACD;AAAA,QACV;AAAA,MACO;AAAA,IACP,OAAW;AACL,mBAAa,WAAW,MAAM;AAC5B,gBAAQ,QAAQ;AAChB,mBAAW;AAAA,MACZ,GAAE,gBAAgB;AAAA,IACpB;AAAA,EACF;AAID,WAAS,QAAS;AAChB,QAAI,YAAY;AACd,mBAAa,UAAU;AACvB,mBAAa;AAAA,IACd;AACD,YAAQ,KAAK;AACb,iBAAa,WAAW,MAAM;AAC5B,cAAQ,QAAQ;AAChB,iBAAW;AAAA,IACZ,GAAE,gBAAgB;AAAA,EACpB;AAED,MAAI,WAAW;AAEf,SAAO,MAAM;AACX,QAAI,aAAa,MAAM;AACrB,iBAAW,EAAE,SAAS,OAAO,MAAK;AAAA,IACnC;AACD,WAAO;AAAA,EACX;AACA,EAAI;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"timer.d.ts","sourceRoot":"","sources":["../../../../components/hovercard/timer.js"],"names":[],"mappings":"AA6DS,iCAKN"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"attachment_carousel_constants.d.ts","sourceRoot":"","sources":["../../../../../recipes/conversation_view/attachment_carousel/attachment_carousel_constants.js"],"names":[],"mappings":"AAAA,qCAAsC"}
|