A method for implementing an adaptive color transform (ACT) during image/video encoding and decoding, comprises determining, for a conversion between a video comprising a block and a bitstream of the video, that a size of the block is greater than a maximum allowed size for an ACT mode, and performing, based on the determining, the conversion, wherein, in response to the size of the block being greater than the maximum allowed size for the ACT mode, the block is partitioned into multiple sub-blocks, and wherein each of the multiple sub-blocks share a same prediction mode, and the ACT mode is enabled at a sub-block level.