Issue #3382510: Introduce a new #config_target Form API property to make it super simple to use validation constraints on simple config forms, adopt in Media(Library)SettingsForm + BookSettingsForm
Compare changes
Files
17
Conflict: This file was modified in both the source and target branches.
Ask someone with write access to resolve it.
+ 111
− 39
@@ -5,6 +5,7 @@
@@ -5,6 +5,7 @@
@@ -17,6 +18,18 @@
@@ -17,6 +18,18 @@
@@ -60,14 +73,89 @@ public function buildForm(array $form, FormStateInterface $form_state) {
@@ -60,14 +73,89 @@ public function buildForm(array $form, FormStateInterface $form_state) {
@@ -90,9 +178,9 @@ public function validateForm(array &$form, FormStateInterface $form_state) {
@@ -90,9 +178,9 @@ public function validateForm(array &$form, FormStateInterface $form_state) {
@@ -100,7 +188,11 @@ public function validateForm(array &$form, FormStateInterface $form_state) {
@@ -100,7 +188,11 @@ public function validateForm(array &$form, FormStateInterface $form_state) {
@@ -191,45 +283,25 @@ public function submitForm(array &$form, FormStateInterface $form_state) {
@@ -191,45 +283,25 @@ public function submitForm(array &$form, FormStateInterface $form_state) {
protected static function copyFormValuesToConfig(Config $config, FormStateInterface $form_state): void {
protected static function mapConfigKeyToFormElementName(string $config_name, string $key) : string {
final protected static function defaultMapConfigKeyToFormElementName(string $config_name, string $key) : string {