summaryrefslogtreecommitdiff
path: root/packages/frontend/src/components/MkGalleryPostPreview.stories.impl.ts
diff options
context:
space:
mode:
authorAcid Chicken (硫酸鶏) <root@acid-chicken.com>2023-04-29 22:57:46 +0900
committerGitHub <noreply@github.com>2023-04-29 22:57:46 +0900
commit9d5911d4e436859127f38d5fcdaa6cb5ce6d01e6 (patch)
tree4feca3f9e8ed46acc0ee3abd7ad357c8d1f05d8e /packages/frontend/src/components/MkGalleryPostPreview.stories.impl.ts
parentfix(backend): `alsoKnownAs`の誤った定義を修正 (#10725) (diff)
downloadmisskey-9d5911d4e436859127f38d5fcdaa6cb5ce6d01e6.tar.gz
misskey-9d5911d4e436859127f38d5fcdaa6cb5ce6d01e6.tar.bz2
misskey-9d5911d4e436859127f38d5fcdaa6cb5ce6d01e6.zip
feat: make `MkImgWithBlurhash` transitionable (#10500)
* feat: make `MkImgWithBlurhash` animatable * refactor: split out transition styles * fix: bug * test: waitFor image loads * style: remove unused await * fix * fix type error --------- Co-authored-by: tamaina <tamaina@hotmail.co.jp>
Diffstat (limited to 'packages/frontend/src/components/MkGalleryPostPreview.stories.impl.ts')
-rw-r--r--packages/frontend/src/components/MkGalleryPostPreview.stories.impl.ts8
1 files changed, 5 insertions, 3 deletions
diff --git a/packages/frontend/src/components/MkGalleryPostPreview.stories.impl.ts b/packages/frontend/src/components/MkGalleryPostPreview.stories.impl.ts
index e46a708192..57b3e75513 100644
--- a/packages/frontend/src/components/MkGalleryPostPreview.stories.impl.ts
+++ b/packages/frontend/src/components/MkGalleryPostPreview.stories.impl.ts
@@ -28,9 +28,11 @@ export const Default = {
async play({ canvasElement }) {
const canvas = within(canvasElement);
const links = canvas.getAllByRole('link');
- await expect(links).toHaveLength(2);
- await expect(links[0]).toHaveAttribute('href', `/gallery/${galleryPost().id}`);
- await expect(links[1]).toHaveAttribute('href', `/@${galleryPost().user.username}@${galleryPost().user.host}`);
+ expect(links).toHaveLength(2);
+ expect(links[0]).toHaveAttribute('href', `/gallery/${galleryPost().id}`);
+ expect(links[1]).toHaveAttribute('href', `/@${galleryPost().user.username}@${galleryPost().user.host}`);
+ const images = canvas.getAllByRole<HTMLImageElement>('img');
+ await waitFor(() => expect(Promise.all(images.map((image) => image.decode()))).resolves.toBeDefined());
},
args: {
post: galleryPost(),