Following is the annotation provided for a custom block plugin
/**
* Provides a 'ChatButtonBlock' block.
*
* @Block(
* id = "chat_button_block",
* admin_label = @Translation("Chat Button"),
* )
*/
module name is foo_chat
.
When the block exposed by the above plugin is placed in a region, then how can i create this plugin specific twig template?
The closest i could get was in using block--foo-chat.html.twig
which will apply for all the blocks created using the module foo_chat
.
I have tried the following,
block--foo-chat--chat-button-block.html.twig
block--foo-chat--chatbutton.html.twig
The reason why i tried chatbutton
was because the actual block is availabe for configuration at http://www.example.com/admin/structure/block/manage/chatbutton
NOTE:
block--chatbutton.html.twig
is recognized.