Skip to content

Commit 930b794

Browse files
authored
pixelSize added to images fixes #40 (#41)
1 parent 1eeee05 commit 930b794

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/Annotator/reducers/image-reducer.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@ export default (state: MainLayoutImageAnnotationState, action: Action) => {
1313
)
1414

1515
switch (action.type) {
16-
case "IMAGE_LOADED": {
16+
case "IMAGE_OR_VIDEO_LOADED": {
1717
return setIn(state, ["images", currentImageIndex, "pixelSize"], {
18-
w: action.image.width,
19-
h: action.image.height
18+
w: action.metadata.naturalWidth,
19+
h: action.metadata.naturalHeight
2020
})
2121
}
2222
}

0 commit comments

Comments
 (0)