gx
chenyc
2025-02-12 ea42ff3ebee1eeb3fb29423aa848a249441db81c
1
2
3
4
5
6
7
8
9
10
11
12
13
import { Dimensions } from '../classes/Dimensions';
import { env } from '../env';
export function getMediaDimensions(input) {
    var _a = env.getEnv(), Image = _a.Image, Video = _a.Video;
    if (input instanceof Image) {
        return new Dimensions(input.naturalWidth, input.naturalHeight);
    }
    if (input instanceof Video) {
        return new Dimensions(input.videoWidth, input.videoHeight);
    }
    return new Dimensions(input.width, input.height);
}
//# sourceMappingURL=getMediaDimensions.js.map