From 4b21b16880bd4008f02a47a25bc690acc402a842 Mon Sep 17 00:00:00 2001 From: Champ Camba Date: Wed, 7 Jun 2023 18:06:09 +0800 Subject: [PATCH] Support button element for info_text field type in settings - This allows the info_text field to display a button element. Button element is used for Stripe's Connect/Disconnect functionality. The issue with anchor tag, it requires to deattach the onclick function before you can disable it. With button, you only need to add a disabled attribute to prevent the js function from triggering --- includes/admin/core/class-admin-forms.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/includes/admin/core/class-admin-forms.php b/includes/admin/core/class-admin-forms.php index 260d29a9..73a0b864 100644 --- a/includes/admin/core/class-admin-forms.php +++ b/includes/admin/core/class-admin-forms.php @@ -125,6 +125,9 @@ if ( ! class_exists( 'um\admin\core\Admin_Forms' ) ) { 'target' => array(), 'class' => array(), ), + 'button' => array( + 'class' => array(), + ), 'i' => array( 'class' => array(), ),