The namespaces UnityEditor or UnityEditorInternal are not included when you build for a platform. Those are only included when working in the actual UnityEditor.
For whatever reasons you needed those namespace at runtime, you’ll have to find a workaround, because that can’t be done