Commit 07f55924 authored by jrockowitz's avatar jrockowitz Committed by jrockowitz

Issue #2989232 by jrockowitz: Release 8.x-5.0-rc17

parent bde541cb
...@@ -42,7 +42,7 @@ ...@@ -42,7 +42,7 @@
/* Float toogle to the right of webform tabs */ /* Float toogle to the right of webform tabs */
.webform-tabs .webform-details-toggle-state-wrapper { .webform-tabs .webform-details-toggle-state-wrapper {
float: right float: right;
} }
@media screen and (max-width: 600px) { @media screen and (max-width: 600px) {
......
...@@ -15,13 +15,13 @@ ...@@ -15,13 +15,13 @@
} }
.webform-progress .progress-title[role="link"] { .webform-progress .progress-title[role="link"] {
color: #1976D2; color: #1976d2;
} }
.webform-progress .progress-title[role="link"]:hover, .webform-progress .progress-title[role="link"]:hover,
.webform-progress .progress-title[role="link"]:focus { .webform-progress .progress-title[role="link"]:focus {
text-decoration: underline; text-decoration: underline;
color: #2196F3; color: #2196f3;
} }
/** /**
......
...@@ -118,7 +118,7 @@ References ...@@ -118,7 +118,7 @@ References
[Git Release Notes for Drush](https://www.drupal.org/project/grn) [Git Release Notes for Drush](https://www.drupal.org/project/grn)
drush release-notes --nouser 8.x-5.0-VERSION 8.x-5.x drush release-notes --nouser 8.x-5.0-rc16 8.x-5.x
7. Tag and create a new release 7. Tag and create a new release
......
...@@ -2418,7 +2418,7 @@ function webform_update_8136() { ...@@ -2418,7 +2418,7 @@ function webform_update_8136() {
} }
/** /**
* Update #counter_* attribute.s * Update #counter_* attributes.
* *
* Replace 'X' in counter message with '%d' and * Replace 'X' in counter message with '%d' and
* move '#counter_message' to '#counter_maxiumum_message'. * move '#counter_message' to '#counter_maxiumum_message'.
......
...@@ -547,7 +547,7 @@ function _webform_preprocess_element(array &$variables, $title_parents = ['title ...@@ -547,7 +547,7 @@ function _webform_preprocess_element(array &$variables, $title_parents = ['title
'description' => $variables['description']['content'], 'description' => $variables['description']['content'],
]; ];
} }
$title =& NestedArray::getValue($variables, $title_parents); $title =& NestedArray::getValue($variables, $title_parents);
// Move #description to #help for webform admin routes. // Move #description to #help for webform admin routes.
...@@ -557,7 +557,7 @@ function _webform_preprocess_element(array &$variables, $title_parents = ['title ...@@ -557,7 +557,7 @@ function _webform_preprocess_element(array &$variables, $title_parents = ['title
_webform_preprocess_form_element_description_more($variables); _webform_preprocess_form_element_description_more($variables);
// Add help to title (aka label). // Add help to title (aka label).
_webform_preprocess_help_title($title,$element); _webform_preprocess_help_title($title, $element);
} }
/** /**
......
...@@ -17,7 +17,6 @@ use Drupal\webform\Element\WebformCodeMirror; ...@@ -17,7 +17,6 @@ use Drupal\webform\Element\WebformCodeMirror;
use Drupal\webform\Element\WebformHtmlEditor; use Drupal\webform\Element\WebformHtmlEditor;
use Drupal\webform\WebformMessageManagerInterface; use Drupal\webform\WebformMessageManagerInterface;
use Drupal\webform\WebformSubmissionInterface; use Drupal\webform\WebformSubmissionInterface;
use Drupal\webform\Utility\WebformAccessibilityHelper;
use Drupal\webform\Utility\WebformDateHelper; use Drupal\webform\Utility\WebformDateHelper;
use Drupal\webform\Utility\WebformDialogHelper; use Drupal\webform\Utility\WebformDialogHelper;
use Drupal\webform\Utility\WebformElementHelper; use Drupal\webform\Utility\WebformElementHelper;
......
...@@ -28,21 +28,20 @@ ...@@ -28,21 +28,20 @@
/** /**
* Show aria-labels. * Show aria-labels.
*/ */
[role=main] [aria-label]:after{ [role=main] [aria-label]:after {
content:"[aria-label]: " attr(aria-label); content: "[aria-label]: " attr(aria-label);
border: 2px dashed green !important; border: 2px dashed green !important;
padding: 4px !important; padding: 4px !important;
position: relative !important; position: relative !important;
font-size: 0.8em; font-size: 0.8em;
font-weight: normal; font-weight: normal;
color: green; color: green;
} }
/** /**
* Show titles. * Show titles.
*/ */
[role=main] [title]:after{ [role=main] [title]:after {
content: "[title]: " attr(title); content: "[title]: " attr(title);
border: 2px dashed green !important; border: 2px dashed green !important;
padding: 4px !important; padding: 4px !important;
......
...@@ -249,7 +249,7 @@ class WebformNodeReferencesListController extends EntityListBuilder implements C ...@@ -249,7 +249,7 @@ class WebformNodeReferencesListController extends EntityListBuilder implements C
'#type' => 'link', '#type' => 'link',
'#title' => $result_total, '#title' => $result_total,
'#attributes' => [ '#attributes' => [
'aria-label' => $this->formatPlural($result_total, '@count result for @label', '@count results for @label', ['@label' => $entity->label()]) 'aria-label' => $this->formatPlural($result_total, '@count result for @label', '@count results for @label', ['@label' => $entity->label()]),
], ],
'#url' => Url::fromRoute('entity.node.webform.results_submissions', $route_parameters), '#url' => Url::fromRoute('entity.node.webform.results_submissions', $route_parameters),
], ],
......
...@@ -46,7 +46,7 @@ class WebformNodeEntityReferenceTest extends WebformNodeTestBase { ...@@ -46,7 +46,7 @@ class WebformNodeEntityReferenceTest extends WebformNodeTestBase {
$this->drupalGet('node/1/webform/test'); $this->drupalGet('node/1/webform/test');
$this->assertNoRaw('textfield_a'); $this->assertNoRaw('textfield_a');
$this->assertRaw('textfield_b'); $this->assertRaw('textfield_b');
// Check result webform B. // Check result webform B.
$this->drupalGet('node/1/webform/results/submissions'); $this->drupalGet('node/1/webform/results/submissions');
$this->assertNoRaw('textfield_a'); $this->assertNoRaw('textfield_a');
......
...@@ -137,13 +137,13 @@ abstract class WebformUiElementFormBase extends FormBase implements WebformUiEle ...@@ -137,13 +137,13 @@ abstract class WebformUiElementFormBase extends FormBase implements WebformUiEle
* @param \Drupal\webform\WebformTokenManagerInterface $token_manager * @param \Drupal\webform\WebformTokenManagerInterface $token_manager
* The webform token manager. * The webform token manager.
*/ */
public function __construct(RendererInterface $renderer, EntityFieldManagerInterface $entity_field_manager, WebformElementManagerInterface $element_manager, WebformEntityElementsValidatorInterface $elements_validator, WebformTokenManagerInterface $token_manager) { public function __construct(RendererInterface $renderer, EntityFieldManagerInterface $entity_field_manager, WebformElementManagerInterface $element_manager, WebformEntityElementsValidatorInterface $elements_validator, WebformTokenManagerInterface $token_manager) {
$this->renderer = $renderer; $this->renderer = $renderer;
$this->entityFieldManager = $entity_field_manager; $this->entityFieldManager = $entity_field_manager;
$this->elementManager = $element_manager; $this->elementManager = $element_manager;
$this->elementsValidator = $elements_validator; $this->elementsValidator = $elements_validator;
$this->tokenManager = $token_manager; $this->tokenManager = $token_manager;
} }
/** /**
* {@inheritdoc} * {@inheritdoc}
......
...@@ -444,7 +444,7 @@ class WebformUiEntityElementsForm extends BundleEntityFormBase { ...@@ -444,7 +444,7 @@ class WebformUiEntityElementsForm extends BundleEntityFormBase {
$element_dialog_attributes = WebformDialogHelper::getOffCanvasDialogAttributes(); $element_dialog_attributes = WebformDialogHelper::getOffCanvasDialogAttributes();
$key = $element['#webform_key']; $key = $element['#webform_key'];
$title = $element['#admin_title'] ?: $element['#title']; $title = $element['#admin_title'] ?: $element['#title'];
$title = (is_array($title)) ? $this->renderer->render($title) : $title; $title = (is_array($title)) ? $this->renderer->render($title) : $title;
$plugin_id = $this->elementManager->getElementPluginId($element); $plugin_id = $this->elementManager->getElementPluginId($element);
/** @var \Drupal\webform\Plugin\WebformElementInterface $webform_element */ /** @var \Drupal\webform\Plugin\WebformElementInterface $webform_element */
...@@ -548,8 +548,8 @@ class WebformUiEntityElementsForm extends BundleEntityFormBase { ...@@ -548,8 +548,8 @@ class WebformUiEntityElementsForm extends BundleEntityFormBase {
// Add custom hash to current page's location. // Add custom hash to current page's location.
// @see Drupal.behaviors.webformAjaxLink // @see Drupal.behaviors.webformAjaxLink
'data-hash' => 'webform-tab--conditions', 'data-hash' => 'webform-tab--conditions',
'title' => $this->t('Edit @states conditional', ['@states' => implode('; ', $states)]), 'title' => $this->t('Edit @states conditional', ['@states' => implode('; ', $states)]),
'aria-label' => $this->t('Edit @states conditional', ['@states' => implode('; ', $states)]), 'aria-label' => $this->t('Edit @states conditional', ['@states' => implode('; ', $states)]),
], ],
]; ];
} }
......
...@@ -5,9 +5,6 @@ ...@@ -5,9 +5,6 @@
* Provides a simple user interface for building and maintaining webforms. * Provides a simple user interface for building and maintaining webforms.
*/ */
use Drupal\Core\Form\FormStateInterface;
use Drupal\webform\Utility\WebformDialogHelper;
/** /**
* Implements hook_entity_type_alter(). * Implements hook_entity_type_alter().
*/ */
......
...@@ -32,4 +32,5 @@ class WebformHandlerAccess { ...@@ -32,4 +32,5 @@ class WebformHandlerAccess {
} }
return $access_result->addCacheTags(['config:webform.settings']); return $access_result->addCacheTags(['config:webform.settings']);
} }
} }
...@@ -5,7 +5,6 @@ namespace Drupal\webform\Controller; ...@@ -5,7 +5,6 @@ namespace Drupal\webform\Controller;
use Drupal\Component\Render\FormattableMarkup; use Drupal\Component\Render\FormattableMarkup;
use Drupal\Core\Ajax\AjaxResponse; use Drupal\Core\Ajax\AjaxResponse;
use Drupal\Core\Ajax\HtmlCommand; use Drupal\Core\Ajax\HtmlCommand;
use Drupal\Core\Ajax\InvokeCommand;
use Drupal\Core\Controller\ControllerBase; use Drupal\Core\Controller\ControllerBase;
use Drupal\webform\Ajax\WebformAnnounceCommand; use Drupal\webform\Ajax\WebformAnnounceCommand;
use Drupal\webform\WebformSubmissionInterface; use Drupal\webform\WebformSubmissionInterface;
...@@ -81,7 +80,7 @@ class WebformSubmissionController extends ControllerBase { ...@@ -81,7 +80,7 @@ class WebformSubmissionController extends ControllerBase {
* @return \Drupal\Component\Render\FormattableMarkup * @return \Drupal\Component\Render\FormattableMarkup
* Sticky icon. * Sticky icon.
*/ */
static public function buildSticky(WebformSubmissionInterface $webform_submission) { public static function buildSticky(WebformSubmissionInterface $webform_submission) {
$t_args = ['@label' => $webform_submission->label()]; $t_args = ['@label' => $webform_submission->label()];
$args = [ $args = [
'@state' => $webform_submission->isSticky() ? 'on' : 'off', '@state' => $webform_submission->isSticky() ? 'on' : 'off',
...@@ -99,7 +98,7 @@ class WebformSubmissionController extends ControllerBase { ...@@ -99,7 +98,7 @@ class WebformSubmissionController extends ControllerBase {
* @return \Drupal\Component\Render\FormattableMarkup * @return \Drupal\Component\Render\FormattableMarkup
* Locked icon. * Locked icon.
*/ */
static public function buildLocked(WebformSubmissionInterface $webform_submission) { public static function buildLocked(WebformSubmissionInterface $webform_submission) {
$t_args = ['@label' => $webform_submission->label()]; $t_args = ['@label' => $webform_submission->label()];
$args = [ $args = [
'@state' => $webform_submission->isLocked() ? 'on' : 'off', '@state' => $webform_submission->isLocked() ? 'on' : 'off',
......
...@@ -202,7 +202,7 @@ class WebformLikert extends FormElement { ...@@ -202,7 +202,7 @@ class WebformLikert extends FormElement {
'data-likert-answers-count' => count($element['#answers']), 'data-likert-answers-count' => count($element['#answers']),
], ],
'#prefix' => '<div class="webform-likert-table-wrapper">', '#prefix' => '<div class="webform-likert-table-wrapper">',
'#suffix' => '</div>' '#suffix' => '</div>',
] + $rows; ] + $rows;
// Build table element with selected properties. // Build table element with selected properties.
......
...@@ -296,7 +296,7 @@ class WebformMultiple extends FormElement { ...@@ -296,7 +296,7 @@ class WebformMultiple extends FormElement {
* @param \Drupal\Core\Form\FormStateInterface $form_state * @param \Drupal\Core\Form\FormStateInterface $form_state
* The current state of the form. * The current state of the form.
* @param array $complete_form * @param array $complete_form
* An associative array containing the structure of the form. * An associative array containing the structure of the form.
* @param array $sub_elements * @param array $sub_elements
* The sub element. * The sub element.
* @param array $required_states * @param array $required_states
...@@ -391,7 +391,7 @@ class WebformMultiple extends FormElement { ...@@ -391,7 +391,7 @@ class WebformMultiple extends FormElement {
if ($element['#sorting']) { if ($element['#sorting']) {
$header[] = [ $header[] = [
'data' => WebformAccessibilityHelper::buildVisuallyHidden(t('Re-order')), 'data' => WebformAccessibilityHelper::buildVisuallyHidden(t('Re-order')),
'class' => ["$table_id--handle", "webform-multiple-table--handle"], 'class' => ["$table_id--handle", 'webform-multiple-table--handle'],
]; ];
} }
...@@ -400,14 +400,14 @@ class WebformMultiple extends FormElement { ...@@ -400,14 +400,14 @@ class WebformMultiple extends FormElement {
if ($element['#sorting']) { if ($element['#sorting']) {
$header[] = [ $header[] = [
'data' => ['#markup' => t('Weight')], 'data' => ['#markup' => t('Weight')],
'class' => ["$table_id--weight", "webform-multiple-table--weight"] 'class' => ["$table_id--weight", 'webform-multiple-table--weight'],
]; ];
} }
if ($element['#operations']) { if ($element['#operations']) {
$header[] = [ $header[] = [
'data' => WebformAccessibilityHelper::buildVisuallyHidden(t('Operations')), 'data' => WebformAccessibilityHelper::buildVisuallyHidden(t('Operations')),
'class' => ["$table_id--handle", "webform-multiple-table--operations"], 'class' => ["$table_id--handle", 'webform-multiple-table--operations'],
]; ];
} }
......
...@@ -64,7 +64,7 @@ class WebformTermsOfService extends Checkbox { ...@@ -64,7 +64,7 @@ class WebformTermsOfService extends Checkbox {
$element['#description']['terms'] = [ $element['#description']['terms'] = [
'#type' => 'container', '#type' => 'container',
'#attributes' => [ '#attributes' => [
'id' => $id . '--description', 'id' => $id . '--description',
'class' => ['webform-terms-of-service-details', 'js-hide'], 'class' => ['webform-terms-of-service-details', 'js-hide'],
], ],
]; ];
......
...@@ -222,7 +222,6 @@ class WebformEntitySettingsFormForm extends WebformEntitySettingsBaseForm { ...@@ -222,7 +222,6 @@ class WebformEntitySettingsFormForm extends WebformEntitySettingsBaseForm {
]; ];
} }
// Wizard settings. // Wizard settings.
$form['wizard_settings'] = [ $form['wizard_settings'] = [
'#type' => 'details', '#type' => 'details',
......
...@@ -323,7 +323,7 @@ class WebformEntitySettingsGeneralForm extends WebformEntitySettingsBaseForm { ...@@ -323,7 +323,7 @@ class WebformEntitySettingsGeneralForm extends WebformEntitySettingsBaseForm {
'data-dialog-options' => Json::encode([ 'data-dialog-options' => Json::encode([
'width' => 400, 'width' => 400,
'height' => 400, 'height' => 400,
]) ]),
], ],
]; ];
$dialog_source = $dialog_link; $dialog_source = $dialog_link;
......
...@@ -194,7 +194,7 @@ class WebformEntitySettingsSubmissionsForm extends WebformEntitySettingsBaseForm ...@@ -194,7 +194,7 @@ class WebformEntitySettingsSubmissionsForm extends WebformEntitySettingsBaseForm
$form['submission_access_denied']['token_tree_link']['#states'] = [ $form['submission_access_denied']['token_tree_link']['#states'] = [
'visible' => [ 'visible' => [
':input[name="submission_login"]' => ['checked' => TRUE], ':input[name="submission_login"]' => ['checked' => TRUE],
] ],
]; ];
} }
......
...@@ -441,7 +441,7 @@ class WebformAdminConfigElementsForm extends WebformAdminConfigBaseForm { ...@@ -441,7 +441,7 @@ class WebformAdminConfigElementsForm extends WebformAdminConfigBaseForm {
$form['types']['excluded_elements']['#header']['description']['width'] = '50%'; $form['types']['excluded_elements']['#header']['description']['width'] = '50%';
// Add warning to all password elements. // Add warning to all password elements.
foreach ($form['types']['excluded_elements']['#options'] as $element_type => &$excluded_element_option) { foreach ($form['types']['excluded_elements']['#options'] as $element_type => &$excluded_element_option) {
if (strpos($element_type,'password') !== FALSE) { if (strpos($element_type, 'password') !== FALSE) {
$excluded_element_option['description'] = [ $excluded_element_option['description'] = [
'data' => [ 'data' => [
'description' => ['#markup' => $excluded_element_option['description']], 'description' => ['#markup' => $excluded_element_option['description']],
......
...@@ -352,7 +352,7 @@ trait WebformAjaxFormTrait { ...@@ -352,7 +352,7 @@ trait WebformAjaxFormTrait {
} }
/** /**
* Set announcements * Set announcements.
* *
* @param array $announcements * @param array $announcements
* An associative array of announcements. * An associative array of announcements.
......
...@@ -208,7 +208,7 @@ class WebformResultsCustomForm extends FormBase { ...@@ -208,7 +208,7 @@ class WebformResultsCustomForm extends FormBase {
'#default_value' => $format['element_format'], '#default_value' => $format['element_format'],
]; ];
// Submission settings // Submission settings.
$form['submission'] = [ $form['submission'] = [
'#type' => 'details', '#type' => 'details',
'#title' => $this->t('Submission settings'), '#title' => $this->t('Submission settings'),
......
...@@ -111,7 +111,7 @@ element_key: 'some value' ...@@ -111,7 +111,7 @@ element_key: 'some value'
# Add ':clear' to the end token to return an empty value when the token is missing. # Add ':clear' to the end token to return an empty value when the token is missing.
title: '[webform_submission:node:title:clear]' title: '[webform_submission:node:title:clear]'
# The below example uses a token to get a field value from the current node. # The below example uses a token to get a field value from the current node.
full_name: '[webform_submission:node:field_full_name:clear]" full_name: '[webform_submission:node:field_full_name:clear]",
], ],
]; ];
......
...@@ -164,7 +164,7 @@ element_key: 'some value' ...@@ -164,7 +164,7 @@ element_key: 'some value'
# Add ':clear' to the end token to return an empty value when the token is missing. # Add ':clear' to the end token to return an empty value when the token is missing.
title: '[webform_submission:node:title:clear]' title: '[webform_submission:node:title:clear]'
# The below example uses a token to get a field value from the current node. # The below example uses a token to get a field value from the current node.
full_name: '[webform_submission:node:field_full_name:clear]" full_name: '[webform_submission:node:field_full_name:clear]",
], ],
]; ];
$element['settings']['token_tree_link'] = $token_manager->buildTreeElement(); $element['settings']['token_tree_link'] = $token_manager->buildTreeElement();
......
...@@ -33,7 +33,6 @@ use Drupal\webform\WebformSubmissionInterface; ...@@ -33,7 +33,6 @@ use Drupal\webform\WebformSubmissionInterface;
*/ */
class Address extends WebformCompositeBase { class Address extends WebformCompositeBase {
/** /**
* {@inheritdoc} * {@inheritdoc}
*/ */
......
...@@ -3,7 +3,6 @@ ...@@ -3,7 +3,6 @@
namespace Drupal\webform\Plugin\WebformElement; namespace Drupal\webform\Plugin\WebformElement;
use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Form\FormStateInterface;
use Drupal\webform\Utility\WebformElementHelper;
use Drupal\webform\WebformSubmissionInterface; use Drupal\webform\WebformSubmissionInterface;
/** /**
......
...@@ -154,7 +154,7 @@ abstract class TextBase extends WebformElementBase { ...@@ -154,7 +154,7 @@ abstract class TextBase extends WebformElementBase {
$form['validation']['counter_container']['#states'] = [ $form['validation']['counter_container']['#states'] = [
'invisible' => [ 'invisible' => [
':input[name="properties[counter_type]"]' => ['value' => ''], ':input[name="properties[counter_type]"]' => ['value' => ''],
] ],
]; ];
$form['validation']['counter_container']['counter_minimum'] = [ $form['validation']['counter_container']['counter_minimum'] = [
'#type' => 'number', '#type' => 'number',
......
...@@ -151,7 +151,7 @@ trait WebformTableTrait { ...@@ -151,7 +151,7 @@ trait WebformTableTrait {
* @param array $option * @param array $option
* A table select option. * A table select option.
* *
* @return string|\Drupal\Component\Render\MarkupInterface|NULL * @return string|\Drupal\Component\Render\MarkupInterface|null
* Table selection option title/text. * Table selection option title/text.
* *
* @see https://www.drupal.org/project/drupal/issues/2719453 * @see https://www.drupal.org/project/drupal/issues/2719453
......
...@@ -897,6 +897,7 @@ class WebformElementBase extends PluginBase implements WebformElementInterface { ...@@ -897,6 +897,7 @@ class WebformElementBase extends PluginBase implements WebformElementInterface {
} }
} }
} }
/** /**
* Replace Core's composite #pre_render with Webform's composite #pre_render. * Replace Core's composite #pre_render with Webform's composite #pre_render.
* *
......
...@@ -508,7 +508,7 @@ class EmailWebformHandler extends WebformHandlerBase implements WebformHandlerMe ...@@ -508,7 +508,7 @@ class EmailWebformHandler extends WebformHandlerBase implements WebformHandlerMe
if ($format == 'html') { if ($format == 'html') {
$form['message']['body_custom_' . $format] = [ $form['message']['body_custom_' . $format] = [
'#type' => 'webform_html_editor', '#type' => 'webform_html_editor',
'#format' => $this->configFactory->get('webform.settings')->get('html_editor.mail_format') '#format' => $this->configFactory->get('webform.settings')->get('html_editor.mail_format'),
]; ];
} }
else { else {
......
...@@ -59,22 +59,6 @@ class QueryStringWebformSourceEntity extends PluginBase implements WebformSource ...@@ -59,22 +59,6 @@ class QueryStringWebformSourceEntity extends PluginBase implements WebformSource
*/ */
protected $webformEntityReferenceManager; protected $webformEntityReferenceManager;
/**
* {@inheritdoc}
*/
public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) {
return new static(
$configuration,
$plugin_id,
$plugin_definition,
$container->get('entity_type.manager'),
$container->get('current_route_match'),
$container->get('request_stack'),
$container->get('language_manager'),
$container->get('webform.entity_reference_manager')
);
}
/** /**
* QueryStringWebformSourceEntity constructor. * QueryStringWebformSourceEntity constructor.
* *
...@@ -105,6 +89,22 @@ class QueryStringWebformSourceEntity extends PluginBase implements WebformSource ...@@ -105,6 +89,22 @@ class QueryStringWebformSourceEntity extends PluginBase implements WebformSource
$this->webformEntityReferenceManager = $webform_entity_reference_manager; $this->webformEntityReferenceManager = $webform_entity_reference_manager;
} }
/**
* {@inheritdoc}
*/
public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) {
return new static(
$configuration,
$plugin_id,
$plugin_definition,
$container->get('entity_type.manager'),
$container->get('current_route_match'),
$container->get('request_stack'),
$container->get('language_manager'),
$container->get('webform.entity_reference_manager')
);
}
/** /**
* {@inheritdoc} * {@inheritdoc}
*/ */
......
...@@ -27,18 +27,6 @@ class RouteParametersWebformSourceEntity extends PluginBase implements WebformSo ...@@ -27,18 +27,6 @@ class RouteParametersWebformSourceEntity extends PluginBase implements WebformSo
*/ */
protected $routeMatch; protected $routeMatch;
/**
* {@inheritdoc}
*/
public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) {
return new static(
$configuration,
$plugin_id,
$plugin_definition,
$container->get('current_route_match')
);
}
/** /**
* RouteParametersWebformSourceEntity constructor. * RouteParametersWebformSourceEntity constructor.
* *
...@@ -57,6 +45,18 @@ class RouteParametersWebformSourceEntity extends PluginBase implements WebformSo ...@@ -57,6 +45,18 @@ class RouteParametersWebformSourceEntity extends PluginBase implements WebformSo
$this->routeMatch = $route_match; $this->routeMatch = $route_match;
} }
/**
* {@inheritdoc}
*/
public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) {
return new static(
$configuration,
$plugin_id,
$plugin_definition,
$container->get('current_route_match')
);
}
/** /**
* {@inheritdoc} * {@inheritdoc}
*/ */
......
...@@ -8,7 +8,7 @@ namespace Drupal\webform\Utility; ...@@ -8,7 +8,7 @@ namespace Drupal\webform\Utility;
class WebformAccessibilityHelper { class WebformAccessibilityHelper {
/**