GroupsV2: Better group invite behavior

This commit is contained in:
Scott Nonnenberg 2020-10-06 10:06:34 -07:00 committed by Josh Perez
parent b9ff4f07d3
commit d51a0b5ece
24 changed files with 1408 additions and 313 deletions

View file

@ -81,6 +81,35 @@ storiesOf('Components/Conversation/GroupV2Change', module)
</>
);
})
.add('Create', () => {
return (
<>
{renderChange({
from: OUR_ID,
details: [
{
type: 'create',
},
],
})}
{renderChange({
from: CONTACT_A,
details: [
{
type: 'create',
},
],
})}
{renderChange({
details: [
{
type: 'create',
},
],
})}
</>
);
})
.add('Title', () => {
return (
<>
@ -784,6 +813,28 @@ storiesOf('Components/Conversation/GroupV2Change', module)
},
],
})}
{renderChange({
from: CONTACT_B,
details: [
{
type: 'pending-remove-one',
conversationId: OUR_ID,
inviter: CONTACT_B,
},
],
})}
{renderChange({
from: CONTACT_A,
details: [
{
type: 'pending-remove-one',
conversationId: CONTACT_B,
inviter: CONTACT_A,
},
],
})}
{renderChange({
from: CONTACT_C,
details: [

View file

@ -65,10 +65,6 @@ story.add('No Image', () => {
return <StagedLinkPreview {...createProps()} />;
});
story.add('No Image', () => {
return <StagedLinkPreview {...createProps()} />;
});
story.add('Image', () => {
const props = createProps({
image: createAttachment({
@ -102,18 +98,6 @@ story.add('No Image, Long Title With Description', () => {
return <StagedLinkPreview {...props} />;
});
story.add('Image, Long Title With Description', () => {
const props = createProps({
title: LONG_TITLE,
image: createAttachment({
url: '/fixtures/kitten-4-112-112.jpg',
contentType: 'image/jpeg' as MIMEType,
}),
});
return <StagedLinkPreview {...props} />;
});
story.add('No Image, Long Title Without Description', () => {
const props = createProps({
title: LONG_TITLE,
@ -123,7 +107,7 @@ story.add('No Image, Long Title Without Description', () => {
return <StagedLinkPreview {...props} />;
});
story.add('Image, Long Title With Description', () => {
story.add('Image, Long Title Without Description', () => {
const props = createProps({
title: LONG_TITLE,
image: createAttachment({