Version Description
- Added options page to WP Admin (see Settins > Steroids for Elementor) for controlling the active extensions
- Overlaiz, added option to clip-path the Background Overlay
- Glider, added support for slideTo() from any link inside the Glider, with the class ".glider-control", and data attribute "data-gotoslide|N" (where N is the slide number)
- Glider, hash navigation enabled (see: https://swiperjs.com/api/#hash-navigation)
Download this release
Release Info
Developer | ooohboi |
Plugin | OoohBoi Steroids for Elementor |
Version | 1.4.8 |
Comparing to | |
See all releases |
Code changes from version 1.4.7 to 1.4.8
- assets/css/admin.css +149 -0
- assets/css/editor.css +1 -21
- assets/img/banner-pre.png +0 -0
- assets/js/ooohboi-steroids-min.js +1 -1
- assets/js/ooohboi-steroids.js +15 -2
- controls/ooohboi-breaking-bad.php +0 -19
- controls/ooohboi-butter-button.php +0 -10
- controls/ooohboi-glider.php +0 -10
- controls/ooohboi-harakiri.php +0 -10
- controls/ooohboi-overlaiz.php +40 -13
- controls/ooohboi-overlay-underlay.php +0 -10
- controls/ooohboi-paginini.php +0 -10
- controls/ooohboi-perspektive.php +0 -10
- controls/ooohboi-photogiraffe.php +0 -10
- controls/ooohboi-searchcop.php +0 -10
- controls/ooohboi-shadough.php +0 -10
- controls/ooohboi-teleporter.php +0 -10
- controls/ooohboi-videomasq.php +0 -13
- inc/RationalOptionPages.php +868 -0
- inc/common-functions.php +94 -8
- lang/ooohboi-steroids.pot +100 -27
- ooohboi-steroids.php +42 -32
- readme.txt +8 -2
assets/css/admin.css
ADDED
@@ -0,0 +1,149 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/* Steroids settings page */
|
2 |
+
|
3 |
+
.ob-settings-page.wrap h1:first-child {
|
4 |
+
font-size: 40px;
|
5 |
+
font-weight: 400;
|
6 |
+
letter-spacing: -1px;
|
7 |
+
}
|
8 |
+
|
9 |
+
.ob-settings-page form h2 + p {
|
10 |
+
font-size: 20px;
|
11 |
+
line-height: 32px;
|
12 |
+
font-weight: 200;
|
13 |
+
}
|
14 |
+
|
15 |
+
.ob-settings-page .form-table {
|
16 |
+
padding: 32px;
|
17 |
+
background-color: #FFF;
|
18 |
+
}
|
19 |
+
|
20 |
+
.ob-settings-page .form-table th,
|
21 |
+
.ob-settings-page .form-table td {
|
22 |
+
position: relative;
|
23 |
+
padding: 24px;
|
24 |
+
border-bottom: 1px solid rgba( 0, 0, 0, 0.1 );
|
25 |
+
}
|
26 |
+
|
27 |
+
.ob-settings-page .form-table th {
|
28 |
+
padding-right: 0;
|
29 |
+
}
|
30 |
+
|
31 |
+
.ob-settings-page .form-table th:before {
|
32 |
+
content: '';
|
33 |
+
position: absolute;
|
34 |
+
top: 0;
|
35 |
+
left: 0;
|
36 |
+
width: 16px;
|
37 |
+
height: 16px;
|
38 |
+
background-image: url( '../img/ooohboi-poopart-icon.png' );
|
39 |
+
background-size: cover;
|
40 |
+
background-position: top left;
|
41 |
+
background-repeat: no-repeat;
|
42 |
+
}
|
43 |
+
|
44 |
+
.ob-settings-page .form-table th label {
|
45 |
+
font-size: 16px !important;
|
46 |
+
font-weight: 400;
|
47 |
+
}
|
48 |
+
|
49 |
+
.ob-settings-page .form-table td label {
|
50 |
+
font-size: 14px !important;
|
51 |
+
font-weight: 300;
|
52 |
+
}
|
53 |
+
|
54 |
+
@supports (-webkit-appearance: none) or (-moz-appearance: none) {
|
55 |
+
.wrap.ob-settings-page input[type='checkbox'],
|
56 |
+
.wrap.ob-settings-page input[type='radio'] {
|
57 |
+
--active: #275EFE;
|
58 |
+
--active-inner: #fff;
|
59 |
+
--focus: 2px rgba(39, 94, 254, .3);
|
60 |
+
--border: #BBC1E1;
|
61 |
+
--border-hover: #275EFE;
|
62 |
+
--background: #fff;
|
63 |
+
--disabled: #F6F8FF;
|
64 |
+
--disabled-inner: #E1E6F9;
|
65 |
+
-webkit-appearance: none;
|
66 |
+
-moz-appearance: none;
|
67 |
+
height: 21px;
|
68 |
+
outline: none;
|
69 |
+
display: inline-block;
|
70 |
+
vertical-align: top;
|
71 |
+
position: relative;
|
72 |
+
margin: 0;
|
73 |
+
cursor: pointer;
|
74 |
+
border: 1px solid var(--bc, var(--border));
|
75 |
+
background: var(--b, var(--background));
|
76 |
+
-webkit-transition: background .3s, border-color .3s, box-shadow .2s;
|
77 |
+
transition: background .3s, border-color .3s, box-shadow .2s;
|
78 |
+
}
|
79 |
+
.wrap.ob-settings-page input[type='checkbox']:after {
|
80 |
+
content: '';
|
81 |
+
display: block;
|
82 |
+
left: 0;
|
83 |
+
top: 0;
|
84 |
+
position: absolute;
|
85 |
+
-webkit-transition: opacity var(--d-o, 0.2s), -webkit-transform var(--d-t, 0.3s) var(--d-t-e, ease);
|
86 |
+
transition: opacity var(--d-o, 0.2s), -webkit-transform var(--d-t, 0.3s) var(--d-t-e, ease);
|
87 |
+
transition: transform var(--d-t, 0.3s) var(--d-t-e, ease), opacity var(--d-o, 0.2s);
|
88 |
+
transition: transform var(--d-t, 0.3s) var(--d-t-e, ease), opacity var(--d-o, 0.2s), -webkit-transform var(--d-t, 0.3s) var(--d-t-e, ease);
|
89 |
+
}
|
90 |
+
.wrap.ob-settings-page input[type='checkbox']:checked {
|
91 |
+
--b: var(--active);
|
92 |
+
--bc: var(--active);
|
93 |
+
--d-o: .3s;
|
94 |
+
--d-t: .6s;
|
95 |
+
--d-t-e: cubic-bezier(.2, .85, .32, 1.2);
|
96 |
+
}
|
97 |
+
.wrap.ob-settings-page input[type='checkbox']:disabled {
|
98 |
+
--b: var(--disabled);
|
99 |
+
cursor: not-allowed;
|
100 |
+
opacity: .9;
|
101 |
+
}
|
102 |
+
.wrap.ob-settings-page input[type='checkbox']:disabled:checked {
|
103 |
+
--b: var(--disabled-inner);
|
104 |
+
--bc: var(--border);
|
105 |
+
}
|
106 |
+
.wrap.ob-settings-page input[type='checkbox']:disabled + label {
|
107 |
+
cursor: not-allowed;
|
108 |
+
}
|
109 |
+
.wrap.ob-settings-page input[type='checkbox']:hover:not(:checked):not(:disabled) {
|
110 |
+
--bc: var(--border-hover);
|
111 |
+
}
|
112 |
+
.wrap.ob-settings-page input[type='checkbox']:focus {
|
113 |
+
box-shadow: 0 0 0 var(--focus);
|
114 |
+
}
|
115 |
+
.wrap.ob-settings-page input[type='checkbox'] + label {
|
116 |
+
font-size: 14px;
|
117 |
+
line-height: 21px;
|
118 |
+
display: inline-block;
|
119 |
+
vertical-align: top;
|
120 |
+
cursor: pointer;
|
121 |
+
margin-left: 4px;
|
122 |
+
}
|
123 |
+
.wrap.ob-settings-page input[type='checkbox'] {
|
124 |
+
width: 38px;
|
125 |
+
border-radius: 11px;
|
126 |
+
}
|
127 |
+
.wrap.ob-settings-page input[type='checkbox']:after {
|
128 |
+
left: 2px;
|
129 |
+
top: 2px;
|
130 |
+
border-radius: 50%;
|
131 |
+
width: 15px;
|
132 |
+
height: 15px;
|
133 |
+
background: var(--ab, var(--border));
|
134 |
+
-webkit-transform: translateX(var(--x, 0));
|
135 |
+
transform: translateX(var(--x, 0));
|
136 |
+
}
|
137 |
+
.wrap.ob-settings-page input[type='checkbox']:checked {
|
138 |
+
--ab: var(--active-inner);
|
139 |
+
--x: 17px;
|
140 |
+
}
|
141 |
+
.wrap.ob-settings-page input[type='checkbox']:disabled:not(:checked):after {
|
142 |
+
opacity: .6;
|
143 |
+
}
|
144 |
+
|
145 |
+
/* checkbox tick fix */
|
146 |
+
.wrap.ob-settings-page input[type="checkbox"]:checked::before {
|
147 |
+
content: '';
|
148 |
+
}
|
149 |
+
}
|
assets/css/editor.css
CHANGED
@@ -45,24 +45,4 @@
|
|
45 |
.ob-is-breaking-bad.elementor-top-section > .elementor-container > .elementor-row,
|
46 |
.ob-is-breaking-bad.elementor-inner-section > .elementor-container > .elementor-row {
|
47 |
flex-wrap: wrap;
|
48 |
-
}
|
49 |
-
|
50 |
-
/* MISC */
|
51 |
-
/*
|
52 |
-
div[class*="_ob_sponsorship"] * {
|
53 |
-
transition: none;
|
54 |
-
border: none;
|
55 |
-
}
|
56 |
-
div[class*="_ob_sponsorship"] {
|
57 |
-
padding-top: 15px;
|
58 |
-
border-top: 2px dashed rgba(0,0,0,0.1);
|
59 |
-
}
|
60 |
-
div[class*="_ob_sponsorship"] a {
|
61 |
-
display: block;
|
62 |
-
line-height: 0;
|
63 |
-
}
|
64 |
-
div[class*="_ob_sponsorship"] a:hover {
|
65 |
-
text-decoration: none;
|
66 |
-
border: none;
|
67 |
-
}
|
68 |
-
*/
|
45 |
.ob-is-breaking-bad.elementor-top-section > .elementor-container > .elementor-row,
|
46 |
.ob-is-breaking-bad.elementor-inner-section > .elementor-container > .elementor-row {
|
47 |
flex-wrap: wrap;
|
48 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
assets/img/banner-pre.png
DELETED
Binary file
|
assets/js/ooohboi-steroids-min.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
"use strict";!function(e,t){var o=e(t);o.on("elementor/frontend/init",(function(){var t=elementorModules.frontend.handlers.Base.extend({onInit:function(){elementorModules.frontend.handlers.Base.prototype.onInit.apply(this,arguments),this.initPoopArtPerspektive()},initPoopArtPerspektive:function(){this.isEdit&&(this.$element.addClass("ob-has-background-overlay"),"yes"===this.getElementSettings("_ob_perspektive_use")&&this.$element.addClass("ob-use-perspektive"))},onElementChange:function(e){"_ob_perspektive_use"===e&&("yes"===this.getElementSettings("_ob_perspektive_use")?this.$element.addClass("ob-use-perspektive"):this.$element.removeClass("ob-use-perspektive"))},isPerspektive:function(){return this.$element.hasClass("ob-use-perspektive")}}),r=elementorModules.frontend.handlers.Base.extend({onInit:function(){elementorModules.frontend.handlers.Base.prototype.onInit.apply(this,arguments),this.initHarakiri()},initHarakiri:function(){this.isEdit&&"inherit"!==this.getElementSettings("_ob_harakiri_writing_mode")&&this.$element.addClass("ob-harakiri")},onElementChange:function(e){"_ob_harakiri_writing_mode"===e&&("inherit"!==this.getElementSettings("_ob_harakiri_writing_mode")?this.$element.addClass("ob-harakiri"):this.$element.removeClass("ob-harakiri"))}}),s={widget:t,"heading.default":r,"text-editor.default":r,section:elementorModules.frontend.handlers.Base.extend({onInit:function(){elementorModules.frontend.handlers.Base.prototype.onInit.apply(this,arguments),this.initSectionExtends()},isBreakingBad:function(){return this.$element.hasClass("ob-is-breaking-bad")},isGlider:function(){return this.$element.hasClass("ob-is-glider")},onElementChange:function(e){"_ob_bbad_use_it"===e&&("yes"===this.getElementSettings("_ob_bbad_use_it")?this.$element.addClass("ob-is-breaking-bad"):this.$element.removeClass("ob-is-breaking-bad")),"_ob_glider_is_slider"===e&&("yes"===this.getElementSettings("_ob_glider_is_slider")?(this.$element.addClass("ob-is-glider"),this.addClassesRouteGlider(".elementor-element-"+this.$element.attr("data-id"),"addClass"),this.initSwiperElements()):"yes"!=this.getElementSettings("_ob_glider_is_slider")&&(this.$element.removeClass("ob-is-glider"),this.addClassesRouteGlider(".elementor-element-"+this.$element.attr("data-id"),"removeClass")))},addClassesRouteGlider:function(t,o){var n=e(t).children(".elementor-container").first();n.length&&n.addClass("swiper-container");var r=e(n).children(".elementor-row").first();r.length&&"addClass"==o?(r.addClass("swiper-wrapper"),e(r).children("div.elementor-column").addClass("swiper-slide")):(e(n).children("div.elementor-column").wrapAll('<div class="swiper-wrapper" />'),e(n).children(".swiper-wrapper").first().children("div.elementor-column").addClass("swiper-slide")),r.length&&"removeClass"==o?(r.removeClass("swiper-wrapper"),e(r).children("div.elementor-column").removeClass("swiper-slide")):(e(n).children("div.elementor-column").unwrap(),e(n).children("div.elementor-column").removeClass("swiper-slide"))},initSectionExtends:function(){this.isEdit?("yes"!==this.getElementSettings("_ob_bbad_use_it")||this.isBreakingBad()||this.$element.addClass("ob-is-breaking-bad"),"yes"===this.getElementSettings("_ob_glider_is_slider")&&(this.$element.addClass("ob-is-glider"),this.addClassesRouteGlider(".elementor-element-"+this.$element.attr("data-id"),"addClass"),this.initSwiperElements())):"yes"===this.getElementSettings("_ob_glider_is_slider")&&(this.$element.addClass("ob-is-glider"),this.addClassesRouteGlider(".elementor-element-"+this.$element.attr("data-id"),"addClass"),this.initSwiperElements())},initSwiperElements:function(){this.$element.children(".elementor-container .swiper-button-next").first().length||this.$element.children(".elementor-container").first().append('<div class="swiper-button-next"><svg xmlns="http://www.w3.org/2000/svg" preserveAspectRatio="xMidYMin" viewBox="0 0 27 44"><path d="M27 22L5 44l-2.1-2.1L22.8 22 2.9 2.1 5 0l22 22z"></path></svg></div>'),this.$element.children(".elementor-container .swiper-button-prev").first().length||this.$element.children(".elementor-container").first().append('<div class="swiper-button-prev"><svg xmlns="http://www.w3.org/2000/svg" preserveAspectRatio="xMidYMin" viewBox="0 0 27 44"><path d="M0 22L22 0l2.1 2.1L4.2 22l19.9 19.9L22 44 0 22z"></path></svg></div>'),this.$element.children(".elementor-container .swiper-pagination").first().length||this.$element.children(".elementor-container").first().append('<div class="swiper-pagination"></div>');var e={};e.pagination_type=this.getElementSettings("_ob_glider_pagination_type"),e.allowTouchMove=this.getElementSettings("_ob_glider_allow_touch_move"),e.autoheight=this.getElementSettings("_ob_glider_auto_h"),e.effect=this.getElementSettings("_ob_glider_effect"),e.loop=this.getElementSettings("_ob_glider_loop"),e.direction=this.getElementSettings("_ob_glider_direction"),e.parallax=this.getElementSettings("_ob_glider_parallax"),e.speed=this.getElementSettings("_ob_glider_speed");var t=this.getElementSettings("_ob_glider_autoplay");e.autoplay=!!t&&{delay:this.getElementSettings("_ob_glider_autoplay_delay")},n(this.$element.attr("data-id"),e)}}),column:elementorModules.frontend.handlers.Base.extend({onInit:function(){elementorModules.frontend.handlers.Base.prototype.onInit.apply(this,arguments),this.$element.find(".elementor-column-wrap").first().length||this.$element.addClass("ob-is-e3");var e=navigator.userAgent.toLowerCase();e.indexOf("chrome")>-1&&this.teleporterChromeResize(),this.initColumnExtends()},teleporterChromeResize:function(){if(this.isTeleporter()){var e=this,t=this.$element.attr("data-id");o.on("resize",(function(){e.$element.closest(".ob-is-teleporter").addClass("ob-chrome-resize"),clearTimeout(t),t=setTimeout((function(){var t=parseInt(e.$element.closest(".ob-is-teleporter").css("height")),o=e.$element.find(".elementor-column-wrap").first();o.length?o.css({height:t}):e.$element.find(".elementor-widget-wrap").first().css({height:t}),e.$element.closest(".ob-is-teleporter").removeClass("ob-chrome-resize")}),500)})),o.trigger("resize")}},isTeleporter:function(){return this.$element.hasClass("ob-is-teleporter")},initColumnExtends:function(){this.isEdit&&"use-teleporter"===this.getElementSettings("_ob_teleporter_use")&&(this.$element.addClass("ob-is-teleporter"),this.$element.find(".elementor-widget-wrap").first().addClass("ob-tele-midget"),this.doTeleporterEditor()),!this.isEdit&&this.isTeleporter()&&(this.$element.find(".elementor-widget-wrap").first().addClass("ob-tele-midget"),this.doTeleporter())},onElementChange:function(e){"_ob_teleporter_overlay_color"===e?this.$element.find('div[class*="ob-teleporter-"] > .ob-tele-overlay').css("background-color",this.getElementSettings("_ob_teleporter_overlay_color")):"_ob_teleporter_no_pass_tablet"===e?"no-tablet"===this.getElementSettings("_ob_teleporter_no_pass_tablet")?this.$element.addClass("ob-tele-no-tablet"):this.$element.removeClass("ob-tele-no-tablet"):"_ob_teleporter_no_pass_mobile"===e&&("no-mobile"===this.getElementSettings("_ob_teleporter_no_pass_mobile")?this.$element.addClass("ob-tele-no-mobile"):this.$element.removeClass("ob-tele-no-mobile"))},doTeleporterEditor:function(){if("use-teleporter"===this.getElementSettings("_ob_teleporter_use")){var t=this.$element.find(".elementor-widget-wrap").first();if(t.length&&(t.wrapInner('<div class="widget-wrap-children" />'),t.find(".elementor-background-overlay").first().length&&t.find(".elementor-background-overlay").first().insertBefore(t.find(".elementor-background-overlay").first().parent())),"do-pass"===this.getElementSettings("_ob_teleporter_pass")){var o=this,n=this.$element,r=this.$element.attr("data-id");"no-tablet"===this.getElementSettings("_ob_teleporter_no_pass_tablet")&&this.$element.addClass("ob-tele-no-tablet"),"no-mobile"===this.getElementSettings("_ob_teleporter_no_pass_mobile")&&this.$element.addClass("ob-tele-no-mobile");var s="section"===this.getElementSettings("_ob_teleporter_pass_element")?this.$element.closest(".elementor-section"):this.$element.closest(".elementor-container");if(s.length){s.css("overflow","hidden");var i=this.getElementSettings("_ob_teleporter_pass_effect"),l='<div class="ob-teleporter-'+r+" ob-tele-eff-"+i+'" data-id-teleporter="'+r+'"><div class="ob-tele-overlay" style="background-color: '+this.getElementSettings("_ob_teleporter_overlay_color")+';"></div></div>';e(".ob-teleporter-"+r).length||this.$element.prepend(l),this.$element.off("mouseenter mouseleave"),this.$element.on("mouseenter mouseleave",(function(t){if("mouseenter"===t.type){if("no-tablet"===o.getElementSettings("_ob_teleporter_no_pass_tablet")&&"tablet"===elementorFrontend.getCurrentDeviceMode())return;if("no-mobile"===o.getElementSettings("_ob_teleporter_no_pass_mobile")&&"mobile"===elementorFrontend.getCurrentDeviceMode())return;if("do-pass"!==o.getElementSettings("_ob_teleporter_pass"))return;var i={"background-color":e(".ob-teleporter-"+r).css("background-color"),"background-image":e(".ob-teleporter-"+r).css("background-image"),"background-position":e(".ob-teleporter-"+r).css("background-position"),"background-size":e(".ob-teleporter-"+r).css("background-size"),"background-repeat":e(".ob-teleporter-"+r).css("background-repeat")};if("section"===o.getElementSettings("_ob_teleporter_pass_element")){var l=s.children().not(".elementor-container").detach();s.addClass("ob-tele-mom-hover").prepend(e(".ob-teleporter-"+r)),s.prepend(l)}else s.addClass("ob-tele-mom-hover").prepend(e(".ob-teleporter-"+r));e(".ob-teleporter-"+r).css(i).hide(),e(".ob-teleporter-"+r).addClass("ob-teleporter-hover").show()}else s.removeClass("ob-tele-mom-hover"),setTimeout((function(){e(".ob-teleporter-"+r).removeAttr("style").removeClass("ob-teleporter-hover"),n.prepend(e(".ob-teleporter-"+r))}),100)}))}}}},doTeleporter:function(){var t=e.parseJSON(this.$element.attr("data-settings"));if("use-teleporter"===t._ob_teleporter_use){var o=this.$element.find(".elementor-widget-wrap").first();if(o.length&&(o.wrapInner('<div class="widget-wrap-children" />'),o.find(".elementor-background-overlay").first().length&&o.find(".elementor-background-overlay").first().insertBefore(o.find(".elementor-background-overlay").first().parent())),"do-pass"===t._ob_teleporter_pass){var n=this.$element,r=this.$element.attr("data-id");"no-tablet"===t._ob_teleporter_no_pass_tablet&&this.$element.addClass("ob-tele-no-tablet"),"no-mobile"===t._ob_teleporter_no_pass_mobile&&this.$element.addClass("ob-tele-no-mobile");var s="section"===t._ob_teleporter_pass_element?this.$element.closest(".elementor-section"):this.$element.closest(".elementor-container");if(s.length){s.css("overflow","hidden");var i=t._ob_teleporter_pass_effect,l='<div class="ob-teleporter-'+r+" ob-tele-eff-"+i+'" data-id-teleporter="'+r+'"><div class="ob-tele-overlay" style="background-color: '+t._ob_teleporter_overlay_color+';"></div>';if(e(".ob-teleporter-"+r).length||this.$element.prepend(l),this.$element.off("mouseenter mouseleave"),this.$element.on("mouseenter",(function(){if(!("no-tablet"===t._ob_teleporter_no_pass_tablet&&"tablet"===elementorFrontend.getCurrentDeviceMode()||"no-mobile"===t._ob_teleporter_no_pass_mobile&&"mobile"===elementorFrontend.getCurrentDeviceMode())){var o={"background-color":e(".ob-teleporter-"+r).css("background-color"),"background-image":e(".ob-teleporter-"+r).css("background-image"),"background-position":e(".ob-teleporter-"+r).css("background-position"),"background-size":e(".ob-teleporter-"+r).css("background-size"),"background-repeat":e(".ob-teleporter-"+r).css("background-repeat")};if("section"===t._ob_teleporter_pass_element){var n=s.children().not(".elementor-container").detach();s.addClass("ob-tele-mom-hover").prepend(e(".ob-teleporter-"+r)),s.prepend(n)}else s.addClass("ob-tele-mom-hover").prepend(e(".ob-teleporter-"+r));e(".ob-teleporter-"+r).css(o).hide(),e(".ob-teleporter-"+r).show().addClass("ob-teleporter-hover")}})),this.$element.on("mouseleave",(function(){s.removeClass("ob-tele-mom-hover"),setTimeout((function(){e(".ob-teleporter-"+r).removeAttr("style").removeClass("ob-teleporter-hover"),n.prepend(e(".ob-teleporter-"+r))}),100)})),void 0!==t._ob_teleporter_link){var a=t._ob_teleporter_link;if(""===a.url)return;this.$element.off("click.obTeleporter"),this.$element.on("click.obTeleporter",(function(){a.is_external?window.open(a.url):location.href=a.url}))}}}}}}),"search-form.default":elementorModules.frontend.handlers.Base.extend({onInit:function(){elementorModules.frontend.handlers.Base.prototype.onInit.apply(this,arguments),this.initSearchCop()},onElementChange:function(e){"_ob_searchcop_srch_options"===e&&this.routeSearchCop()},initSearchCop:function(){this.routeSearchCop()},routeSearchCop:function(){var e=this.getElementSettings("_ob_searchcop_srch_options");if("post"===e||"page"===e){var t=this.$element.find(".elementor-search-form__container");if(!t.length)return;var o='<input type="hidden" name="post_type" value="'+e+'" />';t.prepend(o)}}}),"button.default":elementorModules.frontend.handlers.Base.extend({onInit:function(){elementorModules.frontend.handlers.Base.prototype.onInit.apply(this,arguments),this.initButterButton()},isButterButton:function(){return this.$element.hasClass("ob-is-butterbutton")},onElementChange:function(e){"_ob_butterbutton_use_it"===e&&this.routeButterButton()},initButterButton:function(){this.isEdit&&"yes"===this.getElementSettings("_ob_butterbutton_use_it")&&this.$element.addClass("ob-is-butterbutton")},routeButterButton:function(){this.isButterButton()||"yes"!==this.getElementSettings("_ob_butterbutton_use_it")?this.$element.removeClass("ob-is-butterbutton"):this.$element.addClass("ob-is-butterbutton")}})};e.each(s,(function(e,t){elementorFrontend.hooks.addAction("frontend/element_ready/"+e,(function(e){elementorFrontend.elementsHandler.addHandler(t,{$element:e})}))}))}));var n=function(e,t){new Swiper(".elementor-element-"+e+" .swiper-container",{allowTouchMove:"yes"===t.allowTouchMove,autoHeight:"yes"===t.autoheight,effect:t.effect,loop:t.loop,direction:"fade"===t.effect?"horizontal":t.direction,parallax:"yes"===t.parallax,speed:t.speed,navigation:{nextEl:".elementor-element-"+e+" .swiper-button-next",prevEl:".elementor-element-"+e+" .swiper-button-prev"},pagination:{el:".elementor-element-"+e+" .swiper-pagination",type:t.pagination_type,clickable:!0},autoplay:t.autoplay,watchOverflow:!0})}}(jQuery,window);
|
1 |
+
"use strict";!function(e,t){var o=e(t);o.on("elementor/frontend/init",(function(){var t=elementorModules.frontend.handlers.Base.extend({onInit:function(){elementorModules.frontend.handlers.Base.prototype.onInit.apply(this,arguments),this.initPoopArtPerspektive()},initPoopArtPerspektive:function(){this.isEdit&&(this.$element.addClass("ob-has-background-overlay"),"yes"===this.getElementSettings("_ob_perspektive_use")&&this.$element.addClass("ob-use-perspektive"))},onElementChange:function(e){"_ob_perspektive_use"===e&&("yes"===this.getElementSettings("_ob_perspektive_use")?this.$element.addClass("ob-use-perspektive"):this.$element.removeClass("ob-use-perspektive"))},isPerspektive:function(){return this.$element.hasClass("ob-use-perspektive")}}),r=elementorModules.frontend.handlers.Base.extend({onInit:function(){elementorModules.frontend.handlers.Base.prototype.onInit.apply(this,arguments),this.initHarakiri()},initHarakiri:function(){this.isEdit&&"inherit"!==this.getElementSettings("_ob_harakiri_writing_mode")&&this.$element.addClass("ob-harakiri")},onElementChange:function(e){"_ob_harakiri_writing_mode"===e&&("inherit"!==this.getElementSettings("_ob_harakiri_writing_mode")?this.$element.addClass("ob-harakiri"):this.$element.removeClass("ob-harakiri"))}}),s={widget:t,"heading.default":r,"text-editor.default":r,section:elementorModules.frontend.handlers.Base.extend({onInit:function(){elementorModules.frontend.handlers.Base.prototype.onInit.apply(this,arguments),this.initSectionExtends()},isBreakingBad:function(){return this.$element.hasClass("ob-is-breaking-bad")},isGlider:function(){return this.$element.hasClass("ob-is-glider")},onElementChange:function(e){"_ob_bbad_use_it"===e&&("yes"===this.getElementSettings("_ob_bbad_use_it")?this.$element.addClass("ob-is-breaking-bad"):this.$element.removeClass("ob-is-breaking-bad")),"_ob_glider_is_slider"===e&&("yes"===this.getElementSettings("_ob_glider_is_slider")?(this.$element.addClass("ob-is-glider"),this.addClassesRouteGlider(".elementor-element-"+this.$element.attr("data-id"),"addClass"),this.initSwiperElements()):"yes"!=this.getElementSettings("_ob_glider_is_slider")&&(this.$element.removeClass("ob-is-glider"),this.addClassesRouteGlider(".elementor-element-"+this.$element.attr("data-id"),"removeClass")))},addClassesRouteGlider:function(t,o){var n=e(t).children(".elementor-container").first();n.length&&n.addClass("swiper-container");var r=e(n).children(".elementor-row").first();r.length&&"addClass"==o?(r.addClass("swiper-wrapper"),e(r).children("div.elementor-column").addClass("swiper-slide")):(e(n).children("div.elementor-column").wrapAll('<div class="swiper-wrapper" />'),e(n).children(".swiper-wrapper").first().children("div.elementor-column").addClass("swiper-slide")),r.length&&"removeClass"==o?(r.removeClass("swiper-wrapper"),e(r).children("div.elementor-column").removeClass("swiper-slide")):(e(n).children("div.elementor-column").unwrap(),e(n).children("div.elementor-column").removeClass("swiper-slide"))},initSectionExtends:function(){this.isEdit?("yes"!==this.getElementSettings("_ob_bbad_use_it")||this.isBreakingBad()||this.$element.addClass("ob-is-breaking-bad"),"yes"===this.getElementSettings("_ob_glider_is_slider")&&(this.$element.addClass("ob-is-glider"),this.addClassesRouteGlider(".elementor-element-"+this.$element.attr("data-id"),"addClass"),this.initSwiperElements())):"yes"===this.getElementSettings("_ob_glider_is_slider")&&(this.$element.addClass("ob-is-glider"),this.addClassesRouteGlider(".elementor-element-"+this.$element.attr("data-id"),"addClass"),this.initSwiperElements())},initSwiperElements:function(){this.$element.children(".elementor-container .swiper-button-next").first().length||this.$element.children(".elementor-container").first().append('<div class="swiper-button-next"><svg xmlns="http://www.w3.org/2000/svg" preserveAspectRatio="xMidYMin" viewBox="0 0 27 44"><path d="M27 22L5 44l-2.1-2.1L22.8 22 2.9 2.1 5 0l22 22z"></path></svg></div>'),this.$element.children(".elementor-container .swiper-button-prev").first().length||this.$element.children(".elementor-container").first().append('<div class="swiper-button-prev"><svg xmlns="http://www.w3.org/2000/svg" preserveAspectRatio="xMidYMin" viewBox="0 0 27 44"><path d="M0 22L22 0l2.1 2.1L4.2 22l19.9 19.9L22 44 0 22z"></path></svg></div>'),this.$element.children(".elementor-container .swiper-pagination").first().length||this.$element.children(".elementor-container").first().append('<div class="swiper-pagination"></div>');var e={};e.pagination_type=this.getElementSettings("_ob_glider_pagination_type"),e.allowTouchMove=this.getElementSettings("_ob_glider_allow_touch_move"),e.autoheight=this.getElementSettings("_ob_glider_auto_h"),e.effect=this.getElementSettings("_ob_glider_effect"),e.loop=this.getElementSettings("_ob_glider_loop"),e.direction=this.getElementSettings("_ob_glider_direction"),e.parallax=this.getElementSettings("_ob_glider_parallax"),e.speed=this.getElementSettings("_ob_glider_speed");var t=this.getElementSettings("_ob_glider_autoplay");e.autoplay=!!t&&{delay:this.getElementSettings("_ob_glider_autoplay_delay")},n(this.$element.attr("data-id"),e)}}),column:elementorModules.frontend.handlers.Base.extend({onInit:function(){elementorModules.frontend.handlers.Base.prototype.onInit.apply(this,arguments),this.$element.find(".elementor-column-wrap").first().length||this.$element.addClass("ob-is-e3");var e=navigator.userAgent.toLowerCase();e.indexOf("chrome")>-1&&this.teleporterChromeResize(),this.initColumnExtends()},teleporterChromeResize:function(){if(this.isTeleporter()){var e=this,t=this.$element.attr("data-id");o.on("resize",(function(){e.$element.closest(".ob-is-teleporter").addClass("ob-chrome-resize"),clearTimeout(t),t=setTimeout((function(){var t=parseInt(e.$element.closest(".ob-is-teleporter").css("height")),o=e.$element.find(".elementor-column-wrap").first();o.length?o.css({height:t}):e.$element.find(".elementor-widget-wrap").first().css({height:t}),e.$element.closest(".ob-is-teleporter").removeClass("ob-chrome-resize")}),500)})),o.trigger("resize")}},isTeleporter:function(){return this.$element.hasClass("ob-is-teleporter")},initColumnExtends:function(){this.isEdit&&"use-teleporter"===this.getElementSettings("_ob_teleporter_use")&&(this.$element.addClass("ob-is-teleporter"),this.$element.find(".elementor-widget-wrap").first().addClass("ob-tele-midget"),this.doTeleporterEditor()),!this.isEdit&&this.isTeleporter()&&(this.$element.find(".elementor-widget-wrap").first().addClass("ob-tele-midget"),this.doTeleporter())},onElementChange:function(e){"_ob_teleporter_overlay_color"===e?this.$element.find('div[class*="ob-teleporter-"] > .ob-tele-overlay').css("background-color",this.getElementSettings("_ob_teleporter_overlay_color")):"_ob_teleporter_no_pass_tablet"===e?"no-tablet"===this.getElementSettings("_ob_teleporter_no_pass_tablet")?this.$element.addClass("ob-tele-no-tablet"):this.$element.removeClass("ob-tele-no-tablet"):"_ob_teleporter_no_pass_mobile"===e&&("no-mobile"===this.getElementSettings("_ob_teleporter_no_pass_mobile")?this.$element.addClass("ob-tele-no-mobile"):this.$element.removeClass("ob-tele-no-mobile"))},doTeleporterEditor:function(){if("use-teleporter"===this.getElementSettings("_ob_teleporter_use")){var t=this.$element.find(".elementor-widget-wrap").first();if(t.length&&(t.wrapInner('<div class="widget-wrap-children" />'),t.find(".elementor-background-overlay").first().length&&t.find(".elementor-background-overlay").first().insertBefore(t.find(".elementor-background-overlay").first().parent())),"do-pass"===this.getElementSettings("_ob_teleporter_pass")){var o=this,n=this.$element,r=this.$element.attr("data-id");"no-tablet"===this.getElementSettings("_ob_teleporter_no_pass_tablet")&&this.$element.addClass("ob-tele-no-tablet"),"no-mobile"===this.getElementSettings("_ob_teleporter_no_pass_mobile")&&this.$element.addClass("ob-tele-no-mobile");var s="section"===this.getElementSettings("_ob_teleporter_pass_element")?this.$element.closest(".elementor-section"):this.$element.closest(".elementor-container");if(s.length){s.css("overflow","hidden");var i=this.getElementSettings("_ob_teleporter_pass_effect"),l='<div class="ob-teleporter-'+r+" ob-tele-eff-"+i+'" data-id-teleporter="'+r+'"><div class="ob-tele-overlay" style="background-color: '+this.getElementSettings("_ob_teleporter_overlay_color")+';"></div></div>';e(".ob-teleporter-"+r).length||this.$element.prepend(l),this.$element.off("mouseenter mouseleave"),this.$element.on("mouseenter mouseleave",(function(t){if("mouseenter"===t.type){if("no-tablet"===o.getElementSettings("_ob_teleporter_no_pass_tablet")&&"tablet"===elementorFrontend.getCurrentDeviceMode())return;if("no-mobile"===o.getElementSettings("_ob_teleporter_no_pass_mobile")&&"mobile"===elementorFrontend.getCurrentDeviceMode())return;if("do-pass"!==o.getElementSettings("_ob_teleporter_pass"))return;var i={"background-color":e(".ob-teleporter-"+r).css("background-color"),"background-image":e(".ob-teleporter-"+r).css("background-image"),"background-position":e(".ob-teleporter-"+r).css("background-position"),"background-size":e(".ob-teleporter-"+r).css("background-size"),"background-repeat":e(".ob-teleporter-"+r).css("background-repeat")};if("section"===o.getElementSettings("_ob_teleporter_pass_element")){var l=s.children().not(".elementor-container").detach();s.addClass("ob-tele-mom-hover").prepend(e(".ob-teleporter-"+r)),s.prepend(l)}else s.addClass("ob-tele-mom-hover").prepend(e(".ob-teleporter-"+r));e(".ob-teleporter-"+r).css(i).hide(),e(".ob-teleporter-"+r).addClass("ob-teleporter-hover").show()}else s.removeClass("ob-tele-mom-hover"),setTimeout((function(){e(".ob-teleporter-"+r).removeAttr("style").removeClass("ob-teleporter-hover"),n.prepend(e(".ob-teleporter-"+r))}),100)}))}}}},doTeleporter:function(){var t=e.parseJSON(this.$element.attr("data-settings"));if("use-teleporter"===t._ob_teleporter_use){var o=this.$element.find(".elementor-widget-wrap").first();if(o.length&&(o.wrapInner('<div class="widget-wrap-children" />'),o.find(".elementor-background-overlay").first().length&&o.find(".elementor-background-overlay").first().insertBefore(o.find(".elementor-background-overlay").first().parent())),"do-pass"===t._ob_teleporter_pass){var n=this.$element,r=this.$element.attr("data-id");"no-tablet"===t._ob_teleporter_no_pass_tablet&&this.$element.addClass("ob-tele-no-tablet"),"no-mobile"===t._ob_teleporter_no_pass_mobile&&this.$element.addClass("ob-tele-no-mobile");var s="section"===t._ob_teleporter_pass_element?this.$element.closest(".elementor-section"):this.$element.closest(".elementor-container");if(s.length){s.css("overflow","hidden");var i=t._ob_teleporter_pass_effect,l='<div class="ob-teleporter-'+r+" ob-tele-eff-"+i+'" data-id-teleporter="'+r+'"><div class="ob-tele-overlay" style="background-color: '+t._ob_teleporter_overlay_color+';"></div>';if(e(".ob-teleporter-"+r).length||this.$element.prepend(l),this.$element.off("mouseenter mouseleave"),this.$element.on("mouseenter",(function(){if(!("no-tablet"===t._ob_teleporter_no_pass_tablet&&"tablet"===elementorFrontend.getCurrentDeviceMode()||"no-mobile"===t._ob_teleporter_no_pass_mobile&&"mobile"===elementorFrontend.getCurrentDeviceMode())){var o={"background-color":e(".ob-teleporter-"+r).css("background-color"),"background-image":e(".ob-teleporter-"+r).css("background-image"),"background-position":e(".ob-teleporter-"+r).css("background-position"),"background-size":e(".ob-teleporter-"+r).css("background-size"),"background-repeat":e(".ob-teleporter-"+r).css("background-repeat")};if("section"===t._ob_teleporter_pass_element){var n=s.children().not(".elementor-container").detach();s.addClass("ob-tele-mom-hover").prepend(e(".ob-teleporter-"+r)),s.prepend(n)}else s.addClass("ob-tele-mom-hover").prepend(e(".ob-teleporter-"+r));e(".ob-teleporter-"+r).css(o).hide(),e(".ob-teleporter-"+r).show().addClass("ob-teleporter-hover")}})),this.$element.on("mouseleave",(function(){s.removeClass("ob-tele-mom-hover"),setTimeout((function(){e(".ob-teleporter-"+r).removeAttr("style").removeClass("ob-teleporter-hover"),n.prepend(e(".ob-teleporter-"+r))}),100)})),void 0!==t._ob_teleporter_link){var a=t._ob_teleporter_link;if(""===a.url)return;this.$element.off("click.obTeleporter"),this.$element.on("click.obTeleporter",(function(){a.is_external?window.open(a.url):location.href=a.url}))}}}}}}),"search-form.default":elementorModules.frontend.handlers.Base.extend({onInit:function(){elementorModules.frontend.handlers.Base.prototype.onInit.apply(this,arguments),this.initSearchCop()},onElementChange:function(e){"_ob_searchcop_srch_options"===e&&this.routeSearchCop()},initSearchCop:function(){this.routeSearchCop()},routeSearchCop:function(){var e=this.getElementSettings("_ob_searchcop_srch_options");if("post"===e||"page"===e){var t=this.$element.find(".elementor-search-form__container");if(!t.length)return;var o='<input type="hidden" name="post_type" value="'+e+'" />';t.prepend(o)}}}),"button.default":elementorModules.frontend.handlers.Base.extend({onInit:function(){elementorModules.frontend.handlers.Base.prototype.onInit.apply(this,arguments),this.initButterButton()},isButterButton:function(){return this.$element.hasClass("ob-is-butterbutton")},onElementChange:function(e){"_ob_butterbutton_use_it"===e&&this.routeButterButton()},initButterButton:function(){this.isEdit&&"yes"===this.getElementSettings("_ob_butterbutton_use_it")&&this.$element.addClass("ob-is-butterbutton")},routeButterButton:function(){this.isButterButton()||"yes"!==this.getElementSettings("_ob_butterbutton_use_it")?this.$element.removeClass("ob-is-butterbutton"):this.$element.addClass("ob-is-butterbutton")}})};e.each(s,(function(e,t){elementorFrontend.hooks.addAction("frontend/element_ready/"+e,(function(e){elementorFrontend.elementsHandler.addHandler(t,{$element:e})}))}))}));var n=function(t,o){var n=e(".elementor-element-"+t+" .swiper-container").first(),r=new Swiper(n,{allowTouchMove:"yes"===o.allowTouchMove,autoHeight:"yes"===o.autoheight,effect:o.effect,loop:o.loop,direction:"fade"===o.effect?"horizontal":o.direction,parallax:"yes"===o.parallax,speed:o.speed,navigation:{nextEl:".elementor-element-"+t+" .swiper-button-next",prevEl:".elementor-element-"+t+" .swiper-button-prev"},pagination:{el:".elementor-element-"+t+" .swiper-pagination",type:o.pagination_type,clickable:!0},autoplay:o.autoplay,watchOverflow:!0,hashNavigation:{watchState:!0,replaceState:!0}});n.find(".glider-control").on("click",(function(t){t.preventDefault(),void 0!==e(this).data("gotoslide")&&r.slideTo(parseInt(e(this).data("gotoslide"))-1)}))}}(jQuery,window);
|
assets/js/ooohboi-steroids.js
CHANGED
@@ -548,8 +548,10 @@
|
|
548 |
} );
|
549 |
|
550 |
var makeSwiper = function( elem_id, settings ) {
|
|
|
|
|
551 |
|
552 |
-
var me_the_swiper = new Swiper(
|
553 |
allowTouchMove: ( 'yes' === settings.allowTouchMove ? true : false ),
|
554 |
autoHeight: ( 'yes' === settings.autoheight ? true : false ),
|
555 |
effect: settings.effect,
|
@@ -567,7 +569,18 @@
|
|
567 |
clickable: true,
|
568 |
},
|
569 |
autoplay: settings.autoplay,
|
570 |
-
watchOverflow : true, /* gotta force it down */
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
571 |
} );
|
572 |
|
573 |
}
|
548 |
} );
|
549 |
|
550 |
var makeSwiper = function( elem_id, settings ) {
|
551 |
+
|
552 |
+
var the_s = $( '.elementor-element-' + elem_id + ' .swiper-container' ).first();
|
553 |
|
554 |
+
var me_the_swiper = new Swiper( the_s, {
|
555 |
allowTouchMove: ( 'yes' === settings.allowTouchMove ? true : false ),
|
556 |
autoHeight: ( 'yes' === settings.autoheight ? true : false ),
|
557 |
effect: settings.effect,
|
569 |
clickable: true,
|
570 |
},
|
571 |
autoplay: settings.autoplay,
|
572 |
+
watchOverflow : true, /* gotta force it down */
|
573 |
+
hashNavigation: {
|
574 |
+
watchState: true,
|
575 |
+
replaceState: true,
|
576 |
+
},
|
577 |
+
} );
|
578 |
+
|
579 |
+
the_s.find( '.glider-control' ).on( 'click', function( e ) {
|
580 |
+
e.preventDefault();
|
581 |
+
if( typeof $( this ).data( 'gotoslide' ) !== 'undefined' ) {
|
582 |
+
me_the_swiper.slideTo( parseInt( $( this ).data( 'gotoslide' ) ) - 1 );
|
583 |
+
}
|
584 |
} );
|
585 |
|
586 |
}
|
controls/ooohboi-breaking-bad.php
CHANGED
@@ -134,16 +134,6 @@ class OoohBoi_Breaking_Bad {
|
|
134 |
]
|
135 |
);
|
136 |
|
137 |
-
// ------------------------------------------------------------------------- CONTROL: Sponsor
|
138 |
-
$element->add_control(
|
139 |
-
'_ob_shadough_sponsorship',
|
140 |
-
[
|
141 |
-
'type' => Controls_Manager::RAW_HTML,
|
142 |
-
'raw' => OoohBoi_Steroids::ooohboi_commercializer(),
|
143 |
-
'prefix_class' => 'ob-steroids-sponsor-',
|
144 |
-
]
|
145 |
-
);
|
146 |
-
|
147 |
}
|
148 |
|
149 |
public static function ooohboi_handle_columns( $element, $args ) {
|
@@ -233,15 +223,6 @@ href="https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Flexible_Box_Layout/O
|
|
233 |
],
|
234 |
]
|
235 |
);
|
236 |
-
// ------------------------------------------------------------------------- CONTROL: Sponsor
|
237 |
-
$element->add_control(
|
238 |
-
'_ob_sponsorship_breakingbad',
|
239 |
-
[
|
240 |
-
'type' => Controls_Manager::RAW_HTML,
|
241 |
-
'raw' => OoohBoi_Steroids::ooohboi_commercializer(),
|
242 |
-
'prefix_class' => 'ob-steroids-sponsor-',
|
243 |
-
]
|
244 |
-
);
|
245 |
|
246 |
}
|
247 |
|
134 |
]
|
135 |
);
|
136 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
137 |
}
|
138 |
|
139 |
public static function ooohboi_handle_columns( $element, $args ) {
|
223 |
],
|
224 |
]
|
225 |
);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
226 |
|
227 |
}
|
228 |
|
controls/ooohboi-butter-button.php
CHANGED
@@ -398,16 +398,6 @@ final class OoohBoi_Butter_Button {
|
|
398 |
|
399 |
$element->end_controls_tabs(); // Regular & Hover tabs end
|
400 |
|
401 |
-
// ------------------------------------------------------------------------- CONTROL: Sponsor
|
402 |
-
$element->add_control(
|
403 |
-
'_ob_sponsorship_butterbutton',
|
404 |
-
[
|
405 |
-
'type' => Controls_Manager::RAW_HTML,
|
406 |
-
'raw' => OoohBoi_Steroids::ooohboi_commercializer(),
|
407 |
-
'prefix_class' => 'ob-steroids-sponsor-',
|
408 |
-
]
|
409 |
-
);
|
410 |
-
|
411 |
$element->end_controls_section(); // END SECTION / PANEL
|
412 |
|
413 |
}
|
398 |
|
399 |
$element->end_controls_tabs(); // Regular & Hover tabs end
|
400 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
401 |
$element->end_controls_section(); // END SECTION / PANEL
|
402 |
|
403 |
}
|
controls/ooohboi-glider.php
CHANGED
@@ -581,16 +581,6 @@ final class OoohBoi_Glider {
|
|
581 |
'hide_in_inner' => true,
|
582 |
]
|
583 |
);
|
584 |
-
|
585 |
-
// ------------------------------------------------------------------------- CONTROL: Sponsor
|
586 |
-
$element->add_control(
|
587 |
-
'_ob_sponsorship_glider',
|
588 |
-
[
|
589 |
-
'type' => Controls_Manager::RAW_HTML,
|
590 |
-
'raw' => OoohBoi_Steroids::ooohboi_commercializer(),
|
591 |
-
'prefix_class' => 'ob-steroids-sponsor-',
|
592 |
-
]
|
593 |
-
);
|
594 |
|
595 |
$element->end_controls_section();
|
596 |
|
581 |
'hide_in_inner' => true,
|
582 |
]
|
583 |
);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
584 |
|
585 |
$element->end_controls_section();
|
586 |
|
controls/ooohboi-harakiri.php
CHANGED
@@ -185,16 +185,6 @@ final class OoohBoi_Harakiri {
|
|
185 |
]
|
186 |
);
|
187 |
|
188 |
-
// ------------------------------------------------------------------------- CONTROL: Sponsor
|
189 |
-
$element->add_control(
|
190 |
-
'_ob_sponsorship_overlaiz',
|
191 |
-
[
|
192 |
-
'type' => Controls_Manager::RAW_HTML,
|
193 |
-
'raw' => OoohBoi_Steroids::ooohboi_commercializer(),
|
194 |
-
'prefix_class' => 'ob-steroids-sponsor-',
|
195 |
-
]
|
196 |
-
);
|
197 |
-
|
198 |
}
|
199 |
|
200 |
}
|
185 |
]
|
186 |
);
|
187 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
188 |
}
|
189 |
|
190 |
}
|
controls/ooohboi-overlaiz.php
CHANGED
@@ -411,17 +411,37 @@ final class OoohBoi_Overlaiz {
|
|
411 |
],
|
412 |
]
|
413 |
);
|
414 |
-
|
415 |
-
// --------------------------------------------------------------------------------------------- CONTROL
|
|
|
416 |
$element->add_control(
|
417 |
-
'
|
418 |
[
|
419 |
-
'label' => __( '
|
420 |
-
'type' => Controls_Manager::
|
421 |
-
'
|
422 |
-
'
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
423 |
'selectors' => [
|
424 |
-
$selector => '
|
425 |
],
|
426 |
'condition' => [
|
427 |
'_ob_overlaiz_use_it' => 'yes',
|
@@ -430,15 +450,22 @@ final class OoohBoi_Overlaiz {
|
|
430 |
]
|
431 |
);
|
432 |
|
433 |
-
//
|
|
|
|
|
434 |
$element->add_control(
|
435 |
-
'
|
436 |
[
|
437 |
-
'
|
438 |
-
'
|
439 |
-
'
|
|
|
|
|
|
|
|
|
440 |
'condition' => [
|
441 |
'_ob_overlaiz_use_it' => 'yes',
|
|
|
442 |
],
|
443 |
]
|
444 |
);
|
411 |
],
|
412 |
]
|
413 |
);
|
414 |
+
|
415 |
+
// --------------------------------------------------------------------------------------------- CONTROL Clip path
|
416 |
+
|
417 |
$element->add_control(
|
418 |
+
'_ob_overlaiz_clip_path_popover',
|
419 |
[
|
420 |
+
'label' => __( 'Clip path', 'ooohboi-steroids' ),
|
421 |
+
'type' => Controls_Manager::POPOVER_TOGGLE,
|
422 |
+
'return_value' => 'yes',
|
423 |
+
'condition' => [
|
424 |
+
'_ob_overlaiz_use_it' => 'yes',
|
425 |
+
'background_overlay_background' => [ 'classic', 'gradient' ],
|
426 |
+
],
|
427 |
+
]
|
428 |
+
);
|
429 |
+
|
430 |
+
$element->start_popover();
|
431 |
+
|
432 |
+
$element->add_control(
|
433 |
+
'_ob_overlaiz_clip_path',
|
434 |
+
[
|
435 |
+
'description' => sprintf(
|
436 |
+
__( 'Enter the full clip-path property! See the copy-paste examples at %sClippy%s', 'ooohboi-steroids' ),
|
437 |
+
'<a href="https://bennettfeely.com/clippy/" target="_blank">',
|
438 |
+
'</a>'
|
439 |
+
),
|
440 |
+
'default' => '',
|
441 |
+
'type' => Controls_Manager::TEXTAREA,
|
442 |
+
'rows' => 3,
|
443 |
'selectors' => [
|
444 |
+
$selector => '{{VALUE}}',
|
445 |
],
|
446 |
'condition' => [
|
447 |
'_ob_overlaiz_use_it' => 'yes',
|
450 |
]
|
451 |
);
|
452 |
|
453 |
+
$element->end_popover(); // popover Clip path end
|
454 |
+
|
455 |
+
// --------------------------------------------------------------------------------------------- CONTROL Z-INDeX
|
456 |
$element->add_control(
|
457 |
+
'_ob_overlaiz_z_index',
|
458 |
[
|
459 |
+
'label' => __( 'Z-Index', 'ooohboi-steroids' ),
|
460 |
+
'type' => Controls_Manager::NUMBER,
|
461 |
+
'separator' => 'before',
|
462 |
+
'min' => -9999,
|
463 |
+
'selectors' => [
|
464 |
+
$selector => 'z-index: {{VALUE}};',
|
465 |
+
],
|
466 |
'condition' => [
|
467 |
'_ob_overlaiz_use_it' => 'yes',
|
468 |
+
'background_overlay_background' => [ 'classic', 'gradient' ],
|
469 |
],
|
470 |
]
|
471 |
);
|
controls/ooohboi-overlay-underlay.php
CHANGED
@@ -1187,16 +1187,6 @@ class OoohBoi_Overlay_Underlay {
|
|
1187 |
|
1188 |
$element->end_controls_tabs(); // Underlay and Overlay tabs end
|
1189 |
|
1190 |
-
// ------------------------------------------------------------------------- CONTROL: Sponsor
|
1191 |
-
$element->add_control(
|
1192 |
-
'_ob_sponsorship_poopart',
|
1193 |
-
[
|
1194 |
-
'type' => Controls_Manager::RAW_HTML,
|
1195 |
-
'raw' => OoohBoi_Steroids::ooohboi_commercializer(),
|
1196 |
-
'prefix_class' => 'ob-steroids-sponsor-',
|
1197 |
-
]
|
1198 |
-
);
|
1199 |
-
|
1200 |
$element->end_controls_section(); // END SECTION / PANEL
|
1201 |
|
1202 |
}
|
1187 |
|
1188 |
$element->end_controls_tabs(); // Underlay and Overlay tabs end
|
1189 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1190 |
$element->end_controls_section(); // END SECTION / PANEL
|
1191 |
|
1192 |
}
|
controls/ooohboi-paginini.php
CHANGED
@@ -230,16 +230,6 @@ final class OoohBoi_Paginini {
|
|
230 |
]
|
231 |
);
|
232 |
|
233 |
-
// ------------------------------------------------------------------------- CONTROL: Sponsor
|
234 |
-
$element->add_control(
|
235 |
-
'_ob_sponsorship_paginini',
|
236 |
-
[
|
237 |
-
'type' => Controls_Manager::RAW_HTML,
|
238 |
-
'raw' => OoohBoi_Steroids::ooohboi_commercializer(),
|
239 |
-
'prefix_class' => 'ob-steroids-sponsor-',
|
240 |
-
]
|
241 |
-
);
|
242 |
-
|
243 |
}
|
244 |
|
245 |
}
|
230 |
]
|
231 |
);
|
232 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
233 |
}
|
234 |
|
235 |
}
|
controls/ooohboi-perspektive.php
CHANGED
@@ -240,16 +240,6 @@ class OoohBoi_Perspektive {
|
|
240 |
]
|
241 |
);
|
242 |
|
243 |
-
// ------------------------------------------------------------------------- CONTROL: Sponsor
|
244 |
-
$element->add_control(
|
245 |
-
'_ob_sponsorship_perspektive',
|
246 |
-
[
|
247 |
-
'type' => Controls_Manager::RAW_HTML,
|
248 |
-
'raw' => OoohBoi_Steroids::ooohboi_commercializer(),
|
249 |
-
'prefix_class' => 'ob-steroids-sponsor-',
|
250 |
-
]
|
251 |
-
);
|
252 |
-
|
253 |
}
|
254 |
|
255 |
}
|
240 |
]
|
241 |
);
|
242 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
243 |
}
|
244 |
|
245 |
}
|
controls/ooohboi-photogiraffe.php
CHANGED
@@ -55,16 +55,6 @@ final class OoohBoi_PhotoGiraffe {
|
|
55 |
]
|
56 |
);
|
57 |
|
58 |
-
// ------------------------------------------------------------------------- CONTROL: Sponsor
|
59 |
-
$element->add_control(
|
60 |
-
'_ob_sponsorship_photogiraffe',
|
61 |
-
[
|
62 |
-
'type' => Controls_Manager::RAW_HTML,
|
63 |
-
'raw' => OoohBoi_Steroids::ooohboi_commercializer(),
|
64 |
-
'prefix_class' => 'ob-steroids-sponsor-',
|
65 |
-
]
|
66 |
-
);
|
67 |
-
|
68 |
}
|
69 |
|
70 |
}
|
55 |
]
|
56 |
);
|
57 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
58 |
}
|
59 |
|
60 |
}
|
controls/ooohboi-searchcop.php
CHANGED
@@ -54,16 +54,6 @@ final class OoohBoi_SearchCop {
|
|
54 |
]
|
55 |
);
|
56 |
|
57 |
-
// ------------------------------------------------------------------------- CONTROL: Sponsor
|
58 |
-
$element->add_control(
|
59 |
-
'_ob_sponsorship_searchcop',
|
60 |
-
[
|
61 |
-
'type' => Controls_Manager::RAW_HTML,
|
62 |
-
'raw' => OoohBoi_Steroids::ooohboi_commercializer(),
|
63 |
-
'prefix_class' => 'ob-steroids-sponsor-',
|
64 |
-
]
|
65 |
-
);
|
66 |
-
|
67 |
}
|
68 |
|
69 |
}
|
54 |
]
|
55 |
);
|
56 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
57 |
}
|
58 |
|
59 |
}
|
controls/ooohboi-shadough.php
CHANGED
@@ -161,16 +161,6 @@ final class OoohBoi_Shadough {
|
|
161 |
],
|
162 |
]
|
163 |
);
|
164 |
-
|
165 |
-
// ------------------------------------------------------------------------- CONTROL: Sponsor
|
166 |
-
$element->add_control(
|
167 |
-
'_ob_sponsorship_shadough',
|
168 |
-
[
|
169 |
-
'type' => Controls_Manager::RAW_HTML,
|
170 |
-
'raw' => OoohBoi_Steroids::ooohboi_commercializer(),
|
171 |
-
'prefix_class' => 'ob-steroids-sponsor-',
|
172 |
-
]
|
173 |
-
);
|
174 |
|
175 |
$element->end_controls_section(); // END SECTION / PANEL
|
176 |
|
161 |
],
|
162 |
]
|
163 |
);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
164 |
|
165 |
$element->end_controls_section(); // END SECTION / PANEL
|
166 |
|
controls/ooohboi-teleporter.php
CHANGED
@@ -376,16 +376,6 @@ final class OoohBoi_Teleporter {
|
|
376 |
]
|
377 |
);
|
378 |
|
379 |
-
// ------------------------------------------------------------------------- CONTROL: Sponsor
|
380 |
-
$element->add_control(
|
381 |
-
'_ob_sponsorship_teleporter',
|
382 |
-
[
|
383 |
-
'type' => Controls_Manager::RAW_HTML,
|
384 |
-
'raw' => OoohBoi_Steroids::ooohboi_commercializer(),
|
385 |
-
'prefix_class' => 'ob-steroids-sponsor-',
|
386 |
-
]
|
387 |
-
);
|
388 |
-
|
389 |
}
|
390 |
|
391 |
}
|
376 |
]
|
377 |
);
|
378 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
379 |
}
|
380 |
|
381 |
}
|
controls/ooohboi-videomasq.php
CHANGED
@@ -187,19 +187,6 @@ final class OoohBoi_Videomasq {
|
|
187 |
]
|
188 |
);
|
189 |
|
190 |
-
// ------------------------------------------------------------------------- CONTROL: Sponsor
|
191 |
-
$element->add_control(
|
192 |
-
'_ob_sponsorship_videomasq',
|
193 |
-
[
|
194 |
-
'type' => Controls_Manager::RAW_HTML,
|
195 |
-
'raw' => OoohBoi_Steroids::ooohboi_commercializer(),
|
196 |
-
'prefix_class' => 'ob-steroids-sponsor-',
|
197 |
-
'condition' => [
|
198 |
-
'background_background' => [ 'video' ],
|
199 |
-
],
|
200 |
-
]
|
201 |
-
);
|
202 |
-
|
203 |
}
|
204 |
|
205 |
}
|
187 |
]
|
188 |
);
|
189 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
190 |
}
|
191 |
|
192 |
}
|
inc/RationalOptionPages.php
ADDED
@@ -0,0 +1,868 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
/**
|
4 |
+
* RationalOptionPages class
|
5 |
+
*
|
6 |
+
* @category WordPress Development
|
7 |
+
* @package RationalOptionPages
|
8 |
+
* @author Jeremy Hixon <jeremy@jeremyhixon.com>
|
9 |
+
* @copyright Copyright (c) 2016
|
10 |
+
* @link http://jeremyhixon.com
|
11 |
+
* @version 1.0.0
|
12 |
+
*/
|
13 |
+
class RationalOptionPages {
|
14 |
+
/* ==========================================================================
|
15 |
+
Vars
|
16 |
+
========================================================================== */
|
17 |
+
protected $attributes = array(
|
18 |
+
'input' => array(
|
19 |
+
'autocomplete' => false,
|
20 |
+
'autofocus' => false,
|
21 |
+
'disabled' => false,
|
22 |
+
'list' => false,
|
23 |
+
'max' => false,
|
24 |
+
'maxlength' => false,
|
25 |
+
'min' => false,
|
26 |
+
'pattern' => false,
|
27 |
+
'readonly' => false,
|
28 |
+
'required' => false,
|
29 |
+
'size' => false,
|
30 |
+
'step' => false,
|
31 |
+
),
|
32 |
+
'select' => array(
|
33 |
+
'multiple' => false,
|
34 |
+
'size' => 4,
|
35 |
+
),
|
36 |
+
'textarea' => array(
|
37 |
+
'cols' => 20,
|
38 |
+
'rows' => 2,
|
39 |
+
'wrap' => 'soft',
|
40 |
+
),
|
41 |
+
);
|
42 |
+
protected $defaults = array(
|
43 |
+
'add_menu_page' => array(
|
44 |
+
'page_title' => 'Option Page',
|
45 |
+
'menu_title' => 'Option Page',
|
46 |
+
'capability' => 'manage_options',
|
47 |
+
'menu_slug' => 'option_page',
|
48 |
+
'callback' => false,
|
49 |
+
'icon_url' => false,
|
50 |
+
'position' => null,
|
51 |
+
),
|
52 |
+
'add_settings_field' => array(
|
53 |
+
'id' => 'settings_field',
|
54 |
+
'title' => 'Settings Field',
|
55 |
+
'callback' => false,
|
56 |
+
'page' => 'option_page',
|
57 |
+
'section' => 'settings_section',
|
58 |
+
'args' => false,
|
59 |
+
),
|
60 |
+
'add_settings_section' => array(
|
61 |
+
'id' => 'settings_section',
|
62 |
+
'title' => 'Settings Section',
|
63 |
+
'callback' => false,
|
64 |
+
'page' => 'option_page',
|
65 |
+
),
|
66 |
+
'add_submenu_page' => array(
|
67 |
+
'parent_slug' => 'option_page',
|
68 |
+
'page_title' => 'Sub Option Page',
|
69 |
+
'menu_title' => 'Sub Option Page',
|
70 |
+
'capability' => 'manage_options',
|
71 |
+
'menu_slug' => 'sub_option_page',
|
72 |
+
'callback' => false,
|
73 |
+
),
|
74 |
+
);
|
75 |
+
protected $errors;
|
76 |
+
protected $fields = array(
|
77 |
+
'checkbox' => array(
|
78 |
+
'checked' => false,
|
79 |
+
'value' => 'on',
|
80 |
+
),
|
81 |
+
'text' => array(
|
82 |
+
'class' => 'regular-text',
|
83 |
+
'placeholder' => '',
|
84 |
+
'value' => false,
|
85 |
+
),
|
86 |
+
'textarea' => array(
|
87 |
+
'class' => 'large-text',
|
88 |
+
'placeholder' => '',
|
89 |
+
'rows' => 10,
|
90 |
+
'value' => false,
|
91 |
+
),
|
92 |
+
'wp_editor' => array(
|
93 |
+
'wpautop' => true,
|
94 |
+
'media_buttons' => true,
|
95 |
+
'textarea_rows' => 'default',
|
96 |
+
'tabindex' => false,
|
97 |
+
'editor_css' => false,
|
98 |
+
'editor_class' => '',
|
99 |
+
'editor_height' => false,
|
100 |
+
'teeny' => false,
|
101 |
+
'dfw' => false,
|
102 |
+
'tinymce' => true,
|
103 |
+
'quicktags' => true,
|
104 |
+
'drag_drop_upload' => false,
|
105 |
+
),
|
106 |
+
);
|
107 |
+
protected $media_script = false;
|
108 |
+
protected $notices;
|
109 |
+
protected $options;
|
110 |
+
protected $pages = array();
|
111 |
+
protected $subpages = array();
|
112 |
+
protected $points;
|
113 |
+
|
114 |
+
/* ==========================================================================
|
115 |
+
Magic methods
|
116 |
+
========================================================================== */
|
117 |
+
/**
|
118 |
+
* Catches unknown method calls
|
119 |
+
*
|
120 |
+
* @param string $method The method being requested
|
121 |
+
* @param array $arguments Array of arguments passed to the method
|
122 |
+
*/
|
123 |
+
public function __call( $method, $arguments ) {
|
124 |
+
$request = explode( '|', $method );
|
125 |
+
$source = $request[0];
|
126 |
+
$page_key = !empty( $request[1] ) ? $request[1] : false;
|
127 |
+
$section_key = !empty( $request[2] ) ? $request[2] : false;
|
128 |
+
$field_key = !empty( $request[3] ) ? $request[3] : false;
|
129 |
+
|
130 |
+
switch ( $source ) {
|
131 |
+
case 'add_menu_page':
|
132 |
+
case 'add_submenu_page':
|
133 |
+
$this->build_menu_page( $page_key );
|
134 |
+
break;
|
135 |
+
case 'add_settings_section':
|
136 |
+
$this->build_settings_section( $page_key, $section_key );
|
137 |
+
break;
|
138 |
+
case 'add_settings_field':
|
139 |
+
$this->build_settings_field( $page_key, $section_key, $field_key );
|
140 |
+
break;
|
141 |
+
case 'register_setting':
|
142 |
+
$input = $this->sanitize_setting( $page_key, $arguments[0] );
|
143 |
+
return $input;
|
144 |
+
break;
|
145 |
+
default:
|
146 |
+
$this->submit_notice( $method );
|
147 |
+
}
|
148 |
+
}
|
149 |
+
|
150 |
+
/**
|
151 |
+
* Class construct method. Configures class and hooks into WordPress.
|
152 |
+
*
|
153 |
+
* @param array $pages Array of option pages
|
154 |
+
*/
|
155 |
+
public function __construct( $pages = array() ) {
|
156 |
+
foreach ( $pages as $page_key => $page_params ) {
|
157 |
+
$this->pages[ $page_key ] = $this->validate_page( $page_key, $page_params );
|
158 |
+
}
|
159 |
+
$this->pages = array_merge( $this->pages, $this->subpages );
|
160 |
+
|
161 |
+
add_action( 'admin_enqueue_scripts', array( $this, 'admin_enqueue_scripts' ) );
|
162 |
+
add_action( 'admin_head', array( $this, 'admin_head' ) );
|
163 |
+
add_action( 'admin_init', array( $this, 'admin_init' ) );
|
164 |
+
add_action( 'admin_menu', array( $this, 'admin_menu' ) );
|
165 |
+
add_action( 'admin_notices', array( $this, 'admin_notices' ) );
|
166 |
+
}
|
167 |
+
|
168 |
+
/* ==========================================================================
|
169 |
+
WordPress hooks
|
170 |
+
========================================================================== */
|
171 |
+
/**
|
172 |
+
* Action: admin_enqueue_scripts
|
173 |
+
* Conditionally queue's up jQuery and the media uploader script
|
174 |
+
*/
|
175 |
+
public function admin_enqueue_scripts() {
|
176 |
+
if ( $this->media_script ) {
|
177 |
+
wp_enqueue_script( 'jquery' );
|
178 |
+
wp_enqueue_media();
|
179 |
+
}
|
180 |
+
}
|
181 |
+
|
182 |
+
/**
|
183 |
+
* Action: admin_head
|
184 |
+
* Conditionally adds the script to manage media uploads
|
185 |
+
*/
|
186 |
+
public function admin_head() {
|
187 |
+
if ( $this->media_script ) {
|
188 |
+
?> <script>
|
189 |
+
jQuery.noConflict();
|
190 |
+
(function($) {
|
191 |
+
$(function() {
|
192 |
+
var mediaUploader,
|
193 |
+
rationalMediaButton = $( '.rational-media-upload' ),
|
194 |
+
rationalMediaAttachment;
|
195 |
+
|
196 |
+
rationalMediaButton.click( function( e ) {
|
197 |
+
e.preventDefault();
|
198 |
+
var rationalMediaDestination = $( this ).prev( 'input' );
|
199 |
+
|
200 |
+
if ( mediaUploader ) {
|
201 |
+
mediaUploader.open();
|
202 |
+
return;
|
203 |
+
}
|
204 |
+
|
205 |
+
mediaUploader = wp.media.frames.file_frame = wp.media( {
|
206 |
+
title: 'Choose File',
|
207 |
+
button: {
|
208 |
+
text: 'Choose File',
|
209 |
+
},
|
210 |
+
multiple: false,
|
211 |
+
} );
|
212 |
+
|
213 |
+
mediaUploader.on( 'select', function() {
|
214 |
+
rationalMediaAttachment = mediaUploader.state().get('selection').first().toJSON();
|
215 |
+
rationalMediaDestination.val( rationalMediaAttachment.url );
|
216 |
+
} );
|
217 |
+
|
218 |
+
mediaUploader.open();
|
219 |
+
} );
|
220 |
+
});
|
221 |
+
})(jQuery);
|
222 |
+
</script>
|
223 |
+
<?php }
|
224 |
+
}
|
225 |
+
|
226 |
+
/**
|
227 |
+
* Action: admin_init
|
228 |
+
* Registers settings, adds sections and fields
|
229 |
+
*/
|
230 |
+
public function admin_init() {
|
231 |
+
foreach ( $this->pages as $page_key => $page_params ) {
|
232 |
+
// Finalize sanitize
|
233 |
+
if ( empty( $page_params['custom'] ) && !is_array( $page_params['sanitize'] ) ) {
|
234 |
+
$page_params['sanitize'] = array( $this, $page_params['sanitize'] );
|
235 |
+
}
|
236 |
+
|
237 |
+
register_setting(
|
238 |
+
$page_key,
|
239 |
+
$page_key,
|
240 |
+
$page_params['sanitize']
|
241 |
+
);
|
242 |
+
|
243 |
+
if ( !empty( $page_params['sections'] ) ) {
|
244 |
+
foreach ( $page_params['sections'] as $section_key => $section_params ) {
|
245 |
+
// Sort and trim the array for the function
|
246 |
+
$sort_order = array_keys( $this->defaults['add_settings_section'] );
|
247 |
+
$params = $this->sort_array( $section_params, $sort_order );
|
248 |
+
$params = array_slice( $params, 0, count( $this->defaults['add_settings_section'] ) );
|
249 |
+
|
250 |
+
// Finalize callback
|
251 |
+
if ( empty( $params['custom'] ) && !is_array( $params['callback'] ) ) {
|
252 |
+
$params['callback'] = array( $this, $params['callback'] );
|
253 |
+
}
|
254 |
+
|
255 |
+
call_user_func_array( 'add_settings_section', $params );
|
256 |
+
|
257 |
+
if ( !empty( $section_params['fields'] ) ) {
|
258 |
+
foreach ( $section_params['fields'] as $field_key => $field_params ) {
|
259 |
+
// Check for "media" type for adding script
|
260 |
+
if ( !$this->media_script && $field_params['type'] === 'media' ) {
|
261 |
+
$this->media_script = true;
|
262 |
+
}
|
263 |
+
|
264 |
+
// Sort and trim the array for the function
|
265 |
+
$sort_order = array_keys( $this->defaults['add_settings_field'] );
|
266 |
+
$params = $this->sort_array( $field_params, $sort_order );
|
267 |
+
$params = array_slice( $params, 0, count( $this->defaults['add_settings_field'] ) );
|
268 |
+
|
269 |
+
// Add label wrapper on title
|
270 |
+
if (
|
271 |
+
!in_array( $field_params['type'], array( 'radio' ) ) &&
|
272 |
+
( empty( $field_params['no_label'] ) || $field_params['no_label'] === false )
|
273 |
+
) {
|
274 |
+
$params['title'] = "<label for='{$params['id']}'>{$params['title']}</label>";
|
275 |
+
}
|
276 |
+
|
277 |
+
// Finalize callback
|
278 |
+
if ( empty( $params['custom'] ) && !is_array( $params['callback'] ) ) {
|
279 |
+
$params['callback'] = array( $this, $params['callback'] );
|
280 |
+
}
|
281 |
+
|
282 |
+
call_user_func_array( 'add_settings_field', $params );
|
283 |
+
}
|
284 |
+
}
|
285 |
+
}
|
286 |
+
}
|
287 |
+
}
|
288 |
+
}
|
289 |
+
|
290 |
+
/**
|
291 |
+
* Action: admin_menu. Adding the option pages to the admin menu.
|
292 |
+
*/
|
293 |
+
public function admin_menu() {
|
294 |
+
$all_pages = array_merge( $this->pages, $this->subpages );
|
295 |
+
|
296 |
+
foreach ( $all_pages as $page ) {
|
297 |
+
// Sort and trim the array for the function
|
298 |
+
$sort_order = array_keys( $this->defaults[ $page['function'] ] );
|
299 |
+
$params = $this->sort_array( $page, $sort_order );
|
300 |
+
$params = array_slice( $params, 0, count( $this->defaults[ $page['function'] ] ) );
|
301 |
+
|
302 |
+
// Finalize callback
|
303 |
+
$params['callback'] = array( $this, $params['callback'] );
|
304 |
+
|
305 |
+
call_user_func_array( $page['function'], $params );
|
306 |
+
}
|
307 |
+
}
|
308 |
+
|
309 |
+
/**
|
310 |
+
* Action: admin_notices. Spitting out notices when needed.
|
311 |
+
*/
|
312 |
+
public function admin_notices() {
|
313 |
+
// notice-error, notice-warning, notice-success, or notice-info.
|
314 |
+
if ( !empty( $this->errors ) ) {
|
315 |
+
foreach ( $this->errors as $error ) {
|
316 |
+
echo $error;
|
317 |
+
}
|
318 |
+
}
|
319 |
+
if ( !empty( $this->notices ) ) {
|
320 |
+
foreach ( $this->notices as $notice ) {
|
321 |
+
echo $notice;
|
322 |
+
}
|
323 |
+
}
|
324 |
+
|
325 |
+
// update point in array for future reference
|
326 |
+
$this->points['admin_notices'] = true;
|
327 |
+
}
|
328 |
+
|
329 |
+
/* ==========================================================================
|
330 |
+
Helpers
|
331 |
+
========================================================================== */
|
332 |
+
public function add_page( $page_key, $page_params ) {
|
333 |
+
$this->pages[ $page_key ] = $this->validate_page( $page_key, $page_params );
|
334 |
+
}
|
335 |
+
|
336 |
+
/**
|
337 |
+
* Builds the menu page
|
338 |
+
*
|
339 |
+
* @param string $page_key The array key of the page needing built
|
340 |
+
*/
|
341 |
+
protected function build_menu_page( $page_key ) {
|
342 |
+
$page = $this->pages[ $page_key ];
|
343 |
+
$this->options = get_option( $page_key, array() );
|
344 |
+
?><div class="wrap ob-settings-page">
|
345 |
+
<h1><?php echo $GLOBALS['title']; ?></h1><?php
|
346 |
+
|
347 |
+
if ( !empty( $page['sections'] ) ) {
|
348 |
+
?><form action="options.php" method="post"><?php
|
349 |
+
settings_errors( $page_key );
|
350 |
+
settings_fields( $page_key );
|
351 |
+
do_settings_sections( $page['menu_slug'] );
|
352 |
+
if ( $this->has_fields( $page ) ) {
|
353 |
+
submit_button();
|
354 |
+
}
|
355 |
+
?></form><?php
|
356 |
+
}
|
357 |
+
?></div><?php
|
358 |
+
}
|
359 |
+
|
360 |
+
/**
|
361 |
+
* Builds the fields themselves
|
362 |
+
*
|
363 |
+
* @param string $page_key The array key of the page
|
364 |
+
* @param string $section_key The array key of the section
|
365 |
+
* @param string $field_key The array key of the field
|
366 |
+
*/
|
367 |
+
protected function build_settings_field( $page_key, $section_key, $field_key ) {
|
368 |
+
$page = $this->pages[ $page_key ];
|
369 |
+
$section = $page['sections'][ $section_key ];
|
370 |
+
$field = $section['fields'][ $field_key ];
|
371 |
+
|
372 |
+
if ( $field['type'] !== 'checkbox' ) {
|
373 |
+
$field['value'] = !empty( $this->options[ $field['id'] ] ) ? $this->options[ $field['id'] ] : $field['value'];
|
374 |
+
}
|
375 |
+
|
376 |
+
// Additional attributes
|
377 |
+
if ( !empty( $field['attributes'] ) ) {
|
378 |
+
$attributes = array();
|
379 |
+
foreach ( $field['attributes'] as $attribute => $value ) {
|
380 |
+
if ( !empty( $value ) ) {
|
381 |
+
$attributes[] = "{$attribute}='{$value}'";
|
382 |
+
}
|
383 |
+
}
|
384 |
+
}
|
385 |
+
|
386 |
+
// Sanitize field values, unless 'sanitize' was set to false for this field.
|
387 |
+
if ( ( !isset( $field['sanitize'] ) || $field['sanitize'] ) && $field['type'] !== 'wp_editor' ) {
|
388 |
+
$field['value'] = strip_tags($field['value']); // Removes HTML tags
|
389 |
+
$field['value'] = esc_attr($field['value']); // Escapes field for HTML attributes
|
390 |
+
}
|
391 |
+
|
392 |
+
switch ( $field['type'] ) {
|
393 |
+
case 'checkbox':
|
394 |
+
$checked = $field['checked'] ? 'checked' : '';
|
395 |
+
if ( isset( $this->options[ $field['id'] ] ) ) {
|
396 |
+
$checked = checked( $field['value'], $this->options[ $field['id'] ], false );
|
397 |
+
}
|
398 |
+
printf(
|
399 |
+
'<label><input %s %s id="%s" name="%s" title="%s" type="checkbox" value="%s"> %s</label>',
|
400 |
+
$checked, // checked
|
401 |
+
!empty( $field['class'] ) ? "class='{$field['class']}'" : '', // class
|
402 |
+
$field['id'], // id
|
403 |
+
"{$page_key}[{$field['id']}]", // name
|
404 |
+
$field['title_attr'], // title
|
405 |
+
$field['value'], // value
|
406 |
+
!empty( $field['text'] ) ? $field['text'] : '' // text
|
407 |
+
);
|
408 |
+
break;
|
409 |
+
case 'media':
|
410 |
+
$upload_button = sprintf(
|
411 |
+
'<input class="button rational-media-upload" type="button" value="Upload">'
|
412 |
+
);
|
413 |
+
printf(
|
414 |
+
'<input %s id="%s" name="%s" %s title="%s" type="text" value="%s" %s>%s%s',
|
415 |
+
!empty( $field['class'] ) ? "class='{$field['class']}'" : '', // class
|
416 |
+
$field['id'], // id
|
417 |
+
"{$page_key}[{$field['id']}]", // name
|
418 |
+
!empty( $field['placeholder'] ) ? "placeholder='{$field['placeholder']}'" : '', // placeholder
|
419 |
+
$field['title_attr'], // title
|
420 |
+
$field['value'], // value
|
421 |
+
!empty( $attributes ) ? implode( ' ', $attributes ) : '', // additional attributes
|
422 |
+
$upload_button, // upload button
|
423 |
+
!empty( $field['text'] ) ? "<p class='help'>{$field['text']}</p>" : '' // text
|
424 |
+
);
|
425 |
+
break;
|
426 |
+
case 'radio':
|
427 |
+
echo '<fieldset><legend class="screen-reader-text">' . $field['title'] . '</legend>';
|
428 |
+
$c = 0;
|
429 |
+
foreach ( $field['choices'] as $value => $label ) {
|
430 |
+
$checked = $value === $field['value'] ? 'checked' : '';
|
431 |
+
if ( isset( $this->options[ $field['id'] ] ) ) {
|
432 |
+
$checked = $value === $this->options[ $field['id'] ] ? 'checked' : '';
|
433 |
+
}
|
434 |
+
printf(
|
435 |
+
'<label><input %s %s id="%s" name="%s" type="radio" title="%s" value="%s"> %s</label>%s',
|
436 |
+
$checked, // checked
|
437 |
+
!empty( $field['class'] ) ? "class='{$field['class']}'" : '', // class
|
438 |
+
$field['id'], // id
|
439 |
+
"{$page_key}[{$field['id']}]", // name
|
440 |
+
$label, // title
|
441 |
+
$value, // value
|
442 |
+
$label, // label
|
443 |
+
$c < count( $field['choices'] ) - 1 ? '<br>' : '' // line-break
|
444 |
+
);
|
445 |
+
$c++;
|
446 |
+
}
|
447 |
+
echo '</fieldset>';
|
448 |
+
break;
|
449 |
+
case 'select':
|
450 |
+
if (!empty($field['attributes']) && isset($field['attributes']['multiple']) && $field['attributes']['multiple']) {
|
451 |
+
$field_tag_name = "{$page_key}[{$field['id']}][]";
|
452 |
+
$field_name = "{$field['id']}[]";
|
453 |
+
}
|
454 |
+
else {
|
455 |
+
$field_tag_name = "{$page_key}[{$field['id']}]";
|
456 |
+
$field_name = "{$field['id']}";
|
457 |
+
}
|
458 |
+
printf(
|
459 |
+
'<select %s %s id="%s" name="%s" title="%s">',
|
460 |
+
!empty( $field['class'] ) ? "class='{$field['class']}'" : '', // class
|
461 |
+
!empty( $attributes ) ? implode(' ', $attributes) : '',
|
462 |
+
$field['id'], // id
|
463 |
+
$field_tag_name, // name
|
464 |
+
$field['title_attr'] // title
|
465 |
+
);
|
466 |
+
foreach ( $field['choices'] as $value => $text ) {
|
467 |
+
$selected = $value === $field['value'] ? 'selected' : '';
|
468 |
+
if ( isset( $this->options[ $field['id'] ] ) ) {
|
469 |
+
if (!is_array($this->options[ $field['id'] ] ) ) {
|
470 |
+
$selected = $value === $this->options[ $field['id'] ] ? 'selected="selected"' : '';
|
471 |
+
}
|
472 |
+
else {
|
473 |
+
$selected = '';
|
474 |
+
foreach ($this->options[ $field['id'] ] as $option) {
|
475 |
+
if ($value === $option) {
|
476 |
+
$selected = 'selected="selected"';
|
477 |
+
continue;
|
478 |
+
}
|
479 |
+
}
|
480 |
+
}
|
481 |
+
}
|
482 |
+
printf(
|
483 |
+
'<option %s value="%s">%s</option>',
|
484 |
+
$selected, // selected
|
485 |
+
$value, // value
|
486 |
+
$text // text
|
487 |
+
);
|
488 |
+
}
|
489 |
+
echo '</select>';
|
490 |
+
break;
|
491 |
+
case 'textarea':
|
492 |
+
printf(
|
493 |
+
'<textarea %s id="%s" name="%s" %s %s title="%s">%s</textarea>%s',
|
494 |
+
!empty( $field['class'] ) ? "class='{$field['class']}'" : '', // class
|
495 |
+
$field['id'], // id
|
496 |
+
"{$page_key}[{$field['id']}]", // name
|
497 |
+
!empty( $field['placeholder'] ) ? "placeholder='{$field['placeholder']}'" : '', // placeholder
|
498 |
+
!empty( $field['rows'] ) ? "rows='{$field['rows']}'" : '', // rows
|
499 |
+
$field['title_attr'], // title
|
500 |
+
$field['value'], // value
|
501 |
+
!empty( $field['text'] ) ? "<p class='help'>{$field['text']}</p>" : '' // text
|
502 |
+
);
|
503 |
+
break;
|
504 |
+
case 'wp_editor':
|
505 |
+
$field['textarea_name'] = "{$page_key}[{$field['id']}]";
|
506 |
+
wp_editor( $field['value'], $field['id'], array(
|
507 |
+
'textarea_name' => $field['textarea_name'],
|
508 |
+
) );
|
509 |
+
echo !empty( $field['text'] ) ? "<p class='help'>{$field['text']}</p>" : '';
|
510 |
+
break;
|
511 |
+
default:
|
512 |
+
printf(
|
513 |
+
'<input %s id="%s" name="%s" %s title="%s" type="%s" value="%s" %s>%s',
|
514 |
+
!empty( $field['class'] ) ? "class='{$field['class']}'" : '', // class
|
515 |
+
$field['id'], // id
|
516 |
+
"{$page_key}[{$field['id']}]", // name
|
517 |
+
!empty( $field['placeholder'] ) ? "placeholder='{$field['placeholder']}'" : '', // placeholder
|
518 |
+
$field['title_attr'], // title
|
519 |
+
$field['type'], // type
|
520 |
+
$field['value'], // value
|
521 |
+
!empty( $attributes ) ? implode( ' ', $attributes ) : '', // additional attributes
|
522 |
+
!empty( $field['text'] ) ? "<p class='help'>{$field['text']}</p>" : '' // text
|
523 |
+
);
|
524 |
+
}
|
525 |
+
}
|
526 |
+
|
527 |
+
/**
|
528 |
+
* Builds the settings sections
|
529 |
+
*
|
530 |
+
* @param string $page_key The array key of the page
|
531 |
+
* @param type $section_key The array key of the section
|
532 |
+
*/
|
533 |
+
protected function build_settings_section( $page_key, $section_key ) {
|
534 |
+
$page = $this->pages[ $page_key ];
|
535 |
+
$section = $page['sections'][ $section_key ];
|
536 |
+
|
537 |
+
echo !empty( $section['text'] ) ? $section['text'] : '';
|
538 |
+
|
539 |
+
if ( !empty( $section['include'] ) ) {
|
540 |
+
include $section['include'];
|
541 |
+
}
|
542 |
+
}
|
543 |
+
|
544 |
+
/**
|
545 |
+
* Determines if the option page has fields or not
|
546 |
+
*
|
547 |
+
* @param array $page The page array
|
548 |
+
*
|
549 |
+
* @return boolean True if fields are found, false otherwise
|
550 |
+
*/
|
551 |
+
protected function has_fields( $page ) {
|
552 |
+
if ( !empty( $page['sections'] ) ) {
|
553 |
+
foreach ( $page['sections'] as $section ) {
|
554 |
+
if ( !empty( $section['fields'] ) ) {
|
555 |
+
return true;
|
556 |
+
}
|
557 |
+
}
|
558 |
+
}
|
559 |
+
return false;
|
560 |
+
}
|
561 |
+
|
562 |
+
/**
|
563 |
+
* Cleans up the option page submissions before submitting to the DB
|
564 |
+
*
|
565 |
+
* @param string $page_key The array key of the page
|
566 |
+
*
|
567 |
+
* @return array The sanitized post input
|
568 |
+
*/
|
569 |
+
protected function sanitize_setting( $page_key, $input ) {
|
570 |
+
$page = $this->pages[ $page_key ];
|
571 |
+
|
572 |
+
if ( !empty( $page['sections'] ) ) {
|
573 |
+
foreach ( $page['sections'] as $section ) {
|
574 |
+
if ( isset( $field['sanitize'] ) && !$field['sanitize'] ) {
|
575 |
+
continue;
|
576 |
+
}
|
577 |
+
if ( !empty( $section['fields'] ) ) {
|
578 |
+
foreach ( $section['fields'] as $field ) {
|
579 |
+
switch ( $field['type'] ) {
|
580 |
+
case 'checkbox':
|
581 |
+
if ( empty( $input[ $field['id'] ] ) ) {
|
582 |
+
$input[ $field['id'] ] = false;
|
583 |
+
}
|
584 |
+
break;
|
585 |
+
case 'wp_editor':
|
586 |
+
$input[ $field['id'] ] = wp_kses_post( $input[ $field['id'] ] );
|
587 |
+
break;
|
588 |
+
default:
|
589 |
+
// Sanitize by default; skip if this field's 'sanitize' setting is false.
|
590 |
+
$input[ $field['id'] ] = sanitize_text_field( $input[ $field['id'] ] );
|
591 |
+
}
|
592 |
+
}
|
593 |
+
}
|
594 |
+
}
|
595 |
+
}
|
596 |
+
|
597 |
+
return $input;
|
598 |
+
}
|
599 |
+
|
600 |
+
/**
|
601 |
+
* Converts human-readable strings into more machine-friendly formats
|
602 |
+
*
|
603 |
+
* @param string $text String to be formatted
|
604 |
+
* @param string $separator The character that fills in spaces
|
605 |
+
*
|
606 |
+
* @return string Formatted text
|
607 |
+
*/
|
608 |
+
protected function slugify( $text, $separator = '_' ) {
|
609 |
+
$text = preg_replace( '~[^\\pL\d]+~u', $separator, $text );
|
610 |
+
$text = trim( $text, $separator );
|
611 |
+
$text = iconv( 'utf-8', 'us-ascii//TRANSLIT', $text );
|
612 |
+
$text = strtolower( $text );
|
613 |
+
$text = preg_replace( '~[^-\w]+~', '', $text );
|
614 |
+
if ( empty( $text ) ) {
|
615 |
+
return 'n-a';
|
616 |
+
}
|
617 |
+
return $text;
|
618 |
+
}
|
619 |
+
|
620 |
+
/**
|
621 |
+
* Sorts one array using a second as a guide
|
622 |
+
*
|
623 |
+
* @param array $array Array to be sorted
|
624 |
+
* @param array $order_array Guide array
|
625 |
+
*
|
626 |
+
* @return array Sorted array
|
627 |
+
*/
|
628 |
+
protected function sort_array( $array, $order_array ) {
|
629 |
+
$ordered = array();
|
630 |
+
foreach ( $order_array as $key ) {
|
631 |
+
if ( array_key_exists( $key, $array ) ) {
|
632 |
+
$ordered[ $key ] = $array[ $key ];
|
633 |
+
unset( $array[ $key ] );
|
634 |
+
}
|
635 |
+
}
|
636 |
+
return $ordered + $array;
|
637 |
+
}
|
638 |
+
|
639 |
+
/**
|
640 |
+
* Conditionally outputs an error in WordPress admin
|
641 |
+
*
|
642 |
+
* @param string $error The error to be output
|
643 |
+
*/
|
644 |
+
public function submit_error( $error ) {
|
645 |
+
$error = sprintf(
|
646 |
+
'<div class="notice notice-error"><p>%s</p></div>',
|
647 |
+
is_array( $error ) || is_object( $error ) ? '<pre>' . htmlspecialchars( print_r( $error, true ) ) . '</pre>' : $error
|
648 |
+
);
|
649 |
+
if ( empty( $this->points['admin_notices'] ) ) {
|
650 |
+
$this->errors[] = $error;
|
651 |
+
} else {
|
652 |
+
echo $error;
|
653 |
+
}
|
654 |
+
}
|
655 |
+
|
656 |
+
/**
|
657 |
+
* Conditionally outputs a notice in WordPress admin
|
658 |
+
*
|
659 |
+
* @param string $notice The text to be output
|
660 |
+
*/
|
661 |
+
public function submit_notice( $notice ) {
|
662 |
+
$notice = sprintf(
|
663 |
+
'<div class="notice notice-info"><p>%s</p></div>',
|
664 |
+
is_array( $notice ) || is_object( $notice ) ? '<pre>' . htmlspecialchars( print_r( $notice, true ) ) . '</pre>' : $notice
|
665 |
+
);
|
666 |
+
if ( empty( $this->points['admin_notices'] ) ) {
|
667 |
+
$this->notices[] = $notice;
|
668 |
+
} else {
|
669 |
+
echo $notice;
|
670 |
+
}
|
671 |
+
}
|
672 |
+
|
673 |
+
/**
|
674 |
+
* Validates the field data submitted to the class
|
675 |
+
*
|
676 |
+
* @param array $field Field array
|
677 |
+
* @param string $page_key Array key of the associated page
|
678 |
+
* @param string $section_key Array key of the associated section
|
679 |
+
* @param string $field_key Array key of the field
|
680 |
+
* @param string $page ID of the associated page
|
681 |
+
* @param type $section ID of the associated section
|
682 |
+
*
|
683 |
+
* @return array The validated field array
|
684 |
+
*/
|
685 |
+
protected function validate_field( $field, $page_key, $section_key, $field_key, $page, $section ) {
|
686 |
+
// Label
|
687 |
+
if ( empty( $field['title'] ) ) {
|
688 |
+
$this->submit_error( 'Field parameter "title" is required' );
|
689 |
+
}
|
690 |
+
|
691 |
+
// ID
|
692 |
+
if ( empty( $field['id'] ) ) {
|
693 |
+
$field['id'] = $this->slugify( $field['title'] );
|
694 |
+
}
|
695 |
+
|
696 |
+
// Callback
|
697 |
+
$field['callback'] = empty( $field['callback'] ) ? "add_settings_field|{$page_key}|{$section_key}|{$field_key}" : $field['callback'];
|
698 |
+
|
699 |
+
// Page
|
700 |
+
$field['page'] = $page;
|
701 |
+
|
702 |
+
// Section
|
703 |
+
$field['section'] = $section;
|
704 |
+
|
705 |
+
// Type
|
706 |
+
$field['type'] = empty( $field['type'] ) ? 'text' : $field['type'];
|
707 |
+
|
708 |
+
// Title attribute
|
709 |
+
$field['title_attr'] = empty( $field['title_attr'] ) ? $field['title'] : $field['title_attr'];
|
710 |
+
|
711 |
+
// Choices
|
712 |
+
if ( empty( $field['choices'] ) && in_array( $field['type'], array( 'radio', 'select' ) ) ) {
|
713 |
+
$this->submit_error( 'Field parameter "choices" is required for the "radio" and "select" type' );
|
714 |
+
}
|
715 |
+
|
716 |
+
// Other attributes
|
717 |
+
if ( !empty( $field['attributes'] ) ) {
|
718 |
+
switch ( $field['type'] ) {
|
719 |
+
case 'select':
|
720 |
+
case 'textarea':
|
721 |
+
$field['attributes'] = wp_parse_args( $field['attributes'], $this->attributes[ $field['type'] ] );
|
722 |
+
break;
|
723 |
+
default:
|
724 |
+
$field['attributes'] = wp_parse_args( $field['attributes'], $this->attributes['input'] );
|
725 |
+
}
|
726 |
+
}
|
727 |
+
|
728 |
+
// Making sure we haven't missed anything
|
729 |
+
switch ( $field['type'] ) {
|
730 |
+
case 'checkbox':
|
731 |
+
$field = wp_parse_args( $field, $this->fields['checkbox'] );
|
732 |
+
break;
|
733 |
+
case 'color':
|
734 |
+
case 'radio':
|
735 |
+
case 'range':
|
736 |
+
break;
|
737 |
+
case 'date':
|
738 |
+
$field['value'] = date( 'Y-m-d', strtotime( $field['value'] ) );
|
739 |
+
$field = wp_parse_args( $field, $this->fields['text'] );
|
740 |
+
break;
|
741 |
+
case 'datetime':
|
742 |
+
case 'datetime-local':
|
743 |
+
$field['value'] = date( 'Y-m-d\TH:i:s', strtotime( $field['value'] ) );
|
744 |
+
$field = wp_parse_args( $field, $this->fields['text'] );
|
745 |
+
break;
|
746 |
+
case 'month':
|
747 |
+
$field['value'] = date( 'Y-m', strtotime( $field['value'] ) );
|
748 |
+
$field = wp_parse_args( $field, $this->fields['text'] );
|
749 |
+
break;
|
750 |
+
case 'textarea':
|
751 |
+
$field = wp_parse_args( $field, $this->fields[ $field['type'] ] );
|
752 |
+
break;
|
753 |
+
case 'time':
|
754 |
+
$field['value'] = date( 'H:i:s', strtotime( $field['value'] ) );
|
755 |
+
$field = wp_parse_args( $field, $this->fields['text'] );
|
756 |
+
break;
|
757 |
+
case 'week':
|
758 |
+
$field['value'] = date( 'Y-\WW', strtotime( $field['value'] ) );
|
759 |
+
$field = wp_parse_args( $field, $this->fields['text'] );
|
760 |
+
break;
|
761 |
+
case 'wp_editor':
|
762 |
+
$field = wp_parse_args( $field, $this->fields['wp_editor'] );
|
763 |
+
break;
|
764 |
+
default:
|
765 |
+
$field = wp_parse_args( $field, $this->fields['text'] );
|
766 |
+
}
|
767 |
+
|
768 |
+
return $field;
|
769 |
+
}
|
770 |
+
|
771 |
+
/**
|
772 |
+
* Validates the information submitted to the class
|
773 |
+
*
|
774 |
+
* @param string $page_key Array key of the page
|
775 |
+
* @param array $page Array of page parameters
|
776 |
+
* @param string $parent_slug Menu slug of the parent page if there is one
|
777 |
+
*
|
778 |
+
* @return array Validated array of page parameters
|
779 |
+
*/
|
780 |
+
protected function validate_page( $page_key, $page_params, $parent_slug = false ) {
|
781 |
+
// Page title
|
782 |
+
if ( empty( $page_params['page_title'] ) ) {
|
783 |
+
$this->submit_error( 'Page parameter "page_title" is required' );
|
784 |
+
}
|
785 |
+
|
786 |
+
// Menu title
|
787 |
+
if ( empty( $page_params['menu_title'] ) ) {
|
788 |
+
$page_params['menu_title'] = $page_params['page_title'];
|
789 |
+
}
|
790 |
+
|
791 |
+
// Menu slug
|
792 |
+
if ( empty( $page_params['menu_slug'] ) ) {
|
793 |
+
// Basing it off the page title cause it's likely to be more unique than the menu title
|
794 |
+
$page_params['menu_slug'] = $this->slugify( $page_params['page_title'] );
|
795 |
+
}
|
796 |
+
|
797 |
+
// Menu or submenu item?
|
798 |
+
if ( empty( $page_params['parent_slug'] ) && !$parent_slug ) {
|
799 |
+
$page_params['function'] = 'add_menu_page';
|
800 |
+
} else {
|
801 |
+
$page_params['function'] = 'add_submenu_page';
|
802 |
+
$page_params['parent_slug'] = $parent_slug ? $parent_slug : $page_params['parent_slug'];
|
803 |
+
}
|
804 |
+
|
805 |
+
// Callback
|
806 |
+
$page_params['callback'] = "{$page_params['function']}|{$page_key}";
|
807 |
+
|
808 |
+
// Sanitize
|
809 |
+
$page_params['sanitize'] = empty( $page_params['sanitize'] ) ? "register_setting|{$page_key}" : $page_params['sanitize'];
|
810 |
+
|
811 |
+
// Make sure we haven't missed anything
|
812 |
+
$page_params = wp_parse_args( $page_params, $this->defaults[ $page_params['function'] ] );
|
813 |
+
|
814 |
+
// Subpages?
|
815 |
+
if ( !empty( $page_params['subpages'] ) ) {
|
816 |
+
foreach ( $page_params['subpages'] as $subpage_key => $subpage ) {
|
817 |
+
$this->subpages[ $subpage_key ] = $this->validate_page( $subpage_key, $subpage, $page_params['menu_slug'] );
|
818 |
+
}
|
819 |
+
unset( $page_params['subpages'] );
|
820 |
+
}
|
821 |
+
|
822 |
+
// Sections?
|
823 |
+
if ( !empty( $page_params['sections'] ) ) {
|
824 |
+
foreach ( $page_params['sections'] as $section_key => $section_params ) {
|
825 |
+
$page_params['sections'][ $section_key ] = $this->validate_section( $section_params, $page_key, $section_key, $page_params['menu_slug'] );
|
826 |
+
}
|
827 |
+
}
|
828 |
+
|
829 |
+
return $page_params;
|
830 |
+
}
|
831 |
+
|
832 |
+
/**
|
833 |
+
* Validates the section data submitted to the class
|
834 |
+
*
|
835 |
+
* @param array $section Section array
|
836 |
+
* @param string $page_key Array key of the associated page
|
837 |
+
* @param string $section_key Array key of the associated page
|
838 |
+
* @param string $page ID of the associated page
|
839 |
+
*
|
840 |
+
* @return array Validated section array
|
841 |
+
*/
|
842 |
+
protected function validate_section( $section, $page_key, $section_key, $page ) {
|
843 |
+
// Title
|
844 |
+
if ( empty( $section['title'] ) ) {
|
845 |
+
$this->submit_error( 'Section parameter "title" is required' );
|
846 |
+
}
|
847 |
+
|
848 |
+
// ID
|
849 |
+
if ( empty( $section['id'] ) ) {
|
850 |
+
$section['id'] = $this->slugify( $section['title'] );
|
851 |
+
}
|
852 |
+
|
853 |
+
// Callback
|
854 |
+
$section['callback'] = empty( $section['callback'] ) ? "add_settings_section|{$page_key}|{$section_key}" : $section['callback'];
|
855 |
+
|
856 |
+
// Page
|
857 |
+
$section['page'] = $page;
|
858 |
+
|
859 |
+
// Fields?
|
860 |
+
if ( !empty( $section['fields'] ) ) {
|
861 |
+
foreach ( $section['fields'] as $field_key => $field_params ) {
|
862 |
+
$section['fields'][ $field_key ] = $this->validate_field( $field_params, $page_key, $section_key, $field_key, $page, $section['id'] );
|
863 |
+
}
|
864 |
+
}
|
865 |
+
|
866 |
+
return $section;
|
867 |
+
}
|
868 |
+
}
|
inc/common-functions.php
CHANGED
@@ -1,12 +1,98 @@
|
|
1 |
<?php
|
2 |
/* Common task helpers */
|
3 |
|
4 |
-
if
|
5 |
-
exit; // Exit if accessed directly.
|
6 |
-
}
|
7 |
|
8 |
-
|
9 |
-
|
10 |
-
|
11 |
-
|
12 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
<?php
|
2 |
/* Common task helpers */
|
3 |
|
4 |
+
if( ! defined( 'ABSPATH' ) ) exit;
|
|
|
|
|
5 |
|
6 |
+
$options_page = array(
|
7 |
+
'ob-settings-page' => array(
|
8 |
+
'page_title' => 'Steroids for Elementor',
|
9 |
+
'parent_slug' => 'options-general.php',
|
10 |
+
'sections' => array(
|
11 |
+
'section-ob-options' => array(
|
12 |
+
'title' => ' ',
|
13 |
+
'text' => __( '<p>The following extensions are currently available with Steroids for Elementor add-on.<br/>Enable or disable particular extension by switching it ON or OFF.</p>', 'ooohboi-steroids' ),
|
14 |
+
'fields' => array(
|
15 |
+
'ob_use_harakiri' => array(
|
16 |
+
'title' => 'HARAKIRI',
|
17 |
+
'type' => 'checkbox',
|
18 |
+
'text' => esc_attr__( 'Allows you to change the writing mode of the Heading and Text Editor widgets', 'ooohboi-steroids' ),
|
19 |
+
'checked' => 1,
|
20 |
+
),
|
21 |
+
'ob_use_poopart' => array(
|
22 |
+
'title' => 'POOPART',
|
23 |
+
'type' => 'checkbox',
|
24 |
+
'text' => esc_attr__( 'Add an overlay or underlay ghost-element to any Elementor Widget', 'ooohboi-steroids' ),
|
25 |
+
'checked' => 1,
|
26 |
+
),
|
27 |
+
'ob_use_overlaiz' => array(
|
28 |
+
'title' => 'OVERLAIZ',
|
29 |
+
'type' => 'checkbox',
|
30 |
+
'text' => esc_attr__( 'An awesome set of options for the Background Overlay element manipulation', 'ooohboi-steroids' ),
|
31 |
+
'checked' => 1,
|
32 |
+
),
|
33 |
+
'ob_use_paginini' => array(
|
34 |
+
'title' => 'PAGININI',
|
35 |
+
'type' => 'checkbox',
|
36 |
+
'text' => esc_attr__( 'It allows you to style up the posts pagination in Elementor', 'ooohboi-steroids' ),
|
37 |
+
'checked' => 1,
|
38 |
+
),
|
39 |
+
'ob_use_breakingbad' => array(
|
40 |
+
'title' => 'BREAKING BAD',
|
41 |
+
'type' => 'checkbox',
|
42 |
+
'text' => esc_attr__( 'A must to have extension for the Section and Columns', 'ooohboi-steroids' ),
|
43 |
+
'checked' => 1,
|
44 |
+
),
|
45 |
+
'ob_use_glider' => array(
|
46 |
+
'title' => 'GLIDER',
|
47 |
+
'type' => 'checkbox',
|
48 |
+
'text' => esc_attr__( 'The content slider made out of Section and Columns (Swiper)', 'ooohboi-steroids' ),
|
49 |
+
'checked' => 1,
|
50 |
+
),
|
51 |
+
'ob_use_photogiraffe' => array(
|
52 |
+
'title' => 'PHOTOGIRAFFE',
|
53 |
+
'type' => 'checkbox',
|
54 |
+
'text' => esc_attr__( 'Make the Image widget full-height of the container', 'ooohboi-steroids' ),
|
55 |
+
'checked' => 1,
|
56 |
+
),
|
57 |
+
'ob_use_teleporter' => array(
|
58 |
+
'title' => 'TELEPORTER',
|
59 |
+
'type' => 'checkbox',
|
60 |
+
'text' => esc_attr__( 'The Column hover controls for an exceptional effects', 'ooohboi-steroids' ),
|
61 |
+
'checked' => 1,
|
62 |
+
),
|
63 |
+
'ob_use_searchcop' => array(
|
64 |
+
'title' => 'SEARCH COP',
|
65 |
+
'type' => 'checkbox',
|
66 |
+
'text' => esc_attr__( 'Decide what to search for; posts only, pages only or everything', 'ooohboi-steroids' ),
|
67 |
+
'checked' => 1,
|
68 |
+
),
|
69 |
+
'ob_use_videomasq' => array(
|
70 |
+
'title' => 'VIDEOMASQ',
|
71 |
+
'type' => 'checkbox',
|
72 |
+
'text' => esc_attr__( 'Add the SVG mask to the Section video background and let the video play inside any shape', 'ooohboi-steroids' ),
|
73 |
+
'checked' => 1,
|
74 |
+
),
|
75 |
+
'ob_use_butterbutton' => array(
|
76 |
+
'title' => 'BUTTER BUTTON',
|
77 |
+
'type' => 'checkbox',
|
78 |
+
'text' => esc_attr__( 'Design awesome buttons in Elementor', 'ooohboi-steroids' ),
|
79 |
+
'checked' => 1,
|
80 |
+
),
|
81 |
+
'ob_use_perspektive' => array(
|
82 |
+
'title' => 'PERSPEKTIVE',
|
83 |
+
'type' => 'checkbox',
|
84 |
+
'text' => esc_attr__( 'A small set of options that allow you to move widgets in 3D space', 'ooohboi-steroids' ),
|
85 |
+
'checked' => 1,
|
86 |
+
),
|
87 |
+
'ob_use_shadough' => array(
|
88 |
+
'title' => 'SHADOUGH',
|
89 |
+
'type' => 'checkbox',
|
90 |
+
'text' => esc_attr__( 'Create the shadow that conforms the shape', 'ooohboi-steroids' ),
|
91 |
+
'checked' => 1,
|
92 |
+
),
|
93 |
+
),
|
94 |
+
),
|
95 |
+
),
|
96 |
+
),
|
97 |
+
);
|
98 |
+
$option_page = new RationalOptionPages( $options_page );
|
lang/ooohboi-steroids.pot
CHANGED
@@ -3,8 +3,8 @@ msgid ""
|
|
3 |
msgstr ""
|
4 |
"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
|
5 |
"Project-Id-Version: OoohBoi Steroids for Elementor\n"
|
6 |
-
"POT-Creation-Date: 2020-08-
|
7 |
-
"PO-Revision-Date: 2020-08-
|
8 |
"Last-Translator: \n"
|
9 |
"Language-Team: \n"
|
10 |
"MIME-Version: 1.0\n"
|
@@ -31,26 +31,26 @@ msgid ""
|
|
31 |
"order to fit the available width."
|
32 |
msgstr ""
|
33 |
|
34 |
-
#: controls/ooohboi-breaking-bad.php:65 controls/ooohboi-breaking-bad.php:
|
35 |
#: controls/ooohboi-butter-button.php:71 controls/ooohboi-glider.php:68
|
36 |
#: controls/ooohboi-glider.php:83 controls/ooohboi-glider.php:134
|
37 |
#: controls/ooohboi-glider.php:319 controls/ooohboi-glider.php:463
|
38 |
#: controls/ooohboi-glider.php:503 controls/ooohboi-glider.php:538
|
39 |
#: controls/ooohboi-glider.php:556 controls/ooohboi-harakiri.php:81
|
40 |
-
#: controls/ooohboi-overlaiz.php:61 controls/ooohboi-overlay-underlay.php:
|
41 |
-
#: controls/ooohboi-overlay-underlay.php:
|
42 |
#: controls/ooohboi-perspektive.php:74 controls/ooohboi-shadough.php:50
|
43 |
msgid "Yes"
|
44 |
msgstr ""
|
45 |
|
46 |
-
#: controls/ooohboi-breaking-bad.php:66 controls/ooohboi-breaking-bad.php:
|
47 |
#: controls/ooohboi-butter-button.php:72 controls/ooohboi-glider.php:69
|
48 |
#: controls/ooohboi-glider.php:84 controls/ooohboi-glider.php:135
|
49 |
#: controls/ooohboi-glider.php:320 controls/ooohboi-glider.php:464
|
50 |
#: controls/ooohboi-glider.php:504 controls/ooohboi-glider.php:539
|
51 |
#: controls/ooohboi-glider.php:557 controls/ooohboi-harakiri.php:82
|
52 |
-
#: controls/ooohboi-overlaiz.php:62 controls/ooohboi-overlay-underlay.php:
|
53 |
-
#: controls/ooohboi-overlay-underlay.php:
|
54 |
#: controls/ooohboi-perspektive.php:75 controls/ooohboi-shadough.php:51
|
55 |
msgid "No"
|
56 |
msgstr ""
|
@@ -99,31 +99,31 @@ msgstr ""
|
|
99 |
msgid "Align Items"
|
100 |
msgstr ""
|
101 |
|
102 |
-
#: controls/ooohboi-breaking-bad.php:
|
103 |
msgid "Custom Width"
|
104 |
msgstr ""
|
105 |
|
106 |
-
#: controls/ooohboi-breaking-bad.php:
|
107 |
msgid ""
|
108 |
"You can enter any acceptable CSS value, for example: 50em, 300px, 100%, "
|
109 |
"calc(100% - 300px). NOTE: If you want to make the columns wrap, Enable "
|
110 |
"Breaking Bad for this Column parent SECTION!"
|
111 |
msgstr ""
|
112 |
|
113 |
-
#: controls/ooohboi-breaking-bad.php:
|
114 |
msgid "Custom Height"
|
115 |
msgstr ""
|
116 |
|
117 |
-
#: controls/ooohboi-breaking-bad.php:
|
118 |
msgid "Column Order"
|
119 |
msgstr ""
|
120 |
|
121 |
-
#: controls/ooohboi-breaking-bad.php:
|
122 |
#, php-format
|
123 |
msgid "More info at %sMozilla%s."
|
124 |
msgstr ""
|
125 |
|
126 |
-
#: controls/ooohboi-breaking-bad.php:
|
127 |
msgid "Scrollable Column?"
|
128 |
msgstr ""
|
129 |
|
@@ -447,7 +447,17 @@ msgstr ""
|
|
447 |
msgid "Calc Position - Y"
|
448 |
msgstr ""
|
449 |
|
450 |
-
#: controls/ooohboi-overlaiz.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
451 |
#: controls/ooohboi-overlay-underlay.php:1172
|
452 |
msgid "Z-Index"
|
453 |
msgstr ""
|
@@ -631,53 +641,53 @@ msgstr ""
|
|
631 |
msgid "Underlay Mask"
|
632 |
msgstr ""
|
633 |
|
634 |
-
#: controls/ooohboi-overlay-underlay.php:
|
635 |
msgid "Get rid of the Horizontal scroller?"
|
636 |
msgstr ""
|
637 |
|
638 |
-
#: controls/ooohboi-overlay-underlay.php:
|
639 |
msgid ""
|
640 |
"OoohBoi POOOPART may cause Horizontal Scroller to show up. This is how you "
|
641 |
"can remove it."
|
642 |
msgstr ""
|
643 |
|
644 |
-
#: controls/ooohboi-overlay-underlay.php:
|
645 |
msgid "Baseline Grid"
|
646 |
msgstr ""
|
647 |
|
648 |
-
#: controls/ooohboi-overlay-underlay.php:
|
649 |
msgid "Baseline grid helps you maintain accuracy and consistency"
|
650 |
msgstr ""
|
651 |
|
652 |
-
#: controls/ooohboi-overlay-underlay.php:
|
653 |
msgid "Grid style"
|
654 |
msgstr ""
|
655 |
|
656 |
-
#: controls/ooohboi-overlay-underlay.php:
|
657 |
msgid "Squares"
|
658 |
msgstr ""
|
659 |
|
660 |
-
#: controls/ooohboi-overlay-underlay.php:
|
661 |
msgid "Vertical lines"
|
662 |
msgstr ""
|
663 |
|
664 |
-
#: controls/ooohboi-overlay-underlay.php:
|
665 |
msgid "Horizontal lines"
|
666 |
msgstr ""
|
667 |
|
668 |
-
#: controls/ooohboi-overlay-underlay.php:
|
669 |
msgid "Grid color"
|
670 |
msgstr ""
|
671 |
|
672 |
-
#: controls/ooohboi-overlay-underlay.php:
|
673 |
msgid "Grid size"
|
674 |
msgstr ""
|
675 |
|
676 |
-
#: controls/ooohboi-overlay-underlay.php:
|
677 |
msgid "Vertical Spacing"
|
678 |
msgstr ""
|
679 |
|
680 |
-
#: controls/ooohboi-overlay-underlay.php:
|
681 |
msgid "Horizontal Spacing"
|
682 |
msgstr ""
|
683 |
|
@@ -908,6 +918,69 @@ msgid ""
|
|
908 |
"that’s transparent will be completely hidden."
|
909 |
msgstr ""
|
910 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
911 |
#. Plugin Name of the plugin/theme
|
912 |
msgid "OoohBoi Steroids for Elementor"
|
913 |
msgstr ""
|
3 |
msgstr ""
|
4 |
"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
|
5 |
"Project-Id-Version: OoohBoi Steroids for Elementor\n"
|
6 |
+
"POT-Creation-Date: 2020-08-18 12:53+0200\n"
|
7 |
+
"PO-Revision-Date: 2020-08-18 12:53+0200\n"
|
8 |
"Last-Translator: \n"
|
9 |
"Language-Team: \n"
|
10 |
"MIME-Version: 1.0\n"
|
31 |
"order to fit the available width."
|
32 |
msgstr ""
|
33 |
|
34 |
+
#: controls/ooohboi-breaking-bad.php:65 controls/ooohboi-breaking-bad.php:214
|
35 |
#: controls/ooohboi-butter-button.php:71 controls/ooohboi-glider.php:68
|
36 |
#: controls/ooohboi-glider.php:83 controls/ooohboi-glider.php:134
|
37 |
#: controls/ooohboi-glider.php:319 controls/ooohboi-glider.php:463
|
38 |
#: controls/ooohboi-glider.php:503 controls/ooohboi-glider.php:538
|
39 |
#: controls/ooohboi-glider.php:556 controls/ooohboi-harakiri.php:81
|
40 |
+
#: controls/ooohboi-overlaiz.php:61 controls/ooohboi-overlay-underlay.php:1203
|
41 |
+
#: controls/ooohboi-overlay-underlay.php:1222 controls/ooohboi-paginini.php:220
|
42 |
#: controls/ooohboi-perspektive.php:74 controls/ooohboi-shadough.php:50
|
43 |
msgid "Yes"
|
44 |
msgstr ""
|
45 |
|
46 |
+
#: controls/ooohboi-breaking-bad.php:66 controls/ooohboi-breaking-bad.php:215
|
47 |
#: controls/ooohboi-butter-button.php:72 controls/ooohboi-glider.php:69
|
48 |
#: controls/ooohboi-glider.php:84 controls/ooohboi-glider.php:135
|
49 |
#: controls/ooohboi-glider.php:320 controls/ooohboi-glider.php:464
|
50 |
#: controls/ooohboi-glider.php:504 controls/ooohboi-glider.php:539
|
51 |
#: controls/ooohboi-glider.php:557 controls/ooohboi-harakiri.php:82
|
52 |
+
#: controls/ooohboi-overlaiz.php:62 controls/ooohboi-overlay-underlay.php:1204
|
53 |
+
#: controls/ooohboi-overlay-underlay.php:1223 controls/ooohboi-paginini.php:221
|
54 |
#: controls/ooohboi-perspektive.php:75 controls/ooohboi-shadough.php:51
|
55 |
msgid "No"
|
56 |
msgstr ""
|
99 |
msgid "Align Items"
|
100 |
msgstr ""
|
101 |
|
102 |
+
#: controls/ooohboi-breaking-bad.php:153
|
103 |
msgid "Custom Width"
|
104 |
msgstr ""
|
105 |
|
106 |
+
#: controls/ooohboi-breaking-bad.php:157
|
107 |
msgid ""
|
108 |
"You can enter any acceptable CSS value, for example: 50em, 300px, 100%, "
|
109 |
"calc(100% - 300px). NOTE: If you want to make the columns wrap, Enable "
|
110 |
"Breaking Bad for this Column parent SECTION!"
|
111 |
msgstr ""
|
112 |
|
113 |
+
#: controls/ooohboi-breaking-bad.php:167 controls/ooohboi-harakiri.php:142
|
114 |
msgid "Custom Height"
|
115 |
msgstr ""
|
116 |
|
117 |
+
#: controls/ooohboi-breaking-bad.php:193
|
118 |
msgid "Column Order"
|
119 |
msgstr ""
|
120 |
|
121 |
+
#: controls/ooohboi-breaking-bad.php:195
|
122 |
#, php-format
|
123 |
msgid "More info at %sMozilla%s."
|
124 |
msgstr ""
|
125 |
|
126 |
+
#: controls/ooohboi-breaking-bad.php:211
|
127 |
msgid "Scrollable Column?"
|
128 |
msgstr ""
|
129 |
|
447 |
msgid "Calc Position - Y"
|
448 |
msgstr ""
|
449 |
|
450 |
+
#: controls/ooohboi-overlaiz.php:420
|
451 |
+
msgid "Clip path"
|
452 |
+
msgstr ""
|
453 |
+
|
454 |
+
#: controls/ooohboi-overlaiz.php:436
|
455 |
+
#, php-format
|
456 |
+
msgid ""
|
457 |
+
"Enter the full clip-path property! See the copy-paste examples at %sClippy%s"
|
458 |
+
msgstr ""
|
459 |
+
|
460 |
+
#: controls/ooohboi-overlaiz.php:459 controls/ooohboi-overlay-underlay.php:630
|
461 |
#: controls/ooohboi-overlay-underlay.php:1172
|
462 |
msgid "Z-Index"
|
463 |
msgstr ""
|
641 |
msgid "Underlay Mask"
|
642 |
msgstr ""
|
643 |
|
644 |
+
#: controls/ooohboi-overlay-underlay.php:1200
|
645 |
msgid "Get rid of the Horizontal scroller?"
|
646 |
msgstr ""
|
647 |
|
648 |
+
#: controls/ooohboi-overlay-underlay.php:1201
|
649 |
msgid ""
|
650 |
"OoohBoi POOOPART may cause Horizontal Scroller to show up. This is how you "
|
651 |
"can remove it."
|
652 |
msgstr ""
|
653 |
|
654 |
+
#: controls/ooohboi-overlay-underlay.php:1219
|
655 |
msgid "Baseline Grid"
|
656 |
msgstr ""
|
657 |
|
658 |
+
#: controls/ooohboi-overlay-underlay.php:1220
|
659 |
msgid "Baseline grid helps you maintain accuracy and consistency"
|
660 |
msgstr ""
|
661 |
|
662 |
+
#: controls/ooohboi-overlay-underlay.php:1233
|
663 |
msgid "Grid style"
|
664 |
msgstr ""
|
665 |
|
666 |
+
#: controls/ooohboi-overlay-underlay.php:1237
|
667 |
msgid "Squares"
|
668 |
msgstr ""
|
669 |
|
670 |
+
#: controls/ooohboi-overlay-underlay.php:1238
|
671 |
msgid "Vertical lines"
|
672 |
msgstr ""
|
673 |
|
674 |
+
#: controls/ooohboi-overlay-underlay.php:1239
|
675 |
msgid "Horizontal lines"
|
676 |
msgstr ""
|
677 |
|
678 |
+
#: controls/ooohboi-overlay-underlay.php:1249
|
679 |
msgid "Grid color"
|
680 |
msgstr ""
|
681 |
|
682 |
+
#: controls/ooohboi-overlay-underlay.php:1260
|
683 |
msgid "Grid size"
|
684 |
msgstr ""
|
685 |
|
686 |
+
#: controls/ooohboi-overlay-underlay.php:1284
|
687 |
msgid "Vertical Spacing"
|
688 |
msgstr ""
|
689 |
|
690 |
+
#: controls/ooohboi-overlay-underlay.php:1308
|
691 |
msgid "Horizontal Spacing"
|
692 |
msgstr ""
|
693 |
|
918 |
"that’s transparent will be completely hidden."
|
919 |
msgstr ""
|
920 |
|
921 |
+
#: inc/common-functions.php:13
|
922 |
+
msgid ""
|
923 |
+
"<p>The following extensions are currently available with Steroids for "
|
924 |
+
"Elementor add-on.<br/>Enable or disable particular extension by switching it "
|
925 |
+
"ON or OFF.</p>"
|
926 |
+
msgstr ""
|
927 |
+
|
928 |
+
#: inc/common-functions.php:18
|
929 |
+
msgid ""
|
930 |
+
"Allows you to change the writing mode of the Heading and Text Editor widgets"
|
931 |
+
msgstr ""
|
932 |
+
|
933 |
+
#: inc/common-functions.php:24
|
934 |
+
msgid "Add an overlay or underlay ghost-element to any Elementor Widget"
|
935 |
+
msgstr ""
|
936 |
+
|
937 |
+
#: inc/common-functions.php:30
|
938 |
+
msgid ""
|
939 |
+
"An awesome set of options for the Background Overlay element manipulation"
|
940 |
+
msgstr ""
|
941 |
+
|
942 |
+
#: inc/common-functions.php:36
|
943 |
+
msgid "It allows you to style up the posts pagination in Elementor"
|
944 |
+
msgstr ""
|
945 |
+
|
946 |
+
#: inc/common-functions.php:42
|
947 |
+
msgid "A must to have extension for the Section and Columns"
|
948 |
+
msgstr ""
|
949 |
+
|
950 |
+
#: inc/common-functions.php:48
|
951 |
+
msgid "The content slider made out of Section and Columns (Swiper)"
|
952 |
+
msgstr ""
|
953 |
+
|
954 |
+
#: inc/common-functions.php:54
|
955 |
+
msgid "Make the Image widget full-height of the container"
|
956 |
+
msgstr ""
|
957 |
+
|
958 |
+
#: inc/common-functions.php:60
|
959 |
+
msgid "The Column hover controls for an exceptional effects"
|
960 |
+
msgstr ""
|
961 |
+
|
962 |
+
#: inc/common-functions.php:66
|
963 |
+
msgid "Decide what to search for; posts only, pages only or everything"
|
964 |
+
msgstr ""
|
965 |
+
|
966 |
+
#: inc/common-functions.php:72
|
967 |
+
msgid ""
|
968 |
+
"Add the SVG mask to the Section video background and let the video play "
|
969 |
+
"inside any shape"
|
970 |
+
msgstr ""
|
971 |
+
|
972 |
+
#: inc/common-functions.php:78
|
973 |
+
msgid "Design awesome buttons in Elementor"
|
974 |
+
msgstr ""
|
975 |
+
|
976 |
+
#: inc/common-functions.php:84
|
977 |
+
msgid "A small set of options that allow you to move widgets in 3D space"
|
978 |
+
msgstr ""
|
979 |
+
|
980 |
+
#: inc/common-functions.php:90
|
981 |
+
msgid "Create the shadow that conforms the shape"
|
982 |
+
msgstr ""
|
983 |
+
|
984 |
#. Plugin Name of the plugin/theme
|
985 |
msgid "OoohBoi Steroids for Elementor"
|
986 |
msgstr ""
|
ooohboi-steroids.php
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
/**
|
3 |
* Plugin Name: OoohBoi Steroids for Elementor
|
4 |
* Description: An awesome set of tools, options and settings that expand Elementor defaults. Instead of creating new Elementor Widgets, these act like an upgrade of existing options or the self-standing panels.
|
5 |
-
* Version: 1.4.
|
6 |
* Author: OoohBoi
|
7 |
* Author URI: https://www.youtube.com/c/OoohBoi
|
8 |
* Text Domain: ooohboi-steroids
|
@@ -31,7 +31,7 @@ final class OoohBoi_Steroids {
|
|
31 |
*
|
32 |
* @var string The plugin version.
|
33 |
*/
|
34 |
-
const VERSION = '1.4.
|
35 |
|
36 |
/**
|
37 |
* Minimum Elementor Version
|
@@ -95,6 +95,7 @@ final class OoohBoi_Steroids {
|
|
95 |
public function __construct() {
|
96 |
add_action( 'init', [ $this, 'i18n' ] );
|
97 |
add_action( 'plugins_loaded', [ $this, 'init' ] );
|
|
|
98 |
}
|
99 |
|
100 |
/**
|
@@ -145,7 +146,18 @@ final class OoohBoi_Steroids {
|
|
145 |
return;
|
146 |
}
|
147 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
148 |
// load common stuff functions
|
|
|
149 |
require plugin_dir_path( __FILE__ ) . 'inc/common-functions.php';
|
150 |
|
151 |
// Editor Styles
|
@@ -169,26 +181,39 @@ final class OoohBoi_Steroids {
|
|
169 |
);
|
170 |
} );
|
171 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
172 |
// Include extension classes
|
173 |
self::ooohboi_take_steroids();
|
174 |
|
|
|
|
|
|
|
175 |
// Init Extensions
|
176 |
-
|
177 |
-
|
178 |
-
|
179 |
-
OoohBoi_Paginini::init(); // OoohBoi Paginini
|
180 |
-
OoohBoi_Breaking_Bad::init(); // OoohBoi Breaking Bad
|
181 |
-
OoohBoi_Glider::init(); // OoohBoi Glider Slider
|
182 |
-
OoohBoi_PhotoGiraffe::init(); // OoohBoi PhotoGiraffe
|
183 |
-
OoohBoi_Teleporter::init(); // OoohBoi Teleporter
|
184 |
-
OoohBoi_SearchCop::init(); // OoohBoi Search Cop
|
185 |
-
OoohBoi_Videomasq::init(); // OoohBoi Videomasq
|
186 |
-
OoohBoi_Butter_Button::init(); // OoohBoi Butter Button
|
187 |
-
OoohBoi_Perspektive::init(); // OoohBoi Perspektive
|
188 |
-
OoohBoi_Shadough::init(); // OoohBoi Shadough
|
189 |
-
|
190 |
}
|
191 |
-
|
192 |
/*
|
193 |
* Init styles for Elementor Editor
|
194 |
*
|
@@ -234,21 +259,6 @@ final class OoohBoi_Steroids {
|
|
234 |
|
235 |
}
|
236 |
|
237 |
-
/*
|
238 |
-
* Commercializer
|
239 |
-
*
|
240 |
-
* @since 1.4.6
|
241 |
-
*
|
242 |
-
* @access public
|
243 |
-
*/
|
244 |
-
public static function ooohboi_commercializer() {
|
245 |
-
|
246 |
-
return '';
|
247 |
-
//$com_lnk = '<a href="mailto:oooh.boi29@gmail.com?subject=Steroids Sponsorship"><img src="' . plugins_url( 'assets/img/banner-pre.png', __FILE__ ) . '" alt="Sponsorhip" /></a>';
|
248 |
-
//return $com_lnk;
|
249 |
-
|
250 |
-
}
|
251 |
-
|
252 |
/**
|
253 |
*
|
254 |
* Include extensions
|
2 |
/**
|
3 |
* Plugin Name: OoohBoi Steroids for Elementor
|
4 |
* Description: An awesome set of tools, options and settings that expand Elementor defaults. Instead of creating new Elementor Widgets, these act like an upgrade of existing options or the self-standing panels.
|
5 |
+
* Version: 1.4.8
|
6 |
* Author: OoohBoi
|
7 |
* Author URI: https://www.youtube.com/c/OoohBoi
|
8 |
* Text Domain: ooohboi-steroids
|
31 |
*
|
32 |
* @var string The plugin version.
|
33 |
*/
|
34 |
+
const VERSION = '1.4.8';
|
35 |
|
36 |
/**
|
37 |
* Minimum Elementor Version
|
95 |
public function __construct() {
|
96 |
add_action( 'init', [ $this, 'i18n' ] );
|
97 |
add_action( 'plugins_loaded', [ $this, 'init' ] );
|
98 |
+
add_action( 'init', [ $this, 'ooohboi_init_extensions' ] ); // load CF options
|
99 |
}
|
100 |
|
101 |
/**
|
146 |
return;
|
147 |
}
|
148 |
|
149 |
+
// admin styles
|
150 |
+
add_action( 'admin_enqueue_scripts', function() {
|
151 |
+
wp_enqueue_style(
|
152 |
+
'ooohboi-steroids-admin',
|
153 |
+
plugins_url( 'assets/css/admin.css', __FILE__ ),
|
154 |
+
[],
|
155 |
+
self::VERSION
|
156 |
+
);
|
157 |
+
} );
|
158 |
+
|
159 |
// load common stuff functions
|
160 |
+
require plugin_dir_path( __FILE__ ) . 'inc/RationalOptionPages.php';
|
161 |
require plugin_dir_path( __FILE__ ) . 'inc/common-functions.php';
|
162 |
|
163 |
// Editor Styles
|
181 |
);
|
182 |
} );
|
183 |
|
184 |
+
}
|
185 |
+
|
186 |
+
/*
|
187 |
+
* Init Extensions
|
188 |
+
*
|
189 |
+
* @since 1.5.0
|
190 |
+
*
|
191 |
+
* @access public
|
192 |
+
*/
|
193 |
+
public function ooohboi_init_extensions() {
|
194 |
+
|
195 |
// Include extension classes
|
196 |
self::ooohboi_take_steroids();
|
197 |
|
198 |
+
// what's enabled and what's not?
|
199 |
+
$ob_settings_options = get_option( 'ob-settings-page' );
|
200 |
+
|
201 |
// Init Extensions
|
202 |
+
if( isset( $ob_settings_options[ 'harakiri' ] ) && 'on' === $ob_settings_options[ 'harakiri' ] ) OoohBoi_Harakiri::init(); // OoohBoi Harakiri
|
203 |
+
if( isset( $ob_settings_options[ 'poopart' ] ) && 'on' === $ob_settings_options[ 'poopart' ] ) OoohBoi_Overlay_Underlay::init(); // OoohBoi Overlay Underlay
|
204 |
+
if( isset( $ob_settings_options[ 'overlaiz' ] ) && 'on' === $ob_settings_options[ 'overlaiz' ] ) OoohBoi_Overlaiz::init(); // OoohBoi Overlaiz
|
205 |
+
if( isset( $ob_settings_options[ 'paginini' ] ) && 'on' === $ob_settings_options[ 'paginini' ] ) OoohBoi_Paginini::init(); // OoohBoi Paginini
|
206 |
+
if( isset( $ob_settings_options[ 'breaking_bad' ] ) && 'on' === $ob_settings_options[ 'breaking_bad' ] ) OoohBoi_Breaking_Bad::init(); // OoohBoi Breaking Bad
|
207 |
+
if( isset( $ob_settings_options[ 'glider' ] ) && 'on' === $ob_settings_options[ 'glider' ] ) OoohBoi_Glider::init(); // OoohBoi Glider Slider
|
208 |
+
if( isset( $ob_settings_options[ 'photogiraffe' ] ) && 'on' === $ob_settings_options[ 'photogiraffe' ] ) OoohBoi_PhotoGiraffe::init(); // OoohBoi PhotoGiraffe
|
209 |
+
if( isset( $ob_settings_options[ 'teleporter' ] ) && 'on' === $ob_settings_options[ 'teleporter' ] ) OoohBoi_Teleporter::init(); // OoohBoi Teleporter
|
210 |
+
if( isset( $ob_settings_options[ 'search_cop' ] ) && 'on' === $ob_settings_options[ 'search_cop' ] ) OoohBoi_SearchCop::init(); // OoohBoi Search Cop
|
211 |
+
if( isset( $ob_settings_options[ 'videomasq' ] ) && 'on' === $ob_settings_options[ 'videomasq' ] ) OoohBoi_Videomasq::init(); // OoohBoi Videomasq
|
212 |
+
if( isset( $ob_settings_options[ 'butterbutton' ] ) && 'on' === $ob_settings_options[ 'butterbutton' ] ) OoohBoi_Butter_Button::init(); // OoohBoi Butter Button
|
213 |
+
if( isset( $ob_settings_options[ 'perspektive' ] ) && 'on' === $ob_settings_options[ 'perspektive' ] ) OoohBoi_Perspektive::init(); // OoohBoi Perspektive
|
214 |
+
if( isset( $ob_settings_options[ 'shadough' ] ) && 'on' === $ob_settings_options[ 'shadough' ] ) OoohBoi_Shadough::init(); // OoohBoi Shadough
|
215 |
+
|
216 |
}
|
|
|
217 |
/*
|
218 |
* Init styles for Elementor Editor
|
219 |
*
|
259 |
|
260 |
}
|
261 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
262 |
/**
|
263 |
*
|
264 |
* Include extensions
|
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Tags: page-builder, elementor, add-on, background-overlay, vertical text, ghost
|
|
4 |
Donate link: https://www.paypal.me/ooohboi
|
5 |
Requires at least: 5.0
|
6 |
Tested up to: 5.5
|
7 |
-
Stable tag: 1.4.
|
8 |
Requires PHP: 7.0
|
9 |
License: GPLv3
|
10 |
License URI: http://www.gnu.org/licenses/gpl-3.0
|
@@ -76,7 +76,7 @@ This extension allows you to create the shadow that conforms the shape.
|
|
76 |
|
77 |
== Upgrade Notice ==
|
78 |
|
79 |
-
1.4.
|
80 |
|
81 |
== Frequently Asked Questions ==
|
82 |
|
@@ -113,6 +113,12 @@ No, you don't. It'll work with both free version of Elementor and Elementor PRO.
|
|
113 |
|
114 |
== Changelog ==
|
115 |
|
|
|
|
|
|
|
|
|
|
|
|
|
116 |
= 1.4.7 =
|
117 |
- Ads space removed per sponsor request
|
118 |
|
4 |
Donate link: https://www.paypal.me/ooohboi
|
5 |
Requires at least: 5.0
|
6 |
Tested up to: 5.5
|
7 |
+
Stable tag: 1.4.8
|
8 |
Requires PHP: 7.0
|
9 |
License: GPLv3
|
10 |
License URI: http://www.gnu.org/licenses/gpl-3.0
|
76 |
|
77 |
== Upgrade Notice ==
|
78 |
|
79 |
+
1.4.8 - Beware of the changes in the language file!
|
80 |
|
81 |
== Frequently Asked Questions ==
|
82 |
|
113 |
|
114 |
== Changelog ==
|
115 |
|
116 |
+
= 1.4.8 =
|
117 |
+
- Added options page to WP Admin (see Settins > Steroids for Elementor) for controlling the active extensions
|
118 |
+
- Overlaiz, added option to clip-path the Background Overlay
|
119 |
+
- Glider, added support for slideTo() from any link inside the Glider, with the class ".glider-control", and data attribute "data-gotoslide|N" (where N is the slide number)
|
120 |
+
- Glider, hash navigation enabled (see: https://swiperjs.com/api/#hash-navigation)
|
121 |
+
|
122 |
= 1.4.7 =
|
123 |
- Ads space removed per sponsor request
|
124 |
|