!!! IMPORTANT 2.0 version before upgrade please run full backup of your site !!!
- new code structure, optimized for next development; - created spl_autoloader for remove includes; - UM classes with namespaces; - deprecated global $ultimatemember; variable (use UM() instead); - new UM/WP roles logic; - new settings class and logic (deprecated Redux framework, deprecated some old options, added some new options); - new dependencies class for extensions; - WP native styles for backend fields; - new upgrades and license activations for extensions; - new logic form backend forms and fields; - created uninstall.php file for delete permanently all UM settings; - optimized registration/upgrade profile process; Deprecated Hooks: um_new_user_registration_plain um_user_registration_extra_hook um_add_user_frontend um_post_registration_global_hook um_admin_extend_directory_options_general (was action...will be filter)
@@ -0,0 +1,304 @@
|
||||
/*
|
||||
- General
|
||||
*/
|
||||
|
||||
.um-admin-builder * {
|
||||
-webkit-font-smoothing: antialiased !important;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
}
|
||||
|
||||
.um-admin-builder i {
|
||||
font-size: 15px !important;
|
||||
height: 100% !important;
|
||||
line-height: 100% !important;
|
||||
margin: 0 5px 0 0 !important;
|
||||
}
|
||||
|
||||
.um-admin-builder .um-admin-drag {margin-top: 40px}
|
||||
|
||||
/*
|
||||
- Add field
|
||||
*/
|
||||
.um-admin-drag-add-field {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 30px;
|
||||
line-height: 30px;
|
||||
text-align: center;
|
||||
color: #aaa;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.um-admin-drag-add-field:hover {color: #0085ba}
|
||||
|
||||
.um-admin-drag-add-field i {
|
||||
font-size: 23px !important;
|
||||
margin: 0 !important;
|
||||
}
|
||||
|
||||
/*
|
||||
- Drag controls
|
||||
*/
|
||||
|
||||
.um-admin-drag-ctrls-demo.um-admin-drag-ctrls {
|
||||
position: absolute;
|
||||
right: 7px;
|
||||
top: -30px;
|
||||
left: auto;
|
||||
}
|
||||
|
||||
.um-admin-drag-ctrls {
|
||||
position: absolute;
|
||||
top: -30px;
|
||||
left: 0;
|
||||
}
|
||||
|
||||
.um-admin-drag-ctrls a {
|
||||
float: left;
|
||||
margin: 0 5px 0 0;
|
||||
height: 30px;
|
||||
line-height: 30px;
|
||||
background: #eee;
|
||||
color: #888;
|
||||
padding: 0 8px;
|
||||
text-decoration: none;
|
||||
border-radius: 2px 2px 0 0;
|
||||
}
|
||||
|
||||
.um-admin-drag-ctrls a:hover {background-color: #e5e5e5}
|
||||
|
||||
.um-admin-drag-ctrls a.active,
|
||||
.um-admin-drag-ctrls a.active:hover {
|
||||
/*background-color: #3ba1da;*/
|
||||
background-color: #0085ba;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.um-admin-drag-ctrls.columns a {width: 30px !important;background-image: url(../img/1-column.gif); background-repeat: no-repeat; background-position: center;}
|
||||
.um-admin-drag-ctrls.columns a:nth-child(2) {background-image: url(../img/2-columns.gif);}
|
||||
.um-admin-drag-ctrls.columns a:last-child {background-image: url(../img/3-columns.gif);}
|
||||
|
||||
.um-admin-drag-ctrls.columns a.active {background-image: url(../img/1-column-active.gif)}
|
||||
.um-admin-drag-ctrls.columns a.active:nth-child(2) {background-image: url(../img/2-columns-active.gif);}
|
||||
.um-admin-drag-ctrls.columns a.active:last-child {background-image: url(../img/3-columns-active.gif);}
|
||||
|
||||
/*
|
||||
- Drag Area
|
||||
*/
|
||||
|
||||
.um-admin-drag {
|
||||
width: 100%;
|
||||
background: #f1f1f1;
|
||||
box-sizing: border-box;
|
||||
position: relative;
|
||||
padding: 60px 20px 20px 20px;
|
||||
}
|
||||
|
||||
.um-admin-drag-row {
|
||||
width: 100%;
|
||||
background: #fefefe;
|
||||
box-sizing: border-box;
|
||||
position: relative;
|
||||
padding: 60px 20px 20px 20px;
|
||||
margin: 0 0 60px 0;
|
||||
}
|
||||
.um-admin-drag-row:last-child {margin-bottom: 0}
|
||||
|
||||
.um-admin-drag-row-icons {
|
||||
position: absolute;
|
||||
right: 0;
|
||||
top: -30px;
|
||||
height: 30px;
|
||||
}
|
||||
|
||||
.um-admin-drag-rowsub {
|
||||
position: relative;
|
||||
box-sizing: border-box;
|
||||
background: #f1f1f1;
|
||||
padding: 20px;
|
||||
margin: 0 0 60px 0;
|
||||
}
|
||||
.um-admin-drag-rowsub:last-child {margin-bottom: 0}
|
||||
|
||||
.um-admin-drag-rowsub-icons {
|
||||
position: absolute;
|
||||
right: 0;
|
||||
top: -30px;
|
||||
height: 30px;
|
||||
}
|
||||
|
||||
.um-admin-drag-col {
|
||||
float: left;
|
||||
width: 100%;
|
||||
background: #fff;
|
||||
border: 1px dashed #bbb;
|
||||
box-sizing: border-box;
|
||||
padding: 20px;
|
||||
}
|
||||
|
||||
.um-admin-drag-col.cols-3 {width: 32%;}
|
||||
.um-admin-drag-col.cols-3.cols-last {width: 32%;}
|
||||
.um-admin-drag-col.cols-3.cols-middle {width: 32%;margin: 0 2%;}
|
||||
|
||||
.um-admin-drag-col.cols-1 {width: 100%;}
|
||||
.um-admin-drag-col.cols-1.cols-last {width: 100%;}
|
||||
.um-admin-drag-col.cols-1.cols-middle {}
|
||||
|
||||
.um-admin-drag-col.cols-2 {width: 49%;margin: 0 1% 0 0}
|
||||
.um-admin-drag-col.cols-2.cols-last {width: 49%;margin: 0 0 0 1%;}
|
||||
.um-admin-drag-col.cols-2.cols-middle {}
|
||||
|
||||
.um-admin-drag-addrow {
|
||||
text-align: center;
|
||||
font-size: 14px;
|
||||
color: #888;
|
||||
cursor: pointer;
|
||||
border: 1px dashed #bbb;
|
||||
padding: 10px 0;
|
||||
margin: 20px 0 0 0;
|
||||
}
|
||||
.um-admin-drag-addrow i {
|
||||
font-size: 23px !important;
|
||||
margin: 0 !important;
|
||||
}
|
||||
.um-admin-drag-addrow:hover {color: #0085ba}
|
||||
|
||||
/*
|
||||
- Fields
|
||||
*/
|
||||
|
||||
.um-admin-drag-fld {
|
||||
display: block;
|
||||
position: relative;
|
||||
border: 1px solid #dddddd;
|
||||
margin: 0 0 15px 0;
|
||||
background: #F5F5F5;
|
||||
cursor: move !important;
|
||||
}
|
||||
|
||||
.um-admin-drag-fld-title i {
|
||||
width: 24px;
|
||||
display: inline-block;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.um-admin-drag-fld.um-field-type-group {background: #555;border: 0}
|
||||
.um-admin-drag-fld-title.um-field-type-group,.um-admin-drag-fld-type.um-field-type-group {color: #fff}
|
||||
.um-admin-drag-group {background: #FCFCFC;cursor: default;padding: 20px;border: 1px dashed #bbb;}
|
||||
.um-admin-drag-col.cols-3 .um-admin-drag-fld-icons.um-field-type-group{float: left;position: relative;bottom: auto;right: auto;height: 30px;display: block;}
|
||||
.um-admin-drag-fld-icons.um-field-type-group a.um_admin_duplicate_field {display: none !important}
|
||||
|
||||
.um-admin-drag-fld-title,
|
||||
.um-admin-drag-fld-type {
|
||||
float: left;
|
||||
font-weight: bold;
|
||||
font-size: 13px;
|
||||
color: #666;
|
||||
height: 30px;
|
||||
line-height: 30px;
|
||||
margin: 0 0 0 20px;
|
||||
}
|
||||
|
||||
.um-admin-drag-fld-type {
|
||||
font-weight: 400;
|
||||
color: #999;
|
||||
}
|
||||
|
||||
.um-admin-drag-fld-icons {
|
||||
float: right;
|
||||
}
|
||||
|
||||
/*
|
||||
- Responsive cols appearance
|
||||
*/
|
||||
|
||||
.um-admin-drag-col.cols-3 .um-admin-drag-fld-title,
|
||||
.um-admin-drag-col.cols-3 .um-admin-drag-fld-type {
|
||||
height: auto;
|
||||
line-height: 18px;
|
||||
margin: 10px;
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.um-admin-drag-col.cols-3 .um-admin-drag-fld-type {
|
||||
margin: 10px;
|
||||
}
|
||||
|
||||
.um-admin-drag-col.cols-3 .um-admin-drag-fld-icons {
|
||||
float: none;
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
height: 30px;
|
||||
display: none;
|
||||
}
|
||||
|
||||
.um-admin-drag-col.cols-3 .um-admin-drag-fld:hover .um-admin-drag-fld-icons{display: block;}
|
||||
|
||||
/*
|
||||
- Icons
|
||||
*/
|
||||
|
||||
.um-admin-drag-row-icons a,
|
||||
.um-admin-drag-row-icons span,
|
||||
.um-admin-drag-rowsub-icons a,
|
||||
.um-admin-drag-rowsub-icons span,
|
||||
.um-admin-drag-fld-icons a{
|
||||
text-decoration: none;
|
||||
color: #fff;
|
||||
width: 40px;
|
||||
height: 30px;
|
||||
line-height: 30px;
|
||||
text-align: center;
|
||||
display: block !important;
|
||||
float: left;
|
||||
/*background: #44b0ec;*/
|
||||
background: #0085ba;
|
||||
padding: 0 4px;
|
||||
transition: all .2s linear;
|
||||
border-left: 1px solid #379dd5;
|
||||
}
|
||||
|
||||
.um-admin-drag-row-icons span,
|
||||
.um-admin-drag-rowsub-icons span
|
||||
{cursor: move!important}
|
||||
|
||||
.um-admin-drag-row-icons a:hover,
|
||||
.um-admin-drag-row-icons span:hover,
|
||||
.um-admin-drag-rowsub-icons a:hover,
|
||||
.um-admin-drag-rowsub-icons span:hover,
|
||||
.um-admin-drag-fld-icons a:hover {background: #008ec2;/*background: #3396cd;*/}
|
||||
|
||||
.um-admin-drag-row-icons i,
|
||||
.um-admin-drag-rowsub-icons i,
|
||||
.um-admin-drag-fld-icons i{
|
||||
font-size: 18px !important;
|
||||
margin: 0 !important;
|
||||
top: 2px;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
/*
|
||||
- UI Placeholders
|
||||
*/
|
||||
|
||||
.um-row-placeholder {
|
||||
width: 100%;
|
||||
border: 2px dashed #aaa;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.um-rowsub-placeholder {
|
||||
width: 100%;
|
||||
border: 2px dashed #ccc;
|
||||
box-sizing: border-box;
|
||||
display: block;
|
||||
}
|
||||
|
||||
.um-fld-placeholder {
|
||||
display: block;
|
||||
border: 1px dashed #dddddd;
|
||||
background: #fff;
|
||||
box-sizing: border-box;
|
||||
width: 100%;
|
||||
}
|
||||
@@ -0,0 +1,67 @@
|
||||
.um-admin td, .um-admin th {
|
||||
-webkit-font-smoothing: antialiased !important;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
}
|
||||
|
||||
.um-admin.post-type-um_form .manage-column.column-id {width: 60px}
|
||||
.um-admin.post-type-um_form .manage-column.column-mode {width: 100px}
|
||||
.um-admin.post-type-um_form .manage-column.column-title {width: 200px}
|
||||
.um-admin.post-type-um_form .manage-column.column-shortcode {width: 200px}
|
||||
.um-admin.post-type-um_form .manage-column.column-impressions {width: 100px}
|
||||
.um-admin.post-type-um_form .manage-column.column-conversions {width: 100px}
|
||||
|
||||
.um-admin.post-type-um_directory .manage-column.column-id {width: 60px}
|
||||
.um-admin.post-type-um_directory .manage-column.column-title {width: 250px}
|
||||
|
||||
.um-admin.post-type-um_role .manage-column.column-title {width: 200px}
|
||||
.um-admin.post-type-um_role .manage-column.column-count {width: 150px}
|
||||
.um-admin.post-type-um_role .manage-column.column-core {width: 150px}
|
||||
|
||||
.um-admin.post-type-um_form td.column-shortcode,
|
||||
.um-admin.post-type-um_form td.column-id,
|
||||
.um-admin.post-type-um_directory td.column-shortcode,
|
||||
.um-admin.post-type-um_directory td.column-id,
|
||||
.um-admin.post-type-um_role td.column-count
|
||||
{font-size: 14px;}
|
||||
|
||||
.um-admin.users-php td.column-um_actions {padding-top: 12px}
|
||||
|
||||
.um-admin.users-php td.column-um_actions a.button {
|
||||
height: 29px !important;
|
||||
margin: 0 0 0 2px !important;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.um-admin-tag {
|
||||
display: inline-block;
|
||||
border-radius: 2px;
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
text-align: center;
|
||||
background: #0085ba;
|
||||
color: #fff;
|
||||
font-size: 14px;
|
||||
height: 34px;
|
||||
line-height: 34px;
|
||||
}
|
||||
.um-admin-tag.small {font-size: 13px;height:28px;line-height: 28px;display:inline;padding: 4px 10px;background: transparent;color: #666;border-radius:0;}
|
||||
.um-admin-tag.approved {border-left: 2px solid #7ACF58}
|
||||
.um-admin-tag.pending {border-left: 2px solid #C74A4A}
|
||||
|
||||
.um-admin-txtspace {margin: 0 0 0 10px;}
|
||||
|
||||
.um-adm-ico {
|
||||
font-size: 18px;
|
||||
width: 18px;
|
||||
text-align: center;
|
||||
display: inline-block;
|
||||
color: #7ACF58;
|
||||
}
|
||||
|
||||
.um-adm-ico.inactive {color: #C74A4A}
|
||||
.um-adm-ico.pointer {cursor: pointer}
|
||||
|
||||
.um-admin-icontext i {
|
||||
font-size: 18px;
|
||||
margin: 0 5px 0 0;
|
||||
}
|
||||
@@ -0,0 +1,212 @@
|
||||
#um-extensions-wrap a.plugin-image,
|
||||
#um-extensions-wrap a.plugin-image img {
|
||||
max-width: 100%;
|
||||
display: block;
|
||||
}
|
||||
|
||||
#um-extensions-wrap .plugin-card {
|
||||
width: calc( 33% - 8px );
|
||||
clear: none !important;
|
||||
margin-right: 8px !important;
|
||||
margin-left: 0 !important;
|
||||
}
|
||||
|
||||
|
||||
#um-extensions-wrap .plugin-image img {
|
||||
display: inline-block;
|
||||
width: 70px;
|
||||
margin: auto;
|
||||
/* padding-top: 40px; */
|
||||
border-radius: 500px;
|
||||
height: 70px;
|
||||
padding: 5px;
|
||||
background: #fff;
|
||||
box-shadow: 0 4px 6px rgba(50,50,93,.11), 0 1px 3px rgba(0,0,0,.08);
|
||||
margin-top: 20px;
|
||||
}
|
||||
|
||||
#um-extensions-wrap .plugin-card-top h3 {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
#um-extensions-wrap .plugin-card-top .desc {
|
||||
text-align: center;
|
||||
margin: 0 !important;
|
||||
padding: 10px 0 0 0 !important;
|
||||
}
|
||||
|
||||
#um-extensions-wrap .action-links {
|
||||
margin: 0 !important;
|
||||
padding: 20px 0 0 0 !important;
|
||||
position: static;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
#um-extensions-wrap .action-links ul {
|
||||
margin: 0 0 10px 0 !important;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
#um-extensions-wrap .action-links ul li {
|
||||
display: inline;
|
||||
float: left;
|
||||
clear: none;
|
||||
line-height: 28px;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
|
||||
@media (max-width: 992px) {
|
||||
#um-extensions-wrap .plugin-card {
|
||||
width: calc( 50% - 8px );
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 782px) {
|
||||
#um-extensions-wrap .plugin-card {
|
||||
width: calc( 100% - 8px );
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
#um-extensions-wrap .action-links ul li:last-child {
|
||||
float: right;
|
||||
}
|
||||
|
||||
|
||||
#um-extensions-wrap .plugin-card-top {
|
||||
min-height: 140px;
|
||||
}
|
||||
|
||||
@media screen and (max-width: 782px) {
|
||||
#um-extensions-wrap .plugin-card {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
#um-extensions-wrap .plugin-card-top {
|
||||
min-height: 120px;
|
||||
}
|
||||
}
|
||||
|
||||
#um-extensions-wrap .plugin-card .name,
|
||||
#um-extensions-wrap .plugin-card .desc {
|
||||
margin-left: 0;
|
||||
}
|
||||
|
||||
#um-metaboxes-general h2 sup {
|
||||
font-size: 14px;
|
||||
position: relative;
|
||||
font-weight: 400;
|
||||
background: #0085ba;
|
||||
color: #fff !important;
|
||||
padding: 2px 4px !important;
|
||||
border-radius: 3px;
|
||||
top: 5px;
|
||||
left: 3px;
|
||||
border: none !important;
|
||||
}
|
||||
|
||||
.wrap a.red, .wrap span.red {color:#C74A4A}
|
||||
.wrap span.ok {color:#7ACF58}
|
||||
|
||||
/* Misc */
|
||||
|
||||
.um-admin-dash-review {
|
||||
text-decoration: none !important;
|
||||
font-size: 16px;
|
||||
position: absolute;
|
||||
top: -2px;
|
||||
right: 4px;
|
||||
}
|
||||
|
||||
/* Dashboard widgets */
|
||||
|
||||
.p_seperate {
|
||||
margin-top: 12px;
|
||||
border-top: 1px solid #ddd;
|
||||
}
|
||||
|
||||
.um-metabox-holder p.sub {
|
||||
padding: 0 4px 2px 4px;
|
||||
margin: 0 0 8px 0;
|
||||
color: #8F8F8F;
|
||||
font-size: 14px;
|
||||
border-bottom: 1px solid #ECECEC;
|
||||
}
|
||||
|
||||
.um-metabox-holder .table {
|
||||
float: left;
|
||||
width: 45%;
|
||||
}
|
||||
|
||||
.um-metabox-holder a.warning {
|
||||
color: #C74A4A !important;
|
||||
background: transparent !important;
|
||||
border: 0;
|
||||
}
|
||||
|
||||
.um-metabox-holder .table_right {
|
||||
float: right;
|
||||
width: 45%;
|
||||
}
|
||||
|
||||
.um-metabox-holder td.b {
|
||||
padding-right: 6px;
|
||||
text-align: right;
|
||||
font-family: Georgia,"Times New Roman","Bitstream Charter",Times,serif;
|
||||
font-size: 14px;
|
||||
width: 1%;
|
||||
}
|
||||
|
||||
.um-metabox-holder td.b {
|
||||
text-align: right;
|
||||
font-family: Georgia,"Times New Roman","Bitstream Charter",Times,serif;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.um-metabox-holder table td {
|
||||
white-space: nowrap;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
.um-metabox-holder td.b a {
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
.um-metabox-holder .norm i {
|
||||
display: inline-block;
|
||||
width: 30px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.um-metabox-holder .norm p {
|
||||
margin: 5px 0;
|
||||
}
|
||||
|
||||
.um-metabox-holder .norm .count {
|
||||
font-size: 16px;
|
||||
font-family: Gerogia;
|
||||
color: #999;
|
||||
width: 40px;
|
||||
display: inline-block;
|
||||
text-align: right;
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
/* Share bar */
|
||||
|
||||
.um-admin-dash-share {
|
||||
margin-top: 11px !important;
|
||||
float: left;
|
||||
line-height: 28px;
|
||||
font-size: 15px;
|
||||
}
|
||||
|
||||
.um-admin-dash-share a {
|
||||
margin: 0 15px 0 0 !important;
|
||||
text-decoration: none !important;
|
||||
color: #777 !important;
|
||||
font-size: 22px !important;
|
||||
}
|
||||
.um-admin-dash-share a:hover {color: #0085ba !important}
|
||||
@@ -0,0 +1,61 @@
|
||||
/*
|
||||
- General
|
||||
*/
|
||||
|
||||
.um-admin-metabox * {
|
||||
-webkit-font-smoothing: antialiased !important;
|
||||
-moz-osx-font-smoothing: grayscale !important;
|
||||
}
|
||||
|
||||
.um-admin-metabox h6 {
|
||||
font-size: 14px;
|
||||
margin: 12px 0 0 0;
|
||||
}
|
||||
|
||||
/*
|
||||
- Metabox layout
|
||||
*/
|
||||
|
||||
.um-admin.post-type-um_form div#submitdiv,
|
||||
.um-admin.post-type-um_form div#side-sortables
|
||||
{display:none}
|
||||
|
||||
/*
|
||||
- Boxed Links
|
||||
*/
|
||||
|
||||
.um-admin-boxed-links {
|
||||
width: 100%;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.um-admin-boxed-links a {
|
||||
width: 33.3%;
|
||||
float: left;
|
||||
border-left: 1px solid #fff;
|
||||
border-right: 1px solid #fff;
|
||||
padding: 30px 25px !important;
|
||||
background: #f8f8f8;
|
||||
text-align: center;
|
||||
display: inline-block !important;
|
||||
font-size: 14px;
|
||||
transition: all .2s linear;
|
||||
text-decoration: none;
|
||||
color: #666;
|
||||
margin: 0 !important;
|
||||
box-sizing: border-box !important;
|
||||
border-radius: 2px;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.um-admin-boxed-links i {
|
||||
font-size: 28px;
|
||||
vertical-align: middle;
|
||||
margin: 0 10px 0 0;
|
||||
}
|
||||
|
||||
.um-admin-boxed-links a:hover {
|
||||
background: #eee;
|
||||
}
|
||||
@@ -0,0 +1,174 @@
|
||||
.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;
|
||||
}
|
||||
|
||||
input[type=text].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=text].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=text].um-forms-field.um-small-field,
|
||||
select.um-forms-field.um-small-field,
|
||||
textarea.um-forms-field.um-small-field {
|
||||
width:25% !important;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.um-multi-text-list,
|
||||
.um-multi-selects-list {
|
||||
float: left;
|
||||
width:100%;
|
||||
margin: 0 0 10px 0;
|
||||
}
|
||||
|
||||
.um-hidden-multi-text,
|
||||
.um-hidden-multi-selects {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
.um-multi-text-option-line,
|
||||
.um-multi-selects-option-line {
|
||||
float:left;
|
||||
width:100%;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
clear:both;
|
||||
}
|
||||
|
||||
.um-multi-text-option-line .um-field-wrapper,
|
||||
.um-multi-selects-option-line .um-field-wrapper {
|
||||
float:left;
|
||||
width: calc( 100% - 60px );
|
||||
line-height: 30px;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.um-multi-text-option-line .um-field-wrapper input,
|
||||
.um-multi-selects-option-line .um-field-wrapper select {
|
||||
float:left;
|
||||
width: 100%;
|
||||
margin:0;
|
||||
}
|
||||
|
||||
|
||||
.um-multi-text-option-line .um-field-control,
|
||||
.um-multi-selects-option-line .um-field-control {
|
||||
float:left;
|
||||
width: 60px;
|
||||
line-height: 30px;
|
||||
padding: 0 10px;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.um-form-table .description {
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
|
||||
.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) {
|
||||
.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-form-fields-section label span {
|
||||
width:calc( 100% - 30px );
|
||||
}
|
||||
|
||||
.um-multi-text-option-line,
|
||||
.um-multi-selects-option-line {
|
||||
margin: 0 0 6px 0;
|
||||
}
|
||||
|
||||
.um-forms-line label {
|
||||
float:left;
|
||||
width:100%;
|
||||
}
|
||||
|
||||
|
||||
.um-form-table.um-third-column .um-forms-line th,
|
||||
.um-form-table.um-half-column .um-forms-line th,
|
||||
.um-form-table.um-two-thirds-column .um-forms-line th {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*Multi text filed */
|
||||
.um-forms-line .um-text-delete {
|
||||
color: #a00;
|
||||
float:left;
|
||||
}
|
||||
|
||||
.um-forms-line .um-text-delete:hover {
|
||||
color: red;
|
||||
}
|
||||
|
||||
.um-forms-line .um-multi-text-add-option {
|
||||
margin-bottom: 14px;
|
||||
}
|
||||
|
||||
|
||||
/* Media uploader */
|
||||
.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;
|
||||
}
|
||||
@@ -0,0 +1,181 @@
|
||||
.um-admin-notice {
|
||||
border-color: #0085ba !important;
|
||||
color: #555;
|
||||
}
|
||||
|
||||
.um-admin-notice a.button-primary {
|
||||
background-color: #0085ba !important;
|
||||
border-color: #0085ba !important;
|
||||
}
|
||||
|
||||
.um-admin-notice a.button-primary:hover {
|
||||
background-color: #008ec2 !important;
|
||||
border-color: #008ec2 !important;
|
||||
}
|
||||
|
||||
.um-admin-notice a.button-secondary {opacity: 0.7}
|
||||
.um-admin-notice a.button-secondary:hover {opacity: 0.9}
|
||||
.um-admin-notice a {text-decoration: none;color: #0085ba}
|
||||
.um-admin-notice a:hover {color: #44b0ec}
|
||||
|
||||
.um-filter {
|
||||
padding: 12px;
|
||||
border-color: #ddd !important;
|
||||
margin: 20px 0 0 0 !important;
|
||||
font-size: 14px;
|
||||
line-height: 24px;
|
||||
}
|
||||
|
||||
/*
|
||||
- General metabox styling
|
||||
*/
|
||||
|
||||
#um-admin-access-settings h3 {
|
||||
padding: 10px 20px 10px 60px;
|
||||
color: #fff;
|
||||
background: #0085ba url(../img/logo-small.png) no-repeat 12px center;
|
||||
font-weight: bold;
|
||||
font-size: 14px !important;
|
||||
-webkit-font-smoothing: antialiased !important;
|
||||
-moz-osx-font-smoothing: grayscale !important;
|
||||
}
|
||||
|
||||
#um-admin-access-settings h4 { margin: 10px 0 4px 0!important}
|
||||
|
||||
#um-admin-access-settings div.handlediv {
|
||||
color: #fff !important;
|
||||
-webkit-font-smoothing: antialiased !important;
|
||||
-moz-osx-font-smoothing: grayscale !important;
|
||||
}
|
||||
|
||||
#um-admin-access-settings p {font-size: 13px}
|
||||
|
||||
#um-admin-access-settings input[type=text] {font-size: 13px}
|
||||
|
||||
/*
|
||||
- Nav Menu
|
||||
*/
|
||||
|
||||
.um-nav-edit * {
|
||||
-webkit-font-smoothing: antialiased !important;
|
||||
-moz-osx-font-smoothing: grayscale !important;
|
||||
}
|
||||
|
||||
.um-nav-edit-h2 {
|
||||
padding: 10px 20px 10px 60px;
|
||||
margin: 14px 12px 0 0;
|
||||
border-radius: 3px;
|
||||
color: #fff;
|
||||
background: #0085ba url(../img/logo-small.png) no-repeat 12px center;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.um-nav-mode {margin-top:10px}
|
||||
.um-nav-roles {display: none;margin-top:5px}
|
||||
|
||||
/*
|
||||
- jQuery Tooltips
|
||||
*/
|
||||
|
||||
.um-admin-tip {
|
||||
margin: 0 0 0 2px;
|
||||
color: #0085ba !important;
|
||||
vertical-align: middle;
|
||||
position: relative;
|
||||
top: -3px;
|
||||
opacity: 0.8;
|
||||
}
|
||||
.um-admin-tip.n {margin-left: 5px}
|
||||
.um-admin-tip i {cursor: pointer; vertical-align: middle; font-size: 20px; line-height: 20px;color: #0085ba !important;}
|
||||
a.um-delete{ color: #a00; }
|
||||
|
||||
|
||||
|
||||
/* Roles metabox + table features */
|
||||
.um-metabox-section .description {
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
.um-metabox-section th {
|
||||
width: 35%;
|
||||
}
|
||||
|
||||
.wp-list-table.roles .column-core,
|
||||
.wp-list-table.roles .column-users,
|
||||
.wp-list-table.roles .column-admin_access {
|
||||
width:15%;
|
||||
text-align: center !important;
|
||||
}
|
||||
|
||||
@media screen and (max-width: 782px) {
|
||||
.wp-list-table.roles .column-core,
|
||||
.wp-list-table.roles .column-users,
|
||||
.wp-list-table.roles .column-admin_access {
|
||||
text-align: left !important;
|
||||
}
|
||||
}
|
||||
|
||||
#um-admin-form-wp-capabilities .um-metadata-line th {
|
||||
width: auto;
|
||||
}
|
||||
|
||||
#um-admin-form-wp-capabilities .um-metadata-line td {
|
||||
width: 20px;
|
||||
}
|
||||
|
||||
#um_edit_role #titlewrap > span {
|
||||
width: 40px;
|
||||
font-size: 24px;
|
||||
float:left;
|
||||
display: block;
|
||||
line-height: 37px;
|
||||
}
|
||||
|
||||
#um_edit_role #title {
|
||||
width: calc( 100% - 40px );
|
||||
float:left;
|
||||
}
|
||||
|
||||
#um-roles .row-actions .reset a {
|
||||
color:#a00;
|
||||
}
|
||||
|
||||
#um-roles .row-actions .reset a:hover {
|
||||
color:red;
|
||||
}
|
||||
|
||||
|
||||
/*Tooltip*/
|
||||
.ui-tooltip.um_tooltip {
|
||||
padding: 8px;
|
||||
color: #eeeeee;
|
||||
background-color: #333;
|
||||
position: absolute;
|
||||
z-index: 1000000;
|
||||
max-width: 300px;
|
||||
font-size: 12px;
|
||||
border-radius: 5px;
|
||||
}
|
||||
|
||||
.um_tooltip.dashicons,
|
||||
.um_tooltip.dashicons:before {
|
||||
height:22px;
|
||||
}
|
||||
|
||||
.um_tooltip.dashicons-editor-help::before {
|
||||
float: left;
|
||||
font-size: 20px;
|
||||
line-height: 20px;
|
||||
color: #333 !important;
|
||||
}
|
||||
.um_tooltip {
|
||||
cursor: pointer;
|
||||
vertical-align: middle;
|
||||
}
|
||||
.um_tooltip:hover {
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
.um_tooltip:hover:before {
|
||||
opacity: 0.8;
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
ul#adminmenu a.wp-has-current-submenu:after,ul#adminmenu>li.current>a.current:after {display: none !important}
|
||||
|
||||
ul#adminmenu li.wp-has-submenu.wp-not-current-submenu:hover:after{right:-9999999px}
|
||||
@@ -0,0 +1,260 @@
|
||||
/*
|
||||
- Welcome
|
||||
*/
|
||||
|
||||
.um-about-wrap * {
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
}
|
||||
|
||||
.um-about-wrap a.um-about-icon {
|
||||
margin: 0 0 0 15px !important;
|
||||
padding: 0 !important;
|
||||
text-decoration: none !important;
|
||||
color: #777 !important;
|
||||
font-size: 22px !important;
|
||||
}
|
||||
|
||||
.um-about-wrap a.um-about-icon:hover {color: #0085ba !important}
|
||||
|
||||
.um-badge {
|
||||
color: #fff;
|
||||
background: none !important;
|
||||
background: #0085ba url(../img/logo_small.png) no-repeat center 0px !important;
|
||||
}
|
||||
|
||||
.um-about-wrap .ultimatemember-actions a.button-primary,
|
||||
.um-about-wrap .ultimatemember-actions a.button {
|
||||
vertical-align: top;
|
||||
margin: 0 5px 0 0;
|
||||
}
|
||||
|
||||
.changelog a.button-primary {
|
||||
height: 40px;
|
||||
line-height: 38px;
|
||||
}
|
||||
|
||||
.um-about-wrap a {text-decoration: none}
|
||||
|
||||
/*
|
||||
- General
|
||||
*/
|
||||
|
||||
body.um-admin-modal-open {
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.um-admin #major-publishing-actions{background-color: #fff !important;border-top:0}
|
||||
|
||||
.um-admin-hide {display: none}
|
||||
|
||||
.um-admin-field {
|
||||
display: block;
|
||||
width: 100%;
|
||||
margin-top: 10px;
|
||||
}
|
||||
|
||||
.um-admin-field a.button {
|
||||
position: relative;
|
||||
top: 1px;
|
||||
height: 30px !important;
|
||||
}
|
||||
|
||||
.um-admin-half {
|
||||
float: left;
|
||||
width: 48%;
|
||||
}
|
||||
|
||||
.um-admin-tri {
|
||||
float: left;
|
||||
width: 33%;
|
||||
}
|
||||
|
||||
.um-admin-left{float: left}
|
||||
.um-admin-right {float: right}
|
||||
.um-admin-clear {clear: both}
|
||||
|
||||
.um-admin a.um-admin-activebg,
|
||||
.um-admin a.um-admin-activebg:hover{
|
||||
/*background: #3ba1da;*/
|
||||
background: #0085ba;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.um-admin a.button i,
|
||||
.um-admin a.button-primary i {
|
||||
font-size: 15px !important;
|
||||
height: 15px !important;
|
||||
width: 15px !important;
|
||||
text-align: center !important;
|
||||
margin: 0 5px 0 0 !important;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.um-admin a.button i:before,
|
||||
.um-admin a.button-primary i:before {
|
||||
position: relative;
|
||||
top: 1px;
|
||||
}
|
||||
|
||||
/*
|
||||
- Form Inputs
|
||||
*/
|
||||
|
||||
.um-admin-metabox h3 {
|
||||
padding-left: 0 !important;
|
||||
}
|
||||
|
||||
.um-admin-metabox h4 {
|
||||
font-size: 14px;
|
||||
background: #f5f5f5;
|
||||
padding: 8px 4px;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.um-admin-metabox p {margin: 10px 0 0 0}
|
||||
|
||||
.um-admin-metabox label{
|
||||
display: block;
|
||||
cursor: default;
|
||||
margin: 0 0 8px 0 !important;
|
||||
padding: 0!important;
|
||||
font-size: 13px;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.um-admin-metabox input[type=text]:disabled{
|
||||
opacity: 0.7 !important;
|
||||
color: #aaa !important;
|
||||
}
|
||||
|
||||
.um-admin-metabox input[type=text] {
|
||||
height: auto !important;
|
||||
}
|
||||
|
||||
.um-admin-metabox input[type=text],
|
||||
.um-admin-metabox textarea {
|
||||
width: 100%;
|
||||
max-width: 100%;
|
||||
display: block;
|
||||
box-sizing: border-box !important;
|
||||
font-size: 13px !important;
|
||||
line-height: 1.4em !important;
|
||||
padding: 4px 10px !important;
|
||||
}
|
||||
|
||||
.um-admin-metabox textarea {
|
||||
padding: 8px !important;
|
||||
line-height: 1.6em;
|
||||
color: #888 !important;
|
||||
}
|
||||
|
||||
.um-admin-metabox input[type=text].um-admin-error,
|
||||
.um-admin-metabox textarea.um-admin-error
|
||||
{border-color: #C74A4A!important}
|
||||
|
||||
.um-admin-metabox input[type=text].small {width: 54px}
|
||||
|
||||
.um-admin-metabox textarea {min-height: 100px;height: 100px}
|
||||
.um-admin-metabox textarea.tall {min-height: 200px;height: 200px}
|
||||
|
||||
.wp-picker-container input.wp-color-picker[type="text"] {
|
||||
width: 68px !important;
|
||||
float: left !important;
|
||||
padding: 2px 4px !important;
|
||||
border-width: 1px !important;
|
||||
}
|
||||
|
||||
/*
|
||||
- Error blocks
|
||||
*/
|
||||
|
||||
.um-admin-error-block, .um-admin-success-block{
|
||||
display: none;
|
||||
width: 100%;
|
||||
background: #C74A4A;
|
||||
border-radius: 3px;
|
||||
color: #fff;
|
||||
box-sizing: border-box;
|
||||
position: relative;
|
||||
padding: 12px;
|
||||
font-size: 13px;
|
||||
line-height: 1em !important;
|
||||
margin: 0 0 16px 0;
|
||||
}
|
||||
|
||||
.um-admin-success-block {
|
||||
background: #7ACF58;
|
||||
}
|
||||
|
||||
/*
|
||||
- Yes or NO UI
|
||||
*/
|
||||
|
||||
p.disabled-on-off .um-admin-yesno {
|
||||
opacity: 0.5!important;
|
||||
cursor: default !important;
|
||||
}
|
||||
p.disabled-on-off .um-admin-yesno *{
|
||||
cursor: default !important;
|
||||
}
|
||||
|
||||
.um-admin-yesno {
|
||||
width: 100px !important;
|
||||
height: 26px;
|
||||
display: block;
|
||||
position: relative;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.um-admin-yesno span.btn {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: -2px;
|
||||
width: 50px;
|
||||
height: 28px;
|
||||
text-align: center;
|
||||
background: #f9f9f9;
|
||||
z-index: 999;
|
||||
border-radius: 3px;
|
||||
cursor: pointer;
|
||||
border: solid 1px #D0D9DB;
|
||||
margin: 0;
|
||||
padding: 0 !important;
|
||||
}
|
||||
|
||||
.um-admin-yesno span.btn.pos-1 {left: 48px}
|
||||
|
||||
.um-admin-yesno span.yes, .um-admin-yesno span.no {
|
||||
width: 50px;
|
||||
float: left;
|
||||
line-height: 24px;
|
||||
height: 26px;
|
||||
cursor: default;
|
||||
font-size: 14px;
|
||||
color: #fff;
|
||||
padding: 0 0 0 10px;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.um-admin-yesno .yes {
|
||||
background: #0085ba;
|
||||
border-radius: 3px 0 0 3px;
|
||||
border: 1px solid rgba(0,0,0,.2);
|
||||
}
|
||||
|
||||
.um-admin-yesno .no {
|
||||
padding: 0 10px 0 0 !important;
|
||||
text-align: right;
|
||||
float: right;
|
||||
background: #fff;
|
||||
color: #222 !important;
|
||||
border-radius: 0 3px 3px 0;
|
||||
border: 1px solid #ddd;
|
||||
}
|
||||
|
||||
.um-admin.users-php .subsubsub li.subsep {
|
||||
display: block;
|
||||
visibility: hidden;
|
||||
height: 0;
|
||||
}
|
||||
@@ -0,0 +1,298 @@
|
||||
/*
|
||||
- Overlay
|
||||
*/
|
||||
|
||||
.um-admin-overlay {
|
||||
background: rgba(0,0,0, .7);
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
z-index: 10000;
|
||||
}
|
||||
|
||||
/*
|
||||
- modal
|
||||
*/
|
||||
|
||||
.um-admin-modal * {
|
||||
-webkit-font-smoothing: antialiased !important;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
}
|
||||
|
||||
.um-admin-modal input[type=submit].button-primary,
|
||||
.um-admin-modal a.button-primary,
|
||||
.um-admin-modal a.button {
|
||||
padding: 0 12px !important;
|
||||
vertical-align: middle !important;
|
||||
}
|
||||
|
||||
.um-admin .um-admin-modal a.button i:before {
|
||||
display: block;
|
||||
top: 0px;
|
||||
}
|
||||
|
||||
.um-admin-modal input[type=submit].button-primary {
|
||||
line-height: 24px !important;
|
||||
}
|
||||
|
||||
.um-admin-modal {
|
||||
border-radius: 3px;
|
||||
background: #fff;
|
||||
position: fixed;
|
||||
top: 50% !important;
|
||||
left: 50% !important;
|
||||
display: none;
|
||||
z-index: 10001;
|
||||
box-sizing: border-box;
|
||||
|
||||
width: 730px;
|
||||
margin-left: -365px;
|
||||
}
|
||||
|
||||
.um-admin-modal.normal {width: 730px;margin-left: -365px;}
|
||||
.um-admin-modal.smaller {width: 500px;margin-left: -250px;}
|
||||
.um-admin-modal.small {width: 400px;margin-left: -200px;}
|
||||
|
||||
.um-admin-modal-close {
|
||||
position: absolute;
|
||||
color: #fff !important;
|
||||
right: 16px;
|
||||
top: 14px;
|
||||
font-size: 22px;
|
||||
text-decoration: none;
|
||||
opacity: 0.4;
|
||||
}
|
||||
.um-admin-modal-close:hover{opacity:1}
|
||||
|
||||
.um-admin-modal-head {
|
||||
padding: 4px 20px;
|
||||
background: #0085ba;
|
||||
position: relative;
|
||||
border-radius: 3px 3px 0 0;
|
||||
}
|
||||
|
||||
.um-admin-modal-body {
|
||||
padding: 10px 20px 10px 20px;
|
||||
max-height: 500px;
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
.um-admin-modal-body.um-admin-metabox label {margin: 0!important}
|
||||
|
||||
.um-admin-modal.loading .um-admin-modal-body {
|
||||
height: 200px;
|
||||
background: url(../img/ajax-loader.gif) no-repeat center;
|
||||
}
|
||||
|
||||
.um-admin-modal-foot {
|
||||
padding: 20px 0 !important;
|
||||
border-top: 1px solid #ddd;
|
||||
text-align: center;
|
||||
background: #eee;
|
||||
border-radius: 0 0 3px 3px;
|
||||
}
|
||||
|
||||
.um-admin-modal-foot a,
|
||||
.um-admin-modal-foot input{
|
||||
margin: 0 10px !important;
|
||||
font-size: 14px !important;
|
||||
}
|
||||
|
||||
.um-admin-modal h3 {
|
||||
font-size: 14px;
|
||||
line-height: 14px;
|
||||
font-weight: normal;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.um-admin-modal h4 {
|
||||
margin: 0 0 10px 0 !important;
|
||||
}
|
||||
|
||||
.um-admin-modal label,
|
||||
.um-admin-modal p {
|
||||
font-size: 13px;
|
||||
color: #aaa;
|
||||
}
|
||||
|
||||
.um-admin-infobox p,
|
||||
.um-admin-infobox label {
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.um-admin-infobox p {
|
||||
border-top: 1px solid #e5e5e5;
|
||||
padding-top: 15px;
|
||||
}
|
||||
|
||||
.um-admin-infobox label {
|
||||
font-weight: bold;
|
||||
display: block;
|
||||
color: #333;
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
/*
|
||||
- Conditional fields
|
||||
*/
|
||||
|
||||
.um-admin-btn-toggle {
|
||||
padding: 10px 0;
|
||||
}
|
||||
|
||||
.um-admin-btn-toggle p {
|
||||
margin: 0 5px 0 0 !important;
|
||||
}
|
||||
|
||||
.um-admin-btn-toggle p.um-admin-reset-conditions {
|
||||
margin: 0 0 5px 0 !important;
|
||||
}
|
||||
|
||||
.um-admin-btn-toggle a {
|
||||
text-decoration: none;
|
||||
color: #999;
|
||||
}
|
||||
|
||||
.um-admin-btn-toggle a.active, .um-admin-btn-toggle a.active:hover {
|
||||
color: #0085ba;
|
||||
}
|
||||
|
||||
.um-admin-btn-toggle i {
|
||||
margin: 0 5px 0 0 !important;
|
||||
height: 100%;
|
||||
color: #666;
|
||||
position: relative;
|
||||
top: 1px;
|
||||
}
|
||||
|
||||
.um-admin-btn-content {
|
||||
display: none;
|
||||
padding: 10px 0 0 0;
|
||||
}
|
||||
|
||||
.um-admin-btn-content p {
|
||||
float: left;
|
||||
margin-right: 10px !important;
|
||||
padding: 0 !important;
|
||||
}
|
||||
|
||||
.dynamic-mce-content {display: none}
|
||||
|
||||
/*
|
||||
- Buttons and Links
|
||||
*/
|
||||
|
||||
.um-admin-btns {
|
||||
line-height: 1.5em;
|
||||
margin: 0 0 5px 0;
|
||||
}
|
||||
|
||||
.um-admin-btns a {
|
||||
margin: 0 3px 8px 0!important;
|
||||
font-size: 12px !important;
|
||||
display: inline-block !important;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.um-admin-btns a.button.with-icon {
|
||||
padding-right: 25px !important;
|
||||
}
|
||||
.um-admin-btns a span {
|
||||
color: #aaa;
|
||||
position: absolute !important;
|
||||
width: 25px;
|
||||
text-align: center;
|
||||
right: 0;
|
||||
top: 0;
|
||||
font-size: 15px !important;
|
||||
}
|
||||
|
||||
.um-admin-btns a span.remove:before{
|
||||
font-family: "Ionicons" !important;
|
||||
content: "\f128";
|
||||
}
|
||||
.um-admin-btns a span:hover{color: #cb3838}
|
||||
|
||||
/*
|
||||
- WP Editor
|
||||
*/
|
||||
|
||||
.um-admin-modal-body.um-admin-metabox .um-admin-editor-h {
|
||||
margin-top: 12px;
|
||||
}
|
||||
|
||||
.um-admin-modal-body.um-admin-metabox .um-admin-editor-h label,
|
||||
.um-admin-modal-body.um-admin-metabox .wp-editor-wrap
|
||||
{margin: 0 0 4px 0 !important}
|
||||
|
||||
.um-admin-modal-body.um-admin-metabox .wp-editor-wrap textarea {
|
||||
border: 0 !important;
|
||||
}
|
||||
|
||||
/*
|
||||
- Boxes / Icons
|
||||
*/
|
||||
|
||||
#UM_fonticons div.um-admin-metabox {
|
||||
padding-bottom: 22px !important;
|
||||
}
|
||||
|
||||
p._icon_search{
|
||||
position: relative;
|
||||
width: 85% !important;
|
||||
margin: 0 auto !important;
|
||||
padding: 12px 0 0 0 !important;
|
||||
}
|
||||
|
||||
p._icon_search:before {
|
||||
position: absolute;
|
||||
right: 6px;
|
||||
top: 12px;
|
||||
font-size: 20px;
|
||||
content: "\f4a4";
|
||||
font-family: "Ionicons";
|
||||
color: #999;
|
||||
}
|
||||
p._icon_search input[type=text]{padding-right: 40px!important}
|
||||
|
||||
.um-admin-icons {
|
||||
padding: 0 0 15px 12px;
|
||||
float: left;
|
||||
}
|
||||
|
||||
.um-admin-icons span {
|
||||
cursor: pointer;
|
||||
float: left;
|
||||
margin: 5px;
|
||||
color: #777;
|
||||
border: 4px solid #eee;
|
||||
border-radius: 3px;
|
||||
}
|
||||
.um-admin-icons span:hover,
|
||||
.um-admin-icons span.highlighted
|
||||
{color: #0085ba;border-color: #0085ba}
|
||||
|
||||
.um-admin-icons i{vertical-align: middle !important;font-size: 24px;width: 24px;text-align: center;padding: 15px 20px;display: inline-block;}
|
||||
|
||||
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;}
|
||||
@@ -0,0 +1,59 @@
|
||||
.um-admin-yesno span.yes, .um-admin-yesno span.no {
|
||||
padding: 0 10px 0 0;
|
||||
}
|
||||
|
||||
.um-admin-drag-ctrls-demo.um-admin-drag-ctrls {
|
||||
left: 12px;
|
||||
right: auto;
|
||||
}
|
||||
|
||||
.um-admin-drag-row-icons {
|
||||
left: 0;
|
||||
right: auto;
|
||||
}
|
||||
|
||||
.um-admin-drag-ctrls.columns {
|
||||
right: 0 !important;
|
||||
left: auto;
|
||||
}
|
||||
|
||||
.um-admin-drag-ctrls.columns a {
|
||||
float: right;
|
||||
}
|
||||
|
||||
.um-admin-drag-rowsub-icons {
|
||||
right: auto;
|
||||
left: 0;
|
||||
}
|
||||
|
||||
.um-admin-drag-row-icons a {
|
||||
float: right;
|
||||
}
|
||||
|
||||
.um-admin-drag-fld-icons a {
|
||||
float: right;
|
||||
}
|
||||
|
||||
.um-admin-drag-fld-icons {
|
||||
float: left;
|
||||
}
|
||||
|
||||
.um-admin-drag-fld-title, .um-admin-drag-fld-type {
|
||||
float: right;
|
||||
margin: 0 20px 0 0;
|
||||
}
|
||||
|
||||
.select2-container .select2-choice > .select2-chosen {
|
||||
text-align: right !important;
|
||||
}
|
||||
|
||||
.select2-container .select2-choice .select2-arrow {
|
||||
border: none !important;
|
||||
right: auto !important;
|
||||
left: 0 !important;
|
||||
}
|
||||
|
||||
.select2-container .select2-choice > .select2-chosen {
|
||||
margin-right: 10px !important;
|
||||
margin-left: 26px !important;
|
||||
}
|
||||
@@ -0,0 +1,193 @@
|
||||
/*body.um-admin .select2-container {margin-right: 2px!important;}
|
||||
|
||||
body.um-admin .select2-drop,
|
||||
body.um-admin .select2-drop.select2-drop-above,
|
||||
body.um-admin .select2-drop-active,
|
||||
body.um-admin .select2-container-multi .select2-choices
|
||||
{border: 1px solid #ddd !important}
|
||||
|
||||
body.um-admin .select2-container .select2-choice
|
||||
{
|
||||
height: 27px !important;
|
||||
line-height: 27px !important;
|
||||
border: 1px solid #ddd !important;
|
||||
color: #888 !important;
|
||||
}
|
||||
|
||||
body.um-admin .select2-container .select2-choice > .select2-chosen {
|
||||
font-size: 13px !important;
|
||||
}
|
||||
|
||||
body.um-admin .select2-container .select2-choice {
|
||||
font-size: 13px !important;
|
||||
}
|
||||
|
||||
body.um-admin .select2-container .select2-choice .select2-arrow:before {
|
||||
font-size: 23px !important;
|
||||
line-height: 27px;
|
||||
}
|
||||
|
||||
body.um-admin .select2-search-choice-close:before {
|
||||
font-size: 20px !important;
|
||||
color: #aaa;
|
||||
line-height: 27px;
|
||||
}
|
||||
|
||||
body.um-admin .select2-container-multi .select2-search-choice-close:before {
|
||||
font-size: 15px !important;
|
||||
}
|
||||
|
||||
body.um-admin .select2-search input[type=text] {
|
||||
font-size: 13px !important;
|
||||
}
|
||||
|
||||
body.um-admin .select2-results li {
|
||||
font-size: 13px !important;
|
||||
}
|
||||
|
||||
body.um-admin .select2-results .select2-no-results,
|
||||
body.um-admin .select2-results .select2-searching,
|
||||
body.um-admin .select2-results .select2-selection-limit {
|
||||
font-size: 13px !important;
|
||||
}
|
||||
|
||||
body.um-admin .select2-container-multi .select2-choices .select2-search-choice {
|
||||
line-height: 13px !important;
|
||||
font-size: 13px !important;
|
||||
}
|
||||
|
||||
body.um-admin .select2-drop-mask {
|
||||
z-index: 10020 !important;
|
||||
}
|
||||
|
||||
body.um-admin .select2-drop {
|
||||
z-index: 999999 !important;
|
||||
}
|
||||
|
||||
body.um-admin .select2-search {
|
||||
z-index: 10040 !important;
|
||||
}*/
|
||||
|
||||
/* Select2 4.0*/
|
||||
body.um-admin .select2.select2-container .select2-selection{
|
||||
display: block !important;
|
||||
height: 28px !important;
|
||||
padding: 0 0 0 12px !important;
|
||||
overflow: hidden !important;
|
||||
position: relative !important;
|
||||
white-space: nowrap !important;
|
||||
line-height: 25px !important;
|
||||
color: #666 !important;
|
||||
font-size: 13px !important;
|
||||
text-align: left !important;
|
||||
text-decoration: none !important;
|
||||
-moz-border-radius: 2px !important;
|
||||
-webkit-border-radius: 2px !important;
|
||||
border-radius: 2px !important;
|
||||
background-clip: padding-box !important;
|
||||
-webkit-touch-callout: none;
|
||||
-webkit-user-select: none;
|
||||
-moz-user-select: none;
|
||||
-ms-user-select: none;
|
||||
user-select: none;
|
||||
background: none !important;
|
||||
background-color: #fff !important;
|
||||
border: 2px solid #ddd !important;
|
||||
}
|
||||
body.um-admin .select2.select2-container .select2-selection .select2-selection__arrow b[role=presentation]{
|
||||
display:none;
|
||||
}
|
||||
body.um-admin .select2.select2-container .select2-selection .select2-selection__arrow:before{
|
||||
content: "\f3d0" !important;
|
||||
font-size: 27px !important;
|
||||
font-family: "Ionicons" !important;
|
||||
width: 100% !important;
|
||||
display: block;
|
||||
height: 100%;
|
||||
line-height: 28px;
|
||||
color: #aaaaaa;
|
||||
}
|
||||
body.um-admin .select2.select2-container .select2-selection .select2-selection__arrow {
|
||||
display: inline-block !important;
|
||||
width: 34px !important;
|
||||
height: 100% !important;
|
||||
position: absolute !important;
|
||||
right: 0 !important;
|
||||
top: 0 !important;
|
||||
-moz-border-radius: 0 2px 2px 0 !important;
|
||||
-webkit-border-radius: 0 2px 2px 0 !important;
|
||||
border-radius: 0 2px 2px 0 !important;
|
||||
background-clip: padding-box !important;
|
||||
text-align: center !important;
|
||||
background: transparent !important;
|
||||
border-left: 0 !important;
|
||||
}
|
||||
body.um-admin .select2-container.select2-container--open .select2-dropdown{
|
||||
border: 2px solid #ddd !important;
|
||||
}
|
||||
body.um-admin .select2-results li{
|
||||
list-style: none;
|
||||
display: list-item;
|
||||
background-image: none;
|
||||
font-size: 13px;
|
||||
margin: 5px !important;
|
||||
padding: 3px 0 !important;
|
||||
color: #666 !important;
|
||||
}
|
||||
body.um-admin .select2-results li {
|
||||
padding: 3px 7px 4px !important;
|
||||
cursor: pointer;
|
||||
min-height: 1em !important;
|
||||
}
|
||||
|
||||
body.um-admin .select2-container--default .select2-selection--single .select2-selection__rendered {
|
||||
line-height: 25px;
|
||||
}
|
||||
body.um-admin .select2-results li.select2-results__option.select2-results__option--highlighted{
|
||||
background: none !important;
|
||||
background: #f4f4f4 !important;
|
||||
color: #666 !important;
|
||||
}
|
||||
body.um-admin .select2-container--default .select2-results__option[aria-selected=true] {
|
||||
background: transparent !important;
|
||||
}
|
||||
body.um-admin .select2-selection__clear {
|
||||
right: 10px;
|
||||
font-size: 25px;
|
||||
color: #aaaaaa !important;
|
||||
font-weight: 300 !important;
|
||||
}
|
||||
|
||||
body.um-admin .select2-container--default .select2-selection--multiple .select2-selection__rendered {
|
||||
box-sizing: border-box;
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
padding: 0px;
|
||||
width: 100%;
|
||||
line-height: 20px;
|
||||
font-size: 13px;
|
||||
}
|
||||
|
||||
body.um-admin .select2.select2-container .select2-selection.select2-selection--multiple {
|
||||
height: auto !important;
|
||||
}
|
||||
|
||||
body.um-admin .select2-container--default .select2-selection--multiple .select2-selection__clear {
|
||||
cursor: pointer;
|
||||
float: right;
|
||||
margin-top: 0px;
|
||||
margin-right: 5px;
|
||||
font-size: 25px;
|
||||
}
|
||||
|
||||
body.um-admin .select2-container--default .select2-results__option[aria-selected=true] {
|
||||
background-color: #ddd !important;
|
||||
}
|
||||
|
||||
body.um-admin .select2-container .select2-search--inline {
|
||||
line-height: 37px !important;
|
||||
}
|
||||
|
||||
body.um-admin .select2-drop-active {
|
||||
z-index: 99999 !important;
|
||||
}
|
||||
@@ -0,0 +1,216 @@
|
||||
.um-settings-section .description {
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
.um-notification-status {
|
||||
margin-right: 18px;
|
||||
font-size: 28px;
|
||||
line-height: 22px;
|
||||
}
|
||||
|
||||
.um-notification-status {
|
||||
color: #a00;
|
||||
float:left;
|
||||
box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
-webkit-box-sizing: border-box;
|
||||
}
|
||||
|
||||
.um-notification-status.um-notification-is-active {
|
||||
color: #46b450;
|
||||
}
|
||||
|
||||
.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-nav-tab-wrapper {
|
||||
margin-right: 20px;
|
||||
}
|
||||
|
||||
#um-settings-emails {
|
||||
float:left;
|
||||
width:calc( 100% - 20px );
|
||||
margin-right: 20px;
|
||||
}
|
||||
#um-settings-form {
|
||||
float:left;
|
||||
width:calc( 100% - 10px );
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
#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 thead,
|
||||
.wrap-licenses tbody,
|
||||
.wrap-licenses tfoot,
|
||||
.wrap-licenses tr,
|
||||
.wrap-licenses td,
|
||||
.wrap-licenses th,
|
||||
.wrap-licenses caption {
|
||||
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: 220px;
|
||||
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.edd-license-expired {
|
||||
background-color: #e24e4e;
|
||||
color: #fff;
|
||||
border-color: #e24e4e;
|
||||
}
|
||||
|
||||
.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-missing,
|
||||
.wrap-licenses .edd-license-data.edd-license-invalid,
|
||||
.wrap-licenses .edd-license-data.edd-license-site_inactive,
|
||||
.wrap-licenses .edd-license-data.edd-license-item_name_mismatch {
|
||||
background-color: #ffebcd;
|
||||
border-color: #ffebcd;
|
||||
}
|
||||
.wrap-licenses .edd-license-data p {
|
||||
font-size: 13px;
|
||||
margin-top: 0;
|
||||
}
|
||||
.wrap-licenses .edd-license-data.license-expires-soon-notice a,
|
||||
.wrap-licenses .edd-license-data.edd-license-expired a {
|
||||
color: #fff;
|
||||
}
|
||||
.wrap-licenses .edd-license-data.license-expires-soon-notice a:hover,
|
||||
.wrap-licenses .edd-license-data.edd-license-expired a:hover {
|
||||
text-decoration: none;
|
||||
}
|
||||
.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) {
|
||||
.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%;
|
||||
}
|
||||
}
|
||||
|
After Width: | Height: | Size: 1.1 KiB |
|
After Width: | Height: | Size: 1.1 KiB |
|
After Width: | Height: | Size: 1.1 KiB |
|
After Width: | Height: | Size: 1.1 KiB |
|
After Width: | Height: | Size: 1.1 KiB |
|
After Width: | Height: | Size: 1.1 KiB |
|
After Width: | Height: | Size: 15 KiB |
|
After Width: | Height: | Size: 3.7 KiB |
|
After Width: | Height: | Size: 2.6 KiB |
|
After Width: | Height: | Size: 6.6 KiB |
|
After Width: | Height: | Size: 9.3 KiB |
@@ -0,0 +1,56 @@
|
||||
jQuery(document).ready(function() {
|
||||
|
||||
jQuery(document).ajaxStart(function(){
|
||||
jQuery('.tipsy').hide();
|
||||
});
|
||||
|
||||
jQuery(document).on('click', 'a[data-silent_action^="um_"]',function(){
|
||||
|
||||
if ( typeof jQuery(this).attr('disabled') !== 'undefined' )
|
||||
return false;
|
||||
|
||||
in_row = '';
|
||||
in_sub_row = '';
|
||||
in_column = '';
|
||||
in_group = '';
|
||||
|
||||
if ( jQuery('.um-col-demon-settings').data('in_column') ) {
|
||||
in_row = jQuery('.um-col-demon-settings').data('in_row');
|
||||
in_sub_row = jQuery('.um-col-demon-settings').data('in_sub_row');
|
||||
in_column = jQuery('.um-col-demon-settings').data('in_column');
|
||||
in_group = jQuery('.um-col-demon-settings').data('in_group');
|
||||
}
|
||||
|
||||
act_id = jQuery(this).data('silent_action');
|
||||
arg1 = jQuery(this).data('arg1');
|
||||
arg2 = jQuery(this).data('arg2');
|
||||
|
||||
jQuery('.tipsy').hide();
|
||||
|
||||
um_admin_remove_modal();
|
||||
|
||||
jQuery.ajax({
|
||||
url: um_admin_ajax_data.ajax_url,
|
||||
type: 'POST',
|
||||
data: { act_id : act_id, arg1 : arg1, arg2 : arg2, in_row: in_row, in_sub_row: in_sub_row, in_column: in_column, in_group: in_group },
|
||||
success: function(data){
|
||||
|
||||
jQuery('.um-col-demon-settings').data('in_row', '');
|
||||
jQuery('.um-col-demon-settings').data('in_sub_row', '');
|
||||
jQuery('.um-col-demon-settings').data('in_column', '');
|
||||
jQuery('.um-col-demon-settings').data('in_group', '');
|
||||
|
||||
um_admin_modal_responsive();
|
||||
um_admin_update_builder();
|
||||
|
||||
},
|
||||
error: function(data){
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
return false;
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
@@ -0,0 +1,44 @@
|
||||
/**
|
||||
This function updates the
|
||||
builder area with fields
|
||||
**/
|
||||
|
||||
function um_admin_update_builder() {
|
||||
|
||||
form_id = jQuery('.um-admin-builder').data('form_id');
|
||||
|
||||
jQuery('.tipsy').hide();
|
||||
|
||||
jQuery.ajax({
|
||||
url: um_admin_builder_data.ajax_url,
|
||||
type: 'POST',
|
||||
data: {
|
||||
form_id: form_id
|
||||
},
|
||||
success: function(data){
|
||||
|
||||
jQuery('.um-admin-drag-ajax').html(data);
|
||||
|
||||
jQuery('.tipsy').hide();
|
||||
|
||||
/* trigger columns at start */
|
||||
allow_update_via_col_click = false;
|
||||
jQuery('.um-admin-drag-ctrls.columns a.active').each(function(){
|
||||
jQuery(this).trigger('click');
|
||||
}).promise().done( function(){ allow_update_via_col_click = true; } );
|
||||
|
||||
UM_Rows_Refresh();
|
||||
|
||||
},
|
||||
error: function(data){
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
return false;
|
||||
|
||||
}
|
||||
|
||||
jQuery(document).ready(function() {
|
||||
|
||||
});
|
||||
@@ -0,0 +1,3 @@
|
||||
jQuery(document).ready(function() {
|
||||
|
||||
});
|
||||
@@ -0,0 +1,410 @@
|
||||
function UM_Drag_and_Drop(){
|
||||
|
||||
jQuery('.um-admin-drag-col,.um-admin-drag-group').sortable({
|
||||
items: '.um-admin-drag-fld',
|
||||
connectWith: '.um-admin-drag-col,.um-admin-drag-group',
|
||||
placeholder: "um-fld-placeholder",
|
||||
forcePlaceholderSize:true,
|
||||
update: function(event, ui){
|
||||
|
||||
jQuery('#publish').attr('disabled','disabled');
|
||||
|
||||
if ( ui.item.hasClass('um-field-type-group') && ui.item.parents('.um-field-type-group').length > 0 ) {
|
||||
|
||||
jQuery('.um-admin-drag-col,.um-admin-drag-group').sortable('cancel');
|
||||
|
||||
jQuery('#publish').removeAttr('disabled');
|
||||
|
||||
} else {
|
||||
|
||||
UM_Change_Field_Col();
|
||||
|
||||
UM_Change_Field_Grp();
|
||||
|
||||
UM_Rows_Refresh();
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
jQuery('.um-admin-drag-rowsubs').sortable({
|
||||
items: '.um-admin-drag-rowsub',
|
||||
placeholder: "um-rowsub-placeholder",
|
||||
forcePlaceholderSize:true,
|
||||
zIndex: 9999999999,
|
||||
update: function(){
|
||||
|
||||
jQuery('#publish').attr('disabled','disabled');
|
||||
|
||||
UM_update_subrows();
|
||||
|
||||
UM_Rows_Refresh();
|
||||
|
||||
}
|
||||
}).disableSelection();
|
||||
|
||||
jQuery('.um-admin-drag-rowsub').sortable({
|
||||
items: '.um-admin-drag-col',
|
||||
zIndex: 9999999999,
|
||||
update: function(){
|
||||
|
||||
jQuery('#publish').attr('disabled','disabled');
|
||||
|
||||
row = jQuery(this);
|
||||
row.find('.um-admin-drag-col').removeClass('cols-1 cols-2 cols-3 cols-last cols-middle');
|
||||
row.find('.um-admin-drag-col').addClass('cols-' + row.find('.um-admin-drag-col').length );
|
||||
row.find('.um-admin-drag-col:last').addClass('cols-last');
|
||||
if ( row.find('.um-admin-drag-col').length == 3 ) {row.find('.um-admin-drag-col:eq(1)').addClass('cols-middle');}
|
||||
|
||||
UM_Change_Field_Col();
|
||||
|
||||
UM_Change_Field_Grp();
|
||||
|
||||
UM_Rows_Refresh();
|
||||
|
||||
}
|
||||
}).disableSelection();
|
||||
|
||||
jQuery('.um-admin-drag-ajax').sortable({
|
||||
items: '.um-admin-drag-row',
|
||||
handle: ".um-admin-drag-row-start",
|
||||
zIndex: 9999999999,
|
||||
placeholder: "um-row-placeholder",
|
||||
forcePlaceholderSize:true,
|
||||
out: function(){
|
||||
jQuery('.tipsy').remove();
|
||||
},
|
||||
update: function(){
|
||||
|
||||
jQuery('#publish').attr('disabled','disabled');
|
||||
|
||||
UM_update_rows();
|
||||
|
||||
UM_Change_Field_Col();
|
||||
|
||||
UM_Change_Field_Grp();
|
||||
|
||||
UM_Rows_Refresh();
|
||||
|
||||
}
|
||||
}).disableSelection();
|
||||
|
||||
}
|
||||
|
||||
function UM_update_rows(){
|
||||
var c = 0;
|
||||
jQuery('a[data-remove_element="um-admin-drag-row"]').remove();
|
||||
jQuery('.um-admin-drag-row').each(function(){
|
||||
c++;
|
||||
row = jQuery(this);
|
||||
if ( c != 1 ) {
|
||||
row.find('.um-admin-drag-row-icons').append( '<a href="#" class="um-admin-tipsy-n" title="Delete Row" data-remove_element="um-admin-drag-row"><i class="um-faicon-trash-o"></i></a>' );
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function UM_update_subrows(){
|
||||
jQuery('a[data-remove_element="um-admin-drag-rowsub"]').remove();
|
||||
jQuery('.um-admin-drag-row').each(function(){
|
||||
c = 0;
|
||||
jQuery(this).find('.um-admin-drag-rowsub').each(function(){
|
||||
c++;
|
||||
row = jQuery(this);
|
||||
if ( c != 1 ) {
|
||||
row.find('.um-admin-drag-rowsub-icons').append('<a href="#" class="um-admin-tipsy-n" title="Delete Row" data-remove_element="um-admin-drag-rowsub"><i class="um-faicon-trash-o"></i></a>');
|
||||
}
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
function UM_Change_Field_Col(){
|
||||
jQuery('.um-admin-drag-col .um-admin-drag-fld').each(function(){
|
||||
cols = jQuery(this).parents('.um-admin-drag-rowsub').find('.um-admin-drag-col').length;
|
||||
col = jQuery(this).parents('.um-admin-drag-col');
|
||||
if ( col.hasClass('cols-last') ) {
|
||||
if ( cols == 1 ) {
|
||||
saved_col = 1;
|
||||
}
|
||||
if ( cols == 3 ) {
|
||||
saved_col = 3;
|
||||
} else if ( cols == 2 ) {
|
||||
saved_col = 2;
|
||||
}
|
||||
} else if ( col.hasClass('cols-middle') && cols == 3 ) {
|
||||
saved_col = 2;
|
||||
} else {
|
||||
saved_col = 1;
|
||||
}
|
||||
|
||||
jQuery(this).data('column', saved_col);
|
||||
});
|
||||
}
|
||||
|
||||
function UM_Change_Field_Grp(){
|
||||
jQuery('.um-admin-drag-col .um-admin-drag-fld:not(.um-field-type-group)').each(function(){
|
||||
if ( jQuery(this).parents('.um-admin-drag-group').length == 0 ){
|
||||
jQuery(this).data('group', '');
|
||||
} else {
|
||||
jQuery(this).data('group', jQuery(this).parents('.um-admin-drag-fld.um-field-type-group').data('key') );
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function UM_Rows_Refresh(){
|
||||
|
||||
jQuery('.um_update_order_fields').empty();
|
||||
|
||||
/* ROWS */
|
||||
var c = 0;
|
||||
jQuery('.um-admin-drag-row').each(function(){
|
||||
c++;
|
||||
|
||||
row = jQuery(this);
|
||||
|
||||
col_num = '';
|
||||
row.find('.um-admin-drag-rowsub').each(function(){
|
||||
|
||||
subrow = jQuery(this);
|
||||
|
||||
subrow.find('.um-admin-drag-col').removeClass('cols-1 cols-2 cols-3 cols-last cols-middle');
|
||||
subrow.find('.um-admin-drag-col').addClass('cols-' + subrow.find('.um-admin-drag-col').length );
|
||||
subrow.find('.um-admin-drag-col:last').addClass('cols-last');
|
||||
if ( subrow.find('.um-admin-drag-col').length == 3 ) {subrow.find('.um-admin-drag-col:eq(1)').addClass('cols-middle');}
|
||||
|
||||
if ( !col_num ) {
|
||||
col_num = subrow.find('.um-admin-drag-col').length;
|
||||
} else {
|
||||
col_num = col_num + ':' + subrow.find('.um-admin-drag-col').length;
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
jQuery('.um_update_order_fields').append('<input type="hidden" name="_um_rowcols_'+c+'_cols" id="_um_rowcols_'+c+'_cols" value="'+col_num+'" />');
|
||||
|
||||
sub_rows_count = row.find('.um-admin-drag-rowsub').length;
|
||||
|
||||
var origin_id = jQuery(this).attr('data-original');
|
||||
|
||||
jQuery('.um_update_order_fields').append('<input type="hidden" name="_um_row_'+c+'" id="_um_row_'+c+'" value="_um_row_'+c+'" />');
|
||||
jQuery('.um_update_order_fields').append('<input type="hidden" name="_um_roworigin_'+c+'_val" id="_um_roworigin_'+c+'_val" value="'+origin_id+'" />');
|
||||
jQuery('.um_update_order_fields').append('<input type="hidden" name="_um_rowsub_'+c+'_rows" id="_um_rowsub_'+c+'_rows" value="'+sub_rows_count+'" />');
|
||||
|
||||
jQuery(this).attr('data-original', '_um_row_'+c );
|
||||
|
||||
});
|
||||
|
||||
/* FIELDS */
|
||||
var order;
|
||||
order = 0;
|
||||
jQuery('.um-admin-drag-col .um-admin-drag-fld').each(function(){
|
||||
|
||||
if ( !jQuery(this).hasClass('group') ) {
|
||||
var group = jQuery(this).data('group');
|
||||
if ( group != '' ) {
|
||||
if ( jQuery('.um-admin-drag-fld.um-field-type-group.' + group ).find('.um-admin-drag-group').find( jQuery(this) ).length == 0 ) {
|
||||
jQuery(this).appendTo( jQuery('.um-admin-drag-fld.um-field-type-group.' + group ).find('.um-admin-drag-group') );
|
||||
} else {
|
||||
//jQuery(this).prependTo( jQuery('.um-admin-drag-fld.um-field-type-group.' + group ).find('.um-admin-drag-group') );
|
||||
}
|
||||
jQuery('.um_update_order_fields').append('<input type="hidden" name="um_group_'+jQuery(this).data('key')+'" id="um_group_'+jQuery(this).data('key')+'" value="'+group+'" />');
|
||||
} else {
|
||||
jQuery('.um_update_order_fields').append('<input type="hidden" name="um_group_'+jQuery(this).data('key')+'" id="um_group_'+jQuery(this).data('key')+'" value="" />');
|
||||
}
|
||||
}
|
||||
|
||||
order++;
|
||||
|
||||
row = jQuery(this).parents('.um-admin-drag-row').index()+1;
|
||||
row = '_um_row_'+row;
|
||||
|
||||
saved_col = jQuery(this).data('column');
|
||||
|
||||
if ( saved_col == 3 ){
|
||||
jQuery(this).appendTo( jQuery(this).parents('.um-admin-drag-rowsub').find('.um-admin-drag-col:eq(2)') );
|
||||
}
|
||||
if ( saved_col == 2 ){
|
||||
jQuery(this).appendTo( jQuery(this).parents('.um-admin-drag-rowsub').find('.um-admin-drag-col:eq(1)') );
|
||||
}
|
||||
|
||||
sub_row = jQuery(this).parents('.um-admin-drag-rowsub').index();
|
||||
|
||||
jQuery('.um_update_order_fields').append('<input type="hidden" name="um_position_'+jQuery(this).data('key')+'" id="um_position_'+jQuery(this).data('key')+'" value="'+order+'" />');
|
||||
|
||||
jQuery('.um_update_order_fields').append('<input type="hidden" name="um_row_'+jQuery(this).data('key')+'" id="um_row_'+jQuery(this).data('key')+'" value="'+row+'" />');
|
||||
|
||||
jQuery('.um_update_order_fields').append('<input type="hidden" name="um_subrow_'+jQuery(this).data('key')+'" id="um_subrow_'+jQuery(this).data('key')+'" value="'+sub_row+'" />');
|
||||
|
||||
jQuery('.um_update_order_fields').append('<input type="hidden" name="um_col_'+jQuery(this).data('key')+'" id="um_col_'+jQuery(this).data('key')+'" value="'+saved_col+'" />');
|
||||
|
||||
});
|
||||
|
||||
UM_Drag_and_Drop();
|
||||
|
||||
UM_Add_Icon();
|
||||
|
||||
jQuery.ajax({
|
||||
url: um_admin_dragdrop_data.ajax_url,
|
||||
type: 'POST',
|
||||
data: jQuery( '.um_update_order' ).serialize(),
|
||||
success: function(){
|
||||
jQuery('#publish').removeAttr('disabled');
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
function UM_Add_Icon(){
|
||||
|
||||
var add_icon_html = '<a href="#" class="um-admin-drag-add-field um-admin-tipsy-n" title="Add Field" data-modal="UM_fields" data-modal-size="normal" data-dynamic-content="um_admin_show_fields" data-arg2="'+jQuery('.um-admin-drag-ajax').data('form_id')+'" data-arg1=""><i class="um-icon-plus"></i></a>';
|
||||
|
||||
jQuery('.um-admin-drag-col').each(function(){
|
||||
if ( jQuery(this).find('.um-admin-drag-add-field').length == 0 ) {
|
||||
jQuery(this).append(add_icon_html);
|
||||
} else {
|
||||
jQuery(this).find('.um-admin-drag-add-field').remove();
|
||||
jQuery(this).append(add_icon_html);
|
||||
}
|
||||
});
|
||||
|
||||
jQuery('.um-admin-drag-group').each(function(){
|
||||
if ( jQuery(this).find('.um-admin-drag-add-field').length == 0 ) {
|
||||
jQuery(this).append(add_icon_html);
|
||||
} else {
|
||||
jQuery(this).find('.um-admin-drag-add-field').remove();
|
||||
jQuery(this).append(add_icon_html);
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
jQuery(document).ready(function() {
|
||||
|
||||
if ( !jQuery('.um-admin-drag').length ) return false;
|
||||
|
||||
UM_Drag_and_Drop();
|
||||
|
||||
/* add field to respected area */
|
||||
jQuery(document).on('click', 'a.um-admin-drag-add-field', function(){
|
||||
in_row = jQuery(this).parents('.um-admin-drag-row').index();
|
||||
in_sub_row = jQuery(this).parents('.um-admin-drag-rowsub').index();
|
||||
if ( jQuery(this).parents('.um-admin-drag-rowsub').find('.um-admin-drag-col').length == 1 ) {
|
||||
in_column = 1;
|
||||
} else {
|
||||
if ( jQuery(this).parents('.um-admin-drag-col').hasClass('cols-middle')){
|
||||
in_column = 2;
|
||||
} else if ( jQuery(this).parents('.um-admin-drag-col').hasClass('cols-last') ) {
|
||||
if ( jQuery(this).parents('.um-admin-drag-rowsub').find('.um-admin-drag-col').length == 3 ) {
|
||||
in_column = 3;
|
||||
} else {
|
||||
in_column = 2;
|
||||
}
|
||||
} else {
|
||||
in_column = 1;
|
||||
}
|
||||
}
|
||||
|
||||
if ( jQuery(this).parents('.um-admin-drag-group').length ) {
|
||||
in_group = jQuery(this).parents('.um-admin-drag-fld.um-field-type-group').data('key');
|
||||
} else {
|
||||
in_group = '';
|
||||
}
|
||||
|
||||
jQuery('.um-col-demon-settings').data('in_row', in_row);
|
||||
jQuery('.um-col-demon-settings').data('in_sub_row', in_sub_row);
|
||||
jQuery('.um-col-demon-settings').data('in_column', in_column);
|
||||
jQuery('.um-col-demon-settings').data('in_group', in_group);
|
||||
});
|
||||
|
||||
/* add row */
|
||||
jQuery(document).on('click', '*[data-row_action="add_row"]', function(){
|
||||
var dragg = jQuery('.um-admin-drag-ajax');
|
||||
dragg.append( '<div class="um-admin-drag-row">' + jQuery('.um-col-demon-row').html() + '</div>' );
|
||||
dragg.find('.um-admin-drag-row:last').find('.um-admin-drag-row-icons').find('a.um-admin-drag-row-edit').attr('data-arg3', '_um_row_' + ( dragg.find('.um-admin-drag-row').length ) );
|
||||
dragg.find('.um-admin-drag-row:last').attr('data-original', '_um_row_' + ( dragg.find('.um-admin-drag-row').length ) );
|
||||
UM_update_rows();
|
||||
UM_update_subrows();
|
||||
UM_Rows_Refresh();
|
||||
});
|
||||
|
||||
/* add sub row */
|
||||
jQuery(document).on('click', '*[data-row_action="add_subrow"]', function(){
|
||||
var dragg = jQuery(this).parents('.um-admin-drag-row').find('.um-admin-drag-rowsubs');
|
||||
dragg.append( '<div class="um-admin-drag-rowsub">' + jQuery('.um-col-demon-subrow').html() + '</div>' );
|
||||
UM_update_subrows();
|
||||
UM_Rows_Refresh();
|
||||
});
|
||||
|
||||
/* remove element */
|
||||
jQuery(document).on('click', 'a[data-remove_element^="um-"]',function(){
|
||||
element = jQuery(this).data('remove_element');
|
||||
|
||||
jQuery(this).parents('.' +element).find('.um-admin-drag-fld').each(function(){
|
||||
jQuery(this).find('a[data-silent_action="um_admin_remove_field"]').trigger('click');
|
||||
});
|
||||
|
||||
jQuery(this).parents('.' +element).remove();
|
||||
jQuery('.tipsy').remove();
|
||||
UM_Rows_Refresh();
|
||||
});
|
||||
|
||||
/* dynamically change columns */
|
||||
jQuery(document).on('click', '.um-admin-drag-ctrls.columns a', function(){
|
||||
|
||||
var row = jQuery(this).parents('.um-admin-drag-rowsub');
|
||||
var tab = jQuery(this);
|
||||
var tabs = jQuery(this).parent();
|
||||
tabs.find('a').removeClass('active');
|
||||
tab.addClass('active');
|
||||
var existing_cols = row.find('.um-admin-drag-col').length;
|
||||
var required_cols = tab.data('cols');
|
||||
var needed_cols = required_cols - existing_cols;
|
||||
|
||||
if ( needed_cols > 0 ) {
|
||||
|
||||
for (i = 0; i < needed_cols; i++){
|
||||
row.find('.um-admin-drag-col-dynamic').append('<div class="um-admin-drag-col"></div>');
|
||||
}
|
||||
|
||||
row.find('.um-admin-drag-col').removeClass('cols-1 cols-2 cols-3 cols-last cols-middle');
|
||||
row.find('.um-admin-drag-col').addClass('cols-' + row.find('.um-admin-drag-col').length );
|
||||
row.find('.um-admin-drag-col:last').addClass('cols-last');
|
||||
|
||||
if ( row.find('.um-admin-drag-col').length == 3 ) {row.find('.um-admin-drag-col:eq(1)').addClass('cols-middle');}
|
||||
|
||||
} else if ( needed_cols < 0 ) {
|
||||
|
||||
needed_cols = needed_cols + 3;
|
||||
if ( needed_cols == 2 ) {
|
||||
row.find('.um-admin-drag-col:first').append( row.find('.um-admin-drag-col.cols-last').html() );
|
||||
row.find('.um-admin-drag-col.cols-last').remove();
|
||||
}
|
||||
if ( needed_cols == 1 ) {
|
||||
row.find('.um-admin-drag-col:first').append( row.find('.um-admin-drag-col.cols-last').html() );
|
||||
row.find('.um-admin-drag-col:first').append( row.find('.um-admin-drag-col.cols-middle').html() );
|
||||
row.find('.um-admin-drag-col.cols-last').remove();
|
||||
row.find('.um-admin-drag-col.cols-middle').remove();
|
||||
}
|
||||
|
||||
row.find('.um-admin-drag-col').removeClass('cols-1 cols-2 cols-3 cols-last cols-middle');
|
||||
row.find('.um-admin-drag-col').addClass('cols-' + row.find('.um-admin-drag-col:visible').length );
|
||||
row.find('.um-admin-drag-col:last').addClass('cols-last');
|
||||
|
||||
}
|
||||
|
||||
if ( allow_update_via_col_click == true ) {
|
||||
UM_Change_Field_Col();
|
||||
UM_Rows_Refresh();
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
/* trigger columns at start */
|
||||
allow_update_via_col_click = false;
|
||||
jQuery('.um-admin-drag-ctrls.columns a.active').each(function(){
|
||||
jQuery(this).trigger('click');
|
||||
}).promise().done( function(){ allow_update_via_col_click = true; } );
|
||||
|
||||
UM_Rows_Refresh();
|
||||
|
||||
});
|
||||
@@ -0,0 +1,89 @@
|
||||
jQuery(document).ready(function() {
|
||||
|
||||
/* Remove field permanently */
|
||||
jQuery(document).on('click', '.um-admin-btns a span.remove', function(e){
|
||||
e.preventDefault();
|
||||
|
||||
if (confirm('This will permanently delete this custom field from database')) {
|
||||
|
||||
jQuery(this).parents('a').remove();
|
||||
|
||||
arg1 = jQuery(this).parents('a').data('arg1');
|
||||
|
||||
jQuery.ajax({
|
||||
url: um_admin_field_data.do_ajax_url,
|
||||
type: 'POST',
|
||||
data: {act_id : 'um_admin_remove_field_global', arg1 : arg1 },
|
||||
success: function(data){
|
||||
|
||||
},
|
||||
error: function(data){
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
|
||||
return false;
|
||||
});
|
||||
|
||||
/* Add a Field */
|
||||
jQuery(document).on('submit', 'form.um_add_field', function(e){
|
||||
|
||||
e.preventDefault();
|
||||
|
||||
var form = jQuery(this);
|
||||
|
||||
jQuery.ajax({
|
||||
url: um_admin_field_data.ajax_url,
|
||||
type: 'POST',
|
||||
dataType: 'json',
|
||||
data: form.serialize(),
|
||||
beforeSend: function(){
|
||||
form.css({'opacity': 0.5});
|
||||
jQuery('.um-admin-error').removeClass('um-admin-error');
|
||||
form.find('.um-admin-error-block').hide();
|
||||
form.find('.um-admin-success-block').hide();
|
||||
},
|
||||
complete: function(){
|
||||
form.css({'opacity': 1});
|
||||
},
|
||||
success: function(data){
|
||||
|
||||
if (data.error){
|
||||
|
||||
c = 0;
|
||||
jQuery.each(data.error, function(i, v){
|
||||
c++;
|
||||
if ( c == 1 ) {
|
||||
form.find('#'+i).addClass('um-admin-error').focus();
|
||||
form.find('.um-admin-error-block').show().html(v);
|
||||
}
|
||||
});
|
||||
|
||||
um_admin_modal_responsive();
|
||||
|
||||
} else {
|
||||
|
||||
jQuery('.um-col-demon-settings').data('in_row', '');
|
||||
jQuery('.um-col-demon-settings').data('in_sub_row', '');
|
||||
jQuery('.um-col-demon-settings').data('in_column', '');
|
||||
jQuery('.um-col-demon-settings').data('in_group', '');
|
||||
|
||||
um_admin_remove_modal();
|
||||
um_admin_update_builder();
|
||||
|
||||
}
|
||||
|
||||
},
|
||||
error: function(data){
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
return false;
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
@@ -0,0 +1,38 @@
|
||||
jQuery(document).ready(function() {
|
||||
|
||||
/* Default form tab */
|
||||
if ( jQuery('.um-admin-boxed-links').length > 0 ) {
|
||||
|
||||
var tab = jQuery('.um-admin-boxed-links a[data-role="'+jQuery('input#_um_mode').val()+'"]');
|
||||
|
||||
tab.parents('.um-admin-boxed-links').find('a').removeClass('um-admin-activebg');
|
||||
tab.addClass('um-admin-activebg');
|
||||
jQuery('.um-admin div#side-sortables').show();
|
||||
jQuery('div[id^="um-admin-form"]').hide();
|
||||
jQuery('#submitdiv').show();
|
||||
jQuery('div#um-admin-form-mode,div#um-admin-form-title,div#um-admin-form-builder,div#um-admin-form-shortcode').show();
|
||||
jQuery('div[id^="um-admin-form-'+tab.data('role')+'"]').show();
|
||||
jQuery('.empty-container').css({'border' : 'none'});
|
||||
jQuery('.um-admin-builder').removeClass().addClass( 'um-admin-builder ' + jQuery('input#_um_mode').val() );
|
||||
|
||||
}
|
||||
|
||||
/* Creating new form button */
|
||||
jQuery('.um-admin-boxed-links:not(.is-core-form) a').click(function(){
|
||||
|
||||
var tab = jQuery(this);
|
||||
|
||||
tab.parents('.um-admin-boxed-links').find('a').removeClass('um-admin-activebg');
|
||||
tab.addClass('um-admin-activebg');
|
||||
jQuery('.um-admin div#side-sortables').show();
|
||||
jQuery('div[id^="um-admin-form"]').hide();
|
||||
jQuery('#submitdiv').show();
|
||||
jQuery('div#um-admin-form-mode,div#um-admin-form-title,div#um-admin-form-builder,div#um-admin-form-shortcode').show();
|
||||
jQuery('div[id^="um-admin-form-'+tab.data('role')+'"]').show();
|
||||
jQuery('input#_um_mode').val( tab.data('role') );
|
||||
jQuery('.empty-container').css({'border' : 'none'});
|
||||
jQuery('.um-admin-builder').removeClass().addClass( 'um-admin-builder ' + jQuery('input#_um_mode').val() );
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
@@ -0,0 +1,241 @@
|
||||
jQuery(document).ready( function() {
|
||||
|
||||
/**
|
||||
* Multi-selects field
|
||||
*/
|
||||
jQuery( 'body' ).on( 'click', '.um-select-delete', function() {
|
||||
jQuery( this ).parents( 'li.um-multi-selects-option-line' ).remove();
|
||||
});
|
||||
|
||||
|
||||
jQuery( '.um-multi-selects-add-option' ).click( function() {
|
||||
var list = jQuery(this).siblings('ul.um-multi-selects-list');
|
||||
|
||||
var field_id = list.data('field_id');
|
||||
var k = 0;
|
||||
if ( list.find( 'li:last select.um-forms-field' ).length > 0 ) {
|
||||
k = list.find( 'li:last select.um-forms-field' ).attr('id').split("-");
|
||||
k = k[1]*1 + 1;
|
||||
}
|
||||
|
||||
var selector_html = jQuery( '<div>' ).append( list.siblings('.um-hidden-multi-selects').clone() ).html();
|
||||
|
||||
var classes = list.find('li:last').attr('class');
|
||||
|
||||
list.append(
|
||||
'<li class="' + classes + '"><span class="um-field-wrapper">' + selector_html +
|
||||
'</span><span class="um-field-control"><a href="javascript:void(0);" class="um-select-delete">' + php_data.texts.remove + '</a></span></li>'
|
||||
);
|
||||
|
||||
list.find('li:last .um-hidden-multi-selects').attr('name', jQuery(this).data('name') ).
|
||||
addClass('um-forms-field um-long-field').removeClass('um-hidden-multi-selects').attr('id', list.data('id_attr') + '-' + k);
|
||||
|
||||
});
|
||||
|
||||
|
||||
/**
|
||||
* Multi-text field
|
||||
*/
|
||||
jQuery( 'body' ).on( 'click', '.um-text-delete', function() {
|
||||
jQuery(this).parents('li.um-multi-text-option-line').remove();
|
||||
});
|
||||
|
||||
|
||||
jQuery( '.um-multi-text-add-option' ).click( function() {
|
||||
var list = jQuery(this).siblings( 'ul.um-multi-text-list' );
|
||||
|
||||
var field_id = list.data( 'field_id' );
|
||||
var k = 0;
|
||||
if ( list.find( 'li:last input.um-forms-field' ).length > 0 ) {
|
||||
k = list.find( 'li:last input.um-forms-field' ).attr('id').split("-");
|
||||
k = k[1]*1 + 1;
|
||||
}
|
||||
|
||||
var text_html = jQuery( '<div>' ).append( list.siblings('.um-hidden-multi-text').clone() ).html();
|
||||
|
||||
var classes = list.find('li:last').attr('class');
|
||||
|
||||
list.append(
|
||||
'<li class="' + classes + '"><span class="um-field-wrapper">' + text_html +
|
||||
'</span><span class="um-field-control"><a href="javascript:void(0);" class="um-text-delete">' + php_data.texts.remove + '</a></span></li>'
|
||||
);
|
||||
|
||||
list.find('li:last .um-hidden-multi-text').attr('name', jQuery(this).data('name') ).
|
||||
addClass('um-forms-field um-long-field').removeClass('um-hidden-multi-text').attr('id', list.data('id_attr') + '-' + k);
|
||||
});
|
||||
|
||||
|
||||
/**
|
||||
* Media uploader
|
||||
*/
|
||||
jQuery( '.um-media-upload' ).each( function() {
|
||||
var field = jQuery(this).find( '.um-forms-field' );
|
||||
var default_value = field.data('default');
|
||||
|
||||
if ( field.val() != '' && field.val() != default_value ) {
|
||||
field.siblings('.um-set-image').hide();
|
||||
field.siblings('.um-clear-image').show();
|
||||
field.siblings('.icon_preview').show();
|
||||
} else {
|
||||
if ( field.val() == default_value ) {
|
||||
field.siblings('.icon_preview').show();
|
||||
}
|
||||
field.siblings('.um-set-image').show();
|
||||
field.siblings('.um-clear-image').hide();
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
if ( typeof wp !== 'undefined' && wp.media && wp.media.editor ) {
|
||||
var frame;
|
||||
|
||||
jQuery( '.um-set-image' ).click( function(e) {
|
||||
var button = jQuery(this);
|
||||
|
||||
e.preventDefault();
|
||||
|
||||
// If the media frame already exists, reopen it.
|
||||
if ( frame ) {
|
||||
frame.remove();
|
||||
/*frame.open();
|
||||
return;*/
|
||||
}
|
||||
|
||||
// Create a new media frame
|
||||
frame = wp.media({
|
||||
title: button.data('upload_frame'),
|
||||
button: {
|
||||
text: php_data.texts.select
|
||||
},
|
||||
multiple: false // Set to true to allow multiple files to be selected
|
||||
});
|
||||
|
||||
// When an image is selected in the media frame...
|
||||
frame.on( 'select', function() {
|
||||
// Get media attachment details from the frame state
|
||||
var attachment = frame.state().get('selection').first().toJSON();
|
||||
|
||||
// Send the attachment URL to our custom image input field.
|
||||
button.siblings('.icon_preview').attr( 'src', attachment.url ).show();
|
||||
|
||||
button.siblings('.um-forms-field').val( attachment.url );
|
||||
button.siblings('.um-media-upload-data-id').val(attachment.id);
|
||||
button.siblings('.um-media-upload-data-width').val(attachment.width);
|
||||
button.siblings('.um-media-upload-data-height').val(attachment.height);
|
||||
button.siblings('.um-media-upload-data-thumbnail').val(attachment.thumbnail);
|
||||
button.siblings('.um-media-upload-url').val(attachment.url);
|
||||
|
||||
button.siblings('.um-clear-image').show();
|
||||
button.hide();
|
||||
});
|
||||
|
||||
frame.open();
|
||||
});
|
||||
|
||||
jQuery('.icon_preview').click( function(e) {
|
||||
jQuery(this).siblings('.um-set-image').trigger('click');
|
||||
});
|
||||
|
||||
jQuery('.um-clear-image').click( function(e) {
|
||||
var default_image_url = jQuery(this).siblings('.um-forms-field').data('default');
|
||||
jQuery(this).siblings('.um-set-image').show();
|
||||
jQuery(this).hide();
|
||||
jQuery(this).siblings('.icon_preview').attr( 'src', default_image_url );
|
||||
jQuery(this).siblings('.um-media-upload-data-id').val('');
|
||||
jQuery(this).siblings('.um-media-upload-data-width').val('');
|
||||
jQuery(this).siblings('.um-media-upload-data-height').val('');
|
||||
jQuery(this).siblings('.um-media-upload-data-thumbnail').val('');
|
||||
jQuery(this).siblings('.um-forms-field').val( default_image_url );
|
||||
jQuery(this).siblings('.um-media-upload-url').val( default_image_url );
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* On option fields change
|
||||
*/
|
||||
jQuery('body').on('change', '.um-forms-field', function() {
|
||||
if ( jQuery('.um-forms-line[data-conditional*=\'"' + jQuery(this).data('field_id') + '",\']').length > 0 ) {
|
||||
run_check_conditions();
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
//first load hide unconditional fields
|
||||
run_check_conditions();
|
||||
|
||||
|
||||
/**
|
||||
* Run conditional logic
|
||||
*/
|
||||
function run_check_conditions() {
|
||||
jQuery( '.um-forms-line' ).removeClass('um-forms-line-conditioned').each( function() {
|
||||
if ( typeof jQuery(this).data('conditional') === 'undefined' || jQuery(this).hasClass('um-forms-line-conditioned') )
|
||||
return;
|
||||
|
||||
if ( check_condition( jQuery(this) ) )
|
||||
jQuery(this).show();
|
||||
else
|
||||
jQuery(this).hide();
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Conditional logic
|
||||
*
|
||||
* true - show field
|
||||
* false - hide field
|
||||
*
|
||||
* @returns {boolean}
|
||||
*/
|
||||
function check_condition( form_line ) {
|
||||
|
||||
form_line.addClass( 'um-forms-line-conditioned' );
|
||||
|
||||
var conditional = form_line.data('conditional');
|
||||
var condition = conditional[1];
|
||||
var value = conditional[2];
|
||||
|
||||
var prefix = form_line.data( 'prefix' );
|
||||
//var prefix = form_line.parents( '.um-form-table' ).data( 'prefix' );
|
||||
|
||||
var condition_field = jQuery( '#' + prefix + '_' + conditional[0] );
|
||||
var parent_condition = true;
|
||||
if ( typeof condition_field.parents('.um-forms-line').data('conditional') !== 'undefined' ) {
|
||||
parent_condition = check_condition( condition_field.parents('.um-forms-line') );
|
||||
}
|
||||
|
||||
var own_condition = false;
|
||||
if ( condition == '=' ) {
|
||||
var tagName = condition_field.prop("tagName").toLowerCase();
|
||||
|
||||
if ( tagName == 'input' ) {
|
||||
var input_type = condition_field.attr('type');
|
||||
if ( input_type == 'checkbox' ) {
|
||||
own_condition = ( value == '1' ) ? condition_field.is(':checked') : ! condition_field.is(':checked');
|
||||
} else {
|
||||
own_condition = ( condition_field.val() == value );
|
||||
}
|
||||
} else if ( tagName == 'select' ) {
|
||||
own_condition = ( condition_field.val() == value );
|
||||
}
|
||||
} else if ( condition == '!=' ) {
|
||||
var tagName = condition_field.prop("tagName").toLowerCase();
|
||||
|
||||
if ( tagName == 'input' ) {
|
||||
var input_type = condition_field.attr('type');
|
||||
if ( input_type == 'checkbox' ) {
|
||||
own_condition = ( value == '1' ) ? ! condition_field.is(':checked') : condition_field.is(':checked');
|
||||
} else {
|
||||
own_condition = ( condition_field.val() != value );
|
||||
}
|
||||
} else if ( tagName == 'select' ) {
|
||||
own_condition = ( condition_field.val() != value );
|
||||
}
|
||||
}
|
||||
|
||||
return ( own_condition && parent_condition );
|
||||
}
|
||||
|
||||
});
|
||||
@@ -0,0 +1,373 @@
|
||||
function um_admin_live_update_scripts() {
|
||||
|
||||
/*jQuery('.um-admin-modal-body:visible select').select2({
|
||||
allowClear: false,
|
||||
minimumResultsForSearch: 10
|
||||
});*/
|
||||
|
||||
jQuery('.um-adm-conditional').each(function(){jQuery(this).trigger('change');});
|
||||
|
||||
jQuery('.um-admin-colorpicker').wpColorPicker();
|
||||
|
||||
}
|
||||
|
||||
function um_admin_new_modal( id, ajax, size ){
|
||||
|
||||
var modal = jQuery('body').find('.um-admin-overlay');
|
||||
|
||||
jQuery('.tipsy').hide();
|
||||
|
||||
um_admin_remove_modal();
|
||||
|
||||
jQuery('body').addClass('um-admin-modal-open').append('<div class="um-admin-overlay" /><div class="um-admin-modal" />');
|
||||
jQuery('#' + id).prependTo('.um-admin-modal');
|
||||
jQuery('#' + id).show();
|
||||
jQuery('.um-admin-modal').show();
|
||||
|
||||
jQuery('.um-admin-modal-head').append('<a href="#" data-action="UM_remove_modal" class="um-admin-modal-close"><i class="um-faicon-times"></i></a>');
|
||||
|
||||
if ( ajax == true ) {
|
||||
um_admin_modal_size( size );
|
||||
um_admin_modal_preload();
|
||||
um_admin_modal_responsive();
|
||||
} else {
|
||||
um_admin_modal_responsive();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
function um_admin_modal_ajaxcall( act_id, arg1, arg2, arg3 ) {
|
||||
|
||||
in_row = '';
|
||||
in_sub_row = '';
|
||||
in_column = '';
|
||||
in_group = '';
|
||||
|
||||
if ( jQuery('.um-col-demon-settings').data('in_column') ) {
|
||||
in_row = jQuery('.um-col-demon-settings').data('in_row');
|
||||
in_sub_row = jQuery('.um-col-demon-settings').data('in_sub_row');
|
||||
in_column = jQuery('.um-col-demon-settings').data('in_column');
|
||||
in_group = jQuery('.um-col-demon-settings').data('in_group');
|
||||
}
|
||||
|
||||
jQuery.ajax({
|
||||
url: um_admin_modal_data.ajax_url,
|
||||
type: 'POST',
|
||||
data: {act_id: act_id, arg1 : arg1, arg2 : arg2, arg3: arg3, in_row: in_row, in_sub_row: in_sub_row, in_column: in_column, in_group: in_group },
|
||||
complete: function(){
|
||||
um_admin_modal_loaded();
|
||||
um_admin_modal_responsive();
|
||||
},
|
||||
success: function(data){
|
||||
|
||||
jQuery('.um-admin-modal').find('.um-admin-modal-body').html( data );
|
||||
|
||||
um_responsive();
|
||||
|
||||
um_admin_live_update_scripts();
|
||||
|
||||
jQuery( "#_custom_dropdown_options_source" ).trigger('blur');
|
||||
|
||||
if ( jQuery('.um-admin-editor:visible').length > 0 ) {
|
||||
|
||||
if ( act_id == 'um_admin_edit_field_popup' ) {
|
||||
|
||||
tinyMCE.execCommand('mceRemoveEditor', true, 'um_editor_edit');
|
||||
jQuery('.um-admin-editor:visible').html( jQuery('.um-hidden-editor-edit').contents() );
|
||||
tinyMCE.execCommand('mceAddEditor', true, 'um_editor_edit');
|
||||
|
||||
jQuery('.switch-html').trigger('click');
|
||||
jQuery('.switch-html').trigger('click');
|
||||
jQuery('.switch-tmce').trigger('click');
|
||||
|
||||
jQuery('#um_editor_edit_ifr').height(200);
|
||||
|
||||
var editor = tinyMCE.get('um_editor_edit');
|
||||
var content = editor.getContent();
|
||||
editor.setContent( jQuery('.um-admin-modal:visible .dynamic-mce-content').html() );
|
||||
|
||||
} else {
|
||||
|
||||
tinyMCE.execCommand('mceRemoveEditor', true, 'um_editor_new');
|
||||
jQuery('.um-admin-editor:visible').html( jQuery('.um-hidden-editor-new').contents() );
|
||||
tinyMCE.execCommand('mceAddEditor', true, 'um_editor_new');
|
||||
|
||||
jQuery('.switch-html').trigger('click');
|
||||
jQuery('.switch-html').trigger('click');
|
||||
jQuery('.switch-tmce').trigger('click');
|
||||
|
||||
jQuery('#um_editor_new_ifr').height(200);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
},
|
||||
error: function(data){
|
||||
|
||||
}
|
||||
});
|
||||
return false;
|
||||
}
|
||||
|
||||
function um_admin_modal_responsive() {
|
||||
var required_margin = jQuery('.um-admin-modal:visible').innerHeight() / 2 + 'px';
|
||||
jQuery('.um-admin-modal:visible').css({'margin-top': '-' + required_margin });
|
||||
}
|
||||
|
||||
function um_admin_remove_modal(){
|
||||
|
||||
if ( jQuery('.um-admin-editor:visible').length > 0 ) {
|
||||
|
||||
if ( jQuery('.um-admin-modal:visible').find('form').parent().attr('id') == 'UM_edit_field' ) {
|
||||
|
||||
tinyMCE.execCommand('mceRemoveEditor', true, 'um_editor_edit');
|
||||
jQuery('.um-hidden-editor-edit').html( jQuery('.um-admin-editor:visible').contents() );
|
||||
tinyMCE.execCommand('mceAddEditor', true, 'um_editor_edit');
|
||||
|
||||
} else {
|
||||
|
||||
tinyMCE.execCommand('mceRemoveEditor', true, 'um_editor_new');
|
||||
jQuery('.um-hidden-editor-new').html( jQuery('.um-admin-editor:visible').contents() );
|
||||
tinyMCE.execCommand('mceAddEditor', true, 'um_editor_new');
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
jQuery('body').removeClass('um-admin-modal-open');
|
||||
jQuery('.um-admin-modal div[id^="UM_"]').hide().appendTo('body');
|
||||
jQuery('.um-admin-modal,.um-admin-overlay').remove();
|
||||
}
|
||||
|
||||
function um_admin_modal_preload() {
|
||||
jQuery('.um-admin-modal:visible').addClass('loading');
|
||||
jQuery('.um-admin-modal-body:visible').empty();
|
||||
}
|
||||
|
||||
function um_admin_modal_loaded() {
|
||||
jQuery('.um-admin-modal:visible').removeClass('loading');
|
||||
}
|
||||
|
||||
function um_admin_modal_size( aclass ) {
|
||||
jQuery('.um-admin-modal:visible').addClass(aclass);
|
||||
}
|
||||
|
||||
function um_admin_modal_add_attr( id, value ) {
|
||||
jQuery('.um-admin-modal:visible').data( id, value );
|
||||
}
|
||||
|
||||
/**
|
||||
Custom modal scripting starts
|
||||
**/
|
||||
|
||||
jQuery(document).ready(function() {
|
||||
|
||||
/**
|
||||
disable link
|
||||
**/
|
||||
jQuery(document).on('click', '.um-admin-builder a, .um-admin-modal a', function(e){
|
||||
e.preventDefault();
|
||||
return false;
|
||||
});
|
||||
|
||||
/**
|
||||
toggle area
|
||||
**/
|
||||
jQuery(document).on('click', '.um-admin-btn-toggle a', function(e){
|
||||
var content = jQuery(this).parent().find('.um-admin-btn-content');
|
||||
var link = jQuery(this);
|
||||
if ( content.is(':hidden') ) {
|
||||
content.show();
|
||||
link.find('i').removeClass().addClass('um-icon-minus');
|
||||
link.addClass('active');
|
||||
} else {
|
||||
content.hide();
|
||||
link.find('i').removeClass().addClass('um-icon-plus');
|
||||
link.removeClass('active');
|
||||
}
|
||||
um_admin_modal_responsive();
|
||||
});
|
||||
|
||||
/**
|
||||
clone a condition
|
||||
**/
|
||||
jQuery(document).on('click', '.um-admin-new-condition', function(){
|
||||
if ( jQuery(this).hasClass('disabled') )
|
||||
return false;
|
||||
|
||||
var content = jQuery(this).parents('.um-admin-btn-content');
|
||||
var length = content.find('.um-admin-cur-condition').length;
|
||||
if ( length < 5 ) {
|
||||
//content.find('select').select2('destroy');
|
||||
|
||||
var cloned = jQuery(this).parents('.um-admin-cur-condition').clone();
|
||||
cloned.find('input[type=text],select').each(function(){
|
||||
jQuery(this).attr('id', jQuery(this).attr('id') + length );
|
||||
jQuery(this).attr('name', jQuery(this).attr('name') + length );
|
||||
});
|
||||
cloned.find('input[type=text]').val('');
|
||||
cloned.find('.um-admin-new-condition').replaceWith('<p><a href="#" class="um-admin-remove-condition button um-admin-tipsy-n" title="Remove condition"><i class="um-icon-close" style="margin-right:0!important"></i></a></p>');
|
||||
|
||||
cloned.appendTo( content );
|
||||
cloned.find('select').val('');
|
||||
um_admin_live_update_scripts();
|
||||
um_admin_modal_responsive();
|
||||
} else {
|
||||
jQuery(this).addClass('disabled');
|
||||
alert( 'You already have 5 rules' );
|
||||
}
|
||||
});
|
||||
|
||||
/**
|
||||
reset conditions
|
||||
**/
|
||||
jQuery(document).on('click', '.um-admin-reset-conditions a', function(){
|
||||
var content = jQuery(this).parents('.um-admin-btn-content');
|
||||
content.find('.um-admin-cur-condition').slice(1).remove();
|
||||
content.find('input[type=text]').val('');
|
||||
content.find('select').val('');
|
||||
jQuery('.um-admin-new-condition').removeClass('disabled');
|
||||
um_admin_live_update_scripts();
|
||||
um_admin_modal_responsive();
|
||||
});
|
||||
|
||||
/**
|
||||
remove a condition
|
||||
**/
|
||||
jQuery(document).on('click', '.um-admin-remove-condition', function(){
|
||||
var condition = jQuery(this).parents('.um-admin-cur-condition');
|
||||
jQuery('.um-admin-new-condition').removeClass('disabled');
|
||||
jQuery('.tipsy').remove();
|
||||
condition.remove();
|
||||
um_admin_live_update_scripts();
|
||||
um_admin_modal_responsive();
|
||||
});
|
||||
|
||||
/**
|
||||
remove modal via action
|
||||
**/
|
||||
jQuery(document).on('click', '.um-admin-overlay, a[data-action="UM_remove_modal"]', function(){
|
||||
um_admin_remove_modal();
|
||||
});
|
||||
|
||||
/**
|
||||
fire new modal
|
||||
**/
|
||||
jQuery(document).on('click', 'a[data-modal^="UM_"], span[data-modal^="UM_"]', function(e){
|
||||
|
||||
e.preventDefault();
|
||||
|
||||
var modal_id = jQuery(this).attr('data-modal');
|
||||
|
||||
if ( jQuery(this).attr('data-back') ) {
|
||||
|
||||
jQuery('#UM_fonticons').find('a.um-admin-modal-back').attr("data-modal", jQuery(this).attr('data-back') );
|
||||
var current_icon = jQuery( '#' + jQuery(this).attr('data-back') ).find('input#_icon').val();
|
||||
if ( current_icon == '' ) {
|
||||
jQuery('#UM_fonticons').find('.um-admin-icons span').removeClass('highlighted');
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
if ( jQuery(this).data('dynamic-content') ) {
|
||||
um_admin_new_modal( modal_id, true, jQuery(this).data('modal-size') );
|
||||
um_admin_modal_ajaxcall( jQuery(this).data('dynamic-content'), jQuery(this).data('arg1'), jQuery(this).data('arg2'), jQuery(this).data('arg3') );
|
||||
} else {
|
||||
um_admin_new_modal( modal_id );
|
||||
}
|
||||
|
||||
return false;
|
||||
|
||||
});
|
||||
|
||||
/**
|
||||
choose font icon
|
||||
**/
|
||||
jQuery(document).on('click', '.um-admin-icons span', function(){
|
||||
var icon = jQuery(this).attr('data-code');
|
||||
jQuery(this).parent().find('span').removeClass('highlighted');
|
||||
jQuery(this).addClass('highlighted');
|
||||
jQuery('#UM_fonticons').find('a.um-admin-modal-back').attr("data-code", icon);
|
||||
});
|
||||
|
||||
/**
|
||||
submit font icon
|
||||
**/
|
||||
jQuery(document).on('click', '#UM_fonticons a.um-admin-modal-back:not(.um-admin-modal-cancel)', function(){
|
||||
var v_id = '';
|
||||
var icon_selected = jQuery(this).attr('data-code');
|
||||
if (icon_selected != ''){
|
||||
if ( jQuery(this).attr('data-modal') ) {
|
||||
v_id = '#' + jQuery(this).attr('data-modal');
|
||||
} else {
|
||||
v_id = '.postbox';
|
||||
}
|
||||
jQuery( v_id ).find('input#_icon,input#_um_icon').val( icon_selected );
|
||||
jQuery( v_id ).find('span.um-admin-icon-value').html('<i class="'+icon_selected+'"></i>');
|
||||
jQuery( v_id ).find('.um-admin-icon-clear').show();
|
||||
}
|
||||
jQuery(this).attr('data-code', '');
|
||||
if ( v_id == '.postbox' ) {
|
||||
um_admin_remove_modal();
|
||||
}
|
||||
});
|
||||
|
||||
/**
|
||||
restore font icon
|
||||
**/
|
||||
jQuery(document).on('click', 'span.um-admin-icon-clear', function(){
|
||||
var element = jQuery(this).parents('p');
|
||||
jQuery('#UM_fonticons a.um-admin-modal-back').attr('data-code', '');
|
||||
element.find('input[type=hidden]').val('');
|
||||
element.find('.um-admin-icon-value').html('No Icon');
|
||||
jQuery(this).hide();
|
||||
});
|
||||
|
||||
/**
|
||||
search font icons
|
||||
**/
|
||||
jQuery(document).on('keyup blur', '#_icon_search', function(){
|
||||
if ( jQuery(this).val().toLowerCase() != '' ) {
|
||||
jQuery('.um-admin-icons span').hide();
|
||||
jQuery('.um-admin-icons span[data-code*="'+jQuery(this).val().toLowerCase()+'"]').show();
|
||||
} else {
|
||||
jQuery('.um-admin-icons span:hidden').show();
|
||||
}
|
||||
um_admin_modal_responsive();
|
||||
});
|
||||
|
||||
|
||||
/**
|
||||
* Retrieve options from a callback function
|
||||
*/
|
||||
jQuery(document).on('blur',"#_custom_dropdown_options_source", function(){
|
||||
var me = jQuery(this);
|
||||
var _options = jQuery('textarea[id=_options]');
|
||||
|
||||
if( me.val() != '' ){
|
||||
var um_option_callback = me.val();
|
||||
jQuery.ajax({
|
||||
url: um_admin_modal_data.dropdown_ajax_url,
|
||||
type: 'POST',
|
||||
data: { um_option_callback: um_option_callback },
|
||||
complete: function(){
|
||||
|
||||
},
|
||||
success: function( response ){
|
||||
var arr_opts = [];
|
||||
|
||||
for (var key in response.data ){
|
||||
arr_opts.push( response.data[ key ] );
|
||||
}
|
||||
|
||||
_options.val( arr_opts.join('\n') );
|
||||
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
}); // end jQuery(document).ready
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
jQuery( document ).ready( function() {
|
||||
|
||||
jQuery( '#role' ).change( function() {
|
||||
if ( jQuery.inArray( jQuery(this).val().substr(3), um_roles ) !== -1 ) {
|
||||
jQuery( '#um_role_selector_wrapper' ).hide();
|
||||
jQuery( '#um-role' ).val('');
|
||||
} else {
|
||||
jQuery( '#um_role_selector_wrapper' ).show();
|
||||
}
|
||||
}).trigger('change');
|
||||
|
||||
});
|
||||
@@ -0,0 +1,210 @@
|
||||
jQuery(document).ready(function() {
|
||||
|
||||
/**
|
||||
clone a field dropdown
|
||||
**/
|
||||
jQuery(document).on('click', '.um-admin-clone', function(e){
|
||||
e.preventDefault();
|
||||
var container = jQuery(this).parents('.um-admin-field');
|
||||
var parent = jQuery(this).parents('p').find('.um-admin-field:last-child');
|
||||
container.find('select').select2('destroy');
|
||||
var cloned = container.clone();
|
||||
cloned.find('.um-admin-clone').replaceWith('<a href="#" class="um-admin-clone-remove button um-admin-tipsy-n" title="Remove Field"><i class="um-icon-close" style="margin-right:0!important"></i></a>');
|
||||
cloned.insertAfter( parent );
|
||||
cloned.find('select').val('');
|
||||
jQuery('.um-admin-field select').select2({
|
||||
allowClear: true,
|
||||
minimumResultsForSearch: 10
|
||||
});
|
||||
return false;
|
||||
});
|
||||
|
||||
/**
|
||||
remove a field dropdown
|
||||
**/
|
||||
jQuery(document).on('click', '.um-admin-clone-remove', function(e){
|
||||
e.preventDefault();
|
||||
var container = jQuery(this).parents('.um-admin-field');
|
||||
jQuery('.tipsy').remove();
|
||||
container.remove();
|
||||
jQuery('.um-admin-field select').select2({
|
||||
allowClear: true,
|
||||
minimumResultsForSearch: 10
|
||||
});
|
||||
return false;
|
||||
});
|
||||
|
||||
/**
|
||||
Ajax link
|
||||
**/
|
||||
|
||||
jQuery('.um-admin-ajaxlink').click(function(e){
|
||||
e.preventDefault();
|
||||
return false;
|
||||
});
|
||||
|
||||
/**
|
||||
On/Off Buttons
|
||||
**/
|
||||
|
||||
jQuery(document).on('click', '.um-admin-yesno span.btn', function(){
|
||||
if (!jQuery(this).parents('p').hasClass('disabled-on-off')){
|
||||
if ( jQuery(this).parent().find('input[type=hidden]').val() == 0 ){
|
||||
update_val = 1;
|
||||
jQuery(this).animate({'left': '48px'}, 200);
|
||||
jQuery(this).parent().find('input[type=hidden]').val( update_val ).trigger('change');
|
||||
} else {
|
||||
update_val = 0;
|
||||
jQuery(this).animate({'left': '0'}, 200);
|
||||
jQuery(this).parent().find('input[type=hidden]').val( update_val ).trigger('change');
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
/**
|
||||
WP Color Picker
|
||||
**/
|
||||
|
||||
jQuery('.um-admin-colorpicker').wpColorPicker();
|
||||
|
||||
/* /!**
|
||||
Select Dropdowns
|
||||
**!/
|
||||
|
||||
jQuery(".umaf-selectjs").select2({
|
||||
allowClear: false,
|
||||
minimumResultsForSearch: 10
|
||||
});
|
||||
|
||||
jQuery('.um-admin-field select').select2({
|
||||
allowClear: true,
|
||||
minimumResultsForSearch: 10
|
||||
});*/
|
||||
|
||||
/**
|
||||
Tooltips
|
||||
**/
|
||||
if ( jQuery( '.um_tooltip' ).length > 0 ) {
|
||||
jQuery( '.um_tooltip' ).tooltip({
|
||||
tooltipClass: "um_tooltip",
|
||||
content: function () {
|
||||
return jQuery( this ).attr( 'title' );
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
if( typeof tipsy !== 'undefined' ){
|
||||
jQuery('.um-admin-tipsy-n').tipsy({gravity: 'n', opacity: 1, live: 'a.live' });
|
||||
jQuery('.um-admin-tipsy-w').tipsy({gravity: 'w', opacity: 1, live: 'a.live' });
|
||||
jQuery('.um-admin-tipsy-e').tipsy({gravity: 'e', opacity: 1, live: 'a.live' });
|
||||
jQuery('.um-admin-tipsy-s').tipsy({gravity: 's', opacity: 1, live: 'a.live' });
|
||||
}
|
||||
|
||||
/**
|
||||
Conditional fields
|
||||
**/
|
||||
|
||||
jQuery(document).on('change', '.um-adm-conditional', function(){
|
||||
|
||||
var value;
|
||||
if ( jQuery(this).attr("type") == 'checkbox' ) {
|
||||
value = jQuery(this).is(':checked') ? 1 : 0;
|
||||
} else {
|
||||
value = jQuery(this).val();
|
||||
}
|
||||
|
||||
if ( jQuery(this).data('cond1') ) {
|
||||
if ( value == jQuery(this).data('cond1') ) {
|
||||
jQuery('.' + jQuery(this).data('cond1-show') ).show();
|
||||
jQuery('.' + jQuery(this).data('cond1-hide') ).hide();
|
||||
|
||||
if ( jQuery(this).data('cond1-show') == '_roles' ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
} else {
|
||||
jQuery('.' + jQuery(this).data('cond1-show') ).hide();
|
||||
jQuery('.' + jQuery(this).data('cond1-hide') ).show();
|
||||
}
|
||||
}
|
||||
|
||||
if ( jQuery(this).data('cond2') ) {
|
||||
if ( value == jQuery(this).data('cond2') ) {
|
||||
jQuery('.' + jQuery(this).data('cond2-show') ).show();
|
||||
jQuery('.' + jQuery(this).data('cond2-hide') ).hide();
|
||||
|
||||
if ( jQuery(this).data('cond2-show') == '_roles' ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
} else {
|
||||
jQuery('.' + jQuery(this).data('cond2-show') ).hide();
|
||||
jQuery('.' + jQuery(this).data('cond2-hide') ).show();
|
||||
}
|
||||
}
|
||||
|
||||
if ( jQuery(this).data('cond3') ) {
|
||||
if ( value == jQuery(this).data('cond3') ) {
|
||||
jQuery('.' + jQuery(this).data('cond3-show') ).show();
|
||||
jQuery('.' + jQuery(this).data('cond3-hide') ).hide();
|
||||
} else {
|
||||
jQuery('.' + jQuery(this).data('cond3-show') ).hide();
|
||||
jQuery('.' + jQuery(this).data('cond3-hide') ).show();
|
||||
}
|
||||
}
|
||||
|
||||
});jQuery('.um-adm-conditional').each(function(){jQuery(this).trigger('change');});
|
||||
|
||||
/**
|
||||
Conditional fields for
|
||||
Radio Group
|
||||
**/
|
||||
jQuery('.um-conditional-radio-group input[type=radio]').click(function(){
|
||||
var holder = jQuery('.um-conditional-radio-group');
|
||||
|
||||
var val = jQuery(this).val();
|
||||
var cond1 = holder.data('cond1');
|
||||
var show1 = holder.data('cond1-show');
|
||||
if ( val == cond1 ) { // condition met
|
||||
jQuery('.' + show1).show();
|
||||
} else {
|
||||
jQuery('.' + show1).hide();
|
||||
}
|
||||
|
||||
var val2 = jQuery(this).val();
|
||||
var cond2 = holder.data('cond2');
|
||||
var show2 = holder.data('cond2-show');
|
||||
if ( val2 == cond2 ) { // condition met
|
||||
jQuery('.' + show2).show();
|
||||
} else {
|
||||
jQuery('.' + show2).hide();
|
||||
}
|
||||
|
||||
});jQuery('.um-conditional-radio-group input[type=radio]:checked').each(function(){jQuery(this).trigger('click');});
|
||||
|
||||
/**
|
||||
Conditional fields for
|
||||
nav-menu editor options
|
||||
**/
|
||||
|
||||
jQuery('.um-nav-mode').each(function(){
|
||||
|
||||
if ( jQuery(this).find('input[type=radio]:checked').val() ) {
|
||||
if ( jQuery(this).find('input[type=radio]:checked').val() == 2 ) {
|
||||
jQuery(this).parents('.um-nav-edit').find('.um-nav-roles').show();
|
||||
} else {
|
||||
jQuery(this).parents('.um-nav-edit').find('.um-nav-roles').hide();
|
||||
}
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
jQuery(document).on('click', '.um-nav-mode input[type=radio]', function(){
|
||||
if ( jQuery(this).val() == 2 ) {
|
||||
jQuery(this).parents('.um-nav-edit').find('.um-nav-roles').show();
|
||||
} else {
|
||||
jQuery(this).parents('.um-nav-edit').find('.um-nav-roles').hide();
|
||||
}
|
||||
});
|
||||
|
||||
});
|
||||
@@ -0,0 +1,12 @@
|
||||
jQuery( document ).ready( function() {
|
||||
|
||||
/**
|
||||
* Licenses
|
||||
*/
|
||||
jQuery( 'body' ).on( 'click', '.um_license_deactivate', function() {
|
||||
jQuery(this).siblings('.um-option-field').val('');
|
||||
jQuery(this).parents('form.um-settings-form').submit();
|
||||
});
|
||||
|
||||
|
||||
});
|
||||