You have, for example rectangle which is in ContentControl in XAML, next to FluidC.C. FluidContentControl is in small state. Ona button click SmallContent is assigned to the Rectangle. This leads to the exception stated that rectangle is already a logical child of another element.
The fix is available in LIB version 2018.1.226, it will be also available in the R2 2018 Release.