How do I move the center of the camera to the side of the screen instead of the center

Part of my map is hiding under another HTML element, and sometimes above it.
I want to change the center of the view when I use flyTo according to the new center of the map.

What is the best way to do this?

I think it depends on how you’re using flyTo. If you’re just passing in a destination as a Cartesian3, you can just apply an offset to that before you pass it in. You may also find these functions helpful in translating back and forth between world and screen coordinates:

https://cesiumjs.org/Cesium/Build/Documentation/Scene.html?classFilter=Scene#cartesianToCanvasCoordinates

https://cesiumjs.org/Cesium/Build/Documentation/SceneTransforms.html?classFilter=transforms#.wgs84ToWindowCoordinates