From 67f6254a17f64a0cf0e697fc6a7756c0ea852023 Mon Sep 17 00:00:00 2001 From: Sherv Date: Mon, 16 Sep 2024 15:43:43 +0300 Subject: [PATCH 01/13] Fix style issues on Entry (Edit/New) and Style pages --- css/custom_theme.css.php | 22 +++++++++-------- css/frm_admin.css | 53 ++++++++++++++++++---------------------- 2 files changed, 36 insertions(+), 39 deletions(-) diff --git a/css/custom_theme.css.php b/css/custom_theme.css.php index 6b14cfa643..f28e915be5 100644 --- a/css/custom_theme.css.php +++ b/css/custom_theme.css.php @@ -347,12 +347,12 @@ background-position-y: calc(50% + 3px); } -.with_frm_style input[disabled], -.with_frm_style select[disabled], -.with_frm_style textarea[disabled], -.with_frm_style input[readonly], -.with_frm_style select[readonly], -.with_frm_style textarea[readonly] { +.frm_forms.with_frm_style input[disabled], +.frm_forms.with_frm_style select[disabled], +.frm_forms.with_frm_style textarea[disabled], +.frm_forms.with_frm_style input[readonly], +.frm_forms.with_frm_style select[readonly], +.frm_forms.with_frm_style textarea[readonly] { background-color: var(--bg-color-disabled); color: var(--text-color-disabled); border-color: var(--border-color-disabled); @@ -866,8 +866,8 @@ border-radius:50%; } -.with_frm_style .frm_checkbox input[type=checkbox]{ - border-radius: calc(var(--border-radius) / 2); +.with_frm_style .frm_checkbox input[type=checkbox] { + border-radius: calc(var(--border-radius) / 2) !important; } .with_frm_style .frm_radio input[type=radio], @@ -895,11 +895,13 @@ .frm_forms.with_frm_style .frm_fields_container .frm_scale input[type=radio]:not([disabled]):checked, -.frm_forms.with_frm_style .frm_fields_container .frm_checkbox input[type=checkbox]:not([disabled]):checked { +.frm_forms.with_frm_style .frm_fields_container .frm_checkbox input[type=checkbox]:not([disabled]):checked, +.frm_forms .with_frm_style .frm_fields_container .frm_checkbox input[type=checkbox]:not([disabled]):checked { border-color: var(--border-color-active) !important; } -.frm_forms.with_frm_style .frm_fields_container .frm_checkbox input[type=checkbox]:not([disabled]):checked { +.frm_forms.with_frm_style .frm_fields_container .frm_checkbox input[type=checkbox]:not([disabled]):checked, +.frm_forms .with_frm_style .frm_fields_container .frm_checkbox input[type=checkbox]:not([disabled]):checked { background-color: var(--border-color-active) !important; } diff --git a/css/frm_admin.css b/css/frm_admin.css index 5ad2471fc2..e9e02bdaa0 100644 --- a/css/frm_admin.css +++ b/css/frm_admin.css @@ -1406,7 +1406,7 @@ body.frm-hidden-overflow { .post-type-frm_display.wp-core-ui .button-primary, .frm-button-primary, .wp-core-ui .button-primary.frm-button-primary, -.frm_single_entry_page .button-primary { +.frm_single_entry_page .button-primary:not(.frm-fields-item) { background-color: var(--primary-500) !important; color: #fff !important; } @@ -1468,7 +1468,7 @@ body.frm-hidden-overflow { .frm-white-body .button:not(.frm-button-primary):active, .frm-white-body .frm-button-secondary:hover, .wp-core-ui.frm-white-body .frm-button-secondary:hover, -.wp-core-ui.frm-white-body .button-secondary:hover, +.wp-core-ui.frm-white-body .button-secondary:not(.frm-fields-item):hover, .wp-core-ui.frm-white-body .button-secondary:focus, .wp-core-ui.frm-white-body .tablenav .button:hover, .frm_wrap .preview > .button:hover { @@ -3821,21 +3821,18 @@ input[type="checkbox"] { } .frm-white-body input[type="checkbox"]:checked, -.frm_wrap input[type="checkbox"]:checked, -body[class*="frm-admin"] #wpbody-content input[type="checkbox"]:checked { +.frm_wrap input[type="checkbox"]:checked { background-color: var(--primary-500); border-color: var(--primary-500) !important; } .frm-white-body input[type="checkbox"]:checked:focus, -.frm_wrap input[type="checkbox"]:checked:focus, -body[class*="frm-admin"] #wpbody-content input[type="checkbox"]:checked:focus { +.frm_wrap input[type="checkbox"]:checked:focus { border-color: var(--primary-500); } .frm-white-body input[type="checkbox"]:checked::before, -.frm_wrap input[type="checkbox"]:checked::before, -body[class*="frm-admin"] #wpbody-content input[type="checkbox"]:checked::before { +.frm_wrap input[type="checkbox"]:checked::before { content: ''; display: block; width: 100% !important; @@ -3852,19 +3849,6 @@ body[class*="frm-admin"] #wpbody-content input[type="checkbox"]:checked::before margin-right: 5px; } -.frm_single_entry_page .with_frm_style .frm_radio input[type=radio] { - margin: 5px 0; - width: 18px; - position: relative; /* override Bootstrap */ -} - -.frm_single_entry_page .with_frm_style .frm_radio input[type=radio]:before { - position: relative !important; - left: calc(50% - 6px); - top: calc(50% - 6px); - margin: 0 !important; -} - .frm_inner_field_container { margin-bottom: 10px; } @@ -4505,7 +4489,7 @@ li.frm_field_box > ul.frm_grid_container { /* Image options for Radio and Checkbox */ -.frm_image_options .frm_image_option_container { +body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) .frm_image_options .frm_image_option_container { --field-border-width: 1px; --border-color: var(--grey-300); --border-color-active: var(--primary-500); @@ -8258,19 +8242,30 @@ button.frm_choose_image_box, line-height: var(--leading); } -.frm-white-body textarea:focus, -.frm-white-body input:focus, -.frm-white-body select:focus, -.frm_wrap input:focus, -.frm_wrap select:focus, -.wp-core-ui .frm_wrap select:focus, + +.frm-white-body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) textarea:focus, +.frm-white-body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) input:focus, +.frm-white-body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) select:focus, +body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) .frm_wrap input:focus, +body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) .frm_wrap select:focus, +.wp-core-ui:not(.frm-admin-page-styles):not(.frm-admin-page-entries) .frm_wrap select:focus, #frm-form-templates-modal select:focus, .frm-btn-group .multiselect.dropdown-toggle:focus, -.frm_wrap textarea:focus { +body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) .frm_wrap textarea:focus { border-color: var(--primary-500) !important; box-shadow: none !important; } +.frm-admin-page-styles textarea:focus, +.frm-admin-page-styles input:focus, +.frm-admin-page-styles select:focus, +.frm-admin-page-entries textarea:focus, +.frm-admin-page-entries input:focus, +.frm-admin-page-entries select:focus { + border-color: var(--primary-500); + box-shadow: none; +} + #postbox-container-2 textarea, .frm_wrap textarea, .field-group textarea { From af45f803489272b083d6818dd25a1768840a852c Mon Sep 17 00:00:00 2001 From: Sherv Date: Tue, 24 Sep 2024 17:02:58 +0300 Subject: [PATCH 02/13] Update "frm-fields-item" class to "frm-button-entry-nav" --- css/frm_admin.css | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/css/frm_admin.css b/css/frm_admin.css index b7229b6196..e31e31b925 100644 --- a/css/frm_admin.css +++ b/css/frm_admin.css @@ -1406,7 +1406,7 @@ body.frm-hidden-overflow { .post-type-frm_display.wp-core-ui .button-primary, .frm-button-primary, .wp-core-ui .button-primary.frm-button-primary, -.frm_single_entry_page .button-primary:not(.frm-fields-item) { +.frm_single_entry_page .button-primary:not(.frm-button-entry-nav) { background-color: var(--primary-500) !important; color: #fff !important; } @@ -1468,7 +1468,7 @@ body.frm-hidden-overflow { .frm-white-body .button:not(.frm-button-primary):active, .frm-white-body .frm-button-secondary:hover, .wp-core-ui.frm-white-body .frm-button-secondary:hover, -.wp-core-ui.frm-white-body .button-secondary:not(.frm-fields-item):hover, +.wp-core-ui.frm-white-body .button-secondary:not(.frm-button-entry-nav):hover, .wp-core-ui.frm-white-body .button-secondary:focus, .wp-core-ui.frm-white-body .tablenav .button:hover, .frm_wrap .preview > .button:hover { From 7e5bd44cf42ce34d3cdc4c8881cef8629cc1e78a Mon Sep 17 00:00:00 2001 From: Sherv Date: Tue, 24 Sep 2024 18:58:10 +0300 Subject: [PATCH 03/13] Revert the addition of the ".frm_forms" class to ".with_frm_style". --- css/custom_theme.css.php | 33 ++++++++++++++------------------- 1 file changed, 14 insertions(+), 19 deletions(-) diff --git a/css/custom_theme.css.php b/css/custom_theme.css.php index af238d3c69..1c08d179a0 100644 --- a/css/custom_theme.css.php +++ b/css/custom_theme.css.php @@ -347,12 +347,12 @@ background-position-y: calc(50% + 3px); } -.frm_forms.with_frm_style input[disabled], -.frm_forms.with_frm_style select[disabled], -.frm_forms.with_frm_style textarea[disabled], -.frm_forms.with_frm_style input[readonly], -.frm_forms.with_frm_style select[readonly], -.frm_forms.with_frm_style textarea[readonly] { +.with_frm_style input[disabled], +.with_frm_style select[disabled], +.with_frm_style textarea[disabled], +.with_frm_style input[readonly], +.with_frm_style select[readonly], +.with_frm_style textarea[readonly] { background-color: var(--bg-color-disabled); color: var(--text-color-disabled); border-color: var(--border-color-disabled); @@ -816,15 +816,11 @@ } .with_frm_style .frm_checkbox label, -.with_frm_style .frm_radio label { - display: inline-block; - vertical-align: middle; - white-space:normal; -} - -.with_frm_style .frm_checkbox label input[type=checkbox], -.with_frm_style .frm_radio label input[type=radio] { - margin-right: 4px; +.with_frm_style .frm_radio label{ + display: flex; + align-items: center; + gap: 9px; + white-space: normal; } .with_frm_style .frm_checkbox label:not(.frm-label-disabled), @@ -834,7 +830,6 @@ .with_frm_style .vertical_radio .frm_checkbox label, .with_frm_style .vertical_radio .frm_radio label{ - display: block; width: 100%; } @@ -884,9 +879,9 @@ background-color: var(--bg-color); flex: none; display:inline-block !important; - width: 16px !important; - min-width: 16px !important; - height: 16px !important; + width: 16px; + min-width: 16px; + height: 16px; color: var(--border-color); border: 1px solid currentColor; border-color: var(--border-color); From e1ebac2c7a40a8cc56001306e91efd91149eaf9d Mon Sep 17 00:00:00 2001 From: Sherv Date: Tue, 24 Sep 2024 19:06:06 +0300 Subject: [PATCH 04/13] Update field focus selectors to target wp-admin --- css/frm_admin.css | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/css/frm_admin.css b/css/frm_admin.css index e31e31b925..a95ec5851a 100644 --- a/css/frm_admin.css +++ b/css/frm_admin.css @@ -8250,12 +8250,9 @@ body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) .frm_wrap textarea box-shadow: none !important; } -.frm-admin-page-styles textarea:focus, -.frm-admin-page-styles input:focus, -.frm-admin-page-styles select:focus, -.frm-admin-page-entries textarea:focus, -.frm-admin-page-entries input:focus, -.frm-admin-page-entries select:focus { +.wp-admin .frm_fields_container textarea:focus, +.wp-admin .frm_fields_container input:focus, +.wp-admin .frm_fields_container select:focus { border-color: var(--primary-500); box-shadow: none; } From f8d06094774e5be7e48c5e9c03b28f0b480f9070 Mon Sep 17 00:00:00 2001 From: Sherv Date: Wed, 25 Sep 2024 18:27:02 +0300 Subject: [PATCH 05/13] Revert to master --- css/custom_theme.css.php | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/css/custom_theme.css.php b/css/custom_theme.css.php index 1c08d179a0..28da06e9d1 100644 --- a/css/custom_theme.css.php +++ b/css/custom_theme.css.php @@ -816,11 +816,15 @@ } .with_frm_style .frm_checkbox label, -.with_frm_style .frm_radio label{ - display: flex; - align-items: center; - gap: 9px; - white-space: normal; +.with_frm_style .frm_radio label { + display: inline-block; + vertical-align: middle; + white-space:normal; +} + +.with_frm_style .frm_checkbox label input[type=checkbox], +.with_frm_style .frm_radio label input[type=radio] { + margin-right: 4px; } .with_frm_style .frm_checkbox label:not(.frm-label-disabled), @@ -830,6 +834,7 @@ .with_frm_style .vertical_radio .frm_checkbox label, .with_frm_style .vertical_radio .frm_radio label{ + display: block; width: 100%; } @@ -879,9 +884,9 @@ background-color: var(--bg-color); flex: none; display:inline-block !important; - width: 16px; - min-width: 16px; - height: 16px; + width: 16px !important; + min-width: 16px !important; + height: 16px !important; color: var(--border-color); border: 1px solid currentColor; border-color: var(--border-color); From fa5192ddd5c09adf6e4563f82d40e56a8e736121 Mon Sep 17 00:00:00 2001 From: Sherv Date: Mon, 25 Nov 2024 16:50:21 +0300 Subject: [PATCH 06/13] Optimze frontend CSS --- css/custom_theme.css.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/css/custom_theme.css.php b/css/custom_theme.css.php index 83021b47b4..60f1948df9 100644 --- a/css/custom_theme.css.php +++ b/css/custom_theme.css.php @@ -900,8 +900,7 @@ .frm_forms.with_frm_style .frm_fields_container .frm_scale input[type=radio]:not([disabled]):checked, -.frm_forms.with_frm_style .frm_fields_container .frm_checkbox input[type=checkbox]:not([disabled]):checked, -.frm_forms .with_frm_style .frm_fields_container .frm_checkbox input[type=checkbox]:not([disabled]):checked { +.frm_forms.with_frm_style .frm_fields_container .frm_checkbox input[type=checkbox]:not([disabled]):checked { border-color: var(--border-color-active) !important; } From 496510892dd7775ceca569553a2517b4f83b6e33 Mon Sep 17 00:00:00 2001 From: Sherv Date: Mon, 25 Nov 2024 17:07:06 +0300 Subject: [PATCH 07/13] Make the button style more specific on the single entry page --- css/frm_admin.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/css/frm_admin.css b/css/frm_admin.css index f38cbaf260..4c3176b9a7 100644 --- a/css/frm_admin.css +++ b/css/frm_admin.css @@ -1411,7 +1411,7 @@ body.frm-hidden-overflow { .post-type-frm_display.wp-core-ui .button-primary, .frm-button-primary, .wp-core-ui .button-primary.frm-button-primary, -.frm_single_entry_page .button-primary:not(.frm-button-entry-nav) { +.frm_single_entry_page #frm-publishing .button-primary { background-color: var(--primary-500) !important; color: #fff !important; } From a9a9eefe354b65fd56924a523262321d5efe63e9 Mon Sep 17 00:00:00 2001 From: Sherv Date: Mon, 25 Nov 2024 21:40:21 +0300 Subject: [PATCH 08/13] Remove "frm-button-entry-nav" selector --- css/frm_admin.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/css/frm_admin.css b/css/frm_admin.css index 4c3176b9a7..33c9564c61 100644 --- a/css/frm_admin.css +++ b/css/frm_admin.css @@ -1473,7 +1473,7 @@ body.frm-hidden-overflow { .frm-white-body .button:not(.frm-button-primary):active, .frm-white-body .frm-button-secondary:hover, .wp-core-ui.frm-white-body .frm-button-secondary:hover, -.wp-core-ui.frm-white-body .button-secondary:not(.frm-button-entry-nav):hover, +.wp-core-ui.frm-white-body .button-secondary:hover, .wp-core-ui.frm-white-body .button-secondary:focus, .wp-core-ui.frm-white-body .tablenav .button:hover, .frm_wrap .preview > .button:hover { From 805a7fa59c3b267c7f5b1092c2eccec57501a974 Mon Sep 17 00:00:00 2001 From: Sherv Date: Tue, 26 Nov 2024 18:04:58 +0300 Subject: [PATCH 09/13] Refactor template file --- classes/views/frm-entries/show.php | 26 ++++++++++++++------------ 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/classes/views/frm-entries/show.php b/classes/views/frm-entries/show.php index daf576d8f9..6252515d8c 100644 --- a/classes/views/frm-entries/show.php +++ b/classes/views/frm-entries/show.php @@ -3,18 +3,20 @@ die( 'You are not allowed to call this page directly.' ); } ?> -
+
- __( 'View Entry', 'formidable' ), - 'form' => $form, - 'hide_title' => true, - 'close' => '?page=formidable-entries&form=' . $form->id, - ) - ); - ?> +
+ __( 'View Entry', 'formidable' ), + 'form' => $form, + 'hide_title' => true, + 'close' => '?page=formidable-entries&form=' . $form->id, + ) + ); + ?> +
@@ -88,7 +90,7 @@
-
+
Date: Tue, 26 Nov 2024 18:05:13 +0300 Subject: [PATCH 10/13] Fix styles --- css/custom_theme.css.php | 3 +-- css/frm_admin.css | 8 ++++---- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/css/custom_theme.css.php b/css/custom_theme.css.php index 60f1948df9..72ae325b4b 100644 --- a/css/custom_theme.css.php +++ b/css/custom_theme.css.php @@ -904,8 +904,7 @@ border-color: var(--border-color-active) !important; } -.frm_forms.with_frm_style .frm_fields_container .frm_checkbox input[type=checkbox]:not([disabled]):checked, -.frm_forms .with_frm_style .frm_fields_container .frm_checkbox input[type=checkbox]:not([disabled]):checked { +.frm_forms.with_frm_style .frm_fields_container .frm_checkbox input[type=checkbox]:not([disabled]):checked { background-color: var(--border-color-active) !important; } diff --git a/css/frm_admin.css b/css/frm_admin.css index 33c9564c61..0fc49449be 100644 --- a/css/frm_admin.css +++ b/css/frm_admin.css @@ -8229,12 +8229,12 @@ button.frm_choose_image_box, .frm-white-body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) textarea:focus, .frm-white-body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) input:focus, .frm-white-body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) select:focus, -body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) .frm_wrap input:focus, -body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) .frm_wrap select:focus, -.wp-core-ui:not(.frm-admin-page-styles):not(.frm-admin-page-entries) .frm_wrap select:focus, +.frm_wrap input:focus, +.frm_wrap select:focus, +.wp-core-ui .frm_wrap select:focus, #frm-form-templates-modal select:focus, .frm-btn-group .multiselect.dropdown-toggle:focus, -body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) .frm_wrap textarea:focus { +.frm_wrap textarea:focus { border-color: var(--primary-500) !important; box-shadow: none !important; } From 3a26bcace5801f97a6dea672441d9746605efbe3 Mon Sep 17 00:00:00 2001 From: Sherv Date: Wed, 27 Nov 2024 11:54:07 +0300 Subject: [PATCH 11/13] Revert show template --- classes/views/frm-entries/show.php | 26 ++++++++++++-------------- 1 file changed, 12 insertions(+), 14 deletions(-) diff --git a/classes/views/frm-entries/show.php b/classes/views/frm-entries/show.php index 6252515d8c..daf576d8f9 100644 --- a/classes/views/frm-entries/show.php +++ b/classes/views/frm-entries/show.php @@ -3,20 +3,18 @@ die( 'You are not allowed to call this page directly.' ); } ?> -
+
-
- __( 'View Entry', 'formidable' ), - 'form' => $form, - 'hide_title' => true, - 'close' => '?page=formidable-entries&form=' . $form->id, - ) - ); - ?> -
+ __( 'View Entry', 'formidable' ), + 'form' => $form, + 'hide_title' => true, + 'close' => '?page=formidable-entries&form=' . $form->id, + ) + ); + ?>
@@ -90,7 +88,7 @@
-
+
Date: Wed, 27 Nov 2024 12:04:28 +0300 Subject: [PATCH 12/13] Add a comment for clarification --- css/frm_admin.css | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/css/frm_admin.css b/css/frm_admin.css index 0fc49449be..d14895c630 100644 --- a/css/frm_admin.css +++ b/css/frm_admin.css @@ -8225,7 +8225,6 @@ button.frm_choose_image_box, line-height: var(--leading); } - .frm-white-body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) textarea:focus, .frm-white-body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) input:focus, .frm-white-body:not(.frm-admin-page-styles):not(.frm-admin-page-entries) select:focus, @@ -8239,6 +8238,10 @@ button.frm_choose_image_box, box-shadow: none !important; } +/* +Pages like Entries and Styles need the border-color and box-shadow properties without the !important flag. +To achieve this, we exclude them above and duplicate these rules specifically for those pages without using !important. +*/ .wp-admin .frm_fields_container textarea:focus, .wp-admin .frm_fields_container input:focus, .wp-admin .frm_fields_container select:focus { From cd5bc36b32fa3eb6360efa01011b92849f93a442 Mon Sep 17 00:00:00 2001 From: Sherv Date: Mon, 13 Jan 2025 15:12:14 +0300 Subject: [PATCH 13/13] Fix checkbox checked styles --- css/frm_admin.css | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/css/frm_admin.css b/css/frm_admin.css index 4221a8c243..b3fd8f986f 100644 --- a/css/frm_admin.css +++ b/css/frm_admin.css @@ -3854,13 +3854,13 @@ input[type="checkbox"] { .frm-white-body input[type="checkbox"]:checked, .frm_wrap input[type="checkbox"]:checked { - background-color: var(--primary-500); - border-color: var(--primary-500) !important; + background-color: var(--border-color-active, var(--primary-500)) !important; + border-color: var(--border-color-active, var(--primary-500)) !important; } .frm-white-body input[type="checkbox"]:checked:focus, .frm_wrap input[type="checkbox"]:checked:focus { - border-color: var(--primary-500); + border-color: var(--border-color-active, var(--primary-500)); } .frm-white-body input[type="checkbox"]:checked::before, @@ -8890,7 +8890,6 @@ Responsive Design .frm_wrap input[type="checkbox"]:checked::before { width: 1.2rem; height: 1.2rem; - margin: 0.125rem; } }