diff --git a/assets/css/admin/forms.css b/assets/css/admin/forms.css index 7be89ece..ca663923 100644 --- a/assets/css/admin/forms.css +++ b/assets/css/admin/forms.css @@ -1,9 +1,6 @@ .um-form-table .um-forms-line[data-conditional] { display: none; } -.um-form-table .um-forms-line[data-field_type="checkbox"] td label, .um-form-table .um-forms-line[data-field_type="same_page_update"] td label { - font-style: italic; } - .um-form-table .um-forms-line label .um-req { color: #a00; margin: 0 0 0 3px; @@ -68,10 +65,6 @@ display: block; margin: 0 0 5px 0; } -.um-form-table .description { - font-style: italic; - clear: both; } - .um_admin_fonticon_wrapper { display: flex; flex-direction: row; diff --git a/assets/css/admin/forms.min.css b/assets/css/admin/forms.min.css index 8a7f8bb7..5ecd52a8 100644 --- a/assets/css/admin/forms.min.css +++ b/assets/css/admin/forms.min.css @@ -1 +1 @@ -.um-form-table .um-forms-line[data-conditional]{display:none}.um-form-table .um-forms-line[data-field_type=checkbox] td label,.um-form-table .um-forms-line[data-field_type=same_page_update] td label{font-style:italic}.um-form-table .um-forms-line label .um-req{color:#a00;margin:0 0 0 3px;font-weight:400}.um-form-table .um-forms-line .um-text-delete{color:#a00;float:left}.um-form-table .um-forms-line .um-text-delete:hover{color:red}.um-form-table .um-forms-line .um-multi-text-add-option{margin-bottom:14px}.um-form-table .um-forms-line .icon_preview{display:none;max-width:200px;max-height:200px;padding:5px;cursor:pointer;border:1px solid #e3e3e3;background:#f7f7f7;border-radius:3px;height:auto;width:auto!important}.um-form-table .um-forms-line td .um-same-page-update-wrapper{display:none;margin:7px 0 0 0}.um-form-table .um-forms-line td .um-same-page-update-wrapper input.um-admin-form-same-page-update{margin:7px 0 0 0}.um-form-table .um-forms-line td .um-same-page-update-wrapper .upgrade_log{margin:7px 0 0 0;width:100%;height:150px;overflow:auto;border:1px solid #a1a1a1}.um-form-table .um-forms-line[data-field_type=same_page_update]{vertical-align:baseline}.um-form-table .um-forms-line[data-field_type=same_page_update] td,.um-form-table .um-forms-line[data-field_type=same_page_update] th{vertical-align:baseline}.um-form-table.um-third-column .um-forms-line th{width:33%}.um-form-table.um-half-column .um-forms-line th{width:50%}.um-form-table.um-two-thirds-column .um-forms-line th{width:83%}.um-form-table.um-top-label .um-forms-line td{padding:0 0 15px 0}.um-form-table.um-top-label .um-forms-line td label{margin:0 0 5px 0;display:inline-block}.um-form-table.um-top-label .um-forms-line[data-field_type=icon] td label{width:100%;display:block;margin:0 0 5px 0}.um-form-table .description{font-style:italic;clear:both}.um_admin_fonticon_wrapper{display:flex;flex-direction:row;justify-content:flex-start;align-items:center;flex-wrap:nowrap}.um_admin_fonticon_wrapper .um-admin-icon-value{line-height:1}.um_admin_fonticon_wrapper .um-admin-icon-value i{top:0}input[type=date].um-forms-field,input[type=number].um-forms-field,input[type=password].um-forms-field,input[type=text].um-forms-field,input[type=time].um-forms-field,input[type=url].um-forms-field,select.um-forms-field,textarea.um-forms-field{box-sizing:border-box}input[type=date].um-forms-field.um-long-field,input[type=number].um-forms-field.um-long-field,input[type=password].um-forms-field.um-long-field,input[type=text].um-forms-field.um-long-field,input[type=time].um-forms-field.um-long-field,input[type=url].um-forms-field.um-long-field,select.um-forms-field.um-long-field,textarea.um-forms-field.um-long-field{width:100%!important}input[type=date].um-forms-field.um-medium-field,input[type=number].um-forms-field.um-medium-field,input[type=password].um-forms-field.um-medium-field,input[type=text].um-forms-field.um-medium-field,input[type=time].um-forms-field.um-medium-field,input[type=url].um-forms-field.um-medium-field,select.um-forms-field.um-medium-field,textarea.um-forms-field.um-medium-field{width:50%!important}input[type=date].um-forms-field.um-small-field,input[type=number].um-forms-field.um-small-field,input[type=password].um-forms-field.um-small-field,input[type=text].um-forms-field.um-small-field,input[type=time].um-forms-field.um-small-field,input[type=url].um-forms-field.um-small-field,select.um-forms-field.um-small-field,textarea.um-forms-field.um-small-field{width:25%!important}input[type=number].um-forms-field{padding-right:0}.um-md-default-filters-list,.um-multi-selects-list,.um-multi-text-list{float:left;width:100%;margin:0 0 10px 0}.um-hidden-md-default-filters,.um-hidden-multi-selects,.um-hidden-multi-text{display:none!important}.um-md-default-filters-option-line{float:left;width:100%;clear:both;border-bottom:1px solid #eee;padding:0 0 5px 0;margin:5px 0 0 0}.um-md-default-filters-option-line .um-field-wrapper{float:left;width:calc(100% - 60px);line-height:30px;box-sizing:border-box}.um-md-default-filters-option-line .um-field-wrapper2{float:left;width:calc(100% - 60px);line-height:30px;box-sizing:border-box}.um-md-default-filters-option-line .um-field-wrapper2.um{margin:5px 0 0 0}.um-md-default-filters-option-line .um-field-wrapper2 .ui-slider-range.ui-widget-header{background:#44b0ec;border:1px solid #44b0ec!important;margin-top:-1px}.um-md-default-filters-option-line .um-field-wrapper2 select{width:100%;float:left}.um-md-default-filters-option-line .um-field-wrapper2 input{width:100%;float:left}.um-md-default-filters-option-line .um-field-wrapper2 input.um-datepicker-filter,.um-md-default-filters-option-line .um-field-wrapper2 input.um-timepicker-filter{width:calc(50% - 7px)!important;float:left}.um-md-default-filters-option-line .um-field-wrapper2 input.um-datepicker-filter:first-child,.um-md-default-filters-option-line .um-field-wrapper2 input.um-timepicker-filter:first-child{margin-right:11px}.um-md-default-filters-option-line .um-field-wrapper2 .um-slider{margin:5px 9px 0 9px;width:calc(100% - 18px);box-sizing:border-box;display:block}.um-md-default-filters-option-line .um-field-control{float:left;width:60px;line-height:30px;padding:0 10px;box-sizing:border-box}.um-multi-selects-option-line{float:left;width:100%;padding:0;clear:both;margin:0 0 5px 0}.um-multi-selects-option-line.um-admin-drag-fld{display:flex;flex-direction:row;justify-content:flex-start;align-items:center;flex-wrap:nowrap;background:0 0;border:none}.um-multi-selects-option-line.um-admin-drag-fld .um-field-wrapper{width:calc(100% - 90px)}.um-multi-selects-option-line.um-admin-drag-fld .um-field-icon{float:left;width:20px;text-align:left;line-height:30px}.um-multi-selects-option-line .um-field-wrapper{float:left;width:calc(100% - 60px);line-height:30px;box-sizing:border-box}.um-multi-selects-option-line .um-field-wrapper.um-custom-order-fields{margin:5px 0 0 0}.um-multi-selects-option-line .um-field-wrapper.um-custom-order-fields label{float:left;width:100%;line-height:30px;box-sizing:border-box;margin:0!important;padding:0!important;font-weight:700;display:flex;flex-direction:row;justify-content:space-beetween;align-items:baseline;flex-wrap:nowrap}.um-multi-selects-option-line .um-field-wrapper.um-custom-order-fields label input[type=text],.um-multi-selects-option-line .um-field-wrapper.um-custom-order-fields label select{width:auto;display:inline;font-weight:400;max-width:70%;flex:.9}.um-multi-selects-option-line .um-field-wrapper input,.um-multi-selects-option-line .um-field-wrapper select{float:left;width:100%;margin:0}.um-multi-selects-option-line .um-field-control{float:left;width:60px;line-height:30px;padding:0 10px;box-sizing:border-box}.um-multi-text-option-line{float:left;width:100%;padding:0;clear:both;margin:0 0 5px 0}.um-multi-text-option-line .um-field-wrapper{float:left;width:calc(100% - 90px);line-height:30px;box-sizing:border-box}.um-multi-text-option-line .um-field-wrapper input,.um-multi-text-option-line .um-field-wrapper select{float:left;width:100%;margin:0}.um-multi-text-option-line .um-field-control{float:left;width:60px;line-height:30px;padding:0 10px;box-sizing:border-box}.um-form-fields-section{float:left;clear:none;margin:0;padding:0 10px 0 0;box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box}.um-form-fields-section label{float:left;width:100%;margin:0;padding:0}.um-form-fields-section label input{float:left;margin-top:0}.um-form-fields-section label span{float:left;width:calc(100% - 20px)}@media screen and (max-width:782px){input[type=text].um-forms-field.um-medium-field,select.um-forms-field.um-medium-field,textarea.um-forms-field.um-medium-field{width:100%!important}input[type=text].um-forms-field.um-small-field,select.um-forms-field.um-small-field,textarea.um-forms-field.um-small-field{width:50%!important}.um-form-fields-section{width:100%!important}.um-admin-metabox .um-form-fields-section label{line-height:22px!important;margin:0 0 12px 0!important}.um-admin-metabox .um-form-fields-section label span{width:calc(100% - 30px)}.um-multi-selects-option-line,.um-multi-text-option-line{margin:0 0 6px 0}.um-forms-line label{float:left;width:100%}.um-form-table.um-half-column .um-forms-line th,.um-form-table.um-third-column .um-forms-line th,.um-form-table.um-two-thirds-column .um-forms-line th{float:left;width:100%;margin-bottom:5px}.um-form-table.um-half-column .um-forms-line th label,.um-form-table.um-third-column .um-forms-line th label,.um-form-table.um-two-thirds-column .um-forms-line th label{float:left;width:100%}.um-form-table.um-half-column .um-forms-line td,.um-form-table.um-third-column .um-forms-line td,.um-form-table.um-two-thirds-column .um-forms-line td{float:left;width:100%}}.um-sortable-items-field .um-sortable-item{cursor:move!important;padding:5px;box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;border:1px solid #7e8993;border-radius:4px;-moz-border-radius:4px;background:#fff;height:42px;line-height:28px;display:flex;flex-direction:row;justify-content:flex-start;align-items:center;flex-wrap:nowrap}.um-sortable-items-field .um-sortable-item.um-hidden-item{display:none}.um-sortable-items-field .um-sortable-item .um-field-icon{width:20px;text-align:left;margin:0 10px 0 0}.wp-picker-container input.wp-color-picker[type=text]{width:68px!important;float:left!important;padding:2px 4px!important;border-width:1px!important}span.um-admin-icon-value{margin:0 10px;font-size:13px}span.um-admin-icon-value i{font-size:28px;color:#0085ba;position:relative;top:5px}span.um-admin-icon-clear{display:none;cursor:pointer;position:relative;color:#ccc}span.um-admin-icon-clear.show{display:inline-block}span.um-admin-icon-clear:hover{color:#777}span.um-admin-icon-clear i{font-size:20px;vertical-align:middle} \ No newline at end of file +.um-form-table .um-forms-line[data-conditional]{display:none}.um-form-table .um-forms-line label .um-req{color:#a00;margin:0 0 0 3px;font-weight:400}.um-form-table .um-forms-line .um-text-delete{color:#a00;float:left}.um-form-table .um-forms-line .um-text-delete:hover{color:red}.um-form-table .um-forms-line .um-multi-text-add-option{margin-bottom:14px}.um-form-table .um-forms-line .icon_preview{display:none;max-width:200px;max-height:200px;padding:5px;cursor:pointer;border:1px solid #e3e3e3;background:#f7f7f7;border-radius:3px;height:auto;width:auto!important}.um-form-table .um-forms-line td .um-same-page-update-wrapper{display:none;margin:7px 0 0 0}.um-form-table .um-forms-line td .um-same-page-update-wrapper input.um-admin-form-same-page-update{margin:7px 0 0 0}.um-form-table .um-forms-line td .um-same-page-update-wrapper .upgrade_log{margin:7px 0 0 0;width:100%;height:150px;overflow:auto;border:1px solid #a1a1a1}.um-form-table .um-forms-line[data-field_type=same_page_update]{vertical-align:baseline}.um-form-table .um-forms-line[data-field_type=same_page_update] td,.um-form-table .um-forms-line[data-field_type=same_page_update] th{vertical-align:baseline}.um-form-table.um-third-column .um-forms-line th{width:33%}.um-form-table.um-half-column .um-forms-line th{width:50%}.um-form-table.um-two-thirds-column .um-forms-line th{width:83%}.um-form-table.um-top-label .um-forms-line td{padding:0 0 15px 0}.um-form-table.um-top-label .um-forms-line td label{margin:0 0 5px 0;display:inline-block}.um-form-table.um-top-label .um-forms-line[data-field_type=icon] td label{width:100%;display:block;margin:0 0 5px 0}.um_admin_fonticon_wrapper{display:flex;flex-direction:row;justify-content:flex-start;align-items:center;flex-wrap:nowrap}.um_admin_fonticon_wrapper .um-admin-icon-value{line-height:1}.um_admin_fonticon_wrapper .um-admin-icon-value i{top:0}input[type=date].um-forms-field,input[type=number].um-forms-field,input[type=password].um-forms-field,input[type=text].um-forms-field,input[type=time].um-forms-field,input[type=url].um-forms-field,select.um-forms-field,textarea.um-forms-field{box-sizing:border-box}input[type=date].um-forms-field.um-long-field,input[type=number].um-forms-field.um-long-field,input[type=password].um-forms-field.um-long-field,input[type=text].um-forms-field.um-long-field,input[type=time].um-forms-field.um-long-field,input[type=url].um-forms-field.um-long-field,select.um-forms-field.um-long-field,textarea.um-forms-field.um-long-field{width:100%!important}input[type=date].um-forms-field.um-medium-field,input[type=number].um-forms-field.um-medium-field,input[type=password].um-forms-field.um-medium-field,input[type=text].um-forms-field.um-medium-field,input[type=time].um-forms-field.um-medium-field,input[type=url].um-forms-field.um-medium-field,select.um-forms-field.um-medium-field,textarea.um-forms-field.um-medium-field{width:50%!important}input[type=date].um-forms-field.um-small-field,input[type=number].um-forms-field.um-small-field,input[type=password].um-forms-field.um-small-field,input[type=text].um-forms-field.um-small-field,input[type=time].um-forms-field.um-small-field,input[type=url].um-forms-field.um-small-field,select.um-forms-field.um-small-field,textarea.um-forms-field.um-small-field{width:25%!important}input[type=number].um-forms-field{padding-right:0}.um-md-default-filters-list,.um-multi-selects-list,.um-multi-text-list{float:left;width:100%;margin:0 0 10px 0}.um-hidden-md-default-filters,.um-hidden-multi-selects,.um-hidden-multi-text{display:none!important}.um-md-default-filters-option-line{float:left;width:100%;clear:both;border-bottom:1px solid #eee;padding:0 0 5px 0;margin:5px 0 0 0}.um-md-default-filters-option-line .um-field-wrapper{float:left;width:calc(100% - 60px);line-height:30px;box-sizing:border-box}.um-md-default-filters-option-line .um-field-wrapper2{float:left;width:calc(100% - 60px);line-height:30px;box-sizing:border-box}.um-md-default-filters-option-line .um-field-wrapper2.um{margin:5px 0 0 0}.um-md-default-filters-option-line .um-field-wrapper2 .ui-slider-range.ui-widget-header{background:#44b0ec;border:1px solid #44b0ec!important;margin-top:-1px}.um-md-default-filters-option-line .um-field-wrapper2 select{width:100%;float:left}.um-md-default-filters-option-line .um-field-wrapper2 input{width:100%;float:left}.um-md-default-filters-option-line .um-field-wrapper2 input.um-datepicker-filter,.um-md-default-filters-option-line .um-field-wrapper2 input.um-timepicker-filter{width:calc(50% - 7px)!important;float:left}.um-md-default-filters-option-line .um-field-wrapper2 input.um-datepicker-filter:first-child,.um-md-default-filters-option-line .um-field-wrapper2 input.um-timepicker-filter:first-child{margin-right:11px}.um-md-default-filters-option-line .um-field-wrapper2 .um-slider{margin:5px 9px 0 9px;width:calc(100% - 18px);box-sizing:border-box;display:block}.um-md-default-filters-option-line .um-field-control{float:left;width:60px;line-height:30px;padding:0 10px;box-sizing:border-box}.um-multi-selects-option-line{float:left;width:100%;padding:0;clear:both;margin:0 0 5px 0}.um-multi-selects-option-line.um-admin-drag-fld{display:flex;flex-direction:row;justify-content:flex-start;align-items:center;flex-wrap:nowrap;background:0 0;border:none}.um-multi-selects-option-line.um-admin-drag-fld .um-field-wrapper{width:calc(100% - 90px)}.um-multi-selects-option-line.um-admin-drag-fld .um-field-icon{float:left;width:20px;text-align:left;line-height:30px}.um-multi-selects-option-line .um-field-wrapper{float:left;width:calc(100% - 60px);line-height:30px;box-sizing:border-box}.um-multi-selects-option-line .um-field-wrapper.um-custom-order-fields{margin:5px 0 0 0}.um-multi-selects-option-line .um-field-wrapper.um-custom-order-fields label{float:left;width:100%;line-height:30px;box-sizing:border-box;margin:0!important;padding:0!important;font-weight:700;display:flex;flex-direction:row;justify-content:space-beetween;align-items:baseline;flex-wrap:nowrap}.um-multi-selects-option-line .um-field-wrapper.um-custom-order-fields label input[type=text],.um-multi-selects-option-line .um-field-wrapper.um-custom-order-fields label select{width:auto;display:inline;font-weight:400;max-width:70%;flex:.9}.um-multi-selects-option-line .um-field-wrapper input,.um-multi-selects-option-line .um-field-wrapper select{float:left;width:100%;margin:0}.um-multi-selects-option-line .um-field-control{float:left;width:60px;line-height:30px;padding:0 10px;box-sizing:border-box}.um-multi-text-option-line{float:left;width:100%;padding:0;clear:both;margin:0 0 5px 0}.um-multi-text-option-line .um-field-wrapper{float:left;width:calc(100% - 90px);line-height:30px;box-sizing:border-box}.um-multi-text-option-line .um-field-wrapper input,.um-multi-text-option-line .um-field-wrapper select{float:left;width:100%;margin:0}.um-multi-text-option-line .um-field-control{float:left;width:60px;line-height:30px;padding:0 10px;box-sizing:border-box}.um-form-fields-section{float:left;clear:none;margin:0;padding:0 10px 0 0;box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box}.um-form-fields-section label{float:left;width:100%;margin:0;padding:0}.um-form-fields-section label input{float:left;margin-top:0}.um-form-fields-section label span{float:left;width:calc(100% - 20px)}@media screen and (max-width:782px){input[type=text].um-forms-field.um-medium-field,select.um-forms-field.um-medium-field,textarea.um-forms-field.um-medium-field{width:100%!important}input[type=text].um-forms-field.um-small-field,select.um-forms-field.um-small-field,textarea.um-forms-field.um-small-field{width:50%!important}.um-form-fields-section{width:100%!important}.um-admin-metabox .um-form-fields-section label{line-height:22px!important;margin:0 0 12px 0!important}.um-admin-metabox .um-form-fields-section label span{width:calc(100% - 30px)}.um-multi-selects-option-line,.um-multi-text-option-line{margin:0 0 6px 0}.um-forms-line label{float:left;width:100%}.um-form-table.um-half-column .um-forms-line th,.um-form-table.um-third-column .um-forms-line th,.um-form-table.um-two-thirds-column .um-forms-line th{float:left;width:100%;margin-bottom:5px}.um-form-table.um-half-column .um-forms-line th label,.um-form-table.um-third-column .um-forms-line th label,.um-form-table.um-two-thirds-column .um-forms-line th label{float:left;width:100%}.um-form-table.um-half-column .um-forms-line td,.um-form-table.um-third-column .um-forms-line td,.um-form-table.um-two-thirds-column .um-forms-line td{float:left;width:100%}}.um-sortable-items-field .um-sortable-item{cursor:move!important;padding:5px;box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;border:1px solid #7e8993;border-radius:4px;-moz-border-radius:4px;background:#fff;height:42px;line-height:28px;display:flex;flex-direction:row;justify-content:flex-start;align-items:center;flex-wrap:nowrap}.um-sortable-items-field .um-sortable-item.um-hidden-item{display:none}.um-sortable-items-field .um-sortable-item .um-field-icon{width:20px;text-align:left;margin:0 10px 0 0}.wp-picker-container input.wp-color-picker[type=text]{width:68px!important;float:left!important;padding:2px 4px!important;border-width:1px!important}span.um-admin-icon-value{margin:0 10px;font-size:13px}span.um-admin-icon-value i{font-size:28px;color:#0085ba;position:relative;top:5px}span.um-admin-icon-clear{display:none;cursor:pointer;position:relative;color:#ccc}span.um-admin-icon-clear.show{display:inline-block}span.um-admin-icon-clear:hover{color:#777}span.um-admin-icon-clear i{font-size:20px;vertical-align:middle} \ No newline at end of file diff --git a/assets/css/admin/forms.sass b/assets/css/admin/forms.sass index 1ef1d121..03bab099 100644 --- a/assets/css/admin/forms.sass +++ b/assets/css/admin/forms.sass @@ -7,11 +7,6 @@ .#{$prefix}forms-line &[data-conditional] display: none - &[data-field_type="checkbox"], - &[data-field_type="same_page_update"] - td - label - font-style: italic label .#{$prefix}req color: $required-asterisk @@ -96,9 +91,9 @@ width: 100% display: block margin: 0 0 5px 0 - .description - font-style: italic - clear: both + //.description + // font-style: italic + // clear: both .um_admin_fonticon_wrapper +flex( row, flex-start, center, nowrap ) diff --git a/assets/css/admin/settings.css b/assets/css/admin/settings.css index ffb296f5..831fc4c6 100644 --- a/assets/css/admin/settings.css +++ b/assets/css/admin/settings.css @@ -26,8 +26,8 @@ width: 25%; } .column-configure { - width: 60px; - text-align: center; } + width: 10%; + text-align: right; } th.column-email.column-primary { padding-left: 48px; } @@ -35,16 +35,19 @@ th.column-email.column-primary { .um-form-table .um-forms-line td { padding-right: 0; } -#um-settings-template-versions .wp-list-table .column-core_version { - width: 100px; - text-align: center; } +#um-settings-emails { + margin: 15px 0; } -#um-settings-template-versions .wp-list-table .column-theme_version { - width: 100px; - text-align: center; } - -#um-settings-template-versions .wp-list-table .column-status { - width: 260px; } +#um-settings-template-versions { + margin: 15px 0; } + #um-settings-template-versions .wp-list-table .column-core_version { + width: 100px; + text-align: center; } + #um-settings-template-versions .wp-list-table .column-theme_version { + width: 100px; + text-align: center; } + #um-settings-template-versions .wp-list-table .column-status { + width: 260px; } #um-settings-form { float: left; diff --git a/assets/css/admin/settings.min.css b/assets/css/admin/settings.min.css index 909bc2e5..cad7d4ad 100644 --- a/assets/css/admin/settings.min.css +++ b/assets/css/admin/settings.min.css @@ -1 +1 @@ -.um-settings-section .description{font-style:italic}.um-notification-status{margin-right:18px;font-size:28px;line-height:22px;color:#c74a4a;float:left;box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box}.um-notification-status.um-notification-is-active{color:#7acf58}.um-email-configure span{line-height:24px}.um-long-field{width:100%}.um-medium-field{width:50%}.um-small-field{width:25%}.column-configure{width:60px;text-align:center}th.column-email.column-primary{padding-left:48px}.um-form-table .um-forms-line td{padding-right:0}#um-settings-template-versions .wp-list-table .column-core_version{width:100px;text-align:center}#um-settings-template-versions .wp-list-table .column-theme_version{width:100px;text-align:center}#um-settings-template-versions .wp-list-table .column-status{width:260px}#um-settings-form{float:left;width:100%;margin:0}#um-settings-form .subsubsub{float:left;width:100%}.um-settings-line .multi-checkbox-line{float:left;width:100%;clear:both;margin:0 0 10px 0;padding:0}.um-settings-line .multi-checkbox-column{float:left;margin:0;padding:0}.um-settings-line .multi-checkbox-column label{float:left;width:100%}.wrap-licenses .form-table,.wrap-licenses caption,.wrap-licenses tbody,.wrap-licenses td,.wrap-licenses tfoot,.wrap-licenses th,.wrap-licenses thead,.wrap-licenses tr{display:block}.wrap-licenses .form-table tr{float:left;margin:0 15px 15px 0;background:#fff;border:1px solid #ccc;width:30.5%;max-width:350px;padding:14px;min-height:240px;position:relative;box-sizing:border-box}.wrap-licenses .form-table th{background:#f9f9f9;padding:14px;border-bottom:1px solid #ccc;margin:-14px -14px 20px;width:100%}.wrap-licenses .form-table td{padding:0}.wrap-licenses td input.regular-text{margin:0 0 8px;width:100%}.wrap-licenses .edd-license-data[class*=edd-license-]{position:absolute;background:#fafafa;padding:14px;border-top:1px solid #eee;margin:20px -14px -14px;min-height:67px;width:100%;bottom:14px;box-sizing:border-box}.wrap-licenses .edd-license-data[class*=edd-license-] a{color:#444}.wrap-licenses .edd-license-data[class*=edd-license-] a:hover{text-decoration:none}.wrap-licenses .edd-license-data.license-expires-soon-notice{background-color:#00a0d2;color:#fff;border-color:#00a0d2}.wrap-licenses .edd-license-data.license-expires-soon-notice a{color:#fff}.wrap-licenses .edd-license-data.license-expires-soon-notice a:hover{text-decoration:none}.wrap-licenses .edd-license-data.edd-license-expired{background-color:#e24e4e;color:#fff;border-color:#e24e4e}.wrap-licenses .edd-license-data.edd-license-expired a{color:#fff}.wrap-licenses .edd-license-data.edd-license-expired a:hover{text-decoration:none}.wrap-licenses .edd-license-data.edd-license-valid{background-color:#5abc55;color:#fff;border-color:#5abc55}.wrap-licenses .edd-license-data.edd-license-error,.wrap-licenses .edd-license-data.edd-license-invalid,.wrap-licenses .edd-license-data.edd-license-item_name_mismatch,.wrap-licenses .edd-license-data.edd-license-missing,.wrap-licenses .edd-license-data.edd-license-site_inactive{background-color:#ffebcd;border-color:#ffebcd}.wrap-licenses .edd-license-data p{font-size:13px;margin-top:0}.wrap-licenses~p.submit{clear:both}@media screen and (max-width:980px){.wrap-licenses .form-table tr{width:calc(50% - 15px);max-width:none}}@media screen and (max-width:782px){#um-settings-template-versions .wp-list-table .column-core_version,#um-settings-template-versions .wp-list-table .column-theme_version{width:auto;text-align:left}.wrap-licenses .form-table tr{width:100%;margin-right:0;max-width:none}.um-settings-line .multi-checkbox-column{width:100%!important}.um-settings-line .multi-checkbox-column label{line-height:30px!important}.um-medium-field{width:100%}.um-small-field{width:50%}}.um_setting_ajax_button_response.complete{color:#7acf58;font-style:italic}.wp-core-ui .button.um_license_activate,.wp-core-ui .button.um_license_deactivate,.wp-core-ui .button.um_license_reactivate{margin-top:5px}.um-media-upload .um-media-upload-url{margin-bottom:5px} \ No newline at end of file +.um-settings-section .description{font-style:italic}.um-notification-status{margin-right:18px;font-size:28px;line-height:22px;color:#c74a4a;float:left;box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box}.um-notification-status.um-notification-is-active{color:#7acf58}.um-email-configure span{line-height:24px}.um-long-field{width:100%}.um-medium-field{width:50%}.um-small-field{width:25%}.column-configure{width:10%;text-align:right}th.column-email.column-primary{padding-left:48px}.um-form-table .um-forms-line td{padding-right:0}#um-settings-emails{margin:15px 0}#um-settings-template-versions{margin:15px 0}#um-settings-template-versions .wp-list-table .column-core_version{width:100px;text-align:center}#um-settings-template-versions .wp-list-table .column-theme_version{width:100px;text-align:center}#um-settings-template-versions .wp-list-table .column-status{width:260px}#um-settings-form{float:left;width:100%;margin:0}#um-settings-form .subsubsub{float:left;width:100%}.um-settings-line .multi-checkbox-line{float:left;width:100%;clear:both;margin:0 0 10px 0;padding:0}.um-settings-line .multi-checkbox-column{float:left;margin:0;padding:0}.um-settings-line .multi-checkbox-column label{float:left;width:100%}.wrap-licenses .form-table,.wrap-licenses caption,.wrap-licenses tbody,.wrap-licenses td,.wrap-licenses tfoot,.wrap-licenses th,.wrap-licenses thead,.wrap-licenses tr{display:block}.wrap-licenses .form-table tr{float:left;margin:0 15px 15px 0;background:#fff;border:1px solid #ccc;width:30.5%;max-width:350px;padding:14px;min-height:240px;position:relative;box-sizing:border-box}.wrap-licenses .form-table th{background:#f9f9f9;padding:14px;border-bottom:1px solid #ccc;margin:-14px -14px 20px;width:100%}.wrap-licenses .form-table td{padding:0}.wrap-licenses td input.regular-text{margin:0 0 8px;width:100%}.wrap-licenses .edd-license-data[class*=edd-license-]{position:absolute;background:#fafafa;padding:14px;border-top:1px solid #eee;margin:20px -14px -14px;min-height:67px;width:100%;bottom:14px;box-sizing:border-box}.wrap-licenses .edd-license-data[class*=edd-license-] a{color:#444}.wrap-licenses .edd-license-data[class*=edd-license-] a:hover{text-decoration:none}.wrap-licenses .edd-license-data.license-expires-soon-notice{background-color:#00a0d2;color:#fff;border-color:#00a0d2}.wrap-licenses .edd-license-data.license-expires-soon-notice a{color:#fff}.wrap-licenses .edd-license-data.license-expires-soon-notice a:hover{text-decoration:none}.wrap-licenses .edd-license-data.edd-license-expired{background-color:#e24e4e;color:#fff;border-color:#e24e4e}.wrap-licenses .edd-license-data.edd-license-expired a{color:#fff}.wrap-licenses .edd-license-data.edd-license-expired a:hover{text-decoration:none}.wrap-licenses .edd-license-data.edd-license-valid{background-color:#5abc55;color:#fff;border-color:#5abc55}.wrap-licenses .edd-license-data.edd-license-error,.wrap-licenses .edd-license-data.edd-license-invalid,.wrap-licenses .edd-license-data.edd-license-item_name_mismatch,.wrap-licenses .edd-license-data.edd-license-missing,.wrap-licenses .edd-license-data.edd-license-site_inactive{background-color:#ffebcd;border-color:#ffebcd}.wrap-licenses .edd-license-data p{font-size:13px;margin-top:0}.wrap-licenses~p.submit{clear:both}@media screen and (max-width:980px){.wrap-licenses .form-table tr{width:calc(50% - 15px);max-width:none}}@media screen and (max-width:782px){#um-settings-template-versions .wp-list-table .column-core_version,#um-settings-template-versions .wp-list-table .column-theme_version{width:auto;text-align:left}.wrap-licenses .form-table tr{width:100%;margin-right:0;max-width:none}.um-settings-line .multi-checkbox-column{width:100%!important}.um-settings-line .multi-checkbox-column label{line-height:30px!important}.um-medium-field{width:100%}.um-small-field{width:50%}}.um_setting_ajax_button_response.complete{color:#7acf58;font-style:italic}.wp-core-ui .button.um_license_activate,.wp-core-ui .button.um_license_deactivate,.wp-core-ui .button.um_license_reactivate{margin-top:5px}.um-media-upload .um-media-upload-url{margin-bottom:5px} \ No newline at end of file diff --git a/assets/css/admin/settings.sass b/assets/css/admin/settings.sass index 1d3dc722..327b320c 100644 --- a/assets/css/admin/settings.sass +++ b/assets/css/admin/settings.sass @@ -38,8 +38,8 @@ width: 25% .column-configure - width: 60px - text-align: center + width: 10% + text-align: right th.column-email.column-primary padding-left: 48px @@ -50,7 +50,11 @@ th.column-email.column-primary td padding-right: 0 +##{$prefix}settings-emails + margin: 15px 0 + ##{$prefix}settings-template-versions + margin: 15px 0 .wp-list-table .column-core_version width: 100px diff --git a/includes/admin/class-secure.php b/includes/admin/class-secure.php index f67dacf0..2830bd85 100644 --- a/includes/admin/class-secure.php +++ b/includes/admin/class-secure.php @@ -235,16 +235,18 @@ if ( ! class_exists( 'um\admin\Secure' ) ) { 'description' => __( 'Scan your site to check for vulnerabilities prior to Ultimate Member version 2.6.7 and get recommendations to secure your site.', 'ultimate-member' ), ), array( - 'id' => 'lock_register_forms', - 'type' => 'checkbox', - 'label' => __( 'Lock All Register Forms', 'ultimate-member' ), - 'description' => __( 'This prevents all users from registering with Ultimate Member on your site.', 'ultimate-member' ), + 'id' => 'lock_register_forms', + 'type' => 'checkbox', + 'label' => __( 'Lock All Register Forms', 'ultimate-member' ), + 'checkbox_label' => __( 'Lock Forms', 'ultimate-member' ), + 'description' => __( 'This prevents all users from registering with Ultimate Member on your site.', 'ultimate-member' ), ), array( - 'id' => 'display_login_form_notice', - 'type' => 'checkbox', - 'label' => __( 'Display Login form notice to reset passwords', 'ultimate-member' ), - 'description' => __( 'Enforces users to reset their passwords( one-time ) and prevent from entering old password.', 'ultimate-member' ), + 'id' => 'display_login_form_notice', + 'type' => 'checkbox', + 'label' => __( 'Display Login form notice to reset passwords', 'ultimate-member' ), + 'checkbox_label' => __( 'Enable Login form notice', 'ultimate-member' ), + 'description' => __( 'Enforces users to reset their passwords (one-time) and prevent from entering old password.', 'ultimate-member' ), ), ); @@ -264,17 +266,19 @@ if ( ! class_exists( 'um\admin\Secure' ) ) { $secure_fields, array( array( - 'id' => 'secure_ban_admins_accounts', - 'type' => 'checkbox', - 'label' => __( 'Enable ban for administrative capabilities', 'ultimate-member' ), - 'description' => __( ' When someone tries to inject capabilities to the Account, Profile & Register forms submission, it will be banned.', 'ultimate-member' ), + 'id' => 'secure_ban_admins_accounts', + 'type' => 'checkbox', + 'label' => __( 'Administrative capabilities ban', 'ultimate-member' ), + 'checkbox_label' => __( 'Enable ban for administrative capabilities', 'ultimate-member' ), + 'description' => __( ' When someone tries to inject capabilities to the Account, Profile & Register forms submission, it will be banned.', 'ultimate-member' ), ), array( - 'id' => 'secure_notify_admins_banned_accounts', - 'type' => 'checkbox', - 'label' => __( 'Notify Administrators', 'ultimate-member' ), - 'description' => __( 'When enabled, All administrators will be notified when someone has suspicious activities in the Account, Profile & Register forms.', 'ultimate-member' ), - 'conditional' => array( 'secure_ban_admins_accounts', '=', 1 ), + 'id' => 'secure_notify_admins_banned_accounts', + 'type' => 'checkbox', + 'label' => __( 'Notify Administrators', 'ultimate-member' ), + 'checkbox_label' => __( 'Enable notification', 'ultimate-member' ), + 'description' => __( 'When enabled, All administrators will be notified when someone has suspicious activities in the Account, Profile & Register forms.', 'ultimate-member' ), + 'conditional' => array( 'secure_ban_admins_accounts', '=', 1 ), ), array( 'id' => 'secure_notify_admins_banned_accounts__interval', @@ -291,7 +295,7 @@ if ( ! class_exists( 'um\admin\Secure' ) ) { 'id' => 'secure_allowed_redirect_hosts', 'type' => 'textarea', 'label' => __( 'Allowed hosts for safe redirect (one host per line)', 'ultimate-member' ), - 'description' => __( 'Extend allowed hosts for frontend pages redirects', 'ultimate-member' ), + 'description' => __( 'Extend allowed hosts for frontend pages redirects.', 'ultimate-member' ), ), ) ); diff --git a/includes/admin/core/class-admin-forms.php b/includes/admin/core/class-admin-forms.php index f849273a..946e913a 100644 --- a/includes/admin/core/class-admin-forms.php +++ b/includes/admin/core/class-admin-forms.php @@ -168,7 +168,7 @@ if ( ! class_exists( 'um\admin\core\Admin_Forms' ) ) { } - if ( ! empty( $data['description'] ) && ! in_array( $data['type'], array( 'same_page_update', 'checkbox' ), true ) ) { + if ( ! empty( $data['description'] ) ) { $html .= '

' . $data['description'] . '

'; } @@ -190,7 +190,7 @@ if ( ! class_exists( 'um\admin\core\Admin_Forms' ) ) { } - if ( ! empty( $data['description'] ) && ! in_array( $data['type'], array( 'same_page_update', 'checkbox' ), true ) ) { + if ( ! empty( $data['description'] ) ) { $html .= '

' . $data['description'] . '

'; } @@ -210,7 +210,7 @@ if ( ! class_exists( 'um\admin\core\Admin_Forms' ) ) { } - if ( ! empty( $data['description'] ) && ! in_array( $data['type'], array( 'same_page_update', 'checkbox' ), true ) ) { + if ( ! empty( $data['description'] ) ) { $html .= '

' . $data['description'] . '

'; } @@ -235,7 +235,7 @@ if ( ! class_exists( 'um\admin\core\Admin_Forms' ) ) { } - if ( ! empty( $data['description'] ) && ! in_array( $data['type'], array( 'same_page_update', 'checkbox' ), true ) ) { + if ( ! empty( $data['description'] ) ) { $html .= '

' . $data['description'] . '

'; } @@ -258,7 +258,7 @@ if ( ! class_exists( 'um\admin\core\Admin_Forms' ) ) { } - if ( ! empty( $data['description'] ) && ! in_array( $data['type'], array( 'same_page_update', 'checkbox' ), true ) ) { + if ( ! empty( $data['description'] ) ) { $html .= '

' . $data['description'] . '

'; } @@ -280,7 +280,7 @@ if ( ! class_exists( 'um\admin\core\Admin_Forms' ) ) { } - if ( ! empty( $data['description'] ) && ! in_array( $data['type'], array( 'same_page_update', 'checkbox' ), true ) ) { + if ( ! empty( $data['description'] ) ) { $html .= '

' . $data['description'] . '

'; } @@ -963,11 +963,11 @@ if ( ! class_exists( 'um\admin\core\Admin_Forms' ) ) { $value = $this->get_field_value( $field_data ); - $description = ! empty( $field_data['description'] ) ? $field_data['description'] : ''; + $checkbox_label = ! empty( $field_data['checkbox_label'] ) ? $field_data['checkbox_label'] : ''; $field_html = ""; - if ( '' !== $description ) { - $field_html = ""; + if ( '' !== $checkbox_label ) { + $field_html = ""; } $html = "{$field_html}"; return apply_filters( 'um_admin_render_checkbox_field_html', $html, $field_data ); @@ -993,7 +993,7 @@ if ( ! class_exists( 'um\admin\core\Admin_Forms' ) ) { $class_attr = ' class="um-forms-field ' . esc_attr( $class ) . '" '; $data = array( - 'field_id' => $field_data['id'] + 'field_id' => $field_data['id'], ); if ( ! empty( $field_data['data'] ) ) { @@ -1015,11 +1015,11 @@ if ( ! class_exists( 'um\admin\core\Admin_Forms' ) ) { $value = $this->get_field_value( $field_data ); - $description = ! empty( $field_data['description'] ) ? $field_data['description'] : ''; + $checkbox_label = ! empty( $field_data['checkbox_label'] ) ? $field_data['checkbox_label'] : ''; $field_html = ""; - if ( '' !== $description ) { - $field_html = ""; + if ( '' !== $checkbox_label ) { + $field_html = ""; } $html = "{$field_html}"; @@ -1749,51 +1749,6 @@ if ( ! class_exists( 'um\admin\core\Admin_Forms' ) ) { return $html; } - /** - * @param array $field_data - * - * @return string - */ - public function render_form_section( $field_data ) { - $html = '

' . esc_html( $field_data['title'] ) . '

'; - if ( ! empty( $field_data['content'] ) ) { - $html .= '

' . wp_kses( $field_data['content'] , UM()->get_allowed_html( 'admin_notice' ) ) . '

'; - } - return $html; - } - - public function render_override_templates( $field_data ) { - $um_check_version = get_transient( 'um_check_template_versions' ); - - $check_url = add_query_arg( - array( - 'um_adm_action' => 'check_templates_version', - '_wpnonce' => wp_create_nonce( 'check_templates_version' ), - ) - ); - ?> - -

- - - - -

- - 'um_options' ), admin_url( 'admin.php' ) ) ); exit; } diff --git a/includes/admin/core/class-admin-settings.php b/includes/admin/core/class-admin-settings.php index b1026a8b..60293397 100644 --- a/includes/admin/core/class-admin-settings.php +++ b/includes/admin/core/class-admin-settings.php @@ -42,13 +42,14 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { //init settings structure add_action( 'admin_init', array( &$this, 'init_variables' ), 9 ); - //settings structure handlers + // settings structure handlers add_action( 'um_settings_page_before_email__content', array( $this, 'settings_before_email_tab' ) ); add_filter( 'um_settings_section_custom_fields', array( $this, 'email_section_custom_fields' ), 10, 2 ); + add_filter( 'um_settings_form_section_advanced_override_templates_override_templates_custom_content', array( $this, 'settings_override_templates_tab' ) ); + //custom content for licenses tab add_filter( 'um_settings_section_licenses__custom_content', array( $this, 'settings_licenses_tab' ), 10, 3 ); - add_filter( 'um_settings_section_advanced_override_templates_custom_content', array( $this, 'settings_override_templates_tab' ) ); // @todo remove since 2.9.0 add_filter( 'um_settings_section_install_info__custom_content', array( $this, 'settings_install_info' ) ); @@ -636,10 +637,11 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { $latest_truncate = get_option( 'um_member_directory_truncated', false ); $same_page_update = array( - 'id' => 'member_directory_own_table', - 'type' => 'same_page_update', - 'label' => __( 'Enable custom table for usermeta', 'ultimate-member' ), - 'description' => __( 'Check this box if you would like to enable the use of a custom table for user metadata. Improved performance for member directory searches.', 'ultimate-member' ), + 'id' => 'member_directory_own_table', + 'type' => 'same_page_update', + 'label' => __( 'Custom usermeta table', 'ultimate-member' ), + 'checkbox_label' => __( 'Enable custom table for usermeta', 'ultimate-member' ), + 'description' => __( 'Check this box if you would like to enable the use of a custom table for user metadata. Improved performance for member directory searches.', 'ultimate-member' ), ); if ( empty( $latest_update ) || ( ! empty( $latest_truncate ) && $latest_truncate > $latest_update ) ) { @@ -1142,22 +1144,25 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { 'size' => 'medium', ), array( - 'id' => 'author_redirect', - 'type' => 'checkbox', - 'label' => __( 'Automatically redirect author page to their profile?', 'ultimate-member' ), - 'description' => __( 'If enabled, author pages will automatically redirect to the user\'s profile page', 'ultimate-member' ), + 'id' => 'author_redirect', + 'type' => 'checkbox', + 'label' => __( 'Hide author pages', 'ultimate-member' ), + 'checkbox_label' => __( 'Enable automatically redirect author page to their profile', 'ultimate-member' ), + 'description' => __( 'If enabled, author pages will automatically redirect to the user\'s profile page', 'ultimate-member' ), ), array( - 'id' => 'members_page', - 'type' => 'checkbox', - 'label' => __( 'Enable Members Directory', 'ultimate-member' ), - 'description' => __( 'Control whether to enable or disable member directories on this site', 'ultimate-member' ), + 'id' => 'members_page', + 'type' => 'checkbox', + 'label' => __( 'Members Directory', 'ultimate-member' ), + 'checkbox_label' => __( 'Enable Members Directory', 'ultimate-member' ), + 'description' => __( 'Control whether to enable or disable member directories on this site', 'ultimate-member' ), ), array( - 'id' => 'use_gravatars', - 'type' => 'checkbox', - 'label' => __( 'Use Gravatar', 'ultimate-member' ), - 'description' => __( 'Do you want to use Gravatar instead of the default plugin profile photo (If the user did not upload a custom profile photo/avatar)?', 'ultimate-member' ), + 'id' => 'use_gravatars', + 'type' => 'checkbox', + 'label' => __( 'Use Gravatar', 'ultimate-member' ), + 'checkbox_label' => __( 'Enable Gravatar', 'ultimate-member' ), + 'description' => __( 'Do you want to use Gravatar instead of the default plugin profile photo (If the user did not upload a custom profile photo/avatar)?', 'ultimate-member' ), ), array( 'id' => 'use_um_gravatar_default_builtin_image', @@ -1178,17 +1183,19 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { 'size' => 'medium', ), array( - 'id' => 'use_um_gravatar_default_image', - 'type' => 'checkbox', - 'label' => __( 'Use Default plugin avatar as Gravatar\'s Default avatar', 'ultimate-member' ), - 'description' => __( 'Do you want to use the plugin default avatar instead of the gravatar default photo (If the user did not upload a custom profile photo / avatar)', 'ultimate-member' ), - 'conditional' => array( 'use_um_gravatar_default_builtin_image', '=', 'default' ), + 'id' => 'use_um_gravatar_default_image', + 'type' => 'checkbox', + 'label' => __( 'Replace Gravatar\'s Default avatar', 'ultimate-member' ), + 'checkbox_label' => __( 'Set Default plugin avatar as Gravatar\'s Default avatar', 'ultimate-member' ), + 'description' => __( 'Do you want to use the plugin default avatar instead of the gravatar default photo (If the user did not upload a custom profile photo/avatar)', 'ultimate-member' ), + 'conditional' => array( 'use_um_gravatar_default_builtin_image', '=', 'default' ), ), array( - 'id' => 'delete_comments', - 'type' => 'checkbox', - 'label' => __( 'Deleting user comments after deleting a user', 'ultimate-member' ), - 'description' => __( 'Do you want to delete a user\'s comments when that user deletes themself or is removed from the admin dashboard from the site?', 'ultimate-member' ), + 'id' => 'delete_comments', + 'type' => 'checkbox', + 'label' => __( 'Delete user comments', 'ultimate-member' ), + 'checkbox_label' => __( 'Enable deleting user comments after deleting a user', 'ultimate-member' ), + 'description' => __( 'Do you want to delete a user\'s comments when that user deletes themself or is removed from the admin dashboard from the site?', 'ultimate-member' ), ), ), ), @@ -1197,16 +1204,18 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { 'description' => __( 'Password & Security settings.', 'ultimate-member' ), 'fields' => array( array( - 'id' => 'toggle_password', - 'type' => 'checkbox', - 'label' => __( 'Show/hide password button', 'ultimate-member' ), - 'description' => __( 'Enable visibility for show/hide password button for the password field-type.', 'ultimate-member' ), + 'id' => 'toggle_password', + 'type' => 'checkbox', + 'label' => __( 'Toggle Password Visibility', 'ultimate-member' ), + 'checkbox_label' => __( 'Enable password show/hide button', 'ultimate-member' ), + 'description' => __( 'Enable visibility for show/hide password button for the password field-type.', 'ultimate-member' ), ), array( - 'id' => 'require_strongpass', - 'type' => 'checkbox', - 'label' => __( 'Require Strong Passwords', 'ultimate-member' ), - 'description' => __( 'Enable this option to apply strong password rules to all password fields (user registration, password reset and password change).', 'ultimate-member' ), + 'id' => 'require_strongpass', + 'type' => 'checkbox', + 'label' => __( 'Require Strong Passwords', 'ultimate-member' ), + 'checkbox_label' => __( 'Enable strong passwords', 'ultimate-member' ), + 'description' => __( 'Enable this option to apply strong password rules to all password fields (user registration, password reset and password change).', 'ultimate-member' ), ), array( 'id' => 'password_min_chars', @@ -1401,31 +1410,44 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { ), ), 'email' => array( - 'title' => __( 'Email', 'ultimate-member' ), - 'fields' => array( - array( - 'id' => 'admin_email', - 'type' => 'text', - 'label' => __( 'Admin E-mail Address', 'ultimate-member' ), - 'tooltip' => __( 'e.g. admin@companyname.com', 'ultimate-member' ), + 'title' => __( 'Email', 'ultimate-member' ), + 'form_sections' => array( + 'email_sender' => array( + 'title' => __( 'Email sender options', 'ultimate-member' ), + 'description' => __( 'How the sender appears in outgoing Ultimate Member emails.', 'ultimate-member' ), + 'fields' => array( + array( + 'id' => 'admin_email', + 'type' => 'text', + 'label' => __( 'Admin E-mail Address', 'ultimate-member' ), + 'description' => __( 'e.g. admin@companyname.com', 'ultimate-member' ), + ), + array( + 'id' => 'mail_from', + 'type' => 'text', + 'label' => __( 'Mail appears from', 'ultimate-member' ), + 'description' => __( 'e.g. Site Name', 'ultimate-member' ), + ), + array( + 'id' => 'mail_from_addr', + 'type' => 'text', + 'label' => __( 'Mail appears from address', 'ultimate-member' ), + 'description' => __( 'e.g. admin@companyname.com', 'ultimate-member' ), + ), + ), ), - array( - 'id' => 'mail_from', - 'type' => 'text', - 'label' => __( 'Mail appears from', 'ultimate-member' ), - 'tooltip' => __( 'e.g. Site Name', 'ultimate-member' ), - ), - array( - 'id' => 'mail_from_addr', - 'type' => 'text', - 'label' => __( 'Mail appears from address', 'ultimate-member' ), - 'tooltip' => __( 'e.g. admin@companyname.com', 'ultimate-member' ), - ), - array( - 'id' => 'email_html', - 'type' => 'checkbox', - 'label' => __( 'Use HTML for E-mails?', 'ultimate-member' ), - 'tooltip' => __( 'If you plan use e-mails with HTML, please make sure that this option is enabled. Otherwise, HTML will be displayed as plain text.', 'ultimate-member' ), + 'email_template' => array( + 'title' => __( 'Email template', 'ultimate-member' ), + 'description' => __( 'Section to customize email templates settings.', 'ultimate-member' ), + 'fields' => array( + array( + 'id' => 'email_html', + 'type' => 'checkbox', + 'label' => __( 'Content type', 'ultimate-member' ), + 'checkbox_label' => __( 'Enable HTML for E-mails', 'ultimate-member' ), + 'description' => __( 'If you plan use e-mails with HTML, please make sure that this option is enabled. Otherwise, HTML will be displayed as plain text.', 'ultimate-member' ), + ), + ), ), ), ), @@ -1840,15 +1862,17 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { 'title' => __( 'General', 'ultimate-member' ), 'fields' => array( array( - 'id' => 'form_asterisk', - 'type' => 'checkbox', - 'label' => __( 'Show an asterisk for required fields', 'ultimate-member' ), + 'id' => 'form_asterisk', + 'type' => 'checkbox', + 'label' => __( 'Required fields\' asterisk', 'ultimate-member' ), + 'checkbox_label' => __( 'Show an asterisk for required fields', 'ultimate-member' ), ), array( - 'id' => 'um_profile_object_cache_stop', - 'type' => 'checkbox', - 'label' => __( 'Disable Cache User Profile', 'ultimate-member' ), - 'description' => __( 'Check this box if you would like to disable Ultimate Member user\'s cache.', 'ultimate-member' ), + 'id' => 'um_profile_object_cache_stop', + 'type' => 'checkbox', + 'label' => __( 'Cache User Profile', 'ultimate-member' ), + 'checkbox_label' => __( 'Disable user data cache', 'ultimate-member' ), + 'description' => __( 'Check this box if you would like to disable Ultimate Member user\'s cache.', 'ultimate-member' ), ), array( 'id' => 'rest_api_version', @@ -1861,25 +1885,25 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { ), ), array( - 'id' => 'uninstall_on_delete', - 'type' => 'checkbox', - 'label' => __( 'Remove Data on Uninstall?', 'ultimate-member' ), - 'description' => __( 'Check this box if you would like Ultimate Member to completely remove all of its data when the plugin/extensions are deleted.', 'ultimate-member' ), + 'id' => 'uninstall_on_delete', + 'type' => 'checkbox', + 'label' => __( 'Remove Data on Uninstall?', 'ultimate-member' ), + 'checkbox_label' => __( 'Enable flushing data', 'ultimate-member' ), + 'description' => __( 'Check this box if you would like Ultimate Member to completely remove all of its data when the plugin/extensions are deleted.', 'ultimate-member' ), ), ), ), 'override_templates' => array( 'title' => __( 'Override templates', 'ultimate-member' ), 'form_sections' => array( - array( - 'id' => 'override_templates_options', - 'type' => 'form_section', + 'override_templates' => array( 'title' => __( 'Override templates', 'ultimate-member' ), // translators: %s: Link to the docs article. - 'description' => sprintf( __( 'You may get more details about overriding templates here.', 'ultimate-member' ), 'https://docs.ultimatemember.com/article/1516-templates-map' ), /** @noinspection HtmlUnknownTarget */ + 'description' => sprintf( __( 'You can find a list of template file changes with each release. You can check the latest templates and their statuses, and see if they\'re outdated or updated. You may get more details about overriding templates here.', 'ultimate-member' ), 'https://docs.ultimatemember.com/article/1516-templates-map' ), /** @noinspection HtmlUnknownTarget */ 'fields' => array( array( - 'type' => 'override_templates', + 'id' => 'override_templates_list_table', + 'type' => 'override_templates_list_table', ), ), ), @@ -1893,10 +1917,11 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { 'description' => __( 'Start using new features that are being progressively rolled out to improve the users management experience.', 'ultimate-member' ), 'fields' => array( array( - 'id' => 'enable_blocks', - 'type' => 'checkbox', - 'label' => __( 'Enable Gutenberg Blocks', 'ultimate-member' ), - 'description' => __( 'Check this box if you would like to use Ultimate Member blocks in Gutenberg editor. Important some themes have the conflicts with Gutenberg editor.', 'ultimate-member' ), + 'id' => 'enable_blocks', + 'type' => 'checkbox', + 'label' => __( 'Gutenberg Blocks', 'ultimate-member' ), + 'checkbox_label' => __( 'Enable Gutenberg Blocks', 'ultimate-member' ), + 'description' => __( 'Check this box if you would like to use Ultimate Member blocks in Gutenberg editor. Important some themes have the conflicts with Gutenberg editor.', 'ultimate-member' ), ), $same_page_update, ), @@ -1906,10 +1931,11 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { 'description' => __( 'These features are either experimental or incomplete, enable them at your own risk!', 'ultimate-member' ), 'fields' => array( array( - 'id' => 'disable_legacy_fonicons', - 'type' => 'checkbox', - 'label' => __( 'Disable legacy fonticons', 'ultimate-member' ), - 'description' => __( 'Check this box if you would like to disable legacy Ultimate Member fonticons used outdated versions of FontAwesome and Ionicons libraries.', 'ultimate-member' ), + 'id' => 'disable_legacy_fonicons', + 'type' => 'checkbox', + 'label' => __( 'Legacy fonticons', 'ultimate-member' ), + 'checkbox_label' => __( 'Disable legacy fonticons', 'ultimate-member' ), + 'description' => __( 'Check this box if you would like to disable legacy Ultimate Member fonticons used outdated versions of FontAwesome and Ionicons libraries.', 'ultimate-member' ), ), ), ), @@ -1920,10 +1946,11 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { // backward compatibility option leave it disabled for better security and ability to exclude posts/terms pre-query // otherwise we're filtering only results and restricted posts/terms can be visible array( - 'id' => 'disable_restriction_pre_queries', - 'type' => 'checkbox', - 'label' => __( 'Disable pre-queries for restriction content logic', 'ultimate-member' ), - 'description' => __( 'Please enable this option only in the cases when you have big or unnecessary queries on your site with active restriction logic. If you want to exclude posts only from the results queries instead of pre_get_posts and fully-hidden post logic also please enable this option. It activates the restriction content logic until 2.2.x version without latest security enhancements.', 'ultimate-member' ), + 'id' => 'disable_restriction_pre_queries', + 'type' => 'checkbox', + 'label' => __( 'Restriction content pre-queries', 'ultimate-member' ), + 'checkbox_label' => __( 'Disable pre-queries for restriction content logic', 'ultimate-member' ), + 'description' => __( 'Please enable this option only in the cases when you have big or unnecessary queries on your site with active restriction logic. If you want to exclude posts only from the results queries instead of pre_get_posts and fully-hidden post logic also please enable this option. It activates the restriction content logic until 2.2.x version without latest security enhancements.', 'ultimate-member' ), ), ), ), @@ -2125,7 +2152,7 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { } } - if ( ! empty( $tab['fields'] ) || ! empty( $tab['sections'] ) ) { + if ( ! empty( $tab['fields'] ) || ! empty( $tab['sections'] ) || ! empty( $tab['form_sections'] ) ) { $menu_tabs[ $slug ] = $tab['title']; } } @@ -3037,7 +3064,7 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { * * @return string */ - public function settings_override_templates_tab() { + public function settings_override_templates_tab( $content ) { $um_check_version = get_transient( 'um_check_template_versions' ); $check_url = add_query_arg( @@ -3049,7 +3076,7 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { ob_start(); ?> -

+

@@ -3062,18 +3089,13 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { } ?>

-

- here.', 'ultimate-member' ), 'https://docs.ultimatemember.com/article/1516-templates-map' ), UM()->get_allowed_html( 'admin_notice' ) ); - ?> -

+
-

+

+

Info. echo wp_kses( sprintf( __( 'This settings tab is deprecated. And it will be fully removed since 2.9.0 version. Please get the installation info from there.', 'ultimate-member' ), add_query_arg( 'tab', 'debug', admin_url( 'site-health.php' ) ) ), UM()->get_allowed_html( 'admin_notice' ) ); ?>

-

+

$form_section_fields ) { @@ -3301,6 +3324,9 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { continue; } + $custom_form_section_content = apply_filters( "um_settings_form_section_{$current_tab}_{$current_subtab}_{$section_key}_custom_content", false ); + + ob_start(); if ( ! empty( $form_section_fields['title'] ) ) { ?>

@@ -3313,13 +3339,19 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { admin_forms_settings( - array( - 'class' => 'um_options-' . $current_tab . '-' . $current_subtab . '-' . $section_key . ' um-third-column', - 'prefix_id' => 'um_options', - 'fields' => $form_section_fields['fields'], - ) - )->render_form(); + if ( false === $custom_form_section_content ) { + UM()->admin_forms_settings( + array( + 'class' => 'um_options-' . $current_tab . '-' . $current_subtab . '-' . $section_key . ' um-third-column', + 'prefix_id' => 'um_options', + 'fields' => $form_section_fields['fields'], + ) + )->render_form(); + } else { + echo $custom_form_section_content; + } + + $settings_section .= ob_get_clean(); } } else { $settings_structure = $this->settings_structure[ $current_tab ]; @@ -3335,6 +3367,8 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { $section_description = array_key_exists( 'description', $settings_structure ) ? $settings_structure['description'] : ''; } + ob_start(); + if ( ! empty( $section_title ) ) { ?>

@@ -3354,9 +3388,11 @@ if ( ! class_exists( 'um\admin\core\Admin_Settings' ) ) { 'fields' => $section_fields, ) )->render_form(); + + $settings_section .= ob_get_clean(); } - return ob_get_clean(); + return $settings_section; } /** diff --git a/includes/admin/core/list-tables/emails-list-table.php b/includes/admin/core/list-tables/emails-list-table.php index cbfcf3f3..0ebd6798 100644 --- a/includes/admin/core/list-tables/emails-list-table.php +++ b/includes/admin/core/list-tables/emails-list-table.php @@ -99,6 +99,15 @@ class UM_Emails_List_Table extends WP_List_Table { $this->_column_headers = array( $columns, $hidden, $sortable ); } + /** + * Generates the table navigation above or below the table + * + * @since 3.1.0 + * @param string $which + */ + protected function display_tablenav( $which ) { + // Stop displaying tablenav. + } /** * @param object $item @@ -221,12 +230,14 @@ class UM_Emails_List_Table extends WP_List_Table { function column_email( $item ) { $active = UM()->options()->get( $item['key'] . '_on' ); - $icon = ! empty( $active ) ? 'um-notification-is-active dashicons-yes' : 'dashicons-no-alt'; - $link = add_query_arg( array( 'email' => $item['key'] ) ); - $text = '' . $item['title'] . ''; + $icon = ! empty( $active ) ? 'um-notification-is-active dashicons-yes' : 'dashicons-no-alt'; + $icon_title = ! empty( $active ) ? __( 'Enabled', 'ultimate-member' ) : __( 'Disabled', 'ultimate-member' ); + + $link = add_query_arg( array( 'email' => $item['key'] ), remove_query_arg( 'paged' ) ); + $text = '' . esc_html( $item['title'] ) . ''; if ( ! empty( $item['description'] ) ) { - $text .= ' '; + $text .= ' '; } return $text; @@ -239,11 +250,11 @@ class UM_Emails_List_Table extends WP_List_Table { * @return string */ function column_recipients( $item ) { - if ( $item['recipient'] == 'admin' ) { + if ( 'admin' === $item['recipient'] ) { return UM()->options()->get( 'admin_email' ); - } else { - return __( 'Member', 'ultimate-member' ); } + + return __( 'Member', 'ultimate-member' ); } @@ -253,7 +264,8 @@ class UM_Emails_List_Table extends WP_List_Table { * @return string */ function column_configure( $item ) { - return ''; + $edit_link = add_query_arg( array( 'email' => $item['key'] ), remove_query_arg( 'paged' ) ); + return '' . esc_html__( 'Manage', 'ultimate-member' ) . ''; } @@ -276,13 +288,13 @@ class UM_Emails_List_Table extends WP_List_Table { } $ListTable = new UM_Emails_List_Table( array( - 'singular' => __( 'Email Notification', 'ultimate-member' ), - 'plural' => __( 'Email Notifications', 'ultimate-member' ), - 'ajax' => false + 'singular' => __( 'Email Notification', 'ultimate-member' ), + 'plural' => __( 'Email Notifications', 'ultimate-member' ), + 'ajax' => false, )); -$per_page = 20; -$paged = $ListTable->get_pagenum(); +$per_page = 999; +$paged = $ListTable->get_pagenum(); /** * UM hook @@ -306,9 +318,9 @@ $paged = $ListTable->get_pagenum(); * ?> */ $columns = apply_filters( 'um_email_templates_columns', array( - 'email' => __( 'Email', 'ultimate-member' ), - 'recipients' => __( 'Recipient(s)', 'ultimate-member' ), - 'configure' => '', + 'email' => __( 'Email', 'ultimate-member' ), + 'recipients' => __( 'Recipient(s)', 'ultimate-member' ), + 'configure' => '', ) ); $ListTable->set_columns( $columns ); @@ -317,18 +329,21 @@ $emails = UM()->config()->email_notifications; $ListTable->prepare_items(); $ListTable->items = array_slice( $emails, ( $paged - 1 ) * $per_page, $per_page ); -$ListTable->wpc_set_pagination_args( array( 'total_items' => count( $emails ), 'per_page' => $per_page ) ); ?> +$ListTable->wpc_set_pagination_args( array( 'total_items' => count( $emails ), 'per_page' => $per_page ) ); +?> -

- here', 'ultimate-member' ), 'https://docs.ultimatemember.com/article/1335-email-templates' ), UM()->get_allowed_html( 'admin_notice' ) ); - ?> +

+

+ +
+ + here.', 'ultimate-member' ), 'https://docs.ultimatemember.com/article/1335-email-templates' ), UM()->get_allowed_html( 'admin_notice' ) ); ?>

- +
display(); ?>
+
diff --git a/includes/admin/core/list-tables/version-template-list-table.php b/includes/admin/core/list-tables/version-template-list-table.php index 739dfd6b..bf1360fe 100644 --- a/includes/admin/core/list-tables/version-template-list-table.php +++ b/includes/admin/core/list-tables/version-template-list-table.php @@ -163,6 +163,16 @@ class UM_Versions_List_Table extends WP_List_Table { $icon = 1 === $item['status_code'] ? 'um-notification-is-active dashicons-yes' : 'dashicons-no-alt'; return $item['status'] . ' '; } + + /** + * Generates the table navigation above or below the table + * + * @since 3.1.0 + * @param string $which + */ + protected function display_tablenav( $which ) { + // Stop displaying tablenav. + } } $list_table = new UM_Versions_List_Table(