77 public function __construct(FormBuilderInterface $form_builder, EntityTypeManagerInterface $entity_type_manager, ModuleHandlerInterface $module_handler, EntityManagerInterface $entity_manager,
WidgetBinderDataCompilerInterface $data_compiler) {
78 $this->formBuilder = $form_builder;
79 $this->entityTypeManager = $entity_type_manager;
80 $this->moduleHandler = $module_handler;
81 $this->entityManager = $entity_manager;
82 $this->dataCompiler = $data_compiler;
103 return $this->
render($context, $item);
110 return $this->
duplicate($context, $item, $editor_widget_id);
117 return $this->
close($context);
132 $response =
new AjaxResponse();
149 $response =
new AjaxResponse();
150 $context->
getPlugin(
'delivery_provider')->sendData($response, $this->dataCompiler->compile($context, $item));
168 $response =
new AjaxResponse();
170 $data = $this->dataCompiler->compile($context, $item);
171 $context->
getPlugin(
'delivery_provider')->sendData($response, $data);
185 $response =
new AjaxResponse();
186 $context->
getPlugin(
'delivery_provider')->close($response);
200 $form = $context->
getPlugin(
'bundle_selector');
201 return $this->formBuilder->getForm($form);
216 $form =
new ParagraphEntityForm($context, $item, $this->moduleHandler, $this->entityTypeManager, $this->entityManager, $this->dataCompiler);
217 return $this->formBuilder->getForm($form);
231 return t(
'Insert @title', [
'@title' => $context->
getSetting(
'title')]);
234 return t(
'Edit @title', [
'@title' => $context->
getSetting(
'title')]);
deliverCloseForm(CommandContextInterface $context)
getAdditionalContext($key=NULL)
deliverParagraphEditForm(CommandContextInterface $context, EditBufferItemInterface $item)
close(CommandContextInterface $context)
duplicate(CommandContextInterface $context, EditBufferItemInterface $item, $editor_widget_id)
addAdditionalContext($key, $value)
__construct(FormBuilderInterface $form_builder, EntityTypeManagerInterface $entity_type_manager, ModuleHandlerInterface $module_handler, EntityManagerInterface $entity_manager, WidgetBinderDataCompilerInterface $data_compiler)
getBundleSelectForm(CommandContextInterface $context)
navigate(CommandContextInterface $context, $contents)
getParagraphEditForm(CommandContextInterface $context, EditBufferItemInterface $item)
render(CommandContextInterface $context, EditBufferItemInterface $item)
deliverBundleSelectForm(CommandContextInterface $context)
getDialogTitle(CommandContextInterface $context)
deliverDuplicate(CommandContextInterface $context, EditBufferItemInterface $item, $editor_widget_id)
deliverRenderedParagraph(CommandContextInterface $context, EditBufferItemInterface $item)