  Co-based shandite Co$_3$Sn$_2$S$_2$ is a ferromagnet hosting Weyl fermions in
the layered Co kagome structure. The band topology as well as the magnetism is
predicted to vary drastically in the atomically thin films depending on the
thickness and surface termination, and as an extreme case, the quantum
anomalous Hall state is expected in a monolayer of the Co kagome lattice. Given
that the bulk Weyl gap depends on the magnetization direction, here we
theoretically study how the topological nature and transport properties vary
with the magnetization direction in the systems with kagome monolayer with both
Sn and S surface terminations. By using $ab \ initio$ calculations, we find
that in the Sn-end monolayer the anomalous Hall conductivity shows successive
discrete changes between different quantized values by rotating the
magnetization, indicating several topological transitions between the anomalous
quantum Hall insulators with different Chern numbers. Notably, when the
magnetization is oriented in-plane and perpendicular to the Co-Co bond, the
system exhibits a planar quantized anomalous Hall effect. We clarify that these
peculiar behaviors are due to topological changes in the band structures
associated with gap closing of the Weyl nodes. In contrast, the S-end monolayer
shows rather continuous changes in the transport properties since the system is
metallic, although the band structure contains many Weyl nodes. Our results
pave the way for controlling Weyl fermions in atomically thin films of Co-based
shandite, where the topological nature associated with the Weyl nodes appears
more clearly than the bulk.
