-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
native: update detail views to match figma designs
- Loading branch information
1 parent
9cd3ee4
commit 6ac9786
Showing
27 changed files
with
956 additions
and
468 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
import { PostScreenView } from '@tloncorp/ui/src'; | ||
|
||
import { FixtureWrapper } from './FixtureWrapper'; | ||
import { | ||
createFakePost, | ||
createFakePosts, | ||
tlonLocalBulletinBoard, | ||
tlonLocalGettingStarted, | ||
} from './fakeData'; | ||
|
||
const notebookPost = createFakePost('note'); | ||
const notebookReplies = createFakePosts(notebookPost.replyCount ?? 5, 'reply'); | ||
const galleryPost = createFakePost( | ||
'block', | ||
undefined, | ||
'https://togten.com:9001/finned-palmer/finned-palmer/2024.3.19..21.2.17..5581.0624.dd2f.1a9f-image.png' | ||
); | ||
const galleryReplies = createFakePosts(galleryPost.replyCount ?? 5, 'reply'); | ||
|
||
const NotebookDetailViewFixture = () => { | ||
return ( | ||
<FixtureWrapper> | ||
<PostScreenView | ||
parentPost={notebookPost} | ||
posts={notebookReplies} | ||
contacts={[]} | ||
channel={tlonLocalGettingStarted} | ||
currentUserId={notebookPost.authorId} | ||
sendReply={() => {}} | ||
groupMembers={[]} | ||
negotiationMatch={true} | ||
editPost={() => {}} | ||
uploadInfo={{ | ||
uploading: false, | ||
uploadedImage: null, | ||
imageAttachment: null, | ||
setAttachments: () => {}, | ||
resetImageAttachment: () => {}, | ||
canUpload: true, | ||
}} | ||
storeDraft={() => {}} | ||
clearDraft={() => {}} | ||
getDraft={async () => ({})} | ||
goBack={() => {}} | ||
/> | ||
</FixtureWrapper> | ||
); | ||
}; | ||
|
||
const GalleryDetailViewFixture = () => { | ||
return ( | ||
<FixtureWrapper> | ||
<PostScreenView | ||
parentPost={galleryPost} | ||
posts={galleryReplies} | ||
contacts={[]} | ||
channel={tlonLocalBulletinBoard} | ||
currentUserId={galleryPost.authorId} | ||
sendReply={() => {}} | ||
groupMembers={[]} | ||
negotiationMatch={true} | ||
editPost={() => {}} | ||
uploadInfo={{ | ||
uploading: false, | ||
uploadedImage: null, | ||
imageAttachment: null, | ||
setAttachments: () => {}, | ||
resetImageAttachment: () => {}, | ||
canUpload: true, | ||
}} | ||
storeDraft={() => {}} | ||
clearDraft={() => {}} | ||
getDraft={async () => ({})} | ||
goBack={() => {}} | ||
/> | ||
</FixtureWrapper> | ||
); | ||
}; | ||
|
||
export default { | ||
notebook: NotebookDetailViewFixture, | ||
galleryPost: GalleryDetailViewFixture, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.