Button custom block when not working

Hi !
I created a custom block with the cookbook and I created a Button block.
Some of the fields have when conditions but they doesn’t display at all.
Here is thefile : /site/plugins/block-factory/blueprints/blocks/button.yml

name: Button
icon: attachment
fields:
  isExternal:
    type: toggle
    label: Lien externe ?
  pageLink:
    label: Page
    type: pages
    max: 1
    required: true
    when:
      isExternal: false
  externalLink:
    type: url
    label: Lien externe
    required: true
    when:
      isExternal: true

Thank or your help !

Hi and welcome to the forum?

Could you elaborate a bit more what exactly does not work? If I understand you correctly, you can select the block but the input fields do not appear?

Otherwise, please explain in a bit more detail what does or does not work as expected. Thanks.

Hi !
Thank you for your reply !
I expect that the right field show when I select the link type but nothing show expect the toggles field.
I want that if I click on “External” the “externalLink” field display under the toggles field.

Hm, just tested your blueprint and works fine for me. Could it be that you have some indentation problem?