addColourBorder_ on nested categories

46 views
Skip to first unread message

Joshua Lowe

unread,
Jun 10, 2025, 8:18:41 AMJun 10
to Blockly
Hi all,

I'm following this guide and it works for regular categories however my custom addColourBorder_ function does not apply to top level categories when there are nested categories within it.

Is there a workaround?



epas...@google.com

unread,
Jun 10, 2025, 3:22:58 PMJun 10
to Blockly
Hi there,

Collapsible categories are registered under a separate name since they often need to be styled differently to show they are collapsible. If you repeat the steps in the guide but make a new custom category that extends CollapsibleToolbox and registers using Blockly.CollapsibleToolboxCategory.registrationName instead of Blockly.ToolboxCategory.registrationName it should get applied to the collapsible menus.

Cheers,
Erik

Joshua Lowe

unread,
Jun 11, 2025, 5:32:37 AMJun 11
to Blockly
Thanks Erik! This fixed my issue
Reply all
Reply to author
Forward
0 new messages