Skip to content

Commit f2a6b39

Browse files
committed
Merge branch 'main' into graphiql-v4
2 parents 6587675 + 7404e8e commit f2a6b39

File tree

3 files changed

+8
-1
lines changed

3 files changed

+8
-1
lines changed

.changeset/pink-singers-glow.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
"@graphiql/react": minor
3+
"graphiql": minor
4+
---
5+
6+
Add webp support to graphiql results image-preview

packages/graphiql-react/src/editor/components/image-preview.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,5 +81,5 @@ function tokenToURL(token: Token) {
8181
}
8282

8383
function isImageURL(url: URL) {
84-
return /(bmp|gif|jpeg|jpg|png|svg)$/.test(url.pathname);
84+
return /\.(bmp|gif|jpe?g|png|svg|webp)$/.test(url.pathname);
8585
}

resources/custom-words.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -221,6 +221,7 @@ vitejs
221221
vitest
222222
vizag
223223
vsix
224+
webp
224225
websockets
225226
wgutils
226227
wincent

0 commit comments

Comments
 (0)