@linktr.ee/messaging-react 3.12.4-rc-1784100747 → 3.12.4-rc-1784101037
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 +2 -2
- package/src/components/AttachmentCard/AttachmentCard.stories.tsx +6 -2
- package/src/components/CustomMessage/LockedAttachment/LockedAttachment.stories.tsx +1 -1
- package/src/components/CustomMessage/MessageAttachmentConversations.stories.tsx +4 -1
- package/src/components/CustomMessage/StreamAttachmentMessage.stories.tsx +1 -1
- package/src/components/LinkAttachment/LinkAttachment.stories.tsx +1 -1
- package/src/components/MediaMessage/MediaMessage.stories.tsx +6 -6
- package/src/components/MessageAttachment/stories/StoryTable.tsx +3 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@linktr.ee/messaging-react",
|
|
3
|
-
"version": "3.12.4-rc-
|
|
3
|
+
"version": "3.12.4-rc-1784101037",
|
|
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-1784101037",
|
|
54
54
|
"@phosphor-icons/react": "^2.1.10"
|
|
55
55
|
},
|
|
56
56
|
"devDependencies": {
|
|
@@ -17,7 +17,11 @@ export default meta
|
|
|
17
17
|
|
|
18
18
|
const IMAGE_URL = '/image-thumbnail.jpg'
|
|
19
19
|
|
|
20
|
-
const Template: StoryFn<ComponentProps> = (args) =>
|
|
20
|
+
const Template: StoryFn<ComponentProps> = (args) => (
|
|
21
|
+
<div className="w-[280px]">
|
|
22
|
+
<AttachmentCard {...args} />
|
|
23
|
+
</div>
|
|
24
|
+
)
|
|
21
25
|
|
|
22
26
|
// Per-variant stories stay in Storybook for browsing/design review but are
|
|
23
27
|
// individually covered by cells in AllVariants — skip in Chromatic.
|
|
@@ -216,7 +220,7 @@ export const AllVariants: StoryFn = () => {
|
|
|
216
220
|
return (
|
|
217
221
|
<div className="grid grid-cols-2 gap-6 p-6">
|
|
218
222
|
{cards.map(({ label, props }) => (
|
|
219
|
-
<div key={label} className="flex flex-col gap-2">
|
|
223
|
+
<div key={label} className="flex w-[280px] flex-col gap-2">
|
|
220
224
|
<span className="text-xs text-stone">{label}</span>
|
|
221
225
|
<AttachmentCard {...props} />
|
|
222
226
|
</div>
|
|
@@ -59,7 +59,7 @@ const MatrixTableRow: React.FC<{
|
|
|
59
59
|
const MatrixTableCell: React.FC<{
|
|
60
60
|
isMine: boolean
|
|
61
61
|
children: React.ReactNode
|
|
62
|
-
}> = ({ children }) => <div>{children}</div>
|
|
62
|
+
}> = ({ children }) => <div className="w-[280px]">{children}</div>
|
|
63
63
|
|
|
64
64
|
export const Text: StoryFn = () => {
|
|
65
65
|
const [isUnlocking, setUnlocking] = useState(false)
|
|
@@ -88,7 +88,10 @@ const ChatRow: React.FC<{
|
|
|
88
88
|
) : null}
|
|
89
89
|
</div>
|
|
90
90
|
) : null}
|
|
91
|
-
<div className={
|
|
91
|
+
<div className={classNames(
|
|
92
|
+
'w-[280px]',
|
|
93
|
+
role === 'sender' ? 'flex justify-end' : 'flex justify-start'
|
|
94
|
+
)}>
|
|
92
95
|
{children}
|
|
93
96
|
</div>
|
|
94
97
|
</div>
|
|
@@ -44,7 +44,7 @@ const Bubbles: React.FC<{ isMyMessage: boolean; children: React.ReactNode }> = (
|
|
|
44
44
|
: 'str-chat__message--other'
|
|
45
45
|
)}
|
|
46
46
|
>
|
|
47
|
-
<div className="str-chat__message-inner">{children}</div>
|
|
47
|
+
<div className="str-chat__message-inner w-[280px]">{children}</div>
|
|
48
48
|
</div>
|
|
49
49
|
</div>
|
|
50
50
|
</div>
|
|
@@ -220,7 +220,7 @@ export const LinkApps: StoryFn = () => (
|
|
|
220
220
|
<tr key={label}>
|
|
221
221
|
<RowLabel>{label}</RowLabel>
|
|
222
222
|
{LINK_APPS.map((app) => (
|
|
223
|
-
<td key={app.key} className="align-top">
|
|
223
|
+
<td key={app.key} className="w-[280px] align-top">
|
|
224
224
|
{renderLinkAppCard(layout, state, app)}
|
|
225
225
|
</td>
|
|
226
226
|
))}
|
|
@@ -165,7 +165,7 @@ export const Attachment: StoryFn = () => (
|
|
|
165
165
|
Visitor
|
|
166
166
|
</td>
|
|
167
167
|
{VARIANTS.map(({ label, attachment }) => (
|
|
168
|
-
<td key={label} className="align-top">
|
|
168
|
+
<td key={label} className="w-[280px] align-top">
|
|
169
169
|
<MediaMessage
|
|
170
170
|
isMyMessage={false}
|
|
171
171
|
message={base({
|
|
@@ -182,7 +182,7 @@ export const Attachment: StoryFn = () => (
|
|
|
182
182
|
Creator
|
|
183
183
|
</td>
|
|
184
184
|
{VARIANTS.map(({ label, attachment }) => (
|
|
185
|
-
<td key={label} className="align-top">
|
|
185
|
+
<td key={label} className="w-[280px] align-top">
|
|
186
186
|
<MediaMessage
|
|
187
187
|
isMyMessage={true}
|
|
188
188
|
message={base({
|
|
@@ -207,7 +207,7 @@ export const Links: StoryFn = () => (
|
|
|
207
207
|
Visitor
|
|
208
208
|
</td>
|
|
209
209
|
{LINK_VARIANTS.map(({ label, attachment }) => (
|
|
210
|
-
<td key={label} className="align-top">
|
|
210
|
+
<td key={label} className="w-[280px] align-top">
|
|
211
211
|
<MediaMessage
|
|
212
212
|
isMyMessage={false}
|
|
213
213
|
message={base({
|
|
@@ -224,7 +224,7 @@ export const Links: StoryFn = () => (
|
|
|
224
224
|
Creator
|
|
225
225
|
</td>
|
|
226
226
|
{LINK_VARIANTS.map(({ label, attachment }) => (
|
|
227
|
-
<td key={label} className="align-top">
|
|
227
|
+
<td key={label} className="w-[280px] align-top">
|
|
228
228
|
<MediaMessage
|
|
229
229
|
isMyMessage={true}
|
|
230
230
|
message={base({
|
|
@@ -250,7 +250,7 @@ export const Compound: StoryFn = () => (
|
|
|
250
250
|
MediaMessage.Visitor
|
|
251
251
|
</td>
|
|
252
252
|
{VARIANTS.map(({ label, attachment }) => (
|
|
253
|
-
<td key={label} className="align-top">
|
|
253
|
+
<td key={label} className="w-[280px] align-top">
|
|
254
254
|
<MediaMessage.Visitor
|
|
255
255
|
message={base({
|
|
256
256
|
attachments: [
|
|
@@ -266,7 +266,7 @@ export const Compound: StoryFn = () => (
|
|
|
266
266
|
MediaMessage.Creator
|
|
267
267
|
</td>
|
|
268
268
|
{VARIANTS.map(({ label, attachment }) => (
|
|
269
|
-
<td key={label} className="align-top">
|
|
269
|
+
<td key={label} className="w-[280px] align-top">
|
|
270
270
|
<MediaMessage.Creator
|
|
271
271
|
message={base({
|
|
272
272
|
attachments: [
|
|
@@ -51,9 +51,9 @@ export const StoryRow: React.FC<StoryRowProps> = ({
|
|
|
51
51
|
}) => (
|
|
52
52
|
<div className="grid grid-cols-[160px_minmax(0,1fr)_minmax(0,1fr)_minmax(0,1fr)] items-start gap-6 py-4">
|
|
53
53
|
<p className="text-xs font-medium text-black/55">{label}</p>
|
|
54
|
-
<div>{composer ?? null}</div>
|
|
55
|
-
<div>{sent}</div>
|
|
56
|
-
<div>{received}</div>
|
|
54
|
+
<div className="w-[280px]">{composer ?? null}</div>
|
|
55
|
+
<div className="w-[280px]">{sent}</div>
|
|
56
|
+
<div className="w-[280px]">{received}</div>
|
|
57
57
|
</div>
|
|
58
58
|
)
|
|
59
59
|
|