An example from Sandcastle doesn't work

You need to understand how the import syntax works in TS (and ES6 vanilla-JS modules). ConstantPositionProperty is a class (or more exactly, class-like constructor function, I think?) provided by Cesium. If you import Cesium from "cesium", then Cesium is a module object with all the exports explained in the Cesium documentation as properties, Cesium.Cartesian3, Cesium.Color, etc etc. In that case, you would construct a ConstantPositionProperty with new Cesium.ConstantPositionProperty(...).

I thought you had gotten the syntax import { Cartesian3, Color, ... } from "cesium" working. (It’s a better habit to get into than importing the whole Cesium namespace because it makes your bundler’s job easier.) In that case, you would need to add ConstantPositionProperty to that import list, which makes it a valid top-level identifier within the scope of your TS file. VSCode, which you appear to be using in your screenshots, will offer to do that for you with a quick-fix action, assuming your project is correctly configured.