A custom block that needs a colour picker and a spacing control does not need either to be written: declaring support produces the sidebar and the classes.
register_block_type( 'turkerdev/notice', array(
'supports' => array(
'align' => array( 'wide', 'full' ),
'color' => array( 'background' => true, 'text' => true ),
'anchor' => true,
'html' => false, // no editing as HTML
),
) );
The generated classes are core’s — has-background, has-text-color and the palette slugs — so the theme has to style them or the picker appears to do nothing. html: false is worth setting on any block with a strict markup contract, because editing as HTML is the fastest route to a validation error. Every support declared is a control an editor can reach, so declaring them all is a design decision rather than a convenience.