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chK,MAAMiK,EAC5B,EAQA,YAAAjH,wBAAA,WACC,OAAOlR,KAAKiK,UACVO,KAAK,eACL0D,MAAMlO,KAAKiK,UAAUO,KAAK,mCAC7B,EACD,EAnuCA,IAquCAnL,OAAO+Y,kBAAoBA,C","sources":["webpack:///./node_modules/wicg-inert/dist/inert.esm.js","webpack:///webpack/bootstrap","webpack:///webpack/runtime/compat get default export","webpack:///webpack/runtime/define property getters","webpack:///webpack/runtime/hasOwnProperty shorthand","webpack:///external window \"jQuery\"","webpack:///./js/src/frontend.ts"],"sourcesContent":["var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\n/**\n * This work is licensed under the W3C Software and Document License\n * (http://www.w3.org/Consortium/Legal/2015/copyright-software-and-document).\n */\n\n(function () {\n // Return early if we're not running inside of the browser.\n if (typeof window === 'undefined') {\n return;\n }\n\n // Convenience function for converting NodeLists.\n /** @type {typeof Array.prototype.slice} */\n var slice = Array.prototype.slice;\n\n /**\n * IE has a non-standard name for \"matches\".\n * @type {typeof Element.prototype.matches}\n */\n var matches = Element.prototype.matches || Element.prototype.msMatchesSelector;\n\n /** @type {string} */\n var _focusableElementsString = ['a[href]', 'area[href]', 'input:not([disabled])', 'select:not([disabled])', 'textarea:not([disabled])', 'button:not([disabled])', 'details', 'summary', 'iframe', 'object', 'embed', '[contenteditable]'].join(',');\n\n /**\n * `InertRoot` manages a single inert subtree, i.e. a DOM subtree whose root element has an `inert`\n * attribute.\n *\n * Its main functions are:\n *\n * - to create and maintain a set of managed `InertNode`s, including when mutations occur in the\n * subtree. The `makeSubtreeUnfocusable()` method handles collecting `InertNode`s via registering\n * each focusable node in the subtree with the singleton `InertManager` which manages all known\n * focusable nodes within inert subtrees. `InertManager` ensures that a single `InertNode`\n * instance exists for each focusable node which has at least one inert root as an ancestor.\n *\n * - to notify all managed `InertNode`s when this subtree stops being inert (i.e. when the `inert`\n * attribute is removed from the root node). This is handled in the destructor, which calls the\n * `deregister` method on `InertManager` for each managed inert node.\n */\n\n var InertRoot = function () {\n /**\n * @param {!HTMLElement} rootElement The HTMLElement at the root of the inert subtree.\n * @param {!InertManager} inertManager The global singleton InertManager object.\n */\n function InertRoot(rootElement, inertManager) {\n _classCallCheck(this, InertRoot);\n\n /** @type {!InertManager} */\n this._inertManager = inertManager;\n\n /** @type {!HTMLElement} */\n this._rootElement = rootElement;\n\n /**\n * @type {!Set}\n * All managed focusable nodes in this InertRoot's subtree.\n */\n this._managedNodes = new Set();\n\n // Make the subtree hidden from assistive technology\n if (this._rootElement.hasAttribute('aria-hidden')) {\n /** @type {?string} */\n this._savedAriaHidden = this._rootElement.getAttribute('aria-hidden');\n } else {\n this._savedAriaHidden = null;\n }\n this._rootElement.setAttribute('aria-hidden', 'true');\n\n // Make all focusable elements in the subtree unfocusable and add them to _managedNodes\n this._makeSubtreeUnfocusable(this._rootElement);\n\n // Watch for:\n // - any additions in the subtree: make them unfocusable too\n // - any removals from the subtree: remove them from this inert root's managed nodes\n // - attribute changes: if `tabindex` is added, or removed from an intrinsically focusable\n // element, make that node a managed node.\n this._observer = new MutationObserver(this._onMutation.bind(this));\n this._observer.observe(this._rootElement, { attributes: true, childList: true, subtree: true });\n }\n\n /**\n * Call this whenever this object is about to become obsolete. This unwinds all of the state\n * stored in this object and updates the state of all of the managed nodes.\n */\n\n\n _createClass(InertRoot, [{\n key: 'destructor',\n value: function destructor() {\n this._observer.disconnect();\n\n if (this._rootElement) {\n if (this._savedAriaHidden !== null) {\n this._rootElement.setAttribute('aria-hidden', this._savedAriaHidden);\n } else {\n this._rootElement.removeAttribute('aria-hidden');\n }\n }\n\n this._managedNodes.forEach(function (inertNode) {\n this._unmanageNode(inertNode.node);\n }, this);\n\n // Note we cast the nulls to the ANY type here because:\n // 1) We want the class properties to be declared as non-null, or else we\n // need even more casts throughout this code. All bets are off if an\n // instance has been destroyed and a method is called.\n // 2) We don't want to cast \"this\", because we want type-aware optimizations\n // to know which properties we're setting.\n this._observer = /** @type {?} */null;\n this._rootElement = /** @type {?} */null;\n this._managedNodes = /** @type {?} */null;\n this._inertManager = /** @type {?} */null;\n }\n\n /**\n * @return {!Set} A copy of this InertRoot's managed nodes set.\n */\n\n }, {\n key: '_makeSubtreeUnfocusable',\n\n\n /**\n * @param {!Node} startNode\n */\n value: function _makeSubtreeUnfocusable(startNode) {\n var _this2 = this;\n\n composedTreeWalk(startNode, function (node) {\n return _this2._visitNode(node);\n });\n\n var activeElement = document.activeElement;\n\n if (!document.body.contains(startNode)) {\n // startNode may be in shadow DOM, so find its nearest shadowRoot to get the activeElement.\n var node = startNode;\n /** @type {!ShadowRoot|undefined} */\n var root = undefined;\n while (node) {\n if (node.nodeType === Node.DOCUMENT_FRAGMENT_NODE) {\n root = /** @type {!ShadowRoot} */node;\n break;\n }\n node = node.parentNode;\n }\n if (root) {\n activeElement = root.activeElement;\n }\n }\n if (startNode.contains(activeElement)) {\n activeElement.blur();\n // In IE11, if an element is already focused, and then set to tabindex=-1\n // calling blur() will not actually move the focus.\n // To work around this we call focus() on the body instead.\n if (activeElement === document.activeElement) {\n document.body.focus();\n }\n }\n }\n\n /**\n * @param {!Node} node\n */\n\n }, {\n key: '_visitNode',\n value: function _visitNode(node) {\n if (node.nodeType !== Node.ELEMENT_NODE) {\n return;\n }\n var element = /** @type {!HTMLElement} */node;\n\n // If a descendant inert root becomes un-inert, its descendants will still be inert because of\n // this inert root, so all of its managed nodes need to be adopted by this InertRoot.\n if (element !== this._rootElement && element.hasAttribute('inert')) {\n this._adoptInertRoot(element);\n }\n\n if (matches.call(element, _focusableElementsString) || element.hasAttribute('tabindex')) {\n this._manageNode(element);\n }\n }\n\n /**\n * Register the given node with this InertRoot and with InertManager.\n * @param {!Node} node\n */\n\n }, {\n key: '_manageNode',\n value: function _manageNode(node) {\n var inertNode = this._inertManager.register(node, this);\n this._managedNodes.add(inertNode);\n }\n\n /**\n * Unregister the given node with this InertRoot and with InertManager.\n * @param {!Node} node\n */\n\n }, {\n key: '_unmanageNode',\n value: function _unmanageNode(node) {\n var inertNode = this._inertManager.deregister(node, this);\n if (inertNode) {\n this._managedNodes['delete'](inertNode);\n }\n }\n\n /**\n * Unregister the entire subtree starting at `startNode`.\n * @param {!Node} startNode\n */\n\n }, {\n key: '_unmanageSubtree',\n value: function _unmanageSubtree(startNode) {\n var _this3 = this;\n\n composedTreeWalk(startNode, function (node) {\n return _this3._unmanageNode(node);\n });\n }\n\n /**\n * If a descendant node is found with an `inert` attribute, adopt its managed nodes.\n * @param {!HTMLElement} node\n */\n\n }, {\n key: '_adoptInertRoot',\n value: function _adoptInertRoot(node) {\n var inertSubroot = this._inertManager.getInertRoot(node);\n\n // During initialisation this inert root may not have been registered yet,\n // so register it now if need be.\n if (!inertSubroot) {\n this._inertManager.setInert(node, true);\n inertSubroot = this._inertManager.getInertRoot(node);\n }\n\n inertSubroot.managedNodes.forEach(function (savedInertNode) {\n this._manageNode(savedInertNode.node);\n }, this);\n }\n\n /**\n * Callback used when mutation observer detects subtree additions, removals, or attribute changes.\n * @param {!Array} records\n * @param {!MutationObserver} self\n */\n\n }, {\n key: '_onMutation',\n value: function _onMutation(records, self) {\n records.forEach(function (record) {\n var target = /** @type {!HTMLElement} */record.target;\n if (record.type === 'childList') {\n // Manage added nodes\n slice.call(record.addedNodes).forEach(function (node) {\n this._makeSubtreeUnfocusable(node);\n }, this);\n\n // Un-manage removed nodes\n slice.call(record.removedNodes).forEach(function (node) {\n this._unmanageSubtree(node);\n }, this);\n } else if (record.type === 'attributes') {\n if (record.attributeName === 'tabindex') {\n // Re-initialise inert node if tabindex changes\n this._manageNode(target);\n } else if (target !== this._rootElement && record.attributeName === 'inert' && target.hasAttribute('inert')) {\n // If a new inert root is added, adopt its managed nodes and make sure it knows about the\n // already managed nodes from this inert subroot.\n this._adoptInertRoot(target);\n var inertSubroot = this._inertManager.getInertRoot(target);\n this._managedNodes.forEach(function (managedNode) {\n if (target.contains(managedNode.node)) {\n inertSubroot._manageNode(managedNode.node);\n }\n });\n }\n }\n }, this);\n }\n }, {\n key: 'managedNodes',\n get: function get() {\n return new Set(this._managedNodes);\n }\n\n /** @return {boolean} */\n\n }, {\n key: 'hasSavedAriaHidden',\n get: function get() {\n return this._savedAriaHidden !== null;\n }\n\n /** @param {?string} ariaHidden */\n\n }, {\n key: 'savedAriaHidden',\n set: function set(ariaHidden) {\n this._savedAriaHidden = ariaHidden;\n }\n\n /** @return {?string} */\n ,\n get: function get() {\n return this._savedAriaHidden;\n }\n }]);\n\n return InertRoot;\n }();\n\n /**\n * `InertNode` initialises and manages a single inert node.\n * A node is inert if it is a descendant of one or more inert root elements.\n *\n * On construction, `InertNode` saves the existing `tabindex` value for the node, if any, and\n * either removes the `tabindex` attribute or sets it to `-1`, depending on whether the element\n * is intrinsically focusable or not.\n *\n * `InertNode` maintains a set of `InertRoot`s which are descendants of this `InertNode`. When an\n * `InertRoot` is destroyed, and calls `InertManager.deregister()`, the `InertManager` notifies the\n * `InertNode` via `removeInertRoot()`, which in turn destroys the `InertNode` if no `InertRoot`s\n * remain in the set. On destruction, `InertNode` reinstates the stored `tabindex` if one exists,\n * or removes the `tabindex` attribute if the element is intrinsically focusable.\n */\n\n\n var InertNode = function () {\n /**\n * @param {!Node} node A focusable element to be made inert.\n * @param {!InertRoot} inertRoot The inert root element associated with this inert node.\n */\n function InertNode(node, inertRoot) {\n _classCallCheck(this, InertNode);\n\n /** @type {!Node} */\n this._node = node;\n\n /** @type {boolean} */\n this._overrodeFocusMethod = false;\n\n /**\n * @type {!Set} The set of descendant inert roots.\n * If and only if this set becomes empty, this node is no longer inert.\n */\n this._inertRoots = new Set([inertRoot]);\n\n /** @type {?number} */\n this._savedTabIndex = null;\n\n /** @type {boolean} */\n this._destroyed = false;\n\n // Save any prior tabindex info and make this node untabbable\n this.ensureUntabbable();\n }\n\n /**\n * Call this whenever this object is about to become obsolete.\n * This makes the managed node focusable again and deletes all of the previously stored state.\n */\n\n\n _createClass(InertNode, [{\n key: 'destructor',\n value: function destructor() {\n this._throwIfDestroyed();\n\n if (this._node && this._node.nodeType === Node.ELEMENT_NODE) {\n var element = /** @type {!HTMLElement} */this._node;\n if (this._savedTabIndex !== null) {\n element.setAttribute('tabindex', this._savedTabIndex);\n } else {\n element.removeAttribute('tabindex');\n }\n\n // Use `delete` to restore native focus method.\n if (this._overrodeFocusMethod) {\n delete element.focus;\n }\n }\n\n // See note in InertRoot.destructor for why we cast these nulls to ANY.\n this._node = /** @type {?} */null;\n this._inertRoots = /** @type {?} */null;\n this._destroyed = true;\n }\n\n /**\n * @type {boolean} Whether this object is obsolete because the managed node is no longer inert.\n * If the object has been destroyed, any attempt to access it will cause an exception.\n */\n\n }, {\n key: '_throwIfDestroyed',\n\n\n /**\n * Throw if user tries to access destroyed InertNode.\n */\n value: function _throwIfDestroyed() {\n if (this.destroyed) {\n throw new Error('Trying to access destroyed InertNode');\n }\n }\n\n /** @return {boolean} */\n\n }, {\n key: 'ensureUntabbable',\n\n\n /** Save the existing tabindex value and make the node untabbable and unfocusable */\n value: function ensureUntabbable() {\n if (this.node.nodeType !== Node.ELEMENT_NODE) {\n return;\n }\n var element = /** @type {!HTMLElement} */this.node;\n if (matches.call(element, _focusableElementsString)) {\n if ( /** @type {!HTMLElement} */element.tabIndex === -1 && this.hasSavedTabIndex) {\n return;\n }\n\n if (element.hasAttribute('tabindex')) {\n this._savedTabIndex = /** @type {!HTMLElement} */element.tabIndex;\n }\n element.setAttribute('tabindex', '-1');\n if (element.nodeType === Node.ELEMENT_NODE) {\n element.focus = function () {};\n this._overrodeFocusMethod = true;\n }\n } else if (element.hasAttribute('tabindex')) {\n this._savedTabIndex = /** @type {!HTMLElement} */element.tabIndex;\n element.removeAttribute('tabindex');\n }\n }\n\n /**\n * Add another inert root to this inert node's set of managing inert roots.\n * @param {!InertRoot} inertRoot\n */\n\n }, {\n key: 'addInertRoot',\n value: function addInertRoot(inertRoot) {\n this._throwIfDestroyed();\n this._inertRoots.add(inertRoot);\n }\n\n /**\n * Remove the given inert root from this inert node's set of managing inert roots.\n * If the set of managing inert roots becomes empty, this node is no longer inert,\n * so the object should be destroyed.\n * @param {!InertRoot} inertRoot\n */\n\n }, {\n key: 'removeInertRoot',\n value: function removeInertRoot(inertRoot) {\n this._throwIfDestroyed();\n this._inertRoots['delete'](inertRoot);\n if (this._inertRoots.size === 0) {\n this.destructor();\n }\n }\n }, {\n key: 'destroyed',\n get: function get() {\n return (/** @type {!InertNode} */this._destroyed\n );\n }\n }, {\n key: 'hasSavedTabIndex',\n get: function get() {\n return this._savedTabIndex !== null;\n }\n\n /** @return {!Node} */\n\n }, {\n key: 'node',\n get: function get() {\n this._throwIfDestroyed();\n return this._node;\n }\n\n /** @param {?number} tabIndex */\n\n }, {\n key: 'savedTabIndex',\n set: function set(tabIndex) {\n this._throwIfDestroyed();\n this._savedTabIndex = tabIndex;\n }\n\n /** @return {?number} */\n ,\n get: function get() {\n this._throwIfDestroyed();\n return this._savedTabIndex;\n }\n }]);\n\n return InertNode;\n }();\n\n /**\n * InertManager is a per-document singleton object which manages all inert roots and nodes.\n *\n * When an element becomes an inert root by having an `inert` attribute set and/or its `inert`\n * property set to `true`, the `setInert` method creates an `InertRoot` object for the element.\n * The `InertRoot` in turn registers itself as managing all of the element's focusable descendant\n * nodes via the `register()` method. The `InertManager` ensures that a single `InertNode` instance\n * is created for each such node, via the `_managedNodes` map.\n */\n\n\n var InertManager = function () {\n /**\n * @param {!Document} document\n */\n function InertManager(document) {\n _classCallCheck(this, InertManager);\n\n if (!document) {\n throw new Error('Missing required argument; InertManager needs to wrap a document.');\n }\n\n /** @type {!Document} */\n this._document = document;\n\n /**\n * All managed nodes known to this InertManager. In a map to allow looking up by Node.\n * @type {!Map}\n */\n this._managedNodes = new Map();\n\n /**\n * All inert roots known to this InertManager. In a map to allow looking up by Node.\n * @type {!Map}\n */\n this._inertRoots = new Map();\n\n /**\n * Observer for mutations on `document.body`.\n * @type {!MutationObserver}\n */\n this._observer = new MutationObserver(this._watchForInert.bind(this));\n\n // Add inert style.\n addInertStyle(document.head || document.body || document.documentElement);\n\n // Wait for document to be loaded.\n if (document.readyState === 'loading') {\n document.addEventListener('DOMContentLoaded', this._onDocumentLoaded.bind(this));\n } else {\n this._onDocumentLoaded();\n }\n }\n\n /**\n * Set whether the given element should be an inert root or not.\n * @param {!HTMLElement} root\n * @param {boolean} inert\n */\n\n\n _createClass(InertManager, [{\n key: 'setInert',\n value: function setInert(root, inert) {\n if (inert) {\n if (this._inertRoots.has(root)) {\n // element is already inert\n return;\n }\n\n var inertRoot = new InertRoot(root, this);\n root.setAttribute('inert', '');\n this._inertRoots.set(root, inertRoot);\n // If not contained in the document, it must be in a shadowRoot.\n // Ensure inert styles are added there.\n if (!this._document.body.contains(root)) {\n var parent = root.parentNode;\n while (parent) {\n if (parent.nodeType === 11) {\n addInertStyle(parent);\n }\n parent = parent.parentNode;\n }\n }\n } else {\n if (!this._inertRoots.has(root)) {\n // element is already non-inert\n return;\n }\n\n var _inertRoot = this._inertRoots.get(root);\n _inertRoot.destructor();\n this._inertRoots['delete'](root);\n root.removeAttribute('inert');\n }\n }\n\n /**\n * Get the InertRoot object corresponding to the given inert root element, if any.\n * @param {!Node} element\n * @return {!InertRoot|undefined}\n */\n\n }, {\n key: 'getInertRoot',\n value: function getInertRoot(element) {\n return this._inertRoots.get(element);\n }\n\n /**\n * Register the given InertRoot as managing the given node.\n * In the case where the node has a previously existing inert root, this inert root will\n * be added to its set of inert roots.\n * @param {!Node} node\n * @param {!InertRoot} inertRoot\n * @return {!InertNode} inertNode\n */\n\n }, {\n key: 'register',\n value: function register(node, inertRoot) {\n var inertNode = this._managedNodes.get(node);\n if (inertNode !== undefined) {\n // node was already in an inert subtree\n inertNode.addInertRoot(inertRoot);\n } else {\n inertNode = new InertNode(node, inertRoot);\n }\n\n this._managedNodes.set(node, inertNode);\n\n return inertNode;\n }\n\n /**\n * De-register the given InertRoot as managing the given inert node.\n * Removes the inert root from the InertNode's set of managing inert roots, and remove the inert\n * node from the InertManager's set of managed nodes if it is destroyed.\n * If the node is not currently managed, this is essentially a no-op.\n * @param {!Node} node\n * @param {!InertRoot} inertRoot\n * @return {?InertNode} The potentially destroyed InertNode associated with this node, if any.\n */\n\n }, {\n key: 'deregister',\n value: function deregister(node, inertRoot) {\n var inertNode = this._managedNodes.get(node);\n if (!inertNode) {\n return null;\n }\n\n inertNode.removeInertRoot(inertRoot);\n if (inertNode.destroyed) {\n this._managedNodes['delete'](node);\n }\n\n return inertNode;\n }\n\n /**\n * Callback used when document has finished loading.\n */\n\n }, {\n key: '_onDocumentLoaded',\n value: function _onDocumentLoaded() {\n // Find all inert roots in document and make them actually inert.\n var inertElements = slice.call(this._document.querySelectorAll('[inert]'));\n inertElements.forEach(function (inertElement) {\n this.setInert(inertElement, true);\n }, this);\n\n // Comment this out to use programmatic API only.\n this._observer.observe(this._document.body || this._document.documentElement, { attributes: true, subtree: true, childList: true });\n }\n\n /**\n * Callback used when mutation observer detects attribute changes.\n * @param {!Array} records\n * @param {!MutationObserver} self\n */\n\n }, {\n key: '_watchForInert',\n value: function _watchForInert(records, self) {\n var _this = this;\n records.forEach(function (record) {\n switch (record.type) {\n case 'childList':\n slice.call(record.addedNodes).forEach(function (node) {\n if (node.nodeType !== Node.ELEMENT_NODE) {\n return;\n }\n var inertElements = slice.call(node.querySelectorAll('[inert]'));\n if (matches.call(node, '[inert]')) {\n inertElements.unshift(node);\n }\n inertElements.forEach(function (inertElement) {\n this.setInert(inertElement, true);\n }, _this);\n }, _this);\n break;\n case 'attributes':\n if (record.attributeName !== 'inert') {\n return;\n }\n var target = /** @type {!HTMLElement} */record.target;\n var inert = target.hasAttribute('inert');\n _this.setInert(target, inert);\n break;\n }\n }, this);\n }\n }]);\n\n return InertManager;\n }();\n\n /**\n * Recursively walk the composed tree from |node|.\n * @param {!Node} node\n * @param {(function (!HTMLElement))=} callback Callback to be called for each element traversed,\n * before descending into child nodes.\n * @param {?ShadowRoot=} shadowRootAncestor The nearest ShadowRoot ancestor, if any.\n */\n\n\n function composedTreeWalk(node, callback, shadowRootAncestor) {\n if (node.nodeType == Node.ELEMENT_NODE) {\n var element = /** @type {!HTMLElement} */node;\n if (callback) {\n callback(element);\n }\n\n // Descend into node:\n // If it has a ShadowRoot, ignore all child elements - these will be picked\n // up by the or elements. Descend straight into the\n // ShadowRoot.\n var shadowRoot = /** @type {!HTMLElement} */element.shadowRoot;\n if (shadowRoot) {\n composedTreeWalk(shadowRoot, callback, shadowRoot);\n return;\n }\n\n // If it is a element, descend into distributed elements - these\n // are elements from outside the shadow root which are rendered inside the\n // shadow DOM.\n if (element.localName == 'content') {\n var content = /** @type {!HTMLContentElement} */element;\n // Verifies if ShadowDom v0 is supported.\n var distributedNodes = content.getDistributedNodes ? content.getDistributedNodes() : [];\n for (var i = 0; i < distributedNodes.length; i++) {\n composedTreeWalk(distributedNodes[i], callback, shadowRootAncestor);\n }\n return;\n }\n\n // If it is a element, descend into assigned nodes - these\n // are elements from outside the shadow root which are rendered inside the\n // shadow DOM.\n if (element.localName == 'slot') {\n var slot = /** @type {!HTMLSlotElement} */element;\n // Verify if ShadowDom v1 is supported.\n var _distributedNodes = slot.assignedNodes ? slot.assignedNodes({ flatten: true }) : [];\n for (var _i = 0; _i < _distributedNodes.length; _i++) {\n composedTreeWalk(_distributedNodes[_i], callback, shadowRootAncestor);\n }\n return;\n }\n }\n\n // If it is neither the parent of a ShadowRoot, a element, a \n // element, nor a element recurse normally.\n var child = node.firstChild;\n while (child != null) {\n composedTreeWalk(child, callback, shadowRootAncestor);\n child = child.nextSibling;\n }\n }\n\n /**\n * Adds a style element to the node containing the inert specific styles\n * @param {!Node} node\n */\n function addInertStyle(node) {\n if (node.querySelector('style#inert-style, link#inert-style')) {\n return;\n }\n var style = document.createElement('style');\n style.setAttribute('id', 'inert-style');\n style.textContent = '\\n' + '[inert] {\\n' + ' pointer-events: none;\\n' + ' cursor: default;\\n' + '}\\n' + '\\n' + '[inert], [inert] * {\\n' + ' -webkit-user-select: none;\\n' + ' -moz-user-select: none;\\n' + ' -ms-user-select: none;\\n' + ' user-select: none;\\n' + '}\\n';\n node.appendChild(style);\n }\n\n if (!HTMLElement.prototype.hasOwnProperty('inert')) {\n /** @type {!InertManager} */\n var inertManager = new InertManager(document);\n\n Object.defineProperty(HTMLElement.prototype, 'inert', {\n enumerable: true,\n /** @this {!HTMLElement} */\n get: function get() {\n return this.hasAttribute('inert');\n },\n /** @this {!HTMLElement} */\n set: function set(inert) {\n inertManager.setInert(this, inert);\n }\n });\n }\n})();\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","const __WEBPACK_NAMESPACE_OBJECT__ = window[\"jQuery\"];","/**\n * GP Page Transitions - Frontend Scripts\n */\n\n/* eslint @wordpress/no-global-active-element: 0 */\n\nimport $ from 'jquery';\n\n// eslint-disable-next-line prettier/prettier\nimport type * as Swiper from 'swiper';\n\n// Polyfill for inert attribute\nimport 'wicg-inert';\n\n// Stylesheets\nimport './frontend.css';\n// eslint-disable-next-line import/no-unresolved\nimport 'swiper/css';\n// eslint-disable-next-line import/no-unresolved\nimport 'swiper/css/effect-fade';\n\ninterface GPPageTransitionsArgs {\n\tformId: number;\n\thasConditionalLogic: boolean;\n\tenablePageTransitions: boolean;\n\tenableAutoProgress: boolean;\n\thideNextButton: boolean;\n\thidePrevButton: boolean;\n\tenableSoftValidation: boolean;\n\tvalidationSelectors: any;\n\tvalidationClassForm: string;\n\tvalidationClass: string;\n\tvalidationMessageContainer: string;\n\tsubmission: any;\n\tpagination: {\n\t\ttype: string;\n\t\tstartAtZero: boolean;\n\t\tpageCount: number;\n\t\tprogressIndicators: any;\n\t\tpages: any;\n\t\tisCustom: any;\n\t\tlabels: {\n\t\t\tstep: string;\n\t\t\tof: string;\n\t\t};\n\t};\n\tskipSoftValidation: boolean;\n\tprogressBarStartAtZero: boolean;\n\ttransitionSettings: {\n\t\t[setting: string]: any;\n\t};\n}\n\ninterface GPPageTransitions extends GPPageTransitionsArgs {}\n\nclass GPPageTransitions implements GPPageTransitions {\n\tpublic formId!: number;\n\tpublic swiper!: Swiper.Swiper;\n\tpublic rules = {};\n\tpublic initialized: boolean = false;\n\tpublic sourcePage: number = 0;\n\tpublic inputs: { [selector: string]: JQuery } = {};\n\tpublic functions = {};\n\tpublic currentPage!: number;\n\tpublic $formElem!: JQuery;\n\tpublic $currentPage!: JQuery;\n\tpublic gfPageConditionalLogic: any;\n\tpublic percentageInterval?: NodeJS.Timer;\n\n\t/**\n\t * Observer to resize form body any time the form DOM changes (e.g. adding a row via the list field)\n\t */\n\tpublic observer: MutationObserver | undefined;\n\n\tconstructor(args: GPPageTransitionsArgs) {\n\t\tObject.assign(this, args);\n\t}\n\n\tinit(currentPage: string) {\n\t\t// Do not reinitialize if GF is attempting a JS redirect.\n\t\t// @ts-ignore\n\t\tif (window?.gformRedirect) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Class is reinitialized on every page load.\n\t\tthis.initialized = false;\n\n\t\t// @ts-ignore\n\t\tdelete this.swiper;\n\n\t\t// confirmation page will have no current page specified; no need to init on confirmation\n\t\tif (!currentPage) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this.submission.hasError) {\n\t\t\tthis.sourcePage = this.submission.sourcePage;\n\t\t}\n\n\t\tthis.$formElem = $('#gform_' + this.formId); // @todo: might need to change for WC GF Product Add-ons\n\t\tthis.setCurrentPage(currentPage);\n\n\t\tthis.bindEvents();\n\n\t\tthis.initialized = true;\n\t}\n\n\tinitPageTransitions() {\n\t\tif (!this.$formElem || !this.currentPage || !this.pagination.pageCount) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst $formBody = this.$formElem.find('.gform_body'),\n\t\t\tstartingIndex = Math.max(0, this.sourcePage - 1), //Math.max( 0, isForward ? this.currentPage - 2 : this.currentPage ),\n\t\t\tcurrentIndex = this.currentPage - 1;\n\n\t\t// Set the source page *after* we have identified th startingIndex.\n\t\tthis.sourcePage = this.currentPage;\n\n\t\t$formBody.css({ width: $formBody.width()! });\n\t\t$formBody.find('.gform_page').css({ width: $formBody.width()! });\n\n\t\tthis.$formElem.addClass('swiper');\n\t\tthis.$formElem.find('.gform_body').addClass('swiper-wrapper gform-theme__no-reset--el');\n\t\tthis.$formElem\n\t\t\t.find('.gform_page')\n\t\t\t.attr('style', '')\n\t\t\t.addClass('swiper-slide gform-theme__no-reset--el')\n\n\t\tthis.swiper = new window.GPPageTransitionsSwiper.Swiper(\n\t\t\tthis.$formElem[0],\n\t\t\twindow.gform.applyFilters(\n\t\t\t\t'gppt_swiper_options',\n\t\t\t\t$.extend(\n\t\t\t\t\t{},\n\t\t\t\t\t{\n\t\t\t\t\t\tinitialSlide: startingIndex,\n\t\t\t\t\t\tfadeEffect: { crossFade: true },\n\t\t\t\t\t\tmodules: [window.GPPageTransitionsSwiper.EffectFade],\n\t\t\t\t\t\ton: {\n\t\t\t\t\t\t\tbeforeTransitionStart: this.beforeTransition,\n\t\t\t\t\t\t\tslideChangeTransitionEnd: this.afterTransition,\n\t\t\t\t\t\t\tslideChange: this.slideChange,\n\t\t\t\t\t\t},\n\t\t\t\t\t\tnoSwipingSelector: '.gfield, .gform_page_fields',\n\t\t\t\t\t\tpreventClicks: false,\n\t\t\t\t\t},\n\t\t\t\t\tthis.transitionSettings\n\t\t\t\t),\n\t\t\t\tthis\n\t\t\t)\n\t\t);\n\n\t\tthis.conditionalLogicDisableSlides();\n\n\t\tthis.swiper.slideTo(this.getCurrentPageSlideIndex());\n\n\t\tthis.updateInertAttr();\n\n\t\t/*\n\t\t * If soft validation is disabled, we need to work around an issue where the GF 'submit' handler will look for\n\t\t * any _disabled_ next buttons that are visible (which they will be since they won't be display: none;) and\n\t\t * prevent submission from occurring.\n\t\t */\n\t\tif (!this.enableSoftValidation) {\n\t\t\tthis.$formElem.on('submit.gppt', () => {\n\t\t\t\t// Remove any next buttons on pages outside of the current page\n\t\t\t\tthis.$formElem.find('.swiper-slide:not(.swiper-slide-active) .gform_next_button').remove();\n\t\t\t});\n\t\t}\n\n\t\t// resize form body anytime form DOM changes (e.g. adding a row via the list field) or if fields are hidden/shown\n\t\tthis.observer = new MutationObserver((mutations) => {\n\t\t\tmutationLoop: for (let i = 0; i < mutations.length; i++) {\n\t\t\t\t// find the first non-text node (removed or added) and trigger our resize\n\t\t\t\t// otherwise resize is fired when we update any text which can be problematic\n\t\t\t\tif ( mutations[i].type === 'childList' ) {\n\t\t\t\t\tconst nodes =\n\t\t\t\t\t\tmutations[i].addedNodes.length > 0\n\t\t\t\t\t\t\t? mutations[i].addedNodes\n\t\t\t\t\t\t\t: mutations[i].removedNodes;\n\n\t\t\t\t\tfor (let j = 0; j < nodes.length; j++) {\n\t\t\t\t\t\tif (nodes[j].nodeType !== 3) {\n\t\t\t\t\t\t\tthis.swiper?.updateAutoHeight(\n\t\t\t\t\t\t\t\tthis.transitionSettings.speed / 4\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\tbreak mutationLoop;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} else if ( mutations[i].type === 'attributes' && mutations[i].attributeName === 'style' ) {\n\t\t\t\t\tthis.swiper?.updateAutoHeight(\n\t\t\t\t\t\tthis.transitionSettings.speed / 4\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\tthis.observer.observe(this.$formElem[0], {\n\t\t\tchildList: true,\n\t\t\tsubtree: true,\n\t\t\tattributes: true,\n\t\t\tattributeFilter: ['style'],\n\t\t});\n\n\t\tif (this.submission.hasError && startingIndex !== currentIndex) {\n\t\t\tthis.updateProgressIndicator(this.currentPage);\n\t\t}\n\n\t\t/**\n\t\t * Listen to scroll events on the Swiper container to always ensure that the scrollTop is 0.\n\t\t *\n\t\t * These scroll events will frequently be triggered by an element being focused.\n\t\t */\n\t\tthis.$formElem.on('scroll', () => {\n\t\t\tthis.$formElem.scrollTop(0);\n\t\t});\n\n\t\t// @ts-ignore\n\t\twindow[`GPPT_${this.formId}`] = self;\n\t}\n\n\tsetCurrentPage(currentPage: number | string) {\n\t\tif (typeof currentPage === 'string') {\n\t\t\tcurrentPage = parseInt(currentPage);\n\t\t}\n\n\t\tlet triggerSubmit = false;\n\n\t\tthis.$currentPage = this.$formElem.find('.gform_page.swiper-slide-active');\n\n\t\t/*\n\t\t * If this.$currentPage is not found, we may have arrived on the page due to AJAX request (not Soft Validation).\n\t\t *\n\t\t * In that case, get the current visible page.\n\t\t */\n\t\tif ( ! this.$currentPage.length ) {\n\t\t\tthis.$currentPage = this.$formElem.find('.gform_page').filter(':visible').first();\n\t\t}\n\n\t\t/*\n\t\t * If currentPage passed is 0, the intention is to trigger a form submission.\n\t\t * We have listeners on form submit which should go to the next page with errors or fully submit.\n\t\t * But first, we need to determine the current page for the sake of transitions.\n\t\t */\n\t\tif (currentPage === 0) {\n\t\t\tconst $visiblePages = this.$formElem.find('.gform_page').filter(':visible');\n\t\t\tconst currentPageIndex = $visiblePages.index(this.$currentPage);\n\n\t\t\tcurrentPage = currentPageIndex + 1;\n\t\t\ttriggerSubmit = true;\n\t\t}\n\n\t\tthis.currentPage = currentPage;\n\n\t\tthis.setState();\n\n\t\t// See block above where we handle currentPage === 0.\n\t\tif (triggerSubmit) {\n\t\t\tthis.$formElem.trigger('submit');\n\n\t\t\treturn;\n\t\t}\n\n\t\t// If we're not on the last page.\n\t\tif (this.hideNextButton) {\n\t\t\tconst $nextButton = this.$currentPage.find('[id^=\"gform_next_button_\"]');\n\n\t\t\tif (!this.isOnLastPage()) {\n\t\t\t\tthis.$formElem.find('.gform_next_button').each((_, el) => {\n\t\t\t\t\tconst $el = $(el);\n\t\t\t\t\tif ( $el.parent().hasClass('gppt-show') ) {\n\t\t\t\t\t\t$el.parent().removeClass('gppt-show').addClass('gppt-hide');\n\t\t\t\t\t}\n\n\t\t\t\t\tif ( $el.data('original-value') ) {\n\t\t\t\t\t\t$el.val($el.data('original-value'));\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\tif (this.hideNextButton && this.hidePrevButton) {\n\t\t\t\t\tthis.$formElem?.addClass('gppt-no-buttons');\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tthis.updateProgressIndicator(this.currentPage);\n\t}\n\n\tconditionalLogicDisableSlides() {\n\t\tconst pageCl = this.gfPageConditionalLogic;\n\n\t\tif (!pageCl || !this.swiper) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Add/remove slides based on visibility\n\t\tfor (let i = 0; i < pageCl.options.pages.length; i++) {\n\t\t\tconst page = pageCl.options.pages[i];\n\n\t\t\tconst $slide = this.$formElem\n\t\t\t\t.find('.swiper-wrapper')\n\t\t\t\t.children('.gform_page ')\n\t\t\t\t.eq(i + 1);\n\n\t\t\tif (!pageCl.isPageVisible(page)) {\n\t\t\t\t$slide\n\t\t\t\t\t.removeClass(\n\t\t\t\t\t\t'swiper-slide swiper-slide-next slider-slide-prev'\n\t\t\t\t\t)\n\t\t\t\t\t.addClass('swiper-slide-disabled')\n\t\t\t\t\t.css({ display: 'none' });\n\t\t\t} else {\n\t\t\t\t$slide\n\t\t\t\t\t.removeClass('swiper-slide-disabled')\n\t\t\t\t\t.addClass('swiper-slide')\n\t\t\t\t\t.css({ display: '' });\n\t\t\t}\n\t\t}\n\n\t\tthis.swiper.updateSlides();\n\t\tthis.swiper.updateSlidesClasses();\n\t}\n\n\tsetState() {\n\t\tconst state = window?.gform?.state?.get( this.formId, 'pagination/pages' );\n\n\t\tif (state) {\n\t\t\tstate.currentPage = this.currentPage;\n\n\t\t\t// When switching pages with AJAX, this logic may run before swiper is initialized so we won't be able to get the index.\n\t\t\tif ( this.getCurrentPageSlideIndex() !== -1 ) {\n\t\t\t\tstate.currentStep = this.getCurrentPageSlideIndex() + 1;\n\t\t\t}\n\n\t\t\twindow.gform.state.set( this.formId, 'pagination/pages', state );\n\t\t}\n\t}\n\n\tbindEvents() {\n\t\tif (!this.$formElem) {\n\t\t\treturn;\n\t\t}\n\n\t\t/*\n\t\t * GF 2.9 compatibility.\n\t\t *\n\t\t * There's a ton of (great) improvements in https://github.com/gravityforms/gravityforms/pull/2966, but one of\n\t\t * the problematic changes specifically for GPPT/Swiper is that it considers any page that's not hidden to be\n\t\t * the current page.\n\t\t *\n\t\t * This logic watches the state and updates the page, step, and previous page values to be accurate in the\n\t\t * context of GPPT.\n\t\t */\n\t\twindow?.gform?.state?.watch( this.formId, [ 'pagination/pages' ], () => {\n\t\t\t// Set state as soon as we can to match GPPT.\n\t\t\tthis.setState();\n\t\t} );\n\n\t\twindow?.gform?.state?.watch( this.formId, [ 'pagination/pages' ], () => {\n\t\t\tconst state = window.gform.state.get( this.formId, 'pagination/pages' );\n\n\t\t\t// GF has its own watch on the same state, so we need to ensure our update comes after.\n\t\t\trequestAnimationFrame(() => {\n\t\t\t\t// Due to the race conditions until we get more API access, there is a chance that the state is not set.\n\t\t\t\tthis.setState();\n\t\t\t\tthis.updateProgressIndicator(state.currentPage);\n\t\t\t});\n\t\t} );\n\n\t\twindow.gform.addAction(\n\t\t\t'gform_frontend_pages_evaluated',\n\t\t\t(pages: any, formId: number, self: any) => {\n\t\t\t\tif (formId === this.formId) {\n\t\t\t\t\tthis.gfPageConditionalLogic = self;\n\t\t\t\t\tthis.conditionalLogicDisableSlides();\n\n\t\t\t\t\t/*\n\t\t\t\t\t * Ensure Swiper is initialized, so we're not immediately updating the progress indicator on load which\n\t\t\t\t\t * can make for an awkward animation.\n\t\t\t\t\t */\n\t\t\t\t\tif (this.swiper) {\n\t\t\t\t\t\tthis.updateProgressIndicator(this.currentPage);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t);\n\n\t\tif (this.enablePageTransitions) {\n\t\t\tif (!this.hasConditionalLogic) {\n\t\t\t\tthis.initPageTransitions();\n\t\t\t} else {\n\t\t\t\t$(document).bind('gform_post_conditional_logic', () => {\n\t\t\t\t\tif (!this.swiper && this.$formElem.is(':visible')) {\n\t\t\t\t\t\tthis.initPageTransitions();\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\n\t\tif (this.enablePageTransitions && this.enableSoftValidation) {\n\t\t\tconst $previousButtons = this.$formElem.find(\n\t\t\t\t\t'.gform_previous_button'\n\t\t\t\t),\n\t\t\t\t$nextButtons = this.$formElem.find('.gform_next_button'),\n\t\t\t\t$saveButton = this.$formElem.find('.gform_save_link');\n\n\t\t\t// Handle clicking the submit button as well as using the enter button, excluding the save and continue buttons.\n\t\t\tthis.$formElem.on('submit', (event): void | false => {\n\t\t\t\t// Bypass our logic if the user clicked the Save & Continue button or GP Multi-page Navigation buttons.\n\t\t\t\tif ( document.activeElement\n\t\t\t\t\t&& (\n\t\t\t\t\t\t$(document.activeElement).is('.gform_save_link') ||\n\t\t\t\t\t\t$(document.activeElement).is('.gform_resubmit_button') ||\n\t\t\t\t\t\t$(document.activeElement).is('.gform_next_page_errors_button')\n\t\t\t\t\t)\n\t\t\t\t) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tconst valid = this.validate();\n\n\t\t\t\t// If we're on the last page, let the form submit.\n\t\t\t\tif (valid && this.isOnLastPage()) {\n\t\t\t\t\t// Ensure target page number is 0 right before submission for things like honeypot, etc if the\n\t\t\t\t\t// last _actual_ page is visible.\n\t\t\t\t\tif ( this.$formElem.find('.gform_page:last').is(':visible') ) {\n\t\t\t\t\t\t$(`#gform_target_page_number_${this.formId}`).val(0);\n\t\t\t\t\t}\n\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\t// @ts-ignore\n\t\t\t\twindow[`gf_submitting_${this.formId}`] = false;\n\n\t\t\t\tthis.removeSpinner();\n\t\t\t\tevent.preventDefault();\n\n\t\t\t\tif (valid) {\n\t\t\t\t\tthis.$currentPage.find($nextButtons).filter(':visible').trigger('click');\n\t\t\t\t} else {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t});\n\n\t\t\t$previousButtons.each((_, el) => {\n\t\t\t\t$(el)\n\t\t\t\t\t.attr('type', 'button')\n\t\t\t\t\t.attr('onclick', '')\n\t\t\t\t\t.attr('onkeypress', '')\n\t\t\t\t\t.on('click keypress', (event) => {\n\t\t\t\t\t\t// previous button on last page is a submit button (yeah, no idea)\n\t\t\t\t\t\tevent.preventDefault();\n\n\t\t\t\t\t\tif (\n\t\t\t\t\t\t\tevent.type === 'click' &&\n\t\t\t\t\t\t\t// @ts-ignore\n\t\t\t\t\t\t\tevent.originalEvent.detail === 0\n\t\t\t\t\t\t) {\n\t\t\t\t\t\t\tif (this.validate()) {\n\t\t\t\t\t\t\t\tthis.$formElem.trigger('nextPage.gppt', [\n\t\t\t\t\t\t\t\t\tthis.currentPage + 1,\n\t\t\t\t\t\t\t\t\tthis.currentPage,\n\t\t\t\t\t\t\t\t\tthis.formId,\n\t\t\t\t\t\t\t\t]);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tthis.$formElem.trigger('prevPage.gppt', [\n\t\t\t\t\t\t\tthis.currentPage - 1,\n\t\t\t\t\t\t\tthis.currentPage,\n\t\t\t\t\t\t\tthis.formId,\n\t\t\t\t\t\t]);\n\t\t\t\t\t});\n\t\t\t});\n\n\t\t\t$nextButtons.each((_, el) => {\n\t\t\t\t$(el)\n\t\t\t\t\t.attr('onclick', '')\n\t\t\t\t\t.attr('onkeypress', '')\n\t\t\t\t\t.on('click touchend', (event) => {\n\t\t\t\t\t\t// We explicitly do not bind to the keypress event here as the form submit handler will catch it.\n\n\t\t\t\t\t\t// If this event is 'touchend', prevent the synthetic click event.\n\t\t\t\t\t\tif (event.type === 'touchend') {\n\t\t\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (this.validate()) {\n\t\t\t\t\t\t\t// If the current page has reached the limit, it's time to submit\n\t\t\t\t\t\t\tif ( this.isOnLastPage() ){\n\t\t\t\t\t\t\t\t$( '#gform_' + this.formId ).submit();\n\n\t\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tthis.$formElem.trigger('nextPage.gppt', [\n\t\t\t\t\t\t\t\tparseInt(this.currentPage as unknown as string) + 1,\n\t\t\t\t\t\t\t\tthis.currentPage,\n\t\t\t\t\t\t\t\tthis.formId,\n\t\t\t\t\t\t\t]);\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t});\n\n\t\t\tthis.$formElem.on(\n\t\t\t\t'prevPage.gppt',\n\t\t\t\t(event, newPage, oldPage, formId) => {\n\t\t\t\t\tthis.sourcePage = oldPage;\n\n\t\t\t\t\tthis.swiper?.slidePrev();\n\t\t\t\t\tthis.$formElem.trigger('softValidationPageLoad.gppt', [\n\t\t\t\t\t\tnewPage,\n\t\t\t\t\t\toldPage,\n\t\t\t\t\t\tformId,\n\t\t\t\t\t]);\n\t\t\t\t}\n\t\t\t);\n\n\t\t\tthis.$formElem.on(\n\t\t\t\t'nextPage.gppt',\n\t\t\t\t(event, newPage, oldPage, formId) => {\n\t\t\t\t\tthis.sourcePage = oldPage;\n\n\t\t\t\t\tthis.swiper?.slideNext();\n\t\t\t\t\tthis.$formElem.trigger('softValidationPageLoad.gppt', [\n\t\t\t\t\t\tnewPage,\n\t\t\t\t\t\toldPage,\n\t\t\t\t\t\tformId,\n\t\t\t\t\t]);\n\n\t\t\t\t}\n\t\t\t);\n\n\t\t\t/*\n\t\t\t * Finish initialization for Nested Form fields that were originally hidden. This is only used for soft validation as soft validation does not trigger gform_post_render as of writing.\n\t\t\t *\n\t\t\t * gform_post_render maybe the best route to go here at some point, but it caused issues with GPNF where it'd try to reinit Knockout, but Knockout would fail to since the template\n\t\t\t * HTML would be missing after the original KO init.\n\t\t\t */\n\t\t\tthis.$formElem.on('softValidationPageLoad.gppt', (\n\t\t\t\tevent,\n\t\t\t\tnewPage,\n\t\t\t\toldPage,\n\t\t\t\tformId\n\t\t\t) => {\n\t\t\t\t// Update the hidden inputs for source and target page numbers.\n\t\t\t\t$(`#gform_source_page_number_${formId}`).val(this.getCurrentPageRealIndex() + 1);\n\n\t\t\t\t/*\n\t\t\t\t * Set the target page number to the next expected page. Note, we don't set the target page number to 0\n\t\t\t\t * as we ensure it is '0' right before submission if it's truly the last page.\n\t\t\t\t */\n\t\t\t\t$(`#gform_target_page_number_${formId}`).val(this.getCurrentPageRealIndex() + 2);\n\n\t\t\t\t// GP Nested Forms compatibility\n\t\t\t\tfor (const k in window) {\n\t\t\t\t\tif (\n\t\t\t\t\t\twindow.hasOwnProperty(k) &&\n\t\t\t\t\t\tk.indexOf('GPNestedForms_' + formId + '_') === 0\n\t\t\t\t\t) {\n\t\t\t\t\t\tconst gpnf: any = window[k];\n\n\t\t\t\t\t\tif (\n\t\t\t\t\t\t\tgpnf.hasOwnProperty('finalizeInit') &&\n\t\t\t\t\t\t\t!gpnf.inHiddenPage() &&\n\t\t\t\t\t\t\t!gpnf.initialized\n\t\t\t\t\t\t) {\n\t\t\t\t\t\t\tgpnf.finalizeInit();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// Evaluate CL pages to do things like change the Next button to Submit.\n\t\t\t\tthis.gfPageConditionalLogic?.evaluatePages();\n\n\t\t\t\tthis.setCurrentPage(newPage);\n\n\t\t\t\t/*\n\t\t\t\t * 2.9 compatibility\n\t\t\t\t *\n\t\t\t\t * The listener for `updateNextButton` is on `gform/conditionalLogic/applyRules/end` rather than the new\n\t\t\t\t * `gform/frontend_pages/evaluated`\n\t\t\t\t *\n\t\t\t\t * Needs to come after `setCurrentPage` as it relies on the current page.\n\t\t\t\t */\n\t\t\t\t//\n\t\t\t\twindow?.gform?.utils?.trigger( {\n\t\t\t\t\tevent: 'gform/conditionalLogic/applyRules/end',\n\t\t\t\t\tnative: false,\n\t\t\t\t\tdata: { formId: this.formId, fields: [], isInit: false },\n\t\t\t\t} );\n\t\t\t});\n\t\t}\n\n\t\tif (this.enableAutoProgress) {\n\t\t\tconst attachEvents = (_: number, el: Element) => {\n\t\t\t\tconst $pageElem = $(el);\n\t\t\t\tconst $fields = $pageElem.find(\n\t\t\t\t\t'.gfield.gppt-auto-progress-field'\n\t\t\t\t);\n\n\t\t\t\t$fields.each(\n\t\t\t\t\t// eslint-disable-next-line @typescript-eslint/no-shadow\n\t\t\t\t\t(_, el) => {\n\t\t\t\t\t\tconst $field = $(el);\n\t\t\t\t\t\tconst events = ['gpptAutoProgress'];\n\n\t\t\t\t\t\tlet $inputs = $();\n\n\t\t\t\t\t\tif (\n\t\t\t\t\t\t\t$field.find('input[value=\"gf_other_choice\"]').length\n\t\t\t\t\t\t) {\n\t\t\t\t\t\t\t// any radio button except the \"other\" radio button\n\t\t\t\t\t\t\t$inputs = $inputs.add(\n\t\t\t\t\t\t\t\t$field.find(\n\t\t\t\t\t\t\t\t\t'input[type=\"radio\"][value!=\"gf_other_choice\"]'\n\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\tevents.push('change');\n\t\t\t\t\t\t} else if ($field.find('.gsurvey-likert').length) {\n\t\t\t\t\t\t\t$inputs = $inputs.add(\n\t\t\t\t\t\t\t\t$field.find(\n\t\t\t\t\t\t\t\t\t'.gsurvey-likert tbody tr:last-child input'\n\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\tevents.push('change');\n\t\t\t\t\t\t} else if ($field.find('.gsurvey-rating').length) {\n\t\t\t\t\t\t\t$inputs = $inputs.add(\n\t\t\t\t\t\t\t\t$field.find('.gsurvey-rating label')\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\tevents.push('click');\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tconst $currentInputs = $field\n\t\t\t\t\t\t\t\t.find('input, select')\n\t\t\t\t\t\t\t\t.not('input[type=\"hidden\"]');\n\n\t\t\t\t\t\t\tif ($currentInputs.length) {\n\t\t\t\t\t\t\t\t/*\n\t\t\t\t\t\t\t\t * If radio field, include all inputs, otherwise only include the last input\n\t\t\t\t\t\t\t\t * in a set of inputs as it could potentially cause the form to progress\n\t\t\t\t\t\t\t\t * too early.\n\t\t\t\t\t\t\t\t */\n\t\t\t\t\t\t\t\tif ($currentInputs.is(':radio')) {\n\t\t\t\t\t\t\t\t\t$inputs = $inputs.add($currentInputs);\n\n\t\t\t\t\t\t\t\t\t// Add \"click\" event for radio fields in case the user is clicking on an already selected radio button.\n\t\t\t\t\t\t\t\t\tevents.push('click');\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t$inputs = $inputs.add(\n\t\t\t\t\t\t\t\t\t\t$currentInputs.last()\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t// filter out text inputs; they are exclusively handled by input masks via gpptAutoProgress\n\t\t\t\t\t\t\t\tif (!$currentInputs.is(':text')) {\n\t\t\t\t\t\t\t\t\tevents.push('change');\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t// Auto Progress functionality for GP Advanced Phone Field\n\t\t\t\t\t\t\t\tconst { formId } = this;\n\n\t\t\t\t\t\t\t\t$currentInputs.on('keyup', function () {\n\t\t\t\t\t\t\t\t\tif (!$field.find('.iti').length) {\n\t\t\t\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\tconst fieldId = $field?.attr('id')?.split('_')[2];\n\n\t\t\t\t\t\t\t\t\t// @ts-ignore\n\t\t\t\t\t\t\t\t\tconst gpapf = window?.[`gp_advanced_phone_field_${formId}_${fieldId}`];\n\n\t\t\t\t\t\t\t\t\tif (gpapf?.iti) {\n\t\t\t\t\t\t\t\t\t\tconst {iti} = gpapf;\n\n\t\t\t\t\t\t\t\t\t\t// Ensure phone number is valid before auto-progressing\n\t\t\t\t\t\t\t\t\t\tconst value = $(this).val()?.toString().trim();\n\t\t\t\t\t\t\t\t\t\tconst isValid = iti.isValidNumber(value);\n\n\t\t\t\t\t\t\t\t\t\tif (isValid) {\n\t\t\t\t\t\t\t\t\t\t\tjQuery(this).trigger('gpptAutoProgress');\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (!$inputs) {\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t$inputs.on(events.join(' '), (event) => {\n\t\t\t\t\t\t\tconst $this = $(event.currentTarget);\n\n\t\t\t\t\t\t\t// Save the timeout to the input data so this callback only runs once. For instance,\n\t\t\t\t\t\t\t// if both change and click are triggered, we only want to run this callback once.\n\t\t\t\t\t\t\tif ($this.data('gpptAutoProgressTimeout')) {\n\t\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t// Move handler to the bottom of the stack to ensure\n\t\t\t\t\t\t\t// that conditional fields are shown/hidden before we check\n\t\t\t\t\t\t\t// if this is the last field in the form\n\t\t\t\t\t\t\tconst timeout = window.setTimeout(() => {\n\t\t\t\t\t\t\t\t// eslint-disable-next-line @typescript-eslint/no-shadow\n\t\t\t\t\t\t\t\tconst $field = $this.parents('.gfield');\n\n\t\t\t\t\t\t\t\tif (\n\t\t\t\t\t\t\t\t\t!$pageElem\n\t\t\t\t\t\t\t\t\t\t.find('.gfield:visible:not(.gfield_html):last')\n\t\t\t\t\t\t\t\t\t\t.is($field)\n\t\t\t\t\t\t\t\t) {\n\t\t\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\tif ($pageElem.is('.swiper-disabled')) {\n\t\t\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\tlet $nextButton = $pageElem.find(\n\t\t\t\t\t\t\t\t\t'.gform_next_button'\n\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\tif ($nextButton.length) {\n\t\t\t\t\t\t\t\t\t$nextButton.click();\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t/* eslint-disable jsdoc/no-undefined-types */\n\t\t\t\t\t\t\t\t\t/**\n\t\t\t\t\t\t\t\t\t * Filter whether to automatically submit the form on last page after selecting\n\t\t\t\t\t\t\t\t\t * the last auto-progression-supported input.\n\t\t\t\t\t\t\t\t\t *\n\t\t\t\t\t\t\t\t\t * @since 1.0-beta-1.29\n\t\t\t\t\t\t\t\t\t *\n\t\t\t\t\t\t\t\t\t * @param {boolean} autoSubmit Whether to auto-submit.\n\t\t\t\t\t\t\t\t\t * @param {number} formId Current form ID.\n\t\t\t\t\t\t\t\t\t * @param {JQuery} $trigger Input triggering the auto-progression.\n\t\t\t\t\t\t\t\t\t * @param {GPPageTransitions} instance Current instance of GP Page Transitions.\n\t\t\t\t\t\t\t\t\t */\n\t\t\t\t\t\t\t\t\tconst autoSubmit = window.gform.applyFilters(\n\t\t\t\t\t\t\t\t\t\t'gppt_auto_submit',\n\t\t\t\t\t\t\t\t\t\tfalse,\n\t\t\t\t\t\t\t\t\t\tthis.formId,\n\t\t\t\t\t\t\t\t\t\t$this,\n\t\t\t\t\t\t\t\t\t\tself\n\t\t\t\t\t\t\t\t\t);\n\n\t\t\t\t\t\t\t\t\tif (this.hideNextButton && this.isOnLastPage()) {\n\t\t\t\t\t\t\t\t\t\t$nextButton = this.$currentPage.find('[id^=\"gform_next_button_\"]');\n\n\t\t\t\t\t\t\t\t\t\t$nextButton.parent()\n\t\t\t\t\t\t\t\t\t\t\t.removeClass('gppt-hide')\n\t\t\t\t\t\t\t\t\t\t\t.addClass('gppt-show');\n\n\t\t\t\t\t\t\t\t\t\t$nextButton\n\t\t\t\t\t\t\t\t\t\t\t.data('original-value', $nextButton.val()!)\n\t\t\t\t\t\t\t\t\t\t\t.val(this.$formElem.find('[id^=\"gform_submit_button_\"]').val() as string | number);\n\n\t\t\t\t\t\t\t\t\t\tthis.$formElem?.removeClass('gppt-no-buttons');\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t// eslint-disable-next-line no-lonely-if\n\t\t\t\t\t\t\t\t\tif (autoSubmit) {\n\t\t\t\t\t\t\t\t\t\t$(\n\t\t\t\t\t\t\t\t\t\t\t'#gform_submit_button_' +\n\t\t\t\t\t\t\t\t\t\t\t\tthis.formId\n\t\t\t\t\t\t\t\t\t\t).add(this.$currentPage.find('[id^=\"gform_next_button_\"]')).each(function() {\n\t\t\t\t\t\t\t\t\t\t\t$(this).trigger('click');\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t\t$(\n\t\t\t\t\t\t\t\t\t\t\t'#gform_submit_button_' +\n\t\t\t\t\t\t\t\t\t\t\t\tthis.formId\n\t\t\t\t\t\t\t\t\t\t).focus();\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t$this.removeData('gpptAutoProgressTimeout');\n\t\t\t\t\t\t\t}, 0);\n\n\t\t\t\t\t\t\t$this.data('gpptAutoProgressTimeout', timeout);\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t);\n\t\t\t}\n\n\t\t\tthis.$formElem.find('.gform_page:not(.gppt-disable-auto-progress)').each(attachEvents);\n\n\t\t\t// After GPPA batch field update the attached events is lost, re-attach events.\n\t\t\t$(document).on(\n\t\t\t\t'gppa_updated_batch_fields',\n\t\t\t\t(event, formId, updatedFieldIds) => {\n\t\t\t\t\tif ( parseInt(formId) === this.formId) {\n\t\t\t\t\t\tfor (const id of updatedFieldIds) {\n\t\t\t\t\t\t\t$(`#field_${this.formId}_${id}`)\n\t\t\t\t\t\t\t\t.closest('.gform_page:not(.gppt-disable-auto-progress)')\n\t\t\t\t\t\t\t\t.each(attachEvents);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t);\n\n\t\t\t// trigger a change event on Datepicker selection for auto-progress-enabled Datepicker fields.\n\t\t\twindow.gform.addFilter(\n\t\t\t\t'gform_datepicker_options_pre_init',\n\t\t\t\t(options: any, formId: number, fieldId: number) => {\n\t\t\t\t\t// eslint-disable-next-line eqeqeq\n\t\t\t\t\tif (\n\t\t\t\t\t\tformId !== this.formId ||\n\t\t\t\t\t\t!$(`#input_${formId}_${fieldId}`)\n\t\t\t\t\t\t\t.parents('.gfield')\n\t\t\t\t\t\t\t.hasClass('gppt-auto-progress-field')\n\t\t\t\t\t) {\n\t\t\t\t\t\treturn options;\n\t\t\t\t\t}\n\n\t\t\t\t\tconst onSelect = options.onSelect;\n\n\t\t\t\t\toptions.onSelect = function() {\n\t\t\t\t\t\tif (typeof onSelect === 'function') {\n\t\t\t\t\t\t\tonSelect();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$(this).trigger('gpptAutoProgress');\n\t\t\t\t\t};\n\n\t\t\t\t\treturn options;\n\t\t\t\t}\n\t\t\t);\n\n\t\t\t// show AJAX spinner on Previous button if not other button is visible (specifically if Next button is hidden)\n\t\t\twindow.gform.addFilter(\n\t\t\t\t'gform_spinner_target_elem',\n\t\t\t\t($target: JQuery) => {\n\t\t\t\t\tconst selectors = [\n\t\t\t\t\t\t'#gform_submit_button_' + this.formId + ':visible',\n\t\t\t\t\t\t'.gform_next_button:visible',\n\t\t\t\t\t\t'.gform_previous_button:visible',\n\t\t\t\t\t];\n\t\t\t\t\tfor (let i = 0; i < selectors.length; i++) {\n\t\t\t\t\t\tconst $newTarget = this.$currentPage.find(selectors[i]);\n\t\t\t\t\t\tif ($newTarget.length > 0) {\n\t\t\t\t\t\t\treturn $newTarget;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\treturn $target;\n\t\t\t\t}\n\t\t\t);\n\t\t}\n\t}\n\n\t/**\n\t * Force remove the spinner if it gets added when progressing pages.\n\t *\n\t * Useful if using Soft Validation.\n\t */\n\tremoveSpinner() {\n\t\tconst $spinnerTarget = window.gform.applyFilters(\n\t\t\t'gform_spinner_target_elem',\n\t\t\t$(\n\t\t\t\t'#gform_submit_button_' +\n\t\t\t\tthis.formId +\n\t\t\t\t', #gform_wrapper_' +\n\t\t\t\tthis.formId +\n\t\t\t\t' .gform_next_button, #gform_send_resume_link_button_' +\n\t\t\t\tthis.formId\n\t\t\t),\n\t\t\tthis.formId\n\t\t);\n\n\t\t$spinnerTarget.siblings('.gform_ajax_spinner, .gform-loader').remove();\n\t}\n\n\tvalidate() {\n\t\tconst currentSelectors =\n\t\t\tthis.validationSelectors[this.getCurrentPageRealIndex() + 1] ?? [];\n\t\tlet result = true;\n\n\t\tfor (let i = 0; i < currentSelectors.length; i++) {\n\t\t\tconst selector = currentSelectors[i];\n\t\t\tconst $inputs = this.getInput(\n\t\t\t\tselector.selectors.join(', '),\n\t\t\t\ttrue, // Bypass cache to ensure the node exists so we can add an error to it.\n\t\t\t);\n\t\t\tconst $parent = $inputs.parents('.gfield');\n\n\t\t\tlet isEmpty = false;\n\n\t\t\t// Condtionally hidden fields should not fails this validation.\n\t\t\tif (window.gformIsHidden($inputs)) {\n\t\t\t\tisEmpty = false;\n\t\t\t\t// Make sure at least one checkbox or radio button is checked.\n\t\t\t} else if ($inputs.is(':checkbox') || $inputs.is(':radio')) {\n\t\t\t\tisEmpty = $inputs.filter(':checked').length === 0;\n\t\t\t\t// support for multifile upload fields\n\t\t\t} else if (\n\t\t\t\t$inputs.is(':file') &&\n\t\t\t\twindow.gfMultiFileUploader.uploaders[\n\t\t\t\t\t`gform_multifile_upload_${this.formId}_${selector.id}`\n\t\t\t\t]\n\t\t\t) {\n\t\t\t\tconst uploader =\n\t\t\t\t\twindow.gfMultiFileUploader.uploaders[\n\t\t\t\t\t\t`gform_multifile_upload_${this.formId}_${selector.id}`\n\t\t\t\t\t];\n\n\t\t\t\tconst uploaderHiddenInput = $(`#gform_uploaded_files_${this.formId}`);\n\n\t\t\t\ttry {\n\t\t\t\t\tconst uploaderFiles = JSON.parse(uploaderHiddenInput.val() as string);\n\n\t\t\t\t\tisEmpty = uploaderFiles?.[`input_${selector.id}`].length <= 0;\n\t\t\t\t} catch (e) {\n\t\t\t\t\t// eslint-disable-next-line no-console\n\t\t\t\t\tconsole.debug(e);\n\t\t\t\t\tisEmpty = true;\n\t\t\t\t}\n\t\t\t} else if (selector.relation === 'any') {\n\t\t\t\tisEmpty = !$inputs.val();\n\t\t\t} else {\n\t\t\t\t$.each(\n\t\t\t\t\t$inputs,\n\t\t\t\t\t// @ts-ignore\n\t\t\t\t\t(_, el) => {\n\t\t\t\t\t\tif (!$(el).val() && !$(el).hasClass('gform_hidden')) {\n\t\t\t\t\t\t\tisEmpty = true;\n\t\t\t\t\t\t\treturn false;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t);\n\t\t\t}\n\n\t\t\tif (isEmpty) {\n\t\t\t\tif (!$parent.hasClass(this.validationClass.split(' ')[0])) {\n\t\t\t\t\t$parent.addClass(this.validationClass);\n\t\t\t\t\t$parent\n\t\t\t\t\t\t.children('.ginput_container')\n\t\t\t\t\t\t.after(\n\t\t\t\t\t\t\tthis.validationMessageContainer.gformFormat(\n\t\t\t\t\t\t\t\tselector.validationMessage\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t\tresult = false;\n\t\t\t} else if ($parent.hasClass(this.validationClass.split(' ')[0])) {\n\t\t\t\t$parent.removeClass(this.validationClass);\n\t\t\t\t$parent\n\t\t\t\t\t.children('.ginput_container')\n\t\t\t\t\t.next()\n\t\t\t\t\t.remove();\n\t\t\t}\n\n\t\t\t// Bypass soft validation for the Signature field so pages can at least be navigated and the form submitted.\n\t\t\t// Server-side validation will bring the user back to any unfilled Signature fields.\n\t\t\tif ($parent.hasClass('gfield--type-signature')) {\n\t\t\t\tresult = true;\n\t\t\t}\n\t\t}\n\n\t\tif (result) {\n\t\t\tthis.$formElem\n\t\t\t\t.parents('.gform_wrapper')\n\t\t\t\t.removeClass(this.validationClassForm);\n\t\t} else {\n\t\t\tthis.$formElem\n\t\t\t\t.parents('.gform_wrapper')\n\t\t\t\t.addClass(this.validationClassForm);\n\t\t}\n\n\t\t// If Soft Validation is to be skipped (GP Live Preview).\n\t\tif (this.skipSoftValidation) {\n\t\t\tresult = true;\n\t\t}\n\n\t\t// Force height to update in case the mutation observer doesn't catch it.\n\t\tthis.swiper?.updateAutoHeight(\n\t\t\tthis.transitionSettings.speed / 4\n\t\t);\n\n\t\t/*\n\t\t * Filter the Soft Validation result.\n\t\t *\n\t\t * @param {boolean} result Whether validation passed.\n\t\t * @param {GPPageTransitions} instance Current instance of the class.\n\t\t * @param {number} formId The current form ID.\n\t\t *\n\t\t * @since 1.0.32\n\t\t */\n\t\treturn window.gform.applyFilters(\n\t\t\t'gppt_validation_result',\n\t\t\tresult,\n\t\t\tthis,\n\t\t\tthis.formId\n\t\t);\n\t}\n\n\tgetNamespacedEvents(eventsString: string, namespace: string) {\n\t\tconst events = eventsString.split(' ');\n\t\tconst namespacedEvents = [];\n\n\t\tfor (let i = 0; i < events.length; i++) {\n\t\t\tnamespacedEvents.push(events[i] + '.' + namespace);\n\t\t}\n\n\t\treturn namespacedEvents.join(' ');\n\t}\n\n\tbeforeTransition = (swiper: Swiper.Swiper): void => {\n\t\tconst curr = swiper.clickedSlide;\n\t\tconst next = swiper.slides[swiper.activeIndex];\n\n\t\twindow.gform.doAction('gppt_before_transition', curr, next, this);\n\t\tthis.triggerSoftValidationConditionalLogic(next);\n\t\tthis.triggerPartialEntries();\n\n\t\tthis.updateInertAttr();\n\t};\n\n\tafterTransition = (): void => {\n\t\twindow.gform.doAction('gppt_after_transition', this);\n\t};\n\n\t/**\n\t * Scroll to the top of the form when changing slides/pages.\n\t */\n\tslideChange = (): void => {\n\t\tconst scrollTop = this.$formElem.parents('.gform_wrapper')?.offset()!.top - 50;\n\t\tconst currentScrollTop = $(window).scrollTop() ?? 0;\n\n\t\t// Only animate scrolling if the user is beyond the scroll top of the form top.\n\t\tif ( currentScrollTop < scrollTop ) {\n\t\t\treturn;\n\t\t}\n\n\t\t$('html, body').animate(\n\t\t\t{ scrollTop },\n\t\t\tthis.transitionSettings.speed\n\t\t);\n\t}\n\n\t/**\n\t * Add inert attribute on inactive slides to prevent tabbing to inactive tabs due to\n\t * https://github.com/nolimits4web/swiper/issues/4006\n\t */\n\tupdateInertAttr = (): void => {\n\t\tthis.$formElem.find('.gform_page:not(.swiper-slide-active)').attr('inert', '');\n\t\tthis.$formElem.find('.gform_page.swiper-slide-active').removeAttr('inert');\n\t}\n\n\t/**\n\t * When soft validation is enabled, partial entries doesn't work on page navigation.\n\t * We trigger the heartbeat API.\n\t */\n\ttriggerPartialEntries = (): void => {\n\t\tif ( this.enableSoftValidation && window.GF_Partial_Entries ) {\n\t\t\twindow.wp.heartbeat.connectNow();\n\t\t}\n\t}\n\n\t/**\n\t * Since conditional logic relies on visibility, we need to re-trigger conditional logic when transitioning between pages.\n\t *\n\t * We apply the rules to all fields with conditional logic in the next page.\n\t *\n\t * @param next HTMLDivElement The next page.\n\t */\n\ttriggerSoftValidationConditionalLogic(next: Element) {\n\t\tif (!this.enablePageTransitions || !this.enableSoftValidation) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst fieldIdsOnNextPage: any[] = [];\n\n\t\tif (\n\t\t\t!window.gf_form_conditional_logic ||\n\t\t\t!window.gf_form_conditional_logic[this.formId]\n\t\t) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst $nextPage = $(next);\n\n\t\t$.each(\n\t\t\twindow.gf_form_conditional_logic[this.formId].dependents,\n\t\t\t(fieldId: number) => {\n\t\t\t\tif (\n\t\t\t\t\t$nextPage.find('#field_' + this.formId + '_' + fieldId)\n\t\t\t\t\t\t.length\n\t\t\t\t) {\n\t\t\t\t\tfieldIdsOnNextPage.push(fieldId);\n\t\t\t\t}\n\t\t\t}\n\t\t);\n\n\t\trequestAnimationFrame(() => {\n\t\t\twindow.gf_apply_rules(this.formId, fieldIdsOnNextPage);\n\t\t});\n\t}\n\n\tupdateProgressIndicator(pageNumber: number, speed?: number) {\n\t\tif (!this.swiper) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this.pagination.type === 'none') {\n\t\t\treturn;\n\t\t}\n\n\t\tconst $progressIndicator =\n\t\t\tthis.pagination.type === 'steps'\n\t\t\t\t? $('#gf_page_steps_' + this.formId)\n\t\t\t\t: $('#gf_progressbar_wrapper_' + this.formId);\n\n\t\tif (typeof speed === 'undefined') {\n\t\t\tspeed = this.getProgressIndicatorTransitionSpeed();\n\t\t}\n\n\t\tif (this.pagination.isCustom) {\n\t\t\t$progressIndicator.fadeOut(speed!, () => {\n\t\t\t\tconst newProgressIndicator = $(\n\t\t\t\t\tthis.pagination.progressIndicators[pageNumber - 1]\n\t\t\t\t);\n\t\t\t\t$progressIndicator\n\t\t\t\t\t.html(newProgressIndicator.html())\n\t\t\t\t\t.fadeIn(this.getProgressIndicatorTransitionSpeed());\n\t\t\t});\n\t\t} else if (this.pagination.type === 'steps') {\n\t\t\tconst $steps = $progressIndicator.find('.gf_step');\n\t\t\t// eslint-disable-next-line @typescript-eslint/no-shadow\n\t\t\tlet pageNumber = 0;\n\n\t\t\t$steps\n\t\t\t\t.removeClass(\n\t\t\t\t\t'gf_step_completed gf_step_active gf_step_next gf_step_pending'\n\t\t\t\t)\n\t\t\t\t.each((i, el) => {\n\t\t\t\t\tconst $step = $(el);\n\n\t\t\t\t\tif ($step.hasClass('gf_step_hidden')) {\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\n\t\t\t\t\tpageNumber = pageNumber + 1;\n\n\t\t\t\t\tif (pageNumber < this.currentPage) {\n\t\t\t\t\t\t$step.addClass('gf_step_completed');\n\t\t\t\t\t} else if (pageNumber === this.currentPage) {\n\t\t\t\t\t\t$step.addClass('gf_step_active');\n\t\t\t\t\t} else if (pageNumber === this.currentPage + 1) {\n\t\t\t\t\t\t$step.addClass('gf_step_next');\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$step.addClass('gf_step_pending');\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t} else {\n\t\t\tconst $percentageBar = $progressIndicator.find(\n\t\t\t\t'.gf_progressbar_percentage'\n\t\t\t);\n\t\t\tconst $percentNumber = $percentageBar.children('span');\n\t\t\tconst currentPercentage = this.getProgressPercentage(\n\t\t\t\tthis.progressBarStartAtZero\n\t\t\t\t\t? this.sourcePage - 1\n\t\t\t\t\t: this.sourcePage\n\t\t\t);\n\t\t\tconst targetPercentage = this.getProgressPercentage(\n\t\t\t\tthis.progressBarStartAtZero\n\t\t\t\t\t? this.currentPage - 1\n\t\t\t\t\t: this.currentPage\n\t\t\t);\n\t\t\tconst isForward = targetPercentage > currentPercentage;\n\t\t\tconst $progressBarTitle = $progressIndicator.find(\n\t\t\t\t'.gf_progressbar_title'\n\t\t\t);\n\n\t\t\tconst pageName = this.getPaginationPages()[this.currentPage - 1];\n\t\t\tlet pageTitleSuffix = '';\n\n\t\t\tlet diffPoints = Math.abs(targetPercentage - currentPercentage);\n\n\t\t\tif (pageName) {\n\t\t\t\tpageTitleSuffix = ` – ${pageName}`;\n\t\t\t}\n\n\t\t\t$percentageBar\n\t\t\t\t.width(targetPercentage + '%')\n\t\t\t\t.removeClass((index, className) => {\n\t\t\t\t\treturn (className.match(/percentbar_\\d+/g) || []).join(' ');\n\t\t\t\t})\n\t\t\t\t.addClass(`percentbar_${targetPercentage}`);\n\n\t\t\tthis.currentPage = this.currentPage <= this.getVisiblePageCount() ? this.currentPage : this.getVisiblePageCount();\n\n\t\t\t$progressBarTitle.html(\n\t\t\t\tthis.pagination.labels.step +\n\t\t\t\t\t` ` +\n\t\t\t\t\t`${this.currentPage}` +\n\t\t\t\t\t` ${this.pagination.labels.of} ` +\n\t\t\t\t\t`${this.getVisiblePageCount()}\n\t\t\t\t\t${pageTitleSuffix}`\n\t\t\t);\n\n\t\t\t/*\n\t\t\t * Prevent multiple intervals from running at once. Unlikely to happen in the real-world, but can happen\n\t\t\t * with automated tests.\n\t\t\t */\n\t\t\tif (this.percentageInterval) {\n\t\t\t\tclearInterval(this.percentageInterval);\n\t\t\t}\n\n\t\t\tthis.percentageInterval = setInterval(() => {\n\t\t\t\t// eslint-disable-next-line @typescript-eslint/no-shadow\n\t\t\t\tconst currentPercentage =\n\t\t\t\t\ttargetPercentage -\n\t\t\t\t\t(isForward ? diffPoints : 0 - diffPoints);\n\t\t\t\tdiffPoints--;\n\t\t\t\t$percentNumber.text(currentPercentage + '%');\n\n\t\t\t\tif (currentPercentage === targetPercentage) {\n\t\t\t\t\tclearInterval(this.percentageInterval);\n\t\t\t\t}\n\t\t\t}, 1000 / diffPoints);\n\t\t}\n\t}\n\n\tgetVisiblePageCount(): number {\n\t\tconst pageCl = this.gfPageConditionalLogic;\n\n\t\tif (pageCl) {\n\t\t\tlet pageCount = 1;\n\n\t\t\tfor (let i = 0; i < pageCl.options.pages.length; i++) {\n\t\t\t\tconst page = pageCl.options.pages[i];\n\n\t\t\t\tif (pageCl.isPageVisible(page)) {\n\t\t\t\t\tpageCount++;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn pageCount;\n\t\t}\n\n\t\treturn this.pagination.pageCount;\n\t}\n\n\tisOnLastPage(): boolean {\n\t\treturn this.currentPage >= Number(this.getVisiblePageCount());\n\t}\n\n\tgetPaginationPages() {\n\t\tconst pageCl = this.gfPageConditionalLogic;\n\n\t\tif (pageCl) {\n\t\t\tconst pages = [this.pagination.pages[0]];\n\n\t\t\tfor (let i = 0; i < pageCl.options.pages.length; i++) {\n\t\t\t\tconst page = pageCl.options.pages[i];\n\n\t\t\t\tif (pageCl.isPageVisible(page)) {\n\t\t\t\t\tpages.push(this.pagination.pages[i + 1]);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn pages;\n\t\t}\n\n\t\treturn this.pagination.pages;\n\t}\n\n\tgetProgressIndicatorTransitionSpeed() {\n\t\treturn parseInt(this.transitionSettings.sync) === 1\n\t\t\t? this.transitionSettings.speed / 2\n\t\t\t: this.transitionSettings.speed;\n\t}\n\n\tgetProgressPercentage(currentPage: number) {\n\t\treturn Math.floor((currentPage / this.getVisiblePageCount()) * 100);\n\t}\n\n\tgetInput(selector: string, bypassCache?: boolean) {\n\t\tif (typeof this.inputs[selector] === 'undefined' || bypassCache) {\n\t\t\tthis.inputs[selector] = $(selector);\n\t\t}\n\n\t\treturn this.inputs[selector];\n\t}\n\n\tgetCurrentPageSlideIndex() {\n\t\tconst $activeSlides = this.$formElem\n\t\t\t.find('.swiper-slide:not(.swiper-slide-disabled');\n\n\t\tconst $currentSlide = this.$formElem.find( `#gform_page_${this.formId}_${this.currentPage}` );\n\n\t\treturn $activeSlides.index($currentSlide);\n\t}\n\n\t/**\n\t * this.currentPage takes conditional page logic into account which can cause lookups by initial page indexes\n\t * for things like validation selectors to return the wrong info.\n\t *\n\t * The way we fetch the \"real\" index is by using jQuery and getting the page's index in the DOM.\n\t */\n\tgetCurrentPageRealIndex() {\n\t\treturn this.$formElem\n\t\t\t.find('.gform_page')\n\t\t\t.index(this.$formElem.find('.gform_page.swiper-slide-active'));\n\t}\n}\n\nwindow.GPPageTransitions = GPPageTransitions;\n"],"names":["_createClass","defineProperties","target","props","i","length","descriptor","enumerable","configurable","writable","Object","defineProperty","key","Constructor","protoProps","staticProps","prototype","_classCallCheck","instance","TypeError","window","slice","Array","matches","Element","msMatchesSelector","_focusableElementsString","join","InertRoot","rootElement","inertManager","this","_inertManager","_rootElement","_managedNodes","Set","hasAttribute","_savedAriaHidden","getAttribute","setAttribute","_makeSubtreeUnfocusable","_observer","MutationObserver","_onMutation","bind","observe","attributes","childList","subtree","value","disconnect","removeAttribute","forEach","inertNode","_unmanageNode","node","startNode","_this2","composedTreeWalk","_visitNode","activeElement","document","body","contains","root","undefined","nodeType","Node","DOCUMENT_FRAGMENT_NODE","parentNode","blur","focus","ELEMENT_NODE","element","_adoptInertRoot","call","_manageNode","register","add","deregister","_this3","inertSubroot","getInertRoot","setInert","managedNodes","savedInertNode","records","self","record","type","addedNodes","removedNodes","_unmanageSubtree","attributeName","managedNode","get","set","ariaHidden","InertNode","inertRoot","_node","_overrodeFocusMethod","_inertRoots","_savedTabIndex","_destroyed","ensureUntabbable","_throwIfDestroyed","destroyed","Error","tabIndex","hasSavedTabIndex","size","destructor","InertManager","_document","Map","_watchForInert","addInertStyle","head","documentElement","readyState","addEventListener","_onDocumentLoaded","inert","has","parent","addInertRoot","removeInertRoot","querySelectorAll","inertElement","_this","inertElements","unshift","HTMLElement","hasOwnProperty","callback","shadowRootAncestor","shadowRoot","localName","content","distributedNodes","getDistributedNodes","slot","_distributedNodes","assignedNodes","flatten","_i","child","firstChild","nextSibling","querySelector","style","createElement","textContent","appendChild","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","exports","module","__webpack_modules__","n","getter","__esModule","d","a","definition","o","obj","prop","args","rules","initialized","sourcePage","inputs","functions","beforeTransition","swiper","curr","clickedSlide","next","slides","activeIndex","gform","doAction","triggerSoftValidationConditionalLogic","triggerPartialEntries","updateInertAttr","afterTransition","slideChange","scrollTop","$formElem","parents","offset","top","animate","transitionSettings","speed","find","attr","removeAttr","enableSoftValidation","GF_Partial_Entries","wp","heartbeat","connectNow","assign","init","currentPage","gformRedirect","submission","hasError","formId","setCurrentPage","bindEvents","initPageTransitions","pagination","pageCount","$formBody","startingIndex","Math","max","currentIndex","css","width","addClass","GPPageTransitionsSwiper","Swiper","applyFilters","initialSlide","fadeEffect","crossFade","modules","EffectFade","on","beforeTransitionStart","slideChangeTransitionEnd","noSwipingSelector","preventClicks","conditionalLogicDisableSlides","slideTo","getCurrentPageSlideIndex","remove","observer","mutations","mutationLoop","nodes","j","updateAutoHeight","attributeFilter","updateProgressIndicator","parseInt","triggerSubmit","$currentPage","filter","first","index","setState","trigger","hideNextButton","isOnLastPage","each","_","el","$el","hasClass","removeClass","data","val","hidePrevButton","pageCl","gfPageConditionalLogic","options","pages","page","$slide","children","eq","isPageVisible","display","updateSlides","updateSlidesClasses","state","currentStep","watch","requestAnimationFrame","addAction","enablePageTransitions","hasConditionalLogic","is","$previousButtons","event","valid","validate","removeSpinner","preventDefault","originalEvent","detail","submit","newPage","oldPage","slidePrev","slideNext","k","getCurrentPageRealIndex","indexOf","gpnf","inHiddenPage","finalizeInit","evaluatePages","utils","native","fields","isInit","enableAutoProgress","$pageElem","$field","events","$inputs","push","$currentInputs","not","last","fieldId","split","gpapf","iti","toString","trim","isValidNumber","jQuery","$this","currentTarget","timeout","setTimeout","$nextButton","click","autoSubmit","removeData","updatedFieldIds","id","closest","addFilter","onSelect","$target","selectors","$newTarget","siblings","currentSelectors","validationSelectors","result","selector","getInput","$parent","isEmpty","gformIsHidden","gfMultiFileUploader","uploaders","uploaderHiddenInput","uploaderFiles","JSON","parse","e","console","debug","relation","validationClass","after","validationMessageContainer","gformFormat","validationMessage","validationClassForm","skipSoftValidation","getNamespacedEvents","eventsString","namespace","namespacedEvents","fieldIdsOnNextPage","gf_form_conditional_logic","$nextPage","dependents","gf_apply_rules","pageNumber","$progressIndicator","getProgressIndicatorTransitionSpeed","isCustom","fadeOut","newProgressIndicator","progressIndicators","html","fadeIn","$steps","$step","$percentageBar","currentPercentage","getProgressPercentage","progressBarStartAtZero","$progressBarTitle","pageName","getPaginationPages","pageTitleSuffix","abs","className","match","getVisiblePageCount","labels","step","of","percentageInterval","clearInterval","setInterval","text","Number","sync","floor","bypassCache","$activeSlides","$currentSlide","GPPageTransitions"],"sourceRoot":""}