diff --git a/assets/src/css/admin/settings.scss b/assets/src/css/admin/settings.scss
index b2d1a14945..2d2af68567 100644
--- a/assets/src/css/admin/settings.scss
+++ b/assets/src/css/admin/settings.scss
@@ -383,6 +383,89 @@ div.give-field-description {
}
}
+.give_option_based_form_editor_notice {
+ display: flex;
+ margin: -2rem 0 0.5rem 0;
+ gap: 0.3rem;
+ padding: 0.5rem;
+ background-color: #fffaf2;
+ border-radius: 4px;
+ border: 1px solid #f29718;
+ border-left-width: 4px;
+ font-size: 0.875rem;
+ font-weight: 500;
+ color: #1a0f00;
+ line-height: 1.25rem;
+ max-width: 60rem;
+ width: 100%;
+
+ svg {
+ margin: 0.4rem 0.3rem;
+ height: 1.25rem;
+ width: 1.25rem;
+ }
+}
+
+.give-setting-tab-body-general,
+.give-setting-tab-body-display,
+.give-settings-advanced-tab {
+ label {
+ display: flex;
+ position: relative;
+
+ .give-settings-section-group-helper {
+ padding-left: 0.2rem;
+ --popout-display: none;
+ display: flex;
+ cursor: help;
+
+ img {
+ max-width: 18.9px;
+ }
+
+ &:hover {
+ --popout-display: block;
+ }
+
+ &__popout {
+ background-color: #fff;
+ border: 1px solid #e6e6e6;
+ border-radius: 4px;
+ box-shadow: 0 4px 8px 0 #0000000D;
+ color: #404040;
+ display: var(--popout-display, none);
+ left: 100%;
+ overflow: hidden;
+ position: absolute;
+ top: 0;
+ transform: translateX(10px);
+ z-index: 9999;
+
+ img {
+ max-width: initial;
+ display: block;
+ }
+
+ h5 {
+ font-size: 0.875rem;
+ font-weight: 700;
+ line-height: 1.5;
+ margin: 0;
+ padding: 1rem 1.5rem 0.5rem;
+ }
+
+ p {
+ font-size: 0.75rem;
+ font-weight: 500;
+ line-height: 1.5;
+ margin: 0;
+ padding: 0 1.5rem 1.5rem;
+ }
+ }
+ }
+ }
+}
+
.give-payment-gateways-settings {
&.give-settings-section-content {
.give-settings-section-group-menu {
@@ -917,7 +1000,6 @@ a.give-delete {
}
img {
- object-fit: contain;
width: 100%;
}
diff --git a/give.php b/give.php
index 0761287a59..3cadbc00b9 100644
--- a/give.php
+++ b/give.php
@@ -242,7 +242,8 @@ final class Give
Give\BetaFeatures\ServiceProvider::class,
Give\FormTaxonomies\ServiceProvider::class,
Give\DonationSpam\ServiceProvider::class,
- Give\Settings\ServiceProvider::class
+ Give\Settings\ServiceProvider::class,
+ Give\FeatureFlags\OptionBasedFormEditor\ServiceProvider::class,
];
/**
diff --git a/includes/admin/class-admin-settings.php b/includes/admin/class-admin-settings.php
index 1d24c30b27..cc73c84442 100644
--- a/includes/admin/class-admin-settings.php
+++ b/includes/admin/class-admin-settings.php
@@ -949,7 +949,9 @@ class="give-input-field
>
-
+
|
|
+ is_role( 'give_donor' ) ) && ! empty( $give_donor ) ? 'give_donor' : 'subscriber' );
@@ -366,9 +414,41 @@ public function sanitize_option_donor_default_user_role($value) {
}
}
}
+
return $value;
}
- }
+
+ /**
+ * @unreleased
+ */
+ public function _render_give_based_form_editor_notice($field, $value)
+ {
+ if (OptionBasedFormEditor::isEnabled()) {
+ ?>
+