@mobilon-dev/chotto 0.3.83 → 0.3.85
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/chotto.css +1 -1
- package/dist/components/1_atoms/ButtonContextMenu/ButtonContextMenu.vue2.js +3 -2
- package/dist/components/1_atoms/ContactContextMenu/ContactContextMenu.vue2.js +3 -2
- package/dist/components/1_atoms/EmojiGlyph/EmojiGlyph.vue.js +38 -0
- package/dist/components/1_atoms/EmojiGlyph/EmojiGlyph.vue2.js +4 -0
- package/dist/components/1_atoms/Tooltip/Tooltip.vue.js +1 -1
- package/dist/components/1_atoms/Tooltip/Tooltip.vue2.js +49 -36
- package/dist/components/1_icons/CloseIcon.vue.js +21 -0
- package/dist/components/2_blocks/CommunicationPanel/CommunicationPanel.vue.js +351 -282
- package/dist/components/2_blocks/CommunicationPanel/CommunicationPanelAttributeIndicator.vue.js +38 -33
- package/dist/components/2_blocks/CommunicationPanel/composables/useCommunicationActions.js +64 -39
- package/dist/components/2_blocks/CommunicationPanel/composables/useCommunicationAttributes.js +116 -61
- package/dist/components/2_blocks/CommunicationPanel/composables/useCommunicationChannels.js +1 -1
- package/dist/components/2_blocks/CommunicationPanel/composables/useCommunicationMenu.js +30 -16
- package/dist/components/2_blocks/CommunicationPanel/composables/useCommunicationRecentSelection.js +47 -0
- package/dist/components/2_blocks/CommunicationPanel/icons/{CommunicationPanelConfirmSpinner.vue2.js → CommunicationPanelConfirmSpinner.vue.js} +1 -1
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelUnconfirmedIcon.vue.js +19 -0
- package/dist/components/2_blocks/FeedSearch/FeedSearch.vue2.js +10 -9
- package/dist/components/2_chatinput_elements/ButtonCommandsSelector/ButtonCommandsSelector.vue2.js +8 -7
- package/dist/components/2_chatinput_elements/ButtonEmojiPicker/ButtonEmojiPicker.vue.js +2 -2
- package/dist/components/2_chatinput_elements/ButtonEmojiPicker/ButtonEmojiPicker.vue2.js +48 -37
- package/dist/components/2_chatinput_elements/ButtonTemplateSelector/ButtonTemplateSelector.vue2.js +3 -2
- package/dist/components/2_chatinput_elements/ButtonWabaTemplateSelector/ButtonWabaTemplateSelector.vue.js +7 -6
- package/dist/components/2_chatinput_elements/FilePreview/FilePreview.vue2.js +3 -2
- package/dist/components/2_chatinput_elements/FileUploader/FileUploader.vue2.js +3 -2
- package/dist/components/2_chatinput_elements/StickerPicker/StickerPicker.vue2.js +3 -2
- package/dist/components/2_chatinput_elements/TemplateSelector/TemplateSelector.vue.js +27 -26
- package/dist/components/2_chatinput_elements/TextFormatToolbar/TextFormatToolbar.vue2.js +3 -2
- package/dist/components/2_chatinput_elements/WABAAttachmentSection/WABAAttachmentSection.vue2.js +3 -2
- package/dist/components/2_chatlist_elements/ChatItem/ChatItem.vue2.js +3 -2
- package/dist/components/2_elements/AudioRecorder/AudioRecorder.vue2.js +3 -2
- package/dist/components/2_elements/ChannelSelector/ChannelSelector.vue.js +6 -5
- package/dist/components/2_elements/ThemeMode/ThemeMode.vue.js +10 -9
- package/dist/components/2_elements/VideoRecorder/VideoRecorder.vue2.js +3 -2
- package/dist/components/2_feed_elements/AudioMessage/AudioMessage.vue.js +1 -1
- package/dist/components/2_feed_elements/AudioMessage/AudioMessage.vue2.js +169 -143
- package/dist/components/2_feed_elements/BaseReplyMessage/BaseReplyMessage.vue.js +4 -4
- package/dist/components/2_feed_elements/BaseReplyMessage/BaseReplyMessage.vue2.js +33 -32
- package/dist/components/2_feed_elements/CallMessage/CallMessage.vue2.js +8 -2
- package/dist/components/2_feed_elements/FileMessage/FileMessage.vue.js +3 -3
- package/dist/components/2_feed_elements/FileMessage/FileMessage.vue2.js +134 -108
- package/dist/components/2_feed_elements/ImageMessage/ImageMessage.vue.js +1 -1
- package/dist/components/2_feed_elements/ImageMessage/ImageMessage.vue2.js +116 -97
- package/dist/components/2_feed_elements/MessageKeyboard/MessageKeyboard.vue2.js +3 -2
- package/dist/components/2_feed_elements/MessageReactions/MessageReactions.vue.js +2 -2
- package/dist/components/2_feed_elements/MessageReactions/MessageReactions.vue2.js +232 -113
- package/dist/components/2_feed_elements/MessageReactions/composables/usePositioning.js +77 -62
- package/dist/components/2_feed_elements/MessageReactions/composables/useReactions.js +62 -20
- package/dist/components/2_feed_elements/MessageReactions/composables/useReactionsPanel.js +91 -69
- package/dist/components/2_feed_elements/MessageReactions/composables/useReactionsState.js +46 -22
- package/dist/components/2_feed_elements/MessageReactions/icons/ExpandReactionsIcon.vue.js +21 -0
- package/dist/components/2_feed_elements/MessageReactions/icons/ReplyIcon.vue.js +21 -0
- package/dist/components/2_feed_elements/MessageReactions/utils/quickReactions.js +2 -8
- package/dist/components/2_feed_elements/MessageReactions/utils/reactionTooltip.js +39 -0
- package/dist/components/2_feed_elements/MissedCallMessage/MissedCallMessage.vue2.js +26 -20
- package/dist/components/2_feed_elements/ReplyAudioMessage/ReplyAudioMessage.vue.js +2 -2
- package/dist/components/2_feed_elements/ReplyAudioMessage/ReplyAudioMessage.vue2.js +27 -18
- package/dist/components/2_feed_elements/ReplyCallMessage/ReplyCallMessage.vue.js +2 -2
- package/dist/components/2_feed_elements/ReplyCallMessage/ReplyCallMessage.vue2.js +16 -15
- package/dist/components/2_feed_elements/ReplyFileMessage/ReplyFileMessage.vue.js +3 -3
- package/dist/components/2_feed_elements/ReplyFileMessage/ReplyFileMessage.vue2.js +27 -18
- package/dist/components/2_feed_elements/ReplyImageMessage/ReplyImageMessage.vue.js +1 -1
- package/dist/components/2_feed_elements/ReplyImageMessage/ReplyImageMessage.vue2.js +16 -12
- package/dist/components/2_feed_elements/ReplyStickerMessage/ReplyStickerMessage.vue.js +4 -4
- package/dist/components/2_feed_elements/ReplyStickerMessage/ReplyStickerMessage.vue2.js +74 -65
- package/dist/components/2_feed_elements/ReplyTextMessage/ReplyTextMessage.vue.js +1 -1
- package/dist/components/2_feed_elements/ReplyTextMessage/ReplyTextMessage.vue2.js +20 -11
- package/dist/components/2_feed_elements/ReplyVideoMessage/ReplyVideoMessage.vue.js +2 -2
- package/dist/components/2_feed_elements/ReplyVideoMessage/ReplyVideoMessage.vue2.js +13 -9
- package/dist/components/2_feed_elements/StickerMessage/StickerMessage.vue.js +4 -4
- package/dist/components/2_feed_elements/StickerMessage/StickerMessage.vue2.js +74 -55
- package/dist/components/2_feed_elements/TextMessage/TextMessage.vue.js +4 -4
- package/dist/components/2_feed_elements/TextMessage/TextMessage.vue2.js +102 -76
- package/dist/components/2_feed_elements/VideoMessage/VideoMessage.vue.js +2 -2
- package/dist/components/2_feed_elements/VideoMessage/VideoMessage.vue2.js +74 -55
- package/dist/components/3_compounds/ChatInput/ChatInput.vue.js +2 -2
- package/dist/components/3_compounds/ChatInput/ChatInput.vue2.js +99 -82
- package/dist/components/3_compounds/Feed/Feed.vue.js +3 -3
- package/dist/components/3_compounds/Feed/Feed.vue2.js +159 -139
- package/dist/components/3_compounds/Feed/composables/useFeedReply.js +22 -25
- package/dist/functions/renderAppleEmojis.js +92 -0
- package/dist/hooks/messages/buildReplyPayload.js +14 -0
- package/dist/hooks/messages/useMessageLinks.js +60 -50
- package/dist/hooks/messages/useStartReply.js +29 -0
- package/dist/hooks/useEmojiNative.js +19 -0
- package/dist/index.js +130 -122
- package/dist/themes/dark.css +1 -1
- package/dist/themes/default.css +1 -1
- package/dist/themes/glass.css +1 -1
- package/dist/themes/green.css +1 -1
- package/dist/themes/mobilon1.css +1 -1
- package/dist/types/apps/data/messages.d.ts +20 -18
- package/dist/types/components/1_atoms/EmojiGlyph/EmojiGlyph.vue.d.ts +12 -0
- package/dist/types/components/1_atoms/Tooltip/stories/Tooltip.stories.d.ts +3 -0
- package/dist/types/components/1_icons/CloseIcon.vue.d.ts +2 -0
- package/dist/types/components/2_blocks/CommunicationPanel/CommunicationPanel.vue.d.ts +2 -0
- package/dist/types/components/2_blocks/CommunicationPanel/CommunicationPanelAttributeIndicator.vue.d.ts +2 -2
- package/dist/types/components/2_blocks/CommunicationPanel/composables/useCommunicationActions.d.ts +10 -1
- package/dist/types/components/2_blocks/CommunicationPanel/composables/useCommunicationAttributes.d.ts +23 -2
- package/dist/types/components/2_blocks/CommunicationPanel/composables/useCommunicationMenu.d.ts +1 -0
- package/dist/types/components/2_blocks/CommunicationPanel/composables/useCommunicationRecentSelection.d.ts +20 -0
- package/dist/types/components/2_blocks/CommunicationPanel/icons/CommunicationPanelUnconfirmedIcon.vue.d.ts +2 -0
- package/dist/types/components/2_blocks/CommunicationPanel/icons/index.d.ts +1 -0
- package/dist/types/components/2_blocks/CommunicationPanel/stories/CommunicationPanel.stories.d.ts +2 -0
- package/dist/types/components/2_blocks/CommunicationPanel/styles/types.d.ts +42 -10
- package/dist/types/components/2_chatinput_elements/ButtonEmojiPicker/ButtonEmojiPicker.vue.d.ts +9 -1
- package/dist/types/components/2_feed_elements/AudioMessage/AudioMessage.vue.d.ts +29 -0
- package/dist/types/components/2_feed_elements/AudioMessage/styles/types.d.ts +24 -16
- package/dist/types/components/2_feed_elements/BaseReplyMessage/styles/types.d.ts +8 -4
- package/dist/types/components/2_feed_elements/FileMessage/FileMessage.vue.d.ts +29 -0
- package/dist/types/components/2_feed_elements/FileMessage/styles/types.d.ts +20 -0
- package/dist/types/components/2_feed_elements/ImageMessage/ImageMessage.vue.d.ts +29 -0
- package/dist/types/components/2_feed_elements/ImageMessage/styles/types.d.ts +2 -0
- package/dist/types/components/2_feed_elements/MessageReactions/MessageReactions.vue.d.ts +64 -1
- package/dist/types/components/2_feed_elements/MessageReactions/composables/index.d.ts +2 -2
- package/dist/types/components/2_feed_elements/MessageReactions/composables/usePositioning.d.ts +11 -1
- package/dist/types/components/2_feed_elements/MessageReactions/composables/useReactions.d.ts +20 -12
- package/dist/types/components/2_feed_elements/MessageReactions/composables/useReactionsPanel.d.ts +3 -3
- package/dist/types/components/2_feed_elements/MessageReactions/composables/useReactionsState.d.ts +13 -22
- package/dist/types/components/2_feed_elements/MessageReactions/icons/ExpandReactionsIcon.vue.d.ts +2 -0
- package/dist/types/components/2_feed_elements/MessageReactions/icons/ReplyIcon.vue.d.ts +2 -0
- package/dist/types/components/2_feed_elements/MessageReactions/styles/types.d.ts +14 -74
- package/dist/types/components/2_feed_elements/MessageReactions/utils/quickReactions.d.ts +1 -1
- package/dist/types/components/2_feed_elements/MessageReactions/utils/reactionTooltip.d.ts +14 -0
- package/dist/types/components/2_feed_elements/ReplyAudioMessage/styles/types.d.ts +6 -0
- package/dist/types/components/2_feed_elements/ReplyCallMessage/styles/types.d.ts +6 -0
- package/dist/types/components/2_feed_elements/ReplyFileMessage/styles/types.d.ts +6 -0
- package/dist/types/components/2_feed_elements/ReplyImageMessage/styles/types.d.ts +6 -0
- package/dist/types/components/2_feed_elements/ReplyStickerMessage/styles/types.d.ts +6 -0
- package/dist/types/components/2_feed_elements/ReplyTextMessage/styles/types.d.ts +4 -0
- package/dist/types/components/2_feed_elements/ReplyVideoMessage/styles/types.d.ts +6 -0
- package/dist/types/components/2_feed_elements/StickerMessage/StickerMessage.vue.d.ts +29 -0
- package/dist/types/components/2_feed_elements/TextMessage/TextMessage.vue.d.ts +29 -0
- package/dist/types/components/2_feed_elements/TextMessage/styles/types.d.ts +22 -0
- package/dist/types/components/2_feed_elements/VideoMessage/VideoMessage.vue.d.ts +29 -0
- package/dist/types/components/2_feed_elements/types/messages.d.ts +11 -6
- package/dist/types/components/3_compounds/ChatInput/styles/types.d.ts +2 -0
- package/dist/types/components/3_compounds/Feed/Feed.vue.d.ts +33 -0
- package/dist/types/functions/renderAppleEmojis.d.ts +16 -0
- package/dist/types/hooks/index.d.ts +1 -0
- package/dist/types/hooks/messages/buildReplyPayload.d.ts +11 -0
- package/dist/types/hooks/messages/index.d.ts +2 -0
- package/dist/types/hooks/messages/useStartReply.d.ts +6 -0
- package/dist/types/hooks/useEmojiNative.d.ts +9 -0
- package/package.json +1 -1
|
@@ -16,6 +16,19 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
16
16
|
type: BooleanConstructor;
|
|
17
17
|
default: boolean;
|
|
18
18
|
};
|
|
19
|
+
reactionsMode: {
|
|
20
|
+
type: () => "single" | "multi";
|
|
21
|
+
default: string;
|
|
22
|
+
validator: (value: string) => boolean;
|
|
23
|
+
};
|
|
24
|
+
currentUserId: {
|
|
25
|
+
type: () => string | number | undefined;
|
|
26
|
+
default: undefined;
|
|
27
|
+
};
|
|
28
|
+
reactionUserNames: {
|
|
29
|
+
type: () => Record<string, string>;
|
|
30
|
+
default: undefined;
|
|
31
|
+
};
|
|
19
32
|
subtextTooltipData: {
|
|
20
33
|
type: () => Record<string, string>;
|
|
21
34
|
required: false;
|
|
@@ -47,6 +60,19 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
47
60
|
type: BooleanConstructor;
|
|
48
61
|
default: boolean;
|
|
49
62
|
};
|
|
63
|
+
reactionsMode: {
|
|
64
|
+
type: () => "single" | "multi";
|
|
65
|
+
default: string;
|
|
66
|
+
validator: (value: string) => boolean;
|
|
67
|
+
};
|
|
68
|
+
currentUserId: {
|
|
69
|
+
type: () => string | number | undefined;
|
|
70
|
+
default: undefined;
|
|
71
|
+
};
|
|
72
|
+
reactionUserNames: {
|
|
73
|
+
type: () => Record<string, string>;
|
|
74
|
+
default: undefined;
|
|
75
|
+
};
|
|
50
76
|
subtextTooltipData: {
|
|
51
77
|
type: () => Record<string, string>;
|
|
52
78
|
required: false;
|
|
@@ -63,9 +89,12 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
63
89
|
"onSms-invite"?: ((...args: any[]) => any) | undefined;
|
|
64
90
|
}>, {
|
|
65
91
|
channel: string;
|
|
92
|
+
currentUserId: string | number | undefined;
|
|
93
|
+
reactionUserNames: Record<string, string>;
|
|
66
94
|
applyStyle: Function;
|
|
67
95
|
isFirstInSeries: boolean;
|
|
68
96
|
reactionsEnabled: boolean;
|
|
97
|
+
reactionsMode: "single" | "multi";
|
|
69
98
|
subtextTooltipData: Record<string, string>;
|
|
70
99
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
71
100
|
export default _default;
|
|
@@ -114,6 +114,22 @@ export interface FileMessageThemeCSSVariables {
|
|
|
114
114
|
'--chotto-filemessage-filename-text-font-size': string;
|
|
115
115
|
/** Цвет имени файла */
|
|
116
116
|
'--chotto-filemessage-filename-text-color': string;
|
|
117
|
+
/** Отображение футера (реакции + время) */
|
|
118
|
+
'--chotto-filemessage-footer-display': string;
|
|
119
|
+
/** Выравнивание элементов футера по поперечной оси */
|
|
120
|
+
'--chotto-filemessage-footer-align-items': string;
|
|
121
|
+
/** Выравнивание элементов футера по главной оси */
|
|
122
|
+
'--chotto-filemessage-footer-justify-content': string;
|
|
123
|
+
/** Промежуток между элементами футера */
|
|
124
|
+
'--chotto-filemessage-footer-column-gap': string;
|
|
125
|
+
/** Отступ сверху футера */
|
|
126
|
+
'--chotto-filemessage-footer-margin-top': string;
|
|
127
|
+
/** Растягивание блока реакций в футере */
|
|
128
|
+
'--chotto-filemessage-reactions-flex': string;
|
|
129
|
+
/** Перенос реакций */
|
|
130
|
+
'--chotto-filemessage-reactions-flex-wrap': string;
|
|
131
|
+
/** Минимальная ширина блока реакций */
|
|
132
|
+
'--chotto-filemessage-reactions-min-width': string;
|
|
117
133
|
/** Отображение контейнера информации */
|
|
118
134
|
'--chotto-filemessage-info-container-display': string;
|
|
119
135
|
/** Выравнивание элементов контейнера информации */
|
|
@@ -122,6 +138,10 @@ export interface FileMessageThemeCSSVariables {
|
|
|
122
138
|
'--chotto-filemessage-info-container-justify-content': string;
|
|
123
139
|
/** Промежуток между элементами контейнера информации */
|
|
124
140
|
'--chotto-filemessage-info-container-column-gap': string;
|
|
141
|
+
/** Сжатие контейнера информации */
|
|
142
|
+
'--chotto-filemessage-info-container-flex-shrink': string;
|
|
143
|
+
/** Отступ слева у контейнера информации */
|
|
144
|
+
'--chotto-filemessage-info-container-margin-left': string;
|
|
125
145
|
/** Отступ снизу кнопки скачивания */
|
|
126
146
|
'--chotto-filemessage-download-button-margin-bottom': string;
|
|
127
147
|
/** Отступ слева кнопки скачивания */
|
|
@@ -16,6 +16,19 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
16
16
|
type: BooleanConstructor;
|
|
17
17
|
default: boolean;
|
|
18
18
|
};
|
|
19
|
+
reactionsMode: {
|
|
20
|
+
type: () => "single" | "multi";
|
|
21
|
+
default: string;
|
|
22
|
+
validator: (value: string) => boolean;
|
|
23
|
+
};
|
|
24
|
+
currentUserId: {
|
|
25
|
+
type: () => string | number | undefined;
|
|
26
|
+
default: undefined;
|
|
27
|
+
};
|
|
28
|
+
reactionUserNames: {
|
|
29
|
+
type: () => Record<string, string>;
|
|
30
|
+
default: undefined;
|
|
31
|
+
};
|
|
19
32
|
subtextTooltipData: {
|
|
20
33
|
type: () => Record<string, string>;
|
|
21
34
|
required: false;
|
|
@@ -47,6 +60,19 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
47
60
|
type: BooleanConstructor;
|
|
48
61
|
default: boolean;
|
|
49
62
|
};
|
|
63
|
+
reactionsMode: {
|
|
64
|
+
type: () => "single" | "multi";
|
|
65
|
+
default: string;
|
|
66
|
+
validator: (value: string) => boolean;
|
|
67
|
+
};
|
|
68
|
+
currentUserId: {
|
|
69
|
+
type: () => string | number | undefined;
|
|
70
|
+
default: undefined;
|
|
71
|
+
};
|
|
72
|
+
reactionUserNames: {
|
|
73
|
+
type: () => Record<string, string>;
|
|
74
|
+
default: undefined;
|
|
75
|
+
};
|
|
50
76
|
subtextTooltipData: {
|
|
51
77
|
type: () => Record<string, string>;
|
|
52
78
|
required: false;
|
|
@@ -63,9 +89,12 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
63
89
|
"onSms-invite"?: ((...args: any[]) => any) | undefined;
|
|
64
90
|
}>, {
|
|
65
91
|
channel: string;
|
|
92
|
+
currentUserId: string | number | undefined;
|
|
93
|
+
reactionUserNames: Record<string, string>;
|
|
66
94
|
applyStyle: Function;
|
|
67
95
|
isFirstInSeries: boolean;
|
|
68
96
|
reactionsEnabled: boolean;
|
|
97
|
+
reactionsMode: "single" | "multi";
|
|
69
98
|
subtextTooltipData: Record<string, string>;
|
|
70
99
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
71
100
|
export default _default;
|
|
@@ -358,6 +358,8 @@ export interface ImageMessageThemeCSSVariables {
|
|
|
358
358
|
'--chotto-imagemessage-right-context-menu-right': string;
|
|
359
359
|
/** Отступ контекстного меню справа сверху */
|
|
360
360
|
'--chotto-imagemessage-right-context-menu-margin-top': string;
|
|
361
|
+
/** Внешние отступы реакций */
|
|
362
|
+
'--chotto-imagemessage-reactions-margin': string;
|
|
361
363
|
/** Ширина изображения в модальном окне */
|
|
362
364
|
'--chotto-imagemessage-modal-image-width': string;
|
|
363
365
|
/** Высота изображения в модальном окне */
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import 'vue3-emoji-picker-ru/css';
|
|
2
|
-
import type { MessageReactions } from '@/types';
|
|
2
|
+
import type { MessageReactions, Reply } from '@/types';
|
|
3
|
+
import { type ReactionsMode } from './composables';
|
|
3
4
|
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
4
5
|
reactions: {
|
|
5
6
|
type: () => MessageReactions | undefined;
|
|
@@ -18,6 +19,34 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
18
19
|
type: BooleanConstructor;
|
|
19
20
|
default: boolean;
|
|
20
21
|
};
|
|
22
|
+
mode: {
|
|
23
|
+
type: () => ReactionsMode;
|
|
24
|
+
default: string;
|
|
25
|
+
validator: (value: string) => boolean;
|
|
26
|
+
};
|
|
27
|
+
/** Id текущего пользователя — для расчёта reactedByMe и локальных add/remove */
|
|
28
|
+
currentUserId: {
|
|
29
|
+
type: () => string | number | undefined;
|
|
30
|
+
default: undefined;
|
|
31
|
+
};
|
|
32
|
+
/** Имя текущего пользователя — для тултипа при локальном добавлении реакции */
|
|
33
|
+
currentUserName: {
|
|
34
|
+
type: StringConstructor;
|
|
35
|
+
default: undefined;
|
|
36
|
+
};
|
|
37
|
+
/** userId → имя (если в item нет name) */
|
|
38
|
+
reactionUserNames: {
|
|
39
|
+
type: () => Record<string, string>;
|
|
40
|
+
default: undefined;
|
|
41
|
+
};
|
|
42
|
+
reply: {
|
|
43
|
+
type: () => Reply | undefined;
|
|
44
|
+
default: undefined;
|
|
45
|
+
};
|
|
46
|
+
replyEnabled: {
|
|
47
|
+
type: BooleanConstructor;
|
|
48
|
+
default: boolean;
|
|
49
|
+
};
|
|
21
50
|
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
|
|
22
51
|
"toggle-reaction": (payload: {
|
|
23
52
|
messageId: string | number;
|
|
@@ -49,6 +78,34 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
49
78
|
type: BooleanConstructor;
|
|
50
79
|
default: boolean;
|
|
51
80
|
};
|
|
81
|
+
mode: {
|
|
82
|
+
type: () => ReactionsMode;
|
|
83
|
+
default: string;
|
|
84
|
+
validator: (value: string) => boolean;
|
|
85
|
+
};
|
|
86
|
+
/** Id текущего пользователя — для расчёта reactedByMe и локальных add/remove */
|
|
87
|
+
currentUserId: {
|
|
88
|
+
type: () => string | number | undefined;
|
|
89
|
+
default: undefined;
|
|
90
|
+
};
|
|
91
|
+
/** Имя текущего пользователя — для тултипа при локальном добавлении реакции */
|
|
92
|
+
currentUserName: {
|
|
93
|
+
type: StringConstructor;
|
|
94
|
+
default: undefined;
|
|
95
|
+
};
|
|
96
|
+
/** userId → имя (если в item нет name) */
|
|
97
|
+
reactionUserNames: {
|
|
98
|
+
type: () => Record<string, string>;
|
|
99
|
+
default: undefined;
|
|
100
|
+
};
|
|
101
|
+
reply: {
|
|
102
|
+
type: () => Reply | undefined;
|
|
103
|
+
default: undefined;
|
|
104
|
+
};
|
|
105
|
+
replyEnabled: {
|
|
106
|
+
type: BooleanConstructor;
|
|
107
|
+
default: boolean;
|
|
108
|
+
};
|
|
52
109
|
}>> & Readonly<{
|
|
53
110
|
"onToggle-reaction"?: ((payload: {
|
|
54
111
|
messageId: string | number;
|
|
@@ -63,8 +120,14 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
63
120
|
key: string;
|
|
64
121
|
}) => any) | undefined;
|
|
65
122
|
}>, {
|
|
123
|
+
reply: Reply | undefined;
|
|
124
|
+
mode: ReactionsMode;
|
|
66
125
|
reactions: MessageReactions | undefined;
|
|
67
126
|
readonly: boolean;
|
|
68
127
|
enabled: boolean;
|
|
128
|
+
currentUserId: string | number | undefined;
|
|
129
|
+
currentUserName: string;
|
|
130
|
+
reactionUserNames: Record<string, string>;
|
|
131
|
+
replyEnabled: boolean;
|
|
69
132
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
70
133
|
export default _default;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { findFeedContainer, isRightMessage, calculatePanelPosition, calculateFixedPanelPosition, } from './usePositioning';
|
|
2
|
-
export { updateLocalReactionsAdd, updateLocalReactionsRemove, updateLocalReactionsToggle, } from './useReactions';
|
|
1
|
+
export { findFeedContainer, findMessageContent, isRightMessage, calculatePanelPosition, calculateFixedPanelPosition, calculatePickerPositionAboveQuickPanel, } from './usePositioning';
|
|
2
|
+
export { updateLocalReactionsAdd, updateLocalReactionsRemove, updateLocalReactionsToggle, updateLocalReactionsReplace, aggregateReactions, hasMyReaction, getMyReactionKey, sameUserId, type ReactionsMode, } from './useReactions';
|
|
3
3
|
export { useReactionsState } from './useReactionsState';
|
|
4
4
|
export { useReactionsPanel } from './useReactionsPanel';
|
package/dist/types/components/2_feed_elements/MessageReactions/composables/usePositioning.d.ts
CHANGED
|
@@ -2,15 +2,25 @@
|
|
|
2
2
|
* Находит ближайший feed-контейнер в DOM дереве
|
|
3
3
|
*/
|
|
4
4
|
export declare function findFeedContainer(element: HTMLElement | null): HTMLElement | null;
|
|
5
|
+
/**
|
|
6
|
+
* Находит контейнер содержимого сообщения (например, text-message__content)
|
|
7
|
+
*/
|
|
8
|
+
export declare function findMessageContent(element: HTMLElement | null): HTMLElement | null;
|
|
5
9
|
/**
|
|
6
10
|
* Определяет, является ли сообщение правым (outgoing)
|
|
7
11
|
*/
|
|
8
12
|
export declare function isRightMessage(element: HTMLElement | null): boolean;
|
|
9
13
|
/**
|
|
10
|
-
* Вычисляет позицию панели реакций
|
|
14
|
+
* Вычисляет позицию панели быстрых реакций в координатах viewport (position: fixed):
|
|
15
|
+
* по центру высоты, слева для правых сообщений и справа для левых.
|
|
16
|
+
* Fixed нужен, чтобы панель не обрезалась overflow ленты и могла перекрывать ChatList.
|
|
11
17
|
*/
|
|
12
18
|
export declare function calculatePanelPosition(panelElement: HTMLElement | null, buttonElement: HTMLElement | null, estimatedWidth?: number): Promise<Record<string, string>>;
|
|
13
19
|
/**
|
|
14
20
|
* Вычисляет позицию для fixed-элемента относительно viewport
|
|
15
21
|
*/
|
|
16
22
|
export declare function calculateFixedPanelPosition(panelElement: HTMLElement | null, buttonElement: HTMLElement | null, estimatedWidth?: number): Promise<Record<string, string>>;
|
|
23
|
+
/**
|
|
24
|
+
* Вычисляет позицию EmojiPicker над панелью быстрых реакций
|
|
25
|
+
*/
|
|
26
|
+
export declare function calculatePickerPositionAboveQuickPanel(pickerElement: HTMLElement | null, quickPanelElement: HTMLElement | null, messageElement: HTMLElement | null, estimatedWidth?: number): Promise<Record<string, string>>;
|
package/dist/types/components/2_feed_elements/MessageReactions/composables/useReactions.d.ts
CHANGED
|
@@ -1,19 +1,27 @@
|
|
|
1
|
-
import type { MessageReactions } from '@/types';
|
|
1
|
+
import type { MessageReactionChip, MessageReactions } from '@/types';
|
|
2
|
+
export type ReactionsMode = 'single' | 'multi';
|
|
3
|
+
export type ReactionsRef = {
|
|
4
|
+
value: MessageReactions | undefined;
|
|
5
|
+
};
|
|
6
|
+
export declare function sameUserId(a: string | number | undefined | null, b: string | number | undefined | null): boolean;
|
|
7
|
+
export declare function hasMyReaction(localReactions: ReactionsRef, key: string, currentUserId: string | number | undefined | null): boolean;
|
|
8
|
+
export declare function getMyReactionKey(localReactions: ReactionsRef, currentUserId: string | number | undefined | null): string | undefined;
|
|
9
|
+
/** Группирует event-list в чипы для UI */
|
|
10
|
+
export declare function aggregateReactions(reactions: MessageReactions | undefined, currentUserId: string | number | undefined | null): MessageReactionChip[];
|
|
2
11
|
/**
|
|
3
|
-
* Добавляет
|
|
12
|
+
* Добавляет реакцию текущего пользователя
|
|
4
13
|
*/
|
|
5
|
-
export declare function updateLocalReactionsAdd(localReactions:
|
|
6
|
-
value: MessageReactions | undefined;
|
|
7
|
-
}, key: string): void;
|
|
14
|
+
export declare function updateLocalReactionsAdd(localReactions: ReactionsRef, key: string, currentUserId: string | number, mode?: ReactionsMode, name?: string): void;
|
|
8
15
|
/**
|
|
9
|
-
* Удаляет
|
|
16
|
+
* Удаляет реакцию текущего пользователя по ключу
|
|
10
17
|
*/
|
|
11
|
-
export declare function updateLocalReactionsRemove(localReactions:
|
|
12
|
-
|
|
13
|
-
|
|
18
|
+
export declare function updateLocalReactionsRemove(localReactions: ReactionsRef, key: string, currentUserId: string | number): void;
|
|
19
|
+
/**
|
|
20
|
+
* В single-режиме заменяет свою текущую реакцию на новую.
|
|
21
|
+
* Возвращает ключ снятой реакции (если была).
|
|
22
|
+
*/
|
|
23
|
+
export declare function updateLocalReactionsReplace(localReactions: ReactionsRef, key: string, currentUserId: string | number, name?: string): string | undefined;
|
|
14
24
|
/**
|
|
15
25
|
* Переключает реакцию (добавляет, если нет, или удаляет, если есть)
|
|
16
26
|
*/
|
|
17
|
-
export declare function updateLocalReactionsToggle(localReactions:
|
|
18
|
-
value: MessageReactions | undefined;
|
|
19
|
-
}, key: string): void;
|
|
27
|
+
export declare function updateLocalReactionsToggle(localReactions: ReactionsRef, key: string, currentUserId: string | number, mode?: ReactionsMode, name?: string): void;
|
package/dist/types/components/2_feed_elements/MessageReactions/composables/useReactionsPanel.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { type Ref } from 'vue';
|
|
|
2
2
|
/**
|
|
3
3
|
* Композабл для управления панелями реакций (быстрые реакции и полный picker)
|
|
4
4
|
*/
|
|
5
|
-
export declare function useReactionsPanel(quickEmojis: Ref<readonly string[]>,
|
|
5
|
+
export declare function useReactionsPanel(quickEmojis: Ref<readonly string[]>, messageRef: Ref<HTMLElement | null>): {
|
|
6
6
|
isQuickReactionsOpen: Ref<boolean, boolean>;
|
|
7
7
|
isFullPickerOpen: Ref<boolean, boolean>;
|
|
8
8
|
pickerRef: Ref<HTMLElement | null, HTMLElement | null>;
|
|
@@ -13,11 +13,11 @@ export declare function useReactionsPanel(quickEmojis: Ref<readonly string[]>, a
|
|
|
13
13
|
closeQuickPanel: () => void;
|
|
14
14
|
openFullPicker: () => Promise<void>;
|
|
15
15
|
closeFullPicker: () => void;
|
|
16
|
+
handleMessageMouseEnter: () => void;
|
|
17
|
+
handleMessageMouseLeave: () => void;
|
|
16
18
|
handleQuickPanelMouseEnter: () => void;
|
|
17
19
|
handleQuickPanelMouseLeave: () => void;
|
|
18
20
|
handlePickerMouseEnter: () => void;
|
|
19
21
|
handlePickerMouseLeave: () => void;
|
|
20
|
-
handleButtonMouseEnter: () => void;
|
|
21
|
-
handleButtonMouseLeave: () => void;
|
|
22
22
|
handleClickOutside: (event: MouseEvent) => void;
|
|
23
23
|
};
|
package/dist/types/components/2_feed_elements/MessageReactions/composables/useReactionsState.d.ts
CHANGED
|
@@ -1,23 +1,20 @@
|
|
|
1
1
|
import { type Ref } from 'vue';
|
|
2
2
|
import type { MessageReactions } from '@/types';
|
|
3
|
+
import { type ReactionsMode } from './useReactions';
|
|
3
4
|
/**
|
|
4
|
-
* Композабл для управления локальным состоянием реакций
|
|
5
|
+
* Композабл для управления локальным состоянием реакций (event-list → агрегированные чипы)
|
|
5
6
|
*/
|
|
6
|
-
export declare function useReactionsState(initialReactions: Ref<MessageReactions | undefined>): {
|
|
7
|
+
export declare function useReactionsState(initialReactions: Ref<MessageReactions | undefined>, mode: Ref<ReactionsMode>, currentUserId: Ref<string | number | undefined>, currentUserName?: Ref<string | undefined>): {
|
|
7
8
|
localReactions: Ref<{
|
|
8
9
|
items: {
|
|
9
10
|
key: import("@/types").ReactionKey;
|
|
10
|
-
|
|
11
|
-
|
|
11
|
+
userId: string | number;
|
|
12
|
+
date?: number | undefined;
|
|
13
|
+
name?: string | undefined;
|
|
12
14
|
}[];
|
|
13
15
|
meta?: {
|
|
14
16
|
mode?: "single" | "multi" | undefined;
|
|
15
17
|
} | undefined;
|
|
16
|
-
recent?: {
|
|
17
|
-
userId: string | number;
|
|
18
|
-
key: import("@/types").ReactionKey;
|
|
19
|
-
date?: number | undefined;
|
|
20
|
-
}[] | undefined;
|
|
21
18
|
vendor?: {
|
|
22
19
|
telegram?: {
|
|
23
20
|
total_count?: number | undefined;
|
|
@@ -48,17 +45,13 @@ export declare function useReactionsState(initialReactions: Ref<MessageReactions
|
|
|
48
45
|
} | undefined, MessageReactions | {
|
|
49
46
|
items: {
|
|
50
47
|
key: import("@/types").ReactionKey;
|
|
51
|
-
|
|
52
|
-
|
|
48
|
+
userId: string | number;
|
|
49
|
+
date?: number | undefined;
|
|
50
|
+
name?: string | undefined;
|
|
53
51
|
}[];
|
|
54
52
|
meta?: {
|
|
55
53
|
mode?: "single" | "multi" | undefined;
|
|
56
54
|
} | undefined;
|
|
57
|
-
recent?: {
|
|
58
|
-
userId: string | number;
|
|
59
|
-
key: import("@/types").ReactionKey;
|
|
60
|
-
date?: number | undefined;
|
|
61
|
-
}[] | undefined;
|
|
62
55
|
vendor?: {
|
|
63
56
|
telegram?: {
|
|
64
57
|
total_count?: number | undefined;
|
|
@@ -87,13 +80,11 @@ export declare function useReactionsState(initialReactions: Ref<MessageReactions
|
|
|
87
80
|
} | undefined;
|
|
88
81
|
} | undefined;
|
|
89
82
|
} | undefined>;
|
|
90
|
-
displayedReactions: import("vue").ComputedRef<
|
|
91
|
-
key: import("@/types").ReactionKey;
|
|
92
|
-
count: number;
|
|
93
|
-
reactedByMe?: boolean | undefined;
|
|
94
|
-
}[]>;
|
|
83
|
+
displayedReactions: import("vue").ComputedRef<import("@/types").MessageReactionChip[]>;
|
|
95
84
|
hasReactions: import("vue").ComputedRef<boolean>;
|
|
96
|
-
|
|
85
|
+
myReactionKey: import("vue").ComputedRef<string | undefined>;
|
|
86
|
+
addReaction: (key: string) => string | undefined;
|
|
97
87
|
removeReaction: (key: string) => void;
|
|
98
88
|
toggleReaction: (key: string) => void;
|
|
89
|
+
isMyReaction: (key: string) => boolean;
|
|
99
90
|
};
|
package/dist/types/components/2_feed_elements/MessageReactions/icons/ExpandReactionsIcon.vue.d.ts
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
2
|
+
export default _default;
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
2
|
+
export default _default;
|
|
@@ -32,6 +32,8 @@ export interface MessageReactionsThemeCSSVariables {
|
|
|
32
32
|
'--chotto-messagereactions-no-reactions-padding': string;
|
|
33
33
|
/** Z-index контейнера реакций без реакций */
|
|
34
34
|
'--chotto-messagereactions-no-reactions-z-index': string;
|
|
35
|
+
/** События указателя контейнера реакций без реакций */
|
|
36
|
+
'--chotto-messagereactions-no-reactions-pointer-events': string;
|
|
35
37
|
/** Отступ справа для левых сообщений без реакций */
|
|
36
38
|
'--chotto-messagereactions-left-no-reactions-right': string;
|
|
37
39
|
/** Отступ слева для левых сообщений без реакций */
|
|
@@ -60,6 +62,10 @@ export interface MessageReactionsThemeCSSVariables {
|
|
|
60
62
|
'--chotto-messagereactions-chip-font-size': string;
|
|
61
63
|
/** Курсор чипа реакции */
|
|
62
64
|
'--chotto-messagereactions-chip-cursor': string;
|
|
65
|
+
/** Высота изображения эмодзи в чипе реакции */
|
|
66
|
+
'--chotto-messagereactions-chip-img-height': string;
|
|
67
|
+
/** Ширина изображения эмодзи в чипе реакции */
|
|
68
|
+
'--chotto-messagereactions-chip-img-width': string;
|
|
63
69
|
/** Граница активного чипа реакции */
|
|
64
70
|
'--chotto-messagereactions-chip-active-border': string;
|
|
65
71
|
/** Фон активного чипа реакции */
|
|
@@ -68,76 +74,14 @@ export interface MessageReactionsThemeCSSVariables {
|
|
|
68
74
|
'--chotto-messagereactions-chip-active-font-weight': string;
|
|
69
75
|
/** Высота строки эмодзи реакции */
|
|
70
76
|
'--chotto-messagereactions-emoji-line-height': string;
|
|
77
|
+
/** Размер шрифта счётчика реакции */
|
|
78
|
+
'--chotto-messagereactions-count-font-size': string;
|
|
71
79
|
/** Высота строки счётчика реакции */
|
|
72
80
|
'--chotto-messagereactions-count-line-height': string;
|
|
73
|
-
/**
|
|
74
|
-
'--chotto-messagereactions-
|
|
75
|
-
/** Выравнивание элементов кнопки добавления реакции */
|
|
76
|
-
'--chotto-messagereactions-add-align-items': string;
|
|
77
|
-
/** Выравнивание содержимого кнопки добавления реакции */
|
|
78
|
-
'--chotto-messagereactions-add-justify-content': string;
|
|
79
|
-
/** Ширина кнопки добавления реакции */
|
|
80
|
-
'--chotto-messagereactions-add-width': string;
|
|
81
|
-
/** Высота кнопки добавления реакции */
|
|
82
|
-
'--chotto-messagereactions-add-height': string;
|
|
83
|
-
/** Скругление кнопки добавления реакции */
|
|
84
|
-
'--chotto-messagereactions-add-border-radius': string;
|
|
85
|
-
/** Граница кнопки добавления реакции */
|
|
86
|
-
'--chotto-messagereactions-add-border': string;
|
|
87
|
-
/** Фон кнопки добавления реакции */
|
|
88
|
-
'--chotto-messagereactions-add-bg': string;
|
|
89
|
-
/** Цвет кнопки добавления реакции */
|
|
90
|
-
'--chotto-messagereactions-add-color': string;
|
|
91
|
-
/** Курсор кнопки добавления реакции */
|
|
92
|
-
'--chotto-messagereactions-add-cursor': string;
|
|
93
|
-
/** Размер шрифта кнопки добавления реакции */
|
|
94
|
-
'--chotto-messagereactions-add-font-size': string;
|
|
95
|
-
/** Прозрачность кнопки добавления реакции */
|
|
96
|
-
'--chotto-messagereactions-add-opacity': string;
|
|
97
|
-
/** Переход кнопки добавления реакции */
|
|
98
|
-
'--chotto-messagereactions-add-transition': string;
|
|
99
|
-
/** События указателя кнопки добавления реакции */
|
|
100
|
-
'--chotto-messagereactions-add-pointer-events': string;
|
|
101
|
-
/** Позиционирование кнопки добавления реакции */
|
|
102
|
-
'--chotto-messagereactions-add-position': string;
|
|
103
|
-
/** Отступ снизу кнопки добавления реакции */
|
|
104
|
-
'--chotto-messagereactions-add-bottom': string;
|
|
105
|
-
/** Z-index кнопки добавления реакции */
|
|
106
|
-
'--chotto-messagereactions-add-z-index': string;
|
|
107
|
-
/** Отступ справа кнопки добавления реакции для левых сообщений */
|
|
108
|
-
'--chotto-messagereactions-add-left-right': string;
|
|
109
|
-
/** Отступ слева кнопки добавления реакции для левых сообщений */
|
|
110
|
-
'--chotto-messagereactions-add-left-left': string;
|
|
111
|
-
/** Отступ слева кнопки добавления реакции для правых сообщений */
|
|
112
|
-
'--chotto-messagereactions-add-right-left': string;
|
|
113
|
-
/** Отступ справа кнопки добавления реакции для правых сообщений */
|
|
114
|
-
'--chotto-messagereactions-add-right-right': string;
|
|
115
|
-
/** Позиционирование кнопки добавления реакции когда есть реакции */
|
|
116
|
-
'--chotto-messagereactions-add-has-reactions-position': string;
|
|
117
|
-
/** Отступ снизу кнопки добавления реакции когда есть реакции */
|
|
118
|
-
'--chotto-messagereactions-add-has-reactions-bottom': string;
|
|
119
|
-
/** Трансформация кнопки добавления реакции когда есть реакции */
|
|
120
|
-
'--chotto-messagereactions-add-has-reactions-transform': string;
|
|
121
|
-
/** Прозрачность кнопки добавления реакции когда есть чипы */
|
|
122
|
-
'--chotto-messagereactions-add-has-chip-opacity': string;
|
|
123
|
-
/** События указателя кнопки добавления реакции когда есть чипы */
|
|
124
|
-
'--chotto-messagereactions-add-has-chip-pointer-events': string;
|
|
125
|
-
/** Высота строки span внутри кнопки добавления реакции */
|
|
126
|
-
'--chotto-messagereactions-add-span-line-height': string;
|
|
127
|
-
/** Отображение span внутри кнопки добавления реакции */
|
|
128
|
-
'--chotto-messagereactions-add-span-display': string;
|
|
129
|
-
/** Вертикальное выравнивание span внутри кнопки добавления реакции */
|
|
130
|
-
'--chotto-messagereactions-add-span-align-items': string;
|
|
131
|
-
/** Горизонтальное выравнивание span внутри кнопки добавления реакции */
|
|
132
|
-
'--chotto-messagereactions-add-span-justify-content': string;
|
|
81
|
+
/** Цвет счётчика реакции */
|
|
82
|
+
'--chotto-messagereactions-count-color': string;
|
|
133
83
|
/** Позиционирование панели быстрых реакций */
|
|
134
84
|
'--chotto-messagereactions-quick-panel-position': string;
|
|
135
|
-
/** Отступ сверху панели быстрых реакций */
|
|
136
|
-
'--chotto-messagereactions-quick-panel-top': string;
|
|
137
|
-
/** Отступ слева панели быстрых реакций */
|
|
138
|
-
'--chotto-messagereactions-quick-panel-left': string;
|
|
139
|
-
/** Внешний отступ сверху панели быстрых реакций */
|
|
140
|
-
'--chotto-messagereactions-quick-panel-margin-top': string;
|
|
141
85
|
/** Фон панели быстрых реакций */
|
|
142
86
|
'--chotto-messagereactions-quick-panel-bg': string;
|
|
143
87
|
/** Граница панели быстрых реакций */
|
|
@@ -156,10 +100,6 @@ export interface MessageReactionsThemeCSSVariables {
|
|
|
156
100
|
'--chotto-messagereactions-quick-panel-gap': string;
|
|
157
101
|
/** Z-index панели быстрых реакций */
|
|
158
102
|
'--chotto-messagereactions-quick-panel-z-index': string;
|
|
159
|
-
/** Отступ слева панели быстрых реакций для правых сообщений */
|
|
160
|
-
'--chotto-messagereactions-quick-panel-right-left': string;
|
|
161
|
-
/** Отступ справа панели быстрых реакций для правых сообщений */
|
|
162
|
-
'--chotto-messagereactions-quick-panel-right-right': string;
|
|
163
103
|
/** Отображение элемента быстрой реакции */
|
|
164
104
|
'--chotto-messagereactions-quick-item-display': string;
|
|
165
105
|
/** Выравнивание элементов элемента быстрой реакции */
|
|
@@ -184,6 +124,10 @@ export interface MessageReactionsThemeCSSVariables {
|
|
|
184
124
|
'--chotto-messagereactions-quick-item-transition': string;
|
|
185
125
|
/** Фон элемента быстрой реакции при наведении */
|
|
186
126
|
'--chotto-messagereactions-quick-item-hover-bg': string;
|
|
127
|
+
/** Высота изображения эмодзи в элементе быстрой реакции */
|
|
128
|
+
'--chotto-messagereactions-quick-item-img-height': string;
|
|
129
|
+
/** Ширина изображения эмодзи в элементе быстрой реакции */
|
|
130
|
+
'--chotto-messagereactions-quick-item-img-width': string;
|
|
187
131
|
/** Отображение кнопки развернуть */
|
|
188
132
|
'--chotto-messagereactions-expand-display': string;
|
|
189
133
|
/** Выравнивание элементов кнопки развернуть */
|
|
@@ -210,10 +154,6 @@ export interface MessageReactionsThemeCSSVariables {
|
|
|
210
154
|
'--chotto-messagereactions-expand-transition': string;
|
|
211
155
|
/** Фон кнопки развернуть при наведении */
|
|
212
156
|
'--chotto-messagereactions-expand-hover-bg': string;
|
|
213
|
-
/** Высота строки span внутри кнопки развернуть */
|
|
214
|
-
'--chotto-messagereactions-expand-span-line-height': string;
|
|
215
|
-
/** Толщина шрифта span внутри кнопки развернуть */
|
|
216
|
-
'--chotto-messagereactions-expand-span-font-weight': string;
|
|
217
157
|
/** Z-index пикера реакций */
|
|
218
158
|
'--chotto-messagereactions-picker-z-index': string;
|
|
219
159
|
/** Позиционирование emoji picker внутри пикера */
|
|
@@ -2,5 +2,5 @@
|
|
|
2
2
|
* Список популярных эмоджи для быстрых реакций
|
|
3
3
|
* Используется в MessageReactions
|
|
4
4
|
*/
|
|
5
|
-
export declare const QUICK_REACTION_EMOJIS: readonly ["👍", "❤️", "
|
|
5
|
+
export declare const QUICK_REACTION_EMOJIS: readonly ["👍", "❤️", "🤝"];
|
|
6
6
|
export type QuickReactionEmoji = typeof QUICK_REACTION_EMOJIS[number];
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { MessageReactionItem } from '@/types';
|
|
2
|
+
/** timestamp в секундах или миллисекундах → ms */
|
|
3
|
+
export declare function normalizeReactionTimestamp(date?: number): number | undefined;
|
|
4
|
+
/** Формат: 20.07.26 11:08 */
|
|
5
|
+
export declare function formatReactionDate(date?: number): string;
|
|
6
|
+
export declare function resolveReactionUserName(item: MessageReactionItem, userNames?: Record<string, string> | null): string;
|
|
7
|
+
/** Сортировка событий по дате (старые сверху) */
|
|
8
|
+
export declare function sortReactionEvents(events: MessageReactionItem[]): MessageReactionItem[];
|
|
9
|
+
/**
|
|
10
|
+
* Текст тултипа:
|
|
11
|
+
* Василий Васильев, 20.07.26 11:08
|
|
12
|
+
* Иван Иванов, 20.07.26 11:09
|
|
13
|
+
*/
|
|
14
|
+
export declare function buildReactionTooltipText(events: MessageReactionItem[], userNames?: Record<string, string> | null): string;
|
|
@@ -6,6 +6,8 @@ export interface ReplyAudioMessageThemeCSSVariables {
|
|
|
6
6
|
'--chotto-replyaudiomessage-p-margin': string;
|
|
7
7
|
/** Размер шрифта абзаца */
|
|
8
8
|
'--chotto-replyaudiomessage-p-font-size': string;
|
|
9
|
+
/** Жирность абзаца (заголовок «В ответ») */
|
|
10
|
+
'--chotto-replyaudiomessage-p-font-weight': string;
|
|
9
11
|
/** Цвет абзаца */
|
|
10
12
|
'--chotto-replyaudiomessage-p-color': string;
|
|
11
13
|
/** Переполнение абзаца */
|
|
@@ -56,6 +58,8 @@ export interface ReplyAudioMessageThemeCSSVariables {
|
|
|
56
58
|
'--chotto-replyaudiomessage-text-margin-top': string;
|
|
57
59
|
/** Размер шрифта текста */
|
|
58
60
|
'--chotto-replyaudiomessage-text-font-size': string;
|
|
61
|
+
/** Жирность текста */
|
|
62
|
+
'--chotto-replyaudiomessage-text-font-weight': string;
|
|
59
63
|
/** Цвет текста */
|
|
60
64
|
'--chotto-replyaudiomessage-text-color': string;
|
|
61
65
|
/** Отображение описания ответа */
|
|
@@ -68,6 +72,8 @@ export interface ReplyAudioMessageThemeCSSVariables {
|
|
|
68
72
|
'--chotto-replyaudiomessage-reply-description-margin-bottom': string;
|
|
69
73
|
/** Цвет спана в описании ответа */
|
|
70
74
|
'--chotto-replyaudiomessage-reply-description-span-color': string;
|
|
75
|
+
/** Жирность текста «Аудиосообщение» */
|
|
76
|
+
'--chotto-replyaudiomessage-reply-description-p-font-weight': string;
|
|
71
77
|
/** Жирность жирного текста (markdown **текст**) */
|
|
72
78
|
'--chotto-replyaudiomessage-markdown-strong-font-weight': string;
|
|
73
79
|
/** Стиль курсива (markdown *текст*) */
|
|
@@ -34,6 +34,8 @@ export interface ReplyCallMessageThemeCSSVariables {
|
|
|
34
34
|
'--chotto-replycallmessage-text-container-p-margin': string;
|
|
35
35
|
/** Размер шрифта абзаца */
|
|
36
36
|
'--chotto-replycallmessage-text-container-p-font-size': string;
|
|
37
|
+
/** Жирность абзаца (заголовок «В ответ») */
|
|
38
|
+
'--chotto-replycallmessage-text-container-p-font-weight': string;
|
|
37
39
|
/** Цвет абзаца */
|
|
38
40
|
'--chotto-replycallmessage-text-container-p-color': string;
|
|
39
41
|
/** Переполнение абзаца */
|
|
@@ -58,4 +60,8 @@ export interface ReplyCallMessageThemeCSSVariables {
|
|
|
58
60
|
'--chotto-replycallmessage-reply-description-margin-bottom': string;
|
|
59
61
|
/** Цвет спана в описании ответа */
|
|
60
62
|
'--chotto-replycallmessage-reply-description-span-color': string;
|
|
63
|
+
/** Жирность текста типа звонка */
|
|
64
|
+
'--chotto-replycallmessage-reply-description-span-font-weight': string;
|
|
65
|
+
/** Жирность длительности звонка */
|
|
66
|
+
'--chotto-replycallmessage-duration-font-weight': string;
|
|
61
67
|
}
|