@linktr.ee/messaging-react 3.12.3-rc-1784083967 → 3.12.3-rc-1784084417
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/index.cjs +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.js +11 -10
- package/package.json +2 -2
- package/src/index.test.ts +13 -0
- package/src/index.ts +1 -0
package/dist/index.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-DSxpS5J9.cjs");exports.ActionButton=e.ActionButton;exports.Avatar=e.Avatar;exports.ChannelEmptyState=e.ChannelEmptyState;exports.ChannelList=e.ChannelList;exports.ChannelView=e.ChannelView;exports.CustomMessageProvider=e.CustomMessageProvider;exports.FaqList=e.FaqList;exports.FaqListItem=e.FaqListItem;exports.LinkAttachment=e.LinkAttachment;exports.LockedAttachment=e.LockedAttachment;exports.MediaMessage=e.MediaMessage;exports.MessageAttachment=e.MessageAttachment;exports.MessageBubble=e.MessageBubble;exports.MessageVoteButtons=e.MessageVoteButtons;exports.MessagingProvider=e.MessagingProvider;exports.MessagingShell=e.MessagingShell;exports.buildCompactMetaLabel=e.buildCompactMetaLabel;exports.formatFileSize=e.formatFileSize;exports.formatRelativeTime=e.formatRelativeTime;exports.getFileExtensionLabel=e.getFileExtensionLabel;exports.getMessageDisplayText=e.getMessageDisplayText;exports.isLinkAttachment=e.isLinkAttachment;exports.isUuidLike=e.isUuidLike;exports.messageAttachmentGroupPositionFromStream=e.bubbleGroupPositionFromStream;exports.normalizeLanguageCode=e.normalizeLanguageCode;exports.resolveConversationParticipant=e.resolveConversationParticipant;exports.resolveLinkAttachment=e.resolveLinkAttachment;exports.resolveMediaFromMessage=e.resolveMediaFromMessage;exports.resolveParticipantDisplayName=e.resolveParticipantDisplayName;exports.useComposerLocked=e.useComposerLocked;exports.useCustomMessage=e.useCustomMessage;exports.useMessageVote=e.useMessageVote;exports.useMessaging=e.useMessaging;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-DSxpS5J9.cjs");exports.ActionButton=e.ActionButton;exports.Avatar=e.Avatar;exports.ChannelEmptyState=e.ChannelEmptyState;exports.ChannelList=e.ChannelList;exports.ChannelView=e.ChannelView;exports.CustomMessageProvider=e.CustomMessageProvider;exports.FaqList=e.FaqList;exports.FaqListItem=e.FaqListItem;exports.LinkAttachment=e.LinkAttachment;exports.LockedAttachment=e.LockedAttachment;exports.MediaMessage=e.MediaMessage;exports.MessageAttachment=e.MessageAttachment;exports.MessageBubble=e.MessageBubble;exports.MessageVoteButtons=e.MessageVoteButtons;exports.MessagingProvider=e.MessagingProvider;exports.MessagingShell=e.MessagingShell;exports.buildCompactMetaLabel=e.buildCompactMetaLabel;exports.formatFileSize=e.formatFileSize;exports.formatRelativeTime=e.formatRelativeTime;exports.getFileExtensionLabel=e.getFileExtensionLabel;exports.getMessageDisplayText=e.getMessageDisplayText;exports.isLinkAttachment=e.isLinkAttachment;exports.isUuidLike=e.isUuidLike;exports.messageAttachmentGroupPositionFromStream=e.bubbleGroupPositionFromStream;exports.normalizeLanguageCode=e.normalizeLanguageCode;exports.optimizeMessagingAttachmentUrl=e.optimizeMessagingAttachmentUrl;exports.resolveConversationParticipant=e.resolveConversationParticipant;exports.resolveLinkAttachment=e.resolveLinkAttachment;exports.resolveMediaFromMessage=e.resolveMediaFromMessage;exports.resolveParticipantDisplayName=e.resolveParticipantDisplayName;exports.useComposerLocked=e.useComposerLocked;exports.useCustomMessage=e.useCustomMessage;exports.useMessageVote=e.useMessageVote;exports.useMessaging=e.useMessaging;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
package/dist/index.d.ts
CHANGED
|
@@ -1465,6 +1465,8 @@ export declare type OfficialCtaAttachment = Attachment & {
|
|
|
1465
1465
|
type: 'linktree_official_cta';
|
|
1466
1466
|
};
|
|
1467
1467
|
|
|
1468
|
+
export declare function optimizeMessagingAttachmentUrl(url: string | undefined | null): string | undefined;
|
|
1469
|
+
|
|
1468
1470
|
/**
|
|
1469
1471
|
* Generic participant interface for different host environments
|
|
1470
1472
|
*/
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as e, b as t, C as i, c as o, d as n, e as m, F as r, f as g, L as l, h as M, M as
|
|
1
|
+
import { a as e, b as t, C as i, c as o, d as n, e as m, F as r, f as g, L as l, h as M, M as c, i as u, j as L, k as h, l as p, m as d, n as v, p as C, q as A, s as k, t as F, u as b, v as P, w as f, x, o as y, y as z, z as B, B as S, D as q, E as D, G as E, H as V, I as w } from "./index-B2BrYTjw.js";
|
|
2
2
|
export {
|
|
3
3
|
e as ActionButton,
|
|
4
4
|
t as Avatar,
|
|
@@ -10,12 +10,12 @@ export {
|
|
|
10
10
|
g as FaqListItem,
|
|
11
11
|
l as LinkAttachment,
|
|
12
12
|
M as LockedAttachment,
|
|
13
|
-
|
|
14
|
-
|
|
13
|
+
c as MediaMessage,
|
|
14
|
+
u as MessageAttachment,
|
|
15
15
|
L as MessageBubble,
|
|
16
16
|
h as MessageVoteButtons,
|
|
17
|
-
|
|
18
|
-
|
|
17
|
+
p as MessagingProvider,
|
|
18
|
+
d as MessagingShell,
|
|
19
19
|
v as buildCompactMetaLabel,
|
|
20
20
|
C as formatFileSize,
|
|
21
21
|
A as formatRelativeTime,
|
|
@@ -25,13 +25,14 @@ export {
|
|
|
25
25
|
P as isUuidLike,
|
|
26
26
|
f as messageAttachmentGroupPositionFromStream,
|
|
27
27
|
x as normalizeLanguageCode,
|
|
28
|
-
y as
|
|
28
|
+
y as optimizeMessagingAttachmentUrl,
|
|
29
|
+
z as resolveConversationParticipant,
|
|
29
30
|
B as resolveLinkAttachment,
|
|
30
31
|
S as resolveMediaFromMessage,
|
|
31
32
|
q as resolveParticipantDisplayName,
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
33
|
+
D as useComposerLocked,
|
|
34
|
+
E as useCustomMessage,
|
|
35
|
+
V as useMessageVote,
|
|
36
|
+
w as useMessaging
|
|
36
37
|
};
|
|
37
38
|
//# sourceMappingURL=index.js.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@linktr.ee/messaging-react",
|
|
3
|
-
"version": "3.12.3-rc-
|
|
3
|
+
"version": "3.12.3-rc-1784084417",
|
|
4
4
|
"description": "React messaging components built on messaging-core for web applications",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.cjs",
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
},
|
|
51
51
|
"dependencies": {
|
|
52
52
|
"@linktr.ee/component-library": "11.8.6",
|
|
53
|
-
"@linktr.ee/messaging-core": "2.3.0-rc-
|
|
53
|
+
"@linktr.ee/messaging-core": "2.3.0-rc-1784084417",
|
|
54
54
|
"@phosphor-icons/react": "^2.1.10"
|
|
55
55
|
},
|
|
56
56
|
"devDependencies": {
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { describe, expect, it } from 'vitest'
|
|
2
|
+
|
|
3
|
+
import { optimizeMessagingAttachmentUrl } from './index'
|
|
4
|
+
|
|
5
|
+
describe('messaging-react public utils', () => {
|
|
6
|
+
it('exports optimizeMessagingAttachmentUrl from the package root', () => {
|
|
7
|
+
expect(
|
|
8
|
+
optimizeMessagingAttachmentUrl('https://assets.linktr.ee/photo.jpg')
|
|
9
|
+
).toBe(
|
|
10
|
+
'https://assets.linktr.ee/photo.jpg?io=true&size=messaging-attachment-v1_0'
|
|
11
|
+
)
|
|
12
|
+
})
|
|
13
|
+
})
|
package/src/index.ts
CHANGED
|
@@ -48,6 +48,7 @@ export {
|
|
|
48
48
|
} from './utils/resolveParticipantDisplayName'
|
|
49
49
|
export type { ParticipantDisplayUser } from './utils/resolveParticipantDisplayName'
|
|
50
50
|
export { resolveConversationParticipant } from './utils/resolveConversationParticipant'
|
|
51
|
+
export { optimizeMessagingAttachmentUrl } from './utils/cdnImageUrl'
|
|
51
52
|
|
|
52
53
|
// Types
|
|
53
54
|
export type {
|