Skip to content
Snippets Groups Projects
Commit 353dbe61 authored by Jesus Manuel Olivas's avatar Jesus Manuel Olivas
Browse files

:bug: Issue #3440521: Add paragraph open external page

parent 94893d98
No related branches found
No related tags found
1 merge request!2🐛 Issue #3440521: Add paragraph open external page
......@@ -36,7 +36,6 @@ function visual_editor_paragraphs_paragraphs_widget_actions_alter(
}
$entity = $context['items']->get($delta)->entity;
if (!$entity) {
$widget_actions[$key]['#access'] = FALSE;
continue;
}
......@@ -44,10 +43,6 @@ function visual_editor_paragraphs_paragraphs_widget_actions_alter(
$widget_actions[$key]['edit_button']['#attributes']['data-visual-editor-action'] = 'edit';
$widget_actions[$key]['edit_button']['#attributes']['data-visual-editor-storage'] = 'paragraph';
}
// @todo Implement duplicate button.
if ($key == 'dropdown_actions') {
$widget_actions[$key]['duplicate_button']['#access'] = FALSE;
}
}
}
......@@ -126,9 +126,7 @@ class NodeEditForm extends NodeForm {
$bundles = array_keys($this->entityTypeBundleInfo->getBundleInfo('paragraph'));
foreach ($fields as $fieldName => $field) {
if ($field->getType() === 'entity_reference_revisions') {
$form[$fieldName]['widget']['header_actions']['#access'] = FALSE;
foreach ($bundles as $bundle) {
$form[$fieldName]['widget']['add_more']['operations']['#links']['add_more_button_' . $bundle]['title']['#ajax'] = NULL;
$form[$fieldName]['widget']['add_more']['operations']['#links']['add_more_button_' . $bundle]['title']['#attributes']['data-visual-editor-uuid'] = $node->uuid();
$form[$fieldName]['widget']['add_more']['operations']['#links']['add_more_button_' . $bundle]['title']['#attributes']['data-visual-editor-action'] = 'add';
$form[$fieldName]['widget']['add_more']['operations']['#links']['add_more_button_' . $bundle]['title']['#attributes']['data-visual-editor-storage'] = 'paragraph';
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment