/** Used as references for various `Number` constants. */
/** Used to match leading and trailing whitespace. */
var reTrim = /^\s+|\s+$/g;
/** Used to detect bad signed hexadecimal string values. */
var reIsBadHex = /^[-+]0x[0-9a-f]+$/i;
/** Used to detect binary string values. */
var reIsBinary = /^0b[01]+$/i;
/** Used to detect octal string values. */
var reIsOctal = /^0o[0-7]+$/i;
/** Built-in method references without a dependency on `root`. */
var freeParseInt = parseInt;
* Converts `value` to a number.
* @param {*} value The value to process.
* @returns {number} Returns the number.
* _.toNumber(Number.MIN_VALUE);
function toNumber(value) {
if (typeof value == 'number') {
var other = typeof value.valueOf == 'function' ? value.valueOf() : value;
value = isObject(other) ? (other + '') : other;
if (typeof value != 'string') {
return value === 0 ? value : +value;
value = value.replace(reTrim, '');
var isBinary = reIsBinary.test(value);
return (isBinary || reIsOctal.test(value))
? freeParseInt(value.slice(2), isBinary ? 2 : 8)
: (reIsBadHex.test(value) ? NAN : +value);
module.exports = toNumber;
/***/ "./includes/builder/node_modules/lodash/toString.js":
/*!**********************************************************!*\
!*** ./includes/builder/node_modules/lodash/toString.js ***!
\**********************************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
var baseToString = __webpack_require__(/*! ./_baseToString */ "./includes/builder/node_modules/lodash/_baseToString.js");
* Converts `value` to a string. An empty string is returned for `null`
* and `undefined` values. The sign of `-0` is preserved.
* @param {*} value The value to convert.
* @returns {string} Returns the converted string.
function toString(value) {
return value == null ? '' : baseToString(value);
module.exports = toString;
/***/ "./includes/builder/node_modules/lodash/values.js":
/*!********************************************************!*\
!*** ./includes/builder/node_modules/lodash/values.js ***!
\********************************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
var baseValues = __webpack_require__(/*! ./_baseValues */ "./includes/builder/node_modules/lodash/_baseValues.js"),
keys = __webpack_require__(/*! ./keys */ "./includes/builder/node_modules/lodash/keys.js");
* Creates an array of the own enumerable string keyed property values of `object`.
* **Note:** Non-object values are coerced to objects.
* @param {Object} object The object to query.
* @returns {Array} Returns the array of property values.
* // => [1, 2] (iteration order is not guaranteed)
function values(object) {
return object == null ? [] : baseValues(object, keys(object));
/***/ "./includes/builder/scripts/utils/utils.js":
/*!*************************************************!*\
!*** ./includes/builder/scripts/utils/utils.js ***!
\*************************************************/
/*! exports provided: isBuilderType, is, isFE, isVB, isBFB, isTB, isLBB, isDiviTheme, isExtraTheme, isLBP, isBlockEditor, isBuilder, getOffsets, maybeIncreaseEmitterMaxListeners, maybeDecreaseEmitterMaxListeners, registerFrontendComponent, setImportantInlineValue */
/***/ (function(module, __webpack_exports__, __webpack_require__) {
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isBuilderType", function() { return isBuilderType; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "is", function() { return is; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isFE", function() { return isFE; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isVB", function() { return isVB; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isBFB", function() { return isBFB; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isTB", function() { return isTB; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isLBB", function() { return isLBB; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isDiviTheme", function() { return isDiviTheme; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isExtraTheme", function() { return isExtraTheme; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isLBP", function() { return isLBP; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isBlockEditor", function() { return isBlockEditor; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isBuilder", function() { return isBuilder; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getOffsets", function() { return getOffsets; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "maybeIncreaseEmitterMaxListeners", function() { return maybeIncreaseEmitterMaxListeners; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "maybeDecreaseEmitterMaxListeners", function() { return maybeDecreaseEmitterMaxListeners; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "registerFrontendComponent", function() { return registerFrontendComponent; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "setImportantInlineValue", function() { return setImportantInlineValue; });
/* harmony import */ var lodash_includes__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! lodash/includes */ "./includes/builder/node_modules/lodash/includes.js");
/* harmony import */ var lodash_includes__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash_includes__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var lodash_get__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! lodash/get */ "./includes/builder/node_modules/lodash/get.js");
/* harmony import */ var lodash_get__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(lodash_get__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! jquery */ "jquery");
/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_2__);
/* harmony import */ var _core_admin_js_frame_helpers__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @core/admin/js/frame-helpers */ "./core/admin/js/frame-helpers.js");
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
* IMPORTANT: Keep external dependencies as low as possible since this utils might be
* imported by various frontend scripts; need to keep frontend script size low.
* Check current page's builder Type.
* @param {string} builderType Fe|vb|bfb|tb|lbb|lbp.
var isBuilderType = function isBuilderType(builderType) {
return builderType === window.et_builder_utils_params.builderType;
* Return condition value.
* @param {string} conditionName
var is = function is(conditionName) {
return window.et_builder_utils_params.condition[conditionName];
* Is current page Frontend.
var isFE = isBuilderType('fe');
* Is current page Visual Builder.
var isVB = isBuilderType('vb');
* Is current page BFB / New Builder Experience.
var isBFB = isBuilderType('bfb');
* Is current page Theme Builder.
var isTB = isBuilderType('tb');
* Is current page Layout Block Builder.
var isLBB = isBuilderType('lbb');
* Is current page uses Divi Theme.
var isDiviTheme = is('diviTheme');
* Is current page uses Extra Theme.
var isExtraTheme = is('extraTheme');
* Is current page Layout Block Preview.
var isLBP = isBuilderType('lbp');
* Check if current window is block editor window (gutenberg editing page).
var isBlockEditor = 0 < jquery__WEBPACK_IMPORTED_MODULE_2___default()(_core_admin_js_frame_helpers__WEBPACK_IMPORTED_MODULE_3__["top_window"].document).find('.edit-post-layout__content').length;
* Check if current window is builder window (VB, BFB, TB, LBB).
var isBuilder = lodash_includes__WEBPACK_IMPORTED_MODULE_0___default()(['vb', 'bfb', 'tb', 'lbb'], window.et_builder_utils_params.builderType);
* Get offsets value of all sides.
* @param {object} $selector JQuery selector instance.
var getOffsets = function getOffsets($selector) {
var width = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
var height = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;
// Return previously saved offset if sticky tab is active; retrieving actual offset contain risk
// of incorrect offsets if sticky horizontal / vertical offset of relative position is modified.
var isStickyTabActive = isBuilder && $selector.hasClass('et_pb_sticky') && 'fixed' !== $selector.css('position');
var cachedOffsets = $selector.data('et-offsets');
var cachedDevice = $selector.data('et-offsets-device');
var currentDevice = lodash_get__WEBPACK_IMPORTED_MODULE_1___default()(window.ET_FE, 'stores.window.breakpoint', ''); // Only return cachedOffsets if sticky tab is active and cachedOffsets is not undefined and
// cachedDevice equal to currentDevice.
if (isStickyTabActive && cachedOffsets !== undefined && cachedDevice === currentDevice) {
} // Get top & left offsets
var offsets = $selector.offset(); // If no offsets found, return empty object
if ('undefined' === typeof offsets) {
} // FE sets the flag for sticky module which uses transform as classname on module wrapper while
// VB, BFB, TB, and LB sets the flag on CSS output's <style> element because it can't modify
// its parent. This compromises avoids the needs to extract transform rendering logic
var hasTransform = isBuilder ? $selector.children('.et-fb-custom-css-output[data-sticky-has-transform="on"]').length > 0 : $selector.hasClass('et_pb_sticky--has-transform');
var top = 'undefined' === typeof offsets.top ? 0 : offsets.top;
var left = 'undefined' === typeof offsets.left ? 0 : offsets.left; // If module is sticky module that uses transform, its offset calculation needs to be adjusted
// because transform tends to modify the positioning of the module
// Calculate offset (relative to selector's parent) AFTER it is affected by transform
// NOTE: Can't use jQuery's position() because it considers margin-left `auto` which causes issue
// on row thus this manually calculate the difference between element and its parent's offset
// @see https://github.com/jquery/jquery/blob/1.12-stable/src/offset.js#L149-L155
var parentOffsets = $selector.parent().offset();
var transformedPosition = {
top: offsets.top - parentOffsets.top,
left: offsets.left - parentOffsets.left
}; // Calculate offset (relative to selector's parent) BEFORE it is affected by transform
var preTransformedPosition = {
top: $selector[0].offsetTop,
left: $selector[0].offsetLeft
}; // Update offset's top value
top += preTransformedPosition.top - transformedPosition.top;
offsets.top = top; // Update offset's left value
left += preTransformedPosition.left - transformedPosition.left;
} // Manually calculate right & bottom offsets
offsets.right = left + width;
offsets.bottom = top + height; // Save copy of the offset on element's .data() in case of scenario where retrieving actual
// offset value will lead to incorrect offset value (eg. sticky tab active with position offset)
$selector.data('et-offsets', offsets); // Add current device to cache
if ('' !== currentDevice) {
$selector.data('et-offsets-device', offsets);
* Increase EventEmitter's max listeners if lister count is about to surpass the max listeners limit
* IMPORTANT: Need to be placed BEFORE `.on()`.
* @param {EventEmitter} emitter
* @param {string} EventName
var maybeIncreaseEmitterMaxListeners = function maybeIncreaseEmitterMaxListeners(emitter, eventName) {
var currentCount = emitter.listenerCount(eventName);
var maxListeners = emitter.getMaxListeners();
if (currentCount === maxListeners) {
emitter.setMaxListeners(maxListeners + 1);
* Decrease EventEmitter's max listeners if listener count is less than max listener limit and above
* 10 (default max listener limit). If listener count is less than 10, max listener limit will
* IMPORTANT: Need to be placed AFTER `.removeListener()`.
* @param {EventEmitter} emitter
* @param {string} eventName
var maybeDecreaseEmitterMaxListeners = function maybeDecreaseEmitterMaxListeners(emitter, eventName) {
var currentCount = emitter.listenerCount(eventName);
var maxListeners = emitter.getMaxListeners();
emitter.setMaxListeners(currentCount);
* Expose frontend (FE) component via global object so it can be accessed and reused externally
* Note: window.ET_Builder is for builder app's component; window.ET_FE is for frontend component.
* @param {mixed} component
var registerFrontendComponent = function registerFrontendComponent(type, name, component) {
// Make sure that ET_FE is available
if ('undefined' === typeof window.ET_FE) {
if ('object' !== _typeof(window.ET_FE[type])) {
window.ET_FE[type][name] = component;
* Set inline style with !important tag. JQuery's .css() can't set value with `!important` tag so
* @param {object} $element
* @param {string} cssProp
var setImportantInlineValue = function setImportantInlineValue($element, cssProp, value) {
// Remove prop from current inline style in case the prop is already exist
$element.css(cssProp, ''); // Get current inline style
var inlineStyle = $element.attr('style'); // Re-insert inline style + property with important tag
$element.attr('style', "".concat(inlineStyle, " ").concat(cssProp, ": ").concat(value, " !important;"));
/***/ "./js/src/custom.js":
/*!**************************!*\
!*** ./js/src/custom.js ***!
\**************************/
/*! no exports provided */
/***/ (function(module, __webpack_exports__, __webpack_require__) {
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var builder_scripts_utils_utils__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! builder/scripts/utils/utils */ "./includes/builder/scripts/utils/utils.js");
window.et_calculating_scroll_position = false;
window.et_side_nav_links_initialized = false;
var top_window = builder_scripts_utils_utils__WEBPACK_IMPORTED_MODULE_0__["isBuilder"] ? ET_Builder.Frames.top : window;
function et_get_first_section() {
return $('.et-l:not(.et-l--footer) .et_pb_section:visible:first');
function et_get_first_module() {
return $('.et-l .et_pb_module:visible:first');
var $et_pb_post_fullwidth = $('.single.et_pb_pagebuilder_layout.et_full_width_page'),
et_is_mobile_device = navigator.userAgent.match(/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/),