See there was a post in Facebook for this: https://www.facebook.com/groups/editorxcm/posts/2393114570827235/
Don’t think there’s a specific way to do so as if both the height and width need to be responsive to the screen width and height, it wouldn’t end up being able to scale proportionally. Best thing might be to use the focal point of the image / video if you need the width and height to be responsive but don’t want things to be cut off.