diff --git a/assets/css/admin/account.css b/assets/css/admin/account.css index c9f5abd7..6e0feb48 100755 --- a/assets/css/admin/account.css +++ b/assets/css/admin/account.css @@ -1 +1 @@ -label.fs-tag,span.fs-tag{background:#ffba00;border-radius:3px;color:#fff;display:inline-block;font-size:11px;line-height:11px;padding:5px;vertical-align:baseline}label.fs-tag.fs-warn,span.fs-tag.fs-warn{background:#ffba00}label.fs-tag.fs-info,span.fs-tag.fs-info{background:#00a0d2}label.fs-tag.fs-success,span.fs-tag.fs-success{background:#46b450}label.fs-tag.fs-error,span.fs-tag.fs-error{background:#dc3232}.fs-notice[data-id=license_not_whitelabeled].success,.fs-notice[data-id=license_whitelabeled].success{border-left-color:#00a0d2;color:inherit}.fs-notice[data-id=license_not_whitelabeled].success label.fs-plugin-title,.fs-notice[data-id=license_whitelabeled].success label.fs-plugin-title{display:none}#fs_account .postbox,#fs_account .widefat{max-width:800px}#fs_account h3{border-bottom:1px solid #f1f1f1;font-size:1.3em;line-height:1.4;margin:0 0 12px;padding:12px 15px}#fs_account h3 .dashicons{font-size:1.3em;height:26px;width:26px}#fs_account i.dashicons{font-size:1.2em;height:1.2em;width:1.2em}#fs_account .dashicons{vertical-align:middle}#fs_account .fs-header-actions{font-size:.9em;position:absolute;right:15px;top:17px}#fs_account .fs-header-actions ul{margin:0}#fs_account .fs-header-actions li{float:left}#fs_account .fs-header-actions li form{display:inline-block}#fs_account .fs-header-actions li a{text-decoration:none}#fs_account_details .button-group{float:right}.rtl #fs_account .fs-header-actions{left:15px;right:auto}.fs-key-value-table{width:100%}.fs-key-value-table form{display:inline-block}.fs-key-value-table tr td:first-child{text-align:right}.fs-key-value-table tr td:first-child nobr{font-weight:700}.fs-key-value-table tr td:first-child form{display:block}.fs-key-value-table tr td.fs-right{text-align:right}.fs-key-value-table tr.fs-odd{background:#ebebeb}.fs-key-value-table td,.fs-key-value-table th{padding:10px}.fs-key-value-table code{line-height:28px}.fs-key-value-table code,.fs-key-value-table input[type=text],.fs-key-value-table var{background:none;color:#0073aa;font-size:16px}.fs-key-value-table input[type=text]{font-weight:700;width:100%}.fs-field-beta_program label{margin-left:7px}label.fs-tag{border-radius:3px;color:#fff;display:inline-block;font-size:11px;line-height:11px;padding:5px;vertical-align:baseline}label.fs-tag,label.fs-tag.fs-warn{background:#ffba00}label.fs-tag.fs-success{background:#46b450}label.fs-tag.fs-error{background:#dc3232}#fs_sites .fs-scrollable-table .fs-table-body{border:1px solid #e5e5e5;max-height:200px;overflow:auto}#fs_sites .fs-scrollable-table .fs-table-body>table.widefat{border:none!important}#fs_sites .fs-scrollable-table .fs-main-column{width:100%}#fs_sites .fs-scrollable-table .fs-site-details td:first-of-type{color:gray;text-align:right;width:1px}#fs_sites .fs-scrollable-table .fs-site-details td:last-of-type{text-align:right}#fs_sites .fs-scrollable-table .fs-install-details table tr td{white-space:nowrap;width:1px}#fs_sites .fs-scrollable-table .fs-install-details table tr td:last-of-type{width:auto}#fs_addons h3{border:none;margin-bottom:0;padding:4px 5px}#fs_addons td{vertical-align:middle}#fs_addons thead{white-space:nowrap}#fs_addons td:first-child,#fs_addons th:first-child{font-weight:700;text-align:left}#fs_addons td:last-child,#fs_addons th:last-child{text-align:right}#fs_addons th{font-weight:700}#fs_billing_address{width:100%}#fs_billing_address tr td{padding:5px;width:50%}#fs_billing_address tr:first-of-type td{padding-top:0}#fs_billing_address span{font-weight:700}#fs_billing_address input,#fs_billing_address select{display:block;margin-top:5px;width:100%}#fs_billing_address input::-moz-placeholder,#fs_billing_address select::-moz-placeholder{color:transparent;opacity:1}#fs_billing_address input:-ms-input-placeholder,#fs_billing_address select:-ms-input-placeholder{color:transparent}#fs_billing_address input::-webkit-input-placeholder,#fs_billing_address select::-webkit-input-placeholder{color:transparent}#fs_billing_address input.fs-read-mode,#fs_billing_address select.fs-read-mode{background:none;border-color:transparent;border-bottom:1px dashed #ccc;color:#777;padding-left:0}#fs_billing_address.fs-read-mode td span{display:none}#fs_billing_address.fs-read-mode input,#fs_billing_address.fs-read-mode select{background:none;border-color:transparent;border-bottom:1px dashed #ccc;color:#777;padding-left:0}#fs_billing_address.fs-read-mode input::-moz-placeholder,#fs_billing_address.fs-read-mode select::-moz-placeholder{color:#ccc;opacity:1}#fs_billing_address.fs-read-mode input:-ms-input-placeholder,#fs_billing_address.fs-read-mode select:-ms-input-placeholder{color:#ccc}#fs_billing_address.fs-read-mode input::-webkit-input-placeholder,#fs_billing_address.fs-read-mode select::-webkit-input-placeholder{color:#ccc}#fs_billing_address button{display:block;width:100%}@media screen and (max-width:639px){#fs_account .fs-header-actions{margin:0 0 12px;padding:0 15px 12px;position:static}#fs_account .fs-header-actions li{display:inline-block;float:none}#fs_account #fs_account_details,#fs_account #fs_account_details tbody,#fs_account #fs_account_details td,#fs_account #fs_account_details th,#fs_account #fs_account_details tr{display:block}#fs_account #fs_account_details tr td:first-child{text-align:left}#fs_account #fs_account_details tr td:nth-child(2){padding:0 12px}#fs_account #fs_account_details tr td:nth-child(2) code{margin:0;padding:0}#fs_account #fs_account_details tr td:nth-child(2) label{margin-left:0}#fs_account #fs_account_details tr td:nth-child(3){text-align:left}#fs_account #fs_account_details tr.fs-field-plan td:nth-child(2) .button-group{float:none;margin:12px 0}} \ No newline at end of file +label.fs-tag,span.fs-tag{background:#ffba00;border-radius:3px;color:#fff;display:inline-block;font-size:11px;line-height:11px;padding:5px;vertical-align:baseline}label.fs-tag.fs-warn,span.fs-tag.fs-warn{background:#ffba00}label.fs-tag.fs-info,span.fs-tag.fs-info{background:#00a0d2}label.fs-tag.fs-success,span.fs-tag.fs-success{background:#46b450}label.fs-tag.fs-error,span.fs-tag.fs-error{background:#dc3232}.fs-notice[data-id=license_not_whitelabeled].success,.fs-notice[data-id=license_whitelabeled].success{border-left-color:#00a0d2;color:inherit}.fs-notice[data-id=license_not_whitelabeled].success label.fs-plugin-title,.fs-notice[data-id=license_whitelabeled].success label.fs-plugin-title{display:none}#fs_account .postbox,#fs_account .widefat{max-width:800px}#fs_account h3{border-bottom:1px solid #f1f1f1;font-size:1.3em;line-height:1.4;margin:0 0 12px;padding:12px 15px}#fs_account h3 .dashicons{font-size:1.3em;height:26px;width:26px}#fs_account i.dashicons{font-size:1.2em;height:1.2em;width:1.2em}#fs_account .dashicons{vertical-align:middle}#fs_account .fs-header-actions{font-size:.9em;position:absolute;right:15px;top:17px}#fs_account .fs-header-actions ul{margin:0}#fs_account .fs-header-actions li{float:left}#fs_account .fs-header-actions li form{display:inline-block}#fs_account .fs-header-actions li a{text-decoration:none}#fs_account_details .button-group{float:right}.rtl #fs_account .fs-header-actions{left:15px;right:auto}.fs-key-value-table{width:100%}.fs-key-value-table form{display:inline-block}.fs-key-value-table tr td:first-child{text-align:right}.fs-key-value-table tr td:first-child nobr{font-weight:700}.fs-key-value-table tr td:first-child form{display:block}.fs-key-value-table tr td.fs-right{text-align:right}.fs-key-value-table tr.fs-odd{background:#ebebeb}.fs-key-value-table td,.fs-key-value-table th{padding:10px}.fs-key-value-table code{line-height:28px}.fs-key-value-table code,.fs-key-value-table input[type=text],.fs-key-value-table var{background:none;color:#0073aa;font-size:16px}.fs-key-value-table input[type=text]{font-weight:700;width:100%}.fs-field-beta_program label{margin-left:7px}label.fs-tag{border-radius:3px;color:#fff;display:inline-block;font-size:11px;line-height:11px;padding:5px;vertical-align:baseline}label.fs-tag,label.fs-tag.fs-warn{background:#ffba00}label.fs-tag.fs-success{background:#46b450}label.fs-tag.fs-error{background:#dc3232}#fs_sites .fs-scrollable-table .fs-table-body{border:1px solid #e5e5e5;max-height:200px;overflow:auto}#fs_sites .fs-scrollable-table .fs-table-body>table.widefat{border:none!important}#fs_sites .fs-scrollable-table .fs-main-column{width:100%}#fs_sites .fs-scrollable-table .fs-site-details td:first-of-type{color:gray;text-align:right;width:1px}#fs_sites .fs-scrollable-table .fs-site-details td:last-of-type{text-align:right}#fs_sites .fs-scrollable-table .fs-install-details table tr td{white-space:nowrap;width:1px}#fs_sites .fs-scrollable-table .fs-install-details table tr td:last-of-type{width:auto}#fs_addons h3{border:none;margin-bottom:0;padding:4px 5px}#fs_addons td{vertical-align:middle}#fs_addons thead{white-space:nowrap}#fs_addons td:first-child,#fs_addons th:first-child{font-weight:700;text-align:left}#fs_addons td:last-child,#fs_addons th:last-child{text-align:right}#fs_addons th{font-weight:700}#fs_billing_address{width:100%}#fs_billing_address tr td{padding:5px;width:50%}#fs_billing_address tr:first-of-type td{padding-top:0}#fs_billing_address span{font-weight:700}#fs_billing_address input,#fs_billing_address select{display:block;margin-top:5px;width:100%}#fs_billing_address input::-moz-placeholder,#fs_billing_address select::-moz-placeholder{color:transparent}#fs_billing_address input::placeholder,#fs_billing_address select::placeholder{color:transparent}#fs_billing_address input.fs-read-mode,#fs_billing_address select.fs-read-mode{background:none;border-color:transparent;border-bottom:1px dashed #ccc;color:#777;padding-left:0}#fs_billing_address.fs-read-mode td span{display:none}#fs_billing_address.fs-read-mode input,#fs_billing_address.fs-read-mode select{background:none;border-color:transparent;border-bottom:1px dashed #ccc;color:#777;padding-left:0}#fs_billing_address.fs-read-mode input::-moz-placeholder,#fs_billing_address.fs-read-mode select::-moz-placeholder{color:#ccc}#fs_billing_address.fs-read-mode input::placeholder,#fs_billing_address.fs-read-mode select::placeholder{color:#ccc}#fs_billing_address button{display:block;width:100%}@media screen and (max-width:639px){#fs_account .fs-header-actions{margin:0 0 12px;padding:0 15px 12px;position:static}#fs_account .fs-header-actions li{display:inline-block;float:none}#fs_account #fs_account_details,#fs_account #fs_account_details tbody,#fs_account #fs_account_details td,#fs_account #fs_account_details th,#fs_account #fs_account_details tr{display:block}#fs_account #fs_account_details tr td:first-child{text-align:left}#fs_account #fs_account_details tr td:nth-child(2){padding:0 12px}#fs_account #fs_account_details tr td:nth-child(2) code{margin:0;padding:0}#fs_account #fs_account_details tr td:nth-child(2) label{margin-left:0}#fs_account #fs_account_details tr td:nth-child(3){text-align:left}#fs_account #fs_account_details tr.fs-field-plan td:nth-child(2) .button-group{float:none;margin:12px 0}} \ No newline at end of file diff --git a/assets/css/admin/common.css b/assets/css/admin/common.css index fae28101..a005ed46 100755 --- a/assets/css/admin/common.css +++ b/assets/css/admin/common.css @@ -1 +1 @@ -.fs-badge{background:#71ae00;border-radius:3px 0 0 3px;border-right:0;box-shadow:0 2px 1px -1px rgba(0,0,0,.3);color:#fff;font-weight:700;padding:5px 10px;position:absolute;right:0;text-transform:uppercase;top:10px}.theme-browser .theme .fs-premium-theme-badge-container{position:absolute;right:0;top:0}.theme-browser .theme .fs-premium-theme-badge-container .fs-badge{margin-top:10px;position:relative;text-align:center;top:0}.theme-browser .theme .fs-premium-theme-badge-container .fs-badge.fs-premium-theme-badge{font-size:1.1em}.theme-browser .theme .fs-premium-theme-badge-container .fs-badge.fs-beta-theme-badge{background:#00a0d2}.fs-switch{background:#ececec;border:1px solid #ccc;border:1px solid rgba(0,0,0,.2);box-shadow:0 0 4px rgba(0,0,0,.1),inset 0 1px 3px 0 rgba(0,0,0,.1);color:#ccc;cursor:pointer;display:inline-block;height:18px;padding:6px 6px 5px;position:relative;text-shadow:0 1px 1px hsla(0,0%,100%,.8)}.fs-switch span{display:inline-block;text-transform:uppercase;width:35px}.fs-switch .fs-toggle{background-color:#fff;background-image:linear-gradient(180deg,#ececec,#fff);border:1px solid rgba(0,0,0,.3);border-radius:4px;box-shadow:inset 0 1px 0 0 hsla(0,0%,100%,.5);height:25px;position:absolute;top:1px;transition:.4s cubic-bezier(.54,1.6,.5,1);width:37px;z-index:999}.fs-switch.fs-off .fs-toggle{left:2%}.fs-switch.fs-on .fs-toggle{left:54%}.fs-switch.fs-round{border-radius:24px;padding:4px 25px;top:8px}.fs-switch.fs-round .fs-toggle{border-radius:24px;height:24px;top:0;width:24px}.fs-switch.fs-round.fs-off .fs-toggle{left:-1px}.fs-switch.fs-round.fs-on{background:#0085ba}.fs-switch.fs-round.fs-on .fs-toggle{left:25px}.fs-switch.fs-small.fs-round{padding:1px 19px}.fs-switch.fs-small.fs-round .fs-toggle{border-radius:18px;height:18px;top:0;width:18px}.fs-switch.fs-small.fs-round.fs-on .fs-toggle{left:19px}body.fs-loading,body.fs-loading *{cursor:wait!important}#fs_frame{font-size:0;line-height:0}.fs-full-size-wrapper{margin:40px 0 -65px -20px}@media(max-width:600px){.fs-full-size-wrapper{margin:0 0 -65px -10px}}.fs-notice{position:relative}.fs-notice.fs-has-title{margin-bottom:30px!important}.fs-notice.success{color:green}.fs-notice.promotion{background-color:#f2fcff!important;border-color:#00a0d2!important}.fs-notice .fs-notice-body{margin:.5em 0;padding:2px}.fs-notice .fs-close{color:#aaa;cursor:pointer;float:right}.fs-notice .fs-close:hover{color:#666}.fs-notice .fs-close>*{display:inline-block;margin-top:7px}.fs-notice label.fs-plugin-title{background:rgba(0,0,0,.3);border-radius:0 0 3px 3px;bottom:auto;color:#fff;cursor:auto;font-size:12px;font-weight:700;left:10px;padding:2px 10px;position:absolute;right:auto;top:100%}div.fs-notice.promotion,div.fs-notice.success,div.fs-notice.updated{display:block!important}#fs_connect .fs-error .fs-api-request-error-details,#fs_connect .fs-error .fs-api-request-error-show-details-link,#fs_connect .fs-error ol,.fs-modal .notice-error .fs-api-request-error-details,.fs-modal .notice-error .fs-api-request-error-show-details-link,.fs-modal .notice-error ol,.fs-notice.error .fs-api-request-error-details,.fs-notice.error .fs-api-request-error-show-details-link,.fs-notice.error ol{text-align:left}#fs_connect .fs-error ol,.fs-modal .notice-error ol,.fs-notice.error ol{list-style-type:disc}#fs_connect .fs-error .fs-api-request-error-show-details-link,.fs-modal .notice-error .fs-api-request-error-show-details-link,.fs-notice.error .fs-api-request-error-show-details-link{box-shadow:none;color:#2271b1;text-decoration:none}#fs_connect .fs-error .fs-api-request-error-details,.fs-modal .notice-error .fs-api-request-error-details,.fs-notice.error .fs-api-request-error-details{border:1px solid #ccc;max-height:150px;overflow:auto;padding:5px}.rtl .fs-notice .fs-close{float:left}.fs-secure-notice{background:#ebfdeb;box-shadow:0 2px 2px rgba(6,113,6,.3);color:green;filter:alpha(opacity=95);left:160px;opacity:.95;padding:10px 20px;position:fixed;right:0;top:32px;z-index:9999}.fs-secure-notice:hover{filter:alpha(opacity=100);opacity:1}.fs-secure-notice a.fs-security-proof{color:green;text-decoration:none}@media screen and (max-width:960px){.fs-secure-notice{left:36px}}@media screen and (max-width:600px){.fs-secure-notice{display:none}}@media screen and (max-width:1250px){#fs_promo_tab{display:none}}@media screen and (max-width:782px){.fs-secure-notice{left:0;text-align:center;top:46px}}span.fs-submenu-item.fs-sub:before{content:"↳";padding:0 5px}.rtl span.fs-submenu-item.fs-sub:before{content:"↲"}.fs-submenu-item.pricing.upgrade-mode{color:#adff2f}.fs-submenu-item.pricing.trial-mode{color:#83e2ff}#adminmenu .update-plugins.fs-trial{background-color:#00b9eb}.fs-ajax-spinner{background:url(/wp-admin/images/wpspin_light-2x.gif);background-size:contain;border:0;display:inline-block;height:20px;margin-bottom:-2px;margin-right:5px;vertical-align:sub;width:20px}.wrap.fs-section h2{text-align:left}.plugins p.fs-upgrade-notice{background-color:#d54e21;border:0;color:#f9f9f9;margin-top:10px;padding:10px} \ No newline at end of file +.fs-badge{background:#71ae00;border-radius:3px 0 0 3px;border-right:0;box-shadow:0 2px 1px -1px rgba(0,0,0,.3);color:#fff;font-weight:700;padding:5px 10px;position:absolute;right:0;text-transform:uppercase;top:10px}.theme-browser .theme .fs-premium-theme-badge-container{position:absolute;right:0;top:0}.theme-browser .theme .fs-premium-theme-badge-container .fs-badge{margin-top:10px;position:relative;text-align:center;top:0}.theme-browser .theme .fs-premium-theme-badge-container .fs-badge.fs-premium-theme-badge{font-size:1.1em}.theme-browser .theme .fs-premium-theme-badge-container .fs-badge.fs-beta-theme-badge{background:#00a0d2}.fs-switch{background:#ececec;border:1px solid #ccc;border:1px solid rgba(0,0,0,.2);box-shadow:0 0 4px rgba(0,0,0,.1),inset 0 1px 3px 0 rgba(0,0,0,.1);color:#ccc;cursor:pointer;display:inline-block;height:18px;padding:6px 6px 5px;position:relative;text-shadow:0 1px 1px hsla(0,0%,100%,.8)}.fs-switch span{display:inline-block;text-transform:uppercase;width:35px}.fs-switch .fs-toggle{background-color:#fff;background-image:linear-gradient(180deg,#ececec,#fff);border:1px solid rgba(0,0,0,.3);border-radius:4px;box-shadow:inset 0 1px 0 0 hsla(0,0%,100%,.5);height:25px;position:absolute;top:1px;transition:.4s cubic-bezier(.54,1.6,.5,1);width:37px;z-index:999}.fs-switch.fs-off .fs-toggle{left:2%}.fs-switch.fs-on .fs-toggle{left:54%}.fs-switch.fs-round{border-radius:24px;padding:4px 25px;top:8px}.fs-switch.fs-round .fs-toggle{border-radius:24px;height:24px;top:0;width:24px}.fs-switch.fs-round.fs-off .fs-toggle{left:-1px}.fs-switch.fs-round.fs-on{background:#0085ba}.fs-switch.fs-round.fs-on .fs-toggle{left:25px}.fs-switch.fs-small.fs-round{padding:1px 19px}.fs-switch.fs-small.fs-round .fs-toggle{border-radius:18px;height:18px;top:0;width:18px}.fs-switch.fs-small.fs-round.fs-on .fs-toggle{left:19px}body.fs-loading,body.fs-loading *{cursor:wait!important}#fs_frame{font-size:0;line-height:0}.fs-full-size-wrapper{margin:40px 0 -65px -20px}@media(max-width:600px){.fs-full-size-wrapper{margin:0 0 -65px -10px}}.fs-notice{position:relative}.fs-notice.fs-has-title{margin-bottom:30px!important}.fs-notice.success{color:green}.fs-notice.promotion{background-color:#f2fcff!important;border-color:#00a0d2!important}.fs-notice .fs-notice-body{margin:.5em 0;padding:2px}.fs-notice .fs-close{color:#aaa;cursor:pointer;float:right}.fs-notice .fs-close:hover{color:#666}.fs-notice .fs-close>*{display:inline-block;margin-top:7px}.fs-notice label.fs-plugin-title{background:rgba(0,0,0,.3);border-radius:0 0 3px 3px;bottom:auto;color:#fff;cursor:auto;font-size:12px;font-weight:700;left:10px;padding:2px 10px;position:absolute;right:auto;top:100%}div.fs-notice.promotion,div.fs-notice.success,div.fs-notice.updated{display:block!important}#fs_connect .fs-error .fs-api-request-error-details,#fs_connect .fs-error .fs-api-request-error-show-details-link,#fs_connect .fs-error ol,.fs-modal .notice-error .fs-api-request-error-details,.fs-modal .notice-error .fs-api-request-error-show-details-link,.fs-modal .notice-error ol,.fs-notice.error .fs-api-request-error-details,.fs-notice.error .fs-api-request-error-show-details-link,.fs-notice.error ol{text-align:left}#fs_connect .fs-error ol,.fs-modal .notice-error ol,.fs-notice.error ol{list-style-type:disc}#fs_connect .fs-error .fs-api-request-error-show-details-link,.fs-modal .notice-error .fs-api-request-error-show-details-link,.fs-notice.error .fs-api-request-error-show-details-link{box-shadow:none;color:#2271b1;text-decoration:none}#fs_connect .fs-error .fs-api-request-error-details,.fs-modal .notice-error .fs-api-request-error-details,.fs-notice.error .fs-api-request-error-details{border:1px solid #ccc;max-height:150px;overflow:auto;padding:5px}.rtl .fs-notice .fs-close{float:left}.fs-secure-notice{background:#ebfdeb;box-shadow:0 2px 2px rgba(6,113,6,.3);color:green;left:160px;opacity:.95;padding:10px 20px;position:fixed;right:0;top:32px;z-index:9989}.fs-secure-notice:hover{opacity:1}.fs-secure-notice a.fs-security-proof{color:green;text-decoration:none}@media screen and (max-width:960px){.fs-secure-notice{left:36px}}@media screen and (max-width:600px){.fs-secure-notice{display:none}}@media screen and (max-width:1250px){#fs_promo_tab{display:none}}@media screen and (max-width:782px){.fs-secure-notice{left:0;text-align:center;top:46px}}span.fs-submenu-item.fs-sub:before{content:"↳";padding:0 5px}.rtl span.fs-submenu-item.fs-sub:before{content:"↲"}.fs-submenu-item.pricing.upgrade-mode{color:#adff2f}.fs-submenu-item.pricing.trial-mode{color:#83e2ff}#adminmenu .update-plugins.fs-trial{background-color:#00b9eb}.fs-ajax-spinner{background:url(/wp-admin/images/wpspin_light-2x.gif);background-size:contain;border:0;display:inline-block;height:20px;margin-bottom:-2px;margin-right:5px;vertical-align:sub;width:20px}.wrap.fs-section h2{text-align:left}.plugins p.fs-upgrade-notice{background-color:#d54e21;border:0;color:#f9f9f9;margin-top:10px;padding:10px} \ No newline at end of file diff --git a/assets/css/admin/dialog-boxes.css b/assets/css/admin/dialog-boxes.css index ff6dc13d..562b7bb8 100644 --- a/assets/css/admin/dialog-boxes.css +++ b/assets/css/admin/dialog-boxes.css @@ -1 +1 @@ -.fs-modal{background:rgba(0,0,0,.6);display:none;height:100%;overflow:auto;position:fixed;top:0;width:100%;z-index:100000}@media(min-width:961px){.fs-modal{padding-left:160px}.rtl .fs-modal{padding-left:0;padding-right:160px}}.fs-modal .dashicons{vertical-align:middle}.fs-modal .fs-modal-dialog{background:transparent;left:50%;margin-left:-298px;padding-bottom:30px;position:absolute;top:-100%;width:596px;z-index:100001}@media(max-width:650px){.fs-modal .fs-modal-dialog{box-sizing:border-box;margin-left:-50%;padding-left:10px;padding-right:10px;width:100%}.fs-modal .fs-modal-dialog .fs-modal-panel>h3>strong{font-size:1.3em}}.fs-modal.active,.fs-modal.active:before{display:block}.fs-modal.active .fs-modal-dialog{top:10%}.fs-modal.fs-success .fs-modal-header{border-bottom-color:#46b450}.fs-modal.fs-success .fs-modal-body{background-color:#f7fff7}.fs-modal.fs-warn .fs-modal-header{border-bottom-color:#ffb900}.fs-modal.fs-warn .fs-modal-body{background-color:#fff8e5}.fs-modal.fs-error .fs-modal-header{border-bottom-color:#dc3232}.fs-modal.fs-error .fs-modal-body{background-color:#ffeaea}.fs-modal .fs-modal-body,.fs-modal .fs-modal-footer{background:#fefefe;border:0;padding:20px}.fs-modal .fs-modal-header{background:#fbfbfb;border-bottom:1px solid #eee;margin-bottom:-10px;padding:15px 20px;position:relative}.fs-modal .fs-modal-header h4{color:#cacaca;font-size:1.2em;font-weight:700;letter-spacing:.6px;margin:0;padding:0;text-shadow:1px 1px 1px #fff;text-transform:uppercase;-webkit-font-smoothing:antialiased}.fs-modal .fs-modal-header .fs-close{border-radius:20px;color:#bbb;cursor:pointer;padding:3px;position:absolute;right:10px;top:12px;transition:all .2s ease-in-out}.fs-modal .fs-modal-header .fs-close:hover{background:#aaa;color:#fff}.fs-modal .fs-modal-header .fs-close .dashicons,.fs-modal .fs-modal-header .fs-close:hover .dashicons{text-decoration:none}.fs-modal .fs-modal-body{border-bottom:0}.fs-modal .fs-modal-body p{font-size:14px}.fs-modal .fs-modal-body h2{font-size:20px;line-height:1.5em}.fs-modal .fs-modal-body>div{margin-top:10px}.fs-modal .fs-modal-body>div h2{font-size:20px;font-weight:700;margin-top:0}.fs-modal .fs-modal-footer{border-top:1px solid #eee;text-align:right}.fs-modal .fs-modal-footer>.button{margin:0 7px}.fs-modal .fs-modal-footer>.button:last-of-type{margin:0}.fs-modal .fs-modal-panel>.notice.inline{display:none;margin:0}.fs-modal .fs-modal-panel:not(.active){display:none}.rtl .fs-modal .fs-modal-header .fs-close{left:20px;right:auto}.rtl .fs-modal .fs-modal-footer{text-align:left}body.has-fs-modal{overflow:hidden}.fs-modal.fs-modal-deactivation-feedback .internal-message,.fs-modal.fs-modal-deactivation-feedback .reason-input{margin:3px 0 3px 22px}.fs-modal.fs-modal-deactivation-feedback .internal-message input,.fs-modal.fs-modal-deactivation-feedback .internal-message textarea,.fs-modal.fs-modal-deactivation-feedback .reason-input input,.fs-modal.fs-modal-deactivation-feedback .reason-input textarea{width:100%}.fs-modal.fs-modal-deactivation-feedback li.reason.has-internal-message .internal-message{border:1px solid #ccc;display:none;padding:7px}@media(max-width:650px){.fs-modal.fs-modal-deactivation-feedback li.reason li.reason{margin-bottom:10px}.fs-modal.fs-modal-deactivation-feedback li.reason li.reason .internal-message,.fs-modal.fs-modal-deactivation-feedback li.reason li.reason .reason-input{margin-left:29px}.fs-modal.fs-modal-deactivation-feedback li.reason li.reason label{display:table}.fs-modal.fs-modal-deactivation-feedback li.reason li.reason label>span{display:table-cell;font-size:1.3em}}.fs-modal.fs-modal-deactivation-feedback .anonymous-feedback-label,.fs-modal.fs-modal-deactivation-feedback .feedback-from-snooze-label{float:left;line-height:30px}.rtl .fs-modal.fs-modal-deactivation-feedback .anonymous-feedback-label,.rtl .fs-modal.fs-modal-deactivation-feedback .feedback-from-snooze-label{float:right}.fs-modal.fs-modal-deactivation-feedback .fs-modal-panel{margin-top:0!important}.fs-modal.fs-modal-deactivation-feedback .fs-modal-panel h3{font-size:16px;line-height:1.5em;margin-bottom:0;margin-top:10px}#the-list .deactivate>.fs-slug{display:none}.fs-modal.fs-modal-subscription-cancellation .fs-price-increase-warning{color:red;font-weight:700;margin-bottom:0;padding:0 25px}.fs-modal.fs-modal-subscription-cancellation ul.subscription-actions label input{float:left;position:relative;top:5px}.rtl .fs-modal.fs-modal-subscription-cancellation ul.subscription-actions label input{float:right}.fs-modal.fs-modal-subscription-cancellation ul.subscription-actions label span{display:block;margin-left:24px}.rtl .fs-modal.fs-modal-subscription-cancellation ul.subscription-actions label span{margin-left:0;margin-right:24px}.fs-license-options-container table,.fs-license-options-container table .fs-available-license-key,.fs-license-options-container table select,.fs-modal.fs-modal-license-activation .fs-modal-body input.fs-license-key{width:100%}.fs-license-options-container table td:first-child{width:1%}.fs-license-options-container table .fs-other-license-key-container label{float:left;margin-right:5px;position:relative;top:6px}.fs-license-options-container table .fs-other-license-key-container div{display:block;height:30px;overflow:hidden;position:relative;top:2px;width:auto}.fs-license-options-container table .fs-other-license-key-container div input{margin:0}.fs-sites-list-container td{cursor:pointer}.fs-modal.fs-modal-user-change .fs-modal-body input#fs_other_email_address{width:100%}.fs-user-change-options-container table{border-collapse:collapse;width:100%}.fs-user-change-options-container table tr{display:block;margin-bottom:2px}.fs-user-change-options-container table .fs-email-address-container td{display:inline-block}.fs-user-change-options-container table .fs-email-address-container input[type=radio]{margin-bottom:0;margin-top:0}.fs-user-change-options-container table .fs-other-email-address-container{width:100%}.fs-user-change-options-container table .fs-other-email-address-container>div{display:table;width:100%}.fs-user-change-options-container table .fs-other-email-address-container>div label,.fs-user-change-options-container table .fs-other-email-address-container>div>div{display:table-cell}.fs-user-change-options-container table .fs-other-email-address-container>div label{padding-left:3px;padding-right:3px;width:1%}.fs-user-change-options-container table .fs-other-email-address-container>div>div{width:auto}.fs-modal.fs-modal-developer-license-debug-mode .fs-modal-body input.fs-license-or-user-key,.fs-user-change-options-container table .fs-other-email-address-container>div>div input{width:100%}.fs-multisite-options-container{border:1px solid #ccc;margin-top:20px;padding:5px}.fs-multisite-options-container a{text-decoration:none}.fs-multisite-options-container a:focus{box-shadow:none}.fs-multisite-options-container a.selected{font-weight:700}.fs-multisite-options-container.fs-apply-on-all-sites{border:0;padding:0}.fs-multisite-options-container.fs-apply-on-all-sites .fs-all-sites-options{border-spacing:0}.fs-multisite-options-container.fs-apply-on-all-sites .fs-all-sites-options td:not(:first-child){display:none}.fs-multisite-options-container .fs-sites-list-container{display:none;overflow:auto}.fs-multisite-options-container .fs-sites-list-container table td{border-top:1px solid #ccc;padding:4px 2px}.fs-modal.fs-modal-license-key-resend .email-address-container{overflow:hidden;padding-right:2px}.fs-modal.fs-modal-license-key-resend.fs-freemium input.email-address{width:300px}.fs-modal.fs-modal-license-key-resend.fs-freemium label{display:block;margin-bottom:10px}.fs-modal.fs-modal-license-key-resend.fs-premium input.email-address{width:100%}.fs-modal.fs-modal-license-key-resend.fs-premium .button-container{float:right;margin-left:7px}@media(max-width:650px){.fs-modal.fs-modal-license-key-resend.fs-premium .button-container{margin-top:2px}}.rtl .fs-modal.fs-modal-license-key-resend .fs-modal-body .input-container>.email-address-container{padding-left:2px;padding-right:0}.rtl .fs-modal.fs-modal-license-key-resend .fs-modal-body .button-container{float:left;margin-left:0;margin-right:7px}a.show-license-resend-modal{display:inline-block;margin-top:4px}.fs-modal.fs-modal-email-address-update .fs-modal-body input[type=text]{width:100%}.fs-modal.fs-modal-email-address-update p{margin-bottom:0}.fs-modal.fs-modal-email-address-update ul{margin:1em .5em}.fs-modal.fs-modal-email-address-update ul li label span{float:left;margin-top:0}.fs-modal.fs-modal-email-address-update ul li label span:last-child{display:block;float:none;margin-left:20px}.fs-ajax-loader{height:20px;margin:auto;position:relative;width:170px}.fs-ajax-loader .fs-ajax-loader-bar{animation-direction:normal;animation-duration:1.5s;animation-iteration-count:infinite;-o-animation-iteration-count:infinite;-ms-animation-iteration-count:infinite;-webkit-animation-iteration-count:infinite;-moz-animation-iteration-count:infinite;animation-name:bounce_ajaxLoader;background-color:#0074a3;height:20px;position:absolute;top:0;transform:.3;width:20px}.fs-ajax-loader .fs-ajax-loader-bar-1{animation-delay:.6s;-o-animation-delay:.6s;-ms-animation-delay:.6s;-webkit-animation-delay:.6s;-moz-animation-delay:.6s;left:0}.fs-ajax-loader .fs-ajax-loader-bar-2{animation-delay:.75s;-o-animation-delay:.75s;-ms-animation-delay:.75s;-webkit-animation-delay:.75s;-moz-animation-delay:.75s;left:19px}.fs-ajax-loader .fs-ajax-loader-bar-3{animation-delay:.9s;-o-animation-delay:.9s;-ms-animation-delay:.9s;-webkit-animation-delay:.9s;-moz-animation-delay:.9s;left:38px}.fs-ajax-loader .fs-ajax-loader-bar-4{animation-delay:1.05s;-o-animation-delay:1.05s;-ms-animation-delay:1.05s;-webkit-animation-delay:1.05s;-moz-animation-delay:1.05s;left:57px}.fs-ajax-loader .fs-ajax-loader-bar-5{animation-delay:1.2s;-o-animation-delay:1.2s;-ms-animation-delay:1.2s;-webkit-animation-delay:1.2s;-moz-animation-delay:1.2s;left:76px}.fs-ajax-loader .fs-ajax-loader-bar-6{animation-delay:1.35s;-o-animation-delay:1.35s;-ms-animation-delay:1.35s;-webkit-animation-delay:1.35s;-moz-animation-delay:1.35s;left:95px}.fs-ajax-loader .fs-ajax-loader-bar-7{animation-delay:1.5s;-o-animation-delay:1.5s;-ms-animation-delay:1.5s;-webkit-animation-delay:1.5s;-moz-animation-delay:1.5s;left:114px}.fs-ajax-loader .fs-ajax-loader-bar-8{animation-delay:1.65s;-o-animation-delay:1.65s;-ms-animation-delay:1.65s;-webkit-animation-delay:1.65s;-moz-animation-delay:1.65s;left:133px}@keyframes bounce_ajaxLoader{0%{background-color:#0074a3;transform:scale(1)}to{background-color:#fff;transform:scale(.3)}}.fs-modal-auto-install #request-filesystem-credentials-form .request-filesystem-credentials-action-buttons,.fs-modal-auto-install #request-filesystem-credentials-form h2{display:none}.fs-modal-auto-install #request-filesystem-credentials-form input[type=email],.fs-modal-auto-install #request-filesystem-credentials-form input[type=password],.fs-modal-auto-install #request-filesystem-credentials-form input[type=text]{-webkit-appearance:none;max-width:100%;padding:10px 10px 5px;width:300px}.fs-modal-auto-install #request-filesystem-credentials-form fieldset,.fs-modal-auto-install #request-filesystem-credentials-form label,.fs-modal-auto-install #request-filesystem-credentials-form>div{display:block;margin:0 auto;max-width:100%;width:300px}.button-primary.warn{background:#f56a48;border-color:#ec6544 #d2593c #d2593c;box-shadow:0 1px 0 #d2593c;text-shadow:0 -1px 1px #d2593c,1px 0 1px #d2593c,0 1px 1px #d2593c,-1px 0 1px #d2593c}.button-primary.warn:hover{background:#fd6d4a;border-color:#d2593c}.button-primary.warn:focus{box-shadow:0 1px 0 #dd6041,0 0 2px 1px #e4a796}.button-primary.warn:active{background:#dd6041;border-color:#d2593c;box-shadow:inset 0 2px 0 #d2593c}.button-primary.warn.disabled{background:#e76444!important;border-color:#d85e40!important;color:#f5b3a1!important;text-shadow:0 -1px 0 rgba(0,0,0,.1)!important} \ No newline at end of file +.fs-modal{background:rgba(0,0,0,.6);display:none;height:100%;overflow:auto;position:fixed;top:0;width:100%;z-index:100000}@media(min-width:961px){.fs-modal{padding-left:160px}.rtl .fs-modal{padding-left:0;padding-right:160px}}.fs-modal .dashicons{vertical-align:middle}.fs-modal .fs-modal-dialog{background:transparent;left:50%;margin-left:-298px;padding-bottom:30px;position:absolute;top:-100%;width:596px;z-index:100001}@media(max-width:650px){.fs-modal .fs-modal-dialog{box-sizing:border-box;margin-left:-50%;padding-left:10px;padding-right:10px;width:100%}.fs-modal .fs-modal-dialog .fs-modal-panel>h3>strong{font-size:1.3em}}.fs-modal.active,.fs-modal.active:before{display:block}.fs-modal.active .fs-modal-dialog{top:10%}.fs-modal.fs-success .fs-modal-header{border-bottom-color:#46b450}.fs-modal.fs-success .fs-modal-body{background-color:#f7fff7}.fs-modal.fs-warn .fs-modal-header{border-bottom-color:#ffb900}.fs-modal.fs-warn .fs-modal-body{background-color:#fff8e5}.fs-modal.fs-error .fs-modal-header{border-bottom-color:#dc3232}.fs-modal.fs-error .fs-modal-body{background-color:#ffeaea}.fs-modal .fs-modal-body,.fs-modal .fs-modal-footer{background:#fefefe;border:0;padding:20px}.fs-modal .fs-modal-header{background:#fbfbfb;border-bottom:1px solid #eee;margin-bottom:-10px;padding:15px 20px;position:relative}.fs-modal .fs-modal-header h4{color:#cacaca;font-size:1.2em;font-weight:700;letter-spacing:.6px;margin:0;padding:0;text-shadow:1px 1px 1px #fff;text-transform:uppercase;-webkit-font-smoothing:antialiased}.fs-modal .fs-modal-header .fs-close{border-radius:20px;color:#bbb;cursor:pointer;padding:3px;position:absolute;right:10px;top:12px;transition:all .2s ease-in-out}.fs-modal .fs-modal-header .fs-close:hover{background:#aaa;color:#fff}.fs-modal .fs-modal-header .fs-close .dashicons,.fs-modal .fs-modal-header .fs-close:hover .dashicons{text-decoration:none}.fs-modal .fs-modal-body{border-bottom:0}.fs-modal .fs-modal-body p{font-size:14px}.fs-modal .fs-modal-body h2{font-size:20px;line-height:1.5em}.fs-modal .fs-modal-body>div{margin-top:10px}.fs-modal .fs-modal-body>div h2{font-size:20px;font-weight:700;margin-top:0}.fs-modal .fs-modal-footer{border-top:1px solid #eee;text-align:right}.fs-modal .fs-modal-footer>.button{margin:0 7px}.fs-modal .fs-modal-footer>.button:last-of-type{margin:0}.fs-modal .fs-modal-panel>.notice.inline{display:none;margin:0}.fs-modal .fs-modal-panel:not(.active){display:none}.rtl .fs-modal .fs-modal-header .fs-close{left:20px;right:auto}.rtl .fs-modal .fs-modal-footer{text-align:left}body.has-fs-modal{overflow:hidden}.fs-modal.fs-modal-deactivation-feedback .internal-message,.fs-modal.fs-modal-deactivation-feedback .reason-input{margin:3px 0 3px 22px}.fs-modal.fs-modal-deactivation-feedback .internal-message input,.fs-modal.fs-modal-deactivation-feedback .internal-message textarea,.fs-modal.fs-modal-deactivation-feedback .reason-input input,.fs-modal.fs-modal-deactivation-feedback .reason-input textarea{width:100%}.fs-modal.fs-modal-deactivation-feedback li.reason.has-internal-message .internal-message{border:1px solid #ccc;display:none;padding:7px}@media(max-width:650px){.fs-modal.fs-modal-deactivation-feedback li.reason li.reason{margin-bottom:10px}.fs-modal.fs-modal-deactivation-feedback li.reason li.reason .internal-message,.fs-modal.fs-modal-deactivation-feedback li.reason li.reason .reason-input{margin-left:29px}.fs-modal.fs-modal-deactivation-feedback li.reason li.reason label{display:table}.fs-modal.fs-modal-deactivation-feedback li.reason li.reason label>span{display:table-cell;font-size:1.3em}}.fs-modal.fs-modal-deactivation-feedback .anonymous-feedback-label,.fs-modal.fs-modal-deactivation-feedback .feedback-from-snooze-label{float:left;line-height:30px}.rtl .fs-modal.fs-modal-deactivation-feedback .anonymous-feedback-label,.rtl .fs-modal.fs-modal-deactivation-feedback .feedback-from-snooze-label{float:right}.fs-modal.fs-modal-deactivation-feedback .fs-modal-panel{margin-top:0!important}.fs-modal.fs-modal-deactivation-feedback .fs-modal-panel h3{font-size:16px;line-height:1.5em;margin-bottom:0;margin-top:10px}#the-list .deactivate>.fs-slug{display:none}.fs-modal.fs-modal-subscription-cancellation .fs-price-increase-warning{color:red;font-weight:700;margin-bottom:0;padding:0 25px}.fs-modal.fs-modal-subscription-cancellation ul.subscription-actions label input{float:left;position:relative;top:5px}.rtl .fs-modal.fs-modal-subscription-cancellation ul.subscription-actions label input{float:right}.fs-modal.fs-modal-subscription-cancellation ul.subscription-actions label span{display:block;margin-left:24px}.rtl .fs-modal.fs-modal-subscription-cancellation ul.subscription-actions label span{margin-left:0;margin-right:24px}.fs-license-options-container table,.fs-license-options-container table .fs-available-license-key,.fs-license-options-container table select,.fs-modal.fs-modal-license-activation .fs-modal-body input.fs-license-key{width:100%}.fs-license-options-container table td:first-child{width:1%}.fs-license-options-container table .fs-other-license-key-container label{float:left;margin-right:5px;position:relative;top:6px}.fs-license-options-container table .fs-other-license-key-container div{display:block;height:30px;overflow:hidden;position:relative;top:2px;width:auto}.fs-license-options-container table .fs-other-license-key-container div input{margin:0}.fs-sites-list-container td{cursor:pointer}.fs-modal.fs-modal-user-change .fs-modal-body input#fs_other_email_address{width:100%}.fs-user-change-options-container table{border-collapse:collapse;width:100%}.fs-user-change-options-container table tr{display:block;margin-bottom:2px}.fs-user-change-options-container table .fs-email-address-container td{display:inline-block}.fs-user-change-options-container table .fs-email-address-container input[type=radio]{margin-bottom:0;margin-top:0}.fs-user-change-options-container table .fs-other-email-address-container{width:100%}.fs-user-change-options-container table .fs-other-email-address-container>div{display:table;width:100%}.fs-user-change-options-container table .fs-other-email-address-container>div label,.fs-user-change-options-container table .fs-other-email-address-container>div>div{display:table-cell}.fs-user-change-options-container table .fs-other-email-address-container>div label{padding-left:3px;padding-right:3px;width:1%}.fs-user-change-options-container table .fs-other-email-address-container>div>div{width:auto}.fs-modal.fs-modal-developer-license-debug-mode .fs-modal-body input.fs-license-or-user-key,.fs-user-change-options-container table .fs-other-email-address-container>div>div input{width:100%}.fs-multisite-options-container{border:1px solid #ccc;margin-top:20px;padding:5px}.fs-multisite-options-container a{text-decoration:none}.fs-multisite-options-container a:focus{box-shadow:none}.fs-multisite-options-container a.selected{font-weight:700}.fs-multisite-options-container.fs-apply-on-all-sites{border:0;padding:0}.fs-multisite-options-container.fs-apply-on-all-sites .fs-all-sites-options{border-spacing:0}.fs-multisite-options-container.fs-apply-on-all-sites .fs-all-sites-options td:not(:first-child){display:none}.fs-multisite-options-container .fs-sites-list-container{display:none;overflow:auto}.fs-multisite-options-container .fs-sites-list-container table td{border-top:1px solid #ccc;padding:4px 2px}.fs-modal.fs-modal-license-key-resend .email-address-container{overflow:hidden;padding-right:2px}.fs-modal.fs-modal-license-key-resend.fs-freemium input.email-address{width:300px}.fs-modal.fs-modal-license-key-resend.fs-freemium label{display:block;margin-bottom:10px}.fs-modal.fs-modal-license-key-resend.fs-premium input.email-address{width:100%}.fs-modal.fs-modal-license-key-resend.fs-premium .button-container{float:right;margin-left:7px}@media(max-width:650px){.fs-modal.fs-modal-license-key-resend.fs-premium .button-container{margin-top:2px}}.rtl .fs-modal.fs-modal-license-key-resend .fs-modal-body .input-container>.email-address-container{padding-left:2px;padding-right:0}.rtl .fs-modal.fs-modal-license-key-resend .fs-modal-body .button-container{float:left;margin-left:0;margin-right:7px}a.show-license-resend-modal{display:inline-block;margin-top:4px}.fs-modal.fs-modal-email-address-update .fs-modal-body input[type=text]{width:100%}.fs-modal.fs-modal-email-address-update p{margin-bottom:0}.fs-modal.fs-modal-email-address-update ul{margin:1em .5em}.fs-modal.fs-modal-email-address-update ul li label span{float:left;margin-top:0}.fs-modal.fs-modal-email-address-update ul li label span:last-child{display:block;float:none;margin-left:20px}.fs-ajax-loader{height:20px;margin:auto;position:relative;width:170px}.fs-ajax-loader .fs-ajax-loader-bar{animation-direction:normal;animation-duration:1.5s;animation-iteration-count:infinite;animation-name:bounce_ajaxLoader;background-color:#0074a3;height:20px;position:absolute;top:0;transform:scale(.3);width:20px}.fs-ajax-loader .fs-ajax-loader-bar-1{animation-delay:.6s;left:0}.fs-ajax-loader .fs-ajax-loader-bar-2{animation-delay:.75s;left:19px}.fs-ajax-loader .fs-ajax-loader-bar-3{animation-delay:.9s;left:38px}.fs-ajax-loader .fs-ajax-loader-bar-4{animation-delay:1.05s;left:57px}.fs-ajax-loader .fs-ajax-loader-bar-5{animation-delay:1.2s;left:76px}.fs-ajax-loader .fs-ajax-loader-bar-6{animation-delay:1.35s;left:95px}.fs-ajax-loader .fs-ajax-loader-bar-7{animation-delay:1.5s;left:114px}.fs-ajax-loader .fs-ajax-loader-bar-8{animation-delay:1.65s;left:133px}@keyframes bounce_ajaxLoader{0%{background-color:#0074a3;transform:scale(1)}to{background-color:#fff;transform:scale(.3)}}.fs-modal-auto-install #request-filesystem-credentials-form .request-filesystem-credentials-action-buttons,.fs-modal-auto-install #request-filesystem-credentials-form h2{display:none}.fs-modal-auto-install #request-filesystem-credentials-form input[type=email],.fs-modal-auto-install #request-filesystem-credentials-form input[type=password],.fs-modal-auto-install #request-filesystem-credentials-form input[type=text]{-webkit-appearance:none;max-width:100%;padding:10px 10px 5px;width:300px}.fs-modal-auto-install #request-filesystem-credentials-form fieldset,.fs-modal-auto-install #request-filesystem-credentials-form label,.fs-modal-auto-install #request-filesystem-credentials-form>div{display:block;margin:0 auto;max-width:100%;width:300px}.button-primary.warn{background:#f56a48;border-color:#ec6544 #d2593c #d2593c;box-shadow:0 1px 0 #d2593c;text-shadow:0 -1px 1px #d2593c,1px 0 1px #d2593c,0 1px 1px #d2593c,-1px 0 1px #d2593c}.button-primary.warn:hover{background:#fd6d4a;border-color:#d2593c}.button-primary.warn:focus{box-shadow:0 1px 0 #dd6041,0 0 2px 1px #e4a796}.button-primary.warn:active{background:#dd6041;border-color:#d2593c;box-shadow:inset 0 2px 0 #d2593c}.button-primary.warn.disabled{background:#e76444!important;border-color:#d85e40!important;color:#f5b3a1!important;text-shadow:0 -1px 0 rgba(0,0,0,.1)!important} \ No newline at end of file diff --git a/assets/scss/_mixins.scss b/assets/scss/_mixins.scss index 1fcea863..850f3a27 100644 --- a/assets/scss/_mixins.scss +++ b/assets/scss/_mixins.scss @@ -22,61 +22,6 @@ // THE SOFTWARE. // -// ---- LEGACY IE SUPPORT USING FILTERS ---- -// Should IE filters be used or not? -// PROS: gradients, drop shadows etc will be handled by css. -// CONS: will harm the site performance badly, -// especially on sites with heavy rendering and scripting. -$useIEFilters: 0; -// might be 0 or 1. disabled by default. -// ---- /LEGACY IE SUPPORT USING FILTERS ---- - - -@mixin background-size ($value) { - -webkit-background-size: $value; - background-size: $value; -} - -@mixin border-image ($path, $offsets, $repeats) { - -moz-border-image: $path $offsets $repeats; - -o-border-image: $path $offsets $repeats; - -webkit-border-image: $path $offsets $repeats; - border-image: $path $offsets $repeats; -} - -@mixin border-radius ($values...) { - -moz-border-radius: $values; - -webkit-border-radius: $values; - border-radius: $values; - /*-moz-background-clip: padding; - -webkit-background-clip: padding-box; - background-clip: padding-box;*/ -} - -@mixin box-shadow ($values...) { - -moz-box-shadow: $values; - -webkit-box-shadow: $values; - box-shadow: $values; -} - -//@mixin box-shadow ($x, $y, $offset, $hex, $ie: $useIEFilters, $inset: null, $spread:null) { -// -moz-box-shadow: $x $y $offset $spread $hex $inset; -// -webkit-box-shadow: $x $y $offset $spread $hex $inset; -// box-shadow: $x $y $offset $spread $hex $inset; -// -// @if $ie == 1 { -// $iecolor: '#' + red($hex) + green($hex) + blue($hex); -// filter: progid:DXImageTransform.Microsoft.dropshadow(OffX=#{$x}, OffY=#{$y}, Color='#{$iecolor}'); -// -ms-filter: quote(progid:DXImageTransform.Microsoft.dropshadow(OffX=#{$x}, OffY=#{$y}, Color='#{$iecolor}')); -// } -//} - -@mixin box-sizing($value) { - -moz-box-sizing: $value; - -webkit-box-sizing: $value; - box-sizing: $value; -} - // requires sass 3.2 @mixin keyframes($name){ @-moz-keyframes #{$name} { @content; } @@ -86,169 +31,23 @@ $useIEFilters: 0; @keyframes #{$name} { @content; } } -@mixin linear-gradient($from, $to, $ie: $useIEFilters) { - @if $ie != 1 { background-color: $to; } - - background-image: -webkit-gradient(linear,left top,left bottom,color-stop(0, $from),color-stop(1, $to)); - background-image: -webkit-linear-gradient(top, $from, $to); - background-image: -moz-linear-gradient(top, $from, $to); - background-image: -ms-linear-gradient(top, $from, $to); - background-image: -o-linear-gradient(top, $from, $to); - background-image: linear-gradient(top, bottom, $from, $to); - - @if $ie == 1 { - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#{$from}', endColorstr='#{$to}'); - } -} - -@mixin horizontal-gradient($startColor: #555, $endColor: #333, $ie: $useIEFilters) { - @if $ie != 1 { background-color: $endColor; } - - background-color: $endColor; - background-image: -webkit-gradient(linear, 0 0, 100% 0, from($startColor), to($endColor)); // Safari 4+, Chrome 2+ - background-image: -webkit-linear-gradient(left, $startColor, $endColor); // Safari 5.1+, Chrome 10+ - background-image: -moz-linear-gradient(left, $startColor, $endColor); // FF 3.6+ - background-image: -o-linear-gradient(left, $startColor, $endColor); // Opera 11.10 - background-image: linear-gradient(to right, $startColor, $endColor); // Standard, IE10 - background-repeat: repeat-x; - @if $ie == 1 { - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#{$startColor}', endColorstr='#{$endColor}', GradientType=1); - } -} - -@mixin radial-gradient($from, $to, $ie: $useIEFilters) { - @if $ie != 1 { background-color: $to; } - - background: -moz-radial-gradient(center, circle cover, $from 0%, $to 100%); - background: -webkit-gradient(radial, center center, 0px, center center, 100%, color-stop(0%, $from), color-stop(100%, $to)); - background: -webkit-radial-gradient(center, circle cover, $from 0%, $to 100%); - background: -o-radial-gradient(center, circle cover, $from 0%, $to 100%); - background: -ms-radial-gradient(center, circle cover, $from 0%, $to 100%); - background: radial-gradient(center, circle cover, $from 0%, $to 100%); - background-color: $from; - - @if $ie == 1 { - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#{$from}', endColorstr='#{$to}', GradientType=1); /* IE6-9 fallback on horizontal gradient */ - } -} - -@mixin perspective($perspective) { - -moz-perspective: $perspective; - -ms-perspective: $perspective; - -webkit-perspective: $perspective; - perspective: $perspective; - -moz-transform-style: preserve-3d; - -ms-transform-style: preserve-3d; - -webkit-transform-style: preserve-3d; - transform-style: preserve-3d; -} - -@mixin transform ($transforms) { - -moz-transform: $transforms; - -o-transform: $transforms; - -ms-transform: $transforms; - -webkit-transform: $transforms; - transform: $transforms; -} - - @mixin matrix ($a, $b, $c, $d, $e, $f) { - -moz-transform: matrix($a, $b, $c, $d, #{$e}px, #{$f}px); - -o-transform: matrix($a, $b, $c, $d, $e, $f); - -ms-transform: matrix($a, $b, $c, $d, $e, $f); - -webkit-transform: matrix($a, $b, $c, $d, $e, $f); - transform: matrix($a, $b, $c, $d, $e, $f); - } - - @mixin rotate ($deg) { - @include transform(rotate(#{$deg}deg)); - } - - @mixin scale ($size) { - @include transform(scale(#{$size})); - } - - @mixin translate ($x, $y) { - @include transform(translate($x, $y)); - } - -@mixin transition ($value...) { - -moz-transition: $value; - -o-transition: $value; - -ms-transition: $value; - -webkit-transition: $value; - transition: $value; -} - -@mixin animation($str) { - -webkit-animation: #{$str}; - -moz-animation: #{$str}; - -ms-animation: #{$str}; - -o-animation: #{$str}; - animation: #{$str}; +@mixin transform($transforms) { + transform: $transforms; } -@mixin animation-name($str) { - -webkit-animation-name: #{$str}; - -moz-animation-name: #{$str}; - -ms-animation-name: #{$str}; - -o-animation-name: #{$str}; - animation-name: #{$str}; +@mixin rotate($deg) { + @include transform(rotate(#{$deg}deg)); } -@mixin animation-duration($str) { - -webkit-animation-duration: #{$str}; - -moz-animation-duration: #{$str}; - -ms-animation-duration: #{$str}; - -o-animation-duration: #{$str}; - animation-duration: #{$str}; +@mixin scale($size) { + @include transform(scale(#{$size})); } -@mixin animation-direction($str) { - -webkit-animation-direction: #{$str}; - -moz-animation-direction: #{$str}; - -ms-animation-direction: #{$str}; - -o-animation-direction: #{$str}; - animation-direction: #{$str}; -} - -@mixin animation-delay($str) { - animation-delay:#{$str}; - -o-animation-delay:#{$str}; - -ms-animation-delay:#{$str}; - -webkit-animation-delay:#{$str}; - -moz-animation-delay:#{$str}; -} - -@mixin animation-iteration-count($str) { - animation-iteration-count:#{$str}; - -o-animation-iteration-count:#{$str}; - -ms-animation-iteration-count:#{$str}; - -webkit-animation-iteration-count:#{$str}; - -moz-animation-iteration-count:#{$str}; -} - -@mixin animation-timing-function($str) { - -webkit-animation-timing-function: #{$str}; - -moz-animation-timing-function: #{$str}; - -ms-animation-timing-function: #{$str}; - -o-animation-timing-function: #{$str}; - animation-timing-function: #{$str}; +@mixin translate($x, $y) { + @include transform(translate($x, $y)); } // ==== /CSS3 SASS MIXINS ==== - -@mixin opacity($opacity) { - opacity: $opacity; - $opacity-ie: $opacity * 100; - filter: alpha(opacity=$opacity-ie); //IE8 -} - -@mixin size($width, $height: $width) -{ - width: $width; - height: $height; -} - @mixin clearfix { &:after { @@ -260,11 +59,7 @@ $useIEFilters: 0; // Placeholder text @mixin placeholder($color: $input-color-placeholder) { - // Firefox - &::-moz-placeholder { + &::placeholder { color: $color; - opacity: 1; // Override Firefox's unusual default opacity; see https://github.com/twbs/bootstrap/pull/11526 } - &:-ms-input-placeholder { color: $color; } // Internet Explorer 10+ - &::-webkit-input-placeholder { color: $color; } // Safari and Chrome -} \ No newline at end of file +} diff --git a/assets/scss/admin/_ajax-loader.scss b/assets/scss/admin/_ajax-loader.scss index f748beba..c34753a9 100644 --- a/assets/scss/admin/_ajax-loader.scss +++ b/assets/scss/admin/_ajax-loader.scss @@ -16,11 +16,11 @@ $size: 20; background-color: $color; width: #{$size}px; height: #{$size}px; - @include animation-name(bounce_ajaxLoader); - @include animation-duration(1.5s); - @include animation-iteration-count(infinite); - @include animation-direction(normal); - @include transform(.3); + animation-name: bounce_ajaxLoader; + animation-duration: 1.5s; + animation-iteration-count: infinite; + animation-direction: normal; + @include transform(scale(.3)); } @for $i from 0 through 7 @@ -28,7 +28,7 @@ $size: 20; .fs-ajax-loader-bar-#{$i + 1} { left: #{$i*($size - 1)}px; - @include animation-delay(#{0.6 + $i*0.15}s); + animation-delay: #{0.6 + $i*0.15}s; } } } @@ -46,4 +46,4 @@ $size: 20; @include transform(scale(.3)); background-color: $bkg-color; } -} \ No newline at end of file +} diff --git a/assets/scss/admin/_badge.scss b/assets/scss/admin/_badge.scss index 60119d1e..2f6f64e8 100644 --- a/assets/scss/admin/_badge.scss +++ b/assets/scss/admin/_badge.scss @@ -7,8 +7,8 @@ color: white; text-transform: uppercase; padding: 5px 10px; - @include border-radius(3px 0 0 3px); + border-radius: 3px 0 0 3px; font-weight: bold; border-right: 0; - @include box-shadow(0 2px 1px -1px rgba(0, 0, 0, .3)); -} \ No newline at end of file + box-shadow: 0 2px 1px -1px rgba(0, 0, 0, .3); +} diff --git a/assets/scss/admin/_modal-common.scss b/assets/scss/admin/_modal-common.scss index 3561cf3c..cdcfc0d8 100644 --- a/assets/scss/admin/_modal-common.scss +++ b/assets/scss/admin/_modal-common.scss @@ -124,9 +124,9 @@ top: 12px; cursor: pointer; color: #bbb; - @include border-radius(20px); + border-radius: 20px; padding: 3px; - @include transition(all 0.2s ease-in-out); + transition: all 0.2s ease-in-out; &:hover { color: #fff; @@ -209,4 +209,4 @@ body.has-fs-modal { overflow: hidden; -} \ No newline at end of file +} diff --git a/assets/scss/admin/_switch.scss b/assets/scss/admin/_switch.scss index f21757d5..b217e9fc 100644 --- a/assets/scss/admin/_switch.scss +++ b/assets/scss/admin/_switch.scss @@ -40,7 +40,7 @@ $switch-on-color: $wp-button-primary-background-color; background-image: linear-gradient(to bottom, #ececec, #fff); box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.5); z-index: 999; - @include transition(0.40s cubic-bezier(0.54, 1.6, 0.5, 1)); + transition: 0.40s cubic-bezier(0.54, 1.6, 0.5, 1); } &.fs-off .fs-toggle @@ -57,14 +57,14 @@ $switch-on-color: $wp-button-primary-background-color; { top: math.div($switch-size, 3); padding: 4px ($switch-size + 1px); - @include border-radius($switch-size); + border-radius: $switch-size; .fs-toggle { top: 0; width: $switch-size; height: $switch-size; - @include border-radius($switch-size); + border-radius: $switch-size; } &.fs-off .fs-toggle @@ -94,7 +94,7 @@ $switch-on-color: $wp-button-primary-background-color; top: 0; width: $switch-small-size; height: $switch-small-size; - @include border-radius($switch-small-size); + border-radius: $switch-small-size; } &.fs-on .fs-toggle @@ -103,4 +103,4 @@ $switch-on-color: $wp-button-primary-background-color; } } } -} \ No newline at end of file +} diff --git a/assets/scss/admin/_tooltip.scss b/assets/scss/admin/_tooltip.scss index 7eca0bd1..c1b92394 100644 --- a/assets/scss/admin/_tooltip.scss +++ b/assets/scss/admin/_tooltip.scss @@ -17,7 +17,7 @@ { opacity: 0; visibility: hidden; - @include transition(opacity 0.3s ease-in-out); + transition: opacity 0.3s ease-in-out; position: absolute; background: $tooltip-bkg-color; color: $tooltip-color !important; @@ -29,8 +29,8 @@ margin-bottom: 5px; left: -17px; right: 0; - @include border-radius(5px); - @include box-shadow(1px 1px 1px rgba(0, 0, 0, 0.2)); + border-radius: 5px; + box-shadow: 1px 1px 1px rgba(0, 0, 0, 0.2); line-height: 1.3em; font-weight: bold; text-align: left; @@ -72,4 +72,4 @@ opacity: 1; } } -} \ No newline at end of file +} diff --git a/assets/scss/admin/add-ons.scss b/assets/scss/admin/add-ons.scss index 51fa4008..300eb2b7 100755 --- a/assets/scss/admin/add-ons.scss +++ b/assets/scss/admin/add-ons.scss @@ -40,7 +40,7 @@ & > ul { - @include transition(all, 0.15s); + transition: all, 0.15s; left: 0; right: 0; top: 0; @@ -53,7 +53,7 @@ padding: 0 15px; width: 100%; display: block; - @include box-sizing(border-box); + box-sizing: border-box; } } @@ -66,7 +66,7 @@ height: 100px; background-repeat: repeat-x; background-size: 100% 100%; - @include transition(all, 0.15s); + transition: all, 0.15s; .fs-badge.fs-installed-addon-badge { font-size: 1.02em; @@ -107,7 +107,7 @@ background: greenyellow; display: block; padding: 2px 10px; - @include box-shadow(1px 1px 1px rgba(0,0,0,0.3)); + box-shadow: 1px 1px 1px rgba(0,0,0,0.3); text-transform: uppercase; font-size: 0.9em; font-weight: bold; @@ -235,7 +235,7 @@ height: 225px; float: left; margin-bottom: 20px; - @include box-sizing(content-box); + box-sizing: content-box; a { @@ -243,7 +243,7 @@ width: 100%; height: 100%; border: 1px solid; - @include box-shadow(1px 1px 1px rgba(0, 0, 0, 0.2)); + box-shadow: 1px 1px 1px rgba(0, 0, 0, 0.2); background-size: cover; } @@ -509,7 +509,7 @@ z-index: 1; width: 230px; text-align: left; - @include box-shadow(0px 2px 4px -1px rgba(0, 0, 0, 0.2), 0px 4px 5px 0px rgba(0, 0, 0, 0.14), 0px 1px 10px 0px rgba(0, 0, 0, 0.12)); + box-shadow: 0px 2px 4px -1px rgba(0, 0, 0, 0.2), 0px 4px 5px 0px rgba(0, 0, 0, 0.14), 0px 1px 10px 0px rgba(0, 0, 0, 0.12); li { margin: 0; @@ -534,13 +534,13 @@ &:not(.up) { .fs-dropdown-list { - @include border-radius(3px 0 3px 3px); + border-radius: 3px 0 3px 3px; } } &.up { .fs-dropdown-list { - @include border-radius(3px 3px 0 3px); + border-radius: 3px 3px 0 3px; } } } @@ -612,4 +612,4 @@ } } } -} \ No newline at end of file +} diff --git a/assets/scss/admin/affiliation.scss b/assets/scss/admin/affiliation.scss index 469d24eb..32935fb2 100644 --- a/assets/scss/admin/affiliation.scss +++ b/assets/scss/admin/affiliation.scss @@ -13,7 +13,7 @@ ul { li { - @include box-sizing(border-box); + box-sizing: border-box; list-style-type: none; &:before { @@ -94,4 +94,4 @@ } } } -} \ No newline at end of file +} diff --git a/assets/scss/admin/common.scss b/assets/scss/admin/common.scss index 254182bc..d86e5884 100755 --- a/assets/scss/admin/common.scss +++ b/assets/scss/admin/common.scss @@ -85,7 +85,7 @@ body.fs-loading { top: 100%; bottom: auto; right: auto; - @include border-radius(0 0 3px 3px); + border-radius: 0 0 3px 3px; left: 10px; font-size: 12px; font-weight: bold; @@ -151,13 +151,13 @@ div.fs-notice background: rgb(235, 253, 235); padding: 10px 20px; color: green; - z-index: 9999; - @include box-shadow(0 2px 2px rgba(6, 113, 6, 0.3)); - @include opacity(0.95); + z-index: 9989; // 1 less than WordPress' #adminmenuwrap + box-shadow: 0 2px 2px rgba(6, 113, 6, 0.3); + opacity: 0.95; &:hover { - @include opacity(1); + opacity: 1; } a.fs-security-proof @@ -252,4 +252,4 @@ span.fs-submenu-item.fs-sub:before } } -@import "plugin-upgrade-notice"; \ No newline at end of file +@import "plugin-upgrade-notice"; diff --git a/assets/scss/admin/connect.scss b/assets/scss/admin/connect.scss index 8fe13588..506ac0c5 100755 --- a/assets/scss/admin/connect.scss +++ b/assets/scss/admin/connect.scss @@ -36,7 +36,7 @@ $box_border_radius: 3px; margin: 30px 0 0 -10px; .fs-box-container { - @include box-shadow(none); + box-shadow: none; } } @@ -50,7 +50,7 @@ $box_border_radius: 3px; background: snow; color: $fs-logo-magenta-color; border: 1px solid $fs-logo-magenta-color; - @include box-shadow(0 1px 1px 0 rgba(0,0,0,.1)); + box-shadow: 0 1px 1px 0 rgba(0,0,0,.1); text-align: center; padding: 5px; margin-bottom: 10px; @@ -188,7 +188,7 @@ $box_border_radius: 3px; { padding: 10px 20px; background: #fff; - @include transition(background 0.5s ease); + transition: background 0.5s ease; .fs-license-sync-disclaimer { text-align: center; @@ -492,7 +492,7 @@ $box_border_radius: 3px; #fs_connect { margin: 0; - @include box-shadow(none); + box-shadow: none; } } @@ -559,4 +559,4 @@ $box_border_radius: 3px; margin-top: 10px; } -@import "permissions"; \ No newline at end of file +@import "permissions"; diff --git a/assets/scss/customizer.scss b/assets/scss/customizer.scss index e4b684aa..09dadd33 100644 --- a/assets/scss/customizer.scss +++ b/assets/scss/customizer.scss @@ -45,7 +45,7 @@ .fs-feature-desc { opacity: 0; visibility: hidden; - @include transition(opacity 0.3s ease-in-out); + transition: opacity 0.3s ease-in-out; position: absolute; background: $tooltip-color; @@ -58,8 +58,8 @@ margin-bottom: 5px; left: 0; right: 0; - @include border-radius(5px); - @include box-shadow(1px 1px 1px rgba(0,0,0,0.2)); + border-radius: 5px; + box-shadow: 1px 1px 1px rgba(0,0,0,0.2); line-height: 1.3em; font-weight: bold; text-align: left; @@ -162,4 +162,4 @@ } } } -} \ No newline at end of file +} diff --git a/includes/class-freemius.php b/includes/class-freemius.php index 347bc44d..c22650ee 100755 --- a/includes/class-freemius.php +++ b/includes/class-freemius.php @@ -1257,7 +1257,7 @@ private static function migrate_accounts_to_network() { * * @return bool */ - private static function set_network_upgrade_mode( FS_Storage $storage ) { + public static function set_network_upgrade_mode( FS_Storage $storage ) { return $storage->is_network_activation = true; } @@ -1583,6 +1583,8 @@ private function register_constructor_hooks() { ) { add_action( 'admin_init', array( &$this, 'connect_again' ) ); } + + FS_DebugManager::register_hooks(); } /** @@ -2701,7 +2703,7 @@ static function is_deactivation_snoozed() { * @author Vova Feldman (@svovaf) * @since 2.4.3 */ - private static function reset_deactivation_snoozing( $period = 0 ) { + public static function reset_deactivation_snoozing( $period = 0 ) { $value = ( 0 === $period ) ? null : 'true'; if ( ! is_multisite() || fs_is_network_admin() ) { @@ -3418,20 +3420,7 @@ private static function _load_required_static() { self::$_global_admin_notices = FS_Admin_Notices::instance( 'global' ); - if ( ! WP_FS__DEMO_MODE ) { - add_action( ( fs_is_network_admin() ? 'network_' : '' ) . 'admin_menu', array( - 'Freemius', - '_add_debug_section' - ) ); - } - - add_action( "wp_ajax_fs_toggle_debug_mode", array( 'Freemius', '_toggle_debug_mode' ) ); - - self::add_ajax_action_static( 'get_debug_log', array( 'Freemius', '_get_debug_log' ) ); - - self::add_ajax_action_static( 'get_db_option', array( 'Freemius', '_get_db_option' ) ); - - self::add_ajax_action_static( 'set_db_option', array( 'Freemius', '_set_db_option' ) ); + FS_DebugManager::load_required_static(); if ( 0 == did_action( 'plugins_loaded' ) ) { add_action( 'plugins_loaded', array( 'Freemius', '_load_textdomain' ), 1 ); @@ -3458,6 +3447,14 @@ private static function _load_required_static() { self::$_statics_loaded = true; } + public static function get_static_logger() { + return self::$_static_logger; + } + + public static function get_accounts() { + return self::$_accounts; + } + #-------------------------------------------------------------------------------- #region Clone #-------------------------------------------------------------------------------- @@ -3626,7 +3623,7 @@ function _handle_long_term_duplicate() { * * @since 2.1.3 */ - private static function migrate_options_to_network() { + public static function migrate_options_to_network() { self::migrate_accounts_to_network(); // Migrate API options from site level to network level. @@ -3666,325 +3663,6 @@ static function _load_textdomain() { #endregion - #---------------------------------------------------------------------------------- - #region Debugging - #---------------------------------------------------------------------------------- - - /** - * @author Vova Feldman (@svovaf) - * @since 1.0.8 - */ - static function _add_debug_section() { - if ( ! is_super_admin() ) { - // Add debug page only for super-admins. - return; - } - - self::$_static_logger->entrance(); - - $title = sprintf( '%s [v.%s]', fs_text_inline( 'Freemius Debug' ), WP_FS__SDK_VERSION ); - - if ( WP_FS__DEV_MODE ) { - // Add top-level debug menu item. - $hook = FS_Admin_Menu_Manager::add_page( - $title, - $title, - 'manage_options', - 'freemius', - array( 'Freemius', '_debug_page_render' ) - ); - } else { - // Add hidden debug page. - $hook = FS_Admin_Menu_Manager::add_subpage( - '', - $title, - $title, - 'manage_options', - 'freemius', - array( 'Freemius', '_debug_page_render' ) - ); - } - - if ( ! empty( $hook ) ) { - add_action( "load-$hook", array( 'Freemius', '_debug_page_actions' ) ); - } - } - - /** - * @author Vova Feldman (@svovaf) - * @since 1.1.7.3 - */ - static function _toggle_debug_mode() { - check_admin_referer( 'fs_toggle_debug_mode' ); - - if ( ! is_super_admin() ) { - return; - } - - $is_on = fs_request_get( 'is_on', false, 'post' ); - - if ( fs_request_is_post() && in_array( $is_on, array( 0, 1 ) ) ) { - update_option( 'fs_debug_mode', $is_on ); - - // Turn on/off storage logging. - FS_Logger::_set_storage_logging( ( 1 == $is_on ) ); - } - - exit; - } - - /** - * @author Vova Feldman (@svovaf) - * @since 1.2.1.6 - */ - static function _get_debug_log() { - check_admin_referer( 'fs_get_debug_log' ); - - if ( ! is_super_admin() ) { - return; - } - - $limit = min( ! empty( $_POST['limit'] ) ? absint( $_POST['limit'] ) : 200, 200 ); - $offset = min( ! empty( $_POST['offset'] ) ? absint( $_POST['offset'] ) : 200, 200 ); - - $logs = FS_Logger::load_db_logs( - fs_request_get( 'filters', false, 'post' ), - $limit, - $offset - ); - - self::shoot_ajax_success( $logs ); - } - - /** - * @author Vova Feldman (@svovaf) - * @since 1.2.1.7 - */ - static function _get_db_option() { - check_admin_referer( 'fs_get_db_option' ); - - $option_name = fs_request_get( 'option_name' ); - - if ( ! is_super_admin() || - ! fs_starts_with( $option_name, 'fs_' ) - ) { - self::shoot_ajax_failure(); - } - - $value = get_option( $option_name ); - - $result = array( - 'name' => $option_name, - ); - - if ( false !== $value ) { - if ( ! is_string( $value ) ) { - $value = json_encode( $value ); - } - - $result['value'] = $value; - } - - self::shoot_ajax_success( $result ); - } - - /** - * @author Vova Feldman (@svovaf) - * @since 1.2.1.7 - */ - static function _set_db_option() { - check_admin_referer( 'fs_set_db_option' ); - - $option_name = fs_request_get( 'option_name' ); - - if ( ! is_super_admin() || - ! fs_starts_with( $option_name, 'fs_' ) - ) { - self::shoot_ajax_failure(); - } - - $option_value = fs_request_get_raw( 'option_value' ); - - if ( ! empty( $option_value ) ) { - update_option( $option_name, $option_value ); - } - - self::shoot_ajax_success(); - } - - /** - * @author Vova Feldman (@svovaf) - * @since 1.0.8 - */ - static function _debug_page_actions() { - self::_clean_admin_content_section(); - - if ( fs_request_is_action( 'restart_freemius' ) ) { - check_admin_referer( 'restart_freemius' ); - - if ( ! is_multisite() ) { - // Clear accounts data. - self::$_accounts->clear( null, true ); - } else { - $sites = self::get_sites(); - foreach ( $sites as $site ) { - $blog_id = self::get_site_blog_id( $site ); - self::$_accounts->clear( $blog_id, true ); - } - - // Clear network level storage. - self::$_accounts->clear( true, true ); - } - - // Clear SDK reference cache. - delete_option( 'fs_active_plugins' ); - } else if ( fs_request_is_action( 'clear_updates_data' ) ) { - check_admin_referer( 'clear_updates_data' ); - - if ( ! is_multisite() ) { - set_site_transient( 'update_plugins', null ); - set_site_transient( 'update_themes', null ); - } else { - $current_blog_id = get_current_blog_id(); - - $sites = self::get_sites(); - foreach ( $sites as $site ) { - switch_to_blog( self::get_site_blog_id( $site ) ); - - set_site_transient( 'update_plugins', null ); - set_site_transient( 'update_themes', null ); - } - - switch_to_blog( $current_blog_id ); - } - } else if ( fs_request_is_action( 'reset_deactivation_snoozing' ) ) { - check_admin_referer( 'reset_deactivation_snoozing' ); - - self::reset_deactivation_snoozing(); - } else if ( fs_request_is_action( 'simulate_trial' ) ) { - check_admin_referer( 'simulate_trial' ); - - $fs = freemius( fs_request_get( 'module_id' ) ); - - // Update SDK install to at least 24 hours before. - $fs->_storage->install_timestamp = ( time() - WP_FS__TIME_24_HOURS_IN_SEC ); - // Unset the trial shown timestamp. - unset( $fs->_storage->trial_promotion_shown ); - } else if ( fs_request_is_action( 'simulate_network_upgrade' ) ) { - check_admin_referer( 'simulate_network_upgrade' ); - - $fs = freemius( fs_request_get( 'module_id' ) ); - - self::set_network_upgrade_mode( $fs->_storage ); - } else if ( fs_request_is_action( 'delete_install' ) ) { - check_admin_referer( 'delete_install' ); - - self::_delete_site_by_slug( - fs_request_get( 'slug' ), - fs_request_get( 'module_type' ), - true, - fs_request_get( 'blog_id', null ) - ); - } else if ( fs_request_is_action( 'delete_user' ) ) { - check_admin_referer( 'delete_user' ); - - self::delete_user( fs_request_get( 'user_id' ) ); - } else if ( fs_request_is_action( 'download_logs' ) ) { - check_admin_referer( 'download_logs' ); - - $download_url = FS_Logger::download_db_logs( - fs_request_get( 'filters', false, 'post' ) - ); - - if ( false === $download_url ) { - wp_die( 'Oops... there was an error while generating the logs download file. Please try again and if it doesn\'t work contact support@freemius.com.' ); - } - - fs_redirect( $download_url ); - } else if ( fs_request_is_action( 'migrate_options_to_network' ) ) { - check_admin_referer( 'migrate_options_to_network' ); - - self::migrate_options_to_network(); - } - } - - /** - * @author Leo Fajardo (@leorw) - * @since 2.5.0 - * - * @return array - */ - static function get_all_modules_sites() { - self::$_static_logger->entrance(); - - $sites_by_type = array( - WP_FS__MODULE_TYPE_PLUGIN => array(), - WP_FS__MODULE_TYPE_THEME => array(), - ); - - $module_types = array_keys( $sites_by_type ); - - if ( ! is_multisite() ) { - foreach ( $module_types as $type ) { - $sites_by_type[ $type ] = self::get_all_sites( $type ); - - foreach ( $sites_by_type[ $type ] as $slug => $install ) { - $sites_by_type[ $type ][ $slug ] = array( $install ); - } - } - } else { - $sites = self::get_sites(); - - foreach ( $sites as $site ) { - $blog_id = self::get_site_blog_id( $site ); - - foreach ( $module_types as $type ) { - $installs = self::get_all_sites( $type, $blog_id ); - - foreach ( $installs as $slug => $install ) { - if ( ! isset( $sites_by_type[ $type ][ $slug ] ) ) { - $sites_by_type[ $type ][ $slug ] = array(); - } - - $install->blog_id = $blog_id; - - $sites_by_type[ $type ][ $slug ][] = $install; - } - - } - } - } - - return $sites_by_type; - } - - /** - * @author Vova Feldman (@svovaf) - * @since 1.0.8 - */ - static function _debug_page_render() { - self::$_static_logger->entrance(); - - $all_modules_sites = self::get_all_modules_sites(); - - $licenses_by_module_type = self::get_all_licenses_by_module_type(); - - $vars = array( - 'plugin_sites' => $all_modules_sites[ WP_FS__MODULE_TYPE_PLUGIN ], - 'theme_sites' => $all_modules_sites[ WP_FS__MODULE_TYPE_THEME ], - 'users' => self::get_all_users(), - 'addons' => self::get_all_addons(), - 'account_addons' => self::get_all_account_addons(), - 'plugin_licenses' => $licenses_by_module_type[ WP_FS__MODULE_TYPE_PLUGIN ], - 'theme_licenses' => $licenses_by_module_type[ WP_FS__MODULE_TYPE_THEME ] - ); - - fs_enqueue_local_style( 'fs_debug', '/admin/debug.css' ); - fs_require_once_template( 'debug.php', $vars ); - } - - #endregion - #---------------------------------------------------------------------------------- #region Connectivity Issues #---------------------------------------------------------------------------------- @@ -7482,31 +7160,6 @@ static function _delete_site_by_slug( $slug, $module_type, $store = true, $blog_ return $install_id; } - /** - * Delete user. - * - * @author Vova Feldman (@svovaf) - * @since 2.0.0 - * - * @param number $user_id - * @param bool $store - * - * @return false|int The user ID if deleted. Otherwise, FALSE (when install not exist). - */ - private static function delete_user( $user_id, $store = true ) { - $users = self::get_all_users(); - - if ( ! is_array( $users ) || ! isset( $users[ $user_id ] ) ) { - return false; - } - - unset( $users[ $user_id ] ); - - self::$_accounts->set_option( 'users', $users, $store ); - - return $user_id; - } - /** * Delete plugin's plans information. * @@ -10642,7 +10295,7 @@ static function get_all_users() { * * @return array[string]FS_Site */ - private static function get_all_sites( + public static function get_all_sites( $module_type = WP_FS__MODULE_TYPE_PLUGIN, $blog_id = null, $is_backup = false @@ -10671,7 +10324,7 @@ private static function get_all_sites( * * @return mixed */ - private static function get_account_option( $option_name, $module_type = null, $network_level_or_blog_id = null ) { + public static function get_account_option( $option_name, $module_type = null, $network_level_or_blog_id = null ) { if ( ! is_null( $module_type ) && WP_FS__MODULE_TYPE_PLUGIN !== $module_type ) { $option_name = $module_type . '_' . $option_name; } @@ -10802,36 +10455,6 @@ private static function get_all_licenses( $module_id = null ) { return $licenses; } - /** - * @author Leo Fajardo (@leorw) - * @since 2.0.0 - * - * @return array - */ - private static function get_all_licenses_by_module_type() { - $licenses = self::get_account_option( 'all_licenses' ); - - $licenses_by_module_type = array( - WP_FS__MODULE_TYPE_PLUGIN => array(), - WP_FS__MODULE_TYPE_THEME => array() - ); - - if ( ! is_array( $licenses ) ) { - return $licenses_by_module_type; - } - - foreach ( $licenses as $module_id => $module_licenses ) { - $fs = self::get_instance_by_id( $module_id ); - if ( false === $fs ) { - continue; - } - - $licenses_by_module_type[ $fs->_module_type ] = array_merge( $licenses_by_module_type[ $fs->_module_type ], $module_licenses ); - } - - return $licenses_by_module_type; - } - /** * @author Leo Fajardo (@leorw) * @since 2.0.0 @@ -10974,7 +10597,7 @@ private static function get_all_updates() { * * @return array|false */ - private static function get_all_addons() { + public static function get_all_addons() { $addons = self::maybe_get_entities_account_option( 'addons', array() ); if ( ! is_array( $addons ) ) { @@ -10990,7 +10613,7 @@ private static function get_all_addons() { * * @return number[]|false */ - private static function get_all_account_addons() { + public static function get_all_account_addons() { $addons = self::$_accounts->get_option( 'account_addons', array() ); if ( ! is_array( $addons ) ) { @@ -11107,6 +10730,16 @@ function get_site() { return $this->_site; } + /** + * @author Daniele Alessandra (@danielealessandra) + * @return FS_Storage + * @since 2.6.2 + * + */ + public function get_storage() { + return $this->_storage; + } + /** * @author Leo Fajardo (@leorw) * @since 2.5.0 @@ -15041,6 +14674,20 @@ function pricing_url( $billing_cycle = WP_FS__PERIOD_ANNUALLY, $is_trial = false $this->_parent->addon_url( $this->_slug ) : $this->_get_admin_page_url( 'pricing', $params ); + return $this->get_pricing_url_with_filter( $url ); + } + + /** + * Retrieves the filtered pricing URL. + * + * @author Leo Fajardo (@leorw) + * @since 2.7.4 + * + * @param string $url + * + * @return string + */ + private function get_pricing_url_with_filter( $url ) { return $this->apply_filters( 'pricing_url', $url ); } @@ -19167,18 +18814,34 @@ private function add_submenu_items() { } } - // Add upgrade/pricing page. - $this->add_submenu_item( - $pricing_cta_text . '  ' . ( is_rtl() ? $this->get_text_x_inline( '←', 'ASCII arrow left icon', 'symbol_arrow-left' ) : $this->get_text_x_inline( '➤', 'ASCII arrow right icon', 'symbol_arrow-right' ) ), - array( &$this, '_pricing_page_render' ), - $this->get_plugin_name() . ' – ' . $this->get_text_x_inline( 'Pricing', 'noun', 'pricing' ), - 'manage_options', - 'pricing', - 'Freemius::_clean_admin_content_section', - WP_FS__LOWEST_PRIORITY, - ( $add_submenu_items && $show_pricing ), - $pricing_class - ); + $custom_pricing_url = $this->get_pricing_url_with_filter( null ); + $pricing_menu_title = $pricing_cta_text . '  ' . ( is_rtl() ? $this->get_text_x_inline( '←', 'ASCII arrow left icon', 'symbol_arrow-left' ) : $this->get_text_x_inline( '➤', 'ASCII arrow right icon', 'symbol_arrow-right' ) ); + $show_pricing_submenu_item = ( $add_submenu_items && $show_pricing ); + + // Add upgrade/pricing submenu item. + if ( ! is_null( $custom_pricing_url ) ) { + $this->add_submenu_link_item( + $pricing_menu_title, + $custom_pricing_url, + 'pricing', + 'manage_options', + WP_FS__LOWEST_PRIORITY, + $show_pricing_submenu_item, + $pricing_class + ); + } else { + $this->add_submenu_item( + $pricing_menu_title, + array( &$this, '_pricing_page_render' ), + $this->get_plugin_name() . ' – ' . $this->get_text_x_inline( 'Pricing', 'noun', 'pricing' ), + 'manage_options', + 'pricing', + 'Freemius::_clean_admin_content_section', + WP_FS__LOWEST_PRIORITY, + $show_pricing_submenu_item, + $pricing_class + ); + } } } @@ -19467,6 +19130,7 @@ function add_submenu_item( * @param string $capability * @param int $priority * @param bool $show_submenu + * @param string $class */ function add_submenu_link_item( $menu_title, @@ -19474,7 +19138,8 @@ function add_submenu_link_item( $menu_slug = false, $capability = 'read', $priority = WP_FS__DEFAULT_PRIORITY, - $show_submenu = true + $show_submenu = true, + $class = '' ) { $this->_logger->entrance( 'Title = ' . $menu_title . '; Url = ' . $url ); @@ -19488,7 +19153,8 @@ function add_submenu_link_item( $menu_slug, $capability, $priority, - $show_submenu + $show_submenu, + $class ); return; @@ -19508,6 +19174,7 @@ function add_submenu_link_item( 'render_function' => 'fs_dummy', 'before_render_function' => '', 'show_submenu' => $show_submenu, + 'class' => $class, ); } @@ -24884,27 +24551,6 @@ private function add_after_plan_activation_or_upgrade_instructions_notice( $is_u ); } - /** - * @author Leo Fajardo (@leorw) - * @since 2.1.0 - * - * @param string $url - * @param array $request - */ - private static function enrich_request_for_debug( &$url, &$request ) { - if ( WP_FS__DEBUG_SDK || isset( $_COOKIE['XDEBUG_SESSION'] ) ) { - $url = add_query_arg( 'XDEBUG_SESSION_START', rand( 0, 9999999 ), $url ); - $url = add_query_arg( 'XDEBUG_SESSION', 'PHPSTORM', $url ); - - $request['cookies'] = array( - new WP_Http_Cookie( array( - 'name' => 'XDEBUG_SESSION', - 'value' => 'PHPSTORM', - ) ) - ); - } - } - /** * @author Leo Fajardo (@leorw) * @since 2.1.0 @@ -24934,7 +24580,7 @@ static function safe_remote_post( if ( false === $response ) { if ( $maybe_enrich_request_for_debug ) { - self::enrich_request_for_debug( $url, $request ); + FS_DebugManager::enrich_request_for_debug( $url, $request ); } if ( ! isset( $request['method'] ) ) { diff --git a/includes/class-fs-logger.php b/includes/class-fs-logger.php index 6dde8aa3..c5f0c52a 100644 --- a/includes/class-fs-logger.php +++ b/includes/class-fs-logger.php @@ -32,6 +32,9 @@ class FS_Logger { */ private static $_abspathLength; + /** + * @var FS_Logger[] $LOGGERS + */ private static $LOGGERS = array(); private static $LOG = array(); private static $CNT = 0; @@ -124,7 +127,6 @@ function on() { self::hook_footer(); } - function echo_on() { $this->on(); @@ -320,6 +322,11 @@ public static function _set_storage_logging( $is_on = true ) { $table = "{$wpdb->prefix}fs_logger"; + /** + * Drop logging table in any case. + */ + $result = $wpdb->query( "DROP TABLE IF EXISTS $table;" ); + if ( $is_on ) { /** * Create logging table. @@ -329,7 +336,7 @@ public static function _set_storage_logging( $is_on = true ) { * * @link https://core.trac.wordpress.org/ticket/2695 */ - $result = $wpdb->query( "CREATE TABLE {$table} ( + $result = $wpdb->query( "CREATE TABLE IF NOT EXISTS {$table} ( `id` BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, `process_id` INT UNSIGNED NOT NULL, `user_name` VARCHAR(64) NOT NULL, @@ -348,15 +355,11 @@ public static function _set_storage_logging( $is_on = true ) { KEY `process_logger` (`process_id` ASC, `logger` ASC), KEY `function` (`function` ASC), KEY `type` (`type` ASC))" ); - } else { - /** - * Drop logging table. - */ - $result = $wpdb->query( "DROP TABLE IF EXISTS $table;" ); } if ( false !== $result ) { update_option( 'fs_storage_logger', ( $is_on ? 1 : 0 ) ); + self::$_isStorageLoggingOn = $is_on; } return ( false !== $result ); diff --git a/includes/class-fs-plugin-updater.php b/includes/class-fs-plugin-updater.php index c54c190b..dc233da4 100755 --- a/includes/class-fs-plugin-updater.php +++ b/includes/class-fs-plugin-updater.php @@ -106,6 +106,8 @@ private function filters() { if ( ! $this->_fs->has_any_active_valid_license() ) { add_action( 'admin_head', array( &$this, 'catch_plugin_information_dialog_contents' ) ); + } else { + add_action( 'admin_footer', array( &$this, '_add_fs_allow_updater_and_dialog_request_param' ) ); } if ( ! WP_FS__IS_PRODUCTION_MODE ) { @@ -129,15 +131,48 @@ private function filters() { } } + /** + * @author Leo Fajardo (@leorw) + * @since 2.7.4 + */ + function _add_fs_allow_updater_and_dialog_request_param() { + if ( ! $this->is_plugin_information_dialog_for_plugin() ) { + return; + } + ?> + + _fs->get_slug() === fs_request_get_raw( 'plugin', false ) + ); + } + /** * @author Leo Fajardo (@leorw) * @since 2.1.4 */ function catch_plugin_information_dialog_contents() { - if ( - 'plugin-information' !== fs_request_get( 'tab', false ) || - $this->_fs->get_slug() !== fs_request_get_raw( 'plugin', false ) - ) { + if ( ! $this->is_plugin_information_dialog_for_plugin() ) { return; } @@ -616,7 +651,7 @@ function pre_set_site_transient_update_plugins_filter( $transient_data ) { $slug = $this->_fs->get_slug(); - if ( $this->_fs->is_org_repo_compliant() && $this->_fs->is_freemium() ) { + if ( $this->can_fetch_data_from_wp_org() ) { if ( ! isset( $this->_translation_updates ) ) { $this->_translation_updates = array(); @@ -873,6 +908,16 @@ static function _fetch_plugin_info_from_repository( $action, $args ) { return $res; } + /** + * Returns true if the product can fetch data from WordPress.org. + * + * @author Leo Fajardo (@leorw) + * @since 2.7.4 + */ + private function can_fetch_data_from_wp_org() { + return ( $this->_fs->is_org_repo_compliant() && $this->_fs->is_freemium() ); + } + /** * Fetches module translation updates from wordpress.org. * @@ -1057,7 +1102,7 @@ function plugins_api_filter( $data, $action = '', $args = null ) { } $plugin_in_repo = false; - if ( ! $is_addon ) { + if ( ! $is_addon && $this->can_fetch_data_from_wp_org() ) { // Try to fetch info from .org repository. $data = self::_fetch_plugin_info_from_repository( $action, $args ); diff --git a/includes/class-fs-storage.php b/includes/class-fs-storage.php index 1093302a..1028b113 100644 --- a/includes/class-fs-storage.php +++ b/includes/class-fs-storage.php @@ -20,6 +20,7 @@ * @property bool|null $is_extensions_tracking_allowed * @property bool|null $is_diagnostic_tracking_allowed * @property object $sync_cron + * @property bool|int $install_timestamp */ class FS_Storage { /** diff --git a/includes/entities/class-fs-plugin-plan.php b/includes/entities/class-fs-plugin-plan.php index 5bc6bc2d..e89e2bce 100755 --- a/includes/entities/class-fs-plugin-plan.php +++ b/includes/entities/class-fs-plugin-plan.php @@ -92,6 +92,14 @@ class FS_Plugin_Plan extends FS_Entity { * @var bool Is hidden plan. */ public $is_hidden; + /** + * @var FS_Pricing[] + */ + public $pricing; + /** + * @var object[] + */ + public $features; #endregion Properties diff --git a/includes/entities/class-fs-site.php b/includes/entities/class-fs-site.php index f9012d05..e8049bae 100755 --- a/includes/entities/class-fs-site.php +++ b/includes/entities/class-fs-site.php @@ -182,6 +182,7 @@ static function is_localhost_by_address( $url ) { fs_ends_with( $subdomain, '.staging.wpengine.com' ) || fs_ends_with( $subdomain, '.dev.wpengine.com' ) || fs_ends_with( $subdomain, '.wpengine.com' ) || + fs_ends_with( $subdomain, '.wpenginepowered.com' ) || // Pantheon ( fs_ends_with( $subdomain, 'pantheonsite.io' ) && ( fs_starts_with( $subdomain, 'test-' ) || fs_starts_with( $subdomain, 'dev-' ) ) ) || @@ -201,7 +202,9 @@ static function is_localhost_by_address( $url ) { // Vendasta ( fs_ends_with( $subdomain, '.websitepro-staging.com' ) || fs_ends_with( $subdomain, '.websitepro.hosting' ) ) || // InstaWP - fs_ends_with( $subdomain, '.instawp.xyz' ) + fs_ends_with( $subdomain, '.instawp.xyz' ) || + // 10Web Hosting + ( fs_ends_with( $subdomain, '-dev.10web.site' ) || fs_ends_with( $subdomain, '-dev.10web.cloud' ) ) ); } diff --git a/includes/managers/class-fs-debug-manager.php b/includes/managers/class-fs-debug-manager.php new file mode 100644 index 00000000..f8b8e130 --- /dev/null +++ b/includes/managers/class-fs-debug-manager.php @@ -0,0 +1,508 @@ +entrance(); + + $title = sprintf( '%s [v.%s]', fs_text_inline( 'Freemius Debug' ), WP_FS__SDK_VERSION ); + + if ( WP_FS__DEV_MODE ) { + // Add top-level debug menu item. + $hook = FS_Admin_Menu_Manager::add_page( + $title, + $title, + 'manage_options', + 'freemius', + array( self::class, '_debug_page_render' ) + ); + } else { + // Add hidden debug page. + $hook = FS_Admin_Menu_Manager::add_subpage( + '', + $title, + $title, + 'manage_options', + 'freemius', + array( self::class, '_debug_page_render' ) + ); + } + + if ( ! empty( $hook ) ) { + add_action( "load-$hook", array( self::class, '_debug_page_actions' ) ); + } + } + + /** + * @author Vova Feldman (@svovaf) + * Moved from Freemius + * + * @since 1.0.8 + */ + static function _debug_page_actions() { + Freemius::_clean_admin_content_section(); + + if ( fs_request_is_action( 'restart_freemius' ) ) { + check_admin_referer( 'restart_freemius' ); + + if ( ! is_multisite() ) { + // Clear accounts data. + Freemius::get_accounts()->clear( null, true ); + } else { + $sites = Freemius::get_sites(); + foreach ( $sites as $site ) { + $blog_id = Freemius::get_site_blog_id( $site ); + Freemius::get_accounts()->clear( $blog_id, true ); + } + + // Clear network level storage. + Freemius::get_accounts()->clear( true, true ); + } + + // Clear SDK reference cache. + delete_option( 'fs_active_plugins' ); + } else if ( fs_request_is_action( 'clear_updates_data' ) ) { + check_admin_referer( 'clear_updates_data' ); + + if ( ! is_multisite() ) { + set_site_transient( 'update_plugins', null ); + set_site_transient( 'update_themes', null ); + } else { + $current_blog_id = get_current_blog_id(); + + $sites = Freemius::get_sites(); + foreach ( $sites as $site ) { + switch_to_blog( Freemius::get_site_blog_id( $site ) ); + + set_site_transient( 'update_plugins', null ); + set_site_transient( 'update_themes', null ); + } + + switch_to_blog( $current_blog_id ); + } + } else if ( fs_request_is_action( 'reset_deactivation_snoozing' ) ) { + check_admin_referer( 'reset_deactivation_snoozing' ); + + Freemius::reset_deactivation_snoozing(); + } else if ( fs_request_is_action( 'simulate_trial' ) ) { + check_admin_referer( 'simulate_trial' ); + + $fs = freemius( fs_request_get( 'module_id' ) ); + + // Update SDK install to at least 24 hours before. + $fs->get_storage()->install_timestamp = ( time() - WP_FS__TIME_24_HOURS_IN_SEC ); + // Unset the trial shown timestamp. + unset( $fs->get_storage()->trial_promotion_shown ); + } else if ( fs_request_is_action( 'simulate_network_upgrade' ) ) { + check_admin_referer( 'simulate_network_upgrade' ); + + $fs = freemius( fs_request_get( 'module_id' ) ); + + Freemius::set_network_upgrade_mode( $fs->get_storage() ); + } else if ( fs_request_is_action( 'delete_install' ) ) { + check_admin_referer( 'delete_install' ); + + Freemius::_delete_site_by_slug( + fs_request_get( 'slug' ), + fs_request_get( 'module_type' ), + true, + fs_request_get( 'blog_id', null ) + ); + } else if ( fs_request_is_action( 'delete_user' ) ) { + check_admin_referer( 'delete_user' ); + + self::delete_user( fs_request_get( 'user_id' ) ); + } else if ( fs_request_is_action( 'download_logs' ) ) { + check_admin_referer( 'download_logs' ); + + $download_url = FS_Logger::download_db_logs( + fs_request_get( 'filters', false, 'post' ) + ); + + if ( false === $download_url ) { + wp_die( 'Oops... there was an error while generating the logs download file. Please try again and if it doesn\'t work contact support@freemius.com.' ); + } + + fs_redirect( $download_url ); + } else if ( fs_request_is_action( 'migrate_options_to_network' ) ) { + check_admin_referer( 'migrate_options_to_network' ); + + Freemius::migrate_options_to_network(); + } + } + + /** + * @author Vova Feldman (@svovaf) + * Moved from Freemius + * + * @since 1.0.8 + */ + static function _debug_page_render() { + Freemius::get_static_logger()->entrance(); + + $all_modules_sites = self::get_all_modules_sites(); + + $licenses_by_module_type = self::get_all_licenses_by_module_type(); + + $vars = array( + 'plugin_sites' => $all_modules_sites[ WP_FS__MODULE_TYPE_PLUGIN ], + 'theme_sites' => $all_modules_sites[ WP_FS__MODULE_TYPE_THEME ], + 'users' => Freemius::get_all_users(), + 'addons' => Freemius::get_all_addons(), + 'account_addons' => Freemius::get_all_account_addons(), + 'plugin_licenses' => $licenses_by_module_type[ WP_FS__MODULE_TYPE_PLUGIN ], + 'theme_licenses' => $licenses_by_module_type[ WP_FS__MODULE_TYPE_THEME ], + ); + + fs_enqueue_local_style( 'fs_debug', '/admin/debug.css' ); + fs_require_once_template( 'debug.php', $vars ); + } + + /** + * @author Vova Feldman (@svovaf) + * Moved from Freemius + * + * @since 1.2.1.6 + */ + static function _get_debug_log() { + check_admin_referer( 'fs_get_debug_log' ); + + if ( ! is_super_admin() ) { + return; + } + + if (!FS_Logger::is_storage_logging_on()) { + return; + } + + $limit = min( ! empty( $_POST['limit'] ) ? absint( $_POST['limit'] ) : 200, 200 ); + $offset = min( ! empty( $_POST['offset'] ) ? absint( $_POST['offset'] ) : 200, 200 ); + + $logs = FS_Logger::load_db_logs( + fs_request_get( 'filters', false, 'post' ), + $limit, + $offset + ); + + Freemius::shoot_ajax_success( $logs ); + } + + /** + * @author Vova Feldman (@svovaf) + * Moved from Freemius + * + * @since 1.2.1.7 + */ + static function _get_db_option() { + check_admin_referer( 'fs_get_db_option' ); + + $option_name = fs_request_get( 'option_name' ); + + if ( ! is_super_admin() || + ! fs_starts_with( $option_name, 'fs_' ) + ) { + Freemius::shoot_ajax_failure(); + } + + $value = get_option( $option_name ); + + $result = array( + 'name' => $option_name, + ); + + if ( false !== $value ) { + if ( ! is_string( $value ) ) { + $value = json_encode( $value ); + } + + $result['value'] = $value; + } + + Freemius::shoot_ajax_success( $result ); + } + + /** + * @author Vova Feldman (@svovaf) + * Moved from Freemius + * + * @since 1.2.1.7 + */ + static function _set_db_option() { + check_admin_referer( 'fs_set_db_option' ); + + $option_name = fs_request_get( 'option_name' ); + + if ( ! is_super_admin() || + ! fs_starts_with( $option_name, 'fs_' ) + ) { + Freemius::shoot_ajax_failure(); + } + + $option_value = fs_request_get_raw( 'option_value' ); + + if ( ! empty( $option_value ) ) { + update_option( $option_name, $option_value ); + } + + Freemius::shoot_ajax_success(); + } + + /** + * @author Vova Feldman (@svovaf) + * Moved from Freemius + * + * @since 1.1.7.3 + */ + static function _toggle_debug_mode() { + check_admin_referer( 'fs_toggle_debug_mode' ); + + if ( ! is_super_admin() ) { + return; + } + + $is_on = fs_request_get( 'is_on', false, 'post' ); + + if ( fs_request_is_post() && in_array( $is_on, array( 0, 1 ) ) ) { + if ( $is_on ) { + self::_turn_on_debug_mode(); + } else { + self::_turn_off_debug_mode(); + } + + // Logic to turn debugging off automatically + if ( 1 == $is_on ) { + // Plan a single event triggering after 24 hours to turn debugging off. + wp_schedule_single_event( time() + 24 * HOUR_IN_SECONDS, 'fs_debug_turn_off_logging_hook' ); + } else { + // Cancels any planned event when debugging is turned off manually. + $timestamp = wp_next_scheduled( 'fs_debug_turn_off_logging_hook' ); + if ( $timestamp ) { + wp_unschedule_event( $timestamp, 'fs_debug_turn_off_logging_hook' ); + } + } + } + + exit; + } + + /** + * @author Daniele Alessandra (@danielealessandra) + * @since 2.6.2 + * + */ + static function _turn_off_debug_mode() { + self::update_debug_mode_option( 0 ); + FS_Logger::_set_storage_logging( false ); + } + + /** + * @author Daniele Alessandra (@danielealessandra) + * @since 2.6.2 + * + */ + static function _turn_on_debug_mode() { + self::update_debug_mode_option( 1 ); + FS_Logger::_set_storage_logging(); + } + + /** + * @author Leo Fajardo (@leorw) + * Moved from Freemius + * + * @param string $url + * @param array $request + * + * @since 2.1.0 + * + */ + public static function enrich_request_for_debug( &$url, &$request ) { + if ( WP_FS__DEBUG_SDK || isset( $_COOKIE['XDEBUG_SESSION'] ) ) { + $url = add_query_arg( 'XDEBUG_SESSION_START', rand( 0, 9999999 ), $url ); + $url = add_query_arg( 'XDEBUG_SESSION', 'PHPSTORM', $url ); + + $request['cookies'] = array( + new WP_Http_Cookie( array( + 'name' => 'XDEBUG_SESSION', + 'value' => 'PHPSTORM', + ) ), + ); + } + } + + /** + * @author Leo Fajardo (@leorw) + * Moved from Freemius + * + * @return array + * + * @since 2.0.0 + * + */ + private static function get_all_licenses_by_module_type() { + $licenses = Freemius::get_account_option( 'all_licenses' ); + + $licenses_by_module_type = array( + WP_FS__MODULE_TYPE_PLUGIN => array(), + WP_FS__MODULE_TYPE_THEME => array(), + ); + + if ( ! is_array( $licenses ) ) { + return $licenses_by_module_type; + } + + foreach ( $licenses as $module_id => $module_licenses ) { + $fs = Freemius::get_instance_by_id( $module_id ); + if ( false === $fs ) { + continue; + } + + $licenses_by_module_type[ $fs->get_module_type() ] = array_merge( $licenses_by_module_type[ $fs->get_module_type() ], + $module_licenses ); + } + + return $licenses_by_module_type; + } + + /** + * @author Leo Fajardo (@leorw) + * Moved from Freemius + * + * @return array + * + * @since 2.5.0 + * + */ + static function get_all_modules_sites() { + Freemius::get_static_logger()->entrance(); + + $sites_by_type = array( + WP_FS__MODULE_TYPE_PLUGIN => array(), + WP_FS__MODULE_TYPE_THEME => array(), + ); + + $module_types = array_keys( $sites_by_type ); + + if ( ! is_multisite() ) { + foreach ( $module_types as $type ) { + $sites_by_type[ $type ] = Freemius::get_all_sites( $type ); + + foreach ( $sites_by_type[ $type ] as $slug => $install ) { + $sites_by_type[ $type ][ $slug ] = array( $install ); + } + } + } else { + $sites = Freemius::get_sites(); + + foreach ( $sites as $site ) { + $blog_id = Freemius::get_site_blog_id( $site ); + + foreach ( $module_types as $type ) { + $installs = Freemius::get_all_sites( $type, $blog_id ); + + foreach ( $installs as $slug => $install ) { + if ( ! isset( $sites_by_type[ $type ][ $slug ] ) ) { + $sites_by_type[ $type ][ $slug ] = array(); + } + + $install->blog_id = $blog_id; + + $sites_by_type[ $type ][ $slug ][] = $install; + } + } + } + } + + return $sites_by_type; + } + + /** + * Delete user. + * + * @author Vova Feldman (@svovaf) + * + * @param number $user_id + * @param bool $store + * + * @return false|int The user ID if deleted. Otherwise, FALSE (when install not exist). + * @since 2.0.0 + * + */ + public static function delete_user( $user_id, $store = true ) { + $users = Freemius::get_all_users(); + + if ( ! is_array( $users ) || ! isset( $users[ $user_id ] ) ) { + return false; + } + + unset( $users[ $user_id ] ); + + self::$_accounts->set_option( 'users', $users, $store ); + + return $user_id; + } + + /** + * @author Daniele Alessandra (@danielealessandra) + * + * @return void + * @since 2.6.2 + * + */ + public static function load_required_static() { + if ( ! WP_FS__DEMO_MODE ) { + add_action( ( fs_is_network_admin() ? 'network_' : '' ) . 'admin_menu', array( + self::class, + '_add_debug_section', + ) ); + } + + add_action( "wp_ajax_fs_toggle_debug_mode", array( self::class, '_toggle_debug_mode' ) ); + + Freemius::add_ajax_action_static( 'get_debug_log', array( self::class, '_get_debug_log' ) ); + Freemius::add_ajax_action_static( 'get_db_option', array( self::class, '_get_db_option' ) ); + Freemius::add_ajax_action_static( 'set_db_option', array( self::class, '_set_db_option' ) ); + } + + /** + * @author Daniele Alessandra (@danielealessandra) + * + * @return void + * + * @since 2.6.2 + */ + public static function register_hooks() { + add_action( 'fs_debug_turn_off_logging_hook', array( self::class, '_turn_off_debug_mode' ) ); + } + + /** + * @author Daniele Alessandra (@danielealessandra) + * + * @param int $is_on + * + * @return void + * + * @since 2.6.2 + */ + private static function update_debug_mode_option( $is_on ) { + update_option( 'fs_debug_mode', $is_on ); + } + + } diff --git a/patches/index.php b/patches/index.php new file mode 100644 index 00000000..0316c6a6 --- /dev/null +++ b/patches/index.php @@ -0,0 +1,3 @@ +

newest->version ?>

-
+ +